/* ============================================
   CAMINO DEL PACIENTE — Journey Timeline
   Requiere: Google Fonts (Playfair Display + DM Sans)
   Requiere: Font Awesome 6
============================================ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,700;0,900;1,700;1,900&family=DM+Sans:wght@300;400;500;600&display=swap');

.journey-section {
    background: #0b1628;
    position: relative;
    overflow: hidden;
}

.journey-section::before {
    content: '';
    position: absolute;
    top: -200px;
    left: -200px;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(45, 79, 149, 0.25) 0%, transparent 70%);
    pointer-events: none;
}

.journey-section::after {
    content: '';
    position: absolute;
    bottom: -150px;
    right: -100px;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(208, 19, 65, 0.15) 0%, transparent 70%);
    pointer-events: none;
}

.journey-wrapper {
    max-width: 900px;
    margin: 0 auto;
    padding: 80px 24px 100px;
    position: relative;
    z-index: 2;
}

/* Header */
.journey-header {
    text-align: center;
    margin-bottom: 64px;
}

.journey-eyebrow {
    font-family: 'DM Sans', sans-serif;
    font-size: 11px;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #d01341;
    font-weight: 600;
    margin-bottom: 16px;
}

.journey-title {
    font-family: 'Playfair Display', serif;
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 900;
    color: #ffffff;
    line-height: 1.15;
    margin-bottom: 16px;
}

.journey-title span {
    color: #4c78d4;
    font-style: italic;
}

.journey-subtitle {
    font-family: 'DM Sans', sans-serif;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.5);
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.7;
}

/* Línea conectora vertical */
.journey-line {
    position: relative;
}

.journey-line::before {
    content: '';
    position: absolute;
    left: 38px;
    top: 20px;
    bottom: 20px;
    width: 2px;
    background: linear-gradient(to bottom, #2d4f95 0%, #d01341 100%);
    opacity: 0.4;
}

/* Paso individual */
.step-item {
    display: flex;
    gap: 28px;
    margin-bottom: 20px;
    opacity: 0;
    transform: translateX(-30px);
    animation: cpSlideIn 0.6s ease forwards;
    cursor: pointer;
}

.step-item:nth-child(1) {
    animation-delay: 0.1s;
}

.step-item:nth-child(2) {
    animation-delay: 0.2s;
}

.step-item:nth-child(3) {
    animation-delay: 0.3s;
}

.step-item:nth-child(4) {
    animation-delay: 0.4s;
}

.step-item:nth-child(5) {
    animation-delay: 0.5s;
}

.step-item:nth-child(6) {
    animation-delay: 0.6s;
}

.step-item:nth-child(7) {
    animation-delay: 0.7s;
}

@keyframes cpSlideIn {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Nodo circular */
.step-node {
    flex: 0 0 76px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.step-dot {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: #111e35;
    border: 2px solid #1e3060;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.step-dot::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(45, 79, 149, 0.3), rgba(208, 19, 65, 0.1));
    opacity: 0;
    transition: opacity 0.3s;
}

.step-item:hover .step-dot::before,
.step-item.open .step-dot::before {
    opacity: 1;
}

.step-dot i {
    font-size: 20px;
    color: #4c78d4;
    transition: color 0.3s, transform 0.3s;
}

.step-item:hover .step-dot i {
    color: #ffffff;
    transform: scale(1.1);
}

.step-item.open .step-dot {
    border-color: #2d4f95;
    box-shadow: 0 0 0 4px rgba(45, 79, 149, 0.2);
}

.step-item.open .step-dot i {
    color: #4c78d4;
}

.step-num {
    font-family: 'DM Sans', sans-serif;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1px;
    color: #d01341;
    text-transform: uppercase;
    margin-top: 4px;
}

/* Tarjeta del paso */
.step-body {
    flex: 1;
    background: #111e35;
    border: 1px solid #1e3060;
    border-radius: 16px;
    padding: 22px 24px;
    transition: all 0.35s ease;
    position: relative;
    overflow: hidden;
}

.step-body::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, #2d4f95, #d01341);
    opacity: 0;
    transition: opacity 0.3s;
}

.step-item:hover .step-body::after,
.step-item.open .step-body::after {
    opacity: 1;
}

.step-item:hover .step-body,
.step-item.open .step-body {
    border-color: #2d4f95;
    background: #132040;
}

/* Header de la tarjeta */
.step-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
}

.step-timing {
    font-family: 'DM Sans', sans-serif;
    font-size: 10px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #d01341;
    font-weight: 600;
    margin-bottom: 6px;
}

.step-title {
    font-family: 'DM Sans', sans-serif;
    font-size: 1.05rem;
    font-weight: 600;
    color: #e8eef8;
    line-height: 1.3;
}

.step-chevron {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.3);
    transition: transform 0.3s, color 0.3s;
    flex-shrink: 0;
    margin-top: 6px;
}

.step-item.open .step-chevron {
    transform: rotate(180deg);
    color: #4c78d4;
}

/* Detalles expandibles */
.step-details {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, opacity 0.3s ease;
    opacity: 0;
}

.step-item.open .step-details {
    max-height: 400px;
    opacity: 1;
}

.step-details ul {
    list-style: none;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.step-details li {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.5;
}

.step-details li::before {
    content: '';
    flex-shrink: 0;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #4c78d4;
    margin-top: 7px;
}

/* Responsive */
@media (max-width: 600px) {
    .journey-line::before {
        left: 28px;
    }

    .step-node {
        flex: 0 0 56px;
    }

    .step-dot {
        width: 56px;
        height: 56px;
    }

    .step-dot i {
        font-size: 16px;
    }

    .step-body {
        padding: 16px 18px;
    }

    .step-title {
        font-size: 0.95rem;
    }

    .step-item {
        gap: 16px;
    }
}