body { background: #f3eee8; }
.cbar { position: sticky; top: 0; z-index: 20; background: var(--ink); color: #fff; padding: 10px 14px; padding-top: calc(10px + env(safe-area-inset-top)); display: flex; align-items: center; gap: 10px; }
.cbar .title { font-weight: 800; flex: 1; min-width: 0; }
.cbar .who { font-size: 13px; opacity: 0.75; font-weight: 500; }
.dot { width: 10px; height: 10px; border-radius: 50%; background: #e5a400; flex: none; }
.dot.on { background: #3bd17b; }
.cbar .btn.sm { background: rgba(255, 255, 255, 0.14); color: #fff; }
.shift { background: var(--gold) !important; color: var(--ink) !important; }

.cnav { position: fixed; bottom: 0; left: 0; right: 0; display: flex; background: #fff; border-top: 1px solid var(--line); z-index: 20; padding-bottom: env(safe-area-inset-bottom); }
.cnav button { flex: 1; border: 0; background: none; padding: 10px 2px 12px; font-size: 12px; font-weight: 700; color: var(--muted); cursor: pointer; position: relative; }
.cnav button .ic { display: block; font-size: 20px; line-height: 1.2; }
.cnav button.on { color: var(--red); }
.cnav .badge { position: absolute; top: 4px; left: 54%; background: var(--red); color: #fff; border-radius: 999px; font-size: 11px; min-width: 18px; padding: 1px 5px; }
.cview { padding: 12px 12px 90px; max-width: 980px; margin: 0 auto; }
@media (min-width: 900px) { .cards { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; } .cards > .ocard { margin: 0; } }

.ocard { background: #fff; border-radius: 16px; box-shadow: var(--shadow); padding: 14px; margin-bottom: 12px; border-left: 6px solid var(--gold); }
.ocard.late { border-left-color: var(--danger); }
.ocard.done { border-left-color: var(--line); }
.ocard .hd { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.ocard .tno { font-size: 24px; font-weight: 850; }
.ocard .meta { color: var(--muted); font-size: 14px; }
.ocard .age { margin-left: auto; font-weight: 750; font-variant-numeric: tabular-nums; }
.ocard.late .age { color: var(--danger); }
.oline { display: flex; gap: 10px; padding: 8px 0; border-bottom: 1px dashed var(--line); }
.oline:last-of-type { border-bottom: 0; }
.oline .q { font-size: 20px; font-weight: 850; min-width: 34px; }
.oline .n { font-weight: 700; font-size: 17px; }
.oline .o { font-size: 14px; color: var(--ink-2); }
.oline .note { font-size: 14px; color: #8a3b00; font-weight: 600; }
.oline.void .n, .oline.void .q { text-decoration: line-through; color: var(--muted); }
.pos { font-family: ui-monospace, Menlo, Consolas, monospace; background: #f1ebe4; border-radius: 6px; padding: 1px 6px; font-size: 13px; font-weight: 700; margin-left: 6px; }
.onote { background: var(--amber-bg); color: #6b4300; border-radius: 10px; padding: 8px 10px; margin-top: 8px; font-weight: 600; }
.oact { display: flex; gap: 8px; margin-top: 12px; }
.oact .btn.green { flex: 1; }

.req { display: flex; align-items: center; gap: 12px; background: #fff; border-radius: 14px; box-shadow: var(--shadow); padding: 12px 14px; margin-bottom: 10px; }
.req .k { font-size: 26px; }

.tgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.tcell { background: #fff; border-radius: 14px; box-shadow: var(--shadow); padding: 10px; min-height: 92px; cursor: pointer; border: 2px solid transparent; text-align: left; }
.tcell.busy { border-color: var(--gold); }
.tcell .tl { font-size: 20px; font-weight: 850; }
.tcell .tabchip { white-space: nowrap; display: flex; justify-content: space-between; font-size: 13px; background: #f6f1eb; border-radius: 8px; padding: 4px 7px; margin-top: 5px; gap: 6px; }
.tcell .tabchip.stale { background: var(--danger-bg); color: var(--danger); }
.tcell .tabchip.newo { background: var(--amber-bg); color: var(--amber); }

.login { max-width: 360px; margin: 40px auto; padding: 0 16px; }
.pinpad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.pinpad button { min-height: 60px; font-size: 24px; font-weight: 700; border: 0; border-radius: 14px; background: #fff; box-shadow: var(--shadow); cursor: pointer; }
.pindots { text-align: center; font-size: 30px; letter-spacing: 0.4em; min-height: 44px; }

.stockrow { display: flex; align-items: center; gap: 10px; padding: 10px 4px; border-bottom: 1px solid var(--line); }
.switch { position: relative; width: 50px; height: 30px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch span { position: absolute; inset: 0; background: #d8cfc6; border-radius: 999px; transition: 0.15s; cursor: pointer; }
.switch span::before { content: ""; position: absolute; width: 24px; height: 24px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: 0.15s; }
.switch input:checked + span { background: var(--green); }
.switch input:checked + span::before { transform: translateX(20px); }

.picker-item { display: flex; justify-content: space-between; align-items: center; padding: 10px 2px; border-bottom: 1px solid #f1ebe4; cursor: pointer; background: none; border-left: 0; border-right: 0; border-top: 0; width: 100%; text-align: left; }
.picker-item:disabled { opacity: 0.4; }
.section-h { margin: 18px 0 8px; font-size: 13px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); font-weight: 800; }
