/* Ensure all elements with [hidden] are completely invisible */
[hidden], .search-modal[hidden], .categories-drawer[hidden], .drawer-backdrop[hidden] {
  display: none !important;
}

/* ==========================================================================
   FIGHT.WIX3.COM — RETRO ARCADE DESIGN SYSTEM
   - Fast, lightweight, pure CSS
   - 90s Curved Arcade CRT monitor simulation
   - Tight retro boxed-game grid matching reference
   - Translucent frosted top bar & bottom dock
   ========================================================================== */

:root {
  --bg-dark: #090c13;
  --bg-deep: #05070b;
  --bg-card: rgba(16, 20, 29, 0.72);
  --bg-card-hover: rgba(22, 28, 40, 0.88);
  --pitch-green: #00e676;
  --pitch-glow: rgba(0, 230, 118, 0.35);
  --border-glass: rgba(255, 255, 255, 0.08);
  --border-card: rgba(255, 255, 255, 0.12);
  --gold: #ffd700;
  --gold-glow: rgba(255, 215, 0, 0.35);
  --crimson: #ff3355;
  --cyan: #00e5ff;
  --lime: #d5ff53;
  --white: #f5f7fa;
  --muted: #8b9bb0;
  --font-display: "Barlow Condensed", Impact, sans-serif;
  --font-sans: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: "DM Mono", ui-monospace, Menlo, Consolas, monospace;
  --topbar-height: 64px;
  --bottombar-height: 62px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--topbar-height) + 16px);
  background-color: var(--bg-dark);
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--bg-dark);
  background-image: 
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(0, 230, 118, 0.08) 0%, transparent 60%),
    radial-gradient(circle at 15% 40%, rgba(0, 240, 255, 0.03) 0%, transparent 40%),
    radial-gradient(circle at 85% 75%, rgba(0, 230, 118, 0.025) 0%, transparent 50%);
  color: var(--white);
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  padding-top: var(--topbar-height);
  padding-bottom: calc(var(--bottombar-height) + 20px);
  overflow-x: hidden;
  position: relative;
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select, textarea {
  font: inherit;
}

/* ==========================================================================
   90s CURVED ARCADE CRT SCREEN HOVER OVERLAY
   ========================================================================== */
.crt-screen-overlay {
  display: none !important;
  position: fixed;
  inset: 0;
  z-index: 80;
  pointer-events: none;
  overflow: hidden;
  transition: opacity 0.3s ease;
}

body.crt-off .crt-screen-overlay {
  opacity: 0;
}

/* CRT monitor vignette with curved bezel edges */
.crt-vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 98% 94% at 50% 50%, transparent 64%, rgba(0, 0, 0, 0.45) 84%, rgba(0, 0, 0, 0.92) 100%);
  box-shadow: inset 0 0 80px rgba(0, 0, 0, 0.75), inset 0 0 25px rgba(0, 0, 0, 0.9);
}

/* Subtle phosphor scanlines */
.crt-scanlines {
  position: absolute;
  inset: 0;
  background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.22) 50%);
  background-size: 100% 3px;
  opacity: 0.85;
}

/* Overhead arcade tube glare / glass sheen */
.crt-glare {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 110% 48% at 50% -12%, rgba(255, 255, 255, 0.08) 0%, rgba(255, 255, 255, 0.015) 38%, transparent 62%);
  mix-blend-mode: screen;
}

/* Subtle curved barrel distortion illusion border */
.crt-curve {
  position: absolute;
  inset: 2px;
  border-radius: 20px;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.08), inset 0 -1px 1px rgba(255, 255, 255, 0.04);
}

/* ==========================================================================
   TOP BAR (TRANSLUCENT / SEE-THROUGH / FIXED)
   ========================================================================== */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--topbar-height);
  z-index: 95;
  background: rgba(9, 12, 17, 0.78);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border-bottom: 1px solid var(--border-glass);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.topbar-inner {
  max-width: 1440px;
  height: 100%;
  margin: 0 auto;
  padding: 0 clamp(14px, 3vw, 36px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.topbar-brand {
  display: flex;
  align-items: center;
}

/* ==========================================================================
   BROWSERKICKS MODERN SOCCER BRAND IDENTITY (DISTINCT FROM BROWSERFIGHTS)
   ========================================================================== */
.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.kicks-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  user-select: none;
}

.kicks-crest-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: radial-gradient(circle at 35% 35%, #153422, #08170e);
  border: 1.5px solid #00e676;
  border-radius: 8px;
  box-shadow: 0 0 12px rgba(0, 230, 118, 0.45), inset 0 1px 1px rgba(255, 255, 255, 0.25);
  flex-shrink: 0;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.brand:hover .kicks-crest-badge {
  transform: scale(1.08) rotate(-4deg);
  box-shadow: 0 0 20px rgba(0, 230, 118, 0.7);
}

.kicks-brand-text {
  display: inline-flex;
  align-items: baseline;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-weight: 900;
  line-height: 1;
}

.kicks-brand-word1 {
  font-size: 21px;
  font-weight: 800;
  color: #f8fafc;
  letter-spacing: 0.06em;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.9);
}

.kicks-brand-word2 {
  font-size: 23px;
  font-weight: 900;
  color: #00e676;
  letter-spacing: 0.05em;
  margin-left: 2px;
  text-shadow: 0 0 16px rgba(0, 230, 118, 0.65), 0 2px 4px rgba(0, 0, 0, 0.9);
}

.kicks-brand-tld {
  font-family: var(--font-mono), monospace;
  font-size: 11px;
  font-weight: 800;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.35);
  padding: 2px 6px;
  border-radius: 4px;
  letter-spacing: 0.08em;
  margin-left: 6px;
  text-shadow: 0 0 8px rgba(56, 189, 248, 0.5);
  align-self: center;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 14px;
}

.topbar-stat {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-glass);
  border-radius: 20px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
}

.topbar-stat-games {
  display: flex;
  align-items: center;
  gap: 4px;
}

.topbar-stat-games strong {
  color: #fff;
  font-weight: 700;
}

.topbar-stat-dot {
  color: rgba(255, 255, 255, 0.2);
  font-size: 10px;
}

.topbar-stat-active {
  display: flex;
  align-items: center;
  gap: 6px;
}

.topbar-stat-active strong {
  color: var(--lime);
  font-weight: 700;
}

.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 0 0 8px var(--lime);
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

/* Systems Dropdown Toggle */
.systems-control {
  position: relative;
}

.systems-toggle {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  color: var(--white);
  padding: 7px 13px;
  border-radius: 8px;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s ease;
}

.systems-toggle:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
  color: var(--gold);
}

.systems-panel {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: min(340px, 90vw);
  max-height: 70vh;
  overflow-y: auto;
  background: rgba(14, 18, 25, 0.95);
  backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  padding: 14px;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.6);
  z-index: 100;
}

.systems-panel-title {
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.systems-panel .system-filters {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.systems-panel .system-filter {
  text-align: left;
  padding: 7px 10px;
  border-radius: 6px;
  border: 1px solid transparent;
  background: transparent;
  color: #cfd8dc;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.12s ease;
}

.systems-panel .system-filter:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--white);
}

.systems-panel .system-filter.active {
  background: var(--gold);
  color: #0b0e14;
  font-weight: 700;
}

/* ==========================================================================
   BOTTOM BAR (MATCHING TRANSLUCENT DOCK ACROSS SCREEN)
   ========================================================================== */
.bottombar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--bottombar-height);
  z-index: 95;
  background: rgba(9, 12, 17, 0.85);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border-top: 1px solid var(--border-glass);
  box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
}

.bottombar-inner {
  max-width: 900px;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0 8px;
}

.bottombar-btn {
  background: transparent;
  border: none;
  color: #a0aec0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
  position: relative;
  min-width: 54px;
}

.bottombar-btn:hover {
  color: var(--white);
  background: rgba(255, 255, 255, 0.05);
}

.bottombar-btn.active {
  color: var(--gold);
}

.bottombar-btn .btn-icon {
  font-size: 16px;
  line-height: 1;
}

.bottombar-btn .btn-label {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.bottombar-badge {
  position: absolute;
  top: 3px;
  right: 10px;
  background: var(--gold);
  color: #000;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 800;
  padding: 1px 5px;
  border-radius: 10px;
  line-height: 1.2;
}

/* ==========================================================================
   GAME BOXES — TIGHT PACKING (LIKE THE USER IMAGE)
   ========================================================================== */
.library.section {
  max-width: 1680px;
  margin: 0 auto;
  padding: 14px clamp(8px, 1.8vw, 24px) 40px;
}

.library-controls {
  margin-bottom: 12px;
}

.searchbox-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
}

.searchbox {
  flex: 1;
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  padding: 0 14px;
  height: 44px;
  transition: border-color 0.15s, background 0.15s;
}

.searchbox:focus-within {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 215, 0, 0.45);
  box-shadow: 0 0 12px rgba(255, 215, 0, 0.15);
}

.search-symbol {
  color: var(--muted);
  font-size: 16px;
  margin-right: 10px;
}

.searchbox input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--white);
  font-size: 13px;
}

.searchbox input::placeholder {
  color: #718096;
}

.search-count-pill {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  white-space: nowrap;
}

/* System Groupings */
.system-group {
  margin-top: 28px;
  content-visibility: auto;
  contain-intrinsic-size: 400px;
}

.system-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding-bottom: 6px;
}

.system-group h2, .section-heading h2 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin: 0;
  color: #e2e8f0;
}

.system-badge {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--gold);
  background: rgba(255, 215, 0, 0.08);
  border: 1px solid rgba(255, 215, 0, 0.2);
  padding: 2px 7px;
  border-radius: 4px;
}

/* ==========================================================================
   COMPACT PHYSICAL 3D GAME SHELF WALL (ZERO GAPS / PERFECTLY ALIGNED)
   ========================================================================== */
.game-grid, .game-shelf-wall {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
  gap: 3.5px 3.5px; /* TIGHT MOSAIC WALL LIKE USER PIC */
  margin: 0;
  padding: 0 0 24px;
  width: 100%;
}

@media (min-width: 1600px) {
  .game-grid, .game-shelf-wall {
    grid-template-columns: repeat(auto-fill, minmax(178px, 1fr));
    gap: 4px 4px;
  }
}

@media (max-width: 1200px) {
  .game-grid, .game-shelf-wall {
    grid-template-columns: repeat(auto-fill, minmax(152px, 1fr));
    gap: 3px 3px;
  }
}

@media (max-width: 768px) {
  .game-grid, .game-shelf-wall {
    grid-template-columns: repeat(auto-fill, minmax(128px, 1fr));
    gap: 2.5px 2.5px;
  }
}

@media (max-width: 480px) {
  .game-grid, .game-shelf-wall {
    grid-template-columns: repeat(3, 1fr);
    gap: 2px 2px;
  }
}

/* COMPACT GAME CARD */
.game-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
  margin: 0;
  cursor: pointer;
  transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1), z-index 0.22s ease;
}

.game-card:hover {
  transform: translateY(-8px) scale(1.08);
  z-index: 60;
}

.card-link {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  color: inherit;
  text-decoration: none;
}

/* 3D Physical Game Case - UNIFORM PROPORTIONS: LINES UP PERFECTLY */
.case-3d {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1.42; /* Standard DVD / Game Case proportions */
  display: flex;
  transform-style: preserve-3d;
  perspective: 900px;
  filter: drop-shadow(-3px 5px 6px rgba(0, 0, 0, 0.85));
  transition: filter 0.22s ease;
}

.game-card:hover .case-3d {
  filter: drop-shadow(-10px 18px 24px rgba(0, 0, 0, 0.95)) drop-shadow(0 0 16px rgba(0, 230, 118, 0.5));
}

/* Left Visible Spine (Turned 3D Edge) */
.case-spine {
  width: 20px;
  flex-shrink: 0;
  position: relative;
  transform-origin: right center;
  transform: rotateY(-48deg);
  border-radius: 2px 0 0 2px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  padding: 6px 1px;
  overflow: hidden;
  z-index: 2;
  box-shadow: inset 1px 0 2px rgba(255, 255, 255, 0.4), inset -2px 0 3px rgba(0, 0, 0, 0.85);
  background: #11141c;
}

.case-spine .spine-text {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-family: var(--font-sans), -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 8.5px;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: #fff;
  white-space: nowrap;
  max-height: 60%;
  overflow: hidden;
  text-overflow: ellipsis;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.85);
}

.case-spine .spine-logo {
  font-family: var(--font-mono), monospace;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.5px;
  color: #fff;
}

.case-spine .spine-code {
  font-family: var(--font-mono), monospace;
  font-size: 7px;
  opacity: 0.65;
  color: #cbd5e1;
}

/* Console-Specific Spine Styling */
.case-ps2 .case-spine {
  background: linear-gradient(to right, #001f4d, #000c24);
  border-left: 2px solid #00f0ff;
}
.case-ps2 .spine-logo { color: #00f0ff; }

.case-ps1 .case-spine {
  background: linear-gradient(to right, #2d3748, #1a202c);
  border-left: 2px solid #e2e8f0;
}
.case-ps1 .spine-logo { color: #f8fafc; }

.case-ps3 .case-spine {
  background: linear-gradient(to right, #1a1a1a, #0a0a0a);
  border-left: 2px solid #e50914;
}
.case-ps3 .spine-logo { color: #e50914; }

.case-ps4 .case-spine {
  background: linear-gradient(to right, #003791, #001e54);
  border-left: 2px solid #38bdf8;
}
.case-ps4 .spine-logo { color: #38bdf8; }

.case-ps5 .case-spine {
  background: linear-gradient(to right, #f8fafc, #cbd5e1);
  border-left: 2px solid #00439c;
}
.case-ps5 .spine-text, .case-ps5 .spine-logo, .case-ps5 .spine-code { color: #0f172a; text-shadow: none; }

.case-psp .case-spine {
  background: linear-gradient(to right, #1e293b, #0f172a);
  border-left: 2px solid #cbd5e1;
}
.case-psp .spine-logo { color: #f1f5f9; }

.case-xbox .case-spine, .case-xbox360 .case-spine, .case-xboxone .case-spine, .case-xboxseries .case-spine {
  background: linear-gradient(to right, #107c10, #063806);
  border-left: 2px solid #70e000;
}
.case-xbox360 .spine-logo, .case-xboxone .spine-logo, .case-xbox .spine-logo { color: #70e000; }

.case-gba .case-spine {
  background: linear-gradient(to right, #7b1fa2, #4a148c);
  border-left: 2px solid #e1bee7;
}
.case-gba .spine-logo { color: #e1bee7; }

.case-gbc .case-spine, .case-gameboy .case-spine {
  background: linear-gradient(to right, #475569, #1e293b);
  border-left: 2px solid #94a3b8;
}

.case-nds .case-spine {
  background: linear-gradient(to right, #475569, #0f172a);
  border-left: 2px solid #38bdf8;
}

.case-n64 .case-spine {
  background: linear-gradient(to right, #b91c1c, #7f1d1d);
  border-left: 2px solid #fbbf24;
}
.case-n64 .spine-logo { color: #fbbf24; }

.case-gamecube .case-spine {
  background: linear-gradient(to right, #4c1d95, #2e1065);
  border-left: 2px solid #a855f7;
}
.case-gamecube .spine-logo { color: #c084fc; }

.case-snes .case-spine {
  background: linear-gradient(to right, #334155, #1e293b);
  border-left: 2px solid #cbd5e1;
}

.case-sega .case-spine {
  background: linear-gradient(to right, #0369a1, #0c4a6e);
  border-left: 2px solid #38bdf8;
}

.case-pc .case-spine {
  background: linear-gradient(to right, #0f172a, #020617);
  border-left: 2px solid #38bdf8;
}
.case-pc .spine-logo { color: #38bdf8; }

.case-switch .case-spine {
  background: linear-gradient(to right, #e11d48, #9f1239);
  border-left: 2px solid #ffffff;
}
.case-switch .spine-logo { color: #ffffff; }

/* Front Casing (Authentic black plastic keep-case frame holding sleeve) */
.case-front {
  flex: 1;
  position: relative;
  background: #0d0f14;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-left: none;
  border-radius: 0 4px 4px 0;
  padding: 2.5px 3.5px 3.5px 0;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18), inset -1px -1px 0 rgba(0, 0, 0, 0.8);
  display: flex;
}

.case-art-wrap {
  width: 100%;
  height: 100%;
  position: relative;
  border-radius: 0 3px 3px 0;
  overflow: hidden;
  background: #0d0f14;
  display: flex;
}

.case-art-wrap .poster {
  width: 100%;
  height: 100%;
  margin: 0;
  border-radius: 0;
  box-shadow: none;
  display: flex;
  flex-direction: column;
}

.case-art-wrap img.cover-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Plastic Sheen Reflection */
.case-sheen {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(115deg, rgba(255, 255, 255, 0.25) 0%, rgba(255, 255, 255, 0.06) 12%, transparent 28%, transparent 70%, rgba(255, 255, 255, 0.1) 100%);
  mix-blend-mode: screen;
}

/* Card Hover HUD (Smooth reveal over the game cover) */
.card-hover-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.95) 0%, rgba(0, 0, 0, 0.6) 45%, rgba(0, 0, 0, 0.2) 100%);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 8px 6px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease;
  z-index: 10;
}

.game-card:hover .card-hover-overlay {
  opacity: 1;
  pointer-events: auto;
}

.play-pill {
  align-self: center;
  margin-top: auto;
  margin-bottom: 6px;
  background: #00e676;
  color: #041008;
  font-family: var(--font-sans), sans-serif;
  font-weight: 900;
  font-size: 10.5px;
  letter-spacing: 0.05em;
  padding: 4px 12px;
  border-radius: 12px;
  box-shadow: 0 3px 10px rgba(0, 230, 118, 0.6);
  transform: translateY(4px);
  transition: transform 0.18s ease;
}

.game-card:hover .play-pill {
  transform: translateY(0);
}

.card-hover-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.hover-title {
  font-size: 11px;
  font-weight: 800;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.9);
}

.hover-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 9px;
  font-family: var(--font-mono), monospace;
}

.hover-plat {
  color: #00e676;
  font-weight: 700;
}

.hover-year {
  color: #94a3b8;
}

/* Card bookmark button in upper right corner of card */
.game-card .card-bookmark {
  position: absolute;
  top: 5px;
  right: 5px;
  z-index: 20;
  background: rgba(0, 0, 0, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #cbd5e1;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.game-card:hover .card-bookmark,
.game-card .card-bookmark.bookmarked,
.game-card .card-bookmark.is-bookmarked {
  opacity: 1;
}

.game-card .card-bookmark:hover {
  background: rgba(0, 230, 118, 0.25);
  color: #00e676;
  border-color: #00e676;
}

.game-card .card-bookmark.bookmarked,
.game-card .card-bookmark.is-bookmarked {
  color: #ffd700;
  border-color: #ffd700;
  background: rgba(0, 0, 0, 0.85);
}

/* Random Game Highlight Flash */
.game-card.random-highlight {
  animation: arcade-flash 1.8s ease-out;
}

@keyframes arcade-flash {
  0% { transform: scale(1.08); filter: drop-shadow(0 0 25px #00e676); z-index: 50; }
  25% { transform: scale(1.06); filter: drop-shadow(0 0 20px #38bdf8); }
  50% { transform: scale(1.04); filter: drop-shadow(0 0 20px #ffd700); }
  100% { transform: scale(1); }
}

/* ==========================================================================
   POPULAR GAMES & ACTIVE FILTER BAR
   ========================================================================== */
.popular-games {
  margin-bottom: 28px;
}

.popular-game-grid {
  grid-template-columns: repeat(auto-fill, minmax(154px, 1fr));
  gap: 8px 6px;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 4px;
}

.active-filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  margin-bottom: 18px;
  background: rgba(255, 215, 0, 0.08);
  border: 1px solid rgba(255, 215, 0, 0.25);
  border-radius: 8px;
}

.active-filter-text {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--gold);
}

.clear-filter-btn {
  background: rgba(255, 215, 0, 0.15);
  border: 1px solid rgba(255, 215, 0, 0.3);
  color: var(--gold);
  padding: 5px 11px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.clear-filter-btn:hover {
  background: var(--gold);
  color: #000;
}

.empty-state {
  text-align: center;
  padding: 48px 16px;
  color: var(--muted);
  font-size: 14px;
}

/* ==========================================================================
   CATEGORIES DRAWER (SLIDE-UP FROM BOTTOM)
   ========================================================================== */
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px);
  z-index: 98;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.drawer-backdrop:not([hidden]) {
  opacity: 1;
  pointer-events: auto;
}

.categories-drawer:not([hidden]) {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  max-height: 82vh;
  background: rgba(13, 17, 24, 0.96);
  backdrop-filter: blur(24px);
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 16px 16px 0 0;
  z-index: 99;
  transform: translateY(100%);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  padding-bottom: max(16px, env(safe-area-inset-bottom));
}

.categories-drawer:not([hidden]) {
  transform: translateY(0);
}

.drawer-header {
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.drawer-title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}

.drawer-icon {
  font-size: 24px;
}

.drawer-title-wrap h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--white);
}

.drawer-title-wrap p {
  margin: 0;
  font-size: 11px;
  color: var(--muted);
}

.drawer-close {
  background: rgba(255, 255, 255, 0.07);
  border: none;
  color: var(--white);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  display: grid;
  place-items: center;
  font-size: 14px;
}

.drawer-systems-grid {
  padding: 16px 20px 24px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 8px;
  overflow-y: auto;
}

.drawer-system-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  color: #e2e8f0;
  cursor: pointer;
  transition: all 0.15s ease;
}

.drawer-system-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
  color: var(--white);
}

.drawer-system-btn.active {
  background: var(--gold);
  border-color: var(--gold);
  color: #0a0e14;
  font-weight: 700;
}

.drawer-btn-name {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
}

.drawer-btn-count {
  font-family: var(--font-mono);
  font-size: 10px;
  opacity: 0.8;
}

/* ==========================================================================
   SEARCH MODAL
   ========================================================================== */
.search-modal:not([hidden]) {
  position: fixed;
  inset: 0;
  z-index: 105;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 60px 16px;
}

.search-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
}

.search-modal-panel {
  position: relative;
  width: min(600px, 100%);
  max-height: 75vh;
  background: rgba(14, 18, 25, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.search-modal-head {
  display: flex;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  gap: 10px;
}

.search-modal-icon {
  font-size: 18px;
  color: var(--gold);
}

.search-modal-head input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--white);
  font-size: 15px;
}

.search-modal-close {
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 16px;
  cursor: pointer;
}

.search-modal-body {
  padding: 16px;
  overflow-y: auto;
  max-height: 55vh;
}

.search-modal-hint {
  color: var(--muted);
  font-size: 13px;
  margin: 0;
  text-align: center;
  padding: 24px 0;
}

.search-modal-result-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px;
  border-radius: 6px;
  transition: background 0.12s ease;
}

.search-modal-result-item:hover {
  background: rgba(255, 255, 255, 0.06);
}

.search-result-thumb {
  width: 40px;
  height: 52px;
  object-fit: cover;
  border-radius: 3px;
}

.search-result-copy h4 {
  margin: 0;
  font-size: 13px;
  color: var(--white);
}

.search-result-copy p {
  margin: 2px 0 0;
  font-size: 11px;
  font-family: var(--font-mono);
  color: var(--muted);
}

/* ==========================================================================
   DETAIL PAGE & PLAYER PAGE
   ========================================================================== */
.detail-page {
  max-width: 1000px;
  margin: 0 auto;
  padding: 24px clamp(16px, 4vw, 36px) 60px;
}

.crumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 24px;
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 300px) 1fr;
  gap: 32px;
  align-items: start;
  margin-bottom: 36px;
}

.detail-hero .poster {
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.detail-copy h1 {
  font-family: var(--font-display);
  font-size: clamp(32px, 5vw, 54px);
  font-weight: 800;
  text-transform: uppercase;
  margin: 0 0 16px;
  line-height: 1;
}

.detail-lede {
  color: #cbd5e1;
  font-size: 15px;
  line-height: 1.6;
  margin-bottom: 24px;
}

.button-primary {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: var(--gold);
  color: #0a0e14;
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 12px 24px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(255, 215, 0, 0.35);
  transition: all 0.15s ease;
}

.button-primary:hover {
  background: #ffea70;
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(255, 215, 0, 0.5);
}

.button-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  color: var(--white);
  border: 1px solid var(--border-glass);
  padding: 10px 18px;
  border-radius: 8px;
  font-weight: 700;
  cursor: pointer;
}

.button-disabled {
  display: inline-block;
  padding: 12px 20px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  font-size: 13px;
}

.detail-meta {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.detail-meta small {
  display: block;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--muted);
  margin-bottom: 2px;
}

.detail-meta b {
  font-size: 13px;
  color: var(--white);
}

.detail-note {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 32px;
}

/* Play Shell */
.play-shell {
  max-width: 900px;
  margin: 0 auto;
  padding: 20px 16px 80px;
}

.play-shell-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 16px;
}

.play-shell-head h1 {
  font-family: var(--font-display);
  font-size: 28px;
  margin: 0;
  text-transform: uppercase;
}

.game-player {
  position: relative;
  background: #000;
  border-radius: 10px;
  border: 1px solid var(--border-card);
  overflow: hidden;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.8);
  min-height: 520px;
}

.player-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  background: #0d1117;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
}

.player-fullscreen {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-glass);
  color: var(--white);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 10px;
  cursor: pointer;
}

#game-frame {
  display: block;
  border: none;
}

.player-fallback {
  padding: 10px 14px;
  font-size: 12px;
  color: var(--muted);
  text-align: center;
}

/* Notice & Footer */
.external-games-notice {
  max-width: 1440px;
  margin: 32px auto 16px;
  padding: 12px clamp(14px, 3vw, 36px);
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.02);
  border-top: 1px solid var(--border-glass);
  border-bottom: 1px solid var(--border-glass);
  font-size: 11px;
  color: #718096;
}

.external-games-mark {
  color: var(--gold);
  font-weight: 800;
  font-size: 14px;
}

.site-footer {
  text-align: center;
  padding: 16px 20px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: #718096;
}

.site-footer a {
  margin-left: 12px;
  color: var(--gold);
}

/* Announcement Banner */
.announce {
  min-height: 30px;
  background: var(--gold);
  color: #0a0e14;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0 16px;
}

/* ==========================================================================
   ADMIN PANEL STYLES
   ========================================================================== */
.admin-shell {
  max-width: 1200px;
  margin: auto;
  padding: 40px 24px 100px;
}
.admin-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border-glass);
}
.admin-heading h1 {
  font-family: var(--font-display);
  font-size: 54px;
  margin: 0;
}
.admin-login {
  max-width: 400px;
  margin: 60px auto;
  padding: 28px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 12px;
}
.admin-login form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.game-table-wrap {
  overflow-x: auto;
  margin-top: 24px;
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}
th, td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--border-glass);
}
th {
  font-family: var(--font-mono);
  color: var(--muted);
  font-size: 10px;
}
.status-pill {
  padding: 2px 7px;
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 9px;
  background: rgba(255, 255, 255, 0.05);
}
.status-pill.ready {
  background: rgba(103, 239, 178, 0.15);
  color: #67efb2;
}
.status-pill.failed {
  background: rgba(255, 92, 92, 0.2);
  color: #ff5c5c;
  border: 1px solid rgba(255, 92, 92, 0.4);
}
.table-action {
  background: transparent;
  border: 1px solid var(--border-glass);
  color: var(--white);
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 10px;
  cursor: pointer;
  margin-right: 4px;
}
.table-action.delete {
  color: var(--crimson);
  border-color: rgba(255, 51, 85, 0.3);
}
dialog#game-dialog {
  background: rgba(14, 18, 25, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  color: var(--white);
  max-width: 650px;
  width: 90vw;
  padding: 24px;
}
dialog::backdrop {
  background: rgba(0, 0, 0, 0.75);
}
.dialog-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.form-grid label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 11px;
  color: var(--muted);
}
.form-grid input, .form-grid select, .form-grid textarea {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  color: var(--white);
  padding: 8px 10px;
  border-radius: 6px;
  font-size: 12px;
}
.form-grid .full {
  grid-column: 1 / -1;
}
.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
}
.toast {
  position: fixed;
  bottom: 80px;
  right: 20px;
  background: var(--gold);
  color: #000;
  padding: 8px 16px;
  border-radius: 6px;
  font-weight: 700;
  display: none;
  z-index: 110;
}
.toast:not(:empty) {
  display: block;
}

/* ==========================================================================
   MOBILE & DESKTOP RESPONSIVENESS
   ========================================================================== */
@media (max-width: 768px) {
  :root {
    --topbar-height: 56px;
    --bottombar-height: 58px;
  }
  .game-grid {
    grid-template-columns: repeat(auto-fill, minmax(128px, 1fr));
    gap: 2.5px 2.5px;
  }
  .card-copy, .card-meta-tight {
    padding: 4px 2px 2px;
  }
  .card-title, .card-title-tight {
    font-size: 10px;
  }
  .card-meta, .card-sub-tight {
    font-size: 8px;
  }
  .detail-hero {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .topbar-stat {
    padding: 4px 9px;
    font-size: 10px;
    gap: 5px;
  }
  .topbar-stat .stat-word {
    display: none;
  }
}

@media (max-width: 480px) {
  .game-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 2px 2px;
  }
  .bottombar-btn {
    min-width: 44px;
    padding: 4px 6px;
  }
  .bottombar-btn .btn-icon {
    font-size: 15px;
  }
  .bottombar-btn .btn-label {
    font-size: 9px;
  }
}

.search-modal-go {
  background: var(--gold);
  color: #000;
  border: none;
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 800;
  padding: 6px 14px;
  border-radius: 6px;
  cursor: pointer;
  letter-spacing: 0.04em;
  transition: all 0.15s ease;
  white-space: nowrap;
}
.search-modal-go:hover {
  background: #ffea70;
  transform: scale(1.05);
}


/* ==========================================================================
   PLATFORM MANAGER STYLES
   ========================================================================== */
.platforms-panel {
  margin-top: 24px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 12px;
  padding: 24px;
}
.platforms-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  flex-wrap: wrap;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border-glass);
}
.platforms-heading h2 {
  font-family: var(--font-display);
  font-size: 26px;
  margin: 0;
  letter-spacing: 0.02em;
}
.platforms-heading p {
  color: var(--muted);
  font-size: 12px;
  margin: 4px 0 0;
}
.add-platform-form {
  display: flex;
  gap: 8px;
  align-items: center;
}
.add-platform-form input {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  color: var(--white);
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 13px;
  min-width: 240px;
}
.platform-count-pill {
  padding: 2px 8px;
  border-radius: 12px;
  font-family: var(--font-mono);
  font-size: 10px;
  background: rgba(0, 240, 255, 0.1);
  color: #00f0ff;
  border: 1px solid rgba(0, 240, 255, 0.25);
}
.platform-field-label {
  grid-column: 1 / -1;
}
.platform-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
  max-height: 120px;
  overflow-y: auto;
  padding: 8px;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 6px;
  border: 1px solid var(--border-glass);
}
.platform-chip-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-glass);
  color: var(--muted);
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 11px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.platform-chip-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: var(--white);
}
.platform-chip-btn.selected {
  background: rgba(255, 187, 0, 0.2);
  border-color: var(--gold);
  color: var(--gold);
  font-weight: 600;
}
.platform-chip-btn.chip-add {
  border-style: dashed;
  color: #00f0ff;
  border-color: rgba(0, 240, 255, 0.4);
}
.platform-chips-label {
  font-size: 10px;
  color: var(--muted);
  margin-top: 6px;
  display: block;
}


/* Fallback Modern Stadium Card for entries without custom cover */
.poster-stadium-card {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 12px 10px;
  background: radial-gradient(circle at 50% 25%, #182236 0%, #0a0f1b 60%, #050810 100%);
  border: 1px solid rgba(0, 230, 118, 0.2);
  color: #fff;
  text-align: center;
  box-sizing: border-box;
}
.poster-card-header {
  display: flex;
  justify-content: center;
}
.case-system-pill {
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 700;
  color: #00e676;
  background: rgba(0, 230, 118, 0.12);
  border: 1px solid rgba(0, 230, 118, 0.3);
  padding: 2px 6px;
  border-radius: 4px;
  text-transform: uppercase;
}
.poster-card-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.poster-card-center .soccer-icon {
  font-size: 32px;
  filter: drop-shadow(0 0 10px rgba(0, 230, 118, 0.5));
}
.poster-card-title {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.2;
  text-transform: uppercase;
  color: #f8fafc;
  letter-spacing: 0.02em;
}
.poster-card-footer {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 8px;
  color: #64748b;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 6px;
}

/* ========================================================
   SLENDER VERTICAL SPINES & SEAMLESS SHELVES (NO LINES, CLOSER)
   ======================================================== */

.popular-section {
  margin: 0 0 14px 0;
  padding: 0;
  border: none;
}

.system-shelf-row {
  margin: 0 0 14px 0;
  padding: 0;
  border: none;
}

.shelf-row-container {
  display: flex;
  align-items: stretch;
  gap: 8px;
  position: relative;
  width: 100%;
}

.shelf-vertical-tab {
  width: 36px;
  min-width: 36px;
  max-width: 36px;
  flex: 0 0 36px;
  min-height: 240px;
  align-self: stretch;
  background: linear-gradient(180deg, #101c18 0%, #060e0c 100%);
  border: 1px solid rgba(85, 232, 208, 0.32);
  border-radius: 6px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(85, 232, 208, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 0;
  cursor: pointer;
  user-select: none;
  transition: all 0.16s ease;
  overflow: hidden;
  position: relative;
}

.shelf-vertical-tab:hover {
  border-color: #55e8d0;
  box-shadow: 0 0 14px rgba(85, 232, 208, 0.4), inset 0 1px 0 rgba(85, 232, 208, 0.35);
  transform: scale(1.02);
}

.shelf-vertical-tab.popular-tab {
  background: linear-gradient(180deg, #24140e 0%, #0f0907 100%);
  border-color: rgba(255, 123, 87, 0.45);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 123, 87, 0.25);
  cursor: default;
}

.shelf-vertical-tab.popular-tab:hover {
  border-color: #ff7b57;
  box-shadow: 0 0 14px rgba(255, 123, 87, 0.4), inset 0 1px 0 rgba(255, 123, 87, 0.35);
  transform: none;
}

.vertical-tab-text {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-family: var(--font-display, system-ui, -apple-system, sans-serif);
  font-size: 11.5px;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #55e8d0;
  white-space: nowrap;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.9);
}

.shelf-vertical-tab.popular-tab .vertical-tab-text {
  color: #ff8a6a;
}

.shelf-row-games {
  flex: 1 1 0%;
  min-width: 0;
}

.shelf-row-games .game-shelf-wall {
  padding-bottom: 0;
  margin-bottom: 0;
}

@media (max-width: 600px) {
  .shelf-row-container {
    gap: 6px;
  }
  .shelf-vertical-tab {
    width: 30px;
    min-width: 30px;
    max-width: 30px;
    flex: 0 0 30px;
  }
  .vertical-tab-text {
    font-size: 10px;
    letter-spacing: 0.14em;
  }
}

/* ========================================================
   ADMIN: AUTO SOURCE GAMES & SYSTEM REORDERING UI
   ======================================================== */

.source-panel {
  background: linear-gradient(170deg, #101c18, #091210);
  border: 1px solid rgba(85, 232, 208, 0.35);
  border-radius: 12px;
  padding: 24px 20px;
  margin: 20px 0 30px;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.5);
}

.source-heading h2 {
  margin: 4px 0 8px 0;
  font-size: 22px;
  color: #ffffff;
}

.source-heading p {
  color: #9ba8b8;
  margin: 0 0 16px 0;
  font-size: 13.5px;
  max-width: 820px;
}

.source-input-wrap {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.source-input-wrap input {
  flex: 1 1 360px;
  min-height: 44px;
  background: #060b09;
  border: 1px solid #28443c;
  border-radius: 8px;
  padding: 0 14px;
  color: #fff;
  font-size: 14px;
}

.source-input-wrap input:focus {
  border-color: #55e8d0;
  outline: none;
  box-shadow: 0 0 0 3px rgba(85, 232, 208, 0.2);
}

.source-status {
  margin-top: 12px;
  font-family: var(--font-mono, ui-monospace, monospace);
  font-size: 12px;
  color: #55e8d0;
}

.source-results-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 22px 0 14px 0;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.source-results-header h3 {
  margin: 0;
  color: #fff;
  font-size: 17px;
}

.source-candidates-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 14px;
  max-height: 520px;
  overflow-y: auto;
  padding: 4px;
}

.candidate-card {
  background: #08120e;
  border: 1px solid #203830;
  border-radius: 9px;
  padding: 12px;
  display: flex;
  gap: 12px;
  align-items: center;
  transition: border-color 0.16s ease;
}

.candidate-card:hover {
  border-color: #55e8d0;
}

.candidate-thumb {
  width: 58px;
  height: 82px;
  object-fit: cover;
  border-radius: 5px;
  background: #020403;
  flex-shrink: 0;
}

.candidate-info {
  flex: 1;
  min-width: 0;
}

.candidate-info input {
  width: 100%;
  box-sizing: border-box;
  font-size: 13px;
  font-weight: 700;
  background: #11201b;
  border: 1px solid #2d4c42;
  border-radius: 4px;
  color: #fff;
  padding: 4px 6px;
  margin-bottom: 6px;
}

.candidate-meta-row {
  display: flex;
  gap: 8px;
  align-items: center;
}

.candidate-meta-row select, .candidate-meta-row input[type="number"] {
  background: #11201b;
  border: 1px solid #2d4c42;
  border-radius: 4px;
  color: #a5b3b2;
  font-size: 11px;
  padding: 3px 5px;
}

.candidate-btn-import {
  margin-top: 8px;
  width: 100%;
  background: #00e676;
  color: #04140b;
  border: none;
  border-radius: 5px;
  padding: 5px 8px;
  font-weight: 800;
  font-size: 11px;
  cursor: pointer;
  transition: opacity 0.16s ease;
}

.candidate-btn-import:hover {
  opacity: 0.9;
}

.candidate-btn-import.imported {
  background: #254035;
  color: #79a393;
  cursor: default;
}

/* SYSTEM ORDER MANAGER IN ADMIN */
.system-order-settings {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 16px;
}

.system-order-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 12px;
  max-height: 420px;
  overflow-y: auto;
}

.system-order-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: #0e1714;
  border: 1px solid #223730;
  border-radius: 6px;
}

.system-order-item.is-first {
  border-color: #55e8d0;
  background: rgba(85, 232, 208, 0.08);
}

.system-order-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

.system-order-rank {
  font-family: var(--font-mono, ui-monospace, monospace);
  font-size: 11px;
  font-weight: 800;
  color: #55e8d0;
  min-width: 44px;
}

.system-order-name {
  font-weight: 800;
  color: #fff;
  font-size: 13.5px;
}

.system-order-count {
  font-size: 11px;
  color: #7f948f;
  margin-left: 6px;
}

.system-order-actions {
  display: flex;
  gap: 5px;
}

.system-order-btn {
  background: #172722;
  border: 1px solid #2c453c;
  color: #d1ded9;
  border-radius: 4px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.system-order-btn:hover {
  background: #55e8d0;
  color: #05140f;
  border-color: #55e8d0;
}

/* ==========================================================================
   ADDED FEATURES (privacy, partners, sponsored, banner, game actions, SEO copy)
   Uses the existing BrowserKicks palette and type: pitch green, gold, glass panels,
   Barlow Condensed headings and DM Mono labels.
   ========================================================================== */
h2.vertical-tab-text { margin: 0; line-height: 1.2; }
.detail-hero > img.cover-image, .detail-cover-link img.cover-image { display: block; width: 100%; height: auto; border-radius: 8px; box-shadow: 0 16px 36px rgba(0, 0, 0, 0.6); }
.detail-cover-link { display: block; border-radius: 8px; transition: transform 0.15s ease, box-shadow 0.15s ease; }
.detail-cover-link:hover { transform: translateY(-2px); box-shadow: 0 0 0 2px var(--gold); }
.detail-cover-link:focus-visible, .game-action:focus-visible, .privacy-switch:focus-visible, .privacy-age button:focus-visible, .partner-empty-btn:focus-visible, .bk-advertise:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.bk-hp { position: absolute !important; left: -10000px !important; width: 1px; height: 1px; overflow: hidden; }

/* footer */
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 16px; margin: 0 0 8px; }
.footer-links a, .site-footer .footer-links a { margin: 0; color: var(--gold); }
.footer-disclaimer { max-width: 760px; margin: 8px auto 0; font-size: 10px; line-height: 1.5; color: #5d6b7e; }

/* homepage SEO intro + FAQ (below the catalog) */
.seo-intro { max-width: 1680px; margin: 0 auto; padding: 8px clamp(8px, 1.8vw, 24px) 0; }
.seo-intro-inner { background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border-glass); border-radius: 8px; padding: 18px clamp(14px, 2.4vw, 28px); color: #cbd5e1; }
.seo-intro h1, .seo-intro h2, .detail-about h2, .hub-head h1, .legal-page h1, .legal-body h2, .legal-body h3 { font-family: var(--font-display); text-transform: uppercase; color: var(--white); line-height: 1.05; }
.seo-intro h1 { font-size: clamp(22px, 3vw, 32px); font-weight: 800; margin: 0 0 10px; }
.seo-intro h2 { font-size: 18px; font-weight: 800; margin: 18px 0 8px; }
.seo-intro p { margin: 0 0 12px; font-size: 13px; line-height: 1.65; max-width: 980px; }
.seo-hubs { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 4px; }
.seo-hubs .button-outline { padding: 7px 12px; font-family: var(--font-display); font-size: 13px; text-transform: uppercase; letter-spacing: 0.04em; }
.seo-hubs .button-outline:hover { border-color: var(--pitch-green); color: var(--pitch-green); }
.seo-faq details { border-top: 1px solid var(--border-glass); padding: 9px 0; }
.seo-faq summary { cursor: pointer; font-weight: 700; color: var(--white); font-size: 13px; }
.seo-faq summary::marker { color: var(--gold); }
.seo-faq details p { margin: 8px 0 2px; color: var(--muted); }

/* game page: about + how to play */
.detail-about { background: rgba(255, 255, 255, 0.02); border: 1px solid var(--border-glass); border-radius: 8px; padding: 16px 18px; margin: -12px 0 32px; color: #cbd5e1; font-size: 13px; line-height: 1.65; }
.detail-about h2 { font-size: 20px; font-weight: 800; margin: 4px 0 8px; }
.detail-about h2 + p { margin-top: 0; }
.detail-about ol { margin: 0 0 10px; padding-left: 20px; }
.detail-about li { margin: 4px 0; }
.detail-about li b { color: var(--gold); }
.detail-small { font-size: 11px; color: var(--muted); }

/* game page: Play row + action buttons */
.detail-play-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 14px; }
.game-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.game-action-wrap { position: relative; }
.game-action { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; width: 50px; height: 46px; padding: 0; border-radius: 8px; border: 1px solid var(--border-glass); background: rgba(255, 255, 255, 0.03); color: #a0aec0; cursor: pointer; transition: all 0.15s ease; }
.game-action span { font-family: var(--font-display); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; }
.game-action:hover { color: var(--white); border-color: rgba(255, 255, 255, 0.22); background: rgba(255, 255, 255, 0.06); }
.game-action.is-on, .game-action[aria-expanded="true"] { color: var(--gold); border-color: rgba(255, 215, 0, 0.45); background: rgba(255, 215, 0, 0.08); }
.game-pop { position: absolute; z-index: 40; top: calc(100% + 8px); left: 50%; transform: translateX(-50%); min-width: 190px; background: rgba(14, 18, 25, 0.98); border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 10px; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7); padding: 10px; display: flex; flex-direction: column; gap: 2px; }
.game-pop[hidden] { display: none; }
.game-pop .eyebrow { margin: 2px 6px 6px; }
.game-pop-item { display: block; width: 100%; text-align: left; background: transparent; border: 0; color: var(--white); padding: 8px 10px; border-radius: 6px; font-size: 13px; cursor: pointer; }
.game-pop-item:hover, .game-pop-item:focus-visible { background: rgba(255, 255, 255, 0.06); color: var(--gold); outline: none; }
.rate-stars { display: flex; gap: 2px; padding: 0 4px 4px; }
.rate-stars button { background: transparent; border: 0; font-size: 26px; line-height: 1; color: #3a4556; cursor: pointer; padding: 2px; }
.rate-stars button.is-on { color: var(--gold); text-shadow: 0 0 10px var(--gold-glow); }
.game-rating { margin: 10px 0 0; font-family: var(--font-mono); font-size: 12px; color: var(--gold); }
.game-rating span { color: var(--muted); }
@media (max-width: 768px) { .game-pop { left: 0; transform: none; } .game-action-wrap:last-child .game-pop { left: auto; right: 0; } }

/* hub + legal pages */
.hub-page { max-width: 1680px; }
.hub-head h1 { font-size: clamp(28px, 4.4vw, 46px); font-weight: 800; margin: 0 0 12px; }
.hub-head .detail-lede { max-width: 880px; }
.hub-grid { margin: 8px 0 28px; }
.legal-page h1 { font-size: clamp(30px, 4.6vw, 48px); font-weight: 800; margin: 0 0 18px; }
.legal-body { color: #cbd5e1; font-size: 14px; line-height: 1.7; max-width: 780px; }
.legal-body h2 { font-size: 22px; margin: 26px 0 8px; }
.legal-body h3 { font-size: 18px; margin: 20px 0 6px; }
.legal-body a, .text-link { color: var(--gold); }
.legal-body li { margin: 4px 0; }

/* privacy panel (uses the search modal shell) */
.privacy-panel { width: min(460px, 100%); }
.privacy-title { flex: 1; margin: 0; font-family: var(--font-display); font-size: 20px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.03em; }
.privacy-body { display: flex; flex-direction: column; gap: 8px; }
.privacy-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 14px; background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border-glass); border-radius: 8px; }
.privacy-row-copy { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.privacy-row strong { font-size: 13px; color: var(--white); }
.privacy-row small { font-size: 11px; color: var(--muted); line-height: 1.45; }
.privacy-link { color: var(--white); transition: border-color 0.15s ease; }
.privacy-link span { color: var(--gold); font-weight: 800; }
.privacy-link:hover { border-color: rgba(255, 215, 0, 0.45); }
.privacy-switch { flex: 0 0 auto; position: relative; width: 46px; height: 26px; border-radius: 26px; border: 1px solid var(--border-card); background: rgba(255, 255, 255, 0.08); cursor: pointer; transition: background 0.15s ease; padding: 0; }
.privacy-switch span { position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #a0aec0; transition: transform 0.15s ease, background 0.15s ease; }
.privacy-switch[aria-checked="true"] { background: rgba(0, 230, 118, 0.25); border-color: rgba(0, 230, 118, 0.6); }
.privacy-switch[aria-checked="true"] span { transform: translateX(20px); background: var(--pitch-green); box-shadow: 0 0 10px var(--pitch-glow); }
.privacy-age { flex: 0 0 auto; display: flex; border: 1px solid var(--border-card); border-radius: 8px; overflow: hidden; }
.privacy-age button { background: transparent; border: 0; color: #a0aec0; padding: 7px 10px; font-family: var(--font-display); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em; cursor: pointer; white-space: nowrap; }
.privacy-age button[aria-checked="true"] { background: var(--gold); color: #0a0e14; }

/* dialogs (partners contact, ad request, report) */
dialog.bk-dialog { background: rgba(14, 18, 25, 0.98); border: 1px solid rgba(255, 255, 255, 0.15); border-radius: 12px; color: var(--white); max-width: 560px; width: 92vw; padding: 22px; }
.bk-dialog h2 { margin: 0; font-family: var(--font-display); font-size: 24px; font-weight: 800; text-transform: uppercase; line-height: 1.05; }
.bk-dialog .dialog-close { background: transparent; border: 0; color: var(--muted); font-size: 24px; cursor: pointer; }
.bk-dialog-copy { color: #cbd5e1; font-size: 13px; line-height: 1.6; margin: 0 0 6px; }
.bk-contact-actions { flex-wrap: wrap; }
.bk-whatsapp { background: var(--pitch-green); box-shadow: 0 8px 20px var(--pitch-glow); }
.bk-whatsapp:hover { background: #5dffa8; box-shadow: 0 12px 28px var(--pitch-glow); }
.bk-dialog .form-grid small { color: #5d6b7e; }
@media (max-width: 560px) { .bk-dialog .form-grid { grid-template-columns: 1fr; } }

/* homepage banner slot */
.bk-banner { position: relative; display: flex; justify-content: center; margin: 0 0 14px; }
.bk-banner[hidden] { display: none; }
.bk-banner a { display: block; line-height: 0; }
.bk-banner img { width: min(var(--bw), 100%); height: auto; aspect-ratio: var(--bw) / var(--bh); border-radius: 6px; border: 1px solid var(--border-glass); }
.bk-banner-label { position: absolute; top: 4px; right: 6px; font-family: var(--font-mono); font-size: 9px; color: var(--muted); background: rgba(5, 7, 11, 0.7); padding: 1px 5px; border-radius: 4px; }
.bk-advertise { width: min(var(--bw), 100%); min-height: min(var(--bh), 120px); display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 4px 14px; padding: 10px 16px; background: rgba(255, 255, 255, 0.03); border: 1px dashed rgba(255, 215, 0, 0.35); border-radius: 8px; color: #cbd5e1; cursor: pointer; text-align: center; transition: all 0.15s ease; }
.bk-advertise .eyebrow { margin: 0; }
.bk-advertise strong { font-size: 13px; font-weight: 600; }
.bk-advertise b { font-family: var(--font-display); font-size: 14px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--gold); }
.bk-advertise:hover { border-color: var(--gold); background: rgba(255, 215, 0, 0.05); }
@media (max-width: 1024px) { .bk-banner img { width: min(var(--tw), 100%); aspect-ratio: var(--tw) / var(--th); } .bk-advertise { width: min(var(--tw), 100%); min-height: min(var(--th), 120px); } }
@media (max-width: 600px) { .bk-banner img { width: min(var(--mw), 100%); aspect-ratio: var(--mw) / var(--mh); } .bk-advertise { width: min(var(--mw), 100%); min-height: min(var(--mh), 100px); } .bk-advertise strong { font-size: 12px; } }
html.bk-under18 .third-party-ad { display: none !important; }

/* partners row (same shelf + 3D case look as the catalog) */
.shelf-vertical-tab.partners-tab { background: linear-gradient(180deg, #221d08 0%, #0e0c04 100%); border-color: rgba(255, 215, 0, 0.4); box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 215, 0, 0.22); cursor: default; }
.shelf-vertical-tab.partners-tab:hover { transform: none; border-color: var(--gold); }
.shelf-vertical-tab.partners-tab .vertical-tab-text { color: var(--gold); }
.game-card.partner-empty:hover { transform: none; }
.partner-empty-btn { width: 100%; aspect-ratio: 1 / 1.42; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 10px; border: 1px dashed rgba(255, 215, 0, 0.35); border-radius: 4px; background: rgba(255, 255, 255, 0.02); color: #a0aec0; cursor: pointer; transition: all 0.15s ease; }
.partner-empty-btn:hover { border-color: var(--gold); color: var(--gold); background: rgba(255, 215, 0, 0.05); }
.partner-plus { width: 38px; height: 38px; border-radius: 50%; border: 1.5px solid currentColor; display: flex; align-items: center; justify-content: center; font-size: 22px; font-weight: 300; line-height: 1; }
.partner-empty-text { font-family: var(--font-display); font-size: 13px; font-weight: 800; letter-spacing: 0.05em; text-align: center; line-height: 1.15; }
.sponsor-badge { position: absolute; top: 5px; left: 5px; z-index: 3; font-family: var(--font-mono); font-size: 9px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: #0a0e14; background: var(--gold); padding: 2px 6px; border-radius: 4px; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5); pointer-events: none; }
.case-partner .case-spine { background: linear-gradient(180deg, #2a2408, #120f03); }
.case-partner .spine-logo { color: var(--gold); }
@media (max-width: 600px) { .partner-empty-text { font-size: 11px; } .partner-plus { width: 30px; height: 30px; font-size: 18px; } }

/* admin additions */
.extras-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin: 14px 0; }
.extras-stats div { background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border-glass); border-radius: 8px; padding: 10px 12px; }
.extras-stats small { display: block; font-family: var(--font-mono); font-size: 10px; color: var(--muted); }
.extras-stats b { font-family: var(--font-display); font-size: 24px; color: var(--gold); }
.extras-panel fieldset { border: 1px solid var(--border-glass); border-radius: 8px; padding: 12px; margin: 0; }
.extras-panel legend { font-family: var(--font-display); font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em; padding: 0 6px; color: var(--gold); }
.extras-panel fieldset p { font-size: 12px; color: var(--muted); margin: 0 0 10px; }
.partner-slots { display: grid; gap: 10px; margin-top: 10px; }
.partner-slot-edit { border-top: 1px solid var(--border-glass); padding-top: 10px; }
.extras-badge { position: static; margin-left: 4px; }
.extras-badge[hidden] { display: none; }
tr.is-unread td:first-child { box-shadow: inset 3px 0 0 var(--gold); }
@media (max-width: 768px) { .extras-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.extras-panel .form-grid label.check-label { flex-direction: row; display: flex; align-items: center; gap: 8px; text-transform: none; }
.extras-panel .form-grid label.check-label input { width: auto; margin: 0; flex: 0 0 auto; accent-color: var(--gold); }

/* speed: skip layout/paint of off-screen shelves until they scroll near the viewport (no visual change) */
.system-shelf-row, .seo-intro, .partners-section, .related.section { content-visibility: auto; contain-intrinsic-size: auto 520px; }
