/* BEDESA PRO - PetaKit (assets/js/peta_kit.js): gaya kontrol, pin, legenda & layar penuh */
.pk-wadah { position: relative; }
.pk-wadah.pk-penuh { position: fixed !important; inset: 0 !important; z-index: 2147482000 !important; margin: 0 !important; border-radius: 0 !important; background: #fff; padding: 0 !important; }
.pk-wadah.pk-penuh > .leaflet-container, .pk-wadah.pk-penuh .pk-peta { height: 100% !important; width: 100% !important; border-radius: 0 !important; border: 0 !important; }
html.pk-kunci, html.pk-kunci body { overflow: hidden !important; }

.pk-btn a { display: grid !important; place-items: center; width: 34px !important; height: 34px !important; line-height: 1 !important; color: #334155 !important; font-size: 14px; }
.pk-btn a:hover { color: #0f172a !important; background: #f8fafc !important; }
.pk-btn a.pk-muat i { animation: pkPutar 1s linear infinite; }
@keyframes pkPutar { to { transform: rotate(360deg); } }
.leaflet-touch .leaflet-bar a { width: 34px; height: 34px; line-height: 34px; }
.leaflet-bar { border: 0 !important; box-shadow: 0 4px 14px rgba(15, 23, 42, .18) !important; border-radius: 10px !important; overflow: hidden; }
.leaflet-control-layers { border: 0 !important; border-radius: 12px !important; box-shadow: 0 6px 18px rgba(15, 23, 42, .18) !important; }
.leaflet-control-layers-expanded { padding: 10px 12px !important; font-size: 12.5px; }
.leaflet-control-layers label { margin: 2px 0; }
.pk-li { width: 18px; text-align: center; color: #64748b; margin: 0 4px 0 2px; }
.leaflet-control-scale-line { border-radius: 4px; background: rgba(255, 255, 255, .85); }

.pk-pin { background: none; border: 0; }
.pk-pin-b { display: grid; place-items: center; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); background: var(--c, #2563eb);
    border: 2px solid #fff; box-shadow: 0 4px 10px rgba(15, 23, 42, .35); transition: transform .2s; }
.pk-pin-b i { transform: rotate(45deg); color: #fff; font-size: 13px; }
.leaflet-marker-icon.pk-pin:hover .pk-pin-b { transform: rotate(-45deg) scale(1.12); }
.pk-pin-l { position: absolute; left: 50%; top: calc(100% + 3px); transform: translateX(-50%); white-space: nowrap; font: 700 10.5px/1.2 inherit;
    color: #0f172a; background: rgba(255, 255, 255, .92); padding: 2px 6px; border-radius: 6px; box-shadow: 0 1px 4px rgba(0, 0, 0, .18); pointer-events: none; }

.pk-desa { background: none; border: 0; }
.pk-desa-b { position: absolute; inset: 3px; border-radius: 50%; background: #fff; border: 3px solid #fff; box-shadow: 0 4px 14px rgba(0, 0, 0, .35);
    display: grid; place-items: center; overflow: hidden; color: #dc2626; font-size: 18px; }
.leaflet-container .leaflet-marker-pane .pk-desa-b img { width: 100% !important; height: 100% !important; object-fit: contain; border-radius: 50%; }
.pk-desa-r { position: absolute; inset: 0; border-radius: 50%; background: rgba(220, 38, 38, .35); animation: pkDenyut 2.2s ease-out infinite; }
@keyframes pkDenyut { 0% { transform: scale(.7); opacity: .9; } 100% { transform: scale(2.1); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .pk-desa-r { animation: none; display: none; } }

.pk-legenda { background: rgba(255, 255, 255, .96); border-radius: 12px; box-shadow: 0 6px 18px rgba(15, 23, 42, .18); min-width: 170px; max-width: 230px; overflow: hidden; font-size: 12px; }
.pk-legenda-h { width: 100%; display: flex; align-items: center; gap: 8px; border: 0; background: #0f172a; color: #fff; font-weight: 700; font-size: 12px; padding: 7px 11px; cursor: pointer; }
.pk-legenda-h span { flex: 1; text-align: left; }
.pk-legenda .pk-cv { transition: transform .2s; font-size: 10px; }
.pk-legenda.tutup .pk-cv { transform: rotate(-90deg); }
.pk-legenda.tutup .pk-legenda-b { display: none; }
.pk-legenda-b { padding: 8px 10px; max-height: 260px; overflow-y: auto; }
.pk-legenda-r { display: flex; align-items: center; gap: 8px; padding: 3px 0; color: #334155; font-weight: 600; }
.pk-legenda-r span:nth-child(2) { flex: 1; }
.pk-legenda-r b { font-size: 11px; color: #64748b; font-variant-numeric: tabular-nums; }
.pk-legenda-i { width: 20px; height: 20px; border-radius: 6px; display: grid; place-items: center; background: var(--c); color: #fff; font-size: 10px; flex-shrink: 0; }

.pk-tip { font-weight: 700; font-size: 12px; border-radius: 8px; }
.pk-toast { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 1000; background: #0f172a; color: #fff; font-size: 12px; padding: 8px 14px; border-radius: 10px; box-shadow: 0 6px 18px rgba(0,0,0,.25); transition: opacity .4s; max-width: 90%; text-align: center; }
.pk-toast.hilang { opacity: 0; }

/* Popup modern bersama */
.pk-popup .leaflet-popup-content-wrapper { border-radius: 14px; padding: 0; overflow: hidden; box-shadow: 0 10px 28px rgba(15, 23, 42, .25); }
.pk-popup .leaflet-popup-content { margin: 0; width: auto !important; min-width: 210px; }
.pk-pop { font-size: 12px; color: #334155; }
.pk-pop-h { padding: 10px 12px; color: #fff; background: var(--c, #2563eb); display: flex; gap: 10px; align-items: center; }
.pk-pop-h i { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: rgba(255, 255, 255, .2); font-size: 13px; flex-shrink: 0; }
.pk-pop-h b { display: block; font-size: 13.5px; line-height: 1.25; } .pk-pop-h small { display: block; opacity: .85; font-size: 11px; }
.pk-pop-b { padding: 9px 12px 12px; }
.pk-pop-r { display: flex; justify-content: space-between; gap: 10px; padding: 4px 0; border-bottom: 1px dashed #eef2f7; }
.pk-pop-r:last-child { border-bottom: 0; } .pk-pop-r span { color: #64748b; } .pk-pop-r b { color: #0f172a; text-align: right; }
.pk-pop-a { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }
.pk-pop-a a { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 700; text-decoration: none; border-radius: 8px; padding: 5px 9px; background: #2563eb; color: #fff !important; }
.pk-pop-a a.sek { background: #f1f5f9; color: #334155 !important; }
