/* Chop Chain — one shared stylesheet for every role's screens (login,
   admin CRUD, kitchen/porter boards, cashier POS, client ordering page).
   Kept as one file on purpose: these screens share components (buttons,
   badges, cards, the modal, the CRUD table) far more than they differ. */

:root {
  --ink: #1b211d;
  --paper: #edf1ee;
  --surface: #ffffff;
  --surface-2: #e2e8e3;
  --border: #c7d0ca;
  --text: #1b211d;
  --text-muted: #5b655e;
  --accent: #c8420f;
  --accent-strong: #a9350b;
  --on-accent: #fbf4ee;
  --herb: #3b6b47;
  --mustard: #a9720f;
  /* Status colours (done / ready / on, and in-progress). Deliberately NOT palette tokens: a
     restaurant's chosen palette re-tints --herb/--mustard as decoration, but "ready" and "active"
     must stay green and "preparing" amber whatever palette is picked. */
  --ok: #3b6b47;
  --warn: #a9720f;
  /* The accent as it reads on the dark --ink bar (wordmark, active-nav underline). core/Theme.php
     sets a lightened tint per palette; this fallback is the original value. */
  --accent-on-dark: #a9350b;
  --danger: #b3261e;
  --radius: 8px;
  --font: 'Work Sans', system-ui, -apple-system, sans-serif;
  /* Bold condensed caps display face — matches the weight/character of
     the reference's own headline type, which is a heavy sans throughout,
     never a serif. Anton only ships one weight (it's drawn black already,
     nothing to request); every rule using it sets font-weight:400
     explicitly so a browser never "helpfully" synthesizes a fake bold on
     top of an already-black face, which distorts the letterforms. */
  --font-display: 'Anton', Impact, 'Arial Narrow', sans-serif;
  --mono: 'IBM Plex Mono', 'SFMono-Regular', Consolas, monospace;
  --ease: cubic-bezier(.2, .7, .3, 1);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
/* An author-stylesheet class (.skeleton-grid{display:grid}, .item-grid{display:grid}, ...)
   otherwise beats the browser's own [hidden]{display:none} at equal specificity,
   since author rules always win over user-agent rules — toggling the `hidden`
   attribute from JS silently does nothing without this. */
[hidden] { display: none !important; }
body {
  background: var(--paper); /* fallback for browsers without color-mix() */
  background:
    radial-gradient(680px circle at 12% -8%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 60%),
    radial-gradient(560px circle at 105% 8%, color-mix(in srgb, var(--herb) 13%, transparent), transparent 55%),
    radial-gradient(520px circle at 50% 115%, color-mix(in srgb, var(--mustard) 10%, transparent), transparent 55%),
    var(--paper);
  /* NOT background-attachment:fixed — that repaints the whole gradient on
     every scroll frame, which is the classic cause of janky/stuttery
     scrolling on phones (mobile Safari in particular handles a fixed
     body background very poorly). Scrolling with the page costs nothing
     and looks effectively identical here. */
  color: var(--text);
  font-family: var(--font);
  line-height: 1.5;
  min-height: 100vh;
}
a { color: var(--accent-strong); }
h1, h2, h3 { font-family: var(--font-display); font-weight: 400; margin: 0 0 8px; text-wrap: balance; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.muted { color: var(--text-muted); }
button, .btn, .item-card, .cat-rail .cat, .pill, a { transition: background-color .15s var(--ease), border-color .15s var(--ease), color .15s var(--ease), transform .15s var(--ease), box-shadow .15s var(--ease); }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

.container { max-width: 1100px; margin: 0 auto; padding: 0 20px; }

/* ---- Topbar (every logged-in screen) ---- */
.topbar {
  display: flex; align-items: center; gap: 14px; justify-content: space-between;
  background: var(--ink); /* fallback for browsers without color-mix() */
  background: linear-gradient(100deg, var(--ink) 0%, color-mix(in srgb, var(--ink) 85%, var(--herb) 15%) 100%); color: var(--paper); padding: 13px 16px;
  border-bottom: 2px solid transparent;
  border-image: linear-gradient(90deg, var(--accent), var(--herb), var(--mustard)) 1;
  position: sticky; top: 0; z-index: 20;
}
.topbar .brand { font-family: var(--font-display); font-weight: 400; letter-spacing: .01em; font-size: 1.15rem; flex-shrink: 1; min-width: 0; max-width: 46vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topbar .brand span { color: var(--accent-on-dark); }
/* On a narrow phone six nav links + brand + logout in one row would
   otherwise wrap onto a second line or overflow the screen — this scrolls
   horizontally instead, same pattern as the ordering page's category rail. */
.topbar nav { display: flex; gap: 18px; overflow-x: auto; -ms-overflow-style: none; scrollbar-width: none; min-width: 0; }
.topbar nav::-webkit-scrollbar { display: none; }
.topbar nav a { position: relative; color: var(--paper); text-decoration: none; font-size: .88rem; opacity: .78; padding-bottom: 2px; white-space: nowrap; }
.topbar nav a::after { content: ''; position: absolute; left: 0; right: 100%; bottom: -3px; height: 2px; background: var(--accent-on-dark); transition: right .18s var(--ease); }
.topbar nav a:hover { opacity: 1; }
.topbar nav a:hover::after, .topbar nav a.active::after { right: 0; }
.topbar nav a.active { opacity: 1; font-weight: 600; }
.topbar .logout { color: var(--paper); opacity: .65; text-decoration: none; font-size: .84rem; white-space: nowrap; flex-shrink: 0; }
@media (max-width: 640px) {
  .topbar { gap: 10px; }
  .topbar .logout .logout-name { display: none; }
  /* nav takes only what is left after the brand, and scrolls inside it — the brand keeps its width */
  .topbar nav { flex: 1 1 0; }
  .topbar .brand { max-width: 50vw; }
}
.topbar .logout:hover { opacity: 1; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; gap: 6px; font-family: var(--font);
  font-size: .92rem; font-weight: 600; padding: 9px 16px; border-radius: 6px;
  border: 1px solid var(--border); background: var(--surface); color: var(--text);
  cursor: pointer; text-decoration: none;
}
.btn:hover { border-color: var(--text-muted); }
.btn:active { transform: scale(.96); }
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: var(--accent-strong); border-color: var(--accent-strong); }
.btn-ghost { background: transparent; border-color: transparent; }
.btn-danger { color: var(--danger); }
.btn-sm { padding: 5px 10px; font-size: .82rem; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn:disabled:active { transform: none; }
.btn:focus-visible, .pill:focus-visible, .cat-rail .cat:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 2px;
}

/* ---- Cards / page chrome ---- */
.page-head { display: flex; align-items: center; justify-content: space-between; margin: 28px 0 16px; }
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 18px;
  box-shadow: 0 2px 10px rgba(0,0,0,.04); transition: box-shadow .18s var(--ease), transform .18s var(--ease);
}
.stat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; margin-bottom: 24px; }
.stat-tile { border-left: 3px solid var(--accent); }
.stat-tile:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(0,0,0,.08); }
.stat-tile .num { font-family: var(--mono); font-size: 1.9rem; font-weight: 600; }
.stat-tile .label { font-size: .8rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .05em; margin-top: 2px; }

/* ---- Badges (order/promo/table status) ---- */
.badge { display: inline-block; font-family: var(--mono); font-size: .72rem; padding: 3px 8px; border-radius: 999px; letter-spacing: .03em; }
.badge-received  { background: #e6e1d6; color: #6b5a1a; }
.badge-preparing { background: #f3dfc2; color: var(--warn); }
.badge-ready     { background: #dcece0; color: var(--ok); }
.badge-served    { background: var(--surface-2); color: var(--text-muted); }
.badge-cancelled { background: #f3d9d6; color: var(--danger); }
.badge-on  { background: #dcece0; color: var(--ok); }
.badge-off { background: #f3d9d6; color: var(--danger); }

/* ---- Generic CRUD table (config/resources.php driven) ---- */
table.crud-table { width: 100%; border-collapse: collapse; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
table.crud-table th, table.crud-table td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--border); font-size: .9rem; }
table.crud-table th { background: var(--surface-2); font-family: var(--mono); font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; color: var(--text-muted); }
table.crud-table tr:last-child td { border-bottom: none; }
.table-wrap { overflow-x: auto; }
.table-toolbar { display: flex; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.table-toolbar input[type="search"] { padding: 8px 12px; border: 1px solid var(--border); border-radius: 6px; font-family: var(--font); min-width: 220px; }

/* ---- Modal (the CRUD create/edit form lives here) ---- */
.modal-backdrop {
  position: fixed; inset: 0; background: rgba(15,18,16,.5); backdrop-filter: blur(2px);
  display: flex; align-items: center; justify-content: center; padding: 20px; z-index: 50;
  opacity: 0; pointer-events: none; transition: opacity .18s var(--ease);
}
.modal-backdrop.open { opacity: 1; pointer-events: auto; }
.modal {
  background: var(--surface); border-radius: 14px; padding: 22px; width: 100%; max-width: 440px; max-height: 90vh; overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,.25); transform: scale(.95) translateY(8px); transition: transform .2s var(--ease);
}
.modal-backdrop.open .modal { transform: scale(1) translateY(0); }
.modal h3 { margin-bottom: 16px; }
.field { margin-bottom: 14px; display: flex; flex-direction: column; gap: 5px; }
.field label { font-size: .82rem; font-weight: 600; }
.field input, .field select, .field textarea {
  padding: 9px 11px; border: 1px solid var(--border); border-radius: 6px; font-family: var(--font); font-size: .92rem; background: var(--paper); color: var(--text);
}
.field textarea { resize: vertical; min-height: 70px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.form-error { color: var(--danger); font-size: .85rem; margin-bottom: 10px; }

/* ---- Auth / login ---- */
/* flex-direction:column explicitly, not left to default row — a second
   child here (there used to be one) would otherwise sit side-by-side and
   overflow/collide on a narrow phone instead of stacking. */
.auth-wrap { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: 20px; }
.auth-card {
  width: 100%; max-width: 360px; position: relative; overflow: hidden;
  box-shadow: 0 30px 70px rgba(0,0,0,.16), 0 0 0 1px var(--border);
}
.auth-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 5px;
  background: linear-gradient(90deg, var(--accent), var(--mustard), var(--herb));
}
.auth-card h2 { font-size: 1.4rem; margin-top: 6px; }

/* ---- Staff login: the "open book" — the restaurant's cover on the left, the sign-in page on the right,
   over a full-page wash of the restaurant's accent. Same layout as the school app's login. Everything
   reads from the palette tokens, so a restaurant's saved theme colours the whole page. Below 768px the
   cover becomes a strip above the form. ---- */
body.auth-page {
  background: var(--accent-strong);
  background: linear-gradient(135deg, color-mix(in srgb, var(--accent-strong) 62%, var(--ink)) 0%, var(--accent-strong) 50%, color-mix(in srgb, var(--accent-strong) 62%, var(--ink)) 100%);
}
body.auth-page { --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; --font-display: var(--font); font-size: 14px; }
.book-name, .book-logo { font-weight: 800; letter-spacing: -.01em; }
.book {
  width: 100%; max-width: 440px; display: flex; flex-direction: column;
  border-radius: 20px; overflow: hidden; background: var(--surface); box-shadow: 0 20px 60px rgba(0,0,0,.3);
}
.book-cover {
  position: relative; z-index: 1; isolation: isolate; overflow: hidden; color: var(--on-accent); text-align: center;
  padding: 28px 24px; display: flex; flex-direction: column; align-items: center;
  background: var(--accent);
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
}
/* Big rounded diagonal streaks — an inline SVG drawn in white and overlay-blended, so it always reads as a
   lighter tint of whatever accent is in use. Drifts slowly; still under prefers-reduced-motion. */
.book-cover::before {
  content: ''; position: absolute; inset: -10%; z-index: -1; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 300 400'%3E%3Cg stroke='white' stroke-linecap='round' fill='none'%3E%3Cline x1='10' y1='380' x2='58' y2='296' stroke-width='28' stroke-opacity='.9'/%3E%3Cline x1='74' y1='396' x2='98' y2='348' stroke-width='10' stroke-opacity='.55'/%3E%3Cline x1='62' y1='330' x2='152' y2='150' stroke-width='22' stroke-opacity='.75'/%3E%3Cline x1='122' y1='382' x2='148' y2='330' stroke-width='8' stroke-opacity='.5'/%3E%3Cline x1='142' y1='360' x2='208' y2='228' stroke-width='16' stroke-opacity='.6'/%3E%3Cline x1='192' y1='340' x2='248' y2='230' stroke-width='24' stroke-opacity='.7'/%3E%3Cline x1='212' y1='218' x2='232' y2='178' stroke-width='9' stroke-opacity='.5'/%3E%3Cline x1='242' y1='300' x2='292' y2='200' stroke-width='14' stroke-opacity='.55'/%3E%3Cline x1='30' y1='230' x2='50' y2='190' stroke-width='8' stroke-opacity='.4'/%3E%3Cline x1='100' y1='190' x2='118' y2='154' stroke-width='6' stroke-opacity='.35'/%3E%3C/g%3E%3C/svg%3E");
  background-repeat: no-repeat; background-size: 130% 130%; background-position: 0% 100%;
  mix-blend-mode: overlay; opacity: .55;
  animation: login-drift 26s ease-in-out infinite;
}
@keyframes login-drift { 0%, 100% { background-position: 0% 100%; } 50% { background-position: 14% 84%; } }
@media (prefers-reduced-motion: reduce) { .book-cover::before { animation: none; } }
.book-logo {
  width: 52px; height: 52px; border-radius: 14px; display: flex; align-items: center; justify-content: center; margin-bottom: 12px;
  font-family: var(--font-display); font-size: 1.35rem; letter-spacing: .02em; color: var(--on-accent);
  background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.3); box-shadow: 0 8px 24px rgba(0,0,0,.18);
}
.book-name { font-size: 1.7rem; line-height: 1.15; margin: 0 0 4px; letter-spacing: .01em; overflow-wrap: anywhere; }
.book-tagline { margin: 0; font-size: .88rem; opacity: .9; }
.book-page { padding: 26px 24px 28px; }
.book-form { width: 100%; max-width: 380px; margin: 0 auto; }
.book-form .field { margin-bottom: 16px; }
.book-form .field label { font-size: .84rem; }
.ig {
  display: flex; align-items: stretch; background: var(--surface); border: 1.5px solid var(--border); border-radius: 10px; overflow: hidden;
  transition: border-color .15s var(--ease), box-shadow .15s var(--ease);
}
.ig:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent); }
.ig-icon { display: flex; align-items: center; padding: 0 13px; color: var(--text-muted); background: var(--surface-2); border-right: 1px solid var(--border); }
.book-form .ig input { flex: 1; min-width: 0; border: 0; border-radius: 0; background: transparent; padding: 12px 13px; outline: none; }
.ig-btn { display: flex; align-items: center; padding: 0 14px; background: none; border: 0; border-left: 1px solid var(--border); color: var(--text-muted); cursor: pointer; }
.ig-btn:hover { background: var(--surface-2); color: var(--text); }
.ig-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.book-submit {
  width: 100%; justify-content: center; gap: 8px; padding: 13px 16px; font-size: 1rem; margin-top: 6px; border-radius: 10px; border: 0;
  background: var(--accent); background: linear-gradient(135deg, var(--accent-strong), var(--accent)); color: var(--on-accent);
}
.book-submit:hover { background: linear-gradient(135deg, var(--accent-strong), var(--accent-strong)); }
.book-alert {
  display: flex; align-items: flex-start; gap: 9px; margin-bottom: 18px; padding: 11px 14px; border-radius: 10px; font-size: .86rem; color: var(--danger);
  background: color-mix(in srgb, var(--danger) 9%, var(--surface)); border: 1px solid color-mix(in srgb, var(--danger) 35%, var(--surface));
}
.book-alert svg { flex: none; margin-top: 1px; }
.book-foot { margin: 18px 0 0; font-size: .82rem; text-align: center; }
.book-copy { margin: 0; font-size: .8rem; color: rgba(255,255,255,.78); text-align: center; }

@media (min-width: 768px) {
  .book { max-width: 920px; flex-direction: row; min-height: 560px; }
  .book-cover {
    flex: 0 0 44%; justify-content: center; padding: 48px 40px;
    box-shadow: 10px 0 30px -14px rgba(0,0,0,.35); /* the gutter: the cover's edge casts onto the page */
  }
  .book-logo { width: 64px; height: 64px; border-radius: 16px; font-size: 1.6rem; margin-bottom: 16px; }
  .book-name { font-size: clamp(1.9rem, 3vw, 2.4rem); }
  .book-tagline { font-size: .95rem; }
  .book-page { flex: 1; display: flex; align-items: center; padding: 48px 56px; }
}

/* ---- KDS / Porter ticket board ---- */
.board { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; padding: 20px 0; }
.ticket {
  background: var(--surface); border: 1px solid var(--border); border-top: 4px solid var(--warn); border-radius: 10px; padding: 16px;
  box-shadow: 0 2px 10px rgba(0,0,0,.05); animation: card-in .3s var(--ease) both;
}
.ticket.ready { border-top-color: var(--ok); }
.ticket .head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; }
.ticket .code { font-family: var(--mono); font-weight: 600; }
.ticket .type { font-size: .78rem; color: var(--text-muted); text-transform: uppercase; }
.ticket ul { margin: 10px 0; padding-left: 18px; font-size: .88rem; }
.ticket .mods { color: var(--text-muted); font-size: .78rem; }
.empty-state { color: var(--text-muted); padding: 40px 0; text-align: center; }

/* ---- Client ordering page — this is the customer storefront, the one
   screen that should feel designed rather than merely functional.
   Full-bleed, like the reference: no floating card, no rounded corners,
   no shadow, no colored margin visible around it on a wide screen — the
   page just fills the browser the way an ordinary website does. --page-pad
   is the one shared side-margin every row below scales together, from a
   16px phone edge up to 64px on a wide desktop — never a fixed-width
   column stranded in empty space either way. */
.order-shell {
  --page-pad: clamp(16px, 4vw, 64px);
  width: 100%; background: var(--surface); min-height: 100vh; padding-bottom: 100px;
  position: relative;
}
.order-shell::before {
  content: ''; display: block; height: 4px;
  background: linear-gradient(90deg, var(--accent), var(--mustard), var(--herb));
}
.order-header {
  padding: 20px var(--page-pad) 16px; border-bottom: 1px solid var(--border);
}
.order-header .wordmark { font-family: var(--font-display); font-size: 1.7rem; font-weight: 400; letter-spacing: -.01em; }
.order-header .wordmark .accent-word { color: var(--accent); }
.order-header .tagline { font-size: .8rem; color: var(--text-muted); margin-top: 2px; }
.order-header .table-chip {
  display: inline-flex; align-items: center; gap: 5px; margin-top: 8px; font-size: .74rem; font-weight: 600;
  background: var(--surface-2); background: color-mix(in srgb, var(--herb) 14%, transparent); color: var(--herb); padding: 4px 10px; border-radius: 999px;
}
.order-header .table-chip::before { content: '●'; font-size: .55rem; }

.search-bar {
  display: flex; align-items: center; gap: 8px; margin: 14px var(--page-pad) 0; padding: 10px 16px;
  background: var(--surface-2); border-radius: 999px; border: 1px solid transparent;
}
.search-bar:focus-within { border-color: var(--accent); background: var(--surface); }
.search-bar svg { flex-shrink: 0; color: var(--text-muted); }
.search-bar input {
  border: none; background: transparent; font-family: var(--font); font-size: .92rem; color: var(--text);
  width: 100%; outline: none;
}
.search-bar input::placeholder { color: var(--text-muted); }
.search-bar .clear-search { display: none; border: none; background: none; color: var(--text-muted); cursor: pointer; font-size: 1.1rem; line-height: 1; padding: 0 2px; }
.search-bar.has-query .clear-search { display: block; }
.search-status { padding: 10px var(--page-pad) 0; font-size: .82rem; color: var(--text-muted); }

.order-type-switch { display: flex; gap: 8px; padding: 14px var(--page-pad) 0; }
/* The up-front "how would you like to order?" row — asked before
   browsing starts, not buried inside the cart drawer. */
#top-order-type { padding: 16px var(--page-pad); border-bottom: 1px solid var(--border); }
#top-order-type .pill { padding: 9px 18px; font-size: .82rem; }
.pill {
  font-family: var(--font); font-weight: 700; font-size: .8rem; padding: 7px 15px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--surface); cursor: pointer; color: var(--text-muted);
}
.pill.active { background: var(--accent); border-color: var(--accent); color: var(--on-accent); font-weight: 600; box-shadow: 0 3px 10px rgba(200,66,15,.35); box-shadow: 0 3px 10px color-mix(in srgb, var(--accent) 35%, transparent); }
.pill:not(.active):hover { border-color: var(--text-muted); color: var(--text); }

/* ---- Category rail: plain bold-caps text + an underline on the active
   tab, not a filled pill — matches the reference exactly, and reads as
   more "editorial menu" than "app filter chips." ---- */
.cat-rail-wrap { position: relative; border-bottom: 1px solid var(--border); }
.cat-rail {
  display: flex; gap: 16px; padding: 14px var(--page-pad) 0; overflow-x: auto; -ms-overflow-style: none; scrollbar-width: none;
  position: sticky; top: 0; background: var(--surface); z-index: 5;
}
@media (min-width: 700px) { .cat-rail { gap: 28px; } }
.cat-rail::-webkit-scrollbar { display: none; }
.cat-rail .cat {
  font-family: var(--font-display); font-weight: 400; text-transform: uppercase;
  white-space: nowrap; font-size: 1rem; letter-spacing: .02em;
  color: var(--text-muted); cursor: pointer; padding-bottom: 12px; border-bottom: 3px solid transparent;
}
.cat-rail .cat:hover { color: var(--text); }
.cat-rail .cat.active { color: var(--ink); border-bottom-color: var(--accent); }
/* A right-edge fade + chevron — shown only when JS finds the rail
   actually overflows (Order.updateCatRailHint()) — hints there's more
   to scroll to, the same affordance the reference's category row uses. */
.cat-rail-hint {
  display: none; position: absolute; right: 0; top: 0; bottom: 4px; width: 40px; pointer-events: none;
  align-items: center; justify-content: flex-end; padding-right: 4px; color: var(--text-muted);
  background: linear-gradient(90deg, transparent, var(--surface) 65%);
}
.cat-rail-wrap.overflowing .cat-rail-hint { display: flex; }

.section-heading { font-family: var(--font-display); font-weight: 400; font-size: 1.7rem; text-transform: uppercase; letter-spacing: .01em; padding: 24px var(--page-pad) 0; margin: 0; }

/* Fixed column counts at each breakpoint — 2 on phone, 3 on tablet, 4 on
   desktop — matching the reference's own grid exactly, not an auto-fill
   that lands on however many columns happen to fit a given width. */
.item-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; padding: 16px var(--page-pad); }
@media (min-width: 700px) {
  .item-grid { grid-template-columns: repeat(3, 1fr); gap: 28px; padding: 24px var(--page-pad); }
}
@media (min-width: 1024px) {
  .item-grid { grid-template-columns: repeat(4, 1fr); gap: 32px; }
}
/* No border, no resting shadow — a reference ordering card floats on the
   page and lets the (future) photo carry the visual weight, rather than
   every card being boxed in like a UI component.
   flex-direction:column here + margin-top:auto on .card-cta below is
   what keeps every button in a row sitting on the same baseline even
   when one dish's name wraps to three lines and its neighbor's wraps to
   one — a grid item stretches to fill its row's computed height by
   default, so the flex column just needs to push its button to the
   bottom of that stretched height. Without this a longer name pushes
   just that card's button down, visibly misaligning the row on a
   2-column phone width where wrapping is common. */
.item-card {
  display: flex; flex-direction: column;
  border-radius: 10px; overflow: hidden; background: var(--surface); cursor: pointer;
  animation: card-in .35s var(--ease) both; position: relative;
}
.item-card:hover .item-photo { transform: scale(1.02); }
.item-card:active { transform: scale(.98); }
.item-grid .item-card:nth-child(1) { animation-delay: .02s; } .item-grid .item-card:nth-child(2) { animation-delay: .06s; }
.item-grid .item-card:nth-child(3) { animation-delay: .1s; }  .item-grid .item-card:nth-child(4) { animation-delay: .14s; }
.item-grid .item-card:nth-child(5) { animation-delay: .18s; } .item-grid .item-card:nth-child(6) { animation-delay: .22s; }
/* A neutral, consistent placeholder — not four different rainbow
   gradients per category. The reference doesn't color-code categories
   with background hue either; its photography carries the variety.
   Swap this for a real <img> the moment menu items have photos. */
.item-photo {
  /* aspect-ratio, not a fixed height — the card gets meaningfully wider
     at the 3- and 4-column breakpoints, and a fixed 150px would look
     squashed at that width instead of scaling proportionally the way
     the reference's own photo area does. */
  aspect-ratio: 4 / 3; position: relative; display: flex; align-items: center; justify-content: center;
  background: var(--surface-2); border-radius: 10px; color: var(--accent); transition: transform .25s var(--ease);
}
.item-photo svg { width: 42px; height: 42px; opacity: .8; }
.item-photo img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; border-radius: 10px; }
.item-info { padding: 12px 2px 0; display: flex; flex-direction: column; flex: 1; }
.item-info .name { font-family: var(--font-display); font-weight: 400; font-size: 1.1rem; text-transform: uppercase; line-height: 1.15; letter-spacing: .01em; }
.item-info .price { font-family: var(--font); font-size: .92rem; color: var(--text); font-weight: 600; margin-top: 4px; }
.price-was { color: var(--text-muted); font-weight: 400; text-decoration: line-through; margin-left: 4px; }
/* Every card gets one — icon-only, same red, same shape regardless of
   which icon it shows, in the card's own flow (not a corner badge). Add
   jumps straight to the cart for a plain item; the sliders icon opens
   the modal for one with modifier groups (spice level, extras, ...). */
.card-cta {
  /* margin-top:auto (not a fixed value) is what pushes this to the
     bottom of .item-info's flex column regardless of how many lines the
     name above wrapped to — see .item-card's comment. */
  display: flex; align-items: center; justify-content: center; width: 100%; margin-top: auto; padding: 12px;
  border-radius: 999px; border: none; background: var(--accent); color: var(--on-accent);
  cursor: pointer; box-shadow: 0 4px 12px rgba(0,0,0,.15);
}
.card-cta:hover { background: var(--accent-strong); }
.card-cta:active { transform: scale(.94); }
.card-cta.added { background: var(--ok); animation: pop .3s var(--ease); }
@keyframes pop { 0% { transform: scale(1); } 40% { transform: scale(1.12); } 100% { transform: scale(1); } }

/* Same column breakpoints as .item-grid, so the placeholder doesn't
   reflow the instant the real menu replaces it. */
.skeleton-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; padding: 16px var(--page-pad, 16px); }
@media (min-width: 700px) {
  .skeleton-grid { grid-template-columns: repeat(3, 1fr); gap: 28px; padding: 24px var(--page-pad, 16px); }
}
@media (min-width: 1024px) {
  .skeleton-grid { grid-template-columns: repeat(4, 1fr); gap: 32px; }
}
.skeleton-card { aspect-ratio: 4 / 3.6; border-radius: 10px; background: linear-gradient(100deg, var(--surface-2) 30%, var(--border) 50%, var(--surface-2) 70%); background-size: 200% 100%; animation: shimmer 1.3s ease-in-out infinite; }

/* ---- Store Location page ---- */
.locations-header { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.locations-layout { display: flex; flex-direction: column; }
.locations-list { min-width: 0; }
#branch-map { height: 360px; background: var(--surface-2); }
@media (min-width: 900px) {
  .locations-layout { flex-direction: row; align-items: stretch; }
  .locations-list { flex: 1 1 440px; max-width: 480px; max-height: calc(100vh - 140px); overflow-y: auto; }
  #branch-map { flex: 1; height: auto; }
}
.branch-card { padding: 16px var(--page-pad); border-bottom: 1px solid var(--border); cursor: pointer; }
.branch-card:hover { background: var(--surface-2); }
.branch-card h3 { font-family: var(--font-display); font-weight: 400; text-transform: uppercase; font-size: 1.2rem; margin: 0 0 4px; }
.branch-card .branch-address { color: var(--text-muted); font-size: .88rem; margin: 0 0 6px; }
.branch-card .branch-phone { color: var(--accent-strong); text-decoration: none; font-size: .88rem; font-weight: 600; }
.branch-hours { display: flex; align-items: center; gap: 6px; font-size: .85rem; margin: 8px 0; }
.branch-hours .dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.branch-hours .dot.open { background: var(--ok); }
.branch-hours .dot.closed { background: var(--danger); }
.branch-tags { display: flex; gap: 6px; margin: 8px 0 0; }
.branch-actions { display: flex; gap: 8px; margin-top: 12px; }
.branch-pin { background: transparent; border: none; }

.cart-bar {
  position: fixed; bottom: 14px; left: 50%; width: calc(100% - 28px); max-width: 452px;
  background: var(--ink); color: var(--paper); border-radius: 14px; padding: 14px 18px;
  display: flex; align-items: center; justify-content: space-between; font-size: .9rem; cursor: pointer;
  box-shadow: 0 10px 30px rgba(0,0,0,.28); z-index: 8;
  transform: translate(-50%, 140%); opacity: 0; transition: transform .28s var(--ease), opacity .2s var(--ease);
}
.cart-bar.visible { transform: translate(-50%, 0); opacity: 1; }
.cart-bar.bump { animation: cart-bump .3s var(--ease); }
.cart-bar:active { transform: translate(-50%, 0) scale(.97); }
.cart-bar .cta { color: #ff9d6e; font-weight: 700; }

@keyframes card-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
@keyframes cart-bump { 0% { transform: translate(-50%, 0) scale(1); } 35% { transform: translate(-50%, 0) scale(1.05); } 100% { transform: translate(-50%, 0) scale(1); } }

.drawer-backdrop {
  position: fixed; inset: 0; background: rgba(15,18,16,.5); backdrop-filter: blur(2px); z-index: 60;
  opacity: 0; pointer-events: none; transition: opacity .2s var(--ease);
}
.drawer-backdrop.open { opacity: 1; pointer-events: auto; }
.drawer {
  position: fixed; right: 0; top: 0; bottom: 0; width: 100%; max-width: 420px; background: var(--surface);
  box-shadow: -12px 0 32px rgba(0,0,0,.2); padding: 20px; overflow-y: auto;
  transform: translateX(100%); transition: transform .25s var(--ease);
}
.drawer-backdrop.open .drawer { transform: translateX(0); }
.cart-line { display: flex; justify-content: space-between; align-items: flex-start; padding: 10px 0; border-bottom: 1px dashed var(--border); font-size: .9rem; animation: fade-in .2s var(--ease) both; }
.qty-stepper { display: inline-flex; align-items: center; gap: 8px; }
.qty-stepper button { width: 26px; height: 26px; border-radius: 6px; border: 1px solid var(--border); background: var(--surface); cursor: pointer; font-size: 1rem; line-height: 1; }
.qty-stepper button:active { transform: scale(.9); }
.track-steps { display: flex; justify-content: space-between; margin: 20px 0; }
.track-steps .step { flex: 1; text-align: center; font-size: .78rem; color: var(--text-muted); position: relative; }
.track-steps .step.done { color: var(--ok); font-weight: 600; }
.track-steps .step::before { content: ''; display: block; width: 10px; height: 10px; border-radius: 50%; background: var(--border); margin: 0 auto 6px; }
.track-steps .step.done::before { background: var(--ok); }

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #ecefea; --paper: #14191c; --surface: #1c2320; --surface-2: #232b27;
    --border: #37423c; --text: #ecefea; --text-muted: #98a39c;
    --accent: #ff7440; --accent-strong: #ff8a5c; --on-accent: #1b1310;
    --herb: #72b183; --mustard: #e3ac53;
  }
}
:root[data-theme="dark"] {
  --ink: #ecefea; --paper: #14191c; --surface: #1c2320; --surface-2: #232b27;
  --border: #37423c; --text: #ecefea; --text-muted: #98a39c;
  --accent: #ff7440; --accent-strong: #ff8a5c; --on-accent: #1b1310;
  --herb: #72b183; --mustard: #e3ac53;
}


/* ════════════════════════════════════════════════════════════════════
   Multi-tenant additions: wordmark accent, Settings page, palette
   picker, billing/pay screen, platform-admin panel.
   None of these hard-code a brand colour — everything reads the palette
   tokens (--accent, --herb, --mustard, --ink…) that core/Theme.php
   overrides per restaurant, so they re-theme along with the rest.
   ════════════════════════════════════════════════════════════════════ */
.accent-word { color: var(--accent); }
.topbar .brand .platform-tag {
  font-family: var(--font); font-size: .62rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
  border: 1px solid currentColor; border-radius: 4px; padding: 1px 5px; margin-left: 6px; opacity: .7; vertical-align: middle;
}

/* ---- Flash banners (platform panel) ---- */
.flash { max-width: 1100px; margin: 14px auto 0; padding: 11px 16px; border-radius: 8px; font-size: .9rem; border: 1px solid transparent; }
.flash-ok  { background: color-mix(in srgb, var(--ok) 14%, var(--surface)); border-color: color-mix(in srgb, var(--ok) 40%, transparent); color: var(--ink); }
.flash-err { background: color-mix(in srgb, var(--danger) 10%, var(--surface)); border-color: color-mix(in srgb, var(--danger) 40%, transparent); color: var(--danger); }
body > .flash { margin-left: 16px; margin-right: 16px; }
.container > .flash { margin-left: 0; margin-right: 0; }

/* ---- Shared form bits ---- */
.field-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0 14px; }
.section-intro { margin: 0 0 16px; max-width: 62ch; }
.section-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 6px; }
.form-status { font-size: .86rem; color: var(--text-muted); }
.form-status.ok { color: var(--ok); font-weight: 600; }
.form-status.err { color: var(--danger); font-weight: 600; }
.table-toolbar.toolbar-left { justify-content: flex-start; flex-wrap: wrap; align-items: center; }
.toolbar-select { padding: 8px 10px; border: 1px solid var(--border); border-radius: 6px; font-family: var(--font); background: var(--surface); color: var(--text); }
.details-summary { cursor: pointer; padding: 2px 0; }
code { font-family: var(--mono); font-size: .85em; background: var(--surface-2); padding: 1px 5px; border-radius: 4px; }

/* ---- Settings: one page, sticky section nav + scrollspy ---- */
.settings-layout { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 28px; align-items: start; }
.settings-nav { position: sticky; top: 76px; display: flex; flex-direction: column; gap: 2px; }
.settings-nav a {
  display: block; padding: 8px 12px; border-left: 3px solid transparent; border-radius: 0 6px 6px 0;
  color: var(--text-muted); text-decoration: none; font-size: .92rem;
}
.settings-nav a:hover { background: var(--surface-2); color: var(--text); }
.settings-nav a.active { border-left-color: var(--accent); background: var(--surface); color: var(--text); font-weight: 600; }
.settings-body { display: flex; flex-direction: column; gap: 20px; padding-bottom: 20vh; min-width: 0; }
.settings-section { scroll-margin-top: 84px; }
.settings-section h4 { margin: 22px 0 8px; font-size: 1.05rem; }
@media (max-width: 820px) {
  .settings-layout { grid-template-columns: 1fr; gap: 10px; }
  .settings-nav {
    top: 56px; z-index: 15; flex-direction: row; overflow-x: auto; background: var(--paper);
    padding: 8px 20px; margin: 0 -20px; -ms-overflow-style: none; scrollbar-width: none;
    border-bottom: 1px solid var(--border);
  }
  .settings-nav::-webkit-scrollbar { display: none; }
  .settings-nav a { white-space: nowrap; border-left: 0; border-bottom: 3px solid transparent; border-radius: 0; padding: 6px 12px; }
  .settings-nav a.active { border-bottom-color: var(--accent); background: transparent; }
  .settings-section { scroll-margin-top: 100px; }
}

/* ---- Palette picker ---- */
.swatch-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(124px, 1fr)); gap: 12px; margin: 4px 0 18px; }
.swatch {
  display: flex; flex-direction: column; gap: 9px; text-align: left; cursor: pointer;
  border: 2px solid var(--border); border-radius: 12px; background: var(--surface); padding: 10px;
  font-family: var(--font); color: var(--text);
}
.swatch:hover { border-color: var(--text-muted); }
.swatch:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.swatch[aria-checked="true"] { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent); }
.swatch-chip { display: flex; height: 32px; border-radius: 8px; overflow: hidden; box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); }
.swatch-chip i { flex: 1; display: block; }
.swatch-chip i:first-child { flex: 2; }
.swatch-label { font-size: .86rem; font-weight: 600; }

/* ---- Subscription summary (Settings) ---- */
.sub-summary { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 14px; margin-bottom: 16px; }
.sub-summary .label { font-size: .72rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .05em; }
.sub-summary .value { font-size: 1.1rem; font-weight: 600; margin-top: 2px; }

/* ---- Pay screen ---- */
.pay-card { max-width: 480px; }
.back-link { display: inline-block; font-size: .84rem; margin-bottom: 10px; color: var(--text-muted); text-decoration: none; }
.back-link:hover { color: var(--accent-strong); }
.plan-grid { display: grid; gap: 10px; margin-bottom: 16px; }
.plan-option { display: block; cursor: pointer; position: relative; }
.plan-option input { position: absolute; opacity: 0; pointer-events: none; }
.plan-body {
  display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; align-items: baseline;
  border: 2px solid var(--border); border-radius: 10px; padding: 11px 14px; background: var(--paper);
}
.plan-option input:checked + .plan-body { border-color: var(--accent); background: var(--surface); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent); }
.plan-option input:focus-visible + .plan-body { outline: 2px solid var(--accent); outline-offset: 2px; }
.plan-name { font-weight: 600; }
.plan-price { font-weight: 600; text-align: right; grid-row: 1 / span 2; grid-column: 2; }
.plan-days { font-size: .8rem; color: var(--text-muted); }
.plan-desc { grid-column: 1 / -1; font-size: .78rem; color: var(--text-muted); }
.discount-note { background: color-mix(in srgb, var(--ok) 12%, var(--surface)); border: 1px solid color-mix(in srgb, var(--ok) 35%, transparent); border-radius: 8px; padding: 9px 12px; font-size: .88rem; margin: 0 0 14px; }
.plan-was { color: var(--text-muted); font-weight: 400; font-size: .8rem; }
.plan-save { grid-column: 1 / -1; font-size: .78rem; font-weight: 600; color: var(--ok); }
.pay-waiting { text-align: center; padding: 10px 0 4px; }
.spinner { width: 34px; height: 34px; margin: 6px auto 14px; border-radius: 50%; border: 3px solid var(--border); border-top-color: var(--accent); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---- Platform panel ---- */
.stat-link { text-decoration: none; color: inherit; display: block; }
.stat-money .num { font-size: 1.35rem; }
.detail-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; margin-top: 18px; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 0 0 16px; font-size: .9rem; }
.kv dt { color: var(--text-muted); }
.kv dd { margin: 0; overflow-wrap: anywhere; }
.inline-form { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.inline-form label { min-width: 96px; font-size: .84rem; font-weight: 600; }
.inline-form input { width: 90px; padding: 6px 9px; border: 1px solid var(--border); border-radius: 6px; font-family: var(--font); background: var(--paper); color: var(--text); }
.stack-form { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--border); }
.check { display: flex; gap: 8px; align-items: flex-start; font-size: .84rem; margin-bottom: 10px; }
.secret-card { margin-top: 16px; border-left: 4px solid var(--mustard); }
.danger-zone { border-color: color-mix(in srgb, var(--danger) 45%, var(--border)); }
.danger-zone h3 { color: var(--danger); }
.steps-note { font-size: .86rem; padding-left: 20px; margin: 10px 0 16px; }
.row-actions form { margin: 0; }
tr.edit-row td { padding-top: 0; background: var(--paper); }
.plan-form { margin-top: 10px; }
.grid-heading { margin: 0 0 10px; }
.grid-host { min-width: 0; }
.impersonation-bar { position: sticky; top: 0; z-index: 40; display: flex; gap: 12px; justify-content: center; align-items: center; flex-wrap: wrap;
  background: var(--danger); color: #fff; padding: 7px 16px; font-size: .86rem; }
.impersonation-bar a { color: #fff; font-weight: 600; }
body:has(.impersonation-bar) .topbar { top: 34px; }

/* ════════════════════════════════════════════════════════════════════
   DataGrid (public/assets/js/grid.js) — the one table component.
   ════════════════════════════════════════════════════════════════════ */
.grid-toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.grid-toolbar .grid-search { padding: 8px 12px; border: 1px solid var(--border); border-radius: 6px; font-family: var(--font); min-width: 230px; background: var(--surface); color: var(--text); }
.grid-spacer { flex: 1; }
.grid-msg { font-size: .84rem; color: var(--text-muted); }
.grid-msg.ok { color: var(--ok); font-weight: 600; }
.grid-msg.err { color: var(--danger); font-weight: 600; }
.grid-export { position: relative; }
.grid-menu { position: absolute; right: 0; top: calc(100% + 4px); z-index: 30; min-width: 170px; background: var(--surface); border: 1px solid var(--border); border-radius: 8px; box-shadow: 0 10px 28px rgba(0,0,0,.14); padding: 4px; }
.grid-menu button { display: block; width: 100%; text-align: left; padding: 8px 10px; border: 0; background: none; border-radius: 5px; font: inherit; font-size: .88rem; cursor: pointer; color: var(--text); }
.grid-menu button:hover { background: var(--surface-2); }

table.grid-table th { white-space: nowrap; }
table.grid-table th.num, table.grid-table td.num { text-align: right; }
.grid-sort { border: 0; background: none; padding: 0; font: inherit; color: inherit; text-transform: inherit; letter-spacing: inherit; cursor: pointer; }
.grid-sort:hover { color: var(--text); }
.grid-arrow { font-size: .65rem; margin-left: 3px; }
.grid-filter-btn { border: 0; background: none; padding: 2px 3px; margin-left: 4px; cursor: pointer; color: var(--text-muted); opacity: .55; border-radius: 3px; line-height: 1; vertical-align: middle; }
.grid-filter-btn:hover, .grid-filter-btn.on { opacity: 1; color: var(--accent-strong); background: color-mix(in srgb, var(--accent) 14%, transparent); }
table.grid-table[aria-busy="true"] tbody { opacity: .5; transition: opacity .15s; }
.grid-actions { white-space: nowrap; text-align: right; }
.grid-actions-col { width: 1%; }
button.grid-toggle { border: 0; cursor: pointer; font-family: var(--mono); }
tfoot td { font-weight: 700; background: var(--surface-2); font-size: .88rem; }
table.crud-table td .muted { opacity: .6; }

.grid-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 10px; font-size: .84rem; color: var(--text-muted); }
.grid-pager { display: inline-flex; align-items: center; gap: 8px; }
.grid-pager select { padding: 4px 6px; border: 1px solid var(--border); border-radius: 5px; background: var(--surface); color: var(--text); font-family: var(--font); }
.grid-page { min-width: 80px; text-align: center; }

.grid-pop {
  position: fixed; z-index: 60; width: 250px; max-height: 70vh; overflow: auto; background: var(--surface); color: var(--text);
  border: 1px solid var(--border); border-radius: 10px; padding: 12px; box-shadow: 0 16px 40px rgba(0,0,0,.2); font-size: .86rem;
}
.grid-pop-title { font-family: var(--mono); font-size: .7rem; text-transform: uppercase; letter-spacing: .05em; color: var(--text-muted); margin-bottom: 8px; }
.grid-pop-search, .grid-pop-range input { width: 100%; padding: 6px 8px; border: 1px solid var(--border); border-radius: 6px; font-family: var(--font); background: var(--paper); color: var(--text); margin-bottom: 6px; }
.grid-pop-list { max-height: 220px; overflow: auto; border-top: 1px solid var(--border); margin-top: 4px; padding-top: 4px; }
.grid-pop-item { display: flex; gap: 8px; align-items: center; padding: 4px 2px; cursor: pointer; }
.grid-pop-item[hidden] { display: none; }
.grid-pop-all { font-weight: 600; }
.grid-pop-range label { display: block; font-size: .78rem; font-weight: 600; margin-bottom: 4px; }
.grid-pop-actions { display: flex; gap: 8px; margin-top: 10px; }

/* ---- Settings: SMS + Backups sections ---- */
.warn-note { background: color-mix(in srgb, var(--warn) 14%, var(--surface)); border-color: color-mix(in srgb, var(--warn) 45%, transparent); }
.inline-test { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 14px 0; }
.inline-test label { font-size: .84rem; font-weight: 600; }
.inline-test input, .inline-test select { padding: 7px 10px; border: 1px solid var(--border); border-radius: 6px; font-family: var(--font); background: var(--paper); color: var(--text); }
.drive-box { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 12px; border: 1px dashed var(--border); border-radius: 8px; margin: 10px 0 4px; font-size: .88rem; }
.check input { margin-top: 3px; }

/* ---- Item dialog: servings, add-on rows, photo ---- */
.opt-row { font-weight: 400; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 5px 0; cursor: pointer; }
.opt-row input { margin-right: 6px; }
.modal-photo { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 10px; margin-bottom: 12px; }
.price-from { font-size: .72em; font-weight: 500; color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; margin-right: 2px; }
.field .req { color: var(--danger); }
