/* One stylesheet for the whole platform. --brand is set per takeaway. */
:root {
  --brand: #b3261e;
  --ink: #1f1c1a;
  --muted: #6d6660;
  --line: #e6e1dc;
  --bg: #f6f4f1;
  --card: #ffffff;
  --ok: #1d7a35;
  --warn: #9a5800;
  --bad: #b3261e;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(0, 0, 0, .06), 0 4px 16px rgba(0, 0, 0, .06);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 16px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; color: var(--ink); background: var(--bg); }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: 1.6rem; }
h2 { font-size: 1.25rem; }
h3 { font-size: 1.05rem; }
p { margin: 0 0 .8em; }
a { color: var(--brand); }
img { max-width: 100%; display: block; }
[hidden] { display: none !important; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.error { color: var(--bad); font-weight: 600; }
.ok { color: var(--ok); }
.loading { padding: 2rem 1rem; text-align: center; color: var(--muted); }
.noscript { padding: 1rem; background: #fff3cd; }

/* Buttons and form controls */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4em; min-height: 44px; padding: .6em 1.1em; border: 0; border-radius: 10px;
  background: var(--brand); color: var(--brand-ink, #fff); font: inherit; font-weight: 650; text-decoration: none; cursor: pointer; }
.btn:hover { filter: brightness(1.06); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn.secondary { background: #fff; color: var(--ink); border: 1px solid var(--line); }
.btn.ghost { background: transparent; color: var(--brand); }
.btn.danger { background: #fff; color: var(--bad); border: 1px solid #f0c9c6; }
.btn.good { background: var(--ok); color: #fff; }
.btn.small { min-height: 34px; padding: .35em .75em; font-size: .9rem; border-radius: 8px; }
.btn.block { width: 100%; }
.link { background: none; border: 0; padding: 0; color: var(--brand); font: inherit; cursor: pointer; text-decoration: underline; }
label { display: block; font-weight: 600; font-size: .95rem; }
label .hint { display: block; font-weight: 400; color: var(--muted); font-size: .85rem; }
input, select, textarea { width: 100%; margin-top: .3em; padding: .65em .75em; border: 1px solid #cfc8c1; border-radius: 10px; font: inherit; background: #fff; color: var(--ink); }
input:focus, select:focus, textarea:focus, .btn:focus-visible, .link:focus-visible { outline: 3px solid color-mix(in srgb, var(--brand) 35%, transparent); outline-offset: 1px; }
input[type=checkbox], input[type=radio] { width: 1.15em; height: 1.15em; margin: 0; accent-color: var(--brand); flex: none; }
textarea { min-height: 80px; resize: vertical; }
.check { display: flex; gap: .6em; align-items: flex-start; font-weight: 500; }
.check input { margin-top: .15em; }
.stack > * + * { margin-top: 1rem; }
.row { display: flex; gap: .75rem; align-items: center; flex-wrap: wrap; }
.row.spread { justify-content: space-between; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; }
@media (max-width: 560px) { .grid2, .grid3 { grid-template-columns: 1fr; } }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem; box-shadow: var(--shadow); }
.pill { display: inline-block; padding: .15em .6em; border-radius: 999px; font-size: .8rem; font-weight: 700; background: #eee; color: var(--ink); }
.pill.ok { background: #e3f3e7; color: var(--ok); }
.pill.warn { background: #fff1db; color: var(--warn); }
.pill.bad { background: #fde7e5; color: var(--bad); }
.pill.brand { background: var(--brand); color: var(--brand-ink, #fff); }
.banner { padding: .75rem 1rem; text-align: center; font-weight: 600; }
.banner.warn { background: #fff1db; color: var(--warn); }
.banner.info { background: #eaf2ff; color: #1f3a68; }
.banner a { color: inherit; text-decoration: underline; margin-left: .35rem; }
.order-card.test { border-style: dashed; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); max-width: min(92vw, 520px); padding: .8em 1.1em; border-radius: 10px;
  background: #222; color: #fff; z-index: 2000; box-shadow: var(--shadow); font-weight: 600; }
.toast.bad { background: var(--bad); }
.toast.ok { background: var(--ok); }

/* Pop-up sheet used for items, basket and editors */
.sheet { position: fixed; inset: 0; z-index: 1000; background: rgba(20, 16, 12, .5); display: flex; align-items: flex-end; justify-content: center; }
.sheet-panel { background: #fff; width: min(100%, 640px); max-height: 92vh; overflow: auto; border-radius: 18px 18px 0 0; padding: 1.1rem 1.1rem calc(1.1rem + env(safe-area-inset-bottom)); }
.sheet-panel:focus { outline: none; } /* focused only so the keyboard starts inside it */
@media (min-width: 700px) { .sheet { align-items: center; } .sheet-panel { border-radius: 18px; } }
.sheet-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; margin-bottom: .75rem; }
.sheet-close { flex: none; width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); background: #fff; font-size: 1.3rem; cursor: pointer; }
body.no-scroll { overflow: hidden; }

/* Plain pages (login, errors) */
.plain-body { display: grid; place-items: center; min-height: 100vh; padding: 1rem; }
.center-card { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 2rem; width: min(100%, 420px); box-shadow: var(--shadow); }

/* ---------- Customer ordering page */
.shop { max-width: 820px; margin: 0 auto; padding-bottom: 110px; }
.shop-header { position: relative; background: var(--brand); color: var(--brand-ink, #fff); padding: 1.4rem 1rem 1.1rem; }
.shop-header h1 { font-size: 1.7rem; margin-bottom: .25em; }
.shop-header .meta { display: flex; flex-wrap: wrap; gap: .5rem 1rem; font-size: .92rem; opacity: .95; align-items: center; }
.shop-header a { color: inherit; }
.status-pill { background: rgba(255, 255, 255, .95); color: var(--ink); }
.status-pill.ok { color: var(--ok); }
.status-pill.bad { color: var(--bad); }
.shop-intro { margin: 1rem; padding: .85rem 1rem; background: #fff; border-radius: var(--radius); border: 1px solid var(--line); }
.notice { margin: 1rem; padding: .85rem 1rem; border-radius: var(--radius); background: #fff1db; color: #5c3900; font-weight: 600; }
.cat-nav { position: sticky; top: 0; z-index: 10; display: flex; gap: .5rem; overflow-x: auto; padding: .7rem 1rem; background: rgba(246, 244, 241, .97);
  border-bottom: 1px solid var(--line); scrollbar-width: none; }
.cat-nav::-webkit-scrollbar { display: none; }
.cat-nav a { flex: none; padding: .45em .9em; border-radius: 999px; background: #fff; border: 1px solid var(--line); color: var(--ink); text-decoration: none; font-weight: 600; font-size: .92rem; }
.cat-nav a.active { background: var(--ink); color: #fff; border-color: var(--ink); }
.cat { padding: 1rem 1rem 0; scroll-margin-top: 64px; }
.cat h2 { margin: .4rem 0 .7rem; }
.items { display: grid; gap: .65rem; }
.item { display: flex; gap: .8rem; width: 100%; text-align: left; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: .85rem; cursor: pointer; font: inherit; color: inherit; }
.item:hover { border-color: #cfc6bd; }
.item .info { flex: 1; min-width: 0; }
.item .name { font-weight: 700; }
.item .desc { color: var(--muted); font-size: .9rem; margin: .2em 0 .35em; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.item .price { font-weight: 650; }
.item img { width: 92px; height: 92px; object-fit: cover; border-radius: 10px; flex: none; }
.item.soldout { opacity: .55; cursor: not-allowed; }
.hours-list { margin: 1rem; }
.hours-list summary { cursor: pointer; font-weight: 600; }
.hours-list table { margin-top: .5rem; border-collapse: collapse; }
.hours-list td { padding: .2rem 1rem .2rem 0; }
.cart-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; padding: .75rem 1rem calc(.75rem + env(safe-area-inset-bottom)); background: linear-gradient(transparent, rgba(246, 244, 241, .95) 30%); }
.cart-bar .btn { width: min(100%, 788px); margin: 0 auto; display: flex; justify-content: space-between; min-height: 54px; font-size: 1.05rem; box-shadow: 0 6px 18px rgba(0, 0, 0, .18); }
.opt-group { margin: 1rem 0; }
.opt-group legend { font-weight: 700; padding: 0; margin-bottom: .4rem; }
.opt-group fieldset { border: 0; padding: 0; margin: 0; }
.opt { display: flex; align-items: center; gap: .7rem; padding: .6rem .2rem; border-bottom: 1px solid var(--line); cursor: pointer; font-weight: 500; }
.opt .opt-price { margin-left: auto; color: var(--muted); }
.qty { display: inline-flex; align-items: center; gap: .6rem; }
.qty button { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); background: #fff; font-size: 1.2rem; cursor: pointer; }
.qty b { min-width: 1.5em; text-align: center; }
.basket-line { display: flex; gap: .75rem; padding: .75rem 0; border-bottom: 1px solid var(--line); }
.basket-line .info { flex: 1; }
.basket-line .opts { color: var(--muted); font-size: .88rem; }
.seg { display: flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.seg button { flex: 1; padding: .7em; border: 0; background: #fff; font: inherit; font-weight: 650; cursor: pointer; }
.seg button.on { background: var(--ink); color: #fff; }
.totals { margin-top: .75rem; }
.totals div { display: flex; justify-content: space-between; padding: .2rem 0; }
.totals .grand { font-weight: 800; font-size: 1.15rem; border-top: 1px solid var(--line); margin-top: .3rem; padding-top: .5rem; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Order status page */
.status-page { max-width: 640px; margin: 0 auto; padding: 1rem; }
.status-hero { text-align: center; padding: 1.5rem 1rem; }
.status-hero .big { font-size: 1.5rem; font-weight: 800; margin: .5rem 0; }
.status-icon { width: 64px; height: 64px; border-radius: 50%; margin: 0 auto; display: grid; place-items: center; font-size: 2rem; background: #fff; border: 1px solid var(--line); }
.steps { display: flex; justify-content: space-between; gap: .4rem; margin: 1rem 0; }
.steps span { flex: 1; text-align: center; font-size: .8rem; padding-top: .5rem; border-top: 4px solid var(--line); color: var(--muted); }
.steps span.done { border-color: var(--brand); color: var(--ink); font-weight: 650; }

/* ---------- Admin */
.admin-body { background: var(--bg); }
.masterbar { background: #1f1c1a; color: #fff; padding: .45rem 1rem; font-size: .9rem; text-align: center; }
.masterbar a { color: #ffd9a8; }
.topbar { display: flex; align-items: center; gap: 1rem; padding: .6rem 1rem; background: #fff; border-bottom: 1px solid var(--line); flex-wrap: wrap; position: sticky; top: 0; z-index: 20; }
.topbar .brand { font-weight: 800; }
.tabs { display: flex; gap: .25rem; overflow-x: auto; flex: 1; }
.tabs a { padding: .5em .8em; border-radius: 8px; color: var(--ink); text-decoration: none; font-weight: 600; white-space: nowrap; }
.tabs a.active { background: var(--ink); color: #fff; }
.topbar-right { display: flex; gap: 1rem; align-items: center; font-size: .92rem; }
main.admin { max-width: 1200px; margin: 0 auto; padding: 1rem; }
.section { margin-bottom: 1.25rem; }
.section > h2 { margin-bottom: .75rem; }
table.list { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
table.list th, table.list td { padding: .6rem .7rem; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; font-size: .93rem; }
table.list th { background: #faf8f6; font-size: .82rem; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); }
table.list tr:last-child td { border-bottom: 0; }
.table-wrap { overflow-x: auto; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: .75rem; margin-bottom: 1rem; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem 1rem; }
.stat .v { font-size: 1.5rem; font-weight: 800; }
.stat .l { color: var(--muted); font-size: .85rem; }
.stat.highlight { background: var(--ink); color: #fff; }
.stat.highlight .l { color: #d8d2cc; }

/* Live order screen */
.orders-head { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; justify-content: space-between; margin-bottom: 1rem; }
.conn { font-weight: 700; font-size: .9rem; }
.conn.on { color: var(--ok); }
.conn.off { color: var(--bad); }
.orders-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1rem; align-items: start; }
.col h2 { font-size: 1rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.order-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem; margin-bottom: .75rem; box-shadow: var(--shadow); }
.order-card.pending { border: 3px solid var(--bad); animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px rgba(179, 38, 30, .18); } }
.order-card .top { display: flex; justify-content: space-between; gap: .5rem; align-items: baseline; }
.order-card .num { font-size: 1.3rem; font-weight: 800; }
.order-card ul { list-style: none; padding: 0; margin: .5rem 0; }
.order-card li { padding: .25rem 0; border-bottom: 1px dashed var(--line); }
.order-card li .opts { color: var(--muted); font-size: .88rem; }
.order-card .actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .6rem; }
.minutes { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .5rem; }
.minutes .btn { flex: 1 0 auto; }
.start-overlay { position: fixed; inset: 0; z-index: 3000; background: rgba(20, 16, 12, .88); display: grid; place-items: center; padding: 1rem; color: #fff; text-align: center; }
.start-overlay .btn { font-size: 1.25rem; min-height: 64px; padding: 0 2rem; margin-top: 1rem; }
.switch { display: inline-flex; align-items: center; gap: .5rem; font-weight: 650; cursor: pointer; }

/* Menu builder */
.cat-block { margin-bottom: 1rem; }
.cat-block .cat-head { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; margin-bottom: .5rem; }
.cat-block .cat-head h2 { margin: 0; flex: 1; }
.menu-item-row { display: flex; gap: .75rem; align-items: center; padding: .6rem 0; border-top: 1px solid var(--line); flex-wrap: wrap; }
.menu-item-row .info { flex: 1; min-width: 180px; }
.menu-item-row img { width: 48px; height: 48px; object-fit: cover; border-radius: 8px; }
.group-editor { border: 1px solid var(--line); border-radius: 10px; padding: .75rem; margin-top: .75rem; background: #faf8f6; }
.opt-row { display: grid; grid-template-columns: 1fr 110px auto; gap: .5rem; align-items: end; margin-top: .4rem; }
.photo-preview { width: 120px; height: 120px; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); }
.hours-row { display: grid; grid-template-columns: 70px 1fr; gap: .5rem; align-items: center; padding: .4rem 0; border-bottom: 1px solid var(--line); }
.hours-row .times { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.hours-row input[type=time] { width: auto; margin: 0; }
code.snippet { display: block; padding: .7rem; background: #1f1c1a; color: #f5efe9; border-radius: 8px; overflow-x: auto; font-size: .85rem; white-space: pre-wrap; word-break: break-all; }

/* ---------- Kitchen ticket (80mm printers) */
.ticket-body { background: #fff; }
.ticket { width: 72mm; margin: 0 auto; padding: 2mm; font: 13px/1.35 "Courier New", ui-monospace, monospace; color: #000; }
.ticket hr { border: 0; border-top: 1px dashed #000; margin: 2mm 0; }
.tcenter { text-align: center; }
.tbig { font-size: 16px; font-weight: 700; }
.tbold { font-weight: 700; }
.tinvert { background: #000; color: #fff; font-weight: 700; padding: 1mm; }
.tline { display: flex; justify-content: space-between; gap: 2mm; }
.topt { padding-left: 4mm; font-size: 12px; }
.noprint { text-align: center; margin: 1rem; }
@media print {
  @page { size: 80mm auto; margin: 0; }
  .noprint, .toast { display: none !important; }
  .ticket-body { background: #fff; }
}

/* New-order alert on admin pages other than Live orders */
.new-order-alert { display: block; position: sticky; top: 0; z-index: 60; background: var(--bad); color: #fff; text-align: center;
  padding: .85rem 1rem; font-weight: 700; text-decoration: none; animation: alertflash 1s steps(2, start) infinite; }
.new-order-alert:hover, .new-order-alert:focus { color: #fff; text-decoration: underline; }
@keyframes alertflash { 50% { background: #7a1712; } }
@media (prefers-reduced-motion: reduce) { .new-order-alert { animation: none; } }

/* Privacy notice and ordering-page footer */
.legal-body { background: var(--bg, #f4f2ee); }
.legal { max-width: 720px; margin: 0 auto; padding: 1.5rem 1rem 3rem; line-height: 1.6; }
.legal h1 { font-size: 1.6rem; margin: 1rem 0; }
.legal h2 { font-size: 1.1rem; margin: 1.6rem 0 .4rem; }
.legal ul { padding-left: 1.2rem; }
.shop-footer { text-align: center; margin: 1.5rem 0 6rem; font-size: .9rem; }
.allergy-note { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: .75rem 1rem; font-size: .92rem; margin: 1rem 0; }

/* ---------- Takeaway branding: banner photo, logo, heading style, info cards */
.shop-header.has-cover { background: #1b1714 var(--cover) center / cover no-repeat; color: #fff; padding-top: 8.5rem; }
.shop-header.has-cover::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, .25) 38%, rgba(0, 0, 0, .8) 100%); }
.shop-header > * { position: relative; }
.shop-head { display: flex; gap: .9rem; align-items: center; }
.shop-logo { width: 76px; height: 76px; border-radius: 16px; object-fit: contain; background: #fff; padding: 6px; box-shadow: 0 4px 14px rgba(0, 0, 0, .2); flex: none; }
.shop-title { min-width: 0; }
.shop-title h1 { margin-bottom: .15em; overflow-wrap: anywhere; }
.shop-header .tagline { margin: 0 0 .5rem; font-size: 1rem; opacity: .95; }
.shop-actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .9rem; }
.chip { display: inline-flex; align-items: center; gap: .35em; min-height: 36px; padding: .4em .85em; border-radius: 999px; font: inherit; font-weight: 650; font-size: .9rem;
  color: inherit; text-decoration: none; cursor: pointer; background: color-mix(in srgb, currentColor 14%, transparent); border: 1px solid color-mix(in srgb, currentColor 35%, transparent); }
.shop[data-font="serif"] :is(h1, h2, h3) { font-family: Georgia, "Times New Roman", serif; letter-spacing: -.01em; }
.shop[data-font="rounded"] :is(h1, h2, h3) { font-family: ui-rounded, "SF Pro Rounded", "Arial Rounded MT Bold", "Nunito", system-ui, sans-serif; }
.shop[data-font="condensed"] :is(h1, h2, h3) { font-family: "Oswald", "Bebas Neue", "Arial Narrow", "Roboto Condensed", Impact, sans-serif; font-stretch: condensed; text-transform: uppercase; letter-spacing: .02em; }
.info-cards { display: grid; gap: .75rem; margin: 1rem; }
.info-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.1rem; }
.info-card h2 { font-size: 1.15rem; }
.about-text { white-space: pre-line; color: #3b3632; margin: 0; }
.info-line { margin: 0 0 .45rem; }
.socials { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .7rem; }
.socials a { padding: .4em .85em; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; font-weight: 650; font-size: .9rem; color: var(--ink); }
.preview-ribbon { position: fixed; top: 0; left: 0; right: 0; z-index: 60; background: #111; color: #fff; font-size: .78rem; font-weight: 700; text-align: center; padding: .3rem; pointer-events: none; }

/* ---------- "Your page" designer (admin) */
.design-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 1.25rem; align-items: start; }
.design-preview { position: sticky; top: 72px; }
.preview-toolbar { display: flex; justify-content: space-between; align-items: center; gap: .5rem; margin-bottom: .5rem; }
.preview-stage { background: #e8e2dc; border-radius: 16px; padding: 14px; display: flex; justify-content: center; }
.preview-frame { width: 390px; max-width: 100%; height: 720px; border: 0; border-radius: 22px; background: #fff; box-shadow: 0 10px 30px rgba(0, 0, 0, .18); }
.preview-stage.desktop .preview-frame { width: 100%; border-radius: 10px; }
.image-field { display: flex; gap: .9rem; align-items: center; margin-top: .4rem; }
.thumb { width: 84px; height: 84px; border-radius: 12px; background: #f1ede8; border: 1px dashed #cfc8c1; display: grid; place-items: center; color: var(--muted); font-size: .8rem; flex: none; overflow: hidden; }
.thumb.wide { width: 160px; }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb.logo img { object-fit: contain; background: #fff; }
.swatches { display: flex; gap: .45rem; flex-wrap: wrap; margin-top: .45rem; }
.swatch { width: 32px; height: 32px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px #cfc8c1; cursor: pointer; padding: 0; }
.swatch[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--ink); }
.font-choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: .5rem; margin-top: .45rem; }
.font-choice { border: 1px solid var(--line); border-radius: 10px; background: #fff; padding: .6rem; cursor: pointer; font-size: 1.05rem; font-weight: 700; color: var(--ink); }
.font-choice[aria-pressed="true"] { border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); }
.font-choice.serif { font-family: Georgia, "Times New Roman", serif; }
.font-choice.rounded { font-family: ui-rounded, "SF Pro Rounded", "Arial Rounded MT Bold", "Nunito", system-ui, sans-serif; }
.font-choice.condensed { font-family: "Oswald", "Arial Narrow", "Roboto Condensed", Impact, sans-serif; text-transform: uppercase; }
.savebar { position: sticky; bottom: 0; z-index: 15; display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .8rem 1rem; background: rgba(255, 255, 255, .97);
  border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.savebar .state { font-size: .9rem; color: var(--muted); }
.savebar .state.dirty { color: var(--warn); font-weight: 650; }
@media (max-width: 900px) { .design-layout { grid-template-columns: 1fr; } .design-preview { position: static; } .preview-frame { height: 640px; } }
.shop > .allergy-note { margin: 1rem; }
.btn.secondary[aria-pressed="true"] { background: var(--ink); color: #fff; border-color: var(--ink); }
.help-steps { margin-top: 1rem; background: #faf8f6; border: 1px solid var(--line); border-radius: 10px; padding: .7rem .9rem; }
.help-steps summary { font-weight: 650; cursor: pointer; }
.help-steps ol { margin: .6rem 0 0; padding-left: 1.2rem; }
.help-steps li { margin-bottom: .45rem; }
p.ok { color: var(--ok); font-weight: 650; }
.good-notice { background: #e7f4ea; color: #1d5b2c; font-weight: 600; }
.stripe-box { margin-top: .9rem; }
b.ok { color: var(--ok); }

/* ---------- Help pages */
.help-page { max-width: 860px; margin: 0 auto; }
#help-search { margin: .25rem 0 1rem; }
.help-topic { padding: .85rem 1.1rem; margin-bottom: .6rem; }
.help-topic summary { font-weight: 700; cursor: pointer; font-size: 1.04rem; }
.help-body { margin-top: .7rem; color: #3b3632; }
.help-body li { margin-bottom: .45rem; }
.help-body ol, .help-body ul { padding-left: 1.25rem; margin: .4rem 0 .6rem; }
.help-contact { margin-top: 1.5rem; background: #fff7ea; }
.booking-alert { background: #283593; animation: none; }
.bookings-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.booking-card .num { font-size: 1.5rem; }
.booking-day { margin: 1rem 0 .5rem; font-size: 1rem; color: var(--muted); }
.order-card.booking-card.pending { border: 3px solid #283593; animation: none; }
@media (max-width: 760px) { .bookings-cols { grid-template-columns: 1fr; } }
.tabs a { padding: .5em .7em; }
@media (min-width: 900px) { .tabs { flex-wrap: wrap; } }
/* Sections jumped to (e.g. back from Stripe) stop below the sticky top bar, not under it. */
.card.section[id] { scroll-margin-top: 7.5rem; }
@media (min-width: 900px) { .card.section[id] { scroll-margin-top: 4.5rem; } }
/* Keep the admin tabs on one line on a landscape iPad (1180px wide). */
@media (min-width: 900px) and (max-width: 1280px) { .topbar { gap: .6rem; } .tabs { gap: .1rem; } .tabs a { padding: .45em .55em; font-size: .95rem; } }
.plans-editor { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: .75rem; }
.plan-editor { padding: .9rem; display: grid; gap: .6rem; background: #faf8f6; }
.plan-editor details summary { cursor: pointer; font-weight: 600; font-size: .95rem; }
.history-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.history-list li { padding: .6rem .8rem; border: 1px solid var(--line); border-radius: 10px; background: #fff; }

/* Offers & loyalty, Your page choices, owner controls */
.loyalty-preview { margin: 1rem 0; padding: .75rem 1rem; border-radius: 10px; background: #fff8e1; border: 1px solid #f3dc8b; font-weight: 600; }
fieldset.plain { border: 0; padding: 0; margin: 0; min-width: 0; }
fieldset.plain legend { font-weight: 600; font-size: .95rem; padding: 0; margin-bottom: .4rem; }
fieldset.plain > .check + .check { margin-top: .5rem; }
.stack > fieldset.plain:not(:first-child) { margin-top: 1.25rem; }
.day-check { display: inline-flex; padding: .35rem .6rem; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.choice-row .font-choice { font-size: .95rem; display: flex; flex-direction: column; gap: .15rem; align-items: flex-start; text-align: left; }
.choice-row .font-choice small { font-weight: 500; color: var(--muted); font-size: .8rem; }
.danger-zone { margin-top: 1.5rem; border-top: 1px solid var(--line); padding-top: 1rem; }
.danger-zone summary { cursor: pointer; color: var(--bad); font-weight: 650; }
.filters { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.filters select, .filters input { margin-top: 0; }
.later-head { margin-top: 1.5rem; }

/* New-enquiry count on the owner's Enquiries tab */
.tabs .count { display: inline-block; min-width: 1.4em; padding: 0 .4em; margin-left: .25em; border-radius: 999px; background: #e8590c; color: #fff; font-size: .75rem; line-height: 1.4em; text-align: center; font-weight: 700; }
.enq-meta { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .3rem; }
.enq-details { margin: .4rem 0 0; padding: 0; list-style: none; font-size: .85rem; color: #555; }
.enq-details li { margin: .1rem 0; }
.filters { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin: .75rem 0 1rem; }
.filters select { width: auto; }

/* Ready-made looks on the "Your page" screen */
.look-row .look-choice { display: inline-flex; align-items: center; gap: .45rem; font-size: .95rem; }
.look-dot { width: 14px; height: 14px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0,0,0,.15); flex: none; }

/* Sign-in security (1.6): login choices, two-step setup, recovery codes, sessions, support access */
.remember { margin-top: .25rem; }
.remember .hint { display: block; font-weight: 400; }
.signed-in { display: grid; gap: .75rem; padding: 1rem; border: 1px solid var(--line); border-radius: 12px; background: #fff; margin-bottom: 1rem; }
.center-card.wide { max-width: 560px; }
.setup-steps { padding-left: 1.2em; display: grid; gap: .75rem; }
.qr { margin: .75rem 0; }
.qr svg { width: 220px; height: 220px; display: block; image-rendering: pixelated; }
.key { font-family: ui-monospace, Menlo, Consolas, monospace; letter-spacing: .04em; word-break: break-all; }
.codes { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .4rem .75rem; font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 1.05rem; }
.recovery { display: grid; gap: .75rem; }
.session-row { padding: .6rem 0; border-bottom: 1px solid var(--line); gap: .75rem; flex-wrap: wrap; }
.masterbar .link { color: inherit; text-decoration: underline; font-weight: 700; margin-left: .25rem; }
table.audit td { vertical-align: top; }

/* ---------- Your dashboard (platform owner): sidebar shell, quiet neutral palette (TR §3 visual standards) */
body:is(.master-shell, .admin-shell) { --bg: #f5f6f8; --line: #e2e5ea; --brand: #1d2939; --brand-ink: #fff; --muted-ink: #5b6472; background: var(--bg); }
:is(.master-shell, .admin-shell) a:not(.btn) { color: #1d2939; } /* buttons keep their own colours */
:is(.master-shell, .admin-shell) .shell { display: grid; grid-template-columns: 236px minmax(0, 1fr); min-height: 100vh; }
:is(.master-shell, .admin-shell) .sidebar { position: sticky; top: 0; height: 100vh; overflow-y: auto; background: #fff; border-right: 1px solid var(--line); padding: 1rem .75rem; display: flex; flex-direction: column; gap: .75rem; }
:is(.master-shell, .admin-shell) .sidebar-brand { font-weight: 800; font-size: 1.05rem; padding: 0 .5rem .25rem; }
:is(.master-shell, .admin-shell) .nav-group { margin: 0; }
:is(.master-shell, .admin-shell) .nav-group summary { cursor: pointer; list-style: none; padding: .35rem .5rem; font-size: .8rem; font-weight: 700; color: var(--muted-ink); border-radius: 6px; }
:is(.master-shell, .admin-shell) .nav-group summary::-webkit-details-marker { display: none; }
:is(.master-shell, .admin-shell) .nav-group summary::after { content: '▾'; float: right; font-size: .75rem; }
:is(.master-shell, .admin-shell) .nav-group:not([open]) summary::after { content: '▸'; }
:is(.master-shell, .admin-shell) .nav-group a, :is(.master-shell, .admin-shell) .sidebar-foot a { display: block; padding: .42rem .6rem; border-radius: 7px; text-decoration: none; color: #1d2939; font-weight: 550; font-size: .94rem; }
:is(.master-shell, .admin-shell) .nav-group a:hover, :is(.master-shell, .admin-shell) .sidebar-foot a:hover { background: #f0f2f5; }
:is(.master-shell, .admin-shell) .nav-group a.active, :is(.master-shell, .admin-shell) .sidebar-foot a.active { background: #1d2939; color: #fff; }
:is(.master-shell, .admin-shell) .nav-group a .count { margin-left: .3rem; }
:is(.master-shell, .admin-shell) .sidebar-foot { margin-top: auto; border-top: 1px solid var(--line); padding-top: .75rem; display: grid; gap: .25rem; }
:is(.master-shell, .admin-shell) .sidebar-foot .link { text-align: left; padding: .42rem .6rem; color: var(--muted-ink); }
:is(.master-shell, .admin-shell) .shell-main { min-width: 0; }
:is(.master-shell, .admin-shell) .shell-top { display: flex; align-items: center; gap: 1rem; padding: .7rem 1.25rem; background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
:is(.master-shell, .admin-shell) .shell-title { font-weight: 700; flex: 1; }
:is(.master-shell, .admin-shell) .nav-toggle { display: none; }
:is(.master-shell, .admin-shell) .shell-top a { color: var(--muted-ink); font-size: .92rem; }
@media (max-width: 860px) {
  :is(.master-shell, .admin-shell) .shell { grid-template-columns: minmax(0, 1fr); }
  :is(.master-shell, .admin-shell) .sidebar { position: fixed; inset: 0 auto 0 0; width: min(280px, 85vw); z-index: 40; transform: translateX(-105%); transition: transform .18s ease; box-shadow: 0 0 40px rgba(16, 24, 40, .18); }
  :is(.master-shell, .admin-shell).nav-open .sidebar { transform: none; }
  :is(.master-shell, .admin-shell) .nav-toggle { display: inline-block; padding: .4rem .75rem; border: 1px solid var(--line); border-radius: 8px; background: #fff; font: inherit; font-weight: 600; cursor: pointer; }
}
@media (prefers-reduced-motion: reduce) { :is(.master-shell, .admin-shell) .sidebar { transition: none; } }

/* status pills for accounts and leads */
.pill.st-live, .pill.st-won { background: #dcf3e5; color: #11603a; }
.pill.st-demo { background: #e8eefc; color: #1f3f8f; }
.pill.st-application_submitted, .pill.st-pending_verification, .pill.st-new { background: #fdf0d5; color: #7a4b00; }
.pill.st-approved, .pill.st-setup_in_progress, .pill.st-awaiting_owner_review, .pill.st-contacted, .pill.st-qualified, .pill.st-demo-stage, .pill.st-proposal { background: #e6eaf0; color: #1d2939; }
.pill.st-ready_for_launch { background: #d9f0f5; color: #0b5563; }
.pill.st-paused, .pill.st-suspended, .pill.st-lost { background: #fde2e1; color: #8a1c17; }
.pill.st-cancelled, .pill.st-archived { background: #ececec; color: #555; }

/* overview */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: .6rem; margin: .5rem 0 1.25rem; }
.stat { display: block; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: .75rem .85rem; text-decoration: none; color: inherit; }
a.stat:hover { border-color: #b8c0cc; }
.stat .n { display: block; font-size: 1.45rem; font-weight: 750; font-variant-numeric: tabular-nums; }
.stat .l { display: block; color: var(--muted-ink); font-size: .85rem; }
.queues { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: .75rem; }
.queue { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: .85rem 1rem; }
.queue h2 { font-size: 1rem; margin: 0 0 .5rem; display: flex; justify-content: space-between; gap: .5rem; }
.queue ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .35rem; }
.queue li { display: flex; justify-content: space-between; gap: .75rem; font-size: .93rem; }
.queue .empty { color: var(--muted-ink); font-size: .9rem; }

/* restaurant workspace */
.ws-head { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem 1rem; margin-bottom: .75rem; }
.ws-head h1 { margin: 0; }
.ws-tabs { display: flex; flex-wrap: wrap; gap: 0 .25rem; border-bottom: 1px solid var(--line); margin: .5rem 0 1rem; }
.ws-tabs button { background: none; border: 0; border-bottom: 2px solid transparent; padding: .55rem .75rem; font: inherit; font-weight: 600; color: var(--muted-ink); cursor: pointer; white-space: nowrap; }
.ws-tabs button[aria-selected="true"] { color: #1d2939; border-bottom-color: #1d2939; }
.ws-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: .75rem; }
.kv { display: grid; grid-template-columns: minmax(110px, auto) 1fr; gap: .3rem .9rem; margin: 0; }
.kv dt { color: var(--muted-ink); }
.kv dd { margin: 0; }
.missing-list { margin: .25rem 0 0; padding-left: 1.2rem; color: #8a1c17; }
.timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.timeline li { border-left: 3px solid var(--line); padding: .15rem 0 .15rem .7rem; }
.timeline .meta { display: block; color: var(--muted-ink); font-size: .82rem; }

/* leads pipeline */
.pipeline { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(220px, 1fr); gap: .6rem; overflow-x: auto; padding-bottom: .5rem; }
.pipeline .col { background: #eef0f3; border-radius: 10px; padding: .6rem; min-height: 120px; }
.pipeline .col h2 { font-size: .92rem; margin: 0 0 .5rem; display: flex; justify-content: space-between; }
.lead-card { display: block; width: 100%; text-align: left; background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: .55rem .65rem; margin-bottom: .45rem; font: inherit; cursor: pointer; }
.lead-card:hover { border-color: #b8c0cc; }
.lead-card b { display: block; }
.lead-card .small { color: var(--muted-ink); }
.lead-card .due { color: #8a1c17; font-weight: 650; }
.dupes { background: #fdf0d5; border-radius: 8px; padding: .6rem .8rem; }
.master-shell .pipeline .col h2 { text-transform: none; letter-spacing: 0; color: #1d2939; }
.master-shell table.list th { text-transform: none; letter-spacing: 0; font-size: .85rem; }
.lead-card .small { display: block; }

/* takeaway setup steps (TR §7) */
.setup-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 1rem; align-items: start; }
.setup-nav { list-style: none; margin: 0; padding: 0; display: grid; gap: .2rem; position: sticky; top: 4.5rem; }
.setup-nav button { width: 100%; text-align: left; background: none; border: 0; border-radius: 8px; padding: .45rem .6rem; font: inherit; color: var(--ink); cursor: pointer; }
.setup-nav button[aria-current="step"] { background: var(--ink); color: #fff; }
.setup-nav li.done button:not([aria-current="step"]) { color: #11603a; }
.chips { display: flex; flex-wrap: wrap; gap: .4rem; }
.chip { border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: .4rem .8rem; font: inherit; cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.look-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: .6rem; }
.look-card { display: grid; gap: .3rem; text-align: left; background: #fff; border: 2px solid var(--line); border-radius: 12px; padding: .8rem; font: inherit; cursor: pointer; }
.look-card[aria-pressed="true"] { border-color: var(--ink); }
.look-card .swatch { height: 36px; border-radius: 8px; }
.hours-row { display: grid; grid-template-columns: 140px 1fr auto 1fr; gap: .5rem; align-items: center; }
.hours-row input { margin-top: 0; }
.checklist { list-style: none; padding: 0; margin: 0; display: grid; gap: .3rem; }
.checklist li.done { color: #11603a; }
@media (max-width: 760px) {
  .setup-layout { grid-template-columns: minmax(0, 1fr); }
  .setup-nav { position: static; grid-auto-flow: column; grid-auto-columns: max-content; overflow-x: auto; }
  .hours-row { grid-template-columns: 1fr 1fr auto 1fr; }
}
.setup-preview-wrap { background: var(--bg, #f4f4f2); border: 1px solid var(--line); border-radius: 12px; padding: .75rem; overflow: auto; }
.setup-preview { display: block; margin: 0 auto; border: 1px solid var(--line); border-radius: 10px; background: #fff; height: 620px; }
.setup-preview.phone { width: 390px; max-width: 100%; }
.setup-preview.computer { width: 100%; min-width: 0; }
.menu-choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: .75rem; }
.choice-card { display: grid; gap: .5rem; align-content: start; border: 1px solid var(--line); border-radius: 12px; padding: 1rem; }
.choice-card h3 { margin: 0; }
.approve-item { align-items: flex-start; }
.setup-messages { border-left: 4px solid #1f3a68; }
.setup-messages ul { margin: .25rem 0; padding-left: 1.1rem; }
/* Launch Studio */
.launch-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .35rem; }
.launch-list li { display: grid; grid-template-columns: 1.6rem minmax(0, 1fr); gap: .4rem; align-items: start; }
.launch-list .mark { font-weight: 700; }
.launch-list li.done .mark { color: #11603a; }
.launch-list li.todo.critical .mark { color: var(--warn); }
.launch-list .detail { display: block; font-size: .85rem; color: var(--muted); }
.launch-files { list-style: none; padding: 0; margin: 0; display: grid; gap: .35rem; }
.launch-files li { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.launch-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: .75rem; align-items: start; margin-bottom: .75rem; }
.launch-grid > .stack { gap: .75rem; }
.launch-grid .card.section { margin: 0; }
.step-chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .3rem; }
.step-chips li { font-size: .82rem; border: 1px solid var(--line); border-radius: 999px; padding: .15rem .55rem; color: var(--muted); }
.step-chips li.done { color: #11603a; border-color: #b9dcc8; background: #f1f8f4; }
.approval-parts { list-style: none; margin: .5rem 0; padding: 0; display: grid; gap: .45rem; }
.approval-parts li { display: grid; gap: .1rem; }
.approval-parts b { font-size: .85rem; }
@media (max-width: 860px) { .launch-grid { grid-template-columns: minmax(0, 1fr); } }
/* orders nobody accepts: when a waiting order will be cancelled */
.accept-by { color: var(--muted); }
.accept-by.soon { color: var(--bad, #b42318); font-weight: 700; }
/* History: best sellers this month */
.best-sellers { margin: 0 0 1.25rem; }
.best-sellers h2 { font-size: 1.05rem; margin: 0 0 .5rem; }
.best-sellers ol { margin: 0; padding-left: 1.4rem; display: grid; gap: .35rem; }
.best-sellers li { display: flex; flex-wrap: wrap; gap: .25rem .75rem; align-items: baseline; }
.best-sellers .name { font-weight: 650; }

/* Menu import, ready-made menus and menu history (T-401, T-403) */
.menu-tools { margin: .25rem 0 .75rem; gap: .5rem; }
.menu-start h2 { margin-top: 0; }
.import-waiting { border-color: #f0c36d; background: #fffaf0; }
.import-waiting p { margin-top: 0; }
.import-summary { display: grid; gap: .4rem; }
.import-summary p { margin: 0; }
.import-summary h3 { margin: .5rem 0 0; font-size: 1rem; }
.import-blockers { border: 1px solid #f3b4ae; background: #fdf1f0; border-radius: 10px; padding: .75rem; display: grid; gap: .5rem; justify-items: start; }
.import-removed { color: var(--bad); }
.import-mode { border: 1px solid var(--line); border-radius: 10px; padding: .75rem; margin: .75rem 0 0; display: grid; gap: .5rem; }
.import-mode legend { font-weight: 700; padding: 0 .25rem; }
.import-section { margin-bottom: 1rem; }
.import-section-head { display: flex; align-items: center; gap: .75rem; margin-bottom: .25rem; }
.import-section-head .section-name { font-weight: 700; font-size: 1.05rem; flex: 1; min-width: 0; }
.import-row { border-top: 1px solid var(--line); padding: .6rem 0; display: grid; gap: .35rem; }
.import-row p { margin: 0; }
.import-main { display: grid; grid-template-columns: minmax(0, 1fr) 7.5rem auto; gap: .5rem; align-items: center; }
.price-field { display: flex; align-items: center; gap: .3rem; }
.price-field input { width: 100%; min-width: 0; }
.import-row input.needs { border-color: var(--bad); background: #fff7f6; }
.import-flags { display: flex; flex-wrap: wrap; gap: .35rem; }
.import-flags:empty { display: none; }
.import-more summary { cursor: pointer; font-size: .9rem; color: var(--muted); padding: .25rem 0; }
.import-more label { margin-top: .5rem; }
.import-bar { position: sticky; bottom: 0; display: flex; gap: .5rem; padding: .75rem 0 calc(.75rem + env(safe-area-inset-bottom)); background: var(--bg, #faf8f6); border-top: 1px solid var(--line); z-index: 5; }
.import-help { margin: .25rem 0 .75rem; }
.import-help summary { cursor: pointer; font-weight: 600; }
.import-example { background: #f4f1ee; padding: .1em .35em; border-radius: 4px; white-space: pre-wrap; }
.starter-list { display: grid; gap: .5rem; }
.starter-card { display: flex; gap: .75rem; align-items: center; border: 1px solid var(--line); border-radius: 10px; padding: .75rem; }
.starter-info { flex: 1; min-width: 0; }
.starter-info .pill { margin-left: .5rem; }
.starter-info p { margin: .25rem 0 0; }
/* 1.24: example prices, sample photos and prices in bulk */
.import-examples { border: 1px solid #f0c36d; background: #fffaf0; border-radius: 10px; padding: .75rem; display: grid; gap: .4rem; }
.import-photo { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.import-photo img { width: 64px; height: 36px; object-fit: cover; border-radius: 6px; }
.bulk-prices summary { cursor: pointer; }
.bulk-prices .row { margin-top: .75rem; align-items: center; flex-wrap: wrap; gap: .5rem; }
.bulk-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(10.5rem, 1fr)); gap: .5rem .75rem; margin-top: .5rem; }
.bulk-grid label { display: grid; gap: .25rem; font-size: .9rem; }
.example-banner, .sample-card.is-due, .admin-shell:not(.page-orders) .card.example-banner, .admin-shell:not(.page-orders) .card.sample-card.is-due { border-color: #f0c36d; background: #fffaf0; }
.example-banner p, .sample-card p { margin: .25rem 0; }
.sample-card.is-due { border-color: #e9b44c; }
.sample-list { margin: .5rem 0; padding-left: 1.2rem; }
.photo-wrap { position: relative; display: inline-block; line-height: 0; }
.sample-tag { position: absolute; left: 2px; bottom: 2px; background: rgba(20, 20, 20, .78); color: #fff; font: 600 9.5px/1.3 system-ui, sans-serif; padding: 1px 4px; border-radius: 4px; letter-spacing: .02em; }
.price-btn.is-example { outline: 2px dashed #e9b44c; outline-offset: 2px; }
.ws-import-list { list-style: none; margin: .25rem 0 1rem; padding: 0; display: grid; gap: .6rem; }
.ws-import-list li { border-left: 3px solid var(--line); padding-left: .6rem; }
#ws-menu .kv + p { margin-top: .75rem; }
.example-note { border: 1px solid #f0c36d; background: #fffaf0; border-radius: 10px; padding: .6rem .75rem; display: grid; gap: .35rem; }
.version-list { display: grid; gap: .5rem; margin-top: .75rem; }
.version-row { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; justify-content: space-between; border: 1px solid var(--line); border-radius: 10px; padding: .75rem; }
.version-info { min-width: 0; }
.version-preview h3 { margin: .75rem 0 .25rem; font-size: 1rem; }
.version-preview ul { margin: 0; padding-left: 1.2rem; }
.dialog-layer { z-index: 1100; align-items: center; padding: 1rem; }
.dialog-panel { border-radius: 18px; width: min(100%, 480px); }
.sheet-foot { margin-top: 1rem; gap: .5rem; }
@media (max-width: 560px) {
  .import-main { grid-template-columns: minmax(0, 1fr) 6.5rem; }
  .import-main > .btn { grid-column: 1 / -1; justify-self: start; }
}
.scan-progress { height: 6px; border-radius: 3px; background: linear-gradient(90deg, var(--line) 0 30%, var(--brand, #b3261e) 30% 50%, var(--line) 50%) 0 0 / 300% 100%; animation: scan-move 1.6s linear infinite; }
@keyframes scan-move { to { background-position: -300% 0; } }
@media (prefers-reduced-motion: reduce) { .scan-progress { animation: none; background: var(--line); } }

/* The order-taking app (T-601): offline page, alerts and install */
.offline { max-width: 34rem; margin: 12vh auto; padding: 0 1rem; text-align: center; }
.offline h1 { margin-bottom: .5rem; }
.net-banner { background: #3a1d1b; color: #fff; padding: .75rem 1rem; font-weight: 650; text-align: center; }
.alerts-state { display: grid; gap: .5rem; }
.device-list { display: grid; gap: .5rem; }
.device-row { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; justify-content: space-between; border: 1px solid var(--line); border-radius: 10px; padding: .65rem .75rem; }
.device-row .small { margin: 0; }

/* Home (MER-02) */
.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; }
.home-head { display: flex; flex-wrap: wrap; gap: 1rem; align-items: flex-end; justify-content: space-between; margin-bottom: 1rem; }
.home-head h1 { margin: 0 0 .35rem; }
.home-status { display: flex; flex-wrap: wrap; gap: .4rem; margin: 0; }
.home-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: .75rem; margin-bottom: 1rem; }
.home-stats .stat { display: grid; gap: .15rem; color: inherit; text-decoration: none; }
.home-stats a.stat:hover { border-color: var(--ink); }
.stat-value { font-size: 1.6rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.stat-label { font-weight: 650; }
.stat-sub { font-size: .85rem; color: var(--muted); }
.home-alerts { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.home-alert { display: flex; flex-wrap: wrap; gap: .5rem .75rem; align-items: center; justify-content: space-between; padding: .65rem .8rem; border-radius: 10px; border: 1px solid var(--line); border-left-width: 4px; }
.home-alert.bad { border-left-color: var(--bad); background: #fdf3f2; }
.home-alert.warn { border-left-color: #c77a00; background: #fffaf0; }
.home-alert.info { border-left-color: #6d7e96; }
.home-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1rem; margin: 1rem 0; }
.home-grid .card { margin: 0; }
.home-week { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.home-week th, .home-week td { text-align: left; padding: .4rem .25rem; border-top: 1px solid var(--line); }
.home-week thead th { border-top: 0; font-size: .85rem; color: var(--muted); }
.home-week td:last-child { position: relative; }
.week-bar { display: inline-block; vertical-align: middle; width: calc(var(--w) * .6); max-width: 60%; height: .55rem; border-radius: 3px; background: var(--brand); margin-right: .5rem; }
.home-recent { list-style: none; margin: 0 0 .5rem; padding: 0; display: grid; gap: .4rem; }
.home-actions { gap: .5rem; }
.launch-score { margin: 0 0 .5rem; }
.launch-list li .btn { margin-left: auto; }
.orders-head select { width: auto; min-width: 0; }

/* Incidents (MON-02) and messages to takeaways about a problem */
.banner.ok { background: #e3f3e7; color: var(--ok); }
.banner.notice { text-align: left; font-weight: 500; }
.banner.notice b { font-weight: 700; }
.banner.notice .when { opacity: .8; font-size: .9em; }
.incident-filter { max-width: 26rem; margin: .75rem 0 1rem; }
.incident-list { display: grid; gap: .5rem; margin-bottom: 1rem; }
.incident-row { display: flex; gap: .75rem; align-items: flex-start; padding: .8rem 1rem; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); color: inherit; text-decoration: none; }
.incident-row:hover { border-color: var(--ink); }
.incident-row .pill { flex: none; min-width: 4.6rem; text-align: center; }
.incident-row .what { display: grid; gap: .15rem; }
.incident-facts { margin: .5rem 0 0; }
.incident-notice { white-space: pre-wrap; padding: .6rem .8rem; border-left: 4px solid #c77a00; background: #fffaf0; border-radius: 6px; }
.pick-list { display: grid; gap: .35rem; max-height: 14rem; overflow: auto; margin-top: .5rem; padding: .5rem; border: 1px solid var(--line); border-radius: 8px; }
.timeline { list-style: none; margin: 0 0 1rem; padding: 0; display: grid; gap: .6rem; }
.timeline li { display: grid; grid-template-columns: 9.5rem 1fr; gap: .1rem .75rem; padding-left: .75rem; border-left: 3px solid var(--line); }
.timeline li .small { grid-column: 2; }
.timeline .when { color: var(--muted); font-variant-numeric: tabular-nums; }
.timeline .what { white-space: pre-wrap; }
.timeline .ev-alert { border-left-color: var(--bad); }
.timeline .ev-resolved { border-left-color: var(--ok); }
.timeline .ev-notice { border-left-color: #c77a00; }
@media (max-width: 560px) { .timeline li { grid-template-columns: 1fr; } .timeline li .small { grid-column: 1; } }
.integrations { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; }
.integrations li { display: flex; gap: .6rem; align-items: baseline; }
.integrations .pill { flex: none; min-width: 6.5rem; text-align: center; }

/* The takeaway's dashboard (TR §14): the same sidebar as your dashboard, with plain group labels. On Live orders it
   folds away so the order screen has the whole width; the Menu button opens it over the screen. */
.admin-shell .nav-label { margin: .5rem 0 .15rem; padding: 0 .5rem; font-size: .8rem; font-weight: 700; color: var(--muted-ink); }
.admin-shell .nav-group + .nav-group { margin-top: .25rem; }
.admin-shell .sidebar-brand { overflow-wrap: anywhere; }
.admin-shell .sidebar-foot a { color: var(--muted-ink); }
.admin-shell .masterbar { position: sticky; top: 0; z-index: 30; }
.admin-shell.page-orders .shell { grid-template-columns: minmax(0, 1fr); }
.admin-shell.page-orders .sidebar { position: fixed; inset: 0 auto 0 0; width: min(280px, 85vw); z-index: 40; transform: translateX(-105%); transition: transform .18s ease; box-shadow: 0 0 40px rgba(16, 24, 40, .18); }
.admin-shell.page-orders.nav-open .sidebar { transform: none; }
.admin-shell.page-orders .nav-toggle { display: inline-block; padding: .4rem .75rem; border: 1px solid var(--line); border-radius: 8px; background: #fff; font: inherit; font-weight: 600; cursor: pointer; }
.admin-shell.page-orders main.admin { max-width: none; }
@media (prefers-reduced-motion: reduce) { .admin-shell .sidebar { transition: none; } }

/* The 14 allergens in the dish editor (TRF-37.14) */
.allergen-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: .35rem .9rem; margin: .4rem 0 .6rem; }

/* Support tickets (TR §35): the takeaway's requests on Help, and your helpdesk */
.support-box .row.spread { align-items: center; }
.support-list { list-style: none; margin: .5rem 0 0; padding: 0; display: grid; gap: .45rem; }
.support-list li { display: flex; flex-wrap: wrap; gap: .4rem .75rem; align-items: baseline; }
.conversation { list-style: none; margin: 0 0 1rem; padding: 0; display: grid; gap: .6rem; }
.conversation li { padding: .6rem .8rem; border-radius: 10px; border: 1px solid var(--line); background: #fff; }
.conversation li p { margin: .25rem 0 0; white-space: pre-wrap; }
.conversation .msg-platform { border-left: 4px solid #1d2939; }
.conversation .msg-takeaway { border-left: 4px solid #6d7e96; }
.conversation .msg-internal { background: #fffaf0; border-left-color: #c77a00; }
.conversation .msg-system { background: transparent; border-style: dashed; }
.support-filter { max-width: 30rem; }

/* Menu import check screen: the printed menu beside the draft (AIM-05) */
.import-split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, 38%); gap: 1rem; align-items: start; }
.import-original { position: sticky; top: 4.5rem; max-height: calc(100vh - 6rem); overflow: auto; }
.import-original img { display: block; width: 100%; height: auto; margin-bottom: .6rem; border: 1px solid var(--line); border-radius: 8px; }
@media (max-width: 860px) { .import-split { grid-template-columns: 1fr; } .import-original { position: static; max-height: none; order: -1; } }

/* Your dashboard has its own look (1.21, your decision): a dark brand-green sidebar with an orange marker on the page
   you're on, so it's never mistaken for a takeaway's dashboard (white sidebar). Content, cards and buttons are shared. */
.master-shell .sidebar { background: #072D2A; border-right-color: #072D2A; color: #E7F0EE; }
.master-shell .sidebar-brand { color: #fff; }
.master-shell .sidebar-role { display: block; margin-top: .15rem; font-size: .75rem; font-weight: 600; color: #8FB3AE; }
.master-shell .nav-group summary { color: #8FB3AE; }
.master-shell .nav-group a, .master-shell .sidebar-foot a { color: #E7F0EE; }
.master-shell .nav-group a:hover, .master-shell .sidebar-foot a:hover { background: #0B3A36; }
.master-shell .nav-group a.active, .master-shell .sidebar-foot a.active { background: #0E5751; color: #fff; box-shadow: inset 3px 0 0 #FF7A30; }
.master-shell .sidebar a:focus-visible, .master-shell .sidebar button:focus-visible, .master-shell .sidebar summary:focus-visible { outline: 2px solid #FF7A30; outline-offset: 2px; }
.master-shell .sidebar-foot { border-top-color: rgba(255, 255, 255, .14); }
.master-shell .sidebar-foot .link { color: #8FB3AE; }
.master-shell .nav-group a .count { display: inline-block; min-width: 1.4em; padding: 0 .4em; border-radius: 999px; background: #FF7A30; color: #072D2A; font-size: .75rem; line-height: 1.4em; text-align: center; font-weight: 700; }
/* A Demo Centre demo login (1.24): the same bar as support access, in the demo blue, so it's never mistaken for real. */
.masterbar.demobar { background: #1f3f8f; }
.demobar-form { display: inline; }

/* =====================================================================================================
   2.0.2 (Builder B): the sign-in pages (log in on a takeaway's domain, two-step, choosing a password) in the one
   Food Order Hub look (brand.css tokens). Scoped to body.auth-body (views.authLayout), so ordering pages are untouched.
   A computer shows a food photo beside the card; a phone is one calm column.
   ===================================================================================================== */
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400; font-display: swap; src: url('/static/fonts/Inter-Regular.woff') format('woff'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 600; font-display: swap; src: url('/static/fonts/Inter-SemiBold.woff') format('woff'); }
@font-face { font-family: 'Inter Display'; font-style: normal; font-weight: 700; font-display: swap; src: url('/static/fonts/InterDisplay-Bold.woff') format('woff'); }
body.auth-body { --brand: var(--fh-teal-700, #0E5751); --brand-ink: #fff; --ink: var(--fh-ink, #0F2220); --muted: var(--fh-ink-3, #5F7370); --line: var(--fh-line, #DCE5E2); --bad: var(--fh-bad, #B42318);
  min-height: 100vh; min-height: 100dvh; background: var(--fh-bg, #F7F7F6); color: var(--fh-ink, #0F2220); font: 400 16px/1.55 var(--fh-font, system-ui, sans-serif); -webkit-font-smoothing: antialiased; }
.auth-body .auth-split { display: grid; grid-template-columns: minmax(0, 1fr); min-height: 100vh; min-height: 100dvh; }
.auth-body .auth-pane { display: flex; flex-direction: column; align-items: center; gap: 20px; padding: 20px 16px calc(28px + env(safe-area-inset-bottom)); min-width: 0; }
.auth-body .auth-top { width: min(100%, 440px); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; }
.auth-body .is-wide .auth-top { width: min(100%, 560px); }
.auth-body .auth-logo { min-height: 44px; border-radius: 8px; }
.auth-body .auth-logo svg { width: 32px; height: 32px; flex: none; }
.auth-body .auth-back { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; color: var(--fh-ink-2, #3B4F4C); font-weight: 600; font-size: .9375rem; text-decoration: none; border-radius: 8px; }
.auth-body .auth-back:hover { color: var(--fh-teal-700, #0E5751); text-decoration: underline; text-underline-offset: 3px; }
.auth-body :is(.auth-logo, .auth-back, .auth-way, a):focus-visible { outline: none; box-shadow: var(--fh-focus, 0 0 0 3px rgba(20, 112, 104, .35)); }
.auth-body .center-card.auth-card { width: min(100%, 440px); margin: 0; padding: 32px 32px 28px; background: var(--fh-surface, #fff); border: 1px solid var(--fh-line, #DCE5E2); border-radius: var(--fh-r-lg, 18px); box-shadow: var(--fh-shadow-2); }
.auth-body .center-card.auth-card.wide { width: min(100%, 560px); max-width: none; }
.auth-body .auth-card h1 { margin: 0 0 6px; font: 700 1.875rem/1.15 var(--fh-font-display, system-ui, sans-serif); letter-spacing: -.02em; color: var(--fh-ink, #0F2220); }
.auth-body .auth-card h2 { font: 700 1.2rem/1.25 var(--fh-font-display, system-ui, sans-serif); }
.auth-body .auth-lede { margin: 0 0 22px; color: var(--fh-ink-3, #5F7370); }
.auth-body .auth-step { margin: 0 0 8px; font: 600 .8125rem/1.3 var(--fh-font, system-ui, sans-serif); letter-spacing: .04em; text-transform: uppercase; color: var(--fh-teal-600, #147068); }
.auth-body .auth-card .muted { color: var(--fh-ink-3, #5F7370); }
.auth-body .auth-card label { font-weight: 600; font-size: .9375rem; color: var(--fh-ink, #0F2220); }
.auth-body .auth-card label .hint { color: var(--fh-ink-3, #5F7370); }
.auth-body .auth-card input:not([type=checkbox]) { min-height: 48px; margin-top: 6px; padding: 10px 14px; border: 1px solid #8C9A97; border-radius: var(--fh-r, 12px); font-size: 16px; background: #fff; }
.auth-body .auth-card input:not([type=checkbox]):focus { outline: none; border-color: var(--fh-teal-600, #147068); box-shadow: var(--fh-focus, 0 0 0 3px rgba(20, 112, 104, .35)); }
.auth-body .auth-card input.auth-code { font: 600 1.375rem/1 ui-monospace, Menlo, Consolas, monospace; letter-spacing: .18em; text-align: center; }
.auth-body .auth-card .check { font-size: .9375rem; }
.auth-body .auth-card .check input { width: 20px; height: 20px; accent-color: var(--fh-teal-700, #0E5751); }
.auth-body .auth-card .btn { min-height: 48px; border-radius: var(--fh-r-pill, 999px); background: var(--fh-teal-700, #0E5751); color: #fff; font: 600 1rem/1 var(--fh-font, system-ui, sans-serif); padding: 0 22px; filter: none; transition: background-color .15s; }
.auth-body .auth-card .btn:hover { background: var(--fh-teal-800, #0A3F3B); }
.auth-body .auth-card .btn.secondary { background: #fff; color: var(--fh-ink, #0F2220); border: 1px solid var(--fh-line-2, #C8D5D1); }
.auth-body .auth-card .btn.secondary:hover { border-color: var(--fh-teal-600, #147068); }
.auth-body .auth-card form .btn[type=submit] { width: 100%; }
.auth-body .auth-card .btn:focus-visible { outline: none; box-shadow: var(--fh-focus, 0 0 0 3px rgba(20, 112, 104, .35)); }
.auth-body .auth-card .link { color: var(--fh-teal-700, #0E5751); min-height: 44px; }
.auth-body .auth-card a:not(.btn):not(.auth-way) { color: var(--fh-teal-700, #0E5751); text-underline-offset: 2px; }
/* Errors: a clear box with a mark, not just red words */
.auth-body .auth-card .error:not([hidden]) { display: flex; gap: 10px; align-items: flex-start; margin: 0; padding: 12px 14px; border-radius: var(--fh-r, 12px); background: #FDECEA; border: 1px solid #F0A8A0; color: #8F1C13; font-weight: 600; font-size: .9375rem; line-height: 1.4; }
.auth-body .auth-card .error:not([hidden])::before { content: '!'; flex: none; display: grid; place-items: center; width: 20px; height: 20px; margin-top: 1px; border-radius: 50%; background: #B42318; color: #fff; font: 700 .8125rem/1 var(--fh-font, system-ui, sans-serif); }
.auth-body .auth-card .banner { margin: 0 0 16px; border-radius: var(--fh-r, 12px); text-align: left; }
.auth-body .signed-in { margin: 0 0 8px; border-color: var(--fh-line, #DCE5E2); background: var(--fh-mist, #F4F7F6); border-radius: var(--fh-r, 12px); }
.auth-body .auth-cancel { margin: 14px 0 0; }
/* Two-step setup: the QR code and the recovery codes, readable on a phone */
.auth-body .setup-steps { margin: 16px 0; }
.auth-body .qr svg { max-width: 100%; height: auto; border-radius: 10px; }
.auth-body .codes li { padding: 6px 10px; border-radius: 8px; background: var(--fh-mist, #F4F7F6); }
/* Help: the real ways to reach you */
.auth-body .auth-help { margin: 24px 0 0; padding: 18px 0 0; border-top: 1px solid var(--fh-line, #DCE5E2); }
.auth-body .auth-help-title { margin: 0 0 2px; font-weight: 600; color: var(--fh-ink, #0F2220); }
.auth-body .auth-help-text { margin: 0 0 12px; font-size: .9375rem; color: var(--fh-ink-3, #5F7370); }
.auth-body .auth-ways { display: grid; gap: 8px; }
.auth-body .auth-way { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 8px 14px; border: 1px solid var(--fh-line-2, #C8D5D1); border-radius: var(--fh-r, 12px); color: var(--fh-ink, #0F2220); text-decoration: none; font-size: .9375rem; background: #fff; overflow-wrap: anywhere; transition: border-color .15s, background-color .15s; }
.auth-body .auth-way:hover { border-color: var(--fh-teal-600, #147068); background: var(--fh-teal-50, #EEF6F3); }
.auth-body .auth-way b { font-weight: 600; }
.auth-body .auth-way-ico { flex: none; width: 20px; height: 20px; background: var(--fh-teal-700, #0E5751); -webkit-mask: var(--i) center / contain no-repeat; mask: var(--i) center / contain no-repeat; }
.auth-body .i-phone { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 4h4l2 5-2.5 1.5a11 11 0 0 0 5 5L15 13l5 2v4a2 2 0 0 1-2 2A16 16 0 0 1 3 6a2 2 0 0 1 2-2'/%3E%3C/svg%3E"); }
.auth-body .i-chat { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 12a8.5 8.5 0 0 1-12.6 7.4L3.5 20.5l1.2-4.6A8.5 8.5 0 1 1 21 12z'/%3E%3C/svg%3E"); }
.auth-body .i-mail { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Cpath d='m3.5 6.5 8.5 6.5 8.5-6.5'/%3E%3C/svg%3E"); }
.auth-body .auth-legal { display: none; margin: 0; color: var(--fh-ink-3, #5F7370); }
/* The photo beside the card: computers only */
.auth-body .auth-photo { display: none; }
@media (min-width: 960px) {
  .auth-body .auth-split { grid-template-columns: minmax(0, 1fr) minmax(0, .92fr); }
  .auth-body .auth-pane { justify-content: center; padding: 40px 48px; }
  .auth-body .auth-legal { display: block; width: min(100%, 440px); text-align: right; }
  .auth-body .is-wide .auth-legal { width: min(100%, 560px); }
  .auth-body .auth-photo { position: sticky; top: 0; display: block; height: 100vh; overflow: hidden; background: var(--fh-teal-900, #072D2A); }
  .auth-body .auth-photo img { width: 100%; height: 100%; object-fit: cover; }
  .auth-body .auth-photo::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(5, 34, 31, 0) 45%, rgba(5, 34, 31, .82) 100%); }
  .auth-body .auth-photo-text { position: absolute; z-index: 1; left: 40px; right: 40px; bottom: 40px; color: #fff; }
  .auth-body .auth-photo-kicker { margin: 0 0 6px; font: 600 .8125rem/1.3 var(--fh-font, system-ui, sans-serif); letter-spacing: .06em; text-transform: uppercase; color: var(--fh-accent-100, #FFE3D2); }
  .auth-body .auth-photo-line { margin: 0; max-width: 26ch; font: 700 1.75rem/1.2 var(--fh-font-display, system-ui, sans-serif); letter-spacing: -.02em; }
}
@media (max-width: 480px) {
  .auth-body .center-card.auth-card { padding: 24px 18px 22px; border-radius: 16px; }
  .auth-body .auth-card h1 { font-size: 1.625rem; }
  .auth-body .auth-back { font-size: .875rem; }
  .auth-body .codes { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) { .auth-body .auth-way, .auth-body .auth-card .btn { transition: none; } }
