/* =============================================================
   THE PRICING ARENA — game-show theme
   Teal / Gold / Magenta on deep navy. Mobile-first (390px).
   ============================================================= */
:root {
  --teal: #0e7c7b;
  --teal-deep: #0a5c5b;
  --teal-bright: #19b3b1;
  --gold: #f5b301;
  --gold-dark: #c78d00;
  --gold-pale: #ffe9b8;
  --magenta: #d81e83;
  --magenta-deep: #a3125f;
  --navy: #0b1f3a;
  --navy-2: #10294a;
  --cream: #f7f9fc;
  --slate: #8892a6;
  --red: #e02020;
}

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

html, body { height: 100%; }

body {
  font-family: "Montserrat", -apple-system, sans-serif;
  color: var(--cream);
  background:
    radial-gradient(1200px 600px at 50% -100px, rgba(25, 179, 177, 0.25), transparent 60%),
    radial-gradient(900px 500px at 90% 110%, rgba(216, 30, 131, 0.18), transparent 60%),
    linear-gradient(180deg, var(--navy) 0%, #081729 100%);
  background-attachment: fixed;
  min-height: 100dvh;
  overflow-x: hidden;
}

/* =================== screens =================== */
.screen {
  display: none;
  min-height: 100dvh;
  padding: 64px 18px 48px; /* top clears the fixed mute button */
  max-width: 640px;
  margin: 0 auto;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.screen.show { display: flex; }
.screen.overlay {
  position: fixed;
  inset: 0;
  max-width: none;
  z-index: 40;
  background: rgba(6, 16, 30, 0.96);
  overflow-y: auto;
}

/* =================== marquee =================== */
.marquee-frame {
  border: 4px solid var(--gold);
  border-radius: 18px;
  padding: 22px 26px;
  margin: 26px 0 20px;
  background: linear-gradient(180deg, rgba(245, 179, 1, 0.10), rgba(216, 30, 131, 0.08));
  box-shadow: 0 0 40px rgba(245, 179, 1, 0.25), inset 0 0 30px rgba(0, 0, 0, 0.4);
}
.marquee-frame.small { padding: 14px 20px; }

.bulbs {
  display: flex;
  justify-content: center;
  gap: 9px;
  margin: 4px 0;
}
.bulbs span {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 8px var(--gold);
  animation: bulb 0.9s ease-in-out infinite;
}
.bulbs span:nth-child(3n)   { animation-delay: 0s; }
.bulbs span:nth-child(3n+1) { animation-delay: 0.3s; }
.bulbs span:nth-child(3n+2) { animation-delay: 0.6s; }
@keyframes bulb {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 1; }
}

.showcase-title {
  font-family: "Alfa Slab One", "Montserrat", serif;
  font-size: clamp(2.6rem, 11vw, 4.6rem);
  line-height: 1.02;
  letter-spacing: 2px;
  margin: 10px 0;
  color: var(--gold);
  text-shadow:
    0 3px 0 var(--gold-dark),
    0 6px 0 rgba(0,0,0,0.35),
    0 0 34px rgba(245, 179, 1, 0.5);
}
.showcase-title.sm { font-size: clamp(1.8rem, 7vw, 2.8rem); }

.tagline {
  font-size: 1.05rem;
  line-height: 1.5;
  margin-bottom: 20px;
  color: var(--cream);
}
.tagline strong { color: var(--gold); }

.title-rules {
  list-style: none;
  text-align: left;
  margin: 0 0 26px;
  display: grid;
  gap: 10px;
  font-weight: 600;
  font-size: 0.98rem;
}
.title-rules strong { color: var(--teal-bright); }

.fineprint {
  margin-top: 26px;
  font-size: 0.8rem;
  color: var(--slate);
}
.fineprint a { color: var(--teal-bright); }

/* =================== buttons =================== */
.btn-mega {
  font-family: "Montserrat", sans-serif;
  font-weight: 900;
  font-size: 1.3rem;
  letter-spacing: 1px;
  color: var(--navy);
  background: linear-gradient(180deg, #ffd34d, var(--gold) 55%, var(--gold-dark));
  border: none;
  border-radius: 14px;
  padding: 18px 40px;
  min-height: 60px;
  width: 100%;
  max-width: 380px;
  cursor: pointer;
  box-shadow: 0 6px 0 #8a6200, 0 12px 28px rgba(0,0,0,0.45);
  transition: transform 0.08s ease, box-shadow 0.08s ease, filter 0.15s;
}
.btn-mega:active:not(:disabled) {
  transform: translateY(4px);
  box-shadow: 0 2px 0 #8a6200, 0 6px 14px rgba(0,0,0,0.45);
}
.btn-mega:disabled {
  filter: grayscale(0.7) brightness(0.7);
  cursor: not-allowed;
  box-shadow: 0 6px 0 #444, 0 12px 28px rgba(0,0,0,0.3);
}

#btn-mute {
  position: fixed;
  top: 14px; right: 14px;
  z-index: 60;
  width: 46px; height: 46px;
  border-radius: 50%;
  border: 2px solid var(--teal-bright);
  background: rgba(11, 31, 58, 0.85);
  font-size: 1.2rem;
  cursor: pointer;
  color: var(--cream);
}

/* =================== round screen =================== */
.round-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 10px;
  margin-bottom: 16px;
}
.round-count, .score-chip {
  font-weight: 800;
  font-size: 0.95rem;
  background: var(--navy-2);
  border: 2px solid var(--teal);
  border-radius: 999px;
  padding: 8px 14px;
  white-space: nowrap;
}
.score-chip { border-color: var(--gold); color: var(--gold); }

.marquee-mini {
  flex: 1;
  border: 3px solid var(--magenta);
  border-radius: 12px;
  padding: 6px 8px 8px;
  background: rgba(216, 30, 131, 0.10);
  box-shadow: 0 0 22px rgba(216, 30, 131, 0.30);
  min-width: 0;
}
.marquee-mini h2 {
  font-family: "Alfa Slab One", serif;
  font-size: clamp(1rem, 4.5vw, 1.5rem);
  letter-spacing: 4px;
  color: var(--magenta);
  text-shadow: 0 0 16px rgba(216, 30, 131, 0.6);
}
.marquee-mini .bulbs { gap: 6px; margin: 3px 0; }
.marquee-mini .bulbs span { width: 5px; height: 5px; background: var(--magenta); box-shadow: 0 0 6px var(--magenta); }

/* property card */
.prop-card {
  width: 100%;
  background: linear-gradient(180deg, var(--navy-2), #0c2240);
  border: 3px solid var(--teal-bright);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 10px 34px rgba(0,0,0,0.5), 0 0 24px rgba(25,179,177,0.18);
  margin-bottom: 18px;
  text-align: left;
}
.prop-card.pop-in { animation: popin 0.35s cubic-bezier(0.34, 1.56, 0.64, 1); }
@keyframes popin {
  from { transform: scale(0.92); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}

.prop-art {
  background: linear-gradient(135deg, var(--teal-deep), var(--teal) 60%, var(--teal-bright));
  border-bottom: 3px solid var(--gold);
  display: flex;
  justify-content: center;
  padding: 16px 0 10px;
}
.prop-svg { width: min(52vw, 220px); height: auto; aspect-ratio: 3/2; }

.prop-body { padding: 16px 18px 18px; }
.prop-body h3 { font-size: 1.2rem; font-weight: 800; color: var(--gold-pale); }
.prop-area { color: var(--teal-bright); font-weight: 600; font-size: 0.9rem; margin: 4px 0 10px; }

.prop-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}
.prop-stats span {
  background: rgba(25, 179, 177, 0.14);
  border: 1px solid var(--teal);
  border-radius: 8px;
  padding: 5px 10px;
  font-size: 0.85rem;
  font-weight: 700;
}

.prop-features {
  list-style: none;
  display: grid;
  gap: 5px;
  font-size: 0.9rem;
  color: var(--cream);
}
.prop-features li::before { content: "★ "; color: var(--gold); }

/* guess zone */
.guess-zone { width: 100%; }
.guess-label {
  display: block;
  font-weight: 800;
  letter-spacing: 2px;
  font-size: 1rem;
  margin-bottom: 10px;
}
.guess-label .accent { color: var(--magenta); }

.guess-wrap {
  display: flex;
  align-items: center;
  background: #060f1d;
  border: 3px solid var(--gold);
  border-radius: 14px;
  padding: 6px 16px;
  box-shadow: inset 0 0 18px rgba(0,0,0,0.8), 0 0 24px rgba(245,179,1,0.18);
  margin-bottom: 12px;
}
.guess-dollar {
  font-family: "Alfa Slab One", serif;
  font-size: 2rem;
  color: var(--gold);
  margin-right: 8px;
}
#guess-input {
  flex: 1;
  min-width: 0;
  background: transparent;
  border: none;
  outline: none;
  color: var(--gold);
  font-family: "Alfa Slab One", "Montserrat", serif;
  font-size: clamp(1.7rem, 8vw, 2.6rem);
  letter-spacing: 2px;
  text-align: right;
  caret-color: var(--gold);
}
#guess-input::placeholder { color: rgba(245, 179, 1, 0.25); }

.nudges {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}
.nudge {
  min-height: 48px;
  border-radius: 10px;
  border: 2px solid var(--teal-bright);
  background: rgba(25, 179, 177, 0.12);
  color: var(--cream);
  font-weight: 800;
  font-size: 0.9rem;
  cursor: pointer;
}
.nudge:active { background: rgba(25, 179, 177, 0.3); }

/* =================== reveal =================== */
.reveal-inner {
  max-width: 640px;
  margin: 0 auto;
  width: 100%;
  padding-top: 8vh;
}
.reveal-eyebrow {
  letter-spacing: 3px;
  font-weight: 800;
  color: var(--teal-bright);
  font-size: 0.9rem;
}
.reveal-price {
  font-family: "Alfa Slab One", serif;
  font-size: clamp(2.4rem, 11vw, 4.2rem);
  color: var(--gold);
  margin: 14px 0 10px;
  text-shadow: 0 4px 0 var(--gold-dark), 0 0 36px rgba(245,179,1,0.45);
}
.reveal-price.pulsing { animation: pulse 0.5s ease-in-out infinite alternate; }
@keyframes pulse {
  from { transform: scale(1); opacity: 0.75; }
  to   { transform: scale(1.06); opacity: 1; }
}

.skip-hint { color: var(--slate); font-size: 0.8rem; margin-top: 16px; }

.verdict { margin: 8px 0 4px; }
.verdict.hidden, .breakdown.hidden { display: none; }
.verdict-label {
  font-family: "Alfa Slab One", serif;
  font-size: clamp(1.6rem, 7vw, 2.4rem);
  letter-spacing: 2px;
}
.verdict.mood-win   .verdict-label { color: var(--gold);        text-shadow: 0 0 26px rgba(245,179,1,0.6); }
.verdict.mood-great .verdict-label { color: var(--teal-bright); }
.verdict.mood-good  .verdict-label { color: var(--teal-bright); }
.verdict.mood-meh   .verdict-label { color: var(--magenta); }
.verdict.mood-yikes .verdict-label { color: var(--red); text-shadow: 0 0 22px rgba(224,32,32,0.5); }
.verdict-sub { color: var(--cream); font-weight: 600; margin-top: 6px; }
.verdict-pts {
  display: inline-block;
  margin-top: 10px;
  font-weight: 900;
  font-size: 1.1rem;
  color: var(--navy);
  background: var(--gold);
  border-radius: 999px;
  padding: 6px 18px;
  box-shadow: 0 3px 0 var(--gold-dark);
}

/* YIKES stamp */
#stamp-yikes {
  position: fixed;
  top: 34%;
  left: 50%;
  z-index: 55;
  font-family: "Alfa Slab One", serif;
  font-size: clamp(3rem, 16vw, 5.5rem);
  color: var(--red);
  border: 6px double var(--red);
  border-radius: 10px;
  padding: 4px 26px;
  letter-spacing: 6px;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -50%) rotate(-12deg) scale(3);
  text-shadow: 0 0 2px var(--red);
  box-shadow: inset 0 0 14px rgba(224,32,32,0.4);
  background: rgba(6, 16, 30, 0.25);
}
#stamp-yikes.slam { animation: slam 0.4s cubic-bezier(0.22, 1.4, 0.36, 1) 0.15s forwards; }
#stamp-yikes.fadeout { opacity: 0 !important; transition: opacity 0.6s ease-out; }
@keyframes slam {
  0%   { opacity: 0; transform: translate(-50%, -50%) rotate(-12deg) scale(3); }
  60%  { opacity: 1; transform: translate(-50%, -50%) rotate(-12deg) scale(0.95); }
  80%  { transform: translate(-50%, -50%) rotate(-12deg) scale(1.05); }
  100% { opacity: 1; transform: translate(-50%, -50%) rotate(-12deg) scale(1); }
}

/* breakdown */
.breakdown { margin-top: 18px; text-align: left; }
.breakdown.slide-in { animation: slideup 0.45s ease-out; }
@keyframes slideup {
  from { transform: translateY(40px); opacity: 0; }
  to   { transform: translateY(0); opacity: 1; }
}
.breakdown h4 {
  text-align: center;
  letter-spacing: 2px;
  color: var(--gold-pale);
  margin-bottom: 12px;
}

.bd-trackwrap {
  background: var(--navy-2);
  border: 2px solid var(--teal);
  border-radius: 12px;
  padding: 12px;
  margin-bottom: 12px;
}
#bd-track {
  display: flex;
  height: 34px;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(0,0,0,0.4);
}
.bd-seg {
  height: 100%;
  transition: width 0.5s ease-out;
  flex-shrink: 0;
}
.bd-seg.base { background: var(--teal-deep) !important; }
.bd-seg.neg {
  background-image: repeating-linear-gradient(
    45deg,
    rgba(136, 146, 166, 0.55) 0 6px,
    rgba(136, 146, 166, 0.15) 6px 12px
  ) !important;
  border-left: 2px dashed var(--slate);
  border-right: 2px dashed var(--slate);
}
.bd-total-row {
  margin-top: 10px;
  font-weight: 800;
  font-size: 0.85rem;
  letter-spacing: 1px;
  color: var(--slate);
  text-align: right;
}
#bd-total { color: var(--gold); font-size: 1.05rem; margin-left: 6px; }

#bd-legend { display: grid; gap: 7px; margin-bottom: 18px; }
.bd-row {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.92rem;
  font-weight: 600;
  opacity: 0;
  transform: translateX(-14px);
  transition: opacity 0.3s, transform 0.3s;
}
.bd-row.in { opacity: 1; transform: translateX(0); }
.bd-dot { width: 12px; height: 12px; border-radius: 3px; flex-shrink: 0; }
.bd-label { flex: 1; }
.bd-amt { font-weight: 800; color: var(--teal-bright); }
.bd-amt.neg { color: var(--slate); }

/* =================== wheel overlay =================== */
#overlay-wheel {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: rgba(6, 16, 30, 0.94);
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
}
#overlay-wheel.show { display: flex; }
#wheel-svg {
  width: min(80vw, 420px);
  height: min(80vw, 420px);
  filter: drop-shadow(0 0 34px rgba(245, 179, 1, 0.35));
}
.wheel-pointer {
  position: absolute;
  top: calc(50% - min(40vw, 210px) - 26px);
  width: 0; height: 0;
  border-left: 16px solid transparent;
  border-right: 16px solid transparent;
  border-top: 28px solid var(--gold);
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.6));
}
.wheel-caption {
  font-family: "Alfa Slab One", serif;
  letter-spacing: 3px;
  color: var(--gold);
  font-size: 1.1rem;
}

/* =================== fx canvas =================== */
#fx-canvas {
  position: fixed;
  inset: 0;
  z-index: 70;
  pointer-events: none;
  display: none;
}

/* =================== gate =================== */
.gate-score {
  font-family: "Alfa Slab One", serif;
  font-size: 2.4rem;
  color: var(--gold);
  margin: 6px 0 12px;
}
.gate-score small { font-size: 1rem; color: var(--slate); font-family: "Montserrat", sans-serif; }
.gate-copy { line-height: 1.55; margin-bottom: 20px; }
.gate-copy strong { color: var(--gold); }

#gate-form { width: 100%; max-width: 380px; display: grid; gap: 12px; }
#gate-form input[type="text"],
#gate-form input[type="email"] {
  width: 100%;
  min-height: 54px;
  border-radius: 12px;
  border: 2px solid var(--teal);
  background: var(--navy-2);
  color: var(--cream);
  font-family: "Montserrat", sans-serif;
  font-size: 1rem;
  font-weight: 600;
  padding: 0 16px;
  outline: none;
}
#gate-form input:focus { border-color: var(--gold); }
#gate-company { position: absolute; left: -5000px; opacity: 0; height: 0; }
.gate-fine { font-size: 0.78rem; color: var(--slate); }

/* =================== grade =================== */
.grade-eyebrow {
  margin-top: 30px;
  letter-spacing: 3px;
  font-weight: 800;
  color: var(--teal-bright);
}
.grade-char { width: min(58vw, 240px); margin: 18px 0 10px; animation: popin 0.5s cubic-bezier(0.34, 1.56, 0.64, 1); }
.grade-char svg { width: 100%; height: auto; filter: drop-shadow(0 10px 30px rgba(0,0,0,0.5)); }
.grade-name {
  font-family: "Alfa Slab One", serif;
  font-size: clamp(1.5rem, 6.5vw, 2.3rem);
  color: var(--gold);
  letter-spacing: 1px;
  margin-bottom: 10px;
  text-shadow: 0 3px 0 var(--gold-dark);
}
.grade-note { line-height: 1.55; max-width: 420px; margin-bottom: 16px; }
.grade-score {
  font-family: "Alfa Slab One", serif;
  font-size: 1.7rem;
  color: var(--cream);
  margin-bottom: 12px;
}
.grade-score small { font-size: 0.9rem; color: var(--slate); font-family: "Montserrat", sans-serif; }

.dots { display: flex; gap: 8px; margin-bottom: 24px; }
.dot {
  width: 16px; height: 16px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.25);
}
.dot.mood-win   { background: var(--gold);        box-shadow: 0 0 10px var(--gold); }
.dot.mood-great { background: var(--teal-bright); }
.dot.mood-good  { background: var(--teal); }
.dot.mood-meh   { background: var(--magenta); }
.dot.mood-yikes { background: var(--red); }

/* =================== desktop =================== */
@media (min-width: 700px) {
  .screen { padding-top: 40px; }
  .prop-card { display: grid; grid-template-columns: 240px 1fr; }
  .prop-art { border-bottom: none; border-right: 3px solid var(--gold); align-items: center; }
  .prop-svg { width: 190px; }
}

/* =================== reduced motion =================== */
@media (prefers-reduced-motion: reduce) {
  .bulbs span, .reveal-price.pulsing, .prop-card.pop-in,
  .breakdown.slide-in, .grade-char { animation: none !important; }
  .bd-seg, .bd-row { transition: none !important; }
}
