/* --- ESTILOS PARA LA LÍNEA DE TIEMPO (HISTORIA) --- */

.timeline-container {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 0;
}

/* La línea dorada central */
.timeline-container::after {
    content: '';
    position: absolute;
    width: 4px;
    background-color: var(--dorado);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
    border-radius: 2px;
}

/* Contenedor de cada evento */
.timeline-item {
    padding: 10px 40px;
    position: relative;
    background-color: inherit;
    width: 50%;
}

/* Lado Izquierdo */
.timeline-item.left {
    left: 0;
}

/* Lado Derecho */
.timeline-item.right {
    left: 50%;
}

/* Los círculos (Nodos) en la línea de tiempo */
.timeline-item::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    right: -10px;
    background-color: var(--blanco);
    border: 4px solid var(--vino);
    top: 25px;
    border-radius: 50%;
    z-index: 1;
    transition: all 0.3s ease;
}

.timeline-item.right::after {
    left: -10px;
}

/* Efecto hover en el nodo */
.timeline-item:hover::after {
    background-color: var(--dorado);
    border-color: var(--dorado);
    transform: scale(1.3);
}

/* La Tarjeta de Contenido */
.timeline-content {
    padding: 30px;
    background-color: var(--blanco);
    position: relative;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    border-top: 5px solid var(--vino);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.timeline-item:hover .timeline-content {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(97, 18, 50, 0.15);
    border-top-color: var(--dorado);
}

/* Año destacado */
.timeline-year {
    display: inline-block;
    background: var(--vino);
    color: var(--blanco);
    padding: 5px 15px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 1.1rem;
    margin-bottom: 15px;
    box-shadow: 0 3px 8px rgba(97,18,50,0.3);
}

.timeline-content h3 {
    color: var(--vino-oscuro);
    font-weight: bold;
    margin-bottom: 15px;
}

/* Imagen dentro de la tarjeta */
.timeline-img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 15px;
    border: 1px solid #eee;
}

/* --- MAGIA RESPONSIVE PARA CELULARES --- */
@media screen and (max-width: 850px) {
    /* Mover la línea a la izquierda */
    .timeline-container::after {
        left: 31px;
    }
    
    /* Hacer que todas las tarjetas ocupen el 100% y se alineen a la derecha de la línea */
    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }
    
    .timeline-item.right {
        left: 0;
    }
    
    /* Mover todos los nodos a la izquierda */
    .timeline-item::after, .timeline-item.right::after {
        left: 21px;
    }
}