/* SI-SURAT UTD — tema korporat biru/teal (formal, kesan tata usaha & arsip)
   Kanvas abu-biru muda, panel putih ber-hairline, sidebar navy, aksen biru laut + teal. */
:root {
  --bg: #f2f5fa;
  --bg-2: #f8fafc;
  --panel: #ffffff;
  --panel-2: #f7f9fc;
  --line: #dfe6f0;
  --line-soft: #eef2f8;
  --ink: #0e2438;
  --ink-2: #33495e;
  --muted: #5b6d81;
  --primary: #0d5c8f;
  --primary-2: #1179b5;
  --teal: #0f7d74;
  --navy: #0b2b45;
  --navy-2: #0f3c5e;
  --ok: #0b6b4a;
  --warn: #96610a;
  --bad: #ac2b21;
  --info: #0d5c8f;
  --gold: #a07a2c;
  --radius: 12px;
  --radius-sm: 8px;
  --sidebar: 252px;
  --shadow-sm: 0 1px 2px rgba(14, 36, 56, .06);
  --shadow: 0 1px 2px rgba(14, 36, 56, .05), 0 10px 26px -16px rgba(14, 36, 56, .28);
  --shadow-lg: 0 2px 6px rgba(14, 36, 56, .07), 0 24px 54px -26px rgba(14, 36, 56, .35);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 13.5px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; font-weight: 500; }
a:hover { color: var(--teal); }
h1, h2, h3, h4 { color: var(--ink); }

/* ---------- layout ---------- */
.layout { display: flex; min-height: 100vh; }

.sidebar {
  width: var(--sidebar);
  flex: 0 0 var(--sidebar);
  background-color: var(--navy);
  background-image: linear-gradient(180deg, #0b2b45 0%, #0d3552 55%, #0a2d47 100%);
  color: #d7e5f2;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  border-right: 1px solid rgba(255, 255, 255, .06);
}
.sidebar::-webkit-scrollbar { width: 6px; }
.sidebar::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .16); border-radius: 6px; }

.brand { display: flex; gap: 11px; align-items: center; padding: 18px 16px 16px; border-bottom: 1px solid rgba(255, 255, 255, .08); }
.brand-mark {
  width: 38px; height: 38px; border-radius: 9px; display: grid; place-items: center;
  background-color: #0f7d74;
  background-image: linear-gradient(135deg, #127f96, #0f7d74 55%, #0b665e);
  font-weight: 800; color: #fff; font-size: 11.5px; letter-spacing: .02em;
  box-shadow: 0 8px 16px -8px rgba(0, 0, 0, .55);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.brand-text strong { font-size: 13px; letter-spacing: .12em; color: #fff; }
.brand-text span { font-size: 10px; color: #9db8d0; letter-spacing: .01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.nav { padding: 12px 10px 18px; flex: 1; }
.nav-group { margin-bottom: 14px; }
.nav-label {
  font-size: 9.5px; letter-spacing: .14em; text-transform: uppercase; color: #7fa0bd;
  font-weight: 700; padding: 4px 10px 6px;
}
.nav-link {
  display: flex; align-items: center; gap: 9px; padding: 8px 10px; border-radius: 8px;
  color: #cfe0ee; font-size: 12.5px; font-weight: 500; margin-bottom: 2px;
  border: 1px solid transparent; transition: background .15s, color .15s;
}
.nav-link:hover { background: rgba(255, 255, 255, .07); color: #fff; }
.nav-link.is-active {
  background: linear-gradient(90deg, rgba(17, 121, 181, .35), rgba(15, 125, 116, .22));
  border-color: rgba(255, 255, 255, .14); color: #fff; font-weight: 650;
  box-shadow: inset 3px 0 0 #41c1b0;
}
.nav-count {
  margin-left: auto; font-style: normal; font-size: 10px; font-weight: 700;
  background: #f0b429; color: #3a2a00; border-radius: 20px; padding: 1px 6px; min-width: 18px; text-align: center;
}
.ico { width: 16px; height: 16px; flex: 0 0 16px; opacity: .95; }
.nav-link .ico { width: 15px; height: 15px; flex-basis: 15px; }

.sidebar-foot { border-top: 1px solid rgba(255, 255, 255, .08); padding: 12px; display: grid; gap: 6px; }
.who { display: flex; gap: 9px; align-items: center; padding: 2px 2px 8px; }
.who-avatar {
  width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255, 255, 255, .12); color: #fff; font-size: 11px; font-weight: 700;
  border: 1px solid rgba(255, 255, 255, .18); flex: 0 0 32px;
}
.who div { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.who strong { font-size: 11.5px; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.who span { font-size: 10px; color: #9db8d0; }
.sidebar-foot .btn-ghost { color: #cfe0ee; border-color: rgba(255, 255, 255, .16); background: rgba(255, 255, 255, .04); }
.sidebar-foot .btn-ghost:hover { color: #fff; background: rgba(255, 255, 255, .1); border-color: rgba(255, 255, 255, .3); }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }

.topbar {
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  padding: 12px 22px;
  display: flex; align-items: center; gap: 12px;
  position: sticky; top: 0; z-index: 20;
}
.topbar-title h1 { margin: 0; font-size: 16px; font-weight: 700; letter-spacing: -.01em; color: var(--navy); }
.topbar-title p { margin: 2px 0 0; font-size: 11.5px; color: var(--muted); }
.topbar-meta { margin-left: auto; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.nav-burger { display: none; cursor: pointer; font-size: 18px; color: var(--ink-2); padding: 2px 4px; }

.pill {
  display: inline-flex; align-items: center; gap: 5px;
  border: 1px solid var(--line); background: #fff; color: var(--ink-2);
  border-radius: 20px; padding: 3px 10px; font-size: 10.5px; font-weight: 650; letter-spacing: .03em;
}
.pill-soft { background: var(--panel-2); color: var(--muted); }
.pill-teal { background: #effaf8; border-color: #c8ece7; color: #0a655d; }

.content { padding: 20px 22px 56px; max-width: 1500px; width: 100%; }

/* ---------- flash ---------- */
.flash {
  border: 1px solid var(--line); background: #fff; border-radius: var(--radius-sm);
  padding: 10px 13px; margin-bottom: 14px; font-size: 12.5px; font-weight: 500;
  display: flex; gap: 8px; align-items: flex-start;
}
.flash-ok { border-color: #c3e7d8; background: #f2fbf7; color: #0a5c40; }
.flash-bad { border-color: #f3c7c2; background: #fdf4f3; color: #8f2118; }
.flash-warn { border-color: #f0dfba; background: #fdf9ef; color: #7a4f05; }

/* ---------- kartu & grid ---------- */
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(178px, 1fr)); gap: 14px; margin-bottom: 20px; }
.kpi {
  display: block; position: relative; background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 14px 15px 14px 18px; box-shadow: var(--shadow-sm);
  overflow: hidden; color: inherit;
}
a.kpi:hover { color: inherit; box-shadow: var(--shadow); border-color: #c9d7e6; transform: translateY(-1px); }
.kpi::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px;
  background: linear-gradient(180deg, #8aa6bd, #c3d3e1);
}
.kpi-label { font-size: 9.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 750; }
.kpi-value { font-size: 26px; font-weight: 750; letter-spacing: -.025em; margin-top: 4px; line-height: 1.1; color: var(--navy); }
.kpi-value small { font-size: 12px; font-weight: 600; color: var(--muted); letter-spacing: 0; }
.kpi-hint { font-size: 11px; color: var(--muted); margin-top: 4px; }
.kpi.accent::before { background: linear-gradient(180deg, var(--primary), var(--primary-2)); }
.kpi.accent .kpi-value { color: var(--primary); }
.kpi.teal::before { background: linear-gradient(180deg, var(--teal), #27b3a3); }
.kpi.teal .kpi-value { color: #0a655d; }
.kpi.ok::before { background: linear-gradient(180deg, #0b7a54, #41b98c); }
.kpi.ok .kpi-value { color: #0a5c40; }
.kpi.warn::before { background: linear-gradient(180deg, #b57a08, #e3ac3c); }
.kpi.warn .kpi-value { color: #7a4f05; }
.kpi.bad::before { background: linear-gradient(180deg, #b02a1f, #dd6a5e); }
.kpi.bad .kpi-value { color: #8f2118; }

.panel {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); overflow: hidden;
}
.panel + .panel { margin-top: 18px; }
.panel-head {
  display: flex; align-items: center; gap: 10px; padding: 12px 16px;
  border-bottom: 1px solid var(--line-soft); background: linear-gradient(180deg, #fbfdff, #fff);
}
.panel-head h2 { margin: 0; font-size: 12.5px; font-weight: 750; letter-spacing: .01em; color: var(--navy); display: flex; align-items: center; gap: 7px; }
.panel-head .sub { font-size: 11px; color: var(--muted); }
.panel-head .right { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.panel-body { padding: 16px; }
.panel-body.tight { padding: 0; }

.grid { display: grid; gap: 18px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-2-1 { grid-template-columns: 1.6fr 1fr; }
.grid-1-2 { grid-template-columns: 1fr 1.6fr; }

/* ---------- tabel ---------- */
.table-wrap { overflow: auto; }
table.data { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 12.2px; }
table.data thead th {
  position: sticky; top: 0; z-index: 2; text-align: left;
  font-size: 9.5px; letter-spacing: .11em; text-transform: uppercase; color: var(--muted);
  font-weight: 750; padding: 9px 12px; background: #f6f9fc; border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
table.data tbody td { padding: 10px 12px; border-bottom: 1px solid var(--line-soft); vertical-align: top; color: var(--ink-2); }
table.data tbody tr:hover td { background: #f8fbfe; }
table.data tbody tr:last-child td { border-bottom: 0; }
table.data td.num, table.data th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
table.data td.center, table.data th.center { text-align: center; }
table.data strong { color: var(--ink); font-weight: 650; }
table.data .wrap { min-width: 250px; }
.empty-cell { text-align: center; color: var(--muted); padding: 26px 12px !important; font-size: 12px; }
.mono { font-variant-numeric: tabular-nums; }
.nowrap { white-space: nowrap; }
.small { font-size: 11.5px; }
.muted { color: var(--muted); }

/* ---------- badge & chip ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 6px;
  font-size: 10.5px; font-weight: 700; letter-spacing: .01em; border: 1px solid var(--line);
  background: #f5f7fa; color: var(--ink-2); white-space: nowrap;
}
.badge-ok { color: #0a5c40; background: #eefaf4; border-color: #c3e7d8; }
.badge-warn { color: #7a4f05; background: #fdf7ea; border-color: #f0dfba; }
.badge-bad { color: #8f2118; background: #fdf4f3; border-color: #f3c7c2; }
.badge-info { color: #0b4f7c; background: #eef6fc; border-color: #c8e0f2; }
.badge-muted { color: #54677a; background: #f4f7fa; border-color: #e3eaf2; }

.chip {
  display: inline-flex; align-items: center; gap: 5px; padding: 4px 9px; border-radius: 20px;
  border: 1px solid var(--line); background: #fff; font-size: 11px; font-weight: 600; color: var(--ink-2);
}
.chip-muted { background: var(--panel-2); color: var(--muted); }

/* ---------- tombol ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 8px 13px; min-height: 34px; border-radius: var(--radius-sm); border: 1px solid var(--line);
  background: #fff; color: var(--ink-2); font-size: 12px; font-weight: 650;
  font-family: inherit; cursor: pointer; transition: all .15s; line-height: 1.2;
  text-decoration: none;
}
.btn:hover { border-color: #b9cbdc; background: #fbfdff; color: var(--primary); box-shadow: var(--shadow-sm); }
.btn .ico { width: 14px; height: 14px; flex-basis: 14px; }
.btn-primary {
  background-color: var(--primary);
  background-image: linear-gradient(135deg, var(--primary-2), var(--primary));
  border-color: #0b4f7c; color: #fff; box-shadow: 0 6px 14px -8px rgba(13, 92, 143, .9);
}
.btn-primary:hover { color: #fff; background-image: linear-gradient(135deg, #1384c2, #0d5c8f); border-color: #0b4f7c; }
.btn-teal {
  background-color: var(--teal); background-image: linear-gradient(135deg, #12978c, #0b6b63);
  border-color: #0a5f58; color: #fff;
}
.btn-teal:hover { color: #fff; background-image: linear-gradient(135deg, #17a89b, #0c746c); }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--ink-2); }
.btn-sm { padding: 6px 10px; min-height: 29px; font-size: 11px; border-radius: 7px; }
.btn-danger { color: #8f2118; border-color: #f3c7c2; background: #fdf4f3; }
.btn-danger:hover { color: #7d1a12; background: #fbe9e7; border-color: #e9a79f; }
.btn[disabled], .btn.is-disabled { opacity: .5; pointer-events: none; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* ---------- form ---------- */
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
.form-grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 16px; }
.form-grid .full, .form-grid-3 .full { grid-column: 1 / -1; }
.field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.field > label {
  font-size: 10px; font-weight: 750; letter-spacing: .09em; text-transform: uppercase; color: var(--muted);
}
.field .hint { font-size: 10.5px; color: var(--muted); }
.field .req { color: var(--bad); }
input[type=text], input[type=password], input[type=date], input[type=number], input[type=search],
input[type=email], input[type=tel], input[type=url], input[type=file], select, textarea {
  width: 100%; padding: 8px 10px; border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: #fff; color: var(--ink); font-size: 12.5px; font-family: inherit;
  transition: border-color .15s, box-shadow .15s;
}
input::placeholder, textarea::placeholder { color: #9aabbb; }
input:hover, select:hover, textarea:hover { border-color: #c4d3e2; }
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--primary-2); box-shadow: 0 0 0 3px rgba(17, 121, 181, .13);
}
textarea { min-height: 120px; resize: vertical; line-height: 1.65; font-size: 12.5px; }
textarea.mono-area { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; line-height: 1.6; }
select { appearance: none; 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='%2364788d' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 10px center; padding-right: 28px; }
.form-actions { display: flex; gap: 8px; flex-wrap: wrap; padding-top: 16px; margin-top: 16px; border-top: 1px solid var(--line-soft); }
.inline-form { display: inline; }

/* ---------- filter bar ---------- */
.filter-bar {
  display: flex; gap: 8px; align-items: flex-end; flex-wrap: wrap;
  padding: 12px 14px; background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); margin-bottom: 16px; box-shadow: var(--shadow-sm);
}
.filter-bar .field { flex: 0 1 190px; }
.filter-bar .field.wide { flex: 1 1 260px; }
.filter-bar .btn { margin-bottom: 1px; }

/* ---------- misc ---------- */
.section-title { display: flex; align-items: center; gap: 10px; margin: 26px 0 14px; }
.section-title h2 { margin: 0; font-size: 13px; letter-spacing: .04em; text-transform: uppercase; color: var(--navy); font-weight: 750; }
.section-title .line { flex: 1; height: 1px; background: var(--line); }

.meta-list { display: grid; gap: 10px; }
.meta-row { display: grid; grid-template-columns: 132px 1fr; gap: 12px; align-items: baseline; padding-bottom: 9px; border-bottom: 1px dashed var(--line-soft); }
.meta-row:last-child { border-bottom: 0; padding-bottom: 0; }
.meta-row dt { font-size: 10px; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); font-weight: 750; margin: 0; }
.meta-row dd { margin: 0; font-size: 12.5px; color: var(--ink); font-weight: 550; word-break: break-word; }

.nomor-chip {
  display: inline-block; font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 11.5px;
  background: #f4f8fc; border: 1px solid #dbe7f2; color: #0b4f7c; border-radius: 6px; padding: 1px 6px; font-weight: 650;
}

.timeline { position: relative; padding-left: 20px; display: grid; gap: 14px; }
.timeline::before { content: ""; position: absolute; left: 5px; top: 4px; bottom: 4px; width: 2px; background: var(--line); }
.timeline-item { position: relative; }
.timeline-item::before {
  content: ""; position: absolute; left: -19px; top: 4px; width: 9px; height: 9px; border-radius: 50%;
  background: #fff; border: 2px solid var(--primary-2);
}
.timeline-item .t { font-size: 12px; font-weight: 650; color: var(--ink); }
.timeline-item .d { font-size: 11px; color: var(--muted); }

.note-box {
  border: 1px solid var(--line); border-left: 3px solid var(--teal); background: #f8fcfb;
  border-radius: var(--radius-sm); padding: 11px 13px; font-size: 12px; color: var(--ink-2);
}
.note-box.warn { border-left-color: #b57a08; background: #fdfaf3; }
.note-box.bad { border-left-color: #b02a1f; background: #fdf5f4; }
.note-box strong { color: var(--ink); }

.isi-surat {
  white-space: pre-wrap; font-size: 12.5px; line-height: 1.75; color: var(--ink);
  background: #fdfefe; border: 1px solid var(--line-soft); border-radius: var(--radius-sm);
  padding: 14px 16px; font-family: "Times New Roman", Georgia, serif;
}

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 16px; overflow-x: auto; }
.tab {
  padding: 8px 13px; border-radius: 8px 8px 0 0; font-size: 12px; font-weight: 650; color: var(--muted);
  border: 1px solid transparent; border-bottom: 0; white-space: nowrap;
}
.tab:hover { color: var(--primary); background: #f6fafd; }
.tab.is-active { background: #fff; border-color: var(--line); color: var(--primary); box-shadow: 0 -2px 0 var(--primary) inset; }

.chart-box { position: relative; height: 240px; }
.chart-box.short { height: 200px; }

.progress { height: 6px; border-radius: 6px; background: #e9eff5; overflow: hidden; min-width: 80px; }
.progress i { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--primary), var(--teal)); }

/* ---------- login ---------- */
.login-wrap {
  min-height: 100vh; display: grid; place-items: center; padding: 24px;
  background:
    radial-gradient(760px 420px at 12% 0%, rgba(17, 121, 181, .18), transparent 62%),
    radial-gradient(680px 420px at 92% 100%, rgba(15, 125, 116, .16), transparent 60%),
    linear-gradient(160deg, #0b2b45, #0e3f5f 55%, #0a2d47);
}
.login-card {
  width: 100%; max-width: 412px; background: #fff; border-radius: 16px; padding: 28px 28px 24px;
  box-shadow: 0 30px 70px -30px rgba(0, 0, 0, .6); border: 1px solid rgba(255, 255, 255, .3);
}
.login-brand { display: flex; gap: 12px; align-items: center; margin-bottom: 22px; }
.login-mark {
  width: 46px; height: 46px; border-radius: 11px; display: grid; place-items: center; flex: 0 0 46px;
  background-image: linear-gradient(135deg, #127f96, #0f7d74); color: #fff; font-weight: 800; font-size: 13px;
}
.login-brand strong { display: block; font-size: 14px; letter-spacing: .1em; color: var(--navy); }
.login-brand span { font-size: 11px; color: var(--muted); }
.login-card h1 { margin: 0 0 4px; font-size: 17px; color: var(--navy); }
.login-card .lead { margin: 0 0 18px; font-size: 12px; color: var(--muted); }
.login-card .field + .field { margin-top: 12px; }
.login-card .btn-primary { width: 100%; margin-top: 18px; padding: 10px; font-size: 12.5px; }
.login-foot { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line-soft); font-size: 11px; color: var(--muted); text-align: center; line-height: 1.6; }

/* ---------- modal sederhana (CSS-only) ---------- */
.modal-toggle { display: none; }
.modal { position: fixed; inset: 0; z-index: 60; display: none; }
.modal-toggle:checked + .modal { display: grid; place-items: center; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(11, 43, 69, .55); backdrop-filter: blur(2px); }
.modal-card {
  position: relative; width: min(560px, calc(100% - 28px)); background: #fff; border-radius: 14px;
  box-shadow: var(--shadow-lg); overflow: hidden; max-height: calc(100vh - 60px); display: flex; flex-direction: column;
}
.modal-head { display: flex; align-items: center; gap: 10px; padding: 13px 16px; border-bottom: 1px solid var(--line-soft); }
.modal-head strong { font-size: 13px; color: var(--navy); }
.modal-x { margin-left: auto; cursor: pointer; font-size: 20px; line-height: 1; color: var(--muted); border: 0; background: none; }
.modal-body { padding: 16px; overflow: auto; }
.modal-foot { padding: 12px 16px; border-top: 1px solid var(--line-soft); display: flex; gap: 8px; justify-content: flex-end; background: #fbfdff; }

/* ---------- WhatsApp ---------- */
.wa-preview {
  white-space: pre-wrap; background: #e9f7ef; border: 1px solid #cfe9da; border-radius: 10px;
  padding: 12px 14px; font-size: 12px; line-height: 1.6; color: #14512f;
  font-family: inherit;
}
.wa-bubble-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

/* ---------- responsif ---------- */
.nav-toggle-input:checked ~ .layout .sidebar { transform: translateX(0); }

@media (max-width: 1080px) {
  .grid-2-1, .grid-1-2 { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  .sidebar {
    position: fixed; z-index: 50; left: 0; top: 0; bottom: 0; height: 100%;
    transform: translateX(-100%); transition: transform .22s ease; box-shadow: var(--shadow-lg);
  }
  .nav-burger { display: block; }
  .content { padding: 14px 14px calc(84px + env(safe-area-inset-bottom)); }
  .topbar { padding: 10px 14px; }
  .grid-2, .form-grid, .form-grid-3 { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
  .kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .kpi-value { font-size: 22px; }
  .meta-row { grid-template-columns: 1fr; gap: 2px; }
  .topbar-meta .btn span { display: none; }
}

/* bottom nav — hanya tampil di layar kecil */
.bottom-nav { display: none; }
@media (max-width: 900px) {
  .bottom-nav {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    background: rgba(255, 255, 255, .97); backdrop-filter: blur(10px);
    border-top: 1px solid var(--line); padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
    justify-content: space-around; box-shadow: 0 -8px 20px -16px rgba(14, 36, 56, .4);
  }
  .bottom-nav-item {
    display: flex; flex-direction: column; align-items: center; gap: 2px; flex: 1;
    font-size: 9.5px; font-weight: 650; color: var(--muted); padding: 5px 0; border-radius: 8px;
  }
  .bottom-nav-item .ico { width: 18px; height: 18px; flex-basis: 18px; }
  .bottom-nav-item.is-active { color: var(--primary); background: #eef6fc; }
}

/* ---------- cetak ---------- */
@media print {
  .no-print, .sidebar, .topbar, .bottom-nav { display: none !important; }
  body { background: #fff; }
  .content { padding: 0; }
  .panel { box-shadow: none; border-color: #ddd; }
  a { color: inherit; }
}
