/* weather.css - Dedicated Clean & Rock-Solid CSS Stylesheet for Vietnam Weather Live Map */

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

body, html {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background-color: #0f172a;
}

#map {
  width: 100vw;
  height: 100vh;
}

/* REMOVE BLUE ACCURACY CIRCLE & DEFAULT USER LOCATION HALO */
.maplibregl-user-location-accuracy-circle,
.mapboxgl-user-location-accuracy-circle,
.maplibregl-user-location-dot,
.mapboxgl-user-location-dot {
  display: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
}

/* ENLARGE & BEAUTIFY MAP CONTROL BUTTONS (+, -, COMPASS, GEOLOCATE) */
.maplibregl-ctrl-group {
  background: rgba(15, 23, 42, 0.9) !important;
  backdrop-filter: blur(12px) !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  border-radius: 14px !important;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5) !important;
  overflow: hidden;
}

.maplibregl-ctrl-group button {
  width: 44px !important;
  height: 44px !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
}

.maplibregl-ctrl-group button:last-child {
  border-bottom: none !important;
}

.maplibregl-ctrl-icon {
  filter: invert(1) brightness(1.8) !important;
  transform: scale(1.15) !important;
}

/* PROMINENT FLOATING MY LOCATION BUTTON */
.btn-my-location-floating {
  position: absolute;
  bottom: 36px;
  right: 36px;
  z-index: 30;
  background: linear-gradient(135deg, #0284c7, #1d4ed8);
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-radius: 40px;
  padding: 14px 26px;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 12px 30px rgba(2, 132, 199, 0.6), 0 0 20px rgba(56, 189, 248, 0.4);
  transition: all 0.25s ease;
  letter-spacing: 0.02em;
}

.btn-my-location-floating i {
  font-size: 20px;
  color: #7dd3fc;
}

.btn-my-location-floating:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 16px 36px rgba(2, 132, 199, 0.8), 0 0 25px rgba(56, 189, 248, 0.6);
  background: linear-gradient(135deg, #0369a1, #1e40af);
}

/* TOP FLOATING SEARCH BAR */
.search-container {
  position: absolute;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  width: 520px;
  max-width: calc(100vw - 40px);
}

.search-box {
  display: flex;
  align-items: center;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 30px;
  padding: 6px 16px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.45);
  transition: all 0.3s ease;
}

.search-box:focus-within {
  border-color: #38bdf8;
  box-shadow: 0 14px 35px rgba(56, 189, 248, 0.25);
}

.search-icon {
  font-size: 18px;
  color: #38bdf8;
  margin-right: 12px;
}

.search-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 0;
}

.search-input::placeholder {
  color: #94a3b8;
}

.clear-search-btn {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 18px;
  cursor: pointer;
  padding: 4px;
  display: none;
}

.clear-search-btn:hover {
  color: #fff;
}

/* SMALL TOGGLE MY LOCATION AVATAR BUTTON NEXT TO SEARCH BAR */
.btn-toggle-avatar {
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #38bdf8;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 15px;
  flex-shrink: 0;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.45);
  transition: all 0.25s ease;
}

.btn-toggle-avatar:hover {
  background: rgba(30, 41, 59, 0.95);
  border-color: #38bdf8;
  transform: scale(1.08);
}

.btn-toggle-avatar.hidden-mode {
  color: #94a3b8;
  border-color: rgba(255, 255, 255, 0.1);
  background: rgba(15, 23, 42, 0.75);
}

/* GUARANTEED CSS HIDE FOR USER LOCATION ANIMAL AVATAR */
body.user-avatar-hidden .user-animal-marker-wrapper {
  display: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

/* SEARCH DROPDOWN RESULTS */
.search-results-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: 100%;
  background: rgba(15, 23, 42, 0.96);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 18px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
  max-height: 360px;
  overflow-y: auto;
  display: none;
  z-index: 21;
}

.search-result-item {
  padding: 12px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  transition: background 0.2s ease;
}

.search-result-item:hover {
  background: rgba(56, 189, 248, 0.15);
}

.result-icon {
  color: #38bdf8;
  font-size: 16px;
}

.result-title {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
}

.result-address {
  font-size: 11px;
  color: #94a3b8;
  margin-top: 2px;
}

/* MAIN FLOATING CONTROL PANEL */
.control-panel {
  position: absolute;
  top: 20px;
  left: 20px;
  z-index: 10;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 20px;
  padding: 20px 22px;
  width: 390px;
  max-width: calc(100vw - 40px);
  color: #fff;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  gap: 10px;
}

.panel-header-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.panel-header-left i {
  font-size: 28px;
  color: #38bdf8;
  flex-shrink: 0;
}

.panel-header h2 {
  font-size: 16px;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.panel-header p {
  font-size: 11px;
  color: #94a3b8;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* GLOBAL MULTILINGUAL LANGUAGE SELECTOR DROPDOWN */
.lang-select-wrap {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  background: rgba(30, 41, 59, 0.95);
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 20px;
  padding: 4px 10px;
  gap: 6px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.lang-globe-icon {
  font-size: 13px;
  color: #38bdf8;
}

.lang-dropdown {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  outline: none;
  cursor: pointer;
}

.lang-dropdown option {
  background: #0f172a;
  color: #fff;
  font-weight: 700;
}

/* REAL-TIME WEATHER FORECAST WIDGET CARD */
.real-weather-card {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.9));
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: 14px;
  padding: 14px;
  margin-bottom: 16px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.rw-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.rw-location {
  font-size: 12px;
  font-weight: 700;
  color: #38bdf8;
}

.rw-badge {
  font-size: 10px;
  font-weight: 800;
  background: rgba(34, 197, 94, 0.2);
  color: #4ade80;
  border: 1px solid rgba(34, 197, 94, 0.4);
  padding: 2px 8px;
  border-radius: 10px;
}

.rw-body {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 10px;
}

.rw-temp {
  font-size: 28px;
  font-weight: 900;
  color: #fff;
  line-height: 1;
}

.rw-condition {
  font-size: 12px;
  font-weight: 600;
  color: #cbd5e1;
  margin-top: 4px;
}

.rw-details {
  display: flex;
  gap: 12px;
  font-size: 11px;
  color: #94a3b8;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 8px;
}

/* 5-DAY HORIZONTAL FORECAST STRIP */
.rw-forecast-section {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.rw-forecast-title {
  font-size: 11px;
  font-weight: 700;
  color: #38bdf8;
  margin-bottom: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.rw-forecast-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
}

.rw-day-item {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 6px 2px;
  text-align: center;
  transition: all 0.2s ease;
}

.rw-day-item:hover {
  background: rgba(56, 189, 248, 0.15);
  border-color: rgba(56, 189, 248, 0.3);
}

.rw-day-name {
  font-size: 10px;
  font-weight: 700;
  color: #94a3b8;
  margin-bottom: 4px;
}

.rw-day-icon {
  font-size: 16px;
  margin-bottom: 4px;
}

.rw-day-temp {
  font-size: 10px;
  font-weight: 800;
  color: #fff;
}

.rw-day-rain {
  font-size: 9px;
  color: #60a5fa;
  font-weight: 700;
  margin-top: 2px;
}

/* BUTTON REPORT WEATHER */
.btn-weather-report {
  width: 100%;
  background: linear-gradient(135deg, #0284c7, #2563eb);
  color: #fff;
  border: none;
  padding: 13px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 8px 20px rgba(2, 132, 199, 0.4);
  transition: all 0.25s ease;
  margin-bottom: 16px;
}

.btn-weather-report:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 25px rgba(2, 132, 199, 0.6);
}

.form-group {
  margin-bottom: 14px;
}

.form-group label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  color: #cbd5e1;
  margin-bottom: 6px;
}

.select-input {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(30, 41, 59, 0.9);
  color: #fff;
  font-size: 13px;
  outline: none;
}

/* ----------------------------------------------------
   STABLE 0px OFFSET MARKERS FOR MAPLIBRE GL JS
---------------------------------------------------- */

/* 1. WEATHER LIVE REPORT MARKER (0px OFFSET SYMMETRICAL CIRCLE) */
.marker-wrapper {
  margin: 0 !important;
  padding: 0 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer;
  z-index: 40;
  pointer-events: auto !important;
}

.weather-badge-circle {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.95);
  border: 3px solid #38bdf8;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #fff;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.6);
  user-select: none;
}

.weather-badge-circle i {
  font-size: 16px;
  line-height: 1;
}

.weather-badge-temp {
  font-size: 10px;
  font-weight: 800;
  color: #fff;
  margin-top: 1px;
}

.weather-badge-circle.rain { border-color: #3b82f6; }
.weather-badge-circle.heavy_rain { border-color: #1d4ed8; }
.weather-badge-circle.storm { border-color: #9333ea; }
.weather-badge-circle.flood { border-color: #ef4444; }
.weather-badge-circle.sunny { border-color: #f59e0b; }
.weather-badge-circle.fog { border-color: #94a3b8; }

/* 2. CUTE ANIMAL USER LOCATION MARKER (0px OFFSET SYMMETRICAL CIRCLE) */
.user-animal-marker-wrapper {
  margin: 0 !important;
  padding: 0 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: grab;
  z-index: 60 !important;
  pointer-events: auto !important;
  user-select: none;
}

.user-animal-marker-wrapper:active {
  cursor: grabbing;
}

.user-animal-badge-circle {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0284c7, #2563eb);
  border: 3px solid #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 18px rgba(2, 132, 199, 0.7), 0 0 15px rgba(56, 189, 248, 0.6);
  animation: animal-avatar-glow 2s infinite ease-in-out;
}

.animal-avatar-inner {
  font-size: 23px;
  line-height: 1;
}

@keyframes animal-avatar-glow {
  0%, 100% { box-shadow: 0 6px 18px rgba(2, 132, 199, 0.7), 0 0 15px rgba(56, 189, 248, 0.6); }
  50% { box-shadow: 0 10px 24px rgba(2, 132, 199, 0.95), 0 0 25px rgba(56, 189, 248, 0.9); }
}

/* ANIMAL AVATAR SELECTOR UI */
.animal-picker-wrap {
  display: flex;
  gap: 6px;
  align-items: center;
  margin-top: 8px;
}

.animal-opt {
  font-size: 18px;
  padding: 4px 8px;
  border-radius: 10px;
  background: rgba(30, 41, 59, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.15);
  cursor: pointer;
  transition: all 0.2s ease;
}

.animal-opt:hover, .animal-opt.active {
  background: rgba(56, 189, 248, 0.3);
  border-color: #38bdf8;
  transform: scale(1.15);
}

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ef4444;
  display: inline-block;
  animation: live-dot-blink 1.2s infinite;
}

@keyframes live-dot-blink {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.3; transform: scale(0.7); }
}

/* ZOOM OUT MODE: VIBRANT GLOWING COLORED SPHERES (< 9) */
body.zoom-out-mode .weather-badge-circle {
  width: 18px !important;
  height: 18px !important;
  border-radius: 50% !important;
  border: 2.5px solid #ffffff !important;
  box-shadow: 0 0 16px currentColor, 0 4px 12px rgba(0, 0, 0, 0.4) !important;
  animation: zoom-out-dot-pulse 2s infinite ease-in-out !important;
}

body.zoom-out-mode .weather-badge-circle.sunny { background: linear-gradient(135deg, #f59e0b, #fbbf24) !important; color: #f59e0b !important; }
body.zoom-out-mode .weather-badge-circle.rain { background: linear-gradient(135deg, #3b82f6, #60a5fa) !important; color: #3b82f6 !important; }
body.zoom-out-mode .weather-badge-circle.heavy_rain { background: linear-gradient(135deg, #1d4ed8, #3b82f6) !important; color: #1d4ed8 !important; }
body.zoom-out-mode .weather-badge-circle.storm { background: linear-gradient(135deg, #9333ea, #c084fc) !important; color: #9333ea !important; }
body.zoom-out-mode .weather-badge-circle.flood { background: linear-gradient(135deg, #ef4444, #f87171) !important; color: #ef4444 !important; }
body.zoom-out-mode .weather-badge-circle.fog { background: linear-gradient(135deg, #94a3b8, #e2e8f0) !important; color: #94a3b8 !important; }

body.zoom-out-mode .weather-badge-circle * {
  display: none !important;
}

@keyframes zoom-out-dot-pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.18); }
}

/* NATIONAL SOVEREIGNTY TARGET MARKER STYLING (FIXED 22px CONTAINER FOR ZERO ZOOM DRIFT) */
.sovereignty-bullseye-wrapper {
  margin: 0 !important;
  padding: 0 !important;
  width: 22px !important;
  height: 22px !important;
  position: relative !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  pointer-events: auto !important;
}

.bullseye-target-inner {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(239, 68, 68, 0.3);
  border: 3px solid #ef4444;
  position: absolute;
  top: 0;
  left: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 15px rgba(239, 68, 68, 0.8);
  animation: bullseye-pulse 1.8s infinite;
}

.bullseye-target-inner::after {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ef4444;
}

@keyframes bullseye-pulse {
  0% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.8); }
  70% { box-shadow: 0 0 0 14px rgba(239, 68, 68, 0); }
  100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}

.sovereignty-label-text {
  position: absolute;
  left: 28px;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid rgba(239, 68, 68, 0.6);
  color: #fca5a5;
  font-size: 11px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 14px;
  white-space: nowrap;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.5);
  letter-spacing: 0.03em;
  pointer-events: none;
}

/* POPUP CUSTOM STYLING */
.maplibregl-popup-content {
  background: rgba(15, 23, 42, 0.96) !important;
  backdrop-filter: blur(16px) !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  border-radius: 16px !important;
  padding: 16px !important;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6) !important;
  color: #fff !important;
}

.maplibregl-popup-close-button {
  color: #94a3b8 !important;
  font-size: 18px !important;
  padding: 4px 8px !important;
}

.maplibregl-popup-anchor-top .maplibregl-popup-tip { border-bottom-color: rgba(15, 23, 42, 0.96) !important; }
.maplibregl-popup-anchor-bottom .maplibregl-popup-tip { border-top-color: rgba(15, 23, 42, 0.96) !important; }
.maplibregl-popup-anchor-left .maplibregl-popup-tip { border-right-color: rgba(15, 23, 42, 0.96) !important; }
.maplibregl-popup-anchor-right .maplibregl-popup-tip { border-left-color: rgba(15, 23, 42, 0.96) !important; }

/* MODAL OVERLAY */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(12px);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-card {
  background: #0f172a;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 20px;
  width: 90%;
  max-width: 450px;
  padding: 24px;
  color: #fff;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7);
  max-height: 90vh;
  overflow-y: auto;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-header h3 {
  font-size: 17px;
  font-weight: 700;
  color: #38bdf8;
}

.modal-close {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 22px;
  cursor: pointer;
}

.weather-type-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 14px;
}

.weather-opt {
  background: rgba(30, 41, 59, 0.8);
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 10px 6px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.weather-opt i {
  font-size: 22px;
  display: block;
  margin-bottom: 4px;
}

.weather-opt span {
  font-size: 11px;
  font-weight: 600;
  color: #cbd5e1;
}

.weather-opt:hover, .weather-opt.active {
  border-color: #38bdf8;
  background: rgba(56, 189, 248, 0.18);
}

.range-slider-wrap {
  background: rgba(30, 41, 59, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  padding: 12px;
  margin-bottom: 14px;
}

.range-slider {
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: #334155;
  outline: none;
  accent-color: #38bdf8;
  cursor: pointer;
}

.intensity-badge {
  font-size: 12px;
  font-weight: 700;
  color: #38bdf8;
  margin-top: 6px;
  text-align: center;
}

.input-field {
  width: 100%;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(30, 41, 59, 0.9);
  color: #fff;
  font-size: 13px;
  outline: none;
  margin-bottom: 12px;
}

.btn-submit {
  width: 100%;
  padding: 12px;
  border-radius: 10px;
  border: none;
  background: linear-gradient(135deg, #0284c7, #2563eb);
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-submit:hover {
  background: #0369a1;
}

.gps-info {
  font-size: 11px;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.1);
  padding: 8px 12px;
  border-radius: 8px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.expiry-tag {
  font-size: 10px;
  background: rgba(239, 68, 68, 0.2);
  color: #fca5a5;
  padding: 2px 6px;
  border-radius: 4px;
  margin-top: 4px;
  display: inline-block;
}

/* INITIAL GPS LOADING OVERLAY */
.initial-gps-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.94);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

.initial-gps-overlay.hidden {
  display: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

/* TOUCH-OPTIMIZED LANGUAGE SELECTOR DROPDOWN */
.lang-select-wrap {
  position: relative;
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(56, 189, 248, 0.4);
  border-radius: 20px;
  padding: 4px 10px;
  cursor: pointer;
  z-index: 1000;
  pointer-events: auto !important;
  touch-action: manipulation !important;
}

.lang-globe-icon {
  color: #38bdf8;
  font-size: 14px;
  pointer-events: none;
}

.lang-dropdown {
  background: transparent;
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  border: none;
  outline: none;
  cursor: pointer;
  padding: 4px 6px;
  font-family: inherit;
  pointer-events: auto !important;
  touch-action: manipulation !important;
  -webkit-tap-highlight-color: transparent;
}

.lang-dropdown option {
  background: #0f172a;
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  padding: 12px;
}

.gps-loader-card {
  background: rgba(30, 41, 59, 0.9);
  border: 1px solid rgba(56, 189, 248, 0.4);
  border-radius: 24px;
  padding: 36px;
  width: 90%;
  max-width: 440px;
  text-align: center;
  color: #fff;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.7);
}

.gps-pulse-ring {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0284c7, #2563eb);
  color: #fff;
  font-size: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px auto;
  box-shadow: 0 0 30px rgba(2, 132, 199, 0.8);
  animation: gps-ring-pulse 1.5s infinite;
}

@keyframes gps-ring-pulse {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(2, 132, 199, 0.7); }
  70% { transform: scale(1.05); box-shadow: 0 0 0 20px rgba(2, 132, 199, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(2, 132, 199, 0); }
}

.gps-loader-card h3 {
  font-size: 18px;
  font-weight: 800;
  color: #38bdf8;
  margin-bottom: 8px;
}

.gps-loader-card p {
  font-size: 13px;
  color: #cbd5e1;
  margin-bottom: 20px;
}

.gps-progress-bar {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
  overflow: hidden;
}

.gps-progress-fill {
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, #38bdf8, #3b82f6);
  animation: gps-fill 2s infinite linear;
}

@keyframes gps-fill {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

/* ====================================================
   MOBILE RESPONSIVE UI / PORTRAIT BOTTOM SHEET DRAWER
==================================================== */
.mobile-drag-handle {
  display: none;
}

@media (max-width: 768px) {
  /* Search Container: Full Width Floating Bar Top */
  .search-container {
    top: 12px !important;
    left: 12px !important;
    right: 12px !important;
    width: auto !important;
    max-width: none !important;
    transform: none !important;
  }

  .search-box {
    padding: 2px 14px !important;
    height: 44px !important;
    border-radius: 22px !important;
  }

  /* Native Mobile Bottom Sheet Drag Handle (Apple Maps / Google Maps Style) */
  .mobile-drag-handle {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    width: 100% !important;
    padding: 6px 0 8px 0 !important;
    margin: 0 auto !important;
    cursor: pointer !important;
    position: relative !important;
    top: 0 !important;
    left: 0 !important;
    transform: none !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    z-index: 100 !important;
  }

  .drag-handle-pill {
    width: 44px !important;
    height: 5px !important;
    background: rgba(56, 189, 248, 0.75) !important;
    border-radius: 3px !important;
    box-shadow: 0 0 10px rgba(56, 189, 248, 0.5) !important;
  }

  .mobile-drag-handle i {
    font-size: 11px !important;
    color: #38bdf8 !important;
    line-height: 1 !important;
    margin: 0 !important;
    padding: 0 !important;
  }


  /* Control Panel: Mobile Bottom Sheet Drawer */
  .control-panel {
    position: fixed !important;
    top: auto !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    border-radius: 20px 20px 0 0 !important;
    border-bottom: none !important;
    border-left: none !important;
    border-right: none !important;
    padding: 12px 16px 20px 16px !important;
    max-height: 82vh !important;
    overflow-y: auto !important;
    overflow-x: visible !important;
    z-index: 80 !important;
    box-shadow: 0 -10px 35px rgba(0, 0, 0, 0.75) !important;
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1) !important;
  }

  /* Mobile Collapsed State: Shows Header + Weather Summary Widget, leaves 85% Map visible! */
  .control-panel.mobile-collapsed {
    transform: translateY(calc(100% - 74px)) !important;
  }


  /* Prominent Floating My Location Button on Mobile */
  .btn-my-location-floating {
    bottom: 88px !important;
    right: 16px !important;
    padding: 10px 18px !important;
    font-size: 13px !important;
    border-radius: 30px !important;
    box-shadow: 0 8px 24px rgba(2, 132, 199, 0.6) !important;
  }

  /* Map Controls reposition for Mobile */
  .maplibregl-ctrl-top-right {
    top: 64px !important;
    right: 12px !important;
  }
}
