/* Gagarin Taxi - Operator Dispatch Center Premium Styling */

:root {
  /* HSL Color System */
  --bg-color: #0b0f19;
  --panel-bg: rgba(18, 25, 41, 0.7);
  --panel-bg-solid: #121929;
  --border-color: rgba(255, 255, 255, 0.08);
  --border-color-glow: rgba(74, 144, 217, 0.25);
  
  --text-primary: #f3f4f6;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;
  
  /* Brand Accents */
  --primary: hsl(210, 85%, 55%);       /* Gagarin Neon Blue */
  --primary-glow: hsla(210, 85%, 55%, 0.35);
  --secondary: hsl(45, 100%, 50%);      /* Amber Gold */
  --secondary-glow: hsla(45, 100%, 50%, 0.3);
  
  --success: hsl(142, 70%, 45%);       /* Emerald Green */
  --success-glow: hsla(142, 70%, 45%, 0.3);
  --danger: hsl(350, 80%, 55%);        /* Ruby Red */
  --danger-glow: hsla(350, 80%, 55%, 0.3);
  --info: hsl(190, 80%, 50%);
  
  /* Fonts */
  --font-display: 'Outfit', 'Inter', sans-serif;
  --font-sans: 'Inter', sans-serif;
  
  /* Glassmorphism */
  --glass-blur: blur(12px);
  --card-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
  --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* RESET & CORE STYLES */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-color);
  color: var(--text-primary);
  height: 100vh;
  overflow: hidden;
  display: flex;
  background-image: 
    radial-gradient(at 0% 0%, hsla(210, 80%, 20%, 0.15) 0px, transparent 50%),
    radial-gradient(at 100% 100%, hsla(45, 80%, 15%, 0.1) 0px, transparent 50%);
}

/* APP CONTAINER */
.app-container {
  display: grid;
  grid-template-columns: 320px 1fr;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

/* SIDEBAR LEFT */
.sidebar-left {
  background: var(--panel-bg);
  backdrop-filter: var(--glass-blur);
  border-right: 1px solid var(--border-color);
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
  height: 100%;
  gap: 28px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px;
}

.brand-logo {
  width: 42px;
  height: 42px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 15px var(--primary-glow);
}

.logo-icon {
  font-size: 20px;
  color: #fff;
}

.brand-text h2 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 1.5px;
  background: linear-gradient(to right, #fff, #9ca3af);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-text span {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 500;
  display: block;
  margin-top: -2px;
}

/* NAVIGATION */
.nav-menu {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-grow: 1;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  border-radius: 10px;
  transition: var(--transition-smooth);
}

.nav-item i {
  font-size: 16px;
  width: 20px;
  text-align: center;
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-primary);
}

.nav-item.active {
  background: rgba(74, 144, 217, 0.12);
  color: var(--primary);
  border-left: 3px solid var(--primary);
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}

.badge {
  margin-left: auto;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 20px;
  font-weight: 600;
}

.badge-accent {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 0 10px var(--primary-glow);
}

.badge-outline {
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
}

/* CALL SIMULATOR PANEL */
.simulator-panel {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

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

.simulator-header h3 {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 6px;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background: var(--success);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--success);
  animation: pulse 1.5s infinite;
}

.simulator-desc {
  font-size: 11px;
  color: var(--text-secondary);
  line-height: 1.4;
}

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

/* INCOMING CALL WIDGET */
.incoming-call-card {
  background: linear-gradient(135deg, rgba(18, 48, 38, 0.85), rgba(9, 25, 20, 0.9));
  border: 1px solid var(--success);
  box-shadow: 0 0 20px var(--success-glow);
  border-radius: 14px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  animation: slideUp 0.4s cubic-bezier(0.18, 0.89, 0.32, 1.28);
}

.incoming-call-card.hidden {
  display: none !important;
}

.caller-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.caller-avatar {
  width: 36px;
  height: 36px;
  background: var(--success);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  animation: vibrate 0.5s infinite;
}

.caller-details h4 {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.caller-details span {
  font-size: 10px;
  color: var(--text-secondary);
}

.call-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

/* MIDDLE WORKSPACE */
.main-workspace {
  display: flex;
  flex-direction: column;
  padding: 24px;
  overflow-y: auto;
  gap: 24px;
  height: 100%;
}

/* HEADER */
.workspace-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.header-search {
  position: relative;
  width: 400px;
}

.header-search i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 14px;
}

.header-search input {
  width: 100%;
  padding: 10px 16px 10px 42px;
  background: var(--panel-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
  transition: var(--transition-smooth);
}

.header-search input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 10px var(--primary-glow);
}

.header-profile {
  display: flex;
  align-items: center;
  gap: 16px;
}

.operator-status {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--panel-bg);
  padding: 8px 14px;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  font-size: 13px;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.status-dot.online {
  background: var(--success);
  box-shadow: 0 0 8px var(--success);
}

.system-time {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  color: var(--primary);
  background: var(--panel-bg);
  padding: 8px 14px;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  letter-spacing: 0.5px;
}

/* STATS GRID */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.stat-card {
  background: var(--panel-bg);
  backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: var(--card-shadow);
  transition: var(--transition-smooth);
}

.stat-card:hover {
  transform: translateY(-2px);
  border-color: var(--border-color-glow);
}

.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

.icon-blue {
  background: rgba(74, 144, 217, 0.1);
  color: var(--primary);
}

.icon-yellow {
  background: rgba(245, 158, 11, 0.1);
  color: var(--secondary);
}

.icon-green {
  background: rgba(16, 185, 129, 0.1);
  color: var(--success);
}

.icon-purple {
  background: rgba(139, 92, 246, 0.1);
  color: #8b5cf6;
}

.stat-data {
  display: flex;
  flex-direction: column;
}

.stat-label {
  font-size: 11px;
  color: var(--text-secondary);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.stat-data h3 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  margin-top: 2px;
}

/* WORKSPACE GRID */
.workspace-grid {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 20px;
  flex-grow: 1;
}

/* CARD GLASS */
.card-glass {
  background: var(--panel-bg);
  backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 20px;
  box-shadow: var(--card-shadow);
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 12px;
}

.section-title h3 {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-title h3 i {
  color: var(--primary);
}

/* CHANNEL INDICATOR */
.channel-indicator {
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 20px;
  text-transform: uppercase;
}

.channel-indicator.idle {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-muted);
}

.channel-indicator.active {
  background: var(--success-glow);
  color: var(--success);
  border: 1px solid var(--success);
  animation: pulse 1.5s infinite;
}

/* ORDER FORM */
.new-order-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.form-row {
  display: flex;
  gap: 12px;
}

.flex-2 { flex: 2; }
.flex-3 { flex: 3; }

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
}

.input-with-icon {
  position: relative;
  display: flex;
  align-items: center;
}

.input-with-icon > i {
  position: absolute;
  left: 12px;
  color: var(--text-muted);
  font-size: 13px;
}

.location-start { color: var(--primary) !important; }
.location-end { color: var(--secondary) !important; }

.input-with-icon input,
.new-order-form select {
  width: 100%;
  padding: 10px 12px 10px 36px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
  transition: var(--transition-smooth);
}

.input-with-icon input:focus,
.new-order-form select:focus {
  border-color: var(--primary);
  background: rgba(255, 255, 255, 0.06);
}

.btn-geo {
  position: absolute;
  right: 8px;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  transition: var(--transition-smooth);
}

.btn-geo:hover {
  color: var(--primary);
}

/* BUTTONS */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 13px;
  padding: 10px 16px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: var(--transition-smooth);
  color: #fff;
}

.btn-sm {
  padding: 8px 12px;
  font-size: 11px;
  border-radius: 6px;
}

.btn-full {
  width: 100%;
  padding: 12px;
  font-size: 14px;
  border-radius: 10px;
}

.btn-primary {
  background: var(--primary);
  box-shadow: 0 4px 12px var(--primary-glow);
}

.btn-primary:hover {
  filter: brightness(1.1);
  box-shadow: 0 4px 18px var(--primary-glow);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
}

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

.btn-success {
  background: var(--success);
  box-shadow: 0 4px 12px var(--success-glow);
}

.btn-success:hover {
  filter: brightness(1.1);
}

.btn-danger {
  background: var(--danger);
  box-shadow: 0 4px 12px var(--danger-glow);
}

.btn-danger:hover {
  filter: brightness(1.1);
}

.btn-circle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* LIVE ORDERS BOARD */
.tabs {
  display: flex;
  gap: 4px;
  background: rgba(255, 255, 255, 0.03);
  padding: 4px;
  border-radius: 10px;
  border: 1px solid var(--border-color);
}

.tab-btn {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 11px;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: var(--transition-smooth);
}

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

.tab-btn.active {
  background: rgba(255, 255, 255, 0.06);
  color: var(--primary);
  font-weight: 600;
}

.table-container {
  overflow-x: auto;
  min-height: 180px;
}

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

.orders-table th {
  padding: 10px 12px;
  color: var(--text-muted);
  font-weight: 600;
  border-bottom: 1px solid var(--border-color);
  text-transform: uppercase;
  font-size: 10px;
  letter-spacing: 0.5px;
}

.orders-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-color);
  vertical-align: middle;
}

.orders-table tbody tr {
  transition: var(--transition-smooth);
}

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

/* BADGES FOR TABLE */
.badge-table {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
  display: inline-block;
}

.badge-table.start { background: rgba(74, 144, 217, 0.12); color: var(--primary); }
.badge-table.comfort { background: rgba(245, 158, 11, 0.12); color: var(--secondary); }
.badge-table.business { background: rgba(139, 92, 246, 0.12); color: #a78bfa; }

.status-badge {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 20px;
}

.status-badge.pending { background: rgba(245, 158, 11, 0.15); color: var(--secondary); border: 1px solid rgba(245, 158, 11, 0.3); }
.status-badge.active { background: rgba(74, 144, 217, 0.15); color: var(--primary); border: 1px solid rgba(74, 144, 217, 0.3); }
.status-badge.completed { background: rgba(16, 185, 129, 0.15); color: var(--success); border: 1px solid rgba(16, 185, 129, 0.3); }

/* CHANNELS */
.channel-cell {
  display: flex;
  align-items: center;
  gap: 6px;
}

.channel-cell i {
  font-size: 13px;
}

.channel-cell.app { color: var(--primary); }
.channel-cell.call { color: #8b5cf6; }

.route-cell {
  max-width: 180px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.route-cell small {
  color: var(--text-muted);
  display: block;
}

/* EMPTY STATE */
.empty-state {
  text-align: center;
  padding: 40px !important;
  color: var(--text-muted);
}

.empty-state i {
  font-size: 32px;
  margin-bottom: 10px;
  color: var(--text-muted);
  opacity: 0.5;
}

.empty-state p {
  font-size: 12px;
}

/* RIGHT SIDEBAR: MAP & DRIVER */
.sidebar-right {
  display: none !important;
}

.map-section {
  height: 350px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.map-header, .drivers-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.map-header h3, .drivers-header h3 {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.map-container {
  flex-grow: 1;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border-color);
}

/* LEAFLET OVERRIDES */
.leaflet-container {
  background: #0f1422 !important;
}

.leaflet-bar {
  border: 1px solid var(--border-color) !important;
  background-color: var(--panel-bg-solid) !important;
}

.leaflet-bar a {
  background-color: var(--panel-bg-solid) !important;
  color: var(--text-primary) !important;
  border-bottom: 1px solid var(--border-color) !important;
  transition: var(--transition-smooth);
}

.leaflet-bar a:hover {
  background-color: rgba(255, 255, 255, 0.05) !important;
}

/* CUSTOM POPUP STYLES */
.leaflet-popup-content-wrapper {
  background: var(--panel-bg-solid) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: 8px !important;
  box-shadow: var(--card-shadow) !important;
}

.leaflet-popup-tip {
  background: var(--panel-bg-solid) !important;
  border: 1px solid var(--border-color) !important;
}

/* DRIVER LIST BOX */
.drivers-section {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow: hidden;
}

.driver-summary-tag {
  font-size: 11px;
  font-weight: 600;
  color: var(--primary);
  background: rgba(74, 144, 217, 0.12);
  padding: 2px 8px;
  border-radius: 20px;
}

.driver-filter {
  display: flex;
  gap: 6px;
  margin-bottom: 4px;
}

.filter-tag {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 10px;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 20px;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.filter-tag:hover {
  color: var(--text-primary);
  border-color: var(--text-muted);
}

.filter-tag.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.drivers-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow-y: auto;
  flex-grow: 1;
  padding-right: 2px;
}

/* DRIVER CARD */
.driver-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: var(--transition-smooth);
}

.driver-card:hover {
  border-color: var(--border-color-glow);
  background: rgba(255, 255, 255, 0.04);
}

.driver-card-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.driver-avatar-box {
  position: relative;
}

.driver-avatar-circle {
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  color: var(--text-secondary);
}

.driver-avatar-circle.comfort { color: var(--secondary); }
.driver-avatar-circle.business { color: #a78bfa; }

.driver-dot {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: 1.5px solid var(--bg-color);
}

.driver-dot.empty { background: var(--success); box-shadow: 0 0 6px var(--success); }
.driver-dot.busy { background: var(--danger); }

.driver-info h4 {
  font-size: 12px;
  font-weight: 600;
}

.driver-info span {
  font-size: 10px;
  color: var(--text-muted);
}

.driver-card-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-locate {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 6px;
  border-radius: 6px;
  transition: var(--transition-smooth);
  font-size: 13px;
}

.btn-locate:hover {
  color: var(--primary);
  background: rgba(255, 255, 255, 0.05);
}

/* MODAL CONTAINER */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(5, 7, 12, 0.85);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 1;
  transition: var(--transition-smooth);
}

.modal.hidden {
  display: none !important;
}

.modal-content {
  width: 500px;
  max-width: 90%;
  border-radius: 20px;
  border: 1px solid var(--border-color-glow);
  box-shadow: 0 0 40px var(--primary-glow);
  animation: modalPop 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-header h3 i {
  color: var(--primary);
}

.close-btn {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 24px;
  cursor: pointer;
  line-height: 1;
}

.close-btn:hover {
  color: #fff;
}

.modal-body {
  padding: 20px;
}

.dispatch-order-summary {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 20px;
  font-size: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.dispatch-order-summary p strong {
  color: var(--text-muted);
}

.modal-body h4 {
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 10px;
}

.available-dispatch-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 250px;
  overflow-y: auto;
}

.dispatch-driver-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  transition: var(--transition-smooth);
}

.dispatch-driver-row:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--border-color-glow);
}

.driver-dispatch-info h5 {
  font-size: 12px;
  font-weight: 600;
}

.driver-dispatch-info span {
  font-size: 10px;
  color: var(--text-muted);
}

/* AUDIO NOTICE */
.audio-notice {
  position: fixed;
  bottom: 12px;
  left: 12px;
  background: rgba(18, 25, 41, 0.95);
  border: 1px solid var(--border-color);
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 10px;
  color: var(--text-secondary);
  pointer-events: none;
  z-index: 99;
}

/* SCROLLBAR CUSTOMIZATION */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

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

::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* ANIMATIONS */
@keyframes pulse {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.05); opacity: 0.7; }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes slideUp {
  from { transform: translateY(20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@keyframes modalPop {
  from { transform: scale(0.9); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

@keyframes vibrate {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(8deg); }
  75% { transform: rotate(-8deg); }
}

/* LEAFLET PULSING PASSENGER MARKER */
.pulsing-passenger-icon {
  background: var(--primary);
  border: 2px solid white;
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(74, 144, 217, 0.7);
  animation: pulse-ring 1.5s infinite;
}

@keyframes pulse-ring {
  0% { box-shadow: 0 0 0 0 rgba(74, 144, 217, 0.7); }
  70% { box-shadow: 0 0 0 8px rgba(74, 144, 217, 0); }
  100% { box-shadow: 0 0 0 0 rgba(74, 144, 217, 0); }
}

/* AUTOCOMPLETE SUGGESTIONS DROPDOWN */
.input-with-icon-container {
  position: relative;
  width: 100%;
}

.autocomplete-suggestions {
  position: absolute;
  top: 105%;
  left: 0;
  width: 100%;
  background: var(--panel-bg-solid);
  backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border-color-glow);
  border-radius: 8px;
  z-index: 1000;
  max-height: 200px;
  overflow-y: auto;
  box-shadow: var(--card-shadow);
}

.autocomplete-suggestions.hidden {
  display: none !important;
}

.autocomplete-suggestion {
  padding: 8px 12px;
  font-size: 12px;
  color: var(--text-primary);
  cursor: pointer;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  transition: var(--transition-smooth);
}

.autocomplete-suggestion:last-child {
  border-bottom: none;
}

.autocomplete-suggestion:hover,
.autocomplete-suggestion.active {
  background: rgba(74, 144, 217, 0.15);
  color: var(--primary);
  border-left: 3px solid var(--primary);
  padding-left: 9px;
}

/* KEYBOARD SHORTCUT LEGEND FOOTER */
.shortcut-legend-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 38px;
  background: rgba(11, 14, 25, 0.95);
  backdrop-filter: var(--glass-blur);
  border-top: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  padding: 0 24px;
  gap: 16px;
  z-index: 999;
  font-size: 11px;
}

.legend-title {
  font-weight: 700;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 6px;
}

.legend-items {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  flex-grow: 1;
}

.legend-item {
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.legend-item kbd {
  background: linear-gradient(180deg, #374151 0%, #1f2937 100%);
  border: 1px solid #4b5563;
  box-shadow: 0 1px 0 rgba(255,255,255,0.1), inset 0 1px 0 rgba(255,255,255,0.15);
  border-radius: 4px;
  padding: 1px 5px;
  font-family: inherit;
  font-size: 9px;
  color: var(--text-primary);
  font-weight: 700;
}

/* Adjust Workspace margin for footer */
.app-container {
  padding-bottom: 38px;
}

/* VOICE RECORDER RATSIA OVERLAY (Insert Key) */
.voice-overlay {
  position: fixed;
  inset: 0;
  background: rgba(11, 14, 25, 0.85);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  animation: fadeIn 0.2s ease-out;
}

.voice-overlay.hidden {
  display: none !important;
}

.voice-card {
  background: rgba(18, 25, 41, 0.95);
  border: 2px solid var(--danger);
  box-shadow: 0 0 30px var(--danger-glow);
  border-radius: 24px;
  padding: 40px;
  text-align: center;
  max-width: 450px;
  width: 90%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.recording-circle {
  width: 80px;
  height: 80px;
  background: var(--danger);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: #fff;
  box-shadow: 0 0 20px var(--danger);
}

.animate-pulse-mic {
  animation: micPulse 1.2s infinite ease-in-out;
}

@keyframes micPulse {
  0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7); }
  70% { transform: scale(1.1); box-shadow: 0 0 0 15px rgba(239, 68, 68, 0); }
  100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}

.voice-card h3 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: #fff;
}

.voice-card p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.audio-wave {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  height: 30px;
  margin-top: 10px;
}

.audio-wave span {
  display: inline-block;
  width: 3px;
  height: 8px;
  background: var(--danger);
  border-radius: 3px;
  animation: bounceWave 1.2s infinite ease-in-out;
}

.audio-wave span:nth-child(2) { animation-delay: 0.15s; }
.audio-wave span:nth-child(3) { animation-delay: 0.3s; }
.audio-wave span:nth-child(4) { animation-delay: 0.45s; }
.audio-wave span:nth-child(5) { animation-delay: 0.6s; }
.audio-wave span:nth-child(6) { animation-delay: 0.75s; }

@keyframes bounceWave {
  0%, 100% { height: 8px; }
  50% { height: 30px; }
}

/* WALKIE-TALKIE INCOMING MESSAGE BANNER (Ctrl+1) */
.walkie-talkie-banner {
  position: fixed;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, rgba(88, 28, 135, 0.95), rgba(49, 46, 129, 0.95));
  border: 1px solid #a78bfa;
  box-shadow: 0 10px 25px rgba(139, 92, 246, 0.4);
  border-radius: 12px;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  z-index: 10000;
  max-width: 500px;
  width: 90%;
  animation: slideDownPop 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.walkie-icon {
  width: 36px;
  height: 36px;
  background: #a78bfa;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: #1e1b4b;
  animation: radioChirp 0.5s infinite;
}

.walkie-content h4 {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  margin: 0;
}

.walkie-content p {
  font-size: 12px;
  color: #ddd;
  margin-top: 2px;
  font-style: italic;
}

@keyframes slideDownPop {
  from { transform: translate(-50%, -40px); opacity: 0; }
  to { transform: translate(-50%, 0); opacity: 1; }
}

@keyframes radioChirp {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.08); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.walkie-talkie-banner.hidden {
  display: none !important;
}

/* TARIFF SELECTOR ROW */
.tariff-cards-row {
  display: flex;
  gap: 10px;
  margin-top: 8px;
}
.tariff-card {
  flex: 1;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 14px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
.tariff-card:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-1px);
}
.tariff-card i {
  font-size: 24px;
  color: #888;
  transition: all 0.2s ease;
}
.tariff-card span {
  font-size: 11px;
  font-weight: 700;
  color: #aaa;
  text-align: center;
  transition: all 0.2s ease;
}

/* Active states with neon glowing borders */
.tariff-card.active[data-tariff="yengil"] {
  border-color: #3b82f6;
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.25);
  background: rgba(59, 130, 246, 0.06);
}
.tariff-card.active[data-tariff="yengil"] i, .tariff-card.active[data-tariff="yengil"] span {
  color: #60a5fa;
}

.tariff-card.active[data-tariff="damas"] {
  border-color: #10b981;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.25);
  background: rgba(16, 185, 129, 0.06);
}
.tariff-card.active[data-tariff="damas"] i, .tariff-card.active[data-tariff="damas"] span {
  color: #34d399;
}

.tariff-card.active[data-tariff="labo"] {
  border-color: #f59e0b;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.25);
  background: rgba(245, 158, 11, 0.06);
}
.tariff-card.active[data-tariff="labo"] i, .tariff-card.active[data-tariff="labo"] span {
  color: #fbbf24;
}

.tariff-card.active[data-tariff="tombagaj"] {
  border-color: #ec4899;
  box-shadow: 0 0 12px rgba(236, 72, 153, 0.25);
  background: rgba(236, 72, 153, 0.06);
}
.tariff-card.active[data-tariff="tombagaj"] i, .tariff-card.active[data-tariff="tombagaj"] span {
  color: #f472b6;
}

/* ACTIVE CALL CARD */
.active-call-card {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.25);
  box-shadow: 0 0 15px rgba(16, 185, 129, 0.15);
  border-radius: 12px;
  padding: 12px;
  margin-top: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  animation: slideDownPop 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.active-call-card.hidden {
  display: none !important;
}
.active-pulse-wrapper {
  width: 36px;
  height: 36px;
  background: rgba(16, 185, 129, 0.15);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.active-pulse-dot {
  width: 12px;
  height: 12px;
  background: #10b981;
  border-radius: 50%;
  animation: activePulse 1.5s infinite;
}
@keyframes activePulse {
  0% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1.1); box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.active-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 3px;
}
.rec-badge {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  font-size: 9px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
  border: 1px solid rgba(239, 68, 68, 0.25);
  letter-spacing: 0.5px;
}
.rec-dot {
  width: 6px;
  height: 6px;
  background: #ef4444;
  border-radius: 50%;
  animation: recFlash 1s infinite alternate;
}
@keyframes recFlash {
  from { opacity: 0.3; }
  to { opacity: 1; }
}

.call-timer {
  font-family: var(--font-display);
  font-size: 11px;
  color: #a7f3d0;
  font-weight: 700;
  background: rgba(16, 185, 129, 0.2);
  padding: 1px 6px;
  border-radius: 4px;
  letter-spacing: 0.5px;
}

/* AUDIO SPECTRUM BARS */
.audio-spectrum .bar {
  flex: 1;
  height: 4px;
  background: #10b981;
  border-radius: 3px;
  box-shadow: 0 0 6px rgba(16, 185, 129, 0.6);
  transition: height 0.08s ease-in-out;
}

/* ==========================================
   MOBILE TOP HEADER & SIDEBAR MOBILE DRAWER
   ========================================== */
.mobile-header {
  display: none;
  align-items: center;
  justify-content: space-between;
  background: var(--panel-bg-solid);
  backdrop-filter: var(--glass-blur);
  border-bottom: 1px solid var(--border-color);
  padding: 0 20px;
  position: sticky;
  top: 0;
  z-index: 1005;
  height: 60px;
  width: 100%;
}

.btn-hamburger {
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 20px;
  cursor: pointer;
  padding: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
  border-radius: 8px;
}

.btn-hamburger:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--primary);
}

.mobile-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mobile-brand .logo-icon {
  font-size: 18px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.mobile-brand span {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 1px;
  color: #fff;
}

.mobile-clock {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  background: rgba(255, 255, 255, 0.03);
  padding: 4px 10px;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  letter-spacing: 0.5px;
}

.sidebar-mobile-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(5, 7, 12, 0.6);
  backdrop-filter: blur(4px);
  z-index: 1007;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.sidebar-mobile-overlay.visible {
  display: block;
  opacity: 1;
  pointer-events: auto;
}

/* ==========================================
   RESPONSIVE MEDIA QUERIES (BREAKPOINTS)
   ========================================== */

/* 1. TABLET LANDSCAPE & SMALL DESKTOP (<= 1200px) */
@media (max-width: 1200px) {
  .app-container {
    grid-template-columns: 280px 1fr;
    height: 100vh;
  }
  
  .main-workspace {
    padding: 20px;
  }
}

/* 2. PORTRAIT TABLET (<= 1024px) */
@media (max-width: 1024px) {
  .app-container {
    display: flex;
    flex-direction: column;
    height: auto;
    overflow-y: auto;
    padding-bottom: 38px;
  }
  
  .sidebar-left {
    width: 100%;
    height: auto;
    border-right: none;
    border-bottom: 1px solid var(--border-color);
    padding: 20px;
    gap: 20px;
  }
  
  .nav-menu {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 10px;
  }
  
  .nav-item {
    flex: 1;
    min-width: 150px;
    justify-content: center;
  }
  
  .nav-item.active {
    border-left: none;
    border-bottom: 3px solid var(--primary);
    border-top-left-radius: 10px;
    border-bottom-left-radius: 10px;
    border-bottom-right-radius: 0;
    border-top-right-radius: 0;
  }

  .main-workspace {
    width: 100%;
    height: auto;
    overflow-y: visible;
  }
  
  .drivers-section {
    max-height: 400px;
  }
}

/* 3. MOBILE DEVICES (<= 768px) */
@media (max-width: 768px) {
  .mobile-header {
    display: flex;
  }
  
  .app-container {
    padding-top: 0;
    height: auto;
  }
  
  .sidebar-left {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 320px;
    height: 100vh;
    z-index: 1009;
    transform: translateX(-100%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 15px 0 35px rgba(0, 0, 0, 0.5);
    background: var(--panel-bg-solid);
    border-right: 1px solid var(--border-color-glow);
    overflow-y: auto;
  }
  
  .sidebar-left.mobile-open {
    transform: translateX(0);
  }
  
  .nav-menu {
    flex-direction: column;
  }
  
  .nav-item {
    width: 100%;
    justify-content: flex-start;
  }
  
  .nav-item.active {
    border-left: 3px solid var(--primary);
    border-bottom: none;
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    border-top-right-radius: 10px;
    border-bottom-right-radius: 10px;
  }
  
  .workspace-header {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  
  .header-search {
    width: 100%;
  }
  
  .header-profile {
    justify-content: space-between;
  }
  
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .table-container {
    width: 100%;
    overflow-x: auto;
  }
  
  .orders-table {
    min-width: 700px;
  }
}

/* 4. TINY MOBILE SCREENS (<= 480px) */
@media (max-width: 480px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }
  
  .tariff-cards-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
  
  .main-workspace {
    padding: 15px;
  }
  
  .card-glass {
    padding: 15px;
  }
  
  .form-row {
    flex-direction: column;
    gap: 12px;
  }
  
  .modal-content {
    width: 95%;
  }
  
  .shortcut-legend-bar {
    display: none;
  }
  
  .app-container {
    padding-bottom: 0;
  }
}

