596 lines
13 KiB
CSS
596 lines
13 KiB
CSS
/* ============================================================
|
|
style.css — WebGIS SPBU Pontianak
|
|
============================================================ */
|
|
|
|
/* ── CSS VARIABLES ── */
|
|
:root {
|
|
--bg: #0f1117;
|
|
--panel: #1a1d27;
|
|
--border: #2a2d3a;
|
|
--accent: #4ade80;
|
|
--accent2: #38bdf8;
|
|
--danger: #f87171;
|
|
--text: #e2e8f0;
|
|
--muted: #64748b;
|
|
--header-h: 56px;
|
|
}
|
|
|
|
/* ── RESET ── */
|
|
*, *::before, *::after {
|
|
box-sizing: border-box;
|
|
margin: 0;
|
|
padding: 0;
|
|
}
|
|
|
|
/* ── BASE ── */
|
|
body {
|
|
font-family: 'DM Sans', sans-serif;
|
|
background: var(--bg);
|
|
color: var(--text);
|
|
height: 100vh;
|
|
display: flex;
|
|
flex-direction: column;
|
|
overflow: hidden;
|
|
}
|
|
|
|
/* ============================================================
|
|
HEADER
|
|
============================================================ */
|
|
header {
|
|
height: var(--header-h);
|
|
background: var(--panel);
|
|
border-bottom: 1px solid var(--border);
|
|
display: flex;
|
|
align-items: center;
|
|
padding: 0 20px;
|
|
gap: 16px;
|
|
z-index: 1000;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.logo {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 10px;
|
|
}
|
|
|
|
.logo-icon {
|
|
width: 32px;
|
|
height: 32px;
|
|
background: var(--accent);
|
|
border-radius: 8px;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
font-size: 16px;
|
|
}
|
|
|
|
.logo-text {
|
|
font-family: 'Space Mono', monospace;
|
|
font-size: 13px;
|
|
font-weight: 700;
|
|
letter-spacing: 0.05em;
|
|
color: var(--text);
|
|
}
|
|
|
|
.logo-text span {
|
|
color: var(--accent);
|
|
}
|
|
|
|
.header-divider {
|
|
width: 1px;
|
|
height: 28px;
|
|
background: var(--border);
|
|
margin: 0 4px;
|
|
}
|
|
|
|
/* ── LEGEND ── */
|
|
.legend {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 16px;
|
|
margin-left: auto;
|
|
}
|
|
|
|
.legend-item {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 6px;
|
|
font-size: 12px;
|
|
color: var(--muted);
|
|
}
|
|
|
|
.legend-dot {
|
|
width: 10px;
|
|
height: 10px;
|
|
border-radius: 50%;
|
|
}
|
|
|
|
.legend-line {
|
|
width: 20px;
|
|
height: 3px;
|
|
border-radius: 2px;
|
|
}
|
|
|
|
.legend-poly {
|
|
width: 14px;
|
|
height: 10px;
|
|
border-radius: 2px;
|
|
opacity: 0.7;
|
|
}
|
|
|
|
/* ── LAYER CONTROL ── */
|
|
.layer-control {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 6px;
|
|
margin-left: 8px;
|
|
}
|
|
|
|
.layer-btn {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 7px;
|
|
padding: 5px 12px;
|
|
border-radius: 99px;
|
|
border: 1.5px solid var(--border);
|
|
background: var(--panel);
|
|
color: var(--muted);
|
|
font-family: 'DM Sans', sans-serif;
|
|
font-size: 12px;
|
|
font-weight: 500;
|
|
cursor: pointer;
|
|
transition: all .18s;
|
|
user-select: none;
|
|
}
|
|
|
|
.layer-btn .dot {
|
|
width: 9px;
|
|
height: 9px;
|
|
border-radius: 50%;
|
|
flex-shrink: 0;
|
|
transition: opacity .18s;
|
|
}
|
|
|
|
.layer-btn.active {
|
|
color: var(--text);
|
|
border-color: transparent;
|
|
}
|
|
|
|
.layer-btn.active.btn-24 { background: #064e3b; border-color: #4ade80; color: #4ade80; }
|
|
.layer-btn.active.btn-tidak { background: #450a0a; border-color: #f87171; color: #f87171; }
|
|
|
|
.layer-btn:not(.active) .dot {
|
|
opacity: 0.3;
|
|
}
|
|
|
|
.layer-sep {
|
|
width: 1px;
|
|
height: 22px;
|
|
background: var(--border);
|
|
margin: 0 2px;
|
|
}
|
|
|
|
/* ============================================================
|
|
MAP
|
|
============================================================ */
|
|
#map {
|
|
flex: 1;
|
|
width: 100%;
|
|
}
|
|
|
|
/* ============================================================
|
|
POPUP FORM (input saat tambah data)
|
|
============================================================ */
|
|
.pf {
|
|
font-family: 'DM Sans', sans-serif;
|
|
width: 230px;
|
|
background: #1e2130;
|
|
border-radius: 10px;
|
|
overflow: hidden;
|
|
box-shadow: 0 8px 32px rgba(0, 0, 0, .5);
|
|
}
|
|
|
|
.pf-head {
|
|
padding: 10px 14px;
|
|
font-size: 12px;
|
|
font-weight: 600;
|
|
letter-spacing: .06em;
|
|
text-transform: uppercase;
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 8px;
|
|
}
|
|
|
|
.pf-head-point { background: linear-gradient(135deg, #1d4ed8, #3b82f6); color: #fff; }
|
|
.pf-head-line { background: linear-gradient(135deg, #7c3aed, #a855f7); color: #fff; }
|
|
.pf-head-polygon { background: linear-gradient(135deg, #065f46, #10b981); color: #fff; }
|
|
|
|
.pf-body {
|
|
padding: 12px 14px;
|
|
}
|
|
|
|
.pf-body label {
|
|
display: block;
|
|
font-size: 11px;
|
|
color: #94a3b8;
|
|
margin-bottom: 3px;
|
|
margin-top: 8px;
|
|
font-weight: 500;
|
|
}
|
|
|
|
.pf-body label:first-child {
|
|
margin-top: 0;
|
|
}
|
|
|
|
.pf-body input,
|
|
.pf-body select {
|
|
width: 100%;
|
|
background: #0f1117;
|
|
border: 1px solid #2a2d3a;
|
|
color: #e2e8f0;
|
|
border-radius: 6px;
|
|
padding: 7px 10px;
|
|
font-size: 13px;
|
|
font-family: 'DM Sans', sans-serif;
|
|
outline: none;
|
|
transition: border .15s;
|
|
}
|
|
|
|
.pf-body input:focus,
|
|
.pf-body select:focus {
|
|
border-color: #4ade80;
|
|
}
|
|
|
|
.pf-body select option {
|
|
background: #1a1d27;
|
|
}
|
|
|
|
.pf-info {
|
|
margin-top: 8px;
|
|
padding: 6px 10px;
|
|
background: #0f1117;
|
|
border-radius: 6px;
|
|
font-size: 12px;
|
|
color: #94a3b8;
|
|
font-family: 'Space Mono', monospace;
|
|
}
|
|
|
|
.pf-btn {
|
|
display: block;
|
|
width: 100%;
|
|
margin-top: 12px;
|
|
padding: 9px;
|
|
background: #4ade80;
|
|
color: #0f1117;
|
|
border: none;
|
|
border-radius: 7px;
|
|
font-size: 13px;
|
|
font-weight: 600;
|
|
font-family: 'DM Sans', sans-serif;
|
|
cursor: pointer;
|
|
transition: background .15s, transform .1s;
|
|
}
|
|
|
|
.pf-btn:hover { background: #22c55e; transform: translateY(-1px); }
|
|
.pf-btn:active { transform: translateY(0); }
|
|
|
|
/* ============================================================
|
|
INFO POPUP (tampil data dari DB)
|
|
============================================================ */
|
|
.ip {
|
|
font-family: 'DM Sans', sans-serif;
|
|
min-width: 190px;
|
|
background: #1e2130;
|
|
border-radius: 10px;
|
|
overflow: hidden;
|
|
box-shadow: 0 8px 32px rgba(0, 0, 0, .5);
|
|
}
|
|
|
|
.ip-head {
|
|
padding: 10px 14px;
|
|
font-size: 12px;
|
|
font-weight: 700;
|
|
letter-spacing: .04em;
|
|
color: #fff;
|
|
}
|
|
|
|
.ip-body {
|
|
padding: 10px 14px;
|
|
}
|
|
|
|
.ip-row {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
padding: 4px 0;
|
|
border-bottom: 1px solid #2a2d3a;
|
|
font-size: 12px;
|
|
}
|
|
|
|
.ip-row:last-of-type { border-bottom: none; }
|
|
|
|
.ip-label { color: #64748b; }
|
|
.ip-val { color: #e2e8f0; font-weight: 500; }
|
|
|
|
/* ── BADGES ── */
|
|
.ip-badge {
|
|
display: inline-block;
|
|
padding: 2px 8px;
|
|
border-radius: 99px;
|
|
font-size: 11px;
|
|
font-weight: 600;
|
|
}
|
|
|
|
.badge-green { background: #064e3b; color: #4ade80; }
|
|
.badge-red { background: #450a0a; color: #f87171; }
|
|
.badge-blue { background: #0c1a4a; color: #38bdf8; }
|
|
.badge-gray { background: #1e293b; color: #94a3b8; }
|
|
|
|
/* ── DELETE BUTTON ── */
|
|
.ip-del {
|
|
display: block;
|
|
width: 100%;
|
|
margin-top: 10px;
|
|
padding: 7px;
|
|
background: transparent;
|
|
border: 1px solid #f87171;
|
|
color: #f87171;
|
|
border-radius: 6px;
|
|
font-size: 12px;
|
|
font-weight: 600;
|
|
cursor: pointer;
|
|
transition: all .15s;
|
|
}
|
|
|
|
.ip-del:hover { background: #f87171; color: #0f1117; }
|
|
|
|
/* ============================================================
|
|
LEAFLET OVERRIDES
|
|
============================================================ */
|
|
.leaflet-popup-content-wrapper {
|
|
background: transparent !important;
|
|
border-radius: 10px !important;
|
|
box-shadow: none !important;
|
|
padding: 0 !important;
|
|
}
|
|
|
|
.leaflet-popup-content {
|
|
margin: 0 !important;
|
|
line-height: 1 !important;
|
|
}
|
|
|
|
.leaflet-popup-tip-container { display: none; }
|
|
|
|
/* Draw toolbar */
|
|
.leaflet-draw-toolbar a,
|
|
.leaflet-bar a {
|
|
background-color: #1a1d27 !important;
|
|
border-color: #2a2d3a !important;
|
|
color: #e2e8f0 !important;
|
|
}
|
|
|
|
.leaflet-bar a:hover {
|
|
background-color: #2a2d3a !important;
|
|
}
|
|
|
|
.leaflet-draw-toolbar .leaflet-draw-draw-marker,
|
|
.leaflet-draw-toolbar .leaflet-draw-draw-polyline,
|
|
.leaflet-draw-toolbar .leaflet-draw-draw-polygon {
|
|
filter: invert(1) brightness(0.8);
|
|
}
|
|
|
|
/* ============================================================
|
|
MASJID & PENDUDUK MISKIN
|
|
============================================================ */
|
|
|
|
/* Header subtitle kecil */
|
|
.header-sub {
|
|
font-size: 11px;
|
|
color: var(--muted);
|
|
}
|
|
|
|
/* Radius slider di popup */
|
|
.radius-slider-wrap {
|
|
margin-top: 8px;
|
|
}
|
|
|
|
.radius-slider-wrap input[type=range] {
|
|
width: 100%;
|
|
accent-color: #f59e0b;
|
|
cursor: pointer;
|
|
}
|
|
|
|
.radius-val {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
font-size: 11px;
|
|
color: #94a3b8;
|
|
margin-top: 2px;
|
|
font-family: 'Space Mono', monospace;
|
|
}
|
|
|
|
/* Badge masjid */
|
|
.badge-amber { background: #451a03; color: #f59e0b; }
|
|
.badge-orange { background: #431407; color: #fb923c; }
|
|
|
|
/* Warna marker penduduk dalam radius */
|
|
.marker-in-radius path {
|
|
fill: #f59e0b !important;
|
|
}
|
|
|
|
/* Panel info radius di pojok kiri bawah */
|
|
.radius-info-panel {
|
|
position: absolute;
|
|
bottom: 30px;
|
|
left: 10px;
|
|
z-index: 900;
|
|
background: var(--panel);
|
|
border: 1px solid var(--border);
|
|
border-radius: 10px;
|
|
padding: 10px 14px;
|
|
font-size: 12px;
|
|
color: var(--text);
|
|
min-width: 200px;
|
|
display: none;
|
|
font-family: 'DM Sans', sans-serif;
|
|
}
|
|
|
|
.radius-info-panel.show { display: block; }
|
|
.radius-info-panel strong { color: #f59e0b; }
|
|
|
|
/* ============================================================
|
|
MODE PANEL (pojok kiri bawah)
|
|
============================================================ */
|
|
.mode-panel-box {
|
|
background: rgba(26, 29, 39, 0.85);
|
|
border: 1px solid rgba(255, 255, 255, 0.1);
|
|
border-radius: 12px;
|
|
padding: 12px 14px;
|
|
font-family: 'DM Sans', sans-serif;
|
|
font-size: 12px;
|
|
color: #94a3b8;
|
|
min-width: 210px;
|
|
box-shadow: 0 8px 32px rgba(0,0,0,.5);
|
|
user-select: none;
|
|
}
|
|
|
|
.mode-panel-box.glass {
|
|
backdrop-filter: blur(12px);
|
|
-webkit-backdrop-filter: blur(12px);
|
|
}
|
|
|
|
.mode-panel-title {
|
|
font-size: 10px;
|
|
color: #64748b;
|
|
margin-bottom: 10px;
|
|
letter-spacing: .08em;
|
|
text-transform: uppercase;
|
|
font-weight: 700;
|
|
}
|
|
|
|
.mode-options {
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 4px;
|
|
}
|
|
|
|
.mode-panel-label {
|
|
position: relative;
|
|
cursor: pointer;
|
|
display: block;
|
|
}
|
|
|
|
.mode-panel-label input[type=radio] {
|
|
position: absolute;
|
|
opacity: 0;
|
|
cursor: pointer;
|
|
}
|
|
|
|
.mode-item {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 10px;
|
|
padding: 8px 10px;
|
|
border-radius: 8px;
|
|
transition: all .2s cubic-bezier(0.4, 0, 0.2, 1);
|
|
border: 1px solid transparent;
|
|
}
|
|
|
|
.mode-panel-label:hover .mode-item {
|
|
background: rgba(255, 255, 255, 0.05);
|
|
color: #e2e8f0;
|
|
}
|
|
|
|
.mode-panel-label input:checked + .mode-item {
|
|
background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(245, 158, 11, 0.05));
|
|
border-color: rgba(245, 158, 11, 0.3);
|
|
color: #f59e0b;
|
|
}
|
|
|
|
.mode-panel-icon {
|
|
font-size: 16px;
|
|
filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
|
|
}
|
|
|
|
/* Pastikan Leaflet control tidak terpotong */
|
|
.leaflet-bottom.leaflet-left {
|
|
z-index: 900 !important;
|
|
margin-bottom: 10px;
|
|
margin-left: 10px;
|
|
}
|
|
|
|
/* ── BACK BUTTON (Kembali ke landing page) ── */
|
|
.back-btn {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
width: 32px;
|
|
height: 32px;
|
|
border-radius: 8px;
|
|
background: var(--border);
|
|
border: 1px solid rgba(255,255,255,0.08);
|
|
color: var(--muted);
|
|
text-decoration: none;
|
|
font-size: 16px;
|
|
font-weight: 700;
|
|
flex-shrink: 0;
|
|
transition: background 0.18s, color 0.18s, transform 0.15s;
|
|
}
|
|
.back-btn:hover {
|
|
background: rgba(255,255,255,0.1);
|
|
color: var(--text);
|
|
transform: translateX(-2px);
|
|
}
|
|
|
|
/* ── ACTIVE STATES untuk Masjid & Penduduk buttons ── */
|
|
.layer-btn.active.btn-masjid { background: #451a03; border-color: #f59e0b; color: #f59e0b; }
|
|
.layer-btn.active.btn-penduduk { background: #3b0764; border-color: #e879f9; color: #e879f9; }
|
|
|
|
/* ── HEATMAP BUTTON ── */
|
|
.layer-btn.active#btnHeatmap { background: #431407; border-color: #f97316; color: #f97316; }
|
|
|
|
/* ── STATS PANEL ── */
|
|
.stat-row {
|
|
display: grid;
|
|
grid-template-columns: repeat(4, 1fr);
|
|
gap: 6px;
|
|
}
|
|
.stat-item {
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
background: #1e2233;
|
|
border-radius: 6px;
|
|
padding: 6px 4px;
|
|
text-align: center;
|
|
}
|
|
.stat-num {
|
|
font-size: 18px;
|
|
font-weight: 700;
|
|
color: #e2e8f0;
|
|
line-height: 1.1;
|
|
}
|
|
.stat-lbl {
|
|
font-size: 9px;
|
|
color: #6b7280;
|
|
margin-top: 2px;
|
|
line-height: 1.2;
|
|
}
|
|
|
|
/* ── BLIND SPOT MARKER PULSE ── */
|
|
@keyframes blindspot-pulse {
|
|
0% { transform: scale(1); opacity: 1; }
|
|
50% { transform: scale(1.4); opacity: 0.7; }
|
|
100% { transform: scale(1); opacity: 1; }
|
|
}
|
|
.blindspot-marker svg {
|
|
animation: blindspot-pulse 1.2s ease-in-out infinite;
|
|
transform-origin: center bottom;
|
|
}
|
|
|
|
/* ── GLASS effect ── */
|
|
.glass {
|
|
backdrop-filter: blur(12px);
|
|
-webkit-backdrop-filter: blur(12px);
|
|
} |