/* ============================================================
   LD Custom Cert — Certification Shortcode Styles
   [ldc_certification id="X"]
   ============================================================ */

/* ── Card Container ─────────────────────────────────────────── */
.ldc-cert-card {
    max-width: 700px;
    margin: 0 auto 40px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0,0,0,.12);
    font-family: inherit;
    background: #fff;
    border: 1px solid #e8e8e8;
}

/* ── Featured Image ─────────────────────────────────────────── */
.ldc-cert-image {
    width: 100%;
    max-height: 320px;
    overflow: hidden;
}
.ldc-cert-image img {
    width: 100%;
    height: 320px;
    object-fit: cover;
    display: block;
}

/* ── Body ───────────────────────────────────────────────────── */
.ldc-cert-body {
    padding: 28px 32px 32px;
}

/* ── Title ──────────────────────────────────────────────────── */
.ldc-cert-title {
    font-size: 1.65rem;
    font-weight: 700;
    margin: 0 0 12px;
    color: #1a1a2e;
    line-height: 1.2;
}

/* ── Description ────────────────────────────────────────────── */
.ldc-cert-desc {
    font-size: 1rem;
    color: #555;
    line-height: 1.7;
    margin: 0 0 24px;
}

/* ── Courses List ───────────────────────────────────────────── */
.ldc-cert-courses {
    margin-bottom: 28px;
}
.ldc-cert-courses-title {
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a2e;
    margin: 0 0 12px;
    text-transform: uppercase;
    letter-spacing: .05em;
}
.ldc-cert-courses-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
.ldc-course-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 8px;
    margin-bottom: 6px;
    background: #f8f9fa;
    border: 1px solid #eee;
    transition: background .2s;
}
.ldc-course-item.ldc-course-done {
    background: #f0fff4;
    border-color: #b2dfdb;
}
.ldc-course-item.ldc-course-enrolled {
    background: #fff8e1;
    border-color: #ffe082;
}
.ldc-course-num {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #1a237e;
    color: #fff;
    font-size: .8rem;
    font-weight: 700;
    flex-shrink: 0;
}
.ldc-course-item.ldc-course-done .ldc-course-num {
    background: #2e7d32;
}
.ldc-course-name {
    flex: 1;
    font-size: .95rem;
    color: #333;
}
.ldc-course-name a {
    color: #1a237e;
    text-decoration: none;
    font-weight: 600;
}
.ldc-course-name a:hover { text-decoration: underline; }

.ldc-course-badge {
    font-size: .75rem;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 20px;
}
.ldc-badge-done {
    background: #c8e6c9;
    color: #1b5e20;
}
.ldc-badge-enrolled {
    background: #fff9c4;
    color: #f57f17;
}

/* ── Certificate Template Preview ───────────────────────────── */
.ldc-cert-preview {
    border: 2px solid #1a237e;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 28px;
    font-family: Georgia, serif;
    box-shadow: 0 2px 12px rgba(0,0,0,.08);
}
.ldc-cert-preview-header {
    background: #1a237e;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    gap: 14px;
}
.ldc-cert-preview-logo {
    height: 36px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}
.ldc-cert-preview-org {
    color: #fff;
    font-size: .85rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.ldc-cert-preview-body {
    padding: 20px 24px;
    text-align: center;
    background: #fafafa;
}
.ldc-cert-preview-label {
    font-size: .75rem;
    text-transform: uppercase;
    letter-spacing: .12em;
    color: #888;
    margin-bottom: 8px;
}
.ldc-cert-preview-name {
    font-size: 1.4rem;
    font-style: italic;
    color: #1a237e;
    margin-bottom: 6px;
}
.ldc-cert-preview-course {
    font-size: .95rem;
    color: #444;
    font-weight: 600;
}
.ldc-cert-preview-footer {
    padding: 8px 20px;
    text-align: center;
    font-size: .75rem;
    color: #888;
    border-top: 1px solid #eee;
}

/* ── CTA Section ────────────────────────────────────────────── */
.ldc-cert-cta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-top: 4px;
}
.ldc-cert-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a237e;
    margin-right: 8px;
}
.ldc-cert-price ins {
    text-decoration: none;
}

/* ── Buttons ────────────────────────────────────────────────── */
.ldc-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 12px 28px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 700;
    text-decoration: none !important;
    cursor: pointer;
    transition: all .2s;
    border: none;
    line-height: 1;
}
.ldc-btn-buy {
    background: #1a237e;
    color: #fff !important;
}
.ldc-btn-buy:hover {
    background: #283593;
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(26,35,126,.35);
    color: #fff !important;
}
.ldc-btn-details {
    background: transparent;
    color: #1a237e !important;
    border: 2px solid #1a237e;
}
.ldc-btn-details:hover {
    background: #e8eaf6;
}
.ldc-btn-view {
    background: #2e7d32;
    color: #fff !important;
}
.ldc-btn-view:hover {
    background: #388e3c;
    color: #fff !important;
}
.ldc-btn-continue {
    background: #f57c00;
    color: #fff !important;
}
.ldc-btn-continue:hover {
    background: #ef6c00;
    color: #fff !important;
}

/* ── Earned Badge ───────────────────────────────────────────── */
.ldc-cert-earned {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #e8f5e9;
    border: 1px solid #a5d6a7;
    color: #2e7d32;
    font-weight: 700;
    padding: 10px 16px;
    border-radius: 8px;
    width: 100%;
}
.ldc-cert-earned-icon { font-size: 1.4rem; }

.ldc-cert-progress-msg {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #fff8e1;
    border: 1px solid #ffe082;
    color: #f57f17;
    font-weight: 600;
    padding: 10px 16px;
    border-radius: 8px;
    width: 100%;
}

.ldc-cert-no-product {
    color: #888;
    font-style: italic;
    margin: 0;
}

/* ── Responsive ─────────────────────────────────────────────── */
@media ( max-width: 640px ) {
    .ldc-cert-body {
        padding: 20px 18px 24px;
    }
    .ldc-cert-title {
        font-size: 1.3rem;
    }
    .ldc-cert-cta {
        flex-direction: column;
        align-items: stretch;
    }
    .ldc-btn {
        width: 100%;
        justify-content: center;
    }
}
