:root {
  --brand: #3a2219;
  --brand-deep: #2a1811;
  --brand-tint: #f3ebe6;
  --crust: #e3a640;
  --crust-deep: #b97c1c;
  --ground: #edf2ef;
  --paper: #ffffff;
  --well: #f5f8f6;
  --ink: #1f1a17;
  --ink-2: #463f3a;
  --ink-3: #6a625c;
  --line: #d5ded9;
  --line-soft: #e6ece8;
  --t-info: #8a5426;
  --t-info-bg: #f6ebe0;
  --t-ok: #4e7a1c;
  --t-ok-bg: #e9f1dc;
  --t-wait: #6a4c9c;
  --t-wait-bg: #efe9f8;
  --t-bad: #ab2843;
  --t-bad-bg: #fbe7eb;
  --t-neutral: #5a6862;
  --t-neutral-bg: #e8eeeb;
  --r: 10px;
  --r-lg: 14px;
  --f-ui: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-hand: "Kalam", "Segoe Print", cursive;
  --s-1: 12.5px;
  --s-2: 14px;
  --s-3: 16px;
  --s-4: 24px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { font-family: var(--f-ui); font-size: var(--s-2); line-height: 1.5; color: var(--ink); background: var(--ground); font-variant-numeric: tabular-nums; }
::selection { background: var(--crust); color: var(--brand-deep); }
a { color: var(--t-info); text-underline-offset: 3px; }
button, input, select, textarea { font: inherit; color: inherit; }
input, textarea { caret-color: var(--crust-deep); }
:focus-visible { outline: 2px solid var(--crust); outline-offset: 2px; }
html { scrollbar-color: #b9c6bf transparent; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #b9c6bf; border-radius: 10px; border: 2px solid var(--ground); }
::-webkit-scrollbar-track { background: transparent; }
svg.i { width: 16px; height: 16px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* Kerangka */
.app { min-height: 100vh; display: flex; flex-direction: column; }
.bar { background: var(--brand); color: #f3e9e1; position: sticky; top: 0; z-index: 10; }
.bar-top { display: flex; align-items: center; gap: 12px; padding: 10px 28px; }
.logo { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; margin-right: 8px; }
.logo-mark { width: 34px; height: 34px; padding: 5px; border-radius: 50%; background: var(--crust); stroke: var(--brand); fill: none; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.logo b { display: block; font-size: var(--s-3); font-weight: 700; letter-spacing: -.01em; line-height: 1.15; }
.logo small { display: block; font-size: var(--s-1); color: #d9c3b4; }
.search { flex: 1; max-width: 420px; margin-left: auto; display: flex; align-items: center; gap: 8px; height: 36px; padding: 0 12px; border-radius: 999px; background: rgba(255, 255, 255, .1); color: #d9c3b4; }
.search:focus-within { background: #fff; color: var(--ink-3); }
.search input { border: 0; background: transparent; outline: none; width: 100%; font-size: var(--s-1); color: inherit; }
.search input::placeholder { color: inherit; opacity: .85; }
.search:focus-within input { color: var(--ink); }
.sample { font-size: var(--s-1); font-weight: 600; color: var(--brand-deep); background: var(--crust); border-radius: 999px; padding: 3px 10px; white-space: nowrap; }
.rolesw { display: flex; align-items: center; gap: 8px; font-size: var(--s-1); color: #d9c3b4; }
.rolesw .sel { height: 36px; border-color: transparent; background-color: rgba(255, 255, 255, .1); color: #fff; font-weight: 600; max-width: 280px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23f3e9e1' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); }
.rolesw .sel option { color: var(--ink); }
.bar .iconbtn { background: rgba(255, 255, 255, .1); border-color: transparent; color: #f3e9e1; }
.bar .iconbtn:hover { background: rgba(255, 255, 255, .18); }
.me { display: flex; align-items: center; gap: 9px; color: #fff; text-decoration: none; cursor: pointer; padding-left: 4px; min-width: 0; }
.me-t b { display: block; font-size: var(--s-1); font-weight: 600; white-space: nowrap; }
.me-t small { display: block; font-size: var(--s-1); color: #d9c3b4; white-space: nowrap; max-width: 180px; overflow: hidden; text-overflow: ellipsis; }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--crust); color: var(--brand-deep); display: grid; place-items: center; font-weight: 700; font-size: var(--s-1); flex: none; }
.modnav { display: flex; gap: 4px; padding: 0 20px; overflow-x: auto; scrollbar-width: none; }
.modnav::-webkit-scrollbar { display: none; }
.modnav .ng { display: flex; gap: 2px; }
.modnav .ng + .ng { margin-left: 10px; padding-left: 12px; position: relative; }
.modnav .ng + .ng::before { content: ""; position: absolute; left: 0; top: 12px; bottom: 14px; width: 1px; background: rgba(243, 233, 225, .22); }
.modnav a { display: flex; align-items: center; gap: 7px; padding: 10px 10px 12px; color: #e3d2c6; text-decoration: none; font-size: var(--s-1); font-weight: 600; white-space: nowrap; border-bottom: 3px solid transparent; }
.modnav a:hover { color: #fff; }
.modnav a.on { color: #fff; border-bottom-color: var(--crust); }
.modnav a .n { font-size: 11.5px; font-weight: 700; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--crust); color: var(--brand-deep); display: grid; place-items: center; }
.crumbs { padding: 16px 28px 0; font-size: var(--s-1); color: var(--ink-3); }
.crumbs b { color: var(--ink); font-weight: 600; }
.page { padding: 10px 28px 48px; display: flex; flex-direction: column; gap: 18px; min-width: 0; }

/* Kepala halaman dan kontrol */
.head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 4px; }
.head h1 { font-size: var(--s-4); font-weight: 700; letter-spacing: -.02em; line-height: 1.2; text-wrap: balance; }
.head p { color: var(--ink-3); font-size: var(--s-2); margin-top: 4px; max-width: 72ch; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.btn { display: inline-flex; align-items: center; gap: 7px; height: 38px; padding: 0 15px; border-radius: var(--r); border: 1px solid var(--line); background: var(--paper); color: var(--ink); font-weight: 600; font-size: var(--s-1); cursor: pointer; text-decoration: none; white-space: nowrap; transition: background .15s, border-color .15s, color .15s; }
.btn:hover { border-color: #a9b8b0; background: var(--well); }
.btn.pri { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.pri:hover { background: var(--brand-deep); border-color: var(--brand-deep); }
.btn.ok { background: var(--t-ok); border-color: var(--t-ok); color: #fff; }
.btn.ok:hover { filter: brightness(1.08); }
.btn.danger { border-color: #e6b4bf; color: var(--t-bad); background: var(--paper); }
.btn.danger:hover { background: var(--t-bad); border-color: var(--t-bad); color: #fff; }
.btn.sm { height: 32px; padding: 0 12px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.sel, .inp { height: 36px; border: 1px solid var(--line); border-radius: var(--r); background: var(--paper); padding: 0 12px; font-size: var(--s-1); color: var(--ink); }
.inp:focus, .sel:focus { border-color: var(--crust-deep); outline: none; box-shadow: 0 0 0 3px rgba(227, 166, 64, .25); }
.inp::placeholder { color: #958b84; }
.sel { padding-right: 30px; appearance: none; background: var(--paper) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236a625c' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 11px center; }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.tabs a { padding: 7px 14px; border-radius: 999px; font-weight: 600; font-size: var(--s-1); color: var(--ink-2); text-decoration: none; background: var(--paper); border: 1px solid var(--line); display: flex; gap: 7px; align-items: center; white-space: nowrap; }
.tabs a:hover { border-color: #a9b8b0; }
.tabs a.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.tabs a .c { font-size: 11.5px; font-weight: 700; color: inherit; opacity: .75; }
.iconbtn { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line); background: var(--paper); display: grid; place-items: center; color: var(--ink-2); position: relative; cursor: pointer; }
.iconbtn:hover { border-color: #a9b8b0; }
.iconbtn.sm { width: 32px; height: 32px; border-radius: var(--r); }
.iconbtn.del:hover { color: var(--t-bad); border-color: var(--t-bad); }
.iconbtn .dot { position: absolute; top: 7px; right: 8px; width: 8px; height: 8px; border-radius: 50%; background: var(--crust); box-shadow: 0 0 0 2px var(--brand); }

/* Status */
.st { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px 0 8px; border-radius: 999px; font-size: var(--s-1); font-weight: 600; white-space: nowrap; background: var(--t-neutral-bg); color: var(--t-neutral); }
.st::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.st.info { background: var(--t-info-bg); color: var(--t-info); }
.st.ok { background: var(--t-ok-bg); color: var(--t-ok); }
.st.wait { background: var(--t-wait-bg); color: var(--t-wait); }
.st.bad { background: var(--t-bad-bg); color: var(--t-bad); }
.st.ghost { background: transparent; color: var(--ink-3); box-shadow: inset 0 0 0 1px var(--line); }
.code { font-weight: 600; font-size: var(--s-2); color: var(--ink); white-space: nowrap; font-variant-numeric: tabular-nums slashed-zero; }
a.code { color: var(--t-info); text-decoration: none; }
a.code:hover { text-decoration: underline; }
.muted { color: var(--ink-3); }
.num { text-align: right; white-space: nowrap; }
.urgent { display: inline-flex; align-items: center; gap: 5px; font-size: var(--s-1); font-weight: 700; color: var(--t-bad); }
.urgent::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--t-bad); }
.req::after { content: " *"; color: var(--t-bad); }

/* Panel dan tabel */
.panel { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); min-width: 0; }
.panel > header { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 16px 18px 12px; }
.panel > header h2 { font-size: var(--s-3); font-weight: 700; letter-spacing: -.01em; }
.panel > header small { display: block; color: var(--ink-3); font-size: var(--s-1); }
.panel .pad { padding: 16px 18px; }
.grid2 { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.grid2.even { grid-template-columns: 1fr 1fr; }
.tablewrap { overflow-x: auto; }
table.t { width: 100%; border-collapse: collapse; font-size: var(--s-2); }
.t th { text-align: left; font-size: var(--s-1); font-weight: 600; color: var(--ink-3); padding: 10px 14px; border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); background: var(--well); white-space: nowrap; }
.t th.num { text-align: right; }
.t td { padding: 11px 14px; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
.t tr:last-child td { border-bottom: 0; }
.t tbody tr:hover td { background: #fbf8f5; }
.t td .sub { display: block; font-size: var(--s-1); color: var(--ink-3); }
.t tfoot td { font-weight: 700; border-top: 1px solid var(--line); background: var(--well); }
.t td .inp, .t td .sel { width: 100%; height: 34px; }
.t td.ctl { padding: 6px 8px; }
.t td .inp.num { text-align: right; }
.t.dense th, .t.dense td { padding-left: 10px; padding-right: 10px; }
.pager { display: flex; justify-content: space-between; align-items: center; padding: 11px 18px; border-top: 1px solid var(--line-soft); font-size: var(--s-1); color: var(--ink-3); }
.pager .pg a { display: inline-grid; place-items: center; min-width: 28px; height: 28px; border-radius: 50%; color: var(--ink-2); text-decoration: none; font-weight: 600; }
.pager .pg a.on { background: var(--brand); color: #fff; }

/* Angka ringkas */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); }
.kpi { padding: 16px 20px; min-width: 0; }
.kpi + .kpi { border-left: 1px solid var(--line-soft); }
.kpi .band { display: none; }
.kpi small { display: flex; align-items: center; gap: 7px; font-size: var(--s-1); color: var(--ink-3); font-weight: 600; }
.kpi small::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--t-neutral); flex: none; }
.kpi.info small::before { background: var(--t-info); }
.kpi.ok small::before { background: var(--t-ok); }
.kpi.wait small::before { background: var(--t-wait); }
.kpi.bad small::before { background: var(--t-bad); }
.kpi b { display: block; font-size: var(--s-4); font-weight: 700; letter-spacing: -.02em; margin-top: 6px; line-height: 1.15; }
.kpi span { display: block; font-size: var(--s-1); color: var(--ink-3); margin-top: 2px; }
.kpi span.up { color: var(--t-bad); font-weight: 600; }
.kpi span.ok { color: var(--t-ok); font-weight: 600; }

/* Etalase bahan baku */
.etalase .case { margin: 0 18px; border-radius: var(--r); background: linear-gradient(180deg, #f8fbfa, #eef4f1); box-shadow: inset 0 0 0 1px #d2ddd7, inset 0 10px 18px -12px rgba(58, 34, 25, .18); padding: 6px 16px 4px; }
.shelf { padding: 12px 0 14px; border-bottom: 5px solid #cdd8d2; box-shadow: 0 1px 0 #fff; position: relative; }
.shelf:last-child { border-bottom-width: 0; box-shadow: none; }
.shelf h3 { font-size: var(--s-1); font-weight: 600; color: var(--ink-3); margin-bottom: 8px; }
.trays { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 12px 10px; }
.tray { position: relative; display: flex; flex-direction: column; gap: 2px; text-decoration: none; color: var(--ink); padding: 6px 6px 4px; border-radius: 8px; transition: background .15s; animation: settle .5s cubic-bezier(.16, 1, .3, 1) backwards; animation-delay: var(--d, 0ms); }
.tray:hover { background: rgba(255, 255, 255, .8); }
.tray .pan { position: relative; display: block; height: 30px; border-radius: 4px 4px 7px 7px; background: linear-gradient(180deg, #a9b4af, #8d9893); padding: 3px; overflow: hidden; }
.tray .dough { position: absolute; left: 3px; bottom: 3px; top: 3px; width: calc((100% - 6px) * var(--fill) / 100); border-radius: 3px 3px 5px 5px; background: linear-gradient(180deg, #f2c56f, #d9952f); box-shadow: inset 0 2px 0 rgba(255, 255, 255, .35); transition: width .6s cubic-bezier(.16, 1, .3, 1); }
.tray .minline { position: absolute; top: 2px; bottom: 2px; left: calc(3px + (100% - 6px) / 2); border-left: 2px dashed rgba(31, 26, 23, .55); }
.tray.low .dough { background: linear-gradient(180deg, #f0d8bd, #d8b28a); }
.tray.empty .dough { display: none; }
.tray b { font-size: var(--s-1); font-weight: 600; line-height: 1.25; margin-top: 5px; }
.tray .lvl { font-size: var(--s-1); color: var(--ink-3); }
.tray .lvl em { font-style: normal; font-weight: 700; color: var(--ink); }
.tray.low .lvl em { color: var(--t-bad); }
.tray .tag { position: absolute; top: -9px; right: -2px; font: 700 15px/1 var(--f-hand); font-style: normal; padding: 3px 8px 2px; border-radius: 3px; background: #fffdf8; box-shadow: 0 1px 2px rgba(31, 26, 23, .18), 0 2px 6px rgba(31, 26, 23, .08); transform: rotate(4deg); }
.tray .tag.restock { color: var(--t-bad); }
.tray .tag.exp { color: var(--t-wait); transform: rotate(-3deg); }
.case-foot { display: flex; gap: 16px; flex-wrap: wrap; padding: 12px 18px 16px; font-size: var(--s-1); color: var(--ink-3); }
.case-foot .sw { display: inline-block; width: 16px; height: 9px; border-radius: 2px 2px 4px 4px; margin-right: 6px; vertical-align: 0; background: linear-gradient(180deg, #f2c56f, #d9952f); }
.case-foot .sw.low { background: linear-gradient(180deg, #f0d8bd, #d8b28a); box-shadow: inset 0 0 0 1.5px var(--t-bad); }
.case-foot .sw.exp { background: var(--t-wait-bg); box-shadow: inset 0 0 0 1.5px var(--t-wait); }
@keyframes settle { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }

/* Legenda, umur */
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: var(--s-1); color: var(--ink-3); }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 6px; vertical-align: -1px; }
.age { display: flex; align-items: center; gap: 8px; min-width: 140px; }
.t .age { min-width: 0; }
.age .bar { height: 6px; border-radius: 999px; background: var(--t-info); }
.age .bar.wait { background: var(--t-wait); }
.age .bar.bad { background: var(--t-bad); }
.age em { font-style: normal; font-size: var(--s-1); font-weight: 600; color: var(--ink-2); }

/* Form */
.form { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field.w2 { grid-column: span 2; }
.field.w4 { grid-column: 1 / -1; }
.field label { font-size: var(--s-1); font-weight: 600; color: var(--ink-2); }
.field .inp, .field .sel { height: 40px; font-size: var(--s-2); }
.field .hint { font-size: var(--s-1); color: var(--ink-3); }
.field .inp.auto { background: var(--well); color: var(--ink-2); font-weight: 600; }
textarea.inp { height: 76px; padding: 9px 12px; resize: vertical; line-height: 1.45; }
.chk { display: flex; gap: 8px; align-items: center; font-size: var(--s-2); }
.chk input { accent-color: var(--brand); width: 16px; height: 16px; }
.totals { margin-left: auto; width: 360px; display: grid; grid-template-columns: 1fr auto; gap: 6px 18px; font-size: var(--s-2); }
.totals .tt { font-weight: 700; font-size: var(--s-3); padding-top: 8px; border-top: 1px solid var(--line); }
.totals .neg { color: var(--t-bad); }

/* Dokumen cetak */
.docwrap { background: #dfe6e2; border-radius: var(--r-lg); padding: 28px; display: flex; justify-content: center; }
.doc { background: #fff; width: 760px; min-height: 980px; padding: 48px 54px; box-shadow: 0 2px 4px rgba(31, 26, 23, .06), 0 14px 34px rgba(31, 26, 23, .12); font-size: 12.5px; color: #1f1a17; }
.doc .lh { display: flex; justify-content: space-between; align-items: center; padding-bottom: 16px; border-bottom: 1px solid #1f1a17; }
.doc .lh .co { display: flex; gap: 14px; align-items: center; }
.doc .lh .co .mk { width: 56px; height: 56px; border-radius: 50%; background: var(--brand); color: var(--crust); display: grid; place-items: center; font-weight: 700; font-size: 16px; }
.doc .lh .co b { font-size: 15px; letter-spacing: .02em; }
.doc .lh .co small { display: block; font-size: 11px; color: #5a524c; max-width: 320px; }
.doc .lh h3 { font-size: 17px; font-weight: 700; letter-spacing: .14em; text-align: right; line-height: 1.25; color: var(--brand); }
.doc .meta { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin: 20px 0; }
.doc .meta dl { display: grid; grid-template-columns: 110px 1fr; gap: 4px 8px; }
.doc .meta dt { color: #6a625c; }
.doc table { width: 100%; border-collapse: collapse; margin-top: 8px; }
.doc th { border-top: 1px solid #1f1a17; border-bottom: 1px solid #1f1a17; font-size: 11px; font-weight: 700; padding: 7px 8px; text-align: left; }
.doc td { border-bottom: 1px solid #e4dfdb; padding: 7px 8px; }
.doc .r { text-align: right; }
.doc .sum { margin: 14px 0 0 auto; width: 300px; display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; }
.doc .sum .tt { font-weight: 700; border-top: 1px solid #1f1a17; padding-top: 6px; }
.doc .terb { margin-top: 18px; padding: 10px 12px; background: #f7f3ef; border-radius: 6px; }
.doc .sign { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 46px; text-align: center; }
.doc .sign div { padding-top: 64px; border-bottom: 1px solid #1f1a17; }
.doc .sign span { display: block; margin-top: 6px; font-size: 11.5px; }
.doc .watermark { font-size: 10.5px; letter-spacing: .12em; color: #9a918b; margin-top: 26px; text-align: center; }

/* Alur, riwayat */
.flow { display: grid; grid-template-columns: repeat(var(--n, 5), minmax(0, 1fr)); }
.flow .stp { position: relative; padding: 4px 12px 4px 0; }
.flow .stp::before { content: ""; position: absolute; top: 15px; left: 26px; right: 4px; height: 2px; background: var(--line); }
.flow .stp:last-child::before { display: none; }
.flow .stp.done::before { background: var(--t-ok); }
.flow .dotx { position: relative; width: 24px; height: 24px; border-radius: 50%; background: var(--paper); border: 2px solid var(--line); z-index: 1; }
.flow .done .dotx { background: var(--t-ok); border-color: var(--t-ok); box-shadow: inset 0 0 0 4px var(--paper); }
.flow .cur .dotx { border-color: var(--crust-deep); background: var(--crust); box-shadow: 0 0 0 5px rgba(227, 166, 64, .25); }
.flow b { display: block; margin-top: 8px; font-size: var(--s-2); }
.flow small { color: var(--ink-3); font-size: var(--s-1); }
.hist .row { display: grid; grid-template-columns: 12px 1fr; gap: 12px; padding: 12px 18px; border-top: 1px solid var(--line-soft); }
.hist .sq { width: 10px; height: 10px; border-radius: 50%; margin-top: 6px; background: var(--t-neutral); }
.hist .sq.ok { background: var(--t-ok); }
.hist .sq.bad { background: var(--t-bad); }
.hist .sq.wait { background: var(--t-wait); }
.hist .sq.info { background: var(--t-info); }
.hist b { font-size: var(--s-2); }
.hist small { display: block; color: var(--ink-3); font-size: var(--s-1); }
.hist q { display: block; margin-top: 6px; padding: 8px 12px; background: var(--well); border-radius: var(--r); font-size: var(--s-1); quotes: none; color: var(--ink-2); }
.steps { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 0; }
.steps .box { display: inline-flex; align-items: center; height: 32px; padding: 0 14px; border-radius: 999px; font-size: var(--s-1); font-weight: 600; background: var(--t-neutral-bg); color: var(--t-neutral); }
.steps .box.info { background: var(--t-info-bg); color: var(--t-info); }
.steps .box.ok { background: var(--t-ok-bg); color: var(--t-ok); }
.steps .box.wait { background: var(--t-wait-bg); color: var(--t-wait); }
.steps .box.bad { background: var(--t-bad-bg); color: var(--t-bad); }
.steps .arrow { width: 20px; height: 2px; background: var(--line); }
.kv { display: grid; grid-template-columns: 150px 1fr; gap: 8px 14px; font-size: var(--s-2); }
.kv dt { color: var(--ink-3); }
.kv dd { font-weight: 600; min-width: 0; overflow-wrap: anywhere; }

/* Pesan */
.note, .err, .okmsg { display: flex; gap: 10px; align-items: flex-start; padding: 12px 16px; border-radius: var(--r); font-size: var(--s-1); }
.note { background: var(--brand-tint); color: var(--brand); }
.note.warn, .err { background: var(--t-bad-bg); color: #861d33; }
.okmsg { background: var(--t-ok-bg); color: #36570f; }
.note svg.i, .err svg.i, .okmsg svg.i { margin-top: 1px; }
.tip { justify-content: space-between; align-items: center; }
.tip > span { flex: 1; }
.tip button { border: 0; background: none; color: inherit; cursor: pointer; padding: 2px; display: grid; }

/* Keputusan */
.decide { display: grid; grid-template-columns: 1fr auto; gap: 16px; align-items: end; }
.decide textarea.inp { height: 64px; width: 100%; }
.decide .actions { flex-wrap: nowrap; }
.decide .actions .gap { width: 40px; flex: none; }

/* Kalender cuti */
.cal { display: grid; grid-template-columns: 170px repeat(14, 1fr); font-size: var(--s-1); }
.cal .h { font-weight: 600; color: var(--ink-3); text-align: center; padding: 6px 0; border-bottom: 1px solid var(--line); }
.cal .h.we { color: var(--t-bad); }
.cal .h.today { color: var(--brand); box-shadow: inset 0 -2px 0 var(--crust); }
.cal .nm { padding: 8px 10px 8px 0; border-bottom: 1px solid var(--line-soft); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal .c { border-bottom: 1px solid var(--line-soft); border-left: 1px solid var(--line-soft); position: relative; min-height: 34px; }
.cal .c.we { background: var(--well); }
.cal .lv { position: absolute; inset: 6px 1px; border-radius: 999px; font-size: 11.5px; font-weight: 600; color: #fff; padding: 3px 8px; white-space: nowrap; overflow: hidden; z-index: 1; text-decoration: none; }

/* Notifikasi */
.notif { position: relative; }
.notif > summary { list-style: none; }
.notif > summary::-webkit-details-marker { display: none; }
.notif .drop { position: absolute; right: 0; top: 44px; width: 380px; background: var(--paper); color: var(--ink); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: 0 4px 10px rgba(31, 26, 23, .08), 0 18px 40px rgba(31, 26, 23, .16); z-index: 20; overflow: hidden; }
.notif .drop header { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--line-soft); }
.notif .drop header button { border: 0; background: none; color: var(--t-info); font-weight: 600; font-size: var(--s-1); cursor: pointer; }
.notif .list { max-height: 420px; overflow-y: auto; }
.notif .it { display: block; padding: 11px 16px 11px 30px; border-bottom: 1px solid var(--line-soft); text-decoration: none; color: var(--ink); position: relative; }
.notif .it:hover { background: var(--well); }
.notif .it.unread::before { content: ""; position: absolute; left: 13px; top: 17px; width: 8px; height: 8px; border-radius: 50%; background: var(--crust-deep); }
.notif .it b { display: block; font-size: var(--s-1); font-weight: 600; }
.notif .it span { display: block; font-size: var(--s-1); color: var(--ink-3); margin-top: 1px; }
.notif .it em { font-size: 11.5px; color: var(--ink-3); font-style: normal; }

/* Pengaturan */
.swatches { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.swatches button { width: 30px; height: 30px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px var(--line); cursor: pointer; }
.swatches button.on { box-shadow: 0 0 0 2px var(--ink); }
.swatches input[type="color"] { width: 44px; height: 34px; border: 1px solid var(--line); border-radius: var(--r); background: #fff; padding: 2px; cursor: pointer; }
.brandprev { display: flex; align-items: center; gap: 10px; padding: 12px 14px; background: var(--brand); border-radius: var(--r); color: #f3e9e1; }
.brandprev .mark { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 700; font-size: var(--s-1); }
.brandprev b { display: block; color: #fff; }
.brandprev small { color: #d9c3b4; font-size: var(--s-1); }
.stepedit { display: grid; grid-template-columns: 1fr 1fr 1fr 32px; gap: 8px; align-items: center; }

/* Modal, toast */
dialog.modal { margin: auto; border: 1px solid var(--line); border-radius: var(--r-lg); padding: 0; width: min(620px, calc(100vw - 32px)); box-shadow: 0 24px 60px rgba(31, 26, 23, .3); color: var(--ink); }
dialog.modal::backdrop { background: rgba(42, 24, 17, .45); }
dialog.modal > form > header { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--line-soft); }
dialog.modal h2 { font-size: var(--s-3); }
dialog.modal .pad { padding: 18px; display: flex; flex-direction: column; gap: 14px; }
dialog.modal footer { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 18px; border-top: 1px solid var(--line-soft); background: var(--well); border-radius: 0 0 var(--r-lg) var(--r-lg); }
dialog.modal .form { grid-template-columns: 1fr 1fr; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 90; background: var(--brand); color: #fff; padding: 11px 18px; border-radius: 999px; font-size: var(--s-1); box-shadow: 0 4px 10px rgba(31, 26, 23, .15), 0 14px 32px rgba(31, 26, 23, .25); display: flex; gap: 10px; align-items: center; max-width: calc(100vw - 32px); animation: rise .25s cubic-bezier(.16, 1, .3, 1); }

.stack { display: flex; flex-direction: column; gap: 18px; }
.empty { text-align: center; padding: 40px 20px; color: var(--ink-3); }
.fade-in { animation: rise .3s cubic-bezier(.16, 1, .3, 1); }
@keyframes rise { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { *, *::before { animation: none !important; transition: none !important; } }

@media (max-width: 1280px) {
  .me-t, .rolesw > span { display: none; }
}
@media (max-width: 1100px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpi:nth-child(3) { border-left: 0; }
  .kpi:nth-child(n+3) { border-top: 1px solid var(--line-soft); }
  .grid2, .grid2.even { grid-template-columns: 1fr; }
  .form { grid-template-columns: 1fr 1fr; }
  .decide { grid-template-columns: 1fr; }
  .prgrid { grid-template-columns: 1fr !important; }
  .sample { display: none; }
}
@media (max-width: 760px) {
  .bar-top { flex-wrap: wrap; padding: 10px 16px; gap: 10px; }
  .me { display: none; }
  .logo { margin-right: auto; }
  .search { order: 5; flex-basis: 100%; max-width: none; margin-left: 0; }
  .rolesw .sel { max-width: 170px; }
  .modnav { padding: 0 8px; }
  .crumbs { padding: 14px 16px 0; }
  .page { padding: 10px 16px 32px; }
  .head h1 { font-size: 21px; }
  .form { grid-template-columns: 1fr; }
  .field.w2 { grid-column: auto; }
  .etalase .case { margin: 0 12px; padding: 4px 10px; }
  .trays { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .doc { width: 100%; padding: 22px; min-height: 0; }
  .docwrap { padding: 10px; }
  .doc .meta { grid-template-columns: 1fr; }
  .panel > .pad:has(> .flow) { overflow-x: auto; }
  .flow.auto { min-width: calc(var(--n, 5) * 116px); }
  .notif .drop { position: fixed; left: 12px; right: 12px; width: auto; top: 120px; }
  .stepedit { grid-template-columns: 1fr 1fr; }
  .totals { width: 100%; }
  .decide .actions { flex-wrap: wrap; }
  .decide .actions .gap { width: 100%; height: 0; }
  .tabs { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
}
@page { size: A4; margin: 0; }
@media print {
  .bar, .crumbs, .head .actions, .noprint, .demo-top { display: none !important; }
  body { background: #fff; }
  .page { padding: 0; }
  .docwrap { background: none; padding: 0; border-radius: 0; }
  .doc { box-shadow: none; width: auto; min-height: 0; padding: 0; }
  .prgrid { display: block !important; }
  .doc table, .doc .sum, .doc .sign { break-inside: avoid; }
}
@media (max-width: 1360px) {
  .actpanel .t th, .actpanel .t td { padding-left: 12px; padding-right: 12px; }
  .actpanel .st { white-space: normal; height: auto; min-height: 24px; padding-top: 3px; padding-bottom: 3px; line-height: 1.3; }
  .actpanel .st::before { flex: none; }
}
