/* =========================================================
   Kasir Laundry — design tokens
   ========================================================= */
:root {
  --bg: #f3f6f7; --card: #ffffff; --card-2: #f7f9fa; --ink: #0f1d21; --ink-2: #33464b; --muted: #6b7d82; --line: #e3eaec;
  --brand: #0b7285; --brand-2: #0a5d6e; --brand-ink: #ffffff; --brand-soft: #e2f3f6;
  --green: #16794a; --green-soft: #e1f5e9; --amber: #a15c00; --amber-soft: #fff1d9;
  --red: #c0352b; --red-soft: #fde9e7; --blue: #2457b3; --blue-soft: #e6eefc; --gray-soft: #edf1f2;
  --wa: #1fa855;
  --r: 16px; --r-sm: 12px;
  --shadow: 0 1px 2px rgba(15, 29, 33, .05), 0 4px 16px rgba(15, 29, 33, .05);
  --shadow-lg: 0 10px 30px rgba(11, 114, 133, .28);
  --nav-h: 64px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b1214; --card: #141e21; --card-2: #19252a; --ink: #e9f1f2; --ink-2: #c3d1d4; --muted: #8b9fa4; --line: #223238;
    --brand: #3ec1d3; --brand-2: #1d8fa1; --brand-ink: #04252b; --brand-soft: #163a41;
    --green: #5ad395; --green-soft: #12301f; --amber: #f3b65a; --amber-soft: #352812;
    --red: #ff8b80; --red-soft: #3a1a17; --blue: #91b4ff; --blue-soft: #18264a; --gray-soft: #1e2b2f;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3); --shadow-lg: 0 10px 30px rgba(0, 0, 0, .45);
    color-scheme: dark;
  }
}

/* ---------- base ---------- */
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  padding-bottom: calc(var(--nav-h) + 24px + env(safe-area-inset-bottom)); font-feature-settings: "tnum" 1; overscroll-behavior-y: none; }
a { color: var(--brand); text-decoration: none; }
h1 { font-size: 1.6rem; line-height: 1.15; margin: 0; letter-spacing: -.02em; font-weight: 750; }
h2 { font-size: 1rem; margin: 0 0 10px; letter-spacing: -.005em; font-weight: 700; }
p { margin: 0; }
.wrap { max-width: 760px; margin: 0 auto; padding: calc(10px + env(safe-area-inset-top)) 16px 24px; }
.muted { color: var(--muted); } .small, small { font-size: .82rem; }
.red { color: var(--red); } .green { color: var(--green); }
.center { text-align: center; } .c { text-align: center; } .r { text-align: right; } .right { text-align: right; flex-shrink: 0; display: flex; flex-direction: column; align-items: flex-end; }
.hide { display: none !important; }
.grow { flex: 1; min-width: 0; }
.top-gap { margin-top: 12px; }
.ic { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.ic.xs { width: 14px; height: 14px; vertical-align: -2px; }
details[open] .ic.rot { transform: rotate(90deg); } .ic.rot { transition: transform .25s; }

/* ---------- page header ---------- */
.pagehead { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 8px 0 18px; min-height: 44px; }
.pagehead.detail { margin-bottom: 14px; }
.pagehead.detail h1 { font-size: 1.3rem; }
.eyebrow { color: var(--muted); font-size: .82rem; font-weight: 500; margin-bottom: 2px; }
.iconbtn { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%; color: var(--ink); background: var(--card); border: 1px solid var(--line); flex-shrink: 0; }
.iconbtn.back { margin-left: -4px; }
.only-mobile { display: grid; }

/* ---------- desktop top bar ---------- */
.topbar { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 16px; padding: 10px 20px; background: color-mix(in srgb, var(--card) 88%, transparent); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 750; color: var(--ink); white-space: nowrap; }
.brand img { width: 28px; height: 28px; }
.topnav { display: flex; gap: 2px; flex: 1; overflow-x: auto; }
.topnav a { padding: 7px 11px; border-radius: 10px; color: var(--muted); white-space: nowrap; font-weight: 550; }
.topnav a.on, .topnav a:hover { background: var(--brand-soft); color: var(--brand); }
.who { white-space: nowrap; }

/* ---------- mobile bottom bar ---------- */
.bottomnav { display: none; }
@media (max-width: 760px) {
  .topbar { display: none; }
  .bottomnav { display: flex; position: fixed; bottom: 0; left: 0; right: 0; z-index: 20; height: calc(var(--nav-h) + env(safe-area-inset-bottom));
    padding: 6px 6px env(safe-area-inset-bottom); background: color-mix(in srgb, var(--card) 90%, transparent); backdrop-filter: blur(16px) saturate(1.4);
    border-top: 1px solid var(--line); align-items: center; }
  .bottomnav a.tab { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: .7rem; font-weight: 600; color: var(--muted); position: relative; padding-top: 4px; }
  .bottomnav a.tab .ic { width: 24px; height: 24px; }
  .bottomnav a.on { color: var(--brand); }
  .bottomnav a.on .ic { stroke-width: 2.3; }
  .bottomnav a.on::before { content: ''; position: absolute; top: -7px; width: 28px; height: 3px; border-radius: 0 0 3px 3px; background: var(--brand); }
  body:has(.actionbar) .bottomnav { display: none; }
  body:has(.actionbar) { padding-bottom: calc(96px + env(safe-area-inset-bottom)); }
}
@media (min-width: 761px) {
  body { padding-bottom: 40px; }
  .only-mobile { display: none; }
  .pagehead.detail .back { display: none; }
}

/* ---------- cards & layout ---------- */
.card { display: block; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; margin-bottom: 12px; box-shadow: var(--shadow); color: var(--ink); }
.card.warn { border-color: var(--amber); background: var(--amber-soft); }
.stack { display: flex; flex-direction: column; gap: 12px; }
.row { display: flex; align-items: center; } .between { justify-content: space-between; gap: 10px; } .gap { gap: 8px; } .wrapline { flex-wrap: wrap; gap: 8px; }
.center-row { justify-content: center; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; }
.grid2.top { margin-top: 12px; align-items: start; }
@media (max-width: 760px) { .grid2 { grid-template-columns: 1fr; } }
@media (max-width: 420px) { .grid3 { grid-template-columns: 1fr 1fr; } }
.narrow { max-width: 440px; }
.section { margin-top: 22px; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; gap: 8px; }
.section-head h2 { margin: 0; font-size: 1.05rem; }
.section-head.sticky { position: sticky; top: 0; z-index: 2; background: var(--bg); padding: 8px 0 6px; margin-bottom: 4px; }
@media (min-width: 761px) { .section-head.sticky { top: 57px; } }
.link-more { display: inline-flex; align-items: center; gap: 2px; font-weight: 600; font-size: .9rem; }
.group-label { color: var(--muted); font-size: .76rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; margin: 20px 4px 8px; }

/* ---------- forms ---------- */
label { display: flex; flex-direction: column; gap: 6px; font-size: .84rem; color: var(--ink-2); font-weight: 600; }
label.check { flex-direction: row; align-items: center; gap: 10px; color: var(--ink); font-weight: 500; }
input, select, textarea { font: inherit; font-weight: 400; color: var(--ink); background: var(--card-2); border: 1.5px solid var(--line); border-radius: var(--r-sm); padding: 11px 13px; width: 100%; min-height: 48px; transition: border-color .15s, box-shadow .15s, background .15s; }
input::placeholder, textarea::placeholder { color: var(--muted); opacity: .8; }
input[type=checkbox], input[type=radio] { width: 20px; height: 20px; min-height: 0; accent-color: var(--brand); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); background: var(--card); box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 18%, transparent); }
textarea { resize: vertical; }
.money { font-size: 1.15rem; font-weight: 700; }

.searchbar { position: relative; margin-bottom: 12px; }
.searchbar .ic { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); width: 20px; height: 20px; pointer-events: none; }
.searchbar input { padding-left: 44px; border-radius: 14px; background: var(--card); }
.searchbar.inset input { background: var(--card-2); }

/* segmented control */
.seg { display: flex; background: var(--card-2); border: 1px solid var(--line); border-radius: 14px; padding: 4px; gap: 4px; }
.seg-opt { flex: 1; position: relative; display: block; }
.seg-opt input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.seg-opt span { display: grid; place-items: center; min-height: 42px; padding: 4px 6px; border-radius: 10px; font-weight: 650; font-size: .88rem; color: var(--muted); text-align: center; transition: background .2s, color .2s, box-shadow .2s; }
.seg-opt input:checked + span { background: var(--card); color: var(--ink); box-shadow: var(--shadow); }
.seg-opt input:focus-visible + span { outline: 2px solid var(--brand); }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 16px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--card); color: var(--ink); font: inherit; font-weight: 650; cursor: pointer; white-space: nowrap; text-decoration: none; }
.btn .ic { width: 20px; height: 20px; }
.btn.primary { background: linear-gradient(145deg, var(--brand), var(--brand-2)); color: #fff; border-color: transparent; box-shadow: 0 4px 14px color-mix(in srgb, var(--brand) 35%, transparent); }
@media (prefers-color-scheme: dark) { .btn.primary { color: #04252b; background: var(--brand); } }
.btn.big { width: 100%; min-height: 54px; font-size: 1.05rem; }
.btn.wide { width: 100%; }
.btn.small { min-height: 36px; padding: 6px 12px; font-size: .85rem; border-radius: 10px; }
.btn.ghost { background: transparent; border-color: transparent; }
.btn.danger { color: var(--red); }
.btn.danger:not(.ghost) { border-color: color-mix(in srgb, var(--red) 30%, transparent); }
.btn.wa { background: var(--wa); color: #fff; border-color: var(--wa); }
.btn.icon { padding: 0; width: 46px; }
.btn.icon.big-ic { width: 54px; min-height: 54px; border-radius: 16px; }
.btn.icon.big-ic .ic { width: 24px; height: 24px; }
.btn.ok { color: var(--green); border-color: var(--green); }
.btn:disabled { opacity: .45; cursor: not-allowed; box-shadow: none; }
.link { background: none; border: 0; color: var(--brand); font: inherit; cursor: pointer; padding: 0; }

/* ---------- feedback ---------- */
.flash { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 14px; margin-bottom: 14px; font-weight: 600; }
.flash .ic { width: 20px; height: 20px; }
.flash.ok { background: var(--green-soft); color: var(--green); }
.flash.bad { background: var(--red-soft); color: var(--red); }

.badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px 3px 7px; border-radius: 99px; font-size: .74rem; font-weight: 700; white-space: nowrap; }
.badge i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge.blue { background: var(--blue-soft); color: var(--blue); }
.badge.amber { background: var(--amber-soft); color: var(--amber); }
.badge.green { background: var(--green-soft); color: var(--green); }
.badge.gray { background: var(--gray-soft); color: var(--muted); }
.badge.red { background: var(--red-soft); color: var(--red); }
.badge.amber i { animation: blink 1.6s ease-in-out infinite; }
@keyframes blink { 50% { opacity: .35; } }

.empty { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; padding: 34px 20px; background: var(--card); border: 1.5px dashed var(--line); border-radius: var(--r); }
.empty-ic { width: 64px; height: 64px; border-radius: 22px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); margin-bottom: 6px; }
.empty-ic .ic { width: 30px; height: 30px; }
.empty p { max-width: 280px; font-size: .9rem; margin-bottom: 8px; }
.empty-filter { text-align: center; padding: 18px; }

/* ---------- avatar & person rows ---------- */
.avatar { --h: 190; width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; flex-shrink: 0; font-weight: 750; font-size: .92rem; letter-spacing: .02em;
  background: hsl(var(--h) 70% 92%); color: hsl(var(--h) 55% 30%); }
@media (prefers-color-scheme: dark) { .avatar { background: hsl(var(--h) 35% 22%); color: hsl(var(--h) 70% 80%); } }
.avatar.sm { width: 36px; height: 36px; border-radius: 12px; font-size: .8rem; }
.avatar.lg { width: 72px; height: 72px; border-radius: 24px; font-size: 1.5rem; }
.person { display: flex; align-items: center; gap: 12px; color: var(--ink); text-align: left; }
.person .grow { display: flex; flex-direction: column; }
.person .grow b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.card.person { padding: 12px 14px; }
.plist { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; }
.plist .row-link { padding: 12px 14px; border-bottom: 1px solid var(--line); }
.plist .row-link:last-child { border-bottom: 0; }

/* ---------- order rows ---------- */
.olist { display: flex; flex-direction: column; gap: 8px; }
.orow { display: flex; align-items: center; gap: 12px; padding: 12px 14px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); color: var(--ink); box-shadow: var(--shadow); position: relative; }
.orow.late { border-color: color-mix(in srgb, var(--red) 40%, var(--line)); }
.orow.late::before { content: ''; position: absolute; left: -1px; top: 14px; bottom: 14px; width: 3px; border-radius: 0 3px 3px 0; background: var(--red); }
.orow-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.orow-line { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-width: 0; }
.orow-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .98rem; }
.orow-amt { font-size: .95rem; flex-shrink: 0; }
.orow-meta { display: flex; align-items: center; gap: 8px; min-width: 0; }
.orow-meta small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.owe { flex-shrink: 0; font-weight: 650; }

/* ---------- dashboard ---------- */
.hero { position: relative; overflow: hidden; border-radius: 22px; padding: 18px 18px 14px; color: #fff; margin-bottom: 14px;
  background: radial-gradient(120% 140% at 100% 0%, #14a3b8 0%, transparent 55%), linear-gradient(150deg, #0b7285 0%, #08505e 100%);
  box-shadow: 0 14px 34px rgba(8, 80, 94, .32); }
.hero::after { content: ''; position: absolute; right: -40px; top: -40px; width: 160px; height: 160px; border-radius: 50%; border: 28px solid rgba(255, 255, 255, .06); }
.hero-label { font-size: .84rem; font-weight: 600; opacity: .85; }
.hero-amt { font-size: 2.3rem; font-weight: 800; letter-spacing: -.03em; line-height: 1.15; margin: 2px 0 4px; }
.hero-sub { font-size: .84rem; opacity: .9; display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center; }
.delta { font-weight: 700; padding: 1px 8px; border-radius: 99px; background: rgba(255, 255, 255, .16); font-size: .76rem; }
.spark { display: flex; align-items: flex-end; gap: 6px; height: 92px; margin: 14px 0 4px; position: relative; z-index: 1; }
.spark-col { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; gap: 4px; }
.spark-bar { width: 100%; max-width: 30px; border-radius: 7px 7px 3px 3px; background: rgba(255, 255, 255, .26); height: calc(var(--v) * 54px + 4px); }
.spark-col.today .spark-bar { background: #fff; }
.spark-val { font-size: .62rem; font-weight: 700; opacity: .75; min-height: 12px; }
.spark-day { font-size: .7rem; font-weight: 700; opacity: .7; }
.spark-col.today .spark-day, .spark-col.today .spark-val { opacity: 1; }
.hero-foot { display: flex; align-items: center; gap: 10px; margin: 12px -6px 0; padding: 10px 12px; border-radius: 14px; background: rgba(255, 255, 255, .12); color: #fff; font-size: .88rem; position: relative; z-index: 1; }
.hero-foot span { flex: 1; } .hero-foot .ic { width: 20px; height: 20px; }

.pipe { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 6px; box-shadow: var(--shadow); }
.pipe-step { border: 0; background: transparent; border-radius: 13px; padding: 10px 4px 8px; display: flex; flex-direction: column; align-items: center; gap: 1px; color: var(--muted); font: inherit; cursor: pointer; position: relative; transition: background .2s, color .2s; }
.pipe-step b { font-size: 1.35rem; color: var(--ink); line-height: 1.1; }
.pipe-step span { font-size: .72rem; font-weight: 650; }
.pipe-step.on { background: var(--brand-soft); color: var(--brand); }
.pipe-step.on b { color: var(--brand); }
.pipe-step.good b { color: var(--green); }
.alertbar { width: 100%; display: flex; align-items: center; gap: 10px; margin-top: 10px; padding: 12px 14px; border-radius: 14px; border: 0; background: var(--red-soft); color: var(--red); font: inherit; font-size: .9rem; text-align: left; cursor: pointer; }
.alertbar span { flex: 1; } .alertbar .ic { width: 20px; height: 20px; }

/* ---------- chips ---------- */
.chips { display: flex; gap: 8px; overflow-x: auto; margin: 0 -16px 6px; padding: 2px 16px 8px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; padding: 8px 14px; border-radius: 99px; background: var(--card); border: 1px solid var(--line); color: var(--ink-2); font-weight: 650; font-size: .86rem; }
.chip i { font-style: normal; font-size: .74rem; padding: 1px 7px; border-radius: 99px; background: var(--gray-soft); color: var(--muted); }
.chip.on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.chip.on i { background: color-mix(in srgb, var(--bg) 22%, transparent); color: var(--bg); }
.chip.warn.on { background: var(--red); border-color: var(--red); color: #fff; }

/* ---------- order detail ---------- */
.stepper { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); position: relative; }
.stepper li { display: flex; flex-direction: column; align-items: center; gap: 4px; position: relative; text-align: center; color: var(--muted); }
.stepper li:not(:last-child)::after { content: ''; position: absolute; top: 15px; left: calc(50% + 20px); right: calc(-50% + 20px); height: 3px; border-radius: 3px; background: var(--line); }
.stepper li.done:not(:last-child)::after { background: var(--green); }
.stepper .dot { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: .85rem; background: var(--gray-soft); color: var(--muted); }
.stepper .dot .ic { width: 16px; height: 16px; stroke-width: 3; }
.stepper b { font-size: .8rem; }
.stepper small { font-size: .68rem; min-height: 1em; }
.stepper li.done { color: var(--ink); } .stepper li.done .dot { background: var(--green); color: #fff; }
.stepper li.now { color: var(--ink); } .stepper li.now .dot { background: var(--brand); color: #fff; box-shadow: 0 0 0 5px color-mix(in srgb, var(--brand) 22%, transparent); }
.due { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); font-size: .88rem; color: var(--ink-2); font-weight: 600; text-align: center; }
.due.late { color: var(--red); }
.lines { display: flex; flex-direction: column; }
.line { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.line:last-child { border-bottom: 0; }
.line > span { display: flex; flex-direction: column; min-width: 0; }
.line form { margin: 0; }
.sum { margin-top: 8px; padding-top: 10px; border-top: 1.5px dashed var(--line); display: flex; flex-direction: column; gap: 6px; }
.sum div { display: flex; justify-content: space-between; color: var(--ink-2); }
.sum .grand { font-size: 1.2rem; color: var(--ink); font-weight: 800; padding: 4px 0; }
.sum .red { color: var(--red); } .sum .green { color: var(--green); }
.sum .ic { width: 18px; height: 18px; stroke-width: 2.6; }
.note { background: var(--amber-soft); color: var(--ink); padding: 12px 14px; border-radius: 14px; margin-bottom: 12px; font-size: .92rem; border-left: 4px solid var(--amber); }
.payform { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.actionbar { position: fixed; z-index: 25; left: 0; right: 0; bottom: 0; display: flex; align-items: center; gap: 10px;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); background: color-mix(in srgb, var(--card) 92%, transparent); backdrop-filter: blur(16px) saturate(1.4); border-top: 1px solid var(--line); }
.actionbar form { margin: 0; display: flex; }
.actionbar .btn.primary { min-height: 54px; border-radius: 16px; font-size: 1rem; flex: 1; }
.actionbar a.btn.primary.grow { flex: 1; }
.done-label { display: flex; justify-content: center; }
@media (min-width: 761px) { .actionbar { left: 50%; transform: translateX(-50%); bottom: 18px; max-width: 728px; border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow-lg); padding: 12px; } }
.profile { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; padding: 22px 16px; }
.profile h2 { margin: 8px 0 0; font-size: 1.3rem; }
.kpis { display: grid; grid-template-columns: repeat(3, 1fr); width: 100%; margin: 14px 0; background: var(--card-2); border-radius: 14px; }
.kpis div { padding: 10px 4px; display: flex; flex-direction: column; }
.kpis div + div { border-left: 1px solid var(--line); }
.kpis b { font-size: 1.15rem; } .kpis small { color: var(--muted); font-size: .72rem; }

/* ---------- new order ---------- */
.svc-list { display: flex; flex-direction: column; gap: 8px; }
.svc { display: flex; align-items: center; gap: 10px; padding: 10px 10px 10px 14px; border: 1.5px solid var(--line); border-radius: 14px; background: var(--card-2); transition: border-color .2s, background .2s; }
.svc.on { border-color: var(--brand); background: var(--brand-soft); }
.svc-info { flex: 1; min-width: 0; display: flex; flex-direction: column; cursor: pointer; }
.svc-info b { font-size: .95rem; }
.svc-amt { color: var(--brand); font-weight: 750; min-height: 0; }
.stepper-in { display: flex; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 3px; }
.st-btn { width: 38px; height: 38px; border: 0; border-radius: 9px; background: transparent; color: var(--ink); display: grid; place-items: center; cursor: pointer; }
.st-btn .ic { width: 18px; height: 18px; stroke-width: 2.4; }
.st-btn.plus { background: var(--brand); color: #fff; }
@media (prefers-color-scheme: dark) { .st-btn.plus { color: #04252b; } }
.stepper-in .qty { width: 54px; min-height: 38px; padding: 4px; text-align: center; border: 0; background: transparent; font-weight: 750; font-size: 1rem; box-shadow: none; }
.svc:not(.on) .st-btn.minus { opacity: .35; }
.totalbar .total-amt { font-size: 1.45rem; font-weight: 800; letter-spacing: -.02em; display: block; line-height: 1.1; }
.totalbar .btn.primary { flex: 0 0 auto; padding: 0 22px; }
.suggest { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.suggest .person { border: 1px solid var(--line); background: var(--card); border-radius: 14px; padding: 8px 12px; font: inherit; cursor: pointer; }
.picked { background: var(--brand-soft); border-radius: 14px; padding: 10px 12px; }
details > summary { cursor: pointer; list-style: none; }
details > summary::-webkit-details-marker { display: none; }
details summary small { display: block; font-weight: 500; }

/* ---------- menu list ---------- */
.menu { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; box-shadow: var(--shadow); }
.menu a { display: flex; align-items: center; gap: 12px; padding: 12px 14px; color: var(--ink); font-weight: 600; border-bottom: 1px solid var(--line); }
.menu a:last-child { border-bottom: 0; }
.mi { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; background: hsl(var(--h) 70% 93%); color: hsl(var(--h) 60% 35%); }
@media (prefers-color-scheme: dark) { .mi { background: hsl(var(--h) 35% 20%); color: hsl(var(--h) 70% 78%); } }
.mi .ic { width: 20px; height: 20px; }

/* ---------- legacy pieces still used by owner pages ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-bottom: 16px; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 14px; display: flex; flex-direction: column; color: var(--ink); box-shadow: var(--shadow); }
.stat small { color: var(--muted); font-weight: 650; font-size: .76rem; }
.stat b { font-size: 1.35rem; letter-spacing: -.02em; }
.stat span { font-size: .8rem; }
.stat.good { border-color: var(--green); } .stat.bad { border-color: var(--red); }
.list { display: flex; flex-direction: column; gap: 8px; }
.list details.card { margin: 0; }
.item { display: flex; justify-content: space-between; align-items: center; gap: 12px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; color: var(--ink); }
details[open] > summary { margin-bottom: 12px; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: end; margin-bottom: 12px; }
.filters label { flex: 1 1 140px; }
ul.plain { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 4px 14px; } .kv span { color: var(--muted); }
.tbl { width: 100%; border-collapse: collapse; }
.tbl th, .tbl td { padding: 9px 6px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.tbl th { font-size: .76rem; color: var(--muted); font-weight: 650; }
.tbl .r { text-align: right; }
.tbl tr.grand td { font-weight: 800; font-size: 1.05rem; border-top: 2px solid var(--ink); }
.tbl td.barcell { position: relative; isolation: isolate; }
.barcell .bar { position: absolute; right: 6px; top: 6px; bottom: 6px; background: var(--brand-soft); border-radius: 6px; z-index: -1; max-width: calc(100% - 12px); }
.timeline { list-style: none; margin: 0; padding: 0 0 0 16px; border-left: 2px solid var(--line); display: flex; flex-direction: column; gap: 12px; }
.timeline li { position: relative; }
.timeline li::before { content: ''; position: absolute; left: -22px; top: 5px; width: 10px; height: 10px; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 3px var(--card); }

/* ---------- login + tracking ---------- */
.login, .track { max-width: 420px; margin: 7vh auto 0; }
.login { text-align: center; }
.login h1 { margin: 12px 0 4px; }
.login form { text-align: left; margin-top: 22px; }
.login-logo { width: 72px; height: 72px; border-radius: 22px; box-shadow: var(--shadow-lg); }
.track .c h1 { margin: 12px 0 4px; }
.track .c { margin-bottom: 18px; }
.steps { list-style: none; padding: 0; margin: 6px 0; display: flex; flex-direction: column; gap: 12px; }
.steps li { display: flex; align-items: center; gap: 12px; color: var(--muted); }
.steps .dot { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--gray-soft); font-weight: 800; font-size: .9rem; }
.steps li.done { color: var(--ink); } .steps li.done .dot { background: var(--green-soft); color: var(--green); }
.steps li.now { color: var(--ink); font-weight: 750; } .steps li.now .dot { background: var(--brand); color: #fff; }

/* ---------- printer page ---------- */
.modes { display: flex; flex-direction: column; gap: 8px; }
.mode { flex-direction: row; align-items: flex-start; gap: 12px; padding: 14px; border: 1.5px solid var(--line); border-radius: 14px; color: var(--ink); cursor: pointer; font-weight: 500; }
.mode:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.mode input { margin-top: 2px; flex-shrink: 0; }
.mode span { display: flex; flex-direction: column; gap: 3px; }
.mode small { color: var(--muted); }
.mode em { font-style: normal; font-size: .8rem; font-weight: 650; }
.okc { color: var(--green); } .warnc { color: var(--amber); }
.toast { position: fixed; left: 50%; bottom: calc(var(--nav-h) + 24px + env(safe-area-inset-bottom)); transform: translate(-50%, 20px); max-width: min(92vw, 440px); padding: 12px 18px; border-radius: 14px; background: var(--ink); color: var(--bg); font-weight: 650; opacity: 0; pointer-events: none; transition: .25s cubic-bezier(.3, 1.3, .5, 1); z-index: 50; text-align: center; box-shadow: var(--shadow-lg); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.bad { background: var(--red); color: #fff; }
body:has(.actionbar) .toast { bottom: calc(96px + env(safe-area-inset-bottom)); }
@media (min-width: 761px) { .toast { bottom: 28px; } }

/* ---------- import ---------- */
.lead { margin: -6px 0 16px; font-size: .92rem; }
.nomb { margin: 0; }
.ellipsis { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.drop { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 22px 14px; border: 2px dashed var(--line); border-radius: 16px; background: var(--card-2); cursor: pointer; text-align: center; color: var(--ink); transition: border-color .2s, background .2s; }
.drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; min-height: 0; }
.drop-ic { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); }
.drop-txt { font-weight: 700; }
.drop-names { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.drop.has { border-color: var(--brand); border-style: solid; background: var(--brand-soft); }
.statusbar { display: flex; flex-wrap: wrap; gap: 8px; }
.statusbar > div { display: flex; align-items: center; gap: 8px; padding: 6px 10px 6px 6px; border-radius: 12px; background: var(--card-2); border: 1px solid var(--line); }
.archive { align-items: flex-start; line-height: 1.9; }
.archive input[type=checkbox] { margin-top: 5px; }
.inline-num { display: inline-block; width: 64px; min-height: 34px; padding: 2px 6px; text-align: center; font-weight: 700; }
.ic.green { color: var(--green); } .ic.red { color: var(--red); }

/* ---------- roles, shop profile, setup ---------- */
.perm { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.perm-head, .perm-row { display: grid; grid-template-columns: 1fr 56px 56px; align-items: center; gap: 6px; padding: 10px 12px; }
.perm-head { background: var(--card-2); font-size: .8rem; }
.perm-head b { text-align: center; }
.perm-row { border-top: 1px solid var(--line); font-size: .88rem; }
.perm-row i { font-style: normal; display: grid; place-items: center; color: var(--muted); }
.perm-row i.yes { color: var(--green); }
.perm-row .ic { width: 18px; height: 18px; stroke-width: 2.6; }
.userrow summary { list-style: none; }
.userrow .badge { margin-left: 4px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field-label { font-size: .84rem; color: var(--ink-2); font-weight: 600; }
.shopcard { display: flex; align-items: center; gap: 12px; padding: 14px; background: linear-gradient(135deg, var(--brand-soft), var(--card)); }
.shop-logo { width: 48px; height: 48px; border-radius: 15px; }
.shopcard .grow { display: flex; flex-direction: column; }
.setup { display: flex; align-items: center; gap: 12px; padding: 12px 14px; margin-bottom: 14px; border-radius: 16px; background: var(--amber-soft); color: var(--ink); border: 1px solid color-mix(in srgb, var(--amber) 35%, transparent); }
.setup .grow { display: flex; flex-direction: column; }
.setup small { color: var(--ink-2); }

/* ---------- floating "Nota baru" (replaces the centre + button) ---------- */
.newfab { display: none; }
@media (max-width: 760px) {
  .newfab { position: fixed; right: 16px; bottom: calc(var(--nav-h) + 16px + env(safe-area-inset-bottom)); z-index: 21; display: inline-flex; align-items: center; gap: 8px;
    height: 56px; padding: 0 20px 0 16px; border-radius: 18px; background: linear-gradient(145deg, var(--brand), var(--brand-2)); color: #fff; font-weight: 750; font-size: .98rem;
    box-shadow: 0 10px 26px color-mix(in srgb, var(--brand) 45%, transparent), 0 2px 6px rgba(0,0,0,.18); transition: padding .28s cubic-bezier(.2,.8,.2,1), gap .28s, transform .15s; overflow: hidden; }
  .newfab .ic { width: 24px; height: 24px; stroke-width: 2.4; }
  .newfab span { max-width: 120px; white-space: nowrap; transition: max-width .28s cubic-bezier(.2,.8,.2,1), opacity .2s; }
  .newfab.mini { padding: 0 16px; gap: 0; }
  .newfab.mini span { max-width: 0; opacity: 0; }
  .newfab:active { transform: scale(.94); }
  .newfab.hide { display: none !important; }
  body:has(.newfab:not(.hide)) main.wrap { padding-bottom: 96px; }
}
@media (prefers-color-scheme: dark) { .newfab { color: #04252b; background: var(--brand); } }

/* ---------- order detail: quick actions, history, sheets ---------- */
.quick { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 12px; }
.qbtn { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 4px 10px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); color: var(--ink); font: inherit; font-size: .74rem; font-weight: 650; text-align: center; cursor: pointer; box-shadow: var(--shadow); }
.qbtn .ic { width: 22px; height: 22px; color: var(--brand); }
.qbtn.ok { color: var(--green); }
.history { list-style: none; margin: 0; padding: 0; }
.history li { display: flex; gap: 12px; position: relative; padding-bottom: 14px; }
.history li:last-child { padding-bottom: 0; }
.history li:not(:last-child)::before { content: ''; position: absolute; left: 6px; top: 16px; bottom: -2px; width: 2px; background: var(--line); }
.h-dot { width: 14px; height: 14px; border-radius: 50%; border: 3px solid var(--line); background: var(--card); flex-shrink: 0; margin-top: 3px; }
.history li.latest .h-dot { border-color: var(--brand); background: var(--brand); box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 20%, transparent); }
.h-body { display: flex; flex-direction: column; }
.history li:not(.latest) b { font-weight: 600; color: var(--ink-2); }

dialog.sheet { position: fixed; inset: auto 0 0 0; margin: 0 auto; width: 100%; max-width: 560px; max-height: 88dvh; border: 0; padding: 8px 16px calc(20px + env(safe-area-inset-bottom));
  border-radius: 24px 24px 0 0; background: var(--card); color: var(--ink); overflow-y: auto; box-shadow: 0 -10px 40px rgba(0,0,0,.25); }
dialog.sheet::backdrop { background: rgba(5, 12, 14, .5); backdrop-filter: blur(2px); }
dialog.sheet[open] { animation: sheet-up .32s cubic-bezier(.2, .9, .25, 1); }
dialog.sheet[open]::backdrop { animation: fade-in .25s ease; }
dialog.sheet.closing { animation: sheet-down .22s cubic-bezier(.4, 0, 1, 1) forwards; }
dialog.sheet.closing::backdrop { animation: fade-out .22s ease forwards; }
@keyframes sheet-up { from { transform: translateY(100%); } }
@keyframes sheet-down { to { transform: translateY(100%); } }
@keyframes fade-in { from { opacity: 0; } }
@keyframes fade-out { to { opacity: 0; } }
.sheet-grip { width: 40px; height: 5px; border-radius: 3px; background: var(--line); margin: 4px auto 10px; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.sheet-head h2 { margin: 0; font-size: 1.15rem; }
.opt-list { display: flex; flex-direction: column; gap: 8px; }
.opt-list form { margin: 0; }
.opt { width: 100%; display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--card-2); color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.opt .grow { display: flex; flex-direction: column; }
.opt small { color: var(--muted); }
.opt-n { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--gray-soft); font-weight: 800; font-size: .85rem; flex-shrink: 0; }
.opt.cur { border-color: var(--brand); background: var(--brand-soft); opacity: 1; }
.opt.cur .opt-n { background: var(--brand); color: #fff; }
.opt.cur .ic { color: var(--brand); }
.opt.danger { color: var(--red); border-color: color-mix(in srgb, var(--red) 30%, var(--line)); }
.opt.danger .opt-n { background: var(--red-soft); color: var(--red); }
details.card { overflow: hidden; }

/* ---------- Keuangan ---------- */
.customrange { margin-top: -2px; }
button.chip { font: inherit; font-weight: 650; font-size: .86rem; cursor: pointer; }
.hero.money { padding-bottom: 16px; }
.chart { position: relative; z-index: 1; margin-top: 14px; }
.chart-readout { display: flex; flex-direction: column; padding: 10px 12px; border-radius: 14px; background: rgba(255,255,255,.12); margin-bottom: 10px; min-height: 56px; }
.chart-readout b { font-size: .9rem; } .chart-readout span { font-size: .8rem; opacity: .9; }
.chart-bars { display: grid; grid-template-columns: repeat(var(--n), 1fr); align-items: end; gap: clamp(2px, 1vw, 6px); height: 150px; padding-bottom: 18px; position: relative; }
.cbar { position: relative; height: 100%; border: 0; background: none; padding: 0; cursor: pointer; display: flex; align-items: flex-end; justify-content: center; color: #fff; }
.cbar i { position: absolute; bottom: 18px; left: 50%; transform-origin: bottom; border-radius: 5px 5px 2px 2px; }
.cbar-s { width: 78%; transform: translateX(-50%); height: calc(var(--s) * 124px); background: rgba(255,255,255,.18); }
.cbar-i { width: 48%; transform: translateX(-50%); height: calc(var(--v) * 124px + 2px); background: rgba(255,255,255,.72); }
.cbar.today .cbar-i, .cbar.sel .cbar-i { background: #fff; }
.cbar.sel .cbar-s { background: rgba(255,255,255,.32); }
.cbar small { position: absolute; bottom: 0; left: 50%; transform: translateX(-50%); font-size: .62rem; font-weight: 700; opacity: .75; white-space: nowrap; }
.chart-legend { display: flex; gap: 14px; font-size: .74rem; opacity: .9; margin-top: 4px; }
.chart-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.lg-i { background: rgba(255,255,255,.75); } .lg-s { background: rgba(255,255,255,.22); }
.kpi-lines .line .right { gap: 0; }
.stat-card { display: block; }
.sc-top { display: flex; align-items: center; gap: 12px; }
.sc-top .grow { display: flex; flex-direction: column; }
.sc-top small { color: var(--muted); font-weight: 650; }
.sc-top b { font-size: 1.15rem; }
.stat-card > p { margin-top: 10px; }
.warn-card { border-color: color-mix(in srgb, var(--red) 30%, var(--line)); }
.aging { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.aging-row { display: grid; grid-template-columns: 78px 1fr 56px 26px; align-items: center; gap: 8px; font-size: .84rem; }
.aging-row b, .aging-row small { text-align: right; }
.aging-bar { height: 10px; border-radius: 5px; background: var(--gray-soft); overflow: hidden; }
.aging-bar i { display: block; height: 100%; width: calc(var(--w) * 100%); border-radius: 5px; background: hsl(calc(40 - var(--k) * 13) 85% 52%); }
.share { padding: 8px 0; }
.share-bar { display: block; height: 8px; border-radius: 4px; background: var(--gray-soft); margin-top: 6px; overflow: hidden; }
.share-bar i { display: block; height: 100%; width: calc(var(--w) * 100%); background: var(--brand); border-radius: 4px; }
a.line { color: var(--ink); }
@media (prefers-reduced-motion: no-preference) {
  .cbar i { animation: grow-y .6s cubic-bezier(.2, .9, .25, 1) both; animation-delay: calc(var(--i) * 18ms + 150ms); }
  @keyframes grow-y { from { transform: translateX(-50%) scaleY(0); } }
  .aging-bar i, .share-bar i { animation: grow-x .7s cubic-bezier(.2, .9, .25, 1) .2s both; transform-origin: left; }
  @keyframes grow-x { from { transform: scaleX(0); } }
}
.hero-label { display: flex; justify-content: space-between; align-items: center; }
.hero-link { color: #fff; font-size: .8rem; font-weight: 700; padding: 4px 6px 4px 10px; border-radius: 99px; background: rgba(255,255,255,.14); display: inline-flex; align-items: center; gap: 2px; }

/* ---------- Keuangan v2 ---------- */
.modes-seg { margin-bottom: 12px; }
.seg-link { flex: 1; display: grid; place-items: center; min-height: 40px; border-radius: 10px; font-weight: 650; font-size: .88rem; color: var(--muted); transition: background .2s, color .2s; }
.seg-link.on { background: var(--card); color: var(--ink); box-shadow: var(--shadow); }
.period-nav { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.period-nav .grow { display: flex; flex-direction: column; }
.period-nav b { font-size: 1.05rem; }
.iconbtn.disabled { opacity: .3; }
.hero-hint { font-size: .8rem; font-weight: 600; opacity: .8; }
.hero-split { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; position: relative; z-index: 1; }
.hero-split > * { display: flex; flex-direction: column; padding: 10px 12px; border-radius: 14px; background: rgba(255,255,255,.12); color: #fff; }
.hero-split small { font-size: .74rem; opacity: .85; font-weight: 600; }
.hero-split b { font-size: 1.05rem; }
.hero-split em { font-style: normal; font-size: .74rem; opacity: .85; }
.chart-head { display: flex; justify-content: flex-start; margin-bottom: 8px; }
.mini-seg { background: rgba(255,255,255,.12); border: 0; padding: 3px; border-radius: 12px; display: inline-flex; gap: 2px; }
.mini-seg button { border: 0; background: transparent; color: #fff; font: inherit; font-size: .8rem; font-weight: 700; padding: 6px 12px; border-radius: 9px; opacity: .75; cursor: pointer; }
.mini-seg button.on { background: #fff; color: #08505e; opacity: 1; }
.cbar-fill { position: absolute; bottom: 18px; left: 50%; width: 64%; transform: translateX(-50%); transform-origin: bottom; border-radius: 6px 6px 2px 2px; background: rgba(255,255,255,.38);
  height: calc(var(--h, 0) * 124px + 2px); transition: height .45s cubic-bezier(.2,.8,.2,1), background .2s; }
[data-series-host="sales"] .cbar { --h: var(--s); }
[data-series-host="income"] .cbar { --h: var(--v); }
.cbar.sel .cbar-fill, .cbar.today .cbar-fill { background: #fff; }
.cbar.picked .cbar-fill { background: #fde68a; }
.cbar.future { opacity: .35; }
@media (prefers-reduced-motion: no-preference) {
  .cbar-fill { animation: grow-y .6s cubic-bezier(.2, .9, .25, 1) both; animation-delay: calc(var(--i) * 18ms + 150ms); }
}

/* ---------- lists: filter bar, totals, pagination ---------- */
.filterbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 2px 0 6px; }
.selectchip { position: relative; display: inline-flex; align-items: center; gap: 6px; flex-direction: row; padding: 0 4px 0 12px; border-radius: 99px; background: var(--card); border: 1px solid var(--line); color: var(--ink); font-weight: 650; }
.selectchip select { border: 0; background: transparent; min-height: 36px; padding: 4px 8px 4px 0; width: auto; font-weight: 650; font-size: .86rem; box-shadow: none; }
.sumbar { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); margin: 6px 0 4px; }
.sumbar.warn { background: var(--red-soft); color: var(--red); border-color: transparent; }
.sumbar b { font-size: 1.1rem; }
.pager { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 20px; }
.pager-nums { display: flex; align-items: center; gap: 4px; }
.pager-n { min-width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; color: var(--ink-2); font-weight: 700; }
.pager-n.on { background: var(--ink); color: var(--bg); }
.pager-gap { color: var(--muted); padding: 0 2px; }
.pager-info { text-align: center; margin-top: 8px; }
.dash-more { display: flex; justify-content: center; margin-top: 4px; }
.line > .person { flex-direction: row; align-items: center; gap: 10px; min-width: 0; }
.line > .person .grow { display: flex; flex-direction: column; min-width: 0; }
.line > .person .grow b, .line > .person .grow small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- calendar sheet (fintrack style) ---------- */
.cal-sheet { padding-top: 6px; }
.cal-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 2px 0 2px; }
.cal-head .iconbtn { font-size: 1.4rem; line-height: 1; }
.cal-title { font-size: 1.2rem; font-weight: 800; flex: 1; text-align: center; cursor: pointer; }
.cal-hint { text-align: center; margin-bottom: 10px; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.cal-grid.months { grid-template-columns: repeat(3, 1fr); gap: 10px; }
.cal-dow { text-align: center; font-size: .78rem; font-weight: 700; color: var(--muted); padding: 2px 0 4px; }
.cal-day { aspect-ratio: 1 / 1.05; border: 0; border-radius: 14px; background: transparent; color: var(--ink); font: inherit; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; cursor: pointer; position: relative; }
.cal-grid.months .cal-day { aspect-ratio: 1.6; }
.cal-day b { font-size: 1rem; font-weight: 700; }
.cal-day small { font-size: .62rem; font-weight: 650; color: var(--ink-2); min-height: .8em; }
.cal-day.has { background: color-mix(in srgb, var(--brand) calc(var(--a, .3) * 32%), var(--card-2)); }
.cal-day.today b { color: var(--brand); }
.cal-day.today::after { content: ''; position: absolute; bottom: 5px; width: 4px; height: 4px; border-radius: 50%; background: var(--brand); }
.cal-day.sel { background: var(--brand); color: #fff; }
.cal-day.sel small, .cal-day.sel.today b { color: #fff; }
@media (prefers-color-scheme: dark) { .cal-day.sel { color: #04252b; } .cal-day.sel small { color: #04252b; } }
.cal-day:disabled { opacity: .3; cursor: default; }
.cal-day:not(:disabled):active { transform: scale(.92); }
.cal-foot { margin-top: 14px; }
.cal-foot:empty { display: none; }
/* chips */
.chip.sm { padding: 6px 12px; font-size: .82rem; }
.chip .ic.xs { margin-right: 2px; }
.periodchips { margin-top: -4px; }
.listmeta { margin: 0 0 4px; }
.period-title { border: 0; background: none; color: var(--ink); font: inherit; display: flex; flex-direction: column; align-items: center; cursor: pointer; padding: 4px 8px; border-radius: 12px; }
.period-title[data-cal-open]:active { background: var(--card); }
.ic.rot90 { transform: rotate(90deg); }
/* due picker */
.pickbtn { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 48px; padding: 10px 13px; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: var(--card-2); color: var(--ink); font: inherit; font-weight: 600; text-align: left; cursor: pointer; }
.pickbtn span { flex: 1; }
.pickbtn .ic { color: var(--brand); }
.pickbtn.wide { margin-top: 12px; }
.due-quick, .due-times { display: flex; flex-wrap: wrap; gap: 8px; }
.due-times .chip, .due-quick .chip { cursor: pointer; font: inherit; font-weight: 650; font-size: .88rem; }
.timechip { position: relative; flex-direction: row; gap: 6px; color: var(--ink-2); }
.timechip input { width: 86px; min-height: 0; padding: 0 4px; border: 0; background: transparent; font-weight: 650; }

/* ---------- roles & users ---------- */
button.person.row-link { width: 100%; border: 0; border-bottom: 1px solid var(--line); background: transparent; font: inherit; cursor: pointer; }
.plist button.person.row-link:last-child { border-bottom: 0; }
.hint-card { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 16px; background: var(--brand-soft); color: var(--ink); }
.hint-card .grow { display: flex; flex-direction: column; }
.switch { flex-direction: row; align-items: center; gap: 12px; padding: 12px 0; color: var(--ink); font-weight: 600; cursor: pointer; position: relative; }
.switch .grow { display: flex; flex-direction: column; font-size: .92rem; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch i { width: 48px; height: 28px; border-radius: 99px; background: var(--gray-soft); border: 1px solid var(--line); position: relative; flex-shrink: 0; transition: background .2s, border-color .2s; }
.switch i::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .22s cubic-bezier(.3,1.4,.5,1); }
.switch input:checked + i { background: var(--brand); border-color: var(--brand); }
.switch input:checked + i::after { transform: translateX(20px); }
.switch input:focus-visible + i { outline: 2px solid var(--brand); outline-offset: 2px; }
.switch-list { background: var(--card-2); border: 1px solid var(--line); border-radius: 14px; padding: 0 14px; }
.switch-list .switch + .switch { border-top: 1px solid var(--line); }
.perm-group { margin: 6px 0 -4px; text-transform: uppercase; letter-spacing: .06em; font-size: .72rem; color: var(--muted); }
.opt-list.compact { gap: 6px; }
.opt.radio { position: relative; flex-direction: row; font-weight: 500; }
.opt.radio input { position: absolute; opacity: 0; }
.opt.radio .dot { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line); flex-shrink: 0; transition: border .15s; }
.opt.radio:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.opt.radio:has(input:checked) .dot { border: 7px solid var(--brand); }
.sheet .person .grow { display: flex; flex-direction: column; }
.lbl { display: block; }
.lbl .muted { font-weight: 500; }
.cal-day.today::after { bottom: auto; top: 6px; right: 8px; }
.seg-btn { flex: 1; min-height: 40px; border: 0; border-radius: 10px; background: transparent; color: var(--muted); font: inherit; font-weight: 650; font-size: .86rem; cursor: pointer; padding: 4px 6px; transition: background .2s, color .2s, box-shadow .2s; }
.seg-btn.on { background: var(--card); color: var(--ink); box-shadow: var(--shadow); }
.row-link.inactive { opacity: .5; }
.plist .right { gap: 0; }

/* ---------- Kas ---------- */
.cashhero .small-amt { font-size: 1.5rem; }
.cash-actions { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 14px; position: relative; z-index: 1; }
.cash-actions button { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 4px 10px; border: 0; border-radius: 14px; background: rgba(255,255,255,.14); color: #fff; font: inherit; font-size: .74rem; font-weight: 700; cursor: pointer; }
.cash-actions button .ic { width: 22px; height: 22px; }
.cash-actions button:disabled { opacity: .35; }
.cash-actions .pulse-on { background: #fff; color: #08505e; }
.ledger { display: flex; flex-direction: column; }
.ledger .lg-row { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding: 9px 0; border-bottom: 1px dashed var(--line); font-size: .92rem; }
.ledger .lg-row.in b { color: var(--green); } .ledger .lg-row.out b { color: var(--red); }
.ledger .lg-row.head { font-weight: 600; }
.ledger .lg-row.total { border-bottom: 0; border-top: 2px solid var(--ink); margin-top: 4px; padding-top: 12px; font-size: 1.1rem; font-weight: 800; }
.big-money { font-size: 1.6rem !important; font-weight: 800; letter-spacing: -.02em; }
.catchips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip.pick { position: relative; cursor: pointer; padding: 0; font-weight: 650; }
.chip.pick input { position: absolute; opacity: 0; inset: 0; margin: 0; }
.chip.pick span { padding: 8px 14px; border-radius: 99px; }
.chip.pick:has(input:checked) { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.countdiff { margin-top: -4px; }
.datepick .chip { cursor: pointer; }

.once-card { align-items: flex-start; margin-top: 4px; }
.once-card.warn { background: color-mix(in srgb, #f59e0b 14%, var(--card, transparent)); }
.once-card small { line-height: 1.45; margin-top: 2px; }
.once-steps { margin: 8px 0 6px; padding-left: 18px; display: grid; gap: 8px; font-size: .92em; }
.once-steps .btn { margin-left: 6px; vertical-align: middle; }

.cash-actions.three { grid-template-columns: repeat(3, 1fr); }
.catchips .chip.newcat span { font-weight: 700; }
.lastfill { align-self: flex-start; }
/* page-level floating action (e.g. Catat biaya on Kas) */
.pagefab { display: inline-flex; position: fixed; right: 16px; bottom: calc(var(--nav-h) + 16px + env(safe-area-inset-bottom)); z-index: 21; align-items: center; gap: 8px; border: 0; cursor: pointer; font: inherit;
  height: 56px; padding: 0 20px 0 16px; border-radius: 18px; background: linear-gradient(145deg, var(--brand), var(--brand-2)); color: #fff; font-weight: 750; font-size: .98rem;
  box-shadow: 0 10px 26px color-mix(in srgb, var(--brand) 45%, transparent), 0 2px 6px rgba(0,0,0,.18); transition: padding .28s cubic-bezier(.2,.8,.2,1), gap .28s, transform .15s; overflow: hidden; }
@media (min-width: 761px) { .pagefab { bottom: 24px; right: 24px; } }
body:has(.pagefab) main.wrap { padding-bottom: 96px; }

/* filter dropdown pills (Nota) */
.ddrow { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 2px 0 6px; }
.ddpill { display: flex; align-items: center; gap: 8px; min-width: 0; height: 44px; padding: 0 12px; border-radius: 14px; border: 1px solid var(--line); background: var(--card); color: var(--ink-2); font: inherit; font-weight: 650; font-size: .9rem; cursor: pointer; transition: transform .12s, background .2s; }
.ddpill:active { transform: scale(.97); }
.ddpill .grow { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: left; }
.ddpill i { font-style: normal; font-size: .74rem; padding: 1px 7px; border-radius: 99px; background: var(--gray-soft); color: var(--muted); }
.ddpill .dd-caret { transform: rotate(90deg); opacity: .6; flex-shrink: 0; }
.ddpill.on { border-color: color-mix(in srgb, var(--brand) 55%, var(--line)); background: var(--brand-soft); color: var(--ink); }
.ddpill.warn.on { border-color: color-mix(in srgb, var(--amber, #f59e0b) 60%, var(--line)); background: color-mix(in srgb, #f59e0b 14%, var(--card)); }
.dotc { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; background: hsl(var(--h) 65% 55%); }
.opt-count { color: var(--muted); font-weight: 700; font-variant-numeric: tabular-nums; }
.opt.cur .opt-count { color: var(--brand); }

/* outlet switcher */
.outlet-pill { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; padding: 5px 10px 5px 8px; margin-bottom: 4px; border-radius: 99px; border: 1px solid var(--line); background: var(--card); color: var(--ink-2); font: inherit; font-size: .8rem; font-weight: 700; cursor: pointer; }
.outlet-pill span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.outlet-pill .ic.rot90, .ic.rot90 { transform: rotate(90deg); }
.outlet-pill.sm { margin: 0; flex-shrink: 1; min-width: 0; max-width: 46%; }
.outlet-pill:active { transform: scale(.96); }
.outlet-scope { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 10px; }
.mi.sm { width: 34px; height: 34px; border-radius: 11px; }
.opt-list form .opt { width: 100%; }

.catchips .morebtn { background: transparent; border: 0; font: inherit; cursor: pointer; padding: 0; }
.catchips .morebtn span { color: var(--brand); }
/* sheet title stays visible while the sheet scrolls */
dialog.sheet .sheet-head { position: sticky; top: -1px; z-index: 3; background: inherit; margin: -4px -4px 12px; padding: 8px 4px; }

/* field rows that open a sheet (no chips) */
.pickbtn.unset span { color: var(--muted); }
.pickbtn small { font-weight: 500; }
.picksheet .searchbar.insheet { margin: 0 0 12px; display: flex; align-items: center; gap: 10px; padding: 0 14px; min-height: 48px; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: var(--card-2); }
.picksheet .searchbar.insheet input { border: 0; background: transparent; padding: 0; min-height: 44px; flex: 1; box-shadow: none; }
.picksheet .opt { text-align: left; }
.mi.letter { font-weight: 800; font-size: .95rem; }
.opt.newrow { border-style: solid; border-color: color-mix(in srgb, var(--brand) 45%, var(--line)); }
/* due: date tiles + time grid */
.daystrip { display: flex; gap: 8px; overflow-x: auto; margin: 0 -16px; padding: 2px 16px 6px; scrollbar-width: none; scroll-snap-type: x proximity; }
.daystrip::-webkit-scrollbar { display: none; }
.daytile { flex: 0 0 64px; height: 76px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; border-radius: 16px; border: 1.5px solid var(--line); background: var(--card-2); color: var(--ink); font: inherit; cursor: pointer; scroll-snap-align: center; }
.daytile small { font-size: .7rem; color: var(--muted); font-weight: 650; white-space: nowrap; }
.daytile b { font-size: 1.3rem; line-height: 1.15; }
.daytile.cal { flex-basis: 76px; color: var(--brand); }
.daytile.cal small { color: inherit; }
.daytile.on, .timetile.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.daytile.on small { color: rgba(255,255,255,.85); }
.timegrid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.timetile { height: 46px; display: flex; align-items: center; justify-content: center; border-radius: 12px; border: 1.5px solid var(--line); background: var(--card-2); color: var(--ink); font: inherit; font-weight: 700; font-variant-numeric: tabular-nums; cursor: pointer; position: relative; overflow: hidden; }
.timetile.other span { font-size: .82rem; }
.timetile.other input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
@media (prefers-color-scheme: dark) { .daytile.on, .timetile.on { color: #04252b; } .daytile.on small { color: rgba(4,37,43,.75); } }
.picksheet .searchbar.insheet .ic { position: static; transform: none; flex-shrink: 0; }
.picksheet .searchbar.insheet input { padding-left: 0; }
.picksheet .searchbar.insheet { flex-direction: row; }

/* cash received → change */
.cashcalc { display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: 16px; background: var(--card-2); border: 1px solid var(--line); }
.cashtiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.cashtiles .timetile { font-size: .86rem; padding: 0 4px; white-space: nowrap; min-width: 0; }
.cashtiles .timetile:first-child { font-size: .8rem; }
.change { display: flex; align-items: baseline; justify-content: space-between; padding-top: 10px; border-top: 1px dashed var(--line); }
.change span { font-weight: 650; color: var(--ink-2); }
.change b { font-size: 1.6rem; font-weight: 800; letter-spacing: -.02em; color: var(--green); font-variant-numeric: tabular-nums; }
.change.muted b { color: var(--muted); }
.change.short b, .change.short span { color: var(--red); }
@media (max-width: 390px) { .cashtiles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 390px) { .seg-opt span { font-size: .8rem; white-space: nowrap; padding-left: 2px; padding-right: 2px; } }

/* quantity with its unit (kg, pcs…) */
.qty-box { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0; width: 60px; cursor: text; }
.stepper-in .qty-box .qty { width: 60px; min-height: 0; height: 24px; padding: 0; line-height: 24px; }
.qty-unit { font-size: .68rem; font-weight: 700; color: var(--muted); line-height: 1; letter-spacing: .02em; }
.svc.on .qty-unit { color: var(--brand); }

/* offline: status pill + page */
.netbar { position: fixed; z-index: 60; top: calc(8px + env(safe-area-inset-top)); left: 50%; transform: translate(-50%, -140%); display: flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 99px;
  background: var(--ink); color: var(--bg); font-size: .8rem; box-shadow: var(--shadow-lg); transition: transform .3s cubic-bezier(.2,.9,.25,1); white-space: nowrap; }
.netbar.show { transform: translate(-50%, 0); }
.netbar i { width: 8px; height: 8px; border-radius: 50%; background: #f59e0b; }
.netbar.off i { background: #ef4444; animation: netpulse 1.4s infinite; }
.netbar span { opacity: .75; }
@keyframes netpulse { 50% { opacity: .3; } }
.hero.off { background: linear-gradient(145deg, #7c2d12, #9a3412); }
.netcard .cash-actions a { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 4px 10px; border-radius: 14px; background: rgba(255,255,255,.14); color: #fff; font-size: .74rem; font-weight: 700; text-decoration: none; }
.netcard .cash-actions .ic { width: 22px; height: 22px; }
.offsearch { margin-bottom: 10px !important; }
@media print { body > *:not(main) { display: none !important; } .netcard, .section, .offnota .row, .offnota .muted.small { display: none !important; } .offnota { border: 0; box-shadow: none; } }

/* confirm + cancel sheets */
.confirmsheet .confirm-msg { font-size: 1.05rem; font-weight: 650; line-height: 1.45; margin: 8px 2px 18px; color: var(--ink); }
.btn.danger-solid { background: var(--red); border-color: var(--red); color: #fff; min-height: 52px; font-weight: 750; }
.dangerlink { display: flex; align-items: center; justify-content: center; gap: 6px; width: 100%; margin-top: 14px; padding: 12px; border: 0; background: transparent; color: var(--red); font: inherit; font-weight: 650; cursor: pointer; }
.cancel-what { display: flex; flex-direction: column; gap: 12px; padding: 14px; border-radius: 16px; background: var(--card-2); border: 1px solid var(--line); }
.cw-row { display: flex; gap: 12px; align-items: flex-start; }
.cw-row .grow { display: flex; flex-direction: column; gap: 2px; }

/* QRIS */
.qris-preview { display: flex; justify-content: center; padding: 12px; background: #fff; border-radius: 16px; }
.qris-preview img { width: 180px; height: auto; max-height: 260px; object-fit: contain; }
.qris-preview.sm img { width: 120px; }
.filebtn { cursor: pointer; }
.qrisbtn { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 14px; border-radius: 16px; border: 1.5px solid color-mix(in srgb, var(--brand) 50%, var(--line)); background: var(--brand-soft); color: var(--ink); font: inherit; text-align: left; cursor: pointer; text-decoration: none; }
.qrisbtn .grow { display: flex; flex-direction: column; }
.qrisbtn small { color: var(--muted); }
.qrisbtn.muted-q { border-style: dashed; background: transparent; }
.qrisbtn .qr-ic { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; background: var(--brand); color: #fff; }
.menu .menu-btn { display: flex; align-items: center; gap: 12px; width: 100%; border: 0; background: transparent; font: inherit; color: inherit; text-align: left; cursor: pointer; }
dialog.qrisview { width: 100%; max-width: 480px; height: 100dvh; max-height: 100dvh; margin: 0 auto; padding: 20px 20px calc(20px + env(safe-area-inset-bottom)); border: 0; background: #fff; color: #111; display: flex; flex-direction: column; justify-content: space-between; }
dialog.qrisview:not([open]) { display: none; }
dialog.qrisview::backdrop { background: #fff; }
.qv-card { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center; }
.qv-shop { margin: 0; font-weight: 800; font-size: 1.1rem; }
.qv-label { margin: 0; color: #555; font-weight: 600; }
.qv-amt { margin: 4px 0 10px; font-size: 2.4rem; font-weight: 900; letter-spacing: -.02em; }
.qv-card img { width: min(86vw, 380px); height: auto; max-height: 56dvh; object-fit: contain; }
.qv-hint { margin: 10px 0 0; color: #666; font-size: .82rem; max-width: 300px; }
dialog.qrisview .btn { background: #111; color: #fff; border-color: #111; min-height: 52px; }
.menu .menu-btn { padding: 12px 14px; font-weight: 600; border-bottom: 1px solid var(--line); }
.filebtn { flex-direction: row; align-items: center; gap: 8px; color: var(--ink); font-weight: 650; font-size: .92rem; }

/* closed nota: a status block the same size as the main button */
.donebox { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 54px; padding: 8px 16px; border-radius: 16px; background: var(--gray-soft); color: var(--ink-2); }
.donebox .ic { width: 22px; height: 22px; flex-shrink: 0; stroke-width: 2.4; }
.donebox span { display: flex; flex-direction: column; line-height: 1.2; }
.donebox b { font-size: 1rem; font-weight: 750; }
.donebox small { font-size: .78rem; opacity: .8; font-weight: 600; }
.donebox.ok { background: var(--green-soft, #dcfce7); color: var(--green); }
.donebox.bad { background: var(--red-soft); color: var(--red); }
.donebox.info { background: var(--brand-soft); color: var(--ink); }

/* WhatsApp messages */
.wa-list { display: flex; flex-direction: column; gap: 10px; margin-top: 10px; }
.wa-opt { display: flex; flex-direction: column; gap: 6px; padding: 12px; border-radius: 16px; border: 1.5px solid var(--line); background: var(--card-2); color: var(--ink); text-decoration: none; }
.wa-opt.rec { border-color: color-mix(in srgb, #25d366 55%, var(--line)); }
.wa-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.wa-bubble { display: block; padding: 10px 12px; border-radius: 4px 14px 14px 14px; background: #dcf8c6; color: #111b21; font-size: .86rem; line-height: 1.45; max-height: 230px; overflow: auto; word-break: break-word; }
.wa-opt:not(.rec) .wa-bubble { max-height: 96px; }
@media (prefers-color-scheme: dark) { .wa-bubble { background: #005c4b; color: #e9edef; } }
.wa-send { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; border-radius: 12px; background: #1fa855; color: #fff; font-weight: 750; }
.wa-send .ic { width: 20px; height: 20px; }
.wa-tpl { border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; background: var(--card-2); }
.wa-tpl summary { display: flex; flex-direction: column; cursor: pointer; list-style: none; }
.wa-tpl textarea { margin: 10px 0; font-family: ui-monospace, Menlo, Consolas, monospace; font-size: .82rem; }

/* labeled tool buttons in the bottom bar (Cetak, WhatsApp) */
.btn.tool { flex-direction: column; gap: 2px; min-width: 66px; min-height: 54px; padding: 6px 8px; border-radius: 16px; font-size: .72rem; font-weight: 750; line-height: 1; }
.btn.tool .ic { width: 22px; height: 22px; }
.btn.tool.wa { background: #1fa855; border-color: #1fa855; color: #fff; }
.btn.wa-solid { background: #1fa855; border-color: #1fa855; color: #fff; }
.btn.wa-solid .ic { width: 20px; height: 20px; }
/* after-save sheet */
.saved-head { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; margin: 4px 0 16px; }
.saved-head h2 { margin: 6px 0 0; font-size: 1.3rem; }
.saved-head p { margin: 0; }
.saved-ic { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: var(--green-soft); color: var(--green); }
.saved-ic .ic { width: 30px; height: 30px; stroke-width: 2.6; }
[data-print-now].done { background: var(--card-2); color: var(--ink); border-color: var(--line); }

/* customer picker on Nota baru */
.cust-hint { margin: 8px 2px 0; }
.suggest .field-label { margin: 10px 2px 2px; }
.person.addnew { border: 1.5px dashed color-mix(in srgb, var(--brand) 55%, var(--line)); background: var(--brand-soft); }
.person.addnew.solo { border-style: solid; }
.avatar.plus { background: var(--brand); color: #fff; font-size: 1.3rem; font-weight: 700; }
.nomatch { margin: 10px 2px 6px; }
.newcust { display: flex; flex-direction: column; gap: 12px; }
.newcust-head { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 14px; background: var(--brand-soft); }
.newcust-head .grow { display: flex; flex-direction: column; }
#newAv { background: var(--brand); color: #fff; }

.print-pair .btn { font-size: .9rem; gap: 6px; }
.print-pair .btn .ic { width: 18px; height: 18px; }

.print-set { display: flex; flex-direction: column; gap: 10px; }
.print-set .btn { gap: 8px; }
.print-set .btn .ic { width: 20px; height: 20px; }
.print-set .btn.printed::after { content: '✓'; margin-left: 4px; opacity: .8; }

/* security pages */
.warnbox { background: color-mix(in srgb, #f59e0b 14%, var(--card)); margin-bottom: 12px; }
.steps2 { margin: 0; padding-left: 20px; display: grid; gap: 8px; font-size: .9rem; color: var(--ink-2); }
.totp-qr svg { width: 200px; height: 200px; }
.mono { font-family: ui-monospace, Menlo, Consolas, monospace; letter-spacing: .05em; }
input.otp { font-size: 1.6rem; letter-spacing: .3em; text-align: center; font-weight: 800; }
.person.act.bad b { color: var(--red); }
.person.act .grow { display: flex; flex-direction: column; gap: 1px; }

/* step-by-step guide */
.wizard .wiz-steps { margin: 4px 0 18px; }
.wizard [data-step] { display: flex; flex-direction: column; gap: 12px; min-height: 180px; }
.wizard [data-step].hide { display: none; }
.wizard .wiz-title { margin: 0; font-size: 1.1rem; }
.wizard .wiz-text { margin: 0; color: var(--ink-2); line-height: 1.5; }
.wizard .wiz-nav { display: flex; gap: 10px; margin-top: 18px; }
.wizard .wiz-nav .btn { flex: 1; min-height: 50px; }
.wizard .wiz-nav .invisible { visibility: hidden; }
.wiz-big { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 56px; border-radius: 16px; font-weight: 750; text-decoration: none; }
.wiz-wait { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 14px; background: var(--card-2); color: var(--ink-2); font-size: .9rem; }
.wiz-wait .spin { width: 18px; height: 18px; border-radius: 50%; border: 2.5px solid var(--line); border-top-color: var(--brand); animation: wizspin .8s linear infinite; flex-shrink: 0; }
@keyframes wizspin { to { transform: rotate(360deg); } }
.wiz-ok { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; padding: 8px 0; }
.tg-btn { background: #229ed9; color: #fff; }
.mini-steps { margin: 0; padding-left: 20px; display: grid; gap: 6px; color: var(--ink-2); font-size: .92rem; }

.line-sep { height: 1px; background: var(--line); margin: 4px 0; }
.block { display: block; }
.mini-steps { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 8px; color: var(--ink-2); line-height: 1.45; }
.wizard .opt-list .opt { min-height: 64px; }

/* order kind: express / kiloan / satuan — one icon, one colour each */
.kind { --kc: var(--brand); width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; flex-shrink: 0; color: var(--kc); background: color-mix(in srgb, var(--kc) 12%, var(--card)); }
.kind .ic { width: 22px; height: 22px; }
.kind.k-x { --kc: #e08600; }
.kind.k-pcs { --kc: #7c5cd6; }
.kind.xs { width: 22px; height: 22px; border-radius: 7px; display: inline-grid; vertical-align: -5px; }
.kind.xs .ic { width: 14px; height: 14px; }
.kind.k-x .ic { fill: currentColor; }
@media (prefers-color-scheme: dark) { .kind.k-x { --kc: #ffb340; } .kind.k-pcs { --kc: #b29cff; } }
.svc-name { display: flex; align-items: center; gap: 7px; }
.svc-name span { min-width: 0; }
.kind-legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: .78rem; color: var(--muted); }
.kind-legend span { display: inline-flex; align-items: center; gap: 5px; }
.orow { padding: 13px 16px; }

/* activity log: quiet list, grouped by day, only warnings get colour */
.log-day { margin: 18px 4px 8px; font-size: .8rem; font-weight: 650; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.loglist { padding: 0 16px; }
.log-row { display: flex; align-items: flex-start; gap: 12px; padding: 13px 0; }
.log-row + .log-row { border-top: 1px solid var(--line); }
.log-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.log-main b { font-size: .95rem; font-weight: 650; }
.log-target { font-size: .88rem; color: var(--ink-2); overflow-wrap: anywhere; }
.log-main small { color: var(--muted); font-size: .8rem; overflow-wrap: anywhere; }
.log-row time { flex-shrink: 0; color: var(--muted); font-size: .82rem; font-variant-numeric: tabular-nums; padding-top: 2px; }
.log-row.bad b { color: var(--red); }
.log-row.bad b::before { content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--red); margin-right: 7px; vertical-align: 2px; }
.plist > .person:not(.row-link) { padding: 12px 14px; border-bottom: 1px solid var(--line); }
.plist > .person:not(.row-link):last-child { border-bottom: 0; }
.card .plist { box-shadow: none; }

/* service picker grouped by category */
.svc-search { margin: 4px 0 10px; }
.svc-groups { display: flex; flex-direction: column; gap: 6px; }
.svc-group { --gc: hsl(var(--gh) 38% 48%); }
@media (prefers-color-scheme: dark) { .svc-group { --gc: hsl(var(--gh) 42% 64%); } }
.svc-gh { width: 100%; display: flex; align-items: center; gap: 9px; padding: 10px 4px; background: none; border: 0; color: var(--ink); font: inherit; cursor: pointer; text-align: left; }
.svc-gh b { font-size: .95rem; }
.svc-gh .gdot { width: 9px; height: 9px; border-radius: 50%; background: var(--gc); flex-shrink: 0; }
.svc-gsel { color: var(--gc); font-weight: 700; }
.svc-gh .gcaret { color: var(--muted); transform: rotate(90deg); transition: transform .2s; }
.svc-group.open .gcaret { transform: rotate(-90deg); }
.svc-group:not(.open) .svc-list { display: none; }
.svc-group .svc { border-left: 3px solid var(--gc); }
.svc-group .svc-list { padding-bottom: 6px; }
.svc.hide { display: none; }
.svc-cat { display: flex; align-items: center; gap: 8px; --gc: hsl(var(--gh) 38% 48%); }
.log-day span { font-weight: 500; }
.svc-cat .gdot { width: 8px; height: 8px; border-radius: 50%; background: var(--gc); }
@media (prefers-color-scheme: dark) { .svc-cat { --gc: hsl(var(--gh) 42% 64%); } }
/* service type: a soft name-tag in a fixed spot, before the status */
.kind-tag { display: inline-flex; align-items: center; flex-shrink: 0; padding: 3px 8px; border-radius: 7px; font-size: .72rem; font-weight: 650; white-space: nowrap;
  color: hsl(var(--gh, 200) 45% 32%); background: hsl(var(--gh, 200) 45% 50% / .13); }
@media (prefers-color-scheme: dark) { .kind-tag { color: hsl(var(--gh, 200) 50% 74%); background: hsl(var(--gh, 200) 40% 55% / .16); } }
.orow-meta { gap: 6px; }
/* service type = coloured left edge, same as the service tiles in Nota baru */
.orow.typed { --gc: hsl(var(--gh) 38% 48%); border-left: 3px solid var(--gc); }
@media (prefers-color-scheme: dark) { .orow.typed { --gc: hsl(var(--gh) 42% 64%); } }
.orow.typed.late { border-color: var(--line); border-left-color: var(--gc); }
.orow.typed.late::before { display: none; }
