:root {
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --surface: rgba(15, 23, 42, 0.72);
    --surface-border: rgba(148, 163, 184, 0.25);
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --accent: #38bdf8;
    --accent-strong: #0ea5e9;
    --shadow-soft: 0 10px 24px rgba(2, 6, 23, 0.28);
}

body {
    margin: 20px;
    min-height: 100vh;
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    background:
        radial-gradient(circle at 10% 10%, rgba(56, 189, 248, 0.16) 0%, rgba(56, 189, 248, 0) 34%),
        radial-gradient(circle at 90% 90%, rgba(14, 165, 233, 0.12) 0%, rgba(14, 165, 233, 0) 32%),
        linear-gradient(150deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
    padding-top: 130px;
}

.certificates-page {
    width: min(1150px, 96vw);
    margin: 0 auto;
}

.cert-hero {
    background: var(--surface);
    border: 1px solid var(--surface-border);
    border-radius: 24px;
    box-shadow: var(--shadow-soft);
    padding: 34px 28px;
}

.cert-kicker {
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent);
    font-size: 14px;
    font-weight: 700;
}

.cert-title {
    margin: 8px 0 10px;
    font-family: 'Poppins', sans-serif;
    font-size: clamp(30px, 4.8vw, 52px);
    line-height: 1.1;
}

.cert-subtitle {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.75;
    max-width: 840px;
    font-size: 16px;
}

.cert-stats {
    margin-top: 22px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.cert-stat {
    margin: 0;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(148, 163, 184, 0.3);
    border-radius: 14px;
    padding: 12px 14px;
    color: #dbeafe;
    line-height: 1.5;
    text-align: center;
}

.cert-stat span {
    display: block;
    color: var(--accent);
    font-family: 'Poppins', sans-serif;
    font-size: 22px;
    font-weight: 700;
}

.cert-stat-wide {
    grid-column: 1 / -1;
    text-align: center;
    font-weight: 700;
}

.cert-stat-wide span {
    font-size: 20px;
    letter-spacing: 0.4px;
    text-transform: uppercase;
}

.cert-grid {
    margin-top: 24px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.cert-card {
    background: var(--surface);
    border: 1px solid var(--surface-border);
    border-radius: 18px;
    box-shadow: var(--shadow-soft);
    padding: 18px;
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
    opacity: 0;
    transform: translateY(16px);
    animation: reveal 0.55s ease forwards;
}

.cert-card:nth-child(2) { animation-delay: 0.07s; }
.cert-card:nth-child(3) { animation-delay: 0.14s; }
.cert-card:nth-child(4) { animation-delay: 0.21s; }
.cert-card:nth-child(5) { animation-delay: 0.28s; }
.cert-card:nth-child(6) { animation-delay: 0.35s; }

.cert-card:hover {
    transform: translateY(-4px);
    border-color: rgba(56, 189, 248, 0.45);
    box-shadow: 0 14px 28px rgba(2, 6, 23, 0.35);
}

.cert-chip {
    margin: 0;
    width: fit-content;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(56, 189, 248, 0.18);
    color: #dbeafe;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.45px;
    text-transform: uppercase;
}

.cert-card h2 {
    margin: 12px 0 8px;
    font-family: 'Poppins', sans-serif;
    font-size: 21px;
    line-height: 1.35;
    color: var(--text-primary);
}

.cert-source {
    margin: 0;
    color: #dbeafe;
    font-size: 14px;
}

.cert-date {
    margin: 4px 0 10px;
    color: var(--accent);
    font-size: 13px;
    font-weight: 600;
}

.cert-desc {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.65;
    font-size: 14px;
}

.cert-actions {
    margin-top: 16px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.cert-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    padding: 10px 12px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 700;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

.cert-btn:hover {
    transform: translateY(-2px);
}

.cert-btn-primary {
    color: #dbeafe;
    background: rgba(30, 41, 59, 0.75);
    border: 1px solid rgba(148, 163, 184, 0.45);
}

.cert-btn-primary:hover {
    border-color: rgba(56, 189, 248, 0.72);
    background: rgba(30, 41, 59, 0.95);
    box-shadow: 0 10px 16px rgba(2, 6, 23, 0.26);
}

.cert-btn-secondary {
    color: #dbeafe;
    background: rgba(30, 41, 59, 0.75);
    border: 1px solid rgba(148, 163, 184, 0.45);
}

.cert-btn-secondary:hover {
    border-color: rgba(56, 189, 248, 0.72);
    background: rgba(30, 41, 59, 0.95);
    box-shadow: 0 10px 16px rgba(2, 6, 23, 0.26);
}

.cert-footer {
    margin-top: 36px;
    text-align: center;
    color: var(--text-secondary);
    font-size: 14px;
}

@keyframes reveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 1024px) {
    body {
        padding-top: 165px;
    }

    .cert-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    body {
        margin: 12px;
        padding-top: 165px;
    }

    .cert-hero {
        padding: 24px 18px;
    }

    .cert-stats {
        grid-template-columns: 1fr;
    }

    .cert-grid {
        grid-template-columns: 1fr;
    }

    .cert-actions {
        grid-template-columns: 1fr;
    }
}
