/* Certifications Section */
.certifications-section {
    padding: 6rem 0;
    background: linear-gradient(180deg, var(--bg-primary, #f8fafc) 0%, var(--bg-secondary, #f1f5f9) 100%);
    position: relative;
    overflow: hidden;
}

/* Section Header */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-subtitle {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    background: linear-gradient(135deg, rgba(66, 133, 244, 0.1), rgba(126, 63, 242, 0.1));
    border-radius: 50px;
    font-size: 0.875rem;
    font-weight: 600;
    color: #4285f4;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 1rem;
}

.section-header .section-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-primary, #1a1a2e);
    margin-bottom: 1rem;
}

.section-description {
    font-size: 1.1rem;
    color: var(--text-secondary, #6b7280);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.7;
}

/* Certifications Timeline */
.certifications-timeline {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    max-width: 1000px;
    margin: 0 auto 4rem;
}

/* Certification Row - Contains Card + Badge Box */
.cert-row {
    display: flex;
    gap: 1rem;
    align-items: stretch;
}

/* Certification Card */
.cert-card {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    background: var(--card-bg, #ffffff);
    border-radius: 16px;
    padding: 1.5rem 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid rgba(0, 0, 0, 0.05);
    flex: 1;
}

.cert-card:hover {
    transform: translateY(-5px) scale(1.01);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
}

.cert-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, #4285f4, #7e3ff2);
    opacity: 0;
    transition: opacity 0.3s ease;
}

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

/* Certification Badge Box */
.cert-badge-box {
    width: 200px;
    min-width: 200px;
    background: var(--card-bg, #ffffff);
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    cursor: pointer;
    text-decoration: none;
    gap: 0.5rem;
}

.cert-badge-box i {
    font-size: 1.5rem;
    color: #4285f4;
    transition: all 0.3s ease;
}

.cert-badge-box span {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-secondary, #6b7280);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: center;
    transition: all 0.3s ease;
}

.cert-badge-box:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    background: linear-gradient(135deg, #4285f4, #7e3ff2);
}

.cert-badge-box:hover i,
.cert-badge-box:hover span {
    color: #fff;
}

/* Certification Icon */
.cert-icon-wrapper {
    width: 70px;
    min-width: 70px;
    border-radius: 16px;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}
.cert-icon-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: inherit;
    filter: blur(10px);
    opacity: 0.5;
    transform: scale(1.2);
}

.cert-icon-wrapper i {
    font-size: 1.75rem;
    color: #fff;
    position: relative;
    z-index: 1;
}

/* Icon Variants */
.cert-icon-wrapper.gcp {
    background: linear-gradient(135deg, #4285f4, #34a853, #fbbc04, #ea4335);
}

.cert-icon-wrapper.kubernetes {
    background: linear-gradient(135deg, #326ce5, #1e4a9e);
}

.cert-icon-wrapper.istio {
    background: linear-gradient(135deg, #466bb0, #2d4373);
}

.cert-icon-wrapper.udemy {
    background: linear-gradient(135deg, #a435f0, #7b2cbf);
}

/* Certification Content */
.cert-content {
    flex: 1;
}

.cert-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.5rem;
    flex-wrap: wrap;
}

.cert-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary, #1a1a2e);
    margin: 0;
}

.cert-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.cert-badge.active {
    background: linear-gradient(135deg, #10b981, #059669);
    color: #fff;
    animation: pulse-badge 2s infinite;
}

.cert-badge.completed {
    background: linear-gradient(135deg, #6366f1, #4f46e5);
    color: #fff;
}

@keyframes pulse-badge {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4);
    }
    50% {
        box-shadow: 0 0 0 8px rgba(16, 185, 129, 0);
    }
}

.cert-issuer {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary, #6b7280);
    margin-bottom: 0.5rem;
}

.cert-issuer i {
    font-size: 0.8rem;
    color: #9ca3af;
}

.cert-description {
    font-size: 0.9rem;
    color: var(--text-secondary, #6b7280);
    line-height: 1.6;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Certification Date */
.cert-date {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    background: var(--bg-secondary, #f1f5f9);
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary, #1a1a2e);
    white-space: nowrap;
    transition: all 0.3s ease;
}

.cert-card:hover .cert-date {
    background: linear-gradient(135deg, #4285f4, #7e3ff2);
    color: #fff;
}

.cert-date i {
    font-size: 0.85rem;
}

/* Certification Ribbon */
.cert-ribbon {
    position: absolute;
    top: -10px;
    right: 20px;
    width: 30px;
    height: 50px;
    background: linear-gradient(180deg, #fbbf24, #f59e0b);
    clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 80%, 0 100%);
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.cert-card:hover .cert-ribbon {
    opacity: 1;
    transform: translateY(0);
}

/* Certification Stats */
.cert-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    max-width: 800px;
    margin: 0 auto;
    padding: 3rem 2rem;
    background: var(--card-bg, #ffffff);
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
}

.stat-item {
    text-align: center;
    padding: 1rem;
    position: relative;
}

.stat-item::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 60%;
    background: linear-gradient(180deg, transparent, #e5e7eb, transparent);
}

.stat-item:last-child::after {
    display: none;
}

.stat-icon {
    width: 50px;
    height: 50px;
    margin: 0 auto 1rem;
    background: linear-gradient(135deg, rgba(66, 133, 244, 0.1), rgba(126, 63, 242, 0.1));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.stat-item:hover .stat-icon {
    background: linear-gradient(135deg, #4285f4, #7e3ff2);
    transform: scale(1.1) rotate(5deg);
}

.stat-icon i {
    font-size: 1.25rem;
    color: #4285f4;
    transition: color 0.3s ease;
}

.stat-item:hover .stat-icon i {
    color: #fff;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-primary, #1a1a2e);
    line-height: 1;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #4285f4, #7e3ff2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary, #6b7280);
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.cert-row {
    animation: fadeInUp 0.6s ease forwards;
}

.cert-row:nth-child(1) { animation-delay: 0.1s; }
.cert-row:nth-child(2) { animation-delay: 0.2s; }
.cert-row:nth-child(3) { animation-delay: 0.3s; }
.cert-row:nth-child(4) { animation-delay: 0.4s; }
.cert-row:nth-child(5) { animation-delay: 0.5s; }

/* Responsive Design */
@media (max-width: 768px) {
    .certifications-section {
        padding: 4rem 0;
    }

    .section-header .section-title {
        font-size: 2rem;
    }

    .cert-row {
        flex-direction: column;
    }

    .cert-card {
        flex-direction: column;
        text-align: center;
        padding: 1.5rem;
    }

    .cert-badge-box {
        width: 100%;
        min-width: unset;
        flex-direction: row;
        padding: 0.75rem 1rem;
    }

    .cert-header {
        justify-content: center;
    }

    .cert-issuer {
        justify-content: center;
    }

    .cert-date {
        margin-top: 1rem;
    }

    .cert-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
        padding: 2rem 1rem;
    }

    .stat-item::after {
        display: none;
    }

    .stat-item:nth-child(odd)::after {
        display: block;
    }

    .stat-number {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .cert-stats {
        grid-template-columns: 1fr 1fr;
    }

    .cert-title {
        font-size: 1.1rem;
    }

    .cert-description {
        font-size: 0.85rem;
    }
}

/* Dark Mode Support */
[data-theme="dark"] .certifications-section {
    background: linear-gradient(180deg, var(--bg-primary, #0f172a) 0%, var(--bg-secondary, #1e293b) 100%);
}

[data-theme="dark"] .cert-card,
[data-theme="dark"] .cert-badge-box {
    background: var(--bg-card, #1e293b);
    border-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .cert-title {
    color: var(--text-primary, #f8fafc);
}

[data-theme="dark"] .cert-issuer,
[data-theme="dark"] .cert-description {
    color: var(--text-secondary, #94a3b8);
}

[data-theme="dark"] .cert-date {
    background: var(--bg-tertiary, #334155);
    color: var(--text-primary, #f8fafc);
}

[data-theme="dark"] .cert-badge-box span {
    color: var(--text-secondary, #94a3b8);
}

[data-theme="dark"] .cert-stats {
    background: var(--bg-card, #1e293b);
}

[data-theme="dark"] .stat-number {
    color: var(--text-primary, #f8fafc);
}

[data-theme="dark"] .stat-label {
    color: var(--text-secondary, #94a3b8);
}

[data-theme="dark"] .section-header .section-title {
    color: var(--text-primary, #f8fafc);
}

[data-theme="dark"] .section-description {
    color: var(--text-secondary, #94a3b8);
}

[data-theme="dark"] .section-subtitle {
    color: #60a5fa;
}

[data-theme="dark"] .stat-item::after {
    background: linear-gradient(180deg, transparent, #475569, transparent);
}