/* Prime Bazar Spin & Win — campaign stage (mobile-first, projector-friendly). */

@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('../fonts/manrope-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('../fonts/manrope-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --pb-emerald: #008534;
  --pb-emerald-600: #00732d;
  --pb-emerald-700: #005f25;
  --pb-emerald-bright: #19b35a;
  --pb-gold: #c9a227;
  --pb-gold-light: #e5c158;
  --pb-gold-pale: #f8e39a;
  --pb-gold-ink: #8a6d12;
  --pb-night: #0c1d15;
  --pb-deep: #07130d;
  --pb-ivory: #fffdf6;
  --pb-cream: #f6efda;
  --pb-ink: #141a17;
  --pb-graphite: #525a56;
  --pb-line: #ddd6c2;
  --pb-danger: #b3261e;
  --on-dark: #f6f2e6;
  --on-dark-muted: rgba(246, 242, 230, .74);
  --gold-text: linear-gradient(180deg, #fff6d6 0%, #f3d77e 38%, #d4ad35 70%, #a7851c 100%);
  --ease: cubic-bezier(.2, .8, .2, 1);
  --radius: 22px;
  --font: 'Manrope', system-ui, -apple-system, 'Segoe UI', Roboto, 'Noto Sans', sans-serif;
  --mono: ui-monospace, 'SFMono-Regular', Menlo, Consolas, 'Roboto Mono', monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  font-family: var(--font);
  line-height: 1.5;
  background: var(--pb-deep);
  color: var(--on-dark);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}
body.result-open { overflow: hidden; }
img, svg { display: block; max-width: 100%; }
button, input { font: inherit; }
a { color: var(--pb-gold-light); }
[hidden] { display: none !important; }
h1, h2, p { margin: 0; }

/* ── Backdrop ─────────────────────────────────────────────────────────── */
.backdrop {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  background:
    radial-gradient(1100px 720px at 12% -12%, rgba(0, 133, 52, .55), transparent 62%),
    radial-gradient(900px 700px at 112% 28%, rgba(201, 162, 39, .20), transparent 60%),
    radial-gradient(900px 640px at 50% 118%, rgba(0, 95, 37, .62), transparent 62%),
    var(--pb-deep);
}
.orb {
  position: absolute;
  border-radius: 50%;
  animation: float 16s ease-in-out infinite alternate;
  will-change: transform;
}
.orb-a { width: 46vmax; height: 46vmax; left: -14vmax; top: 28vh; background: radial-gradient(circle, rgba(25, 179, 90, .18), transparent 65%); }
.orb-b { width: 40vmax; height: 40vmax; right: -12vmax; top: -10vh; background: radial-gradient(circle, rgba(229, 193, 88, .16), transparent 65%); animation-duration: 21s; }
.sparkles {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(rgba(248, 227, 154, .38) 1px, transparent 1.6px) 0 0 / 48px 48px,
    radial-gradient(rgba(255, 255, 255, .16) 1px, transparent 1.6px) 24px 24px / 48px 48px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 10%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 10%, transparent 75%);
  opacity: .55;
}
@keyframes float { to { transform: translate3d(6vmax, -4vmax, 0) scale(1.08); } }

/* ── Top bar ──────────────────────────────────────────────────────────── */
.topbar {
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 1280px;
  margin: 0 auto;
  padding: max(14px, env(safe-area-inset-top)) 16px 6px;
}
.brand {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 14px;
  background: var(--pb-ivory);
  box-shadow: 0 8px 24px -10px rgba(0, 0, 0, .6), inset 0 0 0 1px rgba(201, 162, 39, .45);
}
.brand img { height: 36px; width: auto; }
.event-badge {
  margin-left: auto;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(229, 193, 88, .55);
  color: var(--pb-gold-pale);
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 48vw;
}
@media (max-width: 420px) {
  .event-badge { font-size: .62rem; letter-spacing: .07em; padding: 6px 10px; }
  .brand img { height: 32px; }
}
.icon-btn {
  flex: none;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .16);
  background: rgba(255, 255, 255, .07);
  color: var(--on-dark);
  cursor: pointer;
}
.icon-btn svg { width: 22px; height: 22px; fill: currentColor; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon-btn:focus-visible { outline: 3px solid var(--pb-gold-pale); outline-offset: 2px; }
#soundToggle[aria-pressed='true'] .icon-off, #soundToggle[aria-pressed='false'] .icon-on { display: none; }
.event-badge[hidden] + #soundToggle { margin-left: auto; }

/* ── Layout ───────────────────────────────────────────────────────────── */
.game {
  max-width: 1280px;
  margin: 0 auto;
  padding: 10px 16px 28px;
  display: grid;
  grid-template-areas: 'hero' 'wheel' 'panel' 'perks';
  gap: 22px;
}
.hero { grid-area: hero; text-align: center; display: grid; gap: 10px; justify-items: center; }
.wheel-area { grid-area: wheel; display: grid; place-items: center; padding-top: 10px; scroll-margin-top: 12px; }
.panel { grid-area: panel; width: 100%; max-width: 480px; justify-self: center; }
.perks { grid-area: perks; }

/* ── Hero ─────────────────────────────────────────────────────────────── */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(229, 193, 88, .28);
  color: var(--pb-gold-pale);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--pb-emerald-bright);
  box-shadow: 0 0 0 0 rgba(25, 179, 90, .7);
  animation: live 1.8s infinite;
}
.eyebrow:not([data-status='live']) .live-dot { background: var(--pb-gold-light); animation: none; }
@keyframes live { 70% { box-shadow: 0 0 0 9px rgba(25, 179, 90, 0); } 100% { box-shadow: 0 0 0 0 rgba(25, 179, 90, 0); } }
.headline {
  font-size: clamp(3rem, 13vw, 5.8rem);
  font-weight: 800;
  line-height: .95;
  letter-spacing: -.035em;
  background: var(--gold-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 8px 28px rgba(201, 162, 39, .32));
  padding-bottom: .06em;
}
.subheadline { max-width: 34ch; color: var(--on-dark-muted); font-size: clamp(1rem, 3.8vw, 1.22rem); font-weight: 500; }
.upto {
  padding: 8px 16px;
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(0, 133, 52, .55), rgba(0, 95, 37, .55));
  border: 1px solid rgba(25, 179, 90, .45);
  font-weight: 700;
  font-size: 1rem;
}
.upto strong { color: var(--pb-gold-pale); font-weight: 800; }

/* ── Wheel ────────────────────────────────────────────────────────────── */
#wheel { width: min(88vw, 480px); }
.wheel { position: relative; aspect-ratio: 1; user-select: none; -webkit-user-select: none; }
.wheel-glow {
  position: absolute;
  inset: -9%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(229, 193, 88, .38) 0%, rgba(201, 162, 39, .12) 45%, transparent 68%);
  transition: opacity .4s;
  opacity: .75;
}
.wheel.is-spinning .wheel-glow, .wheel.has-winner .wheel-glow { opacity: 1; animation: glow 1.2s ease-in-out infinite alternate; }
@keyframes glow { to { transform: scale(1.05); } }
.wheel-rim, .wheel-disc { position: absolute; inset: 0; width: 100%; height: 100%; }
.wheel-rim { filter: drop-shadow(0 22px 40px rgba(0, 0, 0, .55)); }
.wheel-disc { transform-origin: 50% 50%; will-change: transform; }
.wheel-disc svg { width: 100%; height: 100%; }
.bulb { fill: #fff4c7; }
.bulb-a { animation: twinkle 1.1s ease-in-out infinite alternate; }
.bulb-b { animation: twinkle 1.1s ease-in-out -.55s infinite alternate; }
.wheel.is-spinning .bulb-a, .wheel.is-spinning .bulb-b { animation-duration: .22s; }
@keyframes twinkle { from { opacity: .25; } to { opacity: 1; } }
.seg-amount { font-family: var(--font); font-weight: 800; letter-spacing: -.02em; }
.seg-off { font-family: var(--font); font-weight: 800; letter-spacing: .18em; }
.seg-win { fill: rgba(255, 255, 255, .34); animation: segwin .6s ease-in-out infinite alternate; }
@keyframes segwin { from { fill-opacity: .15; } to { fill-opacity: 1; } }
.wheel-pointer {
  position: absolute;
  top: -4.5%;
  left: 50%;
  width: 12.5%;
  transform: translateX(-50%);
  transform-origin: 50% 30%;
  z-index: 3;
}
.wheel-hub {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  width: 23%;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: .38em solid transparent;
  background:
    radial-gradient(circle at 35% 30%, #1f4a33, #07140d 72%) padding-box,
    linear-gradient(135deg, #fff1b8, #c9a227 45%, #8a6d12 80%, #e5c158) border-box;
  box-shadow: 0 10px 26px rgba(0, 0, 0, .55), inset 0 2px 6px rgba(255, 255, 255, .15);
  display: grid;
  place-items: center;
  color: var(--pb-gold-pale);
  font-weight: 800;
  font-size: clamp(.9rem, 4.2vw, 1.5rem);
  letter-spacing: .08em;
  cursor: default;
  padding: 0;
}
.wheel.is-ready .wheel-hub { cursor: pointer; animation: hubpulse 1.6s ease-in-out infinite; }
.wheel.is-ready .wheel-hub:hover { filter: brightness(1.12); }
.wheel-hub:focus-visible { outline: 3px solid var(--pb-gold-pale); outline-offset: 4px; }
@keyframes hubpulse {
  0%, 100% { box-shadow: 0 10px 26px rgba(0, 0, 0, .55), 0 0 0 0 rgba(248, 227, 154, .55); }
  50% { box-shadow: 0 10px 26px rgba(0, 0, 0, .55), 0 0 0 14px rgba(248, 227, 154, 0); }
}

/* ── Cards, forms, buttons ────────────────────────────────────────────── */
.card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  padding: 26px 20px 22px;
  background: linear-gradient(180deg, var(--pb-ivory), var(--pb-cream));
  color: var(--pb-ink);
  box-shadow: 0 30px 60px -22px rgba(0, 0, 0, .75), 0 0 0 1px rgba(229, 193, 88, .4);
}
.card::before {
  content: '';
  position: absolute;
  inset: 0 0 auto;
  height: 5px;
  background: linear-gradient(90deg, var(--pb-emerald), var(--pb-gold-light), var(--pb-emerald));
}
.card.enter { animation: rise .45s var(--ease) both; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
.card-title { font-size: 1.55rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.2; }
.card-sub { margin-top: 6px; color: var(--pb-graphite); font-size: 1rem; }
.hello { color: var(--pb-emerald-700); font-weight: 700; margin-bottom: 4px; }
.gold-text { color: var(--pb-gold-ink); }
form { margin-top: 18px; display: grid; gap: 14px; }
.field { display: grid; gap: 6px; }
.field label { font-weight: 700; font-size: .92rem; color: var(--pb-ink); }
.field input {
  width: 100%;
  height: 56px;
  padding: 0 16px;
  border-radius: 14px;
  border: 1.5px solid var(--pb-line);
  background: #fff;
  color: var(--pb-ink);
  font-size: 1.12rem;
  font-weight: 600;
  transition: border-color .15s, box-shadow .15s;
}
.field input::placeholder { color: #a7aba5; font-weight: 500; }
.field input:focus { outline: none; border-color: var(--pb-emerald); box-shadow: 0 0 0 4px rgba(0, 133, 52, .16); }
.field.has-error input { border-color: var(--pb-danger); }
.phone { display: flex; }
.phone-cc {
  display: grid;
  place-items: center;
  padding: 0 14px;
  border: 1.5px solid var(--pb-line);
  border-right: 0;
  border-radius: 14px 0 0 14px;
  background: #f3efe2;
  font-weight: 800;
  color: var(--pb-graphite);
}
.phone input { border-radius: 0 14px 14px 0; letter-spacing: .04em; }
.field-error, .form-error { color: var(--pb-danger); font-size: .88rem; font-weight: 600; min-height: 0; }
.field-error:empty, .form-error:empty { display: none; }
.form-error { text-align: center; }
.consent {
  position: relative;
  display: grid;
  grid-template-columns: 26px 1fr;
  gap: 10px;
  align-items: start;
  font-size: .86rem;
  color: var(--pb-graphite);
  cursor: pointer;
  line-height: 1.45;
}
.consent input { position: absolute; opacity: 0; width: 26px; height: 26px; margin: 0; cursor: pointer; }
.consent-box {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  border: 1.5px solid #b9b19a;
  background: #fff;
  display: grid;
  place-items: center;
  transition: background .15s, border-color .15s;
}
.consent input:checked + .consent-box { background: var(--pb-emerald); border-color: var(--pb-emerald); }
.consent input:checked + .consent-box::after { content: ''; width: 7px; height: 13px; border: solid #fff; border-width: 0 3px 3px 0; transform: translateY(-2px) rotate(45deg); }
.consent input:focus-visible + .consent-box { outline: 3px solid rgba(0, 133, 52, .4); outline-offset: 2px; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.fine { margin-top: 12px; font-size: .8rem; color: var(--pb-graphite); text-align: center; }

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 56px;
  padding: 0 22px;
  border: 0;
  border-radius: 16px;
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: .03em;
  text-decoration: none;
  cursor: pointer;
  transition: transform .15s var(--ease), box-shadow .2s, filter .2s;
  overflow: hidden;
}
.btn svg { width: 22px; height: 22px; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.btn:active { transform: translateY(1px) scale(.99); }
.btn:focus-visible { outline: 3px solid var(--pb-gold-pale); outline-offset: 3px; }
.btn:disabled { cursor: default; filter: saturate(.7) brightness(.95); }
.btn-xl { width: 100%; min-height: 64px; font-size: 1.18rem; border-radius: 18px; }
.btn-gold {
  background: linear-gradient(180deg, #f6dd8c 0%, #deb746 48%, #c9a227 100%);
  color: #1e1603;
  box-shadow: 0 14px 28px -12px rgba(201, 162, 39, .85), inset 0 1px 0 rgba(255, 255, 255, .6), inset 0 -3px 0 rgba(0, 0, 0, .12);
}
.btn-gold:hover { filter: brightness(1.05); }
.btn-emerald {
  background: linear-gradient(180deg, #16ad52 0%, #008534 55%, #00732d 100%);
  color: #fff;
  box-shadow: 0 14px 28px -12px rgba(0, 133, 52, .9), inset 0 1px 0 rgba(255, 255, 255, .28), inset 0 -3px 0 rgba(0, 0, 0, .18);
}
.btn-emerald:hover { filter: brightness(1.07); }
.btn-outline { margin-top: 18px; width: 100%; background: transparent; color: var(--pb-emerald-700); box-shadow: inset 0 0 0 1.5px var(--pb-emerald); }
.btn-spin::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, transparent 30%, rgba(255, 255, 255, .55) 50%, transparent 70%);
  transform: translateX(-100%);
  animation: sweep 2.6s ease-in-out infinite;
}
@keyframes sweep { 60%, 100% { transform: translateX(100%); } }
.spinner {
  position: absolute;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 3px solid currentColor;
  border-right-color: transparent;
  opacity: 0;
  animation: spin .8s linear infinite;
}
.btn.is-busy .btn-label { opacity: 0; }
.btn.is-busy .spinner { opacity: 1; }
.btn.is-busy::after { display: none; }
@keyframes spin { to { transform: rotate(360deg); } }
.btn.is-done { background: linear-gradient(180deg, #16ad52, #008534); color: #fff; }

.skeleton { height: 18px; border-radius: 8px; margin: 12px 0; background: linear-gradient(90deg, #eee7d3 25%, #f8f3e5 50%, #eee7d3 75%); background-size: 200% 100%; animation: shimmer 1.3s linear infinite; }
.skeleton-title { height: 28px; width: 60%; }
.skeleton-btn { height: 60px; border-radius: 16px; margin-top: 22px; }
@keyframes shimmer { to { background-position: -200% 0; } }

.closed-icon { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: rgba(201, 162, 39, .14); margin-bottom: 12px; }
.closed-icon svg { width: 30px; height: 30px; stroke: var(--pb-gold-ink); stroke-width: 2; stroke-linecap: round; }
.countdown { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 18px; }
.countdown div { border-radius: 14px; background: var(--pb-night); color: var(--pb-gold-pale); text-align: center; padding: 10px 4px; }
.countdown strong { display: block; font-size: 1.9rem; font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.1; }
.countdown span { font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: rgba(246, 242, 230, .7); }

/* ── Perks + footer ───────────────────────────────────────────────────── */
.perks { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 10px; }
.perks li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .1);
  color: var(--on-dark-muted);
  font-size: .85rem;
  font-weight: 600;
}
.perks svg { width: 18px; height: 18px; fill: none; stroke: var(--pb-gold-light); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.footer { display: flex; justify-content: center; gap: 14px; padding: 8px 16px max(22px, env(safe-area-inset-bottom)); font-size: .82rem; color: rgba(246, 242, 230, .55); }
.footer a { color: rgba(248, 227, 154, .85); text-decoration: none; }

/* ── Result screen ────────────────────────────────────────────────────── */
.result {
  position: fixed;
  inset: 0;
  z-index: 50;
  overflow-y: auto;
  overscroll-behavior: contain;
  display: grid;
  justify-items: center;
  align-items: start;
  padding: max(28px, env(safe-area-inset-top)) 16px max(28px, env(safe-area-inset-bottom));
  background:
    radial-gradient(900px 560px at 50% 12%, rgba(201, 162, 39, .26), transparent 62%),
    radial-gradient(900px 600px at 50% 112%, rgba(0, 133, 52, .5), transparent 62%),
    #050e09;
  opacity: 0;
  transition: opacity .3s ease;
}
.result.is-open { opacity: 1; }
.result-rays {
  position: absolute;
  left: 50%;
  top: 150px;
  width: 1100px;
  height: 1100px;
  margin: -550px 0 0 -550px;
  background: repeating-conic-gradient(from 0deg, rgba(229, 193, 88, .11) 0deg 9deg, transparent 9deg 18deg);
  -webkit-mask-image: radial-gradient(circle, #000 0%, transparent 55%);
  mask-image: radial-gradient(circle, #000 0%, transparent 55%);
  animation: rays 50s linear infinite;
  pointer-events: none;
}
@keyframes rays { to { transform: rotate(360deg); } }
.result-close { position: fixed; top: max(14px, env(safe-area-inset-top)); right: 14px; z-index: 2; }
.result-close svg { fill: none; }
.result-inner {
  position: relative;
  width: 100%;
  max-width: 500px;
  display: grid;
  gap: 18px;
  text-align: center;
  transform: translateY(26px) scale(.97);
  transition: transform .5s var(--ease);
}
.result.is-open .result-inner { transform: none; }
.result-kicker { font-size: 1.15rem; font-weight: 700; color: var(--pb-gold-pale); padding-right: 36px; padding-left: 36px; }
.result-title { display: grid; gap: 2px; }
.result-you-won { font-size: .9rem; font-weight: 800; letter-spacing: .32em; text-transform: uppercase; color: var(--on-dark); }
.result-amount {
  font-size: clamp(3.4rem, 17vw, 6.4rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -.035em;
  background: var(--gold-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 10px 30px rgba(201, 162, 39, .45));
  padding-bottom: .05em;
}
.result.celebrate.is-open .result-amount { animation: pop .8s var(--ease) both .1s; }
@keyframes pop { 0% { transform: scale(.4); opacity: 0; } 60% { transform: scale(1.08); opacity: 1; } 100% { transform: scale(1); } }

.ticket {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  padding: 20px 20px 18px;
  background: linear-gradient(180deg, #fffdf5, #f5edd6);
  color: var(--pb-ink);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .8), 0 0 0 1.5px rgba(229, 193, 88, .8);
}
.ticket::before, .ticket::after {
  content: '';
  position: absolute;
  top: calc(100% - 78px);
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #060f0a;
  box-shadow: inset 0 0 0 1.5px rgba(229, 193, 88, .8);
}
.ticket::before { left: -13px; }
.ticket::after { right: -13px; }
.ticket-label { font-size: .76rem; font-weight: 800; letter-spacing: .2em; text-transform: uppercase; color: var(--pb-emerald-700); }
.ticket-code {
  margin: 12px 0 18px;
  padding: 14px 10px;
  border: 2px dashed var(--pb-gold);
  border-radius: 14px;
  background: #fff;
  font-family: var(--mono);
  font-size: clamp(1.6rem, 8.2vw, 2.4rem);
  font-weight: 800;
  letter-spacing: .1em;
  line-height: 1.2;
  color: var(--pb-night);
  word-break: break-all;
  user-select: all;
  -webkit-user-select: all;
  cursor: copy;
}
.ticket-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding-top: 16px;
  border-top: 2px dashed rgba(138, 109, 18, .35);
}
.ticket-meta div { display: grid; gap: 2px; }
.ticket-meta span { font-size: .74rem; text-transform: uppercase; letter-spacing: .1em; font-weight: 700; color: var(--pb-graphite); }
.ticket-meta strong { font-size: 1.05rem; font-weight: 800; }
.ticket-shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .85) 50%, transparent 65%);
  transform: translateX(-120%);
  pointer-events: none;
}
.result.is-open .ticket-shine { animation: shine 1.3s ease .55s both; }
@keyframes shine { to { transform: translateX(120%); } }
.result-actions { display: grid; gap: 12px; }
.terms {
  text-align: left;
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .1);
  color: var(--on-dark-muted);
  font-size: .84rem;
}
.terms-title { font-weight: 800; color: var(--on-dark); margin-bottom: 4px; font-size: .8rem; text-transform: uppercase; letter-spacing: .12em; }
.terms ul { margin: 0; padding-left: 1.1em; display: grid; gap: 4px; }
.result-fine { color: rgba(246, 242, 230, .6); margin-top: 0; }

/* ── Toast, confetti, utilities ───────────────────────────────────────── */
.toast {
  position: fixed;
  left: 50%;
  bottom: max(20px, env(safe-area-inset-bottom));
  z-index: 80;
  max-width: calc(100vw - 32px);
  padding: 14px 18px;
  border-radius: 14px;
  background: #0f261a;
  border: 1px solid rgba(229, 193, 88, .6);
  color: var(--on-dark);
  font-weight: 600;
  font-size: .95rem;
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, .7);
  transform: translate(-50%, 160%);
  visibility: hidden;
  transition: transform .35s var(--ease), visibility .35s;
  text-align: center;
}
.toast.is-visible { transform: translate(-50%, 0); visibility: visible; }
.confetti { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 60; pointer-events: none; }
.offscreen { position: fixed; left: -9999px; top: 0; opacity: 0; }

/* ── Tablet / desktop / projector ─────────────────────────────────────── */
@media (min-width: 600px) {
  .topbar { padding-left: 24px; padding-right: 24px; }
  .brand img { height: 42px; }
  .card { padding: 30px 28px 26px; }
}

@media (min-width: 960px) {
  .game {
    grid-template-columns: minmax(0, 1.08fr) minmax(380px, .92fr);
    grid-template-areas: 'wheel hero' 'wheel panel' 'perks perks';
    column-gap: clamp(40px, 5vw, 80px);
    row-gap: 22px;
    align-items: center;
    padding: 18px 32px 32px;
  }
  .hero { text-align: left; justify-items: start; align-self: end; }
  .panel { justify-self: start; align-self: start; }
  #wheel { width: min(46vw, 72vh, 640px); }
  .result-inner { max-width: 560px; }
}

@media (min-width: 1500px) and (min-height: 860px) {
  html { font-size: 18px; }
  #wheel { width: min(44vw, 74vh, 760px); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .bulb { opacity: 1; }
}

/* ── Projector screen (screen.html) ───────────────────────────────────── */
body.screen { overflow: hidden; }
.screen-grid {
  height: 100vh;
  height: 100dvh;
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, 1fr);
  align-items: center;
  gap: 4vw;
  padding: 3.5vh 4.5vw;
}
.screen-left { display: grid; gap: 2.4vh; justify-items: start; }
.screen-left .brand img { height: 6.5vh; }
.screen-left .eyebrow { font-size: min(1vw, 1.8vh); }
.screen-left .headline { font-size: min(7.2vw, 12.5vh); white-space: nowrap; }
.screen-left .subheadline { font-size: min(1.7vw, 3vh); max-width: 32ch; }
.scan-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2.2vw;
  align-items: center;
  padding: min(2vw, 3.4vh);
  border-radius: 2vw;
  background: linear-gradient(180deg, var(--pb-ivory), var(--pb-cream));
  color: var(--pb-ink);
  box-shadow: 0 30px 70px -20px rgba(0, 0, 0, .8), 0 0 0 2px rgba(229, 193, 88, .6);
}
.qr { width: min(17vw, 30vh); aspect-ratio: 1; background: #fff; border-radius: 1vw; padding: min(.8vw, 1.4vh); }
.qr svg { width: 100%; height: 100%; }
.scan-title { font-size: min(2.5vw, 4.4vh); font-weight: 800; line-height: 1.05; letter-spacing: -.02em; }
.scan-url { margin-top: 1vh; font-size: min(1.5vw, 2.6vh); font-weight: 800; color: var(--pb-emerald-700); word-break: break-all; }
.scan-steps { margin: 1.4vh 0 0; padding-left: 1.2em; font-size: min(1.1vw, 2vh); color: var(--pb-graphite); font-weight: 600; }
.screen-right { display: grid; justify-items: center; gap: 3vh; }
.screen-right #wheel { width: min(36vw, 56vh); }
.screen-stats { display: flex; gap: 2vw; align-items: start; width: 100%; justify-content: center; }
.stat {
  padding: 1.4vh 2vw;
  border-radius: 1.4vw;
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(229, 193, 88, .35);
  text-align: center;
  min-width: 14vw;
}
.stat strong { display: block; font-size: clamp(2rem, 4vw, 4.6rem); font-weight: 800; line-height: 1; color: var(--pb-gold-pale); font-variant-numeric: tabular-nums; }
.stat span { font-size: clamp(.8rem, 1vw, 1.2rem); color: var(--on-dark-muted); text-transform: uppercase; letter-spacing: .14em; font-weight: 700; }
.winners { list-style: none; margin: 0; padding: 0; flex: 1; max-width: 30vw; display: grid; gap: .8vh; align-content: start; }
.winners li {
  display: flex;
  justify-content: space-between;
  gap: 1vw;
  padding: .9vh 1.2vw;
  border-radius: .9vw;
  background: rgba(255, 255, 255, .05);
  font-size: clamp(.85rem, 1.15vw, 1.4rem);
  font-weight: 700;
  animation: rise .5s var(--ease) both;
}
.winners li strong { color: var(--pb-gold-pale); white-space: nowrap; }
.screen-status { font-size: clamp(1rem, 1.6vw, 2rem); font-weight: 800; color: var(--pb-gold-pale); }
@media (max-width: 900px) {
  body.screen { overflow: auto; }
  .screen-grid { grid-template-columns: 1fr; height: auto; }
  .screen-right #wheel { width: min(80vw, 420px); }
  .winners { max-width: none; }
  .scan-card { grid-template-columns: 1fr; justify-items: center; text-align: center; }
}
