/* Hop A Event — payment, tickets, door (shares the black & gold palette of site.css) */
:root {
  --black: #08090D; --black-2: #0E1017; --black-3: #151823;
  --gold: #D6B36A; --gold-warm: #F0D9A0; --gold-deep: #9c7c3c;
  --frost: #E9EEF4; --ice: #A9C7DA; --muted: #9A9AA3;
  --line: rgba(214, 179, 106, 0.22); --line-soft: rgba(233, 238, 244, 0.1);
  --glass: rgba(18, 20, 30, 0.72);
  --ok: #22c55e; --bad: #ef4444; --warn: #f59e0b; --vip: #D6B36A;
  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: "Manrope", "Segoe UI", system-ui, -apple-system, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; color: var(--frost); font: 16px/1.55 var(--sans); -webkit-font-smoothing: antialiased;
  background:
    radial-gradient(circle at 18% 12%, rgba(214, 179, 106, .10) 0 1.5px, transparent 2.5px) 0 0/110px 110px,
    radial-gradient(circle at 72% 64%, rgba(233, 238, 244, .07) 0 1px, transparent 2px) 0 0/150px 150px,
    radial-gradient(ellipse at 50% -10%, #2a1420 0, transparent 60%),
    linear-gradient(170deg, #0b0d14, #08090D 60%) fixed;
  padding: env(safe-area-inset-top) 0 env(safe-area-inset-bottom);
}
a { color: var(--gold-warm); text-underline-offset: 3px; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--gold-warm); outline-offset: 3px; }

.wrap { max-width: 560px; margin: 0 auto; padding: 18px 16px 48px; }
.wrap.wide { max-width: 1080px; }
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.brand { font: 600 22px/1 var(--serif); letter-spacing: .18em; color: var(--gold-warm); text-decoration: none; }
.top .mut a { color: var(--muted); }
h1 { font: 500 clamp(30px, 7vw, 40px)/1.1 var(--serif); margin: 6px 0 6px; color: #fff; letter-spacing: .02em; }
h2 { font: 600 20px/1.2 var(--sans); margin: 0 0 10px; }
.lead { color: var(--muted); margin: 0 0 18px; }
.mut { color: var(--muted); font-size: 14px; }
.small { font-size: 13px; }

.card { background: var(--glass); border: 1px solid var(--line); border-radius: 18px; padding: 18px; margin-bottom: 14px; backdrop-filter: blur(8px); }
.card.soft { border-color: var(--line-soft); }

label.f { display: block; font-size: 13px; color: var(--muted); margin: 0 0 12px; }
label.f > input, label.f > select, label.f > textarea { margin-top: 5px; }
input, select, textarea {
  width: 100%; padding: 12px 14px; border-radius: 12px; border: 1px solid rgba(233, 238, 244, .16);
  background: rgba(255, 255, 255, .05); color: #fff; font-size: 16px;
}
input::placeholder { color: #7d8090; }
select option { background: #151823; }
input:focus, select:focus, textarea:focus { border-color: var(--gold); outline: none; }
.row { display: flex; gap: 10px; }
.row > * { flex: 1; min-width: 0; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 18px; border-radius: 999px;
  border: 1px solid transparent; font-weight: 700; letter-spacing: .06em; font-size: 14px; cursor: pointer; text-decoration: none;
  background: linear-gradient(180deg, #e5c77f, #c39b4f); color: #17120a; transition: filter .15s, transform .1s;
}
.btn:hover { filter: brightness(1.06); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: default; }
.btn.block { width: 100%; }
.btn.ghost { background: transparent; color: var(--frost); border-color: rgba(233, 238, 244, .22); }
.btn.wa { background: #25d366; color: #062b14; }
.btn.danger { background: transparent; color: #fca5a5; border-color: rgba(239, 68, 68, .45); }
.btn.sm { padding: 8px 13px; font-size: 12px; }
.btn.test { background: repeating-linear-gradient(135deg, #e5c77f 0 14px, #d8b563 14px 28px); }

.err { color: #fca5a5; font-size: 14px; margin: 4px 0 10px; }
.ok-msg { color: #86efac; font-size: 14px; }
.badge { display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .06em; padding: 3px 9px; border-radius: 999px; border: 1px solid currentColor; }
.badge.vip { color: var(--vip); } .badge.ok { color: var(--ok); } .badge.bad { color: #fca5a5; } .badge.warn { color: var(--warn); } .badge.mutd { color: var(--muted); }
.test-banner { background: repeating-linear-gradient(135deg, #3a2a0c 0 12px, #2b1f08 12px 24px); color: var(--gold-warm); border: 1px solid var(--gold-deep); border-radius: 12px; padding: 9px 12px; font-size: 13px; margin-bottom: 14px; }

/* summary lines */
.lines { margin: 0; padding: 0; }
.lines div { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-top: 1px solid var(--line-soft); }
.lines div:first-child { border-top: 0; }
.lines dt { color: var(--muted); }
.lines dd { margin: 0; text-align: right; font-weight: 600; }
.lines .total dt, .lines .total dd { color: var(--gold-warm); font-size: 19px; font-weight: 700; }
.lines .disc dd { color: #86efac; }

/* tickets */
.tickets { display: grid; gap: 16px; }
.ticket { text-align: center; }
.ticket img { width: 100%; max-width: 360px; height: auto; border-radius: 16px; margin: 0 auto 10px; display: block; box-shadow: 0 20px 50px -20px rgba(0, 0, 0, .8); }
.ticket .actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.ticket.used img { opacity: .45; filter: grayscale(.6); }

/* toast */
.toast { position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom)); transform: translateX(-50%); background: #151823; border: 1px solid var(--line); color: #fff; padding: 11px 18px; border-radius: 12px; z-index: 50; max-width: 90vw; font-size: 14px; }
.toast.err { border-color: rgba(239, 68, 68, .6); }

/* ---------- door ---------- */
/* door: site palette (black / burgundy / gold), calm and static so it doesn't tire the eyes at night */
body.door {
  background:
    radial-gradient(circle at 20% 18%, rgba(214, 179, 106, .07) 0 1.2px, transparent 2.2px) 0 0/120px 120px,
    radial-gradient(circle at 70% 62%, rgba(233, 238, 244, .05) 0 1px, transparent 2px) 0 0/170px 170px,
    radial-gradient(ellipse 120% 55% at 50% -8%, rgba(90, 26, 44, .75) 0, rgba(58, 16, 28, .35) 45%, transparent 75%),
    radial-gradient(ellipse 90% 40% at 50% 108%, rgba(58, 16, 28, .45) 0, transparent 70%),
    linear-gradient(180deg, #0b0a0f 0%, #08090D 100%) fixed;
  background-attachment: fixed;
}
.door .card { background: rgba(14, 16, 24, .82); border-color: rgba(214, 179, 106, .2); box-shadow: 0 18px 40px -24px rgba(0, 0, 0, .9); }
.door .brand { color: var(--gold-warm); }
.door h2 { font-family: var(--serif); font-weight: 600; letter-spacing: .04em; color: var(--gold-warm); }
.door .test-banner { margin-bottom: 12px; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 12px; }
.stat { background: rgba(14, 16, 24, .82); border: 1px solid rgba(214, 179, 106, .2); border-radius: 14px; padding: 10px; text-align: center; }
.stat b { display: block; font-size: 26px; line-height: 1.1; color: #fff; }
.stat span { font-size: 12px; color: var(--muted); letter-spacing: .04em; }
.door-hopex { display: block; width: 260px; max-width: 70%; height: auto; margin: 0 auto -6px; border-radius: 0; -webkit-mask-image: radial-gradient(ellipse 58% 78% at 50% 58%, #000 50%, transparent 100%); mask-image: radial-gradient(ellipse 58% 78% at 50% 58%, #000 50%, transparent 100%); }
.door-sub { font-size: 12px; letter-spacing: .28em; color: var(--muted); text-transform: uppercase; margin: -2px 0 14px; }
.door-divider { height: 1px; background: linear-gradient(90deg, transparent, rgba(214, 179, 106, .45), transparent); border: 0; margin: 4px 0 16px; }
#reader { width: 100%; border-radius: 14px; overflow: hidden; background: #000; min-height: 0; }
#reader video { border-radius: 14px; }
.result { border-radius: 18px; padding: 26px 16px; text-align: center; color: #fff; font-weight: 800; font-size: 30px; line-height: 1.15; margin: 12px 0; }
.result small { display: block; font-size: 17px; font-weight: 600; margin-top: 8px; opacity: .95; }
.result .sub2 { display: block; font-size: 14px; font-weight: 500; margin-top: 4px; opacity: .85; }
.result.ok { background: #15803d; } .result.vip { background: linear-gradient(160deg, #a16207, #78350f); } .result.warn { background: #b45309; } .result.bad { background: #b91c1c; }
.result .undo { margin-top: 12px; }
.list-item { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line-soft); }
.list-item:first-child { border-top: 0; }
.list-item small { color: var(--muted); display: block; }
.gate { min-height: 80vh; display: flex; align-items: center; justify-content: center; }
.gate .card { width: 100%; max-width: 360px; text-align: center; }

/* ---------- admin ---------- */
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.tabs button { padding: 9px 14px; border-radius: 999px; border: 1px solid var(--line); background: transparent; color: var(--frost); font-weight: 600; cursor: pointer; font-size: 14px; }
.tabs button.on { background: var(--gold); color: #17120a; border-color: var(--gold); }
table.t { width: 100%; border-collapse: collapse; font-size: 14px; }
table.t th, table.t td { text-align: left; padding: 9px 8px; border-top: 1px solid var(--line-soft); vertical-align: top; }
table.t th { color: var(--muted); font-weight: 600; font-size: 12px; letter-spacing: .04em; border-top: 0; }
.scroll-x { overflow-x: auto; }
.tk { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 3px 0; }
.tk code { font-size: 12px; color: var(--muted); }
.mono { font-family: ui-monospace, Menlo, Consolas, monospace; }
dialog { background: #12141d; color: var(--frost); border: 1px solid var(--line); border-radius: 18px; padding: 20px; width: min(520px, 94vw); }
dialog::backdrop { background: rgba(0, 0, 0, .6); }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
