/* Stack House — warm, mobile-first UI */
:root {
  --bg: #faf7f2;
  --surface: #ffffff;
  --surface-2: #f4efe7;
  --surface-3: #ebe4d9;
  --text: #2a2420;
  --muted: #7a6e64;
  --border: #e6ded2;
  --accent: #b4532a;
  --accent-hover: #9c4522;
  --accent-ink: #ffffff;
  --accent-soft: #f7e6dc;
  --ok: #2f7d4f;
  --ok-soft: #e2f2e7;
  --warn: #9a6412;
  --warn-soft: #fbf0d9;
  --danger: #b42318;
  --danger-soft: #fbe5e2;
  --info: #2f5f8f;
  --info-soft: #e3edf7;
  --shadow: 0 1px 2px rgba(60, 40, 20, .06), 0 4px 16px rgba(60, 40, 20, .06);
  --shadow-lg: 0 10px 40px rgba(40, 25, 10, .18);
  --radius: 16px;
  --radius-sm: 10px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif: ui-serif, Georgia, "Times New Roman", serif;
  --tabbar-h: 64px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #161311;
    --surface: #201c19;
    --surface-2: #292420;
    --surface-3: #342e29;
    --text: #f2ece5;
    --muted: #a99d92;
    --border: #3a332d;
    --accent: #e07a4f;
    --accent-hover: #ea8c63;
    --accent-ink: #1b120d;
    --accent-soft: #3b271d;
    --ok: #6cc690;
    --ok-soft: #1f3327;
    --warn: #e5b45c;
    --warn-soft: #3a2f1a;
    --danger: #f07f72;
    --danger-soft: #3d201d;
    --info: #86b6e6;
    --info-soft: #1d2b3a;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 4px 16px rgba(0, 0, 0, .25);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, .5);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text); font: 16px/1.45 var(--font);
  padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 12px);
  -webkit-tap-highlight-color: transparent;
}
[hidden] { display: none !important; }
h1, h2, h3 { margin: 0; line-height: 1.2; }
h1 { font-size: 1.6rem; font-family: var(--serif); font-weight: 600; letter-spacing: -.01em; }
h2 { font-size: 1.1rem; font-weight: 650; }
h3 { font-size: 1rem; font-weight: 650; }
p { margin: 0; }
a { color: var(--accent); }
button, input, select, textarea { font: inherit; color: inherit; }
svg.i { width: 20px; height: 20px; flex: none; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.tiny { font-size: .78rem; }
.nowrap { white-space: nowrap; }
.row { display: flex; align-items: center; gap: 10px; }
.row.wrap { flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.stack { display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr); }
.stack-lg { display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr); }
.stack > *, .stack-lg > *, .k-grid > *, .form-grid > * { min-width: 0; }
.grow { flex: 1; min-width: 0; }
.center { text-align: center; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- header & navigation ---------- */
.app-header {
  position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 12px;
  padding: calc(10px + env(safe-area-inset-top)) 16px 10px; background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--border);
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; min-width: 0; }
.brand img { width: 34px; height: 34px; border-radius: 9px; }
.brand-name { font-family: var(--serif); font-weight: 700; font-size: 1.15rem; white-space: nowrap; }
.brand-sub { font-size: .75rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.icon-btn {
  position: relative; display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 12px;
  border: 0; background: transparent; color: var(--text); cursor: pointer; text-decoration: none;
}
.icon-btn:hover { background: var(--surface-2); }
.badge {
  position: absolute; top: 4px; right: 3px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: var(--danger); color: #fff; font-size: .7rem; font-weight: 700; display: grid; place-items: center;
}
.avatar {
  width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: .85rem;
  background: var(--c, var(--accent)); color: #fff;
}
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: flex; justify-content: space-around;
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom)); background: var(--surface); border-top: 1px solid var(--border);
}
.tab {
  flex: 1; max-width: 110px; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 2px;
  color: var(--muted); text-decoration: none; font-size: .7rem; font-weight: 600; border-radius: 12px;
}
.tab svg.i { width: 22px; height: 22px; }
.tab.active { color: var(--accent); }
.tab.active svg.i { stroke-width: 2.4; }
@media (min-width: 860px) {
  body { padding-bottom: 32px; }
  .tabbar {
    position: sticky; top: 63px; bottom: auto; justify-content: center; gap: 4px; padding: 6px 16px;
    background: var(--bg); border-top: 0; border-bottom: 1px solid var(--border);
  }
  .tab { flex: none; max-width: none; flex-direction: row; gap: 8px; font-size: .9rem; padding: 8px 14px; }
  .tab svg.i { width: 18px; height: 18px; }
  .tab.active { background: var(--accent-soft); }
}

/* ---------- layout ---------- */
.view { max-width: 760px; margin: 0 auto; padding: 18px 16px 24px; }
.view.wide { max-width: 1120px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.eyebrow { font-size: .78rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); }
.loading { display: grid; place-items: center; min-height: 40vh; }
.spinner { width: 28px; height: 28px; border-radius: 50%; border: 3px solid var(--surface-3); border-top-color: var(--accent); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px;
  box-shadow: var(--shadow);
}
.card.flat { box-shadow: none; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.card-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--border); flex-wrap: wrap; }
.section-title { display: flex; align-items: center; gap: 8px; margin: 26px 0 10px; }
.section-title h2 { font-size: 1rem; }
.section-title .count { font-size: .8rem; color: var(--muted); font-weight: 600; }
.divider { height: 1px; background: var(--border); margin: 12px 0; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px;
  border-radius: 12px; border: 1px solid transparent; background: var(--accent); color: var(--accent-ink);
  font-weight: 650; text-decoration: none; cursor: pointer; white-space: nowrap; transition: background .15s, transform .05s;
}
.btn:hover { background: var(--accent-hover); }
.btn:active { transform: translateY(1px); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; pointer-events: none; }
.btn.secondary { background: var(--surface); color: var(--text); border-color: var(--border); }
.btn.secondary:hover { background: var(--surface-2); }
.btn.ghost { background: transparent; color: var(--text); }
.btn.ghost:hover { background: var(--surface-2); }
.btn.danger { background: var(--danger); color: #fff; }
.btn.danger-ghost { background: transparent; color: var(--danger); }
.btn.danger-ghost:hover { background: var(--danger-soft); }
.btn.ok { background: var(--ok); color: #fff; }
.btn.sm { min-height: 36px; padding: 6px 12px; font-size: .875rem; border-radius: 10px; }
.btn.block { width: 100%; }
.btn.big { min-height: 52px; font-size: 1.05rem; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 45%, transparent); outline-offset: 2px; }

/* ---------- pills, chips, status ---------- */
.pill {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-size: .8rem; font-weight: 650;
  background: var(--surface-2); color: var(--muted); white-space: nowrap;
}
.pill svg.i { width: 15px; height: 15px; }
.pill.ok { background: var(--ok-soft); color: var(--ok); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.pill.danger { background: var(--danger-soft); color: var(--danger); }
.pill.info { background: var(--info-soft); color: var(--info); }
.pill.accent { background: var(--accent-soft); color: var(--accent); }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--c, var(--accent)); flex: none; }
.house-tag { display: inline-flex; align-items: center; gap: 7px; font-weight: 650; }
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 6px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface); color: var(--text); font-weight: 600; font-size: .9rem;
  cursor: pointer; text-decoration: none; white-space: nowrap;
}
.chip.active { background: var(--text); color: var(--bg); border-color: var(--text); }
.chip .n { font-size: .75rem; opacity: .7; }

/* day strip */
.days { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 8px; scrollbar-width: none; scroll-snap-type: x proximity; }
.days::-webkit-scrollbar { display: none; }
.day {
  flex: none; width: 66px; padding: 8px 4px 9px; border-radius: 14px; border: 1px solid var(--border); background: var(--surface);
  text-align: center; text-decoration: none; color: var(--text); scroll-snap-align: start; cursor: pointer;
}
.day .dw { font-size: .72rem; font-weight: 700; text-transform: uppercase; color: var(--muted); letter-spacing: .04em; }
.day .dn { font-size: 1.3rem; font-weight: 700; line-height: 1.2; }
.day .ds { height: 16px; display: grid; place-items: center; font-size: .7rem; }
.day .ds svg.i { width: 15px; height: 15px; }
.day.active { border-color: var(--accent); background: var(--accent-soft); box-shadow: inset 0 0 0 1px var(--accent); }
.day.closed { opacity: .45; }
.day.set .ds { color: var(--ok); }
.day.partial .ds { color: var(--warn); }

/* ---------- banners ---------- */
.banner { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 12px; background: var(--surface-2); font-size: .92rem; }
.banner svg.i { margin-top: 1px; }
.banner.ok { background: var(--ok-soft); color: var(--ok); }
.banner.warn { background: var(--warn-soft); color: var(--warn); }
.banner.danger { background: var(--danger-soft); color: var(--danger); }
.banner.info { background: var(--info-soft); color: var(--info); }
.banner b { color: inherit; }

/* ---------- home ---------- */
.hello { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.meal-line { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; }
.meal-line + .meal-line { border-top: 1px solid var(--border); }
.meal-ico { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; flex: none; background: var(--surface-2); color: var(--accent); }
.meal-ico.dinner { color: var(--info); }
.meal-line .what { font-size: .92rem; color: var(--muted); }
.now-card { display: flex; align-items: center; gap: 14px; background: linear-gradient(135deg, var(--accent-soft), var(--surface)); }
.now-card .big-ico { width: 48px; height: 48px; border-radius: 14px; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; flex: none; }
.notify-cta { display: flex; gap: 12px; align-items: center; }

/* ---------- meal planning ---------- */
.meal-card { padding: 0; overflow: hidden; }
.meal-card > .mc-head { display: flex; align-items: center; gap: 12px; padding: 16px; }
.meal-card > .mc-body { padding: 0 16px 16px; display: grid; gap: 12px; }
.seg { display: inline-flex; background: var(--surface-2); border-radius: 12px; padding: 4px; gap: 4px; width: 100%; }
.seg button {
  flex: 1; border: 0; background: transparent; padding: 10px 12px; border-radius: 9px; font-weight: 650; cursor: pointer; color: var(--muted);
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 42px;
}
.seg button.on { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }
.seg button.on.yes { color: var(--ok); }
.picked { display: grid; gap: 4px; }
.pk-cat { font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin: 8px 0 2px; }
.pk-row { display: flex; align-items: center; gap: 12px; padding: 8px; border-radius: 12px; background: var(--surface-2); }
.thumb { width: 46px; height: 46px; border-radius: 10px; object-fit: cover; flex: none; background: var(--surface-3); display: grid; place-items: center; font-size: 1.4rem; overflow: hidden; }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.pk-name { font-weight: 650; line-height: 1.25; }
.stepper { display: inline-flex; align-items: center; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; flex: none; }
.stepper button { width: 38px; height: 38px; border: 0; background: transparent; cursor: pointer; display: grid; place-items: center; color: var(--text); border-radius: 11px; }
.stepper button:hover { background: var(--surface-2); }
.stepper button svg.i { width: 18px; height: 18px; }
.stepper .val { min-width: 54px; text-align: center; font-weight: 700; line-height: 1.05; }
.stepper .val small { display: block; font-size: .65rem; font-weight: 600; color: var(--muted); }
.add-dishes { border: 2px dashed var(--border); background: transparent; border-radius: 12px; padding: 12px; font-weight: 650; color: var(--accent); cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; }
.add-dishes:hover { background: var(--accent-soft); border-color: var(--accent); }
.save-bar {
  position: sticky; bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 8px); z-index: 20; margin-top: 18px;
  display: flex; align-items: center; gap: 12px; padding: 10px 10px 10px 16px; border-radius: 16px;
  background: var(--text); color: var(--bg); box-shadow: var(--shadow-lg);
}
.save-bar .btn { background: var(--accent); color: var(--accent-ink); }
@media (min-width: 860px) { .save-bar { bottom: 16px; } }

/* ---------- forms ---------- */
.field { display: grid; gap: 6px; }
.field > label, .label { font-size: .85rem; font-weight: 650; color: var(--muted); }
.input, select.input, textarea.input {
  width: 100%; min-height: 46px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface);
  color: var(--text); outline: none;
}
textarea.input { min-height: 80px; resize: vertical; }
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent); }
.input.time { width: auto; min-width: 110px; }
.form-grid { display: grid; gap: 14px; }
@media (min-width: 600px) { .form-grid.two { grid-template-columns: 1fr 1fr; } }
.switch { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; }
.switch input { appearance: none; -webkit-appearance: none; width: 44px; height: 26px; border-radius: 13px; background: var(--surface-3); position: relative; cursor: pointer; transition: background .15s; flex: none; margin: 0; }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .15s; }
.switch input:checked { background: var(--ok); }
.switch input:checked::after { transform: translateX(18px); }
.err { color: var(--danger); font-size: .9rem; min-height: 1.2em; }

/* ---------- sheet / modal ---------- */
.overlay { position: fixed; inset: 0; z-index: 50; background: rgba(20, 12, 6, .45); display: flex; align-items: flex-end; justify-content: center; animation: fade .15s ease-out; }
.sheet {
  width: 100%; max-width: 680px; max-height: 92vh; display: flex; flex-direction: column; background: var(--bg);
  border-radius: 22px 22px 0 0; box-shadow: var(--shadow-lg); animation: up .2s ease-out; padding-bottom: env(safe-area-inset-bottom);
}
.sheet.small { max-width: 440px; }
@media (min-width: 700px) { .overlay { align-items: center; } .sheet { border-radius: 22px; max-height: 86vh; } }
.sheet-head { display: flex; align-items: center; gap: 10px; padding: 16px 16px 10px; }
.sheet-head h2 { flex: 1; }
.sheet-body { overflow-y: auto; padding: 4px 16px 16px; display: flex; flex-direction: column; gap: 14px; }
.sheet-body > * { flex-shrink: 0; }
.sheet-foot { display: flex; gap: 10px; justify-content: flex-end; padding: 12px 16px 16px; border-top: 1px solid var(--border); }
@keyframes fade { from { opacity: 0; } }
@keyframes up { from { transform: translateY(30px); opacity: .6; } }

/* dish picker */
.dish-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.dish-card {
  position: relative; display: flex; flex-direction: column; text-align: left; border: 1px solid var(--border); background: var(--surface);
  border-radius: 14px; overflow: hidden; cursor: pointer; padding: 0; color: var(--text);
}
.dish-card .ph { aspect-ratio: 4 / 3; background: var(--surface-2); display: grid; place-items: center; font-size: 2.4rem; overflow: hidden; }
.dish-card .ph img { width: 100%; height: 100%; object-fit: cover; }
.dish-card .dc-body { padding: 8px 10px 10px; display: grid; gap: 2px; }
.dish-card .dc-name { font-weight: 650; line-height: 1.25; }
.dish-card .dc-desc { font-size: .78rem; color: var(--muted); line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.dish-card .tick { position: absolute; top: 8px; right: 8px; width: 30px; height: 30px; border-radius: 50%; background: rgba(255,255,255,.92); color: var(--text); display: grid; place-items: center; box-shadow: var(--shadow); }
.dish-card.on { border-color: var(--ok); box-shadow: 0 0 0 2px var(--ok); }
.dish-card.on .tick { background: var(--ok); color: #fff; }
.search { position: relative; }
.search svg.i { position: absolute; left: 12px; top: 13px; color: var(--muted); }
.search .input { padding-left: 40px; }

/* ---------- lists ---------- */
.list { display: grid; }
.list-item { display: flex; align-items: center; gap: 12px; padding: 12px 0; }
.list-item + .list-item { border-top: 1px solid var(--border); }
.order-items { margin: 6px 0 0; padding: 0; list-style: none; display: grid; gap: 3px; }
.order-items li { display: flex; justify-content: space-between; gap: 12px; font-size: .94rem; }
.order-items li .q { font-weight: 700; white-space: nowrap; }
.note { font-size: .88rem; padding: 8px 10px; border-radius: 10px; background: var(--warn-soft); color: var(--warn); margin-top: 8px; }
.empty { text-align: center; padding: 28px 16px; color: var(--muted); }
.empty .em { font-size: 2.2rem; margin-bottom: 6px; }

/* notifications */
.notif { display: flex; gap: 12px; padding: 12px; border-radius: 12px; text-decoration: none; color: inherit; cursor: pointer; }
.notif:hover { background: var(--surface-2); }
.notif.unread { background: var(--accent-soft); }
.notif .nt { font-weight: 650; }
.notif .nb { font-size: .88rem; color: var(--muted); }

/* ---------- kitchen ---------- */
.k-grid { display: grid; gap: 16px; }
.k-grid { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 980px) { .k-grid.cols { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; } }
.urgent-card { border-left: 5px solid var(--c, var(--accent)); }
.urgent-card.pending { animation: pulse 1.6s ease-in-out 3; }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--danger) 25%, transparent); } }
.house-status { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
.hs { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 12px; background: var(--surface-2); font-weight: 650; font-size: .92rem; }
.hs .st { margin-left: auto; display: inline-flex; align-items: center; gap: 3px; white-space: nowrap; }
.hs .st svg.i { width: 18px; height: 18px; }
.hs.ordered { background: var(--ok-soft); }
.hs.ordered .st { color: var(--ok); }
.hs.skipped .st { color: var(--muted); }
.hs.pending .st { color: var(--warn); }
.prep-row { display: flex; gap: 14px; align-items: flex-start; padding: 10px 0; }
.prep-row + .prep-row { border-top: 1px solid var(--border); }
.prep-total { min-width: 54px; text-align: center; border-radius: 12px; background: var(--accent-soft); color: var(--accent); padding: 6px 4px; font-weight: 800; font-size: 1.25rem; line-height: 1; }
.prep-total small { display: block; font-size: .62rem; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; margin-top: 3px; }
.by-house { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.by-house span { display: inline-flex; align-items: center; gap: 5px; font-size: .8rem; padding: 2px 8px; border-radius: 999px; background: var(--surface-2); }
.meal-total { display: flex; gap: 8px; flex-wrap: wrap; }
details.orders-by-house summary { cursor: pointer; font-weight: 650; padding: 6px 0; color: var(--accent); }
.house-order { padding: 12px; border-radius: 12px; background: var(--surface-2); border-left: 4px solid var(--c); }
.house-order + .house-order { margin-top: 8px; }

/* admin */
.admin-tabs { margin-bottom: 16px; }
.dish-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.dish-row + .dish-row { border-top: 1px solid var(--border); }
.dish-row.off .pk-name, .dish-row.off .thumb { opacity: .45; }
.photo-pick { display: flex; align-items: center; gap: 14px; }
.photo-pick .thumb { width: 88px; height: 88px; border-radius: 14px; font-size: 2rem; }
.wh-row { display: grid; grid-template-columns: 64px auto 1fr; align-items: center; gap: 12px; padding: 8px 0; }
.wh-row + .wh-row { border-top: 1px solid var(--border); }
.wh-times { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.wh-row.off .wh-times { opacity: .4; pointer-events: none; }
.tag-list { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-list .pill { padding: 6px 6px 6px 12px; }
.tag-list .pill button { border: 0; background: transparent; cursor: pointer; display: grid; place-items: center; color: inherit; padding: 0; }
.tag-list .pill svg.i { width: 15px; height: 15px; }
.color-input { width: 46px; height: 46px; padding: 3px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface); cursor: pointer; }

/* login */
.auth { min-height: calc(100vh - 80px); display: grid; place-items: center; }
.auth-card { width: 100%; max-width: 400px; }
.auth-logo { width: 72px; height: 72px; border-radius: 20px; margin: 0 auto 14px; display: block; box-shadow: var(--shadow); }

/* toast */
.toast {
  position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 18px); z-index: 60;
  max-width: min(92vw, 460px); padding: 12px 16px; border-radius: 14px; background: var(--text); color: var(--bg);
  box-shadow: var(--shadow-lg); font-weight: 600; font-size: .92rem; animation: up .2s ease-out; cursor: pointer;
}
.toast.error { background: var(--danger); color: #fff; }
@media (min-width: 860px) { .toast { bottom: 24px; } }

/* ---------- print (kitchen sheet) ---------- */
@media print {
  :root { --bg: #fff; --surface: #fff; --surface-2: #f3f3f3; --text: #000; --muted: #444; --border: #ccc; }
  body { padding: 0; }
  .app-header, .tabbar, .no-print, .toast, .days, .chips { display: none !important; }
  .card { box-shadow: none; break-inside: avoid; }
  details.orders-by-house { display: block; }
  details.orders-by-house > *:not(summary) { display: block; }
}
