/* ==========================================================================
   DIU Smart Campus & Surrounding Area Navigator - Cyber Emerald Stylesheet
   Design System: Obsidian Dark + Cyber Emerald (#00f59b) + Translucent Glass
   ========================================================================== */

:root {
  --bg-main: #060a08;
  --bg-surface: rgba(13, 22, 18, 0.88);
  --bg-surface-elevated: rgba(19, 34, 28, 0.95);
  --bg-card: rgba(16, 28, 23, 0.75);
  --border-glass: rgba(0, 245, 155, 0.18);
  --border-hover: rgba(0, 245, 155, 0.45);
  
  --emerald-neon: #00f59b;
  --emerald-primary: #10b981;
  --emerald-dark: #064e3b;
  --cyan-accent: #38bdf8;
  --amber-accent: #f59e0b;
  --rose-accent: #f43f5e;
  --purple-accent: #a855f7;
  
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  
  --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-mono: 'Fira Code', monospace;
  --shadow-neon: 0 0 20px rgba(0, 245, 155, 0.25);
  --shadow-lg: 0 10px 30px -5px rgba(0, 0, 0, 0.6);
  --transition-smooth: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-main);
  color: var(--text-primary);
  min-height: 100vh;
  overflow: hidden;
  user-select: none;
}

/* ================= HEADER / TOP NAVBAR ================= */
.app-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 64px;
  background: var(--bg-surface);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-glass);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  z-index: 1000;
}

.brand-section {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-logo-badge {
  width: 42px;
  height: 42px;
  background: linear-gradient(135deg, #059669 0%, #00f59b 100%);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: #060a08;
  box-shadow: 0 0 16px rgba(0, 245, 155, 0.4);
}

.brand-text h1 {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 8px;
}

.brand-text h1 span {
  color: var(--emerald-neon);
  text-shadow: 0 0 12px rgba(0, 245, 155, 0.4);
}

.brand-subtitle {
  font-size: 11px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-dot {
  width: 7px;
  height: 7px;
  background-color: var(--emerald-neon);
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 0 8px var(--emerald-neon);
  animation: pulse-dot 2s infinite ease-in-out;
}

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

/* Header View Mode Switcher */
.view-switcher-group {
  display: flex;
  background: rgba(0, 0, 0, 0.4);
  padding: 4px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-glass);
}

.view-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  padding: 8px 18px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition-smooth);
}

.view-btn.active {
  background: linear-gradient(135deg, rgba(0, 245, 155, 0.25), rgba(16, 185, 129, 0.35));
  color: var(--emerald-neon);
  border: 1px solid var(--emerald-neon);
  box-shadow: 0 0 12px rgba(0, 245, 155, 0.3);
}

.view-btn:hover:not(.active) {
  color: var(--text-primary);
}

/* Header Actions */
.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.action-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  color: var(--text-primary);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition-smooth);
}

.action-btn:hover {
  background: rgba(0, 245, 155, 0.15);
  border-color: var(--emerald-neon);
  color: var(--emerald-neon);
}

.action-btn.emergency-btn {
  background: rgba(244, 63, 94, 0.15);
  border-color: rgba(244, 63, 94, 0.4);
  color: #fb7185;
}

.action-btn.emergency-btn:hover {
  background: rgba(244, 63, 94, 0.3);
  box-shadow: 0 0 12px rgba(244, 63, 94, 0.4);
}

/* ================= MAIN CONTAINER ================= */
.main-wrapper {
  position: absolute;
  top: 64px;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
}

/* ================= 2D MAP & 3D CANVAS VIEWPORTS ================= */
.viewport-container {
  position: relative;
  flex: 1;
  height: 100%;
}

#map-2d {
  width: 100%;
  height: 100%;
  background: #090f0c;
  z-index: 10;
}

#canvas-3d-container {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  opacity: 0;
  pointer-events: none;
  background: #070b09;
  z-index: 20;
  transition: opacity 0.35s ease;
}

#canvas-3d-container.active {
  opacity: 1;
  pointer-events: auto;
}

/* 3D Camera Controls Floating Bar */
.three-controls-bar {
  position: absolute;
  top: 20px;
  right: 24px;
  background: var(--bg-surface);
  backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 6px;
  display: flex;
  gap: 6px;
  z-index: 50;
  box-shadow: var(--shadow-lg);
}

.cam-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid transparent;
  color: var(--text-secondary);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
  transition: var(--transition-smooth);
}

.cam-btn:hover, .cam-btn.active {
  background: rgba(0, 245, 155, 0.2);
  color: var(--emerald-neon);
  border-color: var(--emerald-neon);
}

.cam-btn.light-mode-btn {
  border: 1px solid rgba(245, 158, 11, 0.35);
  color: #fbbf24;
}

.cam-btn.light-mode-btn:hover, .cam-btn.light-mode-btn.active {
  background: rgba(245, 158, 11, 0.25);
  border-color: #f59e0b;
  color: #fef08a;
}

/* 3D Tooltip */
.three-hud-tooltip {
  position: fixed;
  background: rgba(7, 14, 11, 0.92);
  backdrop-filter: blur(12px);
  border: 1px solid var(--emerald-neon);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 12px;
  font-weight: 600;
  padding: 6px 12px;
  pointer-events: none;
  z-index: 9999;
  box-shadow: 0 4px 16px rgba(0, 245, 155, 0.3);
  transform: translateY(-50%);
}

/* ================= FLOATING NAVIGATION HUD / SIDEBAR ================= */
.navigator-hud {
  position: absolute;
  top: 20px;
  left: 24px;
  width: 380px;
  max-height: calc(100% - 40px);
  background: var(--bg-surface);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  z-index: 500;
  transition: var(--transition-smooth);
  overflow: hidden;
}

.hud-header {
  padding: 16px 20px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.hud-header h2 {
  font-size: 15px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.hud-header h2 i {
  color: var(--emerald-neon);
}

.hud-body {
  padding: 16px 20px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Custom HUD Scrollbar */
.hud-body::-webkit-scrollbar {
  width: 4px;
}
.hud-body::-webkit-scrollbar-thumb {
  background: rgba(0, 245, 155, 0.25);
  border-radius: var(--radius-full);
}

/* Route Input Card */
.route-input-box {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 12px;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.input-row {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  transition: var(--transition-smooth);
}

.input-row:focus-within {
  border-color: var(--emerald-neon);
  box-shadow: 0 0 10px rgba(0, 245, 155, 0.2);
}

.input-icon {
  font-size: 13px;
  width: 16px;
  text-align: center;
}

.input-icon.origin { color: var(--emerald-neon); }
.input-icon.destination { color: var(--rose-accent); }

.styled-select {
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 500;
  width: 100%;
  outline: none;
  cursor: pointer;
}

.styled-select option {
  background: #0b1410;
  color: var(--text-primary);
  padding: 8px;
}

.swap-btn {
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glass);
  color: var(--emerald-neon);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-smooth);
  z-index: 5;
}

.swap-btn:hover {
  background: var(--emerald-neon);
  color: #060a08;
  transform: translateY(-50%) rotate(180deg);
  box-shadow: 0 0 12px rgba(0, 245, 155, 0.5);
}

/* Mode Switcher (Walking vs Rickshaw) */
.mode-selector {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.mode-card {
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  padding: 10px 8px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  transition: var(--transition-smooth);
}

.mode-card i {
  font-size: 18px;
  color: var(--text-secondary);
}

.mode-card span {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}

.mode-badge {
  font-size: 9px;
  background: rgba(255, 255, 255, 0.05);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--text-muted);
}

.mode-card.active {
  background: rgba(0, 245, 155, 0.15);
  border-color: var(--emerald-neon);
}

.mode-card.active i, .mode-card.active span {
  color: var(--emerald-neon);
}

.mode-card.active .mode-badge {
  background: rgba(0, 245, 155, 0.25);
  color: var(--emerald-neon);
}

/* Find Route Primary Button */
.find-route-btn {
  background: linear-gradient(135deg, #059669 0%, #00f59b 100%);
  color: #060a08;
  font-weight: 700;
  font-size: 14px;
  border: none;
  border-radius: var(--radius-sm);
  padding: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 18px rgba(0, 245, 155, 0.35);
  transition: var(--transition-smooth);
}

.find-route-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(0, 245, 155, 0.5);
}

.find-route-btn:active {
  transform: translateY(0);
}

/* ================= ROUTE SUMMARY HUD CARD ================= */
.route-summary-card {
  display: none;
  background: linear-gradient(145deg, rgba(16, 185, 129, 0.12), rgba(6, 78, 59, 0.35));
  border: 1px solid var(--emerald-neon);
  border-radius: var(--radius-md);
  padding: 14px;
  animation: slide-in 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.route-summary-card.active {
  display: block;
}

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

.summary-stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
  text-align: center;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(0, 245, 155, 0.2);
}

.stat-item .stat-value {
  font-size: 17px;
  font-weight: 800;
  font-family: var(--font-mono);
  color: var(--emerald-neon);
}

.stat-item .stat-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  margin-top: 2px;
}

.fare-pill {
  background: rgba(245, 158, 11, 0.2);
  border: 1px solid #f59e0b;
  color: #fbbf24;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 10px;
}

/* Step-by-Step Collapsible Section */
.steps-toggle-btn {
  width: 100%;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 12px;
  font-weight: 600;
  padding: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: var(--transition-smooth);
}

.steps-toggle-btn:hover {
  border-color: var(--emerald-neon);
}

.steps-container {
  display: none;
  margin-top: 10px;
  max-height: 220px;
  overflow-y: auto;
  padding-right: 4px;
}

.steps-container.open {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.step-card {
  background: rgba(0, 0, 0, 0.35);
  border-left: 3px solid var(--emerald-neon);
  border-radius: 4px;
  padding: 8px 10px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.step-card i {
  color: var(--emerald-neon);
  margin-top: 3px;
  font-size: 13px;
}

.step-text {
  font-size: 12px;
  line-height: 1.4;
}

.step-text .bn-text {
  color: var(--emerald-neon);
  font-weight: 600;
}

.step-text .en-text {
  color: var(--text-secondary);
  font-size: 11px;
  margin-top: 2px;
}

/* ================= QUICK PRESETS ================= */
.section-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  font-weight: 700;
}

.preset-chip-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.preset-chip {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: var(--transition-smooth);
}

.preset-chip:hover {
  background: rgba(0, 245, 155, 0.1);
  border-color: var(--emerald-neon);
  color: var(--emerald-neon);
  transform: translateX(3px);
}

/* Category Filter Pills */
.category-pills {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.category-pills::-webkit-scrollbar {
  height: 3px;
}

.cat-pill {
  white-space: nowrap;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-full);
  padding: 5px 10px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition-smooth);
}

.cat-pill.active, .cat-pill:hover {
  background: rgba(0, 245, 155, 0.15);
  border-color: var(--emerald-neon);
  color: var(--emerald-neon);
}

/* ================= LEAFLET CUSTOM MARKERS & STYLING ================= */
.custom-pulsing-marker {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.marker-inner {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 14px;
  box-shadow: 0 0 14px rgba(0, 0, 0, 0.6);
  border: 2px solid #fff;
  position: relative;
  z-index: 2;
  transition: transform 0.2s ease;
}

.custom-pulsing-marker:hover .marker-inner {
  transform: scale(1.2);
}

.marker-pulse {
  position: absolute;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  animation: marker-pulse-anim 2s infinite ease-out;
  z-index: 1;
}

@keyframes marker-pulse-anim {
  0% { transform: scale(1); opacity: 0.8; }
  100% { transform: scale(2.4); opacity: 0; }
}

/* Marker category color themes */
.marker-building .marker-inner { background: #059669; }
.marker-building .marker-pulse { background: #10b981; }

.marker-food .marker-inner { background: #d97706; }
.marker-food .marker-pulse { background: #f59e0b; }

.marker-facility .marker-inner { background: #0284c7; }
.marker-facility .marker-pulse { background: #38bdf8; }

.marker-entrance .marker-inner { background: #4f46e5; }
.marker-entrance .marker-pulse { background: #818cf8; }

.marker-mess .marker-inner { background: #9333ea; }
.marker-mess .marker-pulse { background: #c084fc; }

.marker-medical .marker-inner { background: #e11d48; }
.marker-medical .marker-pulse { background: #fb7185; }

.marker-area .marker-inner { background: #0d9488; }
.marker-area .marker-pulse { background: #2dd4bf; }

/* Leaflet Popup Custom Style */
.leaflet-popup-content-wrapper {
  background: rgba(13, 22, 18, 0.95) !important;
  backdrop-filter: blur(16px);
  border: 1px solid var(--emerald-neon) !important;
  border-radius: var(--radius-md) !important;
  color: var(--text-primary) !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7) !important;
}

.leaflet-popup-tip {
  background: rgba(13, 22, 18, 0.95) !important;
  border: 1px solid var(--emerald-neon);
}

.map-popup-card {
  padding: 4px;
}

.map-popup-card h3 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.map-popup-card .popup-bn {
  font-size: 12px;
  color: var(--emerald-neon);
  font-weight: 600;
  margin-bottom: 6px;
}

.map-popup-card p {
  font-size: 11px;
  color: var(--text-secondary);
  line-height: 1.4;
  margin-bottom: 10px;
}

.popup-actions {
  display: flex;
  gap: 6px;
}

.popup-btn {
  flex: 1;
  background: rgba(0, 245, 155, 0.15);
  border: 1px solid var(--emerald-neon);
  color: var(--emerald-neon);
  font-size: 10px;
  font-weight: 700;
  padding: 6px 8px;
  border-radius: 4px;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.popup-btn:hover {
  background: var(--emerald-neon);
  color: #060a08;
}

/* ================= MODAL / EMERGENCY CONTACTS ================= */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  z-index: 2000;
  align-items: center;
  justify-content: center;
}

.modal-overlay.active {
  display: flex;
}

.modal-card {
  width: 90%;
  max-width: 480px;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-lg);
  position: relative;
}

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

.modal-header h3 {
  font-size: 18px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--rose-accent);
}

.close-modal-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 18px;
  cursor: pointer;
}

.close-modal-btn:hover {
  color: var(--text-primary);
}

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

.contact-item {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.contact-info h4 {
  font-size: 13px;
  color: var(--text-primary);
}

.contact-info p {
  font-size: 11px;
  color: var(--text-secondary);
}

.contact-number {
  font-family: var(--font-mono);
  font-weight: 700;
  color: var(--emerald-neon);
  font-size: 13px;
  text-decoration: none;
  background: rgba(0, 245, 155, 0.1);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(0, 245, 155, 0.3);
}

.contact-number:hover {
  background: var(--emerald-neon);
  color: #060a08;
}

/* ================= MOBILE RESPONSIVE ================= */
@media (max-width: 768px) {
  .app-header {
    height: 60px;
    padding: 0 12px;
  }

  .brand-text h1 {
    font-size: 13px;
  }

  .brand-subtitle {
    display: none;
  }

  .app-nav-tabs .nav-tab-btn span {
    display: none;
  }

  .main-wrapper {
    top: 60px;
  }

  .navigator-hud {
    top: auto;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-height: 55vh;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }

  .three-controls-bar {
    top: 10px;
    right: 10px;
    padding: 4px;
    max-width: 90vw;
    overflow-x: auto;
  }

  .cam-btn span {
    display: none;
  }
}

/* ================= MULTI-MODULE NAV TABS & FULL-PAGE VIEWS ================= */
.app-nav-tabs {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(0, 0, 0, 0.45);
  padding: 4px 6px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-glass);
}

.nav-tab-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: var(--radius-full);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition-smooth);
}

.nav-tab-btn:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.06);
}

.nav-tab-btn.active {
  background: linear-gradient(135deg, rgba(0, 245, 155, 0.25) 0%, rgba(16, 185, 129, 0.2) 100%);
  color: var(--emerald-neon);
  border: 1px solid rgba(0, 245, 155, 0.4);
  box-shadow: 0 0 12px rgba(0, 245, 155, 0.2);
}

.module-view {
  display: none !important;
}

.module-view.active {
  display: flex !important;
}

.full-page-view.active {
  display: block !important;
  position: absolute;
  top: 64px;
  left: 0;
  right: 0;
  bottom: 0;
  overflow-y: auto;
  background: radial-gradient(circle at 50% 0%, rgba(16, 185, 129, 0.08) 0%, #060a08 60%);
  padding: 32px 24px 60px 24px;
  user-select: text;
}

.module-container {
  max-width: 1200px;
  margin: 0 auto;
}

.module-header-banner {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.15) 0%, rgba(6, 78, 59, 0.4) 100%);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 28px 32px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow-lg);
}

.banner-title h2 {
  font-size: 24px;
  font-weight: 800;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 6px;
}

.banner-title h2 i {
  color: var(--emerald-neon);
}

.banner-title p {
  color: var(--text-secondary);
  font-size: 14px;
}

.fleet-quick-stats {
  display: flex;
  gap: 16px;
}

.f-stat {
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  padding: 10px 18px;
  text-align: center;
}

.stat-num {
  display: block;
  font-size: 22px;
  font-weight: 800;
  font-family: var(--font-mono);
  color: var(--emerald-neon);
}

.stat-lbl {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
}

/* ================= 2D MAP SATELLITE LAYER SWITCH ================= */
.map-layer-switch {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 800;
}

.layer-btn {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glass);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 600;
  padding: 10px 16px;
  border-radius: var(--radius-full);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: var(--shadow-lg);
  transition: var(--transition-smooth);
}

.layer-btn:hover {
  border-color: var(--emerald-neon);
  box-shadow: var(--shadow-neon);
}

.layer-btn.active {
  background: var(--emerald-neon);
  color: #060a08;
  border-color: var(--emerald-neon);
}

.view-switcher-mini {
  display: flex;
  gap: 4px;
  background: rgba(0, 0, 0, 0.4);
  padding: 3px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.view-switcher-mini .view-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 4px;
  cursor: pointer;
}

.view-switcher-mini .view-btn.active {
  background: var(--emerald-primary);
  color: #fff;
}

/* ================= BUS TIMETABLE STYLES ================= */
.bus-search-bar {
  display: flex;
  gap: 16px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.search-input-wrap {
  flex: 1;
  min-width: 280px;
  position: relative;
}

.search-input-wrap i {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
}

.search-input-wrap input {
  width: 100%;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 14px 16px 14px 44px;
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 14px;
  outline: none;
  transition: var(--transition-smooth);
}

.search-input-wrap input:focus {
  border-color: var(--emerald-neon);
  box-shadow: var(--shadow-neon);
}

.shift-toggle-group {
  display: flex;
  gap: 8px;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 4px;
}

.shift-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition-smooth);
}

.shift-btn.active {
  background: var(--emerald-neon);
  color: #060a08;
  font-weight: 700;
}

.bus-routes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.bus-route-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 22px;
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.bus-route-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.route-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 14px;
}

.route-name-box h3 {
  font-size: 17px;
  font-weight: 700;
  color: var(--text-primary);
}

.route-name-box .bengali-title {
  font-size: 13px;
  color: var(--emerald-neon);
}

.route-badge-code {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.route-meta-row {
  display: flex;
  gap: 12px;
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.route-meta-row span {
  display: flex;
  align-items: center;
  gap: 6px;
}

.route-stops-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
}

.stop-tag {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 11px;
  color: var(--text-secondary);
  padding: 3px 8px;
  border-radius: 4px;
}

.timetable-list {
  background: rgba(0, 0, 0, 0.3);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
}

.timetable-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

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

.timetable-item .time-str {
  font-family: var(--font-mono);
  font-weight: 700;
  color: var(--emerald-neon);
  font-size: 13px;
}

.timetable-item .trip-notes {
  color: var(--text-muted);
}

.bus-footer-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

@media (max-width: 768px) {
  .bus-footer-info-grid {
    grid-template-columns: 1fr;
  }
}

.info-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 24px;
}

.info-card h3 {
  font-size: 16px;
  color: var(--emerald-neon);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.info-card ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 13px;
  color: var(--text-secondary);
}

.info-card ul li i {
  color: var(--emerald-neon);
  margin-right: 8px;
}

.info-card p {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

/* ================= FARE GUIDE & CALCULATOR STYLES ================= */
.fare-banner {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.15) 0%, rgba(180, 83, 9, 0.3) 100%);
}

.fare-calc-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin-bottom: 30px;
}

.fare-calc-card h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--amber-accent);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.calc-row {
  display: flex;
  align-items: flex-end;
  gap: 16px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.calc-input {
  flex: 1;
  min-width: 260px;
}

.calc-input label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.calc-swap {
  width: 44px;
  height: 44px;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  cursor: pointer;
  margin-bottom: 2px;
}

.calc-result-box {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: var(--radius-md);
  padding: 20px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.fare-metric-item {
  background: rgba(255, 255, 255, 0.03);
  padding: 14px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.fare-metric-item .f-val {
  font-size: 24px;
  font-weight: 800;
  font-family: var(--font-mono);
  color: var(--amber-accent);
}

.fare-metric-item .f-lbl {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

.fare-table-wrap {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 24px;
  overflow-x: auto;
}

.fare-table-wrap h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.fare-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 13px;
}

.fare-table th {
  padding: 12px 14px;
  background: rgba(0, 0, 0, 0.5);
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-glass);
  font-weight: 700;
}

.fare-table td {
  padding: 12px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
}

.fare-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

.fare-tag {
  font-family: var(--font-mono);
  font-weight: 700;
  color: var(--amber-accent);
  background: rgba(245, 158, 11, 0.1);
  padding: 3px 8px;
  border-radius: 4px;
  border: 1px solid rgba(245, 158, 11, 0.2);
}

/* ================= AREA DIRECTORY STYLES ================= */
.dir-banner {
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.15) 0%, rgba(3, 105, 161, 0.3) 100%);
}

.dir-filter-bar {
  margin-bottom: 24px;
}

.filter-group {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.dir-filter-btn {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glass);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition-smooth);
}

.dir-filter-btn.active {
  background: var(--cyan-accent);
  color: #060a08;
  font-weight: 700;
  border-color: var(--cyan-accent);
}

.directory-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 20px;
}

.dir-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 20px;
  transition: var(--transition-smooth);
}

.dir-card:hover {
  border-color: var(--cyan-accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.dir-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 10px;
}

.dir-card-header h4 {
  font-size: 16px;
  color: var(--text-primary);
}

.dir-card-header .dir-area-badge {
  font-size: 11px;
  font-weight: 700;
  color: var(--cyan-accent);
  background: rgba(56, 189, 248, 0.1);
  padding: 3px 8px;
  border-radius: 4px;
}

.dir-card p {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 14px;
}

.dir-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--text-muted);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: 10px;
}

.dir-nav-btn {
  background: rgba(0, 245, 155, 0.1);
  border: 1px solid rgba(0, 245, 155, 0.3);
  color: var(--emerald-neon);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.dir-nav-btn:hover {
  background: var(--emerald-neon);
  color: #060a08;
}

/* ================= DIU AI CHAT ASSISTANT STYLES ================= */
.action-btn.ai-btn {
  background: linear-gradient(135deg, rgba(0, 245, 155, 0.2) 0%, rgba(56, 189, 248, 0.2) 100%);
  border: 1px solid var(--emerald-neon);
  color: var(--emerald-neon);
  box-shadow: 0 0 12px rgba(0, 245, 155, 0.25);
}

.action-btn.ai-btn:hover {
  background: var(--emerald-neon);
  color: #060a08;
}

.ai-chat-card {
  max-width: 520px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
}

.ai-quick-prompts {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 12px;
  margin-bottom: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.ai-chip {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-glass);
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition-smooth);
}

.ai-chip:hover {
  border-color: var(--emerald-neon);
  color: var(--emerald-neon);
  background: rgba(0, 245, 155, 0.1);
}

.ai-chat-messages {
  flex: 1;
  max-height: 380px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 16px;
  padding-right: 6px;
}

.ai-msg {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.ai-msg.user {
  flex-direction: row-reverse;
}

.msg-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(0, 245, 155, 0.2);
  color: var(--emerald-neon);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
  border: 1px solid rgba(0, 245, 155, 0.3);
}

.ai-msg.user .msg-avatar {
  background: rgba(56, 189, 248, 0.2);
  color: var(--cyan-accent);
  border-color: rgba(56, 189, 248, 0.3);
}

.msg-bubble {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-primary);
  max-width: 85%;
}

.ai-msg.user .msg-bubble {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.2) 0%, rgba(5, 150, 105, 0.3) 100%);
  border-color: rgba(0, 245, 155, 0.3);
}

.ai-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  background: var(--emerald-neon);
  color: #060a08;
  font-weight: 700;
  font-size: 11px;
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.ai-action-btn:hover {
  box-shadow: var(--shadow-neon);
  transform: translateY(-1px);
}

.ai-chat-input-row {
  display: flex;
  gap: 10px;
}

.ai-chat-input-row input {
  flex: 1;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 13px;
  outline: none;
  transition: var(--transition-smooth);
}

.ai-chat-input-row input:focus {
  border-color: var(--emerald-neon);
  box-shadow: var(--shadow-neon);
}

.ai-send-btn {
  width: 44px;
  height: 44px;
  background: var(--emerald-neon);
  color: #060a08;
  border: none;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 16px;
  transition: var(--transition-smooth);
}

.ai-send-btn:hover {
  box-shadow: var(--shadow-neon);
  transform: scale(1.05);
}


