/* Area O Stage — event app prototype styles */
:root {
  --bg: #0B0B10;
  --surface: #16161D;
  --surface-2: #1C1C24;
  --line: #2A2A35;
  --line-2: #3A3A48;
  --text: #F4F4F7;
  --muted: #A1A1AE;
  --soft: #D4D4DC;
  --purple: #7C3AED;
  --purple-deep: #4C1D95;
  --lavender: #A78BFA;
  --lavender-2: #C4B5FD;
  --lavender-3: #DDD6FE;
  --ink: #111118;
  --radius: 16px;
  --display: "Archivo", "Inter", system-ui, sans-serif;
  --body: "Inter", system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: #000; }
body { font-family: var(--body); color: var(--text); -webkit-font-smoothing: antialiased; }
a { color: var(--lavender-2); }
button { font-family: inherit; }
img { display: block; }
[hidden] { display: none !important; }

/* App frame: full screen on phones, a centered phone-sized column on desktop */
#app {
  position: relative;
  max-width: 430px;
  min-height: 100dvh;
  margin: 0 auto;
  background: var(--bg);
  overflow-x: hidden;
}
.screen { min-height: 100dvh; display: flex; flex-direction: column; }
.pad { padding: calc(env(safe-area-inset-top, 0px) + 40px) 24px calc(env(safe-area-inset-bottom, 0px) + 28px); }
.glow-bg { background: radial-gradient(120% 60% at 50% 0%, #1E1733 0%, var(--bg) 60%); }

/* Brand header */
.brand { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.brand img { width: 64px; height: auto; }
.brand .word { font-size: 20px; font-weight: 600; letter-spacing: 6px; margin-right: -6px; }
.brand .tag { display: flex; align-items: center; gap: 10px; font-size: 11px; letter-spacing: 3px; color: var(--muted); font-weight: 600; }
.brand .tag::before, .brand .tag::after { content: ""; width: 36px; height: 1px; background: var(--line-2); }

.display { font-family: var(--display); font-style: italic; font-weight: 900; letter-spacing: -1px; margin: 0; }
.swoosh { height: 6px; border-radius: 6px; background: linear-gradient(90deg, var(--purple), var(--lavender-2)); transform: rotate(-3deg); }

/* Buttons */
.btn { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 54px; border-radius: 16px; font-size: 16px; font-weight: 700; text-decoration: none; border: 0; cursor: pointer; width: 100%; }
.btn-light { background: var(--text); color: var(--bg); }
.btn-dark { background: var(--bg); color: #fff; }
.btn-purple { background: var(--purple); color: #fff; }
.btn-outline { background: transparent; color: var(--text); border: 1px solid var(--line-2); justify-content: flex-start; padding: 0 20px; font-weight: 600; }
.btn-outline .grow { flex: 1; text-align: left; }
.btn[disabled] { background: #E4E4EA; color: #6B6B78; cursor: not-allowed; }
.btn-hero { min-height: 76px; border-radius: 22px; font-size: 20px; font-weight: 800; box-shadow: 0 0 0 6px rgba(167,139,250,.18), 0 12px 40px rgba(124,58,237,.45); }
.link-btn { background: none; border: 0; color: var(--lavender-2); font-size: 14px; font-weight: 600; padding: 12px; cursor: pointer; text-decoration: none; align-self: center; }
.icon-btn { width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; background: none; border: 0; cursor: pointer; color: inherit; text-decoration: none; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; }
.muted { color: var(--muted); }
.row { display: flex; gap: 12px; align-items: center; }

/* Top bar */
.topbar { height: calc(env(safe-area-inset-top, 0px) + 64px); padding: env(safe-area-inset-top, 0px) 8px 0; display: flex; align-items: center; }
.topbar .title { flex: 1; text-align: center; font-size: 17px; font-weight: 600; margin-right: 44px; }

/* Countdown */
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 12px 0 10px; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.tile b { font-size: 26px; font-variant-numeric: tabular-nums; }
.tile span { font-size: 11px; letter-spacing: 1.5px; color: var(--muted); font-weight: 600; }

/* Modal sheets (pre-register / registered) */
.modal-wrap { position: relative; min-height: 100dvh; display: flex; align-items: center; justify-content: center; padding: 24px 20px; background: radial-gradient(120% 60% at 50% 0%, #1E1733 0%, var(--bg) 60%); }
.modal-wrap::before { content: ""; position: absolute; inset: 0; background: rgba(5,5,10,.55); }
.modal { position: relative; width: 100%; background: #fff; color: var(--ink); border-radius: 28px; padding: 32px 22px 22px; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.modal h1 { margin: 12px 0 0; font-size: 27px; line-height: 1.15; font-weight: 800; text-align: center; letter-spacing: -.5px; }
.modal p { margin: 4px 0 8px; font-size: 15px; line-height: 1.45; color: #4B4B57; text-align: center; }
.modal .close { position: absolute; top: 8px; right: 8px; color: var(--ink); }
.modal .logo { width: 96px; height: auto; }
.modal .word { font-size: 15px; font-weight: 600; letter-spacing: 4px; margin-right: -4px; }
.sso { border: 1px solid #D9D9E0; background: #fff; color: var(--ink); }
.pass { width: 100%; background: #EEE9FE; border-radius: 18px; padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.pass .grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; border-top: 1px solid #D6CCFB; padding-top: 12px; }
.pass small { display: block; font-size: 11px; letter-spacing: 1px; color: #5B4B8A; font-weight: 600; }
.pass strong { font-size: 17px; font-variant-numeric: tabular-nums; }
.live-dot { display: inline-block; width: 8px; height: 8px; border-radius: 4px; background: #16A34A; margin-right: 6px; animation: blink 1s steps(2) infinite; }
@keyframes blink { 50% { opacity: .3; } }

/* Confetti burst (pieces get --x --y --r from JS) */
.burst { position: absolute; left: 50%; top: 50%; width: 0; height: 0; pointer-events: none; }
.burst i { position: absolute; left: -5px; top: -2px; opacity: 0; animation: burst var(--dur, 3s) cubic-bezier(.15,.8,.3,1) infinite; animation-delay: var(--delay, 0s); }
@keyframes burst {
  0% { transform: translate(0,0) rotate(0) scale(.3); opacity: 0; }
  5% { opacity: 1; }
  45% { transform: translate(var(--x), var(--y)) rotate(var(--r)) scale(1); opacity: 1; }
  90% { transform: translate(calc(var(--x) * 1.08), calc(var(--y) + 30px)) rotate(calc(var(--r) * 1.4)) scale(.9); opacity: 0; }
  100% { opacity: 0; }
}

/* Camera */
.cam-stage { flex: 1; position: relative; background: linear-gradient(180deg, #2A2A2E, #1A1A1D); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.cam-frame { position: relative; width: min(82vw, 320px); aspect-ratio: 1 / 1; }
.cam-frame video, .cam-frame .fallback { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: 4px; }
.cam-frame .fallback { background: #EDEBE6; display: flex; align-items: center; justify-content: center; color: #555; font-size: 14px; text-align: center; padding: 20px; }
.corner { position: absolute; width: 40px; height: 40px; border: 3px solid #fff; }
.corner.tl { left: 0; top: 0; border-right: 0; border-bottom: 0; border-radius: 8px 0 0 0; }
.corner.tr { right: 0; top: 0; border-left: 0; border-bottom: 0; border-radius: 0 8px 0 0; }
.corner.bl { left: 0; bottom: 0; border-right: 0; border-top: 0; border-radius: 0 0 0 8px; }
.corner.br { right: 0; bottom: 0; border-left: 0; border-top: 0; border-radius: 0 0 8px 0; }
.cam-hint { position: absolute; top: 20px; left: 0; right: 0; text-align: center; }
.cam-hint span { background: rgba(0,0,0,.6); padding: 8px 14px; border-radius: 20px; font-size: 13px; }
.cam-bar { height: 168px; background: var(--bg); display: flex; align-items: center; justify-content: space-between; padding: 0 44px calc(env(safe-area-inset-bottom, 0px) + 24px); }
.shutter { width: 78px; height: 78px; border-radius: 39px; border: 4px solid #fff; background: none; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.shutter::after { content: ""; width: 62px; height: 62px; border-radius: 31px; background: #fff; }

/* Review form */
.review-card { background: #fff; color: var(--ink); border-radius: 22px; padding: 16px; display: flex; flex-direction: column; gap: 14px; }
.review-card .shot { width: 220px; aspect-ratio: 1 / 1; align-self: center; border-radius: 12px; background: #EDEBE6; object-fit: cover; }
.review-card label.field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 600; }
.review-card input[type=text] { height: 48px; border: 1px solid #C9C9D2; border-radius: 12px; padding: 0 14px; font-size: 17px; font-family: inherit; color: var(--ink); outline-color: var(--purple); }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; line-height: 1.4; color: #2A2A33; cursor: pointer; }
.check input { width: 22px; height: 22px; margin: 0; accent-color: var(--purple); flex-shrink: 0; }
.check a { color: #5B21B6; }

/* Stage (submission complete) */
.stage-screen { position: relative; min-height: 100dvh; overflow: hidden; background: radial-gradient(80% 45% at 50% 58%, #4C1D95 0%, #1E0B44 50%, #07060C 100%); }
.beam { position: absolute; top: -20px; width: 260px; height: 620px; background: linear-gradient(180deg, rgba(221,214,254,.55), rgba(167,139,250,0) 85%); filter: blur(6px); }
.beam.l { left: -40px; clip-path: polygon(0 0, 22% 0, 100% 100%, 55% 100%); transform-origin: 0 0; animation: beamL 4s ease-in-out infinite; }
.beam.r { right: -40px; clip-path: polygon(78% 0, 100% 0, 45% 100%, 0 100%); transform-origin: 100% 0; animation: beamR 4s ease-in-out infinite; }
@keyframes beamL { 0%,100% { transform: rotate(12deg); opacity: .5; } 50% { transform: rotate(-9deg); opacity: 1; } }
@keyframes beamR { 0%,100% { transform: rotate(-12deg); opacity: .5; } 50% { transform: rotate(9deg); opacity: 1; } }
.hero-float { animation: floaty 3.4s ease-in-out infinite; position: relative; z-index: 2; }
@keyframes floaty { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
.hero-ring { width: 176px; height: 176px; border-radius: 88px; padding: 5px; background: linear-gradient(160deg, #fff, var(--lavender) 55%, #5B21B6); animation: glow 4s ease-in-out infinite; }
@keyframes glow { 0%,100% { box-shadow: 0 0 0 6px rgba(196,181,253,.18), 0 0 40px rgba(196,181,253,.6); } 50% { box-shadow: 0 0 0 12px rgba(196,181,253,.18), 0 0 70px rgba(196,181,253,.9); } }
.hero-ring .inner { width: 100%; height: 100%; border-radius: 50%; background: #EDEBE6; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.hero-ring img { width: 100%; height: 100%; object-fit: cover; }
.podium { position: relative; width: 270px; height: 74px; margin-top: -30px; }
.podium .side { position: absolute; left: 0; right: 0; top: 18px; height: 52px; border-radius: 50%; background: linear-gradient(180deg, #3B1A78, #12082A); }
.podium .top { position: absolute; left: 0; right: 0; top: 0; height: 52px; border-radius: 50%; background: radial-gradient(60% 70% at 50% 40%, var(--lavender-3) 0%, #8B5CF6 45%, var(--purple-deep) 100%); animation: glow2 4s ease-in-out infinite; }
@keyframes glow2 { 0%,100% { box-shadow: 0 0 40px rgba(167,139,250,.6); } 50% { box-shadow: 0 0 70px rgba(167,139,250,.95); } }
.podium .rim { position: absolute; left: 22px; right: 22px; top: 8px; height: 34px; border-radius: 50%; border: 1.5px solid rgba(255,255,255,.7); }
.twinkle { animation: twinkle 2.2s ease-in-out infinite; }
@keyframes twinkle { 0%,100% { opacity: .25; } 50% { opacity: 1; } }

/* Tabs + lists */
.tabs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; background: var(--surface-2); border-radius: 14px; padding: 4px; }
.tabs a { height: 40px; border-radius: 10px; color: var(--soft); display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 600; text-decoration: none; }
.tabs a.on { background: var(--text); color: var(--bg); }
.gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.gallery figure { margin: 0; background: #EDEBE6; border-radius: 14px; overflow: hidden; }
.gallery .art { aspect-ratio: 1 / 1; display: flex; align-items: center; justify-content: center; }
.gallery .art img { width: 100%; height: 100%; object-fit: cover; }
.gallery figcaption { background: #fff; padding: 8px 12px; display: flex; justify-content: space-between; color: var(--ink); font-size: 14px; font-weight: 600; }
.gallery figcaption span { font-size: 12px; color: #5F5F6B; font-weight: 500; }

.section { display: flex; flex-direction: column; gap: 12px; }
.section h2 { margin: 0; font-size: 22px; font-weight: 700; }
.section p { margin: 0; font-size: 14px; line-height: 1.55; color: var(--soft); text-wrap: pretty; }
.pill { font-size: 12px; font-weight: 800; letter-spacing: 1.5px; padding: 5px 10px; border-radius: 8px; }
.step { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; }
.num { width: 28px; height: 28px; border-radius: 14px; background: #2A1F4A; color: var(--lavender-3); font-size: 13px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.timeline .item { display: flex; gap: 12px; }
.timeline .rail { display: flex; flex-direction: column; align-items: center; width: 12px; }
.timeline .rail::before { content: ""; width: 10px; height: 10px; border-radius: 5px; background: var(--lavender); margin-top: 5px; }
.timeline .rail::after { content: ""; flex: 1; width: 2px; background: var(--line); min-height: 12px; }
.prize { display: flex; gap: 16px; align-items: center; padding: 16px 0; border-top: 1px solid var(--line); }
.prize:first-child { border-top: 0; }
.prize .thumb { position: relative; width: 84px; height: 84px; flex-shrink: 0; }
.prize .thumb .box { width: 84px; height: 84px; border-radius: 14px; background: #fff; overflow: hidden; }
.prize .thumb .box img { width: 70px; height: 70px; object-fit: contain; margin: 2px 0 0 3px; }
.prize .thumb .tee { position: absolute; right: -8px; bottom: -8px; width: 36px; height: 36px; border-radius: 9px; background: #fff; border: 1px solid #D9D9E0; display: flex; align-items: center; justify-content: center; box-shadow: 0 3px 8px rgba(0,0,0,.35); }
.prize .thumb .tee img { width: 30px; height: 30px; object-fit: contain; }
.person { display: flex; gap: 14px; align-items: center; }
.person img { width: 64px; height: 64px; border-radius: 32px; border: 2px solid var(--line-2); object-fit: cover; flex-shrink: 0; }
.in-btn { width: 44px; height: 44px; flex-shrink: 0; border-radius: 12px; border: 1px solid var(--line-2); display: flex; align-items: center; justify-content: center; text-decoration: none; font-size: 15px; font-weight: 800; color: var(--text); }
.bullets div { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; line-height: 1.4; color: #E4E4EA; }
.bullets div::before { content: ""; width: 5px; height: 5px; border-radius: 3px; background: var(--lavender); flex-shrink: 0; margin-top: 7px; }
.bullets b.big { color: var(--lavender-3); font-weight: 800; }

.preview-bar { position: fixed; left: 50%; bottom: 10px; transform: translateX(-50%); z-index: 50; background: rgba(20,20,28,.92); border: 1px solid var(--line-2); border-radius: 12px; padding: 6px 10px; font-size: 12px; color: var(--muted); display: flex; gap: 6px; align-items: center; }
.preview-bar a { color: var(--lavender-2); text-decoration: none; padding: 4px 6px; }

/* Desktop: the app is a phone-width column on purpose (it's built for the booth, on phones).
   Give the page around it a quiet frame so it reads as intentional, not unfinished. */
@media (min-width: 700px) {
  body { background: #050508 radial-gradient(70% 55% at 50% 0%, #1A1430 0%, #050508 70%) fixed; }
  #app { border-left: 1px solid var(--line); border-right: 1px solid var(--line); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; }
}
.wordmark { height: auto; display: block; margin: 10px auto 2px; }
