/* ═══════════════════════════════════════════════════════════════
   SafeRoute LA — style.css
   Design: Clean Intelligence — light mode only
   Fonts: Bebas Neue + Outfit + JetBrains Mono
═══════════════════════════════════════════════════════════════ */

:root {
  /* Brand */
  --amber: #f59e0b;
  --amber2: #d97706;
  --red: #ef4444;
  --green: #10b981;
  --violet: #7c3aed;
  --blue: #144491;

  /* Light palette — single theme */
  --bg: #f0f4f9;
  --bg2: #e6eaf2;
  --bg3: #d8dfe9;
  --card: #ffffff;
  --border: rgba(0, 0, 0, .08);
  --bord2: rgba(0, 0, 0, .14);
  --text: #0d1421;
  --text2: #4a5568;
  --text3: #94a3b8;
  --hdr: rgba(255, 255, 255, .97);
  --shadow: 0 2px 12px rgba(0, 0, 0, .09);
  --shadow2: 0 4px 24px rgba(0, 0, 0, .13);

  /* Layout */
  --h: 60px;
  --r: 8px;
  --r2: 14px;
  --t: .18s ease;

  /* Fonts */
  --font-d: 'Bebas Neue', sans-serif;
  --font-b: 'Outfit', sans-serif;
  --font-m: 'JetBrains Mono', monospace;
}

/* ── RESET ────────────────────────────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 14px;
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: var(--font-b);
  background: var(--bg);
  color: var(--text);
  min-height: 100dvh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

::-webkit-scrollbar {
  width: 4px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--bord2);
  border-radius: 4px;
}

button {
  cursor: pointer;
  font-family: var(--font-b);
  border: none;
  outline: none;
  background: none;
}

input,
select {
  font-family: var(--font-b);
  outline: none;
}

img,
svg {
  max-width: 100%;
}

.mono {
  font-family: var(--font-m);
}

/* ── BOOT SCREEN ──────────────────────────────────────────────── */
.boot-screen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity .6s, visibility .6s;
}

.boot-screen.out {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.boot-inner {
  text-align: center;
  padding: 0 20px;
}

.boot-logo {
  display: flex;
  align-items: center;
  gap: 14px;
  justify-content: center;
  margin-bottom: 28px;
}

.boot-icon {
  font-size: 2.6rem;
  color: var(--amber);
  animation: pulse 1.5s infinite;
}

.boot-title {
  font-family: var(--font-d);
  font-size: 2rem;
  letter-spacing: .08em;
  color: var(--text);
}

.boot-title span {
  color: var(--amber);
}

.boot-sub {
  font-family: var(--font-m);
  font-size: .58rem;
  color: var(--text3);
  letter-spacing: .2em;
  margin-top: 3px;
}

.boot-progress {
  max-width: 280px;
  margin: 0 auto;
}

.boot-track {
  height: 3px;
  background: var(--bg3);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 10px;
}

.boot-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--amber), var(--blue));
  border-radius: 3px;
  width: 0;
  transition: width .4s ease;
}

.boot-msg {
  font-family: var(--font-m);
  font-size: .62rem;
  color: var(--text3);
  letter-spacing: .1em;
}

/* ── AUTH MODAL ───────────────────────────────────────────────── */
.auth-overlay {
  position: fixed;
  inset: 0;
  z-index: 8000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(13, 20, 33, .55);
  backdrop-filter: blur(6px);
  padding: 16px;
  overflow-y: auto;
}

.auth-card {
  background: var(--card);
  border: 1px solid var(--bord2);
  border-radius: var(--r2);
  padding: 28px 24px;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow2);
  animation: slideUp .32s cubic-bezier(.16, 1, .3, 1);
  position: relative;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

.auth-hdr {
  text-align: center;
  margin-bottom: 20px;
}

.auth-icon {
  font-size: 2rem;
  color: var(--amber);
  margin-bottom: 8px;
}

.auth-hdr h2 {
  font-family: var(--font-d);
  font-size: 1.7rem;
  color: var(--text);
  letter-spacing: .06em;
}

.auth-hdr h2 span {
  color: var(--amber);
}

.auth-hdr p {
  font-size: .7rem;
  color: var(--text3);
  margin-top: 3px;
  letter-spacing: .1em;
  text-transform: uppercase;
  font-family: var(--font-m);
}

.auth-tabs {
  display: flex;
  background: var(--bg2);
  border-radius: var(--r);
  padding: 3px;
  margin-bottom: 18px;
}

.atab {
  flex: 1;
  padding: 8px;
  font-size: .78rem;
  font-weight: 600;
  color: var(--text3);
  border-radius: 6px;
  transition: all var(--t);
  text-transform: uppercase;
  letter-spacing: .06em;
}

.atab.active {
  background: var(--card);
  color: var(--text);
  box-shadow: 0 1px 4px rgba(0, 0, 0, .1);
}

.auth-form {
  display: none;
}

.auth-form.active {
  display: block;
}

.fg {
  margin-bottom: 12px;
}

.fg label {
  display: block;
  font-size: .68rem;
  font-weight: 600;
  color: var(--text2);
  margin-bottom: 4px;
  letter-spacing: .07em;
  text-transform: uppercase;
}

.fw {
  position: relative;
}

.fw i {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text3);
  font-size: .72rem;
  pointer-events: none;
}

.fw input {
  width: 100%;
  background: var(--bg2);
  border: 1px solid var(--bord2);
  border-radius: var(--r);
  color: var(--text);
  font-size: .83rem;
  padding: 9px 34px 9px 30px;
  transition: border-color var(--t), box-shadow var(--t);
}

.fw input:focus {
  border-color: var(--amber);
  box-shadow: 0 0 0 3px rgba(245, 158, 11, .12);
}

.fw input.err {
  border-color: var(--red);
}

.fw input.ok {
  border-color: var(--green);
}

.eye-tog {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text3);
  font-size: .78rem;
  padding: 3px;
  transition: color var(--t);
}

.eye-tog:hover {
  color: var(--text);
}

.ferr {
  font-size: .68rem;
  color: var(--red);
  display: block;
  margin-top: 3px;
  min-height: 15px;
}

.fg-err {
  background: rgba(239, 68, 68, .08);
  border-radius: var(--r);
  padding: 7px 11px;
  font-size: .72rem;
  color: var(--red);
  margin-bottom: 8px;
}

.frow {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.pw-str {
  margin-top: 5px;
  display: flex;
  align-items: center;
  gap: 7px;
}

.pw-track {
  flex: 1;
  height: 4px;
  background: var(--bg3);
  border-radius: 4px;
  overflow: hidden;
}

.pw-track>div {
  height: 100%;
  border-radius: 4px;
  transition: width .4s, background .4s;
}

#pw-lbl {
  font-size: .65rem;
  font-weight: 600;
}

.auth-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: 100%;
  padding: 11px;
  background: linear-gradient(135deg, var(--blue), #1e5fd4);
  color: #fff;
  border-radius: var(--r);
  font-family: var(--font-d);
  font-size: .95rem;
  letter-spacing: .1em;
  transition: opacity var(--t), transform var(--t);
  margin-top: 4px;
  box-shadow: 0 3px 14px rgba(20, 68, 145, .28);
}

.auth-btn:hover:not(:disabled) {
  opacity: .88;
  transform: translateY(-1px);
}

.auth-btn:disabled {
  opacity: .45;
  cursor: not-allowed;
}

.guest-btn {
  display: block;
  width: 100%;
  padding: 8px;
  margin-top: 9px;
  color: var(--text3);
  font-size: .76rem;
  text-align: center;
  border: 1px solid var(--border);
  border-radius: var(--r);
  transition: all var(--t);
}

.guest-btn:hover {
  color: var(--text);
  border-color: var(--bord2);
  background: var(--bg2);
}

/* ── TOASTS ───────────────────────────────────────────────────── */
#toasts {
  position: fixed;
  bottom: 16px;
  right: 14px;
  z-index: 7000;
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: min(320px, calc(100vw - 28px));
}

.toast {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  background: var(--card);
  border: 1px solid var(--bord2);
  border-left: 3px solid var(--amber);
  border-radius: var(--r);
  padding: 10px 12px;
  font-size: .78rem;
  color: var(--text);
  box-shadow: var(--shadow2);
  animation: tIn .25s ease;
  pointer-events: auto;
}

.toast.t-success {
  border-left-color: var(--green);
}

.toast.t-error {
  border-left-color: var(--red);
}

.toast.t-info {
  border-left-color: var(--blue);
}

.toast.t-out {
  animation: tOut .25s ease forwards;
}

@keyframes tIn {
  from {
    transform: translateX(110%);
    opacity: 0;
  }

  to {
    transform: none;
    opacity: 1;
  }
}

@keyframes tOut {
  to {
    transform: translateX(110%);
    opacity: 0;
  }
}

/* ── GLOBAL LOADER ────────────────────────────────────────────── */
.g-loader {
  position: fixed;
  inset: 0;
  z-index: 6000;
  background: rgba(240, 244, 249, .82);
  backdrop-filter: blur(4px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
}

.gl-ring {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 3px solid var(--bg3);
  border-top-color: var(--blue);
  animation: spin 1s linear infinite;
}

#g-loader-msg {
  font-family: var(--font-m);
  font-size: .62rem;
  color: var(--text2);
  letter-spacing: .12em;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes pulse {

  0%,
  100% {
    opacity: .6;
  }

  50% {
    opacity: 1;
  }
}

/* ── HEADER ───────────────────────────────────────────────────── */
.hdr {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 500;
  background: var(--hdr);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.hdr-inner {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 16px;
  height: var(--h);
  max-width: 100%;
  overflow: hidden;
}

/* Brand */
.hdr-brand {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-shrink: 0;
  color: var(--blue);
  font-size: 1.3rem;
  text-decoration: none;
}

.brand-n {
  font-family: var(--font-d);
  font-size: 1.15rem;
  letter-spacing: .05em;
  color: var(--text);
  line-height: 1;
}

.brand-n span {
  color: var(--blue);
}

.brand-s {
  font-family: var(--font-m);
  font-size: .5rem;
  color: var(--text3);
  letter-spacing: .14em;
  margin-top: 2px;
}

/* Desktop search bar */
.sbar {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 5px;
  background: var(--bg2);
  border: 1px solid var(--bord2);
  border-radius: 99px;
  padding: 4px 6px;
  min-width: 0;
  max-width: 640px;
  transition: box-shadow var(--t), border-color var(--t);
}

.sbar:focus-within {
  box-shadow: 0 0 0 2px rgba(20, 68, 145, .18);
  border-color: var(--blue);
}

.sf {
  flex: 1;
  position: relative;
  min-width: 0;
}

.sdot {
  position: absolute;
  left: 9px;
  top: 50%;
  transform: translateY(-50%);
  width: 7px;
  height: 7px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 1;
}

.od {
  background: var(--green);
  box-shadow: 0 0 4px var(--green);
}

.dd {
  background: var(--amber);
  box-shadow: 0 0 4px var(--amber);
}

.sinp {
  width: 100%;
  background: transparent;
  border: none;
  color: var(--text);
  font-size: .78rem;
  padding: 7px 10px 7px 22px;
}

.sinp::placeholder {
  color: var(--text3);
  font-size: .75rem;
}

.swap-b {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--card);
  border: 1px solid var(--bord2);
  color: var(--text3);
  font-size: .72rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all var(--t);
}

.swap-b:hover {
  color: var(--blue);
  transform: rotate(180deg);
}

.gps-b {
  position: absolute;
  right: 5px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text3);
  font-size: .78rem;
  padding: 3px 5px;
  border-radius: 5px;
  transition: color var(--t);
}

.gps-b:hover {
  color: var(--blue);
}

/* Autocomplete dropdown */
.sdrop {
  position: absolute;
  top: calc(100% + 5px);
  left: 0;
  right: 0;
  background: var(--card);
  border: 1px solid var(--bord2);
  border-radius: var(--r);
  overflow: hidden;
  box-shadow: var(--shadow2);
  display: none;
  z-index: 600;
}

.sdrop.open {
  display: block;
}

.sdrop-item {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 11px;
  font-size: .75rem;
  color: var(--text2);
  cursor: pointer;
  border-bottom: 1px solid var(--border);
  transition: background var(--t);
}

.sdrop-item:last-child {
  border-bottom: none;
}

.sdrop-item:hover {
  background: var(--bg2);
  color: var(--text);
}

.sdrop-item i {
  color: var(--blue);
  font-size: .68rem;
  flex-shrink: 0;
}

/* Analyze button */
.analyze-b {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 16px;
  height: 32px;
  background: linear-gradient(135deg, var(--blue), #1e5fd4);
  color: #fff;
  border-radius: 99px;
  font-family: var(--font-d);
  font-size: .88rem;
  letter-spacing: .09em;
  transition: opacity var(--t), transform var(--t);
  white-space: nowrap;
  box-shadow: 0 2px 10px rgba(20, 68, 145, .28);
}

.analyze-b:hover:not(:disabled) {
  opacity: .88;
  transform: translateY(-1px);
}

.analyze-b:disabled {
  opacity: .4;
  cursor: not-allowed;
}

/* Header right */
.hdr-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.live-tag {
  display: flex;
  align-items: center;
  gap: 5px;
  font-family: var(--font-m);
  font-size: .56rem;
  color: var(--green);
  background: rgba(16, 185, 129, .08);
  border: 1px solid rgba(16, 185, 129, .22);
  border-radius: 99px;
  padding: 3px 8px;
  letter-spacing: .09em;
  white-space: nowrap;
}

.live-tag span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--green);
  animation: pulse 1.5s infinite;
}

.icon-b {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--bg2);
  border: 1px solid var(--bord2);
  color: var(--text2);
  font-size: .85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--t);
  flex-shrink: 0;
}

.icon-b:hover {
  border-color: var(--blue);
  color: var(--blue);
}

/* User chip */
.user-wrap {
  position: relative;
  flex-shrink: 0;
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--bg2);
  border: 1px solid var(--bord2);
  border-radius: 99px;
  padding: 3px 10px 3px 3px;
  color: var(--text2);
  font-size: .75rem;
  transition: all var(--t);
  cursor: pointer;
}

.user-chip:hover {
  border-color: var(--blue);
}

.u-av,
.udd-av {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), #1e5fd4);
  color: #fff;
  font-family: var(--font-d);
  font-size: .7rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.udd-av {
  width: 36px;
  height: 36px;
  font-size: .85rem;
}

/* User dropdown */
.user-dd {
  position: absolute;
  top: calc(100% + 7px);
  right: 0;
  background: var(--card);
  border: 1px solid var(--bord2);
  border-radius: var(--r2);
  padding: 7px;
  min-width: 200px;
  box-shadow: var(--shadow2);
  display: none;
  animation: slideUp .18s ease;
  z-index: 600;
}

.user-dd.open {
  display: block;
}

.udd-top {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px;
  margin-bottom: 3px;
}

.udd-name {
  font-weight: 600;
  font-size: .78rem;
  color: var(--text);
}

.udd-email {
  font-size: .65rem;
  color: var(--text3);
}

.udd-sep {
  height: 1px;
  background: var(--border);
  margin: 4px 0;
}

.udd-item {
  display: flex;
  align-items: center;
  gap: 7px;
  width: 100%;
  padding: 7px 9px;
  color: var(--text2);
  font-size: .76rem;
  border-radius: 7px;
  transition: all var(--t);
}

.udd-item:hover {
  background: var(--bg2);
  color: var(--text);
}

.udd-item.logout {
  color: var(--red);
}

.udd-item.logout:hover {
  background: rgba(239, 68, 68, .06);
}

/* Hamburger */
.ham-b {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 5px;
  flex-shrink: 0;
}

.ham-b span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text2);
  border-radius: 2px;
  transition: all .28s;
}

.ham-b.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.ham-b.open span:nth-child(2) {
  opacity: 0;
  width: 0;
}

.ham-b.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Mobile panel */
.mob-panel {
  display: none;
  background: var(--card);
  border-top: 1px solid var(--border);
  padding: 14px 14px 18px;
  overflow: hidden;
}

.mob-panel.open {
  display: block;
}

.mob-s {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.mob-nav {
  display: flex;
  flex-direction: column;
  gap: 1px;
  margin-top: 10px;
  border-top: 1px solid var(--border);
  padding-top: 10px;
}

.mob-nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  color: var(--text2);
  font-size: .83rem;
  border-radius: 7px;
  transition: all var(--t);
  cursor: pointer;
  text-decoration: none;
}

.mob-nav a:hover {
  background: var(--bg2);
  color: var(--text);
}

.mob-nav a i {
  color: var(--blue);
  width: 16px;
  font-size: .8rem;
}

/* ── MAIN LAYOUT ──────────────────────────────────────────────── */
.main-layout {
  display: grid;
  grid-template-columns: 42% 1fr;
  height: calc(100dvh - var(--h));
  padding-top: var(--h);
  overflow: hidden;
  max-width: 100vw;
  position: fixed;
  top: var(--h);
  left: 0;
  right: 0;
  bottom: 0;
}

.map-side {
  position: relative;
  overflow: hidden;
  min-width: 0;
  height: 100%;
}

.panel-side {
  display: flex;
  flex-direction: column;
  border-left: 1px solid var(--border);
  background: var(--bg);
  overflow: hidden;
  min-width: 0;
}

/* ── MAP ──────────────────────────────────────────────────────── */
#map {
  width: 100%;
  height: 100%;
  background: var(--bg2);
}

.leaflet-popup-content-wrapper {
  background: var(--card) !important;
  border: 1px solid var(--bord2) !important;
  border-radius: var(--r) !important;
  box-shadow: var(--shadow2) !important;
  color: var(--text) !important;
  padding: 0 !important;
}

.leaflet-popup-content {
  margin: 0 !important;
  font-family: var(--font-b) !important;
  color: var(--text) !important;
}

.leaflet-popup-tip {
  background: var(--card) !important;
}

.leaflet-control-zoom {
  border: 1px solid var(--bord2) !important;
  border-radius: var(--r) !important;
  overflow: hidden;
  box-shadow: var(--shadow) !important;
}

.leaflet-control-zoom a {
  background: var(--card) !important;
  color: var(--text2) !important;
  border-color: var(--border) !important;
}

.leaflet-control-zoom a:hover {
  background: var(--bg2) !important;
  color: var(--blue) !important;
}

/* Map hint */
.map-hint {
  position: absolute;
  inset: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(240, 244, 249, .78);
  backdrop-filter: blur(3px);
  transition: opacity .4s, visibility .4s;
}

.map-hint.gone {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.mh-box {
  text-align: center;
  padding: 0 20px;
}

.mh-box i {
  font-size: 2rem;
  color: var(--blue);
  display: block;
  margin-bottom: 10px;
  animation: pulse 1.5s infinite;
}

.mh-box strong {
  font-family: var(--font-d);
  font-size: 1.3rem;
  letter-spacing: .1em;
  display: block;
  margin-bottom: 5px;
  color: var(--text);
}

.mh-box p {
  font-size: .78rem;
  color: var(--text2);
  line-height: 1.8;
}

.mh-legend {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 12px;
  font-size: .7rem;
  flex-wrap: wrap;
}

/* Map controls */
.map-ctrl-bar {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  max-width: calc(100% - 20px);
}

.radius-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--card);
  border: 1px solid var(--bord2);
  border-radius: 99px;
  padding: 5px 13px;
  font-size: .68rem;
  color: var(--text2);
  white-space: nowrap;
  box-shadow: var(--shadow);
}

.radius-pill i {
  color: var(--blue);
  font-size: .65rem;
}

input[type=range] {
  -webkit-appearance: none;
  height: 3px;
  background: var(--bg3);
  border-radius: 3px;
  width: 68px;
  cursor: pointer;
}

input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--blue);
  cursor: pointer;
}

/* Map FAB column */
.map-fab-col {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 20;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.fab {
  width: 32px;
  height: 32px;
  background: var(--card);
  border: 1px solid var(--bord2);
  border-radius: var(--r);
  color: var(--text2);
  font-size: .78rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow);
  transition: all var(--t);
}

.fab:hover {
  border-color: var(--blue);
  color: var(--blue);
  box-shadow: var(--shadow2);
}

.fab.active {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
}

/* Map footer */
.map-footer-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 20;
  background: rgba(255, 255, 255, .9);
  backdrop-filter: blur(4px);
  padding: 4px 11px;
  display: flex;
  align-items: center;
  gap: 5px;
  font-family: var(--font-m);
  font-size: .56rem;
  color: var(--text3);
  border-top: 1px solid var(--border);
  overflow: hidden;
}

.map-footer-bar i {
  color: var(--blue);
  flex-shrink: 0;
}

#map-status {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ── PANEL TABS ───────────────────────────────────────────────── */
.panel-tabs {
  display: flex;
  background: var(--card);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.ptab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 0 6px;
  height: 42px;
  color: var(--text3);
  font-family: var(--font-d);
  font-size: .75rem;
  letter-spacing: .07em;
  border-bottom: 2px solid transparent;
  transition: all var(--t);
}

.ptab:hover {
  color: var(--text);
  background: var(--bg2);
}

.ptab.active {
  color: var(--blue);
  border-bottom-color: var(--blue);
  background: var(--bg);
}

.ptab span {
  font-size: .68rem;
}

/* ── PANEL SCROLL ─────────────────────────────────────────────── */
.panel-scroll {
  flex: 1;
  overflow-y: auto;
  padding: 14px;
  background: var(--bg);
  overflow-x: hidden;
}

/* Empty state */
.p-empty {
  text-align: center;
  padding: 32px 16px;
}

.pe-icon {
  font-size: 2.4rem;
  color: var(--bg3);
  margin-bottom: 12px;
}

.p-empty h3 {
  font-family: var(--font-d);
  font-size: 1.2rem;
  color: var(--text);
  letter-spacing: .1em;
  margin-bottom: 7px;
}

.p-empty p {
  font-size: .78rem;
  color: var(--text2);
  line-height: 1.7;
  max-width: 300px;
  margin: 0 auto;
}

.p-empty strong {
  color: var(--blue);
}

.pe-steps {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin-top: 18px;
  flex-wrap: wrap;
}

.pe-steps>div {
  text-align: center;
}

.pe-steps>div span {
  display: block;
  font-family: var(--font-d);
  font-size: 1.5rem;
  color: var(--blue);
  line-height: 1;
}

.pe-steps>div p {
  font-size: .68rem;
  color: var(--text3);
  margin-top: 3px;
}

/* ── SCORE ROW ────────────────────────────────────────────────── */
.score-row {
  display: grid;
  grid-template-columns: 1fr 1.2fr 1fr;
  gap: 9px;
  margin-bottom: 11px;
}

.sc-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 11px;
  transition: border-color var(--t);
  min-width: 0;
}

.sc-card.safe {
  border-color: rgba(16, 185, 129, .3);
}

.sc-card.moderate {
  border-color: rgba(245, 158, 11, .3);
}

.sc-card.danger {
  border-color: rgba(239, 68, 68, .3);
}

.sc-tag {
  font-family: var(--font-d);
  font-size: .68rem;
  letter-spacing: .13em;
  margin-bottom: 3px;
  display: inline-block;
  padding: 2px 7px;
  border-radius: 3px;
}

.otag {
  background: rgba(16, 185, 129, .1);
  color: var(--green);
}

.dtag {
  background: rgba(245, 158, 11, .1);
  color: var(--amber);
}

.rtag {
  background: rgba(20, 68, 145, .1);
  color: var(--blue);
}

.sc-place {
  font-size: .74rem;
  font-weight: 600;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-bottom: 5px;
}

.arc-wrap {
  position: relative;
  display: flex;
  justify-content: center;
  margin-bottom: 5px;
}

.arc-svg {
  width: 110px;
  height: 75px;
}

.arc-track {
  fill: none;
  stroke: var(--bg3);
  stroke-width: 8;
  stroke-linecap: round;
}

.arc-fill {
  fill: none;
  stroke-width: 8;
  stroke-linecap: round;
  transition: stroke-dasharray 1.2s cubic-bezier(.34, 1.56, .64, 1);
}

.arc-val {
  position: absolute;
  bottom: 3px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-m);
  font-size: 1.3rem;
  color: var(--text);
  white-space: nowrap;
}

.arc-val sub {
  font-size: .52rem;
  color: var(--text3);
}

.sc-badge {
  display: inline-block;
  font-family: var(--font-d);
  font-size: .67rem;
  letter-spacing: .11em;
  padding: 2px 8px;
  border-radius: 3px;
  background: var(--bg2);
  color: var(--text3);
  margin-bottom: 7px;
  transition: all var(--t);
}

.sc-badge.safe {
  background: rgba(16, 185, 129, .1);
  color: var(--green);
  border: 1px solid rgba(16, 185, 129, .22);
}

.sc-badge.moderate {
  background: rgba(245, 158, 11, .1);
  color: var(--amber);
  border: 1px solid rgba(245, 158, 11, .22);
}

.sc-badge.danger {
  background: rgba(239, 68, 68, .1);
  color: var(--red);
  border: 1px solid rgba(239, 68, 68, .22);
}

.sc-badge.big {
  font-size: .8rem;
  padding: 3px 12px;
}

.sc-mini-stats>div {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: .65rem;
  color: var(--text2);
  margin-bottom: 3px;
}

.sc-mini-stats i {
  color: var(--blue);
  font-size: .6rem;
  width: 11px;
}

/* Route card */
.rt-card {
  background: linear-gradient(160deg, var(--card), var(--bg2));
  border: 1px solid var(--bord2);
  border-radius: var(--r2);
  padding: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  min-width: 0;
}

.rt-num {
  font-family: var(--font-m);
  font-size: 2.5rem;
  color: var(--text);
  line-height: 1;
  margin: 5px 0;
}

.rt-sub {
  font-size: .65rem;
  color: var(--text3);
  margin-bottom: 7px;
}

.rt-bar-wrap {
  width: 100%;
  margin: 6px 0;
}

.rt-track {
  height: 6px;
  background: var(--bg3);
  border-radius: 6px;
  overflow: hidden;
}

.rt-fill {
  height: 100%;
  width: 0;
  border-radius: 6px;
  background: linear-gradient(90deg, var(--red), var(--amber) 50%, var(--green));
  background-size: 200% 100%;
  transition: width 1.2s ease;
}

.rt-labs {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-m);
  font-size: .54rem;
  color: var(--text3);
  margin-top: 3px;
}

.rt-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px;
  width: 100%;
  margin-top: 7px;
}

.rt-stats>div {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: .65rem;
  color: var(--text2);
  background: var(--bg2);
  border-radius: 5px;
  padding: 4px 6px;
}

.rt-stats i {
  color: var(--blue);
  font-size: .6rem;
}

/* ── VERDICT ──────────────────────────────────────────────────── */
.verdict {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 12px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 12px;
  transition: border-color var(--t);
}

.v-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
  margin-top: 1px;
}

.v-title {
  font-family: var(--font-d);
  font-size: .95rem;
  letter-spacing: .05em;
  color: var(--text);
  margin-bottom: 3px;
}

.v-sub {
  font-size: .72rem;
  color: var(--text2);
  line-height: 1.6;
}

/* ── CASES ────────────────────────────────────────────────────── */
.p-section {
  margin-bottom: 12px;
}

.ps-hdr {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 9px;
  flex-wrap: wrap;
  gap: 6px;
}

.ps-hdr h3 {
  font-family: var(--font-d);
  font-size: .85rem;
  letter-spacing: .07em;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 5px;
}

.ps-hdr h3 i {
  color: var(--blue);
}

.ps-count {
  font-family: var(--font-m);
  font-size: .58rem;
  background: rgba(20, 68, 145, .08);
  color: var(--blue);
  border: 1px solid rgba(20, 68, 145, .18);
  border-radius: 3px;
  padding: 2px 7px;
}

.cases-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.case-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 11px;
  border-left: 3px solid var(--border);
  transition: all var(--t);
  animation: fadeUp .3s ease both;
}

.case-card:hover {
  box-shadow: var(--shadow2);
  transform: translateY(-1px);
}

.case-card.violent {
  border-left-color: #ff3b30;
}

.case-card.property {
  border-left-color: #ff9500;
}

.case-card.other {
  border-left-color: #5856d6;
}

.cc-type {
  font-family: var(--font-d);
  font-size: .8rem;
  letter-spacing: .05em;
  color: var(--text);
  margin-bottom: 6px;
}

.cc-row {
  display: flex;
  align-items: flex-start;
  gap: 5px;
  font-size: .68rem;
  color: var(--text2);
  margin-bottom: 3px;
  line-height: 1.4;
}

.cc-row i {
  color: var(--text3);
  font-size: .6rem;
  width: 10px;
  flex-shrink: 0;
  margin-top: 2px;
}

.cc-tag {
  display: inline-block;
  font-size: .6rem;
  font-weight: 600;
  padding: 1px 5px;
  border-radius: 3px;
  margin-top: 5px;
}

.cc-tag.violent {
  background: rgba(255, 59, 48, .1);
  color: #ff3b30;
}

.cc-tag.property {
  background: rgba(255, 149, 0, .1);
  color: #ff9500;
}

.cc-tag.other {
  background: rgba(88, 86, 214, .1);
  color: #5856d6;
}

/* ── CHARTS ───────────────────────────────────────────────────── */
.charts-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin-bottom: 9px;
}

.cc {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 12px;
  min-width: 0;
}

.cc-hdr {
  font-family: var(--font-d);
  font-size: .7rem;
  letter-spacing: .09em;
  color: var(--text2);
  margin-bottom: 9px;
  display: flex;
  align-items: center;
  gap: 5px;
}

.cc-hdr i {
  color: var(--blue);
}

.bar-row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 5px;
  min-width: 0;
}

.bl {
  font-size: .65rem;
  color: var(--text2);
  flex: 0 0 90px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bt {
  flex: 1;
  height: 6px;
  background: var(--bg3);
  border-radius: 3px;
  overflow: hidden;
  min-width: 0;
}

.bf {
  height: 100%;
  border-radius: 3px;
  transition: width .9s ease;
}

.bn {
  font-family: var(--font-m);
  font-size: .6rem;
  color: var(--text3);
  flex: 0 0 26px;
  text-align: right;
}

.demo-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.demo-sub {
  font-family: var(--font-m);
  font-size: .56rem;
  letter-spacing: .11em;
  color: var(--text3);
  margin-bottom: 6px;
  text-transform: uppercase;
}

.dr {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 4px;
  min-width: 0;
}

.dk {
  font-size: .64rem;
  color: var(--text2);
  flex: 0 0 44px;
}

.dt {
  flex: 1;
  height: 5px;
  background: var(--bg3);
  border-radius: 3px;
  overflow: hidden;
  min-width: 0;
}

.df {
  height: 100%;
  border-radius: 3px;
  transition: width .9s ease;
}

.dp {
  font-family: var(--font-m);
  font-size: .56rem;
  color: var(--text3);
  flex: 0 0 26px;
  text-align: right;
}

/* Tips */
.tip-item {
  display: flex;
  gap: 8px;
  background: var(--bg2);
  border-radius: var(--r);
  padding: 9px;
  margin-bottom: 7px;
  border: 1px solid var(--border);
}

.tip-em {
  font-size: .95rem;
  flex-shrink: 0;
  margin-top: 1px;
}

.tip-t {
  font-size: .72rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 2px;
}

.tip-d {
  font-size: .66rem;
  color: var(--text2);
  line-height: 1.5;
}

/* ── INCIDENTS ────────────────────────────────────────────────── */
.inc-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 11px;
}

.fsel {
  background: var(--bg2);
  border: 1px solid var(--bord2);
  border-radius: var(--r);
  color: var(--text2);
  font-size: .72rem;
  padding: 6px 9px;
  cursor: pointer;
  max-width: 100%;
}

.fsel:focus {
  border-color: var(--blue);
}

.inc-search-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--bg2);
  border: 1px solid var(--bord2);
  border-radius: var(--r);
  padding: 6px 10px;
  flex: 1;
  min-width: 140px;
}

.inc-search-wrap i {
  color: var(--text3);
  font-size: .7rem;
  flex-shrink: 0;
}

.inc-search-wrap input {
  background: none;
  border: none;
  color: var(--text);
  font-size: .72rem;
  flex: 1;
  min-width: 0;
}

.inc-search-wrap input::placeholder {
  color: var(--text3);
}

.inc-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 9px 11px;
  background: var(--card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--border);
  border-radius: var(--r);
  margin-bottom: 5px;
  transition: all var(--t);
}

.inc-row.violent {
  border-left-color: #ff3b30;
}

.inc-row.property {
  border-left-color: #ff9500;
}

.inc-row.other {
  border-left-color: #5856d6;
}

.inc-row:hover {
  background: var(--bg2);
}

.inc-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 4px;
}

.inc-dot.violent {
  background: #ff3b30;
}

.inc-dot.property {
  background: #ff9500;
}

.inc-dot.other {
  background: #5856d6;
}

.inc-body {
  flex: 1;
  min-width: 0;
}

.inc-type {
  font-size: .74rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 2px;
}

.inc-meta {
  font-size: .64rem;
  color: var(--text3);
  margin-bottom: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.inc-date {
  font-family: var(--font-m);
  font-size: .58rem;
  color: var(--text3);
  flex-shrink: 0;
  margin-top: 2px;
  white-space: nowrap;
}

/* ── ROUTES ───────────────────────────────────────────────────── */
.route-opt {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 12px 14px;
  margin-bottom: 9px;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all var(--t);
  min-width: 0;
}

.route-opt:hover {
  box-shadow: var(--shadow);
}

.route-opt.best {
  border-color: rgba(16, 185, 129, .35);
  background: linear-gradient(135deg, var(--card), rgba(16, 185, 129, .03));
}

.ro-score {
  font-family: var(--font-m);
  font-size: 1.3rem;
  flex-shrink: 0;
  min-width: 42px;
  text-align: center;
}

.ro-body {
  flex: 1;
  min-width: 0;
}

.ro-name {
  font-weight: 600;
  font-size: .77rem;
  color: var(--text);
  margin-bottom: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ro-detail {
  font-size: .65rem;
  color: var(--text3);
}

/* ── SAVED ────────────────────────────────────────────────────── */
.saved-item {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 11px 13px;
  margin-bottom: 7px;
  display: flex;
  align-items: center;
  gap: 9px;
  transition: all var(--t);
  min-width: 0;
}

.saved-item:hover {
  border-color: var(--blue);
  box-shadow: var(--shadow);
}

.si-name {
  flex: 1;
  font-weight: 600;
  font-size: .77rem;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.si-meta {
  font-size: .64rem;
  color: var(--text3);
}

.si-acts {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}

.si-b {
  width: 24px;
  height: 24px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text3);
  font-size: .68rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--t);
}

.si-b:hover {
  color: var(--blue);
  border-color: var(--blue);
}

.si-del:hover {
  color: var(--red);
  border-color: var(--red);
}

/* ── CRIME POPUP ──────────────────────────────────────────────── */
.cpop {
  padding: 10px 12px;
  min-width: 180px;
  max-width: 240px;
}

.cpop-hdr {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin-bottom: 7px;
}

.cpop-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 3px;
}

.cpop-title {
  font-size: .78rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
}

.cpop-row {
  display: flex;
  align-items: flex-start;
  gap: 5px;
  font-size: .66rem;
  color: var(--text2);
  margin-bottom: 3px;
}

.cpop-row i {
  color: var(--text3);
  font-size: .58rem;
  width: 10px;
  flex-shrink: 0;
  margin-top: 2px;
}

/* ── NO DATA ──────────────────────────────────────────────────── */
.no-data {
  font-size: .76rem;
  color: var(--text3);
  text-align: center;
  padding: 16px 0;
}

/* ── ANIMATIONS ───────────────────────────────────────────────── */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(7px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

.fu {
  animation: fadeUp .28s ease both;
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════════════════ */

/* Large desktop */
@media (max-width: 1200px) {
  .main-layout {
    grid-template-columns: 40% 1fr;
  }
}

/* Medium — tablet landscape */
@media (max-width: 960px) {
  .main-layout {
    grid-template-columns: 38% 1fr;
  }

  .sbar {
    max-width: 440px;
  }

  .live-tag {
    display: none;
  }
}

/* Tablet portrait — stack map above panel */
@media (max-width: 768px) {
  .main-layout {
    grid-template-columns: 1fr;
    grid-template-rows: 44vh 1fr;
    height: auto;
    min-height: calc(100dvh - var(--h));
  }

  .map-side {
    height: 44vh;
  }

  .panel-side {
    border-left: none;
    border-top: 1px solid var(--border);
    height: auto;
    min-height: 56vh;
  }

  /* Hide desktop search — show hamburger */
  #desktop-sbar {
    display: none;
  }

  .ham-b {
    display: flex;
  }

  .brand-s {
    display: none;
  }

  .u-nm {
    display: none;
  }

  .icon-b {
    display: none;
  }
}

/* Mobile */
@media (max-width: 600px) {
  .hdr-inner {
    padding: 0 12px;
    gap: 8px;
  }

  .score-row {
    grid-template-columns: 1fr;
    gap: 7px;
  }

  .rt-card {
    order: -1;
  }

  .charts-2col {
    grid-template-columns: 1fr;
  }

  .cases-grid {
    grid-template-columns: 1fr;
  }

  .demo-2 {
    grid-template-columns: 1fr;
  }

  .panel-scroll {
    padding: 11px;
  }

  .ptab span {
    display: none;
  }

  .ptab {
    font-size: .68rem;
  }

  #toasts {
    bottom: 10px;
    right: 10px;
  }

  .map-side {
    height: 40vh;
  }
}

/* Small mobile */
@media (max-width: 400px) {
  .auth-card {
    padding: 20px 14px;
  }

  .frow {
    grid-template-columns: 1fr;
  }

  .hdr-brand .brand-n {
    font-size: 1rem;
  }

  .hdr-brand i {
    font-size: 1.1rem;
  }

  .rt-stats {
    grid-template-columns: 1fr;
  }
}

/* ── NAVBAR FIXES ─────────────────────────────────────────────── */

/* 1. Make header stretch full width with no gap */
.hdr {
  width: 100%;
  left: 0;
  right: 0;
}

/* 2. hdr-inner fills full width, no max-width clipping */
.hdr-inner {
  width: 100%;
  max-width: 100%;
  overflow: visible;
  /* was hidden — was clipping dropdown */
}

/* 3. Search bar fills all available space between brand and right actions */
#desktop-sbar {
  flex: 1;
  min-width: 0;
  max-width: none;
  /* remove the 640px cap that caused the gap */
}

/* 4. Push right actions to the far right */
.hdr-right {
  flex-shrink: 0;
  margin-left: auto;
  /* ensures it always goes to the right edge */
  display: flex;
  align-items: center;
  gap: 8px;
}

/* 5. Dropdown above everything — was going behind the map */
.user-dd {
  z-index: 9999;
  /* was 600 — now above map, leaflet, panel */
  position: absolute;
  top: calc(100% + 7px);
  right: 0;
}

/* 6. Mobile panel also needs full width */
.mob-panel {
  width: 100%;
  left: 0;
  right: 0;
}

/* 7. Mobile search fields need background so they are visible */
.mob-s .sf {
  background: var(--bg2);
  border: 1px solid var(--bord2);
  border-radius: var(--r);
  padding: 2px 6px;
}

/* ── NAVBAR FIXES ─────────────────────────────────────────────── */

/* 1. Make header stretch full width with no gap */
.hdr {
  width: 100%;
  left: 0;
  right: 0;
}

/* 2. hdr-inner fills full width, no max-width clipping */
.hdr-inner {
  width: 100%;
  max-width: 100%;
  overflow: visible;
  /* was hidden — was clipping dropdown */
}

/* 3. Search bar fills all available space between brand and right actions */
#desktop-sbar {
  flex: 1;
  min-width: 0;
  max-width: none;
  /* remove the 640px cap that caused the gap */
}

/* 4. Push right actions to the far right */
.hdr-right {
  flex-shrink: 0;
  margin-left: auto;
  /* ensures it always goes to the right edge */
  display: flex;
  align-items: center;
  gap: 8px;
}

/* 5. Dropdown above everything — was going behind the map */
.user-dd {
  z-index: 9999;
  /* was 600 — now above map, leaflet, panel */
  position: absolute;
  top: calc(100% + 7px);
  right: 0;
}

/* 6. Mobile panel also needs full width */
.mob-panel {
  width: 100%;
  left: 0;
  right: 0;
}

/* 7. Mobile search fields need background so they are visible */
.mob-s .sf {
  background: var(--bg2);
  border: 1px solid var(--bord2);
  border-radius: var(--r);
  padding: 2px 6px;
}


/* ── EXPORT BAR ───────────────────────────────────────────────── */
#export-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  flex-shrink: 0;
}
.exp-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 6px 11px;
  border-radius: var(--r);
  font-size: .72rem;
  font-family: var(--font-b);
  font-weight: 600;
  cursor: pointer;
  transition: all var(--t);
  white-space: nowrap;
  border: 1px solid transparent;
}
.exp-btn i { font-size: .65rem; flex-shrink: 0; }

/* JSON — green */
.exp-btn.ejson {
  background: rgba(16,185,129,.12);
  color: #059669;
  border-color: rgba(16,185,129,.3);
}
.exp-btn.ejson:hover {
  background: rgba(16,185,129,.22);
  border-color: rgba(16,185,129,.5);
}

/* CSV — blue */
.exp-btn.ecsv {
  background: rgba(20,68,145,.1);
  color: var(--blue);
  border-color: rgba(20,68,145,.25);
}
.exp-btn.ecsv:hover {
  background: rgba(20,68,145,.18);
  border-color: rgba(20,68,145,.45);
}
