/* ==========================================================================
   Bop Arcade — Dual-Theme Game Portal Stylesheet
   Default: Dark Neon Arcade ([data-theme="dark"])
   Toggle:  Vibrant Light Arcade ([data-theme="light"])
   ========================================================================== */

:root,
[data-theme="dark"] {
  --bg: #0B0D17;
  --bg-elev: #111526;
  --surface: #151A2E;
  --surface-2: #1D243F;
  --header-bg: rgba(11, 13, 23, 0.80);
  --glass-bg: rgba(255, 255, 255, 0.06);
  --glass-hover: rgba(255, 255, 255, 0.12);
  --text: #F8FAFC;
  --muted: #94A3B8;
  --primary: #FF2E88;
  --primary-2: #FF5DA2;
  --primary-glow: rgba(255, 46, 136, 0.42);
  --accent: #00E5FF;
  --accent-soft: rgba(0, 229, 255, 0.14);
  --lime: #A3FF12;
  --lime-text: #0B0D17;
  --violet: #7C3AED;
  --on-primary: #FFFFFF;
  --line: rgba(148, 163, 184, 0.16);
  --line-strong: rgba(148, 163, 184, 0.28);
  --shadow-card: 0 12px 32px rgba(0, 0, 0, 0.36);
  --shadow-hover: 0 18px 42px rgba(0, 0, 0, 0.52), 0 0 0 1px rgba(255, 46, 136, 0.55), 0 0 28px rgba(255, 46, 136, 0.22);
  --btn-play-bg: linear-gradient(135deg, #FF2E88 0%, #FF5D73 100%);
  --btn-play-shadow: 0 8px 24px rgba(255, 46, 136, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.32);
  --spotlight-bg: linear-gradient(135deg, #1A1338 0%, #141933 55%, #0F2038 100%);
  --stage-scrim: linear-gradient(110deg, rgba(11, 13, 23, 0.92) 0%, rgba(11, 13, 23, 0.78) 55%, rgba(11, 13, 23, 0.65) 100%);
  --dock-bg: #0E1222;
  --radius-sm: 10px;
  --radius: 14px;
  --radius-lg: 20px;
  --radius-pill: 999px;
  --display: "Outfit", system-ui, -apple-system, sans-serif;
  --sans: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

[data-theme="light"] {
  --bg: #F5F7FB;
  --bg-elev: #FFFFFF;
  --surface: #FFFFFF;
  --surface-2: #EDF1FA;
  --header-bg: rgba(255, 255, 255, 0.88);
  --glass-bg: rgba(15, 23, 42, 0.05);
  --glass-hover: rgba(59, 91, 219, 0.10);
  --text: #0F172A;
  --muted: #475569;
  --primary: #3B5BDB;
  --primary-2: #FF3B6B;
  --primary-glow: rgba(59, 91, 219, 0.24);
  --accent: #0284C7;
  --accent-soft: rgba(59, 91, 219, 0.10);
  --lime: #FFB703;
  --lime-text: #0F172A;
  --violet: #4C6EF5;
  --on-primary: #FFFFFF;
  --line: rgba(15, 23, 42, 0.09);
  --line-strong: rgba(15, 23, 42, 0.18);
  --shadow-card: 0 8px 24px rgba(15, 23, 42, 0.07), 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-hover: 0 18px 36px rgba(59, 91, 219, 0.16), 0 0 0 2px rgba(59, 91, 219, 0.32);
  --btn-play-bg: linear-gradient(135deg, #FF3B6B 0%, #FF6B4A 100%);
  --btn-play-shadow: 0 5px 0 #C81E4D, 0 10px 22px rgba(255, 59, 107, 0.34);
  --spotlight-bg: linear-gradient(135deg, #273766 0%, #3B5BDB 55%, #5C7CFA 100%);
  --stage-scrim: linear-gradient(110deg, rgba(15, 23, 42, 0.86) 0%, rgba(15, 23, 42, 0.72) 55%, rgba(15, 23, 42, 0.56) 100%);
  --dock-bg: #FFFFFF;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.25s var(--ease), color 0.25s var(--ease);
  overflow-x: hidden;
}

.bg-glow {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  background:
    radial-gradient(600px 420px at 14% -4%, rgba(124, 58, 237, 0.22), transparent 65%),
    radial-gradient(560px 380px at 86% 2%, rgba(0, 229, 255, 0.14), transparent 65%),
    radial-gradient(500px 360px at 50% 24%, rgba(255, 46, 136, 0.08), transparent 70%);
}
[data-theme="light"] .bg-glow {
  background:
    radial-gradient(620px 420px at 12% 0%, rgba(37, 99, 235, 0.11), transparent 64%),
    radial-gradient(520px 360px at 88% 4%, rgba(255, 59, 107, 0.10), transparent 64%),
    radial-gradient(circle, rgba(15, 23, 42, 0.045) 1px, transparent 1px);
  background-size: auto, auto, 24px 24px;
}

img, svg { max-width: 100%; display: block; }
h1, h2, h3 {
  font-family: var(--display);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.02em;
  text-wrap: balance;
  margin: 0 0 12px;
}
h1 { font-size: clamp(28px, 3.6vw, 44px); }
h2 { font-size: clamp(22px, 2.4vw, 30px); }
h3 { font-size: 19px; font-weight: 700; letter-spacing: -0.01em; }
p { margin: 0 0 14px; text-wrap: pretty; }
a { color: var(--accent); text-decoration: none; transition: color 0.18s ease; }
a:hover { color: var(--primary); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
::selection { background: var(--primary); color: #FFFFFF; }

.shell { width: 100%; max-width: 1220px; margin-inline: auto; padding-inline: 20px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 12px; top: 12px; background: var(--surface); color: var(--text); padding: 10px 14px; border-radius: var(--radius-sm); z-index: 200; }

.eyebrow {
  font-family: var(--display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 8px;
}
[data-theme="light"] .eyebrow { color: var(--primary); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--header-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 68px;
  padding-block: 10px;
}
.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
  flex-shrink: 0;
}
.wordmark:hover { color: var(--text); }
.brand-badge {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s var(--ease);
}
[data-theme="light"] .brand-badge {
  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.14);
}
.wordmark:hover .brand-badge { transform: rotate(-6deg) scale(1.06); }
.brand-badge img { width: 100%; height: 100%; display: block; }
.brand-text {
  font-family: var(--display);
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.02em;
}
.brand-text em { font-style: normal; color: var(--accent); }
[data-theme="light"] .brand-text em { color: var(--primary); }

.main-nav {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  background: var(--glass-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
}
.nav-pill {
  padding: 7px 16px;
  border-radius: var(--radius-pill);
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
  transition: background-color 0.2s var(--ease), color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.nav-pill:hover { color: var(--text); background: var(--glass-hover); }
.nav-pill.is-active {
  background: var(--primary);
  color: var(--on-primary);
  box-shadow: 0 4px 14px var(--primary-glow);
}

.header-tools { display: flex; align-items: center; gap: 10px; }
.search-wrap { position: relative; }
.search-ico {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
}
.search-input {
  width: 205px;
  height: 38px;
  padding: 0 14px 0 36px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  background: var(--glass-bg);
  color: var(--text);
  font: inherit;
  font-size: 13.5px;
  transition: width 0.25s var(--ease), border-color 0.2s ease, background-color 0.2s ease;
}
.search-input::placeholder { color: var(--muted); }
.search-input:focus {
  outline: none;
  width: 245px;
  border-color: var(--accent);
  background: var(--surface);
}
.search-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 300px;
  padding: 8px;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.35);
  display: grid;
  gap: 4px;
  z-index: 120;
}
.search-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border-radius: var(--radius-sm);
  color: var(--text);
  transition: background-color 0.16s ease;
}
.search-item:hover { background: var(--surface-2); color: var(--text); }
.search-item img { width: 52px; height: 34px; object-fit: cover; border-radius: 6px; flex-shrink: 0; }
.search-item span { display: flex; flex-direction: column; min-width: 0; }
.search-item strong { font-size: 14px; line-height: 1.2; }
.search-item small { font-size: 12px; color: var(--muted); }
.search-empty { margin: 0; padding: 10px; font-size: 13px; color: var(--muted); text-align: center; }

.theme-toggle {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  background: var(--glass-bg);
  color: var(--text);
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: transform 0.2s var(--ease), border-color 0.2s ease, background-color 0.2s ease;
}
.theme-toggle:hover {
  border-color: var(--accent);
  background: var(--glass-hover);
  transform: rotate(14deg) scale(1.06);
}
[data-theme="dark"] .theme-toggle .ico-moon { display: none; }
[data-theme="light"] .theme-toggle .ico-sun { display: none; }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 11px;
  border-radius: var(--radius-pill);
  font-family: var(--display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.pill-cyan { background: var(--accent); color: #08101C; }
.pill-lime { background: var(--lime); color: var(--lime-text); }
.pill-glass { background: rgba(255, 255, 255, 0.14); color: #FFFFFF; backdrop-filter: blur(8px); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 22px;
  border-radius: var(--radius-pill);
  font-family: var(--display);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.01em;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.18s var(--ease), box-shadow 0.2s var(--ease), background-color 0.2s ease, border-color 0.2s ease;
}
.btn:active { transform: translateY(2px) scale(0.98); }

.btn-play {
  background: var(--btn-play-bg);
  color: #FFFFFF;
  box-shadow: var(--btn-play-shadow);
}
.btn-play:hover {
  color: #FFFFFF;
  transform: translateY(-2px) scale(1.02);
  filter: brightness(1.06);
}

.btn-glass {
  background: var(--glass-bg);
  color: var(--text);
  border-color: var(--line-strong);
}
.btn-glass:hover {
  color: var(--text);
  border-color: var(--accent);
  background: var(--glass-hover);
  transform: translateY(-1px);
}

.bento-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr);
  gap: 18px;
  padding-top: 22px;
}

.spotlight-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.15fr);
  gap: 24px;
  align-items: center;
  padding: 26px;
  border-radius: var(--radius-lg);
  background: var(--spotlight-bg);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  color: #FFFFFF;
}
.spotlight-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 82% 20%, rgba(0, 229, 255, 0.18), transparent 52%);
  pointer-events: none;
}
.spotlight-media {
  position: relative;
  z-index: 1;
  border-radius: 14px;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.35);
}
.spotlight-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--ease);
}
.spotlight-card:hover .spotlight-media img { transform: scale(1.05); }

.spotlight-body { position: relative; z-index: 1; min-width: 0; }
.spotlight-badges { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.spotlight-card h1 {
  font-size: clamp(24px, 2.5vw, 34px);
  color: #FFFFFF;
  margin-bottom: 10px;
}
.spotlight-lede {
  font-size: 14.5px;
  line-height: 1.55;
  color: rgba(248, 250, 252, 0.84);
  margin-bottom: 18px;
}
.spotlight-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.spotlight-card .btn-glass {
  background: rgba(255, 255, 255, 0.12);
  color: #FFFFFF;
  border-color: rgba(255, 255, 255, 0.22);
}
.spotlight-card .btn-glass:hover {
  background: rgba(255, 255, 255, 0.22);
  border-color: #FFFFFF;
}

.spotlight-side {
  display: grid;
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.quick-tile {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr) 36px;
  align-items: center;
  gap: 14px;
  padding: 12px 16px 12px 12px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-card);
  color: var(--text);
  transition: transform 0.22s var(--ease), box-shadow 0.22s var(--ease), border-color 0.22s ease;
}
.quick-tile:hover {
  color: var(--text);
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
  border-color: var(--primary);
}
.quick-tile-thumb {
  aspect-ratio: 16 / 10;
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg-elev);
}
.quick-tile-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s var(--ease);
}
.quick-tile:hover .quick-tile-thumb img { transform: scale(1.08); }
.quick-tile-info { min-width: 0; }
.quick-tile-info .pill { margin-bottom: 6px; font-size: 10px; padding: 3px 9px; }
.quick-tile-info h2 { font-size: 18px; margin: 0 0 2px; }
.quick-tile-info p { margin: 0; font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.quick-tile-go {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--glass-bg);
  color: var(--primary);
  font-size: 12px;
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s var(--ease);
}
.quick-tile:hover .quick-tile-go {
  background: var(--primary);
  color: #FFFFFF;
  transform: scale(1.1);
}

.arcade-catalog { padding-block: 36px 24px; }
.catalog-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.catalog-title-wrap { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.catalog-title-wrap h2 { margin: 0; }
.live-count {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  background: var(--glass-bg);
  border: 1px solid var(--line);
}

.filter-pills,
.category-bar { display: flex; flex-wrap: wrap; gap: 8px; }
.filter-pill {
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
  font-family: var(--display);
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s var(--ease);
}
.filter-pill:hover { color: var(--text); border-color: var(--accent); transform: translateY(-1px); }
.filter-pill.is-active {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--on-primary);
  box-shadow: 0 4px 16px var(--primary-glow);
}

.arcade-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.arcade-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-card);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), border-color 0.25s ease;
}
.arcade-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
  border-color: var(--primary);
}
.arcade-card-link { display: flex; flex-direction: column; flex: 1; color: inherit; text-decoration: none; }
.arcade-card-link:hover { color: inherit; }

.arcade-card-thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--bg-elev);
}
.arcade-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s var(--ease);
}
.arcade-card:hover .arcade-card-thumb img { transform: scale(1.08); }

.card-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  font-family: var(--display);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--accent);
  color: #08101C;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.28);
}
.card-badge--lime { background: var(--lime); color: var(--lime-text); }

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: radial-gradient(circle, rgba(11, 13, 23, 0.22), rgba(11, 13, 23, 0.56));
  opacity: 0;
  transition: opacity 0.25s var(--ease);
}
.arcade-card:hover .play-overlay,
.arcade-card-link:focus-visible .play-overlay { opacity: 1; }

.play-circle {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  padding-left: 3px;
  background: var(--btn-play-bg);
  color: #FFFFFF;
  box-shadow: 0 0 0 6px rgba(255, 255, 255, 0.18), 0 12px 26px rgba(0, 0, 0, 0.45);
  transform: scale(0.75);
  transition: transform 0.28s var(--ease);
}
.arcade-card:hover .play-circle,
.arcade-card-link:focus-visible .play-circle { transform: scale(1); }

.arcade-card-body { padding: 16px 18px 18px; display: flex; flex-direction: column; flex: 1; }
.arcade-card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.arcade-card-top h3 { margin: 0; font-size: 20px; }
.genre-tag {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--muted);
  background: var(--glass-bg);
  border: 1px solid var(--line);
  padding: 2px 9px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
}
.arcade-card-desc {
  margin: 0 0 14px;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.arcade-card-foot {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12.5px;
}
.meta-dot { color: var(--muted); }
.play-label { font-family: var(--display); font-weight: 700; color: var(--primary); transition: transform 0.2s var(--ease); }
.arcade-card:hover .play-label { transform: translateX(3px); }

.arcade-card-sublinks {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 10px 16px 14px;
  border-top: 1px solid var(--line);
  background: var(--bg-elev);
}
.arcade-card-sublinks a {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: var(--glass-bg);
  border: 1px solid var(--line);
  transition: color 0.18s ease, border-color 0.18s ease;
}
.arcade-card-sublinks a:hover { color: var(--primary); border-color: var(--primary); }

.filter-empty {
  text-align: center;
  padding: 40px 20px;
  background: var(--surface);
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-lg);
  margin-top: 16px;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}
.section-head h2 { margin: 0; }
.section-note { margin: 0; font-size: 14px; color: var(--muted); max-width: 42ch; }

.crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding-top: 18px;
  font-size: 13px;
  color: var(--muted);
}
.crumbs a { color: var(--muted); font-weight: 500; }
.crumbs a:hover { color: var(--primary); }

.hero { padding-block: 16px 28px; }
.featured-stage { padding-top: 24px; }

.cabinet-wrap {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-card);
  background: var(--dock-bg);
}

.stage { position: relative; background: #0D111F; overflow: hidden; scroll-margin-top: 84px; }
.stage[data-gf-state="loading"],
.stage[data-gf-state="playing"] { min-height: 660px; height: min(78dvh, 760px); }
.stage[data-gf-orientation="landscape"][data-gf-state="loading"],
.stage[data-gf-orientation="landscape"][data-gf-state="playing"] { min-height: 580px; height: min(74dvh, 700px); }
.stage.is-fullscreen,
.stage.is-fullscreen[data-gf-state] {
  position: fixed;
  inset: 0;
  z-index: 999;
  border-radius: 0;
  border: 0;
  min-height: 100dvh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  background: #0B0D17;
}
.stage.is-fullscreen iframe { min-height: 100dvh; height: 100dvh; }
.fs-close {
  position: absolute;
  top: max(12px, env(safe-area-inset-top));
  right: max(12px, env(safe-area-inset-right));
  z-index: 30;
  background: rgba(11, 13, 23, 0.88);
  color: #FFFFFF;
  border-color: rgba(255, 255, 255, 0.32);
  min-height: 38px;
  padding: 0 14px;
  backdrop-filter: blur(8px);
  transition: transform 0.32s var(--ease), opacity 0.32s var(--ease), padding 0.32s var(--ease), border-radius 0.32s var(--ease), right 0.32s var(--ease), top 0.32s var(--ease);
}
.fs-close.is-docked {
  top: 22%;
  right: 0;
  min-height: 36px;
  min-width: 30px;
  padding: 0 8px 0 10px;
  border-radius: 999px 0 0 999px;
  border-right: 0;
  opacity: 0.62;
  font-size: 14px;
  background: rgba(11, 13, 23, 0.72);
  box-shadow: -2px 2px 10px rgba(0, 0, 0, 0.35);
}
.fs-close.is-docked:hover,
.fs-close.is-docked:active {
  opacity: 1;
}
html.gf-fs-lock, html.gf-fs-lock body { overflow: hidden; }

.cover { position: relative; color: #F8FAFC; overflow: hidden; }
.cover-backdrop {
  position: absolute;
  inset: -24px;
  background-size: cover;
  background-position: center;
  filter: blur(26px) saturate(1.3);
  opacity: 0.42;
  transform: scale(1.08);
  pointer-events: none;
}
.cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--stage-scrim);
  pointer-events: none;
}
.cover-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
  gap: 32px;
  align-items: center;
  padding: 36px;
}
.cover-copy { min-width: 0; }
.cover-copy .eyebrow { color: #00E5FF; }
.cover-copy h1, .cover-copy h3 { color: #FFFFFF; margin-bottom: 12px; }
.cover-copy h1 { font-size: clamp(28px, 3.8vw, 44px); }
.cover-copy h3 { font-size: clamp(24px, 3vw, 34px); }
.lede { font-size: 16.5px; line-height: 1.55; color: rgba(241, 245, 249, 0.86); max-width: 48ch; margin-bottom: 22px; }
.cat-banner .lede { color: var(--muted); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 22px; }
.cover .btn-glass { background: rgba(255, 255, 255, 0.10); color: #FFFFFF; border-color: rgba(255, 255, 255, 0.24); }
.cover .btn-glass:hover { background: rgba(255, 255, 255, 0.18); border-color: #00E5FF; }

.cover-art { margin: 0; }
.cover-art .game-art {
  width: 100%;
  aspect-ratio: 4 / 5;
  max-height: 460px;
  object-fit: cover;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.5);
}
.cover-art--landscape .game-art { aspect-ratio: 16 / 10; max-height: 360px; }
.cover-art figcaption { margin-top: 10px; font-size: 12.5px; color: rgba(226, 232, 240, 0.72); }
.cover-art figcaption a { color: #00E5FF; }

.facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}
.facts div { padding: 10px 12px; border-radius: 12px; background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.10); }
.facts dt { font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: rgba(203, 213, 225, 0.78); margin-bottom: 2px; }
.facts dd { margin: 0; font-family: var(--display); font-size: 16px; font-weight: 700; color: #FFFFFF; }

.loading {
  position: relative;
  padding: 48px 24px;
  min-height: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 8px;
  color: var(--muted);
  background:
    radial-gradient(circle at 50% 42%, var(--primary-glow), transparent 56%),
    radial-gradient(circle at 50% 60%, var(--accent-soft), transparent 60%),
    var(--bg-elev);
}
.loading-spinner { position: relative; width: 56px; height: 56px; margin-bottom: 12px; display: grid; place-items: center; }
.loading-spinner::before, .loading-spinner::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 3px solid transparent; }
.loading-spinner::before { border-top-color: var(--primary); border-right-color: var(--primary-glow); animation: gf-spin 0.9s cubic-bezier(0.55, 0.15, 0.45, 0.85) infinite; }
.loading-spinner::after { inset: 8px; border-bottom-color: var(--accent); border-left-color: var(--accent-soft); animation: gf-spin-rev 1.3s linear infinite; }
.loading-spinner span { width: 10px; height: 10px; border-radius: 50%; background: var(--primary); animation: gf-pulse 1.3s ease-in-out infinite; }
.loading-title { margin: 0; font-family: var(--display); font-size: 24px; font-weight: 700; color: var(--text); }
.loading-sub { margin: 0 0 12px; font-size: 13.5px; color: var(--muted); max-width: 36ch; }
.loading-bar { position: relative; width: min(240px, 72%); height: 5px; border-radius: 999px; background: var(--line); overflow: hidden; }
.loading-bar span { position: absolute; inset: 0; width: 42%; border-radius: 999px; background: linear-gradient(90deg, var(--primary), var(--accent)); animation: gf-slide 1.2s cubic-bezier(0.4, 0, 0.2, 1) infinite; }
@keyframes gf-spin { to { transform: rotate(360deg); } }
@keyframes gf-spin-rev { to { transform: rotate(-360deg); } }
@keyframes gf-pulse { 0%, 100% { transform: scale(0.75); opacity: 0.55; } 50% { transform: scale(1.2); opacity: 1; } }
@keyframes gf-slide { 0% { transform: translateX(-110%); } 100% { transform: translateX(260%); } }

.player-fallback { max-width: 46ch; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); text-align: center; }
.player-fallback .hero-actions { margin-bottom: 0; justify-content: center; }
.player-fallback-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
  padding: 12px 16px;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  font-size: 13.5px;
  color: var(--text);
}
[data-gf-frame] iframe { width: 100%; min-height: 560px; border: 0; }

.cabinet-dock {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px 20px;
  background: var(--dock-bg);
  border-top: 1px solid var(--line);
}
.dock-meta { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; }
.dock-dot { width: 9px; height: 9px; border-radius: 50%; background: #22C55E; box-shadow: 0 0 10px rgba(34, 197, 94, 0.8); }
.dock-meta strong { font-family: var(--display); font-weight: 700; color: var(--text); }
.dock-meta span:last-child { font-size: 12.5px; color: var(--muted); }

.controls { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 0 14px;
  background: var(--glass-bg);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.18s var(--ease);
}
.chip:hover { color: var(--primary); border-color: var(--primary); background: var(--glass-hover); transform: translateY(-1px); }
.chip[aria-pressed="true"] { background: var(--primary); color: #FFFFFF; border-color: var(--primary); }
.chip-fs { border-color: var(--line-strong); }
.notice { font-size: 12.5px; color: var(--accent); font-weight: 600; }

.subnav-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 24px; }
.subnav-link {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  color: var(--text);
  transition: transform 0.2s var(--ease), border-color 0.2s ease, box-shadow 0.2s ease;
}
.subnav-link:hover { transform: translateY(-2px); border-color: var(--accent); box-shadow: var(--shadow-hover); color: var(--text); }
.subnav-link strong { font-family: var(--display); font-size: 15px; color: var(--accent); }
[data-theme="light"] .subnav-link strong { color: var(--primary); }
.subnav-link span { font-size: 13px; color: var(--muted); }

.game-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(280px, 0.85fr);
  gap: 24px;
  align-items: start;
}
.game-main { display: grid; gap: 24px; min-width: 0; }
.game-sidebar { position: sticky; top: 88px; }
.sidebar-box { padding: 20px; }
.sidebar-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.sidebar-head h2 { margin: 0; font-size: 18px; }
.sidebar-head a { font-size: 13px; font-weight: 700; }

.rail-list { display: grid; gap: 10px; }
.rail-card {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr) 28px;
  align-items: center;
  gap: 12px;
  padding: 8px;
  border-radius: 12px;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  color: var(--text);
  transition: transform 0.2s var(--ease), border-color 0.2s ease, background-color 0.2s ease;
}
.rail-card:hover { transform: translateX(3px); border-color: var(--primary); color: var(--text); }
.rail-thumb { aspect-ratio: 16 / 10; border-radius: 8px; overflow: hidden; background: var(--surface-2); }
.rail-thumb img { width: 100%; height: 100%; object-fit: cover; }
.rail-info { display: flex; flex-direction: column; min-width: 0; }
.rail-cat { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--accent); }
[data-theme="light"] .rail-cat { color: var(--primary); }
.rail-info strong { font-family: var(--display); font-size: 15px; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rail-info small { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rail-play { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-size: 10px; background: var(--glass-bg); color: var(--primary); }
.rail-card:hover .rail-play { background: var(--primary); color: #FFFFFF; }

.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 28px;
}

.steps-section { padding-block: 24px; }
.steps-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.step-card { padding: 22px; border-radius: var(--radius-lg); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-card); }
.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent);
  font-family: var(--display);
  font-size: 14px;
  font-weight: 800;
  margin-bottom: 12px;
}
[data-theme="light"] .step-num { color: var(--primary); }
.step-card h3 { margin: 0 0 6px; font-size: 17px; }
.step-card p { margin: 0; font-size: 14px; color: var(--muted); }

.info-deck { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 20px; align-items: start; margin-bottom: 24px; }

.cat-banner {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  padding: 28px;
  margin-top: 20px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-card);
}
.cat-banner h1 { margin-bottom: 8px; }
.cat-banner .lede { margin-bottom: 0; max-width: 56ch; }

.guide p, .prose p { line-height: 1.7; margin-bottom: 1.15em; color: var(--muted); }
.guide strong, .prose strong { color: var(--text); }
.guide h2, .prose h2 { margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--line); font-size: 22px; }
.guide h2:first-child, .prose h2:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.guide h3, .prose h3 { margin-top: 20px; font-size: 17px; }
.guide ul, .prose ul, .guide ol, .prose ol { padding-left: 1.25em; margin: 0 0 16px; color: var(--muted); }
.guide li, .prose li { margin-bottom: 8px; }
.guide table, .prose table { width: 100%; border-collapse: collapse; margin: 18px 0; font-size: 14px; display: block; overflow-x: auto; }
.guide th, .prose th, .guide td, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.guide th, .prose th { font-family: var(--display); font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text); background: var(--bg-elev); }
.guide blockquote, .prose blockquote {
  margin: 18px 0;
  padding: 14px 18px;
  background: var(--bg-elev);
  border-left: 3px solid var(--primary);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}
.guide blockquote p:last-child, .prose blockquote p:last-child { margin-bottom: 0; }

.faq-list { display: grid; gap: 8px; }
.faq details { padding: 14px 16px; border-radius: var(--radius-sm); background: var(--bg-elev); border: 1px solid var(--line); transition: border-color 0.2s ease; }
.faq details[open] { border-color: var(--accent); }
.faq summary { cursor: pointer; font-family: var(--display); font-weight: 700; font-size: 15.5px; color: var(--text); }
.faq summary::marker { color: var(--primary); }
.faq p { margin: 10px 0 0; font-size: 14px; color: var(--muted); }

.discussion { margin-top: 4px; }
.discussion-head p { color: var(--muted); font-size: 14px; margin-bottom: 18px; }
.discussion-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; align-items: start; }
.discussion form { display: grid; gap: 12px; }
.discussion form > p { margin: 0; font-size: 13.5px; color: var(--accent); }
.field { display: grid; gap: 6px; }
.field label { font-family: var(--display); font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.field input, .field textarea {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--bg-elev);
  color: var(--text);
  font: inherit;
  font-size: 14px;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); }
.field textarea { min-height: 92px; resize: vertical; }
.comment { padding: 14px; border-radius: var(--radius-sm); background: var(--bg-elev); border: 1px solid var(--line); margin-bottom: 10px; font-size: 14px; }
.comment header { display: flex; flex-wrap: wrap; gap: 8px; align-items: baseline; color: var(--muted); font-size: 12px; }
.comment header strong { color: var(--text); font-size: 14px; }
.comment p { margin: 6px 0 10px; color: var(--text); }

.prose { max-width: 820px; margin: 18px auto 32px; }
.cta-box {
  margin: 28px 0;
  padding: 22px;
  border-radius: var(--radius);
  background: var(--bg-elev);
  border: 1px solid var(--line-strong);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}
.cta-box h2 { margin: 0 0 6px; padding: 0; border: 0; font-size: 20px; }
.prose figure, .guide figure {
  margin: 22px 0;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-elev);
  border: 1px solid var(--line);
}
.prose figure img, .guide figure img, .prose p > img {
  display: block;
  width: 100%;
  height: auto;
}
.prose p > img {
  margin: 20px 0;
  border-radius: var(--radius);
  border: 1px solid var(--line);
}
.prose figcaption, .guide figcaption {
  padding: 10px 14px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
  border-top: 1px solid var(--line);
}
.cta-box p { margin: 0; max-width: 48ch; font-size: 14px; }
.cta-box .hero-actions { margin-bottom: 0; }
.related { margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--line); }
.related h2 { margin: 0 0 12px; padding: 0; border: 0; font-size: 14px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.related ul { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.related li a {
  display: block;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: var(--bg-elev);
  border: 1px solid var(--line);
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
}
.related li a:hover { border-color: var(--primary); color: var(--primary); }
.legal { padding-block: 24px 48px; }
.back-link { display: inline-flex; margin-bottom: 14px; font-weight: 600; font-size: 14px; }

.site-foot {
  margin-top: 56px;
  padding-block: 40px;
  border-top: 1px solid var(--line);
  background: var(--bg-elev);
  font-size: 14px;
  color: var(--muted);
}
.foot-grid { display: grid; grid-template-columns: 1.25fr 1.35fr 0.9fr; gap: 32px; }
.foot-brand p { margin: 12px 0 14px; max-width: 36ch; font-size: 13.5px; }
.foot-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.foot-badges span {
  font-size: 11.5px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: var(--glass-bg);
  border: 1px solid var(--line);
  color: var(--text);
}
.foot-links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.foot-group { display: flex; flex-direction: column; gap: 8px; }
.foot-group h2 { margin: 0 0 4px; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text); }
.foot-group a, .credit a { color: var(--muted); font-size: 13.5px; }
.foot-group a:hover, .credit a:hover { color: var(--primary); }
.credit p { margin: 0 0 8px; font-size: 13px; }

@media (max-width: 1040px) {
  .bento-hero { grid-template-columns: 1fr; }
  .spotlight-side { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: auto; }
  .arcade-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .game-layout { grid-template-columns: 1fr; }
  .game-sidebar { position: static; }
  .rail-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .info-deck { grid-template-columns: 1fr; }
}

@media (max-width: 860px) {
  .header-inner { flex-wrap: wrap; gap: 10px; }
  .main-nav { order: 3; width: 100%; justify-content: flex-start; overflow-x: auto; scrollbar-width: none; }
  .search-input { width: 155px; }
  .search-input:focus { width: 185px; }
  .spotlight-card { grid-template-columns: 1fr; padding: 20px; }
  .cover-inner { grid-template-columns: 1fr; padding: 22px; gap: 20px; }
  .cover-art .game-art { aspect-ratio: 16 / 10; max-height: 260px; }
  .subnav-strip, .steps-grid, .discussion-body, .foot-grid, .related ul { grid-template-columns: 1fr; }
  .stage[data-gf-state="loading"], .stage[data-gf-state="playing"] { min-height: 560px; height: 75dvh; }
  .stage[data-gf-orientation="landscape"][data-gf-state="loading"],
  .stage[data-gf-orientation="landscape"][data-gf-state="playing"] { min-height: 420px; height: 62dvh; }
  [data-gf-frame] iframe { min-height: 480px; }
}

@media (max-width: 640px) {
  .spotlight-side, .arcade-grid, .rail-list, .foot-links { grid-template-columns: 1fr; }
  .panel { padding: 20px; }
  .hero-actions .btn, .spotlight-actions .btn { width: 100%; }
  .search-wrap { display: none; }
}

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

.mobile-desktop-hint { display: none; margin: 0 0 16px; padding: 10px 14px; border-radius: var(--radius-sm); background: var(--accent-soft); border: 1px solid var(--line-strong); font-size: 13px; line-height: 1.45; color: #F8FAFC; }
@media (max-width: 860px) {
  .mobile-desktop-hint { display: block; }
}

.stage:fullscreen,
.stage:-webkit-full-screen,
.stage.is-fullscreen,
.stage.is-fullscreen[data-gf-state],
.stage.is-fullscreen[data-gf-orientation][data-gf-state] {
  position: fixed !important;
  inset: 0 !important;
  width: 100vw !important;
  height: 100dvh !important;
  min-height: 100dvh !important;
  max-height: none !important;
  z-index: 9999 !important;
  border-radius: 0 !important;
  border: 0 !important;
  margin: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  background: #0B0D17 !important;
}
.stage:fullscreen iframe,
.stage:-webkit-full-screen iframe,
.stage.is-fullscreen iframe {
  width: 100% !important;
  height: 100% !important;
  min-height: 100dvh !important;
}