/* ═══════════════════════════════════════════════════════════
   Gladeye 20th — dark Tron / vaporwave (neon toned DOWN)
   ═══════════════════════════════════════════════════════════ */

:root {
  --bg0: #07050f;
  --bg1: #0d0a24;
  --cyan: #6fd2e0;      /* softened from electric #1ef3ff */
  --magenta: #cf74c2;   /* softened from #ff2bd6 */
  --lime: #a6d96a;
  --violet: #7a68c4;
  --grid: rgba(110, 210, 224, 0.22);
  --ink: #cdd9ea;
  --panel: rgba(12, 10, 30, 0.88);
  --glow-c: rgba(111, 210, 224, 0.28);   /* reusable soft cyan glow */
  --glow-m: rgba(207, 116, 194, 0.25);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body {
  min-height: 100vh;
  font-family: "VT323", "Courier New", monospace;
  font-size: 18px;
  color: var(--ink);
  overflow-x: hidden;
  background-color: var(--bg0);
  /* tiled laser-wolf GIF, GeoCities-style, under a dark veil for readability */
  background-image:
    linear-gradient(rgba(7,5,15,0.28), rgba(7,5,15,0.28)),
    url("../gifs/bg-tile.gif");
  background-repeat: repeat;
  background-size: auto, 128px 128px;
}

/* ── perspective neon grid floor (dimmer) ── */
body::before {
  content: ""; position: fixed; z-index: 0;
  left: 50%; bottom: -6vh;
  width: 320vw; height: 70vh;
  transform: translateX(-50%) perspective(40vh) rotateX(72deg);
  transform-origin: bottom center;
  background-image:
    linear-gradient(var(--grid) 2px, transparent 2px),
    linear-gradient(90deg, var(--grid) 2px, transparent 2px);
  background-size: 70px 70px;
  animation: gridrun 2.8s linear infinite;
  -webkit-mask: linear-gradient(to top, #000 0%, rgba(0,0,0,.3) 45%, transparent 80%);
          mask: linear-gradient(to top, #000 0%, rgba(0,0,0,.3) 45%, transparent 80%);
  pointer-events: none; opacity: .7;
}
@keyframes gridrun { from { background-position: 0 0; } to { background-position: 0 70px; } }

/* ── CRT scanline + vignette overlay (subtler) ── */
.crt {
  position: fixed; inset: 0; z-index: 200; pointer-events: none;
  background:
    repeating-linear-gradient(0deg, rgba(0,0,0,0.07) 0 1px, transparent 1px 3px),
    radial-gradient(circle at 50% 45%, transparent 70%, rgba(0,0,0,0.22) 100%);
  mix-blend-mode: multiply;
}

/* ░░ MARQUEE ░░ */
.marquee {
  position: sticky; top: 0; z-index: 50;
  background: #07050f;
  border-bottom: 1px solid rgba(111,210,224,.5);
  box-shadow: 0 0 6px var(--glow-c);
  overflow: hidden; white-space: nowrap;
}
.marquee__track { display: inline-flex; will-change: transform; animation: scroll-left 24s linear infinite; }
.marquee__track span {
  font-family: "VT323", monospace; font-size: 22px; color: var(--cyan);
  text-shadow: 0 0 4px var(--glow-c); padding: 4px 0; letter-spacing: 1px;
}
@keyframes scroll-left { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ░░ SCATTER LAYER ░░ */
.scatter { position: absolute; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; }
.sticker {
  position: absolute; pointer-events: auto;
  rotate: var(--rot, 0deg); scale: 0; opacity: 0;
  filter: drop-shadow(2px 4px 5px rgba(0,0,0,.6));
  animation: bob var(--bob, 5s) ease-in-out infinite;
  transition: scale .45s cubic-bezier(.34, 1.7, .5, 1), opacity .4s ease;
}
.sticker.in { scale: 1; opacity: 1; }
.sticker img, .sticker .emoji { display: block; width: 100%; height: 100%; object-fit: contain; user-select: none; }
.sticker .emoji {
  display: grid; place-items: center;
  font-family: "Apple Color Emoji","Segoe UI Emoji", sans-serif; line-height: 1;
  background: radial-gradient(circle at 30% 25%, #1a1640, #07050f);
  border: 1px solid rgba(111,210,224,.6); border-radius: 12px;
  box-shadow: 0 0 6px var(--glow-c);
}
.sticker:hover { scale: 1.18 !important; z-index: 99 !important; }
@keyframes bob { 0%,100% { translate: 0 0; } 50% { translate: 0 -10px; } }

/* ░░ STAGE / CONTENT ░░ */
.stage {
  position: relative; z-index: 10;
  max-width: 720px; margin: 0 auto;
  padding: 30px 16px 70px;
  display: flex; flex-direction: column; align-items: center; gap: 32px;
}

/* ── HERO: spinning 3D chrome 20th ── */
.hero { text-align: center; }
.scene { perspective: 800px; height: 210px; display: grid; place-items: center; margin-bottom: 4px; }
.word3d {
  position: relative; transform-style: preserve-3d;
  animation: spinY 7s linear infinite;
  font-family: "Bungee", Impact, sans-serif;
  font-size: clamp(94px, 27vw, 180px); line-height: 1;
}
.word3d sup { font-size: .4em; }
.word3d__face, .word3d__layer {
  display: block;
  background: linear-gradient(180deg, #ffffff 0%, #d8f3ff 16%, #6fc0d8 38%, #143a52 50%, #2f6a86 54%, #aadcf0 72%, #ffffff 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  -webkit-text-stroke: 2px rgba(111,210,224,.85);
  filter: drop-shadow(0 0 5px var(--glow-c));
}
.word3d__layer {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, #2f6a86, #0a2236);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  -webkit-text-stroke: 2px rgba(111,210,224,.3); filter: none;
}
@keyframes spinY { from { transform: rotateY(0deg) rotateX(8deg); } to { transform: rotateY(360deg) rotateX(8deg); } }

.hero__sub {
  margin: 4px 0 0; font-family: "Bungee", Impact, sans-serif;
  font-size: clamp(22px, 6vw, 40px); color: #eef6ff;
  text-shadow: 0 0 3px rgba(255,255,255,.5), 0 0 10px var(--glow-c);
}
.hero__sub b { color: var(--cyan); }
.hero__tag {
  margin: 10px 0 0; font-size: 19px; color: var(--cyan);
  background: rgba(12,10,30,.7); display: inline-block;
  padding: 5px 14px; border-radius: 4px; border: 1px solid rgba(111,210,224,.55);
}

/* ── WINDOW PANELS (CRT terminal) ── */
.win {
  width: 100%;
  background: var(--panel);
  border: 1px solid rgba(111,210,224,.7);
  border-radius: 6px;
  box-shadow: 0 0 0 1px rgba(122,104,196,.4), 0 0 14px var(--glow-c), 0 14px 40px rgba(0,0,0,.7);
  overflow: hidden;
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}
.win__bar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 6px 10px;
  background: linear-gradient(180deg, #1a1450, #0a0826);
  border-bottom: 1px solid rgba(207,116,194,.6);
  color: var(--cyan); font-family: "VT323", monospace; font-size: 20px;
  text-shadow: 0 0 4px var(--glow-c);
}
.win__btns i {
  font-style: normal; display: inline-block; width: 20px; height: 18px;
  background: #0a0826; color: var(--cyan); text-align: center;
  border: 1px solid rgba(111,210,224,.7); border-radius: 3px; margin-left: 3px;
  font-size: 13px; line-height: 16px;
}
.win__body { padding: 18px 20px 22px; }

/* details list */
.details p { margin: 10px 0; font-size: 19px; }
.lbl {
  display: inline-block; min-width: 78px;
  font-family: "Press Start 2P", monospace; font-size: 10px;
  color: #07050f; background: var(--cyan); padding: 6px 7px; border-radius: 3px;
  box-shadow: 0 0 5px var(--glow-c); margin-right: 10px;
}
.val { color: #eef6ff; }
.maplink { color: #eef6ff; text-decoration: none; }
.maplink:hover { text-shadow: 0 0 5px var(--glow-c); }
.maplink .pin {
  display: inline-block; margin-left: 6px; white-space: nowrap;
  font-family: "VT323", monospace; font-size: 15px; color: #07050f;
  background: var(--cyan); padding: 1px 7px; border-radius: 3px;
  box-shadow: 0 0 5px var(--glow-c); vertical-align: middle;
}
.maplink:hover .pin { filter: brightness(1.1); }
.rule { border: none; border-top: 1px dashed rgba(111,210,224,.45); margin: 18px 0; }

/* ── FORM ── */
.form__hint { text-align: center; font-size: 19px; color: var(--magenta); margin: 0 0 16px; }
.field { display: block; margin-bottom: 14px; }
.field > span { display: block; font-family: "VT323", monospace; font-size: 20px; color: var(--cyan); margin-bottom: 5px; }
.field input, .field select, .field textarea {
  width: 100%; font-family: "VT323", monospace; font-size: 18px;
  padding: 9px 10px; border-radius: 4px;
  border: 1px solid rgba(111,210,224,.7);
  background: #07050f; color: #fff;
  box-shadow: inset 0 0 6px rgba(111,210,224,.15);
}
.field input::placeholder, .field textarea::placeholder { color: #5a6b8c; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--magenta);
  box-shadow: 0 0 0 2px var(--glow-m), inset 0 0 6px rgba(207,116,194,.12);
}
.field--radio { border: none; margin: 0 0 14px; padding: 0; }
.field--radio > legend { display: block; padding: 0; margin-bottom: 5px; font-family: "VT323", monospace; font-size: 20px; color: var(--cyan); }
.radios { display: flex; flex-wrap: wrap; gap: 10px; }
.radios label {
  font-size: 17px; background: #07050f; padding: 7px 12px;
  border: 1px solid rgba(122,104,196,.7); border-radius: 4px; cursor: pointer; color: var(--ink);
}
.radios input { margin-right: 5px; accent-color: var(--magenta); }
/* honeypot — kept in the DOM for bots but pulled far off-screen for humans */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

.btn-glossy {
  display: block; width: 100%; margin-top: 8px;
  font-family: "Bungee", Impact, sans-serif; font-size: 20px; letter-spacing: 1px;
  color: #07050f; cursor: pointer;
  padding: 14px; border: 1px solid rgba(255,255,255,.6); border-radius: 6px;
  background: linear-gradient(180deg, #cdeef4 0%, var(--cyan) 50%, #4ba6b4 51%, #8fdce6 100%);
  box-shadow: 0 0 10px var(--glow-c), inset 0 2px 4px rgba(255,255,255,.6);
  text-shadow: 0 1px 0 rgba(255,255,255,.5);
  transition: transform .08s ease, filter .15s ease, box-shadow .15s ease;
}
.btn-glossy:hover { filter: brightness(1.08); box-shadow: 0 0 16px var(--glow-c), inset 0 2px 4px rgba(255,255,255,.6); }
.btn-glossy:active { transform: translateY(2px); }
.btn-glossy:disabled { filter: grayscale(.6) brightness(.8); cursor: wait; }
.form__status { text-align: center; font-size: 18px; margin: 14px 0 0; min-height: 22px; }
.form__status.ok { color: var(--lime); }
.form__status.err { color: var(--magenta); }

/* ── FOOTER ── */
.footer { text-align: center; margin-top: 12px; }
.badges { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.badge {
  font-family: "VT323", monospace; font-size: 16px; color: var(--cyan);
  background: #07050f; border: 1px solid rgba(111,210,224,.5); padding: 4px 9px; border-radius: 3px;
  box-shadow: 0 0 5px var(--glow-c);
}
.badge b { color: var(--magenta); }
button.badge { cursor: pointer; font-family: "VT323", monospace; }
button.badge:hover { filter: brightness(1.15); box-shadow: 0 0 9px var(--glow-c); }
button.badge:active { transform: translateY(1px); }
.cal { align-items: center; gap: 8px 8px; }
.cal__label { font-family: "VT323", monospace; font-size: 17px; color: var(--ink); }
.copy { font-size: 15px; color: #7e8bb0; margin-top: 12px; }

/* keyboard focus visibility */
.btn-glossy:focus-visible, button.badge:focus-visible,
.maplink:focus-visible, .win__bar:focus-visible {
  outline: 3px solid var(--magenta); outline-offset: 2px;
}

/* ── pause everything when tab is backgrounded (perf/battery) ── */
body.paused .sticker,
body.paused .word3d,
body.paused .marquee__track { animation-play-state: paused !important; }
body.paused::before { animation-play-state: paused !important; }

/* ── mobile pass ── */
@media (max-width: 600px) {
  body { font-size: 17px; }
  .stage { padding: 18px 12px 56px; gap: 24px; }
  .scene { height: 150px; }
  .marquee__track span { font-size: 19px; }
  .win__body { padding: 14px 13px 18px; }
  .details p { margin: 9px 0; font-size: 16px; line-height: 1.5; }
  .lbl { min-width: 0; margin-right: 7px; }
  .field > span, .field--radio > legend { font-size: 18px; }
  .field input, .field select, .field textarea { font-size: 16px; padding: 11px 10px; }
  .radios { gap: 8px; }
  .radios label { font-size: 16px; padding: 9px 12px; }   /* bigger tap targets */
  .btn-glossy { font-size: 18px; padding: 15px; }          /* easy thumb target */
  .hero__tag { font-size: 16px; }
  .cal { flex-direction: column; gap: 7px; }
  .cal__label { font-size: 16px; }
  .badge { font-size: 15px; padding: 8px 12px; }
  /* lighter shadows on phones = smoother scroll */
  .sticker { filter: drop-shadow(1px 2px 3px rgba(0,0,0,.5)); }
}

/* ── reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  .word3d, .sticker, .marquee__track, body::before { animation: none !important; }
}
