/* PT1: peta penuh, panel detail satu tempat; stacking Leaflet tetap terisolasi. */
.inv-peta-filters{display:flex;flex-wrap:wrap;gap:10px;align-items:center;margin:20px 0}
.ui-shell .inv-peta-filters label,.inv-peta-filters label{margin:0;display:inline-flex;align-items:center;min-height:40px}
.inv-peta-filters button{min-height:40px}
.inv-peta-filters .pss{width:220px;flex:0 1 220px}
.inv-peta-filters input,.inv-peta-filters select{width:auto;min-height:40px}
.ui-shell .inv-peta-filters input,.ui-shell .inv-peta-filters select{min-height:40px;margin-top:0;margin-bottom:0}
.inv-peta-layout{display:grid;grid-template-columns:minmax(0,1fr);gap:16px}
.inv-peta-layout.inv-peta-open{grid-template-columns:minmax(0,1fr) minmax(280px,380px)}
.inv-peta-map{height:540px;min-width:0;isolation:isolate;z-index:0;border:1px solid var(--ui-border,#ddd);border-radius:6px}
.inv-peta-detail{min-width:0;max-height:540px;overflow:auto;padding:0 8px}
.inv-peta-detail-head{display:flex;justify-content:space-between;gap:8px;align-items:start}
.inv-peta-detail-head h2{margin-top:0}
.inv-peta-pin{width:24px;height:38px;fill:#7a1f2b;stroke:#fff;stroke-width:1.5;filter:drop-shadow(0 1px 2px #0006)}
.inv-peta-pin .inv-peta-state{fill:var(--inv-pin);stroke:none}
.inv-peta-proyek{--inv-pin:#239447}.inv-peta-dicurigai{--inv-pin:#e2bb22}.inv-peta-luar,.inv-peta-tanpa_gps{--inv-pin:#e77c25}.inv-peta-mess,.inv-peta-kantor{--inv-pin:#287cc1}.inv-peta-lama{--inv-pin:#838b93}
.inv-peta-number{display:flex;align-items:center;justify-content:center;width:30px;height:30px;border-radius:50%;background:#fff;color:#111;border:2px solid #7a1f2b;color:#7a1f2b;font-size:12px;font-weight:600}
.inv-peta-legend{padding:6px 8px;background:#fff;color:#222;border-radius:4px;font-size:11px;line-height:1.6;box-shadow:0 1px 4px #0003}
.inv-peta-dot{display:inline-block;width:9px;height:9px;margin-right:6px;border-radius:50%;background:var(--inv-pin)}
.inv-peta-map .leaflet-control-attribution{font-size:11px;background:#fff}
@media(max-width:700px){.inv-peta-layout.inv-peta-open{grid-template-columns:minmax(0,1fr)}.inv-peta-map{height:360px}.inv-peta-detail{max-height:none;padding:0}.inv-peta-filters{align-items:stretch}.ui-shell .inv-peta-filters label,.inv-peta-filters label{align-self:center}}
/* PT2: lingkaran foto/inisial berbingkai warna; zoom jauh jadi titik kecil. */
.pt-hijau{--pt-warna:#16803c}.pt-merah{--pt-warna:#dc2626}.pt-dim{opacity:.35}
.pt-selected{outline:2px solid #2563eb;outline-offset:-2px}
.pt-titik{display:block;width:14px;height:14px;border-radius:50%;background:var(--pt-warna,#16803c);border:2px solid #fff;box-shadow:0 1px 4px #0008}
.pt-titik.pt-merah{box-sizing:border-box;width:18px;height:18px}
.pt-pin{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1px;width:110px;min-height:78px;border-radius:14px;background:#fffffff2;box-shadow:0 1px 5px #0006;color:#111827;font-size:11px;line-height:15px;white-space:nowrap}
.pt-pin>strong,.pt-pin>.pt-nama{max-width:104px;overflow:hidden;text-overflow:ellipsis;min-height:15px}
.pt-foto{display:flex;align-items:center;justify-content:center;flex:none;position:relative;width:44px;height:44px;border-radius:50%;border:4px solid var(--pt-warna,#16803c);background:#e5e7eb;color:#111827;font-weight:700;font-size:14px;overflow:hidden}
.pt-foto img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;display:block}
.inv-peta-filters input[type=checkbox]{min-height:0;width:auto;margin-right:6px}
.inv-peta-cluster{background:#fff;border:2px solid #7a1f2b;color:#7a1f2b;border-radius:20px;display:flex;align-items:center;justify-content:center;gap:4px;min-width:48px;height:36px;font-weight:700;box-shadow:0 1px 4px #0004}

/* PT3: tukang dalam radius ke tabel per lingkaran + lencana angka (lebar peta: PT17 di bawah). */
/* PT6: batas gulir dan lebar kolom berlaku juga di bawah aturan shell HP. */
.ui-shell .peta-tukang-page .pt-tabel-wrap{max-height:min(60vh,560px);overflow-y:auto;overscroll-behavior:contain;--pt-kepala:64px}
.ui-shell .peta-tukang-page .pt-tabel-wrap .pt-tabel{table-layout:fixed;white-space:normal}
.ui-shell .peta-tukang-page .pt-tabel-wrap .pt-tabel th,.ui-shell .peta-tukang-page .pt-tabel-wrap .pt-tabel td{white-space:normal;overflow-wrap:anywhere;padding:8px 10px}
.ui-shell .peta-tukang-page .pt-tabel thead th{height:64px;top:0;z-index:2}
.ui-shell .peta-tukang-page .pt-tabel thead .table-sort{padding:8px 0;max-width:100%;gap:3px}
.pt-tabel thead th:nth-child(1){width:44px}.pt-tabel thead th:nth-child(2){width:64px}.pt-tabel thead th:nth-child(3){width:104px}.pt-tabel thead th:nth-child(4){width:180px}.pt-tabel thead th:nth-child(5){width:180px}
.ui-shell .peta-tukang-page .pt-tabel .pt-grup-baris th{position:static;background:var(--ui-panel)}
.ui-shell .peta-tukang-page .pt-tabel .pt-grup-terbuka .pt-grup-baris th{position:sticky;top:var(--pt-kepala);z-index:1}
@media(max-width:700px){
 .ui-shell .peta-tukang-page .pt-tabel-wrap .pt-tabel th,.ui-shell .peta-tukang-page .pt-tabel-wrap .pt-tabel td{padding:6px 4px;font-size:11px}
 .pt-tabel thead th:nth-child(1){width:30px}.pt-tabel thead th:nth-child(3){width:54px}.pt-tabel thead th:nth-child(4){width:22%}.pt-tabel thead th:nth-child(5){width:82px}
}
.inv-peta-row{display:flex;flex-direction:column;align-items:flex-start;text-align:left;white-space:normal;gap:4px;width:100%;padding:12px;height:auto;flex-shrink:0;font-weight:400}
.pt-tabel .pt-grup-baris th{position:static;text-transform:none;letter-spacing:.02em;font-size:12px;color:var(--ui-text,#111827);border-left:4px solid var(--pt-grup,#dc2626)}
.pt-baris{cursor:pointer}
.pt-baris:focus-visible{outline:3px solid var(--ui-muted,#8a8f98);outline-offset:-3px}
.pt-baris.pt-selected td{background:var(--ui-info-bg,#eff6ff)}
.pt-foto-tabel{display:flex;align-items:center;justify-content:center;position:relative;width:32px;height:32px;border-radius:50%;border:3px solid var(--pt-warna,#16803c);background:#e5e7eb;color:#111827;font-weight:700;font-size:11px;overflow:hidden}
.pt-foto-tabel img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.pt-badge-marker{display:flex;align-items:center;justify-content:center;width:34px;height:34px}
.pt-badge{position:relative;display:flex;align-items:center;justify-content:center;width:28px;height:28px;border-radius:50%;background:#16803c;color:#fff;font-weight:700;font-size:13px;border:2px solid #fff;box-shadow:0 1px 4px #0008}
.pt-badge-cek{position:absolute;top:-8px;right:-9px;display:flex;align-items:center;justify-content:center;min-width:18px;height:18px;padding:0 2px;box-sizing:border-box;border:1px solid #fff;border-radius:12px;background:#f97316;color:#111827;font-size:10px;line-height:1}
.pt-badge-hl{position:absolute;top:-8px;left:-9px;display:flex;align-items:center;justify-content:center;min-width:18px;height:18px;padding:0 2px;box-sizing:border-box;border:1px solid #fff;border-radius:12px;background:#dc2626;color:#fff;font-size:10px;line-height:1}
@keyframes pt-flash{from{background:#dbeafe}to{background:var(--ui-panel,#fff)}}
.pt-grup.pt-flash th,.pt-grup.pt-flash td{animation:pt-flash 1.5s ease-out}
@media(max-width:700px){.ui-shell .peta-tukang-page .pt-tabel th.pt-ko-foto,.ui-shell .peta-tukang-page .pt-tabel td.pt-ko-foto{display:none}}

/* PT4: kelompok lingkaran tertutup bawaan; klik lencana membuka popup daftar tukang. */
.pt-grup-toggle{display:block;width:100%;padding:0;background:none;border:none;font:inherit;color:inherit;text-align:left;cursor:pointer}
.pt-grup-toggle:focus-visible{outline:3px solid var(--ui-muted,#8a8f98);outline-offset:2px;border-radius:4px}
/* Hover tombol global style.css lebih spesifik dari kelas tunggal; lingkup halaman mengembalikan teks terang. */
.peta-tukang-page .pt-grup-toggle:hover,.peta-tukang-page .pt-popup-baris:hover{background:#f3f4f6;color:inherit}
.peta-tukang-page .leaflet-popup-content{margin:12px}
.peta-tukang-page .leaflet-popup-content-wrapper{border-radius:10px}
.pt-popup{display:flex;flex-direction:column;gap:2px}
.pt-popup-judul{font-size:12px}
.pt-popup-baris{display:flex;align-items:center;gap:10px;width:100%;padding:6px 4px;background:none;border:none;border-radius:8px;font:inherit;color:inherit;text-align:left;cursor:pointer}
.pt-popup-baris:focus-visible{outline:3px solid var(--ui-muted,#8a8f98);outline-offset:-3px}
.pt-popup-info{display:flex;flex-direction:column;align-items:flex-start;gap:1px;min-width:0;font-size:12px;line-height:16px}
.pt-popup-info strong{font-weight:700}
.pt-popup-jam{color:#6b7280;white-space:normal}
.pt-foto-popup{display:flex;align-items:center;justify-content:center;flex:none;position:relative;width:40px;height:40px;border-radius:50%;border:3px solid #16803c;background:#e5e7eb;color:#111827;font-weight:700;font-size:12px;overflow:hidden}
.pt-foto-popup img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;display:block}

.inv-peta-detail .inv-peta-list{display:flex;flex-direction:column;gap:8px}
/* PT9: chip membungkus di HP; jumlah nol tetap dapat dipilih. */
/* PT10: cari satu sumber hasil untuk peta, tabel, dan Print. */
.pt-cari{display:flex;align-items:center;gap:6px;flex:1 1 auto;min-width:0;max-width:100%}
.pt-cari label{margin:0;font-size:12px}
.ui-shell .pt-cari input{flex:1;min-width:0;width:100%;min-height:40px;margin:0;font-size:12px}
.peta-tukang-page .pt-hapus-cari{flex:none;min-height:40px;padding:6px 10px;background:#f3f4f6;color:#111827;border:1px solid #d1d5db;border-radius:6px;font-size:18px}
.pt-cari input::-webkit-search-cancel-button{display:none}
.pt-luar-kontrol[hidden]{display:none}
.peta-tukang-page .pt-luar-tombol{display:block;min-height:36px;padding:6px 10px;border:0;border-radius:2px;background:#b91c1c;color:#fff;font-size:12px;font-weight:700}
.peta-tukang-page .pt-luar-tombol:hover{background:#991b1b;color:#fff}
.peta-tukang-page .pt-luar-tombol[aria-pressed=true]{background:#7f1d1d;outline:2px solid #fff;outline-offset:-4px}
.pt-luar-tombol:focus-visible,.pt-hapus-cari:focus-visible{outline:3px solid #2563eb;outline-offset:2px}
.pt-popup-keterangan{white-space:normal;color:#92400e}
.pt-abu{--pt-warna:#737373}
.pt-badge-abu{background:#737373}
.pt-badge-kosong{background:#fff;color:#737373;border:2px solid #737373}
/* PT17: panel kanan kelompok setinggi peta, isi bergulir sendiri; <=800px panel di bawah peta. */
.peta-tukang-page .inv-peta-layout{grid-template-columns:minmax(0,1fr) 340px}
.pt-panel{display:flex;flex-direction:column;min-width:0;height:540px;box-sizing:border-box;border:1px solid var(--ui-border,#ddd);border-radius:6px;background:var(--ui-panel,#fff);overflow:hidden}
.pt-panel-kepala{display:flex;align-items:center;gap:8px;padding:10px 12px;border-bottom:1px solid var(--ui-line,#e5e5e5)}
.peta-tukang-page .pt-tutup-semua{flex:none;min-height:0;padding:4px 2px;border:0;background:none;color:var(--ui-info,#4a6683);font-size:12px;font-weight:400;text-decoration:underline;white-space:nowrap}
.peta-tukang-page .pt-tutup-semua:hover{background:none;color:var(--ui-text,#202020)}
.pt-tutup-semua[hidden]{display:none}
.pt-panel-isi{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain}
.pt-kelompok{border-bottom:1px solid var(--ui-line,#e5e5e5)}
.peta-tukang-page .pt-kelompok-judul{display:flex;align-items:center;gap:8px;width:100%;min-height:40px;padding:8px 12px;border:0;border-radius:0;background:none;color:var(--ui-text,#202020);font-size:13px;font-weight:600;text-align:left}
.peta-tukang-page .pt-kelompok-judul:hover{background:var(--ui-hover,#f1f1f1);color:var(--ui-text,#202020)}
.peta-tukang-page .pt-kelompok-judul[aria-expanded=true]{background:var(--ui-info-bg,#edf1f5)}
.peta-tukang-page .pt-kelompok-judul:disabled{background:none;cursor:default}
.pt-kelompok-judul:focus-visible,.pt-panel-baris:focus-visible,.pt-tutup-semua:focus-visible{outline:3px solid var(--ui-muted,#8a8f98);outline-offset:-3px}
.pt-kelompok-panah{flex:none;width:12px;color:var(--ui-muted,#777);transition:transform .15s}
.pt-kelompok-judul[aria-expanded=true] .pt-kelompok-panah{transform:rotate(90deg)}
.pt-kelompok-label{flex:1;min-width:0}
.pt-kelompok-n{flex:none;min-width:28px;padding:1px 8px;box-sizing:border-box;border-radius:999px;text-align:center;font-size:12px;line-height:18px}
.pt-n-merah{background:#dc2626;color:#fff}.pt-n-oranye{background:#f97316;color:#111827}.pt-n-abu{background:#737373;color:#fff}
.pt-kelompok-daftar{list-style:none;margin:0;padding:0 0 6px}
.peta-tukang-page .pt-panel-baris{display:flex;align-items:center;gap:10px;width:100%;min-height:0;box-sizing:border-box;padding:6px 12px 6px 32px;border:0;border-radius:0;background:none;color:var(--ui-text,#202020);font-weight:400;text-align:left}
.peta-tukang-page button.pt-panel-baris:hover{background:var(--ui-hover,#f1f1f1);color:var(--ui-text,#202020)}
.peta-tukang-page .pt-panel-baris.pt-selected{outline:0;background:var(--ui-info-bg,#edf1f5);box-shadow:inset 3px 0 0 #2563eb}
.pt-foto-panel{width:28px;height:28px;border-width:2px;font-size:10px;flex:none}
.pt-panel-info{display:flex;flex-direction:column;min-width:0;font-size:12px;line-height:16px}
.pt-panel-nama{font-weight:600;overflow-wrap:anywhere}
.pt-panel-ket{color:var(--ui-muted-text,#707070);overflow-wrap:anywhere}
.pt-panel-catatan{padding:4px 12px 4px 32px;color:var(--ui-muted-text,#707070);font-size:12px}
.pt-pemisah{padding:6px 12px;border-bottom:1px solid var(--ui-line,#e5e5e5);background:var(--ui-table-head,#fbfbfb);color:var(--ui-muted-text,#707070);font-size:11px;letter-spacing:.06em;text-transform:uppercase}
@media(max-width:800px){.peta-tukang-page .inv-peta-layout{grid-template-columns:minmax(0,1fr)}.pt-panel{height:auto;max-height:520px}}

/* TL1 2 Nov: di layar lebar halaman yang bergulir; baris grup menempel di bawah kepala tabel yang menempel di bawah topbar. */
@media(min-width:1400px){.ui-shell .peta-tukang-page .pt-tabel-wrap:not(:has(table.ui-sized)){--pt-kepala:calc(var(--ui-sticky-top) + 64px)}}
