body.pgh{--bg:#dff1ff;--ink:#0c2d48;--muted:#3f617c;--line:rgba(14,116,190,.16);--brand:#0369a1;--dark:#075985;--danger:#b42318;margin:0;background:var(--bg);color:var(--ink);font:15px/1.5 system-ui,-apple-system,"Segoe UI",Roboto,sans-serif}
.pgh *{box-sizing:border-box}
.pgh [hidden]{display:none!important}
.pgh h1{font-size:24px;margin:0 0 4px;line-height:1.25}
.pgh h2{font-size:17px;margin:0 0 12px}
.pgh a{color:var(--brand)}
.pgh .muted{color:var(--muted);margin:0 0 18px}
.pgh label{display:flex;flex-direction:column;gap:5px;font-weight:600;font-size:13px;min-width:0}
.pgh input,.pgh select,.pgh textarea{width:100%;font:inherit;font-weight:400;font-size:16px;padding:9px 11px;border:1px solid #b6d8f0;border-radius:8px;background:#fff;color:var(--ink);margin:0}
.pgh input:focus,.pgh select:focus,.pgh textarea:focus,.pgh .btn:focus-visible,.pgh .burger:focus-visible{outline:3px solid #38bdf8;outline-offset:1px}
.pgh label.check{flex-direction:row;align-items:center;font-weight:400}
.pgh .check input{width:auto}
.pgh .btn{display:inline-flex;justify-content:center;align-items:center;padding:9px 16px;border:1px solid #b6d8f0;border-radius:8px;background:#fff;color:var(--ink);font-family:inherit;font-size:14px;font-weight:600;line-height:1.4;cursor:pointer;text-decoration:none}
.pgh .btn.primary{background:var(--brand);border-color:var(--brand);color:#fff}
.pgh .btn.danger{color:var(--danger);border-color:#f1b8b2}
.pgh .btn.small{padding:5px 11px;font-size:13px}
.pgh .btn.block{display:flex;width:100%}
.pgh .logo{display:inline-grid;place-items:center;width:56px;height:56px;border-radius:14px;background:var(--brand);color:#fff;font-weight:800;font-size:20px;flex:none}
.pgh .logo.sm{width:38px;height:38px;font-size:15px;border-radius:10px}
.pgh .alert{padding:10px 13px;border-radius:8px;margin-bottom:14px;font-size:14px}
.pgh .alert.error{background:#fdecea;color:var(--danger)}
.pgh .alert.info{background:rgba(186,230,253,.65);color:#075985}
.auth{min-height:100vh;display:grid;place-items:center;padding:16px;background:transparent}
.auth-card{width:100%;max-width:390px;background:#fff;border-radius:16px;padding:30px;text-align:center;box-shadow:0 20px 50px rgba(0,0,0,.25)}
.auth-card h1{margin-top:12px}
.auth-card form{display:flex;flex-direction:column;gap:13px;text-align:left}
.sidebar{position:fixed;inset:0 auto 0 0;width:250px;background:var(--dark);color:#fff;display:flex;flex-direction:column;padding:18px 14px;z-index:30;overflow-y:auto}
.brand{display:flex;align-items:center;gap:10px;font-weight:700;margin-bottom:22px;overflow-wrap:anywhere}
.sidebar nav{display:flex;flex-direction:column;gap:4px}
.pgh .sidebar nav a{color:#164e72;text-decoration:none;padding:11px 12px;border-radius:8px;font-weight:600}
.pgh .sidebar nav a:hover{background:rgba(255,255,255,.7)}
.pgh .sidebar nav a.active{background:var(--brand);color:#fff}
.user{margin-top:auto;padding-top:20px;display:flex;flex-direction:column;gap:6px}
.user small{color:#3f617c}
.content{margin-left:250px;padding:28px;max-width:1150px}
.topbar,.backdrop{display:none}
.card{background:#fff;border:1px solid var(--line);border-radius:12px;padding:18px;margin-bottom:18px;min-width:0}
.cards{display:grid;grid-template-columns:repeat(3,1fr);gap:16px}
.stat{border-top:4px solid var(--brand);display:flex;flex-direction:column;justify-content:space-between;gap:8px}
.stat.warn{border-top-color:#d97706}.stat.ok{border-top-color:#2563eb}
.stat span{color:var(--muted);font-size:13px}.stat b{font-size:25px;overflow-wrap:anywhere}
.grid{display:grid;grid-template-columns:1fr 1fr;gap:14px}
.pgh .grid .full{grid-column:1/-1;margin-bottom:0}
.actions{display:flex;gap:10px;flex-wrap:wrap}
.tabs{display:flex;gap:6px;margin:12px 0}
.tab{border:0;background:rgba(255,255,255,.55);color:var(--ink);padding:10px 16px;border-radius:8px;font-family:inherit;font-size:14px;font-weight:600;cursor:pointer}
.tab.active{background:var(--brand);color:#fff}
.table-wrap{overflow-x:auto}
.pgh table{width:100%;border-collapse:collapse;font-size:14px;margin:0}
.pgh th,.pgh td{text-align:left;padding:10px;border:0;border-bottom:1px solid var(--line);vertical-align:top}
.pgh th{background:rgba(224,242,254,.65);font-size:12px;color:var(--muted)}
.pgh .num{text-align:right;white-space:nowrap}
.pgh .empty{text-align:center;color:var(--muted)}
.pgh td .actions{flex-wrap:nowrap;gap:6px}
.pgh tfoot td{font-weight:700;background:rgba(224,242,254,.65)}
.week{margin:18px 0 8px;font-size:15px}
.grand{display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap;background:var(--dark);color:#fff;padding:14px 16px;border-radius:8px;font-weight:700;margin-top:18px}
.toast{position:fixed;bottom:18px;left:50%;transform:translateX(-50%);background:var(--ink);color:#fff;padding:11px 18px;border-radius:8px;z-index:50;width:max-content;max-width:calc(100% - 32px)}
@media (max-width:900px){.cards{grid-template-columns:1fr}}
@media (max-width:767px){
.topbar{display:flex;align-items:center;gap:12px;position:sticky;top:0;z-index:10;background:#fff;border-bottom:1px solid var(--line);padding:10px 16px}
.burger{font-size:22px;background:none;border:0;color:var(--ink);padding:4px 8px;cursor:pointer}
.sidebar{transform:translateX(-100%);visibility:hidden;transition:transform .25s,visibility .25s}
.menu-open .sidebar{transform:none;visibility:visible}
.menu-open .backdrop{display:block;position:fixed;inset:0;background:rgba(0,0,0,.55);z-index:20}
body.pgh.menu-open{overflow:hidden}
.content{margin-left:0;padding:16px}
.grid{grid-template-columns:1fr}
}
@media print{.sidebar,.topbar,.toast,#reportForm{display:none!important}.content{margin:0;padding:0}.card{border:0;padding:0}.grand{color:#000;border:2px solid #000}}

/* ---------- Modern glass, biru muda ---------- */
body.pgh{--glass:rgba(255,255,255,.52);--edge:rgba(255,255,255,.85);--shadow:0 10px 32px rgba(14,100,170,.14);min-height:100vh;background:linear-gradient(135deg,#e8f6ff 0%,#cdeaff 45%,#dbeafe 100%) fixed}
body.pgh::before{content:"";position:fixed;inset:0;z-index:-1;pointer-events:none;background:radial-gradient(circle at 12% 18%,rgba(56,189,248,.45),transparent 32%),radial-gradient(circle at 88% 12%,rgba(129,140,248,.30),transparent 30%),radial-gradient(circle at 70% 85%,rgba(34,211,238,.35),transparent 34%),radial-gradient(circle at 30% 95%,rgba(147,197,253,.50),transparent 30%)}
.card,.auth-card,.sidebar,.topbar{background:var(--glass);border:1px solid var(--edge);box-shadow:var(--shadow);-webkit-backdrop-filter:blur(18px) saturate(150%);backdrop-filter:blur(18px) saturate(150%)}
.card{border-radius:20px;padding:20px}
.auth-card{border-radius:26px}
.sidebar{inset:14px auto 14px 14px;width:236px;border-radius:22px;color:var(--ink)}
.content{margin-left:250px}
.pgh input,.pgh select,.pgh textarea{background:rgba(255,255,255,.72);border-radius:12px}
.pgh input[type=checkbox]{accent-color:var(--brand)}
.pgh .btn{border-radius:12px;background:rgba(255,255,255,.65);transition:transform .15s,box-shadow .15s}
.pgh .btn:hover:not(:disabled){transform:translateY(-1px);box-shadow:0 6px 16px rgba(14,100,170,.18)}
.pgh .btn:disabled{opacity:.5;cursor:not-allowed}
.pgh .btn.primary,.pgh .sidebar nav a.active,.tab.active,.pgh .logo{background:linear-gradient(135deg,#0284c7,#0369a1);border-color:transparent;color:#fff}
.pgh .sidebar nav a,.tab{border-radius:12px}
.pgh .sidebar nav a.active{box-shadow:0 6px 16px rgba(2,132,199,.35)}
.tab{border:1px solid var(--edge)}
.stat{border-top:1px solid var(--edge);position:relative;overflow:hidden}
.stat::before{content:"";position:absolute;left:20px;top:0;width:52px;height:4px;border-radius:0 0 6px 6px;background:#0284c7}
.stat.warn{border-top-color:var(--edge)}.stat.ok{border-top-color:var(--edge)}
.stat.warn::before{background:#d97706}.stat.ok::before{background:#4f46e5}
.pgh th:first-child{border-radius:10px 0 0 10px}.pgh th:last-child{border-radius:0 10px 10px 0}
.grand{background:linear-gradient(135deg,#075985,#0369a1);border-radius:14px}
.toast{border-radius:12px;background:rgba(12,45,72,.94)}
@supports not ((backdrop-filter:blur(1px)) or (-webkit-backdrop-filter:blur(1px))){body.pgh{--glass:rgba(255,255,255,.94)}}
@media (max-width:767px){
.topbar{border-width:0 0 1px}
.sidebar{inset:0 auto 0 0;width:260px;border-radius:0 22px 22px 0;background:rgba(236,248,255,.9);transform:translateX(-100%)}
.menu-open .sidebar{transform:none}
.menu-open .backdrop{background:rgba(8,47,73,.45)}
.content{margin-left:0}
.card{padding:16px}
}
@media print{body.pgh,body.pgh::before{background:#fff}.card{box-shadow:none;border:0;background:none}.content{margin:0}.grand{background:none;color:#000}}

/* ---------- Pilih banyak ---------- */
.pgh th.chk,.pgh td.chk{width:36px;padding-right:0}
.pgh td.chk input,.pgh th.chk input{width:18px;height:18px;padding:0;cursor:pointer}
.bulkbar{display:flex;justify-content:space-between;align-items:center;gap:10px;margin:-4px 0 10px}
.pgh .bulkbar .muted{margin:0;font-size:13px}

/* ---------- Animasi (tema air / kaca biru muda) ---------- */
@keyframes pgh-drift{0%{transform:translate3d(0,0,0) scale(1)}50%{transform:translate3d(2.5%,-2%,0) scale(1.08)}100%{transform:translate3d(-2.5%,2.5%,0) scale(1.04)}}
@keyframes pgh-rise{from{opacity:0;transform:translateY(18px) scale(.985)}to{opacity:1;transform:none}}
@keyframes pgh-fade{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:none}}
@keyframes pgh-slide{from{opacity:0;transform:translateX(-24px)}to{opacity:1;transform:none}}
@keyframes pgh-float{0%,100%{transform:translateY(0)}50%{transform:translateY(-7px)}}
@keyframes pgh-ring{0%{box-shadow:0 0 0 0 rgba(2,132,199,.45)}70%,100%{box-shadow:0 0 0 18px rgba(2,132,199,0)}}
@keyframes pgh-shine{0%{transform:translateX(-120%) skewX(-20deg)}60%,100%{transform:translateX(220%) skewX(-20deg)}}
@keyframes pgh-bubble{0%{transform:translate3d(0,0,0) scale(.6);opacity:0}12%{opacity:.9}100%{transform:translate3d(var(--sway,20px),-115vh,0) scale(1);opacity:0}}
@keyframes pgh-shake{10%,90%{transform:translateX(-2px)}20%,80%{transform:translateX(4px)}30%,50%,70%{transform:translateX(-7px)}40%,60%{transform:translateX(7px)}}
@keyframes pgh-spin{to{transform:rotate(360deg)}}
@keyframes pgh-toast{from{opacity:0;transform:translate(-50%,16px)}to{opacity:1;transform:translate(-50%,0)}}

/* latar bergerak pelan */
body.pgh::before{animation:pgh-drift 22s ease-in-out infinite alternate;will-change:transform}

/* halaman login */
.bubbles{position:fixed;inset:0;overflow:hidden;pointer-events:none;z-index:0}
.bubbles span{position:absolute;bottom:-60px;left:var(--x,10%);width:var(--s,28px);height:var(--s,28px);border-radius:50%;background:radial-gradient(circle at 30% 28%,rgba(255,255,255,.95),rgba(186,230,253,.45) 45%,rgba(56,189,248,.18) 75%);border:1px solid rgba(255,255,255,.8);box-shadow:inset 0 0 10px rgba(255,255,255,.7),0 4px 14px rgba(14,116,190,.15);opacity:0;animation:pgh-bubble var(--d,16s) linear var(--t,0s) infinite}
.bubbles span:nth-child(1){--x:6%;--s:22px;--d:15s;--t:0s;--sway:30px}
.bubbles span:nth-child(2){--x:16%;--s:46px;--d:21s;--t:3s;--sway:-40px}
.bubbles span:nth-child(3){--x:27%;--s:18px;--d:13s;--t:7s;--sway:24px}
.bubbles span:nth-child(4){--x:38%;--s:34px;--d:18s;--t:1s;--sway:-26px}
.bubbles span:nth-child(5){--x:52%;--s:60px;--d:26s;--t:5s;--sway:36px}
.bubbles span:nth-child(6){--x:63%;--s:24px;--d:14s;--t:9s;--sway:-30px}
.bubbles span:nth-child(7){--x:74%;--s:40px;--d:20s;--t:2s;--sway:28px}
.bubbles span:nth-child(8){--x:84%;--s:20px;--d:16s;--t:6s;--sway:-22px}
.bubbles span:nth-child(9){--x:92%;--s:52px;--d:24s;--t:11s;--sway:-34px}
.bubbles span:nth-child(10){--x:45%;--s:16px;--d:12s;--t:4s;--sway:18px}
.auth{position:relative;z-index:1}
.auth-card{animation:pgh-rise .7s cubic-bezier(.2,.8,.2,1) both}
.auth-card .logo{animation:pgh-float 4s ease-in-out infinite,pgh-ring 2.8s ease-out infinite}
.auth-card>*{animation:pgh-fade .6s ease-out both}
.auth-card>:nth-child(2){animation-delay:.12s}.auth-card>:nth-child(3){animation-delay:.2s}.auth-card>:nth-child(4){animation-delay:.28s}.auth-card>:nth-child(5){animation-delay:.36s}.auth-card>:nth-child(6){animation-delay:.44s}
.auth-card.has-error{animation:pgh-rise .7s cubic-bezier(.2,.8,.2,1) both,pgh-shake .6s .7s both}
.auth-card input[type=text],.auth-card input[type=password]{transition:box-shadow .2s,border-color .2s,transform .2s}
.auth-card input[type=text]:focus,.auth-card input[type=password]:focus{transform:translateY(-1px);border-color:#38bdf8;box-shadow:0 0 0 4px rgba(56,189,248,.25);outline:0}
.pgh .btn.primary{position:relative;overflow:hidden}
.pgh .btn.primary::after{content:"";position:absolute;top:0;left:0;width:45%;height:100%;background:linear-gradient(90deg,transparent,rgba(255,255,255,.45),transparent);transform:translateX(-120%) skewX(-20deg);pointer-events:none}
.pgh .btn.primary:hover::after{animation:pgh-shine .9s ease}
.pgh .btn:active:not(:disabled){transform:scale(.97)}
.pgh .btn.loading{pointer-events:none;color:transparent}
.pgh .btn.loading::before{content:"";position:absolute;inset:0;margin:auto;width:18px;height:18px;border-radius:50%;border:2px solid rgba(255,255,255,.5);border-top-color:#fff;animation:pgh-spin .7s linear infinite}

/* aplikasi */
.sidebar{animation:pgh-slide .6s cubic-bezier(.2,.8,.2,1) both}
.pgh .sidebar nav a{transition:background .2s,transform .2s,box-shadow .2s}
.pgh .sidebar nav a:hover:not(.active){transform:translateX(4px)}
.page:not([hidden]){animation:pgh-fade .45s ease-out both}
.page:not([hidden]) .card{animation:pgh-rise .55s cubic-bezier(.2,.8,.2,1) both}
.page:not([hidden]) .cards .card:nth-child(2){animation-delay:.08s}
.page:not([hidden]) .cards .card:nth-child(3){animation-delay:.16s}
.page:not([hidden])>.card:nth-of-type(n+2),.page:not([hidden])>.cards~.card{animation-delay:.2s}
.card.stat{transition:transform .25s,box-shadow .25s}
.card.stat:hover{transform:translateY(-4px);box-shadow:0 16px 38px rgba(14,100,170,.22)}
.stat.warn::before{animation:pgh-pulse-bar 2.4s ease-in-out infinite}
@keyframes pgh-pulse-bar{0%,100%{width:52px}50%{width:84px}}
.page:not([hidden]) tbody tr{animation:pgh-fade .4s ease-out both;transition:background .2s}
.page:not([hidden]) tbody tr:nth-child(1){animation-delay:.05s}.page:not([hidden]) tbody tr:nth-child(2){animation-delay:.1s}.page:not([hidden]) tbody tr:nth-child(3){animation-delay:.15s}.page:not([hidden]) tbody tr:nth-child(4){animation-delay:.2s}.page:not([hidden]) tbody tr:nth-child(5){animation-delay:.25s}.page:not([hidden]) tbody tr:nth-child(n+6){animation-delay:.3s}
.pgh tbody tr:hover{background:rgba(186,230,253,.35)}
.tabpane:not([hidden]){animation:pgh-fade .35s ease-out both}
.toast:not([hidden]){animation:pgh-toast .3s ease-out both}

@media (prefers-reduced-motion:reduce){
body.pgh::before,.bubbles span,.auth-card,.auth-card *,.sidebar,.page,.page *,.tabpane,.toast,.stat::before,.btn::after,.btn::before{animation:none!important;transition:none!important}
.bubbles{display:none}
}

/* ---------- Karyawan belum gajian ---------- */
.due-head{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:12px}
.due-head h2{margin:0}
.chip{display:inline-flex;align-items:center;padding:4px 12px;border-radius:999px;background:rgba(217,119,6,.14);color:#92400e;font-size:12.5px;font-weight:700;border:1px solid rgba(217,119,6,.25)}
.due-list{display:flex;flex-direction:column;gap:10px}
.due-item{display:grid;grid-template-columns:auto 1fr auto auto;align-items:center;gap:14px;padding:12px 14px;border-radius:16px;background:rgba(255,255,255,.62);border:1px solid var(--edge);box-shadow:0 4px 14px rgba(14,100,170,.08);transition:transform .2s,box-shadow .2s}
.due-item:hover{transform:translateY(-2px);box-shadow:0 10px 24px rgba(14,100,170,.16)}
.avatar{width:44px;height:44px;border-radius:50%;display:grid;place-items:center;font-weight:800;font-size:15px;color:#fff;background:linear-gradient(135deg,#38bdf8,#0369a1);box-shadow:0 4px 10px rgba(2,132,199,.3)}
.due-main{display:flex;flex-direction:column;gap:4px;min-width:0}
.due-name{font-size:15.5px;overflow-wrap:anywhere}
.due-months{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.due-months small,.due-amount small{color:var(--muted);font-size:12px}
.pill{display:inline-block;padding:2px 10px;border-radius:999px;background:#fef3c7;color:#92400e;font-size:12px;font-weight:700;border:1px solid #fcd34d}
.due-amount{display:flex;flex-direction:column;align-items:flex-end;text-align:right;gap:1px}
.due-amount b{font-size:18px;white-space:nowrap}
.due-empty{display:flex;align-items:center;justify-content:center;gap:10px;padding:22px;color:var(--muted);font-weight:600}
.ok-ico{display:inline-grid;place-items:center;width:28px;height:28px;border-radius:50%;background:#dcfce7;color:#15803d;font-weight:800}
.pgh .btn.success{background:linear-gradient(135deg,#22c55e,#15803d);border-color:transparent;color:#fff;position:relative;overflow:hidden}
.pgh .btn.success:hover:not(:disabled){box-shadow:0 6px 16px rgba(21,128,61,.4)}
@media (max-width:640px){
.due-item{grid-template-columns:auto 1fr;gap:10px 12px}
.due-amount{grid-column:1/-1;flex-direction:row;justify-content:space-between;align-items:baseline;text-align:left;padding-top:8px;border-top:1px dashed var(--line)}
.due-item .btn{grid-column:1/-1;width:100%}
}

/* ---------- Popup konfirmasi ---------- */
.modal{position:fixed;inset:0;z-index:60;display:grid;place-items:center;padding:16px;background:rgba(8,47,73,.5);-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);animation:pgh-fade-in .2s ease-out both}
.modal-card{width:100%;max-width:440px;text-align:center;padding:28px 24px 22px;border-radius:24px;background:rgba(255,255,255,.92);border:1px solid var(--edge);box-shadow:0 24px 60px rgba(8,47,73,.35);animation:pgh-pop .35s cubic-bezier(.2,1.2,.3,1) both}
.modal-icon{width:60px;height:60px;margin:0 auto 12px;border-radius:50%;display:grid;place-items:center;font-size:32px;font-weight:800;color:#fff;background:linear-gradient(135deg,#fbbf24,#d97706);animation:pgh-warn 1.8s ease-in-out infinite}
.modal-card h2{font-size:22px;letter-spacing:.5px;color:#b45309;margin:0 0 8px}
.modal-card p{margin:0 0 14px;font-size:16px;line-height:1.55}
.pay-name{color:var(--brand);font-size:17px}
.pay-sum{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap;padding:10px 14px;border-radius:12px;background:#f0f9ff;border:1px solid #bae6fd;margin-bottom:18px;font-size:13.5px;color:var(--muted)}
.pay-sum b{font-size:17px;color:var(--ink)}
.modal-actions{display:flex;gap:10px}
.modal-actions .btn{flex:1;padding:12px 14px;font-size:15px}
.modal-actions .btn.success{flex:1.4;letter-spacing:.4px}
body.pgh.modal-open{overflow:hidden}
@keyframes pgh-fade-in{from{opacity:0}to{opacity:1}}
@keyframes pgh-pop{from{opacity:0;transform:scale(.88) translateY(14px)}to{opacity:1;transform:none}}
@keyframes pgh-warn{0%,100%{box-shadow:0 0 0 0 rgba(217,119,6,.45)}60%{box-shadow:0 0 0 14px rgba(217,119,6,0)}}
.page:not([hidden]) .due-item{animation:pgh-fade .4s ease-out both}
.due-item:nth-child(2){animation-delay:.06s!important}.due-item:nth-child(3){animation-delay:.12s!important}.due-item:nth-child(n+4){animation-delay:.18s!important}
@media (prefers-reduced-motion:reduce){.modal,.modal-card,.modal-icon,.due-item{animation:none!important;transition:none!important}}

/* ---------- Logo Farraz Kreasindo (putih di atas latar biru) ---------- */
.pgh .logo{width:96px;height:112px;border-radius:24px;padding:11px;box-shadow:0 10px 26px rgba(3,105,161,.35),inset 0 1px 0 rgba(255,255,255,.35)}
.pgh .logo.sm{width:42px;height:48px;border-radius:12px;padding:5px;box-shadow:0 4px 10px rgba(3,105,161,.3)}
.pgh .logo img{display:block;width:100%;height:100%;object-fit:contain}
.auth-card .logo{margin:0 auto 6px}
