/* Cricket Mechanic — taken from the logo: black, cricket-ball red, brushed silver, willow wood.
   Amber marks warnings so they never get mixed up with the brand red. */
:root {
  --bg: #F4F5F7;
  --surface: #FFFFFF;
  --surface-2: #F7F8FA;
  --ink: #16191D;
  --muted: #5B6470;
  --line: #E2E5EA;
  --line-soft: #EEF0F3;
  --field: #D3D8DF;
  --side: #0B0C0E;
  --side-active: #1F2226;
  --side-ink: #D9DCE0;
  --side-muted: #8B9198;
  --brand: #D11F26;
  --brand-dark: #A3141B;
  --brand-soft: #FDECEC;
  --brand-line: #F6C6C8;
  --wood: #C9A27A;
  --wood-light: #E8C9A0;
  --silver: #C3C8CE;
  --warn-soft: #FFF4DC;
  --warn-line: #F3DDA6;
  --warn-ink: #7A4F00;
  --pos: #15803D;
  --pos-soft: #E6F4EA;
  --pos-ink: #14532D;
  --neg: #B42318;
  --neg-soft: #FDECEA;
  --neg-ink: #8A1C12;
  --blue-soft: #E6EEF9;
  --blue-ink: #1E4A85;
  --cost: #3F4650;
  --radius: 16px;
  --side-w: 248px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 15px/1.5 Manrope, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
a { color: var(--brand); }
a:hover { color: var(--brand-dark); }
h1 { font-size: 30px; font-weight: 800; letter-spacing: -0.02em; margin: 0; line-height: 1.2; }
h2, h3 { margin: 0; }
.card h2, .card h3 { font-size: 18px; font-weight: 800; }
.eyebrow, h2.section {
  font-size: 13px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); margin: 0;
}
h2.section { margin: 30px 0 12px; }
.muted, .muted-row td { color: var(--muted); }
.small { font-size: 13px; }
.nowrap { white-space: nowrap; }
.r { text-align: right; }
.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.pos { color: var(--pos); }
.neg { color: var(--neg); }
.mt { margin-top: 24px; }
.print-only { display: none; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- shell ---------- */
.sidebar {
  position: fixed; inset: 0 auto 0 0; width: var(--side-w); overflow-y: auto; z-index: 30;
  background: var(--side); color: var(--side-ink); padding: 22px 14px 20px;
  display: flex; flex-direction: column; gap: 2px;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: #fff; }
.brand:hover { color: #fff; }
.brand .logo { width: 38px; height: 38px; flex: none; }
.brand span { display: flex; flex-direction: column; line-height: 1.2; }
.brand strong { font-size: 16px; font-weight: 800; letter-spacing: -0.01em; }
.brand small { font-size: 12px; color: #A3ADB8; }
.sidebar > .brand { padding: 4px 10px 20px; }
.brand-img { display: block; line-height: 0; }
.sidebar > .brand-img { margin: -8px -4px 6px; }
.brand-img img { width: 100%; height: auto; border-radius: 10px; }
.topbar .brand-img img { width: auto; height: 46px; }
.sidebar { border-right: 1px solid #1A1C20; }
.sidebar > .brand-img + .nav-group { padding-top: 6px; }
.nav-group { font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--side-muted); padding: 16px 12px 6px; }
.sidebar > a:not(.brand):not(.brand-img) {
  display: flex; align-items: center; gap: 12px; min-height: 40px; padding: 0 12px; border-radius: 10px;
  color: var(--side-ink); text-decoration: none; font-weight: 500;
}
.sidebar > a:not(.brand):not(.brand-img):hover { background: #17191C; color: #fff; }
.sidebar > a.active { background: var(--side-active); color: #fff; font-weight: 800; box-shadow: inset 3px 0 0 var(--brand); }
.sidebar > a.active svg { color: #FF5A5F; }
.badge { margin-left: auto; background: var(--brand); color: #fff; font-size: 12px; font-weight: 700; border-radius: 99px; padding: 0 8px; }
.avatar { width: 36px; height: 36px; flex: none; border-radius: 50%; background: var(--wood-light); color: var(--side); display: flex; align-items: center; justify-content: center; font-weight: 800; }
.nav-foot { margin-top: auto; padding: 22px 10px 0; display: flex; align-items: center; gap: 10px; font-size: 14px; }
.nav-foot > span:last-child { display: flex; flex-direction: column; line-height: 1.3; }
.nav-foot strong { color: #fff; }
.nav-foot a { color: #A3ADB8; font-size: 12px; }
.topbar, .tabbar, .nav-scrim { display: none; }

.main { padding: 32px clamp(16px, 3vw, 44px) 64px; max-width: 1320px; }
.has-nav .main { margin-left: var(--side-w); }

@media (max-width: 900px) {
  .topbar {
    display: flex; align-items: center; justify-content: space-between; position: sticky; top: 0; z-index: 20;
    background: var(--side); padding: 10px 16px;
  }
  .topbar .logo { width: 32px; height: 32px; }
  .sidebar { transform: translateX(-100%); transition: transform .2s ease; width: 280px; padding-bottom: 90px; }
  .navtoggle:checked ~ .sidebar { transform: none; box-shadow: 8px 0 30px rgba(0,0,0,.25); }
  .navtoggle:checked ~ .nav-scrim { display: block; position: fixed; inset: 0; z-index: 25; background: rgba(0,0,0,.35); }
  .has-nav .main { margin-left: 0; padding: 18px 16px 110px; }
  .tabbar {
    display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); position: fixed; inset: auto 0 0 0; z-index: 20;
    background: var(--surface); border-top: 1px solid var(--line); padding: 4px 4px calc(8px + env(safe-area-inset-bottom));
  }
  .tabbar a, .tabbar label {
    min-height: 54px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
    font-size: 11px; font-weight: 600; color: var(--muted); text-decoration: none; cursor: pointer;
  }
  .tabbar a.active { color: var(--brand); font-weight: 800; }
  h1 { font-size: 26px; }
}

/* ---------- building blocks ---------- */
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.page-head > div:first-child { display: flex; flex-direction: column; gap: 4px; }
.page-head p { margin: 0; max-width: 720px; font-size: 14px; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; }
.back { text-decoration: none; font-size: 14px; font-weight: 700; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 22px; margin-bottom: 20px; }
.card-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 14px; }
.card-head a { font-size: 14px; font-weight: 700; text-decoration: none; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 440px), 1fr)); gap: 20px; margin-bottom: 20px; align-items: start; }
.grid-2 > .card { margin-bottom: 0; }
.stack { display: flex; flex-direction: column; gap: 20px; }
.stack > .card { margin-bottom: 0; }
.empty { text-align: center; padding: 40px 18px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: 12px;
  border: 1px solid var(--field); background: var(--surface); color: var(--ink);
  font: inherit; font-weight: 700; text-decoration: none; cursor: pointer; white-space: nowrap;
}
.btn:hover { border-color: var(--muted); color: var(--ink); }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.primary:hover { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; }
.btn.ghost { background: transparent; }
.btn.danger { color: var(--neg); border-color: var(--neg); background: transparent; }
.btn.small { min-height: 36px; padding: 0 12px; font-size: 14px; border-radius: 10px; }
.btn.block { width: 100%; }
.btn.icon { width: 44px; padding: 0; }

.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 12px; margin-bottom: 20px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; display: flex; flex-direction: column; gap: 3px; }
.kpi > span { color: var(--muted); font-size: 13px; font-weight: 600; }
.kpi strong { font-size: 26px; font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.kpi small { color: var(--muted); font-size: 13px; }
.kpi small a { text-decoration: none; font-weight: 700; }
.kpi.dark { background: var(--side); border-color: var(--side); color: #fff; }
.kpi.dark > span, .kpi.dark small { color: #A3ADB8; }
.kpi.dark { box-shadow: inset 0 -3px 0 var(--brand); }
.kpi.dark a { color: #FF8A8E; }
.kpi.dark .pos { color: #4ADE80; }
.kpi.dark .neg { color: #FF8A8E; }
.kpi.warn { background: var(--warn-soft); border-color: var(--warn-line); }
.kpi.warn > span, .kpi.warn strong { color: var(--warn-ink); }
.kpi.loss { border: 2px solid var(--neg); padding: 15px 17px; }

.flash { padding: 12px 16px; border-radius: 12px; margin: 0 0 16px; background: var(--pos-soft); color: var(--pos-ink); font-weight: 600; }
.flash-err { background: var(--neg-soft); color: var(--neg-ink); }
.note { display: flex; gap: 10px; align-items: flex-start; background: var(--warn-soft); color: var(--warn-ink); padding: 12px 14px; border-radius: 12px; font-size: 14px; margin: 14px 0 0; }
.note svg { flex: none; margin-top: 2px; }

.pill { display: inline-block; padding: 2px 10px; border-radius: 99px; font-size: 12px; font-weight: 700; background: #F1F2F4; color: #4A515B; white-space: nowrap; }
.pill-ok, .pill-delivered, .pill-working, .pill-active, .pill-ready, .pill-paid { background: var(--pos-soft); color: var(--pos-ink); }
.pill-delivered { background: #F1F2F4; color: #4A515B; }
.pill-off, .pill-left, .pill-inactive { background: #F1F2F4; color: var(--muted); }
.pill-low, .pill-received { background: var(--warn-soft); color: var(--warn-ink); }
.pill-in-progress, .pill-in-making { background: var(--blue-soft); color: var(--blue-ink); }
.pill-ordered { background: var(--warn-soft); color: var(--warn-ink); }

/* customer message page */
.msg-card textarea { font-size: 15px; line-height: 1.5; resize: vertical; background: var(--surface-2); }
.msg-card.first { border-color: var(--brand-line); }
.btn.wa { background: #1FA855; border-color: #1FA855; color: #fff; }
.btn.wa:hover { background: #178A45; border-color: #178A45; color: #fff; }
.placeholders { font-size: 13px; color: var(--muted); }
code { background: #ECEEF1; border-radius: 6px; padding: 1px 6px; font-size: 13px; color: var(--ink); }
.field small { font-size: 12px; font-weight: 500; }
.pill-loss { background: var(--neg-soft); color: var(--neg-ink); }
.pill-profit { background: var(--pos-soft); color: var(--pos-ink); }

/* bars & charts */
.bar { height: 12px; background: var(--line-soft); border-radius: 99px; overflow: hidden; }
.bar > span { display: block; height: 100%; border-radius: 99px; background: var(--pos); }
.bar.thin { height: 6px; }
.bar.cost > span { background: var(--cost); }
.meter { display: flex; flex-direction: column; gap: 6px; }
.meter-top { display: flex; justify-content: space-between; gap: 12px; font-weight: 700; font-variant-numeric: tabular-nums; }
.split { display: flex; height: 14px; border-radius: 99px; overflow: hidden; gap: 2px; }
.split.tall { height: 40px; border-radius: 12px; gap: 3px; font-size: 13px; font-weight: 800; }
.split.tall > span { display: flex; align-items: center; padding: 0 12px; white-space: nowrap; overflow: hidden; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13px; color: #3C434C; margin-top: 8px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.dot { width: 10px; height: 10px; border-radius: 3px; display: inline-block; flex: none; }
.c0 { background: #0B0C0E; color: #fff; } .c1 { background: #D11F26; color: #fff; } .c2 { background: #C9A27A; color: #0B0C0E; } .c3 { background: #6B7280; color: #fff; }
.c-co { background: #C3C8CE; color: #0B0C0E; }

.daychart { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 4px; align-items: end; height: 170px; border-bottom: 1px solid var(--field); }
.daychart span { display: block; background: var(--pos); border-radius: 5px 5px 0 0; min-height: 3px; }
.daychart span.zero { background: var(--field); }
.daychart span.today { background: var(--brand); }
.daylabels { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 4px; font-size: 11px; font-weight: 600; color: var(--muted); text-align: center; margin-top: 6px; }

.hero { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 28px; }
.hero-num { font-size: 44px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.hero .meters { display: flex; flex-direction: column; gap: 16px; justify-content: center; }
.divider { border-top: 1px solid var(--line-soft); margin: 22px 0 18px; }

.status-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; text-align: center; margin-bottom: 12px; }
.status-grid div { border-radius: 12px; padding: 10px 4px; font-size: 12px; font-weight: 600; }
.status-grid strong { display: block; font-size: 22px; color: var(--ink); }

.rowlist { display: flex; flex-direction: column; gap: 10px; }
.rowitem { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; text-decoration: none; color: var(--ink); }
a.rowitem:hover { border-color: var(--field); background: var(--surface-2); color: var(--ink); }
.rowitem .grow { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.rowitem .end { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; font-variant-numeric: tabular-nums; }
.rowitem small { font-size: 13px; color: var(--muted); }
.leftbox { width: 44px; height: 44px; flex: none; border-radius: 12px; background: var(--warn-soft); color: var(--warn-ink); display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1; }
.leftbox strong { font-size: 18px; }
.leftbox span { font-size: 10px; font-weight: 700; }
.datebox { width: 44px; flex: none; text-align: center; line-height: 1.1; }
.datebox strong { display: block; font-size: 18px; }
.datebox span { font-size: 11px; font-weight: 700; color: var(--muted); text-transform: uppercase; }
.lines .rowitem { border: 0; border-top: 1px solid var(--line-soft); border-radius: 0; padding: 10px 0; }

/* ---------- tables ---------- */
.table-wrap { overflow-x: auto; }
.table-wrap.card { padding: 0; overflow: hidden; }
.table-wrap.card > table { min-width: 640px; }
.table-scroll { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: 14px; font-variant-numeric: tabular-nums; }
table.data th, table.data td { padding: 12px; border-bottom: 1px solid var(--line-soft); text-align: left; vertical-align: middle; }
table.data th.r, table.data td.r { text-align: right; }
table.data thead th { font-size: 12px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); font-weight: 700; white-space: nowrap; background: var(--surface-2); border-bottom: 1px solid var(--line); }
table.data th:first-child, table.data td:first-child { padding-left: 20px; }
table.data th:last-child, table.data td:last-child { padding-right: 20px; }
table.data tfoot td { border-top: 2px solid var(--field); border-bottom: 0; font-weight: 800; }
table.data tbody tr[data-href] { cursor: pointer; }
table.data tbody tr[data-href]:hover, table.data tbody tr[data-href]:focus { background: var(--surface-2); outline: none; }
table.data tr.current td { background: var(--brand-soft); }
.card table.compact thead th { background: transparent; border-bottom: 1px solid var(--line); }
.card table.compact th, .card table.compact td { padding: 10px 8px; }
.card table.compact th:first-child, .card table.compact td:first-child { padding-left: 0; }
.card table.compact th:last-child, .card table.compact td:last-child { padding-right: 0; }

.statement { display: flex; flex-direction: column; font-variant-numeric: tabular-nums; }
.statement .row { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0 8px 14px; border-bottom: 1px solid var(--line-soft); }
.statement .head { display: flex; justify-content: space-between; padding: 18px 0 6px; border-bottom: 2px solid var(--ink); font-weight: 800; }
.statement .head:first-child { padding-top: 4px; }
.statement .head span:first-child { font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; }
.statement .total { display: flex; justify-content: space-between; align-items: center; margin-top: 14px; padding: 16px 18px; border-radius: 14px; background: var(--pos-soft); font-weight: 800; }
.statement .total.loss { background: var(--neg-soft); }
.statement .total strong:last-child { font-size: 24px; }

.share-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.share-cards div { border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; }
.share-cards span { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 700; }
.share-cards strong { font-size: 20px; font-variant-numeric: tabular-nums; }

.trend a { display: grid; grid-template-columns: 110px minmax(0, 1fr) 120px; gap: 16px; align-items: center; padding: 12px 14px; border-radius: 14px; text-decoration: none; color: var(--ink); }
.trend a:hover { background: var(--surface-2); color: var(--ink); }
.trend a.current { background: var(--bg); }
.trend .bars { display: flex; flex-direction: column; gap: 6px; }
.trend .bars span { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.trend .bars i { display: block; height: 10px; border-radius: 99px; background: var(--pos); }
.trend .bars i.cost { background: var(--cost); }
@media (max-width: 560px) { .trend a { grid-template-columns: 1fr; gap: 6px; } }

.partner-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 16px; margin-bottom: 20px; }
.partner-cards .card { margin: 0; display: flex; flex-direction: column; gap: 14px; font-variant-numeric: tabular-nums; }
.partner-cards .who { display: flex; align-items: center; gap: 12px; }
.partner-cards .who .avatar { width: 44px; height: 44px; font-size: 18px; }
.partner-cards .who span:last-child { display: flex; flex-direction: column; line-height: 1.25; }
.kv { display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.kv div { display: flex; justify-content: space-between; gap: 12px; }
.kv div span:first-child { color: var(--muted); }
.kv.sep { border-top: 1px solid var(--line-soft); padding-top: 12px; }
.kv .hl { background: var(--pos-soft); border-radius: 10px; padding: 8px 10px; margin-top: 4px; }
.kv .hl.loss { background: var(--neg-soft); }
.kv .hl span:first-child { color: var(--ink); font-weight: 800; }

/* ---------- forms ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; margin-bottom: 16px; }
.filters label { display: flex; flex-direction: column; font-size: 12px; font-weight: 700; color: var(--muted); gap: 4px; }
.filters .grow { flex: 1 1 220px; }
input, select, textarea {
  font: inherit; color: var(--ink); background: var(--surface); width: 100%;
  border: 1px solid var(--field); border-radius: 10px; padding: 10px 12px; min-height: 46px;
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--brand); outline-offset: -1px; border-color: transparent; }
.filters input, .filters select { width: auto; min-width: 150px; min-height: 44px; }
.filters .grow input { width: 100%; }

.form .grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 16px 18px; }
.field { display: flex; flex-direction: column; gap: 5px; }
.field > span { font-size: 13px; font-weight: 700; }
.field.wide { grid-column: 1 / -1; }
.req { color: var(--neg); font-weight: 700; }
.money-input { display: flex; align-items: center; border: 1px solid var(--field); border-radius: 10px; background: var(--surface); }
.money-input:focus-within { outline: 2px solid var(--brand); outline-offset: -1px; border-color: transparent; }
.money-input span { padding: 0 0 0 12px; color: var(--muted); font-weight: 700; }
.money-input input { border: 0; outline: none; }
.form-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line-soft); }
.record-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.preview { background: var(--surface-2); border-radius: 14px; padding: 14px 16px; margin-top: 18px; display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-variant-numeric: tabular-nums; max-width: 420px; }
.preview div { display: flex; justify-content: space-between; gap: 12px; }
.preview div:last-child { border-top: 1px solid var(--line); padding-top: 6px; font-weight: 800; }
.form-stack { display: flex; flex-direction: column; gap: 12px; max-width: 380px; }

.auth { max-width: 400px; margin: 9vh auto 0; display: flex; flex-direction: column; gap: 16px; padding: 28px; }
.who-pick { display: flex; flex-direction: column; gap: 10px; }
.who-pick .btn { justify-content: flex-start; min-height: 56px; font-size: 16px; }
.who-pick .avatar { width: 34px; height: 34px; }
.auth-logo { background: #0B0C0E; border-radius: 14px; margin: -10px -10px 4px; overflow: hidden; line-height: 0; }
.auth-logo img { width: 100%; height: auto; }
.auth p { margin: 0; }
body.bare { background: var(--side); }
body.bare .main { padding: 16px; }

.month-nav { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.month-nav h1 { min-width: 200px; text-align: center; }
.month-nav input { width: auto; min-height: 44px; }
.detail-links { display: flex; gap: 8px; flex-wrap: wrap; }
.explain { margin: 0; padding-left: 18px; }
.explain li { margin-bottom: 6px; }

/* ---------- print ---------- */
@media print {
  .sidebar, .topbar, .tabbar, .no-print, .flash { display: none !important; }
  .print-only { display: block; }
  .has-nav .main { margin: 0; padding: 0; max-width: none; }
  body { background: #fff; color: #000; font-size: 12px; }
  .card, .kpi { border-color: #ccc; break-inside: avoid; }
}

.stock-id { font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.stock-price { min-width: 120px; max-width: 170px; font-variant-numeric: tabular-nums; text-align: right; }
.inventory-table .data th { text-transform: none; letter-spacing: 0; }
.inventory-table .data td { font-variant-numeric: tabular-nums; }
.inventory-table .data td:first-child { min-width: 180px; }
.stock-name { white-space: normal; max-width: 240px; line-height: 1.4; margin-top: 4px; }
.price-form .form-actions { margin-bottom: 24px; }
.stock-help { margin-top: 24px; }
.stock-help summary { cursor: pointer; font-weight: 700; }
.stock-help p { max-width: 70ch; }
.inventory-summary.kpis { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.inventory-summary .kpi { padding: 12px 16px; min-height: 0; }
.inventory-summary .kpi strong { font-size: 24px; line-height: 1.25; }
.stock-search { margin-bottom: 8px; }
.stock-more { margin: 0 0 16px; }
.stock-more summary { cursor: pointer; font-size: 14px; font-weight: 600; margin-bottom: 12px; }
.inventory-table .data td:first-child,.inventory-table .data th:first-child { position: sticky; left: 0; background: #fff; z-index: 1; }
.sticker-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(220px,1fr)); gap: 16px; }
.stock-sticker { background: #fff; color: #0b0c0e; border: 1px solid #d7d8db; padding: 16px; min-height: 142px; break-inside: avoid; }
.sticker-shop { font-size: 12px; font-weight: 600; }
.sticker-id { display: block; font-size: 23px; font-weight: 800; line-height: 1.3; margin: 6px 0; font-variant-numeric: tabular-nums; }
.sticker-name { font-size: 13px; line-height: 1.4; overflow-wrap: anywhere; }
.sticker-price { font-size: 16px; font-weight: 700; margin-top: 6px; }
@media (max-width: 640px) { .stock-price { min-height: 44px; } .sticker-grid { grid-template-columns: 1fr; } }
@media print {
 @page { size: A4; margin: 10mm; }
 body:has(.sticker-grid) { background: #fff; color: #000; }
 body:has(.sticker-grid) .page-head,body:has(.sticker-grid) .sidebar,body:has(.sticker-grid) .topbar,body:has(.sticker-grid) .tabbar,body:has(.sticker-grid) .flash { display: none !important; }
 body:has(.sticker-grid) .main { margin: 0 !important; padding: 0 !important; max-width: none !important; }
 .sticker-grid { grid-template-columns: repeat(3,60mm); gap: 2mm; }
 .stock-sticker { width: 60mm; height: 32mm; min-height: 0; box-sizing: border-box; padding: 2.5mm; border: 0.2mm solid #bbb; }
 .sticker-shop { font-size: 7pt; }.sticker-id { font-size: 14pt; margin: 1mm 0; }.sticker-name { font-size: 8pt; line-height: 1.2; }.sticker-price { font-size: 10pt; margin-top: 1mm; }
}
