/* SK Tasking — design system
   Monokrom: putih murni (terang) & hitam pekat (gelap). Tanpa emoji, ikon garis 1.75px. */

@font-face { font-family: "Inter"; font-style: normal; font-weight: 400; font-display: swap; src: url(../fonts/inter-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 500; font-display: swap; src: url(../fonts/inter-latin-500-normal.woff2) format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 600; font-display: swap; src: url(../fonts/inter-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 700; font-display: swap; src: url(../fonts/inter-latin-700-normal.woff2) format("woff2"); }

:root, [data-theme="light"] {
  --bg: #ffffff;
  --bg-2: #fafafa;
  --bg-3: #f4f4f4;
  --bg-elev: #ffffff;
  --hover: rgba(0, 0, 0, .04);
  --active: rgba(0, 0, 0, .07);
  --line: #ededed;
  --line-2: #e2e2e2;
  --line-3: #cdcdcd;
  --fg: #0a0a0a;
  --fg-2: #525252;
  --fg-3: #8a8a8a;
  --fg-4: #bdbdbd;
  --primary: #0a0a0a;
  --primary-fg: #ffffff;
  --primary-hover: #2a2a2a;
  --danger: #d92d20;
  --danger-bg: rgba(217, 45, 32, .07);
  --warn: #b54708;
  --warn-bg: rgba(181, 71, 8, .08);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .05);
  --shadow: 0 1px 2px rgba(0, 0, 0, .04), 0 6px 20px rgba(0, 0, 0, .07);
  --shadow-lg: 0 2px 6px rgba(0, 0, 0, .05), 0 24px 60px rgba(0, 0, 0, .14);
  --ring: 0 0 0 3px rgba(0, 0, 0, .09);
  --overlay: rgba(10, 10, 10, .32);
  --scroll: #d4d4d4;
  color-scheme: light;
}

[data-theme="dark"] {
  --bg: #000000;
  --bg-2: #0a0a0a;
  --bg-3: #141414;
  --bg-elev: #0c0c0c;
  --hover: rgba(255, 255, 255, .06);
  --active: rgba(255, 255, 255, .1);
  --line: #1a1a1a;
  --line-2: #262626;
  --line-3: #3a3a3a;
  --fg: #fafafa;
  --fg-2: #a3a3a3;
  --fg-3: #6f6f6f;
  --fg-4: #474747;
  --primary: #fafafa;
  --primary-fg: #000000;
  --primary-hover: #dcdcdc;
  --danger: #ff6b5f;
  --danger-bg: rgba(255, 107, 95, .1);
  --warn: #f5b041;
  --warn-bg: rgba(245, 176, 65, .1);
  --shadow-sm: 0 0 0 1px rgba(255, 255, 255, .04);
  --shadow: 0 0 0 1px #222, 0 10px 30px rgba(0, 0, 0, .7);
  --shadow-lg: 0 0 0 1px #262626, 0 30px 80px rgba(0, 0, 0, .8);
  --ring: 0 0 0 3px rgba(255, 255, 255, .14);
  --overlay: rgba(0, 0, 0, .7);
  --scroll: #2e2e2e;
  color-scheme: dark;
}

:root {
  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius: 10px;
  --radius-lg: 14px;
  --radius-xl: 18px;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Code", "JetBrains Mono", Menlo, Consolas, monospace;
  --side-w: 248px;
  --top-h: 56px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --safe-b: env(safe-area-inset-bottom, 0px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.5;
  color: var(--fg);
  background: var(--bg);
  font-feature-settings: "cv11", "ss01", "ss03";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, h4 { margin: 0; font-weight: 600; letter-spacing: -.018em; line-height: 1.25; }
p { margin: 0; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
button:disabled { cursor: not-allowed; }
img { max-width: 100%; display: block; }
code { font-family: var(--mono); font-size: .88em; }
[hidden] { display: none !important; }
::selection { background: var(--fg); color: var(--bg); }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 2px; border-radius: 6px; }
.input:focus-visible, .rte:focus-visible, .tm-title:focus-visible, [contenteditable]:focus-visible, .cmdk-input input:focus-visible, .sk-text-input:focus-visible, .auth-card .input:focus-visible { outline: none; }
* { scrollbar-width: thin; scrollbar-color: var(--scroll) transparent; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--scroll); border-radius: 10px; border: 3px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-track { background: transparent; }

.muted { color: var(--fg-3); }
.small { font-size: 12.5px; }
.nowrap { white-space: nowrap; }
.tnum { font-variant-numeric: tabular-nums; }
.grow { flex: 1 1 auto; min-width: 0; }
.row { display: flex; align-items: center; gap: 8px; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.stack > .segmented { align-self: flex-start; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.text-danger { color: var(--danger); }
.text-warn { color: var(--warn); }

/* ---------- Ikon ---------- */
.i {
  width: 18px; height: 18px; flex: none;
  fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round;
  vertical-align: middle;
}
.i-sm { width: 15px; height: 15px; }
.i-xs { width: 13px; height: 13px; }
.i-lg { width: 22px; height: 22px; }
.logo-mark { width: 30px; height: 30px; color: var(--fg); flex: none; }

/* ---------- Tombol ---------- */
.btn {
  --h: 34px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: var(--h); padding: 0 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line-2);
  background: var(--bg);
  color: var(--fg);
  font-size: 13.5px; font-weight: 500; letter-spacing: -.005em;
  white-space: nowrap; user-select: none;
  transition: background .15s, border-color .15s, color .15s, box-shadow .15s, transform .08s;
  box-shadow: var(--shadow-sm);
}
.btn .i { width: 16px; height: 16px; }
.btn:hover { background: var(--bg-3); border-color: var(--line-3); }
.btn:active { transform: translateY(.5px); }
.btn:disabled { opacity: .45; }
.btn-primary { background: var(--primary); color: var(--primary-fg); border-color: var(--primary); }
.btn-primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); }
.btn-ghost { background: transparent; border-color: transparent; box-shadow: none; color: var(--fg-2); }
.btn-ghost:hover { background: var(--hover); border-color: transparent; color: var(--fg); }
.btn-danger { color: var(--danger); }
.btn-danger:hover { background: var(--danger-bg); border-color: var(--danger); }
.btn-danger-solid { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn-danger-solid:hover { filter: brightness(.94); background: var(--danger); border-color: var(--danger); }
.btn-sm { --h: 28px; padding: 0 10px; font-size: 12.5px; border-radius: 7px; gap: 6px; }
.btn-sm .i { width: 14px; height: 14px; }
.btn-lg { --h: 42px; padding: 0 18px; font-size: 14.5px; border-radius: var(--radius); }
.btn-block { width: 100%; }
.btn-icon { width: var(--h); padding: 0; }
.btn-icon.btn-ghost { color: var(--fg-2); }
.btn .kbd { margin-left: 2px; }

.kbd {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 20px; height: 20px; padding: 0 5px;
  border: 1px solid var(--line-2); border-bottom-width: 2px; border-radius: 5px;
  font-size: 11px; font-weight: 500; color: var(--fg-3); background: var(--bg);
  font-family: var(--font);
}
.btn-primary .kbd { background: transparent; color: inherit; border-color: rgba(127,127,127,.4); opacity: .7; }

/* ---------- Form ---------- */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field-label { font-size: 12.5px; font-weight: 500; color: var(--fg-2); }
.field-hint { font-size: 12px; color: var(--fg-3); }
.input {
  width: 100%; height: 38px; padding: 0 12px;
  border: 1px solid var(--line-2); border-radius: var(--radius-sm);
  background: var(--bg); color: var(--fg);
  font-size: 14px;
  transition: border-color .15s, box-shadow .15s;
  -webkit-appearance: none; appearance: none;
}
.input::placeholder { color: var(--fg-4); }
.input:hover { border-color: var(--line-3); }
.input:focus { border-color: var(--fg-3); box-shadow: var(--ring); }
textarea.input { height: auto; padding: 10px 12px; resize: vertical; line-height: 1.5; }
textarea.code { font-family: var(--mono); font-size: 12px; }
.input[type="date"], .input[type="time"], .input[type="datetime-local"] { font-variant-numeric: tabular-nums; }
.input-wrap { position: relative; display: flex; align-items: center; }
.input-wrap > .i { position: absolute; left: 12px; color: var(--fg-3); pointer-events: none; width: 16px; height: 16px; }
.input-wrap > .input { padding-left: 38px; }
.input-wrap .input-action { position: absolute; right: 4px; width: 32px; height: 30px; border-radius: 6px; display: grid; place-items: center; color: var(--fg-3); }
.input-wrap .input-action:hover { color: var(--fg); background: var(--hover); }
.select-wrap { position: relative; display: block; }
.select-wrap .input { padding-right: 34px; cursor: pointer; }
.select-wrap > .i { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); width: 15px; height: 15px; color: var(--fg-3); pointer-events: none; }
.input-sm { height: 32px; font-size: 13px; padding: 0 10px; border-radius: 7px; }
.select-wrap .input-sm { padding-right: 30px; }

.check { display: inline-flex; align-items: center; gap: 9px; cursor: pointer; font-size: 13.5px; color: var(--fg-2); user-select: none; }
.check input { position: absolute; opacity: 0; pointer-events: none; }
.check-box {
  width: 17px; height: 17px; border-radius: 5px; border: 1.5px solid var(--line-3);
  display: grid; place-items: center; background: var(--bg); transition: all .15s; flex: none;
}
.check-box .i { width: 12px; height: 12px; stroke-width: 3; color: var(--primary-fg); opacity: 0; transform: scale(.6); transition: all .15s; }
.check input:checked + .check-box { background: var(--primary); border-color: var(--primary); }
.check input:checked + .check-box .i { opacity: 1; transform: none; }
.check input:focus-visible + .check-box { box-shadow: var(--ring); }

.switch { position: relative; display: inline-flex; align-items: center; gap: 10px; cursor: pointer; }
.switch input { position: absolute; opacity: 0; pointer-events: none; }
.switch-track { width: 34px; height: 20px; border-radius: 20px; background: var(--line-3); position: relative; transition: background .2s; flex: none; }
.switch-track::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.3); transition: transform .2s var(--ease); }
.switch input:checked + .switch-track { background: var(--primary); }
.switch input:checked + .switch-track::after { transform: translateX(14px); background: var(--primary-fg); }
[data-theme="dark"] .switch-track::after { background: #d4d4d4; }

.segmented { display: inline-flex; padding: 3px; gap: 2px; background: var(--bg-3); border-radius: 9px; border: 1px solid var(--line); }
.segmented button { height: 28px; padding: 0 12px; border-radius: 7px; font-size: 13px; font-weight: 500; color: var(--fg-3); display: inline-flex; align-items: center; gap: 7px; transition: all .15s; }
.segmented button .i { width: 15px; height: 15px; }
.segmented button:hover { color: var(--fg); }
.segmented button.is-active { background: var(--bg); color: var(--fg); box-shadow: 0 1px 2px rgba(0,0,0,.08), 0 0 0 1px var(--line-2); }
.segmented.block { display: flex; }
.segmented.block button { flex: 1; justify-content: center; }

.form-grid { display: flex; flex-direction: column; gap: 16px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-section { font-size: 11.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--fg-3); padding-top: 6px; }

.alert { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: var(--radius-sm); font-size: 13.5px; border: 1px solid var(--line-2); background: var(--bg-2); }
.alert .i { width: 16px; height: 16px; margin-top: 2px; }
.alert-danger { color: var(--danger); background: var(--danger-bg); border-color: transparent; }
.alert-warn { color: var(--warn); background: var(--warn-bg); border-color: transparent; }

/* ---------- Badge, chip, avatar ---------- */
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  height: 24px; padding: 0 8px; border-radius: 7px;
  border: 1px solid var(--line-2); background: var(--bg);
  font-size: 12.5px; font-weight: 500; color: var(--fg-2); white-space: nowrap;
}
.chip .i { width: 14px; height: 14px; }
.chip-solid { background: var(--primary); border-color: var(--primary); color: var(--primary-fg); }
.chip-muted { background: var(--bg-3); border-color: transparent; }
.chip-danger { color: var(--danger); border-color: transparent; background: var(--danger-bg); }
.chip-warn { color: var(--warn); border-color: transparent; background: var(--warn-bg); }
button.chip:hover { border-color: var(--line-3); color: var(--fg); }
.count {
  display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 9px; font-size: 11px; font-weight: 600; background: var(--bg-3); color: var(--fg-2);
  font-variant-numeric: tabular-nums;
}
.count-solid { background: var(--primary); color: var(--primary-fg); }
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--fg); display: inline-block; flex: none; }

.avatar {
  --s: 24px;
  width: var(--s); height: var(--s); border-radius: 50%; flex: none;
  display: inline-grid; place-items: center;
  background: var(--bg-3); color: var(--fg-2);
  font-size: calc(var(--s) * .4); font-weight: 600; letter-spacing: -.02em;
  box-shadow: inset 0 0 0 1px var(--line-2);
  user-select: none; text-transform: uppercase;
}
.avatar-sm { --s: 22px; }
.avatar-md { --s: 30px; }
.avatar-lg { --s: 40px; }
.avatar-xl { --s: 56px; }
.avatar-dark { background: var(--primary); color: var(--primary-fg); box-shadow: none; }
.avatar-stack { display: inline-flex; align-items: center; }
.avatar-stack .avatar { position: relative; box-shadow: 0 0 0 2px var(--bg), inset 0 0 0 1px var(--line-2); }
.avatar-stack .avatar + .avatar { margin-left: -4px; }
.avatar-stack .avatar:nth-child(1) { z-index: 4; }
.avatar-stack .avatar:nth-child(2) { z-index: 3; }
.avatar-stack .avatar:nth-child(3) { z-index: 2; }
.avatar-stack .avatar:nth-child(4) { z-index: 1; }
.avatar-more { font-size: 9.5px; background: var(--bg); }

/* ---------- Skeleton & empty ---------- */
.skeleton { background: linear-gradient(90deg, var(--bg-3) 0%, var(--hover) 50%, var(--bg-3) 100%); background-size: 200% 100%; animation: shimmer 1.4s infinite linear; border-radius: 6px; }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
.empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; padding: 56px 20px; }
.empty-icon { width: 46px; height: 46px; border-radius: 12px; border: 1px solid var(--line-2); display: grid; place-items: center; color: var(--fg-3); margin-bottom: 8px; box-shadow: var(--shadow-sm); background: var(--bg); }
.empty-icon .i { width: 22px; height: 22px; }
.empty h3 { font-size: 15px; }
.empty p { color: var(--fg-3); font-size: 13.5px; max-width: 360px; }
.empty .btn { margin-top: 12px; }
.spinner { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--line-3); border-top-color: var(--fg); animation: spin .7s linear infinite; display: inline-block; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Shell ---------- */
.boot-screen { position: fixed; inset: 0; display: grid; place-items: center; }
.boot-screen .logo-mark { width: 40px; height: 40px; animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .35; } }

.app { display: grid; grid-template-columns: var(--side-w) minmax(0, 1fr); min-height: 100vh; min-height: 100dvh; }
.sidebar {
  position: sticky; top: 0; height: 100vh; height: 100dvh;
  display: flex; flex-direction: column;
  border-right: 1px solid var(--line);
  background: var(--bg);
  padding: 12px 10px;
  z-index: 40;
}
.side-brand { display: flex; align-items: center; gap: 10px; padding: 4px 8px 14px; min-width: 0; }
.side-brand .logo-mark { width: 28px; height: 28px; }
.side-brand-text { min-width: 0; }
.side-brand-name { font-weight: 600; font-size: 14.5px; letter-spacing: -.02em; }
.side-brand-org { font-size: 11.5px; color: var(--fg-3); }
.side-search {
  display: flex; align-items: center; gap: 8px; height: 34px; padding: 0 8px 0 10px; margin: 0 0 12px;
  border: 1px solid var(--line-2); border-radius: var(--radius-sm); color: var(--fg-3); font-size: 13px; width: 100%;
  background: var(--bg); box-shadow: var(--shadow-sm); transition: border-color .15s;
}
.side-search:hover { border-color: var(--line-3); color: var(--fg-2); }
.side-search .i { width: 15px; height: 15px; }
.side-search span:first-of-type { flex: 1; text-align: left; }
.side-nav { display: flex; flex-direction: column; gap: 1px; }
.side-label { font-size: 11px; font-weight: 600; letter-spacing: .07em; text-transform: uppercase; color: var(--fg-4); padding: 16px 10px 6px; }
.side-link {
  display: flex; align-items: center; gap: 10px; height: 34px; padding: 0 10px; border-radius: var(--radius-sm);
  color: var(--fg-2); font-size: 13.5px; font-weight: 500; transition: background .12s, color .12s; position: relative;
}
.side-link .i { width: 17px; height: 17px; color: var(--fg-3); transition: color .12s; }
.side-link:hover { background: var(--hover); color: var(--fg); }
.side-link:hover .i { color: var(--fg-2); }
.side-link.is-active { background: var(--active); color: var(--fg); }
.side-link.is-active .i { color: var(--fg); }
.side-link .count { margin-left: auto; }
.side-link .count.danger { background: var(--danger-bg); color: var(--danger); }
.side-spacer { flex: 1; }
.side-foot { border-top: 1px solid var(--line); padding-top: 10px; margin-top: 10px; }
.side-user { display: flex; align-items: center; gap: 10px; width: 100%; padding: 6px 8px; border-radius: var(--radius-sm); text-align: left; }
.side-user:hover { background: var(--hover); }
.side-user-name { font-size: 13px; font-weight: 500; line-height: 1.2; }
.side-user-role { font-size: 11.5px; color: var(--fg-3); line-height: 1.3; }
.side-user .i { color: var(--fg-3); width: 15px; height: 15px; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 30;
  height: var(--top-h); display: flex; align-items: center; gap: 10px;
  padding: 0 24px; background: var(--bg); border-bottom: 1px solid var(--line);
}
.topbar-menu { display: none; }
.crumbs { display: flex; align-items: center; gap: 6px; min-width: 0; font-size: 13.5px; color: var(--fg-3); }
.crumbs a:hover { color: var(--fg); }
.crumbs .i { width: 14px; height: 14px; color: var(--fg-4); }
.crumbs strong { color: var(--fg); font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topbar-actions { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.bell { position: relative; }
.bell .badge-dot { position: absolute; top: 6px; right: 7px; width: 8px; height: 8px; border-radius: 50%; background: var(--fg); box-shadow: 0 0 0 2px var(--bg); }
.bell .badge-dot.danger { background: var(--danger); }

.view { width: 100%; max-width: 1320px; margin: 0 auto; padding: 28px 32px 80px; animation: viewIn .25s var(--ease); }
.view-wide { max-width: none; }
@keyframes viewIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.page-head { display: flex; align-items: flex-end; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head h1 { font-size: 24px; letter-spacing: -.028em; }
.page-head p { color: var(--fg-3); margin-top: 4px; font-size: 13.5px; }
.page-head .actions { margin-left: auto; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

.side-backdrop { display: none; }

/* ---------- Card ---------- */
.card { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-lg); }
.card-head { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.card-head h3 { font-size: 14px; }
.card-head .i { color: var(--fg-3); width: 16px; height: 16px; }
.card-head .actions { margin-left: auto; }
.card-body { padding: 16px 18px; }
.card-foot { padding: 10px 18px; border-top: 1px solid var(--line); }

/* ---------- Dashboard ---------- */
.dash-hello { margin-bottom: 24px; }
.dash-hello h1 { font-size: 26px; letter-spacing: -.03em; }
.dash-hello p { color: var(--fg-3); margin-top: 4px; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 20px; }
.stat {
  padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--bg);
  display: flex; flex-direction: column; gap: 10px; text-align: left; transition: border-color .15s, box-shadow .15s;
}
.stat:hover { border-color: var(--line-3); box-shadow: var(--shadow-sm); }
.stat-top { display: flex; align-items: center; justify-content: space-between; color: var(--fg-3); font-size: 12.5px; font-weight: 500; }
.stat-top .i { width: 16px; height: 16px; }
.stat-value { font-size: 30px; font-weight: 600; letter-spacing: -.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.stat-sub { font-size: 12px; color: var(--fg-3); }
.stat.is-alert .stat-value { color: var(--danger); }
.dash-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.dash-col { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.mini-list { display: flex; flex-direction: column; }
.mini-task { display: flex; align-items: center; gap: 12px; padding: 10px 18px; border-bottom: 1px solid var(--line); min-width: 0; transition: background .12s; }
.mini-task:last-child { border-bottom: 0; }
.mini-task:hover { background: var(--bg-2); }
.mini-task-title { flex: 1; min-width: 0; font-weight: 500; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.statusbar { display: flex; height: 8px; border-radius: 8px; overflow: hidden; gap: 2px; background: var(--bg-3); margin: 4px 0 14px; }
.statusbar span { display: block; height: 100%; }
.statusbar .s-todo { background: var(--line-3); }
.statusbar .s-in_progress { background: var(--fg-2); }
.statusbar .s-review { background: var(--fg-3); }
.statusbar .s-done { background: var(--fg); }
.legend { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 16px; }
.legend-item { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--fg-2); }
.legend-item .sw { width: 8px; height: 8px; border-radius: 2px; }
.legend-item strong { margin-left: auto; font-weight: 600; color: var(--fg); font-variant-numeric: tabular-nums; }
.workload { display: flex; flex-direction: column; gap: 12px; }
.wl-row { display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; align-items: center; gap: 10px; }
.wl-name { font-size: 13px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wl-bar { height: 4px; border-radius: 4px; background: var(--bg-3); margin-top: 5px; overflow: hidden; }
.wl-bar span { display: block; height: 100%; background: var(--fg); border-radius: 4px; }
.wl-num { font-size: 12.5px; color: var(--fg-3); font-variant-numeric: tabular-nums; text-align: right; }
.feed { display: flex; flex-direction: column; }
.feed-item { display: flex; gap: 10px; padding: 10px 18px; font-size: 13px; color: var(--fg-2); border-bottom: 1px solid var(--line); }
.feed-item:last-child { border-bottom: 0; }
.feed-item strong { color: var(--fg); font-weight: 500; }
.feed-item a:hover { text-decoration: underline; text-underline-offset: 2px; }
.feed-time { color: var(--fg-3); font-size: 12px; margin-top: 2px; }

/* ---------- Toolbar / filter ---------- */
.toolbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.toolbar .search { position: relative; width: 220px; }
.toolbar .search .i { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); width: 15px; height: 15px; color: var(--fg-3); }
.toolbar .search .input { height: 32px; padding-left: 32px; font-size: 13px; border-radius: 8px; }
.toolbar .spacer { flex: 1; }
.filter-btn.is-set { border-color: var(--fg-3); color: var(--fg); }
.filter-btn .count { margin-left: 2px; }

/* ---------- Status & prioritas ---------- */
.st { display: inline-grid; place-items: center; width: 20px; height: 20px; flex: none; color: var(--fg-3); border-radius: 50%; }
.st .i { width: 17px; height: 17px; }
.st-in_progress { color: var(--fg-2); }
.st-review { color: var(--fg-2); }
.st-done { color: var(--fg); }
button.st { transition: transform .12s, background .12s; }
button.st:hover { transform: scale(1.12); }
.pr { display: inline-grid; place-items: center; width: 20px; height: 20px; color: var(--fg-3); flex: none; }
.pr .i { width: 16px; height: 16px; }
.pr-high { color: var(--fg-2); }
.pr-urgent { color: var(--fg); }
.due { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--fg-3); white-space: nowrap; font-variant-numeric: tabular-nums; }
.due .i { width: 14px; height: 14px; }
.due.is-soon { color: var(--warn); }
.due.is-over { color: var(--danger); font-weight: 500; }
.due.is-done { color: var(--fg-4); text-decoration: line-through; }
.meta-ico { display: inline-flex; align-items: center; gap: 4px; color: var(--fg-3); font-size: 12px; font-variant-numeric: tabular-nums; }
.meta-ico .i { width: 14px; height: 14px; }
.progress-mini { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--fg-3); font-variant-numeric: tabular-nums; }
.ring { --p: 0; width: 16px; height: 16px; border-radius: 50%; background: conic-gradient(var(--fg) calc(var(--p) * 1%), var(--line-2) 0); position: relative; flex: none; }
.ring::after { content: ""; position: absolute; inset: 3px; border-radius: 50%; background: var(--bg); }

/* ---------- Daftar tugas ---------- */
.tlist { border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; background: var(--bg); }
.tgroup + .tgroup { border-top: 1px solid var(--line); }
.tgroup-head {
  display: flex; align-items: center; gap: 10px; height: 40px; padding: 0 16px; width: 100%;
  background: var(--bg-2); font-size: 13px; font-weight: 600; color: var(--fg); text-align: left;
  border-bottom: 1px solid var(--line);
}
.tgroup-head .chev { color: var(--fg-3); width: 15px; height: 15px; transition: transform .2s var(--ease); }
.tgroup.is-collapsed .chev { transform: rotate(-90deg); }
.tgroup.is-collapsed .tgroup-head { border-bottom: 0; }
.tgroup.is-collapsed .tgroup-body { display: none; }
.tgroup-head .count { font-weight: 500; }
.trow {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr) auto;
  align-items: center; gap: 12px;
  min-height: 46px; padding: 6px 16px;
  border-bottom: 1px solid var(--line);
  cursor: pointer; transition: background .1s;
}
.tgroup-body .trow:last-child { border-bottom: 0; }
.trow:hover { background: var(--bg-2); }
.trow-main { display: flex; align-items: center; gap: 10px; min-width: 0; }
.trow-title { font-weight: 500; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trow.is-done .trow-title { color: var(--fg-3); }
.trow-tags { display: flex; align-items: center; gap: 6px; flex: none; }
.trow-meta { display: flex; align-items: center; gap: 14px; }
.trow-meta .due { min-width: 96px; justify-content: flex-end; }

/* ---------- Board ---------- */
.board { display: grid; grid-template-columns: repeat(4, minmax(260px, 1fr)); gap: 12px; overflow-x: auto; padding-bottom: 12px; align-items: start; }
.bcol { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius-lg); display: flex; flex-direction: column; min-height: 200px; max-height: calc(100dvh - 210px); }
.bcol-head { display: flex; align-items: center; gap: 8px; padding: 12px 14px 8px; font-size: 13px; font-weight: 600; }
.bcol-body { display: flex; flex-direction: column; gap: 8px; padding: 4px 8px 10px; overflow-y: auto; flex: 1; min-height: 60px; border-radius: 0 0 var(--radius-lg) var(--radius-lg); transition: background .15s; }
.bcol.is-over .bcol-body { background: var(--hover); }
.bcard {
  background: var(--bg); border: 1px solid var(--line-2); border-radius: var(--radius); padding: 12px;
  display: flex; flex-direction: column; gap: 10px; cursor: grab; box-shadow: var(--shadow-sm);
  transition: border-color .15s, box-shadow .15s; touch-action: pan-y; user-select: none;
}
.bcard:hover { border-color: var(--line-3); box-shadow: var(--shadow); }
.bcard-title { font-weight: 500; font-size: 13.5px; line-height: 1.4; word-break: break-word; }
.bcard-foot { display: flex; align-items: center; gap: 10px; }
.bcard-foot .avatar-stack { margin-left: auto; }
.bcard.is-ghost { opacity: .35; }
.drag-proxy { position: fixed; z-index: 2000; pointer-events: none; box-shadow: var(--shadow-lg); transform: rotate(1.5deg); cursor: grabbing; }
.bcol-empty { font-size: 12.5px; color: var(--fg-4); text-align: center; padding: 18px 0; border: 1px dashed var(--line-2); border-radius: var(--radius); }

/* ---------- Kalender ---------- */
.cal-head { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; flex-wrap: wrap; }
.cal-head h2 { font-size: 18px; letter-spacing: -.02em; min-width: 180px; }
.cal { border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; background: var(--bg); }
.cal-dow { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); background: var(--bg-2); border-bottom: 1px solid var(--line); }
.cal-dow div { padding: 8px 10px; font-size: 11.5px; font-weight: 600; color: var(--fg-3); text-transform: uppercase; letter-spacing: .06em; }
.cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal-cell { min-height: 118px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 6px; display: flex; flex-direction: column; gap: 3px; min-width: 0; position: relative; }
.cal-cell:nth-child(7n) { border-right: 0; }
.cal-cell.is-out { background: var(--bg-2); }
.cal-cell.is-out .cal-day { color: var(--fg-4); }
.cal-day { display: flex; align-items: center; justify-content: space-between; font-size: 12.5px; font-weight: 500; color: var(--fg-2); padding: 0 2px 2px; font-variant-numeric: tabular-nums; }
.cal-day span { width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; }
.cal-cell.is-today .cal-day span { background: var(--primary); color: var(--primary-fg); font-weight: 600; }
.cal-add { opacity: 0; width: 22px; height: 22px; border-radius: 6px; display: grid; place-items: center; color: var(--fg-3); }
.cal-add .i { width: 14px; height: 14px; }
.cal-cell:hover .cal-add { opacity: 1; }
.cal-add:hover { background: var(--hover); color: var(--fg); }
.cal-item {
  display: flex; align-items: center; gap: 5px; height: 22px; padding: 0 6px; border-radius: 6px;
  font-size: 12px; font-weight: 500; background: var(--bg-3); color: var(--fg); min-width: 0; text-align: left; width: 100%;
}
.cal-item:hover { background: var(--active); }
.cal-item .st { width: 14px; height: 14px; }
.cal-item .st .i { width: 13px; height: 13px; }
.cal-item span.t { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-item.is-over { color: var(--danger); background: var(--danger-bg); }
.cal-item.is-done span.t { text-decoration: line-through; color: var(--fg-3); }
.cal-more { font-size: 11.5px; color: var(--fg-3); padding: 0 6px; text-align: left; }
.cal-more:hover { color: var(--fg); }

/* ---------- Detail tugas ---------- */
.detail { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 36px; align-items: start; }
.detail-main { min-width: 0; }
.detail-title { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 6px; }
.detail-title .st { margin-top: 6px; width: 24px; height: 24px; }
.detail-title .st .i { width: 21px; height: 21px; }
.detail-title h1 { font-size: 26px; letter-spacing: -.03em; line-height: 1.25; word-break: break-word; flex: 1; outline: none; border-radius: 6px; }
.detail-title h1[contenteditable="true"]:hover { background: var(--hover); box-shadow: 0 0 0 4px var(--hover); }
.detail-title h1[contenteditable="true"]:focus { background: transparent; box-shadow: 0 0 0 4px var(--bg-3); }
.detail-sub { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; color: var(--fg-3); font-size: 13px; margin: 0 0 22px 36px; }
.detail-sub .sep { width: 3px; height: 3px; border-radius: 50%; background: var(--fg-4); }
.section { margin-top: 28px; }
.section-head { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.section-head h2 { font-size: 15px; letter-spacing: -.015em; }
.section-head .i { color: var(--fg-3); width: 16px; height: 16px; }
.section-head .actions { margin-left: auto; display: flex; gap: 6px; }
.desc-box { border: 1px solid transparent; border-radius: var(--radius); padding: 2px 0; }
.desc-empty { color: var(--fg-4); font-size: 14px; }
.desc-edit-hint { cursor: text; }
.desc-edit-hint:hover { background: var(--bg-2); border-color: var(--line); padding: 10px 12px; margin: -10px -12px; }

.props { position: sticky; top: calc(var(--top-h) + 20px); display: flex; flex-direction: column; gap: 16px; }
.props-card { border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--bg); }
.prop { display: grid; grid-template-columns: 96px minmax(0, 1fr); align-items: center; gap: 8px; min-height: 42px; padding: 4px 14px; border-bottom: 1px solid var(--line); }
.prop:last-child { border-bottom: 0; }
.prop-label { font-size: 12.5px; color: var(--fg-3); display: flex; align-items: center; gap: 7px; }
.prop-label .i { width: 14px; height: 14px; }
.prop-value { min-width: 0; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 13px; }
.prop-btn { display: inline-flex; align-items: center; gap: 7px; height: 30px; padding: 0 8px; margin-left: -8px; border-radius: 7px; font-size: 13px; font-weight: 500; max-width: 100%; }
.prop-btn:hover:not(:disabled) { background: var(--hover); }
.prop-btn:disabled { cursor: default; }
.prop-btn .i { width: 15px; height: 15px; }

.progress-card { padding: 14px; }
.progress-top { display: flex; align-items: baseline; gap: 8px; margin-bottom: 10px; }
.progress-top strong { font-size: 22px; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.progress-top span { color: var(--fg-3); font-size: 12.5px; }
.bar { height: 6px; border-radius: 6px; background: var(--bg-3); overflow: hidden; }
.bar span { display: block; height: 100%; border-radius: 6px; background: var(--fg); transition: width .4s var(--ease); }
.people { display: flex; flex-direction: column; max-height: 280px; overflow: auto; margin-top: 12px; border-top: 1px solid var(--line); padding-top: 6px; }
.person { display: flex; align-items: center; gap: 10px; padding: 6px 0; font-size: 13px; }
.person .name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.person .state { color: var(--fg-4); display: inline-flex; }
.person .state.done { color: var(--fg); }
.person .state .i { width: 16px; height: 16px; }
.my-complete { margin-top: 12px; }

.activity { display: flex; flex-direction: column; gap: 0; }
.act { display: flex; gap: 10px; font-size: 12.5px; color: var(--fg-3); padding: 7px 0; position: relative; }
.act::before { content: ""; position: absolute; left: 9.5px; top: 26px; bottom: -6px; width: 1px; background: var(--line-2); }
.act:last-child::before { display: none; }
.act-ico { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; background: var(--bg); box-shadow: inset 0 0 0 1px var(--line-2); flex: none; color: var(--fg-3); position: relative; z-index: 1; }
.act-ico .i { width: 11px; height: 11px; stroke-width: 2.2; }
.act strong { color: var(--fg-2); font-weight: 500; }
.act-time { display: block; font-size: 11.5px; color: var(--fg-4); margin-top: 1px; }

/* ---------- Catatan ---------- */
.notes { display: flex; flex-direction: column; gap: 12px; }
.note { border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--bg); transition: border-color .15s; }
.note:hover { border-color: var(--line-2); }
.note.is-new { animation: noteIn .45s var(--ease); }
@keyframes noteIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.note-head { display: flex; align-items: center; gap: 10px; padding: 12px 14px 0; }
.note-author { font-weight: 600; font-size: 13.5px; }
.note-time { color: var(--fg-3); font-size: 12.5px; }
.note-head .btn-icon { margin-left: auto; }
.note-body { padding: 8px 14px 14px 48px; }
.note-body .rich:empty { display: none; }
.note .att-grid { margin-top: 10px; }

.rich { font-size: 14px; line-height: 1.65; color: var(--fg); word-wrap: break-word; overflow-wrap: anywhere; }
.rich > *:first-child { margin-top: 0; }
.rich > *:last-child { margin-bottom: 0; }
.rich p { margin: 0 0 .55em; }
.rich h2 { font-size: 17px; margin: 1em 0 .4em; }
.rich h3 { font-size: 15px; margin: .9em 0 .35em; }
.rich ul, .rich ol { margin: .3em 0 .7em; padding-left: 1.4em; }
.rich li { margin: .15em 0; }
.rich li::marker { color: var(--fg-3); }
.rich blockquote { margin: .6em 0; padding: 2px 0 2px 14px; border-left: 2px solid var(--line-3); color: var(--fg-2); }
.rich code { background: var(--bg-3); border-radius: 5px; padding: 1px 5px; border: 1px solid var(--line); }
.rich pre { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 12px; overflow-x: auto; font-family: var(--mono); font-size: 12.5px; white-space: pre-wrap; }
.rich a { text-decoration: underline; text-decoration-color: var(--fg-4); text-underline-offset: 3px; }
.rich a:hover { text-decoration-color: var(--fg); }

.att-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 8px; }
.att {
  position: relative; aspect-ratio: 4 / 3; border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--line-2); background: var(--bg-3); cursor: zoom-in; display: block; width: 100%;
}
.att img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s var(--ease); }
.att.is-drawing img { object-fit: contain; background: #fff; }
.att:hover img { transform: scale(1.03); }
.att-badge {
  position: absolute; left: 6px; bottom: 6px; display: inline-flex; align-items: center; gap: 4px;
  height: 20px; padding: 0 6px; border-radius: 6px; background: rgba(0,0,0,.72); color: #fff;
  font-size: 11px; font-weight: 500; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.att-badge .i { width: 12px; height: 12px; }
.att-x {
  position: absolute; top: 6px; right: 6px; width: 24px; height: 24px; border-radius: 7px; display: grid; place-items: center;
  background: rgba(0,0,0,.72); color: #fff; opacity: 0; transition: opacity .15s;
}
.att-x .i { width: 13px; height: 13px; stroke-width: 2.2; }
.att:hover .att-x, .att:focus-within .att-x { opacity: 1; }
@media (hover: none) { .att-x { opacity: 1; } }
.att-edit { right: 34px; }
.att-progress { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(0,0,0,.45); color: #fff; font-size: 12px; font-weight: 600; }
.att-progress .bar { position: absolute; left: 10px; right: 10px; bottom: 10px; height: 3px; background: rgba(255,255,255,.25); }
.att-progress .bar span { background: #fff; }
.att.is-error { border-color: var(--danger); }

.composer { border: 1px solid var(--line-2); border-radius: var(--radius-lg); background: var(--bg); box-shadow: var(--shadow-sm); transition: border-color .15s, box-shadow .15s; }
.composer:focus-within { border-color: var(--line-3); box-shadow: var(--shadow); }
.composer.is-drop { border-color: var(--fg); border-style: dashed; }
.composer .att-grid { padding: 0 14px 12px; }
.composer-foot { display: flex; align-items: center; gap: 4px; padding: 8px 10px; border-top: 1px solid var(--line); }
.composer-foot .hint { margin-left: auto; margin-right: 8px; font-size: 12px; color: var(--fg-4); }

/* Editor teks kaya */
.rte-bar { display: flex; align-items: center; gap: 2px; padding: 6px 8px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.rte-bar::-webkit-scrollbar { display: none; }
.rte-btn { width: 30px; height: 30px; border-radius: 7px; display: grid; place-items: center; color: var(--fg-3); flex: none; }
.rte-btn .i { width: 16px; height: 16px; }
.rte-btn:hover { background: var(--hover); color: var(--fg); }
.rte-btn.is-on { background: var(--active); color: var(--fg); }
.rte-sep { width: 1px; height: 18px; background: var(--line-2); margin: 0 4px; flex: none; }
.rte { min-height: 92px; max-height: 420px; overflow-y: auto; padding: 12px 14px; outline: none; cursor: text; }
.rte:empty::before { content: attr(data-placeholder); color: var(--fg-4); pointer-events: none; }
.rte-plain { border: 1px solid var(--line-2); border-radius: var(--radius); }
.rte-plain:focus-within { border-color: var(--fg-3); box-shadow: var(--ring); }

/* ---------- Overlay: modal, popover, toast ---------- */
.layer-backdrop { position: fixed; inset: 0; background: var(--overlay); z-index: 1700; animation: fadeIn .18s ease; }
@keyframes fadeIn { from { opacity: 0; } }
.modal-wrap { position: fixed; inset: 0; z-index: 1701; display: flex; align-items: flex-start; justify-content: center; padding: 8vh 16px 16px; overflow-y: auto; }
.modal {
  width: 100%; max-width: 560px; background: var(--bg-elev); border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg); border: 1px solid var(--line); animation: modalIn .22s var(--ease);
  display: flex; flex-direction: column; max-height: calc(100dvh - 10vh - 16px);
}
.modal-lg { max-width: 720px; }
.modal-sm { max-width: 420px; }
@keyframes modalIn { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
.modal-head { display: flex; align-items: center; gap: 10px; padding: 16px 18px 12px; }
.modal-head h2 { font-size: 16px; }
.modal-head .btn-icon { margin-left: auto; margin-right: -6px; }
.modal-body { padding: 4px 18px 18px; overflow-y: auto; }
.modal-foot { display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding: 12px 18px; border-top: 1px solid var(--line); background: var(--bg-2); border-radius: 0 0 var(--radius-xl) var(--radius-xl); }
.modal-foot .left { margin-right: auto; display: flex; gap: 8px; align-items: center; }
.confirm-body { display: flex; gap: 14px; }
.confirm-icon { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; flex: none; background: var(--bg-3); color: var(--fg-2); }
.confirm-icon.danger { background: var(--danger-bg); color: var(--danger); }
.confirm-body p { color: var(--fg-2); margin-top: 4px; font-size: 13.5px; }

.tm-title { width: 100%; border: 0; background: transparent; font-size: 20px; font-weight: 600; letter-spacing: -.025em; padding: 4px 0; outline: none; }
.tm-title::placeholder { color: var(--fg-4); }
.tm-props { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 2px; }
.tm-row { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 12px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); }
.tm-row .lbl { font-size: 13px; color: var(--fg-3); display: flex; gap: 8px; align-items: center; }
.tm-row .lbl .i { width: 15px; height: 15px; }
.dt-row { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.dt-row .input { width: auto; height: 32px; font-size: 13px; }
.dt-quick { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 6px; }

.popover {
  position: fixed; z-index: 1800; min-width: 200px; max-width: calc(100vw - 16px);
  background: var(--bg-elev); border: 1px solid var(--line-2); border-radius: 12px;
  box-shadow: var(--shadow); padding: 4px; animation: popIn .14s var(--ease);
}
@keyframes popIn { from { opacity: 0; transform: translateY(-4px) scale(.98); } }
.menu-item {
  display: flex; align-items: center; gap: 10px; width: 100%; min-height: 34px; padding: 0 10px;
  border-radius: 8px; font-size: 13.5px; color: var(--fg); text-align: left;
}
.menu-item .i { width: 16px; height: 16px; color: var(--fg-3); }
.menu-item:hover, .menu-item.is-focus { background: var(--hover); }
.menu-item.is-selected .check-mark { opacity: 1; }
.menu-item .check-mark { margin-left: auto; opacity: 0; color: var(--fg); }
.menu-item.danger, .menu-item.danger .i { color: var(--danger); }
.menu-item .desc { display: block; font-size: 12px; color: var(--fg-3); }
.menu-sep { height: 1px; background: var(--line); margin: 4px -4px; }
.menu-label { font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--fg-4); padding: 8px 10px 4px; }
.menu-search { padding: 4px 4px 6px; border-bottom: 1px solid var(--line); margin: -4px -4px 4px; }
.menu-search .input { border: 0; box-shadow: none; height: 36px; padding: 0 10px; background: transparent; }
.menu-scroll { max-height: 300px; overflow-y: auto; }

.toasts { position: fixed; z-index: 3000; right: 16px; bottom: calc(16px + var(--safe-b)); display: flex; flex-direction: column; gap: 8px; align-items: flex-end; pointer-events: none; }
.toast {
  display: flex; align-items: center; gap: 10px; padding: 10px 14px; min-height: 42px; max-width: 380px;
  background: var(--primary); color: var(--primary-fg); border-radius: 11px; font-size: 13.5px; font-weight: 500;
  box-shadow: var(--shadow-lg); pointer-events: auto; animation: toastIn .3s var(--ease);
}
.toast .i { width: 16px; height: 16px; }
.toast.is-error .i { color: #ff8a80; }
[data-theme="dark"] .toast.is-error .i { color: var(--danger); }
.toast.is-out { animation: toastOut .2s ease forwards; }
@keyframes toastIn { from { opacity: 0; transform: translateY(10px) scale(.96); } }
@keyframes toastOut { to { opacity: 0; transform: translateY(6px); } }

/* Notifikasi */
.notif-pop { width: 390px; padding: 0; }
.notif-head { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.notif-head h3 { font-size: 14px; }
.notif-head .btn { margin-left: auto; }
.notif-body { max-height: min(520px, 70dvh); overflow-y: auto; }
.notif-sec { font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--fg-4); padding: 10px 14px 4px; }
.notif { display: flex; gap: 10px; padding: 10px 14px; width: 100%; text-align: left; font-size: 13px; color: var(--fg-2); position: relative; }
.notif:hover { background: var(--bg-2); }
.notif.is-unread { color: var(--fg); }
.notif.is-unread::after { content: ""; position: absolute; right: 14px; top: 16px; width: 7px; height: 7px; border-radius: 50%; background: var(--fg); }
.notif-ico { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; background: var(--bg-3); flex: none; color: var(--fg-2); }
.notif-ico .i { width: 15px; height: 15px; }
.notif-ico.danger { background: var(--danger-bg); color: var(--danger); }
.notif-text { flex: 1; min-width: 0; padding-right: 14px; }
.notif-time { font-size: 11.5px; color: var(--fg-3); margin-top: 2px; }

/* Command palette */
.cmdk { max-width: 600px; overflow: hidden; }
.cmdk-input { display: flex; align-items: center; gap: 10px; padding: 0 16px; border-bottom: 1px solid var(--line); }
.cmdk-input .i { color: var(--fg-3); }
.cmdk-input input { flex: 1; height: 52px; border: 0; background: transparent; outline: none; font-size: 15px; }
.cmdk-list { max-height: 380px; overflow-y: auto; padding: 6px; }
.cmdk-item { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 40px; padding: 0 10px; border-radius: 9px; text-align: left; font-size: 13.5px; }
.cmdk-item.is-focus { background: var(--hover); }
.cmdk-item .t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cmdk-foot { display: flex; gap: 14px; padding: 8px 14px; border-top: 1px solid var(--line); font-size: 12px; color: var(--fg-3); background: var(--bg-2); }
.cmdk-foot span { display: inline-flex; align-items: center; gap: 5px; }

/* User picker */
.picker-list { display: flex; flex-direction: column; }
.picker-item { display: flex; align-items: center; gap: 10px; min-height: 38px; padding: 0 10px; border-radius: 8px; text-align: left; width: 100%; font-size: 13.5px; }
.picker-item:hover, .picker-item.is-focus { background: var(--hover); }
.picker-item .sub { color: var(--fg-3); font-size: 12px; }
.picker-item .check-box { margin-left: auto; }
.picker-item.is-on .check-box { background: var(--primary); border-color: var(--primary); }
.picker-item.is-on .check-box .i { opacity: 1; transform: none; }
.assignee-chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.assignee-chip { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 4px 0 3px; border-radius: 14px; border: 1px solid var(--line-2); font-size: 12.5px; font-weight: 500; }
.assignee-chip button { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; color: var(--fg-3); }
.assignee-chip button:hover { background: var(--hover); color: var(--fg); }
.assignee-chip button .i { width: 12px; height: 12px; }
.universal-note { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--bg-2); border: 1px solid var(--line); font-size: 13px; color: var(--fg-2); }
.universal-note .i { width: 16px; height: 16px; }

/* Tabel pengguna */
.table-wrap { border: 1px solid var(--line); border-radius: var(--radius-lg); overflow-x: auto; background: var(--bg); }
.table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.table th { text-align: left; font-weight: 500; font-size: 12px; color: var(--fg-3); padding: 10px 16px; background: var(--bg-2); border-bottom: 1px solid var(--line); white-space: nowrap; }
.table td { padding: 10px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table tr:hover td { background: var(--bg-2); }
.table .user-cell { display: flex; align-items: center; gap: 10px; min-width: 200px; }
.table .user-cell strong { font-weight: 500; display: block; }
.table .user-cell span { color: var(--fg-3); font-size: 12.5px; }
.table tr.is-inactive td { color: var(--fg-3); }

/* Pengaturan / profil */
.settings-grid { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 32px; align-items: start; }
.settings-nav { position: sticky; top: calc(var(--top-h) + 20px); display: flex; flex-direction: column; gap: 2px; }
.settings-block { border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--bg); margin-bottom: 16px; }
.settings-block-head { padding: 16px 20px; border-bottom: 1px solid var(--line); }
.settings-block-head h3 { font-size: 14.5px; }
.settings-block-head p { font-size: 13px; color: var(--fg-3); margin-top: 2px; }
.settings-block-body { padding: 18px 20px; display: flex; flex-direction: column; gap: 16px; }
.settings-block-foot { padding: 12px 20px; border-top: 1px solid var(--line); display: flex; justify-content: flex-end; gap: 8px; background: var(--bg-2); border-radius: 0 0 var(--radius-lg) var(--radius-lg); }
.setting-row { display: flex; align-items: center; gap: 16px; justify-content: space-between; }
.setting-row .txt strong { display: block; font-weight: 500; font-size: 13.5px; }
.setting-row .txt span { color: var(--fg-3); font-size: 12.5px; }
.theme-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.theme-card { border: 1px solid var(--line-2); border-radius: var(--radius); padding: 8px; text-align: left; transition: border-color .15s, box-shadow .15s; }
.theme-card:hover { border-color: var(--line-3); }
.theme-card.is-active { border-color: var(--fg); box-shadow: 0 0 0 1px var(--fg); }
.theme-preview { height: 72px; border-radius: 7px; overflow: hidden; display: grid; grid-template-columns: 30% 1fr; border: 1px solid rgba(127,127,127,.25); }
.theme-preview .a { background: #fff; border-right: 1px solid #eee; }
.theme-preview .b { background: #fff; padding: 10px 8px; display: flex; flex-direction: column; gap: 5px; }
.theme-preview .b i { display: block; height: 5px; border-radius: 3px; background: #e5e5e5; }
.theme-preview .b i:first-child { width: 60%; background: #0a0a0a; }
.theme-preview.dark .a { background: #000; border-color: #1c1c1c; }
.theme-preview.dark .b { background: #000; }
.theme-preview.dark .b i { background: #262626; }
.theme-preview.dark .b i:first-child { background: #fafafa; }
.theme-preview.system { background: linear-gradient(135deg, #fff 50%, #000 50%); }
.theme-preview.system .a, .theme-preview.system .b { background: transparent; border: 0; }
.theme-card-label { display: flex; align-items: center; gap: 6px; margin-top: 8px; font-size: 13px; font-weight: 500; }
.theme-card-label .i { width: 15px; height: 15px; color: var(--fg-3); }
.profile-head { display: flex; align-items: center; gap: 14px; }
.profile-head h2 { font-size: 18px; }
.kv { display: grid; grid-template-columns: 160px 1fr; gap: 8px 16px; font-size: 13px; }
.kv dt { color: var(--fg-3); }
.kv dd { margin: 0; font-variant-numeric: tabular-nums; }

/* ---------- Lightbox ---------- */
.lightbox { position: fixed; inset: 0; z-index: 1500; background: rgba(0,0,0,.94); display: flex; flex-direction: column; color: #fafafa; animation: fadeIn .2s ease; }
.lb-top { display: flex; align-items: center; gap: 8px; height: 58px; padding: 0 12px 0 18px; }
.lb-top .t { flex: 1; min-width: 0; font-size: 13.5px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb-top .t small { color: #8a8a8a; font-weight: 400; margin-left: 8px; }
.lb-btn { height: 34px; padding: 0 12px; border-radius: 8px; display: inline-flex; align-items: center; gap: 8px; color: #e5e5e5; font-size: 13px; font-weight: 500; }
.lb-btn:hover { background: rgba(255,255,255,.1); color: #fff; }
.lb-btn.icon { width: 36px; padding: 0; justify-content: center; }
.lb-btn .i { width: 17px; height: 17px; }
.lb-stage { flex: 1; min-height: 0; position: relative; display: grid; place-items: center; padding: 0 64px 24px; }
.lb-stage img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 4px; user-select: none; box-shadow: 0 20px 80px rgba(0,0,0,.6); }
.lb-stage img.is-drawing { background: #fff; }
.lb-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: rgba(255,255,255,.08); }
.lb-nav:hover { background: rgba(255,255,255,.16); }
.lb-nav.prev { left: 12px; }
.lb-nav.next { right: 12px; }
.lb-count { position: absolute; bottom: 8px; left: 50%; transform: translateX(-50%); font-size: 12px; color: #8a8a8a; font-variant-numeric: tabular-nums; }

/* ---------- Sketch (canvas) ---------- */
.sketch { position: fixed; inset: 0; z-index: 1600; background: var(--bg-3); display: flex; flex-direction: column; animation: fadeIn .18s ease; }
.sk-top { height: 56px; flex: none; display: flex; align-items: center; gap: 6px; padding: 0 10px; background: var(--bg); border-bottom: 1px solid var(--line); }
.sk-title { font-weight: 600; font-size: 14px; margin: 0 8px 0 4px; white-space: nowrap; }
.sk-group { display: flex; align-items: center; gap: 2px; }
.sk-sep { width: 1px; height: 22px; background: var(--line-2); margin: 0 6px; flex: none; }
.sk-zoom { min-width: 52px; height: 30px; font-size: 12.5px; font-weight: 500; color: var(--fg-2); border-radius: 7px; font-variant-numeric: tabular-nums; }
.sk-zoom:hover { background: var(--hover); color: var(--fg); }
.sk-top .push { margin-left: auto; }
.sk-stage { flex: 1; min-height: 0; position: relative; overflow: hidden; touch-action: none; cursor: crosshair; }
.sk-stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.sk-stage.tool-hand { cursor: grab; }
.sk-stage.is-panning { cursor: grabbing; }
.sk-stage.tool-text { cursor: text; }
.sk-dock {
  position: absolute; left: 50%; bottom: calc(18px + var(--safe-b)); transform: translateX(-50%);
  display: flex; align-items: center; gap: 4px; padding: 6px; border-radius: 16px;
  background: var(--bg-elev); border: 1px solid var(--line-2); box-shadow: var(--shadow-lg); z-index: 3; max-width: calc(100% - 20px); overflow-x: auto; scrollbar-width: none;
}
.sk-dock::-webkit-scrollbar { display: none; }
.sk-tool { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; color: var(--fg-2); flex: none; position: relative; }
.sk-tool .i { width: 19px; height: 19px; }
.sk-tool:hover { background: var(--hover); color: var(--fg); }
.sk-tool.is-active { background: var(--primary); color: var(--primary-fg); }
.sk-props {
  position: absolute; left: 50%; top: 12px; transform: translateX(-50%);
  display: flex; align-items: center; gap: 4px; padding: 5px 6px; border-radius: 14px;
  background: var(--bg-elev); border: 1px solid var(--line-2); box-shadow: var(--shadow); z-index: 3; max-width: calc(100% - 20px); overflow-x: auto; scrollbar-width: none;
}
.sk-props::-webkit-scrollbar { display: none; }
.sk-swatch { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; flex: none; }
.sk-swatch:hover { background: var(--hover); }
.sk-swatch span { width: 18px; height: 18px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(127,127,127,.35); transition: transform .12s; }
.sk-swatch.is-active span { box-shadow: 0 0 0 2px var(--bg-elev), 0 0 0 3.5px var(--fg); }
.sk-size { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; flex: none; }
.sk-size:hover { background: var(--hover); }
.sk-size span { border-radius: 50%; background: var(--fg-2); }
.sk-size.is-active { background: var(--active); }
.sk-size.is-active span { background: var(--fg); }
.sk-text-input {
  position: absolute; z-index: 4; min-width: 60px; padding: 2px 4px; margin: 0; border: 1.5px dashed var(--fg-3); border-radius: 4px;
  background: transparent; outline: none; resize: none; overflow: hidden; font-family: var(--font); font-weight: 500; line-height: 1.25; white-space: pre;
}
.sk-hint { position: absolute; left: 16px; bottom: calc(24px + var(--safe-b)); font-size: 12px; color: var(--fg-3); z-index: 2; pointer-events: none; }

/* ---------- Auth ---------- */
.auth-body { background: var(--bg); }
.auth { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); min-height: 100vh; min-height: 100dvh; }
.auth-brand {
  position: relative; overflow: hidden; background: #0a0a0a; color: #fafafa; padding: 40px 48px;
  display: flex; flex-direction: column; justify-content: space-between;
}
[data-theme="dark"] .auth-brand { background: #050505; border-right: 1px solid var(--line); }
.auth-brand::before {
  content: ""; position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(ellipse at 70% 30%, #000 10%, transparent 70%);
  mask-image: radial-gradient(ellipse at 70% 30%, #000 10%, transparent 70%);
}
.auth-brand > * { position: relative; }
.auth-brand .logo-mark { color: #fafafa; --bg: #0a0a0a; }
.auth-brand-top { display: flex; align-items: center; gap: 12px; }
.auth-brand-name { font-weight: 600; font-size: 16px; letter-spacing: -.02em; }
.auth-brand-body { max-width: 460px; }
.auth-brand-body h1 { font-size: 40px; line-height: 1.08; letter-spacing: -.04em; font-weight: 600; }
.auth-brand-body p { color: #a3a3a3; font-size: 15px; line-height: 1.6; margin-top: 16px; }
.auth-points { list-style: none; padding: 0; margin: 32px 0 0; display: flex; flex-direction: column; gap: 14px; }
.auth-points li { display: flex; align-items: center; gap: 12px; color: #d4d4d4; font-size: 14px; }
.auth-points .i { width: 18px; height: 18px; color: #fafafa; padding: 7px; box-sizing: content-box; border: 1px solid #262626; border-radius: 9px; background: #111; }
.auth-brand-foot { font-size: 12.5px; color: #6f6f6f; }
.auth-main { display: grid; place-items: center; padding: 32px 20px; }
.auth-card { width: 100%; max-width: 380px; display: flex; flex-direction: column; gap: 16px; }
.auth-card-head h2 { font-size: 24px; letter-spacing: -.03em; }
.auth-card-head p { color: var(--fg-3); margin-top: 6px; }
.logo-mobile { display: none; width: 38px; height: 38px; margin-bottom: 18px; }
.auth-card .input { height: 42px; }
.auth-row { display: flex; align-items: center; justify-content: space-between; }
.auth-theme { display: flex; gap: 2px; justify-content: center; margin-top: 10px; }
.auth-theme button { width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; color: var(--fg-4); }
.auth-theme button:hover { color: var(--fg); background: var(--hover); }
.auth-theme button.is-active { color: var(--fg); background: var(--bg-3); }
.auth-theme .i { width: 16px; height: 16px; }

/* ---------- Installer ---------- */
.ins-body { background: var(--bg-2); }
.ins { max-width: 680px; margin: 0 auto; padding: 40px 16px 32px; }
.ins-head { display: flex; align-items: center; gap: 12px; margin-bottom: 28px; }
.ins-head .logo-mark { width: 36px; height: 36px; }
.ins-title { font-weight: 600; font-size: 16px; letter-spacing: -.02em; }
.ins-sub { font-size: 12.5px; color: var(--fg-3); }
.ins-steps { list-style: none; margin: 0 0 16px; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.ins-steps li { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--fg-3); position: relative; min-width: 0; }
.ins-step-dot { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; border: 1px solid var(--line-2); background: var(--bg); flex: none; }
.ins-step-dot .i { width: 13px; height: 13px; }
.ins-step-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ins-steps li.is-current { color: var(--fg); font-weight: 500; }
.ins-steps li.is-current .ins-step-dot { border-color: var(--fg); box-shadow: 0 0 0 3px var(--hover); }
.ins-steps li.is-done .ins-step-dot { background: var(--primary); color: var(--primary-fg); border-color: var(--primary); }
.ins-card { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-xl); padding: 28px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 16px; }
.ins-h { font-size: 20px; letter-spacing: -.025em; }
.ins-lead { color: var(--fg-2); margin-top: -8px; }
.ins-actions { display: flex; justify-content: space-between; gap: 8px; padding-top: 8px; }
.ins-actions.end { justify-content: flex-end; }
.ins-foot { text-align: center; font-size: 12px; color: var(--fg-4); margin-top: 20px; }
.req-list { list-style: none; margin: 0; padding: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.req-list li { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.req-list li:last-child { border-bottom: 0; }
.req-icon .i { width: 18px; height: 18px; }
.req-list li.ok .req-icon { color: var(--fg); }
.req-list li.fail .req-icon { color: var(--danger); }
.req-list li.warn .req-icon { color: var(--warn); }
.req-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.req-text strong { font-weight: 500; font-size: 13.5px; }
.req-text small { color: var(--fg-3); font-size: 12px; }
.req-tag { font-size: 11.5px; font-weight: 500; color: var(--fg-3); border: 1px solid var(--line-2); border-radius: 6px; padding: 1px 7px; }
.req-list li.fail .req-tag { color: var(--danger); border-color: transparent; background: var(--danger-bg); }
.ins-state { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 12px 0; }
.ins-state h2 { font-size: 20px; }
.ins-state p { color: var(--fg-2); max-width: 460px; }
.ins-state .btn { margin-top: 12px; }
.ins-state-icon { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: var(--primary); color: var(--primary-fg); margin-bottom: 8px; }
.ins-state-icon .i { width: 24px; height: 24px; stroke-width: 2.2; }
.ins-checklist { display: flex; flex-direction: column; gap: 8px; }
.ins-check { display: flex; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius); font-size: 13px; color: var(--fg-2); }
.ins-check .i { width: 17px; height: 17px; color: var(--fg); margin-top: 1px; }
.ins-check strong { color: var(--fg); font-weight: 500; }

/* ---------- Responsif ---------- */
@media (max-width: 1180px) {
  .detail { grid-template-columns: minmax(0, 1fr) 290px; gap: 24px; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 980px) {
  .app { grid-template-columns: minmax(0, 1fr); }
  .sidebar {
    position: fixed; left: 0; top: 0; bottom: 0; width: 280px; height: 100%;
    transform: translateX(-102%); transition: transform .28s var(--ease); box-shadow: var(--shadow-lg);
  }
  .app.nav-open .sidebar { transform: none; }
  .side-backdrop { display: block; position: fixed; inset: 0; z-index: 35; background: var(--overlay); opacity: 0; pointer-events: none; transition: opacity .25s; }
  .app.nav-open .side-backdrop { opacity: 1; pointer-events: auto; }
  .topbar { padding: 0 12px; }
  .topbar-menu { display: inline-flex; }
  .view { padding: 20px 16px 96px; }
  .detail { grid-template-columns: minmax(0, 1fr); }
  .props { position: static; }
  .dash-grid { grid-template-columns: minmax(0, 1fr); }
  .settings-grid { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .settings-nav { position: static; flex-direction: row; overflow-x: auto; }
  .auth { grid-template-columns: minmax(0, 1fr); }
  .auth-brand { display: none; }
  .logo-mobile { display: block; }
  .hide-md { display: none !important; }
}
@media (max-width: 640px) {
  body { font-size: 14.5px; }
  .page-head h1 { font-size: 21px; }
  .page-head .actions { margin-left: 0; width: 100%; }
  .stats { gap: 8px; }
  .stat { padding: 12px 14px; }
  .stat-value { font-size: 26px; }
  .grid-2 { grid-template-columns: minmax(0, 1fr); }
  .toolbar .search { width: 100%; }
  .trow { grid-template-columns: 20px minmax(0, 1fr); padding: 10px 14px; row-gap: 6px; }
  .trow-meta { grid-column: 2; flex-wrap: wrap; gap: 10px; }
  .trow-meta .due { min-width: 0; justify-content: flex-start; }
  .trow-tags { display: none; }
  .board { grid-template-columns: repeat(4, 84vw); scroll-snap-type: x mandatory; }
  .bcol { scroll-snap-align: start; max-height: none; }
  .cal-cell { min-height: 64px; padding: 3px; }
  .cal-item span.t, .cal-more { display: none; }
  .cal-item { width: 100%; height: 6px; padding: 0; border-radius: 3px; background: var(--fg-3); }
  .cal-item .st { display: none; }
  .cal-item.is-over { background: var(--danger); }
  .cal-add { display: none; }
  .cal-dow div { padding: 6px 4px; text-align: center; font-size: 10.5px; }
  .detail-title h1 { font-size: 21px; }
  .detail-sub { margin-left: 0; }
  .note-body { padding-left: 14px; }
  .modal-wrap { padding: 0; align-items: flex-end; }
  .modal { max-width: none !important; border-radius: var(--radius-xl) var(--radius-xl) 0 0; max-height: 94dvh; animation: sheetIn .28s var(--ease); }
  .modal-foot { border-radius: 0; padding-bottom: calc(12px + var(--safe-b)); }
  @keyframes sheetIn { from { transform: translateY(40px); opacity: 0; } }
  .tm-row { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .notif-pop { width: calc(100vw - 16px); }
  .theme-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
  .kv { grid-template-columns: 1fr; gap: 2px; }
  .kv dd { margin-bottom: 8px; }
  .lb-stage { padding: 0 8px 48px; }
  .lb-nav { top: auto; bottom: 8px; transform: none; width: 40px; height: 40px; }
  .lb-btn span { display: none; }
  .sk-title, .sk-hide-sm { display: none; }
  .sk-tool { width: 34px; height: 34px; border-radius: 9px; }
  .sk-tool .i { width: 18px; height: 18px; }
  .sk-dock { gap: 2px; padding: 5px; }
  .sk-dock .sk-sep { margin: 0 2px; }
  .sk-swatch, .sk-size { width: 26px; height: 26px; }
  .sk-swatch span { width: 16px; height: 16px; }
  .sk-props .sk-sep { margin: 0 3px; }
  .sk-props { top: 8px; }
  .ins-card { padding: 20px; }
  .ins-step-label { display: none; }
  .ins-steps { display: flex; justify-content: center; gap: 24px; }
  .hide-sm { display: none !important; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
@media print {
  .sidebar, .topbar, .composer, .props .btn { display: none !important; }
  .app { display: block; }
}

.shake { animation: shake .38s ease; }
@keyframes shake { 20%, 60% { transform: translateX(-5px); } 40%, 80% { transform: translateX(5px); } }
.menu-scroll-pop { max-height: min(460px, 70vh); overflow-y: auto; }

/* =====================================================================
   v1.1 — Group berwarna, kartu papan, checklist, color picker hexagon
   ===================================================================== */

/* Chip group: matte (datar, tanpa bayangan) */
.gchip {
  display: inline-flex; align-items: center; height: 20px; padding: 0 7px; border-radius: 6px;
  background: var(--gc, var(--bg-3)); color: var(--gc-fg, var(--fg));
  font-size: 11.5px; font-weight: 600; letter-spacing: .005em; line-height: 20px;
  white-space: nowrap; max-width: 160px; overflow: hidden; text-overflow: ellipsis;
  border: 0; box-shadow: none; vertical-align: 1px; flex: none;
}
button.gchip { cursor: pointer; }
button.gchip:hover { filter: brightness(.94); }
.gchip-lg { height: 26px; line-height: 26px; padding: 0 10px; font-size: 13px; border-radius: 8px; max-width: 260px; vertical-align: middle; }
.gdot { width: 10px; height: 10px; border-radius: 3px; background: var(--gc); flex: none; display: inline-block; }
.gdot.is-empty { background: transparent; box-shadow: inset 0 0 0 1.5px var(--line-3); }
.menu-item .gdot { margin: 0 3px; }
.prop-btn .gdot { margin-right: 2px; }
.chip-add-group { border-style: dashed; color: var(--fg-3); box-shadow: none; }
.chip-add-group:hover { color: var(--fg); }
.trow-tags .gchip { max-width: 140px; }
.mini-task .gchip { max-width: 120px; }

/* Kartu papan: bayangan penuh (tidak matte) */
.bcard {
  position: relative; background: var(--bg); color: var(--fg);
  border: 1px solid var(--line); border-radius: 12px; padding: 12px 12px 11px; gap: 9px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, .06), 0 8px 18px -8px rgba(0, 0, 0, .2);
  transition: box-shadow .2s var(--ease), transform .2s var(--ease), border-color .2s;
}
.bcard:hover { border-color: var(--line-2); box-shadow: 0 2px 4px rgba(0, 0, 0, .07), 0 16px 30px -12px rgba(0, 0, 0, .28); transform: translateY(-1px); }
[data-theme="dark"] .bcard { background: #0d0d0d; border-color: #222; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .04), 0 12px 26px -10px rgba(0, 0, 0, .95); }
[data-theme="dark"] .bcard:hover { border-color: #2e2e2e; }
.bcard.is-colored { border-color: transparent; }
.bcard.is-solid, [data-theme="dark"] .bcard.is-solid {
  background: var(--gc); border-color: transparent;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .18), 0 1px 2px rgba(0, 0, 0, .12), 0 12px 24px -12px color-mix(in srgb, var(--gc) 70%, #000);
}
.bcard.is-solid:hover, [data-theme="dark"] .bcard.is-solid:hover { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .2), 0 2px 4px rgba(0, 0, 0, .14), 0 20px 34px -14px color-mix(in srgb, var(--gc) 80%, #000); }
.bcard.is-soft {
  background: color-mix(in srgb, var(--gc) 15%, #ffffff); border-color: color-mix(in srgb, var(--gc) 26%, transparent);
  box-shadow: 0 1px 2px rgba(0, 0, 0, .05), 0 12px 24px -14px color-mix(in srgb, var(--gc) 75%, transparent);
}
[data-theme="dark"] .bcard.is-soft { background: color-mix(in srgb, var(--gc) 20%, #0a0a0a); border-color: color-mix(in srgb, var(--gc) 32%, transparent); }
.bcard.is-solid .gchip { background: rgba(0, 0, 0, .17); color: var(--fg); }
.bcard.is-done:not(.is-colored) .bcard-title > span:first-child { color: var(--fg-3); }
.bcard-top { display: flex; align-items: flex-start; gap: 8px; }
.bcard-title { flex: 1; min-width: 0; font-weight: 600; font-size: 13.5px; line-height: 1.45; word-break: break-word; }
.bcard-title > span:first-child { margin-right: 6px; }
.bcard-foot { flex-wrap: wrap; row-gap: 6px; }
.bcard .avatar-stack .avatar { box-shadow: 0 0 0 2px var(--bg), inset 0 0 0 1px var(--line-2); }
.bcard.is-soft .avatar-stack .avatar { box-shadow: inset 0 0 0 1px var(--line-2); }
.bcard.is-preview { cursor: default; transform: none !important; }
.bcard.is-dragging-proxy { transform: rotate(1.5deg); }
.drag-proxy.bcard { box-shadow: 0 30px 60px -12px rgba(0, 0, 0, .35); }

/* Checklist di kartu */
.bcheck { display: flex; flex-direction: column; gap: 2px; margin: 0 -5px; }
.bcheck-head {
  display: flex; align-items: center; gap: 7px; height: 26px; padding: 0 5px; width: 100%;
  border-radius: 7px; color: var(--fg-2); font-size: 12px; font-weight: 600; text-align: left;
}
.bcheck-head:hover { background: var(--hover); }
.bcheck-head > .i { width: 14px; height: 14px; }
.bcheck-count { min-width: 26px; }
.bcheck-bar { flex: 1; height: 4px; border-radius: 4px; background: var(--bg-3); overflow: hidden; }
.bcheck-bar i { display: block; height: 100%; background: var(--fg); border-radius: 4px; transition: width .3s var(--ease); }
.bcheck-chev { color: var(--fg-3); transition: transform .2s var(--ease); }
.bcheck.is-collapsed .bcheck-chev { transform: rotate(-90deg); }
.bcheck.is-collapsed .bcheck-list { display: none; }
.bcheck-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.bcheck-item {
  display: flex; align-items: flex-start; gap: 8px; padding: 4px 5px; border-radius: 7px;
  font-size: 12.5px; line-height: 1.4; cursor: pointer; user-select: none; color: var(--fg);
}
.bcheck-item:hover { background: var(--hover); }
.bcheck-item:focus-visible { outline: 2px solid var(--fg); outline-offset: -2px; }
.bcheck-item.is-readonly { cursor: default; }
.bcheck-item.is-readonly:hover { background: transparent; }
.bcheck-item .t { flex: 1; min-width: 0; word-break: break-word; transition: opacity .15s; }
.bcheck-item.is-done .t { text-decoration: line-through; text-decoration-thickness: 1.5px; opacity: .6; }

/* Kotak centang bersama */
.cbox {
  width: 16px; height: 16px; border-radius: 5px; border: 1.5px solid var(--line-3); background: transparent;
  display: grid; place-items: center; flex: none; margin-top: 1px; padding: 0; transition: background .15s, border-color .15s;
}
.cbox .i { width: 11px; height: 11px; stroke-width: 3.2; color: var(--primary-fg); opacity: 0; transform: scale(.5); transition: opacity .15s, transform .15s; }
.is-done > .cbox { background: var(--fg); border-color: var(--fg); }
.is-done > .cbox .i { opacity: 1; transform: none; }
.bcheck-item:hover > .cbox { border-color: var(--fg-3); }
.meta-ico.is-complete { color: var(--fg); }

/* Checklist di detail tugas */
.clist-progress { display: flex; align-items: center; gap: 10px; margin: -4px 0 10px; font-size: 12px; font-weight: 500; color: var(--fg-3); }
.clist-progress .bar { flex: 1; height: 5px; }
.clist { list-style: none; margin: 0; padding: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--bg); }
.clist:empty { display: none; }
.citem { display: flex; align-items: center; gap: 8px; min-height: 42px; padding: 6px 8px 6px 4px; border-bottom: 1px solid var(--line); background: var(--bg); position: relative; }
.citem:last-child { border-bottom: 0; }
.citem:hover { background: var(--bg-2); }
.citem .cbox { width: 18px; height: 18px; margin: 0; cursor: pointer; }
.citem .cbox:disabled { cursor: default; }
.citem .cbox .i { width: 12px; height: 12px; }
.citem-grip { color: var(--fg-4); cursor: grab; display: grid; place-items: center; width: 18px; height: 26px; touch-action: none; opacity: 0; transition: opacity .15s; flex: none; }
.citem:hover .citem-grip, .citem.is-dragging .citem-grip { opacity: 1; }
.citem-grip .i { width: 15px; height: 15px; }
.citem-text { flex: 1; min-width: 0; font-size: 14px; cursor: text; word-break: break-word; padding: 2px 0; transition: opacity .15s; }
.citem.is-done .citem-text { text-decoration: line-through; text-decoration-thickness: 1.5px; opacity: .6; }
.citem-meta { font-size: 12px; color: var(--fg-4); white-space: nowrap; }
.citem-del { width: 28px; height: 28px; border-radius: 7px; display: grid; place-items: center; color: var(--fg-4); opacity: 0; flex: none; }
.citem:hover .citem-del, .citem-del:focus-visible { opacity: 1; }
.citem-del:hover { color: var(--danger); background: var(--danger-bg); }
.citem-del .i { width: 15px; height: 15px; }
.citem-edit { flex: 1; min-width: 0; border: 0; outline: none; background: transparent; font-size: 14px; padding: 2px 0; box-shadow: inset 0 -1.5px 0 var(--fg-3); }
.citem.is-dragging { z-index: 2; box-shadow: var(--shadow); cursor: grabbing; }
@media (hover: none) { .citem-grip, .citem-del { opacity: 1; } }
.clist-add { display: flex; align-items: center; gap: 10px; height: 42px; padding: 0 10px 0 14px; margin-top: 8px; border: 1px dashed var(--line-3); border-radius: var(--radius); color: var(--fg-3); transition: border-color .15s, box-shadow .15s; }
.clist-add:focus-within { border-style: solid; border-color: var(--fg-3); box-shadow: var(--ring); color: var(--fg-2); }
.clist-add > .i { width: 16px; height: 16px; }
.clist-add-input { flex: 1; min-width: 0; border: 0; outline: none; background: transparent; font-size: 14px; height: 100%; }
.clist-add-input::placeholder { color: var(--fg-4); }

/* Judul detail + chip group */
.detail-title-text { flex: 1; min-width: 0; display: flex; align-items: center; flex-wrap: wrap; gap: 6px 12px; }
.detail-title-text h1 { flex: 0 1 auto; min-width: 0; }

/* Form tugas: checklist awal */
.tm-row-top { align-items: start; }
.tm-row-top .lbl { padding-top: 7px; }
.form-check-list { display: flex; flex-direction: column; }
.form-check-list:empty { display: none; }
.form-check-item { display: flex; align-items: center; gap: 10px; font-size: 13.5px; min-height: 32px; border-bottom: 1px solid var(--line); }
.form-check-item .cbox { margin: 0; }
.form-check-add { position: relative; display: flex; align-items: center; }
.form-check-add > .i { position: absolute; left: 10px; width: 14px; height: 14px; color: var(--fg-3); pointer-events: none; }
.form-check-add .input { padding-left: 30px; }
.tm-props .chip .gdot { margin-right: 1px; }

/* Color picker hexagon */
.hexpick { display: flex; flex-direction: column; gap: 6px; width: 100%; max-width: 300px; user-select: none; }
.hexpick-map, .hexpick-grays { width: 100%; height: auto; display: block; overflow: visible; }
.hexpick-cell { cursor: pointer; transition: opacity .12s; }
.hexpick-cell:hover { stroke: var(--fg); stroke-width: 1.4; }
.hexpick-sel-outer { stroke: #0a0a0a; stroke-width: 4.6; stroke-linejoin: round; pointer-events: none; }
.hexpick-sel-inner { stroke: #ffffff; stroke-width: 2.3; stroke-linejoin: round; pointer-events: none; }
.hexpick-foot { display: flex; align-items: center; gap: 8px; margin-top: 4px; }
.hexpick-swatch { width: 32px; height: 32px; border-radius: 8px; box-shadow: inset 0 0 0 1px rgba(127, 127, 127, .3); flex: none; }
.hexpick-input { width: 104px; font-family: var(--mono); text-transform: uppercase; letter-spacing: .02em; }
.hexpick-input.is-invalid { border-color: var(--danger); }
.hexpick-more { position: relative; overflow: hidden; margin-left: auto; }
.hexpick-native { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; border: 0; padding: 0; }

/* Editor group */
.group-editor { display: grid; grid-template-columns: minmax(0, 1fr) 270px; gap: 24px; align-items: start; padding-top: 4px; }
.group-preview { display: flex; flex-direction: column; gap: 10px; padding: 16px; border-radius: var(--radius-lg); background: var(--bg-3); border: 1px solid var(--line); position: sticky; top: 0; }
[data-theme="dark"] .group-preview { background: #0a0a0a; }

/* Halaman Group */
.group-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.group-card {
  display: flex; align-items: center; gap: 12px; padding: 14px; min-width: 0;
  border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--bg);
  box-shadow: 0 1px 2px rgba(0, 0, 0, .05), 0 8px 18px -12px rgba(0, 0, 0, .2); transition: box-shadow .18s, border-color .18s, transform .18s;
}
.group-card:hover { border-color: var(--line-2); box-shadow: 0 2px 4px rgba(0, 0, 0, .06), 0 16px 28px -14px rgba(0, 0, 0, .3); transform: translateY(-1px); }
.group-swatch { width: 44px; height: 44px; border-radius: 11px; background: var(--gc); color: var(--gc-fg); display: grid; place-items: center; font-weight: 700; font-size: 14px; letter-spacing: -.02em; flex: none; }
.group-name { font-weight: 600; font-size: 14.5px; letter-spacing: -.01em; }
.group-meta { font-size: 12.5px; color: var(--fg-3); margin-top: 2px; }

/* Pengaturan gaya kartu */
.style-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.style-card { border: 1px solid var(--line-2); border-radius: var(--radius-lg); padding: 14px; text-align: left; background: var(--bg-3); display: flex; flex-direction: column; gap: 12px; transition: border-color .15s, box-shadow .15s; }
[data-theme="dark"] .style-card { background: #0a0a0a; }
.style-card:hover { border-color: var(--line-3); }
.style-card.is-active { border-color: var(--fg); box-shadow: 0 0 0 1px var(--fg); }
.style-card .theme-card-label { flex-direction: column; align-items: flex-start; gap: 2px; margin: 0; }
.settings-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: -4px 0 16px; flex-wrap: wrap; }

/* Kalender: penanda warna group */
.cal-item.has-group { box-shadow: inset 3px 0 0 var(--gc); padding-left: 8px; }

@media (max-width: 640px) {
  .group-editor { grid-template-columns: minmax(0, 1fr); }
  .group-preview { position: static; }
  .style-cards { grid-template-columns: minmax(0, 1fr); }
  .cal-item.has-group { background: var(--gc); box-shadow: none; padding: 0; }
}
.is-sorting, .is-sorting * { cursor: grabbing !important; user-select: none !important; }
