/* Games directory — from static-games.html / static-style.css */

.page-games {
  --page: #f4f5f8;
  --card: #ffffff;
  --ink: #161f2b;
  --ink-soft: #2b3543;
  --muted: #697384;
  --muted-2: #9aa2b1;
  --border: #e8eaef;
  --border-2: #eef0f4;
  --indigo: #4338e0;
  --indigo-h: #372cc9;
  --soft: #ecebff;
  --purple: #7b2ba0;
  --gold: #dca00f;
  --serif: "Playfair Display", Georgia, "Times New Roman", serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --shadow-sm: 0 3px 9px rgba(22, 31, 43, .06), 0 1px 2px rgba(22, 31, 43, .04);
  --shadow-md: 0 10px 26px rgba(22, 31, 43, .09), 0 2px 6px rgba(22, 31, 43, .05);
  width: 100%;
  max-width: 100%;
  overflow-x: clip;
}

.page-games,
.page-games * {
  box-sizing: border-box;
}

.page-games .games-main,
.page-games .layout,
.page-games .main,
.page-games .main-search,
.page-games .game-grid,
.page-games .game-card,
.page-games .hero,
.page-games .res-head {
  min-width: 0;
  max-width: 100%;
}

.page-games .ico {
  width: 22px;
  height: 22px;
  stroke: currentColor;
  stroke-width: 1.7;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.page-games .games-main {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px 56px;
  min-width: 0;
}

.page-games input,
.page-games button,
.page-games select {
  font-family: inherit;
  max-width: 100%;
}

.page-games .crumb {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 12.5px;
  color: var(--muted);
  padding: 22px 0 0;
  flex-wrap: wrap;
}

.page-games .crumb a:hover {
  color: var(--indigo);
}

.page-games .crumb .cur {
  color: var(--ink);
  font-weight: 600;
}

.page-games .crumb span {
  color: var(--muted-2);
}

.page-games .hero {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow-sm);
  padding: 30px 32px;
  margin: 14px 0 22px;
}

.page-games .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--indigo);
  background: var(--soft);
  border: 1px solid #dcd9fb;
  border-radius: 30px;
  padding: 6px 14px;
}

.page-games .hero h1 {
  font-family: var(--serif);
  font-size: 38px;
  line-height: 1.04;
  font-weight: 800;
  letter-spacing: -.02em;
  color: #1b2440;
  margin: 14px 0 0;
}

.page-games .hero .sub {
  font-size: 15px;
  color: var(--muted);
  margin: 11px 0 0;
  max-width: 640px;
  line-height: 1.55;
}

.page-games .stats {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  margin-top: 22px;
  padding-top: 22px;
  border-top: 1px solid var(--border-2);
}

.page-games .stats div {
  display: flex;
  flex-direction: column;
}

.page-games .stats b {
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 800;
  color: var(--indigo);
  line-height: 1;
}

.page-games .stats span {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .05em;
  margin-top: 6px;
}

.page-games .layout {
  display: grid;
  grid-template-columns: minmax(0, 220px) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.page-games .layout--full {
  grid-template-columns: minmax(0, 1fr);
}

.page-games .side {
  position: sticky;
  top: 88px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.page-games .side-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow-sm);
  padding: 18px 16px;
}

.page-games .side-card h3 {
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 12px;
  padding: 0 6px;
}

.page-games .feat a {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 8px;
  border-radius: 9px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink-soft);
}

.page-games .feat a:hover {
  background: var(--page);
  color: var(--indigo);
}

.page-games .feat .fic {
  font-size: 17px;
}

.page-games .main-search {
  display: flex;
  align-items: center;
  gap: 11px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 13px;
  box-shadow: var(--shadow-sm);
  padding: 13px 16px;
  margin-bottom: 16px;
}

.page-games .main-search svg {
  width: 18px;
  height: 18px;
  color: var(--muted-2);
  flex: none;
}

.page-games .main-search input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 15px;
  color: var(--ink);
  min-width: 0;
}

.page-games .res-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.page-games .res-head h2 {
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 800;
  margin: 0;
}

.page-games .res-head small {
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  margin-left: 8px;
}

.page-games .res-head select {
  font-size: 13.5px;
  color: var(--ink-soft);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 9px 12px;
  background: #fff;
  outline: none;
}

.page-games .game-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.page-games .game-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
  padding: 16px 18px;
  transition: border-color .15s, box-shadow .15s, transform .12s;
  color: inherit;
  text-decoration: none;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.page-games .game-card:hover {
  border-color: #c9cdfa;
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.page-games .g-ico {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: var(--soft);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 23px;
  flex: none;
}

.page-games .g-body {
  flex: 1;
  min-width: 0;
}

.page-games .g-body h3 {
  font-size: 15px;
  font-weight: 800;
  color: var(--ink);
  margin: 0;
  letter-spacing: -.01em;
}

.page-games .g-play {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--indigo);
  flex: none;
}

.page-games .g-play .ico {
  width: 14px;
  height: 14px;
  transition: transform .15s;
}

.page-games .game-card:hover .g-play .ico {
  transform: translateX(3px);
}

.page-games .empty {
  display: none;
  text-align: center;
  color: var(--muted);
  font-size: 14px;
  padding: 40px 0;
}

.page-games .empty button {
  margin-top: 12px;
}

.page-games .btn-ghost {
  background: #fff;
  border-color: var(--border);
  color: var(--ink-soft);
}

.page-games .btn-ghost:hover {
  border-color: #c9cdfa;
  color: var(--indigo);
}

.page-games .showing {
  text-align: center;
  font-size: 13px;
  color: var(--muted);
  margin-top: 20px;
}

.page-games .pager {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 7px;
  margin-top: 26px;
  flex-wrap: wrap;
}

.page-games .pager button {
  min-width: 38px;
  height: 38px;
  padding: 0 12px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--ink-soft);
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.page-games .pager button:hover:not(:disabled) {
  border-color: #c9cdfa;
  color: var(--indigo);
}

.page-games .pager button.active {
  background: var(--indigo);
  border-color: var(--indigo);
  color: #fff;
}

.page-games .pager button:disabled {
  opacity: .45;
  cursor: default;
}

.page-games .pager .pg-ico {
  width: 15px;
  height: 15px;
}

.page-games .games-empty-state {
  text-align: center;
  color: var(--muted);
  font-size: 14px;
  padding: 48px 20px;
  background: var(--card);
  border: 1px dashed var(--border);
  border-radius: 14px;
}

@media (max-width: 980px) {
  .page-games .layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .page-games .side {
    position: static;
    flex-direction: row;
    flex-wrap: wrap;
  }

  .page-games .side-card {
    flex: 1 1 auto;
    min-width: 0;
    max-width: 100%;
  }
}

@media (max-width: 620px) {
  .page-games .games-main {
    padding: 0 16px 48px;
    max-width: 100%;
  }

  .page-games .game-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .page-games .hero h1 {
    font-size: 29px;
  }

  .page-games .stats {
    gap: 22px;
  }

  .page-games .g-play {
    display: none;
  }

  .page-games .main-search,
  .page-games .game-card,
  .page-games .res-head {
    max-width: 100%;
  }

  .page-games .res-head select {
    max-width: 100%;
  }
}
