/* ==========================================================================
   Sky Hopper — Shared Stylesheet
   A cosmic arcade flying game.
   ========================================================================== */

/* ---------- Design Tokens ---------- */
:root {
  /* Colors */
  --color-bg-dark: #0a0e27;
  --color-cosmic-purple: #1a1a4e;
  --color-accent-cyan: #00d4ff;
  --color-accent-magenta: #ff2d95;
  --color-warm-gold: #ffd700;
  --color-text: #ffffff;
  --color-text-muted: rgba(255, 255, 255, 0.7);

  /* Glassmorphism */
  --glass-bg: rgba(26, 26, 78, 0.55);
  --glass-border: rgba(255, 255, 255, 0.12);
  --shadow-glass: 0 8px 32px rgba(0, 0, 0, 0.37);

  /* Typography */
  --font-main: "Segoe UI", system-ui, -apple-system, sans-serif;

  /* Spacing & Borders */
  --radius-lg: 16px;
  --radius-md: 8px;
  --radius-sm: 4px;
  --transition-fast: 0.2s ease;
  --transition-normal: 0.35s ease;
}

/* ---------- Reset & Base ---------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  font-family: var(--font-main);
  background: linear-gradient(160deg, var(--color-bg-dark) 0%, #0d1b3e 40%, var(--color-cosmic-purple) 100%);
  background-attachment: fixed;
  color: var(--color-text);
  min-height: 100vh;
  line-height: 1.65;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition-fast);
}

img { max-width: 100%; display: block; }

/* ---------- Typography Utilities ---------- */
.text-gradient {
  background: linear-gradient(135deg, var(--color-accent-cyan), var(--color-accent-magenta));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: inline-block;
}

/* ---------- Glassmorphism Utility ---------- */
.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-glass);
}

/* ==========================================================================
   Navigation — works for both index.html (direct <a>) and auxiliary pages (<ul><li><a>)
   ========================================================================== */
nav.site-nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 60px;
  z-index: 1000;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 2rem;
  background: rgba(10, 14, 39, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--glass-border);
  transition: opacity var(--transition-normal), background var(--transition-normal),
              transform var(--transition-normal);
}

/* Auto-hide nav when playing */
nav.site-nav.nav-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(-100%);
}

.nav-brand {
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: 1px;
  white-space: nowrap;
}

/* --- Nav links (shared for both <div class="nav-links"> and <ul class="nav-links">) --- */
.nav-links {
  display: flex;
  gap: 1.5rem;
  list-style: none;
  align-items: center;
}

/* Direct <a> children (index.html) */
.nav-links > a,
/* <li><a> children (auxiliary pages) */
.nav-links > li > a {
  position: relative;
  font-size: 0.95rem;
  font-weight: 500;
  padding: 0.25rem 0;
  transition: color var(--transition-fast), text-shadow var(--transition-fast);
}

.nav-links > a:hover,
.nav-links > a.active,
.nav-links > li > a:hover,
.nav-links > li > a.active {
  color: var(--color-accent-cyan);
  text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}

.nav-links > a.active::after,
.nav-links > li > a.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--color-accent-cyan);
  box-shadow: 0 0 8px var(--color-accent-cyan);
  border-radius: 2px;
}

/* --- Mobile hamburger toggle (CSS checkbox hack) --- */
/* Checkbox is visually hidden */
.nav-toggle-input,
.mobile-menu-toggle {
  display: none;
}

/* Hamburger label (three-line icon) — index.html uses nav-toggle-label, aux pages use mobile-menu-icon */
.nav-toggle-label,
.mobile-menu-icon {
  display: none;            /* Hidden on desktop */
  cursor: pointer;
  color: var(--color-text);
  z-index: 1001;
}

/* index.html hamburger: three <span> bars */
.nav-toggle-label {
  flex-direction: column;
  gap: 5px;
  width: 28px;
  height: 20px;
  justify-content: center;
}

.nav-toggle-label span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: transform var(--transition-fast), opacity var(--transition-fast);
}

/* aux pages hamburger: ☰ character */
.mobile-menu-icon {
  font-size: 1.6rem;
  line-height: 1;
}

/* ==========================================================================
   Content Pages (how-to-play, about, privacy)
   ========================================================================== */
.page-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 100px 1.5rem 4rem;
}

.page-header {
  font-size: clamp(2rem, 5vw, 3rem);
  margin-bottom: 2rem;
  text-align: center;
}

.content-card {
  border-radius: var(--radius-lg);
  padding: 2rem;
  margin-bottom: 1.5rem;
}

.content-card h2 {
  margin-top: 0;
  margin-bottom: 1.2rem;
  color: var(--color-accent-cyan);
  border-bottom: 1px solid var(--glass-border);
  padding-bottom: 0.5rem;
}

.content-card h3 {
  color: var(--color-accent-magenta);
  margin-top: 1.2rem;
}

.content-card p,
.content-card li {
  color: var(--color-text-muted);
  font-size: 1.05rem;
}

.content-card ul,
.content-card ol {
  padding-left: 1.5rem;
}

.content-card li {
  margin-bottom: 0.5rem;
}

.content-card code {
  background: rgba(255, 255, 255, 0.08);
  padding: 0.15em 0.45em;
  border-radius: var(--radius-sm);
  font-size: 0.9em;
}

/* Feature grid (about page) */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
  margin-top: 1.25rem;
}

.feature-item {
  background: rgba(255, 255, 255, 0.04);
  padding: 1.5rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.06);
  text-align: center;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast),
              border-color var(--transition-fast);
}

.feature-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
  border-color: rgba(0, 212, 255, 0.3);
}

.feature-item h3 {
  margin: 0 0 0.75rem;
  color: var(--color-accent-cyan);
  font-size: 1.1rem;
}

.feature-item p {
  font-size: 0.95rem;
}

/* Keyboard key indicator */
.control-key {
  display: inline-block;
  background: linear-gradient(to bottom, #3a3a5c, #222240);
  border: 1px solid #555;
  border-bottom-width: 3px;
  border-radius: var(--radius-sm);
  padding: 0.25rem 0.65rem;
  font-family: "Segoe UI Mono", "Consolas", monospace;
  font-weight: 700;
  font-size: 0.9em;
  color: #fff;
  margin: 0 0.15rem;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
  white-space: nowrap;
}

/* Footer */
footer,
.site-footer {
  text-align: center;
  padding: 2rem 1rem;
  color: var(--color-text-muted);
  font-size: 0.88rem;
  border-top: 1px solid var(--glass-border);
  margin-top: 2rem;
}

footer a {
  color: var(--color-accent-cyan);
  text-decoration: underline;
}

/* ==========================================================================
   Game Page — Canvas & UI Overlays
   ========================================================================== */
#game-container {
  position: relative;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  background-color: #050814;
}

#gameCanvas {
  display: block;
  width: 100%;
  height: 100%;
}

/* --- Overlay shared base --- */
.game-ui {
  position: absolute;
  pointer-events: auto;   /* Allow interaction */
  z-index: 5;
}

/* --- Score HUD --- */
#score-display {
  top: 72px;
  left: 28px;
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  color: var(--color-text);
  text-shadow: 0 0 12px var(--color-accent-cyan), 0 2px 6px rgba(0, 0, 0, 0.5);
  transition: transform 0.15s ease;
  user-select: none;
}

#score-display.score-pop {
  animation: score-pop 0.3s ease;
}

#best-score-display {
  top: 128px;
  left: 28px;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--color-warm-gold);
  text-shadow: 0 0 8px rgba(255, 215, 0, 0.5);
  user-select: none;
}

/* --- Sound toggle --- */
#sound-toggle {
  top: 72px;
  right: 28px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: 1px solid var(--glass-border);
  background: rgba(10, 14, 39, 0.5);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: var(--color-text);
  transition: all var(--transition-fast);
}

#sound-toggle:hover {
  box-shadow: 0 0 18px rgba(255, 45, 149, 0.5);
  border-color: var(--color-accent-magenta);
  background: rgba(255, 45, 149, 0.15);
}

/* --- Overlay screens (start, game-over) --- */
.overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  background: rgba(10, 14, 39, 0.45);
  animation: fade-in 0.4s ease;
}

.overlay-card {
  text-align: center;
  padding: 2.5rem 3rem;
  border-radius: var(--radius-lg);
  max-width: 92%;
  width: 420px;
  animation: slide-up 0.5s ease;
}

/* Game title */
.game-title {
  font-size: clamp(2.4rem, 7vw, 3.6rem);
  font-weight: 800;
  background: linear-gradient(135deg, var(--color-accent-cyan), var(--color-accent-magenta));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin: 0 0 0.4rem;
  animation: pulse-glow 3s ease-in-out infinite;
}

.game-subtitle {
  font-size: 1.1rem;
  color: var(--color-text-muted);
  margin: 0 0 1.8rem;
  line-height: 1.5;
}

.game-over-title {
  font-size: clamp(2rem, 6vw, 3rem);
  font-weight: 800;
  color: var(--color-accent-magenta);
  text-shadow: 0 0 20px rgba(255, 45, 149, 0.4);
  margin: 0 0 1.2rem;
}

/* Control hints on start screen */
.control-hints {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.control-divider {
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

.control-text {
  font-size: 1rem;
  color: var(--color-text-muted);
  margin-left: 0.25rem;
}

/* Score on game-over screen */
.score-display-final {
  margin-bottom: 1rem;
}

.score-label {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--color-text-muted);
  margin-bottom: 0.2rem;
}

.score-value {
  font-size: 3rem;
  font-weight: 800;
  color: var(--color-accent-cyan);
  text-shadow: 0 0 15px rgba(0, 212, 255, 0.5);
  line-height: 1.1;
}

.score-value.best {
  color: var(--color-warm-gold);
  text-shadow: 0 0 15px rgba(255, 215, 0, 0.5);
  font-size: 2rem;
}

/* New best badge */
.new-best {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--color-warm-gold);
  text-shadow: 0 0 12px rgba(255, 215, 0, 0.6);
  margin-bottom: 1rem;
  animation: float 1.5s ease-in-out infinite;
}

/* --- Buttons --- */
.btn-primary,
.btn {
  display: inline-block;
  background: linear-gradient(135deg, var(--color-accent-cyan), var(--color-accent-magenta));
  color: #fff;
  border: none;
  padding: 0.9rem 2.5rem;
  font-size: 1.15rem;
  font-weight: 700;
  font-family: var(--font-main);
  border-radius: 30px;
  cursor: pointer;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.3), 0 0 30px rgba(0, 212, 255, 0.15);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  min-height: 48px;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.btn-primary:hover,
.btn:hover {
  transform: translateY(-2px) scale(1.04);
  box-shadow: 0 8px 28px rgba(255, 45, 149, 0.45), 0 0 40px rgba(0, 212, 255, 0.2);
}

.btn-primary:active,
.btn:active {
  transform: translateY(1px) scale(0.97);
}

/* ==========================================================================
   Animations
   ========================================================================== */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}

@keyframes pulse-glow {
  0%, 100% { text-shadow: 0 0 10px rgba(0, 212, 255, 0.3); }
  50%      { text-shadow: 0 0 25px rgba(0, 212, 255, 0.5), 0 0 50px rgba(255, 45, 149, 0.2); }
}

@keyframes fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes slide-up {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes score-pop {
  0%   { transform: scale(1); }
  40%  { transform: scale(1.45); }
  100% { transform: scale(1); }
}

@keyframes shimmer {
  0%   { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* ==========================================================================
   Utilities
   ========================================================================== */
.hidden {
  display: none !important;
}

.fade-in {
  animation: fade-in 0.5s ease forwards;
}

.slide-up {
  animation: slide-up 0.5s ease both;
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 768px) {
  /* Show hamburger icons */
  .nav-toggle-label {
    display: flex;
  }
  .mobile-menu-icon {
    display: block;
  }

  /* Mobile dropdown */
  .nav-links {
    position: absolute;
    top: 60px;
    left: 0;
    width: 100%;
    background: rgba(10, 14, 39, 0.96);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    flex-direction: column;
    padding: 0.75rem 0;
    gap: 0;
    border-bottom: 1px solid var(--glass-border);
    transform: translateY(-120%);
    opacity: 0;
    transition: transform var(--transition-normal), opacity var(--transition-normal);
    z-index: 999;
  }

  .nav-links > a,
  .nav-links > li {
    width: 100%;
    text-align: center;
  }

  .nav-links > a,
  .nav-links > li > a {
    display: block;
    padding: 0.85rem 1rem;
    font-size: 1rem;
  }

  /* Checkbox hack: show dropdown when toggle is checked */
  .nav-toggle-input:checked ~ .nav-links,
  .mobile-menu-toggle:checked ~ .nav-links {
    transform: translateY(0);
    opacity: 1;
  }

  /* Animate hamburger to X on open */
  .nav-toggle-input:checked ~ .nav-toggle-label span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }
  .nav-toggle-input:checked ~ .nav-toggle-label span:nth-child(2) {
    opacity: 0;
  }
  .nav-toggle-input:checked ~ .nav-toggle-label span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
  }

  .page-header {
    font-size: 2.2rem;
  }

  .content-card {
    padding: 1.5rem;
  }

  .overlay-card {
    padding: 2rem 1.5rem;
  }
}

@media (max-width: 480px) {
  nav.site-nav {
    padding: 0 1rem;
  }

  .page-container {
    padding-top: 80px;
    padding-left: 1rem;
    padding-right: 1rem;
  }

  #score-display {
    left: 16px;
    top: 68px;
    font-size: 2rem;
  }

  #best-score-display {
    left: 16px;
    top: 108px;
    font-size: 0.95rem;
  }

  #sound-toggle {
    top: 68px;
    right: 16px;
    width: 42px;
    height: 42px;
  }

  .overlay-card h1,
  .game-title {
    font-size: 2.2rem;
  }

  .btn-primary,
  .btn {
    padding: 0.8rem 2rem;
    font-size: 1rem;
    min-height: 44px;
  }

  .score-value {
    font-size: 2.5rem;
  }

  .score-value.best {
    font-size: 1.6rem;
  }
}

/* Touch: prevent highlight & callout on mobile */
canvas,
button {
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
}

/* ==========================================================================
   Gaming Hub — Homepage & Games Pages
   ========================================================================== */

/* --- Hero Section --- */
.hero {
  position: relative;
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 120px 2rem 4rem;
  overflow: hidden;
}

.hero-bg-decor {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.25;
}

.hero-orb-1 {
  width: 400px;
  height: 400px;
  background: var(--color-accent-cyan);
  top: -100px;
  right: -100px;
  animation: float 8s ease-in-out infinite;
}

.hero-orb-2 {
  width: 300px;
  height: 300px;
  background: var(--color-accent-magenta);
  bottom: -50px;
  left: -80px;
  animation: float 10s ease-in-out infinite reverse;
}

.hero-orb-3 {
  width: 200px;
  height: 200px;
  background: var(--color-warm-gold);
  top: 40%;
  left: 50%;
  opacity: 0.12;
  animation: float 12s ease-in-out infinite;
}

.hero-content {
  position: relative;
  text-align: center;
  max-width: 680px;
  z-index: 2;
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 1.2rem;
  letter-spacing: -0.5px;
}

.hero-subtitle {
  font-size: clamp(1.05rem, 2.5vw, 1.25rem);
  color: var(--color-text-muted);
  line-height: 1.7;
  margin-bottom: 2.5rem;
  max-width: 540px;
  margin-left: auto;
  margin-right: auto;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* Secondary button */
.btn-secondary {
  display: inline-block;
  background: transparent;
  color: var(--color-text);
  border: 2px solid var(--glass-border);
  padding: 0.85rem 2.3rem;
  font-size: 1.1rem;
  font-weight: 600;
  font-family: var(--font-main);
  border-radius: 30px;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  min-height: 48px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.btn-secondary:hover {
  border-color: var(--color-accent-cyan);
  color: var(--color-accent-cyan);
  box-shadow: 0 0 20px rgba(0, 212, 255, 0.2);
  transform: translateY(-2px);
}

/* Small button variant */
.btn-sm {
  padding: 0.6rem 1.8rem;
  font-size: 0.95rem;
  min-height: 40px;
}

/* --- Section Layout --- */
.section {
  padding: 3rem 2rem 4rem;
  max-width: 1100px;
  margin: 0 auto;
}

.section-title {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 700;
  text-align: center;
  margin-bottom: 2.5rem;
}

.section-subtitle {
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--color-accent-cyan);
  margin-bottom: 1.5rem;
}

.section-desc {
  color: var(--color-text-muted);
  margin-bottom: 1.5rem;
}

/* Page intro paragraph */
.page-intro {
  text-align: center;
  color: var(--color-text-muted);
  font-size: 1.1rem;
  max-width: 600px;
  margin: -0.5rem auto 2.5rem;
}

/* --- Featured Game Card --- */
.featured-card {
  display: flex;
  gap: 2.5rem;
  border-radius: var(--radius-lg);
  overflow: hidden;
  max-width: 900px;
  margin: 0 auto;
}

.featured-artwork {
  position: relative;
  flex: 0 0 320px;
  min-height: 260px;
  background: linear-gradient(135deg, #0d1b3e, #1a1a4e, #2d1b4e);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.featured-artwork-inner {
  position: relative;
  width: 100%;
  height: 100%;
}

/* CSS artwork: floating stars, gate, sprite */
.artwork-star {
  position: absolute;
  width: 4px;
  height: 4px;
  background: #fff;
  border-radius: 50%;
  animation: float 3s ease-in-out infinite;
}

.artwork-star-1 { top: 20%; left: 15%; animation-delay: 0s; }
.artwork-star-2 { top: 50%; left: 75%; animation-delay: 1s; }
.artwork-star-3 { top: 70%; left: 40%; animation-delay: 2s; width: 3px; height: 3px; }

.artwork-gate {
  position: absolute;
  right: 30%;
  top: 20%;
  width: 16px;
  height: 60%;
  background: linear-gradient(to bottom, #6b3fa0, #2a1050);
  border-radius: 3px;
  box-shadow: 0 0 12px rgba(107, 63, 160, 0.5);
}

.artwork-gate::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  height: 30%;
  margin-top: 50px;
  background: linear-gradient(to bottom, #6b3fa0, #2a1050);
  border-radius: 3px;
  box-shadow: 0 0 12px rgba(107, 63, 160, 0.5);
}

.artwork-sprite {
  position: absolute;
  left: 25%;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: radial-gradient(circle, #00d4ff, #0066cc);
  box-shadow: 0 0 20px rgba(0, 212, 255, 0.6), 0 0 40px rgba(0, 212, 255, 0.2);
  animation: float 2s ease-in-out infinite;
}

.featured-badge,
.game-card-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: linear-gradient(135deg, var(--color-accent-cyan), var(--color-accent-magenta));
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
}

.badge-soon {
  background: linear-gradient(135deg, #555, #888);
}

.featured-info {
  flex: 1;
  padding: 2rem 2rem 2rem 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.featured-game-title {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 0.8rem;
}

.featured-game-desc {
  color: var(--color-text-muted);
  font-size: 1.05rem;
  line-height: 1.6;
  margin-bottom: 1.2rem;
}

.featured-meta {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}

.meta-tag {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  background: rgba(255, 255, 255, 0.06);
  padding: 0.3rem 0.7rem;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

/* --- Features Row --- */
.features-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.5rem;
  max-width: 1000px;
  margin: 0 auto;
}

.feature-card {
  border-radius: var(--radius-lg);
  padding: 2rem 1.5rem;
  text-align: center;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

.feature-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  line-height: 1;
}

.feature-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
  color: var(--color-accent-cyan);
}

.feature-card p {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  line-height: 1.5;
}

/* --- Games Grid --- */
.games-section {
  margin-bottom: 3rem;
}

.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.game-card {
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.game-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

.game-card-artwork {
  position: relative;
  height: 180px;
  background: linear-gradient(135deg, #0d1b3e, #1a1a4e);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.game-card-art-inner {
  position: relative;
  width: 100%;
  height: 100%;
}

/* Game card CSS art elements */
.gc-star {
  position: absolute;
  width: 3px;
  height: 3px;
  background: #fff;
  border-radius: 50%;
  animation: float 4s ease-in-out infinite;
}

.gc-star-1 { top: 25%; left: 20%; }
.gc-star-2 { top: 60%; right: 25%; animation-delay: 1.5s; }

.gc-sprite {
  position: absolute;
  left: 30%;
  top: 50%;
  transform: translateY(-50%);
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: radial-gradient(circle, #00d4ff, #0066cc);
  box-shadow: 0 0 14px rgba(0, 212, 255, 0.5);
  animation: float 2.5s ease-in-out infinite;
}

.gc-gate {
  position: absolute;
  right: 28%;
  top: 15%;
  width: 12px;
  height: 40%;
  background: linear-gradient(to bottom, #6b3fa0, #2a1050);
  border-radius: 2px;
  box-shadow: 0 0 8px rgba(107, 63, 160, 0.4);
}

.gc-gate::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  height: 50%;
  margin-top: 40px;
  background: linear-gradient(to bottom, #6b3fa0, #2a1050);
  border-radius: 2px;
}

.game-card-body {
  padding: 1.5rem;
}

.game-card-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.game-card-desc {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  line-height: 1.5;
  margin-bottom: 1rem;
}

.game-card-meta {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
  margin-bottom: 1.2rem;
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

/* --- Coming Soon Cards --- */
.coming-soon-card {
  opacity: 0.65;
  pointer-events: none;
}

.coming-soon-card:hover {
  transform: none;
  box-shadow: none;
}

.coming-soon-art {
  background: linear-gradient(135deg, #0d1525, #151535) !important;
  display: flex;
  align-items: center;
  justify-content: center;
}

.coming-soon-icon {
  font-size: 3rem;
  opacity: 0.4;
}

.coming-soon-label {
  display: inline-block;
  color: var(--color-text-muted);
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 0.35rem 1rem;
  border: 1px solid var(--glass-border);
  border-radius: 20px;
}

/* --- Hub Footer --- */
.footer-content {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
}

.footer-brand {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 1rem;
  background: linear-gradient(135deg, var(--color-accent-cyan), var(--color-accent-magenta));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: inline-block;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-bottom: 1.2rem;
}

.footer-links a {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--color-accent-cyan);
}

.footer-copy {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.4);
}

/* --- Wide page container for hub pages --- */
.page-container-wide {
  max-width: 1100px;
  margin: 0 auto;
  padding: 100px 1.5rem 4rem;
}

/* ==========================================================================
   Hub Responsive Additions
   ========================================================================== */
@media (max-width: 768px) {
  .hero {
    min-height: 70vh;
    padding: 100px 1.5rem 3rem;
  }

  .hero-title {
    font-size: 2.2rem;
  }

  .featured-card {
    flex-direction: column;
  }

  .featured-artwork {
    flex: none;
    height: 200px;
  }

  .featured-info {
    padding: 1.5rem;
  }

  .hero-orb-1 {
    width: 250px;
    height: 250px;
  }

  .hero-orb-2 {
    width: 180px;
    height: 180px;
  }

  .games-grid {
    grid-template-columns: 1fr;
  }

  .features-row {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 480px) {
  .hero {
    padding: 90px 1rem 2rem;
  }

  .hero-actions {
    flex-direction: column;
    align-items: center;
  }

  .btn-secondary {
    padding: 0.75rem 2rem;
    font-size: 0.95rem;
  }

  .features-row {
    grid-template-columns: 1fr;
  }

  .featured-game-title {
    font-size: 1.6rem;
  }

  .footer-links {
    flex-direction: column;
    gap: 0.75rem;
  }
}
