/* Chu-Swap shared styles: "warm and appetizing". A restaurant's own brand colour overrides --accent at runtime (common.js). */
:root {
  --bg: #fbefe0;            /* warm cream */
  --surface: #fffaf3;
  --surface-2: #f6dfc4;
  --ink: #3b2417;           /* espresso */
  --ink-muted: #86624a;
  --border: #ecd2b3;
  --accent: #bf4f22;        /* clay */
  --accent-ink: #ffffff;
  --accent-soft: color-mix(in srgb, var(--accent) 11%, var(--surface));
  --olive: #6b7a3a;
  --butter: #f2b03a;
  --money: #4f7a24; --money-soft: #e6efcf;
  --warn: #9c3a1a; --warn-soft: #f7e0d3;
  --shadow: 0 2px 4px rgba(191,79,34,.07), 0 14px 30px -16px rgba(120,60,20,.35);
  --radius: 24px;
  color-scheme: light;      /* the site is always light, whatever the browser's dark-mode setting */
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { background: var(--bg); color: var(--ink); font-family: 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif; line-height: 1.5; -webkit-text-size-adjust: 100%; }
.wrap { max-width: 720px; margin: 0 auto; padding: 24px 16px 96px; }
.wrap.wide { max-width: 1160px; }
.wrap.mid { max-width: 960px; }
.wrap.narrow { max-width: 420px; margin-top: 56px; }

h1, h2, h3 { font-family: 'Nunito', system-ui, sans-serif; font-weight: 800; margin: 0; text-wrap: balance; letter-spacing: -.01em; }
a { color: var(--accent); }
.mono { font-family: 'IBM Plex Mono', ui-monospace, Menlo, monospace; font-variant-numeric: tabular-nums; }
.muted { color: var(--ink-muted); }
.small { font-size: 13px; }
[hidden] { display: none !important; }

/* brand mark */
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-family: 'Nunito', system-ui, sans-serif; font-weight: 800; font-size: 22px; }
.brand svg { width: 30px; height: 36px; flex: none; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.topbar a.quiet { color: var(--ink-muted); font-size: 13px; text-decoration: none; }
.topbar a.quiet:hover { color: var(--accent); text-decoration: underline; }

/* header with optional logo */
header.top { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; }
header.top img.logo { width: 60px; height: 60px; border-radius: 16px; object-fit: cover; background: var(--surface-2); flex: none; }
header.top h1 { font-size: 30px; color: var(--accent); line-height: 1.12; }
header.top .tag { color: var(--ink-muted); font-size: 14px; margin-top: 2px; }

label.lbl { font-size: 12px; color: var(--ink-muted); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; display: block; margin-bottom: 4px; }
input[type="text"], input[type="tel"], input[type="email"], input[type="number"], input[type="password"], input[type="url"], input[type="datetime-local"], input[type="month"], input[type="search"], textarea, select {
  font: inherit; color: var(--ink); background: var(--surface);
  border: 1.5px solid var(--border); border-radius: 14px; padding: 10px 12px; width: 100%; min-height: 44px;
}
textarea { resize: vertical; }
input[type="color"] { width: 56px; height: 44px; padding: 2px; border: 1.5px solid var(--border); border-radius: 12px; background: var(--surface); }
input:focus-visible, textarea:focus-visible, select:focus-visible, button:focus-visible, a:focus-visible, summary:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 45%, transparent); outline-offset: 2px; }

button { font: inherit; font-weight: 700; border-radius: 14px; padding: 10px 18px; border: 1.5px solid transparent; cursor: pointer; min-height: 44px; }
button.primary { background: var(--accent); color: var(--accent-ink); box-shadow: 0 6px 16px -8px var(--accent); }
button.primary:hover { filter: brightness(1.06); }
button.ghost { background: transparent; color: var(--accent); border-color: var(--border); }
button.ghost:hover { background: var(--accent-soft); }
button.danger { background: transparent; color: var(--warn); border-color: var(--border); }
button.small { padding: 5px 11px; font-size: 13px; min-height: 34px; }
button:disabled { opacity: .5; cursor: not-allowed; }

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; margin-bottom: 18px; box-shadow: var(--shadow); }
.card h2 { font-size: 20px; margin-bottom: 10px; }
.card-sub { color: var(--ink-muted); font-size: 13px; margin: -4px 0 14px; }
.grid { display: grid; gap: 12px; }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 640px) { .grid.two, .grid.three { grid-template-columns: 1fr; } }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.spread { justify-content: space-between; }

.banner { border-radius: 14px; padding: 11px 15px; font-size: 14px; margin-bottom: 16px; border: 1px solid transparent; }
.banner.info { background: var(--accent-soft); color: var(--ink); border-color: color-mix(in srgb, var(--accent) 35%, var(--border)); }
.banner.warn { background: var(--warn-soft); color: var(--warn); border-color: var(--warn); }
.banner.ok { background: var(--money-soft); color: var(--money); border-color: var(--money); }

/* DEMO ribbon: shown on any page of a restaurant that is still in private demo mode */
.demo-ribbon { background: var(--ink); color: var(--bg); text-align: center; padding: 9px 14px; font-size: 13px; font-weight: 600; letter-spacing: .02em; }
.demo-ribbon b { color: var(--butter); }

/* delivery / pickup switch */
.seg { display: inline-flex; border: 1.5px solid var(--border); border-radius: 14px; padding: 3px; background: var(--surface-2); gap: 3px; width: 100%; }
.seg button { flex: 1; background: transparent; color: var(--ink); border: none; border-radius: 11px; padding: 10px 12px; }
.seg button[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); box-shadow: 0 4px 10px -6px var(--accent); }
.pickup-box { background: var(--surface-2); border-radius: 14px; padding: 12px 14px; font-size: 14px; }

/* menu */
.menu-cats { display: flex; gap: 8px; overflow-x: auto; padding: 4px 0 10px; position: sticky; top: 0; background: var(--surface, #fff); z-index: 5; -webkit-overflow-scrolling: touch; }
.menu-cats .chip { flex: none; white-space: nowrap; }
.menu-sec { font-size: 18px; margin: 22px 0 2px; padding-top: 6px; scroll-margin-top: 56px; border-bottom: 2px solid var(--accent-soft); padding-bottom: 6px; }
.menu-sec:first-child { margin-top: 4px; }
.menu-item { display: flex; justify-content: space-between; gap: 12px; padding: 13px 0; border-bottom: 1px dashed var(--border); align-items: center; }
.menu-item:last-child { border-bottom: none; }
.menu-item .grow { flex: 1 1 150px; min-width: 0; }
@media (max-width: 560px) {
  .menu-item { flex-wrap: wrap; }
  .menu-item .ctl { flex: 1 1 100%; justify-content: space-between; }
  .menu-item img.dish ~ .ctl { padding-left: 84px; }
}
.menu-item img.dish { width: 72px; height: 72px; border-radius: 16px; object-fit: cover; flex: none; background: var(--accent-soft); }
.menu-item .name { font-weight: 600; }
.menu-item .desc { color: var(--ink-muted); font-size: 13px; }
.menu-item .price { font-family: 'IBM Plex Mono', monospace; white-space: nowrap; }
.qty { display: inline-flex; align-items: center; gap: 6px; }
.qty button { padding: 2px 12px; min-height: 38px; font-size: 18px; line-height: 1; border-radius: 999px; }
.qty .n { min-width: 22px; text-align: center; font-family: 'IBM Plex Mono', monospace; }
.tagpill { display: inline-block; background: var(--money-soft); color: var(--money); border-radius: 999px; padding: 1px 8px; font-size: 11px; margin: 3px 4px 0 0; font-weight: 600; }

.chips { display: flex; flex-wrap: wrap; gap: 7px; }
.chip { border: 1.5px solid var(--border); border-radius: 999px; padding: 6px 13px; font-size: 13px; cursor: pointer; background: var(--surface); color: var(--ink); min-height: 38px; font-weight: 500; }
.chip[aria-pressed="true"] { background: var(--olive); color: #fff; border-color: var(--olive); }

.totals { display: grid; gap: 4px; font-size: 14px; margin-bottom: 10px; }
.totals .line { display: flex; justify-content: space-between; color: var(--ink-muted); }
.totalrow { display: flex; justify-content: space-between; align-items: baseline; font-size: 18px; font-weight: 600; }
.totalrow .mono { font-size: 24px; }

/* stats + tables (dashboards) */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; margin-bottom: 18px; }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 13px 15px; }
.stat .num { font-family: 'Nunito', system-ui, sans-serif; font-size: 26px; font-weight: 800; line-height: 1.1; }
.stat .lbl { font-size: 12px; color: var(--ink-muted); margin-top: 2px; }
.stat .sub { font-size: 11px; color: var(--ink-muted); margin-top: 4px; }
.stat.good { border-color: var(--money); } .stat.good .num { color: var(--money); }
.stat.mid  { border-color: var(--butter); }
.stat.bad  { border-color: var(--warn); } .stat.bad .num { color: var(--warn); }
.table-wrap { overflow-x: auto; }
table.orders { width: 100%; border-collapse: collapse; font-size: 13.5px; min-width: 640px; }
table.orders th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-muted); padding: 6px 8px; border-bottom: 1.5px solid var(--border); white-space: nowrap; }
table.orders td { padding: 9px 8px; border-bottom: 1px solid var(--border); vertical-align: top; }
table.orders td.num, table.orders th.num { text-align: right; }
.pill { display: inline-block; border-radius: 999px; padding: 2px 10px; font-size: 11px; font-weight: 700; white-space: nowrap; }
.pill.wait { background: var(--surface-2); color: var(--ink-muted); }
.pill.matched { background: var(--money-soft); color: var(--money); }
.pill.demo { background: var(--butter); color: #3a2a06; }
.pill.live { background: var(--money-soft); color: var(--money); }
.pill.paused { background: var(--warn-soft); color: var(--warn); }
.pill.pickup { background: #e6eefb; color: #2f5aa8; } .pill.delivery { background: var(--accent-soft); color: var(--accent); }

.match-card { border: 1px solid var(--border); border-radius: 16px; padding: 14px; margin-bottom: 12px; background: var(--surface-2); }
.match-card .pair { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-family: 'Nunito', system-ui, sans-serif; font-weight: 800; font-size: 17px; margin-bottom: 6px; flex-wrap: wrap; }
.match-card .breakdown { font-size: 13px; color: var(--ink-muted); margin-bottom: 10px; }
.match-card .breakdown .money { color: var(--money); font-weight: 700; }
.relay { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 640px) { .relay { grid-template-columns: 1fr; } }
.relay-box { background: var(--surface); border: 1.5px dashed var(--border); border-radius: 12px; padding: 10px; font-size: 13px; }
.relay-box .who { font-weight: 600; margin-bottom: 4px; }
pre.ticket { margin: 0; white-space: pre-wrap; word-break: break-word; font-family: 'IBM Plex Mono', ui-monospace, monospace; font-size: 12.5px; background: var(--surface-2); border-radius: 8px; padding: 8px; }
.status-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; border-top: 1px solid var(--border); padding-top: 8px; margin-top: 8px; }
.status-row .who { min-width: 80px; font-size: 13px; color: var(--ink-muted); }
.feedback { font-size: 13px; color: var(--ink-muted); margin: 4px 0 0; }

/* tabs (super admin) */
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 18px; border-bottom: 1.5px solid var(--border); }
.tabs button { background: transparent; color: var(--ink-muted); border: none; border-bottom: 3px solid transparent; border-radius: 0; padding: 10px 16px; margin-bottom: -1.5px; }
.tabs button[aria-selected="true"] { color: var(--accent); border-bottom-color: var(--accent); }

/* simple charts */
.bars { display: flex; align-items: flex-end; gap: 3px; height: 120px; padding-top: 6px; }
.bars .col { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: stretch; min-width: 0; height: 100%; }
.bars .b { background: var(--accent); border-radius: 4px 4px 0 0; min-height: 0; }
.bars .b2 { background: var(--olive); border-radius: 4px 4px 0 0; }
.bar-legend { display: flex; gap: 14px; font-size: 12px; color: var(--ink-muted); margin-top: 6px; }
.bar-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.hbar { display: grid; grid-template-columns: 28px 1fr 34px; gap: 8px; align-items: center; font-size: 13px; margin: 5px 0; }
.hbar .track { background: var(--surface-2); border-radius: 999px; height: 12px; overflow: hidden; }
.hbar .fill { background: var(--butter); height: 100%; border-radius: 999px; }

/* menu editor rows */
.menu-row { display: grid; grid-template-columns: 1.3fr 1.5fr 90px 1fr 1.1fr auto auto; gap: 8px; align-items: center; margin-bottom: 8px; }
.menu-row.fresh { background: var(--accent-soft); border-radius: 12px; padding: 6px; }
@media (max-width: 800px) { .menu-row { grid-template-columns: 1fr 1fr; } }

/* importer */
.import-tabs { display: flex; gap: 6px; margin-bottom: 12px; flex-wrap: wrap; }
.import-tabs button[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
table.draft { width: 100%; border-collapse: collapse; font-size: 13px; }
table.draft td, table.draft th { padding: 5px 6px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: top; }

/* landing */
.hero { padding: 18px 0 8px; text-align: center; }
.hero h1 { font-size: clamp(38px, 8vw, 58px); color: var(--ink); line-height: 1.04; }
.hero h1 em { color: var(--accent); font-style: italic; }
.hero p { font-size: 18px; color: var(--ink-muted); max-width: 32em; margin: 14px auto 0; }
.search { max-width: 460px; margin: 22px auto 6px; }
.steps { counter-reset: s; display: grid; gap: 10px; padding: 0; list-style: none; margin: 18px 0; }
.steps li { counter-increment: s; background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 14px 16px 14px 56px; position: relative; }
.steps li::before { content: counter(s); position: absolute; left: 15px; top: 13px; width: 28px; height: 28px; border-radius: 50%; background: var(--butter); color: #3a2a06; display: grid; place-items: center; font-weight: 800; font-size: 14px; }
.rest-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 18px; }
/* each restaurant card wears that restaurant's own colour (--rc is set per card) */
a.rest-card { --rc: var(--accent); position: relative; text-decoration: none; color: var(--ink); background: var(--surface); border: 1.5px solid color-mix(in srgb, var(--rc) 28%, var(--border)); border-radius: 22px; overflow: hidden; display: flex; flex-direction: column; box-shadow: 0 10px 22px -16px color-mix(in srgb, var(--rc) 70%, #000); transition: transform .18s, box-shadow .18s, border-color .18s; }
a.rest-card:hover, a.rest-card:focus-visible { border-color: var(--rc); transform: translateY(-4px); box-shadow: 0 18px 30px -16px color-mix(in srgb, var(--rc) 80%, #000); }
a.rest-card:focus-visible { outline: 3px solid color-mix(in srgb, var(--rc) 55%, transparent); outline-offset: 2px; }
a.rest-card .rc-band { display: block; height: 66px; background:
  radial-gradient(circle at 88% 20%, rgba(255,255,255,.28) 0 28px, transparent 29px),
  radial-gradient(circle at 70% 90%, rgba(255,255,255,.16) 0 40px, transparent 41px),
  radial-gradient(circle at 8% 110%, rgba(0,0,0,.14) 0 46px, transparent 47px),
  linear-gradient(135deg, var(--rc), color-mix(in srgb, var(--rc) 72%, #000)); }
a.rest-card .rc-logo { position: absolute; top: 34px; left: 16px; width: 64px; height: 64px; border-radius: 18px; background: #fff; padding: 3px; box-shadow: 0 8px 16px -8px rgba(0,0,0,.45); display: block; }
a.rest-card .rc-logo img, a.rest-card .rc-logo .dot { width: 100%; height: 100%; border-radius: 15px; object-fit: cover; display: grid; place-items: center; color: #fff; font-family: 'Nunito', system-ui, sans-serif; font-weight: 800; font-size: 26px; }
a.rest-card .rc-body { display: flex; flex-direction: column; gap: 4px; padding: 40px 16px 14px; flex: 1; }
a.rest-card .nm { font-weight: 800; font-size: 17px; line-height: 1.2; }
a.rest-card .rc-tag { color: var(--ink-muted); font-size: 14px; line-height: 1.4; }
a.rest-card .rc-go { position: absolute; right: 12px; top: 74px; display: inline-flex; align-items: center; gap: 2px; font-size: 13px; font-weight: 800; color: color-mix(in srgb, var(--rc) 70%, #000); background: color-mix(in srgb, var(--rc) 11%, #fff); border-radius: 999px; padding: 5px 10px 5px 12px; transition: background .15s, color .15s; }
a.rest-card:hover .rc-go { background: var(--rc); color: #fff; }
a.rest-card .badges { margin-top: 8px; display: flex; gap: 6px; flex-wrap: wrap; }

/* rating page */
.big-stars { display: inline-flex; gap: 4px; }
.big-stars button { padding: 0 3px; border: none; background: none; font-size: 34px; line-height: 1; color: var(--border); min-height: 46px; min-width: 42px; }
.big-stars button.set { color: var(--butter); }
.q { margin-bottom: 20px; }
.q .qt { font-weight: 600; margin-bottom: 2px; }
.q .qd { color: var(--ink-muted); font-size: 13px; margin-bottom: 6px; }
.got { background: var(--accent-soft); border-radius: 16px; padding: 14px 16px; margin-bottom: 18px; }
.got .lbl2 { font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-muted); font-weight: 600; }
.got .items { font-family: 'Nunito', system-ui, sans-serif; font-size: 22px; font-weight: 800; margin-top: 4px; }
.yn { display: flex; gap: 8px; }
.yn button[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }

.toast { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); background: var(--ink); color: var(--bg); padding: 11px 20px; border-radius: 999px; font-size: 14px; box-shadow: var(--shadow); opacity: 0; pointer-events: none; transition: opacity .2s; z-index: 50; max-width: 90vw; text-align: center; }
.toast.show { opacity: 1; }
footer.site { margin-top: 36px; font-size: 12px; color: var(--ink-muted); text-align: center; }

/* ---------- landing intro animation (skippable; off for reduced-motion) ---------- */
#intro { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; overflow: hidden; }
#intro .half { position: absolute; left: 0; right: 0; height: 50.2%; background: #fae3c4; background-image: radial-gradient(ellipse at 50% 40%, #fff4e4 0%, #fae3c4 60%, #f2cfa3 100%); background-size: 100% 200%; transition: transform .8s cubic-bezier(.7,0,.2,1) .1s; will-change: transform; }
#intro .half.top { top: 0; background-position: 50% 0; }
#intro .half.bottom { bottom: 0; background-position: 50% 100%; }
#intro.leaving { pointer-events: none; }
#intro.leaving .half.top { transform: translateY(-101%); }
#intro.leaving .half.bottom { transform: translateY(101%); }
#intro .stage, #intro .food, #intro .rays, #intro .skip, #intro .intro-bar { transition: opacity .35s ease; }
#intro.leaving .stage, #intro.leaving .food, #intro.leaving .rays, #intro.leaving .skip, #intro.leaving .intro-bar { opacity: 0 !important; animation: none; }
#intro .stage { position: relative; width: min(92vw, 420px); text-align: center; color: var(--ink); z-index: 2; }

/* soft sunburst that blooms when the bags swap */
#intro .rays { position: absolute; left: 50%; top: 44%; width: 150vmax; height: 150vmax; margin: -75vmax 0 0 -75vmax; opacity: 0; z-index: 1;
  background: repeating-conic-gradient(from 0deg, rgba(242,176,58,.26) 0 7deg, rgba(242,176,58,0) 7deg 20deg);
  -webkit-mask-image: radial-gradient(circle, #000 0, transparent 46%); mask-image: radial-gradient(circle, #000 0, transparent 46%);
  animation: raysIn 4.2s ease-out 2.4s forwards, spin 28s linear infinite; }
@keyframes raysIn { 0% { opacity: 0; } 25% { opacity: 1; } 100% { opacity: .75; } }
@keyframes spin { to { transform: rotate(360deg); } }

/* little food icons drift in around the edges */
#intro .food { position: absolute; width: 46px; height: 46px; opacity: 0; z-index: 2; filter: drop-shadow(0 6px 6px rgba(80,45,20,.22)); animation: foodIn .7s cubic-bezier(.2,.9,.3,1.3) forwards, bob 3.4s ease-in-out infinite; }
#intro .f1 { left: 9%; top: 16%; animation-delay: .5s, 1.2s; --tilt: -14deg; }
#intro .f2 { right: 10%; top: 22%; animation-delay: .75s, 1.5s; --tilt: 12deg; width: 52px; height: 52px; }
#intro .f3 { left: 13%; bottom: 17%; animation-delay: 1s, 1.8s; --tilt: 10deg; }
#intro .f4 { right: 12%; bottom: 14%; animation-delay: 1.25s, 2.1s; --tilt: -10deg; }
@keyframes foodIn { from { opacity: 0; transform: translateY(26px) scale(.4) rotate(var(--tilt)); } to { opacity: .95; transform: translateY(0) scale(1) rotate(var(--tilt)); } }
@keyframes bob { 0%, 100% { margin-top: 0; } 50% { margin-top: -9px; } }

/* the two mystery bags: drop in, wobble, trade places in an arc, land with a squash */
#intro .bags { position: relative; height: 160px; margin: 0 auto 8px; width: 300px; max-width: 100%; }
#intro .bag { position: absolute; bottom: 0; width: 82px; height: 104px; opacity: 0; animation: drop .85s cubic-bezier(.3,1.4,.5,1) .15s forwards; }
#intro .bag.a { left: 18px; } #intro .bag.b { right: 18px; animation-delay: .35s; }
@keyframes drop { 0% { opacity: 0; transform: translateY(-260px) rotate(-14deg); } 55% { opacity: 1; transform: translateY(0) rotate(4deg); } 75% { transform: translateY(-14px) rotate(-2deg); } 100% { opacity: 1; transform: translateY(0) rotate(0); } }
#intro .bag .mv { width: 100%; height: 100%; }
#intro .bag svg { width: 100%; height: 100%; display: block; overflow: visible; filter: drop-shadow(0 8px 10px rgba(80,45,20,.28)); transform-origin: 50% 100%; }
#intro .bag.a .mv { animation: swapA 1.15s cubic-bezier(.45,.05,.35,1) 1.75s forwards; }
#intro .bag.b .mv { animation: swapB 1.15s cubic-bezier(.45,.05,.35,1) 1.75s forwards; }
@keyframes swapA { 0% { transform: translate(0,0) rotate(0); } 50% { transform: translate(91px,-104px) rotate(14deg) scale(1.08); } 100% { transform: translate(182px,0) rotate(0); } }
@keyframes swapB { 0% { transform: translate(0,0) rotate(0); } 50% { transform: translate(-91px,-52px) rotate(-14deg) scale(.96); } 100% { transform: translate(-182px,0) rotate(0); } }
#intro .bag svg { animation: wobble .7s ease-in-out 1.05s 1, land .5s ease-out 2.9s 1; }
@keyframes wobble { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-7deg); } 50% { transform: rotate(6deg); } 75% { transform: rotate(-3deg); } }
@keyframes land { 0% { transform: scale(1.1, .8); } 55% { transform: scale(.94, 1.1); } 100% { transform: scale(1); } }
/* the "?" turns into a star once unwrapped */
#intro .bag .q { animation: qOut .3s ease 2.85s forwards; }
#intro .bag .st { opacity: 0; transform-box: fill-box; transform-origin: center; animation: stIn .55s cubic-bezier(.2,1.6,.4,1) 3.0s forwards; }
@keyframes qOut { to { opacity: 0; } }
@keyframes stIn { from { opacity: 0; transform: scale(.2) rotate(-90deg); } to { opacity: 1; transform: scale(1) rotate(0); } }

/* confetti burst at the moment of the swap landing */
#intro .burst { position: absolute; left: 50%; bottom: 66px; width: 0; height: 0; }
#intro .cf { position: absolute; left: 0; top: 0; width: var(--w, 8px); height: calc(var(--w, 8px) * .6); background: var(--c); border-radius: 2px; opacity: 0; animation: confetti 1.5s cubic-bezier(.15,.7,.3,1) 2.95s forwards; }
@keyframes confetti { 0% { opacity: 1; transform: translate(0,0) rotate(0) scale(.5); } 70% { opacity: 1; } 100% { opacity: 0; transform: translate(var(--dx), calc(var(--dy) + 70px)) rotate(var(--r)) scale(1); } }

/* wordmark, underline, tagline */
#intro .word { font-family: 'Nunito', system-ui, sans-serif; font-weight: 900; font-size: clamp(46px, 13vw, 68px); letter-spacing: -.02em; line-height: 1; }
#intro .word span { display: inline-block; opacity: 0; transform: translateY(30px) scale(.6); animation: rise .6s cubic-bezier(.2,1.5,.35,1) forwards; }
#intro .word span:nth-child(1) { animation-delay: 3.05s; } #intro .word span:nth-child(2) { animation-delay: 3.11s; }
#intro .word span:nth-child(3) { animation-delay: 3.17s; } #intro .word span:nth-child(4) { animation-delay: 3.23s; }
#intro .word span:nth-child(5) { animation-delay: 3.29s; color: var(--accent); } #intro .word span:nth-child(6) { animation-delay: 3.35s; color: var(--accent); }
#intro .word span:nth-child(7) { animation-delay: 3.41s; color: var(--accent); } #intro .word span:nth-child(8) { animation-delay: 3.47s; color: var(--accent); }
@keyframes rise { to { opacity: 1; transform: translateY(0) scale(1); } }
#intro .swoosh { display: block; width: 62%; max-width: 250px; height: 14px; margin: 6px auto 0; }
#intro .swoosh path { stroke-dasharray: 260; stroke-dashoffset: 260; animation: draw .7s ease-out 3.7s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
#intro .tagline { margin-top: 10px; font-size: 19px; font-weight: 700; color: var(--ink-muted); opacity: 0; transform: translateY(8px); animation: tagIn .6s ease 4.05s forwards; }
@keyframes tagIn { to { opacity: 1; transform: translateY(0); } }

#intro .skip { position: absolute; z-index: 3; top: 16px; right: 16px; background: rgba(255,255,255,.65); color: var(--ink); border: 1.5px solid var(--border); border-radius: 999px; padding: 6px 16px; min-height: 38px; font-size: 14px; }
#intro .intro-bar { position: absolute; z-index: 3; left: 0; right: 0; bottom: 0; height: 5px; background: rgba(191,79,34,.12); }
#intro .intro-bar i { display: block; height: 100%; width: 100%; background: linear-gradient(90deg, #bf4f22, #f2b03a); transform-origin: left; transform: scaleX(0); animation: bar 5.6s linear forwards; }
@keyframes bar { to { transform: scaleX(1); } }
@media (prefers-reduced-motion: reduce) { #intro { display: none !important; } }

#printArea { display: none; }
@media print {
  body > *:not(#printArea) { display: none !important; }
  #printArea { display: block; color: #000; background: #fff; }
  #printArea .ticket-page { page-break-inside: avoid; border: 2px dashed #000; padding: 14px; margin: 0 0 14px; font: 16px/1.4 ui-monospace, Menlo, monospace; white-space: pre-wrap; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* section sub-heading inside cards / pages */
h3.sec { font-family: 'Nunito', system-ui, sans-serif; font-size: 18px; margin: 22px 0 8px; }
.rest-edit > summary { cursor: pointer; list-style: none; }
.rest-edit > summary::-webkit-details-marker { display: none; }
.rest-edit { margin-bottom: 12px; }

/* final-sale notice */
.ack { display: flex; gap: 10px; align-items: flex-start; margin: 14px 0 10px; font-size: 14px; cursor: pointer; }
.ack input { width: 20px; height: 20px; margin-top: 1px; flex: none; accent-color: var(--accent); }

/* swap range picker */
.range { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 10px; }
.rangeopt { display: flex; flex-direction: column; gap: 3px; text-align: left; background: var(--surface); color: var(--ink); border: 1.5px solid var(--border); border-radius: 14px; padding: 11px 12px; cursor: pointer; font: inherit; min-height: 44px; }
.rangeopt[aria-checked="true"] { border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 0 0 1px var(--accent) inset; }
.rangeopt .rn1 { font-weight: 700; }
.rangeopt .rn2 { font-weight: 700; color: var(--accent); }
.rangeopt .rn3 { font-size: 12.5px; color: var(--ink-muted); }
@media (max-width: 560px) { .range { grid-template-columns: 1fr; } }

/* ---------- restaurant order page: looks like the restaurant's own site; Chu-Swap is an opt-in in the cart ---------- */
.r-hero { background: var(--accent); color: var(--accent-ink); }
.r-hero-in { max-width: 1120px; margin: 0 auto; padding: 26px 16px 24px; display: flex; align-items: center; gap: 18px; }
.r-hero img.logo { width: 84px; height: 84px; border-radius: 22px; object-fit: cover; background: rgba(255,255,255,.2); flex: none; box-shadow: 0 6px 18px -8px rgba(0,0,0,.45); }
.r-hero h1 { font-size: clamp(28px, 5vw, 42px); color: inherit; line-height: 1.08; }
.r-hero .tag { font-size: 16px; opacity: .92; margin-top: 3px; }
.r-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.r-meta span { background: rgba(255,255,255,.2); border-radius: 999px; padding: 3px 12px; font-size: 13px; font-weight: 600; }
body.shop-page main.shop { max-width: 1120px; margin: 0 auto; padding: 22px 16px 110px; }
.shop-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; align-items: start; }
.shop-main { min-width: 0; }
@media (min-width: 900px) {
  .shop-grid { grid-template-columns: minmax(0, 1fr) 380px; }
  .cart { position: sticky; top: 16px; max-height: calc(100vh - 32px); overflow-y: auto; margin-bottom: 0; }
  body.shop-page main.shop { padding-bottom: 60px; }
}
.menu-card .menu-cats { top: 0; margin: -6px -4px 0; padding: 8px 4px 10px; }
.cart h2 { margin-bottom: 12px; }
.cart-lines { margin-bottom: 12px; }
.cart-line { display: grid; grid-template-columns: 1fr auto auto; gap: 8px; align-items: center; padding: 8px 0; border-bottom: 1px dashed var(--border); }
.cart-line:last-child { border-bottom: none; }
.cart-line .cl-name { font-size: 14px; font-weight: 600; min-width: 0; overflow-wrap: anywhere; }
.cart-line .cl-price { font-size: 13px; min-width: 62px; text-align: right; }
.cart-line .qty button { min-height: 32px; padding: 0 10px; font-size: 16px; }

/* the Chu-Swap opt-in inside the cart */
/* The Chu-Swap box is Chu-Swap's own brand: same colours on every restaurant's page, whatever the restaurant's theme. */
.chu-opt { --accent: #bf4f22; --accent-ink: #ffffff; --accent-soft: color-mix(in srgb, #bf4f22 11%, var(--surface)); }
.chu-opt { border: 1.5px dashed color-mix(in srgb, var(--accent) 55%, var(--border)); border-radius: 18px; background: var(--accent-soft); overflow: hidden; }
.chu-opt[data-on="true"] { border-style: solid; border-color: var(--accent); }
.chu-toggle { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; background: transparent; color: var(--ink); border: none; border-radius: 0; padding: 12px 14px; min-height: 60px; cursor: pointer; }
.chu-ico { color: var(--accent); flex: none; }
.chu-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.chu-t b { font-size: 15px; }
.chu-t small { font-size: 12.5px; font-weight: 500; color: var(--ink-muted); line-height: 1.35; }
.chu-state { flex: none; font-size: 12px; font-weight: 800; padding: 5px 11px; border-radius: 999px; border: 1.5px solid var(--accent); color: var(--accent); background: var(--surface); }
.chu-opt[data-on="true"] .chu-state { background: var(--accent); color: var(--accent-ink); }
.chu-panel { padding: 4px 14px 14px; border-top: 1px dashed color-mix(in srgb, var(--accent) 35%, var(--border)); }
.chu-how { font-size: 13.5px; margin: 12px 0 14px; }
.chu-panel .q { margin-bottom: 14px; }
.chu-panel .range { grid-template-columns: 1fr; }
.chu-panel .final { font-size: 13.5px; background: var(--warn-soft); color: var(--warn); border-radius: 12px; padding: 9px 12px; margin: 4px 0 0; }
.chu-panel .ack { margin: 12px 0 8px; font-size: 13.5px; }
.linkbtn { background: none; border: none; color: var(--ink-muted); text-decoration: underline; font-weight: 600; font-size: 13px; padding: 4px 0; min-height: 36px; cursor: pointer; }

/* phone: a bar stays at the bottom with the running total and takes you to the cart */
.cartbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: var(--surface); border-top: 1.5px solid var(--border); box-shadow: 0 -10px 24px -16px rgba(0,0,0,.45); transition: transform .2s; }
.cartbar.gone { transform: translateY(110%); }
.cartbar .cb-sum { display: flex; flex-direction: column; font-size: 13px; color: var(--ink-muted); line-height: 1.25; }
.cartbar .cb-sum b { font-size: 18px; color: var(--ink); }
@media (min-width: 900px) { .cartbar { display: none !important; } }

/* landing "how it works": a picture of the cart box so people know what to look for */
.how-mock { margin: 12px 0 2px; max-width: 420px; pointer-events: none; user-select: none; }
.how-mock .how-label { font-size: 12px; font-weight: 700; color: var(--ink-muted); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 6px; }
.steps li strong { font-weight: 700; }

/* ---------- customer account page ---------- */
.narrowcard { max-width: 460px; margin: 30px auto; }
a.primary-link { display: inline-block; background: var(--accent); color: var(--accent-ink); text-decoration: none; padding: 11px 18px; border-radius: 14px; font-weight: 700; }
.starrow { margin-bottom: 16px; }
.starhead { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; }
.starname { font-weight: 700; }
.starnum { font-size: 18px; color: var(--accent); }
.track { background: var(--surface-2); border-radius: 999px; height: 12px; overflow: hidden; margin-bottom: 6px; }
.track .fill { background: var(--butter); height: 100%; border-radius: 999px; }
.ocard { border: 1px solid var(--border); border-radius: 18px; padding: 14px; margin-bottom: 12px; background: var(--surface); }
.ohead { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: baseline; }
.oname { font-weight: 800; font-size: 17px; }
.prow { display: flex; justify-content: space-between; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px dashed var(--border); flex-wrap: wrap; }
.prow:last-child { border-bottom: none; }
.pname { font-weight: 700; }

.reward-box { background: var(--money-soft); border: 1.5px solid var(--money); color: var(--ink); border-radius: 14px; padding: 10px 12px; margin-bottom: 12px; }

/* reactions on a delivered swap: a gold Chu-Star banner, then a Chu-Yes / Chu-No pair */
.react { margin-top: 14px; display: grid; gap: 8px; }
.react-h { font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-muted); margin-top: 4px; }
.react-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
@media (max-width: 420px) { .react-pair { grid-template-columns: 1fr; } }
.rbtn { display: flex; align-items: center; gap: 12px; text-align: left; width: 100%; background: var(--surface); color: var(--ink); border: 2px solid var(--border); border-radius: 16px; padding: 12px 14px; cursor: pointer; transition: transform .12s, box-shadow .12s, background .12s; }
.rbtn:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 8px 16px -10px rgba(59,36,23,.5); }
.rbtn .rico { flex: none; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; }
.rbtn .ri { width: 22px; height: 22px; }
.rbtn .rtxt { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.rbtn .rtxt b { font-size: 15px; }
.rbtn small { font-weight: 500; font-size: 12px; color: var(--ink-muted); line-height: 1.3; }
.rbtn.star { background: linear-gradient(135deg, #fff4d4, #ffe6a3); border-color: var(--butter); }
.rbtn.star .rico { background: var(--butter); color: #5a3b00; }
.rbtn.star:disabled { background: #fff4d4; opacity: 1; cursor: default; }
.rbtn.star:disabled .rico { background: #e0a21f; color: #fff; }
.rbtn.yes .rico { background: var(--money-soft); color: var(--money); }
.rbtn.no .rico { background: var(--warn-soft); color: var(--warn); }
.rbtn.yes:hover:not(:disabled) { border-color: var(--money); }
.rbtn.no:hover:not(:disabled) { border-color: var(--warn); }
.rbtn.yes[aria-pressed="true"] { background: var(--money); border-color: var(--money); color: #fff; }
.rbtn.yes[aria-pressed="true"] small { color: #eaf3d6; } .rbtn.yes[aria-pressed="true"] .rico { background: #fff; }
.rbtn.no[aria-pressed="true"] { background: var(--warn); border-color: var(--warn); color: #fff; }
.rbtn.no[aria-pressed="true"] small { color: #f7e0d3; } .rbtn.no[aria-pressed="true"] .rico { background: #fff; }

/* back to the restaurant list, on every restaurant page */
.r-top { max-width: 1120px; margin: 0 auto; padding: 14px 16px 0; }
.r-back { display: inline-flex; align-items: center; gap: 4px; padding: 7px 14px 7px 9px; border-radius: 999px; background: rgba(255,255,255,.22); color: var(--accent-ink); font-weight: 800; font-size: 14px; text-decoration: none; border: 1.5px solid rgba(255,255,255,.35); backdrop-filter: blur(4px); transition: background .15s, transform .15s; }
.r-back:hover { background: rgba(255,255,255,.34); transform: translateX(-2px); }
.r-back:focus-visible { outline: 3px solid var(--accent-ink); outline-offset: 2px; }
.r-hero-in { padding-top: 14px; }
.r-back-link { font-weight: 700; }

/* ---------- "Finding your Chu-Swapper" (the matching screen) ---------- */
.fx { max-width: 380px; margin: 4px auto 18px; text-align: center; }
.fx-stage { position: relative; height: 230px; margin: 0 auto; width: 260px; max-width: 100%; }
.fx-ring { position: absolute; left: 50%; top: 50%; width: 120px; height: 120px; margin: -60px 0 0 -60px; border-radius: 50%; border: 2.5px solid rgba(191,79,34,.55); opacity: 0; animation: fxRing 3s ease-out infinite; }
.fx-ring:nth-of-type(2) { animation-delay: 1s; } .fx-ring:nth-of-type(3) { animation-delay: 2s; }
@keyframes fxRing { 0% { transform: scale(.45); opacity: .85; } 100% { transform: scale(2.1); opacity: 0; } }
.fx-orbit { position: absolute; inset: 0; animation: fxSpin 7s linear infinite; }
.fx-sat { position: absolute; left: 50%; top: 50%; width: 30px; height: 38px; margin: -19px 0 0 -15px; transform: rotate(var(--a)) translateY(-88px) rotate(calc(var(--a) * -1)); }
.fx-sat svg { width: 100%; height: 100%; display: block; animation: fxSpin 7s linear infinite reverse; filter: drop-shadow(0 4px 5px rgba(80,45,20,.25)); }
.fx-sat .st { display: none; }
@keyframes fxSpin { to { transform: rotate(360deg); } }
.fx-bag { position: absolute; left: 50%; top: 50%; width: 66px; height: 82px; margin: -41px 0 0 -33px; }
.fx-bag svg { width: 100%; height: 100%; display: block; overflow: visible; filter: drop-shadow(0 8px 10px rgba(80,45,20,.3)); }
.fx-me { animation: fxBob 2.2s ease-in-out infinite; }
@keyframes fxBob { 0%, 100% { transform: translateY(0) rotate(-3deg); } 50% { transform: translateY(-7px) rotate(3deg); } }
.fx-bag .st { opacity: 0; transform-box: fill-box; transform-origin: center; }
.fx-twin, .fx-check { opacity: 0; }
.fx-check { position: absolute; left: 50%; top: 50%; width: 84px; height: 84px; margin: -42px 0 0 -42px; border-radius: 50%; background: var(--money); display: grid; place-items: center; transform: scale(.4); }
/* matched: the orbiting bags collapse, a second bag arrives, and the two trade places */
.fx[data-state="matched"] .fx-orbit, .fx[data-state="delivered"] .fx-orbit { animation: fxCollapse .6s ease-in forwards; }
.fx[data-state="matched"] .fx-ring, .fx[data-state="delivered"] .fx-ring { animation: none; opacity: 0; }
@keyframes fxCollapse { to { transform: scale(.1) rotate(200deg); opacity: 0; } }
.fx[data-state="matched"] .fx-me, .fx[data-state="delivered"] .fx-me { animation: fxMeSwap 1.5s cubic-bezier(.45,.05,.35,1) .35s forwards; }
.fx[data-state="matched"] .fx-twin, .fx[data-state="delivered"] .fx-twin { animation: fxTwinSwap 1.5s cubic-bezier(.45,.05,.35,1) .35s forwards; }
@keyframes fxMeSwap { 0% { transform: translate(0,0); } 25% { transform: translate(-50px,0); } 38% { transform: translate(-50px,0); } 65% { transform: translate(0,-74px) rotate(12deg) scale(1.08); } 90% { transform: translate(50px,4px); } 100% { transform: translate(50px,0); } }
@keyframes fxTwinSwap { 0% { opacity: 0; transform: translate(0,20px) scale(.5); } 22% { opacity: 1; transform: translate(50px,0) scale(1); } 38% { opacity: 1; transform: translate(50px,0); } 65% { opacity: 1; transform: translate(0,-24px) rotate(-12deg) scale(.96); } 90% { opacity: 1; transform: translate(-50px,4px); } 100% { opacity: 1; transform: translate(-50px,0); } }
.fx[data-state="matched"] .fx-bag .q, .fx[data-state="delivered"] .fx-bag .q { animation: fxFade .3s ease 1.8s forwards; }
.fx[data-state="matched"] .fx-bag .st, .fx[data-state="delivered"] .fx-bag .st { animation: fxStar .55s cubic-bezier(.2,1.6,.4,1) 1.95s forwards; }
@keyframes fxFade { to { opacity: 0; } }
@keyframes fxStar { from { opacity: 0; transform: scale(.2) rotate(-90deg); } to { opacity: 1; transform: scale(1) rotate(0); } }
.fx[data-state="regular"] .fx-orbit, .fx[data-state="regular"] .fx-ring, .fx[data-state="regular"] .fx-me { display: none; }
.fx[data-state="regular"] .fx-check { animation: fxPop .5s cubic-bezier(.2,1.5,.4,1) forwards; }
@keyframes fxPop { to { opacity: 1; transform: scale(1); } }
.fx-burst { position: absolute; left: 50%; top: 50%; width: 0; height: 0; }
.fx-cf { position: absolute; left: 0; top: 0; width: var(--w, 8px); height: calc(var(--w, 8px) * .6); background: var(--c); border-radius: 2px; opacity: 0; animation: fxCf 1.5s cubic-bezier(.15,.7,.3,1) 1.9s forwards; }
@keyframes fxCf { 0% { opacity: 1; transform: translate(0,0) rotate(0) scale(.5); } 70% { opacity: 1; } 100% { opacity: 0; transform: translate(var(--dx), calc(var(--dy) + 60px)) rotate(var(--r)) scale(1); } }

.fx-title { font-size: 22px; margin: 4px 0 6px; }
.fx-sub { margin: 0 auto 14px; max-width: 34ch; color: var(--ink-muted); min-height: 2.8em; }
.fx-steps { list-style: none; padding: 0; margin: 0 auto 14px; display: inline-grid; gap: 7px; text-align: left; font-size: 14px; color: var(--ink-muted); }
.fx-steps li { position: relative; padding-left: 28px; }
.fx-steps li::before { content: ''; position: absolute; left: 0; top: 1px; width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--border); background: var(--surface); box-sizing: border-box; }
.fx-steps li.on { color: var(--ink); font-weight: 700; }
.fx-steps li.on::before { border-color: var(--accent); border-top-color: transparent; animation: fxSpin 1s linear infinite; }
.fx-steps li.done { color: var(--ink); }
.fx-steps li.done::before { background: var(--money); border-color: var(--money); }
.fx-steps li.done::after { content: ''; position: absolute; left: 6px; top: 5px; width: 5px; height: 9px; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.fx-steps li.skip { opacity: .45; text-decoration: line-through; }
.fx[data-state="matched"] .fx-steps, .fx[data-state="delivered"] .fx-steps { display: none; }
.fx-more { text-align: left; background: var(--surface); border: 1.5px solid var(--border); border-radius: 18px; padding: 14px; margin: 6px 0 8px; display: grid; gap: 8px; }
.fx-more-h { font-weight: 800; }
.fx-opt { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; width: 100%; text-align: left; }
.fx-opt small { font-weight: 500; font-size: 12.5px; opacity: .85; line-height: 1.35; }
.fx-note { margin: 8px 0 0; }
@media (prefers-reduced-motion: reduce) { .fx-orbit, .fx-ring, .fx-me, .fx-sat svg { animation: none !important; } }

/* returning customer: one-tap "same settings" offer (never pre-ticks the swap) */
.chu-again{display:flex;align-items:center;gap:12px;justify-content:space-between;flex-wrap:wrap;margin:0 0 10px;padding:11px 14px;border:1.5px dashed var(--chu,#bf4f22);border-radius:14px;background:#fff7ec;font-size:.92rem}
.chu-again button{flex:none}

/* front-door sign-in card */
.gate{position:fixed;inset:0;z-index:60;display:flex;align-items:center;justify-content:center;padding:16px;background:rgba(59,36,23,.45);opacity:0;transition:opacity .3s}
.gate[hidden]{display:none}
.gate.show{opacity:1}
.gate-card{width:100%;max-width:400px;background:#fff;border:1px solid #ecd2b3;border-radius:22px;padding:24px 22px;box-shadow:0 18px 50px rgba(59,36,23,.28);transform:translateY(14px) scale(.98);transition:transform .35s cubic-bezier(.2,.9,.3,1.2);max-height:92vh;overflow:auto}
.gate.show .gate-card{transform:none}
.gate-logo{display:block;margin:0 auto 6px}
.gate-card h2{text-align:center;margin:0 0 6px}
.hi{font-weight:800;color:var(--ink)}

/* payment box (prototype test card) */
.paybox { margin: 4px 0 6px; padding: 12px; border: 1px solid var(--border, #ecd2b3); border-radius: 14px; background: #fffaf2; }
.payopt { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border: 1.5px solid #ecd2b3; border-radius: 12px; margin-top: 8px; cursor: pointer; background: #fff; }
.payopt:has(input:checked) { border-color: var(--accent, #bf4f22); background: #fff6ee; }
.payopt input { flex: none; }
.payopt .payt { display: flex; flex-direction: column; line-height: 1.25; }
.payopt .payt small { color: #86624a; font-size: 12px; }
.chip-card { width: 38px; height: 26px; border-radius: 5px; background: linear-gradient(135deg, #5d6d2c, #bf4f22); flex: none; }
.tk-card-lite { display: flex; align-items: center; gap: 10px; background: #fbefe0; border: 1px solid #ecd2b3; border-radius: 12px; padding: 10px 12px; margin: 10px 0; font-size: 14px; }
.primary-link { display: inline-block; background: var(--accent, #bf4f22); color: #fff; padding: 11px 20px; border-radius: 12px; font-weight: 800; text-decoration: none; }

/* account: test card */
.wcard { display: flex; align-items: center; gap: 14px; background: linear-gradient(135deg, #5d6d2c, #bf4f22); color: #fff; border-radius: 16px; padding: 16px 18px; }
.wcard .small { color: rgba(255,255,255,.85); }
.wcard .chip-card { background: rgba(255,255,255,.35); }
.wbal { font-size: 28px; font-weight: 800; }
.wledger { margin-top: 10px; }
.wrow { display: flex; justify-content: space-between; padding: 6px 0; border-bottom: 1px solid #f0dfc7; font-size: 14px; }
.wrow .pos { color: #3f6b2a; font-weight: 700; } .wrow .neg { color: #9a3d18; font-weight: 700; }
