/* Timeline Container */
.timeline-container {
    position: relative;
    max-width: 800px;
    margin: 50px auto;
    padding: 20px 0;
}

/* Vertical Line */
.timeline-container::after {
    content: '';
    position: absolute;
    width: 4px;
    background-color: var(--separator-color);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
    border-radius: 2px;
}

/* Timeline Item */
.timeline-item {
    padding: 10px 40px;
    position: relative;
    background-color: inherit;
    width: 50%;
    box-sizing: border-box;
}

/* Left/Right Positioning */
.timeline-item:nth-child(odd) {
    left: 0;
    text-align: right;
}

.timeline-item:nth-child(even) {
    left: 50%;
    text-align: left;
}

/* Dots on the Line */
.timeline-item::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    right: -10px;
    background-color: #ffffff;
    border: 4px solid var(--red-accent);
    top: 25px;
    border-radius: 50%;
    z-index: 1;
    transition: all 0.3s ease;
    box-shadow: 0 0 0 4px rgba(231, 76, 60, 0.1);
}

.timeline-item:nth-child(even)::after {
    left: -10px;
}

.timeline-item:hover::after {
    background-color: var(--red-accent);
    transform: scale(1.2);
    box-shadow: 0 0 0 8px rgba(231, 76, 60, 0.2);
}

/* Content Box */
.timeline-content {
    padding: 25px;
    background-color: #ffffff;
    position: relative;
    border-radius: 8px;
    box-shadow: var(--shadow-card);
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.03);
}

.timeline-item:hover .timeline-content {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

/* Date Label */
.timeline-date {
    font-weight: 700;
    color: var(--red-accent);
    margin-bottom: 10px;
    font-size: 0.9em;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Typography */
.timeline-content h3 {
    margin: 0 0 5px 0;
    font-size: 1.2em;
    color: var(--dark-text);
    font-weight: 700;
}

.timeline-content h4 {
    margin: 0 0 15px 0;
    font-size: 1em;
    color: var(--light-text);
    font-weight: 500;
}

.timeline-content p {
    margin: 0;
    font-size: 0.95em;
    line-height: 1.6;
    color: var(--light-text);
}

/* Certifications Section */
.cert-title {
    text-align: center;
    margin-top: 80px;
    margin-bottom: 40px;
    font-size: 1.8em;
    color: var(--dark-text);
    font-weight: 700;
}

.cert-container {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 30px;
    margin-bottom: 50px;
}

.cert-badges {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
    justify-content: center;
}

.cert-link {
    text-decoration: none;
    display: block;
}

.cert-badge {
    display: flex;
    align-items: center;
    background-color: #ffffff;
    padding: 15px 25px;
    border-radius: 50px;
    /* Pill shape */
    box-shadow: var(--shadow-card);
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
    min-width: 200px;
}

.cert-badge:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: var(--shadow-hover);
    border-color: var(--red-accent);
}

.cert-logo {
    height: 40px;
    width: auto;
    margin-right: 15px;
}

.cert-info {
    display: flex;
    flex-direction: column;
}

.cert-provider {
    font-size: 0.8em;
    color: var(--light-text);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cert-name {
    font-weight: 700;
    color: var(--dark-text);
    font-size: 1.1em;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .timeline-container::after {
        left: 31px;
    }

    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }

    .timeline-item:nth-child(odd),
    .timeline-item:nth-child(even) {
        left: 0;
        text-align: left;
    }

    .timeline-item::after {
        left: 21px;
        /* Adjust based on line position */
        right: auto;
    }

    .timeline-item:nth-child(even)::after {
        left: 21px;
    }

    .cert-badges {
        flex-direction: column;
        align-items: center;
    }

    .cert-badge {
        width: 100%;
        max-width: 300px;
    }
}