:root {
  /* SLYDE "Maison": ivory, sand and black. Quiet, square, hairline. */
  --bg: #f3ede3;        /* ivory beige */
  --card: #fbf8f3;      /* paper */
  --ink: #121110;       /* near-black */
  --muted: #73695c;     /* warm taupe */
  --line: #ddd3c3;      /* sand hairline */
  --brand: #121110;     /* black */
  --brand-ink: #f6f1e8;
  --accent: #b79f7c;    /* champagne sand */
  --good: #121110;      /* success is shown in black, not green */
  --warn: #8c2f22;      /* oxblood */
  --upi: #7b6446;       /* bronze */
  --upi-ink: #fbf8f3;
  --radius: 2px;
  /* digits are left out of the serif (see unicode-range) so numbers like T1 or ₹299 stay crisp in the sans */
  --serif: "Bodoni Moda", "Helvetica Neue", Helvetica, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --sans: "Helvetica Neue", Helvetica, system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", Arial, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e0d0c; --card: #171513; --ink: #eee7db; --muted: #a39887; --line: #2d2924;
    --brand: #eee7db; --brand-ink: #121110; --accent: #c4ab84; --good: #eee7db; --warn: #d97a66; --upi: #c4a77a; --upi-ink: #121110;
  }
}
@font-face {
  font-family: "Bodoni Moda"; font-style: normal; font-weight: 400 900; font-display: swap;
  src: url(/fonts/bodoni-moda.woff2) format("woff2-variations"), url(/fonts/bodoni-moda.woff2) format("woff2");
  unicode-range: U+0000-002F, U+003A-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215;
}
a { color: var(--ink); text-underline-offset: 3px; text-decoration-thickness: 1px; }
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font: 16px/1.45 var(--sans); letter-spacing: .005em;
  background: var(--bg); color: var(--ink);
  padding-bottom: calc(72px + env(safe-area-inset-bottom));
}
.topbar {
  position: sticky; top: 0; z-index: 5; display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; background: var(--brand); color: var(--brand-ink);
}
.brand { color: var(--brand-ink); text-decoration: none; font: 500 22px/1 var(--serif); letter-spacing: .32em; }
.who { font-size: 14px; opacity: .9; }
.who button { margin-left: 8px; }
main { max-width: 880px; margin: 0 auto; padding: 16px; }
h1 { font-size: 22px; margin: 4px 0 12px; }
h2 { font-size: 17px; margin: 20px 0 8px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; margin-bottom: 12px; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.row > .grow { flex: 1 1 160px; }
.spread { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.grid { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
label { display: block; font-size: 13px; color: var(--muted); margin: 10px 0 4px; }
input, select, textarea {
  width: 100%; font: inherit; color: var(--ink); background: var(--card);
  border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 12px; min-height: 44px;
}
input:focus, select:focus, textarea:focus, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
button, .btn {
  font: inherit; font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  border: 1px solid var(--ink); background: transparent; color: var(--ink);
  border-radius: var(--radius); padding: 10px 16px; min-height: 44px; cursor: pointer; text-decoration: none; display: inline-flex;
  align-items: center; justify-content: center; gap: 6px;
}
button.primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
button.cash { background: var(--ink); border-color: var(--ink); color: var(--bg); }
button.upi { background: var(--upi); border-color: var(--upi); color: var(--upi-ink); }
button.danger { color: var(--warn); border-color: var(--warn); }
button.block { width: 100%; }
button:disabled { opacity: .5; cursor: not-allowed; }
button.link { border: 0; background: none; padding: 4px; min-height: 0; color: inherit; text-decoration: underline; text-underline-offset: 3px; font-weight: 500; letter-spacing: .02em; text-transform: none; font-size: 14px; }
.tile { text-align: left; display: block; padding: 14px; min-height: 84px; border-color: var(--line); background: var(--card); text-transform: none; letter-spacing: normal; font-size: 14px; font-weight: 500; }
.tile.busy { border-color: var(--ink); box-shadow: inset 3px 0 0 var(--ink); }
.tile b { display: block; font: 600 18px/1.2 var(--sans); letter-spacing: .02em; margin-bottom: 4px; }
.pill { display: inline-block; font-size: 10.5px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; padding: 2px 8px; border-radius: var(--radius); border: 1px solid var(--line); vertical-align: middle; }
.pill.paid { color: var(--bg); background: var(--ink); border-color: var(--ink); }
.pill.open { color: var(--upi); border-color: var(--accent); }
.pill.void { color: var(--warn); border-color: var(--warn); }
.pill.cash { color: var(--ink); }
.pill.upi { color: var(--upi); }
.veg, .nonveg { display: inline-block; width: 10px; height: 10px; border: 1.5px solid; border-radius: 2px; margin-right: 6px; position: relative; }
.veg { color: #2a7d4f; } .nonveg { color: #a33; }
.veg::after, .nonveg::after { content: ""; position: absolute; inset: 1.5px; border-radius: 50%; background: currentColor; }
.items { list-style: none; padding: 0; margin: 0; }
.items li { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.items li:last-child { border-bottom: 0; }
.qty { display: inline-flex; align-items: center; gap: 4px; }
.qty button { min-width: 40px; padding: 6px; border-color: var(--line); font-size: 16px; letter-spacing: 0; }
.qty span { min-width: 24px; text-align: center; font-weight: 600; font-variant-numeric: tabular-nums; }
.totals { width: 100%; border-collapse: collapse; }
.totals td { padding: 4px 0; }
.totals td:last-child { text-align: right; font-variant-numeric: tabular-nums; }
.totals tr.grand td { font: 300 24px/1.2 var(--sans); letter-spacing: .01em; padding-top: 10px; border-top: 1px solid var(--ink); }
.totals tr.grand td:first-child { font: 500 22px/1.2 var(--serif); }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.stat .v { font: 300 26px/1.15 var(--sans); font-variant-numeric: tabular-nums; }
.stat .k { font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.bar { height: 6px; border-radius: 0; overflow: hidden; display: flex; background: var(--line); margin-top: 8px; }
.bar i { display: block; height: 100%; }
table.list { width: 100%; border-collapse: collapse; font-size: 15px; }
table.list th, table.list td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--line); }
table.list th { font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
table.list td.num, table.list th.num { text-align: right; font-variant-numeric: tabular-nums; }
.qrbox { text-align: center; }
.qrbox svg { width: min(280px, 80vw); height: auto; background: #fff; padding: 8px; border-radius: var(--radius); }
.chips { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 6px; }
.chips button { white-space: nowrap; min-height: 36px; padding: 6px 14px; border-color: var(--line); font-size: 11.5px; }
.chips button.on { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.tabs {
  position: fixed; bottom: 0; left: 0; right: 0; display: flex; background: var(--card); border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom); z-index: 5;
}
.tabs a { flex: 1; text-align: center; padding: 14px 4px; color: var(--muted); text-decoration: none; font-size: 11px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; }
.tabs a.on { color: var(--ink); }
.toast {
  position: fixed; left: 50%; bottom: 88px; transform: translateX(-50%); background: var(--ink); color: var(--bg);
  padding: 12px 18px; border-radius: var(--radius); z-index: 10; max-width: calc(100vw - 32px); font-size: 14px; letter-spacing: .02em;
}
.toast.err { background: var(--warn); color: #fbf8f3; }
.pinpad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; max-width: 300px; margin: 12px auto; }
.pinpad button { font: 300 26px/1 var(--sans); min-height: 62px; border-color: var(--line); letter-spacing: 0; }
.pindots { text-align: center; font-size: 28px; letter-spacing: 10px; min-height: 40px; }
.sticky-foot { position: sticky; bottom: 72px; background: var(--bg); padding: 10px 0; }
.print-only { display: none; }

@media print {
  body { background: #fff; color: #000; padding: 0; }
  .topbar, .tabs, main, .toast { display: none !important; }
  .print-only { display: block; width: 72mm; margin: 0 auto; font: 12px/1.35 ui-monospace, Menlo, Consolas, monospace; }
  .print-only h3 { text-align: center; margin: 0; font-size: 15px; }
  .print-only .c { text-align: center; }
  .print-only table { width: 100%; border-collapse: collapse; }
  .print-only td { padding: 1px 0; vertical-align: top; }
  .print-only td.r { text-align: right; }
  .print-only hr { border: 0; border-top: 1px dashed #000; }
}

/* dish suggestions */
.suggest { position: relative; }
.suggest-list {
  position: absolute; z-index: 20; left: 0; right: 0; top: calc(100% + 4px); margin: 0; padding: 4px 0; list-style: none;
  background: var(--card); border: 1px solid var(--ink); border-radius: var(--radius); box-shadow: 0 12px 28px -18px rgba(18,17,16,.35);
  max-height: 320px; overflow-y: auto;
}
.suggest-list li { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 12px; cursor: pointer; min-height: 44px; }
.suggest-list li.on, .suggest-list li:hover { background: var(--bg); }
.suggest-list li.custom { border-top: 1px solid var(--line); color: var(--brand); font-weight: 600; }
#addItem .suggest { flex: 1 1 100%; }

/* test-mode warning and pairing code */
.testbanner { background: color-mix(in srgb, var(--accent) 16%, var(--card)); color: var(--ink); border: 1px solid var(--accent); border-radius: var(--radius); padding: 10px 12px; margin: 10px 0; font-size: 14px; }
.paircode { text-align: center; font: 300 44px/1.1 var(--sans); letter-spacing: 10px; margin: 16px 0 4px; font-variant-numeric: tabular-nums; }

/* =====================================================================
   MOTION — SLYDE's "sliding" feel. Only transform/opacity are animated
   (smooth on cheap phones). Everything stops for "reduce motion".
   ===================================================================== */
:root {
  --ease-out: cubic-bezier(.22, 1, .36, 1);     /* fast start, soft landing */
  --ease-spring: cubic-bezier(.34, 1.56, .64, 1); /* slight overshoot */
}

/* --- top bar: a gold sliver slides across once on load --- */
.topbar { overflow: hidden; }
.topbar::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 1px; width: 40%;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  animation: sliver 1.6s var(--ease-out) .2s both;
}
@keyframes sliver { from { transform: translateX(-100%); } to { transform: translateX(260%); opacity: 0; } }

/* --- screen entrance: slide in, then the parts cascade --- */
main.enter.from-right { animation: inRight .42s var(--ease-out) both; }
main.enter.from-left  { animation: inLeft  .42s var(--ease-out) both; }
main.enter.from-up    { animation: inUp    .45s var(--ease-out) both; }
main.enter [style*="--i"]:not(.bar) { animation: rise .5s var(--ease-out) both; animation-delay: calc(var(--i) * 40ms + 60ms); }
@keyframes inRight { from { transform: translateX(28px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes inLeft  { from { transform: translateX(-28px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes inUp    { from { transform: translateY(14px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes rise    { from { transform: translateY(16px) scale(.98); opacity: 0; } to { transform: none; opacity: 1; } }

/* --- bottom tabs: the underline glides to the chosen tab --- */
.tabs { position: fixed; }
.tab-links { display: flex; width: 100%; }
.tab-ink {
  position: absolute; top: 0; left: 0; height: 2px; border-radius: 0; background: var(--ink);
  transition: transform .38s var(--ease-out), width .3s var(--ease-out), opacity .2s;
}
.tabs a { transition: color .25s; }

/* --- touch feedback --- */
button, .btn, .tile { transition: transform .12s var(--ease-out), box-shadow .2s, background-color .2s, border-color .2s; }
button:active:not(:disabled), .btn:active { transform: scale(.96); }
.tile:active { transform: scale(.97); }
@media (hover: hover) {
  .tile:hover { border-color: var(--ink); }
}
.tile.busy { position: relative; overflow: hidden; }
.tile.busy::after { /* a slow shine sliding over running tables */
  content: ""; position: absolute; inset: 0; transform: translateX(-100%);
  background: linear-gradient(100deg, transparent 30%, color-mix(in srgb, var(--accent) 18%, transparent) 50%, transparent 70%);
  animation: shine 3.2s ease-in-out infinite;
}
@keyframes shine { 0%, 55% { transform: translateX(-100%); } 100% { transform: translateX(100%); } }

/* --- quantity pop, collect button nudge, total roll --- */
.qty span.bump { animation: bump .35s var(--ease-spring); color: var(--upi); }
@keyframes bump { 0% { transform: scale(1); } 40% { transform: scale(1.55); } 100% { transform: scale(1); } }
.nudge { animation: nudge .45s var(--ease-spring); }
@keyframes nudge { 0% { transform: scale(1); } 35% { transform: scale(1.04); } 100% { transform: scale(1); } }
.totals tr.grand td:last-child { font-variant-numeric: tabular-nums; }

/* --- category chips slide --- */
.chips button { transition: background-color .25s, color .25s, transform .12s; }

/* --- toast springs up --- */
.toast.pop { animation: toastIn .42s var(--ease-spring); }
@keyframes toastIn { from { transform: translate(-50%, 24px) scale(.96); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }

/* --- suggestions drop down --- */
.suggest-list:not([hidden]) { animation: drop .22s var(--ease-out); transform-origin: top; }
@keyframes drop { from { transform: translateY(-6px) scaleY(.96); opacity: 0; } to { transform: none; opacity: 1; } }

/* --- PIN: dots pop, wrong PIN shakes --- */
.pindots .dot { display: inline-block; }
.pindots .dot.new { animation: bump .3s var(--ease-spring); }
.shake { animation: shake .42s cubic-bezier(.36,.07,.19,.97); }
@keyframes shake { 10%, 90% { transform: translateX(-2px); } 20%, 80% { transform: translateX(4px); } 30%, 50%, 70% { transform: translateX(-8px); } 40%, 60% { transform: translateX(8px); } }

/* --- QR: appears with a pop, pulsing ring + scan line while waiting --- */
.qrframe { position: relative; display: inline-block; border-radius: var(--radius); animation: qrIn .45s var(--ease-spring); }
.qrframe svg { display: block; }
@keyframes qrIn { from { transform: scale(.85); opacity: 0; } to { transform: none; opacity: 1; } }
.qrframe.waiting::before {
  content: ""; position: absolute; inset: -6px; border-radius: var(--radius); border: 1px solid var(--upi);
  animation: ring 1.8s ease-out infinite;
}
@keyframes ring { 0% { transform: scale(.97); opacity: .7; } 100% { transform: scale(1.08); opacity: 0; } }
.qrframe .scan { display: none; }
.qrframe.waiting .scan {
  display: block; position: absolute; left: 8px; right: 8px; top: 8px; height: 3px; border-radius: 3px;
  background: linear-gradient(90deg, transparent, var(--upi), transparent); box-shadow: 0 0 12px var(--upi);
  animation: scan 2.2s ease-in-out infinite alternate;
}
@keyframes scan { from { transform: translateY(0); } to { transform: translateY(calc(min(280px, 80vw) - 4px)); } }

/* --- report: cash/UPI bar wipes in --- */
.bar { animation: wipe .9s var(--ease-out) .2s both; }
@keyframes wipe { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }

/* --- loading shimmer --- */
.skeleton { display: grid; gap: 12px; }
.skeleton i {
  display: block; height: 72px; border-radius: var(--radius);
  background: linear-gradient(90deg, var(--card) 25%, var(--line) 50%, var(--card) 75%); background-size: 200% 100%;
  animation: shimmer 1.1s linear infinite;
}
.skeleton i:first-child { height: 34px; width: 50%; }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

/* --- welcome hero: logo draws itself, letters slide in, lanes glide --- */
.hero { position: relative; isolation: isolate; text-align: center; padding: 28px 0 10px; overflow: hidden; }
.hero-logo { width: 88px; height: 88px; animation: logoIn .7s var(--ease-spring) both; }
.hero-logo rect { fill: var(--brand); }
.hero-logo path {
  fill: none; stroke: var(--accent); stroke-width: 6; stroke-linecap: round;
  stroke-dasharray: 90; stroke-dashoffset: 90; animation: draw 1s var(--ease-out) .35s forwards;
}
@keyframes logoIn { from { transform: translateY(18px) rotate(-8deg) scale(.8); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes draw { to { stroke-dashoffset: 0; } }
.hero-word { font-size: 40px; letter-spacing: .22em; margin: 10px 0 2px; padding-left: .22em; overflow: hidden; }
.hero-word span { display: inline-block; animation: letter .6s var(--ease-out) both; animation-delay: calc(.5s + var(--l) * 70ms); }
@keyframes letter { from { transform: translateX(-40px); opacity: 0; } to { transform: none; opacity: 1; } }
.hero-tag { color: var(--muted); margin: 0; font-weight: 600; animation: inUp .6s var(--ease-out) 1s both; }
.hero-lanes { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.hero-lanes i {
  position: absolute; left: 0; height: 2px; width: 45%; border-radius: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent); opacity: .5;
  animation: lane 4.5s linear infinite;
}
.hero-lanes i:nth-child(1) { top: 22%; animation-delay: 0s; }
.hero-lanes i:nth-child(2) { top: 50%; animation-delay: 1.5s; animation-duration: 5.5s; }
.hero-lanes i:nth-child(3) { top: 78%; animation-delay: 3s; animation-duration: 4s; }
@keyframes lane { from { transform: translateX(-110%); } to { transform: translateX(260%); } }

/* --- payment success sheet --- */
.celebrate {
  position: fixed; inset: 0; z-index: 50; display: grid; place-items: center;
  background: rgba(18, 17, 16, .5); backdrop-filter: blur(3px); animation: fadeIn .25s ease both;
}
.celebrate.leave { animation: fadeOut .4s ease both; }
.celebrate.leave .celebrate-card { animation: sheetOut .4s var(--ease-out) both; }
.celebrate-card {
  position: relative; background: var(--card); color: var(--ink); border-radius: var(--radius); padding: 30px 40px; text-align: center; border: 1px solid var(--ink);
  min-width: 240px; box-shadow: 0 20px 60px rgba(0,0,0,.25); animation: sheetIn .5s var(--ease-spring) both;
}
.tick { width: 92px; height: 92px; }
.tick circle { fill: none; stroke: var(--good); stroke-width: 1.5; stroke-dasharray: 151; stroke-dashoffset: 151; animation: draw .6s var(--ease-out) .1s forwards; }
.tick path { fill: none; stroke: var(--good); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 40; stroke-dashoffset: 40; animation: draw .35s var(--ease-out) .6s forwards; }
.celebrate.upi .tick circle, .celebrate.upi .tick path { stroke: var(--upi); }
.celebrate-amt { font: 300 34px/1.15 var(--sans); margin-top: 6px; animation: inUp .4s var(--ease-out) .55s both; }
.celebrate-sub { color: var(--muted); font-weight: 600; animation: inUp .4s var(--ease-out) .65s both; }
.burst { position: absolute; left: 50%; top: 74px; width: 0; height: 0; }
.burst i {
  position: absolute; width: 8px; height: 8px; border-radius: 2px; background: var(--accent);
  transform: rotate(var(--a)) translateY(0); opacity: 0; animation: burst .8s var(--ease-out) .55s both;
}
.burst i:nth-child(3n) { background: var(--ink); }
.burst i:nth-child(3n+1) { background: var(--upi); }
@keyframes burst { 0% { opacity: 1; transform: rotate(var(--a)) translateY(0) scale(1); } 100% { opacity: 0; transform: rotate(var(--a)) translateY(calc(var(--d) * -1)) scale(.5); } }
@keyframes sheetIn { from { transform: translateY(60px) scale(.9); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes sheetOut { to { transform: translateX(120%) rotate(6deg); opacity: 0; } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes fadeOut { to { opacity: 0; } }

/* --- respect "reduce motion" --- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .hero-logo path, .tick circle, .tick path { stroke-dashoffset: 0 !important; }
}
@media print { .celebrate { display: none !important; } }

/* public demo banner */
.demobar { background: var(--accent); color: #121110; letter-spacing: .04em; text-align: center; font-size: 13px; padding: 6px 16px; }

/* long or non-English item names wrap instead of widening the page */
.items li > span:first-child, .totals td:first-child, table.list td { overflow-wrap: anywhere; word-break: break-word; }
.items li > span:last-child { flex-shrink: 0; }
details.card summary { cursor: pointer; min-height: 32px; }
details.card[open] summary { margin-bottom: 6px; }

/* iPhone notch / home bar when opened from the home screen */
.topbar { padding-top: max(12px, env(safe-area-inset-top)); }

/* =====================================================================
   SLYDE look "Maison": black and ivory panels, serif display, hairlines.
   ===================================================================== */
:root {
  --night: #121110;            /* black panels */
  --night-2: #1d1b18;
  --chart-cash: #1d1b18;       /* cash = black */
  --chart-upi: #a68a60;        /* UPI = bronze sand */
  --chart-grid: rgba(18, 17, 16, .08);
  --chart-ink: #73695c;
}
@media (prefers-color-scheme: dark) {
  :root { --night: #050505; --night-2: #12110f; --chart-cash: #eee7db; --chart-upi: #b89a6c; --chart-grid: rgba(238, 231, 219, .08); --chart-ink: #a39887; }
}

/* type: serif for titles and money, small spaced capitals for labels */
h1 { font: 500 30px/1.15 var(--serif); letter-spacing: .005em; }
h2 { font-size: 11.5px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); margin-top: 28px; }
.card { border-radius: var(--radius); box-shadow: none; }
.topbar { background: var(--night); color: #f6f1e8; border-bottom: 1px solid #2a2622; }
.topbar .brand, .topbar .who, .topbar .who a, .topbar .who button { color: #f6f1e8; }
.who { font-size: 12px; letter-spacing: .08em; }

/* hero panel (Today) */
.hero-card {
  position: relative; overflow: hidden; isolation: isolate; color: #f6f1e8;
  background: var(--night); border: 1px solid var(--night);
  border-radius: var(--radius); padding: 20px 20px 18px; margin-bottom: 14px;
}
.hero-card .glow {
  position: absolute; z-index: -1; width: 280px; height: 280px; right: -90px; top: -110px; border-radius: 50%;
  background: radial-gradient(circle, rgba(183, 159, 124, .22), rgba(183, 159, 124, 0) 65%);
  animation: drift 12s ease-in-out infinite alternate;
}
.hero-card::after { /* one fine sand line under the header */
  content: ""; position: absolute; z-index: -1; left: 20px; right: 20px; top: 58px; height: 1px; background: rgba(246, 241, 232, .14);
}
@keyframes drift { from { transform: translate(0, 0); } to { transform: translate(-50px, 30px); } }
.hero-top { align-items: center; }
.eyebrow { font-size: 11px; letter-spacing: .24em; text-transform: uppercase; color: rgba(246, 241, 232, .62); font-weight: 600; }
.hero-card input[type=date] {
  width: auto; min-height: 36px; padding: 4px 10px; background: transparent; color: #f6f1e8;
  border: 1px solid rgba(246, 241, 232, .3); border-radius: var(--radius); color-scheme: dark;
}
.hero-card .big { font: 200 clamp(42px, 12vw, 62px)/1.05 var(--sans); letter-spacing: -0.01em; margin: 18px 0 4px; font-variant-numeric: lining-nums tabular-nums; }
.hero-sub { color: rgba(246, 241, 232, .66); font-size: 13px; letter-spacing: .04em; }
.closed-pill { display: inline-block; padding: 1px 8px; border-radius: var(--radius); border: 1px solid var(--accent); color: var(--accent); font-weight: 600; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; }
.split { display: flex; gap: 22px; flex-wrap: wrap; margin-top: 16px; font-size: 11.5px; letter-spacing: .14em; text-transform: uppercase; color: rgba(246, 241, 232, .66); }
.split b { color: #f6f1e8; font: 400 18px/1 var(--sans); letter-spacing: 0; text-transform: none; margin-left: 6px; font-variant-numeric: lining-nums tabular-nums; }
.sw { display: inline-block; width: 9px; height: 9px; border-radius: 0; margin-right: 6px; vertical-align: 0; }
.sw.cash { background: var(--chart-cash); }
.sw.upi { background: var(--chart-upi); }
.hero-card .sw.cash { background: #f6f1e8; }
.hero-card .sw.upi { background: #b79f7c; }
.hero-bar { margin-top: 14px; background: rgba(246, 241, 232, .12); height: 3px; gap: 2px; }
.hero-bar i.cash { background: #f6f1e8; border-radius: 0; }
.hero-bar i.upi { background: #b79f7c; border-radius: 0; }

/* tables: actions under the title */
.head-actions { margin: -4px 0 14px; }
.head-actions > * { flex: 1 1 0; }

/* owner quick billing */
.quick { display: flex; gap: 10px; margin: 4px 0 6px; }
.quick > * { flex: 1; }
.btn.upi-btn { background: var(--upi); border-color: var(--upi); color: var(--upi-ink); }

/* hourly chart */
.chart-legend { display: flex; gap: 16px; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.chart-wrap { position: relative; }
.hchart { width: 100%; height: auto; display: block; overflow: visible; }
.hchart .grid { stroke: var(--chart-grid); stroke-width: 1; }
.hchart .axis { stroke: var(--line); stroke-width: 1; }
.hchart .tick { fill: var(--chart-ink); font-size: 12px; }
.hchart .seg.cash { fill: var(--chart-cash); }
.hchart .seg.upi { fill: var(--chart-upi); }
.hchart .hit { fill: transparent; cursor: pointer; }
.hchart .hbar .seg { transform-box: fill-box; transform-origin: bottom; animation: grow .7s var(--ease-out) both; animation-delay: calc(var(--b) * 30ms + 150ms); }
.hchart .hbar.on .seg, .hchart .hbar:hover .seg { filter: brightness(1.12); }
.hchart .hbar.on .hit { fill: var(--chart-grid); }
@keyframes grow { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.chart-tip {
  position: absolute; top: -6px; transform: translateY(-100%); min-width: 140px; pointer-events: none; z-index: 3;
  background: var(--card); border: 1px solid var(--ink); border-radius: var(--radius); padding: 8px 10px; font-size: 13px;
  box-shadow: 0 10px 28px -16px rgba(18,17,16,.35);
}
.chart-tip .tip-total { margin-top: 4px; font-weight: 600; }
details summary { cursor: pointer; color: var(--muted); margin-top: 8px; }

/* close the day */
.closed-box { background: color-mix(in srgb, var(--accent) 12%, transparent); border: 1px solid var(--accent); border-radius: var(--radius); padding: 10px 12px; margin-bottom: 10px; }
.good-text { color: var(--good); font-weight: 700; }
.warn-text { color: var(--warn); font-weight: 700; }

/* welcome: black panel, the wordmark in serif capitals */
.hero {
  color: #f6f1e8; border-radius: var(--radius); padding: 44px 16px 30px; margin-bottom: 18px; background: var(--night);
}
.hero::before {
  content: ""; position: absolute; inset: 14px; z-index: -1; border: 1px solid rgba(183, 159, 124, .35); pointer-events: none;
}
.hero-logo rect { fill: transparent; stroke: rgba(183, 159, 124, .6); stroke-width: 1; }
.hero-logo path { stroke: #f6f1e8; stroke-width: 4; }
.hero-word { color: #f6f1e8; font: 400 50px/1.1 var(--serif); letter-spacing: .34em; padding-left: .34em; }
.hero-tag { color: var(--accent); letter-spacing: .28em; text-transform: uppercase; font-size: 11px; font-weight: 600; }
.hero-lanes i { opacity: .35; height: 1px; } /* the moving trails in the logo banner: soft and quiet */
.hero + p.muted { margin-bottom: 14px; }

/* network banner */
.netbar { text-align: center; font-size: 12px; letter-spacing: .06em; padding: 8px 16px; background: var(--card); border-bottom: 1px solid var(--line); }
.netbar.off { background: var(--accent); color: #121110; border-color: transparent; }
.netbar.ok { background: var(--card); color: var(--ink); border-bottom-color: var(--ink); }

/* bill: kitchen + discount */
.sent-tag { font-size: 11px; color: var(--upi); font-weight: 600; letter-spacing: .06em; }
.kot-btn { margin-top: 10px; background: transparent; color: var(--ink); border-color: var(--ink); }
.totals tr.disc td { color: var(--upi); }
.disc-panel { margin-top: 10px; padding: 12px; border: 1px solid var(--line); border-radius: var(--radius); }

/* kitchen screen */
.kot-cols { display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 760px) { .kot-cols { grid-template-columns: 1fr 1fr; } }
.kot { background: var(--card); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: var(--radius); padding: 12px 14px; margin-bottom: 12px; }
.kot.ready { border-left-color: var(--ink); }
.kot.served { opacity: .6; border-left-color: var(--line); }
.kot.late { border-left-color: var(--warn); box-shadow: 0 0 0 1px var(--warn); }
.kot.late .age { color: var(--warn); font-weight: 700; }
.kot-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.kot-head b { font-size: 17px; font-weight: 700; letter-spacing: .08em; }
.kot-table { font-size: 15px; font-weight: 700; letter-spacing: .16em; }
.kot-meta { font-size: 13px; color: var(--muted); margin: 2px 0 6px; }
.kot-note { font-size: 13px; font-weight: 700; color: var(--warn); margin-bottom: 4px; }
.kot-items { list-style: none; padding: 0; margin: 6px 0 10px; font-size: 19px; line-height: 1.5; overflow-wrap: anywhere; }
.kot-items .cancel { color: var(--warn); font-weight: 700; text-decoration: line-through; text-decoration-thickness: 2px; }

/* printed KOT */
@media print {
  .print-only .big-line { font-size: 18px; font-weight: 800; margin: 4px 0; }
  .print-only td.kq { width: 1%; white-space: nowrap; font-weight: 800; padding-right: 6px; }
  .print-only td.kn { font-size: 14px; }
}

/* =====================================================================
   Business types: sign-up cards, the Sell checkout and its cart bar
   ===================================================================== */
.biz-grid { display: grid; gap: 10px; grid-template-columns: 1fr 1fr; }
@media (max-width: 360px) { .biz-grid { grid-template-columns: 1fr; } }
.biz-card {
  position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; text-align: left;
  padding: 16px 14px 14px; min-height: 148px; background: var(--card); border: 1px solid var(--line);
  text-transform: none; letter-spacing: normal; font-size: 14px; font-weight: 400;
}
.biz-card b { font: 500 19px/1.15 var(--serif); }
.biz-card span { color: var(--muted); font-size: 12.5px; line-height: 1.35; }
.biz-card.on { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.biz-card.on::after { content: "✓"; position: absolute; top: 10px; right: 12px; font-size: 14px; color: var(--ink); }
.biz-icon { width: 34px; height: 34px; color: var(--ink); margin-bottom: 4px; }
.biz-card:not(.on) .biz-icon { color: var(--muted); }
.biz-default { position: absolute; top: 12px; right: 30px; font-style: normal; font-size: 9.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--upi); }
.biz-card.on .biz-default { right: 30px; }
.biz-chosen { display: flex; gap: 12px; align-items: center; margin: 0 0 12px; }
.biz-chosen .biz-icon { width: 40px; height: 40px; flex: none; }

.sell-grid { display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); margin-top: 6px; }
.sell-tile {
  position: relative; display: flex; flex-direction: column; justify-content: space-between; align-items: flex-start; gap: 8px;
  min-height: 92px; padding: 12px; text-align: left; background: var(--card); border: 1px solid var(--line);
  text-transform: none; letter-spacing: normal; font-size: 14px; font-weight: 500; line-height: 1.25;
}
.sell-tile span { color: var(--muted); font-size: 13px; font-weight: 400; font-variant-numeric: tabular-nums; }
.sell-tile.on { border-color: var(--ink); }
.sell-q {
  position: absolute; top: -1px; right: -1px; min-width: 26px; height: 26px; padding: 0 6px; display: grid; place-items: center;
  background: var(--ink); color: var(--bg); font-style: normal; font-size: 13px; font-weight: 600; animation: bump .3s var(--ease-spring);
}
.empty { text-align: center; padding: 28px 16px; }

.cart { position: sticky; bottom: calc(64px + env(safe-area-inset-bottom)); z-index: 4; margin-top: 16px; }
.cart.has { padding-bottom: 4px; }
.cart-sheet { background: var(--card); border: 1px solid var(--ink); border-bottom: 0; padding: 12px 14px; max-height: 46vh; overflow-y: auto; animation: inUp .25s var(--ease-out); }
.cart-sheet .row { margin-top: 10px; }
.cart-bar { display: flex; gap: 0; background: var(--ink); color: var(--bg); box-shadow: 0 14px 30px -18px rgba(18, 17, 16, .7); }
.cart-sum {
  flex: 1; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 1px;
  background: transparent; border: 0; color: var(--bg); padding: 10px 16px; text-transform: none; letter-spacing: .02em; font-size: 14px;
}
.cart-sum small { font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; opacity: .65; }
.cart-pay { flex: 1.3; background: var(--bg) !important; color: var(--ink) !important; border: 1px solid var(--ink) !important; margin: 6px; }
/* keep messages clear of the Sell cart bar */
body:has(.cart.has) .toast { bottom: calc(150px + env(safe-area-inset-bottom)); }

/* saved reports: folders and insights */
.crumb { margin: -6px 0 12px; display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.folders li { padding: 0; }
.fold {
  display: flex; align-items: center; gap: 12px; width: 100%; padding: 14px 2px; border: 0; background: none; color: var(--ink);
  text-align: left; text-decoration: none; text-transform: none; letter-spacing: normal; font-size: 15px; font-weight: 500; min-height: 56px;
}
.fold > span:nth-child(2) { flex: 1; }
.fold-ic { width: 26px; height: 26px; flex: none; color: var(--upi); }
.insights { list-style: none; margin: 0; padding: 0; }
.insights li { padding: 8px 0 8px 26px; position: relative; border-bottom: 1px solid var(--line); }
.insights li:last-child { border-bottom: 0; }
.insights li::before { position: absolute; left: 2px; top: 8px; font-weight: 700; }
.insights.good li::before { content: "✓"; color: var(--ink); }
.insights.bad li::before { content: "!"; color: var(--warn); left: 6px; }
.insights.order li::before { content: "＋"; color: var(--upi); }
label.check { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); font-size: 14px; margin: 6px 14px 0 0; }
label.check input { width: auto; min-height: 0; }

/* ---- Rupee-S identity: wordmark in the top bar, the welcome screen and printed bills ---- */
.brand { display: inline-flex; align-items: center; line-height: 0; letter-spacing: 0; }
.brand .wordmark { height: 20px; width: auto; color: #f6f1e8; }
.hero-word { margin: 6px 0 18px; padding: 0; line-height: 0; letter-spacing: 0; }
.hero-word .wordmark { height: 58px; width: auto; color: #f6f1e8; overflow: visible; }
/* the rupee lines draw in first, then the letters rise */
.hero-word .wordmark > rect { transform-box: fill-box; transform-origin: left; animation: wipe-in .7s var(--ease-out) .15s both; }
.hero-word .wordmark > path { animation: inUp .6s var(--ease-out) .45s both; }
.hero-word .wordmark > g { animation: inUp .6s var(--ease-out) .6s both; }
@keyframes wipe-in { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.hero::before { inset: 14px; }
.print-brand .wordmark { height: 9px; width: auto; vertical-align: -1px; margin-left: 3px; color: #000; }
@media print { .print-only .print-brand .wordmark { height: 9px; } }

/* Security (Stage 4): password check dialog, sign-up bot trap, activity log */
.reauth { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 16px; background: rgba(20, 18, 15, .45); }
.reauth form { width: min(420px, 100%); margin: 0; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
#secLog li.sec-warn > span:first-child { color: var(--warn); }

/* Phone ordering page (order.html) */
.order-page main { padding-bottom: 96px; }
.order-shop { font: 500 18px/1.2 var(--serif); color: inherit; text-decoration: none; }
.order-hero h1 { font-size: 30px; margin-bottom: 4px; }
.order-test { color: var(--upi); }
.order-closed { color: var(--warn); font-weight: 600; }
.order-bar { position: fixed; left: 0; right: 0; bottom: 0; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); background: var(--bg); border-top: 1px solid var(--line); z-index: 20; }
.order-bar button { max-width: 848px; margin: 0 auto; display: block; }
.order-pay { display: grid; gap: 12px; }
.order-pay a.primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); text-align: center; text-decoration: none; }
.order-pay .qr { width: min(240px, 70vw); margin: 0 auto; }
.order-pay .qr svg { width: 100%; height: auto; display: block; }
.order-status { text-align: center; }
.order-no { font: 500 34px/1.15 var(--serif); margin: 6px 0 2px; }
.order-name { font-size: 18px; margin: 0 0 14px; }
.order-steps { list-style: none; padding: 0; margin: 0 auto; max-width: 320px; text-align: left; }
.order-steps li { padding: 8px 0 8px 28px; position: relative; color: var(--muted); }
.order-steps li::before { content: ""; position: absolute; left: 4px; top: 12px; width: 12px; height: 12px; border: 1.5px solid var(--line); border-radius: 50%; }
.order-steps li.on { color: var(--ink); font-weight: 600; }
.order-steps li.on::before { background: var(--ink); border-color: var(--ink); }
.order-ready { font-weight: 600; margin-top: 12px; }
.order-foot { text-align: center; padding: 8px 16px 110px; }

/* Countries (sign-up, login, Setup) */
.country-pick { display: grid; gap: 6px; }
.country-pick .country-search { min-height: 38px; }
.phone-row { display: flex; align-items: stretch; gap: 0; }
.phone-row .dial { display: inline-flex; align-items: center; padding: 0 10px; border: 1px solid var(--line); border-right: 0; background: var(--card); color: var(--muted); font-variant-numeric: tabular-nums; }
.phone-row input { flex: 1; min-width: 0; }
/* BETA tag next to the SLYDE wordmark */
.beta { display: inline-block; margin-left: 8px; padding: 1px 6px 0; border: 1px solid currentColor; border-radius: 3px; font: 600 9.5px/1.5 var(--sans); letter-spacing: .16em; vertical-align: top; opacity: .85; }

/* ---------- Tablets and laptops ---------- */
/* iPad portrait and small laptops: wider workspace, bigger tiles */
@media (min-width: 760px) {
  main { max-width: 1040px; padding: 20px 24px; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 12px; }
  .tile { min-height: 96px; }
  .sell-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
  .sell-tile { min-height: 104px; font-size: 15px; }
}
/* Landscape tablets and laptops: a left sidebar instead of bottom tabs, the cart beside the items */
@media (min-width: 1024px) {
  .tabs.side {
    top: 0; bottom: 0; right: auto; width: 208px; flex-direction: column; border-top: 0; border-right: 1px solid var(--line);
    padding: calc(76px + env(safe-area-inset-top)) 0 16px; z-index: 4; overflow-y: auto;
  }
  .tabs.side .tab-links { flex-direction: column; }
  .tabs.side a { flex: none; text-align: left; padding: 15px 24px; font-size: 11.5px; border-left: 2px solid transparent; }
  .tabs.side a.on { border-left-color: var(--ink); background: var(--bg); }
  .tabs.side .tab-ink { display: block; top: 0; left: 0; background: var(--accent); transition: transform .38s var(--ease-out), height .3s var(--ease-out), opacity .2s; }
  .tabs.side a.on { border-left-color: transparent; }
  body.has-side main, body.has-side .netbar, body.has-side .demobar { margin-left: 208px; }
  body.has-side main { max-width: 1280px; padding: 24px 32px 48px; }
  body.has-side .toast { left: calc(50% + 104px); bottom: 28px; }
  body.has-side .cart { bottom: 16px; }
  /* Sell: items on the left, the order on the right */
  body.has-side main:has(> #cart) { display: grid; grid-template-columns: minmax(0, 1fr) 380px; column-gap: 28px; align-items: start; }
  body.has-side main:has(> #cart) > * { grid-column: 1; }
  body.has-side main:has(> #cart) > #cart { grid-column: 2; grid-row: 1 / span 30; position: sticky; top: 88px; margin-top: 0; }
  body.has-side main:has(> #cart) > #cart .cart-sheet { max-height: calc(100vh - 220px); border-bottom: 1px solid var(--ink); }
  body.has-side:has(.cart.has) .toast { bottom: 28px; }
  .kot-cols { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
}
@media (min-width: 1440px) { body.has-side main { max-width: 1440px; } }

/* Sell tiles: − count + on the tile's corner */
.sell-cell { position: relative; }
.sell-cell .sell-tile { width: 100%; }
.tile-step { position: absolute; top: -1px; right: -1px; display: flex; align-items: stretch; background: var(--ink); color: var(--bg); z-index: 1; }
.tile-step button { min-width: 34px; min-height: 32px; padding: 0 8px; border: 0; background: transparent; color: var(--bg); font-size: 18px; letter-spacing: 0; }
.tile-step .sell-q { position: static; animation: none; min-width: 22px; }
/* Kitchen: steps, ticked items, change tickets */
.kot .kot-st { margin-right: 4px; }
.kot.accepted, .kot.preparing { border-color: var(--accent); }
.kot.change { border-style: dashed; border-color: var(--warn); }
.kot-items li.done { opacity: .5; text-decoration: line-through; }
.kot-items .tick { min-height: 0; padding: 0 8px 0 0; font-size: 18px; text-decoration: none; }
@media (min-width: 760px) { .kot-cols.kds { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
/* Overview (expo) */
.expo { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.expo-card.all-ready { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
/* Table QR sheet */
.qr-sheet { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); margin-top: 14px; }
.qr-card { background: var(--card); border: 1px solid var(--line); padding: 16px; text-align: center; }
.qr-card .qr { width: 170px; margin: 8px auto; background: #fff; padding: 6px; }
.qr-card .qr svg { width: 100%; height: auto; display: block; }
.qr-shop { font: 500 15px/1.2 var(--serif); }
.qr-table { font: 600 22px/1.2 var(--sans); letter-spacing: .04em; margin-top: 4px; }
.qr-hint { font-size: 12px; color: var(--muted); }
.qr-card .row { justify-content: center; }
@media print {
  .qr-print { display: grid; grid-template-columns: 1fr 1fr; gap: 10mm; }
  .qr-print .qr-card { border: 1px solid #000; break-inside: avoid; padding: 8mm; color: #000; background: #fff; }
  .qr-print .qr { width: 55mm; }
  .qr-print .no-print { display: none !important; }
}
/* Customers asking (Tables) */
.requests li b { color: var(--warn); }
.order-table { font-size: 16px; margin: 2px 0 8px; }
.order-table b { font: 600 20px/1.2 var(--sans); letter-spacing: .04em; }
.kot-items li { display: flex; align-items: baseline; justify-content: flex-start; gap: 6px; text-align: left; }
.kot-items .tick { flex: none; }
.sell-cell .sell-tile.on { padding-top: 42px; }
.kot-items button.tick { width: auto; min-width: 0; min-height: 0; height: auto; padding: 0 2px; margin: 0; border: 0; background: none; line-height: 1.2; flex: 0 0 auto; }

/* ---------- POS order screen (laptops and landscape tablets) ---------- */
body.has-side main:has(> .pos) { max-width: none; padding: 16px 20px 16px 24px; }
.pos { display: grid; grid-template-columns: minmax(320px, 400px) minmax(0, 1fr); gap: 22px; align-items: start; }
.pos-check {
  position: sticky; top: 72px; max-height: calc(100vh - 92px); display: flex; flex-direction: column;
  background: var(--card); border: 1px solid var(--line); padding: 16px; overflow: hidden;
}
.pos-check h1 { margin: 0; }
.pos-lines { flex: 1 1 auto; overflow-y: auto; min-height: 80px; margin: 6px -4px 10px; padding: 0 4px; }
.pos-lines li { gap: 10px; }
.pos-lines li > span:first-child { flex: 1; min-width: 0; }
.pos-amt { min-width: 78px; text-align: right; font-variant-numeric: tabular-nums; font-weight: 600; }
.pos-sum { border-top: 1px solid var(--ink); padding-top: 10px; }
.pos-bar { display: flex; gap: 10px; align-items: center; margin-bottom: 12px; }
.pos-bar #search { flex: 1; min-height: 50px; font-size: 16px; }
.pos-bell { position: relative; min-width: 50px; min-height: 50px; padding: 0; font-size: 20px; letter-spacing: 0; }
.pos-bell i { position: absolute; top: -6px; right: -6px; min-width: 22px; height: 22px; padding: 0 6px; display: grid; place-items: center; border-radius: 11px; background: var(--warn); color: #fbf8f3; font: 700 12px/1 var(--sans); font-style: normal; }
.pos-crumb { min-height: 28px; margin-bottom: 6px; font-size: 14px; }
.pos-grid { display: grid; gap: 10px; }
.pos-grid.cats { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
.pos-grid.dishes { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
.pos-cat {
  min-height: 112px; display: flex; flex-direction: column; justify-content: space-between; align-items: flex-start; padding: 14px 16px;
  background: var(--tile); border: 0; color: #f8f3ea; text-align: left; text-transform: none; letter-spacing: .01em; font-size: 17px; font-weight: 600; line-height: 1.2;
  box-shadow: inset 0 -3px 0 rgba(0, 0, 0, .18);
}
.pos-cat span { font-size: 12px; font-weight: 500; opacity: .75; letter-spacing: .08em; }
.pos-cat:active, .pos-dish:active { transform: scale(.98); }
.pos-cell { position: relative; }
.pos-dish {
  width: 100%; min-height: 112px; display: flex; flex-direction: column; justify-content: space-between; align-items: flex-start; gap: 8px; padding: 12px 14px;
  background: var(--card); border: 1px solid var(--line); border-top: 6px solid var(--tile); color: var(--ink);
  text-align: left; text-transform: none; letter-spacing: normal; font-size: 15px; font-weight: 500; line-height: 1.25;
}
.pos-dish span { color: var(--muted); font-size: 14px; font-variant-numeric: tabular-nums; }
.pos-dish.on { border-color: var(--ink); border-top-color: var(--tile); padding-top: 40px; }
.pos-dish .veg, .pos-dish .nonveg { position: absolute; bottom: 12px; right: 12px; margin: 0; }
@media (min-width: 1024px) and (max-height: 700px) { .pos-cat, .pos-dish { min-height: 92px; } }
.pos-bell i[hidden] { display: none; }

/* Scan paper menu: review table */
.scan-card { border-style: dashed; }
.scan-table { overflow-x: auto; margin-top: 8px; }
.scan-table table { width: 100%; border-collapse: collapse; font-size: 14px; }
.scan-table th { text-align: left; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); padding: 6px 4px; }
.scan-table td { padding: 4px; border-top: 1px solid var(--line); vertical-align: top; }
.scan-table input:not([type=checkbox]), .scan-table select { min-height: 36px; padding: 4px 8px; font-size: 14px; }
.scan-table input[type=checkbox] { width: 20px; height: 20px; min-height: 0; }
.scan-table tr.unsure td { background: rgba(140, 47, 34, .06); }

/* Tables at a glance: free = light red, occupied (a bill is running) = light green */
.tile[data-table] { background: #f7dedb; border-color: #d9a39b; box-shadow: none; }
.tile[data-table] .small { color: #7d3a30; }
.tile[data-table].busy { background: #d8eed9; border-color: #7fb589; box-shadow: inset 4px 0 0 #3f8a4f; }
.tile[data-table].busy .small { color: #2f6a3b; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .tile[data-table] { background: #3a2321; border-color: #6b3a33; }
  :root:not([data-theme="light"]) .tile[data-table] .small { color: #f0b7ae; }
  :root:not([data-theme="light"]) .tile[data-table].busy { background: #1f3524; border-color: #3f7a4b; box-shadow: inset 4px 0 0 #6cc27e; }
  :root:not([data-theme="light"]) .tile[data-table].busy .small { color: #a8e0b3; }
}

/* Folded Setup sections: one row each, tap to open */
.fold-bar { margin: -4px 0 6px; text-align: right; }
details.fold-sec { border-top: 1px solid var(--line); }
details.fold-sec:last-of-type { border-bottom: 1px solid var(--line); }
details.fold-sec > summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 50px; padding: 10px 2px; font-size: 13px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--ink);
}
details.fold-sec > summary::-webkit-details-marker { display: none; }
details.fold-sec > summary::after { content: "+"; font: 300 24px/1 var(--sans); letter-spacing: 0; color: var(--muted); transition: transform .25s var(--ease-out); }
details.fold-sec[open] > summary::after { transform: rotate(45deg); }
details.fold-sec[open] > summary { color: var(--ink); }
details.fold-sec[open] { padding-bottom: 12px; }
details.fold-sec > :not(summary) { animation: drop .25s var(--ease-out) both; }

/* Seated tables (tapped once: customers sitting, nothing ordered yet) */
.tile-cell { position: relative; }
.tile-cell .tile { width: 100%; height: 100%; }
.tile-x { position: absolute; top: 6px; right: 6px; min-height: 30px; padding: 2px 8px; font-size: 10.5px; letter-spacing: .1em; background: rgba(255, 255, 255, .7); border-color: #7fb589; color: #2f6a3b; }
.tile[data-table].seated { box-shadow: inset 4px 0 0 #3f8a4f; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .tile-x { background: rgba(0, 0, 0, .35); color: #a8e0b3; } }
.phone-row .dial-pick { flex: 0 0 auto; width: auto; min-width: 108px; border-right: 0; padding-right: 28px; }
#pform fieldset { border: 1px solid var(--line, #ddd); border-radius: 10px; padding: 8px 12px 10px; margin: 10px 0; }
#pform fieldset legend { font-weight: 600; padding: 0 4px; }
#pform fieldset label.check { display: flex; }

/* ---------- home: customers first ("Slide to order"), restaurants below ---------- */
.slide-order { text-align: center; margin: 6px 0 22px; }
.slide-lead { margin: 0 auto 14px; max-width: 30em; color: var(--muted); }
.slide-track { --slid: 0; position: relative; height: 72px; border-radius: 999px; overflow: hidden; touch-action: pan-y; user-select: none; margin: 0 auto 12px; max-width: 440px;
  background: linear-gradient(100deg, #121110 0%, #2a2219 55%, #4a3a26 100%); color: #f6f1e8;
  box-shadow: 0 10px 28px -10px rgba(74, 58, 38, .65), inset 0 0 0 1px rgba(196, 171, 132, .45); }
/* filled part behind the knob as it slides */
.slide-track::before { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(196,171,132,.55), rgba(196,171,132,.15)); transform-origin: left; transform: scaleX(var(--slid)); }
/* a light sweep that keeps running across the rail */
.slide-track::after { content: ''; position: absolute; top: 0; bottom: 0; width: 40%; left: -40%; background: linear-gradient(100deg, transparent, rgba(255,240,215,.22), transparent); animation: railSweep 2.8s ease-in-out infinite; pointer-events: none; }
.slide-label { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: 8px; padding-left: 48px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; font-size: 15px; opacity: calc(1 - var(--slid)); pointer-events: none; text-shadow: 0 1px 8px rgba(0,0,0,.45); }
.chev { display: inline-flex; font-size: 22px; line-height: 1; color: #c4ab84; }
.chev i { font-style: normal; animation: chev 1.4s ease-in-out infinite; }
.chev i:nth-child(2) { animation-delay: .18s; }
.chev i:nth-child(3) { animation-delay: .36s; }
.slide-knob { position: absolute; top: 6px; left: 6px; width: 60px; height: 60px; min-height: 0; padding: 0; border-radius: 50%; border: 0; z-index: 1;
  background: radial-gradient(circle at 35% 30%, #fffaf0, #e8dcc6); color: #121110; font-size: 26px; cursor: grab; touch-action: none;
  box-shadow: 0 4px 14px rgba(0,0,0,.45), 0 0 0 0 rgba(196,171,132,.7); animation: knobPulse 2.2s ease-out infinite; }
.slide-track:not(.dragging) .slide-knob { transition: transform .3s cubic-bezier(.2,.9,.3,1.2); }
.slide-track.dragging .slide-knob { cursor: grabbing; animation: none; }
.slide-track.done .slide-label { opacity: 0; }
@keyframes railSweep { 0% { left: -40%; } 60%, 100% { left: 110%; } }
@keyframes chev { 0%, 100% { opacity: .25; transform: translateX(0); } 50% { opacity: 1; transform: translateX(4px); } }
@keyframes knobPulse { 0% { box-shadow: 0 4px 14px rgba(0,0,0,.45), 0 0 0 0 rgba(196,171,132,.7); } 70%, 100% { box-shadow: 0 4px 14px rgba(0,0,0,.45), 0 0 0 14px rgba(196,171,132,0); } }
@media (prefers-reduced-motion: reduce) { .slide-track::after, .chev i, .slide-knob { animation: none; } }
.biz-block { border-top: 1px solid var(--line); padding-top: 14px; display: grid; gap: 8px; }
.biz-head { margin: 0; font-size: 11px; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); text-align: center; }
.center { text-align: center; }

/* ---------- find restaurants (find.html) and the owner's map pin ---------- */
.find-title { font-size: 28px; margin: 6px 0 12px; }
.find-search { display: flex; gap: 8px; }
.find-search input { flex: 1; min-width: 0; }
.find-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 10px 0; }
.find-map { height: 42vh; min-height: 240px; border: 1px solid var(--line); border-radius: var(--radius); margin: 6px 0 10px; z-index: 0; }
.small-map { height: 260px; min-height: 0; }
.find-note { margin: 0 0 12px; }
.find-card h2 { font-size: 18px; margin: 0; }
.find-cuisine { margin: 4px 0 2px; }
.map-pin { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); background: var(--ink); color: var(--bg); font: 700 12px var(--sans); border: 2px solid var(--bg); box-shadow: 0 1px 4px rgba(0,0,0,.35); }
.map-pin.closed { background: var(--muted); }
.map-pin.you { background: #1f6feb; border-radius: 50%; width: 18px; height: 18px; transform: none; }
.map-pin i { font-style: normal; transform: rotate(45deg); }
.leaflet-container { font: inherit; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.slide-free { margin: 0 0 6px; font-weight: 600; font-size: 14px; }
.find-sub { font-size: 20px; margin: 18px 0 8px; }
.map-credit { margin: -6px 0 8px; font-size: 10px; color: var(--muted); text-align: right; }
.map-credit a { color: inherit; }
/* header on small phones: the version badge stays on one line; the name and Log out wrap instead */
.beta { white-space: nowrap; }
.topbar .brand { flex: none; }
.topbar .who { min-width: 0; text-align: right; }
