:root {
  --bg: #0c1120;
  --surface: #151c30;
  --surface-2: #1c2540;
  --line: rgba(255, 255, 255, 0.08);
  --text: #f3f5fa;
  --muted: #9aa4bd;
  --gold: #ffc24b;
  --gold-2: #ff9f2e;
  --coral: #ff6b5e;
  --green: #3ddc97;
}

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

[hidden] { display: none !important; }

body {
  min-height: 100vh;
  font-family: 'Be Vietnam Pro', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: var(--text);
  background:
    radial-gradient(120% 60% at 50% -10%, rgba(255, 194, 75, 0.16), transparent 60%),
    var(--bg);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

.page {
  max-width: 440px;
  margin: 0 auto;
  padding: 20px 16px calc(110px + env(safe-area-inset-bottom));
}

/* Top bar */
.topbar { display: flex; justify-content: space-between; align-items: center; }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 3px rgba(61, 220, 151, 0.2);
}

.pill-age { color: var(--text); font-weight: 700; }

/* Hero */
.hero { padding: 36px 0 28px; }

.eyebrow {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
}

h1 {
  margin-top: 10px;
  font-size: clamp(40px, 12vw, 54px);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.gold {
  background: linear-gradient(180deg, var(--gold), var(--gold-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lead {
  margin-top: 14px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--muted);
  max-width: 34ch;
}

/* Ticket card with perforation notches */
.ticket {
  position: relative;
  border-radius: 20px;
  background: linear-gradient(160deg, #ffd36e 0%, #ffb340 55%, #ff8f3a 100%);
  color: #2a1700;
  overflow: hidden;
}

.ticket::before,
.ticket::after {
  content: '';
  position: absolute;
  bottom: 44px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--bg);
  transform: translateY(50%);
}

.ticket::before { left: -11px; }
.ticket::after { right: -11px; }

.ticket-top { padding: 22px 22px 20px; }

.ticket-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.75;
}

.ticket-amount {
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.ticket-amount .from { font-size: 28px; opacity: 0.6; text-decoration: line-through; text-decoration-thickness: 2px; }
.ticket-amount .arrow { width: 26px; height: 26px; stroke-width: 2.5; opacity: 0.7; }
.ticket-amount .to { font-size: 52px; line-height: 1; }

.ticket-bottom {
  height: 44px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 22px;
  border-top: 2px dashed rgba(42, 23, 0, 0.25);
  font-size: 12.5px;
  font-weight: 600;
}

.ticket-bottom svg { width: 16px; height: 16px; }

/* Perks */
.perks {
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.perk {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 12px;
  border-radius: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
}

.perk svg { color: var(--gold); margin-bottom: 6px; }
.perk strong { font-size: 14px; font-weight: 700; }
.perk span { font-size: 12px; line-height: 1.4; color: var(--muted); }

/* Steps */
.steps {
  margin-top: 28px;
  padding: 20px;
  border-radius: 20px;
  background: var(--surface);
  border: 1px solid var(--line);
}

.steps h2 { font-size: 16px; font-weight: 700; margin-bottom: 16px; }

.steps ol { list-style: none; display: flex; flex-direction: column; gap: 18px; position: relative; }

.steps ol::before {
  content: '';
  position: absolute;
  left: 15px;
  top: 16px;
  bottom: 16px;
  width: 2px;
  background: var(--surface-2);
}

.steps li { display: flex; gap: 14px; align-items: flex-start; position: relative; }

.num {
  width: 32px;
  height: 32px;
  flex: none;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 14px;
  font-weight: 800;
  background: var(--surface-2);
  color: var(--gold);
  border: 1px solid rgba(255, 194, 75, 0.35);
}

.steps li div { display: flex; flex-direction: column; gap: 2px; padding-top: 4px; }
.steps li strong { font-size: 15px; font-weight: 700; }
.steps li span { font-size: 13px; color: var(--muted); }

.fine {
  margin-top: 20px;
  font-size: 12px;
  line-height: 1.6;
  color: #6f7a94;
}

/* Sticky CTA */
.cta-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(12, 17, 32, 0), rgba(12, 17, 32, 0.92) 35%);
}

.cta-bar .btn-primary { max-width: 440px; margin: 0 auto; }

.btn-primary {
  width: 100%;
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 0;
  border-radius: 16px;
  background: linear-gradient(180deg, var(--gold), var(--gold-2));
  color: #2a1700;
  font-family: inherit;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.01em;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 10px 30px -8px rgba(255, 159, 46, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.5);
  transition: transform 0.15s ease, filter 0.2s ease;
}

.btn-primary:hover { filter: brightness(1.05); }
.btn-primary:active { transform: translateY(1px); }
.btn-primary:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
.btn-primary[aria-disabled="true"] { filter: grayscale(0.8) brightness(0.6); box-shadow: none; cursor: not-allowed; }

/* Bottom sheet */
.sheet-backdrop {
  position: fixed;
  inset: 0;
  z-index: 20;
  background: rgba(4, 7, 15, 0.6);
  backdrop-filter: blur(3px);
  animation: fade 0.2s ease;
}

.sheet {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  max-width: 480px;
  margin: 0 auto;
  padding: 10px 20px calc(20px + env(safe-area-inset-bottom));
  border-radius: 24px 24px 0 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-bottom: 0;
  animation: rise 0.25s ease;
}

.grabber { width: 40px; height: 4px; margin: 0 auto 16px; border-radius: 4px; background: var(--surface-2); }

.sheet h2 { font-size: 20px; font-weight: 800; }

.checks { list-style: none; margin: 14px 0 18px; display: flex; flex-direction: column; gap: 10px; }

.checks li {
  position: relative;
  padding-left: 26px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--muted);
}

.checks li::before {
  content: '';
  position: absolute;
  left: 2px;
  top: 4px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230c1120' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5 9-10'/%3E%3C/svg%3E") center / 10px no-repeat;
}

/* Human check */
.human {
  display: flex;
  gap: 12px;
  align-items: center;
  min-height: 64px;
  padding: 12px 14px;
  border-radius: 14px;
  background: var(--surface-2);
  border: 1px solid var(--line);
}

.human-box {
  position: relative;
  width: 28px;
  height: 28px;
  flex: none;
  border-radius: 6px;
  border: 2px solid #5b6684;
  background: #0f1528;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: border-color 0.2s, background 0.2s;
}

.human-box:hover { border-color: var(--gold); }
.human-box:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

.human-box .spinner,
.human-box .tick { display: none; }

.human-box .spinner {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 3px solid rgba(255, 194, 75, 0.25);
  border-top-color: var(--gold);
  animation: spin 0.7s linear infinite;
}

.human-box .tick { width: 20px; height: 20px; stroke: #0c1120; stroke-width: 3.5; }

.human.loading .human-box { border-color: transparent; background: none; cursor: progress; }
.human.loading .spinner { display: block; }
.human.ok .human-box { border-color: var(--green); background: var(--green); cursor: default; }
.human.ok .tick { display: block; }

.human-text { flex: 1; font-size: 15px; font-weight: 600; }

.human-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-size: 10px;
  color: var(--muted);
}

.human-badge svg { width: 22px; height: 22px; color: var(--muted); }

.human-msg { min-height: 20px; margin: 6px 2px 8px; font-size: 13px; color: var(--muted); }
.human-msg.err { color: var(--coral); }
.human-msg.ok { color: var(--green); }

@keyframes spin { to { transform: rotate(360deg); } }

.btn-ghost {
  width: 100%;
  min-height: 48px;
  margin-top: 6px;
  border: 0;
  background: none;
  color: var(--muted);
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.btn-ghost:hover { color: var(--text); }

@keyframes rise { from { transform: translateY(100%); } }
@keyframes fade { from { opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
  .sheet, .sheet-backdrop { animation: none; }
}
