/* AL-AAED V1 · one stylesheet. Warm, readable at arm's length, large touch targets. The BT frame is drawn by bt-identity.js. */
:root { --bg: #fbf6ee; --card: #fff; --ink: #2a1d12; --mut: #7a6552; --line: #eadfce; --acc: #b5451b; --acc2: #d9772b; --ok: #1f7a4d; --warn: #b7791f; --bad: #b42318;
  --r: 14px; --sh: 0 2px 10px rgba(60, 35, 15, .08); font-family: system-ui, -apple-system, 'Segoe UI', Tahoma, Arial, sans-serif; }
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); }
body { min-height: 100vh; -webkit-tap-highlight-color: transparent; }
button { font: inherit; cursor: pointer; }
.btn { border: 1px solid var(--line); background: #fff; color: var(--ink); border-radius: 12px; padding: 10px 14px; font-weight: 700; min-height: 44px; }
.btn.pri { background: var(--acc); border-color: var(--acc); color: #fff; }
.btn.ok { background: var(--ok); border-color: var(--ok); color: #fff; }
.btn.bad { background: #fff; border-color: var(--bad); color: var(--bad); }
.btn.ghost { background: transparent; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
input, select, textarea { font: inherit; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; background: #fff; color: var(--ink); min-height: 44px; }
.mut { color: var(--mut); } .small { font-size: 13px; }
/* header — the physical left keeps room for the BT eagle */
.top { position: sticky; top: 0; z-index: 50; background: linear-gradient(180deg, #3b2314, #52301a); color: #fff; padding: 12px 14px 12px 90px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
@media (max-width: 700px) { .top { padding-left: 76px; } }
.top h1 { font-size: 20px; margin: 0; font-weight: 800; letter-spacing: .2px; }
.top .tb { background: var(--acc2); color: #fff; border-radius: 999px; padding: 4px 12px; font-weight: 800; font-size: 15px; }
.top .sp { flex: 1; }
.langs { display: flex; gap: 4px; }
.langs button { background: rgba(255,255,255,.12); color: #fff; border: 0; border-radius: 8px; padding: 6px 9px; min-height: 36px; font-weight: 700; }
.langs button.on { background: #fff; color: #3b2314; }
.icon-btn { background: rgba(255,255,255,.14); color: #fff; border: 0; border-radius: 10px; min-height: 40px; padding: 6px 12px; font-weight: 700; }
.banner { margin: 10px 12px; padding: 12px 14px; border-radius: 12px; background: #fff4e5; border: 1px solid #f3c98b; color: #7a4a0c; font-weight: 700; }
.banner.bad { background: #fdecea; border-color: #f5b5ac; color: var(--bad); }
/* categories */
.cats { display: flex; gap: 8px; overflow-x: auto; padding: 10px 12px; position: sticky; top: 64px; z-index: 40; background: var(--bg); scrollbar-width: none; }
.cats::-webkit-scrollbar { display: none; }
.cats button { flex: none; border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 8px 14px; font-weight: 700; min-height: 40px; }
.cats button.on { background: var(--ink); color: #fff; border-color: var(--ink); }
/* dishes */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; padding: 4px 12px 120px; }
.dish { background: var(--card); border-radius: var(--r); box-shadow: var(--sh); overflow: hidden; display: flex; flex-direction: column; border: 0; padding: 0; text-align: start; color: inherit; }
.dish .ph { aspect-ratio: 4/3; background: #f1e6d6 center/cover no-repeat; display: flex; align-items: center; justify-content: center; font-size: 42px; }
.dish .bd { padding: 9px 10px 11px; }
.dish .nm { font-weight: 800; font-size: 15px; line-height: 1.25; }
.dish .pr { color: var(--acc); font-weight: 800; margin-top: 4px; }
.dish.out { opacity: .5; } .dish.out .pr { color: var(--mut); }
/* bottom bar */
.bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; padding: 10px 12px calc(10px + env(safe-area-inset-bottom)); background: linear-gradient(0deg, var(--bg) 70%, transparent); }
.bar button { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 10px; background: var(--acc); color: #fff; border: 0; border-radius: 16px; padding: 14px 18px; font-size: 18px; font-weight: 800; box-shadow: 0 6px 18px rgba(181,69,27,.35); min-height: 56px; }
.bar .cnt { background: #fff; color: var(--acc); border-radius: 999px; padding: 2px 10px; }
/* sheets */
.sheet-bg { position: fixed; inset: 0; background: rgba(30,18,8,.45); z-index: 200; display: flex; align-items: flex-end; justify-content: center; }
.sheet { background: #fff; width: 100%; max-width: 560px; max-height: 92vh; overflow: auto; border-radius: 20px 20px 0 0; padding: 16px 16px calc(16px + env(safe-area-inset-bottom)); }
.sheet h2 { margin: 0 0 8px; font-size: 21px; }
.sheet .ph { width: 100%; aspect-ratio: 16/9; border-radius: 14px; background: #f1e6d6 center/cover no-repeat; margin-bottom: 10px; display: flex; align-items: center; justify-content: center; font-size: 56px; }
.opts { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 12px; }
.opts button { border: 2px solid var(--line); background: #fff; border-radius: 12px; padding: 10px 12px; font-weight: 700; min-height: 48px; }
.opts button.on { border-color: var(--acc); background: #fff3ec; color: var(--acc); }
.lbl { font-weight: 800; margin-top: 6px; }
.stepper { display: inline-flex; align-items: center; gap: 4px; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.stepper button { width: 44px; height: 44px; border: 0; background: #f6efe4; font-size: 22px; font-weight: 800; }
.stepper b { min-width: 34px; text-align: center; font-size: 18px; }
.row { display: flex; align-items: center; gap: 10px; }
.line { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.line .who { font-size: 12px; color: var(--mut); }
.line .x { margin-inline-start: auto; }
.tot { display: flex; justify-content: space-between; font-size: 20px; font-weight: 800; margin: 12px 0; }
.chip { display: inline-block; border-radius: 999px; padding: 3px 10px; font-size: 13px; font-weight: 800; background: #eee; }
.chip.pending { background: #fff4e5; color: var(--warn); } .chip.approved, .chip.imported { background: #e6f4ec; color: var(--ok); }
.chip.rejected { background: #fdecea; color: var(--bad); } .chip.closed { background: #eee; color: var(--mut); }
.ord { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin: 8px 0; }
.toast { position: fixed; left: 50%; bottom: 90px; transform: translateX(-50%) translateY(20px); background: #2a1d12; color: #fff; padding: 12px 18px; border-radius: 12px; font-weight: 700; opacity: 0; transition: .25s; z-index: 400; pointer-events: none; max-width: 90vw; text-align: center; }
.toast.show { opacity: 1; transform: translateX(-50%); } .toast.bad { background: var(--bad); } .toast.ok { background: var(--ok); }
/* scanner */
.scan-ov { position: fixed; inset: 0; background: #000; z-index: 500; display: flex; align-items: center; justify-content: center; }
.scan-ov video { width: 100%; height: 100%; object-fit: cover; }
.scan-box { position: absolute; width: 64vmin; height: 64vmin; border: 4px solid #fff; border-radius: 18px; box-shadow: 0 0 0 100vmax rgba(0,0,0,.45); }
.scan-hint { position: absolute; top: 12vh; color: #fff; font-weight: 800; font-size: 18px; text-align: center; padding: 0 20px; }
.scan-x { position: absolute; bottom: 8vh; }
/* staff pages */
.wrap { max-width: 1280px; margin: 0 auto; padding: 12px; }
.panel { background: #fff; border-radius: var(--r); box-shadow: var(--sh); padding: 14px; margin-bottom: 12px; }
.panel h2 { margin: 0 0 10px; font-size: 18px; }
.cols { display: grid; grid-template-columns: 1.4fr 1fr; gap: 12px; }
@media (max-width: 900px) { .cols { grid-template-columns: 1fr; } }
.tables { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 8px; }
.tcell { border: 2px solid var(--line); border-radius: 12px; padding: 10px; background: #fff; text-align: center; }
.tcell .n { font-size: 28px; font-weight: 900; }
.tcell.basket { border-color: #d6c3a5; background: #fffaf2; } .tcell.pending { border-color: var(--warn); background: #fff4e5; }
.tcell.approved { border-color: #7fb89a; background: #f1faf5; } .tcell.imported { border-color: var(--ok); background: #e6f4ec; }
.ocard { border: 2px solid var(--line); border-radius: 14px; padding: 12px; margin-bottom: 10px; }
.ocard.pending { border-color: var(--warn); box-shadow: 0 0 0 3px rgba(183,121,31,.12); }
.ocard .hd { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-weight: 800; }
.ocard .hd .tn { font-size: 22px; background: var(--ink); color: #fff; border-radius: 10px; padding: 2px 12px; }
.ocard ul { margin: 8px 0; padding-inline-start: 20px; } .ocard li { margin: 3px 0; }
.ocard .acts { display: flex; gap: 8px; flex-wrap: wrap; }
.status { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.pill { border-radius: 999px; padding: 5px 12px; font-weight: 800; font-size: 14px; background: #eee; }
.pill.ok { background: #e6f4ec; color: var(--ok); } .pill.bad { background: #fdecea; color: var(--bad); } .pill.warn { background: #fff4e5; color: var(--warn); }
.list { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 6px; max-height: 360px; overflow: auto; }
.list label { display: flex; gap: 8px; align-items: center; border: 1px solid var(--line); border-radius: 10px; padding: 6px 10px; }
.list label.out { background: #fdecea; }
.code { font: 800 30px ui-monospace, Consolas, monospace; letter-spacing: 4px; background: #f6efe4; border-radius: 12px; padding: 8px 14px; display: inline-block; }
.qrbox svg { width: 200px; height: 200px; }
.dev { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.center { max-width: 460px; margin: 40px auto; }
