/* Timeline Section */
.timeline {
    padding: 6rem 0;
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    min-height: 100vh;
    perspective: 1000px;
    overflow-x: hidden;
}

.timeline-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    position: relative;
}

.section-title {
    font-size: 2.8rem;
    font-weight: 800;
    background: linear-gradient(135deg, #007acc 0%, #0056b3 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 4rem;
    text-align: center;
    letter-spacing: -0.5px;
}

.timeline-intro {
    max-width: 800px;
    margin: 0 auto 4rem;
    text-align: center;
    padding: 0 1.5rem;
}

.timeline-intro h3 {
    font-size: 1.8rem;
    color: #2c3e50;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.timeline-intro p {
    font-size: 1.1rem;
    color: #546e7a;
    line-height: 1.7;
    margin-bottom: 1rem;
}

.timeline-intro p:last-child {
    margin-bottom: 0;
}

.timeline-items {
    position: relative;
    height: 400px;
    margin: 0 auto;
    max-width: 800px;
}

.timeline-item {
    position: absolute;
    width: 100%;
    background: #ffffff;
    padding: 2rem;
    border-radius: 16px;
    border: 1px solid #eaeaea;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center center;
    backface-visibility: hidden;
    min-height: 300px;
}

.timeline-item:not(.active) {
    pointer-events: none;
}

.timeline-date {
    display: inline-block;
    font-size: 0.95rem;
    color: #ffffff;
    font-weight: 600;
    padding: 0.5rem 1.2rem;
    background: linear-gradient(135deg, #007acc, #0056b3);
    border-radius: 30px;
    margin-bottom: 1rem;
    box-shadow: 0 3px 8px rgba(0, 122, 204, 0.2);
}

.timeline-position {
    font-size: 1.4rem;
    color: #2c3e50;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.timeline-company {
    font-size: 1.1rem;
    color: #007acc;
    font-weight: 500;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.timeline-company i {
    font-size: 0.9rem;
    opacity: 0.8;
}

.timeline-description {
    font-size: 1.05rem;
    color: #546e7a;
    line-height: 1.7;
}

/* Stack effect - will be modified by JavaScript */
.timeline-item:nth-child(1) { z-index: 4; }
.timeline-item:nth-child(2) { z-index: 3; }
.timeline-item:nth-child(3) { z-index: 2; }
.timeline-item:nth-child(4) { z-index: 1; }

.timeline-controls {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
}

.timeline-nav {
    background: #ffffff;
    border: 2px solid #007acc;
    color: #007acc;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 122, 204, 0.1);
}

.timeline-nav:hover {
    background: #007acc;
    color: #ffffff;
    transform: translateY(-2px);
}

.timeline-nav:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* Mobile responsive design */
@media (max-width: 768px) {
    .timeline {
        padding: 4rem 0;
    }
    
    .timeline-container {
        padding: 0 1.5rem;
    }

    .section-title {
        font-size: 2.2rem;
        margin-bottom: 3rem;
    }
    
    .timeline-position {
        font-size: 1.2rem;
    }
    
    .timeline-date {
        font-size: 0.85rem;
        padding: 0.4rem 1rem;
    }
    
    .timeline-description {
        font-size: 0.95rem;
        line-height: 1.6;
    }

    .timeline-nav {
        width: 40px;
        height: 40px;
    }
    
    .timeline-intro {
        margin-bottom: 3rem;
    }
    
    .timeline-intro h3 {
        font-size: 1.6rem;
        margin-bottom: 1.2rem;
    }
    
    .timeline-intro p {
        font-size: 1rem;
        line-height: 1.6;
    }

    .timeline-company {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .timeline {
        padding: 3rem 0;
    }
    
    .timeline-container {
        padding: 0 1rem;
    }
    
    .section-title {
        font-size: 1.8rem;
        margin-bottom: 2.5rem;
    }
    
    .timeline-position {
        font-size: 1.1rem;
    }
    
    .timeline-date {
        font-size: 0.8rem;
        padding: 0.3rem 0.8rem;
    }
    
    .timeline-description {
        font-size: 0.9rem;
        line-height: 1.5;
    }

    .timeline-controls {
        margin-top: 1.5rem;
    }
    
    .timeline-nav {
        width: 36px;
        height: 36px;
    }
    
    .timeline-intro {
        margin-bottom: 2.5rem;
        padding: 0 1rem;
    }
    
    .timeline-intro h3 {
        font-size: 1.4rem;
        margin-bottom: 1rem;
    }
    
    .timeline-intro p {
        font-size: 0.95rem;
        line-height: 1.5;
    }

    .timeline-company {
        font-size: 0.95rem;
    }
}