/* Main Layout */
.path-maisbus .prefooter{
  display: none;
}
#maisbus-wrapper {
  display: flex;
  height: 600px;
  width: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

#maisbus-panel {
  width: 350px;
  flex-shrink: 0;
  background-color: #f8f9fa;
  border-right: 1px solid #dee2e6;
  display: flex;
  flex-direction: column;
  box-shadow: 2px 0 5px rgba(0,0,0,0.1);
}

#maisbus-map-container {
  flex-grow: 1;
}

#map {
  height: 800px;
  width: 100%;
}

/* Panel Header */
.panel-header {
  padding: 1rem;
  border-bottom: 1px solid #dee2e6;
}

.panel-header h2 {
  margin-top: 0;
  font-size: 1.25rem;
}

#stop-search-form {
  display: flex;
}

#stop-search-input {
  flex-grow: 1;
  padding: 0.5rem;
  border: 1px solid #ccc;
  border-radius: 4px 0 0 4px;
}

#stop-search-form button {
  padding: 0.5rem 1rem;
  border: 1px solid #007bff;
  background-color: #007bff;
  color: white;
  border-radius: 0 4px 4px 0;
  cursor: pointer;
}

/* Panel Content */
.panel-content-area {
  overflow-y: auto;
  flex-grow: 1;
  padding: 1rem;
}

.loader {
  text-align: center;
  padding: 2rem;
  color: #6c757d;
}

/* Lists */
ul.item-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

ul.item-list li {
  padding: 0.75rem;
  border-bottom: 1px solid #e9ecef;
  cursor: pointer;
  transition: background-color 0.2s;
  font-size: 0.9rem;
}

ul.item-list li:hover {
  background-color: #e9ecef;
}

ul.item-list li strong {
  display: block;
  font-size: 1rem;
  color: #343a40;
  font-size: 0.9rem;
}

ul.item-list li span {
  font-size: 0.875rem;
  color: #6c757d;
}

/* Line Detail View */
.line-detail-header {  
  margin-bottom: 1rem;
  display: flex;
  justify-content: flex-end;
  gap: 5px;
}

.back-button {
  background: none;
  border: none;
  color: #007bff;
  cursor: pointer;
  font-size: 1rem;
  padding: 0.5rem;
}

.route-selector {
  padding-top: 1rem;
}
.route-selector label {
  margin-right: 0.5rem;
}

/* Leaflet Customizations */
.leaflet-popup-content-wrapper {
  border-radius: 4px;
}
.leaflet-popup-content {
  font-size: 1rem;
  font-weight: bold;
}

.routes {
  padding-top: 1rem;  
}

.routes .routes-title {
  padding-bottom: 1rem;
}

.route-title {
  padding: 0.75rem;
  cursor: pointer;
  transition: background-color 0.2s;
}

.route-title:hover {
  background-color: #e9ecef;
}

.btn {
  cursor: pointer;
}

.container-full {
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
  box-sizing: border-box;
}

@media (max-width: 768px) {
  .panel-header {
    margin-top: 20px;
  }

  button.btn-clear {
    border: solid 1px #508095;
    background-color: #FFF;
  }

  button.btn-p {
    font-size: 1rem;
  }

  .toggle-panel {
    display: block !important;
    margin-bottom: 10px;
  }

  #maisbus-panel.oculto {  
    width: 0;
  }

  #maisbus-panel {
    transition: width 0.4s ease;  
  }

  .hide-panel {
    position: absolute;
    margin-left: 300px;
  }
}

.toggle-panel {
  display: none;
}

.leaflet-popup .stop-code {
  border: solid 1px #dee2e6;
  box-shadow: 2px 0 5px rgba(0,0,0,0.1);
  border-radius: 4px;
  padding: 2px 5px;
  margin-right: 10px;
}

.leaflet-popup .proximas-paradas > p {
  background-color: #e9ecef;
  font-size: 12px;
  padding: 10px 0;
  border: solid 1px #dee2e6;
  position: absolute;
  left: 0;
  width: 100%;
  top: 5rem;
  max-width: 100%;
  padding-left: 20px;
}

.leaflet-popup .proximas-paradas .parada-linea:first-of-type {
  margin-top: 5rem;
}

.leaflet-popup .proximas-paradas .parada-linea {
  color: #FFF;
  text-align: center;
  padding: 5px;
  margin-bottom: 10px;
}

.leaflet-popup .proximas-paradas .parada-linea .nombre-parada {
  font-size: 12px;
}

.leaflet-popup .stop-zone {
  font-size: 12px;
  font-weight: 100;
}

.stop-codigo {
  border: solid 1px #dee2e6;
  box-shadow: 2px 0 5px rgba(0,0,0,0.1);
  border-radius: 4px;
  padding: 2px 5px;
  margin-right: 10px;
}