@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&family=JetBrains+Mono:ital,wght@0,400;0,500;0,700;1,400&display=swap');

:root{
  --bg:#120f1a;
  --panel:#1d1830;
  --panel-2:#241f3a;
  --gold:#ffce45;
  --gold-dim:#b8860b;
  --red:#e6483c;
  --cream:#f3ead2;
  --muted:#8a83a8;
  --border:#3a3454;
  --maxw:960px;
}

*{box-sizing:border-box;}
html{scroll-behavior:smooth;}

body{
  margin:0;
  background:var(--bg);
  color:var(--cream);
  font-family:'JetBrains Mono', ui-monospace, monospace;
  font-size:16px;
  line-height:1.65;
  -webkit-font-smoothing:antialiased;
}

/* Subtle CRT scanline texture, ambient not decorative overload */
body::before{
  content:"";
  position:fixed;
  inset:0;
  pointer-events:none;
  z-index:2;
  background:repeating-linear-gradient(
    0deg,
    rgba(0,0,0,0.10) 0px,
    rgba(0,0,0,0.10) 1px,
    transparent 1px,
    transparent 3px
  );
  opacity:.35;
  mix-blend-mode:overlay;
}

.pixel{
  font-family:'Press Start 2P', monospace;
  line-height:1.5;
  letter-spacing:.5px;
}

a{color:var(--gold); text-decoration:none;}
a:hover{color:var(--red);}
a:focus-visible, button:focus-visible{
  outline:3px solid var(--gold);
  outline-offset:3px;
}

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

.wrap{
  max-width:var(--maxw);
  margin:0 auto;
  padding:0 24px;
}

/* ---------- NAV ---------- */
.nav{
  position:relative;
  z-index:3;
  border-bottom:1px solid var(--border);
  background:rgba(18,15,26,.9);
  backdrop-filter:blur(4px);
}
.nav .wrap{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding-top:18px;
  padding-bottom:18px;
}
.nav-logo{
  font-family:'Press Start 2P', monospace;
  font-size:.72rem;
  color:var(--cream);
  letter-spacing:1px;
}
.nav-logo span{color:var(--gold);}
.nav-links{
  display:flex;
  gap:28px;
  font-size:.85rem;
}
.nav-links a{color:var(--muted);}
.nav-links a:hover{color:var(--gold);}

/* ---------- HERO ---------- */
.hero{
  position:relative;
  z-index:1;
  padding:96px 0 72px;
  overflow:hidden;
}
.hero::after{
  content:"";
  position:absolute;
  inset:-20% -10% auto -10%;
  height:340px;
  background:radial-gradient(ellipse at 30% 30%, rgba(255,206,69,.14), transparent 60%);
  z-index:-1;
}
.eyebrow{
  font-size:.72rem;
  letter-spacing:3px;
  color:var(--red);
  text-transform:uppercase;
  margin-bottom:18px;
}
.hero h1{
  font-family:'Press Start 2P', monospace;
  font-size:clamp(1.7rem, 5vw, 3rem);
  line-height:1.4;
  margin:0 0 22px;
  color:var(--cream);
  text-shadow:3px 3px 0 var(--gold-dim), 6px 6px 0 rgba(0,0,0,.4);
}
.hero h1 span{color:var(--gold);}
.hero p.lede{
  max-width:52ch;
  color:var(--muted);
  font-size:1.05rem;
  margin-bottom:34px;
}

/* Blinking insert-coin cursor -- the signature element */
.insert-coin{
  display:inline-flex;
  align-items:center;
  gap:10px;
  font-family:'Press Start 2P', monospace;
  font-size:.78rem;
  color:var(--gold);
  cursor:pointer;
  background:none;
  border:none;
  padding:0;
}
.insert-coin::before{
  content:"▸";
  color:var(--red);
}
.insert-coin .cursor{
  display:inline-block;
  width:10px;
  height:1em;
  background:var(--gold);
  animation:blink 1s steps(1) infinite;
  margin-left:4px;
}
@keyframes blink{ 50%{ opacity:0; } }
@media (prefers-reduced-motion: reduce){
  .insert-coin .cursor{ animation:none; }
}

/* ---------- SECTION HEADERS ---------- */
.section{ padding:64px 0; position:relative; z-index:1; }
.section-head{ margin-bottom:36px; }
.section-head .eyebrow{ margin-bottom:10px; }
.section-head h2{
  font-family:'Press Start 2P', monospace;
  font-size:1.2rem;
  color:var(--cream);
  margin:0;
}

/* ---------- CARTRIDGE CARD ---------- */
.cartridge{
  display:grid;
  grid-template-columns:96px 1fr;
  gap:22px;
  background:var(--panel);
  border:2px solid var(--border);
  border-top:6px solid var(--gold);
  padding:22px;
  border-radius:4px;
  position:relative;
}
.cartridge::before{
  content:"";
  position:absolute;
  top:-6px; left:18px;
  width:34px; height:6px;
  background:var(--bg);
}
.cart-icon{
  width:96px; height:96px;
  border-radius:6px;
  border:2px solid var(--border);
  overflow:hidden;
  background:var(--bg);
}
.cart-body h3{
  font-family:'Press Start 2P', monospace;
  font-size:.95rem;
  margin:2px 0 12px;
  color:var(--gold);
}
.cart-body p{ color:var(--cream); margin:0 0 16px; }
.cart-actions{ display:flex; gap:14px; flex-wrap:wrap; }

.btn{
  display:inline-block;
  font-family:'JetBrains Mono', monospace;
  font-weight:700;
  font-size:.85rem;
  padding:10px 18px;
  border-radius:3px;
  border:2px solid var(--gold);
  color:var(--gold);
  background:transparent;
  letter-spacing:.5px;
}
.btn:hover{ background:var(--gold); color:var(--bg); }
.btn.primary{ background:var(--gold); color:var(--bg); }
.btn.primary:hover{ background:var(--red); border-color:var(--red); color:var(--cream); }

/* ---------- BADGE GRID (achievements) ---------- */
.badge-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill, minmax(150px, 1fr));
  gap:18px;
}
.badge{
  background:var(--panel);
  border:1px solid var(--border);
  border-radius:6px;
  padding:16px;
  text-align:center;
}
.badge img{
  width:64px; height:64px;
  margin:0 auto 12px;
  border-radius:4px;
}
.badge .name{
  font-family:'Press Start 2P', monospace;
  font-size:.6rem;
  color:var(--gold);
  line-height:1.6;
  margin-bottom:8px;
}
.badge .desc{ font-size:.78rem; color:var(--muted); }

/* ---------- FEATURE LIST ---------- */
.features{
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(220px,1fr));
  gap:24px;
}
.feature .tag{
  font-family:'Press Start 2P', monospace;
  font-size:.6rem;
  color:var(--red);
  margin-bottom:10px;
  display:block;
}
.feature h4{ margin:0 0 8px; color:var(--cream); font-size:1rem; }
.feature p{ margin:0; color:var(--muted); font-size:.9rem; }

/* ---------- FOOTER ---------- */
footer{
  border-top:1px solid var(--border);
  padding:36px 0;
  position:relative; z-index:1;
}
footer .wrap{
  display:flex;
  flex-wrap:wrap;
  gap:16px;
  align-items:center;
  justify-content:space-between;
  font-size:.82rem;
  color:var(--muted);
}
footer a{ color:var(--muted); }
footer a:hover{ color:var(--gold); }

/* ---------- PROSE (privacy page) ---------- */
.prose{ max-width:70ch; }
.prose h2{
  font-family:'Press Start 2P', monospace;
  font-size:.95rem;
  color:var(--gold);
  margin-top:44px;
}
.prose p, .prose li{ color:var(--cream); }
.prose .updated{ color:var(--muted); font-size:.85rem; }

@media (max-width:560px){
  .cartridge{ grid-template-columns:1fr; }
  .cart-icon{ width:72px; height:72px; }
}
