.cert-page {
    background: #f8fbff;
    color: #1f2937;
}

.cert-hero {
    position: relative;
    min-height: 420px;
    padding: 96px 20px 86px;
    text-align: center;
    background:
        linear-gradient(
            rgba(10, 22, 38, 0.38),
            rgba(10, 22, 38, 0.38)
        ),
        url("/images/shop/cert/certificate_main_pc.png") center center / cover no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cert-hero-inner {
    position: relative;
        z-index: 1;
        max-width: 880px;
        margin: -120px auto 0;
        color: #fff;
}

.cert-eyebrow {
    font-size: 13px;
    font-weight: 800;
    color: #dbeafe;
    letter-spacing: 0.12em;
    margin-bottom: 14px;
}

.cert-hero h1 {
    font-size: 42px;
    line-height: 1.28;
    font-weight: 900;
    margin: 0 0 18px;
    color: #fff;

    text-shadow:
        0 2px 4px rgba(0,0,0,0.25),
        0 8px 18px rgba(0,0,0,0.35),
        0 18px 38px rgba(0,0,0,0.25);
}

.cert-hero p {
    font-size: 14px;
    line-height: 1.8;
    color: rgba(255,255,255,.92);
    text-shadow: 0 2px 12px rgba(0,0,0,.35);
}

@media (max-width: 640px) {
    .cert-hero {
        min-height: 340px;
        padding: 76px 18px 64px;
        background:
            linear-gradient(
                rgba(10, 22, 38, 0.46),
                rgba(10, 22, 38, 0.46)
            ),
            url("/images/shop/cert/certificate_main_mo.png") center center / cover no-repeat;
    }

    .cert-hero h1 {
        font-size: 30px;
    }

    .cert-hero p {
        font-size: 13px;
    }

    .cert-hero-inner {
        position: relative;
        z-index: 1;
        max-width: 880px;
        margin: -38px auto 0;
        color: #fff;
    }
}

.cert-section {
    padding: 56px 20px 80px;
}

.cert-container {
    max-width: 1180px;
    margin: 0 auto;
}

.cert-tab-wrap {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 36px;
}

.cert-tab {
    border: 1px solid #dbeafe;
    background: #fff;
    color: #475569;
    padding: 11px 20px;
    border-radius: 999px;
    font-weight: 700;
    cursor: pointer;
}

.cert-tab.active {
    background: #2f80ed;
    color: #fff;
    border-color: #2f80ed;
}

.cert-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 26px;
}

.cert-card {
    background: #fff;
    border: 1px solid #e5eef8;
    border-radius: 26px;
    overflow: hidden;
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.07);
    transition: transform .2s ease, box-shadow .2s ease;
}

.cert-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 44px rgba(15, 23, 42, 0.12);
}

.cert-thumb {
    height: 250px;
    background: #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.cert-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cert-card-body {
    padding: 22px;
}

.cert-badge {
    display: inline-block;
    padding: 6px 11px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
    margin-bottom: 12px;
}

.badge-kc {
    background: #e0f2fe;
    color: #0369a1;
}

.badge-patent {
    background: #ede9fe;
    color: #6d28d9;
}

.badge-test {
    background: #dcfce7;
    color: #15803d;
}

.cert-card h3 {
    font-size: 18px;
    margin: 0 0 12px;
    color: #0f172a;
}

.cert-card p {
    font-size: 14px;
    color: #64748b;
    margin: 4px 0;
}

.cert-view-btn {
    margin-top: 18px;
    width: 100%;
    height: 44px;
    border: 0;
    border-radius: 14px;
    background: #10233f;
    color: #fff;
    font-weight: 800;
    cursor: pointer;
}

.cert-modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, .65);
    z-index: 9999;
    padding: 24px;
    align-items: center;
    justify-content: center;
}

.cert-modal.show {
    display: flex;
}

.cert-modal-box {
    display: inline-block;
    width: auto;
    max-width: calc(100vw - 48px);
    max-height: calc(100vh - 48px);
    background: #fff;
    border-radius: 26px;
    padding: 26px;
    position: relative;
    text-align: center;
    overflow: auto;
}

.cert-modal-box img {
    display: block;
    margin: 0 auto;
    max-width: calc(100vw - 100px);
    max-height: 72vh;
    width: auto;
    height: auto;
    border-radius: 16px;
}

.cert-modal-close {
    position: absolute;
    top: 16px;
    right: 18px;
    border: 0;
    background: transparent;
    font-size: 32px;
    cursor: pointer;
}

.cert-modal-box h3 {
    margin: 0 0 20px;
    font-size: 22px;
}


@media (max-width: 900px) {
    .cert-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .cert-hero h1 {
        font-size: 34px;
    }
}

@media (max-width: 640px) {
    .cert-hero {
        padding: 54px 18px 44px;
    }

    .cert-hero h1 {
        font-size: 28px;
    }

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

    .cert-thumb {
        height: 220px;
    }
}

.cert-btn-row {
    display: flex;
    gap: 8px;
    margin-top: 18px;
    align-items: stretch;
}

.cert-view-btn,
.cert-download-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;

    height: 44px;
    padding: 0 14px;

    border: 0;
    border-radius: 14px;

    background: #10233f;
    color: #fff;

    font-size: 14px;
    font-weight: 800;
    line-height: 1;

    cursor: pointer;
    text-decoration: none;

    box-sizing: border-box;
    appearance: none;
    -webkit-appearance: none;

    margin: 0;
}

.cert-download-btn {
    background: #10233f;
}