/* foundations.css — the shared components of the customer website and the customer app.
   Foundations rebuild, sitting B (2026-09-16, Admin PIN, W-6cf45b). ONE definition of the button, the card,
   the chip, the pill, the menu item and the look of a sheet; base.html and app.html both load it right after
   _tokens.html and BEFORE their own <style>, so a shell can still tune density (widths, block margins) but
   never redefines a component. The scale and the colours come from _tokens.html, generated from
   hub-next/design/tokens.json — never type a colour or a step here.

   Corners: --radius-small for chips, inputs and thumbnails · --radius-medium for cards and tiles ·
   --radius-large for sheets · --radius-pill for buttons and pills (visual-guide: one small, one medium;
   the pill stays for buttons because that is the brand's button and was never in question).
   Shadow only on what floats — a sheet, a toast, the cart bar. A card is a 1px rule, never a shadow. */

/* ── form controls inherit neither font nor colour (visual-guide, accessibility) ── */
button, input, textarea, select { font-family: inherit; color: inherit; }

/* ── the button ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 12px 24px;
  border: 0; border-radius: var(--radius-pill);
  white-space: nowrap; max-width: 100%;   /* a label never wraps into a two-line pill (critic, 2026-09-16); the outline variant carries the border */
  background: var(--pink); color: #fff;
  font-family: 'Poppins', sans-serif; font-size: 16px; font-weight: 600; letter-spacing: .4px; line-height: 1.2;
  text-decoration: none; text-align: center; cursor: pointer;
  transition: filter .15s, transform .12s, background .15s, color .15s;
  -webkit-tap-highlight-color: transparent;
}
.btn:hover { color: #fff; filter: brightness(1.08); }
.btn:active { transform: scale(.97); }
.btn-pink { background: var(--pink); color: #fff; }
.btn-navy, .btn-secondary { background: var(--navy); color: #fff; }
.btn-navy:hover, .btn-secondary:hover { filter: brightness(1.14); }
.btn-outline { background: #fff; border: 0; box-shadow: inset 0 0 0 2px var(--pink-text); color: var(--pink-text); }   /* the ring is an inset shadow, not a border: same 48px, same padding, every number on the scale (the census caught 10/22) */   /* a white ground, not transparent: the home banner's "View the Menu" sits on a photo and measured 1.14:1 transparent (sweep, 2026-09-16) */
.btn-outline:hover { background: var(--pink); box-shadow: none; color: #fff; filter: none; }
.btn-sm { min-height: 44px; padding: 8px 16px; font-size: 14px; }
.btn-auto { width: auto; }
.btn[disabled], .btn:disabled, .btn[disabled]:hover {
  background: #E9E2DA; border-color: #E9E2DA; color: #4A5A6B; opacity: 1;
  cursor: not-allowed; filter: none; transform: none; pointer-events: none;
}

/* ── the card ── */
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-medium); padding: 24px; box-shadow: none; }
/* a section INSIDE a card: a rule above it, never a second box (a card in a card is how the account page's button lost its width) */
.card-inset { border-top: 1px solid var(--line); padding-top: 16px; margin-top: 16px; }

/* ── chips (small, flat, never stretched) ── */
.chip, .pop-chip, .off-chip, .nut-chip {
  display: inline-flex; align-items: center; gap: 4px; align-self: flex-start;
  padding: 4px 8px; border-radius: var(--radius-small);
  font-family: 'Poppins', sans-serif; font-size: 12px; font-weight: 700; line-height: 1.4;
  white-space: nowrap; vertical-align: middle;
}
.pop-chip { background: var(--pink); color: #fff; }
.off-chip { background: #F1EDE9; color: var(--muted); }
.nut-chip { background: var(--warn-bg); color: var(--warn-ink); border: 1px solid var(--warn-line); }

/* ── pills: the open/closed status and the busy chip ── */
.status-pill, .busy-chip {
  display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px;
  border-radius: var(--radius-pill); font-size: 14px; font-weight: 600; line-height: 1.2;
}
.status-pill .dot { width: 9px; height: 9px; border-radius: 50%; background: currentColor; flex: 0 0 auto; }
.status-pill.open { background: rgba(48,209,88,.12); color: #2D7A31; }
.status-pill.open .dot { background: #30d158; box-shadow: 0 0 0 0 rgba(48,209,88,.5); animation: pulse 1.8s infinite; }
.status-pill.closed { background: rgba(255,69,58,.10); color: var(--danger); }
.status-pill.closed .dot { background: #ff453a; }
.busy-chip.quiet { background: rgba(48,209,88,.12); color: #2D7A31; }
.busy-chip.steady { background: rgba(168,192,216,.28); color: var(--navy); }
.busy-chip.busy { background: rgba(255,159,10,.16); color: #995C00; }
.busy-chip.very_busy { background: rgba(255,69,58,.12); color: #BC382A; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(48,209,88,.5); } 70% { box-shadow: 0 0 0 8px rgba(48,209,88,0); } 100% { box-shadow: 0 0 0 0 rgba(48,209,88,0); } }
@media (prefers-reduced-motion: reduce) { .status-pill.open .dot { animation: none; } }

/* ── the menu item: the website's .tile and the app's .mitem are the same card ── */
.tile, .mitem {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-medium); box-shadow: none;
}
.tile:hover { border-color: var(--pink); box-shadow: none; }
.tile .nm, .mitem-info h3, .mitem-info h4 { font-family: 'Poppins', sans-serif; font-size: 16px; font-weight: 600; line-height: 1.3; color: var(--navy); }
.tile .ds, .mitem-info p { font-size: 14px; line-height: 1.4; color: var(--muted); }
.tile .pr, .mitem-price { font-size: 16px; font-weight: 600; color: var(--pink); white-space: nowrap; font-variant-numeric: tabular-nums; }
.tile .timg, .tile .timg-ph, .mitem-img { border-radius: var(--radius-small); }

/* ── the sheet's look: the website's .sheet (centred) and the app's .item-sheet / .login-sheet (bottom) ── */
.sheet, .item-sheet, .login-sheet { background: #fff; color: var(--navy); box-shadow: 0 12px 40px rgba(28,53,84,.25); }
.sheet { border-radius: var(--radius-large); max-width: 440px; width: 100%; max-height: 92dvh; overflow: auto; padding: 24px; }
.item-sheet, .login-sheet { border-radius: var(--radius-large) var(--radius-large) 0 0; }
.sheet h3, .item-sheet-title { font-family: 'Bebas Neue', sans-serif; font-size: 26px; letter-spacing: 1px; color: var(--navy); margin: 0 0 4px; }
.sheet .sub, .item-sheet-desc { color: var(--muted); font-size: 14px; margin: 0 0 16px; }
.sheet .x, .sheet-close {
  width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center;
  border: none; background: none; border-radius: 50%; font-size: 26px; font-weight: 400; line-height: 1; color: var(--navy); cursor: pointer; padding: 0;
}
.sheet .x:hover, .sheet-close:hover, .sheet-close:active { background: var(--cream); color: var(--pink); }
.sheet input[type=text], .sheet input[type=tel], .sheet input[type=email], .sheet input[type=number], .sheet textarea {
  width: 100%; padding: 12px; border: 1px solid var(--line); border-radius: var(--radius-small); font-size: 16px; margin: 8px 0; background: #fff;
}
.sheet input:focus, .sheet textarea:focus { border-color: var(--pink); outline: none; }

/* ── sitting C: the pieces that were pasted into two files ─────────────────────────────────── */
/* badge rows under a menu item name */
.nbadges { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; margin-top: 4px; }
.nbadges:empty { display: none; }
.nbadges > * { margin: 0 !important; }
/* the skip link, for keyboards */
.skip-link { position: absolute; left: -9999px; top: 0; z-index: 9999; background: var(--navy); color: #fff; padding: 12px 16px; border-radius: 0 0 var(--radius-small) 0; font-weight: 600; text-decoration: none; }
.skip-link:focus { left: 0; }
/* the loyalty tier badge (account page and the app's loyalty card) */
.loyalty-card .tier-badge { display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase; padding: 8px 16px; border-radius: var(--radius-pill); margin-bottom: 16px; }
.tier-Bronze .tier-badge { background: var(--bronze); color: var(--navy); }
.tier-Silver .tier-badge { background: var(--silver); color: var(--navy); }
.tier-Gold .tier-badge { background: var(--gold); color: var(--navy); }
/* the order card: one order, its status track and its lines (account page and the app's orders) */
.oc { border: 1px solid var(--line); border-radius: var(--radius-medium); padding: 16px; margin-bottom: 12px; background: #fff; }
.oc-top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.oc-title { font-weight: 600; font-size: 16px; color: var(--navy); }
.oc-amt { font-weight: 700; color: var(--pink); white-space: nowrap; }
.oc-amt.dead { color: var(--muted); text-decoration: line-through; }
.oc-sub { font-size: 12px; color: var(--muted); margin-top: 4px; }
.oc-pill { display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: .4px; padding: 4px 12px; border-radius: var(--radius-pill); color: #fff; margin: 12px 0 4px; }
.oc-track { display: flex; margin: 12px 0 8px; }
.oc-step { flex: 1; text-align: center; font-size: 12px; font-weight: 600; color: var(--muted); position: relative; padding-top: 16px; }
.oc-step::before { content: ''; position: absolute; top: 1px; left: calc(50% - 5px); width: 10px; height: 10px; border-radius: 50%; background: #e6ebf1; z-index: 1; }
.oc-step::after { content: ''; position: absolute; top: 5px; left: 50%; width: 100%; height: 2px; background: #e6ebf1; }
.oc-step:last-child::after { display: none; }
.oc-step.on { color: var(--navy); }
.oc-step.on::before { background: var(--pink); }
.oc-step.done::after { background: var(--pink); }
.oc-hint { font-size: 14px; color: var(--muted); margin-top: 4px; }
.oc-badge { display: inline-block; background: var(--danger); color: #fff; font-size: 12px; font-weight: 700; padding: 4px 12px; border-radius: var(--radius-small); margin-top: 8px; }
.oc-click { cursor: pointer; }
.oc-actions { margin-top: 12px; }
.oc-again { padding: 8px 16px; font-size: 14px; }
.oc-tap { color: var(--pink); font-weight: 600; }
.oc-det { margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--line); }
.oc-det-h { font-size: 12px; font-weight: 800; letter-spacing: .4px; text-transform: uppercase; color: var(--muted); margin: 8px 0 4px; }
.oc-det-r { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; color: var(--navy); padding: 4px 0; }
.oc-det-mut { color: var(--muted); font-size: 14px; font-weight: 400; }
.oc-det-sub { padding-left: 16px; font-size: 14px; }
.oc-det-tot { font-weight: 700; border-top: 1px solid var(--line); margin-top: 4px; padding-top: 8px; }

/* ── sitting D: the pop-up's bones, the same on both surfaces ──────────────────────────────── */
.sheet .x { float: right; }   /* top-right on the website too; the app's close already sits right */
.opt-group { margin: 16px 0 0; }
.opt-group .gt, .opt-group-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 8px; }
.opt-group .gt, .opt-group-head h4 { font-size: 16px; font-weight: 600; color: var(--navy); }
.opt-group .gt .req, .opt-group .gt .optional, .opt-req { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .5px; }
.opt-group .gt .req, .opt-req.required { color: var(--pink); }
.opt-group .gt .optional, .opt-req.optional { color: var(--muted); }
.opt, .opt-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; min-height: 44px; border-bottom: 1px solid rgba(168,192,216,.3); cursor: pointer; font-size: 14px; color: var(--navy); }
.opt:last-child, .opt-row:last-child { border-bottom: none; }
.opt:focus-within, .opt-row:focus-visible { outline: 3px solid var(--pink); outline-offset: -3px; border-radius: var(--radius-small); }
/* the website's native inputs draw the app's mark: a 22px ring, a pink disc with a white tick when chosen */
.opt input[type=radio], .opt input[type=checkbox] { appearance: none; -webkit-appearance: none; width: 22px; height: 22px; margin: 0; flex: 0 0 auto; cursor: pointer;
  border: 2px solid var(--blue); border-radius: var(--radius-small); background: #fff; display: inline-grid; place-content: center; }
.opt input[type=radio] { border-radius: 50%; }
.opt input:checked { background: var(--pink); border-color: var(--pink); }
.opt input:checked::after { content: ''; width: 11px; height: 6px; border: solid #fff; border-width: 0 0 2.5px 2.5px; transform: translateY(-1px) rotate(-45deg); }
.opt .op, .opt-price { margin-left: auto; color: var(--muted); font-size: 14px; font-weight: 400; white-space: nowrap; }
.qtyrow, .qty-stepper { display: flex; align-items: center; gap: 12px; }
.qtyrow button, .qty-stepper button { width: 44px; height: 44px; border-radius: 50%; border: 2px solid var(--navy); background: #fff; color: var(--navy); font-size: 19px; font-weight: 700; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; padding: 0; }
.qtyrow button:active, .qty-stepper button:active { background: var(--navy); color: #fff; }
.qtyrow b, .qty-stepper span { font-size: 16px; font-weight: 600; min-width: 16px; text-align: center; }
.sheet-foot, .item-sheet-foot { display: flex; gap: 12px; align-items: center; padding: 12px 24px; border-top: 1px solid var(--line); background: #fff; }
.sheet-foot .btn, .item-sheet-foot .btn { flex: 1 1 auto; width: auto; margin: 0; }
.sheet-foot .qtyrow, .item-sheet-foot .qty-stepper { flex: 0 0 auto; }
.sheet:has(.sheet-foot) { padding-bottom: 0; }   /* a sheet with a foot has no bottom padding: the foot IS the bottom (critic C+D, 2026-09-16) */
.sheet .sheet-foot { position: sticky; bottom: 0; margin: 16px -24px 0; padding-bottom: 24px; }
.sheet .sheet-foot .btn { margin: 0; }

/* ── the allergen line in a pop-up, and the earn line above a menu (2026-09-17) ───────────────── */
.alg { margin: 8px 0 12px; padding: 8px 12px; border-radius: var(--radius-small); font-size: 14px; line-height: 1.45; }
.alg-has { background: #FBEFDC; color: #7A4A00; border: 1px solid #E8C98A; }
.alg-none { background: var(--cream); color: var(--navy); border: 1px solid var(--lightblue); }
.alg-ask { background: var(--cream); color: var(--navy); border: 1px dashed var(--lightblue); }
.earn-line { max-width: 820px; margin: 0 auto 12px; padding: 0 4px; font-size: 14px; line-height: 1.5; color: var(--navy); text-align: center; }
.earn-line a { color: var(--pink-text); font-weight: 600; }
