/* ============================================================
   PWA Arrival Coordinator - Modern Sleek UI
   ============================================================ */

:root {
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  
  /* Color Palette - Dark Sleek Glassmorphism */
  --bg-deep: #07090e;
  --bg-surface: #0f1422;
  --bg-surface-elevated: #161c2e;
  --bg-glass: rgba(18, 25, 42, 0.82);
  --bg-glass-strong: rgba(22, 30, 52, 0.94);
  
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(59, 130, 246, 0.35);
  
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  
  --primary: #3b82f6;
  --primary-glow: rgba(59, 130, 246, 0.4);
  --success: #10b981;
  --success-glow: rgba(16, 185, 129, 0.3);
  --warning: #f59e0b;
  --danger: #ef4444;
  --danger-glow: rgba(239, 68, 68, 0.4);
  --purple: #8b5cf6;

  --shadow-card: 0 10px 30px -10px rgba(0, 0, 0, 0.5), 0 0 1px 1px rgba(255, 255, 255, 0.05);
  --shadow-floating: 0 20px 40px -15px rgba(0, 0, 0, 0.7);
  --radius-lg: 18px;
  --radius-md: 12px;
  --radius-full: 9999px;
  
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-deep);
  color: var(--text-main);
  height: 100vh;
  width: 100vw;
  overflow: hidden;
  position: fixed;
  display: flex;
  flex-direction: column;
}

/* ============================================================
   Typography & Utilities
   ============================================================ */
h1, h2, h3, h4 {
  font-weight: 700;
  letter-spacing: -0.02em;
}

.text-gradient {
  background: linear-gradient(135deg, #60a5fa 0%, #a855f7 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--border-subtle);
}

.badge-live {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border-color: rgba(16, 185, 129, 0.3);
}

.badge-live::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #34d399;
  box-shadow: 0 0 8px #34d399;
  animation: pulse-dot 1.5s infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

.hidden {
  display: none !important;
}

/* ============================================================
   Buttons & Inputs
   ============================================================ */
button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  outline: none;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-primary {
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  color: white;
  padding: 14px 22px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 1rem;
  box-shadow: 0 8px 20px -6px var(--primary-glow);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-primary:active {
  transform: scale(0.98);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-main);
  border: 1px solid var(--border-subtle);
  padding: 12px 18px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
}

.btn-icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--bg-glass);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.input-field {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  color: var(--text-main);
  font-size: 1rem;
  outline: none;
  transition: border-color 0.2s;
}

.input-field:focus {
  border-color: var(--primary);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

/* ============================================================
   Lobby & Home Screen
   ============================================================ */
#lobby-view {
  position: absolute;
  inset: 0;
  z-index: 50;
  overflow-y: auto;
  background: radial-gradient(circle at 50% 10%, #172138 0%, #07090e 65%);
  padding: calc(var(--safe-top) + 24px) 20px calc(var(--safe-bottom) + 30px);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lobby-container {
  width: 100%;
  max-width: 460px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.brand-header {
  text-align: center;
  margin-top: 10px;
}

.brand-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(59, 130, 246, 0.25);
  border-radius: var(--radius-full);
  color: #60a5fa;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 12px;
}

.brand-title {
  font-size: 2.2rem;
  margin-bottom: 8px;
}

.brand-subtitle {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.4;
}

.glass-card {
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-card);
}

.tabs-nav {
  display: flex;
  background: rgba(0, 0, 0, 0.25);
  border-radius: var(--radius-md);
  padding: 4px;
  margin-bottom: 20px;
  border: 1px solid var(--border-subtle);
}

.tab-btn {
  flex: 1;
  padding: 10px;
  background: transparent;
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.9rem;
  border-radius: 8px;
}

.tab-btn.active {
  background: var(--bg-surface-elevated);
  color: var(--text-main);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.preset-destinations {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}

.preset-chip {
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  color: var(--text-muted);
  cursor: pointer;
}

.preset-chip:hover, .preset-chip.active {
  background: rgba(59, 130, 246, 0.15);
  border-color: var(--primary);
  color: #93c5fd;
}

/* ============================================================
   Live Coordination View
   ============================================================ */
#live-view {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* Map Container */
#map {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: #0f1422;
}

/* Custom Leaflet Map Controls Position & Styling */
.leaflet-top.leaflet-left {
  top: calc(var(--safe-top) + 80px);
  left: 16px;
}

.leaflet-bar {
  border: 1px solid var(--border-subtle) !important;
  border-radius: var(--radius-md) !important;
  overflow: hidden;
  box-shadow: var(--shadow-card) !important;
}

.leaflet-bar a {
  background-color: var(--bg-glass-strong) !important;
  color: var(--text-main) !important;
  border-bottom: 1px solid var(--border-subtle) !important;
}

/* Floating Map Controls (Locate Me & Simulate) */
.map-floating-controls {
  position: absolute;
  bottom: 125px;
  right: 16px;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}

.btn-map-control {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--bg-glass-strong);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-subtle);
  color: #60a5fa;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-card);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-map-control:hover {
  background: var(--bg-surface-elevated);
  transform: scale(1.08);
  border-color: var(--primary);
  color: #93c5fd;
}

.btn-map-control:active {
  transform: scale(0.92);
}

.btn-map-control.locating svg {
  animation: spin-pulse 1s infinite linear;
}

@keyframes spin-pulse {
  0% { transform: rotate(0deg) scale(1); }
  50% { transform: rotate(180deg) scale(1.15); }
  100% { transform: rotate(360deg) scale(1); }
}

.map-sim-btn {
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  font-size: 0.8rem;
  padding: 8px 14px;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-card);
}

/* Location Status in Lobby */
.loc-detect-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: var(--radius-full);
  color: #34d399;
  font-size: 0.8rem;
  font-weight: 500;
  margin-top: 10px;
  transition: all 0.3s ease;
}

.loc-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: pulse-dot 1.5s infinite;
}

.btn-text-link {
  background: transparent;
  color: #60a5fa;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 6px;
  transition: all 0.2s;
  cursor: pointer;
}

.btn-text-link:hover {
  background: rgba(96, 165, 250, 0.12);
  text-decoration: underline;
}

/* Top App Bar */
.top-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  padding: calc(var(--safe-top) + 12px) 16px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  pointer-events: none;
}

.top-bar > * {
  pointer-events: auto;
}

.room-meta-pill {
  background: var(--bg-glass);
  backdrop-filter: blur(14px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 8px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow-card);
  max-width: calc(100vw - 120px);
}

.room-details {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.room-title-text {
  font-size: 0.95rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.room-dest-text {
  font-size: 0.75rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Floating Driving Quick-Status Chips */
.quick-status-bar {
  position: absolute;
  top: calc(var(--safe-top) + 72px);
  left: 0;
  right: 0;
  z-index: 15;
  display: flex;
  justify-content: center;
  padding: 0 16px;
  pointer-events: none;
}

.quick-status-chips {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  border: 1px solid var(--border-subtle);
  padding: 6px 10px;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-floating);
  overflow-x: auto;
  max-width: 100%;
}

.status-chip {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid transparent;
  padding: 8px 14px;
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  font-weight: 600;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-chip:active {
  transform: scale(0.96);
}

.status-chip.active {
  background: rgba(59, 130, 246, 0.2);
  border-color: var(--primary);
  color: #93c5fd;
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.3);
}

.status-chip.status-arrived.active {
  background: rgba(16, 185, 129, 0.25);
  border-color: var(--success);
  color: #6ee7b7;
  box-shadow: 0 0 16px rgba(16, 185, 129, 0.4);
}

/* Bottom Sheet / Drawer */
.bottom-sheet {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 25;
  background: var(--bg-glass-strong);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--border-subtle);
  border-radius: 24px 24px 0 0;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  max-height: 85vh;
  padding-bottom: var(--safe-bottom);
}

.sheet-handle-area {
  width: 100%;
  padding: 12px 0 6px;
  display: flex;
  justify-content: center;
  cursor: grab;
}

.sheet-handle {
  width: 44px;
  height: 5px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 3px;
}

.sheet-summary {
  padding: 6px 20px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.my-eta-hero {
  display: flex;
  flex-direction: column;
}

.eta-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.eta-value {
  font-size: 1.6rem;
  font-weight: 800;
  color: #38bdf8;
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.eta-dist {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-muted);
}

.btn-arrived-action {
  background: linear-gradient(135deg, #059669, #10b981);
  color: white;
  padding: 12px 20px;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 6px 18px -4px rgba(16, 185, 129, 0.5);
}

.btn-arrived-action:active {
  transform: scale(0.96);
}

.sheet-content {
  padding: 0 20px 20px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.participants-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 10px;
  border-top: 1px solid var(--border-subtle);
}

.participants-header h3 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-dim);
}

.participants-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.participant-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 12px 14px;
}

.p-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.p-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1rem;
  color: white;
  background: #3b82f6;
  border: 2px solid rgba(255, 255, 255, 0.2);
}

.p-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.p-name {
  font-weight: 600;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 6px;
}

.p-status {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.p-right {
  text-align: right;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.p-eta {
  font-weight: 700;
  font-size: 1rem;
  color: #38bdf8;
}

.p-dist {
  font-size: 0.75rem;
  color: var(--text-dim);
}

/* ============================================================
   Custom Map Markers
   ============================================================ */
.dest-marker-pin {
  width: 38px;
  height: 38px;
  border-radius: 50% 50% 50% 0;
  background: #ef4444;
  position: absolute;
  transform: rotate(-45deg);
  left: 50%;
  top: 50%;
  margin: -24px 0 0 -19px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 15px rgba(239, 68, 68, 0.6);
  border: 2px solid white;
}

.dest-marker-pin::after {
  content: '🎯';
  transform: rotate(45deg);
  font-size: 18px;
}

.dest-pulse-ring {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: rgba(239, 68, 68, 0.35);
  position: absolute;
  top: 50%;
  left: 50%;
  margin: -27px 0 0 -27px;
  animation: ring-pulse 2s infinite ease-out;
  pointer-events: none;
}

@keyframes ring-pulse {
  0% { transform: scale(0.6); opacity: 1; }
  100% { transform: scale(1.8); opacity: 0; }
}

.vehicle-marker-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.vehicle-marker-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: white;
  font-weight: 700;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid white;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  position: relative;
  transition: transform 0.25s ease;
}

.vehicle-heading-arrow {
  position: absolute;
  top: -8px;
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-bottom: 8px solid white;
  filter: drop-shadow(0 2px 3px rgba(0,0,0,0.5));
}

.vehicle-marker-label {
  background: rgba(15, 20, 34, 0.9);
  color: white;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
  white-space: nowrap;
  margin-top: 4px;
  border: 1px solid var(--border-subtle);
  box-shadow: 0 2px 6px rgba(0,0,0,0.4);
}

/* ============================================================
   Modals & Overlays
   ============================================================ */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-card {
  width: 100%;
  max-width: 440px;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: var(--shadow-floating);
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.modal-icon-header {
  font-size: 2.2rem;
  text-align: center;
}

.modal-card h2 {
  font-size: 1.4rem;
  text-align: center;
}

.modal-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.5;
  text-align: center;
}

.safety-check-box {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
  border-radius: var(--radius-md);
  padding: 14px;
  font-size: 0.85rem;
  color: #fca5a5;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

/* Wake Lock Badge */
.wakelock-badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: var(--radius-full);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(16, 185, 129, 0.12);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.25);
}

/* Toast Notifications */
#toast-container {
  position: fixed;
  top: calc(var(--safe-top) + 20px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 200;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}

.toast {
  background: rgba(18, 25, 42, 0.95);
  backdrop-filter: blur(14px);
  color: white;
  padding: 12px 20px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
  font-size: 0.9rem;
  font-weight: 600;
  box-shadow: var(--shadow-floating);
  animation: toast-in 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: auto;
}

@keyframes toast-in {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   Map Location Picker Modal
   ============================================================ */
.map-picker-modal-content {
  position: relative;
  width: 100vw;
  height: 100vh;
  background: var(--bg-deep);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.picker-top-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: max(14px, env(safe-area-inset-top, 14px)) 16px 12px;
  background: linear-gradient(180deg, rgba(7, 9, 14, 0.95) 0%, rgba(7, 9, 14, 0.8) 75%, transparent 100%);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.picker-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.picker-icon-badge {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(59, 130, 246, 0.15);
  border: 1px solid var(--border-glow);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.picker-close-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.picker-close-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  transform: scale(1.05);
}

.picker-search-container {
  position: relative;
  width: 100%;
}

.picker-search-container input {
  width: 100%;
  padding: 11px 84px 11px 14px;
  background: rgba(22, 28, 46, 0.9);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-md);
  color: #fff;
  font-size: 0.9rem;
  outline: none;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
  transition: border-color 0.2s;
}

.picker-search-container input:focus {
  border-color: #60a5fa;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.3);
}

.picker-search-btn {
  position: absolute;
  right: 4px;
  top: 4px;
  bottom: 4px;
  padding: 0 16px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 9px;
  font-weight: 600;
  font-size: 0.82rem;
  cursor: pointer;
  transition: background 0.2s;
}

.picker-search-btn:hover {
  background: #2563eb;
}

.picker-results-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-md);
  max-height: 220px;
  overflow-y: auto;
  z-index: 1010;
  box-shadow: var(--shadow-floating);
}

.picker-search-item {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: background 0.15s;
  font-size: 0.85rem;
  color: var(--text-main);
  display: flex;
  flex-direction: column;
  gap: 2px;
}

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

.picker-search-item:hover {
  background: rgba(59, 130, 246, 0.15);
}

.picker-search-item .item-title {
  font-weight: 600;
  color: #fff;
}

.picker-search-item .item-subtitle {
  font-size: 0.75rem;
  color: var(--text-dim);
}

#picker-map {
  width: 100%;
  height: 100%;
  position: relative;
  z-index: 1;
}

.picker-hint-pill {
  position: absolute;
  top: 130px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 999;
  background: rgba(15, 20, 34, 0.88);
  backdrop-filter: blur(8px);
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid var(--border-subtle);
  color: #94a3b8;
  font-size: 0.75rem;
  font-weight: 500;
  pointer-events: none;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

.picker-recenter-btn {
  position: absolute;
  right: 16px;
  bottom: 175px;
  z-index: 999;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: rgba(15, 20, 34, 0.92);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-glow);
  color: #60a5fa;
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6);
  transition: transform 0.2s, background 0.2s;
}

.picker-recenter-btn:hover {
  transform: scale(1.08);
  background: rgba(22, 30, 52, 0.95);
}

.picker-bottom-card {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 999;
  padding: 16px 20px max(16px, env(safe-area-inset-bottom, 16px));
  background: rgba(15, 20, 34, 0.95);
  backdrop-filter: blur(16px);
  border-top: 1px solid var(--border-subtle);
  box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.picker-dest-info {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.picker-dest-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}

.picker-dest-title {
  font-weight: 600;
  font-size: 0.95rem;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.picker-dest-subtitle {
  font-size: 0.75rem;
  color: var(--text-dim);
  margin-top: 2px;
}

.dest-preview-card {
  transition: all 0.2s ease;
}

.dest-preview-card:hover {
  background: rgba(59, 130, 246, 0.14) !important;
  border-color: rgba(59, 130, 246, 0.45) !important;
  transform: translateY(-1px);
}
