/* JARI — Journal Automation & Review Intelligence · gaya app (login, app, install)
   Token warna ikut _sumber/bina_ui.py (Light / Dark). Jenama: Ink #0B1220, Biru Agentic #2F6BFF, Siber #22C4E8,
   Maroon UTM #7A1230, Emas UTM #C9A227, Kertas #F5F7FB. Fon: Outfit (jenama), Roboto (UI), JetBrains Mono (status/log). */

:root {
  --ink: #0B1220; --blue: #2F6BFF; --cyan: #22C4E8; --maroon: #7A1230; --gold: #C9A227; --amb: #F4C24D; --paper: #F5F7FB;
  --mist: #7C879C; --soft: #C3CCE0;
  --glow: linear-gradient(45deg, #0E2A8C 0%, #2F6BFF 55%, #22C4E8 100%);
  --glow-h: linear-gradient(45deg, #0B2378 0%, #255EEB 55%, #1BB2D6 100%);
  --night: linear-gradient(45deg, #0B1220, #14275A);
  --f-brand: "Outfit", system-ui, sans-serif;
  --f-ui: "Roboto", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --bg: #F5F7FB; --bar: #FFFFFF; --card: #FFFFFF; --tile: #F1F4F9; --line: #E2E7F0; --line2: #D3DAE6;
  --term: #FBFCFE; --field: #FFFFFF; --hilite: #EEF3FF; --on: #0B1220; --var: #3E4A61; --outl: #66728A; --outv: #9AA5B8;
  --pri: #1F55D6; --pric: #2F6BFF; --sec: #0E9668; --ter: #C2620A; --err: #D92D20; --xerr: #FFFFFF; --waitic: #FFFFFF;
  --dim: rgba(11, 18, 32, .45); --shadow: 0 12px 40px rgba(11, 18, 32, .14); --utm-border: transparent;
  --pdf-bg: #525866;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #0B1220; --bar: #0E1628; --card: #121C33; --tile: #18243F; --line: #22304F; --line2: #2E3D61;
  --term: #080E1B; --field: #0E1628; --hilite: #1A2A52; --on: #E6ECF7; --var: #B9C4DA; --outl: #8090AE; --outv: #56648A;
  --pri: #7FA6FF; --pric: #2F6BFF; --sec: #34D399; --ter: #FBBF24; --err: #F87171; --xerr: #3B0A0A; --waitic: #0B1220;
  --dim: rgba(3, 6, 13, .66); --shadow: 0 16px 48px rgba(0, 0, 0, .5); --utm-border: var(--gold);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--on); font: 400 14px/1.45 var(--f-ui); -webkit-font-smoothing: antialiased; }
a { color: var(--pri); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
code, pre { font-family: var(--f-mono); }
h1, h2, h3 { margin: 0; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--pric); outline-offset: 2px; }
.ic { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; display: inline-block; vertical-align: middle; }
.ic-f { fill: currentColor; stroke: none; }
.mono { font-family: var(--f-mono); }
.muted { color: var(--outl); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.spin { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
@keyframes blink { 50% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }

/* ------------------------------------------------------------ jenama */
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--on); text-decoration: none !important; }
.brand-mark { width: 35px; height: 35px; flex: none; display: block; }
.brand-word { font: 700 22px/1 var(--f-brand); letter-spacing: .03em; }
.utm-pill { display: inline-flex; align-items: center; height: 18px; padding: 0 7px; border-radius: 9px; background: var(--maroon);
  color: #fff; font: 700 9.2px/1 var(--f-mono); letter-spacing: .12em; border: .8px solid var(--utm-border); white-space: nowrap; }
.brand-lg .brand-mark { width: 52px; height: 52px; }
.brand-lg .brand-word { font-size: 30px; }
.brand-lg .utm-pill { height: 22px; font-size: 11px; padding: 0 9px; border-radius: 11px; }

/* ------------------------------------------------------------ butang (Default / Hover / Aktif / Disabled — Butang-1/2) */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 18px; border-radius: 9px;
  border: 1px solid var(--line2); background: var(--tile); color: var(--var); font: 500 13px/1 var(--f-ui); white-space: nowrap;
  text-decoration: none !important; transition: background .15s, border-color .15s, color .15s, box-shadow .15s, transform .05s; user-select: none; }
.btn .ic { width: 17px; height: 17px; stroke-width: 2; }
.btn:hover { border-color: var(--pric); color: var(--pri); background: var(--hilite); }
.btn:active { transform: translateY(1px); background: var(--line2); color: var(--on); }
.btn:disabled, .btn[aria-disabled="true"] { cursor: not-allowed; background: var(--tile); border-color: var(--line); color: var(--outv); opacity: .75; transform: none; box-shadow: none; }
.btn-pri { background: var(--glow); border: 0; color: #fff; }
.btn-pri:hover { background: var(--glow-h); color: #fff; box-shadow: 0 6px 18px rgba(47, 107, 255, .35); }
.btn-pri:active { background: #1f56c4; color: #fff; }
.btn-pri:disabled { background: var(--tile); color: var(--outv); border: 1px solid var(--line); }
.btn-ter { background: transparent; border: 1.2px solid color-mix(in srgb, var(--ter) 70%, transparent); color: var(--ter); }
.btn-ter:hover { background: color-mix(in srgb, var(--ter) 12%, transparent); color: var(--ter); border-color: var(--ter); }
.btn-ter:active { background: color-mix(in srgb, var(--ter) 22%, transparent); color: var(--ter); }
.btn-err { background: transparent; border: 1.2px solid color-mix(in srgb, var(--err) 60%, transparent); color: var(--err); }
.btn-err:hover { background: color-mix(in srgb, var(--err) 10%, transparent); color: var(--err); border-color: var(--err); }
.btn-err:active { background: color-mix(in srgb, var(--err) 20%, transparent); color: var(--err); }
.btn-danger { background: var(--err); border: 0; color: #fff; }
.btn-danger:hover { background: color-mix(in srgb, var(--err) 85%, #000); color: #fff; border: 0; }
.btn-danger:active { background: color-mix(in srgb, var(--err) 70%, #000); color: #fff; }
.btn-link { background: none; border: 0; color: var(--outl); height: 36px; }
.btn-link:hover { background: none; color: var(--on); text-decoration: underline; }
.btn-sm { height: 34px; padding: 0 12px; font-size: 12.5px; }
.btn-block { display: flex; width: 100%; }
.btn.is-busy { pointer-events: none; }
.icon-btn { position: relative; display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--line2);
  background: transparent; color: var(--outl); padding: 0; transition: background .15s, border-color .15s, color .15s; }
.icon-btn .ic { width: 16px; height: 16px; }
.icon-btn:hover { border-color: var(--pric); color: var(--pri); background: var(--hilite); }
.icon-btn:active, .icon-btn.on { background: color-mix(in srgb, var(--pri) 16%, transparent); border-color: var(--pri); color: var(--pri); }
.icon-btn:disabled { color: var(--outv); border-color: var(--line); background: transparent; cursor: not-allowed; opacity: .6; }
.icon-btn.ok { color: var(--sec); border-color: var(--sec); }
.icon-plain { border-color: transparent; }

.seg { display: inline-flex; padding: 2px; border: 1px solid var(--line2); border-radius: 8px; height: 28px; gap: 0; }
.seg button { border: 0; background: transparent; padding: 0 7px; min-width: 30px; border-radius: 6px; font: 400 11px/1 var(--f-mono); color: var(--outl); }
.seg button:hover { color: var(--pri); }
.seg button.on { background: color-mix(in srgb, var(--pri) 16%, transparent); color: var(--pri); font-weight: 700; }

.pill { display: inline-flex; align-items: center; gap: 6px; height: 20px; padding: 0 9px; border-radius: 10px; font: 400 10px/1 var(--f-mono);
  color: var(--c, var(--pri)); background: color-mix(in srgb, var(--c, var(--pri)) 14%, transparent); white-space: nowrap; letter-spacing: .02em; }
.pill.b { font-weight: 700; letter-spacing: .06em; }
.pill.st { border: 1px solid color-mix(in srgb, var(--c) 40%, transparent); height: 22px; }
.pill .dot, .dot { width: 6.4px; height: 6.4px; border-radius: 50%; background: var(--c, currentColor); flex: none; display: inline-block; }
.c-pri { --c: var(--pri); } .c-sec { --c: var(--sec); } .c-ter { --c: var(--ter); } .c-err { --c: var(--err); } .c-outl { --c: var(--outl); } .c-outv { --c: var(--outv); }
.pulse .dot { animation: pulse 1.4s ease-in-out infinite; }

/* ------------------------------------------------------------ medan borang */
.field { display: block; margin-bottom: 18px; }
.field > span.lbl { display: block; font: 500 12px/1 var(--f-ui); color: var(--var); margin-bottom: 8px; }
.input { position: relative; display: flex; align-items: center; height: 46px; border: 1px solid var(--line2); border-radius: 9px; background: var(--field);
  transition: border-color .15s, box-shadow .15s; }
.input > .ic { position: absolute; left: 14px; width: 17px; height: 17px; color: var(--outl); pointer-events: none; }
.input input, .input select { flex: 1; height: 100%; border: 0; background: transparent; padding: 0 44px 0 42px; outline: none; font-size: 14px; color: var(--on); min-width: 0; }
.input input::placeholder { color: var(--outv); }
.input:focus-within { border-color: var(--pri); border-width: 1.5px; }
.input:focus-within > .ic { color: var(--pri); }
.input.err { border-color: var(--err); border-width: 1.6px; }
.input.err > .ic { color: var(--err); }
.input .eye { position: absolute; right: 8px; width: 32px; height: 32px; border: 1px solid transparent; border-radius: 8px; background: none; color: var(--outl); display: grid; place-items: center; }
.input .eye:hover { border-color: var(--pric); color: var(--pri); background: var(--hilite); }
.input .eye.on { color: var(--pri); background: color-mix(in srgb, var(--pri) 16%, transparent); }
.check { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; font-size: 12px; color: var(--var); user-select: none; }
.check input { appearance: none; width: 16px; height: 16px; border: 1.5px solid var(--line2); border-radius: 4px; background: var(--field); margin: 0; display: grid; place-items: center; cursor: pointer; }
.check input:hover { border-color: var(--pric); }
.check input:checked { background: var(--pric); border-color: var(--pric); }
.check input:checked::after { content: ""; width: 8px; height: 4.5px; border: solid #fff; border-width: 0 0 2.2px 2.2px; transform: translateY(-1px) rotate(-45deg); }
.check input:disabled { opacity: .5; cursor: not-allowed; }

.alert { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 9px; font-size: 13px; line-height: 1.45; margin-bottom: 14px;
  background: color-mix(in srgb, var(--c) 10%, transparent); border: 1px solid color-mix(in srgb, var(--c) 40%, transparent); color: var(--on); }
.alert > .ic { color: var(--c); width: 16px; height: 16px; margin-top: 1px; stroke-width: 2; }
.alert b, .alert strong { color: var(--c); font-weight: 500; }
.alert small { display: block; color: var(--var); font-size: 11.5px; margin-top: 2px; }
.alert-err { --c: var(--err); } .alert-ter { --c: var(--ter); } .alert-sec { --c: var(--sec); } .alert-pri { --c: var(--pri); }

/* ------------------------------------------------------------ tooltip ⓘ */
.info { display: inline-grid; place-items: center; width: 13px; height: 13px; border-radius: 50%; border: 1.1px solid var(--outl); color: var(--outl);
  font: 700 9px/1 var(--f-ui); background: var(--card); padding: 0; vertical-align: middle; cursor: help; flex: none; }
.info:hover, .info:focus-visible { border-color: var(--pri); color: var(--pri); }
.tip { position: fixed; z-index: 1000; max-width: 280px; padding: 12px 14px; border-radius: 9px; background: var(--on); color: var(--bg);
  font: 400 11.5px/1.35 var(--f-ui); box-shadow: var(--shadow); pointer-events: none; opacity: 0; transform: translateY(4px); transition: opacity .12s, transform .12s; }
.tip b { display: block; font: 500 12.5px/1.3 var(--f-ui); margin-bottom: 4px; }
.tip.small { padding: 5px 8px; border-radius: 5px; font: 500 11px/1 var(--f-ui); max-width: 220px; }
.tip.show { opacity: 1; transform: none; }
.tip::before { content: ""; position: absolute; left: var(--ax, 50%); top: -6px; border: 6px solid transparent; border-top: 0; border-bottom-color: var(--on); transform: translateX(-50%); }
.tip.up::before { top: auto; bottom: -6px; border-bottom: 0; border-top: 6px solid var(--on); }

/* ================================================================= LOG MASUK (/login) */
.page-login { min-height: 100vh; background: var(--bg); }
.login { display: grid; grid-template-columns: minmax(420px, 640px) 1fr; min-height: 100vh; }
.login-side { position: relative; background: var(--ink); color: #fff; padding: 56px 64px 40px; display: flex; flex-direction: column; overflow: hidden; }
.login-side .brand { color: #fff; }
.login-side .brand-mark { width: 48px; height: 48px; }
.login-side .brand-word { font-size: 31px; }
.login-side .utm-pill { border-color: var(--gold); height: 20px; font-size: 10px; }
.login-side h1 { font: 700 46px/1.1 var(--f-brand); margin-top: 120px; }
.login-side .lead { font-size: 18px; line-height: 28px; color: var(--soft); max-width: 480px; margin: 16px 0 26px; }
.login-side ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; position: relative; z-index: 1; }
.login-side li { display: flex; align-items: center; gap: 12px; font-size: 15px; color: var(--soft); }
.login-side li .ck { width: 20px; height: 20px; border-radius: 50%; background: rgba(34, 196, 232, .16); color: var(--cyan); display: grid; place-items: center; }
.login-side li .ck .ic { width: 12px; height: 12px; stroke-width: 2.4; }
.login-side .side-pattern { position: absolute; left: 0; right: 0; bottom: 60px; height: 340px; background: url("../img/corak-nod.svg") 0 0 / 1360px auto no-repeat; }
.login-side .side-pattern::after { content: ""; position: absolute; inset: 0; background: var(--night); opacity: .5; }
.login-side .side-foot { margin-top: auto; position: relative; z-index: 1; font: 400 13px/1 var(--f-brand); color: var(--mist); }
.login-main { position: relative; display: flex; flex-direction: column; align-items: center; padding: 42px 56px 40px; }
.login-top { width: 100%; display: flex; justify-content: space-between; align-items: center; }
.login-top .back { display: inline-flex; align-items: center; gap: 6px; color: var(--mist); font-size: 14px; margin-left: 140px; }
.login-top .back .ic { width: 16px; height: 16px; }
.login-top .tools { display: flex; gap: 10px; align-items: center; }
.login-form { width: 400px; max-width: 100%; margin: auto 0; padding: 40px 0; }
.login-form h2 { font: 700 34px/1.15 var(--f-brand); color: var(--on); }
.login-form .sub { font-size: 16px; color: var(--var); margin: 10px 0 34px; }
.login-form .field > span.lbl { font: 500 13px/1 var(--f-ui); color: var(--on); }
.login-form .input { height: 50px; border-radius: 12px; border-width: 1.2px; }
.login-form .input:focus-within { border-width: 1.8px; border-color: var(--pric); }
.login-form .input > .ic { left: 16px; width: 18px; height: 18px; }
.login-form .input input { font-size: 15px; padding-left: 46px; }
.login-form .check { font-size: 14px; margin: 4px 0 24px; }
.login-form .check input { width: 18px; height: 18px; border-radius: 5px; }
.btn-login { height: 54px; border-radius: 27px; font-size: 16px; width: 100%; }
.login-form .forgot { display: block; margin: 22px 0 22px; font-size: 14px; color: var(--pric); }
.login-form .note { display: flex; gap: 10px; padding-top: 20px; border-top: 1px solid var(--line); font-size: 13px; line-height: 19px; color: var(--mist); }
.login-form .note .ic { width: 14px; height: 14px; margin-top: 2px; }
.login-url { align-self: flex-start; margin-left: 140px; font: 400 12px/1 var(--f-mono); color: var(--mist); }
.login .alert { margin: -4px 0 18px; }

.login-form p.forgot { color: var(--pric); }
.login-mtop { display: none; }
.seg-dark { border-color: #3B4A6B; } .seg-dark button { color: var(--mist); } .seg-dark button.on { background: rgba(47,107,255,.25); color: #fff; }

/* ================================================================= PEMASANG */
.page-install { background: var(--bg); }
.inst { min-height: 100vh; display: flex; flex-direction: column; align-items: center; padding: 48px 16px; }
.inst-card { width: 560px; max-width: 100%; background: var(--card); border: 1px solid var(--line2); border-radius: 16px; padding: 32px; box-shadow: var(--shadow); }
.inst-head { text-align: center; margin-bottom: 18px; }
.inst-head .brand { justify-content: center; }
.inst h3 { font: 600 16px/1.3 var(--f-brand); margin: 22px 0 12px; }
.inst-form label { display: block; font: 500 12px/1 var(--f-ui); color: var(--var); margin-bottom: 14px; }
.inst-form input { display: block; width: 100%; margin-top: 7px; height: 42px; border-radius: 9px; border: 1px solid var(--line2); background: var(--field); padding: 0 12px; font-size: 14px; color: var(--on); }
.inst-form input:focus { border-color: var(--pri); outline: none; }
.inst .muted { font-size: 12.5px; }
.inst-secret { background: var(--term); border: 1px solid var(--line); border-radius: 9px; padding: 14px; font-size: 12px; white-space: pre-wrap; word-break: break-all; }
.inst-foot { font-size: 11px; color: var(--outv); margin-top: 18px; text-align: center; }
.inst .btn-block { margin-top: 14px; }

/* ================================================================= APP */
.page-app { min-height: 100vh; overflow-x: hidden; }
.topbar { position: sticky; top: 0; z-index: 50; height: 64px; display: flex; align-items: center; gap: 14px; padding: 0 22px; background: var(--bar); border-bottom: 1px solid var(--line); }
.topbar .vdiv { width: 1px; height: 20px; background: var(--line2); flex: none; }
.topbar .tagline { font-size: 12.5px; color: var(--outl); white-space: nowrap; }
.chips { display: flex; gap: 8px; margin-left: 8px; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px; border-radius: 12px; font-size: 11.5px; white-space: nowrap;
  background: color-mix(in srgb, var(--c) 10%, transparent); border: 1px solid color-mix(in srgb, var(--c) 35%, transparent); cursor: default; }
.chip b { font-weight: 500; color: var(--on); }
.chip span { color: var(--c); }
.chip .dot { width: 7px; height: 7px; }
.chip.c-err .dot { animation: pulse 1.4s infinite; }
.tb-right { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.avatar { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--tile); border: 1px solid var(--line2); color: var(--pri); font: 500 11px/1 var(--f-ui); flex: none; }
.uname { font-size: 13px; color: var(--var); }
.spill { cursor: default; }
.spill.clickable { cursor: pointer; }

.banner { display: flex; align-items: center; gap: 12px; min-height: 50px; padding: 8px 8px 8px 16px; border-radius: 10px; border: 1.4px solid var(--c); background: color-mix(in srgb, var(--c) 9%, var(--card)); margin-bottom: 14px; font: 500 13.5px/1.35 var(--f-ui); }
.banner > .ic { color: var(--c); stroke-width: 2; }
.banner .grow { flex: 1; }
.banner .btn { height: 34px; }

.main { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 24px; padding: 24px; max-width: 1600px; margin: 0 auto; }
.col-l { min-width: 0; display: flex; flex-direction: column; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 12px; }
.card-h { display: flex; align-items: center; gap: 10px; font: 500 15px/1 var(--f-ui); }
.card-h > .ic { color: var(--pri); }
.cap { font: 700 9.5px/1 var(--f-mono); letter-spacing: .08em; color: var(--outl); text-transform: uppercase; display: flex; align-items: center; gap: 8px; }

/* pipeline */
.pipe { padding: 20px 24px 18px; min-height: 172px; }
.pipe .card-h { margin-bottom: 18px; }
.pipe .step-of { margin-left: auto; display: flex; gap: 10px; align-items: center; font: 400 11px/1 var(--f-mono); color: var(--outl); }
.nodes { position: relative; display: grid; grid-template-columns: repeat(8, 1fr); }
.node { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; padding: 0 4px; }
.node::before { content: ""; position: absolute; top: 21px; right: calc(50% + 24px); width: calc(100% - 48px); border-top: 2px dashed var(--line2); }
.node:first-child::before { display: none; }
.node.done::before, .node.active::before, .node.wait::before { border-top-style: solid; border-color: var(--sec); }
.nb { position: relative; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: var(--tile); border: 1.5px solid var(--line2); color: var(--outv); z-index: 1; transition: all .2s; }
.nb .ic { width: 17px; height: 17px; }
.node.done .nb { background: color-mix(in srgb, var(--sec) 14%, var(--card)); border-color: var(--sec); color: var(--sec); }
.node.done .nb .ic { stroke-width: 2.2; }
.node.active .nb { width: 44px; height: 44px; margin-top: -1px; background: var(--glow); border: 2px solid var(--pri); color: #fff; box-shadow: 0 0 0 8px color-mix(in srgb, var(--pri) 10%, transparent); }
.node.wait .nb { width: 44px; height: 44px; margin-top: -1px; background: var(--c); border: 2px solid var(--c); color: var(--waitic); box-shadow: 0 0 0 8px color-mix(in srgb, var(--c) 10%, transparent); }
.node.active .nb .ic, .node.wait .nb .ic { stroke-width: 2; }
.node.notready .nb { background: transparent; border: 1.5px dashed var(--line2); color: var(--outv); opacity: .8; }
.node.notready .nb .lockb { position: absolute; right: -4px; bottom: -4px; width: 16px; height: 16px; border-radius: 50%; background: var(--card); border: 1px solid var(--line2); display: grid; place-items: center; color: var(--outl); }
.node.notready .nb .lockb .ic { width: 10px; height: 10px; stroke-width: 2.2; }
.nl { margin-top: 12px; font-size: 11.5px; line-height: 14px; color: var(--outl); max-width: 104px; display: inline; }
.node.done .nl { color: var(--var); }
.node.active .nl { color: var(--pri); font-weight: 500; }
.node.wait .nl { color: var(--c); font-weight: 500; }
.node.notready .nl { color: var(--outv); }
.nsub { margin-top: 4px; font: 400 9.5px/1.2 var(--f-mono); color: var(--pri); max-width: 120px; }
.node.wait .nsub { color: var(--c); }
.node.notready .nsub { color: var(--outv); }
.nlw { display: flex; align-items: flex-start; justify-content: center; gap: 4px; margin-top: 12px; }
.nlw .nl { margin-top: 0; }

/* jubin tindakan */
.acts { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; margin: 16px 0; }
.tile { position: relative; height: 92px; border-radius: 10px; border: 1px solid var(--line); background: var(--card); color: var(--var); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 8px 12px; text-align: center; font: 400 12px/15px var(--f-ui); transition: all .15s; }
.tile > .ic { width: 22px; height: 22px; }
.tile:hover:not(:disabled) { background: var(--hilite); border-color: color-mix(in srgb, var(--pric) 60%, transparent); color: var(--pri); }
.tile:active:not(:disabled) { transform: translateY(1px); }
.tile.running { border: 1.5px solid var(--pri); color: var(--on); font-weight: 500; }
.tile.running > .ic { color: var(--pri); }
.tile .run-tag { position: absolute; left: 10px; top: 9px; display: flex; align-items: center; gap: 5px; font: 400 9px/1 var(--f-mono); color: var(--pri); }
.tile .run-tag .dot { background: var(--pri); width: 7px; height: 7px; animation: pulse 1.4s infinite; }
.tile .stop-x { position: absolute; right: 6px; top: 5px; width: 18px; height: 18px; border-radius: 50%; border: 0; padding: 0; background: color-mix(in srgb, var(--err) 90%, transparent); color: var(--xerr); display: grid; place-items: center; }
.tile .stop-x .ic { width: 11px; height: 11px; stroke-width: 2.6; }
.tile .stop-x:hover { background: var(--err); transform: scale(1.1); }
.tile:disabled { cursor: not-allowed; background: var(--tile); color: var(--outv); border-color: var(--line); opacity: .8; }
.tile.notready { border-style: dashed; }
.tile-full { background: var(--glow); border: 0; color: #fff; font: 500 13px/1.2 var(--f-ui); }
.tile-full > .ic { width: 26px; height: 26px; }
.tile-full:hover:not(:disabled) { background: var(--glow-h); color: #fff; border: 0; box-shadow: 0 8px 22px rgba(47, 107, 255, .35); }
.tile-full.running { background: #1f56c4; border: 0; color: #fff; }
.tile-full.running > .ic { color: #fff; }
.tile-full.running .run-tag { color: #fff; } .tile-full.running .run-tag .dot { background: #fff; }
.tile-full:disabled { background: var(--tile); color: var(--outv); border: 1px solid var(--line); }

/* terminal */
.term { flex: 1; min-height: 360px; display: flex; flex-direction: column; background: var(--term); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.term-h { height: 44px; flex: none; display: flex; align-items: center; gap: 10px; padding: 0 16px 0 18px; border-bottom: 1px solid var(--line); }
.term-h > .ic { width: 16px; height: 16px; color: var(--outl); }
.term-h .cap { font-size: 11px; }
.term-h .live { margin-left: auto; display: flex; align-items: center; gap: 6px; font: 400 10.5px/1 var(--f-mono); color: var(--sec); margin-right: 8px; }
.term-h .live .dot { background: var(--sec); width: 7px; height: 7px; animation: pulse 2s infinite; }
.term-h .live.off { color: var(--outv); } .term-h .live.off .dot { background: var(--outv); animation: none; }
.term-b { flex: 1; overflow: auto; padding: 16px 20px; font: 400 12px/24px var(--f-mono); color: var(--var); min-height: 0; max-height: calc(100vh - 470px); }
.term-b p { margin: 0; display: grid; grid-template-columns: 92px 52px 1fr; white-space: pre-wrap; word-break: break-word; }
.term-b time { color: var(--outv); }
.term-b b { font-weight: 700; }
.term-b .m { color: var(--on); } .term-b .INFO .m { color: var(--var); }
.lv-INFO { color: var(--pri); } .lv-OK { color: var(--sec); } .lv-WARN { color: var(--ter); } .lv-ERROR { color: var(--err); }
.cursor { display: inline-block; width: 8px; height: 15px; background: var(--pri); opacity: .8; animation: blink 1.1s steps(1) infinite; margin-top: 4px; }
.term-empty { color: var(--outv); }

/* aside */
.aside { padding: 20px; display: flex; flex-direction: column; gap: 0; align-self: start; }
.aside .card-h { margin-bottom: 20px; }
.tiles4 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 12px; }
.stile { height: 56px; border-radius: 9px; background: var(--tile); display: flex; align-items: center; gap: 12px; padding: 0 13px; border: 1px solid transparent; }
.stile > .ic { color: var(--c, var(--var)); }
.stile small { display: block; font: 400 9.5px/1 var(--f-mono); letter-spacing: .06em; color: var(--outl); margin-bottom: 5px; }
.stile b { display: block; font: 500 13px/1 var(--f-ui); color: var(--c, var(--on)); }
.stile.hl { border-color: color-mix(in srgb, var(--c) 50%, transparent); }
.excel { margin-top: 12px; height: 40px; border-radius: 9px; background: var(--tile); display: flex; align-items: center; gap: 8px; padding: 0 12px; font-size: 12px; color: var(--var); }
.excel > .ic { color: var(--sec); width: 16px; height: 16px; }
.excel .cap { font-weight: 400; margin-right: 4px; }
.excel .xn { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.asec { margin-top: 20px; }
.asec > .cap { margin-bottom: 10px; }
.sumrow { height: 40px; border-radius: 9px; background: var(--tile); display: flex; align-items: center; gap: 28px; padding: 0 16px; font: 500 12.5px/1 var(--f-ui); }
.sumrow span { display: flex; align-items: center; gap: 8px; color: var(--c); }
.sumrow .dot { width: 8px; height: 8px; }
.kv { border-radius: 9px; background: var(--tile); padding: 10px 16px; display: grid; gap: 0; }
.kv div { display: flex; justify-content: space-between; gap: 10px; font-size: 12px; line-height: 22px; }
.kv span { color: var(--outl); flex: none; } .kv b { min-width: 0; font-weight: 500; color: var(--on); text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kv .slow { color: var(--ter); font-weight: 400; font-style: italic; }
.fbtns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 12px; }
.fbtn { height: 38px; border-radius: 9px; border: 1px solid color-mix(in srgb, var(--c, var(--pri)) 30%, transparent); background: transparent; display: flex; align-items: center; gap: 8px; padding: 0 12px 0 14px; color: var(--var); font-size: 12px; text-align: left; transition: all .15s; }
.fbtn > .ic { width: 15px; height: 15px; color: var(--c, var(--pri)); }
.fbtn .chev { margin-left: auto; width: 13px; height: 13px; color: var(--outv); }
.fbtn .n { font: 400 10px/1 var(--f-mono); color: var(--outl); }
.fbtn:hover { border-color: var(--pric); background: var(--hilite); color: var(--pri); }
.fbtn:active { background: color-mix(in srgb, var(--pri) 14%, transparent); }
.rp-h { display: flex; align-items: center; gap: 8px; font: 500 13px/1 var(--f-ui); margin: 22px 0 12px; flex-wrap: wrap; }
.rp-h > .ic { color: var(--pri); width: 15px; height: 15px; }
.rp-h .filters { margin-left: auto; display: flex; gap: 6px; }
.dd { height: 22px; border-radius: 5px; border: 1px solid var(--line2); background: var(--tile); color: var(--var); font: 400 10px/1 var(--f-mono); padding: 0 20px 0 7px; appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2366728A' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M7 10l5 5 5-5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 4px center; background-size: 11px; cursor: pointer; }
.dd:hover { border-color: var(--pric); color: var(--pri); }
.dd:focus { border-color: var(--pri); outline: none; }
.chipf { display: flex; gap: 6px; margin-bottom: 10px; }
.chipf button { height: 26px; padding: 0 12px; border-radius: 13px; border: 1px solid var(--line2); background: var(--tile); font: 500 11.5px/1 var(--f-ui); color: var(--var); }
.chipf button:hover { border-color: var(--pri); color: var(--pri); }
.chipf button.on { background: color-mix(in srgb, var(--pri) 16%, transparent); border-color: color-mix(in srgb, var(--pri) 60%, transparent); color: var(--pri); }
.chipf button:disabled { opacity: .5; }
.papers { display: grid; gap: 8px; max-height: 360px; overflow: auto; }
.pcard { border-radius: 9px; background: var(--tile); padding: 12px 14px; }
.pcard .top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.pcard .no { font: 700 13px/1 var(--f-mono); color: var(--pri); }
.pcard .ago { font: 400 10.5px/1 var(--f-mono); color: var(--outl); }
.pcard .cur { font-size: 12px; color: var(--var); margin: 6px 0 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pcard .sim { font: 400 10.5px/1 var(--f-mono); color: var(--outl); margin-left: 6px; }
.stg { display: flex; flex-wrap: wrap; gap: 5px; }
.stg span { display: inline-flex; align-items: center; gap: 5px; height: 16px; padding: 0 7px 0 6px; border-radius: 8px; font: 400 8.5px/1 var(--f-mono); color: var(--c); background: color-mix(in srgb, var(--c) 14%, transparent); }
.stg .dot { width: 5.6px; height: 5.6px; }
.s-done { --c: var(--sec); } .s-run { --c: var(--pri); } .s-wait { --c: var(--outv); } .s-warn { --c: var(--ter); } .s-fail { --c: var(--err); }
.s-run .dot { animation: pulse 1.4s infinite; }
.empty { padding: 22px 12px; text-align: center; color: var(--outl); font-size: 12.5px; border: 1px dashed var(--line2); border-radius: 9px; }
.empty .ic { display: block; margin: 0 auto 8px; width: 26px; height: 26px; color: var(--outv); }
.empty b { display: block; color: var(--var); font-weight: 500; margin-bottom: 4px; }

/* lapisan (modal / laci) */
.overlay { position: fixed; inset: 64px 0 0 0; z-index: 80; background: var(--dim); display: flex; align-items: flex-start; justify-content: center; padding: 32px 16px; overflow: auto; animation: fade .15s ease-out; }
.overlay.full { inset: 0; z-index: 90; }
@keyframes fade { from { opacity: 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(10px) scale(.985); } }
@keyframes slidein { from { transform: translateX(40px); opacity: 0; } }
.modal { position: relative; width: 520px; max-width: 100%; background: var(--card); border: 1px solid var(--line2); border-radius: 16px; padding: 24px 32px 26px; box-shadow: var(--shadow); margin: auto 0; animation: rise .18s ease-out; }
.modal.err-b { border-color: color-mix(in srgb, var(--err) 50%, transparent); }
.mh { display: flex; gap: 16px; align-items: flex-start; margin: 0 -8px 20px -12px; }
.mh .mic { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 14%, transparent); color: var(--c); flex: none; }
.mh .mic.sq { border-radius: 10px; background: color-mix(in srgb, var(--pri) 12%, transparent); color: var(--pri); }
.mh .mic .ic { width: 20px; height: 20px; stroke-width: 2; }
.mh h3 { font: 500 18px/1.3 var(--f-ui); color: var(--on); margin-top: 2px; }
.mh p { margin: 3px 0 0; font-size: 12.5px; color: var(--outl); }
.mh .x { margin-left: auto; }
.modal .body { font-size: 13.5px; line-height: 20px; color: var(--var); }
.modal .foot { display: flex; justify-content: flex-end; gap: 12px; margin-top: 24px; }
.opt-box { border-radius: 10px; background: var(--tile); padding: 16px 18px; margin: 16px 0 20px; display: grid; gap: 12px; }
.opt-box b { display: flex; align-items: center; gap: 8px; font: 500 13px/1.2 var(--f-ui); }
.opt-box p { margin: 4px 0 0; font-size: 12.5px; color: var(--var); }
.stack { display: grid; gap: 10px; }
.stack .btn { height: 46px; }
.center-link { display: block; margin: 14px auto 0; }

/* D3 Pelayar Jauh */
.rb { width: 1100px; max-width: 100%; height: calc(100vh - 64px - 50px); max-height: 770px; display: flex; flex-direction: column; padding: 0; overflow: hidden; }
.rb.fs { position: fixed; inset: 0; width: 100vw; height: 100vh; max-height: none; border-radius: 0; z-index: 95; }
.rb-h { display: flex; align-items: center; gap: 10px; padding: 16px 20px; }
.rb-h > .ic { color: var(--ter); width: 20px; height: 20px; }
.rb-h h3 { font: 500 17px/1 var(--f-ui); }
.rb-h .cd { margin-left: auto; font: 400 11px/1 var(--f-mono); color: var(--outl); margin-right: 8px; }
.rb-h .cd.low { color: var(--err); }
.rb-h .icon-btn { width: 30px; height: 30px; border-radius: 7px; }
.rb-frame { flex: 1; margin: 0 20px; border-radius: 10px; overflow: hidden; background: #F3F4F7; position: relative; min-height: 200px; }
.rb-frame iframe { width: 100%; height: 100%; border: 0; display: block; background: #fff; }
.rb-wait { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; color: #3A3F4B; font-size: 13px; padding: 24px; }
.rb-wait .ic { width: 28px; height: 28px; color: var(--ter); display: block; margin: 0 auto 10px; }
.rb-f { display: flex; align-items: center; gap: 16px; padding: 18px 20px; border-top: 1px solid var(--line); margin-top: 20px; }
.rb-f > .ic { color: var(--pri); width: 18px; height: 18px; flex: none; }
.rb-f p { margin: 0; flex: 1; font-size: 12.5px; line-height: 18px; color: var(--var); max-width: 600px; }
.rb.fs .rb-f, .rb.fs .rb-h { flex: none; }
.float-pill { position: fixed; right: 24px; bottom: 22px; z-index: 70; height: 48px; border-radius: 24px; border: 1.4px solid var(--ter); background: var(--card); display: flex; align-items: center; gap: 10px; padding: 0 18px 0 20px; font: 500 12.5px/1 var(--f-ui); color: var(--on); box-shadow: var(--shadow); }
.float-pill .dot { --c: var(--ter); width: 12px; height: 12px; animation: pulse 1.4s infinite; }
.float-pill .ic { color: var(--ter); width: 14px; height: 14px; }
.float-pill:hover { background: color-mix(in srgb, var(--ter) 10%, var(--card)); }

/* D5 laci fail */
.drawer-wrap { justify-content: flex-end; padding: 0; overflow: hidden; }
.drawer { width: 620px; max-width: 100%; height: 100%; background: var(--bar); border-left: 1px solid var(--line2); display: flex; flex-direction: column; animation: slidein .2s ease-out; }
.drawer-h { display: flex; align-items: flex-start; padding: 26px 24px 0 32px; }
.drawer-h h3 { font: 500 20px/1.2 var(--f-ui); }
.drawer-h p { margin: 6px 0 0; font: 400 12px/1 var(--f-mono); color: var(--outl); }
.drawer-h .x { margin-left: auto; }
.tabs { display: flex; gap: 26px; padding: 0 32px; margin-top: 30px; border-bottom: 1px solid var(--line); margin-left: 32px; margin-right: 32px; padding: 0; overflow-x: auto; scrollbar-width: none; }
.tabs button { position: relative; background: none; border: 0; padding: 0 0 12px; display: flex; align-items: center; gap: 6px; font: 400 13px/1 var(--f-ui); color: var(--var); white-space: nowrap; }
.tabs button:hover { color: var(--pri); text-decoration: underline; text-underline-offset: 4px; }
.tabs button.on { color: var(--pri); font-weight: 500; }
.tabs button.on::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2.5px; border-radius: 1px; background: var(--pri); }
.tabs .pill { height: 17px; padding: 0 5px; font-size: 9.5px; }
.search { margin: 18px 32px 0; }
.search .input { height: 40px; }
.flist { flex: 1; overflow-y: auto; overflow-x: hidden; padding: 16px 32px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; align-content: start; }
.frow { display: flex; align-items: center; gap: 14px; min-width: 0; min-height: 54px; padding: 8px 14px; border-radius: 9px; background: var(--tile); border: 1px solid transparent; }
.frow:hover { background: var(--hilite); border-color: color-mix(in srgb, var(--pri) 35%, transparent); }
.frow .fic { width: 32px; height: 32px; border-radius: 7px; display: grid; place-items: center; background: color-mix(in srgb, var(--c, var(--err)) 12%, transparent); color: var(--c, var(--err)); flex: none; }
.frow .fic .ic { width: 17px; height: 17px; }
.frow .fn { flex: 1; min-width: 0; }
.frow .fn b { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; font: 400 12.5px/1.35 var(--f-mono); color: var(--on); overflow: hidden; overflow-wrap: anywhere; word-break: break-word; }
.frow .fn small { display: block; margin-top: 4px; font-size: 11px; color: var(--outl); }
.frow .fa { display: flex; gap: 10px; flex: none; }
.icon-btn.dl:hover { background: var(--pric); border-color: var(--pric); color: #fff; }
.drawer-f { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 76px; padding: 0 32px; border-top: 1px solid var(--line); flex: none; }
.drawer-f .mono { font-size: 12.5px; color: var(--outl); }

/* D10 pratonton */
.pv { width: calc(100vw - 300px); max-width: 1200px; height: calc(100vh - 80px); padding: 0; display: flex; flex-direction: column; overflow: hidden; }
.pv-h { display: flex; align-items: center; gap: 12px; padding: 12px 20px; flex-wrap: wrap; }
.pv-h > .ic { color: var(--err); }
.pv-h b { font: 400 14px/1 var(--f-mono); }
.pv-h small { color: var(--outl); font-size: 12px; }
.pv-h .acts2 { margin-left: auto; display: flex; gap: 8px; }
.pv-h .btn { height: 36px; font-size: 12.5px; }
.pv-b { flex: 1; background: var(--pdf-bg); }
.pv-b iframe { width: 100%; height: 100%; border: 0; display: block; }
.pv-msg { display: grid; place-items: center; padding: 24px; background: var(--tile); }
.pv-note { max-width: 420px; text-align: center; color: var(--outl); font-size: 13px; }
.pv-note > .ic { display: block; width: 30px; height: 30px; margin: 0 auto 12px; color: var(--pri); }
.pv-note b { display: block; color: var(--on); font-size: 15px; font-weight: 500; margin-bottom: 6px; }
.pv-note p { margin: 0 0 18px; line-height: 1.5; }
.pv-note .btn { display: inline-flex; height: 38px; }

/* D8 masalah */
.d8 { width: 780px; padding: 24px 32px; }
.d8 .grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.d8 .cell { border-radius: 9px; background: var(--tile); padding: 12px 14px; min-width: 0; }
.d8 .cell small { display: block; font: 700 9.5px/1 var(--f-mono); letter-spacing: .06em; color: var(--outl); margin-bottom: 8px; }
.d8 .cell b { display: block; font: 500 13.5px/1.25 var(--f-ui); color: var(--on); overflow-wrap: anywhere; }
.d8 .cell .errt { font: 400 12.5px/1.3 var(--f-mono); color: var(--err); }
.d8 .alert { margin: 14px 0 0; font-size: 12.5px; }
.d8 .retry { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 16px; font-size: 12px; line-height: 20px; color: var(--var); }
.bars-h { display: flex; justify-content: space-between; margin-top: 16px; font: 400 10.5px/1 var(--f-mono); color: var(--outl); }
.bars { display: grid; grid-template-columns: repeat(72, 1fr); gap: 3px; height: 22px; margin-top: 10px; }
.bars i { border-radius: 2px; background: var(--line2); opacity: .85; }
.bars i.up { background: var(--sec); } .bars i.slow { background: var(--ter); } .bars i.down { background: var(--err); }
.qlist { display: grid; gap: 4px; margin-top: 10px; max-height: 170px; overflow: auto; }
.qrow { display: flex; align-items: center; gap: 12px; height: 26px; padding: 0 14px; border-radius: 6px; background: var(--tile); font-size: 12px; color: var(--var); }
.qrow.stopped { background: color-mix(in srgb, var(--err) 8%, transparent); }
.qrow b { font: 700 12px/1 var(--f-mono); color: var(--pri); width: 62px; }
.qrow .qs { margin-left: auto; display: flex; align-items: center; gap: 6px; font: 400 10.5px/1 var(--f-mono); color: var(--c); }
.qrow .qs .dot { width: 6px; height: 6px; }
.dec { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 14px; }
.dec label { position: relative; display: block; border-radius: 10px; border: 1px solid var(--line2); padding: 14px 16px 14px 46px; cursor: pointer; min-height: 96px; }
.dec input { position: absolute; left: 16px; top: 17px; appearance: none; width: 16px; height: 16px; border-radius: 50%; border: 1.6px solid var(--outl); background: var(--card); margin: 0; }
.dec input:checked { border-color: var(--pri); box-shadow: inset 0 0 0 3px var(--card); background: var(--pri); }
.dec label:has(input:checked) { border: 1.6px solid var(--pri); background: color-mix(in srgb, var(--pri) 8%, transparent); }
.dec label:hover { border-color: var(--pric); }
.dec b { display: block; font: 500 13px/1.3 var(--f-ui); color: var(--on); }
.dec .clr b { color: var(--err); }
.dec p { margin: 6px 0 0; font-size: 11.5px; line-height: 15px; color: var(--var); }
.dec .pill { margin-top: 6px; height: 18px; font-size: 9px; }

/* toasts D17 */
.toasts { position: fixed; top: 76px; right: 20px; z-index: 200; display: grid; gap: 10px; width: 410px; max-width: calc(100vw - 32px); }
.toast { position: relative; display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 9px 16px 9px 16px; border-radius: 12px; background: var(--card);
  border: 1px solid color-mix(in srgb, var(--c) 45%, transparent); box-shadow: var(--shadow); animation: slidein .2s ease-out; overflow: hidden; }
.toast::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 4px; border-radius: 2px; background: var(--c); }
.toast .tic { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 14%, transparent); color: var(--c); flex: none; margin-left: 2px; }
.toast .tic .ic { width: 15px; height: 15px; stroke-width: 2; }
.toast .tt { flex: 1; min-width: 0; }
.toast b { display: block; font: 500 13px/1.3 var(--f-ui); }
.toast small { display: block; font-size: 11.5px; color: var(--outl); margin-top: 2px; }
.toast .ta { background: none; border: 0; color: var(--pri); font: 500 12.5px/1 var(--f-ui); padding: 4px; }
.toast .ta:hover { text-decoration: underline; }
.toast .tx { background: none; border: 0; color: var(--outl); padding: 2px; }
.toast .prog { height: 4px; border-radius: 2px; background: var(--line2); margin-top: 7px; overflow: hidden; }
.toast .prog i { display: block; height: 100%; width: 40%; background: var(--glow); border-radius: 2px; animation: indet 1.2s ease-in-out infinite; }
@keyframes indet { 0% { transform: translateX(-100%); } 100% { transform: translateX(250%); } }

/* D6 credentials */
.credp { padding: 24px 40px 40px; max-width: 1440px; margin: 0 auto; }
.crumb { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--outl); }
.crumb a { color: var(--outl); display: inline-flex; align-items: center; gap: 6px; }
.crumb a:hover { color: var(--pri); }
.crumb span { color: var(--var); }
.credp h1 { font: 500 26px/1.2 var(--f-ui); margin-top: 18px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.credp .lead { color: var(--outl); font-size: 13.5px; margin: 8px 0 20px; }
.cred-grid { display: grid; grid-template-columns: minmax(0, 900px) minmax(0, 420px); gap: 40px; align-items: start; }
.ccard { padding: 20px; margin-bottom: 16px; transition: border-color .2s; }
.ccard.bad { border: 1.6px solid var(--err); }
.ccard .row1 { display: flex; align-items: flex-start; gap: 16px; }
.ccard .cic { width: 40px; height: 40px; border-radius: 10px; background: color-mix(in srgb, var(--pri) 12%, transparent); color: var(--pri); display: grid; place-items: center; flex: none; }
.ccard .cic .ic { width: 20px; height: 20px; }
.ccard h3 { font: 500 16px/1.2 var(--f-ui); margin-bottom: 7px; }
.ccard .cacts { margin-left: auto; display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.ccard .cacts .btn { height: 38px; }
.ccard .cacts .icon-btn { width: 38px; height: 38px; border-radius: 9px; }
.ccols { display: grid; grid-template-columns: 330px 200px 1fr; gap: 18px; margin: 18px 0 0 56px; }
.ccols small { display: block; font: 700 9.5px/1 var(--f-mono); letter-spacing: .06em; color: var(--outl); margin-bottom: 8px; }
.ccols span { display: block; font: 400 12.5px/1.2 var(--f-mono); color: var(--on); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ccols .pw { color: var(--var); }
.cfoot { margin: 14px 0 0 56px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 11.5px; color: var(--outl); }
.cfoot.plain { border: 0; padding-top: 0; font-size: 12.5px; }
.howc { padding: 22px 24px; margin-bottom: 16px; }
.howc ol { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 16px; }
.howc li { display: flex; gap: 12px; font-size: 12.5px; line-height: 17px; color: var(--var); }
.howc li i { font-style: normal; width: 22px; height: 22px; border-radius: 50%; background: color-mix(in srgb, var(--pri) 14%, transparent); color: var(--pri); font: 500 11.5px/22px var(--f-ui); text-align: center; flex: none; }
.howc .card-h > .ic { color: var(--sec); }
.alog { padding: 22px 24px; }
.alog ul { list-style: none; padding: 0; margin: 14px 0 0; }
.alog li { display: flex; align-items: center; gap: 10px; height: 44px; border-bottom: 1px solid var(--line); font-size: 12.5px; }
.alog li time { font: 400 11.5px/1 var(--f-mono); color: var(--outl); width: 52px; flex: none; }
.alog li b { font-weight: 500; }
.alog li span { color: var(--var); }
.alog li em { margin-left: auto; font: normal 400 11.5px/1 var(--f-mono); color: var(--c, var(--sec)); max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.toggle { position: relative; width: 42px; height: 24px; flex: none; }
.toggle input { appearance: none; width: 42px; height: 24px; border-radius: 12px; background: var(--line2); margin: 0; cursor: pointer; transition: background .15s; }
.toggle input:checked { background: var(--pric); }
.toggle input::after { content: ""; position: absolute; left: 3px; top: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .15s; }
.toggle input:checked::after { transform: translateX(18px); }
.trow { display: flex; align-items: center; gap: 12px; border-radius: 10px; background: var(--tile); padding: 10px 16px; margin-bottom: 18px; }
.trow div { flex: 1; } .trow b { display: block; font: 500 13px/1.3 var(--f-ui); } .trow small { font-size: 11.5px; color: var(--outl); }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.modal hr { border: 0; border-top: 1px solid var(--line); margin: 6px 0 18px; }
.modal h4 { font: 500 13px/1.2 var(--f-ui); margin: 0; }
.modal .hint { font-size: 12px; color: var(--outl); margin: 4px 0 10px; }
.input.mono-in input { font-family: var(--f-mono); letter-spacing: .04em; }

/* ------------------------------------------------------------ D18 / D19 / M7 Paparan Langsung (lihat sahaja) */
.term.tabbed .term-h .live { margin-left: 0; }
.term-h .lv-title { font: 500 14px/1 var(--f-ui); color: var(--on); }
.term.is-live { background: var(--card); }
.term.is-live .term-h > .ic { color: var(--pri); width: 17px; height: 17px; }
.ptabs { margin-left: auto; display: flex; gap: 8px; margin-right: 6px; }
.ptabs button { height: 28px; padding: 0 14px; border-radius: 14px; border: 1px solid var(--line2); background: transparent; color: var(--var); font: 500 12.5px/1 var(--f-ui); }
.ptabs button:hover { border-color: var(--pric); color: var(--pri); }
.ptabs button.on { border-color: var(--pri); background: color-mix(in srgb, var(--pri) 14%, transparent); color: var(--pri); }
.term-h .icon-btn { width: 28px; height: 28px; border-radius: 7px; }
.term-h .icon-btn .ic { width: 14px; height: 14px; }
.lv-badge { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 11px 0 9px; border-radius: 12px; background: #D92D20; color: #fff;
  font: 700 11px/1 var(--f-mono); letter-spacing: .08em; flex: none; }
.lv-badge .dot { width: 7px; height: 7px; background: #fff; animation: pulse 1.6s infinite; }
.lv-badge.off { background: #66728A; }
.lv-badge.off .dot { animation: none; opacity: .7; }
.live-b { flex: 1; min-height: 0; padding: 14px 16px 16px; }
.live-b[hidden] { display: none; }
.lv-grid { display: grid; grid-template-columns: minmax(0, 1fr) 272px; gap: 20px; align-items: start; }
.lv-stage { position: relative; aspect-ratio: 5 / 3; border-radius: 6px; overflow: hidden; background: #0B1220; border: 1px solid var(--line); }
.lv-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; display: none; background: #0B1220; }
.lv-stage.has .lv-img { display: block; }
.lv-stage.stale .lv-img { opacity: .28; filter: grayscale(1); }
.lv-ph { position: absolute; inset: 0; display: none; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 24px; text-align: center; color: #C3CCE0; }
.lv-stage.stale .lv-ph, .lv-stage:not(.has) .lv-ph { display: flex; }
.lv-ph > .ic { width: 34px; height: 34px; color: #7C879C; }
.lv-ph-t b { display: block; font: 500 15px/1.3 var(--f-ui); color: #fff; margin-bottom: 6px; }
.lv-ph-t span { font-size: 12.5px; line-height: 1.45; max-width: 420px; display: inline-block; }
.lv-ib { position: absolute; left: 12px; top: 12px; }
.lv-cap { position: absolute; left: 0; right: 0; bottom: 0; min-height: 40px; display: flex; align-items: center; gap: 16px; padding: 8px 16px;
  background: rgba(11, 18, 32, .78); color: #fff; font: 500 13px/1.3 var(--f-ui); }
.lv-cap-t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lv-cap-tm { font: 400 12px/1 var(--f-mono); color: #C3CCE0; flex: none; }
.lv-stage.stale .lv-cap, .lv-stage:not(.has) .lv-cap { display: none; }
.lv-side { display: flex; flex-direction: column; min-width: 0; padding-top: 6px; }
.lv-side > .cap { margin: 0 0 10px; }
.lv-side > .cap ~ .cap { margin-top: 20px; }
.lv-watch { border-radius: 10px; background: var(--tile); padding: 12px 16px 13px; }
.lv-watch b { display: flex; align-items: center; gap: 10px; font: 500 13px/1 var(--f-ui); color: var(--on); }
.lv-watch b .dot { width: 9px; height: 9px; background: var(--sec); }
.lv-watch p { margin: 9px 0 0; font-size: 11.5px; line-height: 15px; color: var(--var); }
.lv-take { margin-top: 14px; height: 40px; font-size: 12.5px; }
.lv-now { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.lv-now li { display: grid; grid-template-columns: 18px minmax(0, 1fr) auto; align-items: center; gap: 8px; min-height: 30px; font-size: 12px; color: var(--on); }
.lv-now li > .ic { width: 14px; height: 14px; color: var(--c); stroke-width: 2.2; }
.lv-now li.nx { color: var(--outv); }
.lv-now .tx { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lv-now time { font: 400 10.5px/1 var(--f-mono); color: var(--outl); }
.lv-now .lv-empty { display: block; color: var(--outl); font-size: 12px; min-height: 0; padding: 4px 0; }
.lv-stream { font: 400 11.5px/20px var(--f-mono); color: var(--var); }
.lv-stream div { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* D19: skrin penuh #/live */
.r-live .topbar { display: none; }
.lvp { min-height: 100vh; background: #05080F; display: flex; flex-direction: column; }
.lvp-bar { height: 56px; flex: none; display: flex; align-items: center; gap: 14px; padding: 0 24px; background: var(--bar); border-bottom: 1px solid var(--line); }
.lvp-back { display: inline-flex; align-items: center; gap: 8px; color: var(--var); font-size: 13px; margin-right: 18px; }
.lvp-back:hover { color: var(--pri); text-decoration: none; }
.lvp-back .ic { width: 16px; height: 16px; }
.lvp-bar h1 { font: 500 15px/1 var(--f-ui); margin: 0; color: var(--on); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lvp-bar .grow { flex: 1; }
.lvp-bar .btn { height: 36px; font-size: 12.5px; }
.lvp-bar .btn-err { min-width: 156px; }
.lvp-main { flex: 1; display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 20px; padding: 20px; }
.lvp-col { min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.lvp-col .lv-stage { border-color: #1A2438; border-radius: 4px; max-height: calc(100vh - 290px); aspect-ratio: auto; height: calc((100vw - 440px) * .6); min-height: 280px; }
.lvp-col .lv-ib { display: none; }
.lvp-out { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px 10px; }
.lvp-out .cap { margin-bottom: 8px; }
.lvp-out .lv-out { padding: 0; max-height: 132px; font-size: 11.5px; line-height: 22px; overflow: hidden; }
.lvp-out .lv-out p { grid-template-columns: 88px 48px 1fr; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lvp-steps { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 20px 18px; display: flex; flex-direction: column; align-self: stretch; }
.lvp-steps h2 { font: 500 15px/1 var(--f-ui); margin: 0 0 22px; }
.lv-steps { list-style: none; margin: 0; padding: 0; flex: 1; }
.lv-steps li { position: relative; display: flex; gap: 14px; min-height: 58px; }
.lv-steps li::before { content: ""; position: absolute; left: 15px; top: 32px; bottom: 2px; border-left: 2px dashed var(--line2); }
.lv-steps li:last-child::before { display: none; }
.lv-steps li.ls-done::before { border-left-style: solid; }
.lsb { --c: var(--outv); width: 32px; height: 32px; border-radius: 50%; flex: none; display: grid; place-items: center; color: var(--c);
  background: color-mix(in srgb, var(--c) 16%, transparent); border: 1.4px solid var(--c); }
.lsb .ic { width: 14px; height: 14px; stroke-width: 2.2; }
.ls-done .lsb { --c: var(--sec); } .ls-run .lsb { --c: var(--pri); } .ls-lock .lsb { border-style: dashed; }
.lv-steps b { display: block; font: 400 12.5px/1.2 var(--f-ui); color: var(--on); margin-top: 3px; }
.lv-steps .ls-run b { font-weight: 500; }
.lv-steps .ls-lock b { color: var(--outv); }
.lv-steps small { display: block; margin-top: 4px; font: 400 10.5px/1.2 var(--f-mono); color: var(--outv); }
.lv-steps .ls-done small { color: var(--sec); } .lv-steps .ls-run small { color: var(--pri); }
.lv-pace { margin: 12px 0 0; font: 400 11px/1.4 var(--f-mono); color: var(--outl); }
.lv-pace:empty { display: none; }
.lvm { display: none; }

/* M2: kad ke M7 */
.mlive { display: none; }

/* ------------------------------------------------------------ telefon (M2–M6) */
.mview { display: none; }
.tabbar { display: none; }
.mhead { display: none; }

@media (max-width: 1240px) {
  .topbar .tagline, .topbar .tagline + .vdiv { display: none; }
  .main { grid-template-columns: minmax(0, 1fr) 360px; }
  .cred-grid { grid-template-columns: 1fr; }
  .ccols { grid-template-columns: 1fr 1fr; margin-left: 0; }
  .cfoot { margin-left: 0; }
}
@media (max-width: 1020px) {
  .main { grid-template-columns: 1fr; }
  .term-b { max-height: 420px; }
  .uname { display: none; }
  .nl { font-size: 10.5px; }
}
@media (max-width: 900px) {
  .login { grid-template-columns: 1fr; }
  .login-side { display: none; }
  .login-top .back, .login-url { margin-left: 0; }
  .pv { width: 100%; }
}
@media (max-width: 760px) {
  .login-main { padding: 0 0 32px; }
  .login-top { display: none; }
  .login-mtop { display: block; width: 100%; background: var(--ink); color: #fff; padding: 22px 24px 30px; border-bottom: 4px solid transparent;
    border-image: var(--glow) 1; }
  .login-mtop .mt-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 26px; }
  .login-mtop .back { color: var(--soft); display: inline-flex; padding: 4px; }
  .login-mtop .tools { display: flex; gap: 8px; }
  .login-mtop .icon-btn { border-color: #3B4A6B; color: var(--soft); }
  .login-mtop .brand { color: #fff; } .login-mtop .brand-mark { width: 40px; height: 40px; } .login-mtop .brand-word { font-size: 26px; }
  .login-mtop .utm-pill { border-color: var(--gold); }
  .login-mtop h1 { font: 700 30px/1.15 var(--f-brand); margin-top: 40px; }
  .login-mtop p { margin: 8px 0 0; font-size: 14px; color: var(--soft); }
  .login-form { padding: 32px 24px 0; margin: 0; width: 100%; }
  .login-form h2, .login-form .sub { display: none; }
  .login-form .forgot { text-align: center; }
  .login-url { margin: 24px 24px 0; align-self: center; text-align: center; }
}

@media (max-width: 760px) {
  .page-app { padding-bottom: 92px; }
  .topbar { display: none; }
  .mhead { display: flex; align-items: center; gap: 10px; padding: 16px 20px 12px; position: sticky; top: 0; z-index: 50; background: var(--bg); }
  .mhead .brand-mark { width: 32px; height: 32px; }
  .mhead .brand-word { font-size: 20px; }
  .mhead .mtitle { font: 700 18px/1 var(--f-brand); }
  .mhead .mtools { margin-left: auto; display: flex; gap: 8px; align-items: center; }
  .mhead .avatar { width: 32px; height: 32px; }
  .main { display: none !important; }
  .mview.on { display: block; padding: 0 20px 16px; }
  .tabbar { display: grid; grid-template-columns: repeat(4, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; height: calc(76px + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
    background: var(--bar); border-top: 1px solid var(--line); }
  .tabbar button { background: none; border: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; font: 400 11px/1 var(--f-ui); color: var(--outl); }
  .tabbar button .ic { width: 20px; height: 20px; }
  .tabbar button span.pillbg { display: grid; place-items: center; width: 60px; height: 30px; border-radius: 15px; }
  .tabbar button:hover { color: var(--var); }
  .tabbar button:active span.pillbg { background: color-mix(in srgb, var(--pri) 10%, transparent); }
  .tabbar button.on { color: var(--pri); font-weight: 500; }
  .tabbar button.on span.pillbg { background: color-mix(in srgb, var(--pri) 14%, transparent); }
  .mcard { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 18px; margin-top: 14px; }
  .mcard .top { display: flex; justify-content: space-between; }
  .mcard h2 { font: 500 20px/1.2 var(--f-ui); margin: 14px 0 6px; }
  .mcard .sub { font-size: 12.5px; color: var(--var); }
  .segbar { display: grid; grid-template-columns: repeat(8, 1fr); gap: 5px; margin: 16px 0 18px; }
  .segbar i { height: 6px; border-radius: 3px; background: var(--line2); }
  .segbar i.d { background: var(--sec); } .segbar i.a { background: var(--pri); } .segbar i.w { background: var(--ter); } .segbar i.n { background: transparent; border: 1px dashed var(--line2); }
  .msum { display: flex; gap: 22px; font: 500 12.5px/1 var(--f-ui); }
  .msum span { display: flex; align-items: center; gap: 7px; color: var(--c); }
  .mview .tiles4 { margin-top: 16px; gap: 8px 10px; }
  .mview .stile { border-radius: 10px; }
  .mview .cap.blk { margin: 22px 0 12px; }
  .mfull { height: 50px; width: 100%; border-radius: 9px; font-size: 14px; }
  .macts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 12px; }
  .macts .tile { height: 66px; font-size: 11.5px; gap: 6px; padding: 6px; }
  .macts .tile > .ic { width: 20px; height: 20px; }
  .macts .tile .run-tag { display: none; }
  .macts .tile .stop-x { width: 14px; height: 14px; right: 3px; top: 3px; }
  .macts .tile .stop-x .ic { width: 9px; height: 9px; }
  .mview .chipf button { height: 32px; border-radius: 16px; padding: 0 14px; font-size: 12.5px; }
  .mview .chipf { align-items: center; flex-wrap: wrap; }
  .mview .chipf .dd { height: 32px; border-radius: 16px; font: 400 12px/1 var(--f-ui); padding: 0 28px 0 12px; margin-left: auto; background-position: right 10px center; }
  .mview .papers { max-height: none; gap: 10px; }
  .mview .pcard { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 16px; }
  .mview .pcard .no { font-size: 15px; }
  .mview .pcard .cur { font-size: 13px; white-space: normal; }
  .mview .stg span { height: 20px; font-size: 9px; border-radius: 10px; }
  .mview .term { min-height: calc(100vh - 210px); }
  .mview .term-b { max-height: calc(100vh - 260px); padding: 12px; font-size: 10.5px; line-height: 15px; }
  .mview .term-b p { grid-template-columns: 42px 42px 1fr; margin-bottom: 14px; }
  .mview .flist { padding: 14px 0 0; }
  .mview .frow { background: var(--card); border: 1px solid var(--line); border-radius: 12px; min-height: 62px; padding: 0 12px; }
  .mview .frow .fn b { font-size: 11.5px; }
  .mview .tabs-m { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
  .mview .tabs-m button { flex: none; height: 32px; border-radius: 16px; border: 1px solid var(--line2); background: var(--tile); padding: 0 12px 0 14px; display: flex; align-items: center; gap: 10px; font: 500 12.5px/1 var(--f-ui); color: var(--var); }
  .mview .tabs-m button small { font: 400 10px/1 var(--f-mono); color: var(--outl); }
  .mview .tabs-m button.on { background: color-mix(in srgb, var(--pri) 16%, transparent); border-color: var(--pri); color: var(--pri); }
  .mzip { margin-top: 14px; width: 100%; height: 46px; }
  .overlay { inset: 0; padding: 16px; }
  .modal { padding: 20px; }
  .mh { margin: 0 0 16px; }
  .d8 .grid3, .dec, .grid2 { grid-template-columns: 1fr; }
  .rb { position: fixed; inset: 0; width: 100vw; height: 100vh; max-height: none; border-radius: 0; border: 0; }
  .rb-frame { margin: 0 16px; }
  .rb-h { padding: 14px 16px; flex-wrap: wrap; }
  .rb-h .rb-tools { display: none; }
  .rb-f { flex-wrap: wrap; padding: 14px 16px; gap: 10px; }
  .rb-f p { flex-basis: 100%; }
  .rb-f .btn { flex: 1; }
  .drawer { width: 100%; }
  .pv { width: 100%; height: calc(100vh - 32px); }
  .float-pill { bottom: calc(88px + env(safe-area-inset-bottom)); right: 16px; }
  .banner { flex-wrap: wrap; margin: 12px 0 0; }
  .toasts { top: 12px; right: 16px; }
}

/* M7: Paparan Langsung telefon (#/live) + kad di M2 */
@media (max-width: 1240px) {
  .lv-grid { grid-template-columns: minmax(0, 1fr) 240px; gap: 16px; }
}
@media (max-width: 1020px) {
  .lvp-main { grid-template-columns: 1fr; }
  .lvp-col .lv-stage { height: auto; aspect-ratio: 5 / 3; max-height: none; }
}
@media (max-width: 760px) {
  .lvp { min-height: 0; background: transparent; padding: 0 16px 16px; }
  .lvp-bar, .lvp-main { display: none; }
  .lvm { display: block; }
  .lvm-head { display: flex; align-items: center; gap: 12px; margin: 8px 0 12px; font-size: 12px; color: var(--var); }
  .lvm .lv-stage { border-radius: 4px; }
  .lvm .lv-cap { min-height: 34px; padding: 6px 10px; font-size: 11.5px; }
  .lvm .lv-cap-tm { display: none; }
  .lvm .lv-ib { display: none; }
  .lvm-hint { margin: 14px 0 10px; font-size: 11.5px; color: var(--outl); }
  .lv-now.m { gap: 6px; }
  .lv-now.m li { background: var(--card); border: 1px solid var(--line); border-radius: 10px; min-height: 38px; padding: 0 12px 0 14px; grid-template-columns: 10px minmax(0, 1fr) auto; gap: 10px; font-size: 12.5px; }
  .lv-now.m li .dot { width: 9px; height: 9px; background: var(--c); }
  .lv-now.m li.nx { color: var(--on); }
  .lv-now.m .lv-empty { background: none; border: 0; }
  .lvm-take { width: 100%; height: 44px; margin-top: 18px; }
  .mlive { display: flex; align-items: center; gap: 12px; width: 100%; margin-top: 12px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line);
    background: var(--card); color: var(--on); text-align: left; }
  .mlive > .ic:first-child { color: var(--pri); width: 20px; height: 20px; }
  .mlive span { flex: 1; min-width: 0; }
  .mlive b { display: block; font: 500 13.5px/1.2 var(--f-ui); }
  .mlive small { display: block; margin-top: 3px; font-size: 11.5px; color: var(--outl); }
  .mlive > .ic:last-child { color: var(--outl); width: 16px; height: 16px; }
}
