/* ========================================
   Social Game Database
======================================== */

/* ページ全体 */

.socialgame-page {
  box-sizing: border-box;
}

.socialgame-page *,
.socialgame-page *::before,
.socialgame-page *::after {
  box-sizing: border-box;
}


/* ========================================
   検索エリア
======================================== */

.socialgame-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: end;
  gap: 14px;
  margin: 0 0 36px;
}

.socialgame-search {
  display: block;
  min-width: 0;
}

.socialgame-search-label {
  display: block;
  margin-bottom: 6px;
  color: #5769b7;
  font-family: "Montserrat", "Zen Kaku Gothic New", sans-serif;
  font-size: 1.2rem;
  letter-spacing: 0.15em;
}

.socialgame-search input {
  display: block;
  width: 100%;
  margin: 0;
  padding: 12px 16px;

  color: inherit;
  background-color: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(87, 105, 183, 0.45);
  border-radius: 0;

  font: inherit;
}

.socialgame-search input:focus {
  background-color: #fff;
  border-color: #5769b7;
  outline: 2px solid rgba(135, 191, 242, 0.25);
  outline-offset: 2px;
}

.socialgame-clear-button {
  min-height: 48px;
  margin: 0;
  padding: 10px 20px;

  color: #5769b7;
  background-color: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(87, 105, 183, 0.45);
  border-radius: 0;

  font: inherit;
  cursor: pointer;

  transition:
    background-color 0.25s ease,
    border-color 0.25s ease,
    transform 0.25s ease;
}

.socialgame-result-count {
  min-width: 4.5em;
  margin: 0;
  padding-bottom: 12px;

  color: #9aa9b8;
  font-family: "Montserrat", sans-serif;
  font-size: 1rem;
  letter-spacing: 0.1em;
  text-align: right;
}

@media (hover: hover) {
  .socialgame-clear-button:hover {
    background-color: rgba(135, 191, 242, 0.22);
    border-color: rgba(87, 105, 183, 0.7);
    transform: translateY(-2px);
  }
}


/* ========================================
   カード一覧
======================================== */

.socialgame-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  align-items: stretch;
}

.socialgame-card {
  position: relative;
  min-width: 0;
  min-height: 230px;

  color: inherit;
  background: rgba(135, 191, 242, 0.08);
  border: 1px solid rgba(87, 105, 183, 0.3);

  overflow: hidden;

  transition:
    background-color 0.25s ease,
    border-color 0.25s ease,
    transform 0.25s ease;
}

.socialgame-card::before,
.socialgame-card::after {
  position: absolute;
  right: 20px;
  bottom: 20px;

  content: "";
  display: block;

  background: rgba(87, 105, 183, 0.5);

  transition:
    width 0.25s ease,
    height 0.25s ease;
}

.socialgame-card::before {
  width: 34px;
  height: 1px;
}

.socialgame-card::after {
  width: 1px;
  height: 34px;
}

.socialgame-card[hidden] {
  display: none;
}

.socialgame-card-link {
  position: relative;
  z-index: 1;

  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;

  padding: 28px 58px 28px 28px;

  color: inherit;
  text-decoration: none;
}

.socialgame-card-title {
  margin: 0 0 26px;

  color: #5769b7;
  font-size: clamp(1.6rem, 1.4rem + 0.5vw, 2.1rem);
  font-weight: normal;
  line-height: 1.45;
  letter-spacing: 0.1em;
}

.socialgame-card-properties {
  display: grid;
  gap: 14px;
  margin: 0;
}

.socialgame-property {
  display: grid;
  grid-template-columns: 8em minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.socialgame-property dt {
  margin: 0;

  color: #9aa9b8;
  font-family: "Montserrat", "Zen Kaku Gothic New", sans-serif;
  font-size: 0.95rem;
  letter-spacing: 0.1em;
}

.socialgame-property dd {
  min-width: 0;
  margin: 0;

  font-size: 1.2rem;
  line-height: 1.6;
  overflow-wrap: anywhere;
}

@media (hover: hover) {
  .socialgame-card:hover {
    background: rgba(135, 191, 242, 0.18);
    border-color: rgba(87, 105, 183, 0.55);
    transform: translateY(-4px);
  }

  .socialgame-card:hover::before {
    width: 46px;
  }

  .socialgame-card:hover::after {
    height: 46px;
  }
}


/* ========================================
   データなし・検索結果なし
======================================== */

.socialgame-empty,
.socialgame-no-results {
  margin: 40px 0 10px;

  color: #9aa9b8;
  text-align: center;
}


/* ========================================
   個別ページ
======================================== */

.socialgame-back {
  margin: 0 0 20px;
}

.socialgame-back a {
  display: inline-flex;
  align-items: center;

  padding: 9px 16px;

  color: #225b75;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(87, 105, 183, 0.35);

  font-size: 1.15rem;
  letter-spacing: 0.06em;
  text-decoration: none;

  transition:
    background-color 0.25s ease,
    transform 0.25s ease;
}

.socialgame-detail {
  max-width: 900px;
  margin: 0 auto;
  padding: 36px;

  color: #111;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(87, 105, 183, 0.3);

  backdrop-filter: blur(6px);
}

.socialgame-detail .titles {
  margin-top: 0;
  color: #174764;
  text-align: center;
}

.socialgame-detail-properties {
  display: grid;
  gap: 0;
  margin: 34px 0 0;

  border-top: 1px solid rgba(70, 120, 150, 0.2);
}

.socialgame-detail-property {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr);

  border-bottom: 1px solid rgba(70, 120, 150, 0.2);
}

.socialgame-detail-property dt,
.socialgame-detail-property dd {
  margin: 0;
  padding: 14px 16px;
}

.socialgame-detail-property dt {
  color: #16455d;
  background: rgba(122, 193, 220, 0.22);

  font-weight: 700;
  white-space: nowrap;
}

.socialgame-detail-property dd {
  min-width: 0;

  background: rgba(255, 255, 255, 0.4);

  line-height: 1.7;
  overflow-wrap: anywhere;
}

@media (hover: hover) {
  .socialgame-back a:hover {
    background: rgba(135, 191, 242, 0.28);
    transform: translateX(-4px);
  }
}


/* ========================================
   タブレット
======================================== */

@media screen and (max-width: 768px) {
  .socialgame-toolbar {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .socialgame-result-count {
    grid-column: 1 / -1;
    padding: 0;
  }

  .socialgame-card-grid {
    grid-template-columns: 1fr;
  }

  .socialgame-detail {
    padding: 28px 20px;
  }
}


/* ========================================
   スマホ
======================================== */

@media screen and (max-width: 520px) {
  .socialgame-toolbar {
    display: block;
  }

  .socialgame-clear-button {
    width: 100%;
    margin-top: 10px;
  }

  .socialgame-result-count {
    margin-top: 12px;
  }

  .socialgame-card {
    min-height: 0;
  }

  .socialgame-card-link {
    padding: 22px 42px 22px 18px;
  }

  .socialgame-card-title {
    margin-bottom: 20px;
    font-size: 1.55rem;
  }

  .socialgame-property {
    grid-template-columns: 1fr;
    gap: 3px;
  }

  .socialgame-property dd {
    font-size: 1.1rem;
  }

  .socialgame-back a {
    width: 100%;
    justify-content: center;
  }

  .socialgame-detail {
    padding: 22px 16px;
  }

  .socialgame-detail-property {
    grid-template-columns: 1fr;
  }

  .socialgame-detail-property dt {
    padding-bottom: 7px;
  }

  .socialgame-detail-property dd {
    padding-top: 7px;
  }
}
.socialgame-card-title {
  color: #16455d;
}
.socialgame-card {
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(6px);
}
.socialgame-card-link::after {
  content: "→";

  position: absolute;
  right: 24px;
  bottom: 18px;

  color: #5769b7;
  font-size: 1.5rem;
  transition: transform .25s ease;
}

.socialgame-card:hover .socialgame-card-link::after {
  transform: translateX(6px);
}
.socialgame-card-grid {
  justify-content: center;
}