:root {
  --red: #B60505; --red-dark: #8f0404; --gold: #C0900A; --charcoal: #4A463F; --cream: #F1ECE3;
  --ink: #2c2a26; --line: #dcd4c6; --paper: #fbf8f2; --muted: #6f6a60; --grey: #a8a297; --ok: #2f6b3a;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--cream); color: var(--ink); font: 400 15px/1.5 Poppins, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
h1, h2, h3 { font-family: Lora, Georgia, serif; font-weight: 600; line-height: 1.25; margin: 0; }
h2 { font-size: 22px; } h3 { font-size: 17px; }
a { color: var(--red); }
p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
.wrap { max-width: 560px; margin: 0 auto; padding: 0 14px 110px; }
.loading { text-align: center; padding: 60px 20px; color: var(--muted); }

.top { background: var(--red); color: #fff; }
.top-in { max-width: 560px; margin: 0 auto; padding: 10px 14px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.brand { color: #fff; text-decoration: none; font: 600 21px/1.1 Lora, Georgia, serif; }
.brand small { display: block; font: 400 11px/1.3 Poppins, system-ui, sans-serif; opacity: .9; }
.back { color: #fff; text-decoration: none; padding: 8px 2px; font-weight: 600; }

/* chalkboard special */
.special { display: block; width: 100%; text-align: left; margin: 14px 0 0; padding: 14px 16px; background: #34312b; color: #f4efe4; border: 5px solid #7a6240; border-radius: 6px; }
.special .tag { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: #e4c977; }
.special .name { font: 600 22px/1.25 Lora, Georgia, serif; display: block; }
.special .go { font-size: 13px; opacity: .85; }

.doors { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.door { display: flex; flex-direction: column; justify-content: flex-end; min-height: 118px; padding: 14px; background: var(--paper); border: 1px solid var(--line); border-top: 4px solid var(--red); border-radius: 6px; color: inherit; text-decoration: none; }
.door b { font: 600 19px/1.2 Lora, Georgia, serif; }
.door span { font-size: 13px; color: var(--muted); line-height: 1.35; margin-top: 3px; }
.usual { display: block; width: 100%; margin-top: 12px; padding: 12px; background: #fff7df; border: 1px solid var(--gold); border-radius: 6px; font-weight: 600; text-align: left; }
.usual small { display: block; font-weight: 400; color: var(--muted); }
.foot { margin-top: 24px; font-size: 13px; color: var(--muted); text-align: center; }

.sec { margin-top: 22px; }
.sec > h3 { margin-bottom: 8px; }
.hint { font-size: 12.5px; color: var(--muted); }
.note { margin-top: 12px; padding: 10px 12px; background: var(--paper); border-left: 4px solid var(--gold); font-size: 13.5px; border-radius: 0 4px 4px 0; }
.closed { margin-top: 12px; padding: 12px; background: #e9e4da; color: var(--charcoal); border-radius: 6px; font-weight: 600; font-size: 14px; }
.greyed { opacity: .55; }

.pills { display: flex; flex-wrap: wrap; gap: 7px; }
.pill { min-height: 42px; padding: 7px 13px; border: 1px solid var(--charcoal); background: #fff; border-radius: 22px; font-size: 14px; }
.pill.on { background: var(--charcoal); color: #fff; }
.pill:disabled { border-color: var(--line); color: var(--grey); background: #eee9df; cursor: not-allowed; }
.pill.add { border-color: var(--red); color: var(--red); font-weight: 600; }
.pill.add:disabled { border-color: var(--line); color: var(--grey); font-weight: 400; }
.chips { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.chip { min-height: 58px; font: 600 21px Lora, Georgia, serif; border: 2px solid var(--red); background: #fff; color: var(--red); border-radius: 6px; }
.chip.on { background: var(--red); color: #fff; }
.chip:disabled { border-color: var(--line); color: var(--grey); background: #eee9df; }

.row { display: flex; gap: 11px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.row:last-child { border-bottom: 0; }
.row .body { flex: 1; min-width: 0; }
.row .name { font-weight: 600; }
.row .pills { margin-top: 6px; }
.thumb { flex: none; width: 44px; height: 44px; border-radius: 6px; background: #e6dfd1; color: var(--charcoal); display: grid; place-items: center; font: 600 18px Lora, Georgia, serif; object-fit: cover; }
.badge { display: inline-block; font-size: 11px; padding: 0 7px; border-radius: 9px; background: #efe4c3; color: #6a5007; margin-left: 5px; font-weight: 400; }
.out { font-size: 12px; color: var(--muted); }

.qty { display: inline-flex; align-items: center; gap: 2px; }
.qty button { width: 40px; height: 40px; border: 1px solid var(--charcoal); background: #fff; border-radius: 6px; font-size: 19px; }
.qty b { min-width: 32px; text-align: center; }

.bar { position: fixed; left: 0; right: 0; bottom: 0; padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); background: var(--paper); border-top: 1px solid var(--line); }
.bar a { display: block; max-width: 532px; margin: 0 auto; }
.btn { display: block; width: 100%; min-height: 50px; padding: 12px 16px; background: var(--red); color: #fff; border: 0; border-radius: 6px; font-weight: 600; font-size: 16px; text-align: center; text-decoration: none; }
.btn:disabled { background: var(--grey); }
.btn.ghost { background: #fff; color: var(--charcoal); border: 1px solid var(--charcoal); }
.btn.wa { background: #1f7a4d; }

label.f { display: block; margin-top: 12px; font-size: 14px; font-weight: 600; }
label.f input, label.f select, label.f textarea { display: block; width: 100%; margin-top: 4px; min-height: 46px; padding: 10px; border: 1px solid #b9b1a2; border-radius: 6px; background: #fff; font-weight: 400; font-size: 16px; }
.check { display: flex; gap: 9px; align-items: flex-start; margin-top: 14px; font-size: 14px; }
.check input { width: 22px; height: 22px; margin: 0; flex: none; }

.sum { margin-top: 14px; padding: 12px; background: var(--paper); border: 1px solid var(--line); border-radius: 6px; }
.sum div { display: flex; justify-content: space-between; gap: 12px; padding: 2px 0; }
.sum .tot { font-weight: 600; font-size: 18px; border-top: 1px solid var(--line); margin-top: 6px; padding-top: 7px; }
.code { font: 600 38px Lora, Georgia, serif; letter-spacing: .05em; color: var(--red); text-align: center; margin: 8px 0; }
.err { margin-top: 12px; color: var(--red-dark); font-weight: 600; }

#toast { position: fixed; left: 50%; bottom: 84px; transform: translateX(-50%); max-width: 88vw; background: var(--charcoal); color: #fff; padding: 10px 16px; border-radius: 8px; font-size: 14px; opacity: 0; pointer-events: none; transition: opacity .15s; z-index: 20; }
#toast.show { opacity: 1; }
#toast.big { top: 40%; bottom: auto; padding: 26px 30px; font-size: 22px; font-weight: 600; background: var(--ok); text-align: center; }
#toast.big.bad { background: var(--red); }

/* staff screens */
.tabs { display: flex; overflow-x: auto; gap: 6px; padding: 10px 14px; background: var(--paper); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
.tab { flex: none; min-height: 44px; padding: 8px 14px; border: 1px solid var(--line); background: #fff; border-radius: 6px; font-weight: 600; }
.tab.on { background: var(--charcoal); color: #fff; border-color: var(--charcoal); }
.pinbox { max-width: 320px; margin: 60px auto; padding: 0 16px; text-align: center; }
.pinbox input { text-align: center; font-size: 26px; letter-spacing: .3em; width: 100%; padding: 12px; border: 1px solid #b9b1a2; border-radius: 6px; margin: 14px 0; }
.toggle { min-width: 104px; min-height: 48px; border-radius: 6px; font-weight: 600; border: 0; background: var(--ok); color: #fff; }
.toggle.off { background: var(--red); }
.line { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.priceinput { width: 84px; min-height: 46px; padding: 8px; font-size: 18px; text-align: right; border: 1px solid #b9b1a2; border-radius: 6px; }
table.t { width: 100%; border-collapse: collapse; margin-top: 6px; font-size: 14px; }
table.t th, table.t td { text-align: left; padding: 6px 6px; border-bottom: 1px solid var(--line); }
table.t th { font-weight: 600; background: var(--paper); }
.right { text-align: right; }

/* kitchen */
.kbar { display: flex; align-items: center; gap: 8px; padding: 10px 14px; background: var(--charcoal); color: #fff; flex-wrap: wrap; }
.kbar .title { font: 600 19px Lora, Georgia, serif; margin-right: auto; }
.kbar .tab { background: transparent; color: #fff; border-color: #8a857a; }
.kbar .tab.on { background: var(--cream); color: var(--ink); }
.offline { display: none; padding: 12px; background: var(--red); color: #fff; font-weight: 600; text-align: center; font-size: 18px; }
.offline.show { display: block; }
.cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; padding: 12px 14px; align-items: start; }
.col h3 { margin-bottom: 8px; }
.card { background: #fff; border: 1px solid var(--line); border-left: 5px solid var(--charcoal); border-radius: 6px; padding: 10px 12px; margin-bottom: 10px; font-size: 14px; }
.card.biz { border-left-color: var(--gold); }
.card .head { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.card .ocode { font: 600 20px Lora, Georgia, serif; }
.card ul { margin: 6px 0; padding-left: 18px; }
.card .btn { min-height: 44px; padding: 8px; font-size: 15px; margin-top: 8px; }
.paid { color: var(--ok); font-weight: 600; } .unpaid { color: var(--red-dark); font-weight: 600; }
.pane { padding: 12px 14px; max-width: 900px; }
.searchin { width: 100%; max-width: 340px; min-height: 44px; padding: 8px 10px; border: 1px solid #b9b1a2; border-radius: 6px; margin-bottom: 12px; }
@media (max-width: 700px) { .cols { grid-template-columns: 1fr; } }
[hidden] { display: none !important; }
label.f input.big { font-size: 22px; font-weight: 600; text-align: right; }
label.btn { display: block; }

/* customer site: the logo's red needs a light header */
.top.light { background: #fff; color: var(--ink); border-bottom: 4px solid var(--red); }
.top.light .back { color: var(--red); }
.top.light .logo { display: block; height: 56px; width: auto; }
.top.light.home .top-in { justify-content: center; padding: 14px; }
.top.light.home .logo { height: 136px; }
