:root {
  --sf: 'Space Grotesk', sans-serif;
  --bf: 'Inter', sans-serif;
  --bg: #0a1628;
  --purple: #8b5cf6;
  --blue: #00adff;
  --mint: #00d9c0;
  --accent: #a78bfa;          /* WCAG-compliant inline accent (§1) */
  --white: #ffffff;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --glass-bg: rgba(255,255,255,0.05);
  --glass-bg-hover: rgba(255,255,255,0.07);
  --glass-border: rgba(255,255,255,0.1);
  --glass-border-hover: rgba(139,92,246,0.2);
  --shadow: 0 8px 32px rgba(0,0,0,0.3);
  --shadow-hover: 0 8px 32px rgba(0,0,0,0.35), 0 0 20px rgba(139,92,246,0.08);
  --transition: all 0.5s cubic-bezier(0.4,0,0.2,1);

  /* HubSpot form dark theme — retained for future use if forms are added */
}

/* --- 0.4 Body defaults --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: var(--bf);
  font-size: 1rem;
  line-height: 1.5;
  color: var(--gray-300);
  background: linear-gradient(135deg, #0a1628 0%, #0d1a2d 50%, #0a1628 100%);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
.hero-game{
    min-height:100vh;display:flex;align-items:center;padding-top:5rem;padding-bottom:6rem;
}
.cta-sec{
    padding-top:5rem;padding-bottom:2rem;
}
/* --- Tailwind utility equivalents (§0.1–0.3) --- */
.text-5xl { font-size: 3rem; line-height: 1; }
.text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
.text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
.text-2xl { font-size: 1.5rem; line-height: 2rem; }
.text-xl  { font-size: 1.25rem; line-height: 1.75rem; }
.text-lg  { font-size: 1.125rem; line-height: 1.75rem; }
.text-base { font-size: 1rem; line-height: 1.5rem; }
.text-sm  { font-size: 0.875rem; line-height: 1.25rem; }
.text-xs  { font-size: 0.75rem; line-height: 1rem; }
.font-bold { font-weight: 700; }
.font-semibold { font-weight: 600; }
.font-medium { font-weight: 500; }
.text-white { color: var(--white); }
.text-gray-200 { color: var(--gray-200); }
.text-gray-300 { color: var(--gray-300); }
.text-gray-400 { color: var(--gray-400); }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-12 { margin-bottom: 3rem; }
.mt-auto { margin-top: auto; }
.py-20 { padding-top: 5rem; padding-bottom: 5rem; }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
.pt-20 { padding-top: 5rem; }
.p-4 { padding: 1rem; }
.p-8 { padding: 2rem; }
.max-w-7xl { max-width: 80rem; }
.max-w-4xl { max-width: 56rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-xl { max-width: 36rem; }
.mx-auto { margin-left: auto; margin-right: auto; }
.text-center { text-align: center; }
.relative { position: relative; }
.z-10 { z-index: 10; }
.w-full { width: 100%; }
.inline-flex { display: inline-flex; }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.flex-grow { flex-grow: 1; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.gap-2 { gap: 0.5rem; }
.gap-4 { gap: 1rem; }
.leading-relaxed { line-height: 1.625; }
.uppercase { text-transform: uppercase; }
.tracking-wider { letter-spacing: 0.05em; }
.rounded-xl { border-radius: 0.75rem; }
.rounded-2xl { border-radius: 1rem; }
.rounded-lg { border-radius: 0.5rem; }
.overflow-hidden { overflow: hidden; }
.min-h-screen { min-height: 100vh; }

/* --- §2 Gradient text --- */
.grad-text {
  color: var(--purple); /* solid fallback (§9) */
  background: linear-gradient(90deg, #8b5cf6 0%, #00adff 50%, #00d9c0 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- §9 Accessibility --- */
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; top: -100px; left: 1rem; z-index: 9999;
  padding: 0.5rem 1rem; border-radius: 0.5rem;
  background: var(--purple); color: var(--white);
  font-family: var(--bf); font-size: 0.875rem; font-weight: 500;
  text-decoration: none; transition: top 0.2s;
}
.skip-link:focus { top: 5rem; }
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--purple);
  outline-offset: 2px;
  border-radius: 4px;
}

/* --- Ambient background glows --- */
.ambient-glow-1 {
  position: fixed; inset: 0; pointer-events: none; z-index: 0;
  background: radial-gradient(ellipse 80% 50% at 70% 20%, rgba(139,92,246,0.06) 0%, transparent 50%);
}
.ambient-glow-2 {
  position: fixed; inset: 0; pointer-events: none; z-index: 0;
  background: radial-gradient(ellipse 60% 40% at 30% 70%, rgba(0,173,255,0.04) 0%, transparent 50%);
}

/* --- Neural canvas --- */
#neuralCanvas {
  position: fixed; inset: 0; pointer-events: none; z-index: 0;
}

/* --- §5.1 Primary button --- */
.btn-primary {
  position: relative; overflow: hidden;
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.75rem 1.5rem; border-radius: 8px;
  font-family: var(--bf); font-size: 0.875rem; font-weight: 600;
  color: var(--white); text-decoration: none;
  background: rgba(139,92,246,0.8);
  border: 1px solid rgba(139,92,246,0.5);
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
  min-height: 44px;
  transition: all 0.3s; cursor: pointer;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(139,92,246,0.3);
}
.btn-primary .btn-fill {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, #8b5cf6, #00adff);
  transform: translateX(-100%);
  transition: transform 0.5s;
  border-radius: inherit;
}
.btn-primary:hover .btn-fill { transform: translateX(0); }
.btn-primary .btn-text,
.btn-primary .btn-arrow { position: relative; z-index: 1; }
.btn-primary:hover .btn-arrow { transform: translateX(4px); }
.btn-primary .btn-arrow { transition: transform 0.3s; display: inline-block; }

/* --- §0.10 Secondary button --- */
.btn-secondary {
  position: relative;
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.75rem 1.5rem; border-radius: 8px;
  font-family: var(--bf); font-size: 0.875rem; font-weight: 500;
  color: var(--white); text-decoration: none;
  background: rgba(255,255,255,0.05);
  backdrop-filter: blur(10px);
  overflow: visible;
  min-height: 44px;
  transform: translateY(0);
  transition: all 0.3s; cursor: pointer;
  border: none;
}
.btn-secondary:hover {
  background: rgba(255,255,255,0.1);
  transform: translateY(-2px);
}
.btn-secondary .btn-border-static {
  position: absolute; inset: 0; border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.2);
  transition: opacity 0.3s; pointer-events: none;
}
.btn-secondary:hover .btn-border-static { opacity: 0; }
.btn-secondary .border-svg {
  position: absolute; inset: 0; width: 100%; height: 100%;
  overflow: visible; pointer-events: none;
}
.btn-secondary .border-svg rect {
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
  transition: stroke-dashoffset 0.6s ease-out;
}
.btn-secondary:hover .border-svg rect { stroke-dashoffset: 0; }
.btn-secondary .btn-glow {
  position: absolute; inset: 0; border-radius: 8px;
  box-shadow: 0 0 20px rgba(139,92,246,0.3);
  opacity: 0; transition: opacity 0.3s; pointer-events: none;
}
.btn-secondary:hover .btn-glow { opacity: 1; }
.btn-secondary .btn-text,
.btn-secondary .btn-arrow { position: relative; z-index: 1; }
.btn-secondary:hover .btn-arrow { transform: translateX(4px); }
.btn-secondary .btn-arrow { transition: transform 0.3s; display: inline-block; }

/* --- Small button (Play Now in game cards) --- */
.btn-small {
  position: relative;
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.5rem 1rem; border-radius: 8px;
  font-family: var(--bf); font-size: 0.8125rem; font-weight: 500;
  color: var(--white); text-decoration: none;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.2);
  backdrop-filter: blur(10px);
  min-height: 44px;
  justify-content: center;
  transition: all 0.3s; cursor: pointer;
  overflow: hidden;
}
.btn-small:hover {
  transform: translateY(-2px);
  background: rgba(255,255,255,0.1);
  border-color: rgba(139,92,246,0.5);
  box-shadow: 0 0 20px rgba(139,92,246,0.3);
}
.btn-small--primary {
  background: rgba(139,92,246,0.8);
  border: 1px solid rgba(139,92,246,0.5);
}
.btn-small--primary:hover {
  background: rgba(139,92,246,0.8);
  box-shadow: 0 8px 32px rgba(139,92,246,0.3);
  border-color: rgba(139,92,246,0.5);
}
.btn-small--primary .btn-fill {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, #8b5cf6, #00adff);
  transform: translateX(-100%);
  transition: transform 0.5s;
  border-radius: 7px;
}
.btn-small--primary:hover .btn-fill { transform: translateX(0); }
.btn-small .btn-icon,
.btn-small .btn-label { position: relative; z-index: 1; }
.btn-small .btn-icon { display: flex; align-items: center; }
.btn-small--disabled {
  background: rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.5);
  border: 1px solid rgba(255,255,255,0.1);
  cursor: default;
}
.btn-small--disabled:hover {
  transform: none;
  box-shadow: none;
  border-color: rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.08);
}

/* --- Download button (secondary button style per §0.10 + SoR) --- */
.btn-download {
  position: relative;
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.5rem 1rem; border-radius: 8px;
  font-family: var(--bf); font-size: 0.8125rem; font-weight: 500;
  color: var(--white); text-decoration: none;
  background: rgba(255,255,255,0.05);
  backdrop-filter: blur(10px);
  overflow: visible;
  min-height: 44px;
  min-width: 110px;
  justify-content: center;
  transform: translateY(0);
  transition: all 0.3s; cursor: pointer;
  border: none;
}
.btn-download:hover {
  background: rgba(255,255,255,0.1);
  transform: translateY(-2px);
}
.btn-download .btn-border-static {
  position: absolute; inset: 0; border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.2);
  transition: opacity 0.3s; pointer-events: none;
}
.btn-download:hover .btn-border-static { opacity: 0; }
.btn-download .border-svg {
  position: absolute; inset: 0; width: 100%; height: 100%;
  overflow: visible; pointer-events: none;
}
.btn-download .border-svg rect {
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
  transition: stroke-dashoffset 0.6s ease-out;
}
.btn-download:hover .border-svg rect { stroke-dashoffset: 0; }
.btn-download .btn-glow {
  position: absolute; inset: 0; border-radius: 8px;
  box-shadow: 0 0 20px rgba(139,92,246,0.3);
  opacity: 0; transition: opacity 0.3s; pointer-events: none;
}
.btn-download:hover .btn-glow { opacity: 1; }
.btn-download .btn-icon,
.btn-download .btn-label { position: relative; z-index: 1; }
.btn-download .btn-icon { display: flex; align-items: center; }

/* --- Back to AT link --- */
.back-link {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-family: var(--bf); font-size: 0.875rem;
  color: var(--gray-300); text-decoration: none;
  padding: 0.5rem 1rem; border-radius: 8px;
  min-height: 44px;
  transition: all 0.3s;
}
.back-link:hover {
  color: var(--white);
  background: rgba(255,255,255,0.05);
}
.back-link:hover .back-link-arrow {
  transform: rotate(180deg) translateX(4px);
}
.back-link-arrow {
  display: inline-block;
  transform: rotate(180deg);
  transition: transform 0.3s;
}

/* --- Feature Card (Light Glass) — per ge-feature-card-spec --- */
.card-light {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 0.75rem;
  padding: 0;  /* padding handled by inner content divs */
  box-shadow: none;
  backdrop-filter: none;
  overflow: hidden;
  position: relative;
  transition: all 0.5s cubic-bezier(0.4,0,0.2,1);
}
.card-light:hover, .card-light:focus-within {
  background: rgba(255,255,255,0.07);
  border-color: rgba(139,92,246,0.2);
  box-shadow: 0 8px 32px rgba(0,0,0,0.35), 0 0 20px rgba(139,92,246,0.08);
  transform: translateY(-2px);
}
.card-light .card-glow {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 50% 0%, rgba(139,92,246,0.08) 0%, transparent 60%);
  opacity: 0; transition: opacity 0.5s; pointer-events: none;
}
.card-light:hover .card-glow { opacity: 1; }

/* --- §5.2 Glassmorphic cards --- */
.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  box-shadow: var(--shadow);
  transition: var(--transition);
  overflow: hidden;
  position: relative;
}
.glass:hover, .glass:focus-within {
  background: var(--glass-bg-hover);
  backdrop-filter: blur(24px) saturate(1.1);
  border-color: var(--glass-border-hover);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}
.glass .glass-glow {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 50% 0%, rgba(139,92,246,0.08) 0%, transparent 60%);
  opacity: 0; transition: opacity 0.5s; pointer-events: none;
}
.glass:hover .glass-glow { opacity: 1; }

/* Featured game card — no hover lift (content-heavy) */
.featured-game-card {
  transform: none !important;
}
.featured-game-card:hover {
  transform: translateY(-4px) !important;
}

/* --- Game card grid --- */
.games-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.75rem;
}
@media (min-width: 1200px) {
  .px-6 { padding-left: 2.5rem; padding-right: 2.5rem; }
}
@media (max-width: 1000px) {
  .games-grid { grid-template-columns: repeat(2, 1fr) !important; }
}
@media (max-width: 600px) {
  .games-grid { grid-template-columns: 1fr !important; }
}

/* Featured game card inner grid */
.featured-game-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 0;
}
@media (max-width: 768px) {
    .hero-game{
    min-height:80vh;padding-top:1rem;padding-bottom:1rem;
}
.py-20 {
    padding-top: 1rem;
    padding-bottom: 1rem;
}
.cta-sec{padding-top:1rem;padding-bottom:1rem}
  .featured-game-grid { grid-template-columns: 1fr !important; }
}

/* Game card image zone */
.game-card-img-zone {
  aspect-ratio: 10 / 9;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(139,92,246,0.06);
}
.game-card-img-zone img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.featured-img-zone {
  min-height: 280px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(139,92,246,0.06);
}
.featured-img-zone img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* --- Hero section --- */
.hero-grid {
  display: grid;
  grid-template-columns: 2fr 3fr;
  gap: 3rem;
  align-items: center;
}
@media (max-width: 768px) {
  .hero-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .text-5xl { font-size: 2.25rem; line-height: 2.5rem; }
  .learn-more-chevron { display: none; }
}
.hero-body { max-width: 26em; }
.hero-img-zone {
  position: relative;
  overflow: hidden;
  max-height: 500px;
}
.hero-img-zone::before {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 80%; height: 80%;
  background: radial-gradient(ellipse at center,
    rgba(139,92,246,0.2) 0%,
    rgba(0,173,255,0.1) 40%,
    transparent 70%);
  filter: blur(40px);
  z-index: 0;
  pointer-events: none;
}
.hero-img-zone img {
  width: 100%;
  max-height: 500px;
  object-fit: contain;
  display: block;
  position: relative;
  z-index: 1;
}

/* Floating nodes */
.hero-nodes {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  overflow: visible;
}
.hero-node {
  position: absolute;
  border-radius: 50%;
  opacity: 0.6;
  animation: node-float 6s ease-in-out infinite;
}
.hero-node:nth-child(1) { width: 6px; height: 6px; background: #8b5cf6; top: 12%; left: 18%; animation-delay: 0s; animation-duration: 5.5s; }
.hero-node:nth-child(2) { width: 4px; height: 4px; background: #00adff; top: 25%; right: 12%; animation-delay: 1.2s; animation-duration: 7s; }
.hero-node:nth-child(3) { width: 5px; height: 5px; background: #00d9c0; bottom: 20%; left: 10%; animation-delay: 2.4s; animation-duration: 6.5s; }
.hero-node:nth-child(4) { width: 3px; height: 3px; background: #8b5cf6; top: 40%; right: 22%; animation-delay: 0.8s; animation-duration: 8s; }
.hero-node:nth-child(5) { width: 5px; height: 5px; background: #00adff; bottom: 30%; right: 8%; animation-delay: 3s; animation-duration: 6s; }
.hero-node:nth-child(6) { width: 4px; height: 4px; background: #00d9c0; top: 8%; left: 45%; animation-delay: 1.8s; animation-duration: 7.5s; }
.hero-node:nth-child(7) { width: 6px; height: 6px; background: #8b5cf6; bottom: 12%; left: 55%; animation-delay: 4s; animation-duration: 5s; opacity: 0.4; }
.hero-node:nth-child(8) { width: 3px; height: 3px; background: #00adff; top: 55%; left: 5%; animation-delay: 2s; animation-duration: 9s; }

@keyframes node-float {
  0%, 100% { transform: translate(0, 0); opacity: 0.6; }
  25% { transform: translate(8px, -12px); opacity: 0.8; }
  50% { transform: translate(-6px, -8px); opacity: 0.5; }
  75% { transform: translate(10px, 6px); opacity: 0.7; }
}

/* --- Learn More chevron --- */
.learn-more-chevron {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.375rem;
  color: var(--gray-200);
  text-decoration: none;
  font-family: var(--bf);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  padding: 0.5rem 1rem;
  min-height: 44px;
  transition: color 0.3s, opacity 0.4s;
  animation: chevron-bob 2s ease-in-out infinite;
  opacity: 1;
}
.learn-more-chevron.hidden {
  opacity: 0;
  pointer-events: none;
}
.learn-more-chevron:hover {
  color: var(--white);
}
.learn-more-text {
  display: block;
}
@keyframes chevron-bob {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(6px); }
}

/* --- §3.1 Icon mask gradient technique --- */
.icon-mask {
  background: linear-gradient(135deg, #8b5cf6, #00adff, #00d9c0);
  -webkit-mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
  display: inline-block;
}

/* --- Reduced motion (§9) --- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  #neuralCanvas { display: none; }
}

/* --- Link styling --- */
a.text-link {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}
a.text-link:hover {
  color: var(--white);
}

/* --- Divider --- */
.btn-divider {
  color: var(--gray-600);
  margin: 0 0.5rem;
  user-select: none;
}