/* Layout: phone-first store app. Sticky header with language switch, one scrolling pane per section, bottom tab bar on phones, side tabs on wide screens. Celadon glaze accent on stone neutrals, umber ink. */
/* Palette: hanji ivory and onggi lacquer, a thin brass rule for emphasis, celadon kept for progress and confirmation. */
:root {
  --bg: #f4efe6;
  --surface: #fffcf6;
  --sunk: #ece5d8;
  --line: #e2d8c7;
  --ink: #221a14;
  --muted: #7a6d5f;
  --accent: #2c5a52;
  --accent-ink: #ffffff;
  --accent-soft: #e1ebe6;
  --umber: #6b3f2a;
  --gold: #a3824f;
  --gold-soft: #f1e6d1;
  --lacquer: #1e1814;
  --lacquer-ink: #f4ead9;
  --ok: #2f7a43;
  --ok-soft: #dcefe0;
  --warn: #9a6408;
  --warn-soft: #f6e8c9;
  --bad: #a3352b;
  --bad-soft: #f5dcd8;
  --shadow: 0 1px 2px rgba(34, 26, 20, .05), 0 10px 28px -16px rgba(34, 26, 20, .22);
  --f-display: "Noto Serif KR", "Gowun Batang", "Songti SC", serif;
  --f-body: "IBM Plex Sans KR", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, monospace;
  --r: 14px;
  --logo-filter: none;
  --mark: #f3dc7c;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  --bg: #15110e; --surface: #1f1a16; --sunk: #2a241f; --line: #372f28; --ink: #f1e9dd; --muted: #a89a8a;
  --accent: #7fbcb0; --accent-ink: #0f1f1c; --accent-soft: #22362f; --umber: #d4a184; --gold: #cfae78; --gold-soft: #3a2f20;
  --lacquer: #0e0b09; --lacquer-ink: #f1e6d4; --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 10px 28px -16px rgba(0, 0, 0, .6);
  --ok: #7cc58c; --ok-soft: #1f3324; --warn: #e3b360; --warn-soft: #3a2f1a; --bad: #ec8a7f; --bad-soft: #3d2320; --logo-filter: invert(1); --mark: #6a5717; color-scheme: dark; } }
:root[data-theme="dark"] {
  --bg: #15110e; --surface: #1f1a16; --sunk: #2a241f; --line: #372f28; --ink: #f1e9dd; --muted: #a89a8a;
  --accent: #7fbcb0; --accent-ink: #0f1f1c; --accent-soft: #22362f; --umber: #d4a184; --gold: #cfae78; --gold-soft: #3a2f20;
  --lacquer: #0e0b09; --lacquer-ink: #f1e6d4; --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 10px 28px -16px rgba(0, 0, 0, .6);
  --ok: #7cc58c; --ok-soft: #1f3324; --warn: #e3b360; --warn-soft: #3a2f1a; --bad: #ec8a7f; --bad-soft: #3d2320; --logo-filter: invert(1); --mark: #6a5717; color-scheme: dark; }

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { background: var(--bg); color: var(--ink); }
body { font-family: var(--f-body); font-size: 15px; line-height: 1.55; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--surface); }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
h1, h2, h3 { text-wrap: balance; margin: 0; }
.num { font-family: var(--f-mono); font-variant-numeric: tabular-nums; }

header.top { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 5; background: var(--surface); border-bottom: 1px solid var(--line);
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); padding-block: 10px; }
.top-in { max-width: 1100px; margin: 0 auto; display: flex; align-items: center; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1; }
.home-btn { border: 0; background: none; padding: 0; flex: none; display: flex; }
.home-btn img { height: 40px; width: auto; }
img.logo { filter: var(--logo-filter); max-width: 100%; }
.crumb-store { display: flex; align-items: center; gap: 8px; min-width: 0; padding-left: 10px; border-left: 1px solid var(--line); }
.crumb-store img { height: 22px; width: auto; }
.crumb-store b { font-family: var(--f-display); font-size: 17px; color: var(--umber); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.home { max-width: 760px; margin: 0 auto; display: flex; flex-direction: column; gap: 22px; }
.home-hero { display: flex; flex-direction: column; align-items: center; gap: 6px; padding-block: 18px 6px; text-align: center; }
.home-hero img { width: min(420px, 90%); }
.brand-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; display: flex; flex-direction: column; gap: 14px; }
.brand-card > img { width: min(280px, 80%); }
.stores { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; }
.store-btn { border: 1px solid var(--line); background: var(--bg); border-radius: var(--r); padding: 14px 16px; text-align: left; display: flex; flex-direction: column; gap: 2px; }
.store-btn:hover { border-color: var(--accent); }
.store-btn b { font-size: 17px; }
.store-btn span { font-size: 13px; color: var(--muted); }
@media (max-width: 480px) { .home-btn img { height: 30px; } .crumb-store img { display: none; } }
.langs { display: flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; flex: none; }
.langs button { border: 0; background: transparent; padding: 5px 10px; font-size: 13px; color: var(--muted); }
.langs button[aria-pressed="true"] { background: var(--ink); color: var(--bg); }

.shell { max-width: 1100px; margin: 0 auto; display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 24px;
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); padding-block: 20px 40px; }
nav.tabs { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 76px); align-self: start; display: flex; flex-direction: column; gap: 4px; }
nav.tabs button { display: flex; align-items: center; gap: 10px; text-align: left; border: 0; background: transparent; padding: 10px 12px; border-radius: var(--r); color: var(--muted); font-weight: 500; }
nav.tabs button .ix { font-family: var(--f-mono); font-size: 12px; color: var(--muted); width: 18px; }
nav.tabs button[aria-selected="true"] { background: var(--accent-soft); color: var(--ink); }
nav.tabs .sec { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); padding: 14px 12px 4px; font-weight: 600; }
nav.tabs .sec:first-child { padding-top: 0; }
.badge { margin-left: auto; background: var(--bad); color: #fff; border-radius: 999px; font-size: 11px; padding: 0 7px; font-family: var(--f-mono); }
.idea-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.idea { border: 1px solid var(--line); background: var(--surface); border-radius: var(--r); overflow: hidden; display: flex; flex-direction: column; }
.idea .ph { aspect-ratio: 4 / 3; max-width: 100%; background: var(--sunk); display: grid; place-items: center; color: var(--muted); font-size: 13px; }
.idea .ph img { width: 100%; height: 100%; object-fit: cover; display: block; }
.idea .in { padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; flex: 1; min-width: 0; }
.idea .nm { font-weight: 600; font-size: 16px; }
.idea p { margin: 0; font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.idea a { color: var(--accent); font-size: 13px; overflow-wrap: anywhere; }
.pill.st_new { background: var(--sunk); color: var(--muted); } .pill.st_review, .pill.st_test { background: var(--warn-soft); color: var(--warn); }
.pill.st_adopt { background: var(--ok-soft); color: var(--ok); } .pill.st_hold { background: var(--bad-soft); color: var(--bad); }
.gate { max-width: 460px; margin: 40px auto; text-align: center; display: flex; flex-direction: column; gap: 12px; align-items: center; }
.gate h2 { font-family: var(--f-display); font-size: 24px; }
.person { display: flex; align-items: center; gap: 10px; padding: 10px 4px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.person .who { flex: 1; min-width: 160px; }
nav.tabs button[aria-selected="true"] .ix { color: var(--accent); }
.menu-btn { display: none; }
@media (max-width: 760px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .menu-btn:not([hidden]) { display: flex; flex-direction: column; justify-content: center; gap: 4px; flex: none; width: 40px; height: 40px; margin-left: -6px; border: 0; background: none; padding: 0 9px; }
  .menu-btn span { display: block; height: 2px; border-radius: 2px; background: var(--ink); }
  /* Phone: the sidebar is its own page, opened from the menu button and on entering a store. */
  nav.tabs { position: static; display: none; }
  body.nav-open nav.tabs:not([hidden]) { display: flex; }
  body.nav-open nav.tabs:not([hidden]) ~ main { display: none; }
  nav.tabs button { padding: 12px; font-size: 16px; }
}

main { min-width: 0; }
.pane-head { display: flex; flex-wrap: wrap; align-items: end; gap: 12px; margin-bottom: 16px; }
.pane-head .t { flex: 1; min-width: 200px; }
.pane-head h2 { font-family: var(--f-display); font-size: 26px; }
.pane-head p { margin: 2px 0 0; color: var(--muted); font-size: 14px; }

.btn { border: 1px solid var(--line); background: var(--surface); border-radius: 8px; padding: 8px 14px; font-weight: 500; font-size: 14px; }
.btn:hover { border-color: var(--muted); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.danger { color: var(--bad); }
.btn.sm { padding: 4px 10px; font-size: 13px; }
.btn:disabled { opacity: .5; cursor: default; }

.search { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.search input { flex: 1; min-width: 180px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 16px; }
.chip { border: 1px solid var(--line); background: transparent; border-radius: 999px; padding: 4px 12px; font-size: 13px; color: var(--muted); }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.toc { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); overflow: hidden; margin-bottom: 18px; }
.toc-row { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; border: 0; border-top: 1px solid var(--line); background: transparent; padding: 11px 14px; font-size: 15px; color: var(--ink); }
.toc-row:first-child { border-top: 0; }
.toc-row[aria-pressed="true"] { background: var(--accent-soft); font-weight: 600; }
.toc-t { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.toc-n { flex: none; font: 12px var(--f-mono); color: var(--muted); }
/* today's checklist */
.menu-card { display: block; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); margin-bottom: 18px; overflow: hidden; color: var(--ink); text-decoration: none; }
.menu-card-t { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; padding: 12px 14px; }
.menu-card img { display: block; width: 100%; height: auto; background: #0d0f10; }
.chk { border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: var(--r); background: var(--surface); margin-bottom: 18px; overflow: hidden; }
.chk.chk-done { border-left-color: var(--ok); }
.chk-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; width: 100%; border: 0; background: transparent; text-align: left; padding: 12px 14px; color: var(--ink); }
.chk-t { display: flex; flex-direction: column; min-width: 0; }
.chk-t b { font-size: 16px; }
.chk-n { font: 600 15px var(--f-mono); align-self: center; }
.chk-bar { grid-column: 1 / -1; height: 6px; border-radius: 3px; background: var(--sunk); overflow: hidden; }
.chk-bar i { display: block; height: 100%; background: var(--accent); }
.chk-done .chk-bar i { background: var(--ok); }
.chk-hint { padding: 0 14px; margin: 0 0 4px; }
.chk-at { font: 600 12px var(--f-mono); letter-spacing: .08em; color: var(--muted); padding: 12px 14px 4px; border-top: 1px solid var(--line); }
.chk-row { display: flex; gap: 12px; align-items: flex-start; width: 100%; border: 0; background: transparent; text-align: left; padding: 9px 14px; color: var(--ink); font-size: 15px; }
.chk-row[aria-pressed="true"] .chk-txt { color: var(--muted); }
.chk-box { flex: none; width: 22px; height: 22px; border: 2px solid var(--line); border-radius: 6px; display: grid; place-items: center; font-weight: 700; color: var(--accent-ink); margin-top: 1px; }
.chk-row[aria-pressed="true"] .chk-box { background: var(--ok); border-color: var(--ok); }
.chk-row.warn .chk-box { background: var(--bad); border-color: var(--bad); }
.chk-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; overflow-wrap: anywhere; }
.chk-role { font: 600 11px var(--f-mono); color: var(--umber); }
.chk-who { font-size: 12px; color: var(--ok); }
.chk-warn { font-size: 13px; color: var(--bad); font-weight: 600; }
.chk-foot { display: grid; gap: 10px; justify-items: stretch; padding: 14px 16px 16px; border-top: 1px solid var(--line); }
.chk-foot > .btn { width: 100%; justify-content: center; }
.chk-saved { font-size: 13px; font-weight: 600; margin: 0; }
.chk-acts { display: flex; gap: 8px; }
.chk-acts .btn { flex: 1; justify-content: center; }
.chk-foot .chk-warn { margin: 0; }
.chk-in { display: flex; gap: 8px; margin-top: 6px; }
.chk-in input { flex: 1; min-width: 0; max-width: 220px; padding: 6px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); color: var(--ink); font: inherit; }
@media (max-width: 760px) {
  .chips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-left: -16px; margin-right: -16px; padding: 0 16px; }
  .chip { flex: none; white-space: nowrap; }
}

.group-title { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 20px 0 8px; font-weight: 600; }
.list { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.item { border-bottom: 1px solid var(--line); }
.item > button.row { width: 100%; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: center; border: 0; background: transparent; padding: 14px 4px; text-align: left; }
.item .ttl { font-weight: 600; font-size: 16px; }
.item .sum { color: var(--muted); font-size: 14px; margin-top: 2px; }
.item .chev { color: var(--muted); font-family: var(--f-mono); transition: transform .15s; }
.item[open-state="1"] .chev { transform: rotate(90deg); }
.tags { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 6px; }
.tag { font-size: 11px; padding: 1px 8px; border-radius: 4px; background: var(--sunk); color: var(--muted); }
.detail { padding: 4px 4px 20px; display: flex; flex-direction: column; gap: 12px; }
.body { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px; max-width: 72ch; }
.body h4 { margin: 14px 0 6px; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.body h4:first-child { margin-top: 0; }
.body p { margin: 0 0 6px; }
.body ol, .body ul { margin: 0 0 6px; padding-left: 22px; }
.body li { margin-bottom: 3px; }
mark { background: var(--mark); color: inherit; border-radius: 3px; padding: 0 1px; }
.search .hits { align-self: center; }
.item .snip { font-size: 13px; color: var(--muted); margin-top: 4px; }
.pdf { display: flex; gap: 12px; align-items: center; padding: 12px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); color: var(--ink); text-decoration: none; min-width: 0; }
.pdf:hover { border-color: var(--accent); }
.sec-pdf { margin: 22px 0 8px; border-left: 4px solid var(--umber); }
.sec-pdf:first-child { margin-top: 4px; }
.pdf-ic { flex: none; width: 42px; height: 52px; border-radius: 4px 12px 4px 4px; background: var(--umber); color: var(--surface); display: grid; place-items: end center; padding-bottom: 8px; font: 700 11px/1 var(--f-mono); letter-spacing: .06em; }
.pdf-t { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.pdf-t b { font-size: 14px; line-height: 1.35; overflow-wrap: anywhere; }
.pdf-go { align-self: flex-start; display: inline-flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; margin-bottom: 10px; text-decoration: none; color: var(--accent); border-color: var(--accent); }
.pdf-go .note { font-size: 12px; }
.attach { display: flex; gap: 8px; flex-wrap: wrap; }
.attach a { display: inline-flex; gap: 6px; align-items: center; padding: 6px 12px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); text-decoration: none; font-size: 14px; }
.attach img { max-width: 100%; max-height: 360px; border-radius: var(--r); border: 1px solid var(--line); }
.empty { padding: 28px 20px; border: 1px dashed var(--line); border-radius: var(--r); color: var(--muted); text-align: center; }
.empty b { color: var(--ink); display: block; margin-bottom: 4px; }
.note { font-size: 13px; color: var(--muted); }
.banner { padding: 10px 14px; border-radius: 8px; background: var(--warn-soft); color: var(--warn); font-size: 14px; margin-bottom: 14px; }
.banner.info { background: var(--accent-soft); color: var(--ink); }

/* forms */
.sheet { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; display: flex; flex-direction: column; gap: 12px; margin-bottom: 16px; }
.sheet h3 { font-size: 16px; }
.fgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; }
label.f { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); min-width: 0; }
label.f input, label.f select, label.f textarea { padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); font-size: 14px; color: var(--ink); width: 100%; }
label.f textarea { min-height: 110px; resize: vertical; font-family: var(--f-body); }
.row-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* invoice */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-bottom: 18px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; }
.kpi small { display: block; font-size: 12px; color: var(--muted); }
.kpi b { font-family: var(--f-mono); font-size: 22px; font-weight: 500; font-variant-numeric: tabular-nums; }
.bars { display: flex; flex-direction: column; gap: 6px; margin-bottom: 20px; }
.bar { display: grid; grid-template-columns: 110px minmax(0, 1fr) 90px; gap: 10px; align-items: center; font-size: 13px; }
.bar .track { height: 14px; background: var(--sunk); border-radius: 3px; overflow: hidden; }
.bar .fill { height: 100%; background: var(--accent); border-radius: 3px; }
.bar .v { text-align: right; font-family: var(--f-mono); font-variant-numeric: tabular-nums; }
.tbl-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); margin-bottom: 18px; }
table { border-collapse: collapse; width: 100%; font-size: 14px; }
th, td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
th { font-size: 12px; color: var(--muted); font-weight: 600; background: var(--sunk); position: sticky; top: 0; }
td.r, th.r { text-align: right; font-family: var(--f-mono); font-variant-numeric: tabular-nums; }
tr:last-child td { border-bottom: 0; }
table input, table select { width: 100%; min-width: 70px; padding: 4px 6px; border: 1px solid var(--line); border-radius: 6px; background: var(--bg); font-size: 13px; }
table input.wide { min-width: 160px; }
.drop { border: 2px dashed var(--accent); border-radius: var(--r); padding: 22px; text-align: center; background: var(--accent-soft); display: flex; flex-direction: column; gap: 8px; align-items: center; }
.drop b { font-size: 16px; }
.preview-img { max-width: 100%; max-height: 420px; border-radius: 8px; border: 1px solid var(--line); }
.inv-row { display: grid; grid-template-columns: 90px minmax(0, 1fr) auto; gap: 12px; padding: 10px 4px; border-bottom: 1px solid var(--line); align-items: center; }
.inv-row button.lnk { border: 0; background: none; text-align: left; padding: 0; min-width: 0; }
.example-flag { display: inline-block; font-size: 11px; padding: 1px 8px; border-radius: 4px; background: var(--warn-soft); color: var(--warn); font-weight: 600; margin-left: 6px; vertical-align: middle; }

/* staff */
.staff-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; margin-bottom: 18px; }
.staff-card { border: 1px solid var(--line); background: var(--surface); border-radius: var(--r); padding: 12px 14px; text-align: left; display: flex; flex-direction: column; gap: 6px; }
.staff-card[aria-pressed="true"] { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.staff-card .nm { font-weight: 600; font-size: 16px; }
.prog { height: 6px; background: var(--sunk); border-radius: 3px; overflow: hidden; }
.prog i { display: block; height: 100%; background: var(--ok); }
.check-area { margin-bottom: 18px; }
.check { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 10px 4px; border-bottom: 1px solid var(--line); }
.check .lbl { min-width: 0; }
.check .meta { font-size: 12px; color: var(--muted); }
.tri { display: flex; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; flex: none; }
.tri button { border: 0; background: transparent; padding: 5px 9px; font-size: 12px; color: var(--muted); }
.tri button + button { border-left: 1px solid var(--line); }
.tri button[aria-pressed="true"][data-v="0"] { background: var(--bad-soft); color: var(--bad); font-weight: 600; }
.tri button[aria-pressed="true"][data-v="1"] { background: var(--warn-soft); color: var(--warn); font-weight: 600; }
.tri button[aria-pressed="true"][data-v="2"] { background: var(--ok-soft); color: var(--ok); font-weight: 600; }
.tri button:disabled { cursor: default; }
.pill { display: inline-block; font-size: 12px; padding: 2px 9px; border-radius: 999px; font-weight: 600; }
.pill.s0 { background: var(--sunk); color: var(--muted); }
.pill.s1 { background: var(--warn-soft); color: var(--warn); }
.pill.s2 { background: var(--ok-soft); color: var(--ok); }
.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(96px + env(safe-area-inset-bottom, 0px)); background: var(--ink); color: var(--bg); padding: 8px 16px; border-radius: 8px; font-size: 14px; z-index: 20; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* sign-in and accounts */
.gate .sheet { width: 100%; text-align: left; }
.gate .sheet h2 { font-family: var(--f-display); font-size: 22px; }
.gate-logo { width: min(320px, 80%); margin-bottom: 8px; }
.note.err { color: var(--bad); margin: 0; min-height: 1em; }
label.chk { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; }
.person.off .who { opacity: .55; }
.sm-select, .inline-in { padding: 4px 8px; border: 1px solid var(--line); border-radius: 6px; background: var(--bg); font-size: 13px; }
.inline-in { width: 150px; font-family: var(--f-mono); }
textarea.tall { min-height: 220px; }
details.other-langs { border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; display: flex; flex-direction: column; gap: 10px; }
details.other-langs[open] > summary { margin-bottom: 10px; }
details.other-langs summary { cursor: pointer; font-size: 14px; color: var(--muted); }
details.other-langs > .fgrid, details.other-langs > label { margin-bottom: 10px; }

/* Manual quiz */
.q-daily { width: 100%; display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; justify-content: space-between; text-align: left; border: 1px solid var(--line); border-left: 4px solid var(--umber); border-radius: var(--r); background: var(--surface); padding: 16px; color: var(--ink); }
.q-daily:hover, .q-tile:hover:not(:disabled) { border-color: var(--accent); }
.q-daily-t { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.q-daily-t b { font-family: var(--f-display); font-size: 20px; }
.q-daily-s { display: flex; gap: 6px; flex-wrap: wrap; }
.q-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; }
.q-tile { border: 1px solid var(--line); background: var(--surface); border-radius: var(--r); padding: 14px; text-align: left; display: flex; flex-direction: column; gap: 4px; color: var(--ink); }
.q-tile b { font-size: 16px; }
.q-tile:disabled { opacity: .55; cursor: default; }
.q-prog { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px 12px; align-items: center; margin-bottom: 12px; }
.q-prog .num { font-weight: 600; }
.q-prog .q-cat { font-size: 13px; color: var(--umber); font-weight: 600; justify-self: end; }
.q-prog .chk-bar { grid-column: 1 / -1; }
.q-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; display: flex; flex-direction: column; gap: 14px; }
.q-q { font-family: var(--f-display); font-size: 20px; line-height: 1.4; }
.q-choices { display: flex; flex-direction: column; gap: 8px; }
.q-choice { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; border: 1px solid var(--line); background: var(--bg); border-radius: var(--r); padding: 12px 14px; color: var(--ink); font-size: 15px; }
.q-choice:hover:not(:disabled) { border-color: var(--accent); }
.q-choice:disabled { cursor: default; }
.q-choice > span:nth-child(2) { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.q-key { flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font: 600 13px var(--f-mono); background: var(--sunk); color: var(--muted); }
.q-mark { font-weight: 700; }
.q-choice.right { border-color: var(--ok); background: var(--ok-soft); }
.q-choice.right .q-key { background: var(--ok); color: var(--accent-ink); }
.q-choice.wrong { border-color: var(--bad); background: var(--bad-soft); }
.q-choice.wrong .q-key { background: var(--bad); color: var(--accent-ink); }
.q-choice.dim { opacity: .55; }
.q-fb { border-radius: var(--r); padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; }
.q-fb.ok { background: var(--ok-soft); } .q-fb.ok b { color: var(--ok); }
.q-fb.bad { background: var(--bad-soft); } .q-fb.bad b { color: var(--bad); }
.q-fb p { margin: 0; }
.q-result { align-items: center; text-align: center; }
.q-result.pass { border-color: var(--ok); }
.q-big { font-size: 44px; font-weight: 600; }
.q-result p { margin: 0; }
.q-wrong { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; align-items: center; padding: 12px 4px; border-bottom: 1px solid var(--line); }
.q-wrong .ttl { font-weight: 600; } .q-wrong .sum { grid-column: 1; color: var(--ok); font-size: 14px; }
.q-wrong .btn { grid-column: 2; grid-row: 1 / 3; }
.q-hist { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; padding: 10px 4px; border-bottom: 1px solid var(--line); font-size: 14px; }
.q-hist span:first-child { font-family: var(--f-mono); color: var(--muted); }
@media (max-width: 480px) { .q-q { font-size: 18px; } .q-wrong { grid-template-columns: minmax(0, 1fr); } .q-wrong .btn { grid-column: 1; grid-row: auto; justify-self: start; } }

/* Xero import */
.xero-box { margin: 0 0 18px; }
.xero-flag { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px; font-size: 11px; font-weight: 600; background: color-mix(in srgb, #13b5ea 16%, transparent); color: #0b7fae; vertical-align: middle; }
.uploader-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; width: 100%; }
.chk-inline { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; }
.xero-flag.tg { background: color-mix(in srgb, #229ed9 14%, transparent); color: #1b7fb0; }
.xero-flag.warn { background: color-mix(in srgb, #d97706 16%, transparent); color: #b45309; }
.tg-out { white-space: pre-wrap; word-break: break-all; font-size: 12px; margin: 6px 0 0; }
.tg-out:empty { display: none; }
.xero-link { display: grid; gap: 6px; margin: 12px 0 0; padding: 12px 0 0; border-top: 1px dashed var(--line, #ddd); }
.xero-link select { max-width: 100%; }

/* ---------- Premium skin: lacquer header, brass rules, soft raised cards ---------- */
body::before { background: var(--lacquer); }
header.top { background: var(--lacquer); color: var(--lacquer-ink); border-bottom: 0; box-shadow: inset 0 -1px 0 var(--gold); padding-block: 12px; }
header.top img.logo { filter: invert(1) sepia(.25) brightness(1.05); }
.crumb-store { border-left-color: color-mix(in srgb, var(--gold) 60%, transparent); }
.crumb-store b { color: var(--gold); font-weight: 600; letter-spacing: .01em; }
header.top .menu-btn span { background: var(--lacquer-ink); }
.langs { border-color: color-mix(in srgb, var(--lacquer-ink) 30%, transparent); }
.langs button { color: color-mix(in srgb, var(--lacquer-ink) 70%, transparent); letter-spacing: .04em; }
.langs button[aria-pressed="true"] { background: var(--gold); color: var(--lacquer); font-weight: 600; }

.pane-head { margin-bottom: 22px; padding-bottom: 14px; border-bottom: 1px solid var(--line); position: relative; }
.pane-head::after { content: ""; position: absolute; left: 0; bottom: -1px; width: 48px; height: 2px; background: var(--gold); }
.pane-head h2 { font-size: 28px; font-weight: 600; letter-spacing: -.01em; }
.group-title, nav.tabs .sec { color: var(--gold); letter-spacing: .16em; }

nav.tabs button { border-radius: 0; border-left: 2px solid transparent; padding-left: 14px; }
nav.tabs button[aria-selected="true"] { background: linear-gradient(90deg, var(--gold-soft), transparent); border-left-color: var(--gold); font-weight: 600; }
nav.tabs button[aria-selected="true"] .ix { color: var(--gold); }
nav.tabs button:hover:not([aria-selected="true"]) { color: var(--ink); }

.btn { border-radius: 999px; padding: 8px 16px; transition: border-color .15s, background .15s; }
.btn.sm { padding: 5px 12px; }
.btn.primary { background: var(--lacquer); border-color: var(--lacquer); }
.btn.primary:hover:not(:disabled) { border-color: var(--gold); box-shadow: inset 0 0 0 1px var(--gold); }
:root[data-theme="dark"] .btn.primary { background: var(--gold); border-color: var(--gold); color: var(--lacquer); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .btn.primary { background: var(--gold); border-color: var(--gold); color: var(--lacquer); } }

.sheet, .kpi, .toc, .chk, .tbl-wrap, .brand-card, .staff-card, .idea, .q-card, .q-tile, .q-daily, .body, .pdf { border-color: var(--line); box-shadow: var(--shadow); }
.chk { border-left: 3px solid var(--gold); }
.chk.chk-done { border-left-color: var(--ok); }
.toc-row[aria-pressed="true"] { background: var(--gold-soft); }
.search input, label.f input, label.f select, label.f textarea { border-radius: 10px; }
.search input { background: var(--surface); padding: 11px 14px; }

.kpi { padding: 14px 16px; }
.kpi small { letter-spacing: .08em; text-transform: uppercase; font-size: 11px; color: var(--gold); font-weight: 600; }
.kpi b { font-family: var(--f-display); font-size: 26px; font-weight: 600; }
.bar .fill { background: linear-gradient(90deg, var(--accent), color-mix(in srgb, var(--accent) 70%, var(--gold))); }
.drop { border: 1px dashed var(--gold); background: var(--gold-soft); }

/* home: a lacquer brand panel with ivory store cards */
.home { gap: 26px; }
.home-hero { padding-block: 26px 4px; }
.home-hero img { width: min(360px, 82%); }
.home-hero .note { letter-spacing: .14em; text-transform: uppercase; font-size: 12px; color: var(--gold); font-weight: 600; }
.brand-card { background: var(--lacquer); border: 0; padding: 26px 22px 22px; gap: 18px; position: relative; overflow: hidden; }
.brand-card::before { content: ""; position: absolute; inset: 10px; border: 1px solid color-mix(in srgb, var(--gold) 45%, transparent); border-radius: calc(var(--r) - 6px); pointer-events: none; }
.brand-card > img { filter: invert(1) sepia(.25) brightness(1.05); width: min(240px, 72%); align-self: center; position: relative; }
.stores { position: relative; }
.store-btn { background: var(--surface); border: 0; padding: 16px 18px; flex-direction: row; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; color: var(--ink); }
.store-btn b { font-size: 18px; font-weight: 700; color: var(--ink); flex: 1; min-width: 0; }
.stores.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 480px) { .stores.two .store-btn { padding: 14px 12px; } .stores.two .store-btn b { font-size: 16px; } }
.store-btn::after { content: "→"; color: var(--gold); font-size: 18px; order: 2; }
.store-btn span { order: 3; flex-basis: 100%; }
.store-btn:hover { box-shadow: inset 0 0 0 1px var(--gold); }
.gate .sheet { box-shadow: var(--shadow); }
@media (max-width: 480px) { .top-in { gap: 8px; } .brand { gap: 8px; } .home-btn img { height: 22px; } .crumb-store { padding-left: 8px; } .crumb-store b { font-size: 15px; } .langs button { padding: 4px 7px; font-size: 12px; } }

/* Owner dashboard on the admin home */
.home:has(.dash) { max-width: 1000px; }
.dash { display: flex; flex-direction: column; gap: 12px; }
.dash-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 12px; padding-bottom: 10px; border-bottom: 1px solid var(--line); position: relative; }
.dash-head::after { content: ""; position: absolute; left: 0; bottom: -1px; width: 48px; height: 2px; background: var(--gold); }
.dash-head h2 { font-family: var(--f-display); font-size: 24px; font-weight: 600; }
.dash-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 400px), 1fr)); gap: 12px; }
.d-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: 16px 18px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.d-card .group-title { margin: 0; }
.d-card .tbl-wrap { margin: 0; box-shadow: none; }
.d-store { display: flex; flex-direction: column; gap: 6px; padding-bottom: 10px; border-bottom: 1px dashed var(--line); }
.d-store:last-child { border-bottom: 0; padding-bottom: 0; }
.d-store > b { font-family: var(--f-display); font-size: 17px; font-weight: 600; }
.d-meter { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 10px; align-items: center; font-size: 13px; }
.d-meter .chk-bar { height: 6px; }
.d-mv { font-size: 12px; color: var(--muted); }
.d-alert { font-size: 13px; font-weight: 600; color: var(--bad); }
.d-big { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.d-big b { font-family: var(--f-display); font-size: 30px; font-weight: 600; }
.d-chg { font: 600 13px var(--f-mono); }
.d-chg.up { color: var(--bad); } .d-chg.down { color: var(--ok); }
.d-sub { font-size: 12px; font-weight: 600; color: var(--muted); margin-top: 4px; }
.d-list { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 4px; font-size: 14px; }
.d-list li > span:first-child { margin-right: 8px; }
.d-list li .num { color: var(--muted); font-size: 12px; margin-right: 6px; }
.d-meter .chk-bar { grid-column: auto; }
.d-card th, .d-card td { white-space: normal; }
.shell:has(> nav.tabs[hidden]) { grid-template-columns: minmax(0, 1fr); }
.d-saved { grid-column: 1 / -1; font-size: 12px; font-weight: 600; color: var(--ok); }
/* day notes and past days, under the checklists */
.notes-card, .hist { border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); box-shadow: var(--shadow); margin-bottom: 18px; padding: 14px 16px 16px; display: grid; gap: 8px; min-width: 0; }
.notes-card h3, .hist h3 { margin: 0; font-size: 16px; }
.notes-card > .note, .hist > .note { margin: 0; }
.notes { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.notes li { background: var(--sunk); border-radius: 10px; padding: 10px 12px; display: grid; gap: 4px; }
.notes li p { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.note-pic img { max-width: min(100%, 240px); border-radius: 8px; display: block; }
.notes li .note { display: flex; gap: 10px; align-items: center; }
.linkish { border: 0; background: none; padding: 0; color: var(--bad); font-size: 12px; text-decoration: underline; cursor: pointer; }
.note-form { display: grid; gap: 8px; }
.note-form textarea { width: 100%; box-sizing: border-box; font: inherit; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--sunk); color: var(--ink); resize: vertical; }
.note-form .btn { justify-self: end; }
.h-row { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; width: 100%; border: 0; border-top: 1px solid var(--line); background: transparent; text-align: left; padding: 10px 0; color: var(--ink); font-size: 13px; }
.h-row b { font-size: 14px; min-width: 92px; }
.h-part { color: var(--bad); }
.h-part.ok { color: var(--ok); }
.h-n { color: var(--umber); }
.h-detail { display: grid; gap: 8px; padding-bottom: 10px; }
.h-detail .note { margin: 0; }
/* closing photos: example next to today's shot */
.ph-head { display: flex; justify-content: space-between; }
.ph-bulk { display: grid; gap: 8px; padding: 4px 14px 10px; }
.ph-bulk p { margin: 0; }
.ph-bulk-btn { cursor: pointer; justify-self: start; font-size: 15px; padding: 12px 18px; }
.ph-bulk-btn[aria-busy] { opacity: .75; cursor: progress; }
.ph-alldone { color: var(--ok); font-weight: 600; font-size: 14px; }
.ph-left { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); gap: 8px; }
.ph-left figure { margin: 0; display: grid; gap: 6px; min-width: 0; }
.ph-left img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 8px; background: var(--sunk); }
.ph-left select { width: 100%; min-width: 0; }
.ph-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 10px; padding: 4px 14px 14px; }
.ph-slot { border: 1px solid var(--line); border-radius: 12px; padding: 10px; display: grid; gap: 8px; background: var(--surface); min-width: 0; }
.ph-slot.ok { border-color: var(--ok); }
.ph-slot b { font-size: 14px; }
.ph-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ph-pair figure { margin: 0; display: grid; gap: 4px; min-width: 0; }
.ph-pair img, .ph-empty { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 8px; background: var(--sunk); display: block; }
.ph-empty { display: grid; place-items: center; font-size: 12px; color: var(--muted); text-align: center; padding: 6px; box-sizing: border-box; }
.ph-empty.today { border: 2px dashed var(--line); background: transparent; }
.ph-pair figcaption { font-size: 11px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ph-acts { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.ph-acts label.btn { cursor: pointer; }
.ai-body { white-space: pre-wrap; margin: 4px 0 0; font-size: 14px; }
.cash-count { display: grid; gap: 6px; padding: 8px 0; border-top: 1px solid var(--line); }
.cash-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; }
.cc-box { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; margin: 6px 0 12px; background: #f3faf2; }
.cc-box.bad { background: #fdf0ef; border-color: #e6a6a0; }
.cc-box h4 { margin: 0 0 2px; }
.cc-row { display: grid; grid-template-columns: 6.5em 1fr auto; gap: 8px; align-items: baseline; padding: 5px 0; border-top: 1px dashed var(--line); }
.cc-row .num { font-weight: 600; overflow-wrap: anywhere; }
.cc-mark { font-weight: 700; }
.cc-row.ok .cc-mark { color: #2e7d32; }
.cc-row.bad .cc-mark, .cc-row.bad .num { color: #c62828; }
.cash-tbl { border-collapse: collapse; font-size: 14px; }
.cash-tbl th, .cash-tbl td { padding: 3px 12px 3px 0; text-align: right; }
.cash-tbl th:first-child, .cash-tbl td:first-child { text-align: left; }
.h-pics { display: grid; grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)); gap: 6px; }
.h-pics a { display: grid; gap: 2px; color: var(--muted); font-size: 11px; text-decoration: none; min-width: 0; }
.h-pics img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 6px; background: var(--sunk); }
.h-pics span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* drinks used without a sale (purchases tab) */
.use { border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); box-shadow: var(--shadow); margin-bottom: 18px; padding: 14px 16px 16px; display: grid; gap: 10px; min-width: 0; }
.use h3 { margin: 0; font-size: 16px; }
.use h4 { margin: 10px 12px 4px; font-size: 13px; color: var(--muted); }
.use > .note { margin: 0; }
.use-form { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); gap: 10px; align-items: end; }
.use-form .use-item, .use-form .use-note { grid-column: span 2; }
@media (max-width: 480px) { .use-form .use-item, .use-form .use-note { grid-column: 1 / -1; } }
.use-form input, .use-form select { width: 100%; box-sizing: border-box; }
.use-acts { grid-column: 1 / -1; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.use .tbl-wrap { margin: 0; box-shadow: none; }
.use-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.use-list li { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; padding: 8px 0; border-top: 1px solid var(--line); font-size: 14px; }
.use-list .note { margin-left: auto; display: flex; gap: 8px; }
.pages { display: flex; gap: 10px; overflow-x: auto; }
.pages .page { margin: 0; display: grid; gap: 4px; flex: 0 0 auto; max-width: min(100%, 320px); }
.pages .page figcaption { display: flex; justify-content: space-between; font-size: 13px; }
.pages > a { flex: 0 0 auto; max-width: min(100%, 320px); }
.note.warn { color: var(--bad); }
#pc-box .row-actions input { flex: 1; min-width: 10rem; }
#pc-code b { font-size: 1.4rem; letter-spacing: .08em; }
/* number screens: viewer watermark, no long-press saving without download rights */
/* The tilted watermark is bigger than its host; clip it so the page never grows sideways on a phone. */
.wm-host { position: relative; overflow: clip; }
html, body { overflow-x: clip; }
/* iPhone zooms the page into any field under 16px and leaves it zoomed; keep fields at 16px on phones. */
@media (max-width: 760px) { input, select, textarea, table input, table select, label.f input, label.f select, label.f textarea, .sm-select, .inline-in { font-size: 16px; } }
.wm { position: absolute; inset: 0; overflow: hidden; pointer-events: none; display: flex; flex-wrap: wrap; align-content: flex-start; gap: 56px 40px; padding: 24px; transform: rotate(-18deg) scale(1.3); opacity: .09; color: var(--ink, #000); font-size: 13px; font-weight: 600; white-space: nowrap; z-index: 5; user-select: none; }
.no-save img { -webkit-touch-callout: none; -webkit-user-drag: none; user-select: none; }
.no-save { -webkit-user-select: none; user-select: none; }
.no-save input, .no-save textarea, .no-save select { -webkit-user-select: text; user-select: text; }
.logo-text { font-size: 1.4rem; letter-spacing: .02em; }
.dep-sheet { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-start; margin: 6px 0 10px; }
.dep-sheet .tbl-wrap { min-width: 0; }
.cash-tbl tfoot th { border-top: 1px solid var(--line, #ddd); padding-top: 6px; }
.dep-pics { display: flex; gap: 8px; flex-wrap: wrap; }
.dep-pics img { width: 140px; max-width: 100%; border-radius: 8px; display: block; }
.stock .st-in { width: 5.5em; text-align: right; font: inherit; padding: 2px 4px; }
.st-tbl th:first-child, .st-tbl td:first-child { position: sticky; left: 0; background: var(--surface); z-index: 1; }
.st-tbl thead th:first-child { z-index: 2; }
.st-now { font-weight: 600; }
.st-short { color: var(--bad, #c0392b); font-weight: 600; }
.st-over { color: #b7791f; font-weight: 600; }
.st-even { color: var(--ok); font-weight: 600; }
.st-sheet .st-tbl { font-size: 14px; }
/* Month sheet: six columns that fit a phone, no sideways scroll, no sticky column (it slid out of line on iPhone, 11-03). */
.st-sheet .st-tbl { width: 100%; table-layout: fixed; }
.st-sheet .st-tbl th, .st-sheet .st-tbl td { padding: 8px 6px; }
.st-sheet .st-tbl th:first-child, .st-sheet .st-tbl td:first-child { position: static; width: 32%; }
.st-sheet .st-tbl thead th, .st-sheet .st-tbl tfoot th { background: var(--sunk); }
.st-sheet .st-tbl td.st-gap { white-space: normal; line-height: 1.2; }
.st-sheet .st-wait { font-size: 11px; font-weight: 500; color: var(--muted); white-space: normal; }
.st-sheet .st-tbl thead th { position: static; white-space: normal; line-height: 1.25; vertical-align: bottom; }
.st-sheet .st-tbl td:first-child { overflow-wrap: anywhere; }
.st-sheet .st-tbl tr.st-hasrm td { border-bottom: 0; padding-bottom: 2px; }
.st-sheet .st-rmrow td { font-size: 12px; color: var(--muted); padding-top: 0; }
@media (max-width: 480px) { .st-sheet .st-tbl { font-size: 13px; } .st-sheet .st-tbl th { font-size: 11px; } .st-sheet .st-tbl th, .st-sheet .st-tbl td { padding: 7px 4px; } .st-sheet .st-gap { font-size: 13px; } }
.st-sheet .st-gap { font-size: 15px; }
.st-rm { font-size: 12px; color: var(--muted); min-width: 14em; }
.st-ph .ph-slot a { display: block; }
.st-shot { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 8px; background: var(--sunk); display: block; }
.st-detail > summary { cursor: pointer; font-weight: 600; padding: 4px 0; }
.st-detail[open] > summary { margin-bottom: 10px; }

/* roster (근무표) */
.rs-days { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 14px; }
.rs-day { flex: none; display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 52px; padding: 8px 10px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); color: var(--ink); font-size: 14px; }
.rs-day .rs-w { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.rs-day.today { border-color: var(--accent); }
.rs-day[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.rs-day[aria-pressed="true"] .rs-w { color: var(--accent-ink); }
.rs-all { justify-content: center; }
.rs-cards { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.rs-row { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding: 6px 0; border-top: 1px solid var(--line); }
.rs-row:first-of-type { border-top: 0; }
.rs-t { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; font: 13px var(--f-mono); }
.rs-shift { white-space: nowrap; }
.rs-tag { margin-left: 6px; font-size: 11px; font-weight: 500; color: var(--warn); background: var(--warn-soft); border-radius: 999px; padding: 1px 7px; }
.rs-offs { font-size: 13px; color: var(--bad); }
.rs-tbl { font-size: 12px; }
.rs-tbl th, .rs-tbl td { text-align: center; padding: 6px 5px; white-space: nowrap; }
.rs-tbl tbody th { text-align: left; position: sticky; left: 0; background: var(--surface); z-index: 1; }
.rs-tbl th.today { color: var(--accent); }


/* roster colours: solid fills with white text read the same in light and dark */
.tone-full { --rs: #1f7a5c; --rs-ink: #fff; }
.tone-lunch { --rs: #f2b705; --rs-ink: #2a1d00; }
.tone-dinner { --rs: #2f5fb3; --rs-ink: #fff; }
.tone-dish { --rs: #7a4fb0; --rs-ink: #fff; }
.tone-agency { --rs: #f07800; --rs-ink: #fff; }
.tone-sup { --rs: #6b4fbb; --rs-ink: #fff; }
.tone-vac { --rs: #ffd84d; --rs-ink: #3a2a00; }
.rs-tbl td.tone-sup { font-family: inherit; font-size: 11px; }
.rs-tbl td.on { background: var(--rs); color: var(--rs-ink); font-family: var(--f-mono); font-weight: 600; border: 2px solid var(--surface); }
.rs-tbl td.off { background: #d64541; color: #fff; font-weight: 700; border: 2px solid var(--surface); }
.rs-tbl tr.rs-grp th { text-align: left; background: var(--rs); color: var(--rs-ink); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; position: static; }
.rs-card { border-left: 6px solid var(--rs); }
.rs-card .group-title { display: flex; align-items: center; gap: 8px; color: var(--ink); font-weight: 700; }
.rs-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--rs); flex: none; }
.rs-shift { background: var(--rs); color: var(--rs-ink); border-radius: 6px; padding: 2px 8px; font-weight: 600; }
.rs-offs { font-weight: 600; }
.rs-tag { color: #fff; background: #f07800; }
.tone-need { --rs: #3a3a3a; --rs-ink: #fff; }
.rs-full { display: block; font-size: 11px; font-weight: 400; color: var(--muted); }
.rs-tbl td.need { font-weight: 700; font-family: var(--f-mono); color: #fff; border: 2px solid var(--surface); }
/* 11-07: over = red, short = green, exact = grey */
.rs-tbl td.need.even { background: #6b7280; }
.rs-tbl td.need.over { background: #d64541; }
.rs-tbl td.need.short { background: #1f9d55; }
.rs-tbl td.on.rs-over, .rs-shift.rs-over { background: #f28b82 !important; color: #5c0a06 !important; }
.rs-tbl td.on.rs-conf { background: #ffe94d !important; color: #3a2a00 !important; }
.rs-tbl td.on.rs-tentc { background: repeating-linear-gradient(45deg, var(--rs), var(--rs) 6px, transparent 6px, transparent 10px); opacity: .75; }
.rs-tent { display: inline-block; margin-left: 4px; font-size: 10px; padding: 0 5px; border-radius: 4px; border: 1px dashed currentColor; color: var(--muted, #888); }
.rs-tbl td.pt { font-family: var(--f-mono); font-size: 11px; color: var(--ink); }
.rs-need { font-weight: 700; border-radius: 6px; padding: 2px 8px; color: #fff; font-size: 13px; }
.rs-need.even { background: #6b7280; }
.rs-need.over { background: #d64541; }
.rs-need.short { background: #1f9d55; }

/* Week roster fits the phone width: no sideways scroll, so names and colour bands never slide apart (한수님 11-03). */
@media (max-width: 640px) {
  .rs-wrap { overflow-x: hidden; }
  .rs-tbl { table-layout: fixed; width: 100%; min-width: 0; font-size: 10px; letter-spacing: -.02em; }
  .rs-tbl col.rs-name { width: 22%; }
  .rs-tbl th, .rs-tbl td { padding: 4px 1px; white-space: normal; overflow-wrap: anywhere; line-height: 1.25; }
  .rs-tbl tbody th, .rs-tbl tfoot th { position: static; padding-left: 6px; font-size: 11px; }
  .rs-tbl td.on, .rs-tbl td.off, .rs-tbl td.need { border-width: 1px; }
  .rs-tbl td.pt { font-size: 9px; }
  .rs-tbl tr.rs-grp th { padding: 5px 6px; font-size: 11px; }
  .rs-tbl .rs-full { font-size: 9px; }
  .rs-tbl .rs-tag { display: inline-block; margin: 2px 0 0; font-size: 9px; padding: 0 5px; }
}

/* Lunch and dinner tables, with a role tag beside each name (한수님 11-03). */
.rs-wrap + .rs-wrap { margin-top: 4px; }
.rs-tbl tr.rs-meal th { font-size: 15px; padding: 9px 10px; letter-spacing: .06em; }
.rs-kind { display: inline-block; margin-left: 6px; font-size: 10px; font-weight: 700; border-radius: 999px; padding: 1px 6px; vertical-align: 1px; color: #fff; white-space: nowrap; }
.rs-kind.k-full { background: #1f7a5c; }
.rs-kind.k-part { background: #6b6b6b; }
.rs-kind.k-agency { background: #f07800; }
@media (max-width: 640px) {
  .rs-tbl .rs-kind { display: table; margin: 2px 0 0; font-size: 9px; padding: 0 5px; }
  .rs-tbl tr.rs-meal th { font-size: 13px; padding: 7px 6px; }
}
.rs-tbl { table-layout: fixed; }
.rs-tbl col.rs-name { width: 190px; }
@media (max-width: 640px) { .rs-tbl col.rs-name { width: 22%; } }
@media (max-width: 640px) { .rs-tbl .rs-kind { line-height: 1.5; overflow-wrap: normal; word-break: keep-all; } }
@media (max-width: 640px) { .rs-tbl th .rs-kind { display: inline-block; margin: 2px 0 0; padding: 1px 6px; font-size: 9px; line-height: 1.3; letter-spacing: 0; } }
/* Role tag in its own column (한수님 11-03). */
.rs-tbl col.rs-kcol { width: 88px; }
.rs-tbl td.rs-kc { padding: 4px 2px; }
.rs-tbl td.rs-kc .rs-kind { margin: 0; }
.rs-tbl th.rs-kh { font-size: 11px; }
@media (max-width: 640px) {
  .rs-tbl col.rs-name { width: 19%; }
  .rs-tbl col.rs-kcol { width: 13%; }
  .rs-tbl td.rs-kc .rs-kind { display: inline-block; font-size: 8.5px; padding: 1px 4px; margin: 0; line-height: 1.3; letter-spacing: 0; word-break: keep-all; }
  .rs-tbl th.rs-kh { font-size: 9px; }
}
@media (max-width: 640px) { .rs-tbl col.rs-name { width: 18%; } .rs-tbl col.rs-kcol { width: 12%; } .rs-tbl td.on, .rs-tbl td.need { white-space: nowrap; font-size: 9.5px; letter-spacing: -.05em; padding: 4px 0; } }
@media (max-width: 640px) { .rs-tbl col.rs-name { width: 17%; } .rs-tbl col.rs-kcol { width: 13%; } .rs-tbl td.rs-kc { padding: 4px 1px; } .rs-tbl td.rs-kc .rs-kind { font-size: 8px; padding: 1px 3px; letter-spacing: -.03em; } }

/* Thin visible grid on every roster cell (한수님 11-03). */
:root { --rs-grid: #b9ad9a; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --rs-grid: #5a4e43; } }
:root[data-theme="dark"] { --rs-grid: #5a4e43; }
.rs-tbl { border-collapse: collapse; }
.rs-tbl th, .rs-tbl td,
.rs-tbl td.on, .rs-tbl td.off, .rs-tbl td.need { border: 1px solid var(--rs-grid); }
@media (max-width: 640px) { .rs-tbl td.on, .rs-tbl td.off, .rs-tbl td.need { border-width: 1px; } }

/* Softer roster colours: same hues, one step calmer (한수님 11-03). */
.tone-full { --rs: #4f9479; --rs-ink: #fff; }
.tone-lunch { --rs: #ebc85e; --rs-ink: #3a2c05; }
.tone-dinner { --rs: #5d80c0; --rs-ink: #fff; }
.tone-dish { --rs: #9479bb; --rs-ink: #fff; }
.tone-agency { --rs: #e5955a; --rs-ink: #fff; }
.tone-need { --rs: #5c5753; --rs-ink: #fff; }
.rs-tbl td.off { background: #d9716d; }
.rs-tbl td.need.ok, .rs-need.ok, .rs-kind.k-full { background: #4f9479; }

.rs-kind.k-part { background: #8a8580; }
.rs-kind.k-agency, .rs-tag { background: #e5955a; }

/* Full-time and part-time each boxed (한수님 11-03). */
:root { --rs-box: #6f6457; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --rs-box: #a39482; } }
:root[data-theme="dark"] { --rs-box: #a39482; }
.rs-tbl tbody.rs-box { border: 2.5px solid var(--rs-box); }
.rs-tbl tr.rs-sub th { background: var(--sunk); color: var(--ink); font-size: 11px; font-weight: 700; text-align: left; padding: 4px 8px; letter-spacing: .04em; }

/* Calmer still: muted, slightly greyed fills. */
.tone-full { --rs: #6a9a86; --rs-ink: #fff; }
.tone-lunch { --rs: #dcc27a; --rs-ink: #3a2c05; }
.tone-dinner { --rs: #7389b5; --rs-ink: #fff; }
.tone-dish { --rs: #9a87b8; --rs-ink: #fff; }
.tone-agency { --rs: #d9a072; --rs-ink: #fff; }
.tone-need { --rs: #6b6662; --rs-ink: #fff; }
.rs-tbl td.off { background: #cf8582; }
.rs-tbl td.need.ok, .rs-need.ok, .rs-kind.k-full { background: #6a9a86; }

.rs-kind.k-part { background: #96918c; }
.rs-kind.k-agency, .rs-tag { background: #d9a072; }

/* Meal name sits in the date header; role column (홀 / 디쉬워셔) after the name (한수님 11-03). */
.rs-tbl thead th.rs-meal-h { background: var(--rs); color: var(--rs-ink); font-size: 15px; font-weight: 800; letter-spacing: .06em; text-align: left; padding-left: 10px; text-transform: uppercase; }
.rs-tbl col.rs-rcol { width: 64px; }
.rs-tbl td.rs-rc { font-size: 11px; font-weight: 500; color: var(--ink); padding: 4px 2px; }
@media (max-width: 640px) {
  .rs-tbl col.rs-name { width: 15%; }
  .rs-tbl col.rs-rcol { width: 9%; }
  .rs-tbl col.rs-kcol { width: 12%; }
  .rs-tbl thead th.rs-meal-h { font-size: 12px; padding-left: 5px; }
  .rs-tbl td.rs-rc { font-size: 8.5px; padding: 3px 1px; line-height: 1.2; word-break: keep-all; }
  .rs-tbl td.rs-kc .rs-kind { font-size: 7.5px; padding: 1px 2px; }
}
/* Hall / kitchen switch at the top of the roster. */
.rs-sec { display: inline-flex; gap: 0; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; margin-bottom: 12px; background: var(--surface); }
.rs-sec-b { border: 0; background: transparent; color: var(--ink); font: inherit; font-weight: 700; font-size: 14px; padding: 8px 22px; cursor: pointer; }
.rs-sec-b[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink, #fff); }
.rs-notes { margin: 4px 0 18px; padding: 12px 14px 12px 30px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); font-size: 13px; color: var(--ink); display: grid; gap: 4px; }
/* Narrower name column, names centred (한수님 11-03). */
.rs-tbl col.rs-name { width: 130px; }
.rs-tbl tbody th { text-align: center; }
.rs-tbl thead th.rs-meal-h { text-align: center; padding-left: 4px; }
@media (max-width: 640px) { .rs-tbl col.rs-name { width: 15%; } .rs-tbl tbody th { padding-left: 2px; padding-right: 2px; } }
/* A shift wraps after its dash only when the column is too narrow for it. */
.rs-tbl td.on { white-space: normal; overflow-wrap: normal; word-break: keep-all; }
@media (max-width: 640px) { .rs-tbl td.on { white-space: normal; } }

/* Owner signal board: one row per store, red first */
.sig { width: 100%; border-collapse: collapse; font-size: 13px; }
.sig th, .sig td { padding: 6px 4px; text-align: center; border-bottom: 1px solid var(--line); }
.sig thead th { font-size: 11px; font-weight: 600; color: var(--muted); }
.sig tbody th { text-align: left; font-weight: 600; white-space: nowrap; }
.sig-urg { display: inline-block; margin-left: 6px; padding: 1px 6px; border-radius: 99px; background: var(--bad); color: #fff; font-size: 11px; }
.sig-dot { min-width: 44px; min-height: 30px; padding: 2px 6px; border-radius: 99px; border: 1px solid transparent; font: 600 12px var(--f-mono, inherit); cursor: pointer; background: var(--line); color: var(--muted); }
.sig-dot.ok { background: var(--ok-soft); color: var(--ok); }
.sig-dot.warn { background: var(--warn-soft); color: var(--warn); }
.sig-dot.bad { background: var(--bad); color: #fff; }
.acct-rows { display: flex; flex-direction: column; gap: 6px; }
.acct-row { display: grid; grid-template-columns: 84px minmax(0, 1fr) auto 52px; gap: 8px; align-items: center; font-size: 13px; }
.acct-row .chk-bar { height: 6px; }
.acct-row .num { font-size: 12px; color: var(--muted); }
.acct-row .d-chg { text-align: right; }
@media (max-width: 480px) { .acct-row { grid-template-columns: 70px minmax(0, 1fr) 46px; } .acct-row .num { grid-column: 2 / -1; grid-row: 2; } }
.acct-row .chk-bar { grid-column: auto; }
.sig-dot { min-width: 34px; }
.sig-why { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 3px; font-size: 12px; }
.sig-why li.bad { color: var(--bad); } .sig-why li.warn { color: var(--warn); }
.sig-why:empty { display: none; }
.sig tbody th { white-space: normal; min-width: 84px; font-size: 12px; }
.sig th, .sig td { padding: 5px 2px; }
/* cost control (원가 관리) */
.cc-checks ul { margin: 0; padding-left: 18px; display: grid; gap: 6px; }
.cc-checks li.cc-bad { color: var(--bad); font-weight: 600; }
.cc-checks li.cc-warn { color: var(--ink); }
.cc-checks li.cc-ok { color: var(--muted); }
.kpi small.cc-up { color: var(--bad); display: block; }
.kpi small.cc-down { color: var(--ok); display: block; }
.kpi small { display: block; }
.tbl tr.sum td { font-weight: 700; border-top: 2px solid var(--line); }
.tbl tr.cc-off td { opacity: .45; }
.cc-num { width: 84px; text-align: right; }
.cc-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; margin-bottom: 18px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 10px; }
.cc-card h3 { margin: 0; }
.cc-card .note { margin: 0; }
.cc-card > .btn { align-self: flex-start; }

/* role boards (11-07): SV progress grid, orders, manager to-do */
.dash + .dash { margin-top: 24px; }
.lnk { background: none; border: 0; padding: 0; font: inherit; color: inherit; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.ord-form textarea { width: 100%; }
.ord-row { display: flex; flex-wrap: wrap; gap: 8px 12px; }
.wk-tbl { width: 100%; border-collapse: collapse; font-size: 13px; }
.wk-tbl th, .wk-tbl td { text-align: center; padding: 4px 2px; border-bottom: 1px solid var(--line); }
.wk-tbl tbody th { text-align: left; font-weight: 600; white-space: nowrap; padding-right: 8px; }
.wk-tbl td.wk { font-weight: 700; font-family: var(--f-mono); }
.wk-tbl td.ok { color: #1f7a5c; }
.wk-tbl td.bad { color: #fff; background: #d64541; }
.wk-tbl td.warn { color: #3a2a00; background: #ffd84d; }
.ord-list, .todo-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.ord { border: 1px solid var(--line); border-left: 4px solid var(--line); border-radius: 8px; padding: 8px 10px; display: flex; flex-direction: column; gap: 6px; }
.ord.bad { border-left-color: #d64541; } .ord.warn { border-left-color: #f0a500; } .ord.done { border-left-color: #2f6fd6; } .ord.ok { border-left-color: #1f7a5c; opacity: .7; }
.ord-h { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: baseline; }
.ord-st { font-size: 12px; font-weight: 700; padding: 1px 8px; border-radius: 99px; background: var(--line); }
.ord-st.bad { background: #d64541; color: #fff; } .ord-st.warn { background: #ffe9a8; color: #5a3d00; } .ord-st.done { background: #dbe7fb; color: #173f86; } .ord-st.ok { background: #d7efe5; color: #135241; }
.ord-b { margin: 0; white-space: pre-wrap; }
.ord-done { margin: 0; font-size: 13px; color: #135241; }
.todo { display: grid; grid-template-columns: 24px 1fr auto; gap: 8px; align-items: center; }
.todo-m { font-weight: 700; text-align: center; border-radius: 99px; width: 22px; height: 22px; line-height: 22px; font-size: 12px; background: var(--line); }
.todo.ok .todo-m { background: #1f7a5c; color: #fff; } .todo.bad .todo-m { background: #d64541; color: #fff; }
.todo-l { display: flex; flex-direction: column; }
.leak td { vertical-align: top; }
.leak-n { display: block; font-size: 11px; line-height: 1.3; color: var(--muted, #6b6b6b); margin-top: 3px; }
.leak th, .leak td { min-width: 0; padding-left: 2px; padding-right: 2px; text-align: center; }
.leak tbody th { text-align: left; }
.leak .sig-dot { cursor: default; }
.leak .sig-dot { display: inline-flex; align-items: center; justify-content: center; }

/* Staff needed vs rostered (한수님 11-07): over = red, short = green, exact = grey.
   Red part-time cell = extra staff that day; yellow = confirmed part-timer; hatched = not confirmed (not counted). */
.rs-tbl td.need.even, .rs-need.even { background: #8a8580; }
.rs-tbl td.need.over, .rs-need.over { background: #d64541; }
.rs-tbl td.need.short, .rs-need.short { background: #2e9d5b; }
.rs-tbl td.on.rs-over, .rs-shift.rs-over { background: #e05a52 !important; color: #fff !important; }
.rs-tbl td.on.rs-conf { background: #ffe94d !important; color: #3a2a00 !important; }
.rs-tbl td.on.rs-tentc { background: repeating-linear-gradient(45deg, #ece8e2, #ece8e2 6px, #fff 6px, #fff 11px) !important; color: #6b6662 !important; opacity: 1; }

/* A day with a note (e.g. 대체휴무 public holiday, 한수님 11-08). */
.rs-tbl th.rs-hol, .rs-holn { color: #d64541; }
.rs-holn { display: block; font-size: 10px; font-weight: 700; }

/* 선금 (customer prepaid credit), 11-09 */
.cr-card { display: grid; gap: 12px; }
.cr-head h3 { margin: 0 0 6px; }
.cr-sum { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 14px; }
.cr-sum b { font-family: var(--f-mono); }
.cr-left b { font-size: 18px; color: var(--accent); }
.cr-lines { flex-direction: column; gap: 4px; }
.cr-two { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.cr-box { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border: 1px solid var(--line, #ddd); border-radius: 10px; min-width: 0; }
.cr-box b { font-family: var(--f-mono); font-size: 18px; }
.cr-box small { font-size: 12px; opacity: .75; }
.cr-note { margin: 0; font-size: 12px; color: var(--muted, #777); }
.cr-acts { display: flex; flex-wrap: wrap; gap: 8px; }
.cr-read { border-radius: 8px; padding: 10px 12px; display: grid; gap: 8px; border: 2px solid; }
.cr-read.ok { border-color: #2e9d5b; background: rgba(46,157,91,.08); }
.cr-read.bad { border-color: #d64541; background: rgba(214,69,65,.08); }
.cr-read.new { border-color: #e5955a; background: rgba(229,149,90,.08); }
.cr-form { display: grid; gap: 8px; }
.cr-form label { display: grid; gap: 2px; font-size: 12px; }
.cr-tbl td.num { text-align: right; font-family: var(--f-mono); }
.cr-tbl tr.cr-dep td { font-weight: 700; }
/* Photo viewer over the page (ENT receipts, cost photos) */
.pv { position: fixed; inset: 0; z-index: 30; background: rgba(0,0,0,.88); display: flex; align-items: center; justify-content: center; padding: calc(48px + env(safe-area-inset-top, 0px)) 12px calc(16px + env(safe-area-inset-bottom, 0px)); }
.pv img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 6px; background: #fff; touch-action: pinch-zoom; }
.pv-x { position: absolute; top: calc(8px + env(safe-area-inset-top, 0px)); right: 12px; width: 40px; height: 40px; border-radius: 20px; border: 0; background: rgba(255,255,255,.18); color: #fff; font-size: 20px; }
/* 매출 관리 (11-11) */
.sls-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 4px 0 12px; }
.sls-tbl td.note { text-align: left; }

/* 11-19: the viewer's name over every screen for everyone (stampAll in app.js) */
#wm-all.wm { position: fixed; inset: -20vh -20vw; z-index: 60; opacity: .07; }
@media print { #wm-all.wm { position: absolute; } }

/* 점장 보고 (11-19) */
.rep-form { display: grid; gap: 10px; }
.rep-form label { display: grid; gap: 4px; font-weight: 600; font-size: 14px; }
.rep-form textarea { min-height: 72px; }
.rep-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.rep-days label { font-weight: 500; font-size: 12px; text-align: center; }
.rep-days input { width: 100%; min-width: 0; text-align: right; padding: 6px 4px; }
.rep-days small { color: var(--muted, #777); font-weight: 400; }
@media (max-width: 520px) { .rep-days { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.rep-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.rep-list li { border: 1px solid var(--line, #ddd); border-radius: 10px; padding: 10px 12px; display: grid; gap: 4px; }
.rep-list li.open { border-left: 4px solid var(--red, #c0392b); }
.rep-list li.done { border-left: 4px solid var(--green, #2e7d32); }
.rep-list .rep-meta { font-size: 12px; color: var(--muted, #777); }
.rep-list b { font-size: 13px; }
.rep-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
/* CEO: today at a glance (11-19) */
.ceo-sum { margin: 0 0 10px; padding: 8px 12px; border-radius: 10px; font-weight: 700; }
.ceo-sum.ok { background: var(--ok-soft); color: var(--ok); } .ceo-sum.bad { background: var(--warn-soft); color: var(--bad); }
.ceo-list { display: flex; flex-direction: column; gap: 8px; }
.ceo-row { border: 1px solid var(--line); border-radius: 12px; padding: 10px; display: flex; flex-direction: column; gap: 8px; background: var(--card, transparent); }
.ceo-row.has-bad { border-color: var(--bad); }
.ceo-row.off { flex-direction: row; justify-content: space-between; align-items: center; opacity: .6; }
.ceo-cells { display: grid; grid-template-columns: repeat(auto-fit, minmax(64px, 1fr)); gap: 6px; }
.ceo-cell { display: flex; flex-direction: column; align-items: center; gap: 2px; min-height: 48px; padding: 6px 4px; border-radius: 10px; border: 2px solid transparent; background: var(--line); color: var(--muted); cursor: pointer; font: inherit; }
.ceo-cell.ok { background: var(--ok-soft); color: var(--ok); } .ceo-cell.warn { background: var(--warn-soft); color: var(--warn); } .ceo-cell.bad { background: var(--bad); color: #fff; }
.ceo-cell.sel { border-color: currentColor; box-shadow: 0 0 0 2px var(--bg, #fff) inset; }
.ceo-k { font-size: 11px; font-weight: 600; } .ceo-v { font-size: 15px; font-weight: 700; }
.ceo-detail { border-top: 1px dashed var(--line); padding-top: 8px; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.ceo-detail p { margin: 0; } .ceo-detail.bad > p:first-of-type { color: var(--bad); font-weight: 600; }
.ceo-left { margin: 0; padding-left: 18px; font-size: 13px; display: flex; flex-direction: column; gap: 2px; }
.ceo-txt { white-space: pre-wrap; font-size: 13px; }

.sup-folder { display: flex; align-items: center; gap: 10px; width: 100%; padding: 14px 4px; text-align: left; text-decoration: none; }
.sup-folder .sf-name { font-weight: 700; flex: 1; min-width: 0; overflow-wrap: anywhere; }
.sup-folder .sf-meta { color: var(--muted, inherit); white-space: nowrap; font-variant-numeric: tabular-nums; }
.sup-inner { margin: 0 0 8px 22px; border-left: 2px solid var(--line); border-top: 0; padding-left: 10px; }
.brand-card-title { margin: 0; color: var(--gold, #c9a227); font-size: 1rem; letter-spacing: .12em; position: relative; }
/* In-app camera for invoices (11-25) */
.cam { position: fixed; inset: 0; z-index: 1000; background: #000; display: flex; flex-direction: column; }
.cam-video { flex: 1; min-height: 0; width: 100%; object-fit: contain; background: #000; }
.cam-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px max(16px, env(safe-area-inset-right, 0px)) calc(16px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); background: #000; }
.cam-shoot { width: 72px; height: 72px; border-radius: 50%; border: 5px solid #fff; background: #fff; box-shadow: inset 0 0 0 4px #000; cursor: pointer; }
.cam-shoot:active { transform: scale(.94); }
