/* ==========================================================================
   Kids Games Play — Design System
   A premium dark arcade aesthetic: deep space violet, electric purple, warm gold
   ========================================================================== */

:root {
  --bg: #08060f;
  --bg-soft: #0d0a18;
  --surface: #131022;
  --surface-2: #1a1530;
  --surface-3: #221b3d;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.14);
  --text: #f4f1ff;
  --muted: #a49cc4;
  --faint: #6f678f;
  --accent: #8b5cf6;
  --accent-2: #c084fc;
  --accent-deep: #6d28d9;
  --accent-rgb: 139, 92, 246;
  --gold: #f5b544;
  --gold-soft: #ffd98a;
  --success: #34d399;
  --danger: #fb7185;
  --radius-sm: 12px;
  --radius: 18px;
  --radius-lg: 26px;
  --radius-xl: 34px;
  --shadow-sm: 0 8px 24px rgba(0, 0, 0, 0.35);
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  --shadow-glow: 0 18px 55px rgba(139, 92, 246, 0.35);
  --container: 1280px;
  --header-h: 78px;
  --font-display: "Outfit", "Inter", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-arabic: "Cairo", "Tajawal", "Segoe UI", sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

[dir="rtl"] {
  --font-display: "Cairo", "Tajawal", sans-serif;
  --font-body: "Cairo", "Tajawal", sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 15.5px;
  line-height: 1.65;
  letter-spacing: 0.005em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  background:
    radial-gradient(900px 500px at 12% -8%, rgba(124, 58, 237, 0.22), transparent 62%),
    radial-gradient(700px 460px at 92% 4%, rgba(245, 181, 68, 0.08), transparent 60%),
    radial-gradient(800px 700px at 50% 120%, rgba(109, 40, 217, 0.14), transparent 65%);
}

img { max-width: 100%; display: block; }
.icon { width: 1em; height: 1em; flex-shrink: 0; display: inline-block; vertical-align: -0.125em; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
ul, ol { list-style: none; }

h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

::selection { background: rgba(139, 92, 246, 0.45); color: #fff; }

:focus-visible {
  outline: 2px solid var(--accent-2);
  outline-offset: 3px;
  border-radius: 6px;
}

/* Layout ------------------------------------------------------------------ */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 22px;
}

.container-wide { max-width: 1440px; }
.container-narrow { max-width: 860px; }

.section { padding-block: 54px; }
.section-tight { padding-block: 34px; }

.grid { display: grid; gap: 18px; }
.grid-games {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px 18px;
  align-items: start;
}

.stack { display: flex; flex-direction: column; }
.row { display: flex; align-items: center; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.wrap { flex-wrap: wrap; }
.gap-1 { gap: 6px; } .gap-2 { gap: 12px; } .gap-3 { gap: 18px; } .gap-4 { gap: 26px; }
.mt-2 { margin-top: 12px; } .mt-3 { margin-top: 20px; } .mt-4 { margin-top: 32px; }
.mb-2 { margin-bottom: 12px; } .mb-3 { margin-bottom: 20px; } .mb-4 { margin-bottom: 32px; }
.text-muted { color: var(--muted); }
.text-faint { color: var(--faint); }
.text-gold { color: var(--gold); }
.text-center { text-align: center; }
.hide { display: none !important; }

/* Type -------------------------------------------------------------------- */
.display-1 { font-size: clamp(2.5rem, 5vw, 4.2rem); line-height: 1.04; letter-spacing: -0.035em; }
.display-2 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); letter-spacing: -0.03em; }
.title-lg { font-size: 1.45rem; }
.text-gradient {
  background: linear-gradient(100deg, #fff 10%, #dcccff 45%, var(--gold-soft) 95%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--gold), transparent);
}
.lead { font-size: 1.02rem; color: var(--muted); max-width: 62ch; }

/* Buttons ----------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  height: 46px;
  padding-inline: 22px;
  border-radius: 14px;
  font-weight: 650;
  font-size: 0.92rem;
  letter-spacing: 0.01em;
  border: 1px solid transparent;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s, border-color 0.25s;
  white-space: nowrap;
  cursor: pointer;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, #7c3aed 55%, #6d28d9 100%);
  color: #fff;
  box-shadow: 0 12px 30px rgba(124, 58, 237, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.22);
}
.btn-primary:hover { box-shadow: 0 18px 42px rgba(124, 58, 237, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.28); }
.btn-gold {
  background: linear-gradient(135deg, #ffce6b, #f5b544 55%, #e69b22);
  color: #221500;
  box-shadow: 0 12px 30px rgba(245, 181, 68, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.4);
}
.btn-ghost {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--line-strong);
  color: var(--text);
  backdrop-filter: blur(8px);
}
.btn-ghost:hover { background: rgba(255, 255, 255, 0.09); border-color: rgba(255, 255, 255, 0.25); }
.btn-sm { height: 38px; padding-inline: 15px; font-size: 0.83rem; border-radius: 11px; }
.btn-lg { height: 54px; padding-inline: 30px; font-size: 1rem; border-radius: 16px; }
.btn-block { width: 100%; }
.btn-icon { width: 46px; padding: 0; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none; }

/* Chips & badges ---------------------------------------------------------- */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 36px;
  padding-inline: 15px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 600;
  transition: 0.2s var(--ease);
}
.chip:hover { color: #fff; border-color: var(--line-strong); background: rgba(255, 255, 255, 0.08); }
.chip.is-active {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.3), rgba(139, 92, 246, 0.12));
  border-color: rgba(139, 92, 246, 0.55);
  color: #e9e2ff;
  box-shadow: 0 6px 20px rgba(139, 92, 246, 0.25);
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 9px;
  border-radius: 8px;
  font-size: 0.68rem;
  font-weight: 750;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}
.badge-gold { background: rgba(245, 181, 68, 0.16); color: var(--gold-soft); border: 1px solid rgba(245, 181, 68, 0.32); }
.badge-violet { background: rgba(139, 92, 246, 0.18); color: #d6c6ff; border: 1px solid rgba(139, 92, 246, 0.35); }
.badge-live { background: rgba(52, 211, 153, 0.14); color: #7ef0c6; border: 1px solid rgba(52, 211, 153, 0.3); }
.badge-muted { background: rgba(255, 255, 255, 0.06); color: var(--muted); border: 1px solid var(--line); }

/* Cards ------------------------------------------------------------------- */
.panel {
  background: linear-gradient(165deg, rgba(28, 22, 50, 0.92), rgba(18, 14, 33, 0.96));
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.panel-pad { padding: 26px; }

/* Header ------------------------------------------------------------------ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background: rgba(8, 6, 15, 0.72);
  backdrop-filter: blur(18px) saturate(140%);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s, background 0.3s;
}
.site-header.is-scrolled {
  background: rgba(8, 6, 15, 0.92);
  border-bottom-color: var(--line);
}
.header-inner { display: flex; align-items: center; gap: 26px; }
.brand { display: flex; align-items: center; gap: 11px; flex-shrink: 0; }
.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, #a78bfa, #7c3aed 55%, #4c1d95);
  box-shadow: 0 8px 22px rgba(124, 58, 237, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.35);
  color: #fff;
}
.brand-mark svg { width: 23px; height: 23px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-name { font-family: var(--font-display); font-weight: 800; font-size: 1.16rem; letter-spacing: -0.02em; }
.brand-name em { font-style: normal; color: var(--gold); }
.brand-tag { font-size: 0.64rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); font-weight: 600; }

.main-nav { display: flex; align-items: center; gap: 4px; }
.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 40px;
  padding-inline: 13px;
  border-radius: 10px;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 600;
  transition: 0.2s;
}
.nav-link:hover, .nav-link.is-active { color: #fff; background: rgba(255, 255, 255, 0.06); }
.nav-link .caret { width: 7px; height: 7px; border-right: 1.6px solid currentColor; border-bottom: 1.6px solid currentColor; transform: rotate(45deg) translateY(-2px); margin-inline-start: 2px; }

.nav-dropdown { position: relative; }
.nav-menu {
  position: absolute;
  top: calc(100% + 10px);
  inset-inline-start: 0;
  width: 460px;
  padding: 14px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  background: linear-gradient(170deg, #1a1430, #120e22);
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  box-shadow: var(--shadow);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: 0.22s var(--ease);
}
.nav-dropdown:hover .nav-menu, .nav-dropdown:focus-within .nav-menu, .nav-dropdown.is-open .nav-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.nav-menu a {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 12px;
  border-radius: 11px;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--muted);
}
.nav-menu a:hover { background: rgba(255, 255, 255, 0.06); color: #fff; }
.cat-dot { width: 9px; height: 9px; border-radius: 3px; flex-shrink: 0; }

.header-search { position: relative; flex: 1; max-width: 420px; margin-inline-start: auto; }
.search-input {
  width: 100%;
  height: 44px;
  padding-inline: 44px 86px;
  border-radius: 13px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.045);
  color: var(--text);
  font-size: 0.87rem;
  transition: 0.22s;
}
.search-input::placeholder { color: var(--faint); }
.search-input:focus {
  outline: none;
  border-color: rgba(139, 92, 246, 0.6);
  background: rgba(255, 255, 255, 0.07);
  box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.13);
}
.search-icon { position: absolute; inset-inline-start: 15px; top: 50%; transform: translateY(-50%); color: var(--faint); pointer-events: none; width: 18px; height: 18px; }
.search-kbd {
  position: absolute;
  inset-inline-end: 10px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.66rem;
  font-weight: 700;
  color: var(--faint);
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  padding: 3px 7px;
  pointer-events: none;
}
.search-results {
  position: absolute;
  top: calc(100% + 10px);
  inset-inline: 0;
  background: #151027;
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 8px;
  max-height: 420px;
  overflow: auto;
  z-index: 80;
}
.search-results a { display: flex; align-items: center; gap: 11px; padding: 8px; border-radius: 10px; }
.search-results a:hover { background: rgba(255, 255, 255, 0.06); }
.search-results img { width: 52px; height: 39px; border-radius: 7px; object-fit: cover; }
.search-results strong { display: block; font-size: 0.85rem; font-weight: 600; }
.search-results small { color: var(--faint); font-size: 0.72rem; }
.search-empty { padding: 16px; text-align: center; color: var(--faint); font-size: 0.84rem; }

.header-actions { display: flex; align-items: center; gap: 8px; }
.icon-btn {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: var(--muted);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  transition: 0.2s;
}
.icon-btn { position: relative; }
.icon-btn:hover { color: #fff; border-color: var(--line-strong); background: rgba(255, 255, 255, 0.08); }
.icon-btn svg { width: 20px; height: 20px; }

.lang-menu { position: relative; }
.lang-menu .nav-menu {
  width: 190px;
  grid-template-columns: 1fr;
  padding: 8px;
  inset-inline-start: auto;
  inset-inline-end: 0;
}
.lang-menu .nav-menu a { font-size: 0.84rem; }
.lang-current { display: inline-flex; align-items: center; gap: 7px; font-size: 0.82rem; font-weight: 700; text-transform: uppercase; color: var(--muted); }
.lang-current:hover { color: #fff; }

/* Theme switcher --------------------------------------------------------- */
.theme-menu { position: relative; }
.theme-trigger .theme-icon { display: none; }
html[data-theme-pref="light"] .theme-trigger .theme-icon-light,
html:not([data-theme-pref]) .theme-trigger .theme-icon-light { display: block; }
html[data-theme-pref="dark"] .theme-trigger .theme-icon-dark { display: block; }
html[data-theme-pref="system"] .theme-trigger .theme-icon-system { display: block; }
.theme-options {
  width: 188px;
  grid-template-columns: 1fr;
  padding: 8px;
  inset-inline-start: auto;
  inset-inline-end: 0;
}
.theme-options button {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  padding: 10px 12px;
  border-radius: 11px;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--muted);
  text-align: start;
  transition: 0.18s;
}
.theme-options button:hover { background: rgba(255, 255, 255, 0.06); color: #fff; }
.theme-options button svg { width: 16px; height: 16px; }
.theme-options .theme-check { margin-inline-start: auto; opacity: 0; color: var(--accent-2); }
.theme-options button[aria-checked="true"] { color: var(--text); }
.theme-options button[aria-checked="true"] .theme-check { opacity: 1; }
.theme-choices { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; }
.theme-choices button {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 11px 6px;
  border-radius: 12px;
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 650;
}
.theme-choices button svg { width: 18px; height: 18px; }
.theme-choices button[aria-checked="true"] {
  color: var(--text);
  border-color: rgba(139, 92, 246, 0.45);
  background: rgba(139, 92, 246, 0.12);
}

.mobile-toggle { display: none; }

/* Hero -------------------------------------------------------------------- */
.hero { position: relative; padding-block: 46px 20px; overflow: hidden; }
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.92fr);
  gap: 24px;
  align-items: stretch;
}
.hero-grid > * { min-width: 0; }
.hero-feature {
  position: relative;
  min-height: 430px;
  border-radius: var(--radius-xl);
  overflow: hidden;
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow);
  isolation: isolate;
}
.hero-feature img.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
  transition: transform 8s linear;
}
.hero-feature:hover img.hero-bg { transform: scale(1.1); }
.hero-feature::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(8, 6, 15, 0.96) 8%, rgba(8, 6, 15, 0.72) 42%, rgba(8, 6, 15, 0.12) 78%),
    linear-gradient(0deg, rgba(8, 6, 15, 0.95) 2%, transparent 55%);
  z-index: 1;
}
[dir="rtl"] .hero-feature::after {
  background:
    linear-gradient(270deg, rgba(8, 6, 15, 0.96) 8%, rgba(8, 6, 15, 0.72) 42%, rgba(8, 6, 15, 0.12) 78%),
    linear-gradient(0deg, rgba(8, 6, 15, 0.95) 2%, transparent 55%);
}
.hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  padding: 38px 40px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  max-width: 560px;
  min-width: 0;
}
.hero-content h1 { font-size: clamp(2rem, 3.6vw, 3rem); margin-top: 14px; }
.hero-content p { color: #cfc7e8; margin-top: 12px; max-width: 44ch; font-size: 0.96rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 11px; margin-top: 24px; }
.hero-meta { display: flex; align-items: center; gap: 16px; margin-top: 20px; color: var(--muted); font-size: 0.8rem; }
.hero-meta span { display: inline-flex; align-items: center; gap: 6px; }
.hero-meta svg { width: 15px; height: 15px; }

.hero-side {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto 1fr;
  gap: 18px;
  min-width: 0;
}
.hero-side-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-width: 0; }
.hero-side-head h2 { font-size: 1.1rem; }
.hero-side-head a { color: var(--gold); font-size: 0.78rem; font-weight: 700; }
.trend-list { display: flex; flex-direction: column; gap: 8px; }
.trend-item {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 9px 11px;
  border-radius: 14px;
  border: 1px solid transparent;
  transition: 0.22s var(--ease);
  background: rgba(255, 255, 255, 0.022);
}
.trend-item:hover { background: rgba(255, 255, 255, 0.06); border-color: var(--line); transform: translateX(4px); }
[dir="rtl"] .trend-item:hover { transform: translateX(-4px); }
.trend-rank {
  width: 24px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.95rem;
  color: var(--faint);
  text-align: center;
}
.trend-item:nth-child(1) .trend-rank { color: var(--gold); }
.trend-item:nth-child(2) .trend-rank { color: #cfcfcf; }
.trend-item:nth-child(3) .trend-rank { color: #d08a52; }
.trend-item img { width: 64px; height: 48px; border-radius: 9px; object-fit: cover; }
.trend-info { min-width: 0; }
.trend-info strong { display: block; font-size: 0.86rem; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.trend-info small { color: var(--faint); font-size: 0.7rem; }
.trend-play { margin-inline-start: auto; color: var(--faint); }
.trend-play svg { width: 16px; height: 16px; }

/* Stats strip ------------------------------------------------------------- */
.stats-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  margin-top: 34px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--line);
}
.stat-cell { background: rgba(15, 11, 26, 0.94); padding: 18px 22px; display: flex; align-items: center; gap: 14px; }
.stat-icon {
  width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center;
  background: rgba(139, 92, 246, 0.12); color: var(--accent-2);
}
.stat-icon svg { width: 20px; height: 20px; }
.stat-cell strong { display: block; font-family: var(--font-display); font-size: 1.3rem; letter-spacing: -0.02em; }
.stat-cell span { font-size: 0.75rem; color: var(--faint); }

/* Section headers --------------------------------------------------------- */
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; margin-bottom: 22px; }
.section-head h2 { font-size: clamp(1.35rem, 2.2vw, 1.85rem); display: flex; align-items: center; gap: 12px; }
.section-head h2 .spark {
  width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center;
  background: linear-gradient(140deg, rgba(139, 92, 246, 0.3), rgba(245, 181, 68, 0.18));
  color: var(--gold);
}
.section-head h2 .spark svg { width: 16px; height: 16px; }
.section-head p { color: var(--faint); font-size: 0.84rem; margin-top: 4px; }
.section-link { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-weight: 650; font-size: 0.82rem; white-space: nowrap; }
.section-link:hover { color: #fff; }
.section-link svg { width: 15px; height: 15px; transition: transform 0.2s; }
.section-link:hover svg { transform: translateX(3px); }
[dir="rtl"] .section-link:hover svg { transform: translateX(-3px) rotate(180deg); }
[dir="rtl"] .section-link svg { transform: rotate(180deg); }

/* Game card --------------------------------------------------------------- */
.game-card { position: relative; display: flex; flex-direction: column; min-width: 0; border-radius: 16px; }
.game-thumb {
  display: block;
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: 15px;
  overflow: hidden;
  background: var(--surface-2);
  border: 1px solid var(--line);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.28);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s;
}
.game-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.55s var(--ease); }
.game-card:hover .game-thumb {
  transform: translateY(-6px);
  border-color: rgba(139, 92, 246, 0.55);
  box-shadow: 0 22px 44px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(139, 92, 246, 0.25);
}
.game-card:hover .game-thumb img { transform: scale(1.07); }
.game-play {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: linear-gradient(0deg, rgba(8, 6, 15, 0.86) 0%, rgba(8, 6, 15, 0.05) 55%);
  opacity: 0;
  transition: opacity 0.28s;
}
.game-card:hover .game-play { opacity: 1; }
.play-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 42px;
  padding-inline: 20px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-deep));
  color: #fff;
  font-weight: 700;
  font-size: 0.82rem;
  box-shadow: 0 12px 28px rgba(124, 58, 237, 0.5);
  transform: translateY(8px);
  transition: transform 0.28s var(--ease);
}
.game-card:hover .play-pill { transform: translateY(0); }
.play-pill svg { width: 14px; height: 14px; }
.game-tag {
  position: absolute;
  top: 9px;
  inset-inline-start: 9px;
  padding: 4px 9px;
  border-radius: 8px;
  background: rgba(8, 6, 15, 0.72);
  border: 1px solid var(--line-strong);
  backdrop-filter: blur(8px);
  font-size: 0.64rem;
  font-weight: 750;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #e4dcff;
}
.game-tag.gold { color: var(--gold-soft); border-color: rgba(245, 181, 68, 0.35); }
.game-fav {
  position: absolute;
  top: 8px;
  inset-inline-end: 8px;
  width: 32px; height: 32px; border-radius: 9px;
  display: grid; place-items: center;
  background: rgba(8, 6, 15, 0.65);
  border: 1px solid var(--line-strong);
  backdrop-filter: blur(8px);
  color: #ddd;
  opacity: 0;
  transform: scale(0.9);
  transition: 0.22s;
}
.game-card:hover .game-fav { opacity: 1; transform: scale(1); }
.game-fav:hover { color: var(--danger); border-color: rgba(251, 113, 133, 0.5); }
.game-fav svg { width: 15px; height: 15px; }
.game-fav.is-active { color: var(--danger); opacity: 1; transform: scale(1); }
.game-info { padding: 10px 3px 0; min-height: 48px; }
.game-name {
  font-family: var(--font-display);
  font-weight: 650;
  font-size: 0.89rem;
  letter-spacing: -0.005em;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.game-sub { display: flex; align-items: center; gap: 8px; margin-top: 3px; color: var(--faint); font-size: 0.71rem; }
.game-sub .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--faint); }
.game-card:hover .game-name { color: #e9e3ff; }

/* Featured strip ---------------------------------------------------------- */
.featured-rail {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}
.feature-card {
  position: relative;
  min-height: 168px;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid var(--line);
  display: flex;
  align-items: flex-end;
  padding: 18px;
  isolation: isolate;
  transition: 0.3s var(--ease);
}
.feature-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform 0.6s var(--ease); }
.feature-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(0deg, rgba(8, 6, 15, 0.96) 5%, rgba(8, 6, 15, 0.35) 58%, rgba(8, 6, 15, 0.05) 100%);
}
.feature-card:hover { transform: translateY(-4px); border-color: rgba(139, 92, 246, 0.5); }
.feature-card:hover img { transform: scale(1.06); }
.feature-card strong { display: block; font-family: var(--font-display); font-size: 1rem; }
.feature-card small { color: #bdb4d8; font-size: 0.74rem; }

/* Category tiles ---------------------------------------------------------- */
.cat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 13px; }
.cat-tile {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 4px;
  position: relative;
  padding: 17px;
  min-height: 124px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: linear-gradient(160deg, rgba(30, 23, 53, 0.9), rgba(15, 11, 27, 0.95));
  overflow: hidden;
  transition: 0.28s var(--ease);
}
.cat-tile::before {
  content: "";
  position: absolute;
  width: 120px; height: 120px;
  border-radius: 50%;
  inset-inline-end: -40px;
  top: -45px;
  background: var(--cat-color, var(--accent));
  opacity: 0.2;
  filter: blur(26px);
  transition: opacity 0.3s;
}
.cat-tile:hover { transform: translateY(-4px); border-color: var(--line-strong); box-shadow: var(--shadow-sm); }
.cat-tile:hover::before { opacity: 0.4; }
.cat-tile .cat-icon {
  width: 38px; height: 38px; border-radius: 11px;
  display: grid; place-items: center;
  background: color-mix(in srgb, var(--cat-color, var(--accent)) 20%, transparent);
  color: var(--cat-color, var(--accent-2));
  margin-bottom: auto;
}
.cat-tile .cat-icon svg { width: 19px; height: 19px; }
.cat-tile strong { display: block; font-size: 0.92rem; font-weight: 650; }
.cat-tile small { color: var(--faint); font-size: 0.71rem; }

/* Game player ------------------------------------------------------------- */
.game-page { padding-block: 28px 60px; }
.breadcrumbs { display: flex; align-items: center; gap: 8px; color: var(--faint); font-size: 0.78rem; margin-bottom: 18px; flex-wrap: wrap; }
.breadcrumbs a:hover { color: #fff; }
.breadcrumbs .sep { opacity: 0.5; }
.game-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 24px;
  align-items: start;
}
.player-panel {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line-strong);
  background: #000;
  box-shadow: var(--shadow);
  position: relative;
}
.player-stage { position: relative; aspect-ratio: 16 / 10; background: radial-gradient(circle at 50% 40%, #1b1430, #06040c 70%); }
.player-stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.player-loader {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 50% 45%, rgba(80, 45, 160, 0.35), rgba(6, 4, 12, 0.95));
  z-index: 5;
  text-align: center;
  transition: opacity 0.4s;
}
.player-loader.is-hidden { opacity: 0; pointer-events: none; }
.loader-ring {
  width: 54px; height: 54px; border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.12);
  border-top-color: var(--accent-2);
  animation: spin 0.9s linear infinite;
  margin: 0 auto 18px;
}
@keyframes spin { to { transform: rotate(360deg); } }
.player-loader strong { font-family: var(--font-display); font-size: 1.05rem; }
.player-loader p { color: var(--faint); font-size: 0.8rem; margin-top: 5px; }
.player-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  background: #0e0a1a;
  border-top: 1px solid var(--line);
  flex-wrap: wrap;
}
.player-toolbar .group { display: flex; align-items: center; gap: 7px; }
.tool-btn {
  display: inline-flex; align-items: center; gap: 7px;
  height: 36px; padding-inline: 12px; border-radius: 10px;
  border: 1px solid var(--line); background: rgba(255, 255, 255, 0.04);
  color: var(--muted); font-size: 0.78rem; font-weight: 600;
  transition: 0.2s;
}
.tool-btn:hover { color: #fff; border-color: var(--line-strong); background: rgba(255, 255, 255, 0.08); }
.tool-btn.is-active { color: var(--danger); border-color: rgba(251, 113, 133, 0.4); }
.tool-btn svg { width: 15px; height: 15px; }

.game-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-top: 24px; flex-wrap: wrap; }
.game-heading h1 { font-size: clamp(1.6rem, 2.8vw, 2.2rem); }
.game-stats { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; color: var(--faint); font-size: 0.8rem; margin-top: 9px; }
.rating-stars { display: inline-flex; align-items: center; gap: 3px; color: var(--gold); }
.rating-stars svg { width: 15px; height: 15px; }
.rating-stars .empty { color: rgba(255, 255, 255, 0.14); }
.rating-value { color: #fff; font-weight: 700; margin-inline-start: 5px; }
.game-actions { display: flex; gap: 9px; flex-wrap: wrap; }

.game-section { margin-top: 26px; }
.game-section h2 { font-size: 1.05rem; margin-bottom: 11px; display: flex; align-items: center; gap: 9px; }
.game-section h2 .line { width: 22px; height: 2px; background: var(--gold); border-radius: 2px; }
.game-description { color: #c9c1e0; font-size: 0.93rem; line-height: 1.8; white-space: pre-line; }
.instructions-box {
  padding: 16px 18px;
  border-radius: 14px;
  background: rgba(139, 92, 246, 0.07);
  border: 1px solid rgba(139, 92, 246, 0.2);
  color: #d7cff0;
  font-size: 0.88rem;
  white-space: pre-line;
}
.game-tags { display: flex; flex-wrap: wrap; gap: 7px; }
.game-tags .chip { height: 31px; font-size: 0.75rem; }

.side-stack { display: flex; flex-direction: column; gap: 18px; }
.side-panel { padding: 18px; border-radius: var(--radius); border: 1px solid var(--line); background: rgba(19, 16, 34, 0.8); }
.side-panel h3 { font-size: 0.92rem; margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.mini-list { display: flex; flex-direction: column; gap: 7px; }
.mini-item { display: flex; align-items: center; gap: 10px; padding: 6px; border-radius: 10px; transition: 0.2s; }
.mini-item:hover { background: rgba(255, 255, 255, 0.05); }
.mini-item img { width: 58px; height: 44px; border-radius: 8px; object-fit: cover; }
.mini-item strong { display: block; font-size: 0.78rem; font-weight: 600; line-height: 1.3; }
.mini-item small { color: var(--faint); font-size: 0.68rem; }
.rating-box { text-align: center; }
.rating-box .big { font-family: var(--font-display); font-size: 2.4rem; color: var(--gold); line-height: 1; }
.star-input { display: flex; justify-content: center; gap: 5px; margin-top: 12px; }
.star-input button { color: rgba(255, 255, 255, 0.18); transition: 0.15s; }
.star-input button:hover, .star-input button.is-on { color: var(--gold); }
.star-input svg { width: 23px; height: 23px; }

/* Listing pages ----------------------------------------------------------- */
.page-head { padding-block: 34px 10px; }
.page-head h1 { font-size: clamp(1.8rem, 3vw, 2.5rem); }
.filter-bar { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin-bottom: 24px; }
.filter-chips { display: flex; gap: 8px; flex-wrap: wrap; }
.select {
  height: 40px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.045);
  color: var(--text);
  padding-inline: 12px;
  font-size: 0.82rem;
}
.select option { background: #17122a; }
.list-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 26px; align-items: start; }

/* Pagination -------------------------------------------------------------- */
.pagination { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 40px; flex-wrap: wrap; }
.pagination a, .pagination span {
  min-width: 38px; height: 38px; padding-inline: 10px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 10px; border: 1px solid var(--line);
  color: var(--muted); font-size: 0.82rem; font-weight: 600;
  transition: 0.2s;
}
.pagination a:hover { color: #fff; border-color: var(--line-strong); background: rgba(255, 255, 255, 0.06); }
.pagination .is-current { background: linear-gradient(135deg, var(--accent), var(--accent-deep)); color: #fff; border-color: transparent; }
.pagination .dots { border: 0; }

/* Article ----------------------------------------------------------------- */
.post-hero { padding-block: 30px 0; }
.post-cover { width: 100%; aspect-ratio: 21 / 9; object-fit: cover; border-radius: var(--radius-lg); border: 1px solid var(--line); }
.post-layout { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 30px; align-items: start; }
.post-body { font-size: 1rem; line-height: 1.85; color: #cfc8e4; }
.post-body p { margin-bottom: 18px; }
.post-body h2 { font-size: 1.5rem; margin: 30px 0 14px; }
.post-body h3 { font-size: 1.18rem; margin: 24px 0 10px; }
.post-body ul, .post-body ol { margin-block: 0 18px; margin-inline-start: 22px; }
.post-body ul { list-style: disc; }
.post-body ol { list-style: decimal; }
.post-body li { margin-bottom: 8px; }
.post-body a { color: var(--gold); text-decoration: underline; text-underline-offset: 3px; }
.post-body strong { color: #fff; }
.post-body img { border-radius: 14px; margin: 20px 0; }
.post-figure { margin: 0 0 22px; }
.post-figure img { width: 100%; border-radius: 16px; border: 1px solid var(--line); margin: 0; }
.source-credit {
  margin-top: 26px;
  padding: 12px 15px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--line);
  font-size: 0.78rem !important;
  color: var(--faint);
}
.source-credit a { color: var(--gold); }
.review-verdict {
  margin: 26px 0 10px;
  padding: 20px;
  border-radius: 16px;
  background: linear-gradient(150deg, rgba(139, 92, 246, 0.14), rgba(245, 181, 68, 0.06));
  border: 1px solid rgba(139, 92, 246, 0.28);
}
.review-verdict p { margin-bottom: 10px; }
.review-score {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--gold);
  margin-bottom: 8px;
}
.review-verdict .btn { margin-top: 4px; }
.post-card { display: flex; flex-direction: column; border-radius: 18px; overflow: hidden; border: 1px solid var(--line); background: rgba(19, 16, 34, 0.6); transition: 0.25s var(--ease); }
.post-card:hover { transform: translateY(-4px); border-color: rgba(139, 92, 246, 0.4); box-shadow: var(--shadow-sm); }
.post-card .cover { aspect-ratio: 16 / 9; overflow: hidden; background: var(--surface-2); }
.post-card .cover img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.post-card:hover .cover img { transform: scale(1.05); }
.post-card .content { padding: 16px 18px 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.post-card h3 { font-size: 1rem; line-height: 1.35; }
.post-card p { color: var(--muted); font-size: 0.8rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.post-card .meta { margin-top: auto; color: var(--faint); font-size: 0.72rem; display: flex; align-items: center; gap: 9px; }
.toc { position: sticky; top: calc(var(--header-h) + 20px); }

/* Auth -------------------------------------------------------------------- */
.auth-wrap { min-height: calc(100vh - var(--header-h) - 120px); display: grid; place-items: center; padding-block: 50px; }
.auth-card { width: 100%; max-width: 430px; padding: 34px; border-radius: var(--radius-lg); border: 1px solid var(--line-strong); background: linear-gradient(170deg, rgba(27, 21, 47, 0.96), rgba(13, 10, 24, 0.98)); box-shadow: var(--shadow); }
.auth-card h1 { font-size: 1.6rem; }
.auth-card .sub { color: var(--muted); font-size: 0.86rem; margin-top: 6px; }
.form-stack { display: flex; flex-direction: column; gap: 15px; margin-top: 26px; }
.field label { display: block; font-size: 0.78rem; font-weight: 650; color: var(--muted); margin-bottom: 6px; }
.input {
  width: 100%;
  height: 46px;
  padding-inline: 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.045);
  color: var(--text);
  font-size: 0.88rem;
  transition: 0.2s;
}
.input:focus { outline: none; border-color: rgba(139, 92, 246, 0.65); box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.12); background: rgba(255, 255, 255, 0.06); }
.input.is-invalid { border-color: rgba(251, 113, 133, 0.6); }
textarea.input { height: auto; padding-block: 12px; resize: vertical; }
.field-error { color: var(--danger); font-size: 0.74rem; margin-top: 5px; }
.form-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: 0.8rem; color: var(--muted); flex-wrap: wrap; }
.form-foot a { color: var(--gold); }
.divider { display: flex; align-items: center; gap: 12px; color: var(--faint); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.12em; margin-block: 4px; }
.divider::before, .divider::after { content: ""; height: 1px; flex: 1; background: var(--line); }

/* Alerts ------------------------------------------------------------------ */
.alert { padding: 13px 16px; border-radius: 12px; font-size: 0.84rem; border: 1px solid; display: flex; align-items: flex-start; gap: 10px; margin-bottom: 16px; }
.alert-success { background: rgba(52, 211, 153, 0.09); border-color: rgba(52, 211, 153, 0.28); color: #a7f3d0; }
.alert-error { background: rgba(251, 113, 133, 0.09); border-color: rgba(251, 113, 133, 0.3); color: #fecdd3; }
.alert-info { background: rgba(96, 165, 250, 0.09); border-color: rgba(96, 165, 250, 0.3); color: #bfdbfe; }

/* Empty state ------------------------------------------------------------- */
.empty-state { text-align: center; padding: 70px 24px; border: 1px dashed var(--line-strong); border-radius: var(--radius-lg); color: var(--muted); }
.empty-state .icon { width: 60px; height: 60px; margin: 0 auto 18px; border-radius: 18px; display: grid; place-items: center; background: rgba(139, 92, 246, 0.1); color: var(--accent-2); }
.empty-state .icon svg { width: 28px; height: 28px; }
.empty-state h3 { color: var(--text); margin-bottom: 6px; }
.empty-state p { font-size: 0.86rem; max-width: 44ch; margin-inline: auto; }

/* Footer ------------------------------------------------------------------ */
.site-footer { margin-top: 40px; border-top: 1px solid var(--line); background: linear-gradient(180deg, rgba(13, 10, 24, 0.4), rgba(8, 6, 15, 0.95)); }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.2fr; gap: 36px; padding-block: 48px; }
.footer-brand p { color: var(--muted); font-size: 0.83rem; margin-top: 16px; max-width: 34ch; }
.footer-col h4 { font-size: 0.74rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); margin-bottom: 15px; }
.footer-col ul { display: flex; flex-direction: column; gap: 9px; }
.footer-col a { color: var(--muted); font-size: 0.83rem; transition: 0.2s; }
.footer-col a:hover { color: #fff; }
.newsletter { display: flex; gap: 8px; margin-top: 14px; }
.newsletter .input { height: 42px; }
.socials { display: flex; gap: 8px; margin-top: 18px; }
.socials a { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; border: 1px solid var(--line); color: var(--muted); transition: 0.2s; }
.socials a:hover { color: #fff; border-color: var(--line-strong); background: rgba(255, 255, 255, 0.06); }
.socials svg { width: 16px; height: 16px; }
.footer-bottom { border-top: 1px solid var(--line); padding-block: 18px; display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; color: var(--faint); font-size: 0.75rem; }
.footer-bottom .links { display: flex; gap: 18px; }
.footer-bottom a:hover { color: #fff; }

/* Ad slots ---------------------------------------------------------------- */
.ad-slot { margin-block: 18px; text-align: center; min-height: 0; }
.ad-slot .ad-label { font-size: 0.6rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--faint); margin-bottom: 5px; opacity: 0.6; }
.ad-slot .ad-body { display: flex; justify-content: center; overflow: hidden; }

/* Anchor ad --------------------------------------------------------------- */
.ad-anchor {
  position: fixed;
  bottom: 16px;
  inset-inline-end: 16px;
  z-index: 70;
  width: 320px;
  max-width: calc(100vw - 32px);
  background: #120e22;
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  padding: 10px;
  box-shadow: var(--shadow);
}
.ad-anchor .ad-slot { margin: 0; }
.ad-anchor .ad-label { display: none; }
.ad-anchor-close {
  position: absolute;
  top: -10px;
  inset-inline-end: -8px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #241b40;
  border: 1px solid var(--line-strong);
  color: var(--muted);
  font-size: 15px;
  line-height: 1;
  display: grid;
  place-items: center;
}
.ad-anchor-close:hover { color: #fff; }

/* Sticky mobile CTA ------------------------------------------------------- */
.mobile-dock { display: none; }

/* Toast ------------------------------------------------------------------- */
.toast {
  position: fixed;
  bottom: 26px;
  inset-inline-start: 50%;
  transform: translate(-50%, 20px);
  background: #1d1733;
  border: 1px solid var(--line-strong);
  color: #fff;
  padding: 11px 18px;
  border-radius: 12px;
  font-size: 0.83rem;
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transition: 0.3s var(--ease);
  z-index: 100;
}
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

/* Utilities --------------------------------------------------------------- */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
.clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.clamp-3 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.divider-line { height: 1px; background: var(--line); }

/* Responsive -------------------------------------------------------------- */
@media (max-width: 1400px) {
  .header-inner { gap: 18px; }
  .nav-link { padding-inline: 10px; }
  .search-input { padding-inline: 42px 18px; }
  .search-kbd { display: none; }
}

@media (max-width: 1180px) {
  .nav-link { padding-inline: 10px; font-size: 0.83rem; }
  .header-search { max-width: 300px; }
  .grid-games { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hero-content { padding: 28px; }
  .game-shell { grid-template-columns: minmax(0, 1fr) 300px; }
}

@media (max-width: 1024px) {
  .main-nav { display: none; }
  .header-search { max-width: none; }
  .mobile-toggle {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 11px;
    border: 1px solid var(--line);
    color: var(--text);
    margin-inline-start: 0;
  }
  .mobile-toggle svg { width: 22px; height: 22px; }
  .theme-menu { display: none; }
  .site-header .btn-primary.header-cta { display: none; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-side { grid-template-rows: auto; }
  .hero-feature { min-height: 380px; }
  .stats-strip { grid-template-columns: repeat(2, 1fr); }
  .game-shell { grid-template-columns: 1fr; }
  .list-layout, .post-layout { grid-template-columns: 1fr; }
  .toc { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 420px) {
  .header-inner { gap: 10px; }
  .header-login { display: none; }
  .brand-name { font-size: 1.05rem; }
  .hero-content { padding: 22px 18px; }
  .hero-content h1 { font-size: 1.75rem; }
}

@media (max-width: 760px) {
  :root { --header-h: 66px; }
  .container { padding-inline: 16px; }
  .header-inner { gap: 12px; }
  .brand-tag { display: none; }
  .header-search { display: none; }
  .mobile-toggle {
    display: grid;
    place-items: center;
    width: 40px; height: 40px;
    border-radius: 11px;
    border: 1px solid var(--line);
    color: var(--text);
    margin-inline-start: auto;
  }
  .mobile-toggle svg { width: 22px; height: 22px; }
  .theme-menu { display: none; }
  .site-header .btn-primary.header-cta { display: none; }
  .hero { padding-top: 24px; }
  .hero-feature { min-height: 400px; border-radius: var(--radius-lg); }
  .hero-content { padding: 24px 20px; }
  .hero-content h1 { font-size: 1.9rem; }
  .section { padding-block: 38px; }
  .grid-games { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 11px; }
  .game-name { font-size: 0.82rem; }
  .game-sub { display: none; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .featured-rail { grid-template-columns: 1fr; }
  .stats-strip { grid-template-columns: 1fr 1fr; }
  .stat-cell { padding: 14px; }
  .stat-cell strong { font-size: 1.1rem; }
  .footer-grid { grid-template-columns: 1fr; gap: 26px; padding-block: 34px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .player-stage { aspect-ratio: 4 / 3; }
  .game-heading { margin-top: 18px; }
  .post-cover { aspect-ratio: 16 / 9; border-radius: var(--radius); }
  .section-head { align-items: flex-start; }
  .mobile-dock {
    display: flex;
    position: fixed;
    bottom: 0; inset-inline: 0;
    z-index: 50;
    background: rgba(11, 8, 20, 0.92);
    backdrop-filter: blur(16px);
    border-top: 1px solid var(--line);
    padding: 8px 14px calc(8px + env(safe-area-inset-bottom));
    justify-content: space-around;
    gap: 4px;
  }
  .dock-link { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 0.6rem; color: var(--faint); font-weight: 600; padding: 4px 10px; border-radius: 9px; }
  .dock-link svg { width: 20px; height: 20px; }
  .dock-link.is-active { color: var(--accent-2); }
  body { padding-bottom: 62px; }
}

/* Mobile slide menu ------------------------------------------------------- */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(6, 4, 12, 0.98);
  backdrop-filter: blur(20px);
  padding: 22px;
  overflow-y: auto;
  transform: translateY(-8px);
  opacity: 0;
  visibility: hidden;
  transition: 0.28s var(--ease);
}
.mobile-menu.is-open { opacity: 1; visibility: visible; transform: translateY(0); }
.mobile-menu-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 26px; }
.mobile-menu nav { display: flex; flex-direction: column; gap: 3px; }
.mobile-menu nav a { padding: 13px 14px; border-radius: 12px; font-size: 0.98rem; font-weight: 600; color: var(--muted); border: 1px solid transparent; }
.mobile-menu nav a:hover, .mobile-menu nav a.is-active { color: #fff; background: rgba(255, 255, 255, 0.05); border-color: var(--line); }
.mobile-menu .m-section { font-size: 0.68rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); margin: 22px 0 8px; padding-inline: 6px; }
.mobile-menu .m-search { margin-bottom: 10px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}

/* ==========================================================================
   RTL refinements
   ========================================================================== */
[dir="rtl"] .pagination svg { transform: scaleX(-1); }
[dir="rtl"] .nav-link .caret {
  border-right: 0;
  border-left: 1.6px solid currentColor;
  transform: rotate(-45deg) translateY(-2px);
}

/* ==========================================================================
   Light theme
   ========================================================================== */
:root[data-theme="light"] {
  --bg: #f7f5ff;
  --bg-soft: #ffffff;
  --surface: #ffffff;
  --surface-2: #f2edff;
  --surface-3: #e8e1ff;
  --line: rgba(23, 17, 48, 0.10);
  --line-strong: rgba(23, 17, 48, 0.18);
  --text: #171130;
  --muted: #5f5877;
  --faint: #8b84a3;
  --gold: #a16207;
  --gold-soft: #7a4d0d;
  --success: #047857;
  --danger: #dc2626;
  --shadow-sm: 0 8px 24px rgba(31, 22, 72, 0.08);
  --shadow: 0 20px 60px rgba(31, 22, 72, 0.13);
  --shadow-glow: 0 18px 55px rgba(124, 58, 237, 0.18);
}
:root[data-theme="light"] body::before {
  background:
    radial-gradient(900px 500px at 12% -8%, rgba(124, 58, 237, 0.10), transparent 62%),
    radial-gradient(700px 460px at 92% 4%, rgba(245, 181, 68, 0.10), transparent 60%),
    radial-gradient(800px 700px at 50% 120%, rgba(109, 40, 217, 0.06), transparent 65%);
}
:root[data-theme="light"] .text-gradient {
  background: linear-gradient(100deg, var(--text) 8%, var(--accent) 48%, var(--gold) 96%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
:root[data-theme="light"] .site-header { background: rgba(247, 245, 255, 0.82); }
:root[data-theme="light"] .site-header.is-scrolled { background: rgba(247, 245, 255, 0.95); }
:root[data-theme="light"] .nav-link:hover,
:root[data-theme="light"] .nav-link.is-active { color: var(--text); background: rgba(23, 17, 48, 0.06); }
:root[data-theme="light"] .nav-menu { background: linear-gradient(170deg, #ffffff, #f7f3ff); box-shadow: 0 18px 50px rgba(31, 22, 72, 0.14); }
:root[data-theme="light"] .nav-menu a:hover,
:root[data-theme="light"] .theme-options button:hover { background: rgba(23, 17, 48, 0.05); color: var(--text); }
:root[data-theme="light"] .search-input { background: rgba(255, 255, 255, 0.78); }
:root[data-theme="light"] .search-input:focus { background: #ffffff; }
:root[data-theme="light"] .search-kbd { background: rgba(255, 255, 255, 0.7); }
:root[data-theme="light"] .search-results { background: #ffffff; }
:root[data-theme="light"] .search-results a:hover { background: rgba(23, 17, 48, 0.05); }
:root[data-theme="light"] .icon-btn { background: rgba(255, 255, 255, 0.72); }
:root[data-theme="light"] .icon-btn:hover { color: var(--text); background: #ffffff; }
:root[data-theme="light"] .btn-ghost { background: rgba(23, 17, 48, 0.035); }
:root[data-theme="light"] .btn-ghost:hover { background: rgba(23, 17, 48, 0.08); border-color: var(--line-strong); color: var(--text); }
:root[data-theme="light"] .chip { background: rgba(23, 17, 48, 0.04); }
:root[data-theme="light"] .chip:hover { color: var(--text); background: rgba(23, 17, 48, 0.075); }
:root[data-theme="light"] .chip.is-active { color: var(--accent-deep); background: rgba(124, 58, 237, 0.10); }
:root[data-theme="light"] .badge-violet { color: #6d28d9; background: rgba(124, 58, 237, 0.10); }
:root[data-theme="light"] .badge-live { color: #047857; background: rgba(5, 150, 105, 0.10); }
:root[data-theme="light"] .badge-muted { background: rgba(23, 17, 48, 0.05); }
:root[data-theme="light"] .trend-item { background: rgba(23, 17, 48, 0.025); }
:root[data-theme="light"] .trend-item:hover { background: rgba(23, 17, 48, 0.05); }
:root[data-theme="light"] .stat-cell { background: #ffffff; }
:root[data-theme="light"] .game-card:hover .game-name { color: var(--accent-deep); }
:root[data-theme="light"] .game-card:hover .game-thumb { box-shadow: 0 22px 44px rgba(31, 22, 72, 0.16), 0 0 0 1px rgba(139, 92, 246, 0.2); }
:root[data-theme="light"] .cat-tile { background: linear-gradient(160deg, #ffffff, #f3efff); }
:root[data-theme="light"] .hero-feature .text-gradient {
  background: linear-gradient(100deg, #ffffff 10%, #e6dcff 45%, #ffe1a1 95%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
:root[data-theme="light"] .hero-content p { color: #e3dcf5; }
:root[data-theme="light"] .hero-content .eyebrow { color: #ffd98a; }
:root[data-theme="light"] .hero-content .hero-meta { color: rgba(244, 241, 255, 0.78); }
:root[data-theme="light"] .hero-feature .btn-ghost { color: #ffffff; background: rgba(255, 255, 255, 0.12); border-color: rgba(255, 255, 255, 0.32); }
:root[data-theme="light"] .hero-feature .btn-ghost:hover { color: #ffffff; background: rgba(255, 255, 255, 0.22); border-color: rgba(255, 255, 255, 0.45); }
:root[data-theme="light"] .feature-card { color: #ffffff; }
:root[data-theme="light"] .tool-btn { background: rgba(23, 17, 48, 0.04); }
:root[data-theme="light"] .tool-btn:hover { color: var(--text); background: rgba(23, 17, 48, 0.08); }
:root[data-theme="light"] .breadcrumbs a:hover { color: var(--text); }
:root[data-theme="light"] .rating-stars .empty { color: rgba(23, 17, 48, 0.18); }
:root[data-theme="light"] .game-description,
:root[data-theme="light"] .post-body { color: var(--muted); }
:root[data-theme="light"] .instructions-box { color: #4c3d78; background: rgba(124, 58, 237, 0.06); }
:root[data-theme="light"] .side-panel,
:root[data-theme="light"] .post-card { background: #ffffff; }
:root[data-theme="light"] .mini-item:hover { background: rgba(23, 17, 48, 0.05); }
:root[data-theme="light"] .star-input button { color: rgba(23, 17, 48, 0.18); }
:root[data-theme="light"] .select,
:root[data-theme="light"] .input { background: #ffffff; }
:root[data-theme="light"] .select option { background: #ffffff; }
:root[data-theme="light"] .input:focus { background: #ffffff; }
:root[data-theme="light"] .pagination a:hover { color: var(--text); background: rgba(23, 17, 48, 0.05); }
:root[data-theme="light"] .post-body strong { color: var(--text); }
:root[data-theme="light"] .source-credit { background: rgba(23, 17, 48, 0.035); }
:root[data-theme="light"] .auth-card { background: linear-gradient(170deg, #ffffff, #f7f3ff); }
:root[data-theme="light"] .alert-success { color: #047857; background: rgba(5, 150, 105, 0.08); }
:root[data-theme="light"] .alert-error { color: #be123c; background: rgba(220, 38, 38, 0.07); }
:root[data-theme="light"] .alert-info { color: #1d4ed8; background: rgba(37, 99, 235, 0.07); }
:root[data-theme="light"] .site-footer { background: linear-gradient(180deg, rgba(255, 255, 255, 0.65), #f1ecff); }
:root[data-theme="light"] .footer-col a:hover,
:root[data-theme="light"] .footer-bottom a:hover,
:root[data-theme="light"] .socials a:hover,
:root[data-theme="light"] .section-link:hover { color: var(--text); }
:root[data-theme="light"] .socials a:hover { background: rgba(23, 17, 48, 0.05); }
:root[data-theme="light"] .ad-anchor { background: #ffffff; }
:root[data-theme="light"] .ad-anchor-close { background: #f1ecff; }
:root[data-theme="light"] .ad-anchor-close:hover { color: var(--text); }
:root[data-theme="light"] .player-toolbar { background: #f5f1ff; }
:root[data-theme="light"] .player-loader { color: #f4f1ff; }
:root[data-theme="light"] .player-loader p { color: rgba(244, 241, 255, 0.72); }
:root[data-theme="light"] .mobile-dock { background: rgba(247, 245, 255, 0.94); }
:root[data-theme="light"] .mobile-menu { background: rgba(247, 245, 255, 0.985); }
:root[data-theme="light"] .mobile-menu nav a:hover,
:root[data-theme="light"] .mobile-menu nav a.is-active { color: var(--text); background: rgba(23, 17, 48, 0.05); }
:root[data-theme="light"] .theme-options button[aria-checked="true"] { color: var(--text); }
:root[data-theme="light"] .toast { background: #ffffff; color: var(--text); }
:root[data-theme="light"] .empty-state .icon { background: rgba(124, 58, 237, 0.08); }
:root[data-theme="light"] .section-head h2 .spark { background: linear-gradient(140deg, rgba(124, 58, 237, 0.16), rgba(245, 181, 68, 0.16)); }
