/* SITS guest portal — dark navy (matching the existing DITS booking look).
   Event theming via --event-* tokens; bg image sits behind a dark overlay. */
:root {
  --bg: #0B1120; --panel: #0E1624; --card: #141D2E; --card2: #182338;
  --border: #263349; --border-strong: #35507A;
  --text: #E8ECF2; --muted: #8B98AA;
  --blue: #5B9BD9; --green: #4CC38A; --orange: #F0A24A; --red: #E5645C;
  --primary: var(--event-primary, #0B1F3F);
  --accent: var(--event-accent, #C9A227);
  --warm: var(--event-warm, #B3312B);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body.sits-guest {
  color: var(--text);
  font: 16px/1.5 Inter, -apple-system, 'Segoe UI', sans-serif;
  min-height: 100vh;
  background: linear-gradient(rgba(9,14,22,.60), rgba(9,14,22,.60)), var(--event-bg-image, none) center/cover fixed, var(--bg);
  background-color: var(--bg);
}
main {
  max-width: 680px; margin: 8px auto 40px; padding: 8px 20px 20px;
  background: var(--panel); border: 1px solid var(--border); border-radius: 16px;
}
@media (max-width: 720px) { main { margin: 8px 10px 32px; padding: 8px 12px 16px; } }
.hero { background: linear-gradient(to bottom, var(--primary), transparent); color: #fff; padding: 32px 16px 16px; text-align: center; position: relative; }
.hero h1 { font-family: var(--event-font-display, inherit); font-size: 30px; text-shadow: 0 1px 8px rgba(0,0,0,.5); }
.hero .logo { max-height: 156px; max-width: min(80vw, 420px); width: auto; height: auto; display: block; margin: 0 auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.btn-row { display: flex; gap: 12px; margin-top: 20px; }
.btn-row .btn { margin-top: 0; }
.btn-row .btn-secondary { flex: 1; }
.btn-row .btn-primary { flex: 2; }
.card > .btn-secondary, .card > .btn-row { margin-top: 20px; }
.hero .lang { position: absolute; top: 12px; right: 16px; font-size: 13px; display: flex; gap: 2px; }
.hero .lang a { color: #fff; text-decoration: none; opacity: .6; padding: 6px 8px; min-height: 32px; border-radius: 6px; transition: opacity .12s, background-color .12s; }
.hero .lang a:hover { opacity: 1; }
.hero .lang a.on { opacity: 1; background: rgba(255,255,255,.12); font-weight: 600; }
.muted { color: var(--muted); }
.foot { text-align: center; padding: 24px; font-size: 13px; color: var(--muted); }
.foot-links { margin-top: 8px; }
/* per-guest ticket PDF link under a QR code (groups) */
.ticket-dl { display: inline-block; margin-top: 8px; font-size: 13px; color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.foot-links a { color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }
.foot-links a:hover { color: var(--text); }
/* public terms / privacy page */
.card.legal { line-height: 1.6; font-size: 14px; }
.card.legal h3 { font-size: 18px; font-weight: 700; margin: 0 0 12px; }
.card.legal h4 { font-size: 15px; font-weight: 600; margin: 18px 0 6px; }
.card.legal p { margin: 6px 0; }
.card.legal ul { margin: 6px 0 12px 20px; padding: 0; }
.card.legal li { margin: 3px 0; }
.card.legal br { display: block; content: ""; margin: 4px 0; }
h2, h3 { color: var(--text); }

.card {
  background: var(--card); border: 1px solid var(--border); border-radius: 12px;
  padding: 24px 18px; margin: 16px 0;
}
main a { color: var(--accent); }
main a:visited { color: var(--accent); }
main a.gday, main a.slot, main a.btn { color: var(--text); }
main .step-links a { color: var(--muted); }
main .step-links a:hover { color: var(--text); }
.notice { background: var(--card2); border-left: 3px solid var(--accent); padding: 12px 16px; margin: 16px 0; font-size: 14px; border-radius: 0 8px 8px 0; }
.code-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 12px; }
.code-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 6px; background: var(--card2); border: 1px solid var(--border); font-size: 13px; color: var(--text); font-variant-numeric: tabular-nums; letter-spacing: .3px; }
.flight-summary { margin: 2px 0 4px; font-size: 15px; }
.flight-summary strong { color: var(--text); font-weight: 600; }
.step-links { margin: 0 0 12px; font-size: 14px; }
.step-links a { color: var(--muted); text-decoration: none; transition: color .12s; }
.step-links a:hover { color: var(--text); text-decoration: underline; }
.form-section { font-size: 15px; font-weight: 600; margin: 24px 0 0; padding-top: 16px; border-top: 1px solid var(--border); }
.empty-state { padding: 24px 0; text-align: center; }
.days-hint { font-size: 12px; margin-top: 12px; }

/* progress: numbered circles, check for done, connectors */
.steps { display: flex; align-items: flex-start; list-style: none; margin: 20px 4px 8px; }
.steps li { flex: 1; text-align: center; position: relative; font-size: 12px; color: var(--muted); }
.steps li .dot {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; border-radius: 50%;
  border: 2px solid var(--border-strong); background: var(--panel);
  font-weight: 700; font-size: 13px; color: var(--muted);
  position: relative; z-index: 1;
}
.steps li .lbl { display: block; margin-top: 5px; }
.steps li:not(:first-child)::before {
  content: ''; position: absolute; top: 15px; left: calc(-50% + 15px); right: calc(50% + 15px);
  height: 2px; background: var(--border-strong);
}
.steps li.done .dot { background: var(--accent); border-color: var(--accent); color: #fff; }
.steps li.done:not(:first-child)::before, .steps li.current:not(:first-child)::before { background: var(--accent); }
.steps li.current { color: var(--text); font-weight: 600; }
.steps li.current .dot { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: 0 0 0 4px rgba(201,162,39,.22); }
@media (max-width: 560px) { .steps li:not(.current) .lbl { visibility: hidden; } }

/* buttons */
.btn {
  display: inline-block; width: 100%; text-align: center; padding: 14px 20px; min-height: 44px;
  border-radius: 8px; border: 1px solid transparent; font: inherit; font-weight: 600;
  cursor: pointer; text-decoration: none; font-size: 17px;
  transition-property: background-color, border-color, opacity, transform, box-shadow;
  transition-duration: .12s; transition-timing-function: cubic-bezier(.2, 0, 0, 1);
}
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.25), 0 1px 0 rgba(255,255,255,.08) inset; }
.btn-primary:hover { filter: brightness(1.06); }
.btn-secondary { background: transparent; color: var(--text); border-color: var(--border-strong); }
.btn-secondary:hover { border-color: var(--accent); }
.btn-danger { background: transparent; color: var(--red); border-color: var(--red); }
.btn-danger:hover { background: rgba(229,100,92,.1); }
.btn:active:not(:disabled) { transform: scale(.96); }
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.btn:disabled { opacity: .4; cursor: not-allowed; }
main a.btn { color: inherit; }

/* month calendar (day picker) */
.gcal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.gcal-h { text-align: center; font-size: 11px; text-transform: uppercase; letter-spacing: 1px; color: var(--muted); padding: 4px 0 2px; }
.gday {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px;
  min-height: 48px; border-radius: 8px; border: 1px solid var(--border-strong); background: var(--card2);
  color: var(--text); text-decoration: none; padding: 4px 2px;
  transition-property: border-color, background-color, transform; transition-duration: .12s;
}
.gday .daynum { font-size: 17px; font-weight: 700; line-height: 1.2; font-variant-numeric: tabular-nums; }
.gday .sub { font-size: 10px; line-height: 1.2; color: var(--orange); font-weight: 600; text-align: center; }
.gday { position: relative; overflow: hidden; }
.gday .cap { position: absolute; left: 0; right: 0; bottom: 0; height: 4px; }
.gday.ok .cap { background: var(--green); }
.gday.scarce .cap { background: var(--orange); }
.gday.empty { border: 0; background: transparent; }
.gday.off { border-color: transparent; background: transparent; color: var(--muted); opacity: .4; cursor: default; }
.gday.off .daynum { font-weight: 500; }
a.gday:hover { border-color: var(--accent); background: rgba(201,162,39,.08); }
a.gday:active { transform: scale(.96); }
a.gday:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.gday.selected { border-color: var(--accent); background: rgba(201,162,39,.16); }
@media (max-width: 400px) { .gday { min-height: 44px; } .gday .daynum { font-size: 15px; } }

/* time slots */
.slot-group { font-size: 12px; text-transform: uppercase; letter-spacing: 1px; color: var(--muted); margin: 18px 0 8px; font-weight: 600; }
.slot-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
@media (max-width: 480px) { .slot-grid { grid-template-columns: repeat(3, 1fr); } }
.slot-form { display: contents; }
.slot {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  width: 100%; min-height: 52px; padding: 8px 6px 10px; border-radius: 8px; position: relative; overflow: hidden;
  border: 1px solid var(--border-strong); background: var(--card2); color: var(--text);
  font: inherit; text-decoration: none; cursor: pointer;
  transition-property: border-color, background-color, transform; transition-duration: .12s;
}
.slot .sl-time { font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.2; }
.slot .sl-title { font-size: 11px; color: var(--muted); }
.slot .sl-sub { font-size: 10px; font-weight: 600; line-height: 1.2; }
.slot .sl-sub.low { color: var(--orange); }
.slot .sl-sub.full { color: var(--red); }
.slot .sl-sub.ok { color: var(--muted); font-weight: 500; }
.need-note { font-size: 13px; margin: -4px 0 8px; }
.slot:hover:not(.disabled) { border-color: var(--accent); background: rgba(201,162,39,.08); }
.slot:active:not(.disabled) { transform: scale(.96); }
.slot:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.slot.disabled { opacity: .45; cursor: not-allowed; border-color: var(--border); }
.slot .cap { position: absolute; left: 0; right: 0; bottom: 0; height: 4px; }
.slot.ok .cap { background: var(--green); }
.slot.low .cap { background: var(--orange); }

/* day tiles (legacy calendar style, still used by rebooking) */
.pick-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.pick {
  display: block; text-align: center; padding: 10px 4px; min-height: 44px;
  border: 1px solid var(--border-strong); border-radius: 10px;
  text-decoration: none; color: var(--text); background: var(--card2);
}
.pick:hover { border-color: var(--accent); }
.pick .sub { display: block; font-size: 12px; color: var(--muted); }
.pick.scarce .sub { color: var(--orange); font-weight: 600; }
.month-head { margin: 18px 0 8px; font-size: 15px; color: var(--muted); font-weight: 600; }
.pick .dow { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: 1px; color: var(--muted); }
.pick .daynum { display: block; font-size: 25px; font-weight: 700; line-height: 1.2; }

/* shift rows (Lunch / Tapas & Wine / Dinner style) */
.shiftrow {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--card2); border: 1px solid var(--border); border-radius: 12px;
  padding: 18px 18px; margin: 10px 0; text-decoration: none; color: var(--text);
}
a.shiftrow:hover { border-color: var(--accent); }
.shiftrow .st-title { font-size: 18px; font-weight: 700; }
.shiftrow .st-time { font-size: 14px; color: var(--muted); margin-top: 2px; }
.shiftrow .st-desc { font-size: 13px; color: var(--muted); margin-top: 2px; }
.shiftrow .st-status { font-weight: 700; font-size: 15px; white-space: nowrap; }
.st-status.free { color: var(--green); }
.st-status.low { color: var(--orange); }
.st-status.full { color: var(--red); }
.shiftrow.disabled { opacity: .55; cursor: not-allowed; }

/* seat map */
#seatmap { display: grid; gap: 4px; justify-content: center; margin: 16px 0; }
.seat {
  width: 34px; height: 34px; border-radius: 6px; border: 2px solid var(--border-strong);
  display: flex; align-items: center; justify-content: center;
  font-size: 9px; font-weight: 600; cursor: pointer; user-select: none;
  background: var(--card2); color: var(--text);
}
.seat.free:hover { border-color: var(--accent); }
.seat.mine { background: var(--accent); border-color: var(--accent); color: #fff; }
.seat.booked, .seat.held { background: repeating-linear-gradient(45deg, #232B3A, #232B3A 4px, #1B2230 4px, #1B2230 8px); color: #5A6577; cursor: not-allowed; border-color: var(--border); }
.legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: 13px; margin: 8px 0; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 16px; height: 16px; border-radius: 4px; display: inline-block; border: 2px solid var(--border-strong); background: var(--card2); }
.legend i.mine { background: var(--accent); border-color: var(--accent); }
.legend i.taken { background: repeating-linear-gradient(45deg, #232B3A, #232B3A 4px, #1B2230 4px, #1B2230 8px); }
#countdown { font-weight: 600; color: var(--orange); }

/* forms */
label { display: block; font-size: 14px; color: var(--muted); margin: 14px 0 4px; }
input, select {
  width: 100%; padding: 12px; min-height: 44px; border: 1px solid var(--border-strong);
  border-radius: 8px; font: inherit; background: var(--card2); color: var(--text);
  transition: border-color .12s, box-shadow .12s;
}
input:focus, select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(201,162,39,.25); }
input::placeholder { color: var(--muted); opacity: .7; }
.code-row { position: relative; margin-top: 8px; }
.code-row:first-child { margin-top: 0; }
.code-input { text-transform: uppercase; font-size: 18px; letter-spacing: 2px; text-align: center; font-variant-numeric: tabular-nums; }
.code-row .code-input { padding-right: 44px; padding-left: 44px; }
.code-del { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 32px; height: 32px; border-radius: 6px; background: none; border: 0; color: var(--muted); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; transition: color .12s, background-color .12s; }
.code-del:hover { color: var(--text); background: rgba(255,255,255,.08); }
.guest-row { margin-top: 4px; }
select {
  appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238B98AA' stroke-width='2' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center; padding-right: 36px; cursor: pointer;
}
.field-err { color: var(--red); font-size: 13px; margin-top: 4px; }
.consent { display: flex; gap: 12px; align-items: flex-start; margin: 14px 0; font-size: 14px; }
.consent input { width: 20px; height: 20px; min-height: 0; margin-top: 1px; flex-shrink: 0; accent-color: var(--accent); }
.consent label { margin: 0; color: var(--text); line-height: 1.5; cursor: pointer; }
.alert { padding: 12px 16px; border-radius: 10px; margin: 16px 0; border: 1px solid var(--red); color: var(--red); background: rgba(229,100,92,.08); }

table.summary { width: 100%; border-collapse: collapse; font-size: 15px; }
table.summary td { padding: 6px 0; border-bottom: 1px solid var(--border); }
table.summary td.num { text-align: right; font-variant-numeric: tabular-nums; }
.total { font-size: 20px; font-weight: 700; text-align: right; margin: 12px 0; }
.lang-toggle { margin-top: 16px; font-size: 12px; text-align: center; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }


/* Hold countdown bar — sticks to the top of the booking card, resets whenever the seat selection changes */
.holdbar {
  position: sticky; top: 8px; margin: 4px auto 0; width: fit-content;
  z-index: 200; display: flex; align-items: center; gap: 10px;
  padding: 8px 18px; border-radius: 999px;
  background: rgba(11, 22, 44, .92); border: 1px solid rgba(255,255,255,.18);
  backdrop-filter: blur(6px);
  box-shadow: 0 6px 24px rgba(0,0,0,.45);
  font-size: 13px; color: rgba(255,255,255,.75);
}
.holdbar strong {
  font-size: 16px; letter-spacing: 1px; color: #fff;
  font-variant-numeric: tabular-nums; min-width: 52px; text-align: center;
}
.holdbar.warn { border-color: rgba(210,153,34,.7); }
.holdbar.warn strong { color: #E8B93E; }
.holdbar.crit { border-color: rgba(248,81,73,.8); animation: sits-hold-pulse 1s infinite; }
.holdbar.crit strong { color: #FF6B64; }
@keyframes sits-hold-pulse {
  0%, 100% { box-shadow: 0 6px 24px rgba(0,0,0,.45); }
  50% { box-shadow: 0 6px 24px rgba(248,81,73,.35); }
}


/* Who-is-flying steppers above the seat map */
.who { display: flex; gap: 24px; flex-wrap: wrap; margin: 12px 0 16px; }
.who .grp { display: flex; align-items: center; gap: 10px; }
.who .grp > span { font-size: 14px; color: rgba(255,255,255,.85); min-width: 92px; }
.stepper { display: flex; align-items: center; gap: 0; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
.stepper button {
  width: 38px; height: 38px; border: 0; background: rgba(255,255,255,.06);
  color: #fff; font-size: 18px; cursor: pointer; line-height: 1;
}
.stepper button:hover { background: rgba(255,255,255,.12); }
.stepper button:disabled { opacity: .35; cursor: not-allowed; }
.stepper .val {
  width: 44px; text-align: center; font-size: 16px; font-weight: 700;
  font-variant-numeric: tabular-nums; color: #fff;
}
.need-hint { font-size: 13px; margin: 8px 0; color: rgba(255,255,255,.65); }
.need-hint.ok { color: #3FB950; }
