/* Only keeping Leaflet overrides and custom map height */
.map-wrapper {
  height: 500px;
  width: 100%;
}

#map {
  width: 100%;
  height: 100%;
  z-index: 10;
}

/* Custom icon rendering styles */
.transport-icon {
  background-color: white;
  border-radius: 50%;
  padding: 4px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  border: 2px solid #3b82f6; /* blue-500 */
  display: flex;
  align-items: center;
  justify-content: center;
  color: #3b82f6;
  transition: all 0.3s;
}

.transport-icon.origin {
  border-color: #10b981; /* emerald-500 */
  color: #10b981;
}

.transport-icon.destination {
  border-color: #f43f5e; /* rose-500 */
  color: #f43f5e;
}

.plbn-icon {
  background-color: white;
  border-radius: 50%;
  padding: 4px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  border: 2px solid #f59e0b; /* amber-500 */
  display: flex;
  align-items: center;
  justify-content: center;
  color: #f59e0b;
}

/* Leaflet Popup overrides for light theme */
.leaflet-popup-content-wrapper {
  border-radius: 0.5rem !important;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05) !important;
}
.leaflet-popup-content {
  font-family: inherit !important;
  font-size: 0.875rem !important;
}

/* Remove default Leaflet Tooltip styles so Tailwind takes over */
.leaflet-tooltip {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
}

/* Animated Polyline Effect */
.animated-route {
  stroke-dasharray: 10, 15;
  animation: move-dash 1s linear infinite;
}

@keyframes move-dash {
  to {
    stroke-dashoffset: -25;
  }
}

/* Leaflet Routing Machine UI Overrides */
#routing-sidebar .leaflet-routing-container {
  width: 100% !important;
  max-width: 100% !important;
  background-color: transparent !important;
  box-shadow: none !important;
  margin: 0 !important;
  padding: 0 !important;
  color: #334155; /* text-slate-700 */
  font-family: inherit;
}

#routing-sidebar .leaflet-routing-alt {
  max-height: none !important;
  background-color: transparent !important;
}

#routing-sidebar .leaflet-routing-alt h2,
#routing-sidebar .leaflet-routing-alt h3 {
  display: none !important; /* Hide duplicate distance/time text */
}

#routing-sidebar .leaflet-routing-alt table {
  width: 100%;
  border-collapse: collapse;
}

#routing-sidebar .leaflet-routing-alt tr {
  border-bottom: 1px dashed #e2e8f0; /* slate-200 */
  transition: all 0.2s;
  cursor: pointer;
}

#routing-sidebar .leaflet-routing-alt tr:last-child {
  border-bottom: none;
}

#routing-sidebar .leaflet-routing-alt tr:hover {
  background-color: #f1f5f9; /* slate-100 */
}

#routing-sidebar .leaflet-routing-alt td {
  padding: 12px 8px;
  font-size: 0.8rem;
  font-weight: 500;
  vertical-align: middle;
}

/* Icon column specific adjustments */
#routing-sidebar .leaflet-routing-icon {
  margin-right: 6px;
  opacity: 0.7;
}

/* Tom Select Tailwind Overrides */
.ts-control {
  background-color: #f8fafc !important; /* bg-slate-50 */
  border: 1px solid #e2e8f0 !important; /* border-slate-200 */
  border-radius: 0.75rem !important; /* rounded-xl */
  padding: 0.75rem 1rem 0.75rem 2.75rem !important; /* py-3 pl-11 pr-10 */
  color: #1e293b !important; /* text-slate-800 */
  font-size: 0.875rem !important;
  font-weight: 500 !important;
  transition: all 0.2s;
}

.ts-control.focus {
  border-color: #3b82f6 !important; /* focus:border-blue-500 */
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.5) !important; /* focus:ring-2 */
}

.ts-control > input {
  font-family: inherit !important;
  font-size: 0.875rem !important;
  font-weight: 500 !important;
}

.ts-dropdown {
  border-radius: 0.75rem !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06) !important;
  overflow: hidden;
  margin-top: 4px;
}

.ts-dropdown .option {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #334155;
}

.ts-dropdown .option.active {
  background-color: #f1f5f9; /* bg-slate-100 */
  color: #1e293b;
}

.ts-dropdown .option.selected {
  background-color: #eff6ff; /* bg-blue-50 */
  color: #2563eb; /* text-blue-600 */
  font-weight: 600;
}
