/* ============================================================
   THE PIXEL_VILLAGE — Spin page (neo-brutalist redesign)
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Anton&family=JetBrains+Mono:wght@400;500;700&display=swap');

:root{
  --background: #F9F8F6;
  --heading: #040D13;
  --teal: #61FFF1;
  --white: #F9F8F6;

  --font-heading: 'Anton', sans-serif;
  --font-body: 'JetBrains Mono', monospace;

  --border-w: 2px;
  --radius: 2px;
  --max-w: 1360px;
}

*,*::before,*::after{ box-sizing: border-box; }
html{ scroll-behavior: smooth; overflow-x: hidden; }
body{
  margin:0;
  background: var(--background);
  color: var(--heading);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a{ color: inherit; text-decoration:none; }
button{ font-family: inherit; cursor:pointer; }
svg{ display:block; }

.wrap{ max-width: var(--max-w); margin: 0 auto; padding: 0 clamp(20px, 4vw, 56px); }

/* ---------- Header ---------- */
.nav{ border-bottom: 2px solid var(--heading); }
.nav-inner{
  max-width: var(--max-w); margin: 0 auto;
  padding: 24px clamp(20px, 4vw, 56px);
  display:flex; align-items:center; justify-content:space-between; gap:24px;
}
.logo{ font-family: var(--font-body); font-weight:700; line-height:1.1; }
.logo .eyebrow{ display:block; font-size:10px; letter-spacing:.18em; color:#5B6570; }
.logo .mark{ font-size:22px; letter-spacing:.02em; }
.logo .mark .bracket{ color: var(--teal); }

.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  font-family: var(--font-body); font-weight:700; font-size:13px; letter-spacing:.04em;
  padding: 12px 20px;
  border: var(--border-w) solid var(--heading);
  border-radius: var(--radius);
  background: var(--background);
  color: var(--heading);
  transition: transform .15s ease, box-shadow .15s ease;
}
.btn:hover{ transform: translate(-2px,-2px); }
.btn:focus-visible{ outline: 3px solid var(--heading); outline-offset: 3px; }
.btn-teal{
  background: var(--teal);
  box-shadow: 4px 4px 0 var(--heading);
}
.btn-teal:hover{ box-shadow: 6px 6px 0 var(--heading); }
.btn-teal:active{ transform: translate(0,0); box-shadow: 2px 2px 0 var(--heading); }
.btn-ghost{ border-color: var(--heading); }
.btn[disabled]{ opacity:.5; cursor:not-allowed; transform:none; }

/* ---------- Main / hero grid ---------- */
main.wrap{ position: relative; }
.hero-grid{
  display:grid;
  grid-template-columns: 1.1fr 1fr;
  align-items:center;
  gap: 56px;
  min-height: calc(100vh - 76px - 60px);
  position:relative;
}

/* ---------- Wheel column ---------- */
.wheel-col{ position:relative; align-self:stretch; min-height: 480px; overflow: visible; }
.wheel-rig{
  position:absolute; top:50%;
  right: 6%;
  transform: translateY(-50%);
  /* Fallback size; js/wheel.js measures the column and sets exact px
     width/height so the circle can never exceed available height. */
  width: 60%; max-width: 640px; min-width: 300px;
  aspect-ratio: 1/1;
}
.wheel-shadow{
  position:absolute; inset:0; border-radius:50%;
  background: var(--teal);
  transform: translate(10px, 10px);
  z-index: 0;
}
.wheel-spin{
  position:absolute; inset:0;
  transform: rotate(0deg);
  z-index: 1;
  will-change: transform;
}
.wheel-spin svg{ width:100%; height:100%; }

.wheel-label{
  position:absolute;
  width: 32%;
  transform: translate(-50%, -50%);
  text-align:center;
  pointer-events:none;
  z-index: 2;
}
.wheel-label .icon{ margin: 0 auto 4px; width:30px; height:22px; }
.wheel-label h4{
  font-family: var(--font-heading); font-weight:400; text-transform:uppercase;
  font-size: clamp(12px, 1.5vw, 18px); line-height:1.05; margin: 0 0 4px;
}
.wheel-label p{
  font-family: var(--font-body); font-size: clamp(9px, 0.95vw, 11px);
  line-height:1.3; margin:0; opacity:.85;
}
.wheel-label--dark{ color: var(--heading); }
.wheel-label--light{ color: var(--background); }

.wheel-hub{
  position:absolute; top:50%; left:50%; transform: translate(-50%,-50%);
  width: 20%; height:20%; min-width:76px; min-height:76px;
  border-radius:50%;
  background: var(--heading);
  border: 3px solid var(--background);
  box-shadow: 0 0 0 3px var(--heading);
  display:flex; align-items:center; justify-content:center;
  z-index: 3;
  cursor:pointer;
}
.wheel-hub span{
  font-family: var(--font-heading); font-weight:400; letter-spacing:.04em;
  color: var(--teal); font-size: clamp(14px, 1.8vw, 22px);
}
.wheel-hub[disabled]{ cursor:default; opacity:.85; }

.wheel-pointer{
  position:absolute; top:50%; right:-4%;
  transform: translateY(-50%);
  width: 9%; min-width: 44px; max-width: 68px;
  z-index: 4;
  filter: drop-shadow(2px 2px 0 rgba(0,0,0,0));
}

/* ---------- Content column ---------- */
.content-col{ position:relative; padding: 40px 0; z-index: 2; }
.kicker{
  font-family: var(--font-body); font-size:13px; letter-spacing:.14em;
  color: var(--heading); display:flex; gap:10px; align-items:center; margin-bottom:18px;
}
.kicker .sq{ width:9px; height:9px; background: var(--teal); border: 1px solid var(--heading); display:inline-block; }

h1.headline{
  font-family: var(--font-heading); font-weight:400; text-transform:uppercase;
  font-size: clamp(34px, 4.4vw, 58px); line-height:0.95; margin: 0 0 6px;
}
.headline-block{
  display:inline-block;
  background: var(--teal);
  border: var(--border-w) solid var(--heading);
  box-shadow: 5px 5px 0 var(--heading);
  padding: 2px 16px;
  margin-top: 6px;
}

.stage-sub{
  font-size:14px; line-height:1.7; color:#20262B; max-width:44ch; margin: 22px 0 10px;
}
.stage-note{
  font-size:12.5px; line-height:1.6; color:#5B6570; max-width:42ch; margin: 0 0 26px;
}
.stage-sub .accent{ text-decoration: underline; text-decoration-style: dashed; text-decoration-color: var(--teal); text-underline-offset:3px; }
.stage-sub .email-chip{
  font-family: var(--font-body); font-size:12px; background: var(--background);
  border:2px solid var(--heading); padding: 2px 8px; border-radius:2px;
}

/* ---------- CTA / result card ---------- */
.action-card{
  border: var(--border-w) solid var(--heading);
  background: var(--background);
  box-shadow: 6px 6px 0 var(--teal);
  border-radius: var(--radius);
  padding: 16px;
  max-width: 500px;
}
.action-card .spin-btn{
  width:100%; padding: 20px; font-size:16px;
}
.hint{ font-family: var(--font-body); font-size:12px; color:#5B6570; margin: 14px 0 0; }

.result-card{ display:none; }
.result-card.is-visible{ display:block; opacity:0; transform: translateY(16px); }
.result-card .tag{
  font-family: var(--font-body); font-size:11px; letter-spacing:.14em; color:#5B6570;
  display:block; margin-bottom:10px;
}
.result-card h3{
  font-family: var(--font-heading); text-transform:uppercase; font-weight:400;
  font-size: clamp(22px, 2.6vw, 30px); margin: 0 0 14px; line-height:1.05;
}
.result-card p{ font-size:13px; line-height:1.65; color:#20262B; margin: 0 0 20px; }
.result-card .btn-teal{ width:100%; padding:18px; font-size:15px; margin-bottom: 14px; }
.result-card .back-link{
  display:inline-block; font-family: var(--font-body); font-size:12px;
  border-bottom: 2px solid var(--heading);
}

/* ---------- Pixel dot decorations ---------- */
.dot-grid{
  position:absolute; display:grid; grid-template-columns: repeat(6, 4px);
  gap: 12px; pointer-events:none;
}
.dot-grid span{ width:4px; height:4px; background: var(--heading); }
.dot-grid span.on{ background: var(--teal); }
.dot-grid--tr{ top: 22px; right: clamp(20px, 4vw, 56px); }
.dot-grid--bl{ bottom: 10px; left: clamp(0px, 2vw, 20px); }

/* ---------- Footer ---------- */
.foot{
  border-top: 2px solid var(--heading);
  font-family: var(--font-body); font-size:12px; color:#5B6570;
  padding: 20px 0;
}
.foot .wrap{ display:flex; justify-content:space-between; flex-wrap:wrap; gap:10px; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior:auto; }
  *{ animation-duration:.001ms !important; animation-iteration-count:1 !important; transition-duration:.001ms !important; }
}

/* ---------- Responsive ---------- */
/* Tablet-width sizing is now handled by the JS measurement in wheel.js,
   which reads the actual column box — no separate override needed. */

@media (max-width: 768px){
  .nav-inner{ padding: 16px 20px; }
  .hero-grid{
    grid-template-columns: 1fr;
    min-height: auto;
    gap: 6px;
  }
  .content-col{ order:1; padding: 24px 0 0; text-align:center; }
  .kicker{ justify-content:center; }
  .headline-block{ margin-left:auto; margin-right:auto; }
  .stage-sub{ margin-left:auto; margin-right:auto; }
  .stage-note{ margin-left:auto; margin-right:auto; }
  .action-card{ margin: 0 auto; }
  .wheel-col{
    order:2; height:auto; min-height:0;
    display:flex; justify-content:center; padding: 26px 0 10px;
  }
  .wheel-rig{
    position:relative; top:auto; right:auto; transform:none;
    width: 78vw; max-width: 340px; min-width: 0;
  }
  .dot-grid{ display:none; }
}

@media (max-width: 380px){
  .logo .mark{ font-size:15px; }
  .btn{ font-size:12px; padding:10px 14px; }
}
