/* --- VARIABLES --- */
:root {
    --morado-cir: #35256A;
    --amarillo-cir: #F2E628;
    --amarillo-hover: #e5d91f;
    --blanco: #ffffff;
    --fondo-gris: #f9f9f9;
    --exito: #27ae60;
    --texto-oscuro: #333;
    --sombra: 0 10px 30px rgba(0, 0, 0, 0.08);
}

/* --- BASE --- */
* {
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--fondo-gris);
    padding-top: 70px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: var(--texto-oscuro);
    overflow-x: hidden;
}

/* --- CONTENEDORES --- */
.rutas-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 20px;
}

.texto-rutas {
    text-align: center;
    margin-bottom: 40px;
}

.texto-rutas h1 { 
    color: var(--morado-cir);
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.divisor-amarillo {
    width: 80px;
    height: 4px;
    background-color: var(--amarillo-cir);
    border: none;
    margin: 20px auto;
    border-radius: 2px;
}

/* --- BADGES INFORMATIVOS --- */
.info-badges {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.badge-item {
    background: white;
    padding: 12px 25px;
    border-radius: 50px;
    box-shadow: var(--sombra);
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid #eee;
    color: black !important;
}

.badge-item span{
    color: black !important;
}

/* --- BANNER DINÁMICO --- */
.banner-proxima-salida {
    background: linear-gradient(135deg, var(--morado-cir) 0%, #4a368d 100%);
    border-radius: 15px;
    padding: 20px 30px;
    margin-bottom: 30px;
    color: white;
    box-shadow: 0 10px 20px rgba(53, 37, 106, 0.2);
    border-left: 6px solid var(--amarillo-cir);
}

.banner-content {
    display: flex;
    align-items: center;
    gap: 20px;
}

.icono-reloj {
    font-size: 2.5rem;
    color: var(--amarillo-cir);
    animation: pulse-icon 2s infinite;
}

/* --- BUSCADOR --- */
.buscador-container {
    max-width: 550px;
    margin: 0 auto 40px auto;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper i {
    position: absolute;
    left: 20px;
    color: var(--morado-cir);
}

#inputBusqueda {
    width: 100%;
    padding: 16px 16px 16px 50px;
    border: 2px solid #eee;
    border-radius: 50px;
    outline: none;
    font-size: 1rem;
    transition: all 0.3s ease;
}

#inputBusqueda:focus {
    border-color: var(--amarillo-cir);
    box-shadow: 0 4px 20px rgba(53, 37, 106, 0.15);
}

/* --- TABLA DE LOGÍSTICA MEJORADA --- */
.tabla-wrapper {
    width: 100%;
    overflow-x: auto;
    border-radius: 15px;
    box-shadow: 0 15px 35px rgba(53, 37, 106, 0.1);
    background: white;
    border: 1px solid rgba(53, 37, 106, 0.05);
}

.tabla-logistica {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    min-width: 900px;
}

.tabla-logistica thead {
    background: linear-gradient(90deg, var(--morado-cir) 0%, #4a368d 100%);
    color: white;
}

.tabla-logistica th {
    padding: 22px;
    text-align: left;
    font-size: 0.9rem;
    letter-spacing: 1px;
    border: none;
}

.tabla-logistica td {
    padding: 20px;
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.2s ease;
}

.ciudad-principal {
    font-weight: 700;
    color: var(--morado-cir);
    font-size: 1.1rem;
    position: relative;
}

.tag-dia {
    display: inline-block;
    background: #f1f3f9;
    color: #4a368d !important;
    padding: 5px 12px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    margin: 3px;
    border: 1px solid #e0e6ed;
    transition: all 0.3s ease;
}

.tag-dia:hover {
    background: var(--amarillo-cir);
    color: var(--morado-cir);
    transform: translateY(-2px);
}

.frecuencia {
    font-weight: 800;
    color: var(--exito);
    background: rgba(39, 174, 96, 0.1);
    padding: 6px 15px;
    border-radius: 50px;
    text-align: center;
    display: inline-block;
    margin: 20px 20px;
}

.tabla-logistica tbody tr:hover td {
    background-color: #f8f6ff;
}

.tabla-logistica tbody tr:hover .ciudad-principal {
    color: #6c5ce7;
    transform: translateX(5px);
}

.tabla-logistica th i {
    margin-right: 8px;
    color: var(--amarillo-cir);
}

/* --- ANIMACIONES --- */
@keyframes pulse-icon {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* --- RESPONSIVE --- */
@media (max-width: 768px) {
    .tabla-logistica td > ul {
        grid-template-columns: 1fr; 
    }
}