/* ═══════════════════════════════════════════════════════════════
   ROYAL DARBAR — OWNER'S LEDGER
   Designed to belong to the same world as the Darbar Menu Books:
   cream paper, green ink, saffron wax, gold foil, Fraunces serif
   numerals, small-caps kickers, ✦ ornaments. Additive only — no
   customer page loads this file. No libraries, no images: the
   paper grain and foil are pure CSS.
   ═══════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,400;0,9..144,500;0,9..144,600;0,9..144,700;1,9..144,400;1,9..144,500&family=Nunito+Sans:wght@400;600;700;800&display=swap');

:root {
  --green: #0E5B3A; --green-deep: #0A3D27; --green-ink: #09301F;
  --green-tint: #EDF4EE;
  --saffron: #F0A02E; --saffron-deep: #C9820F; --gold: #C9A227;
  --paper: #F9F5EA; --page: #FFFDF6; --cream: #F2ECDC;
  --ink: #23291F; --ink-line: rgba(35, 41, 31, .22); --ink-faint: rgba(35, 41, 31, .10);
  --muted: #75796B;
  --display: 'Fraunces', 'Iowan Old Style', Georgia, serif;
  --body: 'Nunito Sans', 'Segoe UI', system-ui, sans-serif;
  --ok: #23693A; --warn: #A03123;
  --shadow: 0 1px 0 rgba(35,41,31,.05), 0 14px 34px -18px rgba(9, 48, 31, .35);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body.od {
  font-family: var(--body); color: var(--ink); line-height: 1.5;
  background:
    radial-gradient(1100px 500px at 85% -5%, rgba(14, 91, 58, .06), transparent 60%),
    radial-gradient(1.2px 1.2px at 25% 35%, rgba(35,41,31,.05) 45%, transparent 55%),
    radial-gradient(1.2px 1.2px at 70% 65%, rgba(35,41,31,.05) 45%, transparent 55%),
    var(--paper);
  background-size: auto, 7px 7px, 11px 11px, auto;
  -webkit-font-smoothing: antialiased;
}
body.od img { max-width: 100%; display: block; }
body.od button { font-family: inherit; cursor: pointer; }

::selection { background: rgba(240, 160, 46, .30); }

/* shared typographic voices */
.kicker {
  font-size: 10px; font-weight: 800; letter-spacing: .22em; text-transform: uppercase;
  color: var(--muted);
}
.orn { color: var(--gold); font-size: 11px; letter-spacing: .35em; user-select: none; }

/* ─────────────────────────── LOGIN — the ledger cover ─────────────────────────── */
.gate {
  position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 22px;
  background:
    radial-gradient(900px 620px at 50% -12%, #116344, transparent 62%),
    repeating-linear-gradient(45deg, rgba(255, 255, 255, .016) 0 2px, transparent 2px 6px),
    linear-gradient(160deg, #0E4A30, var(--green-deep) 55%, var(--green-ink));
}
.gate::before, .gate::after {
  content: "✦"; position: fixed; color: rgba(201, 162, 39, .5); font-size: 15px; letter-spacing: 0;
}
.gate::before { content: "✦   ✦   ✦"; top: 34px; left: 50%; transform: translateX(-50%); }
.gate::after { content: "DUM · FIRE · FEAST · EST. PENDURTHI, VIZAG"; bottom: 30px; left: 0; right: 0;
  text-align: center; font-size: 9.5px; font-weight: 800; letter-spacing: .34em; color: rgba(234, 243, 236, .38); }

.gate-card {
  position: relative; width: min(400px, 100%);
  background:
    linear-gradient(rgba(255, 255, 255, .5), transparent 30%),
    radial-gradient(1px 1px at 20% 30%, rgba(35,41,31,.06) 45%, transparent 55%),
    radial-gradient(1px 1px at 60% 70%, rgba(35,41,31,.06) 45%, transparent 55%),
    var(--page);
  background-size: auto, 6px 6px, 9px 9px, auto;
  border: 1px solid rgba(201, 162, 39, .55);
  outline: 1px solid rgba(201, 162, 39, .30);
  outline-offset: 5px;
  border-radius: 4px; padding: 40px 34px 30px; text-align: center;
  box-shadow: 0 40px 90px rgba(4, 24, 15, .6), 0 2px 0 rgba(255, 255, 255, .6) inset;
}
.gate-crown {
  width: 62px; height: 62px; margin: 0 auto 12px; display: grid; place-items: center;
  font-size: 28px; color: var(--gold);
  border: 1.5px solid rgba(201, 162, 39, .75); border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, rgba(201, 162, 39, .22), transparent 65%);
}
.gate-kicker { font-size: 9.5px; font-weight: 800; letter-spacing: .3em; text-transform: uppercase; color: var(--muted); }
.gate-brand { font-family: var(--display); font-weight: 600; font-size: 34px; color: var(--green); margin-top: 6px; letter-spacing: .01em; }
.gate-sub {
  display: flex; align-items: center; gap: 10px; justify-content: center;
  font-size: 10.5px; font-weight: 800; letter-spacing: .26em; text-transform: uppercase;
  color: var(--saffron-deep); margin: 8px 0 4px;
}
.gate-sub::before, .gate-sub::after { content: ""; width: 34px; height: 1px; background: var(--gold); opacity: .6; }
.gate-rule { display: flex; align-items: center; gap: 8px; justify-content: center; color: var(--gold); margin: 14px 0 18px; }
.gate-rule::before, .gate-rule::after { content: ""; height: 1px; flex: 1; background: var(--ink-faint); }
.gate-label { display: block; text-align: left; font-size: 10px; font-weight: 800; letter-spacing: .2em;
  text-transform: uppercase; color: var(--muted); margin: 4px 0 6px; }
#gatePin {
  width: 100%; font-family: var(--display); font-size: 26px; letter-spacing: .45em; text-indent: .45em;
  text-align: center; padding: 11px 10px 9px; color: var(--green);
  border: 0; border-bottom: 2px solid var(--ink-line); border-radius: 0;
  background: transparent; outline: none; transition: border-color .15s;
}
#gatePin:focus { border-bottom-color: var(--saffron); }
.gate-hint { font-size: 12.5px; color: var(--muted); margin: 12px 0 16px; }
.gate-back { display: inline-block; margin-top: 14px; font-size: 12px; font-weight: 700; letter-spacing: .06em;
  color: var(--muted); text-decoration: none; }
.gate-back:hover { color: var(--green); }
.gate.err #gatePin { border-bottom-color: var(--warn); animation: shake .3s; }
.gate.busy .btn-gold { opacity: .6; pointer-events: none; }
.gate.busy .btn-gold::after { content: " — checking…"; }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }

/* buttons — letterpress */
.btn { border: 1px solid transparent; border-radius: 3px; padding: 12px 20px;
  font-weight: 800; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
.btn-gold {
  color: #241703; background: linear-gradient(180deg, #F5AC41, var(--saffron) 45%, #DD9018);
  box-shadow: 0 1px 0 rgba(255,255,255,.55) inset, 0 8px 20px -8px rgba(201, 130, 15, .8);
}
.btn-gold:hover { filter: brightness(1.04); }
.btn-gold:active { transform: translateY(1px); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--ink-line); }
.btn-ghost:hover { border-color: var(--green); color: var(--green); }
.btn-sm { padding: 7px 13px; font-size: 11px; border-radius: 3px; }
.btn-block { width: 100%; }

/* ─────────────────────────── SHELL — book spine + pages ─────────────────────────── */
.app { display: flex; min-height: 100vh; }

.side {
  width: 250px; flex: none; display: flex; flex-direction: column;
  position: sticky; top: 0; height: 100vh; z-index: 40;
  color: #DCEBE0;
  background:
    repeating-linear-gradient(0deg, rgba(255, 255, 255, .014) 0 1px, transparent 1px 5px),
    linear-gradient(175deg, #0F4C31, var(--green-deep) 55%, var(--green-ink));
  border-right: 1px solid rgba(201, 162, 39, .35);
}
.side-brand { padding: 24px 20px 18px; border-bottom: 3px double rgba(201, 162, 39, .4); }
.side-logo {
  width: 46px; height: 46px; display: grid; place-items: center; font-size: 21px; color: var(--gold);
  border: 1.5px solid rgba(201, 162, 39, .7); border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, rgba(201, 162, 39, .2), transparent 65%);
}
.side-brand b { display: block; font-family: var(--display); font-weight: 600; font-size: 19.5px;
  color: #FDFBF5; line-height: 1.15; margin-top: 12px; letter-spacing: .01em; }
.side-brand small { display: block; margin-top: 3px; color: rgba(220, 235, 224, .62);
  font-size: 9.5px; font-weight: 800; letter-spacing: .28em; text-transform: uppercase; }

.side-nav { padding: 14px 12px; display: flex; flex-direction: column; gap: 1px; flex: 1; overflow-y: auto; }
.side-nav a {
  position: relative; display: flex; align-items: center; gap: 12px;
  padding: 11px 12px 11px 16px; border-radius: 3px; cursor: pointer; user-select: none;
  color: #B9D2C0; font-weight: 700; font-size: 14px; letter-spacing: .015em;
}
.side-nav a::before {
  content: ""; position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 3px; height: 0; background: var(--saffron); transition: height .18s;
}
.side-nav a:hover { color: #FDFBF5; background: rgba(255, 255, 255, .045); }
.side-nav a.on { color: var(--saffron); background: rgba(240, 160, 46, .08); }
.side-nav a.on::before { height: 60%; }
.side-nav a span { flex: 1; }
.badge { background: rgba(240, 160, 46, .92); color: #241703; font-style: normal; font-weight: 800;
  font-size: 10.5px; border-radius: 999px; padding: 2px 7px; }
.badge.gold { background: rgba(253, 251, 245, .92); }

.side-foot { border-top: 3px double rgba(201, 162, 39, .4); padding: 15px 16px 17px; display: grid; gap: 6px; }
.owner-chip { display: flex; gap: 11px; align-items: center; }
.owner-av {
  width: 38px; height: 38px; flex: none; border-radius: 50%; display: grid; place-items: center;
  font-family: var(--display); font-weight: 600; font-size: 17px; color: #241703;
  background: radial-gradient(circle at 35% 30%, #F5AC41, var(--saffron) 60%, #DD9018);
  border: 1px solid rgba(201, 162, 39, .8);
}
.owner-chip b { display: block; font-size: 13.5px; color: #FDFBF5; line-height: 1.2; }
.owner-chip small { color: rgba(220, 235, 224, .6); font-size: 11px; }
.side-out, .side-site { text-align: left; background: none; border: 0; color: #B9D2C0;
  font-size: 12px; font-weight: 700; letter-spacing: .04em; padding: 5px 2px; text-decoration: none; }
.side-out:hover { color: #F0B9AC; }
.side-site:hover { color: #FDFBF5; }

.main { flex: 1; min-width: 0; padding: 26px clamp(18px, 3.4vw, 44px) 70px; }
.main-top { display: flex; align-items: flex-end; gap: 16px; margin-bottom: 8px; }
.burger { display: none; background: transparent; border: 1px solid var(--ink-line); border-radius: 3px;
  font-size: 17px; padding: 8px 12px; color: var(--ink); }
.page-title { font-family: var(--display); font-style: italic; font-weight: 500;
  font-size: clamp(26px, 3.2vw, 34px); color: var(--green); line-height: 1.1; }
.page-date { color: var(--muted); font-size: 12px; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; margin-top: 5px; }
.top-actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.demo-pill {
  font-size: 9px; font-weight: 800; letter-spacing: .22em; text-transform: uppercase;
  color: var(--saffron-deep); border: 1px dashed rgba(201, 130, 15, .55); border-radius: 2px;
  padding: 5px 9px 4px; background: rgba(240, 160, 46, .07);
}
body.live .demo-pill {
  color: var(--ok); border: 1px solid rgba(35, 105, 58, .5); background: rgba(35, 105, 58, .07);
  animation: livepulse 2.4s ease-in-out infinite;
}
@keyframes livepulse { 50% { box-shadow: 0 0 0 4px rgba(35, 105, 58, .08); } }
.bell { position: relative; background: transparent; border: 1px solid var(--ink-line);
  border-radius: 50%; font-size: 16px; width: 42px; height: 42px; }
.bell:hover { border-color: var(--green); }
.bell .dot { position: absolute; top: 9px; right: 10px; width: 7px; height: 7px; border-radius: 50%;
  background: var(--warn); box-shadow: 0 0 0 2px var(--paper); }
.bell .dot.off { display: none; }
.main-orn { display: flex; align-items: center; gap: 12px; margin: 2px 0 22px; color: var(--gold); }
.main-orn::before, .main-orn::after { content: ""; height: 1px; flex: 1; background: var(--ink-faint); }

/* notifications */
.notif {
  position: absolute; right: clamp(18px, 3.4vw, 44px); top: 84px; width: min(370px, calc(100vw - 32px));
  background: var(--page); border: 1px solid var(--ink-line); border-radius: 4px;
  box-shadow: 0 30px 70px -20px rgba(9, 48, 31, .5); padding: 16px; z-index: 60;
}
.notif::before { content: "NOTICES"; display: block; font-size: 9.5px; font-weight: 800;
  letter-spacing: .26em; text-transform: uppercase; color: var(--saffron-deep); margin-bottom: 8px; }
.notif h3 { display: none; }
.notif-item { display: flex; gap: 11px; padding: 10px 4px; border-bottom: 1px solid var(--cream); font-size: 13px; }
.notif-item:last-child { border: 0; }
.notif-item time { color: var(--muted); font-size: 10.5px; display: block; letter-spacing: .06em; text-transform: uppercase; }
.notif-item .ic { font-size: 17px; }

/* ─────────────────────────── PAGES / CARDS — ledger paper ─────────────────────────── */
.page { display: none; animation: fade .28s ease; }
.page.on { display: block; }
@keyframes fade { from { opacity: 0; transform: translateY(7px); } }

.kpi-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; margin-bottom: 20px; }
.kpi {
  position: relative; background: var(--page); border: 1px solid var(--ink-line); border-radius: 3px;
  padding: 17px 16px 14px; display: flex; gap: 13px; align-items: flex-start; box-shadow: var(--shadow);
  overflow: hidden;
}
.kpi::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--saffron), rgba(240, 160, 46, 0)); }
.kpi-ic {
  width: 40px; height: 40px; flex: none; display: grid; place-items: center; font-size: 18px;
  color: var(--green); border: 1px solid var(--ink-faint); border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, rgba(14, 91, 58, .07), transparent 60%);
}
.kpi-ic.gold { color: var(--saffron-deep);
  background: radial-gradient(circle at 35% 30%, rgba(240, 160, 46, .16), transparent 60%); }
.kpi-ic.green { color: var(--ok); }
.kpi b { font-family: var(--display); font-weight: 600; font-variant-numeric: tabular-nums;
  font-size: clamp(21px, 2.2vw, 26px); display: block; line-height: 1.1; color: var(--green-ink); }
.kpi span { color: var(--muted); font-size: 10.5px; font-weight: 800; letter-spacing: .14em;
  text-transform: uppercase; display: block; margin-top: 4px; }
.trend { display: inline-block; font-style: normal; font-size: 10px; font-weight: 800; letter-spacing: .08em;
  margin-top: 7px; color: var(--ok); border: 1px solid rgba(35, 105, 58, .35); border-radius: 999px; padding: 2px 8px; }
.trend.dn { color: var(--warn); border-color: rgba(160, 49, 35, .35); }

.duo { display: grid; grid-template-columns: 1.35fr 1fr; gap: 14px; margin-bottom: 20px; }
.card {
  position: relative; background: var(--page); border: 1px solid var(--ink-line); border-radius: 3px;
  padding: 19px 20px; box-shadow: var(--shadow);
}
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding-bottom: 11px; margin-bottom: 13px; border-bottom: 1px solid var(--ink-faint); }
.card-head h3 { font-family: var(--display); font-style: italic; font-weight: 500;
  font-size: 18px; color: var(--green); }
.card-head h3::after { content: " ✦"; color: var(--gold); font-style: normal; font-size: 11px; vertical-align: 2px; }
.link { background: none; border: 0; color: var(--saffron-deep); font-weight: 800;
  font-size: 12px; letter-spacing: .06em; text-transform: uppercase; }
.link:hover { color: var(--green); }
.range, .seg { display: inline-flex; flex-wrap: wrap; gap: 2px; padding: 0; background: none; border: 0; }
.range button, .seg button {
  border: 0; background: none; border-radius: 2px; padding: 6px 12px;
  font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted);
}
.range button:hover, .seg button:hover { color: var(--green); }
.range button.on, .seg button.on { color: var(--page); background: var(--green); box-shadow: 0 0 0 1px var(--green); }

/* bars */
.bars { display: grid; gap: 11px; }
.bar-row { display: grid; grid-template-columns: minmax(110px, auto) 1fr auto; gap: 10px;
  align-items: center; font-size: 13px; font-weight: 700; }
.bar-row .track { background: var(--cream); height: 8px; border-radius: 0; overflow: hidden;
  border-bottom: 1px solid var(--ink-faint); }
.bar-row .fill { height: 100%; background: repeating-linear-gradient(45deg, var(--saffron) 0 6px, #E8951F 6px 12px); }
.bar-row .val { color: var(--muted); font-variant-numeric: tabular-nums; font-size: 12px; }

.mini-list { display: grid; gap: 2px; }
.mini-row { display: flex; align-items: center; gap: 12px; padding: 10px 4px;
  border-bottom: 1px dashed var(--ink-faint); font-size: 13.5px; }
.mini-row:last-child { border: 0; }
.mini-row b { font-variant-numeric: tabular-nums; font-family: var(--display); font-weight: 600; }
.mini-row .grow { flex: 1; min-width: 0; }
.mini-row .grow i { color: var(--muted); font-style: normal; font-size: 12px; display: block; }

/* status seals */
.pill { font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase;
  border-radius: 999px; padding: 4px 10px 3px; white-space: nowrap; border: 1px solid transparent; }
.pill.New { background: rgba(240, 160, 46, .14); color: #8a5a10; border-color: rgba(201, 130, 15, .45); }
.pill.Confirmed { background: rgba(29, 93, 144, .10); color: #1d5d90; border-color: rgba(29, 93, 144, .4); }
.pill.Preparing { background: rgba(109, 63, 158, .10); color: #6d3f9e; border-color: rgba(109, 63, 158, .4); }
.pill.Ready { background: rgba(35, 105, 58, .10); color: var(--ok); border-color: rgba(35, 105, 58, .4); }
.pill.Completed { background: rgba(35, 105, 58, .08); color: var(--ok); border-color: rgba(35, 105, 58, .3); }
.pill.Cancelled { background: rgba(160, 49, 35, .09); color: var(--warn); border-color: rgba(160, 49, 35, .4); }

/* ─────────────────────────── tables — ruled ledger ─────────────────────────── */
.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 16px; }
.search {
  flex: 1; min-width: 180px; max-width: 340px; font: 700 13.5px var(--body); color: var(--ink);
  background: transparent; border: 0; border-bottom: 2px solid var(--ink-line);
  border-radius: 0; padding: 9px 2px 7px; outline: none; transition: border-color .15s;
}
.search:focus { border-bottom-color: var(--saffron); }
.search::placeholder { color: rgba(117, 121, 107, .75); }
.tbl-wrap { overflow-x: auto; }
.tbl { width: 100%; border-collapse: collapse; min-width: 640px; }
.tbl th {
  text-align: left; font-size: 10px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase;
  color: var(--muted); padding: 8px 10px; border-bottom: 3px double var(--ink-line); white-space: nowrap;
}
.tbl td { padding: 12px 10px; border-bottom: 1px solid var(--ink-faint); font-size: 13.5px; vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tr:hover td { background: rgba(240, 160, 46, .05); }
.tbl td b { font-family: var(--display); font-weight: 600; color: var(--green-ink); }
.tbl .grow { max-width: 260px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.btn-sm.on { background: var(--green); color: var(--page); border-color: var(--green); }
.link-btn { background: none; border: 0; color: var(--green); font-weight: 800; font-size: 12px;
  letter-spacing: .06em; text-transform: uppercase; padding: 6px 8px; }
.link-btn:hover { color: var(--saffron-deep); }
.note { color: var(--muted); font-size: 12.5px; font-style: italic; margin-top: 14px;
  padding-top: 10px; border-top: 1px dashed var(--ink-faint); }
.demo-tag { background: rgba(240, 160, 46, .13); color: #8a5a10; font-size: 9px; font-weight: 800;
  letter-spacing: .14em; text-transform: uppercase; border-radius: 2px; padding: 3px 7px;
  border: 1px dashed rgba(201, 130, 15, .5); vertical-align: middle; white-space: nowrap; }

/* dish rows */
.thumb { width: 46px; height: 46px; border-radius: 3px; object-fit: cover; background: var(--cream);
  border: 1px solid var(--ink-faint); }
.dish-cell { display: flex; align-items: center; gap: 12px; min-width: 0; }
.dish-cell .nm { font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 200px; }
.dish-cell .ct { color: var(--muted); font-size: 11.5px; }
.veg-dot { width: 9px; height: 9px; border-radius: 2px; display: inline-block; margin-right: 6px;
  border: 1.5px solid; background: transparent; }
.veg-dot.v { color: var(--ok); background: rgba(35, 105, 58, .15); border-color: var(--ok); }
.veg-dot.n { color: var(--warn); background: rgba(160, 49, 35, .15); border-color: var(--warn); }
.pop-track { width: 90px; height: 7px; background: var(--cream); border-bottom: 1px solid var(--ink-faint); overflow: hidden; }
.pop-fill { height: 100%; background: repeating-linear-gradient(45deg, var(--saffron) 0 6px, #E8951F 6px 12px); }

/* switches */
.switch { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 13.5px; margin: 9px 0; cursor: pointer; }
.switch input { display: none; }
.switch i { width: 40px; height: 22px; flex: none; background: var(--cream); border: 1px solid var(--ink-line);
  border-radius: 999px; position: relative; transition: .2s; }
.switch i::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px;
  background: var(--page); border: 1px solid var(--ink-line); border-radius: 50%; transition: .2s; }
.switch input:checked + i { background: var(--green); border-color: var(--green); }
.switch input:checked + i::after { left: 20px; border-color: var(--green); }

/* ─────────────────────────── drawer — order slip ─────────────────────────── */
.drawer { position: fixed; inset: 0; background: rgba(9, 30, 19, .55); z-index: 80;
  display: grid; place-items: center; padding: 18px; }
.drawer[hidden] { display: none; }
.drawer-card {
  position: relative; width: min(520px, 100%); max-height: min(86vh, 720px); overflow-y: auto;
  background:
    radial-gradient(1px 1px at 20% 20%, rgba(35,41,31,.05) 45%, transparent 55%),
    radial-gradient(1px 1px at 70% 60%, rgba(35,41,31,.05) 45%, transparent 55%),
    var(--page);
  background-size: 6px 6px, 9px 9px, auto;
  border: 1px solid rgba(201, 162, 39, .5); outline: 1px solid rgba(201, 162, 39, .25); outline-offset: 4px;
  border-radius: 4px; padding: 24px 24px 20px; box-shadow: 0 40px 90px rgba(4, 24, 15, .55);
}
.drawer-card h3 { font-family: var(--display); font-style: italic; font-weight: 500;
  color: var(--green); font-size: 22px; padding-bottom: 10px; border-bottom: 3px double var(--ink-line); }
.drawer-sec { margin-top: 15px; }
.drawer-sec h4 { font-size: 10px; font-weight: 800; letter-spacing: .2em; text-transform: uppercase;
  color: var(--saffron-deep); margin-bottom: 7px; }
.d-item { display: flex; justify-content: space-between; gap: 10px; padding: 8px 0;
  border-bottom: 1px dashed var(--ink-faint); font-size: 14px; }
.d-item:last-child { border: 0; }
.d-item b { font-variant-numeric: tabular-nums; white-space: nowrap; font-family: var(--display); font-weight: 600; }
.status-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.drawer-x { position: absolute; top: 12px; right: 14px; background: none; border: 0;
  font-size: 22px; color: var(--muted); line-height: 1; }
.drawer-x:hover { color: var(--warn); }

/* ─────────────────────────── birthday CRM ─────────────────────────── */
.bday-head { display: flex; align-items: center; justify-content: space-between; gap: 14px;
  flex-wrap: wrap; margin-bottom: 18px; }
.bday-head h3 { font-family: var(--display); font-style: italic; font-weight: 500; color: var(--green); font-size: 19px; }
.bday-head p { color: var(--muted); font-size: 13.5px; max-width: 540px; margin-top: 3px; }
.bday-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(215px, 1fr)); gap: 14px; margin-bottom: 18px; }
.bday-col { background: var(--page); border: 1px solid var(--ink-line); border-radius: 3px;
  padding: 15px; box-shadow: var(--shadow); }
.bday-col h4 { font-size: 11px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase;
  margin-bottom: 12px; padding-bottom: 8px; border-bottom: 1px solid var(--ink-faint); }
.stack { display: grid; gap: 9px; }
.bday-card { border: 1px solid var(--ink-faint); border-left: 3px solid var(--saffron); border-radius: 3px;
  padding: 10px 12px; display: flex; align-items: center; gap: 10px; background: var(--paper); }
.bday-col[data-b="today"] .bday-card { border-left-color: var(--warn); }
.bday-col[data-b="soon"] .bday-card { border-left-color: var(--saffron); }
.bday-col[data-b="week"] .bday-card { border-left-color: var(--gold); }
.bday-col[data-b="later"] .bday-card { border-left-color: var(--ok); }
.bday-card .cake { font-size: 19px; }
.bday-card b { display: block; font-size: 13.5px; line-height: 1.25; }
.bday-card small { color: var(--muted); font-size: 11.5px; }
.bday-card .days { margin-left: auto; font-family: var(--display); font-style: italic; font-weight: 600;
  font-size: 13px; white-space: nowrap; }
.days.d0 { color: var(--warn); } .days.d3 { color: #C25E0A; } .days.d7 { color: #8a5a10; } .days.dl { color: var(--ok); }
.msg-preview .wa-bubble {
  background: #E8F4E4; border: 1px solid rgba(35, 105, 58, .25); border-radius: 1px 12px 12px 12px;
  padding: 14px 16px; font-size: 14px; max-width: 560px;
}

/* AI / analytics */
.conv { text-align: center; padding: 10px 0 4px; }
.conv b { font-family: var(--display); font-style: italic; font-weight: 500; font-size: 44px; color: var(--green); }
.conv-track { height: 10px; background: var(--cream); border-bottom: 1px solid var(--ink-faint);
  overflow: hidden; margin: 12px auto; max-width: 340px; }
.conv-track i { display: block; height: 100%;
  background: repeating-linear-gradient(45deg, var(--saffron) 0 6px, #E8951F 6px 12px); }
.conv span { color: var(--muted); font-size: 12.5px; font-weight: 700; }
.q-item { background: var(--paper); border: 1px solid var(--ink-faint); border-left: 3px solid var(--gold);
  border-radius: 3px; padding: 11px 14px; font-size: 13.5px; font-weight: 700; margin-bottom: 9px;
  font-family: var(--display); font-style: italic; }
.q-item small { display: block; color: var(--muted); font-weight: 600; margin-top: 3px;
  font-family: var(--body); font-style: normal; }

/* reviews */
.rev-sum { display: grid; grid-template-columns: auto 1fr; gap: 26px; align-items: center; }
.rev-big { text-align: center; }
.rev-big b { font-family: var(--display); font-style: italic; font-weight: 500; font-size: 58px;
  color: var(--green); line-height: 1; }
.stars { color: var(--saffron); font-size: 19px; letter-spacing: 3px; }
.stars span { color: rgba(35, 41, 31, .18); }
.rev-big small { color: var(--muted); font-weight: 700; font-size: 10.5px; letter-spacing: .14em;
  text-transform: uppercase; display: block; margin-top: 6px; }
.dist { display: grid; gap: 8px; }
.dist .bar-row { grid-template-columns: 34px 1fr 40px; }
.rev-list { display: grid; gap: 2px; max-height: 420px; overflow-y: auto; }
.rev-item { border-bottom: 1px dashed var(--ink-faint); padding: 12px 2px; }
.rev-item:last-child { border: 0; }
.rev-item .rh { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 13.5px; }
.rev-item .rh .stars { font-size: 12px; letter-spacing: 1px; }
.rev-item .rh time { margin-left: auto; color: var(--muted); font-weight: 700; font-size: 10.5px;
  letter-spacing: .08em; text-transform: uppercase; }
.rev-item p { font-size: 13.5px; color: #3c4437; margin-top: 4px; }

/* settings */
.set-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px; }
.f-label { display: block; font-size: 10px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase;
  color: var(--muted); margin: 13px 0 5px; }
.f-in { width: 100%; font: 700 14px var(--body); color: var(--ink); background: transparent;
  border: 0; border-bottom: 2px solid var(--ink-line); border-radius: 0; padding: 8px 2px 6px;
  outline: none; transition: border-color .15s; }
.f-in:focus { border-bottom-color: var(--saffron); }
select.f-in { border: 1px solid var(--ink-line); border-radius: 3px; padding: 9px 10px; background: var(--page); }
#saveSettings { margin-top: 18px; }
.owner-chip.big { background: var(--paper); border: 1px solid var(--ink-faint); border-radius: 3px;
  padding: 11px; margin-bottom: 12px; }
.owner-chip.big b { color: var(--ink); }
.owner-chip.big small { color: var(--muted); }

/* toast */
.toast {
  position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(20px);
  background: var(--green-ink); color: #FDFBF5; font-weight: 700; font-size: 13.5px;
  letter-spacing: .02em; padding: 13px 24px; border-radius: 3px;
  border: 1px solid rgba(201, 162, 39, .5); opacity: 0; pointer-events: none; transition: .25s;
  z-index: 120; box-shadow: 0 18px 44px rgba(4, 24, 15, .5); max-width: calc(100vw - 40px); text-align: center;
}
.toast.on { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast::before { content: "✦ "; color: var(--gold); }

/* scrim / responsive */
.scrim { position: fixed; inset: 0; background: rgba(9, 30, 19, .5); z-index: 39;
  opacity: 0; pointer-events: none; transition: .2s; }
.scrim.on { opacity: 1; pointer-events: auto; }

@media (max-width: 1024px) {
  .duo { grid-template-columns: 1fr; }
  .side { position: fixed; left: 0; top: 0; bottom: 0; transform: translateX(-100%);
    transition: transform .25s; box-shadow: 24px 0 70px rgba(4, 24, 15, .45); }
  .side.open { transform: none; }
  .burger { display: block; }
  .notif { position: fixed; right: 16px; left: auto; }
}
@media (max-width: 640px) {
  .main { padding: 18px 15px 56px; }
  .main-top { align-items: center; }
  .page-title { font-size: 24px; }
  .kpi-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .kpi { padding: 14px 12px 12px; gap: 10px; }
  .kpi b { font-size: 19px; }
  .kpi-ic { width: 34px; height: 34px; font-size: 15px; }
  .kpi span { font-size: 9px; letter-spacing: .1em; }
  .card { padding: 15px 14px; }
  .tbl { min-width: 560px; }
  .demo-pill { display: none; }
  .rev-sum { grid-template-columns: 1fr; gap: 16px; }
  .bday-cols { grid-template-columns: 1fr 1fr; }
  .status-actions .btn-sm { padding: 9px 12px; }
  .gate-card { padding: 32px 24px 24px; }
}
@media (max-width: 400px) { .bday-cols { grid-template-columns: 1fr; } }
