/* Education Page Styles */
.education-section {
    padding: var(--spacing-3xl) 0;
}

.page-header {
    text-align: center;
    margin-bottom: var(--spacing-2xl);
}

.page-header h1 {
    font-size: var(--font-4xl);
    font-weight: var(--font-weight-semibold);
    margin-bottom: var(--spacing-xs);
    color: var(--text-color);
}

.page-header p {
    color: var(--text-secondary);
    font-size: var(--font-md);
}

/* Modern Timeline Styles */
.timeline {
    position: relative;
    max-width: 1000px;
    margin: 0 auto 5rem;
    padding: var(--spacing-lg) 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    top: 0;
    height: 100%;
    width: 2px;
    background: linear-gradient(180deg, var(--primary-color), rgba(var(--primary-color-rgb), 0.2));
}

.timeline-item {
    position: relative;
    margin-bottom: var(--spacing-xl);
    display: flex;
    justify-content: flex-end;
    width: 100%;
}

.timeline-item:nth-child(even) {
    justify-content: flex-start;
}

.timeline-marker {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    top: 0;
    z-index: 2;
}

.timeline-marker::before {
    display: none;
}

.timeline-dot {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--bg-color);
    border: 4px solid var(--primary-color);
    box-shadow: 0 0 0 6px rgba(var(--primary-color-rgb), 0.15);
    position: relative;
    z-index: 1;
}

.timeline-content {
    background: var(--bg-alt);
    padding: var(--spacing-lg);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
    transition: all var(--transition-base);
    width: calc(50% - 40px);
}

.timeline-item:nth-child(odd) .timeline-content {
    margin-right: auto;
}

.timeline-item:nth-child(even) .timeline-content {
    margin-left: auto;
}

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

.timeline-badge {
    display: inline-block;
    background: var(--primary-color);
    color: var(--bg-color);
    padding: 0.5rem var(--spacing-sm);
    border-radius: var(--radius-full);
    font-size: var(--font-xs);
    font-weight: var(--font-weight-medium);
    margin-bottom: var(--spacing-sm);
}

.timeline-content h3 {
    font-size: var(--font-xl);
    font-weight: var(--font-weight-semibold);
    margin-bottom: var(--spacing-xs);
    color: var(--text-color);
}

.timeline-content h4 {
    font-size: var(--font-md);
    color: var(--primary-color);
    margin-bottom: var(--spacing-sm);
    font-weight: var(--font-weight-medium);
}

.timeline-description {
    color: var(--text-secondary);
    line-height: var(--line-height-relaxed);
    margin-bottom: var(--spacing-sm);
}

.timeline-highlights {
    list-style: none;
    padding: 0;
    margin-top: var(--spacing-md);
}

.timeline-highlights li {
    position: relative;
    padding-left: var(--spacing-md);
    margin-bottom: 0.75rem;
    color: var(--text-secondary);
    line-height: var(--line-height-relaxed);
}

.timeline-highlights li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: var(--font-weight-bold);
}

/* Certificates Section */
.certs-header {
    margin-top: 5rem;
}

.certs-header h2 {
    font-size: var(--font-3xl);
    font-weight: var(--font-weight-semibold);
    margin-bottom: var(--spacing-xl);
    color: var(--text-color);
    text-align: center;
}

.certs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: var(--spacing-lg);
    margin: 0 auto;
}

.cert-card {
    background: var(--bg-alt);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: transform var(--transition-base), box-shadow var(--transition-base);
    box-shadow: var(--shadow-sm);
}

.cert-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.cert-image-container {
    position: relative;
    width: 100%;
    max-width: 100%;
    height: 210px;
    overflow: hidden;
    background: var(--bg-alt);
    margin: 0 auto;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-sm);
}

.cert-image {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform var(--transition-slow);
    display: block;
}

.cert-card:hover .cert-image {
    transform: scale(1.05);
}

.cert-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity var(--transition-base);
}

.cert-card:hover .cert-overlay {
    opacity: 1;
}

.cert-overlay svg {
    color: var(--bg-color);
    width: 32px;
    height: 32px;
}

.cert-info {
    padding: var(--spacing-md);
}

.cert-info h4 {
    font-size: var(--font-lg);
    font-weight: var(--font-weight-semibold);
    margin-bottom: var(--spacing-xs);
    color: var(--text-color);
}

.cert-issuer {
    color: var(--primary-color);
    font-weight: var(--font-weight-medium);
    margin-bottom: 0.25rem;
}

.cert-date {
    color: var(--text-secondary);
    font-size: var(--font-sm);
}

/* Certifications Section */
.certifications-section {
    margin-top: 5rem;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 600;
    margin-bottom: 3rem;
    color: var(--text-color);
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -1rem;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: var(--primary-color);
    border-radius: 2px;
}

.cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 400px));
    gap: 2rem;
    max-width: 800px;
    margin: 0 auto;
    justify-content: center;
}

.cert-card {
    background: var(--bg-alt);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.cert-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.cert-image-container {
    position: relative;
    width: 100%;
    height: 250px;
    overflow: hidden;
    background: #f5f5f5;
}

.cert-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.cert-card:hover .cert-image {
    transform: scale(1.05);
}

.cert-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.cert-card:hover .cert-overlay {
    opacity: 1;
}

.cert-overlay svg {
    color: var(--bg-color);
    width: 32px;
    height: 32px;
}

.cert-info {
    padding: 1.5rem;
}

.cert-info h4 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.cert-issuer {
    color: var(--primary-color);
    font-weight: 500;
    margin-bottom: 0.25rem;
}

.cert-date {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-header h1 {
        font-size: 2.5rem;
    }
    
    .timeline-content {
        width: calc(50% - 30px);
        padding: 1.75rem;
    }
}

@media (max-width: 768px) {
    .page-header h1 {
        font-size: 2rem;
    }
    
    .page-header p {
        font-size: 1rem;
    }

    .timeline::before {
        left: 20px;
    }

    .timeline-item {
        justify-content: flex-start !important;
        padding-left: 50px;
    }

    .timeline-marker {
        left: 20px;
        transform: translateX(0);
    }

    .timeline-content {
        width: 100%;
        margin: 0 !important;
        padding: 1.5rem;
    }

    .timeline-content h3 {
        font-size: 1.25rem;
    }
    
    .timeline-content h4 {
        font-size: 1.05rem;
    }

    .cert-image-container {
        max-width: 350px;
        height: 240px;
    }

    .education-section {
        padding: 3rem 0;
    }
    
    .certs-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .page-header h1 {
        font-size: 1.75rem;
    }
    
    .page-header p {
        font-size: 0.95rem;
    }
    
    .timeline {
        padding: 1rem 0;
    }
    
    .timeline-item {
        margin-bottom: 2rem;
        padding-left: 40px;
    }
    
    .timeline::before {
        left: 15px;
    }
    
    .timeline-marker {
        left: 15px;
    }
    
    .timeline-dot {
        width: 16px;
        height: 16px;
        border: 3px solid var(--primary-color);
    }
    
    .timeline-content {
        padding: 1.25rem;
    }
    
    .timeline-badge {
        font-size: 0.75rem;
        padding: 0.35rem 0.8rem;
    }
    
    .cert-image-container {
        max-width: 100%;
        height: 200px;
    }
    
    .cert-info {
        padding: 1.25rem;
    }
    
    .cert-info h4 {
        font-size: 1.1rem;
    }
    
    .education-section {
        padding: 2rem 0;
    }
}
