/* App Proyek PT Arindra Jaya - tampilan premium (web & HP) */
:root {
  --navy: #00183E; --navy2: #002A5E; --biru: #004A8B; --biru2: #1C6BB8; --langit: #7CC4FF; --langit2: #E1EDFA;
  --oranye: #B54708; --oranye2: #FEF0C7; --hijau: #1E7A46; --hijau2: #D1FADF; --merah: #B42318; --merah2: #FEE4E2;
  --kuning: #F79009; --teks: #14202B; --teks2: #3B4651; --redup: #56636F; --garis: #E4E8EF; --garis2: #EEF1F5;
  --latar: #F3F5F9; --kartu: #FFFFFF; --aksen: var(--biru); --aksen-tua: var(--navy);
  --bayang: 0 1px 2px rgba(0,24,62,.05), 0 8px 20px rgba(0,24,62,.06);
  --bayang2: 0 2px 4px rgba(0,24,62,.06), 0 16px 32px rgba(0,24,62,.12);
  --r: 16px; --font: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, Consolas, monospace;
  --nav-h: 64px; --gerak: cubic-bezier(.2,.7,.2,1);
}
.peran-inspektor { --aksen: #B54708; --aksen-tua: #7A2E0E; }
.peran-klien { --aksen: #004A8B; --aksen-tua: #00183E; }
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { font-family: var(--font); color: var(--teks); background: var(--latar); -webkit-font-smoothing: antialiased; font-size: 15px; line-height: 1.45; }
a { color: var(--aksen); }
button, input, select, textarea { font: inherit; color: inherit; }
img { max-width: 100%; }
.mono { font-family: var(--mono); font-size: .92em; }
.redup { color: var(--redup); }
.kecil { font-size: 12.5px; }
.tebal { font-weight: 700; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.sembunyi { display: none !important; }
:focus-visible { outline: 3px solid var(--langit); outline-offset: 2px; border-radius: 6px; }

/* ---------- Splash / welcome ---------- */
#splash { position: fixed; inset: 0; z-index: 1000; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 22px;
  background: radial-gradient(120% 90% at 50% 40%, #0B3A78 0%, #00183E 55%, #000C22 100%); color: #fff; overflow: hidden; cursor: pointer; }
#splash::before { content: ''; position: absolute; inset: -40%; background: conic-gradient(from 0deg, transparent 0 70%, rgba(124,196,255,.18) 80%, transparent 90%);
  animation: aj-putar 3.2s linear infinite; }
#splash .grid { position: absolute; inset: 0; background-image: linear-gradient(rgba(124,196,255,.07) 1px, transparent 1px), linear-gradient(90deg, rgba(124,196,255,.07) 1px, transparent 1px);
  background-size: 44px 44px; mask-image: radial-gradient(60% 50% at 50% 50%, #000 30%, transparent 75%); animation: aj-pudar-masuk 1.2s ease both; }
#splash .ikon-wrap { position: relative; width: 132px; height: 88px; animation: aj-logo-masuk 1.1s var(--gerak) both; }
#splash .ikon-wrap img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 10px 30px rgba(124,196,255,.45)) brightness(1.35) saturate(1.1); }
#splash .ikon-wrap::after { content: ''; position: absolute; inset: 0; background: linear-gradient(105deg, transparent 35%, rgba(255,255,255,.85) 50%, transparent 65%);
  -webkit-mask: url(../aset/ikon.png) center/contain no-repeat; mask: url(../aset/ikon.png) center/contain no-repeat; background-size: 250% 100%;
  animation: aj-kilau 1.4s ease .9s both; }
#splash .cincin { position: absolute; width: 220px; height: 220px; border-radius: 50%; border: 1.5px solid rgba(124,196,255,.35); animation: aj-cincin 2.2s ease-out .2s infinite; }
#splash .kata { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; }
#splash .kata img { width: min(250px, 64vw); animation: aj-naik .9s var(--gerak) .75s both; }
#splash .garis-muat { position: relative; width: 160px; height: 3px; border-radius: 3px; background: rgba(255,255,255,.15); overflow: hidden; animation: aj-pudar-masuk .4s ease 1s both; }
#splash .garis-muat i { position: absolute; inset: 0; background: linear-gradient(90deg, var(--langit), #fff); transform-origin: left; animation: aj-tumbuh 1.6s var(--gerak) 1s both; }
#splash .salam { position: relative; font-size: 13px; letter-spacing: .18em; text-transform: uppercase; color: #B9D8F5; animation: aj-naik .8s var(--gerak) 1.1s both; }
#splash.keluar { animation: aj-splash-keluar .7s var(--gerak) forwards; }
@keyframes aj-putar { to { transform: rotate(360deg); } }
@keyframes aj-logo-masuk { 0% { opacity: 0; transform: scale(.6) translateY(16px); filter: blur(10px); } 60% { opacity: 1; filter: blur(0); } 100% { opacity: 1; transform: none; } }
@keyframes aj-kilau { from { background-position: 150% 0; } to { background-position: -60% 0; } }
@keyframes aj-cincin { 0% { transform: scale(.5); opacity: .9; } 100% { transform: scale(1.6); opacity: 0; } }
@keyframes aj-splash-keluar { to { opacity: 0; transform: scale(1.06); visibility: hidden; } }

/* ---------- Gerak umum ---------- */
@keyframes aj-naik { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes aj-pudar-masuk { from { opacity: 0; } to { opacity: 1; } }
@keyframes aj-tumbuh { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes aj-cincin-isi { from { stroke-dasharray: 0 999; } }
@keyframes aj-denyut { 0% { box-shadow: 0 0 0 0 rgba(0,74,139,.45); } 70% { box-shadow: 0 0 0 10px rgba(0,74,139,0); } 100% { box-shadow: 0 0 0 0 rgba(0,74,139,0); } }
@keyframes aj-latar { 0%,100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
@keyframes aj-kedip { 0%,100% { opacity: 1; } 50% { opacity: .4; } }
@keyframes aj-gambar { from { stroke-dashoffset: 1200; } to { stroke-dashoffset: 0; } }
@keyframes aj-kerangka { 0% { background-position: -300px 0; } 100% { background-position: 300px 0; } }
.muncul { animation: aj-naik .6s var(--gerak) both; }
.muncul:nth-child(2) { animation-delay: .05s; } .muncul:nth-child(3) { animation-delay: .1s; } .muncul:nth-child(4) { animation-delay: .15s; }
.muncul:nth-child(5) { animation-delay: .2s; } .muncul:nth-child(6) { animation-delay: .25s; } .muncul:nth-child(n+7) { animation-delay: .3s; }
.kerangka { border-radius: 10px; min-height: 16px; background: linear-gradient(90deg, #E9EDF2 0, #F6F8FB 50%, #E9EDF2 100%); background-size: 600px 100%; animation: aj-kerangka 1.3s linear infinite; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition: none !important; } }

/* ---------- Kerangka app ---------- */
#app { min-height: 100%; }
.shell { display: flex; min-height: 100vh; }
.samping { width: 260px; flex: none; background: linear-gradient(180deg, var(--navy) 0%, var(--navy2) 100%); color: #fff; padding: 22px 14px; display: flex; flex-direction: column; gap: 4px;
  position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.peran-inspektor .samping { background: linear-gradient(180deg, #1A1208 0%, #3A1F07 100%); }
.samping .logo { width: 196px; margin: 0 8px 4px; }
.samping .label-peran { font-size: 11px; letter-spacing: .14em; font-weight: 700; color: var(--langit); margin: 0 10px 18px; }
.peran-inspektor .samping .label-peran { color: #FDB022; }
.samping a.menu { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 0 14px; border-radius: 10px; color: #B9C7DD; text-decoration: none; font-size: 14px; font-weight: 500;
  transition: background .2s, color .2s; position: relative; }
.samping a.menu:hover { background: rgba(255,255,255,.06); color: #fff; }
.samping a.menu.aktif { background: rgba(124,196,255,.16); color: #fff; }
.samping a.menu.aktif::before { content: ''; position: absolute; left: -14px; top: 10px; bottom: 10px; width: 4px; border-radius: 0 4px 4px 0; background: var(--langit); }
.samping .bawah { margin-top: auto; padding: 12px 8px 0; border-top: 1px solid rgba(255,255,255,.1); display: flex; flex-direction: column; gap: 8px; }
.badge-menu { margin-left: auto; min-width: 22px; height: 22px; border-radius: 11px; background: #F04438; color: #fff; font-size: 11px; font-weight: 800; display: inline-flex; align-items: center; justify-content: center; padding: 0 6px; }
.utama { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.atas { position: sticky; top: 0; z-index: 20; background: rgba(243,245,249,.86); backdrop-filter: blur(10px); border-bottom: 1px solid transparent; }
.atas-isi { max-width: 1280px; margin: 0 auto; padding: 14px clamp(16px, 3vw, 36px); display: flex; align-items: center; gap: 12px; }
.atas h1 { margin: 0; font-size: 22px; font-weight: 800; letter-spacing: -.01em; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.atas .logo-hp { display: none; height: 26px; }
.konten { width: 100%; max-width: 1280px; margin: 0 auto; padding: 8px clamp(16px, 3vw, 36px) 40px; display: flex; flex-direction: column; gap: 18px; }
.nav-bawah { display: none; }
.tombol-ikon { width: 44px; height: 44px; border-radius: 12px; border: 0; background: transparent; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; position: relative; color: var(--teks2); }
.tombol-ikon:hover { background: #E8ECF2; }
.tombol-ikon .titik { position: absolute; top: 8px; right: 8px; min-width: 18px; height: 18px; border-radius: 9px; background: #F04438; color: #fff; font-size: 10px; font-weight: 800; display: flex; align-items: center; justify-content: center; padding: 0 4px; border: 2px solid var(--latar); }
.avatar { width: 38px; height: 38px; border-radius: 50%; background: var(--langit2); color: var(--biru); font-weight: 800; display: inline-flex; align-items: center; justify-content: center; flex: none; }

@media (max-width: 900px) {
  .samping { display: none; }
  .atas { background: linear-gradient(135deg, var(--navy) 0%, var(--biru) 100%); color: #fff; }
  .peran-inspektor .atas { background: linear-gradient(135deg, #1A1208 0%, #5A2A06 100%); }
  .atas h1 { font-size: 18px; }
  .atas .logo-hp { display: block; }
  .atas .tombol-ikon { color: #fff; }
  .atas .tombol-ikon:hover { background: rgba(255,255,255,.12); }
  .atas .tombol-ikon .titik { border-color: var(--navy); }
  .konten { padding: 14px 16px calc(var(--nav-h) + 28px); }
  .nav-bawah { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: #fff; border-top: 1px solid #DDE2E7; padding: 6px 4px calc(8px + env(safe-area-inset-bottom));
    justify-content: space-around; box-shadow: 0 -6px 20px rgba(0,24,62,.06); }
  .nav-bawah a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 11px; color: var(--redup); text-decoration: none; min-height: 48px; justify-content: center; position: relative; }
  .nav-bawah a.aktif { color: var(--aksen); font-weight: 700; }
  .nav-bawah a.aktif svg { transform: translateY(-2px); transition: transform .2s; }
  .nav-bawah .badge-menu { position: absolute; top: 2px; left: calc(50% + 6px); height: 18px; min-width: 18px; font-size: 10px; }
}

/* ---------- Komponen ---------- */
.kartu { background: var(--kartu); border: 1px solid var(--garis); border-radius: var(--r); box-shadow: var(--bayang); padding: 18px; }
.kartu.klik { cursor: pointer; transition: transform .2s var(--gerak), box-shadow .2s; text-decoration: none; color: inherit; display: block; }
.kartu.klik:hover { transform: translateY(-3px); box-shadow: var(--bayang2); }
.kartu h2, .kartu h3 { margin: 0 0 10px; font-size: 16px; font-weight: 800; }
.judul-bagian { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.judul-bagian h2 { margin: 0; font-size: 16px; font-weight: 800; }
.kisi { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); }
.kisi-2 { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); }
.kisi-kpi { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 170px), 1fr)); }
.baris { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.kolom { display: flex; flex-direction: column; gap: 10px; }
.antara { justify-content: space-between; }
.isi { flex: 1; min-width: 0; }
.kpi { position: relative; overflow: hidden; }
.kpi .angka { font-size: 30px; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; }
.kpi .ket { font-size: 13px; color: var(--redup); margin-top: 4px; }
.kpi .ikon-kpi { position: absolute; right: 14px; top: 14px; width: 38px; height: 38px; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: var(--langit2); color: var(--biru); }
.kpi.peringatan .ikon-kpi { background: var(--oranye2); color: var(--oranye); }
.kpi.bahaya .ikon-kpi { background: var(--merah2); color: var(--merah); }
.kpi.baik .ikon-kpi { background: var(--hijau2); color: var(--hijau); }
.hero { border-radius: 22px; color: #fff; padding: clamp(18px, 3vw, 30px); background: linear-gradient(135deg, var(--navy) 0%, var(--biru) 55%, #0B5FAE 100%); background-size: 220% 220%;
  animation: aj-naik .7s var(--gerak) both, aj-latar 14s ease-in-out infinite; position: relative; overflow: hidden; }
.peran-inspektor .hero { background: linear-gradient(135deg, #1A1208 0%, #7A2E0E 60%, #B54708 100%); background-size: 220% 220%; }
.hero::after { content: ''; position: absolute; right: -60px; top: -60px; width: 260px; height: 260px; border-radius: 50%; border: 40px solid rgba(255,255,255,.05); }
.hero h2 { margin: 0; font-size: clamp(20px, 3vw, 28px); font-weight: 800; }
.hero .sub { color: #D6E6F7; font-size: 14px; }
.chip { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 700; padding: 3px 10px; border-radius: 999px; white-space: nowrap; background: #EEF1F5; color: var(--teks2); }
.chip.biru { background: var(--langit2); color: var(--biru); } .chip.hijau { background: var(--hijau2); color: #05603A; }
.chip.oranye { background: var(--oranye2); color: #7A2E0E; } .chip.merah { background: var(--merah2); color: #912018; }
.chip.navy { background: var(--navy); color: #fff; } .chip.ungu { background: #EBE9FE; color: #5925DC; }
.btn { min-height: 44px; padding: 0 18px; border-radius: 12px; border: 1px solid transparent; background: var(--aksen-tua); color: #fff; font-weight: 700; font-size: 14px; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; transition: transform .15s, box-shadow .2s, background .2s; white-space: nowrap; }
.btn:hover { box-shadow: 0 6px 16px rgba(0,24,62,.2); transform: translateY(-1px); }
.btn:active { transform: none; }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }
.btn.sekunder { background: #fff; color: var(--teks2); border-color: #C5CCD3; }
.btn.aksen { background: var(--aksen); }
.btn.hijau { background: var(--hijau); } .btn.merah { background: var(--merah); }
.btn.tipis { background: transparent; color: var(--aksen); border-color: transparent; padding: 0 10px; }
.btn.kecil { min-height: 36px; padding: 0 12px; font-size: 13px; border-radius: 10px; }
.btn.penuh { width: 100%; }
.btn .putar { width: 16px; height: 16px; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%; animation: aj-putar .8s linear infinite; }
.fab { position: fixed; right: 20px; bottom: calc(var(--nav-h) + 26px); z-index: 25; min-height: 56px; border-radius: 18px; padding: 0 20px; box-shadow: 0 8px 24px rgba(0,24,62,.3); background: var(--aksen); }
@media (min-width: 901px) { .fab { bottom: 28px; right: 32px; } }

/* form */
.medan { display: flex; flex-direction: column; gap: 6px; }
.medan > span { font-size: 13px; font-weight: 600; color: var(--teks2); }
.medan small { color: var(--redup); font-size: 12px; }
.input, select.input, textarea.input { width: 100%; min-height: 44px; border: 1px solid #C5CCD3; border-radius: 12px; padding: 10px 12px; background: #fff; font-size: 15px; transition: border-color .2s, box-shadow .2s; }
textarea.input { min-height: 90px; resize: vertical; }
.input:focus { outline: none; border-color: var(--aksen); box-shadow: 0 0 0 4px rgba(0,74,139,.12); }
.input.salah { border-color: var(--merah); }
.form-kisi { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); }
.cek { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; cursor: pointer; }
.cek input { width: 20px; height: 20px; accent-color: var(--aksen); flex: none; margin-top: 1px; }
.saklar { position: relative; width: 50px; height: 28px; flex: none; }
.saklar input { opacity: 0; width: 0; height: 0; position: absolute; }
.saklar i { position: absolute; inset: 0; border-radius: 14px; background: #C5CCD3; transition: background .2s; cursor: pointer; }
.saklar i::after { content: ''; position: absolute; left: 3px; top: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .25s var(--gerak); }
.saklar input:checked + i { background: var(--hijau); }
.saklar input:checked + i::after { transform: translateX(22px); }
.saklar input:focus-visible + i { outline: 3px solid var(--langit); outline-offset: 2px; }
.pilih-segmen { display: inline-flex; background: #E8ECF2; border-radius: 12px; padding: 4px; gap: 4px; flex-wrap: wrap; }
.pilih-segmen button { min-height: 36px; padding: 0 14px; border: 0; border-radius: 9px; background: transparent; font-weight: 600; font-size: 13px; cursor: pointer; color: var(--teks2); }
.pilih-segmen button.aktif { background: #fff; color: var(--teks); box-shadow: 0 1px 3px rgba(0,0,0,.1); }

/* tab */
.tab-bar { display: flex; gap: 4px; border-bottom: 1px solid var(--garis); overflow-x: auto; scrollbar-width: none; }
.tab-bar::-webkit-scrollbar { display: none; }
.tab-bar a, .tab-bar button { min-height: 44px; padding: 0 14px; border: 0; background: transparent; font-weight: 600; font-size: 14px; color: var(--redup); border-bottom: 3px solid transparent;
  text-decoration: none; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; cursor: pointer; transition: color .2s, border-color .2s; }
.tab-bar a.aktif, .tab-bar button.aktif { color: var(--teks); border-bottom-color: var(--aksen); }

/* tabel */
.tabel-wrap { overflow-x: auto; border-radius: 12px; }
table.tabel { width: 100%; border-collapse: collapse; font-size: 14px; }
.tabel th { font-size: 12px; color: var(--redup); font-weight: 600; text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--garis); white-space: nowrap; background: #FAFBFC; }
.tabel td { padding: 10px 12px; border-bottom: 1px solid var(--garis2); vertical-align: middle; }
.tabel tbody tr { transition: background .15s; }
.tabel tbody tr:hover { background: #F7FAFE; }
.tabel .kanan { text-align: right; }
.tabel input.sel { width: 100%; min-width: 60px; min-height: 36px; border: 1px solid transparent; border-radius: 8px; padding: 0 8px; background: transparent; font-size: 14px; }
.tabel input.sel:hover { border-color: #C5CCD3; background: #fff; }
.tabel input.sel:focus { outline: none; border-color: var(--aksen); background: #fff; }
.tabel input.sel.berubah { background: #FFF7E6; border-color: #F5B54A; }

/* daftar */
.daftar { display: flex; flex-direction: column; }
.daftar .item { display: flex; gap: 12px; align-items: center; padding: 12px 4px; border-bottom: 1px solid var(--garis2); text-decoration: none; color: inherit; }
.daftar .item:last-child { border-bottom: 0; }
.daftar a.item:hover { background: #F7FAFE; border-radius: 10px; }
.kosong { text-align: center; padding: 34px 16px; color: var(--redup); display: flex; flex-direction: column; align-items: center; gap: 10px; }
.kosong svg { color: #A8B3BF; }
.kosong strong { color: var(--teks2); font-size: 15px; }

/* progres */
.bar { height: 8px; background: #E3E7EB; border-radius: 4px; overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: 4px; background: var(--aksen); transform-origin: left; animation: aj-tumbuh 1.2s var(--gerak) .2s both; }
.bar.rencana { position: relative; }
.bar .tanda { position: absolute; top: -3px; bottom: -3px; width: 2px; background: var(--navy); border-radius: 1px; }
.cincin svg circle.isi { animation: aj-cincin-isi 1.6s var(--gerak) .3s both; }
.tahapan { display: flex; gap: 4px; }
.tahapan span { flex: 1; height: 6px; border-radius: 3px; background: #E3E7EB; transform-origin: left; animation: aj-tumbuh .4s var(--gerak) both; }
.tahapan span.selesai { background: var(--biru); } .tahapan span.jalan { background: var(--langit); animation: aj-tumbuh .4s var(--gerak) both, aj-kedip 1.6s ease-in-out .8s infinite; }
.tahapan span.tunggu { background: var(--kuning); animation: aj-tumbuh .4s both, aj-kedip 1.6s ease-in-out .8s infinite; } .tahapan span.revisi { background: #F04438; }
.linimasa { display: flex; flex-direction: column; gap: 0; }
.linimasa .ev { display: grid; grid-template-columns: 28px 1fr; gap: 10px; position: relative; padding-bottom: 16px; animation: aj-naik .5s var(--gerak) both; }
.linimasa .ev::before { content: ''; position: absolute; left: 13px; top: 26px; bottom: 0; width: 2px; background: var(--garis); }
.linimasa .ev:last-child::before { display: none; }
.linimasa .bulat { width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: #E3E7EB; color: #fff; font-size: 12px; font-weight: 800; }
.linimasa .ev.selesai .bulat { background: var(--hijau); } .linimasa .ev.jalan .bulat { background: var(--biru); animation: aj-denyut 1.8s infinite; }
.linimasa .ev.tunggu .bulat { background: var(--kuning); animation: aj-denyut 1.8s infinite; } .linimasa .ev.revisi .bulat { background: #F04438; }

/* foto */
.galeri { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(min(46%, 150px), 1fr)); }
.galeri .foto { position: relative; aspect-ratio: 4/3; border-radius: 12px; overflow: hidden; background: #E3E7EB; cursor: zoom-in; border: 0; padding: 0; }
.galeri .foto img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s var(--gerak); }
.galeri .foto:hover img { transform: scale(1.05); }
.galeri .foto span { position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 8px 6px; font-size: 11.5px; color: #fff; background: linear-gradient(transparent, rgba(0,0,0,.65)); text-align: left; }
.lightbox { position: fixed; inset: 0; z-index: 300; background: rgba(0,8,20,.92); display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 10px; padding: 20px; animation: aj-pudar-masuk .2s; }
.lightbox img { max-width: 100%; max-height: 82vh; border-radius: 10px; }
.lightbox p { color: #fff; margin: 0; font-size: 14px; text-align: center; }

/* modal & toast */
.latar-modal { position: fixed; inset: 0; z-index: 200; background: rgba(0,12,34,.5); backdrop-filter: blur(2px); display: flex; align-items: flex-end; justify-content: center; animation: aj-pudar-masuk .2s; }
.modal { background: #fff; width: 100%; max-width: 640px; max-height: 92vh; overflow-y: auto; border-radius: 22px 22px 0 0; padding: 20px; animation: aj-naik .35s var(--gerak); display: flex; flex-direction: column; gap: 14px; }
.modal.lebar { max-width: 980px; }
.modal h2 { margin: 0; font-size: 19px; font-weight: 800; }
.modal .aksi { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; padding-top: 6px; position: sticky; bottom: -20px; background: #fff; padding-bottom: 4px; }
@media (min-width: 700px) { .latar-modal { align-items: center; padding: 20px; } .modal { border-radius: 22px; } }
#toast { position: fixed; left: 50%; bottom: calc(var(--nav-h) + 30px); transform: translateX(-50%); z-index: 400; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: min(92vw, 460px); }
#toast div { background: #14202B; color: #fff; padding: 12px 16px; border-radius: 12px; font-size: 14px; box-shadow: var(--bayang2); animation: aj-naik .3s var(--gerak); pointer-events: auto; width: 100%; }
#toast div.salah { background: #912018; } #toast div.ok { background: #05603A; }
@media (min-width: 901px) { #toast { bottom: 30px; } }

/* tanda tangan */
.pad-ttd { position: relative; height: 190px; border-radius: 14px; border: 1.5px dashed #8FB3DC; background: #F8FBFF; touch-action: none; }
.pad-ttd canvas { width: 100%; height: 100%; display: block; border-radius: 14px; cursor: crosshair; }
.pad-ttd .garis-dasar { position: absolute; left: 18px; right: 18px; bottom: 34px; border-top: 1px solid #C5CCD3; pointer-events: none; }
.pad-ttd .petunjuk { position: absolute; left: 0; right: 0; top: 46%; text-align: center; color: #A8B3BF; font-size: 13px; pointer-events: none; }
.slot-ttd { display: grid; grid-template-columns: 34px 1fr auto; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--garis2); animation: aj-naik .5s var(--gerak) both; }
.slot-ttd:last-child { border-bottom: 0; }
.slot-ttd .tanda { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--hijau); color: #fff; }
.slot-ttd .tanda.tunggu { background: #fff; border: 3px solid #C5CCD3; }
.slot-ttd .tanda.giliran { background: #fff; border: 3px solid var(--aksen); animation: aj-denyut 1.8s ease-out infinite; }
.slot-ttd img.gbr { height: 44px; max-width: 120px; object-fit: contain; }

/* kurva S */
.grafik { width: 100%; height: auto; overflow: visible; }
.grafik .rencana { fill: none; stroke: #8FA3B8; stroke-width: 2; stroke-dasharray: 6 5; }
.grafik .aktual { fill: none; stroke: var(--biru); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1200; animation: aj-gambar 2s var(--gerak) .3s both; }
.grafik .area { fill: url(#gradAktual); opacity: .9; animation: aj-pudar-masuk 1.2s ease .8s both; }
.grafik .sumbu { stroke: #E3E7EB; stroke-width: 1; }
.grafik text { font-size: 11px; fill: var(--redup); font-family: var(--font); }
.grafik .hariini { stroke: var(--oranye); stroke-width: 1.5; stroke-dasharray: 3 3; }

/* auth */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }
.auth .sisi { position: relative; overflow: hidden; background: linear-gradient(135deg, var(--navy) 0%, #003A78 60%, var(--biru) 100%); background-size: 200% 200%; animation: aj-latar 16s ease-in-out infinite;
  color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; }
.auth .sisi::before { content: ''; position: absolute; inset: 0; background-image: linear-gradient(rgba(124,196,255,.08) 1px, transparent 1px), linear-gradient(90deg, rgba(124,196,255,.08) 1px, transparent 1px);
  background-size: 48px 48px; mask-image: linear-gradient(160deg, #000 10%, transparent 70%); }
.auth .sisi > * { position: relative; }
.auth .sisi h2 { font-size: clamp(26px, 3vw, 38px); font-weight: 800; line-height: 1.15; margin: 0 0 12px; max-width: 520px; }
.auth .sisi .poin { display: flex; flex-direction: column; gap: 12px; margin-top: 24px; }
.auth .sisi .poin div { display: flex; gap: 12px; align-items: center; color: #D6E6F7; font-size: 15px; animation: aj-naik .6s var(--gerak) both; }
.auth .sisi .poin div:nth-child(2) { animation-delay: .1s; } .auth .sisi .poin div:nth-child(3) { animation-delay: .2s; }
.auth .sisi .poin i { width: 36px; height: 36px; border-radius: 10px; background: rgba(124,196,255,.15); display: flex; align-items: center; justify-content: center; flex: none; color: var(--langit); }
.auth .form-sisi { display: flex; align-items: center; justify-content: center; padding: 32px 20px; }
.auth form { width: 100%; max-width: 400px; display: flex; flex-direction: column; gap: 14px; animation: aj-naik .6s var(--gerak) both; }
.auth form h1 { margin: 0; font-size: 26px; font-weight: 800; }
.btn-google { background: #fff; color: var(--teks); border: 1px solid #C5CCD3; }
.pemisah { display: flex; align-items: center; gap: 10px; color: var(--redup); font-size: 12px; }
.pemisah::before, .pemisah::after { content: ''; flex: 1; height: 1px; background: var(--garis); }
@media (max-width: 900px) {
  .auth { grid-template-columns: 1fr; }
  .auth .sisi { padding: 28px 22px 34px; min-height: auto; }
  .auth .sisi .poin, .auth .sisi .kaki { display: none; }
  .auth .sisi h2 { font-size: 22px; }
}

/* lain-lain */
.pita { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 12px; font-size: 13.5px; line-height: 1.5; }
.pita.info { background: var(--langit2); color: #12365C; } .pita.awas { background: #FFF7E6; color: #7A2E0E; border: 1px solid #F5D08A; }
.pita.bahaya { background: var(--merah2); color: #7A1A12; } .pita.ok { background: var(--hijau2); color: #05603A; }
.butir-cek { display: grid; grid-template-columns: 1fr; gap: 8px; padding: 14px 0; border-bottom: 1px solid var(--garis2); }
.butir-cek .pilih3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.butir-cek .pilih3 button { min-height: 44px; border-radius: 10px; border: 1.5px solid #C5CCD3; background: #fff; font-weight: 700; cursor: pointer; transition: all .15s; }
.butir-cek .pilih3 button.ok.aktif { background: var(--hijau); border-color: var(--hijau); color: #fff; }
.butir-cek .pilih3 button.tidak.aktif { background: var(--merah); border-color: var(--merah); color: #fff; }
.butir-cek .pilih3 button.na.aktif { background: #56636F; border-color: #56636F; color: #fff; }
.lonceng-daftar { position: absolute; right: 0; top: 52px; width: min(380px, 92vw); max-height: 70vh; overflow-y: auto; background: #fff; color: var(--teks); border-radius: 16px; box-shadow: var(--bayang2);
  border: 1px solid var(--garis); z-index: 50; animation: aj-naik .25s var(--gerak); }
.lonceng-daftar a { display: block; padding: 12px 16px; border-bottom: 1px solid var(--garis2); text-decoration: none; color: inherit; font-size: 13.5px; }
.lonceng-daftar a.baru { background: #F5F9FE; }
.lonceng-daftar a:hover { background: #EEF4FB; }
.offline-pita { position: fixed; top: 0; left: 0; right: 0; z-index: 500; background: #7A2E0E; color: #fff; text-align: center; font-size: 13px; padding: 6px; }
.komentar { display: flex; flex-direction: column; gap: 10px; }
.komentar .k { max-width: 86%; padding: 10px 12px; border-radius: 14px; background: #EEF1F5; font-size: 14px; animation: aj-naik .35s var(--gerak) both; }
.komentar .k.saya { align-self: flex-end; background: var(--langit2); }
.komentar .k.sistem { align-self: center; background: transparent; color: var(--redup); font-size: 12.5px; text-align: center; max-width: 100%; }
.komentar .k .siapa { font-size: 11.5px; font-weight: 700; color: var(--redup); margin-bottom: 2px; }
.komentar .k.internal { background: #FFF7E6; border: 1px dashed #F5B54A; }
@media print { .samping, .nav-bawah, .atas, .fab, #toast { display: none !important; } }
