/* ============================================================
   NOA DASHBOARD — DESIGN SYSTEM v2 "Mission Control"
   Stack: custom properties + komponen; Tailwind = utility layer.
   Tema: [data-theme="light"] / [data-theme="dark"].
   ============================================================ */

/* ---------- 1. TOKENS ---------- */
:root {
  --font-sans: 'Inter', ui-sans-serif, system-ui, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, monospace;

  --radius-sm: 6px;
  --radius: 8px;
  --radius-lg: 12px;
  --sidebar-w: 244px;
  --topbar-h: 58px;

  --ease: cubic-bezier(.4, 0, .2, 1);
}

[data-theme="light"] {
  color-scheme: light;
  --bg: #F3F5F8;
  --bg-accent: radial-gradient(1200px 500px at 80% -10%, rgba(22,163,74,.07), transparent 60%);
  --surface: #FFFFFF;
  --surface-2: #F8FAFC;
  --surface-3: #EEF2F6;
  --border: #E4E9EF;
  --border-strong: #CBD5E1;
  --text: #101828;
  --text-2: #475467;
  --text-muted: #98A2B3;

  --primary: #16A34A;
  --primary-hover: #12813C;
  --primary-soft: #E9F9F0;
  --on-primary: #FFFFFF;

  --success: #16A34A;
  --success-soft: #E9F9F0;
  --warning: #B45309;
  --warning-bright: #F59E0B;
  --warning-soft: #FEF6E7;
  --danger: #DC2626;
  --danger-soft: #FEECEC;
  --info: #2563EB;
  --info-soft: #EAF1FE;

  --shadow-xs: 0 1px 2px rgba(16,24,40,.05);
  --shadow-sm: 0 1px 3px rgba(16,24,40,.08), 0 1px 2px rgba(16,24,40,.04);
  --shadow-md: 0 8px 24px -6px rgba(16,24,40,.14), 0 2px 6px rgba(16,24,40,.06);
  --shadow-lg: 0 24px 60px -12px rgba(16,24,40,.25);
  --terminal-bg: #0C1424;
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0B1120;
  --bg-accent: radial-gradient(1100px 480px at 75% -10%, rgba(52,211,153,.08), transparent 55%);
  --surface: #131C2E;
  --surface-2: #182338;
  --surface-3: #1F2C45;
  --border: #25334D;
  --border-strong: #37476A;
  --text: #E6EBF4;
  --text-2: #9AA8BF;
  --text-muted: #5D6E8C;

  --primary: #22C55E;
  --primary-hover: #4ADE80;
  --primary-soft: rgba(34,197,94,.12);
  --on-primary: #06220F;

  --success: #4ADE80;
  --success-soft: rgba(74,222,128,.12);
  --warning: #FBBF24;
  --warning-bright: #FBBF24;
  --warning-soft: rgba(251,191,36,.12);
  --danger: #F87171;
  --danger-soft: rgba(248,113,113,.12);
  --info: #60A5FA;
  --info-soft: rgba(96,165,250,.12);

  --shadow-xs: 0 1px 2px rgba(0,0,0,.4);
  --shadow-sm: 0 2px 6px rgba(0,0,0,.35);
  --shadow-md: 0 10px 30px -8px rgba(0,0,0,.5);
  --shadow-lg: 0 28px 70px -12px rgba(0,0,0,.65);
  --terminal-bg: #0A101E;
}

/* ---------- 2. BASE ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.5;
  color: var(--text);
  background-color: var(--bg);
  background-image: var(--bg-accent);
  background-repeat: no-repeat;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--primary); color: var(--on-primary); }

h1, h2, h3, p, ul, dl, dd { margin: 0; }
ul { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; }
code { font-family: var(--font-mono); font-size: .92em; }

:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: 4px;
}

.hidden { display: none !important; }
.tabular { font-variant-numeric: tabular-nums; }

.skip-link {
  position: fixed; top: -48px; left: 16px; z-index: 200;
  padding: 10px 18px;
  background: var(--primary); color: var(--on-primary);
  border-radius: var(--radius-sm);
  font-size: 12px; font-weight: 700; letter-spacing: .08em;
  transition: top .15s var(--ease);
}
.skip-link:focus { top: 12px; }

.mono-label {
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.meta-label {
  font-size: 11px; font-weight: 600;
  letter-spacing: .05em; text-transform: uppercase;
  color: var(--text-muted);
}
.kbd {
  font-family: var(--font-mono); font-size: 10px; font-weight: 600;
  padding: 2px 6px;
  border: 1px solid var(--border-strong);
  border-bottom-width: 2px;
  border-radius: 4px;
  background: var(--surface-2);
  color: var(--text-2);
}

/* ---------- 3. APP SHELL ---------- */
.app-shell { display: flex; min-height: 100vh; }

.app-main {
  flex: 1;
  min-width: 0;
  margin-left: var(--sidebar-w);
  display: flex;
  flex-direction: column;
}

.page-content {
  flex: 1;
  width: 100%;
  max-width: 1440px;
  padding: 24px 28px 48px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* ---------- 4. SIDEBAR ---------- */
.sidebar {
  position: fixed; inset-block: 0; left: 0;
  z-index: 50;
  width: var(--sidebar-w);
  display: flex; flex-direction: column;
  background: var(--surface);
  border-right: 1px solid var(--border);
  transition: transform .22s var(--ease);
}

.sidebar-brand {
  display: flex; align-items: center; gap: 11px;
  height: var(--topbar-h);
  padding: 0 18px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.brand-mark {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; flex-shrink: 0;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--primary), #0E7A38);
  color: #fff;
  font-weight: 800; font-size: 15px; letter-spacing: -.02em;
  box-shadow: var(--shadow-xs);
}
/* Varian logo petir — zap hijau menyala di tile gelap */
.brand-zap {
  background: linear-gradient(150deg, #123524 0%, #071E11 100%);
  border: 1px solid color-mix(in srgb, var(--primary) 45%, transparent);
}
.brand-zap .lucide {
  width: 17px; height: 17px;
  color: #52F2A0;
  filter:
    drop-shadow(0 0 5px rgba(82,242,160,.9))
    drop-shadow(0 0 14px rgba(34,197,94,.55));
  animation: zap-glow 3.2s ease-in-out infinite;
}
@keyframes zap-glow {
  0%, 100% { filter: drop-shadow(0 0 4px rgba(82,242,160,.7)) drop-shadow(0 0 10px rgba(34,197,94,.4)); }
  50% { filter: drop-shadow(0 0 8px rgba(82,242,160,1)) drop-shadow(0 0 20px rgba(34,197,94,.75)); }
}
.login-brand .brand-zap .lucide { width: 21px; height: 21px; }
.brand-name { font-size: 15px; font-weight: 700; letter-spacing: -.01em; line-height: 1.2; }
.brand-sub {
  font-family: var(--font-mono); font-size: 9.5px; font-weight: 600;
  letter-spacing: .14em; color: var(--text-muted);
}

.sidebar-nav { flex: 1; overflow-y: auto; padding: 14px 12px; }
.nav-group { margin-bottom: 18px; }
.nav-group-label {
  padding: 0 10px; margin-bottom: 6px;
  font-family: var(--font-mono); font-size: 10px; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase;
  color: var(--text-muted);
}
.nav-item {
  position: relative;
  display: flex; align-items: center; gap: 8px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  font-size: 13.5px; font-weight: 500;
  color: var(--text-2);
  transition: background .12s var(--ease), color .12s var(--ease);
}
.nav-item:hover { background: var(--surface-3); color: var(--text); }
.nav-item.is-active {
  background: var(--primary-soft);
  color: var(--primary);
  font-weight: 650;
}
.nav-item.is-active::before {
  content: '';
  position: absolute; left: -12px; top: 7px; bottom: 7px;
  width: 3px; border-radius: 0 3px 3px 0;
  background: var(--primary);
}
.nav-meta {
  margin-left: auto;
  font-family: var(--font-mono); font-size: 10.5px; font-weight: 600;
  color: var(--text-muted);
  background: var(--surface-3);
  padding: 1px 7px; border-radius: 99px;
}
.nav-item.is-active .nav-meta { background: transparent; color: var(--primary); }

.sidebar-foot { padding: 12px; border-top: 1px solid var(--border); }
.sidebar-status {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 11px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.logout-form { margin-top: 8px; }
.logout-form .button { width: 100%; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--text-muted); }
.logout-form .button:hover { color: var(--danger); background: var(--danger-soft); }

.sidebar-backdrop {
  position: fixed; inset: 0; z-index: 40;
  background: rgba(8, 12, 20, .55);
  opacity: 0; pointer-events: none;
  transition: opacity .2s var(--ease);
}
.sidebar-backdrop.is-visible { opacity: 1; pointer-events: auto; }

.menu-button { display: none !important; }

/* ---------- 5. TOPBAR ---------- */
.topbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; gap: 12px;
  height: var(--topbar-h);
  padding: 0 28px;
  background: color-mix(in srgb, var(--surface) 86%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.topbar-context { display: flex; align-items: center; gap: 10px; min-width: 0; }
.context-meta { white-space: nowrap; }
.context-divider { width: 1px; height: 14px; background: var(--border-strong); }
.topbar-spacer { flex: 1; }

.health-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 10px;
  border-radius: 99px;
  font-family: var(--font-mono); font-size: 10.5px; font-weight: 600;
  letter-spacing: .06em;
}
.health-pill::before {
  content: ''; width: 6px; height: 6px; border-radius: 99px;
  background: currentColor;
}
.health-pill.is-live { color: var(--success); background: var(--success-soft); }
.health-pill.is-down { color: var(--danger); background: var(--danger-soft); }
.health-pill.is-down::before { animation: pulse 1.1s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .25; } }

.topbar-search {
  display: inline-flex; align-items: center; gap: 10px;
  height: 34px; padding: 0 6px 0 12px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  transition: border-color .12s, background .12s;
}
.topbar-search:hover { border-color: var(--border-strong); background: var(--surface-3); }
.search-hint { font-family: var(--font-mono); font-size: 10px; font-weight: 600; letter-spacing: .05em; }

.session-select {
  height: 34px; max-width: 190px;
  padding: 0 28px 0 10px;
  font-size: 12.5px; font-weight: 550;
  color: var(--text);
  background: var(--surface-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%2398A2B3' stroke-width='1.6' fill='none' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right 10px center;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  appearance: none;
  cursor: pointer;
}

.theme-switch {
  display: inline-flex;
  background: var(--surface-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 2px;
}
.theme-option {
  padding: 4px 10px;
  font-family: var(--font-mono); font-size: 10px; font-weight: 600;
  letter-spacing: .07em;
  color: var(--text-muted);
  background: none; border: none; border-radius: 4px;
  transition: all .12s var(--ease);
}
.theme-option[aria-pressed="true"] {
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-xs);
}

.account-chip {
  display: flex; align-items: center; gap: 9px;
  padding-left: 12px;
  border-left: 1px solid var(--border);
}
.account-chip::before {
  content: 'O';
  display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px;
  border-radius: 99px;
  background: var(--surface-3);
  border: 1px solid var(--border-strong);
  font-size: 12px; font-weight: 700; color: var(--text-2);
}
.account-name { font-size: 12px; font-weight: 650; line-height: 1.25; display: block; }
.account-role {
  font-family: var(--font-mono); font-size: 9px; font-weight: 600;
  letter-spacing: .1em; color: var(--text-muted);
}

/* ---------- 6. PAGE HEADER ---------- */
.page-header { display: flex; flex-direction: column; gap: 4px; }
.breadcrumb {
  display: flex; align-items: center; gap: 7px;
  font-family: var(--font-mono); font-size: 10.5px; font-weight: 600;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--text-muted);
}
.breadcrumb li + li::before { content: '/'; margin-right: 7px; color: var(--border-strong); }
.breadcrumb .is-current { color: var(--primary); }

.page-header-row {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 16px; flex-wrap: wrap;
}
.h1.page-title {
  font-size: 23px; font-weight: 750; letter-spacing: -.02em; line-height: 1.2;
}
.page-description { margin-top: 3px; font-size: 13px; color: var(--text-2); max-width: 62ch; }
.page-actions { display: flex; gap: 8px; flex-shrink: 0; }

/* ---------- 7. CARD ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
}
.section-card { overflow: hidden; }
.card > .card-head,
.section-card > .card-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}
.card:not(.section-card) > .card-head { border-bottom: 0; padding-bottom: 0; }
.card:not(.section-card) { padding: 18px; }
.card:not(.section-card) > .card-head { padding: 0 0 12px; }
.card-head { min-width: 0; }
.card-title { font-size: 14px; font-weight: 700; letter-spacing: -.01em; min-width: 0; }
.card-list li {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 18px;
  border-top: 1px solid var(--border);
  transition: background .1s;
}
.card-list li:first-child { border-top: 0; }
.card-list li:hover { background: var(--surface-2); }
.list-divide > * + * { border-top: 1px solid var(--border); }

/* ---------- 8. METRIC / STAT ---------- */
.stat-value {
  font-size: 26px; font-weight: 750; letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
  line-height: 1.15; margin-top: 6px;
}
.stat-sub { margin-top: 2px; font-size: 12px; color: var(--text-muted); }

/* ---------- 9. BADGE / CHIP / SEGMENTED ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 2px 9px;
  border-radius: 99px;
  font-size: 11px; font-weight: 600; letter-spacing: .01em;
  border: 1px solid transparent;
  white-space: nowrap;
}
.badge::before { content: ''; width: 5px; height: 5px; border-radius: 99px; background: currentColor; }
.badge--success { color: var(--success); background: var(--success-soft); }
.badge--warning { color: var(--warning); background: var(--warning-soft); }
.badge--danger  { color: var(--danger);  background: var(--danger-soft); }
.badge--info    { color: var(--info);    background: var(--info-soft); }
.badge--neutral { color: var(--text-2);  background: var(--surface-3); }
.badge--plain { color: var(--text-muted); background: var(--surface-3); }
.badge--plain::before { display: none; }

.chip-row { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.chip {
  padding: 4px 12px;
  border-radius: 99px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 12px; font-weight: 550;
  color: var(--text-2);
  transition: all .12s var(--ease);
}
.chip:hover { border-color: var(--border-strong); color: var(--text); }
.chip.is-active {
  background: var(--primary-soft);
  border-color: var(--primary);
  color: var(--primary);
  font-weight: 650;
}
.chip-count {
  font-family: var(--font-mono); font-size: 10px; font-weight: 600;
  opacity: .75; margin-left: 4px;
}

.filter-group {
  display: inline-flex; gap: 2px;
  background: var(--surface-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 3px;
}
.filter-btn {
  padding: 5px 13px;
  border: none; background: none; border-radius: 5px;
  font-family: var(--font-mono); font-size: 11px; font-weight: 600;
  letter-spacing: .04em;
  color: var(--text-2);
  transition: all .12s var(--ease);
}
.filter-btn:hover { color: var(--text); }
.filter-btn.is-active {
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-xs);
}

/* Switch — dua varian: checkbox (.switch-input) & button role=switch
   (aria-checked) yg dipakai cmd-toggle di cards/detail command. */
.switch { position: relative; display: inline-flex; align-items: center; }
.switch-input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.switch-track {
  position: relative;
  width: 34px; height: 20px; flex-shrink: 0;
  border-radius: 99px;
  background: var(--border-strong);
  transition: background .15s var(--ease);
}
.switch-track::after {
  content: '';
  position: absolute; top: 2px; left: 2px;
  width: 16px; height: 16px; border-radius: 99px;
  background: #fff;
  box-shadow: var(--shadow-xs);
  transition: transform .15s var(--ease);
}
.switch-input:checked + .switch-track,
.switch[aria-checked="true"] > .switch-track {
  background: var(--primary);
}
.switch-input:checked + .switch-track::after,
.switch[aria-checked="true"] > .switch-track::after {
  transform: translateX(14px);
}
.switch-input:focus-visible + .switch-track,
.switch:focus-visible .switch-track {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* ---------- 10. BUTTONS ---------- */
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  height: 38px; padding: 0 16px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font-size: 13px; font-weight: 600; letter-spacing: .005em;
  transition: all .13s var(--ease);
  position: relative;
  white-space: nowrap;
}
.button:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.button:disabled { opacity: .55; cursor: not-allowed; }

.button--primary { background: var(--primary); color: var(--on-primary); box-shadow: var(--shadow-xs); }
.button--primary:hover:not(:disabled) { background: var(--primary-hover); }

.button--secondary {
  background: var(--surface);
  border-color: var(--border-strong);
  color: var(--text);
  box-shadow: var(--shadow-xs);
}
.button--secondary:hover:not(:disabled) { background: var(--surface-2); border-color: var(--text-muted); }

.button--ghost { background: none; color: var(--text-2); }
.button--ghost:hover:not(:disabled) { background: var(--surface-3); color: var(--text); }

.button--outline {
  background: none; border-color: var(--border-strong); color: var(--text-2);
}
.button--outline:hover:not(:disabled) { border-color: var(--warning); color: var(--warning); background: var(--warning-soft); }

.button--danger { background: var(--danger); color: #fff; }
.button--danger:hover:not(:disabled) { filter: brightness(1.08); }

.button--danger-outline { background: none; border-color: var(--danger); color: var(--danger); }
.button--danger-outline:hover:not(:disabled) { background: var(--danger-soft); }

.button--sm { height: 31px; padding: 0 12px; font-size: 12px; }
.button.is-disabled, .button:disabled.is-disabled { opacity: .5; cursor: not-allowed; }

.button.is-loading { color: transparent !important; pointer-events: none; }
.button.is-loading::after {
  content: '';
  position: absolute;
  width: 15px; height: 15px;
  border: 2px solid color-mix(in srgb, currentColor 30%, transparent);
  border-top-color: var(--primary);
  border-radius: 99px;
  animation: spin .6s linear infinite;
}
.button--primary.is-loading::after { border-color: color-mix(in srgb, var(--on-primary) 35%, transparent); border-top-color: var(--on-primary); }
@keyframes spin { to { transform: rotate(360deg); } }

.action-link {
  background: none; border: none; padding: 4px 8px;
  border-radius: 5px;
  font-size: 12px; font-weight: 600;
  color: var(--primary);
  transition: background .1s;
}
.action-link:hover { background: var(--primary-soft); }
.action-link--muted { color: var(--text-2); }
.action-link--muted:hover { background: var(--surface-3); color: var(--text); }
.action-link--danger { color: var(--danger); }
.action-link--danger:hover { background: var(--danger-soft); }

/* ---------- 11. FORMS ---------- */
.stack { display: flex; flex-direction: column; }
.gap-1 { gap: 4px; } .gap-2 { gap: 8px; } .gap-3 { gap: 12px; } .gap-4 { gap: 16px; }

.form-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.form-label { font-size: 12.5px; font-weight: 650; color: var(--text); }
.helper-text { font-size: 12px; line-height: 1.45; color: var(--text-muted); }

.input {
  width: 100%;
  height: 38px;
  padding: 0 12px;
  font-size: 13.5px;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  transition: border-color .12s, box-shadow .12s;
}
textarea.input { height: auto; padding: 9px 12px; resize: vertical; min-height: 88px; line-height: 1.55; }
select.input { cursor: pointer; }
.input::placeholder { color: var(--text-muted); }
.input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent);
}
input[type="checkbox"], input[type="radio"] { width: 16px; height: 16px; accent-color: var(--primary); }

.pin-input { font-family: var(--font-mono); font-size: 17px; letter-spacing: .35em; text-align: center; }

/* ---------- 12. ALERT / TOAST ---------- */
.alert {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 11px 14px;
  border-radius: var(--radius);
  font-size: 13px; font-weight: 500;
  border: 1px solid;
}
.alert--success { background: var(--success-soft); border-color: color-mix(in srgb, var(--success) 35%, transparent); color: var(--success); }
.alert--warning { background: var(--warning-soft); border-color: color-mix(in srgb, var(--warning) 35%, transparent); color: var(--warning); }
.alert--danger  { background: var(--danger-soft);  border-color: color-mix(in srgb, var(--danger) 35%, transparent);  color: var(--danger); }

.toast-region {
  position: fixed; right: 20px; bottom: 20px; z-index: 150;
  display: flex; flex-direction: column; gap: 10px;
  width: min(360px, calc(100vw - 32px));
}
.toast {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 12px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--success);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  animation: toast-in .22s var(--ease);
}
.toast--error { border-left-color: var(--danger); }
.toast--warning { border-left-color: var(--warning); }
.toast--info { border-left-color: var(--info); }
.toast.is-leaving { opacity: 0; transform: translateY(8px); transition: all .2s var(--ease); }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px); } }
.toast-title {
  font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  letter-spacing: .1em; color: var(--success);
}
.toast--error .toast-title { color: var(--danger); }
.toast--warning .toast-title { color: var(--warning); }
.toast--info .toast-title { color: var(--info); }
.toast-message { font-size: 12.5px; color: var(--text-2); margin-top: 2px; }
.toast-close {
  background: none; border: none;
  font-family: var(--font-mono); font-size: 9.5px; font-weight: 700;
  letter-spacing: .08em; color: var(--text-muted);
  padding: 3px 5px; border-radius: 4px; flex-shrink: 0;
}
.toast-close:hover { color: var(--text); background: var(--surface-3); }

/* ---------- 13. MODAL ---------- */
.confirm-dialog {
  width: min(420px, calc(100vw - 40px));
  padding: 22px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}
.confirm-dialog::backdrop { background: rgba(6, 10, 18, .6); backdrop-filter: blur(3px); }
.confirm-title { font-size: 15px; font-weight: 700; }
.confirm-body { margin-top: 8px; font-size: 13.5px; line-height: 1.55; color: var(--text-2); }
.confirm-foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 20px; }

/* ---------- 14. TABLE ---------- */
.table-container {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
  overflow: hidden;
}
.data-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.data-table th {
  padding: 10px 16px;
  text-align: left;
  font-family: var(--font-mono); font-size: 10.5px; font-weight: 600;
  letter-spacing: .09em; text-transform: uppercase;
  color: var(--text-muted);
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.data-table td { padding: 12px 16px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr { transition: background .1s; }
.data-table tbody tr:hover { background: var(--surface-2); }
.data-table tbody tr.is-muted td { opacity: .55; }
.cell-strong { font-weight: 650; }
.cell-mono { font-family: var(--font-mono); font-size: 12px; color: var(--text-2); }
.cell-desc { margin-top: 2px; font-size: 12px; color: var(--text-muted); max-width: 42ch; }
.cell-actions { text-align: right; white-space: nowrap; }

.data-list { display: flex; flex-direction: column; }
.data-row {
  display: flex; align-items: baseline; justify-content: space-between; gap: 16px;
  padding: 9px 0;
  border-bottom: 1px dashed var(--border);
  font-size: 13px;
}
.data-row:last-child { border-bottom: 0; }
.data-row dt { color: var(--text-muted); font-weight: 500; flex-shrink: 0; }
.data-row dd { text-align: right; min-width: 0; font-weight: 550; }

/* ---------- 15. FEED / LOG / TERMINAL ---------- */
.feed-row {
  display: flex; align-items: baseline; gap: 10px;
  padding: 8px 18px;
  font-size: 12.5px;
  border-top: 1px solid var(--border);
}
li:first-child.feed-row, .card-list .feed-row:first-child, #activity-feed .feed-row:first-child { border-top: 0; }
.feed-time { font-family: var(--font-mono); font-size: 10.5px; color: var(--text-muted); flex-shrink: 0; }
.feed-text { color: var(--text-2); min-width: 0; }
.feed-text b { color: var(--text); font-weight: 650; }
.feed-empty { padding: 22px 18px; font-size: 12.5px; color: var(--text-muted); text-align: center; }

.log-viewer {
  margin: 0;
  padding: 12px 14px;
  overflow-y: auto;
  font-family: var(--font-mono); font-size: 11.5px; line-height: 1.7;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  list-style: none;
}
.dark-scroll { background: var(--terminal-bg); border-color: color-mix(in srgb, var(--border) 60%, black); color: #B7C3D8; }
.dark-scroll::-webkit-scrollbar-thumb { background: #2A3A57; }
.log-empty { color: var(--text-muted); text-align: center; padding: 14px 0; }
.dark-scroll .log-empty { color: #5D6E8C; }

.log-line { display: flex; gap: 8px; white-space: pre-wrap; word-break: break-word; }
.log-time { color: #5D6E8C; flex-shrink: 0; }
.log-level { font-weight: 700; flex-shrink: 0; width: 58px; }
.log-level--DEBUG { color: #5D6E8C; }
.log-level--INFO { color: #7DD3FC; }
.log-level--WARN { color: #FBBF24; }
.log-level--ERROR { color: #F87171; }
.log-level--CRITICAL { color: #FCA5A5; background: rgba(248,113,113,.15); border-radius: 3px; padding: 0 4px; }
.log-source { color: #93A5C4; }
.log-session { color: #64748B; }
.log-message { color: #C4CFE2; min-width: 0; }
.conn-line { display: flex; gap: 8px; }
.conn-time { color: #5D6E8C; flex-shrink: 0; }
.conn-msg { color: #C4CFE2; word-break: break-word; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 99px; border: 2px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-track { background: transparent; }

/* ---------- 16. PAIRING ---------- */
.pairing-hint { font-size: 12.5px; line-height: 1.55; color: var(--text-2); }
.pairing-code {
  font-family: var(--font-mono);
  font-size: 27px; font-weight: 700; letter-spacing: .18em;
  text-align: center;
  padding: 18px 12px;
  color: var(--primary);
  background: var(--primary-soft);
  border: 1px dashed color-mix(in srgb, var(--primary) 45%, transparent);
  border-radius: var(--radius);
  user-select: all;
}
.pairing-qr { display: flex; justify-content: center; padding: 12px; background: #fff; border-radius: var(--radius); }
.pairing-qr svg { display: block; }

/* ---------- 17. CHART (analytics) ---------- */
.chart-note {
  padding: 10px 14px;
  font-size: 12.5px; color: var(--text-2);
  background: var(--info-soft);
  border: 1px solid color-mix(in srgb, var(--info) 30%, transparent);
  border-radius: var(--radius);
}
.chart-note b { color: var(--info); }
.chart { display: flex; align-items: flex-end; gap: 8px; height: 180px; }
.chart-col {
  flex: 1; height: 100%;
  display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 6px;
  border-radius: 5px;
  transition: background .12s;
}
.chart-col:hover { background: var(--surface-2); }
.chart-bar {
  width: 100%; max-width: 44px;
  border-radius: 5px 5px 2px 2px;
  background: linear-gradient(180deg, var(--primary), color-mix(in srgb, var(--primary) 72%, transparent));
  min-height: 2px;
  transition: filter .12s;
}
.chart-bar:hover { filter: brightness(1.1); }
.chart-bar.is-peak { box-shadow: 0 0 0 2px color-mix(in srgb, var(--primary) 30%, transparent); }
.chart-val { font-family: var(--font-mono); font-size: 10.5px; font-weight: 700; color: var(--text-2); }
.chart-labels {
  display: flex; gap: 8px; padding-top: 8px;
  border-top: 1px dashed var(--border);
}
.chart-labels span {
  flex: 1; text-align: center;
  font-family: var(--font-mono); font-size: 10px; color: var(--text-muted);
}
.chart-chip {
  font-family: var(--font-mono); font-size: 10.5px; font-weight: 600;
  padding: 4px 11px;
  background: var(--surface-3);
  border-radius: 99px;
  color: var(--text-2);
}

/* ---------- 18. COMMAND PALETTE ---------- */
.overlay-backdrop {
  position: fixed; inset: 0; z-index: 90;
  background: rgba(6, 10, 18, .55);
  backdrop-filter: blur(2px);
  opacity: 0; pointer-events: none;
  transition: opacity .18s var(--ease);
}
.overlay-backdrop.is-visible { opacity: 1; pointer-events: auto; }

.command-palette {
  position: fixed; z-index: 100;
  top: 14vh; left: 50%;
  transform: translateX(-50%) scale(.97);
  width: min(560px, calc(100vw - 32px));
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  opacity: 0; pointer-events: none;
  transition: opacity .15s var(--ease), transform .15s var(--ease);
  overflow: hidden;
}
.command-palette.is-open { opacity: 1; pointer-events: auto; transform: translateX(-50%) scale(1); }
.palette-input {
  width: 100%; height: 48px;
  padding: 0 18px;
  font-family: var(--font-mono); font-size: 13.5px;
  color: var(--text);
  background: none; border: none;
  border-bottom: 1px solid var(--border);
}
.palette-input:focus { outline: none; }
.palette-list { max-height: 320px; overflow-y: auto; padding: 6px; }
.palette-item {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  width: 100%; padding: 10px 12px;
  background: none; border: none; border-radius: var(--radius-sm);
  text-align: left;
  font-size: 13px; font-weight: 550; color: var(--text);
  cursor: pointer;
}
.palette-item:first-child { margin-top: 0; }
.palette-item.is-active { background: var(--primary-soft); color: var(--primary); }
.palette-path { font-family: var(--font-mono); font-size: 10.5px; color: var(--text-muted); }
.palette-empty { padding: 26px; text-align: center; font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; color: var(--text-muted); }

/* ---------- 19. AUTH / LOGIN ---------- */
.auth-body {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  min-height: 100vh;
  padding: 24px;
  gap: 18px;
}
.login-card {
  width: min(400px, 100%);
  padding: 32px 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow-md);
  animation: rise-in .35s var(--ease);
}
@keyframes rise-in { from { opacity: 0; transform: translateY(14px); } }
.login-brand { display: flex; align-items: center; gap: 13px; }
.login-brand .brand-mark { width: 42px; height: 42px; font-size: 18px; border-radius: 11px; }
.login-brand .brand-name { font-size: 18px; }
.login-brand .brand-sub { font-size: 10px; }
.login-tagline { margin-top: 16px; font-size: 13.5px; color: var(--text-2); }
.login-stack { display: flex; flex-direction: column; gap: 16px; margin-top: 20px; }
.login-foot { font-size: 12px; color: var(--text-muted); }

/* ---------- 20. FOOTER ---------- */
.app-footer { border-top: 1px solid var(--border); background: var(--surface); }
.footer-inner {
  max-width: 1440px;
  margin-inline: auto;
  padding: 12px 28px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.status-line { display: inline-flex; align-items: center; gap: 8px; }
.status-dot {
  width: 8px; height: 8px; border-radius: 99px;
  background: var(--success);
  box-shadow: 0 0 0 3px var(--success-soft);
  animation: pulse 2.4s ease-in-out infinite;
}
.status-dot.is-down { background: var(--warning-bright); box-shadow: 0 0 0 3px var(--warning-soft); }

/* ---------- 21. EMPTY STATE ---------- */
.state-panel {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 40px 24px;
  text-align: center;
}
.state-title { font-size: 14.5px; font-weight: 700; }
.state-text { font-size: 13px; color: var(--text-muted); max-width: 44ch; margin-bottom: 10px; }

/* ---------- 22. STEPPER (form wizard) ---------- */
.stepper { display: flex; flex-direction: column; gap: 0; counter-reset: step; }
.step { display: flex; gap: 12px; position: relative; padding-bottom: 18px; }
.step:last-child { padding-bottom: 0; }
.step::before {
  content: '';
  position: absolute; left: 13px; top: 28px; bottom: 2px;
  width: 2px; border-radius: 2px;
  background: var(--border);
}
.step:last-child::before { display: none; }
.step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 27px; height: 27px; flex-shrink: 0;
  border-radius: 99px;
  border: 2px solid var(--border-strong);
  background: var(--surface);
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  color: var(--text-muted);
  position: relative; z-index: 1;
}
.step.is-done .step-num { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.step.is-current .step-num { border-color: var(--primary); color: var(--primary); }
.step-title { font-size: 13px; font-weight: 650; padding-top: 4px; }
.step-desc { font-size: 12px; color: var(--text-muted); margin-top: 1px; }

/* ---------- 23. TIMELINE (aktivitas) ---------- */
.timeline { position: relative; padding-left: 20px; }
.timeline::before {
  content: '';
  position: absolute; left: 5px; top: 6px; bottom: 6px;
  width: 2px; border-radius: 2px;
  background: var(--border);
}
.timeline-item { position: relative; padding: 7px 0 7px 4px; font-size: 12.5px; color: var(--text-2); }
.timeline-item::before {
  content: '';
  position: absolute; left: -19px; top: 14px;
  width: 8px; height: 8px; border-radius: 99px;
  background: var(--surface);
  border: 2px solid var(--border-strong);
}
.timeline-item.tone-success::before { border-color: var(--success); }
.timeline-item.tone-warning::before { border-color: var(--warning-bright); }
.timeline-item.tone-danger::before { border-color: var(--danger); }
.timeline-item.tone-info::before { border-color: var(--info); }
.timeline-time {
  display: block;
  font-family: var(--font-mono); font-size: 10px; color: var(--text-muted);
}

/* ---------- 24. RESPONSIVE ---------- */
@media (max-width: 1024px) {
  .page-content { padding: 20px 18px 40px; }
  .topbar { padding: 0 18px; }
  .footer-inner { padding: 12px 18px; }
}

@media (max-width: 820px) {
  :root { --sidebar-w: 0px; }
  .app-main { margin-left: 0; }
  .menu-button { display: inline-flex !important; }
  .sidebar {
    transform: translateX(-105%);
    width: min(300px, 84vw);
    box-shadow: var(--shadow-lg);
  }
  .sidebar.is-open { transform: translateX(0); }
  .topbar-context { display: none; }
  .topbar-search { display: none; }
  .session-select { display: none; }
  .account-chip span { display: none; }
  .account-chip { border-left: 0; padding-left: 0; }
  .stat-value { font-size: 21px; }
  .page-header-row { align-items: flex-start; flex-direction: column; }
}

/* ---------- 25. ICONS (lucide) & ICON BUTTON ---------- */
.lucide { width: 16px; height: 16px; flex-shrink: 0; }
/* Ukuran placeholder sebelum lucide render (anti layout-shift & anti ikon kosong) */
i[data-lucide] { display: inline-block; width: 16px; height: 16px; flex-shrink: 0; }
.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px;
  background: none; border: none; border-radius: var(--radius-sm);
  color: var(--text-2);
  transition: background .12s, color .12s;
}
.icon-btn:hover { background: var(--surface-3); color: var(--text); }
.icon-btn .lucide { width: 18px; height: 18px; }
.nav-item .lucide { width: 16.5px; height: 16.5px; color: var(--text-muted); transition: color .12s; }
.nav-item:hover .lucide, .nav-item.is-active .lucide { color: inherit; }

/* ---------- 26. STAT STRIP (analytics) ---------- */
.stat-strip {
  display: flex; align-items: stretch;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
  overflow-x: auto;
}
.strip-item { flex: 1; min-width: 128px; padding: 14px 18px; display: flex; flex-direction: column; gap: 2px; }
.strip-item + .strip-item { border-left: 1px solid var(--border); }
.strip-value { font-size: 21px; font-weight: 750; letter-spacing: -.02em; font-variant-numeric: tabular-nums; line-height: 1.2; }
.mini-track { height: 6px; border-radius: 99px; background: var(--surface-3); overflow: hidden; margin-top: 8px; }
.mini-fill { height: 100%; border-radius: 99px; background: var(--primary); }
.mini-fill.is-alt { background: var(--info); }

/* ---------- 27. TABS ---------- */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--border); padding: 0 18px; background: var(--surface); border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
.tab {
  padding: 11px 15px;
  background: none; border: none;
  font-size: 13px; font-weight: 600; color: var(--text-muted);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  display: inline-flex; align-items: center; gap: 7px;
  transition: color .12s, border-color .12s;
}
.tab:hover { color: var(--text); }
.tab.is-active { color: var(--primary); border-bottom-color: var(--primary); }
.tab-panel[hidden] { display: none !important; }

/* ---------- 28. COMMAND ROWS (list, bukan tabel) ---------- */
.cmd-list { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-xs); overflow: hidden; }
.cmd-row {
  display: flex; align-items: center; gap: 14px;
  padding: 13px 18px;
  border-top: 1px solid var(--border);
  transition: background .1s;
}
.cmd-row:first-child { border-top: 0; }
.cmd-row:hover { background: var(--surface-2); }
.cmd-row.is-muted .cmd-name, .cmd-row.is-muted .cmd-desc, .cmd-row.is-muted .cmd-triggers { opacity: .5; }
.cmd-id { min-width: 220px; flex-shrink: 0; }
.cmd-name { font-family: var(--font-mono); font-weight: 700; font-size: 13px; display: inline; }
.cmd-desc { margin-top: 2px; font-size: 12px; color: var(--text-muted); }
.cmd-triggers { display: flex; flex-wrap: wrap; gap: 5px; min-width: 0; flex: 1; }
.trigger-chip {
  font-family: var(--font-mono); font-size: 11px; font-weight: 600;
  padding: 2px 9px;
  color: var(--primary);
  background: var(--primary-soft);
  border-radius: 99px;
}
.cmd-meta { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

/* ---------- 29. PROVIDER BANNER (AI) ---------- */
.provider-banner {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 16px;
  background: var(--success-soft);
  border: 1px solid color-mix(in srgb, var(--success) 30%, transparent);
  border-radius: var(--radius);
}
.provider-banner .lucide { color: var(--success); }

/* ---------- 30. COMMAND GRID CARD ---------- */
.cmd-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 14px;
}
.cmd-card {
  display: flex; flex-direction: column; gap: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
  padding: 15px 16px;
  transition: border-color .13s var(--ease), box-shadow .13s var(--ease), transform .13s var(--ease);
}
.cmd-card:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}
.cmd-card.is-muted { opacity: .6; }
.cmd-card-head { display: flex; align-items: center; gap: 8px; min-width: 0; }
.cmd-card-name {
  font-family: var(--font-mono); font-size: 13.5px; font-weight: 700;
  color: var(--text);
  transition: color .12s;
}
.cmd-card:hover .cmd-card-name { color: var(--primary); }
.cmd-card-desc {
  font-size: 12.5px; line-height: 1.5; color: var(--text-2);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; min-height: 2.9em;
}
.cmd-card-triggers { display: flex; flex-wrap: wrap; gap: 5px; }
.cmd-card-foot {
  display: flex; align-items: center; gap: 8px;
  margin-top: auto; padding-top: 10px;
  border-top: 1px dashed var(--border);
}
.cmd-card-link { margin-right: auto; }

/* ---------- 31. SETTINGS INDEX ---------- */
.settings-grid { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 24px; align-items: start; }
.settings-index { position: sticky; top: calc(var(--topbar-h) + 20px); display: flex; flex-direction: column; gap: 2px; }
.settings-index a {
  padding: 7px 12px;
  border-left: 2px solid var(--border);
  font-size: 13px; font-weight: 550; color: var(--text-muted);
  transition: color .12s, border-color .12s;
}
.settings-index a:hover { color: var(--text); border-left-color: var(--border-strong); }
.settings-group-head { display: flex; align-items: center; gap: 9px; }
.settings-group-head .lucide { color: var(--primary); }
@media (max-width: 900px) {
  .settings-grid { grid-template-columns: 1fr; }
  .settings-index { display: none; }
}

/* ---------- 32. AI CONFIG GRID ---------- */
input[type="range"] {
  width: 100%;
  accent-color: var(--primary);
  height: 22px;
  cursor: pointer;
}
.range-val {
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  padding: 2px 9px;
  background: var(--primary-soft);
  color: var(--primary);
  border-radius: 99px;
}
/* Anti-overflow: semua anak grid card tidak boleh memaksa lebar */
.grid > .card { min-width: 0; max-width: 100%; }
.card input, .card select, .card textarea { max-width: 100%; }

/* ---------- 33. LANDING (halaman publik /) ---------- */
/* Grid statik — identitas technical/grid-oriented, subtle + fade radial
   agar readability konten utama tidak berkurang (AGENTS.md §8). */
.landing-body {
  --grid-line: color-mix(in srgb, var(--border-strong) 42%, transparent);
}
[data-theme="dark"] .landing-body { --grid-line: color-mix(in srgb, var(--border-strong) 52%, transparent); }
.landing-body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(to right, var(--grid-line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--grid-line) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(120% 92% at 50% 0%, #000 18%, transparent 74%);
          mask-image: radial-gradient(120% 92% at 50% 0%, #000 18%, transparent 74%);
}

.landing-wrap { max-width: 1120px; margin-inline: auto; padding-inline: 28px; }

.landing-header {
  position: sticky; top: 0; z-index: 30;
  background: color-mix(in srgb, var(--surface) 86%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.landing-nav { display: flex; align-items: center; gap: 18px; }
.landing-brand { display: flex; align-items: center; gap: 11px; min-width: 0; }
.landing-nav-links { display: flex; align-items: center; gap: 20px; margin-left: 12px; }
.landing-nav-link {
  font-size: 13px; font-weight: 550;
  color: var(--text-2);
  transition: color .12s var(--ease);
}
.landing-nav-link:hover { color: var(--text); }
.landing-spacer { flex: 1; }

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 400px;
  gap: 48px;
  align-items: center;
  padding-block: 84px 76px;
}
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-mono); font-size: 11px; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase;
  color: var(--primary);
}
.hero-eyebrow::before {
  content: ''; width: 7px; height: 7px; border-radius: 99px;
  background: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-soft);
}
.hero-title {
  margin-top: 18px;
  font-size: clamp(28px, 4.5vw, 44px);
  font-weight: 800; letter-spacing: -.03em; line-height: 1.12;
}
.hero-accent { color: var(--primary); }
.hero-desc {
  margin-top: 16px;
  font-size: 15px; line-height: 1.65;
  color: var(--text-2); max-width: 54ch;
}
.hero-actions { margin-top: 26px; display: flex; flex-wrap: wrap; gap: 10px; }
.hero-meta {
  margin-top: 22px;
  display: flex; flex-wrap: wrap; gap-x: 18px; gap-y: 6px;
  font-family: var(--font-mono); font-size: 10.5px; font-weight: 600;
  letter-spacing: .09em; text-transform: uppercase;
  color: var(--text-muted);
}
.hero-meta span::before { content: '// '; color: var(--border-strong); }

/* Tick HUD '+' di sudut area hero — dekorasi grid minimalis, text-only. */
.hud-tick {
  position: absolute;
  font-family: var(--font-mono); font-size: 13px; line-height: 1;
  color: var(--text-muted); opacity: .55;
  pointer-events: none; user-select: none;
}
.hud-tick--tl { top: 60px; left: 6px; }
.hud-tick--tr { top: 60px; right: 6px; }
.hud-tick--bl { bottom: 52px; left: 6px; }
.hud-tick--br { bottom: 52px; right: 6px; }

/* Terminal quick-start — memakai --terminal-bg + palet warna log system. */
.term {
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  background: var(--terminal-bg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}
.term-head {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 9px 14px;
  border-bottom: 1px solid rgba(148, 163, 184, .14);
}
.term-head .mono-label { color: #5D6E8C; }
.term-body {
  margin: 0; padding: 16px 16px 18px;
  font-family: var(--font-mono); font-size: 12.5px; line-height: 1.85;
  color: #C4CFE2;
  overflow-x: auto;
  white-space: pre;
}
.term-prompt { color: #52F2A0; font-weight: 600; }
.term-cmd { color: #E6EBF4; }
.term-comment { color: #5D6E8C; }
.term-out { color: #93A5C4; }

.features { padding-block: 8px 28px; }
.section-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 16px; flex-wrap: wrap;
  margin-bottom: 16px;
}
.section-title { font-size: 17px; font-weight: 750; letter-spacing: -.02em; }
.section-desc { margin-top: 3px; font-size: 13px; color: var(--text-2); max-width: 62ch; }
.feature-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.feature-card { padding: 18px; }
.feature-index {
  font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  letter-spacing: .14em;
  color: var(--primary);
}
.feature-title { margin-top: 10px; font-size: 14px; font-weight: 700; letter-spacing: -.01em; }
.feature-desc { margin-top: 6px; font-size: 12.5px; line-height: 1.6; color: var(--text-2); }

.stack-card { padding: 16px 18px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.stack-chips { display: flex; flex-wrap: wrap; gap: 8px; }

.landing-foot-note { padding-bottom: 56px; }

#fitur, #mulai { scroll-margin-top: calc(var(--topbar-h) + 20px); }

@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; gap: 34px; padding-block: 56px 52px; }
}
@media (max-width: 640px) {
  .landing-wrap { padding-inline: 18px; }
  .landing-nav-links { display: none; }
}

/* ---------- 34. REDUCED MOTION ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
