*{box-sizing:border-box;margin:0}html,body{height:100%}body{font:15px/1.4 system-ui,'Segoe UI',Roboto,sans-serif;background:#eef1f6;color:#1b2540;-webkit-text-size-adjust:100%}
button,input,select,textarea{font:inherit;color:inherit}[hidden]{display:none!important}
#app{max-width:600px;margin:0 auto;min-height:100dvh;display:flex;flex-direction:column}
/* bar atas */
.top{background:#0b3a6e;color:#fff;padding:calc(12px + env(safe-area-inset-top)) 16px 13px;display:flex;align-items:center;justify-content:space-between;gap:10px;position:sticky;top:0;z-index:5}
.top h1{font-size:18px}.top .sub{font-size:12px;opacity:.8}.top .r{display:flex;gap:8px;align-items:center}
.ic-btn{background:rgba(255,255,255,.14);border:0;color:#fff;border-radius:10px;padding:8px 10px;font-size:13px;font-weight:600}
/* isi */
.wrap{flex:1;padding:14px;display:flex;flex-direction:column;gap:13px;overflow-y:auto;padding-bottom:84px}
.sec{font-size:12px;font-weight:700;letter-spacing:.03em;color:#6b7488;text-transform:uppercase}
.card{background:#fff;border-radius:14px;box-shadow:0 1px 3px rgba(16,24,40,.08)}
.lbl{font-size:12.5px;font-weight:700;color:#475569;margin-bottom:4px}
input[type=text],input[type=password],input[type=date],input[type=time],input[type=search],input[type=number],select,textarea{width:100%;background:#fff;border:1px solid #cbd5e1;border-radius:11px;padding:11px 12px}
textarea{min-height:74px;resize:vertical}.two{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.kpis{display:grid;grid-template-columns:1fr 1fr;gap:11px}.kpi{padding:13px 14px}.kpi small{font-size:12px;color:#6b7488}.kpi b{display:block;white-space:nowrap;font-size:27px;line-height:1.2;margin:3px 0 2px}.kpi span{font-size:12px;color:#6b7488}
.red{color:#d92d20}.blue{color:#0b3a6e}.green{color:#12805c}.amber{color:#b54708}.mut{color:#6b7488}
.list .it{display:flex;justify-content:space-between;align-items:center;padding:12px 14px;border-bottom:1px solid #eef1f6;gap:10px}.list .it:last-child{border-bottom:0}
.it .l{min-width:0}.it .l b{display:block;font-size:15px}.it .l small{display:block;font-size:12.5px;color:#6b7488}.it .r{text-align:right;flex:none}.it .r b{display:block;font-size:16px}.it .r small{font-size:12px;color:#6b7488}
.it.warn{background:#fffaeb}
.pill{display:inline-block;font-size:11px;font-weight:700;border-radius:18px;padding:2px 9px;white-space:nowrap}.p-r{background:#fee4e2;color:#b42318}.p-a{background:#fef0c7;color:#93370d}.p-b{background:#d1e9ff;color:#175cd3}.p-g{background:#d1fadf;color:#05603a}
.chips{display:flex;flex-wrap:wrap;gap:7px}.chip{background:#fff;border:1px solid #cbd5e1;border-radius:18px;padding:7px 12px;font-size:14px}.chip.on{background:#0b3a6e;border-color:#0b3a6e;color:#fff}
.seg{display:flex;background:#e2e6ef;border-radius:11px;padding:3px}.seg button{flex:1;border:0;background:none;padding:9px;border-radius:9px;font-size:13.5px;font-weight:600;color:#5b6478}.seg button.on{background:#fff;color:#0b3a6e;box-shadow:0 1px 3px rgba(16,24,40,.15)}
.btn{display:block;width:100%;border:0;border-radius:12px;padding:13px;font-weight:700;font-size:16px;text-align:center}.pr{background:#0b3a6e;color:#fff}.go{background:#16a34a;color:#fff}.add{background:#fff;border:2px dashed #0b3a6e;color:#0b3a6e}.gh{background:#fff;border:1px solid #cbd5e1;color:#334155}.dg{background:#fff;border:1px solid #fca5a5;color:#b91c1c}.btn:disabled{opacity:.5}
.fab{position:fixed;left:50%;transform:translateX(calc(300px - 86px));bottom:calc(74px + env(safe-area-inset-bottom));width:58px;height:58px;border-radius:50%;background:#0b3a6e;color:#fff;font-size:33px;display:grid;place-items:center;box-shadow:0 8px 18px rgba(11,58,110,.4);z-index:6;border:0}
@media(max-width:620px){.fab{left:auto;right:16px;transform:none}}
.foot{position:fixed;bottom:calc(60px + env(safe-area-inset-bottom));left:0;right:0;max-width:600px;margin:0 auto;background:#fff;border-top:1px solid #e2e8f0;padding:10px 14px;display:flex;flex-direction:column;gap:8px;z-index:6}
/* tab bar bawah */
.tabbar{position:fixed;bottom:0;left:0;right:0;max-width:600px;margin:0 auto;background:#fff;border-top:1px solid #e3e7ef;display:flex;padding:7px 4px calc(7px + env(safe-area-inset-bottom));z-index:7}
.tabbar button{flex:1;border:0;background:none;display:flex;flex-direction:column;align-items:center;gap:2px;font-size:11px;color:#8a93a6;font-weight:600;padding:3px 0}
.tabbar button .ic{font-size:21px;line-height:1.1}.tabbar button.on{color:#0b3a6e}.tabbar button .bdg{position:absolute;margin:-4px 0 0 16px;background:#d92d20;color:#fff;border-radius:10px;font-size:9px;padding:0 5px;font-weight:700}
/* login */
.login{flex:1;background:linear-gradient(165deg,#0b3a6e,#0a1f3d);color:#fff;padding:58px 24px;display:flex;flex-direction:column;gap:12px}
.login .mk{width:62px;height:62px;border-radius:16px;background:#fff;display:grid;place-items:center;font-size:32px}.login h2{font-size:25px;margin-top:6px}
.login input{background:rgba(255,255,255,.12);border-color:rgba(255,255,255,.28);color:#fff}.login input::placeholder{color:#cbd5e1}
.login .btn{background:#38bdf8;color:#06243f}.login .err{color:#fecaca;font-size:14px;min-height:18px}
.err{color:#b91c1c;font-size:14px}
.done{flex:1;display:grid;place-content:center;text-align:center;gap:10px;padding:24px}.done .c{width:88px;height:88px;border-radius:50%;background:#d1fadf;color:#05603a;font-size:48px;display:grid;place-items:center;margin:0 auto}
.rep{background:#fff7ed;border:1px solid #fdba74;border-radius:12px;padding:9px 12px}.rep .h{font-size:12.5px;font-weight:700;color:#9a3412;margin-bottom:5px}.hg{display:flex;justify-content:space-between;align-items:center;padding:7px 0;border-top:1px dashed #fed7aa}.hg:first-of-type{border-top:0}.st{display:flex;gap:7px;align-items:center}.st button{width:36px;height:36px;border-radius:50%;border:0;background:#0b3a6e;color:#fff;font-size:20px}.st input{width:58px;text-align:center;font-weight:700}
.photos{display:flex;gap:9px;flex-wrap:wrap}.photos .th{position:relative;width:78px;height:78px}.photos img{width:100%;height:100%;object-fit:cover;border-radius:10px;border:1px solid #cbd5e1}.photos .th button{position:absolute;top:-7px;right:-7px;width:24px;height:24px;border-radius:50%;border:0;background:#dc2626;color:#fff}
.photos label.add2{width:78px;height:78px;border:2px dashed #94a3b8;border-radius:10px;display:grid;place-items:center;text-align:center;font-size:11.5px;color:#64748b;background:#fff}
.jigline{display:grid;grid-template-columns:1fr 70px 30px;gap:8px;align-items:center;padding:9px 12px;border-bottom:1px solid #eef1f6}.jigline:last-child{border-bottom:0}.jigline.warn{background:#fffaeb}.jigline input[type=text]{padding:8px 10px}.jigline input[type=number]{padding:8px 6px;text-align:center}.jigline .x{border:0;background:none;color:#b91c1c;font-size:18px}
.modal{position:fixed;inset:0;background:rgba(16,24,40,.5);display:grid;place-items:center;z-index:20;padding:16px}.sheetm{background:#fff;border-radius:18px;width:100%;max-width:460px;padding:18px;display:flex;flex-direction:column;gap:11px;max-height:88dvh;overflow:auto}.sheetm h3{font-size:17px}
.opt{display:flex;gap:13px;align-items:center;border-radius:15px;padding:15px;color:#fff}.opt .ic{width:46px;height:46px;border-radius:13px;background:rgba(255,255,255,.2);display:grid;place-items:center;font-size:24px}.opt b{display:block;font-size:17px}.opt small{font-size:12.5px;opacity:.9}
table{width:100%;border-collapse:collapse}th{text-align:left;font-size:11px;color:#6b7488;font-weight:700;padding:9px 10px 7px;text-transform:uppercase}td{padding:9px 10px;border-top:1px solid #eef1f6;font-size:14px}th.n,td.n{text-align:right}tr.tot td{background:#f4f6fa;font-weight:700}
.u{display:flex;justify-content:space-between;align-items:center;padding:12px 14px;border-bottom:1px solid #eef1f6;gap:8px}.u:last-child{border-bottom:0}.u b{font-size:14.5px;display:block}.u small{color:#6b7488;font-size:12px}.ck{display:flex;gap:5px}.ck span{font-size:11px;font-weight:700;border-radius:8px;padding:4px 8px;background:#e4e8f0;color:#98a2b3}.ck .on{background:#d1fadf;color:#05603a}
#toast{position:fixed;left:50%;bottom:calc(84px + env(safe-area-inset-bottom));transform:translateX(-50%);background:#14213d;color:#fff;border-radius:12px;padding:10px 16px;max-width:88%;z-index:30;font-size:14px;text-align:center}
.empty{text-align:center;color:#6b7488;font-size:13.5px;padding:24px 10px}
.sec-gap{margin-top:8px}
.kpi b small{font-size:14px;font-weight:600;color:#6b7488}
.jigline{display:grid;grid-template-columns:1fr 70px 30px;gap:8px;align-items:start}
textarea.jn{width:100%;min-height:40px;resize:none;overflow:hidden;white-space:pre-wrap;word-break:break-word;font-size:14px;line-height:1.35;padding:8px 10px;border:1px solid #cbd5e1;border-radius:9px;background:#fff;field-sizing:content}
.jigline input[type=number]{width:70px;padding:8px 6px;text-align:center;margin-top:0}
.jigline .x{padding:6px 4px;justify-self:center;margin-top:2px}
.it .l b{white-space:normal;word-break:break-word;overflow-wrap:anywhere}
button.jn.pick{width:100%;text-align:left;min-height:40px;padding:8px 10px;border:1px solid #cbd5e1;border-radius:9px;background:#fff;font:inherit;color:#0f172a;cursor:pointer;white-space:normal;word-break:break-word;line-height:1.35}
button.jn.pick b{display:block;font-size:14px;font-weight:600}
button.jn.pick small{display:block;font-size:11.5px;color:#64748b;margin-top:2px}
button.jn.pick.none{border-color:#f59e0b;background:#fffbeb}button.jn.pick.none b{color:#b45309}
.pickm{max-height:88vh;display:flex;flex-direction:column}.pickm input[type=search]{margin:6px 0}
.picklist{overflow-y:auto;flex:1;min-height:200px;border:1px solid #eef1f6;border-radius:10px}
.picklist .pc{position:sticky;top:0;background:#eef6f5;color:#0f766e;font-size:11.5px;font-weight:700;padding:6px 10px;text-transform:uppercase}
.picklist .po{display:block;width:100%;text-align:left;border:0;border-bottom:1px solid #f1f5f9;background:#fff;padding:11px 12px;font:inherit;font-size:14px;white-space:normal;word-break:break-word}
.picklist .po:active{background:#ecfdf5}
.readst{background:#eff6ff;color:#1e3a8a;border-radius:10px;padding:10px 12px;font-size:13.5px;font-weight:600}
.readst.bad{background:#fef2f2;color:#991b1b}.readst .btn{margin-top:8px;width:100%}
.pgrow{display:flex;flex-direction:column;gap:8px}.pgrow input{max-width:140px}
.photos .add2{font-size:12.5px}
.card.opn{display:flex;flex-direction:column;gap:6px;padding:12px 14px}.card.opn small{color:#64748b;font-size:12px}.card.opn b{font-size:15px}
.pbar{position:relative;height:22px;background:#eef1f6;border-radius:11px;overflow:hidden}.pbar i{position:absolute;left:0;top:0;bottom:0;background:linear-gradient(90deg,#f59e0b,#16a34a);border-radius:11px}
.pbar span{position:relative;display:block;text-align:center;font-size:12.5px;font-weight:700;line-height:22px;color:#0f172a}
.photos .th em{position:absolute;left:4px;bottom:4px;background:rgba(15,23,42,.7);color:#fff;font-size:10px;font-style:normal;padding:1px 5px;border-radius:6px}.photos .th{position:relative}
