
#map-wrap { position: relative; width: 100%; height: 80vh; }
#map { width: 100%; height: 100%; }

/* TOOLBAR */
.toolbar {
  position: absolute; top: 14px; left: 14px; right: 14px;
  z-index: 500; display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.search-box {
  flex: 1 1 220px; max-width: 320px;
  background: rgba(15, 26, 50, 0.94);
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 10px; padding: 9px 14px; color: #fff; font-size: 13px;
  display: flex; align-items: center; gap: 8px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.25);
}
.search-box i { color: #7d8bab; }
.search-box input {
  flex: 1; background: transparent; border: none; outline: none;
  color: #fff; font-size: 13px;
}
.search-box input::placeholder { color: #7d8bab; }
.count-pill {
  background: rgba(251,146,60,0.16); color: #fb923c;
  border: 1px solid rgba(251,146,60,0.3); border-radius: 20px;
  padding: 8px 14px; font-size: 12px; font-weight: 700; white-space: nowrap;
}

/* LEGEND */
.legend {
  position: absolute; left: 18px; bottom: 18px; z-index: 500;
  background: rgba(15,26,50,0.94);
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 10px; padding: 14px 18px; color: #fff; font-size: 13px;
  min-width: 190px; box-shadow: 0 8px 30px rgba(0,0,0,0.25);
  max-height: 60vh; overflow-y: auto;
}
.legend-row {
  display: flex; align-items: center; gap: 10px; margin-bottom: 8px;
  cursor: pointer; user-select: none; transition: opacity 0.15s ease;
}
.legend-row:last-child { margin-bottom: 0; }
.legend-row.off { opacity: 0.35; }
.dot {
  width: 14px; height: 14px; border-radius: 50%; flex-shrink: 0;
  border: 2px solid rgba(255,255,255,0.5);
}
.dot.school { background: #22c55e; }
.dot.junior { background: #06b6d4; }
.dot.college { background: #3b82f6; }
.dot.business { background: #a855f7; }
.dot.exam { background: #eab308; }
.dot.nursing { background: #ec4899; }
.dot.university { background: #f97316; }

/* ===== CHANGED: International Schools dot color (was #14b8a6 teal) ===== */
.dot.international { background: #e11d48; }

/* ===== CHANGED: International Schools category block INSIDE legend ===== */
.legend-divider {
  height: 1px;
  background: rgba(225,29,72,0.45);   /* matches new dot color */
  margin: 10px 0 8px;
}
.legend-subtitle {
  font-size: 11px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #fb7185;                     /* ===== CHANGED label color ===== */
  font-weight: 700;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.legend-subtitle i { font-size: 11px; }

/* International school individual rows (clickable) */
.intl-row {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 12.5px;
  color: #e2e8f0;
  padding: 3px 0;
  cursor: pointer;
  transition: color .15s ease;
}
.intl-row:hover { color: #fb7185; }    /* ===== CHANGED hover color ===== */
.intl-row .dot {
  width: 12px;
  height: 12px;
  border-width: 2px;
}

/* MARKER */
.pin {
  width: 26px; height: 26px; border-radius: 50% 50% 50% 0;
  transform: rotate(-45deg);
  display: flex; align-items: center; justify-content: center;
  border: 2px solid rgba(255,255,255,0.9);
  box-shadow: 0 3px 8px rgba(0,0,0,0.4);
}
.pin i { transform: rotate(45deg); color: #0b1830; font-size: 11px; }
.pin.school { background: #22c55e; }
.pin.junior { background: #06b6d4; }
.pin.college { background: #3b82f6; }
.pin.business { background: #a855f7; }
.pin.exam { background: #eab308; }
.pin.nursing { background: #ec4899; }
.pin.university {
  background: #f97316;
  width: 32px; height: 32px;
  border: 3px solid #fff;
  box-shadow: 0 0 0 3px rgba(249,115,22,0.35), 0 3px 10px rgba(0,0,0,0.5);
  animation: pulse 2s infinite;
}
.pin.university i { font-size: 13px; }

/* ===== CHANGED: International school marker pin color (was #14b8a6 teal) ===== */
.pin.international {
  background: #e11d48;
  border: 2px solid #fff;
  box-shadow: 0 0 0 3px rgba(225,29,72,0.3), 0 3px 8px rgba(0,0,0,0.4);
}

@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(249,115,22,0.35), 0 3px 10px rgba(0,0,0,0.5); }
  50% { box-shadow: 0 0 0 8px rgba(249,115,22,0.15), 0 3px 10px rgba(0,0,0,0.5); }
}

/* POPUP */
.leaflet-popup-content-wrapper {
  background: #0f1a32; color: #fff; border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.14);
  box-shadow: 0 12px 40px rgba(0,0,0,0.35);
}
.leaflet-popup-tip { background: #0f1a32; }
.leaflet-popup-content { margin: 0; width: 300px !important; }
.leaflet-popup-close-button { color: #9fb0cc !important; }

.popup-card { padding: 16px 18px 18px; }
.popup-badge {
  display: inline-block;
  background: rgba(249,115,22,0.16); color: #fb923c;
  font-size: 11px; font-weight: 700; letter-spacing: .04em;
  text-transform: uppercase; padding: 3px 10px;
  border-radius: 20px; margin-bottom: 8px;
}
.popup-card h3 {
  font-size: 15px; font-weight: 600; margin-bottom: 8px; color: #fff;
}
.popup-detail {
  display: flex; align-items: flex-start; gap: 8px;
  font-size: 13px;  margin-bottom: 6px; line-height: 1.5;
}
.popup-detail i {
  color: #fb923c; width: 14px; margin-top: 2px;
  font-size: 12px; flex-shrink: 0;
}
.popup-detail a { color: #cbd5e1; text-decoration: none; }
.popup-detail a:hover { color: #fb923c; }
.popup-note { font-size: 12px;  margin-top: 8px; font-style: italic; }
.popup-divider { border-top: 1px solid rgba(255,255,255,0.1); margin: 10px 0; }
.get-directions {
  display: inline-flex; align-items: center; gap: 6px;
  color: #fb923c;  font-size: 13px;
  text-decoration: none; margin-top: 4px;
}
.get-directions:hover { color: #fdba74; }

/* MOBILE */
@media (max-width: 767px) {
  .legend { left: 12px; bottom: 12px; padding: 11px 13px; min-width: 160px; font-size: 12px; max-height: 46vh; }
  .leaflet-popup-content { width: 260px !important; }
  .toolbar { top: 10px; left: 10px; right: 10px; }
  .search-box { max-width: none; }
}
@media (max-width: 480px) {
  .legend { left: 10px; bottom: 10px; }
}



/* =========================================
   CAMPUS & INSTITUTION LOCATOR
========================================= */

.map-section-card {
  width: 100%;
  margin: 0 auto;
  background: #ffffff;
  border: 1px solid #e7ebf2;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(15, 35, 70, 0.08);
}

/* Section Header */
.map-section-header {
  padding: 42px 50px 34px;
  text-align: center;
  background: #ffffff;
}

.map-section-eyebrow {
  display: inline-block;
  margin-bottom: 10px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #ff6100;
}



/* Map container */
#map-wrap {
  position: relative;
  width: 100%;
  height: 400px;
  overflow: hidden;
}

/* Leaflet map */
#map {
  width: 100%;
  height: 100%;
}

/* =========================================
   RESPONSIVE
========================================= */

@media (max-width: 991px) {

  .map-section-card {
    border-radius: 20px;
  }

  .map-section-header {
    padding: 34px 30px 28px;
  }

  #map-wrap {
     height: 400px;
}

@media (max-width: 767px) {

  .map-section-card {
    border-radius: 16px;
  }

  .map-section-header {
    padding: 28px 20px 24px;
  }

  .map-section-eyebrow {
    font-size: 11px;
  }



  #map-wrap {
     height: 400px;
}