/* SatSet customer UI. Mobile first: customers arrive by scanning a QR on their phone. */
:root {
    --bg: #f3f7f7;
    --surface: #ffffff;
    --ink: #142726;
    --muted: #5a6d6c;
    --line: #dbe6e5;
    --brand: #2e6d6d;
    --brand-strong: #235656;
    --brand-soft: #e4efef;
    --dark: #12302f;
    --accent: #a6e3d6;
    --amber: #8a5a0b;
    --amber-soft: #fff4dc;
    --red: #b42318;
    --red-soft: #fdecea;
    --radius: 14px;
    --shadow: 0 1px 2px rgba(20, 39, 38, .05), 0 8px 24px rgba(20, 39, 38, .06);
    --ease: cubic-bezier(.23, 1, .32, 1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    background: var(--bg);
    color: var(--ink);
    font: 16px/1.55 Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
}
main { flex: 1; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button, a { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
img { display: block; max-width: 100%; }
h1, h2, h3, p, ol, ul { margin: 0; }
ol, ul { padding: 0; list-style: none; }
h1, h2, h3 { line-height: 1.2; overflow-wrap: anywhere; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 3px; border-radius: 4px; }
.skip-link:not(:focus) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link:focus { position: fixed; top: 10px; left: 10px; z-index: 99; background: white; padding: 12px; }

/* Shell */
.topbar { position: sticky; top: 0; z-index: 10; background: rgba(255, 255, 255, .92); border-bottom: 1px solid var(--line); backdrop-filter: blur(12px); }
.topbar-inner { max-width: 1080px; margin: 0 auto; min-height: 60px; padding: 0 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-size: 20px; font-weight: 800; }
.brand-mark { width: 32px; height: 32px; border-radius: 8px; object-fit: cover; }
.topbar-caption { font-size: 12px; font-weight: 600; color: var(--muted); }
.footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 16px; max-width: 1080px; width: 100%; margin: 0 auto; padding: 20px 16px calc(20px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); font-size: 12px; color: var(--muted); }
.footer strong { color: var(--ink); }
.flash { max-width: 520px; margin: 16px auto 0; padding: 12px 16px; border-radius: 10px; background: var(--brand-soft); color: var(--brand-strong); font-size: 14px; font-weight: 600; }

/* Layout */
.page { max-width: 520px; margin: 0 auto; padding: 20px 16px 40px; display: grid; gap: 16px; }
.page-wide { max-width: 1080px; display: block; padding-top: 40px; }

/* Type */
.eyebrow { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--brand); }
.eyebrow-light { color: var(--accent); }
.section-title { font-size: 26px; margin: 6px 0 24px; }
.muted { color: var(--muted); font-size: 15px; }
.fine-print { font-size: 13px; color: var(--muted); padding-top: 14px; border-top: 1px solid var(--line); }
.live-note { font-size: 12px; color: var(--muted); }
.center { text-align: center; }
.back-link { justify-self: start; font-size: 14px; font-weight: 600; color: var(--brand); padding: 6px 0; }

/* Components */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; display: grid; gap: 16px; }
.card-title { font-size: 16px; }

.pill { justify-self: start; display: inline-flex; align-items: center; gap: 8px; min-height: 30px; padding: 0 12px; border-radius: 999px; font-size: 13px; font-weight: 700; background: var(--brand-soft); color: var(--brand-strong); }
.pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.pill-closed { background: var(--amber-soft); color: var(--amber); }

.button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 0 20px; border: 1px solid transparent; border-radius: 12px; font-weight: 700; line-height: 1.2; text-align: center; transition: background-color 160ms var(--ease), transform 160ms var(--ease); }
.button:active { transform: scale(.98); }
.button-primary { background: var(--brand); color: white; }
.button-block { width: 100%; min-height: 54px; font-size: 17px; }
.button-ghost-danger { background: transparent; border-color: var(--line); color: var(--red); }

.alert { padding: 14px 16px; border-radius: 12px; background: var(--amber-soft); color: var(--amber); font-size: 14px; font-weight: 600; }

.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.stat { display: grid; gap: 4px; padding: 14px; border-radius: 12px; background: var(--bg); }
.stat > span { font-size: 13px; color: var(--muted); }
.stat strong { font-size: 30px; line-height: 1.1; font-weight: 800; font-variant-numeric: tabular-nums; }
.stat small { font-size: 13px; font-weight: 600; color: var(--muted); }

.steps { display: grid; gap: 14px; }
.steps li { display: flex; align-items: flex-start; gap: 12px; }
.steps strong { display: block; font-size: 15px; }
.steps li span:not(.step-number) { display: block; font-size: 14px; color: var(--muted); }
.step-number { flex-shrink: 0; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; background: var(--brand-soft); color: var(--brand-strong); font-size: 13px; font-weight: 800; }

/* Home */
.home-hero { position: relative; isolation: isolate; color: #f3f8f8; background: var(--dark) url('/images/satset-food-hero.jpg') center right / cover no-repeat; }
.home-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(10, 32, 31, .97) 0%, rgba(10, 32, 31, .85) 45%, rgba(10, 32, 31, .35) 100%); }
.home-hero-inner { max-width: 1080px; margin: 0 auto; padding: 64px 16px; }
.home-hero h1 { max-width: 520px; margin: 10px 0 14px; font-size: clamp(32px, 7vw, 52px); font-weight: 800; }
.home-hero-text { max-width: 420px; color: #cddcdb; }
.hero-points { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 22px; font-size: 13px; color: #d5e3e2; }
.hero-points li::before { content: ""; display: inline-block; width: 6px; height: 6px; margin-right: 8px; border-radius: 50%; background: var(--accent); vertical-align: middle; }
.steps-row li { padding: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }

/* Outlet */
.outlet-photo { position: relative; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--radius); background: #dbe6e5; }
.outlet-photo img { width: 100%; height: 100%; object-fit: cover; }
.outlet-photo > span { display: none; }
.outlet-header { display: grid; gap: 8px; }
.outlet-header h1 { font-size: 28px; }
.serving { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border-radius: 12px; background: var(--dark); color: #cddcdb; font-size: 14px; }
.serving strong { color: var(--accent); font-size: 22px; font-variant-numeric: tabular-nums; }
.cta { display: grid; gap: 10px; }
.cta-note { font-size: 13px; color: var(--muted); text-align: center; }

/* Ticket */
.ticket { position: relative; display: grid; gap: 6px; padding: 22px 20px 20px; text-align: center; background: var(--surface); border: 1px solid var(--line); border-top: 6px solid var(--brand); border-radius: var(--radius); box-shadow: var(--shadow); }
.ticket-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; text-align: left; }
.ticket .pill { justify-self: auto; }
.ticket-number { margin: 8px 0 0; font-size: clamp(56px, 18vw, 76px); font-weight: 800; line-height: 1.1; letter-spacing: -.02em; color: var(--brand); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.ticket-meta { color: var(--muted); font-size: 14px; }
.ticket-divider { margin: 14px -20px; border-top: 2px dashed var(--line); }
.ticket .stats { text-align: left; }
.ticket-message { text-align: center; font-size: 15px; font-weight: 600; max-width: 380px; justify-self: center; }

[data-status="called"] .ticket { border-top-color: var(--accent); background: var(--dark); color: #f3f8f8; border-color: var(--dark); }
[data-status="called"] .ticket-number, [data-status="called"] .eyebrow { color: var(--accent); }
[data-status="called"] .ticket-meta, [data-status="called"] .stat > span, [data-status="called"] .stat small { color: #b5c9c8; }
[data-status="called"] .stat { background: rgba(255, 255, 255, .08); }
[data-status="called"] .ticket-divider { border-color: rgba(255, 255, 255, .18); }
[data-status="called"] .pill { background: var(--accent); color: var(--dark); }
[data-status="called"] .ticket-message { color: var(--brand-strong); }
[data-status="completed"] .ticket, [data-status="cancelled"] .ticket, [data-status="skipped"] .ticket { border-top-color: var(--line); }
[data-status="completed"] .ticket-number, [data-status="cancelled"] .ticket-number, [data-status="skipped"] .ticket-number { color: #9aa8a0; }
[data-status="cancelled"] .pill, [data-status="skipped"] .pill { background: var(--red-soft); color: var(--red); }
[data-status="completed"] .pill { background: #eef1ef; color: var(--muted); }

@media (hover: hover) and (pointer: fine) {
    .button-primary:hover { background: var(--brand-strong); }
    .button-ghost-danger:hover { background: var(--red-soft); }
    .back-link:hover { text-decoration: underline; }
}
@media (min-width: 720px) {
    .steps-row { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .page { padding-top: 32px; }
}
@media (max-width: 380px) {
    .topbar-caption { display: none; }
    .stat strong { font-size: 26px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* Web sign-up */
.signup { gap: 14px; }
.signup > label { font-size: 16px; }
.party-picker { display: grid; grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); gap: 8px; }
.party-option { position: relative; }
.party-option input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.party-option span { display: grid; place-items: center; height: 52px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--surface); font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; transition: background-color 150ms var(--ease), border-color 150ms var(--ease); }
.party-option input:checked + span { background: var(--brand); border-color: var(--brand); color: white; }
.party-option input:focus-visible + span { outline: 3px solid var(--brand); outline-offset: 2px; }
.party-input { width: 100%; min-height: 52px; padding: 0 14px; border: 1.5px solid var(--line); border-radius: 12px; font-size: 18px; }
.form-error { color: var(--red); font-size: 14px; font-weight: 600; }
.my-ticket { text-align: center; justify-items: center; }
.my-ticket > span { color: var(--muted); font-size: 14px; }
.my-ticket strong { font-size: 40px; line-height: 1.1; color: var(--brand); font-variant-numeric: tabular-nums; }
