/* ==========================================================
   LEVEL 50 UNLOCKED — Yaron & Aytan
   Mobile-first. Pixel type for display, Nunito for reading.
   ========================================================== */

@font-face { font-family: 'Press Start 2P'; src: url('/fonts/press-start-2p.woff2') format('woff2'); font-display: swap; }
@font-face { font-family: 'Silkscreen'; src: url('/fonts/silkscreen-700.woff2') format('woff2'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Nunito'; src: url('/fonts/nunito.woff2') format('woff2'); font-weight: 400 800; font-display: swap; }

:root {
  --navy-950: #040616;
  --navy-900: #070b24;
  --navy-800: #0c1338;
  --navy-700: #141d52;
  --neon: #1f8bff;
  --neon-hi: #7fd4ff;
  --cyan: #3ee6ff;
  --yellow: #ffd23f;
  --yellow-hi: #ffe680;
  --pink: #ff3d9a;
  --pink-hi: #ff7cc0;
  --magenta: #9e0f55;
  --plum: #5a0b3a;
  --cream: #fff4dc;
  --text: #f4efe2;
  --muted: #aab4dc;
  --red: #ff4d5e;
  --teal: #2fe0c8;
  --sky: #8fd8ff;
  --lilac: #c9a7ff;
  --ok: #5cffb0;
  --err: #ff6b81;

  --pixel: 'Press Start 2P', ui-monospace, monospace;
  --pixel-alt: 'Silkscreen', 'Press Start 2P', ui-monospace, monospace;
  --body: 'Nunito', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;

  --radius: 12px;
  --gutter: 16px;
  --glow: 0 0 0 2px rgba(31, 139, 255, .9), 0 0 18px rgba(31, 139, 255, .55), inset 0 0 18px rgba(31, 139, 255, .18);
  --hud-h: 34px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: radial-gradient(120% 70% at 50% 0%, #10195a 0%, var(--navy-900) 55%, var(--navy-950) 100%) fixed;
  background-color: var(--navy-900);
  color: var(--text);
  font: 17px/1.5 var(--body);
  overflow-x: hidden;
  position: relative;
  -webkit-tap-highlight-color: transparent;
}
img { max-width: 100%; display: block; }
a { color: var(--cyan); }
button { font: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; }

.skip-link { position: absolute; left: -9999px; top: 8px; z-index: 50; background: var(--yellow); color: var(--navy-900); padding: 8px 12px; font-weight: 800; border-radius: 6px; }
.skip-link:focus { left: 8px; }

/* ---------- background maze + CRT ---------- */
.maze-bg { position: absolute; inset: 0 auto auto 0; z-index: 0; pointer-events: none; image-rendering: pixelated; }
.crt {
  position: fixed; inset: 0; z-index: 40; pointer-events: none;
  background:
    repeating-linear-gradient(0deg, rgba(0, 0, 0, .16) 0 1px, transparent 1px 3px),
    radial-gradient(130% 100% at 50% 50%, transparent 60%, rgba(0, 0, 0, .45) 100%);
  mix-blend-mode: multiply;
  opacity: .55;
}

/* ---------- HUD ---------- */
.hud {
  position: sticky; top: 0; z-index: 30;
  height: var(--hud-h);
  padding: 0 calc(var(--gutter) + env(safe-area-inset-left)) 0 calc(var(--gutter) + env(safe-area-inset-right));
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  background: linear-gradient(180deg, rgba(4, 6, 22, .96), rgba(4, 6, 22, .82));
  border-bottom: 1px solid rgba(31, 139, 255, .35);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  font: 8px/1 var(--pixel); letter-spacing: .04em; color: var(--cream);
}
.hud__slot { display: flex; gap: 6px; align-items: baseline; }
.hud__slot--mid { justify-content: center; }
.hud__slot--right { justify-content: flex-end; }
.hud__label { color: var(--pink-hi); }
.hud__label--p1 { color: var(--red); }
.hud__label--p2 { color: var(--teal); }
.hud__score { font-variant-numeric: tabular-nums; }

/* ---------- layout ---------- */
.cabinet {
  position: relative; z-index: 3; /* above the footer, so pop-up menus (Add to calendar) stay tappable */
  width: 100%; max-width: 1180px;
  margin: 0 auto;
  padding: 18px var(--gutter) 28px;
  padding-left: max(var(--gutter), env(safe-area-inset-left));
  padding-right: max(var(--gutter), env(safe-area-inset-right));
}
.screen { animation: screen-in .45s ease-out both; }
@keyframes screen-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.home-grid { display: grid; gap: 18px; }
.home-grid__art, .home-grid__info { display: grid; gap: 16px; min-width: 0; }
@media (min-width: 960px) {
  .home-grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 40px; align-items: start; padding-top: 18px; }
  .home-grid__info { position: sticky; top: calc(var(--hud-h) + 20px); }
}

.panel {
  position: relative;
  background: linear-gradient(180deg, rgba(10, 16, 52, .97), rgba(6, 10, 34, .97));
  border-radius: var(--radius);
  box-shadow: var(--glow), 0 18px 40px rgba(0, 0, 0, .45);
  padding: 22px 18px;
}
.panel::before {
  /* pixel corner studs */
  content: ''; position: absolute; inset: 6px; pointer-events: none; border-radius: 8px;
  border: 1px dashed rgba(127, 212, 255, .16);
}
@media (min-width: 600px) { .panel { padding: 30px 30px; } }

.kicker { margin: 0 0 10px; font: 9px/1.6 var(--pixel); color: var(--cyan); letter-spacing: .06em; }
.kicker--center { text-align: center; }
.blink { animation: blink 1s steps(1) infinite; color: var(--pink-hi); }
@keyframes blink { 50% { opacity: 0; } }

/* ---------- title ---------- */
.title {
  position: relative; margin: 6px auto 0; text-align: center;
  display: grid; justify-items: center; gap: 12px;
  font-family: var(--pixel); font-weight: 400;
  line-height: 1;
  padding: 18px 10px 4px;
  isolation: isolate;
}
.title::before {
  content: ''; position: absolute; inset: -10px -6px -6px; z-index: -1; border-radius: 24px;
  background: radial-gradient(60% 70% at 50% 50%, rgba(7, 11, 36, .92), rgba(7, 11, 36, .55) 70%, transparent);
}
.title__row { display: flex; align-items: flex-end; gap: .35em; font-size: clamp(32px, 10.5vw, 66px); }
.title__level {
  color: var(--cream);
  text-shadow: 0 .08em 0 #d9c8a5, .06em .14em 0 var(--pink), .1em .2em 0 var(--plum), 0 0 24px rgba(255, 61, 154, .35);
}
.title__num {
  all: unset; cursor: pointer; display: inline-block; min-width: 2.05em; text-align: left;
  color: var(--yellow); font-size: 1.22em; font-variant-numeric: tabular-nums;
  text-shadow: 0 .07em 0 #e3a51a, .06em .13em 0 var(--pink), .1em .19em 0 var(--plum), 0 0 26px rgba(255, 210, 63, .45);
  transition: transform .15s;
}
.title__num:focus-visible { outline: 3px solid var(--yellow); outline-offset: 6px; }
.title__num:active { transform: scale(.94); }
.title__banner {
  position: relative; display: inline-block;
  font-size: clamp(22px, 7.4vw, 44px);
  padding: .32em .6em .28em;
  color: var(--cream);
  background: linear-gradient(180deg, #c3166c, var(--magenta));
  clip-path: polygon(.5em 0, calc(100% - .5em) 0, 100% 50%, calc(100% - .5em) 100%, .5em 100%, 0 50%);
  text-shadow: .08em .08em 0 var(--plum);
  box-shadow: inset 0 0 0 .14em var(--pink);
}
.title__banner::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, transparent 0 30%, rgba(255, 255, 255, .45) 45%, transparent 60%);
  transform: translateX(-120%);
  animation: shine 4.5s 2.6s ease-in-out infinite;
}
@keyframes shine { 0%, 70% { transform: translateX(-120%); } 100% { transform: translateX(120%); } }
.title__rays { position: absolute; inset: 0; pointer-events: none; z-index: -1; }
.title__rays::before, .title__rays::after {
  content: ''; position: absolute; top: 18%; width: 34px; height: 46px;
  background:
    linear-gradient(var(--yellow), var(--yellow)) 0 0 / 14px 4px no-repeat,
    linear-gradient(var(--yellow), var(--yellow)) 4px 20px / 16px 4px no-repeat,
    linear-gradient(var(--yellow), var(--yellow)) 0 40px / 14px 4px no-repeat;
  animation: rays 1.6s steps(2) infinite;
}
.title__rays::before { left: 0; transform: rotate(-12deg); }
.title__rays::after { right: 0; transform: scaleX(-1) rotate(-12deg); }
@keyframes rays { 50% { opacity: .35; } }

/* intro sequence */
.is-intro .title__level { animation: drop-in .5s cubic-bezier(.2, 1.6, .4, 1) both; }
.is-intro .title__num { animation: drop-in .5s .12s cubic-bezier(.2, 1.6, .4, 1) both; }
/* UNLOCKED and the rays appear exactly when the counter hits 50 */
.is-intro:not(.is-unlocked) .title__banner, .is-intro:not(.is-unlocked) .title__rays { opacity: 0; }
.is-intro.is-unlocked .title__banner { animation: slam 0.45s cubic-bezier(.2, 1.8, .4, 1) both; }
.is-intro.is-unlocked .title__rays { animation: fade-in .3s .15s both; }
.title__num.is-suspense { animation: suspense .14s steps(2) infinite; }
@keyframes suspense { 0% { transform: translate(-2px, 1px); color: var(--pink-hi); } 100% { transform: translate(2px, -1px); color: var(--yellow); } }
.title__num.is-fifty { animation: fifty-pop .7s cubic-bezier(.2, 1.8, .4, 1) both; }
@keyframes fifty-pop {
  0% { transform: scale(1.9); filter: brightness(2.2) drop-shadow(0 0 18px #fff); }
  60% { filter: brightness(1.4) drop-shadow(0 0 22px var(--pink)); }
  100% { transform: none; filter: none; }
}
@keyframes drop-in { from { transform: translateY(-40px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes slam { 0% { transform: scale(2.4); opacity: 0; filter: brightness(3); } 60% { opacity: 1; } 100% { transform: none; filter: none; } }
@keyframes fade-in { from { opacity: 0; } }
.flash { animation: flash .5s ease-out; }
@keyframes flash { 0% { filter: brightness(2.4) drop-shadow(0 0 20px var(--yellow)); } 100% { filter: none; } }

/* ---------- stage ---------- */
.stage {
  position: relative;
  height: 252px;
  margin: 0 calc(-1 * var(--gutter));
}
.stage--done { height: 180px; margin: 6px -18px 14px; }
@media (min-width: 600px) { .stage { height: 300px; } .stage--done { margin: 6px -30px 16px; } }
@media (min-width: 960px) { .stage { height: 380px; margin: 0; } .stage--done { height: 220px; } }
.stage__canvas { position: absolute; left: 0; top: 0; image-rendering: pixelated; touch-action: manipulation; cursor: pointer; }

.stage__play {
  position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); z-index: 2;
  min-height: 40px; padding: 10px 14px; border: 0; border-radius: 999px; cursor: pointer;
  font: 400 9px/1 var(--pixel); color: var(--plum); background: var(--yellow);
  box-shadow: 0 0 0 3px var(--pink), 0 6px 18px rgba(0, 0, 0, .5);
}
.debug-box {
  position: fixed; left: 8px; right: 8px; top: calc(var(--hud-h) + 6px); z-index: 60; margin: 0; padding: 10px;
  font: 11px/1.4 ui-monospace, monospace; color: #b8ffcf; background: rgba(0, 0, 0, .85); border-radius: 8px;
  white-space: pre-wrap; word-break: break-all; pointer-events: none;
}

/* ---------- cast legend ---------- */
.cast { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.cast__btn {
  width: 100%; display: grid; justify-items: center; gap: 6px; padding: 10px 4px 8px;
  border: 0; border-radius: 10px; cursor: pointer; color: var(--c, var(--cream));
  background: rgba(7, 11, 36, .88);
  box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--c) 55%, transparent);
  font: 8px/1.3 var(--pixel); letter-spacing: .03em;
  transition: transform .15s, box-shadow .15s;
}
.cast__btn img { width: 36px; height: 36px; image-rendering: pixelated; }
.cast__btn small { font: 700 11px/1.2 var(--body); color: var(--muted); letter-spacing: 0; }
.cast__btn:hover { transform: translateY(-2px); box-shadow: inset 0 0 0 2px var(--c), 0 0 16px color-mix(in srgb, var(--c) 45%, transparent); }
.cast__btn:active { transform: translateY(1px) scale(.97); }
@media (min-width: 600px) { .cast__btn { font-size: 10px; } .cast__btn img { width: 44px; height: 44px; } }

/* ---------- details ---------- */
.details__title {
  margin: 0 0 8px; font: 400 clamp(17px, 5.3vw, 24px)/1.35 var(--pixel); color: var(--yellow);
  text-shadow: .1em .1em 0 var(--magenta);
}
.details__title .amp { color: var(--pink-hi); }
.details__title .dot { color: var(--cream); }
.details__title .fifty { color: var(--cream); white-space: nowrap; }
.details__title .fifty b { font-weight: 400; color: var(--pink-hi); }
.details__lead { margin: 0 0 16px; font-size: 18px; color: var(--cream); }
.facts { margin: 0; display: grid; gap: 0; border-top: 2px solid rgba(255, 61, 154, .55); border-bottom: 2px solid rgba(255, 61, 154, .55); }
.fact { display: grid; grid-template-columns: 74px 1fr; gap: 12px; align-items: baseline; padding: 12px 0; }
.fact + .fact { border-top: 1px dashed rgba(127, 212, 255, .22); }
.fact dt { font: 9px/1.8 var(--pixel); color: var(--cyan); letter-spacing: .05em; }
.fact dd { margin: 0; font-size: 18px; line-height: 1.35; }
.fact strong { font-weight: 800; color: var(--text); }
.address { display: block; color: var(--muted); font-size: 16px; margin-top: 2px; }
.details__vibe { margin: 14px 0 0; color: var(--muted); font-size: 16px; }

/* Hebrew-first details: English game tags on the left, values right-aligned like a scoreboard */
.he-block { text-align: right; font-family: 'Nunito', 'Arial Hebrew', 'Segoe UI', Arial, sans-serif; }
.details__lead.he-block { margin-bottom: 2px; font-size: 20px; font-weight: 800; }
.details__lead-en { margin: 0 0 16px; text-align: right; font-size: 14px; color: var(--muted); }
.facts dd { text-align: right; }
.facts dd strong, .facts dd .address, .facts dd .en { display: block; }
.facts dd .address { margin-top: 2px; }
.facts dd .en { margin-top: 2px; font-size: 13px; color: #8790bd; }
/* English-only invitations (hebrew: false in event.config.js): English becomes the main text, left-aligned */
.no-he .details__lead-en { text-align: left; font-size: 17px; color: var(--cream); }
.no-he .facts dd { text-align: left; }
.no-he .facts dd > .en:first-child { margin-top: 0; font-size: 18px; color: var(--cream); }
.no-he .parking-note__en { margin-top: 16px; font-weight: 800; }
.details__vibe.he-block { font-size: 16px; }

.parking-note { margin-top: 16px; font-weight: 800; color: var(--cream) !important; display: flex; align-items: center; gap: 10px; justify-content: flex-start; }
.parking-note__p {
  flex: none; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 6px;
  font: 400 14px/1 var(--pixel); color: #fff; background: #1f6bff; box-shadow: inset 0 0 0 2px #8fd8ff;
}
.parking-note__en { margin: 4px 0 0; }

/* tappable hotel address → Google Maps (walking, taxi, public transport) */
.map-link { display: block; color: inherit; text-decoration: none; border-radius: 8px; }
.map-link:hover strong, .map-link:focus-visible strong { color: var(--cyan); }
.map-link__hint {
  display: inline-block !important; margin-top: 8px; padding: 6px 10px; border-radius: 999px;
  font: 800 13px/1.2 var(--body); color: var(--cyan) !important; background: rgba(62, 230, 255, .1); box-shadow: inset 0 0 0 1px rgba(62, 230, 255, .45);
}
.map-link__hint > span { display: block; text-align: center; }
.map-link__hint > span + span { font-weight: 700; font-size: 12px; opacity: .85; margin-top: 2px; }

/* ---------- big arcade button ---------- */
.cta { display: grid; gap: 10px; }
.btn-start {
  --b: 4px;
  position: relative; display: flex; align-items: center; justify-content: center; gap: 12px;
  width: 100%; min-height: 64px; padding: 16px 18px;
  border: 0; cursor: pointer; text-decoration: none;
  font: 400 clamp(12px, 3.4vw, 17px)/1.3 var(--pixel); letter-spacing: 0; text-align: center;
  color: var(--plum);
  background: linear-gradient(180deg, var(--yellow-hi), var(--yellow) 45%, #f5b915);
  clip-path: polygon(10px 0, calc(100% - 10px) 0, 100% 10px, 100% calc(100% - 10px), calc(100% - 10px) 100%, 10px 100%, 0 calc(100% - 10px), 0 10px);
  box-shadow: inset 0 0 0 var(--b) var(--pink), inset 0 -8px 0 var(--b) rgba(158, 15, 85, .25);
  transition: transform .12s, filter .12s;
  filter: drop-shadow(0 0 14px rgba(255, 210, 63, .35));
  animation: pulse 2.2s ease-in-out infinite;
}
.btn-start:hover { filter: brightness(1.06) drop-shadow(0 0 20px rgba(255, 210, 63, .6)); }
.btn-start:active { transform: translateY(2px) scale(.99); }
.btn-start[disabled] { cursor: progress; filter: saturate(.6); animation: none; }
@keyframes pulse { 50% { filter: drop-shadow(0 0 22px rgba(255, 210, 63, .65)); } }
.tri { width: 0; height: 0; border-top: 8px solid transparent; border-bottom: 8px solid transparent; flex: none; animation: blink 1s steps(1) infinite; }
.tri--l { border-left: 11px solid var(--pink); }
.tri--r { border-right: 11px solid var(--pink); }
.saved-note {
  margin: 0; padding: 10px 12px; border-radius: 10px; text-align: center; font-size: 15px;
  background: rgba(92, 255, 176, .08); color: var(--cream); box-shadow: inset 0 0 0 1px rgba(92, 255, 176, .45);
}
.saved-note b { color: var(--ok); }
.saved-note a { color: var(--yellow); font-weight: 800; }

/* ---------- secondary buttons ---------- */
.actions { display: grid; gap: 10px; }
.actions__row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.btn {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 12px 14px; border-radius: 10px; cursor: pointer;
  font: 400 10px/1.4 var(--pixel); letter-spacing: .03em; text-align: center; text-decoration: none;
  border: 0; list-style: none; user-select: none;
  transition: transform .12s, box-shadow .12s, background .12s;
}
.btn::-webkit-details-marker { display: none; }
.btn:active { transform: translateY(1px) scale(.98); }
.btn--waze {
  min-height: 58px; font-size: 13px; color: #032033;
  background: linear-gradient(180deg, #8ff0ff, #33ccff);
  box-shadow: 0 0 0 2px #b8f6ff inset, 0 0 18px rgba(51, 204, 255, .45);
}
.btn--waze:hover { box-shadow: 0 0 0 2px #fff inset, 0 0 26px rgba(51, 204, 255, .7); }
.btn__icon { font-family: var(--body); font-size: 18px; transform: rotate(-45deg); display: inline-block; }
.btn--ghost { color: var(--cream); background: rgba(7, 11, 36, .92); box-shadow: inset 0 0 0 2px rgba(127, 212, 255, .55); }
.btn--ghost:hover { box-shadow: inset 0 0 0 2px var(--neon-hi), 0 0 14px rgba(31, 139, 255, .45); }

.cal { position: relative; }
.cal > summary { height: 100%; }
.cal[open] > summary { box-shadow: inset 0 0 0 2px var(--yellow); }
.cal__menu {
  position: absolute; z-index: 20; left: 0; top: calc(100% + 6px); min-width: 100%; width: max-content; max-width: calc(100vw - 32px);
  display: grid; padding: 6px; border-radius: 10px;
  background: var(--navy-800); box-shadow: var(--glow), 0 12px 30px rgba(0, 0, 0, .5);
}
.cal__menu a { display: flex; align-items: center; min-height: 48px; padding: 12px 16px; border-radius: 8px; color: var(--cream); text-decoration: none; font-weight: 700; font-size: 17px; }
.cal__menu a:hover, .cal__menu a:focus-visible { background: rgba(31, 139, 255, .2); }

/* ---------- RSVP form ---------- */
.screen--rsvp, .screen--done { max-width: 620px; margin: 8px auto 0; }
.back-link { display: inline-block; margin-bottom: 18px; font: 9px/1.6 var(--pixel); color: var(--muted); text-decoration: none; padding: 6px 0; }
.back-link:hover { color: var(--yellow); }
.form-title { margin: 0 0 6px; font: 400 clamp(16px, 5vw, 22px)/1.4 var(--pixel); color: var(--yellow); text-shadow: .1em .1em 0 var(--magenta); }
.form-sub { margin: 0 0 18px; color: var(--muted); font-size: 15px; }
.welcome-back {
  margin: 0 0 18px; padding: 12px 14px; border-radius: 10px; font-size: 15px;
  background: rgba(255, 210, 63, .08); box-shadow: inset 0 0 0 1px rgba(255, 210, 63, .45);
}
.welcome-back b { color: var(--yellow); }

.field { margin: 0 0 18px; border: 0; padding: 0; min-width: 0; }
.field label, .field legend, .counts__title {
  display: block; margin: 0 0 8px; padding: 0;
  font: 400 10px/1.6 var(--pixel); color: var(--cream); letter-spacing: .03em;
}
.optional { font: 700 12px/1 var(--body); color: var(--muted); margin-left: 6px; letter-spacing: 0; }
input[type='text'], input[type='tel'], input[type='number'], input[type='password'], input[type='search'], textarea, select {
  width: 100%; min-height: 52px; padding: 12px 14px;
  font: 600 17px/1.35 var(--body); color: var(--text);
  background: #050820; border: 2px solid #2a3a8a; border-radius: 10px;
  transition: border-color .15s, box-shadow .15s;
  -webkit-appearance: none; appearance: none;
}
textarea { min-height: 96px; resize: vertical; }
input::placeholder, textarea::placeholder { color: #66709c; font-weight: 500; }
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(62, 230, 255, .25), 0 0 16px rgba(62, 230, 255, .25); }
.field.has-error input, .field.has-error textarea, .field.has-error .choice__card { border-color: var(--err); }
.field__hint { margin: 6px 0 0; font-size: 14px; color: var(--muted); }
.field__hint--right { text-align: right; }
.field__error { margin: 6px 0 0; font-size: 14px; font-weight: 700; color: var(--err); min-height: 0; }
.field__error:empty { display: none; }

.choice__grid { display: grid; gap: 10px; }
@media (min-width: 560px) { .choice__grid { grid-template-columns: repeat(3, 1fr); } }
.choice__opt { position: relative; display: block; margin: 0; cursor: pointer; }
.choice__opt input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.choice__card {
  display: flex; align-items: center; gap: 12px; min-height: 60px; padding: 10px 14px;
  border: 2px solid #2a3a8a; border-radius: 12px; background: #050820;
  font: 800 17px/1.25 var(--body); color: var(--text);
  transition: border-color .15s, background .15s, transform .12s, box-shadow .15s;
}
@media (min-width: 560px) { .choice__card { flex-direction: column; justify-content: center; text-align: center; min-height: 118px; gap: 10px; } }
.choice__icon { width: 34px; height: 34px; flex: none; image-rendering: pixelated; }
.choice__icon--q {
  display: grid; place-items: center; font: 15px/1 var(--pixel); color: var(--cream);
  background: var(--magenta); border-radius: 50%; box-shadow: inset 0 0 0 3px var(--pink), 0 0 12px rgba(255, 61, 154, .5);
}
.choice__opt input:focus-visible + .choice__card { outline: 3px solid var(--yellow); outline-offset: 2px; }
.choice__opt:hover .choice__card { border-color: var(--neon-hi); }
.choice__opt input:checked + .choice__card { transform: translateY(-1px); }
.choice__opt--yes input:checked + .choice__card { border-color: var(--yellow); background: rgba(255, 210, 63, .1); box-shadow: 0 0 18px rgba(255, 210, 63, .3); }
.choice__opt--no input:checked + .choice__card { border-color: var(--sky); background: rgba(143, 216, 255, .1); box-shadow: 0 0 18px rgba(143, 216, 255, .28); }
.choice__opt--maybe input:checked + .choice__card { border-color: var(--pink); background: rgba(255, 61, 154, .1); box-shadow: 0 0 18px rgba(255, 61, 154, .3); }

.counts { margin: 0 0 18px; padding: 16px; border-radius: 12px; background: rgba(31, 139, 255, .07); box-shadow: inset 0 0 0 1px rgba(31, 139, 255, .35); animation: screen-in .3s ease-out both; }
.counts--flash { animation: counts-flash 1.4s ease-out; }
@keyframes counts-flash { 0%, 40% { box-shadow: inset 0 0 0 2px var(--yellow), 0 0 22px rgba(255, 210, 63, .45); } 100% { box-shadow: inset 0 0 0 1px rgba(31, 139, 255, .35); } }
.choice__hint { margin: -2px 0 10px; }
.counts__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.counts .field { margin: 0; }
.stepper__ctl { display: grid; grid-template-columns: 48px 1fr 48px; align-items: stretch; }
.stepper__ctl input { text-align: center; border-radius: 0; border-left: 0; border-right: 0; padding: 0 4px; font-size: 20px; font-weight: 800; -moz-appearance: textfield; }
.stepper__ctl input::-webkit-outer-spin-button, .stepper__ctl input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.stepper__btn {
  border: 2px solid #2a3a8a; background: #0d1650; color: var(--yellow); cursor: pointer;
  font: 400 18px/1 var(--pixel); min-height: 52px;
}
.stepper__btn:first-child { border-radius: 10px 0 0 10px; }
.stepper__btn:last-child { border-radius: 0 10px 10px 0; }
.stepper__btn:active { background: #18237a; }

.hp { position: absolute !important; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form-error { margin: 0 0 14px; padding: 12px 14px; border-radius: 10px; background: rgba(255, 107, 129, .12); color: #ffd0d8; box-shadow: inset 0 0 0 1px rgba(255, 107, 129, .5); font-weight: 700; }
.btn-start--submit { margin-top: 6px; }
.form-foot { margin: 14px 0 0; text-align: center; font-size: 14px; color: var(--muted); }
.is-loading-btn .btn-start__label::after { content: ''; display: inline-block; width: 1.2em; text-align: left; animation: dots 1s steps(4) infinite; }
@keyframes dots { 0% { content: ''; } 25% { content: '.'; } 50% { content: '..'; } 75% { content: '...'; } }

/* ---------- done screen ---------- */
.screen--done { position: relative; }
.confetti { position: fixed; inset: 0; width: 100vw; height: 100vh; pointer-events: none; z-index: 35; image-rendering: pixelated; }
.done-panel { text-align: center; overflow: visible; } /* visible: the Add to calendar menu must not be clipped */
.done-panel:focus { outline: none; }
.done-title {
  margin: 4px 0 14px; font: 400 clamp(22px, 7.5vw, 38px)/1.25 var(--pixel); color: var(--yellow);
  text-shadow: .08em .08em 0 var(--magenta), 0 0 24px rgba(255, 210, 63, .45);
  animation: slam .5s cubic-bezier(.2, 1.8, .4, 1) both;
}
.done-title--no { color: var(--sky); text-shadow: .08em .08em 0 #20306f, 0 0 24px rgba(143, 216, 255, .4); font-size: clamp(17px, 5.4vw, 28px); }
.done-title--maybe { color: var(--pink-hi); text-shadow: .08em .08em 0 var(--plum); font-size: clamp(18px, 6vw, 30px); }
.done-msg { margin: 0 auto 14px; max-width: 30ch; font-size: 19px; color: var(--cream); font-weight: 700; }
.done-summary { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 4px; }
.chip { padding: 8px 12px; border-radius: 999px; font: 400 9px/1.4 var(--pixel); color: var(--cream); background: rgba(31, 139, 255, .14); box-shadow: inset 0 0 0 1px rgba(127, 212, 255, .45); }
.chip--score { color: var(--yellow); box-shadow: inset 0 0 0 1px rgba(255, 210, 63, .55); background: rgba(255, 210, 63, .08); }
.actions--done { text-align: left; }
.done-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; margin-top: 18px; }
.text-link { color: var(--cyan); font-weight: 800; text-decoration: none; padding: 8px 2px; }
.text-link:hover { color: var(--yellow); text-decoration: underline; }

/* ---------- footer ---------- */
.footer { position: relative; z-index: 2; text-align: center; padding: 18px var(--gutter) calc(28px + env(safe-area-inset-bottom)); color: var(--muted); font-size: 14px; }
.footer p { margin: 0 auto 8px; max-width: 46ch; background: rgba(7, 11, 36, .85); display: table; padding: 4px 10px; border-radius: 6px; }
.footer__credit { font: 8px/1.8 var(--pixel); color: #6d78ad; letter-spacing: .05em; }

/* ---------- screen wipe transition ---------- */
.wipe {
  position: fixed; inset: 0; z-index: 45; display: grid; place-items: center; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(31, 139, 255, .12) 1px, transparent 1px) 0 0 / 24px 24px,
    linear-gradient(rgba(31, 139, 255, .12) 1px, transparent 1px) 0 0 / 24px 24px,
    var(--navy-950);
  clip-path: inset(0 0 100% 0);
}
.wipe__text { font: 400 clamp(18px, 6vw, 30px)/1 var(--pixel); color: var(--yellow); text-shadow: .1em .1em 0 var(--magenta); opacity: 0; }
.wipe.is-in { animation: wipe-in .32s steps(8) forwards; }
.wipe.is-in .wipe__text { animation: fade-in .1s .2s forwards; opacity: 0; }
.wipe.is-out { clip-path: inset(0); animation: wipe-out .32s steps(8) forwards; }
.wipe.is-out .wipe__text { opacity: 1; }
@keyframes wipe-in { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes wipe-out { from { clip-path: inset(0 0 0 0); } to { clip-path: inset(100% 0 0 0); } }
@keyframes fade-in { to { opacity: 1; } }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: calc(22px + env(safe-area-inset-bottom)); z-index: 50;
  transform: translate(-50%, calc(100% + 60px)); visibility: hidden;
  transition: transform .25s cubic-bezier(.2, 1.4, .4, 1), visibility 0s .25s;
  max-width: calc(100vw - 32px); padding: 12px 16px; border-radius: 10px;
  background: var(--navy-800); color: var(--cream); box-shadow: var(--glow), 0 10px 30px rgba(0, 0, 0, .5);
  font: 400 10px/1.6 var(--pixel); text-align: center;
}
.toast.is-on { transform: translate(-50%, 0); visibility: visible; transition-delay: 0s; }

.noscript { position: relative; z-index: 5; margin: 16px; padding: 16px; background: var(--navy-800); border-radius: 10px; }

/* home-page promo card (shown only when the feed is enabled) */
.feed-promo {
  display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 12px; text-decoration: none; color: var(--cream);
  background: linear-gradient(90deg, rgba(158, 15, 85, .35), rgba(7, 11, 36, .95));
  box-shadow: inset 0 0 0 2px var(--pink), 0 0 18px rgba(255, 61, 154, .3);
}
.feed-promo img { width: 34px; height: 34px; image-rendering: pixelated; flex: none; }
.feed-promo b { display: block; font: 400 10px/1.6 var(--pixel); color: var(--pink-hi); }
.feed-promo span { font-size: 15px; color: var(--cream); }
.feed-promo:hover { box-shadow: inset 0 0 0 2px var(--pink-hi), 0 0 26px rgba(255, 61, 154, .5); }

/* home-page call-out under the characters */
.feed-callout { display: grid; justify-items: center; gap: 6px; }
.feed-callout__arrow { margin: 0; display: grid; justify-items: center; gap: 4px; animation: arrow-bounce 1s ease-in-out infinite; }
.feed-callout__arrow span {
  padding: 5px 8px; border-radius: 4px; font: 400 8px/1 var(--pixel); color: var(--plum); background: var(--yellow);
  box-shadow: 0 0 14px rgba(255, 210, 63, .55);
}
/* chunky pixel arrow pointing down */
.feed-callout__arrow i {
  display: block; width: 28px; height: 22px; background: var(--yellow);
  clip-path: polygon(30% 0, 70% 0, 70% 45%, 100% 45%, 50% 100%, 0 45%, 30% 45%);
  filter: drop-shadow(0 0 6px rgba(255, 210, 63, .8));
}
@keyframes arrow-bounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(8px); } }
.feed-promo--hero {
  width: 100%; gap: 14px; padding: 16px 16px; border-radius: 14px;
  background: linear-gradient(100deg, rgba(158, 15, 85, .7), rgba(12, 19, 56, .97) 70%);
  box-shadow: inset 0 0 0 3px var(--pink), 0 0 24px rgba(255, 61, 154, .45);
  animation: promo-glow 2.2s ease-in-out infinite;
}
.feed-promo--hero img { width: 44px; height: 40px; }
.feed-promo--hero .feed-promo__text { flex: 1; min-width: 0; font-size: 15px; line-height: 1.35; }
.feed-promo--hero b { font-size: clamp(12px, 3.6vw, 15px); color: var(--yellow); text-shadow: .1em .1em 0 var(--magenta); margin-bottom: 4px; }
.feed-promo__go { flex: none; padding: 8px 10px; border-radius: 8px; font: 400 9px/1 var(--pixel) !important; color: var(--plum) !important; background: var(--yellow); }
@keyframes promo-glow { 50% { box-shadow: inset 0 0 0 3px var(--pink-hi), 0 0 38px rgba(255, 61, 154, .75); } }
@media (max-width: 380px) { .feed-promo__go { display: none; } }
.feed-callout--done { margin: 14px 0 6px; text-align: left; }
.feed-promo__text > span { display: block; font-size: 15px; color: var(--cream); }

/* ---------- music toggle ---------- */
.music-btn {
  position: fixed; z-index: 42; right: max(12px, env(safe-area-inset-right)); bottom: calc(12px + env(safe-area-inset-bottom));
  display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 8px 12px; border: 0; border-radius: 999px; cursor: pointer;
  font: 400 8px/1 var(--pixel); letter-spacing: .04em; color: var(--cream);
  background: rgba(7, 11, 36, .92); box-shadow: inset 0 0 0 2px rgba(127, 212, 255, .5), 0 6px 18px rgba(0, 0, 0, .45);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  transition: box-shadow .15s, transform .12s;
}
.music-btn:hover { box-shadow: inset 0 0 0 2px var(--neon-hi), 0 0 16px rgba(31, 139, 255, .5); }
.music-btn:active { transform: scale(.96); }
.music-btn.is-waiting { color: var(--cream); animation: music-nudge 1.6s ease-in-out infinite; }
@keyframes music-nudge { 50% { box-shadow: inset 0 0 0 2px var(--pink-hi), 0 0 22px rgba(255, 61, 154, .6); transform: scale(1.04); } }
.music-btn.is-on { color: var(--yellow); box-shadow: inset 0 0 0 2px var(--yellow), 0 0 16px rgba(255, 210, 63, .35); }
.music-btn__eq { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; }
.music-btn__eq i { display: block; width: 3px; height: 5px; background: currentColor; }
.music-btn:not(.is-on) .music-btn__eq i:nth-child(2) { height: 9px; }
.music-btn:not(.is-on) .music-btn__eq i:nth-child(3) { height: 7px; }
.music-btn.is-on .music-btn__eq i { animation: eq .9s steps(3) infinite; }
.music-btn.is-on .music-btn__eq i:nth-child(2) { animation-delay: -.3s; }
.music-btn.is-on .music-btn__eq i:nth-child(3) { animation-delay: -.6s; }
@keyframes eq { 0% { height: 4px; } 33% { height: 14px; } 66% { height: 8px; } 100% { height: 4px; } }
.footer { padding-bottom: calc(70px + env(safe-area-inset-bottom)); }

/* ---------- Hebrew sub-labels on buttons ---------- */
.he {
  display: block; margin-top: 4px;
  font: 700 13px/1.25 'Nunito', 'Arial Hebrew', 'Segoe UI', Arial, system-ui, sans-serif;
  letter-spacing: 0; text-transform: none; text-align: center; unicode-bidi: isolate;
}
.btn-start__labels, .btn__labels { display: grid; justify-items: center; gap: 2px; text-align: center; }
.btn-start .he { font-size: 14px; color: var(--plum); opacity: .9; }
.btn .he { font-size: 12px; opacity: .85; }
.btn--waze .he { font-size: 13px; }
.choice__text .he { text-align: left; font-size: 14px; font-weight: 600; color: var(--muted); margin-top: 2px; }
@media (min-width: 560px) { .choice__text .he { text-align: center; } }
.feed-promo__text .he { text-align: left; font-size: 14px; color: var(--pink-hi); }

/* ---------- after-party memory mode ---------- */
.memories-panel { display: none; }
.is-memories .memories-panel { display: block; }
.is-memories .details, .is-memories .cta, .is-memories .actions, .is-memories .feed-callout { display: none !important; }
.memories-panel__cta { margin-top: 18px; }

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .blink, .tri { animation: none !important; }
  .title__banner::after { display: none; }
}

/* Draft / preview invitations (not published yet) */
.draft-ribbon {
  position: fixed; z-index: 50; left: 50%; bottom: 14px; transform: translateX(-50%);
  padding: 9px 16px; border-radius: 999px; font: 400 10px/1.3 var(--pixel); letter-spacing: .04em;
  color: #070b24; background: var(--yellow); box-shadow: 0 6px 20px rgba(0,0,0,.45); text-decoration: none; white-space: nowrap;
}

/* "Made with …" link (platform invitations, except Premium) */
.made-with { margin: 14px 0 0; }
.made-with a { display: inline-block; padding: 8px 14px; border-radius: 999px; font: 700 13px/1.3 var(--body); color: var(--muted); text-decoration: none; background: rgba(255,255,255,.05); box-shadow: inset 0 0 0 1px rgba(127,212,255,.3); }
.made-with a b { color: var(--yellow); font-weight: 800; }
.made-with a:hover, .made-with a:focus-visible { color: var(--cream); box-shadow: inset 0 0 0 1px var(--yellow); }
