:root {
  --bg: #f3f0e8; --cd: #fffdf8; --tx: #2a2110; --mu: #7a6c4f; --bd: #e6dcc2;
  --nv: #3a2a05; --rd: #e4002b; --bl: #b8860b; --gr: #0e9f6e; --am: #d98a00;
  --hv: #faf5e6; --gl: rgba(255,253,246,.78); --ln: #cdb987; --hl: rgba(255,255,255,.85);
  --sb: linear-gradient(180deg,#f8eab0 0%,#e3be58 40%,#c8972a 100%);
  --sbt: #43310a; --sbo: #2b1d02; --sh: rgba(255,255,255,.55);
  --hub: #b0001f; --erc: #b0001f;
  --tri: linear-gradient(90deg,#e4002b 0 34%,#1f6fe0 34% 67%,#12a37a 67%);
  font-size: 15px;
}
:root[data-theme="dark"] {
  --bg: #14110a; --cd: #1f1a10; --tx: #f3ead2; --mu: #b3a37c; --bd: #352c18;
  --hv: #2a2314; --bl: #e3b93c; --gr: #2fc18d; --am: #f0a82a;
  --gl: rgba(34,28,16,.78); --ln: #5f4e24; --hl: rgba(255,255,255,.08);
  --sb: linear-gradient(180deg,#53421a 0%,#2c2209 45%,#1a1405 100%);
  --sbt: #ead9a4; --sbo: #fff3cc; --sh: rgba(255,255,255,.14);
  --hub: #ff7b8f; --erc: #ff9aab;
}
* { box-sizing: border-box; }
body {
  margin: 0; color: var(--tx);
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  line-height: 1.5; min-height: 100vh;
  background:
    radial-gradient(700px 420px at 92% -6%, rgba(228,0,43,.14), transparent 60%),
    radial-gradient(800px 520px at -6% 108%, rgba(31,111,224,.16), transparent 60%),
    radial-gradient(900px 420px at 50% -12%, rgba(236,196,84,.38), transparent 65%),
    var(--bg);
}
button, select, input { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--bl); outline-offset: 2px; }

.pr {
  background: linear-gradient(180deg,#fdeea8 0%,#e9c250 48%,#d3a02a 52%,#edcb60 100%);
  color: #3a2a05; border: 1px solid #a5790f; border-radius: 99px;
  padding: 9px 18px; font-weight: 700;
  text-shadow: 0 1px 0 rgba(255,255,255,.55);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.9), 0 1px 3px rgba(90,65,10,.35);
}
.pr:hover { filter: brightness(1.06); }
.pr:active { filter: brightness(.94); }

/* Wrapper Login & Portal LP */
.fh-page { min-height: 100vh; display: flex; flex-direction: column; position: relative; }
.fh-page:before {
  content: ""; position: fixed; inset: 0; pointer-events: none;
  background-image: radial-gradient(var(--ln) 1px, transparent 1.3px);
  background-size: 26px 26px; opacity: .4;
  -webkit-mask-image: radial-gradient(75% 65% at 50% 52%, #000, transparent);
  mask-image: radial-gradient(75% 65% at 50% 52%, #000, transparent);
}
.fh-page > * { position: relative; }

/* Menu bar ala macOS */
.fh-lgm {
  position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 12px;
  height: 38px; padding: 0 16px; background: var(--gl);
  backdrop-filter: blur(22px) saturate(1.7); -webkit-backdrop-filter: blur(22px) saturate(1.7);
  border-bottom: 1px solid var(--hl); font-size: .78rem; font-weight: 600;
}
.fh-lgm .fh-nm { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; }
.fh-lgm .fh-nm svg { width: 17px; height: 13px; flex: none; }
.fh-lgm .fh-nm b { font-weight: 800; }
.fh-lgm .fh-nm span { color: var(--mu); font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fh-lgm .fh-ck { color: var(--mu); font-variant-numeric: tabular-nums; white-space: nowrap; }
.fh-lgm .fh-tt {
  width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--bd);
  background: linear-gradient(180deg, var(--cd), var(--hv));
  display: grid; place-items: center; font-size: .85rem; padding: 0;
}

.fh-lgs { flex: 1; display: grid; place-items: center; padding: 26px 18px 10px; }
.fh-lgw, .fh-lpw {
  width: min(1000px, 100%); border-radius: 28px; overflow: hidden;
  background: color-mix(in srgb, var(--cd) 82%, transparent);
  backdrop-filter: blur(26px) saturate(1.6); -webkit-backdrop-filter: blur(26px) saturate(1.6);
  border: 1px solid var(--hl);
  box-shadow: 0 40px 90px rgba(60,45,10,.28), 0 8px 24px rgba(60,45,10,.12), inset 0 1px 0 var(--hl);
  animation: lgin .6s cubic-bezier(.2,.8,.2,1) both;
}
@keyframes lgin { from { opacity: 0; transform: translateY(18px) scale(.985); } }
.fh-lgw.fh-shk { animation: lgsk .46s cubic-bezier(.36,.07,.19,.97); }
@keyframes lgsk {
  10%, 90% { transform: translateX(-3px); } 20%, 80% { transform: translateX(6px); }
  30%, 50%, 70% { transform: translateX(-10px); } 40%, 60% { transform: translateX(10px); }
}
.fh-tbr {
  position: relative; height: 42px; display: flex; align-items: center; padding: 0 16px;
  border-bottom: 1px solid var(--bd); background: linear-gradient(180deg, var(--hl), transparent);
}
.fh-lgd { display: flex; gap: 8px; }
.fh-lgd i { width: 12px; height: 12px; border-radius: 50%; box-shadow: 0 0 0 .5px rgba(0,0,0,.3); }
.fh-tbr b { position: absolute; left: 0; right: 0; text-align: center; font-size: .8rem; font-weight: 700; color: var(--mu); pointer-events: none; }
.fh-lgb2 { display: grid; grid-template-columns: 1fr 1.04fr; min-height: 572px; }

/* Brand badge (SVG + teks tajam tanpa bloat base64) */
.fh-bpl {
  align-self: flex-start; display: inline-flex; align-items: center; gap: 10px;
  background: #fff; color: #1b1b1b; border-radius: 16px; padding: 9px 15px;
  box-shadow: inset 0 1px 0 #fff, 0 3px 12px rgba(60,40,0,.25);
}
.fh-bpl svg { width: 32px; height: 24px; flex: none; }
.fh-bpl div { line-height: 1.1; }
.fh-bpl strong { display: block; font-size: .86rem; font-weight: 800; letter-spacing: .02em; color: #0a1f44; }
.fh-bpl span { font-size: .68rem; font-weight: 700; color: #e4002b; letter-spacing: .06em; }

/* Panel kiri brand */
.fh-bp {
  position: relative; background: var(--sb); color: var(--sbt);
  padding: 30px 30px 0; display: flex; flex-direction: column; overflow: hidden; isolation: isolate;
}
.fh-bp:before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 65%; background: linear-gradient(180deg, var(--sh), transparent); z-index: -1; }
.fh-bp h1 { margin: 24px 0 6px; font-size: 2.8rem; line-height: 1; font-weight: 800; letter-spacing: -.04em; color: var(--sbo); }
.fh-bp h1 span { color: var(--hub); }
.fh-bp .fh-sb2 { font-size: .78rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; opacity: .8; margin: 0; }
.fh-bp .fh-tg2 { margin: 16px 0 0; max-width: 330px; font-size: .92rem; line-height: 1.55; color: var(--sbo); opacity: .82; }
.fh-chp {
  margin-top: 18px; align-self: flex-start; display: flex; align-items: center; gap: 10px;
  padding: 8px 14px; border-radius: 99px; background: rgba(255,255,255,.45);
  border: 1px solid rgba(255,255,255,.6); font-size: .74rem; font-weight: 700; color: var(--sbo);
}
:root[data-theme="dark"] .fh-chp { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.18); }
.fh-chp .fh-cb { width: 74px; height: 6px; border-radius: 6px; background: rgba(0,0,0,.18); overflow: hidden; }
.fh-chp .fh-cb i { display: block; height: 100%; width: 100%; transform-origin: left; transform: scaleX(var(--fill, .1)); transition: transform .6s cubic-bezier(.3,1.3,.5,1); background: var(--tri); }
.fh-chp b { font-variant-numeric: tabular-nums; min-width: 2.6em; text-align: right; }

/* Animasi Skid Tank */
.fh-sn { margin: auto 0 0; padding-top: 26px; }
.fh-bp .fh-rd, .fh-bp .fh-tri { margin: 0 -30px; }
.fh-tkh { display: block; width: 100%; max-width: 430px; height: auto; margin: 0 auto; overflow: visible; transition: transform 1.2s cubic-bezier(.55,0,.75,.35); }
.fh-dep .fh-tkh { transform: translateX(135%); }
.fh-tkh .fh-lq { transform-box: fill-box; transform-origin: 50% 100%; transform: scaleY(var(--fill, .1)); transition: transform .6s cubic-bezier(.3,1.3,.5,1); }
.fh-wr { transform-box: fill-box; transform-origin: center; animation: lgsp .5s linear infinite; animation-play-state: paused; }
.fh-rev .fh-wr, .fh-go .fh-wr, .fh-ld .fh-wr { animation-play-state: running; }
@keyframes lgsp { to { transform: rotate(360deg); } }
.fh-bob { animation: lgbob .3s ease-in-out infinite alternate; animation-play-state: paused; }
.fh-rev .fh-bob, .fh-go .fh-bob { animation-play-state: running; }
@keyframes lgbob { to { transform: translateY(-1px); } }
.fh-bc { animation: lgbc 1.2s steps(2, jump-none) infinite; animation-play-state: paused; }
.fh-rev .fh-bc, .fh-go .fh-bc, .fh-lpw .fh-bc { animation-play-state: running; }
@keyframes lgbc { 0% { opacity: 1; } 100% { opacity: .25; } }
.fh-rd { height: 16px; background: #2b2f36; position: relative; overflow: hidden; }
.fh-rd:before {
  content: ""; position: absolute; left: 0; top: 7px; height: 2px; width: calc(100% + 60px);
  background: repeating-linear-gradient(90deg, #f5f1e6 0 22px, transparent 22px 44px);
  animation: lgrd .45s linear infinite; animation-play-state: paused;
}
.fh-rev .fh-rd:before, .fh-go .fh-rd:before { animation-play-state: running; }
@keyframes lgrd { to { transform: translateX(-44px); } }
.fh-tri { height: 5px; background: var(--tri); }

/* Panel kanan form */
.fh-fp { padding: 34px 42px 24px; display: flex; flex-direction: column; justify-content: center; gap: 17px; min-width: 0; }
.fh-eb { font-size: .68rem; font-weight: 800; letter-spacing: .2em; color: var(--bl); }
.fh-fp h2 { margin: 4px 0 5px; font-size: 1.8rem; line-height: 1.1; font-weight: 800; letter-spacing: -.03em; }
.fh-fp .fh-sb3 { margin: 0; color: var(--mu); font-size: .88rem; min-height: 1.4em; }
.fh-dock { display: flex; gap: 12px; }
.fh-dk {
  position: relative; flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 12px 8px 15px; border-radius: 20px; cursor: pointer; border: 1px solid transparent; text-align: center;
  transition: background .2s, border-color .2s, box-shadow .2s;
}
.fh-dk input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.fh-dk .fh-sq {
  position: relative; width: 58px; height: 58px; border-radius: 17px; display: grid; place-items: center;
  color: #fff; background: var(--g); box-shadow: inset 0 1px 0 rgba(255,255,255,.55), 0 7px 16px var(--s);
  transition: transform .28s cubic-bezier(.3,1.6,.5,1), filter .2s;
}
.fh-dk .fh-sq svg { width: 27px; height: 27px; }
.fh-dk b { font-size: .86rem; font-weight: 800; }
.fh-dk small { font-size: .7rem; color: var(--mu); margin-top: -4px; }
.fh-dk:not(.fh-on) .fh-sq { filter: saturate(.65) opacity(.9); }
.fh-dk.fh-on { background: color-mix(in srgb, var(--cd) 72%, transparent); border-color: var(--bd); box-shadow: 0 8px 20px rgba(60,45,10,.1); }
.fh-dk.fh-on .fh-sq { transform: translateY(-4px) scale(1.09); }
.fh-dk.fh-on:after { content: ""; position: absolute; bottom: 5px; width: 5px; height: 5px; border-radius: 50%; background: var(--bl); }

.fh-fld {
  position: relative; height: 56px; border-radius: 17px;
  background: color-mix(in srgb, var(--cd) 78%, transparent); border: 1px solid var(--bd);
  transition: border-color .2s, box-shadow .25s, background .2s;
}
.fh-fld:focus-within { border-color: var(--bl); background: var(--cd); box-shadow: 0 0 0 4px rgba(233,194,80,.32); }
.fh-fld .fh-ic { position: absolute; left: 16px; top: 50%; margin-top: -11px; width: 22px; height: 22px; color: var(--mu); pointer-events: none; }
.fh-fld:focus-within .fh-ic { color: var(--bl); }
.fh-fld input {
  position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: transparent;
  outline: 0; padding: 20px 50px 0 50px; font-size: 1rem; font-weight: 600; border-radius: 17px;
}
.fh-fld label {
  position: absolute; left: 50px; top: 50%; transform: translateY(-50%);
  color: var(--mu); font-weight: 500; pointer-events: none; transition: .2s;
}
.fh-fld input:focus + label, .fh-fld input:not(:placeholder-shown) + label {
  top: 14px; transform: none; font-size: .66rem; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; color: var(--bl);
}
.fh-fld .fh-ln {
  position: absolute; left: 16px; right: 16px; bottom: -1px; height: 3px; border-radius: 3px;
  background: var(--tri); transform-origin: left; transform: scaleX(var(--k, 0)); transition: transform .3s;
}
.fh-fld .fh-ok {
  position: absolute; right: 14px; top: 50%; margin-top: -11px; width: 22px; height: 22px; border-radius: 50%;
  display: grid; place-items: center; background: var(--gr); color: #fff; transform: scale(0); transition: transform .3s;
}
.fh-fld.fh-has .fh-ok { transform: scale(1); }
.fh-fld .fh-eye {
  position: absolute; right: 9px; top: 50%; margin-top: -18px; width: 36px; height: 36px; border-radius: 50%;
  border: 0; background: transparent; color: var(--mu); display: grid; place-items: center; padding: 0;
}
.fh-eye .fh-x { display: none; }
.fh-eye[aria-pressed="true"] .fh-x { display: block; }
.fh-gg { display: flex; align-items: center; gap: 8px; height: 14px; margin: -9px 4px 0; font-size: .62rem; font-weight: 800; color: var(--mu); opacity: 0; transition: opacity .25s; }
.fh-gg.fh-on { opacity: 1; }
.fh-gg div { flex: 1; display: flex; gap: 4px; }
.fh-gg i { flex: 1; height: 6px; border-radius: 3px; background: var(--bd); transition: .2s; }
.fh-gg i.fh-on { transform: scaleY(1.35); }
.fh-gg i.fh-on:nth-child(-n+3) { background: #e4002b; }
.fh-gg i.fh-on:nth-child(n+4):nth-child(-n+7) { background: #e9a800; }
.fh-gg i.fh-on:nth-child(n+8) { background: #12a37a; }
.fh-cap { display: none; margin: -9px 4px 0; font-size: .74rem; font-weight: 700; color: var(--am); }
.fh-cap.fh-on { display: block; }
.fh-msg {
  display: none; gap: 10px; align-items: flex-start; padding: 11px 14px; border-radius: 14px;
  font-size: .84rem; font-weight: 600; background: color-mix(in srgb, #e4002b 11%, var(--cd));
  color: var(--erc); border: 1px solid rgba(228,0,43,.28);
}
.fh-msg.fh-on { display: flex; }
.fh-msg svg { width: 18px; height: 18px; flex: none; margin-top: 1px; }

/* Tombol login + animasi skidtank mini */
.fh-lgbtn { position: relative; height: 58px; width: 100%; font-size: 1rem; overflow: hidden; display: block; padding: 0; }
.fh-lgbtn .fh-lb2 { display: flex; align-items: center; justify-content: center; gap: 10px; height: 100%; font-weight: 800; transition: .25s; }
.fh-lgbtn .fh-lb2 svg { width: 20px; height: 20px; }
.fh-lgbtn .fh-rt { position: absolute; inset: 0; opacity: 0; pointer-events: none; transition: opacity .2s; }
.fh-lgbtn.fh-ld { cursor: progress; }
.fh-lgbtn.fh-ld .fh-lb2 { opacity: 0; transform: translateY(-10px); }
.fh-lgbtn.fh-ld .fh-rt { opacity: 1; }
.fh-rt .fh-cp2 { position: absolute; left: 0; right: 0; top: 8px; text-align: center; font-size: .7rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.fh-rt .fh-rdl { position: absolute; left: 0; right: 0; bottom: 9px; height: 2px; background: repeating-linear-gradient(90deg, rgba(58,42,5,.5) 0 8px, transparent 8px 16px); }
.fh-rt .fh-trl { position: absolute; left: 0; right: 0; bottom: 8px; height: 4px; background: var(--tri); transform-origin: left; transform: scaleX(var(--t, 0)); transition: transform var(--d, .8s) cubic-bezier(.45,0,.25,1); }
.fh-rt .fh-tkm { position: absolute; left: 0; bottom: 10px; width: 62px; height: 28px; overflow: visible; transform: translateX(var(--x, -80px)); transition: transform var(--d, .8s) cubic-bezier(.45,0,.25,1); }
.fh-lgbtn.fh-ok { background: linear-gradient(180deg,#a6ecc8 0%,#2fc58b 48%,#12a37a 52%,#46d8a2 100%); border-color: #0b7a56; color: #04321f; }
.fh-lgbtn.fh-bad { background: linear-gradient(180deg,#ff9aa8 0%,#f0364f 48%,#d0001f 52%,#f2566b 100%); border-color: #8f0016; color: #fff; text-shadow: none; }
.fh-sec { display: flex; align-items: center; justify-content: center; gap: 7px; font-size: .74rem; color: var(--mu); }
.fh-sec svg { width: 14px; height: 14px; }

/* Portal LP */
.fh-lpb { display: grid; grid-template-columns: 1.1fr .9fr; min-height: 520px; }
.fh-lpl { padding: 38px 42px 30px; display: flex; flex-direction: column; gap: 16px; justify-content: center; }
.fh-bdg { align-self: flex-start; display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 99px; font-size: .74rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; background: color-mix(in srgb, #e9a800 20%, var(--cd)); color: var(--am); border: 1px solid color-mix(in srgb, #e9a800 45%, transparent); }
.fh-bdg i { width: 8px; height: 8px; border-radius: 50%; background: #e9a800; animation: lgpl 1.6s ease-in-out infinite; }
@keyframes lgpl { 50% { opacity: .3; transform: scale(.7); } }
.fh-lpl h2 { margin: 0; font-size: 1.85rem; line-height: 1.18; font-weight: 800; }
.fh-lpl p { margin: 0; color: var(--mu); font-size: .92rem; line-height: 1.6; }
.fh-stp { display: grid; gap: 9px; }
.fh-stp div { display: flex; align-items: center; gap: 11px; font-size: .86rem; font-weight: 600; }
.fh-stp i { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; flex: none; font-style: normal; font-size: .7rem; font-weight: 800; background: var(--hv); border: 1px solid var(--bd); color: var(--mu); }
.fh-stp .fh-d i { background: var(--gr); border-color: transparent; color: #fff; }
.fh-stp .fh-r i { background: #e9a800; border-color: transparent; color: #3a2a05; }
.fh-stp span { font-weight: 500; color: var(--mu); margin-left: auto; font-size: .76rem; }
.fh-pbr { height: 7px; border-radius: 7px; background: var(--hv); overflow: hidden; border: 1px solid var(--bd); }
.fh-pbr i { display: block; width: 38%; height: 100%; border-radius: 7px; background: var(--tri); animation: lgind 1.8s ease-in-out infinite; }
@keyframes lgind { 0% { transform: translateX(-105%); } 100% { transform: translateX(265%); } }
.fh-ac2 { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-top: 4px; }
.fh-ac2 .pr { padding: 12px 26px; font-size: .95rem; }
.fh-lpr { position: relative; background: var(--sb); color: var(--sbo); overflow: hidden; display: flex; flex-direction: column; }
.fh-lpr .fh-sg { margin: 26px 26px 0; align-self: flex-end; padding: 7px 14px; border-radius: 99px; background: rgba(255,255,255,.5); font-size: .72rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.fh-lpr .fh-sn { margin: auto 0 0; position: relative; }
.fh-lpr .fh-tkh { width: 76%; margin: 0 0 0 4%; }
.fh-cone { position: absolute; bottom: -7px; width: 26px; height: 32px; }
.fh-cone.fh-a { right: 9%; } .fh-cone.fh-b { right: 20%; }

.fh-lgf { text-align: center; padding: 12px 16px 18px; font-size: .78rem; color: var(--mu); }
.fh-lgf .fd { margin-top: 4px; font-weight: 600; }
.fh-lgf .fd b { background: linear-gradient(180deg,#f2cf62,#b8860b); -webkit-background-clip: text; background-clip: text; color: transparent; font-family: Georgia, serif; font-style: italic; font-size: 1.05rem; }

@media (max-width: 900px) {
  .fh-lgb2, .fh-lpb { grid-template-columns: 1fr; min-height: 0; }
  .fh-bp { padding: 18px 18px 0; min-height: 170px; }
  .fh-bp .fh-tg2, .fh-bp .fh-chp, .fh-bp .fh-sb2 { display: none; }
  .fh-bp h1 { font-size: 1.9rem; margin: 12px 0 0; }
  .fh-fp, .fh-lpl { padding: 24px 20px; }
}

/* ================= Layout Aplikasi Utama & Master Data ================= */
.app { display: grid; grid-template-columns: 268px minmax(0, 1fr); min-height: 100vh; padding: 12px; gap: 16px; }
.side {
  position: sticky; top: 12px; height: calc(100vh - 24px); border-radius: 26px;
  background: var(--sb); color: var(--sbt); padding: 16px 14px;
  display: flex; flex-direction: column; gap: 4px; overflow-y: auto;
  box-shadow: inset -1px 0 0 var(--sh), 4px 0 24px rgba(90,65,10,.2);
}
.side-brand { background: #fff; border-radius: 16px; padding: 10px 14px; display: flex; align-items: center; gap: 10px; box-shadow: 0 3px 12px rgba(60,40,0,.22); color: #1b1b1b; }
.side-brand svg { width: 28px; height: 22px; flex: none; }
.side-brand strong { display: block; font-size: .84rem; font-weight: 800; color: #0a1f44; line-height: 1.1; }
.side-brand span { font-size: .66rem; font-weight: 700; color: #e4002b; letter-spacing: .06em; }
.side-title { margin: 12px 4px 6px; }
.side-title b { display: block; font-size: 1.45rem; font-weight: 800; color: var(--sbo); line-height: 1.1; }
.side-title small { font-size: .72rem; opacity: .8; font-weight: 600; }
.ng { font-size: .66rem; font-weight: 800; letter-spacing: .14em; opacity: .65; padding: 12px 10px 4px; text-transform: uppercase; }
.nv {
  display: flex; align-items: center; gap: 11px; padding: 9px 10px; border-radius: 15px;
  text-decoration: none; color: var(--sbt); font-weight: 600; font-size: .88rem;
  transition: background .15s; position: relative;
}
.nv:hover { background: var(--sh); }
.nv.on { background: rgba(255,255,255,.62); color: #2b1d02; font-weight: 800; box-shadow: 0 4px 14px rgba(60,40,0,.25); }
.nv.on:before { content: ""; position: absolute; left: -14px; top: 8px; bottom: 8px; width: 5px; border-radius: 0 5px 5px 0; background: #e4002b; }
.nc { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: rgba(255,255,255,.65); color: var(--ac, #b8860b); flex: none; }
.nv.on .nc { background: var(--ac, #b8860b); color: #fff; }
.sf2 { margin-top: auto; padding-top: 12px; display: grid; gap: 8px; }
.sf2 button { width: 100%; border: 1px solid rgba(255,255,255,.55); background: rgba(255,255,255,.4); color: var(--sbo); border-radius: 99px; padding: 9px 12px; font-weight: 700; font-size: .82rem; }
.sf2 button:hover { background: rgba(255,255,255,.65); }

main { min-width: 0; padding-bottom: 32px; }
.top {
  position: sticky; top: 12px; z-index: 15; margin-bottom: 18px; padding: 12px 18px; border-radius: 20px;
  background: var(--gl); backdrop-filter: blur(22px) saturate(1.7); -webkit-backdrop-filter: blur(22px) saturate(1.7);
  border: 1px solid var(--hl); box-shadow: 0 8px 28px rgba(60,45,10,.12);
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.top:after { content: ""; position: absolute; left: 20px; right: 20px; bottom: -1px; height: 3px; border-radius: 3px; background: var(--tri); }
.top h1 { margin: 0; font-size: 1.18rem; font-weight: 800; }
.top-meta { display: flex; align-items: center; gap: 10px; font-size: .82rem; color: var(--mu); font-weight: 600; }
.bgr { display: none; border: 1px solid #a5790f; background: linear-gradient(180deg,#fdeea8,#e9c250); color: #3a2a05; border-radius: 12px; width: 38px; height: 38px; font-size: 1.1rem; font-weight: 800; }
.sc { display: none; position: fixed; inset: 0; background: rgba(20,12,0,.55); z-index: 50; }
.sc.on { display: block; }

/* Kartu & Filter */
.cd {
  background: color-mix(in srgb, var(--cd) 86%, transparent);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--bd); border-radius: 22px; padding: 18px;
  box-shadow: inset 0 1px 0 var(--hl), 0 10px 28px rgba(60,45,10,.07);
  margin-bottom: 16px;
}
.flt-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.flt-item label { display: block; font-size: .72rem; font-weight: 700; color: var(--mu); margin-bottom: 4px; text-transform: uppercase; letter-spacing: .04em; }
.flt-item input, .flt-item select {
  width: 100%; padding: 8px 11px; border-radius: 11px; border: 1px solid var(--bd);
  background: var(--cd); color: var(--tx); font-size: .86rem;
}
.flt-act { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 12px; }
.btn-sec {
  padding: 9px 16px; border-radius: 99px; border: 1px solid var(--bd);
  background: var(--cd); color: var(--tx); font-weight: 700; font-size: .86rem; text-decoration: none;
}
.btn-sec:hover { background: var(--hv); }

/* Tabel Master Data & Pewarnaan Status (Hijau / Kuning / Merah) */
.tbl-wrap { overflow-x: auto; border-radius: 16px; border: 1px solid var(--bd); }
.tbl { width: 100%; border-collapse: collapse; font-size: .84rem; min-width: 980px; }
.tbl th {
  text-align: left; padding: 11px 12px; font-size: .72rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: .04em; color: var(--mu);
  background: var(--hv); border-bottom: 1px solid var(--bd); white-space: nowrap;
}
.tbl td { padding: 11px 12px; border-bottom: 1px solid var(--bd); vertical-align: middle; }

/* Traffic-light row coloring (aman untuk Light & Dark mode) */
.tbl tr.row-green td { background: rgba(14, 159, 110, 0.13); }
.tbl tr.row-yellow td { background: rgba(233, 168, 0, 0.18); }
.tbl tr.row-red td { background: rgba(228, 0, 43, 0.13); }
.tbl tr.row-green td:first-child { box-shadow: inset 4px 0 0 #0e9f6e; }
.tbl tr.row-yellow td:first-child { box-shadow: inset 4px 0 0 #d98a00; }
.tbl tr.row-red td:first-child { box-shadow: inset 4px 0 0 #e4002b; }

.bdg { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 99px; font-size: .74rem; font-weight: 800; white-space: nowrap; }
.bdg-green { background: #0e9f6e; color: #fff; }
.bdg-yellow { background: #e9a800; color: #2b1d02; }
.bdg-red { background: #e4002b; color: #fff; }

.alert-ok { padding: 12px 16px; border-radius: 14px; background: rgba(14,159,110,.15); border: 1px solid rgba(14,159,110,.4); color: var(--gr); font-weight: 700; font-size: .88rem; margin-bottom: 14px; }
.alert-err { padding: 12px 16px; border-radius: 14px; background: rgba(228,0,43,.12); border: 1px solid rgba(228,0,43,.35); color: var(--erc); font-weight: 600; font-size: .86rem; margin-bottom: 14px; }

/* Modal */
.mo { position: fixed; inset: 0; background: rgba(20,12,0,.55); backdrop-filter: blur(4px); display: none; align-items: center; justify-content: center; z-index: 80; padding: 16px; }
.mo.on { display: flex; }
.mb { background: var(--cd); width: min(640px, 100%); max-height: 90vh; overflow-y: auto; border-radius: 20px; border: 1px solid var(--bd); box-shadow: 0 24px 60px rgba(20,12,0,.45); }
.mh { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; background: var(--sb); color: var(--sbo); font-weight: 800; }
.mh button { border: 0; background: rgba(255,255,255,.55); width: 30px; height: 30px; border-radius: 50%; font-weight: 800; }
.mc { padding: 18px; display: grid; gap: 12px; }
.mc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.mc label { display: block; font-size: .76rem; font-weight: 700; color: var(--mu); margin-bottom: 4px; }
.mc input, .mc select, .mc textarea { width: 100%; padding: 9px 11px; border-radius: 11px; border: 1px solid var(--bd); background: var(--cd); color: var(--tx); }

.pg-wrap { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: 14px; font-size: .82rem; color: var(--mu); }
.pg-links { display: flex; gap: 6px; }
.pg-links a, .pg-links span { padding: 6px 12px; border-radius: 99px; border: 1px solid var(--bd); text-decoration: none; color: var(--tx); font-weight: 700; }
.pg-links span.active { background: var(--bl); color: #fff; border-color: var(--bl); }

@media (max-width: 900px) {
  .app { grid-template-columns: 1fr; padding: 8px; }
  .bgr { display: grid; place-items: center; }
  .side { position: fixed; left: 0; top: 0; bottom: 0; width: 280px; height: auto; border-radius: 0 26px 26px 0; transform: translateX(-105%); transition: transform .25s; z-index: 60; }
  .side.open { transform: none; }
  .mc-grid { grid-template-columns: 1fr; }
}