:root {
  --bg: #f3f5f2; --surface: #ffffff; --ink: #17231f; --muted: #5d6b66; --line: #dde3df;
  --brand: #0f5c4a; --brand-ink: #ffffff; --spice: #e0a21b; --ok: #1f8a4c; --ok-ink: #17663a; --bad: #c2412d; --soft: #e8efeb;
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1513; --surface: #18211e; --ink: #e7eeea; --muted: #9aaba4; --line: #2a3632;
    --brand: #3fb592; --brand-ink: #08130f; --spice: #f0b83a; --ok: #4cc27e; --ok-ink: #4cc27e; --bad: #ec6a55; --soft: #1f2b27;
    color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--ink); font: 16px/1.45 var(--font); }
[hidden] { display: none !important; }
h1, h2, h3 { margin: 0; line-height: 1.2; text-wrap: balance; }
.wrap { max-width: 640px; margin: 0 auto; padding: 16px 16px 120px; }
.wrap.wide { max-width: 1100px; }
.hero { background: var(--brand); color: var(--brand-ink); padding: 22px 16px; }
.hero .inner { max-width: 640px; margin: 0 auto; position: relative; }
.hero small { opacity: .85; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.tag { font-size: .74rem; letter-spacing: .06em; text-transform: uppercase; font-weight: 700; color: var(--muted); }
.row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.price { font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap; }
.muted { color: var(--muted); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px; }
.modes { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 16px; }
.mode { border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); border-radius: 12px; padding: 10px; font: 600 1rem var(--font); cursor: pointer; text-align: left; }
.mode[aria-pressed="false"] { background: color-mix(in srgb, var(--surface) 72%, transparent); border-color: transparent; }
.mode[aria-pressed="true"] { background: var(--surface); border: 3px solid var(--spice); box-shadow: 0 2px 10px rgb(0 0 0 / .18); }
.mode[aria-pressed="true"]::before { content: "✓ "; color: var(--brand); }
.mode:disabled { opacity: .5; cursor: not-allowed; }
.mode span { display: block; font-weight: 400; font-size: .82rem; color: var(--muted); }
.cat { font-size: 1.1rem; margin: 18px 0 4px; }
.dish { display: flex; gap: 10px; align-items: center; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid var(--line); }
.dish .info { min-width: 0; flex: 1; }
.dish b { display: block; }
.dish small { color: var(--muted); }
.dish.off b { color: var(--muted); text-decoration: line-through; }
.qty { display: flex; align-items: center; gap: 8px; }
.round { border: 0; background: var(--brand); color: var(--brand-ink); width: 36px; height: 36px; border-radius: 50%; font-size: 1.2rem; cursor: pointer; flex: none; }
.round.minus { background: var(--soft); color: var(--ink); }
.round:disabled { background: var(--line); color: var(--muted); cursor: not-allowed; }
.pill { display: inline-block; font-size: .74rem; font-weight: 700; padding: 2px 9px; border-radius: 99px; background: var(--soft); color: var(--muted); }
.pill.ok { background: color-mix(in srgb, var(--ok) 15%, transparent); color: var(--ok-ink, var(--ok)); }
.pill.bad { background: color-mix(in srgb, var(--bad) 15%, transparent); color: var(--bad); }
.pill.new { background: color-mix(in srgb, var(--spice) 25%, transparent); color: var(--ink); }
.cartbar { position: fixed; left: 0; right: 0; bottom: 0; padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px)); background: var(--surface); border-top: 1px solid var(--line); }
.cartbar .inner { max-width: 640px; margin: 0 auto; }
label { font-size: .85rem; font-weight: 600; display: flex; flex-direction: column; gap: 4px; }
input, select, textarea { font: inherit; padding: 10px 11px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--ink); width: 100%; }
.btn { border: 0; border-radius: 12px; padding: 13px 16px; font: 700 1rem var(--font); cursor: pointer; background: var(--brand); color: var(--brand-ink); width: 100%; }
.btn.ghost { background: transparent; border: 1.5px solid var(--line); color: var(--ink); }
.btn.bad { background: var(--bad); color: #fff; }
.btn.small { padding: 9px 12px; width: auto; font-size: .92rem; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid var(--spice); outline-offset: 2px; }
.notice { border-radius: 12px; padding: 12px 14px; background: color-mix(in srgb, var(--spice) 20%, transparent); }
.error { border-radius: 12px; padding: 12px 14px; background: color-mix(in srgb, var(--bad) 15%, transparent); color: var(--bad); font-weight: 600; }

/* Restaurant app */
.topbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; padding: 12px 0; }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.tab { border: 0; background: transparent; color: var(--muted); font: 700 .95rem var(--font); padding: 9px 13px; border-radius: 10px; cursor: pointer; }
/* On a phone, one row slid with the finger, so the first order stays near the top. */
@media (max-width: 700px) {
  .tabs { width: 100%; min-width: 0; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; margin: 0 -4px; padding: 2px 4px; }
  .tabs::-webkit-scrollbar { display: none; }
  .tab { flex: none; white-space: nowrap; }
}
.tab[aria-selected="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 0 0 1px var(--line); }
.badge { background: var(--bad); color: #fff; border-radius: 99px; font-size: .72rem; padding: 1px 7px; margin-left: 4px; }
.orders { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.order { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.order.is-new { border-color: var(--spice); box-shadow: 0 0 0 3px color-mix(in srgb, var(--spice) 35%, transparent); }
.order ul { margin: 0; padding-left: 18px; }
.delays { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.switch { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; }
.switch b { display: block; }
.toggle { position: relative; width: 56px; height: 32px; border-radius: 99px; border: 0; background: var(--line); cursor: pointer; flex: none; }
.toggle::after { content: ""; position: absolute; top: 3px; left: 3px; width: 26px; height: 26px; border-radius: 50%; background: #fff; transition: left .15s; }
.toggle[aria-checked="true"] { background: var(--ok); }
.toggle[aria-checked="true"]::after { left: 27px; }
.empty { color: var(--muted); text-align: center; padding: 28px 10px; border: 1.5px dashed var(--line); border-radius: 14px; }
.conn { font-size: .8rem; }
.toast { position: fixed; left: 50%; bottom: calc(16px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 50;
  max-width: min(92vw, 520px); background: #b3261e; color: #fff; padding: 12px 16px; border-radius: 12px; box-shadow: 0 6px 24px rgb(0 0 0 / .25); font-weight: 600; }
.toast[hidden] { display: none; }
.print-alert { position: fixed; left: 12px; right: 12px; top: calc(12px + env(safe-area-inset-top)); z-index: 60; display: grid; gap: 10px;
  background: #b3261e; color: #fff; padding: 12px 14px; border-radius: 12px; box-shadow: 0 6px 20px rgba(0,0,0,.3); max-height: 60vh; overflow: auto; }
.print-alert .btn.ghost { color: #fff; border-color: rgba(255,255,255,.7); background: transparent; }
#ticket { display: none; }
@media print {
  @page { margin: 0; } /* no browser header or footer on the ticket; the paper width comes from the printer */
  body.admin > :not(#ticket) { display: none !important; } /* the hidden app would otherwise print as blank pages */
  body { background: #fff; }
  body:not(.client) * { visibility: hidden; }
  #ticket, #ticket * { visibility: visible; }
  #ticket { display: block; position: absolute; top: 0; left: 0; width: 72mm; margin: 0 4mm; font: 11pt/1.35 monospace; color: #000; background: #fff; }
  .slip { padding: 2mm 0 6mm; break-after: page; }
  .slip:last-child { break-after: auto; }
  .slip .center { text-align: center; }
  .slip .big { font-size: 13pt; }
  .slip small { display: block; font-size: 8pt; }
  .slip .huge { font-size: 18pt; letter-spacing: .05em; }
  .slip .strong, .slip b { font-weight: 700; }
  .slip .tl { display: flex; justify-content: space-between; gap: 2mm; }
  .slip .tl span:first-child { white-space: pre-wrap; }
  .slip .tl span:last-child { flex: none; }
  .slip .cut { border-top: 1px dashed #000; margin: 2mm 0; }
  .slip .inverse { background: #000; color: #fff; font-weight: 700; padding: 1mm 2mm; margin: 1mm 0; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .slip .boxed { border: 1.5px solid #000; padding: 1mm 2mm; margin: 1mm 0; font-weight: 700; }
  .slip .indent { padding-left: 5mm; }
  .slip.kitchen .big { font-size: 15pt; }
}
@media (prefers-reduced-motion: reduce) { .toggle::after { transition: none; } }
a.btn { display: block; text-align: center; text-decoration: none; }
a { color: var(--brand); }

/* Choice sheet */
.sheet-backdrop { position: fixed; inset: 0; background: rgb(0 0 0 / .45); display: flex; align-items: flex-end; justify-content: center; z-index: 20; }
.sheet { background: var(--surface); width: 100%; max-width: 640px; max-height: 90vh; overflow-y: auto; border-radius: 18px 18px 0 0; padding: 18px 16px calc(18px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 12px; }
.sheet p { margin: 0; }
body.locked { overflow: hidden; }
.group { border: 0; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.group legend { font-weight: 700; padding: 0 0 6px; }
.choice { flex-direction: row; align-items: center; gap: 10px; font-weight: 500; font-size: 1rem; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; }
.choice input { width: 20px; height: 20px; flex: none; accent-color: var(--brand); }
.choice span:nth-child(2) { flex: 1; }
.choice.off { opacity: .5; cursor: not-allowed; }
.choice:has(input:checked) { border-color: var(--brand); background: var(--soft); }
.block { display: block; }
.row .info { min-width: 0; flex: 1; }

/* Menu editor */
.actions { display: flex; align-items: center; gap: 8px; flex: none; }
.btn.add { align-self: flex-start; }
.row > label { flex: 1; }
.choice small { flex: none; }

/* Menu sections: a sticky tab bar and one coloured block per category */
.catnav { position: sticky; top: 0; z-index: 5; display: flex; gap: 8px; overflow-x: auto; padding: 10px 16px; margin: 0 -16px 4px;
  background: var(--bg); border-bottom: 1px solid var(--line); scrollbar-width: none; }
.catnav::-webkit-scrollbar { display: none; }
.chip { flex: none; border: 1.5px solid color-mix(in srgb, var(--accent) 45%, var(--line)); background: var(--surface); color: var(--ink);
  border-radius: 99px; padding: 7px 14px; font: 600 .9rem var(--font); cursor: pointer; white-space: nowrap; }
.chip.on { background: var(--accent); border-color: var(--accent); color: #fff; }
.menu-sec { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; margin-top: 16px; overflow: hidden; scroll-margin-top: 64px; }
.menu-sec > .cat { margin: 0; padding: 12px 14px; color: #fff; background: var(--accent); font-size: 1.05rem; }
.menu-sec .dish { padding: 12px 14px; }
.menu-sec .dish:last-child { border-bottom: 0; }
.a0 { --accent: #0f7a5f; } .a1 { --accent: #c2562d; } .a2 { --accent: #2f6fb3; } .a3 { --accent: #c23d74; }
.a4 { --accent: #9a6a00; } .a5 { --accent: #7a4fc2; } .a6 { --accent: #3d7a2f; } .a7 { --accent: #8a5a3c; }

/* Opening hours editor */
.card > .switch { padding: 0; }
.day { border-top: 1px solid var(--line, #e5e5e5); padding-top: 8px; display: flex; flex-direction: column; gap: 6px; }
.slot { display: flex; align-items: center; gap: 8px; }
.slot input { flex: 1; min-width: 0; }

/* Order lists and end-of-day report */
.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.filters .chip { --accent: var(--brand); }
.filters .chip[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; }
.stat b { display: block; font-size: 1.35rem; font-variant-numeric: tabular-nums; }
.stat small { color: var(--muted); }

/* Pre-orders */
.notice.strong { font-weight: 700; }
label.check { display: flex; flex-direction: row; align-items: flex-start; gap: 10px; font-weight: 400; }
label.check input { width: auto; flex: none; margin-top: 4px; }

/* Install the app */
.install { margin-top: 10px; }
.install-card { position: relative; display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 6px 12px;
  background: var(--surface); color: var(--ink); border-radius: 16px; padding: 12px 40px 12px 12px; box-shadow: 0 4px 14px rgb(0 0 0 / .15); }
.install-card img { border-radius: 12px; }
.install-text b { display: block; }
.hero .install-card small { opacity: 1; color: var(--muted); }
.install-close { position: absolute; top: 4px; right: 4px; width: 36px; height: 36px; border: 0; background: none; color: var(--muted); font-size: 1.4rem; cursor: pointer; }
.install-btn, .install-steps { grid-column: 1 / -1; margin: 0; }
.install-steps { font-size: .9rem; }
.hero .install small { opacity: .9; }
.again { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; border-color: var(--brand); }
.again .info { flex: 1; min-width: 0; }

/* Menu top bar: "order for later" while closed, then the section tabs; both stay visible */
.menutop { position: sticky; top: 0; z-index: 5; margin: 0 -16px 4px; background: var(--bg); border-bottom: 1px solid var(--line); }
.menutop .catnav { position: static; margin: 0; border-bottom: 0; }
.later { display: flex; align-items: center; gap: 10px; padding: 10px 16px; font-weight: 600; font-size: .92rem;
  background: color-mix(in srgb, var(--spice) 45%, var(--bg)); }
.later span { flex: 1; }
.later .btn { flex: none; }
.menu-sec { scroll-margin-top: 120px; }
.cat-desc { margin: 0; padding: 10px 14px 0; color: var(--muted); font-size: .9rem; }
.times { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.times .chip { --accent: var(--brand); text-align: center; }
.times .chip[aria-pressed="true"] { background: var(--brand); color: var(--brand-ink); }
.small-title { font-size: .85rem; }
.book-link { display: inline-block; margin-top: 10px; color: var(--brand-ink); font-weight: 700; text-decoration: underline; }

/* Dish with choices: one list at a time, answered choices fold into a line, the button stays in view */
.group-done { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 12px; border: 1px solid var(--brand);
  background: var(--soft); border-radius: 12px; font: inherit; color: var(--ink); cursor: pointer; }
.group-done span { color: var(--muted); font-size: .9rem; }
.group-done b { flex: 1; }
.group-done small { color: var(--brand); font-weight: 600; }
.group-done.empty { border-color: var(--line); background: var(--surface); }
.sheet-foot { position: sticky; bottom: calc(-18px - env(safe-area-inset-bottom, 0px)); display: flex; align-items: center; gap: 12px;
  margin: 0 -16px calc(-18px - env(safe-area-inset-bottom, 0px)); padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px));
  background: var(--surface); border-top: 1px solid var(--line); }
.sheet-foot .btn { flex: 1; }

/* Big screens: wider page, dishes in two columns, as restaurant menus usually read */
.dish small { font-size: .9rem; line-height: 1.35; }
@media (min-width: 960px) {
  body.client .wrap { max-width: 1100px; }
  body.client .menu-sec { display: grid; grid-template-columns: 1fr 1fr; column-gap: 0; }
  body.client .menu-sec > .cat, body.client .menu-sec > .cat-desc { grid-column: 1 / -1; }
  body.client .menu-sec .dish:nth-of-type(odd) { border-right: 1px solid var(--line); }
  body.client .menu-sec .dish:last-child { border-bottom: 1px solid var(--line); }
}

.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.dish .info.tap { cursor: pointer; }
.line-note { color: var(--accent, #0f5c4a); font-style: italic; }
.note-field { margin-top: 12px; }
.note-add { background: none; border: 0; padding: 2px 0; color: var(--muted); text-decoration: underline; font: inherit; font-size: .85rem; cursor: pointer; }
.note-input { margin-top: 4px; font-size: .9rem; }
.receipt h3 { margin: 0; }
@media print {
  body.client .hero, body.client #status > :not(.receipt), body.client .cartbar { display: none !important; }
  body.client .receipt { box-shadow: none; border: 0; }
}
.stack.tight { gap: 6px; }
.suggest { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 10px; background: #fff; overflow: hidden; }
.suggest button { text-align: left; background: none; border: 0; border-bottom: 1px solid var(--line); padding: 10px 12px; font: inherit; cursor: pointer; }
.suggest button:last-child { border-bottom: 0; }
.suggest button:hover, .suggest button:focus { background: #f2f7f5; }
.zone-info { font-size: .9rem; color: var(--muted); }
.zone-info.ok { color: #0f5c4a; font-weight: 600; }
.zone-info.bad { color: #b3261e; font-weight: 600; }
.zone-map { height: 320px; border-radius: 12px; border: 1px solid var(--line); }
.zone-row { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr auto; gap: 8px; align-items: end; }
.zone-row .dot { width: 12px; height: 12px; border-radius: 50%; display: inline-block; margin-right: 6px; }
@media (max-width: 600px) { .zone-row { grid-template-columns: 1fr 1fr; } }
.error-text { color: #b3261e; font-weight: 600; }
.zone-row .dot[data-color="0"] { background: #fc743a; }
.zone-row .dot[data-color="1"] { background: #2f80ed; }
.zone-row .dot[data-color="2"] { background: #9b51e0; }
.zone-row .dot[data-color="3"] { background: #27ae60; }
.zone-row .dot[data-color="4"] { background: #eb5757; }
.zone-row .dot[data-color="5"] { background: #f2c94c; }
.legal-links { text-align: center; font-size: 13px; color: var(--muted, #6b6b6b); margin-top: 24px; }
#infos p { margin: 0; }
.allergens { display: block; color: var(--muted); font-size: .8rem; }
.allergen-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px; }
.allergen-grid .choice { padding: 6px 10px; font-size: .9rem; }
.countdown { font-weight: 700; font-variant-numeric: tabular-nums; color: var(--brand); }
.countdown.late { color: var(--bad, #c0392b); }
.dish small.few { display: block; color: var(--bad); font-weight: 700; }
.ok-text { color: var(--ok-ink); font-weight: 700; }
.poster { max-width: 560px; margin: 16px auto; padding: 32px 24px; text-align: center; background: #fff; color: #111; border: 2px solid var(--brand); border-radius: 16px; }
.poster h1 { font-size: 2.2rem; margin: 0 0 8px; color: var(--brand); }
.poster-call { font-size: 1.6rem; font-weight: 800; margin: 8px 0; }
.poster-qr { display: block; width: min(80vw, 340px); height: auto; margin: 16px auto; }
.poster-url { font-size: 1.1rem; font-weight: 700; word-break: break-all; }
@media print {
  .no-print { display: none !important; }
  body.poster-page { background: #fff; }
  .poster { border: none; margin: 0 auto; }
}

/* Restaurant's own look: shop front photo behind the header, logo, sentence, social networks; dish photos. */
.hero.has-cover { background-color: var(--brand); background-size: cover; background-position: center; color: #fff; padding-top: 48px; }
.hero.has-cover .book-link, .hero.has-cover .social a { color: #fff; }
.hero .logo { width: 72px; height: 72px; border-radius: 18px; object-fit: cover; background: #fff; box-shadow: 0 2px 10px rgb(0 0 0 / .25); margin-bottom: 10px; display: block; }
.hero .tagline { margin: 4px 0 6px; font-size: 1.02rem; opacity: .95; }
.social { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.social a { color: var(--brand-ink); font-size: .85rem; font-weight: 700; padding: 4px 11px; border-radius: 99px; border: 1.5px solid currentColor; text-decoration: none; opacity: .92; }
.dish .thumb { width: 76px; height: 76px; border-radius: 12px; object-fit: cover; flex: none; background: var(--soft); }
.dish.off .thumb { filter: grayscale(1); opacity: .5; }
.chooser-photo { width: 100%; max-height: 240px; object-fit: cover; border-radius: 14px; }
.photo-preview { width: 96px; height: 96px; object-fit: cover; border-radius: 14px; border: 1px solid var(--line); }
.photo-preview.wide { width: 100%; max-width: 320px; height: 120px; }
.swatches { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.swatch { width: 34px; height: 34px; border-radius: 50%; border: 2px solid var(--surface); box-shadow: 0 0 0 1px var(--line); cursor: pointer; }
.swatches input[type=color] { width: 46px; height: 36px; padding: 2px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
/* Statistics: horizontal rankings and the sales-over-time bars (one hue, thin marks, rounded data ends). */
.stat .trend { display: block; margin-top: 2px; }
.hbar { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(60px, 1fr) auto; align-items: center; gap: 10px; }
.hbar-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hbar-track { height: 10px; background: var(--soft); border-radius: 4px; overflow: hidden; }
.hbar-fill { display: block; height: 100%; background: var(--brand); border-radius: 0 4px 4px 0; }
.hbar-value { font-variant-numeric: tabular-nums; font-size: .9rem; white-space: nowrap; }
.vbars { display: flex; align-items: flex-end; gap: 2px; height: 160px; border-bottom: 1px solid var(--line); }
.vbar { flex: 1 1 0; min-width: 0; height: 100%; display: flex; align-items: flex-end; padding: 0; border: 0; background: none; cursor: pointer; }
.vbar:hover, .vbar:focus-visible { background: var(--soft); outline: none; }
.vbar-fill { display: block; width: 100%; background: var(--brand); border-radius: 4px 4px 0 0; }
.small-print { font-size: .8rem; }
details > summary { cursor: pointer; color: var(--muted); }
.suggest-box { border-top: 1px dashed var(--line); padding-top: 12px; }
.history-head { width: 100%; background: none; border: 0; border-bottom: 1px solid var(--line); padding: 8px 0; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.qr { display: block; width: 220px; height: 220px; margin: 0 auto; }
.lang-switch { position: absolute; top: -8px; right: 0; background: rgb(0 0 0 / .18); border: 1px solid rgb(255 255 255 / .5); color: #fff; border-radius: 99px; padding: 4px 12px; font: 600 .8rem var(--font); cursor: pointer; }
/* Onglet Menu de l'appli restaurateur : une ligne par catégorie, touchée pour l'ouvrir. */
.cat-entry { display: flex; justify-content: space-between; align-items: center; gap: 12px; width: 100%; text-align: left; font: inherit; color: inherit; cursor: pointer; }
.cat-entry .actions { display: flex; align-items: center; gap: 8px; }
/* Restaurant app: the categories wear the colour they have on the customer site. */
.cat-entry.tinted { border-left: 6px solid var(--accent); background: color-mix(in srgb, var(--accent) 8%, var(--surface)); }
.cat-entry.tinted b { color: var(--accent); }
.cat-head.tinted { background: var(--accent); color: #fff; border-radius: 12px; padding: 4px 6px 4px 14px; }
.cat-head.tinted h2.cat { color: #fff; margin: 0; }
.cat-head.tinted .btn { color: #fff; border-color: rgb(255 255 255 / .6); }
.cat-entry .chev { font-size: 1.6rem; line-height: 1; color: var(--muted); }
/* Heures d'une commande (passée, acceptée, prévue, prête…) sur la fiche. */
.steps { display: grid; grid-template-columns: max-content 1fr; gap: 2px 12px; margin: 6px 0; font-size: .9rem; font-variant-numeric: tabular-nums; }
.steps dt { color: var(--muted); }
.steps dd { margin: 0; }

/* Marque Yakul : icône et nom (« ya » foncé, « kul » orange). Police Fredoka (licence libre SIL OFL), réduite aux lettres du nom. */
@font-face { font-family: 'Fredoka Yakul'; font-weight: 700; src: url('/static/fonts/fredoka-yakul.ttf') format('truetype'); font-display: swap; }
.brand-logo { display: block; width: 64px; height: 64px; margin: 0 auto; }
.brand-name { font-family: 'Fredoka Yakul', ui-rounded, 'Arial Rounded MT Bold', system-ui, sans-serif; font-weight: 700; color: #E8501C; text-align: center; letter-spacing: 0; }
.brand-name span { color: #1E1B1A; }
.hero.yakul { background: #fff; color: #1E1B1A; display: flex; align-items: center; gap: 14px; }
.hero.yakul .inner { display: flex; align-items: center; gap: 14px; }
.hero.yakul .brand-logo { margin: 0; }
.hero.yakul .brand-name { margin: 0; font-size: 3rem; text-align: left; line-height: 1; }

/* Long e-mail addresses and links never make a phone screen scroll sideways. */
#tab-clients, #tab-settings { overflow-wrap: anywhere; }

/* Restaurant app laid out like GloriaFood: page title, bottom bar, one line per order. */
body.admin #app { padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
.top-title { display: flex; align-items: center; gap: 10px; width: 100%; }
.top-title h1 { font-size: 1.45rem; flex: 1; }
.top-sub { width: 100%; font-size: .82rem; margin-top: -6px; }
.dot { width: 11px; height: 11px; border-radius: 50%; background: var(--muted); flex: none; }
.dot.on { background: var(--ok); }
.dot.off { background: var(--bad); }
.dot-btn { border: 0; background: none; padding: 12px; margin: -12px; cursor: pointer; display: inline-flex; }
.check-row { display: flex; gap: 10px; align-items: center; padding: 6px 0; }
.bottom-nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 15; display: flex; justify-content: space-around;
  background: var(--surface); border-top: 1px solid var(--line); padding: 6px 4px calc(6px + env(safe-area-inset-bottom, 0px)); }
.bottom-nav[hidden] { display: none; }
.bottom-nav button { flex: 1; max-width: 160px; border: 0; background: none; font: 600 .78rem var(--font); color: var(--muted);
  display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 4px; cursor: pointer; position: relative; }
.bottom-nav button[hidden] { display: none; }
.bottom-nav button[aria-current="page"] { color: var(--brand); }
.bottom-nav .nav-ico { font-size: 1.45rem; line-height: 1; filter: grayscale(1); opacity: .7; }
.bottom-nav button[aria-current="page"] .nav-ico { filter: none; opacity: 1; }
.bottom-nav .badge { position: absolute; top: 0; left: calc(50% + 8px); margin: 0; }
.view-tabs { display: flex; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.view-tabs::-webkit-scrollbar { display: none; }
.view-tabs button { flex: 1 0 auto; border: 0; background: none; font: 600 .95rem var(--font); color: var(--muted); padding: 10px 12px;
  border-bottom: 3px solid transparent; cursor: pointer; white-space: nowrap; }
.view-tabs button[aria-selected="true"] { color: var(--brand); border-bottom-color: var(--brand); }
.order-list { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.order-row { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; border: 0; border-bottom: 1px solid var(--line);
  background: none; padding: 10px 12px; font: inherit; color: var(--ink); cursor: pointer; min-height: 64px; }
.order-row:last-child { border-bottom: 0; }
.order-row:hover, .order-row:focus-visible { background: var(--soft); }
.mode-ico { flex: none; width: 52px; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.mode-ico > span { width: 40px; height: 40px; border-radius: 50%; background: var(--soft); display: grid; place-items: center; font-size: 1.3rem; }
.mode-ico small { font-size: .7rem; color: var(--muted); }
.order-row-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.order-row-who { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 600; }
.order-row-price { flex: none; white-space: nowrap; }
.auto-refused { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.auto-refused a { font-weight: 700; }
.logged-out { background: var(--bad); color: #fff; font-size: 1.1rem; }
.unprinted { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.more-group { display: flex; flex-direction: column; gap: 4px; }
.more-group h3 { font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin: 10px 4px 4px; }
.more-row { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; border: 0; border-radius: 12px; background: var(--surface);
  padding: 10px 12px; font: inherit; color: var(--ink); cursor: pointer; min-height: 58px; }
.more-row:hover { background: var(--soft); }
.more-ico { width: 42px; height: 42px; border-radius: 50%; background: var(--ink); display: grid; place-items: center; font-size: 1.2rem; flex: none; }
.lines { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.lines .row { justify-content: space-between; }
.map-link { font-size: .85rem; }
.tabs[hidden] { display: none; }

/* Restaurant app: full screen until touched, when the phone keeps the ringing off. */
.sound-gate { position: fixed; inset: 0; z-index: 70; display: grid; place-content: center; gap: 12px; padding: 24px; text-align: center;
  border: 0; font: inherit; color: #fff; background: #E8501C; }
.sound-gate b { font-size: 1.5rem; }
.sound-gate .big { font-size: 4rem; }
