/* Font lokal (Plus Jakarta Sans, variable) — tidak lagi ambil dari fonts.googleapis.com */
@font-face{font-family:'Plus Jakarta Sans';font-style:normal;font-weight:200 800;font-display:swap;src:url('/assets/fonts/pjs-var.woff2') format('woff2');}

/* ============================================================
   Ojol Nusantara — Design System (Light Modern)
   ============================================================ */
:root {
  --green: #00A651;
  --green-600: #008F45;
  --green-700: #00753C;
  --green-900: #0B3D24;
  --green-50: #E9F8F0;
  --green-100: #D2F0E1;
  --amber: #FFB020;
  --orange: #FF7A00;
  --red: #EF4444;
  --blue: #2563EB;
  --violet: #7C3AED;
  --ink: #0F172A;
  --ink-2: #334155;
  --muted: #64748B;
  --line: #E2E8F0;
  --bg: #F4F7F9;
  --card: #FFFFFF;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(15,23,42,.06), 0 1px 3px rgba(15,23,42,.05);
  --shadow: 0 4px 14px rgba(15,23,42,.07);
  --shadow-lg: 0 18px 40px rgba(15,23,42,.14);
  --font: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  font-size: 14px;
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font-family: inherit; font-size: inherit; }
button { cursor: pointer; border: none; background: none; }
img { max-width: 100%; display: block; }

/* ---------- scrollbar ---------- */
::-webkit-scrollbar { width: 9px; height: 9px; }
::-webkit-scrollbar-thumb { background: #CBD5E1; border-radius: 20px; }
::-webkit-scrollbar-thumb:hover { background: #94A3B8; }
::-webkit-scrollbar-track { background: transparent; }

/* ---------- typography ---------- */
.h1 { font-size: 26px; font-weight: 800; letter-spacing: -.4px; }
.h2 { font-size: 20px; font-weight: 800; letter-spacing: -.3px; }
.h3 { font-size: 16px; font-weight: 700; }
.sub { color: var(--muted); font-size: 13px; }
.tiny { font-size: 11px; }
.bold { font-weight: 700; }
.center { text-align: center; }
.mono { font-variant-numeric: tabular-nums; }

/* ---------- layout ---------- */
.row { display: flex; align-items: center; }
.row.between { justify-content: space-between; }
.row.gap6 { gap: 6px; } .row.gap8 { gap: 8px; } .row.gap10 { gap: 10px; } .row.gap12 { gap: 12px; }
.col { display: flex; flex-direction: column; }
.grid { display: grid; }
.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.hidden { display: none !important; }
.ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- card ---------- */
.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--line);
}
.card.pad { padding: 18px; }
.card-title { font-weight: 800; font-size: 15px; }
.pad { padding: 18px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 18px; border-radius: 12px; font-weight: 700; font-size: 13.5px;
  background: #F1F5F9; color: var(--ink-2); transition: .16s; white-space: nowrap;
  border: 1px solid transparent;
}
.btn:hover { filter: brightness(.97); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--green); color: #fff; box-shadow: 0 6px 16px rgba(0,166,81,.28); }
.btn.primary:hover { background: var(--green-600); }
.btn.dark { background: var(--ink); color: #fff; }
.btn.outline { background: #fff; border-color: var(--line); color: var(--ink-2); }
.btn.outline:hover { border-color: var(--green); color: var(--green-700); }
.btn.danger { background: #FEF2F2; color: var(--red); border-color: #FECACA; }
.btn.danger:hover { background: var(--red); color: #fff; }
.btn.ghost { background: transparent; color: var(--muted); }
.btn.sm { padding: 7px 12px; font-size: 12px; border-radius: 9px; }
.btn.lg { padding: 14px 22px; font-size: 15px; }
.btn.block { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

/* ---------- badges ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 10px; border-radius: 999px; font-size: 11px; font-weight: 700;
  background: #F1F5F9; color: var(--ink-2);
}
.badge.green { background: var(--green-50); color: var(--green-700); }
.badge.amber { background: #FFF7E6; color: #B45309; }
.badge.red { background: #FEF2F2; color: #B91C1C; }
.badge.blue { background: #EFF6FF; color: #1D4ED8; }
.badge.violet { background: #F5F3FF; color: #6D28D9; }
.badge.gray { background: #F1F5F9; color: #475569; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; display: inline-block; }

/* ---------- form ---------- */
.field { display: block; margin-bottom: 14px; }
.field > label { display: block; font-size: 12px; font-weight: 700; color: var(--ink-2); margin-bottom: 6px; }
.input, .select, .textarea {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px;
  background: #fff; color: var(--ink); outline: none; transition: .16s;
}
.input:focus, .select:focus, .textarea:focus { border-color: var(--green); box-shadow: 0 0 0 3px rgba(0,166,81,.12); }
.input::placeholder { color: #94A3B8; }
.textarea { min-height: 78px; resize: vertical; }
.input-group { position: relative; }
.input-group .ic { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: #94A3B8; font-size: 15px; }
.input-group .input { padding-left: 40px; }

/* ---------- table ---------- */
.table-wrap { overflow-x: auto; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 13px; }
table.tbl th {
  text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .5px;
  color: var(--muted); font-weight: 700; padding: 11px 14px; border-bottom: 1px solid var(--line);
  background: #FAFCFD; white-space: nowrap;
}
table.tbl td { padding: 12px 14px; border-bottom: 1px solid #F1F5F9; vertical-align: middle; }
table.tbl tbody tr:hover { background: #FAFCFD; }
table.tbl tr:last-child td { border-bottom: none; }

/* ---------- avatar ---------- */
.avatar {
  width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center;
  background: var(--green-50); color: var(--green-700); font-weight: 800; font-size: 14px;
  flex: 0 0 auto; overflow: hidden;
}
.avatar.round { border-radius: 50%; }
.avatar.lg { width: 58px; height: 58px; font-size: 20px; border-radius: 18px; }
.avatar.sm { width: 30px; height: 30px; font-size: 11px; border-radius: 9px; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- misc ---------- */
.divider { height: 1px; background: var(--line); margin: 14px 0; }
.pill-tabs { display: flex; gap: 6px; background: #F1F5F9; padding: 4px; border-radius: 12px; }
.pill-tabs button { flex: 1; padding: 8px 12px; border-radius: 9px; font-weight: 700; font-size: 12.5px; color: var(--muted); }
.pill-tabs button.active { background: #fff; color: var(--green-700); box-shadow: var(--shadow-sm); }
.skeleton { background: linear-gradient(90deg,#EEF2F6 25%,#F7FAFC 50%,#EEF2F6 75%); background-size: 200% 100%; animation: sk 1.3s infinite; border-radius: 10px; }
@keyframes sk { 0%{background-position:200% 0} 100%{background-position:-200% 0} }
.spin { width: 18px; height: 18px; border: 2.5px solid rgba(255,255,255,.35); border-top-color: #fff; border-radius: 50%; animation: sp .7s linear infinite; }
@keyframes sp { to { transform: rotate(360deg); } }
.fade-in { animation: fade .28s ease both; }
@keyframes fade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.pop { animation: pop .22s cubic-bezier(.2,1.3,.5,1) both; }
@keyframes pop { from { opacity: 0; transform: scale(.94); } to { opacity: 1; transform: none; } }

/* ---------- toast ---------- */
#ojol-toast { position: fixed; top: 18px; left: 50%; transform: translateX(-50%); z-index: 99999; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: max-content; max-width: 92vw; }
.toast {
  background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--green);
  padding: 12px 18px; border-radius: 12px; box-shadow: var(--shadow-lg); font-weight: 600; font-size: 13px;
  animation: tst .3s ease both; max-width: 92vw;
}
.toast.err { border-left-color: var(--red); }
.toast.info { border-left-color: var(--blue); }
@keyframes tst { from { opacity: 0; transform: translateY(-12px); } to { opacity: 1; transform: none; } }

/* ---------- modal ---------- */
.modal-wrap { position: fixed; inset: 0; background: rgba(15,23,42,.55); backdrop-filter: blur(3px); z-index: 9999; display: flex; align-items: center; justify-content: center; padding: 18px; }
.modal { background: #fff; border-radius: 20px; box-shadow: var(--shadow-lg); width: 100%; max-width: 460px; max-height: 90vh; overflow: auto; animation: pop .22s ease both; }
.modal .modal-head { padding: 18px 20px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; }
.modal .modal-body { padding: 20px; }
.modal .modal-foot { padding: 16px 20px; border-top: 1px solid var(--line); display: flex; gap: 10px; justify-content: flex-end; }
.x-btn { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: var(--muted); font-size: 17px; }
.x-btn:hover { background: #F1F5F9; color: var(--ink); }

/* ---------- stat card ---------- */
.stat-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow-sm); }
.stat-card .ic { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; font-size: 19px; }
.stat-card .val { font-size: 24px; font-weight: 800; letter-spacing: -.6px; }
.stat-card .lbl { font-size: 12px; color: var(--muted); font-weight: 600; }
.trend-up { color: #059669; font-size: 11.5px; font-weight: 700; }
.trend-down { color: var(--red); font-size: 11.5px; font-weight: 700; }

/* ---------- map ---------- */
.ojol-map { position: relative; background: #E8F1EA; border-radius: var(--radius); overflow: hidden; }
.ojol-map svg { display: block; width: 100%; height: 100%; }
.map-pin { position: absolute; transform: translate(-50%,-100%); background: var(--green); color: #fff; padding: 4px 9px; border-radius: 9px; font-size: 10.5px; font-weight: 800; box-shadow: var(--shadow); white-space: nowrap; }
.map-pin::after { content: ''; position: absolute; left: 50%; bottom: -5px; transform: translateX(-50%); border: 5px solid transparent; border-top-color: var(--green); border-bottom: 0; }
.map-pin.blue { background: var(--blue); } .map-pin.blue::after { border-top-color: var(--blue); }
.map-pin.orange { background: var(--orange); } .map-pin.orange::after { border-top-color: var(--orange); }
.map-ctrls { position: absolute; right: 12px; bottom: 12px; display: flex; flex-direction: column; gap: 6px; }
.map-ctrls button { width: 38px; height: 38px; border-radius: 11px; background: #fff; box-shadow: var(--shadow); display: grid; place-items: center; font-size: 16px; color: var(--ink-2); }
.map-ctrls button:hover { color: var(--green); }
.map-legend { position: absolute; left: 12px; bottom: 12px; background: rgba(255,255,255,.95); border-radius: 11px; padding: 9px 12px; box-shadow: var(--shadow-sm); font-size: 11px; font-weight: 600; display: flex; gap: 12px; flex-wrap: wrap; }
.map-legend i { width: 9px; height: 9px; border-radius: 50%; display: inline-block; margin-right: 5px; }

@media (max-width: 720px) {
  .hide-sm { display: none !important; }
}
