/* assets/certificate.css */

/* ── Shell ── */
.cert-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 24px 80px;
    background: #0e1422;
}

.cert-no-print {
    margin-bottom: 28px;
}

.cert-print-btn {
    display: inline-block;
    padding: 11px 32px;
    background: #6AA59C;
    color: #0D1117;
    font-size: 0.9rem;
    font-weight: 700;
    border-radius: 999px;
    cursor: pointer;
    text-decoration: none;
    letter-spacing: 0.02em;
    transition: opacity 0.15s;
}

.cert-print-btn:hover {
    opacity: 0.85;
    color: #0D1117;
}

/* ── Certificate card ── */
.cert-card {
    width: 100%;
    max-width: 780px;
    background: #121a2b;
    color: #E8EAF0;
    border: 1px solid rgba(106, 165, 156, 0.25);
    border-radius: 20px;
    padding: 0 0 48px;
    box-shadow: 0 32px 80px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(106,165,156,0.08);
    position: relative;
    overflow: hidden;
    text-align: center;
    box-sizing: border-box;
}

/* Thick teal gradient header bar */
.cert-border-top {
    height: 8px;
    background: linear-gradient(90deg, #4B7F76, #6AA59C, #8FCFC7);
    border-radius: 20px 20px 0 0;
    margin-bottom: 48px;
}

.cert-border-bottom {
    height: 6px;
    background: linear-gradient(90deg, #8FCFC7, #6AA59C, #4B7F76);
    border-radius: 0 0 20px 20px;
    margin-top: 48px;
    display: none; /* hidden — bottom padding handles spacing */
}

/* Subtle corner watermark */
.cert-card::before {
    content: "B";
    position: absolute;
    bottom: -20px;
    right: -20px;
    font-size: 160px;
    font-weight: 900;
    color: rgba(106, 165, 156, 0.04);
    line-height: 1;
    pointer-events: none;
    font-family: 'DM Sans', sans-serif;
}

/* Card inner padding */
.cert-inner {
    padding: 0 64px;
}

/* ── Seal / medallion ── */
.cert-seal {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4B7F76, #6AA59C);
    color: #fff;
    font-weight: 900;
    font-size: 1.9rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 28px;
    box-shadow: 0 0 0 6px rgba(106,165,156,0.12), 0 0 0 12px rgba(106,165,156,0.06);
    font-family: 'DM Sans', sans-serif;
}

/* ── Typography ── */
.cert-label {
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.25em;
    color: #6AA59C;
    text-transform: uppercase;
    margin-bottom: 32px;
}

.cert-intro {
    font-size: 0.88rem;
    color: rgba(200, 205, 220, 0.5);
    margin-bottom: 6px;
    font-style: italic;
}

.cert-name {
    font-size: 2.4rem;
    font-weight: 800;
    color: #E8EAF0;
    margin: 10px 0 24px;
    font-family: Georgia, 'Times New Roman', serif;
    letter-spacing: 0.01em;
}

.cert-track {
    font-size: 1.25rem;
    font-weight: 700;
    color: #6AA59C;
    margin-bottom: 8px;
    letter-spacing: 0.01em;
}

.cert-tagline {
    font-size: 0.82rem;
    color: rgba(200, 205, 220, 0.35);
    margin-bottom: 0;
    letter-spacing: 0.02em;
}

.cert-score-line {
    font-size: 0.8rem;
    color: rgba(106, 165, 156, 0.8);
    font-weight: 600;
    margin: 8px 0 10px;
    letter-spacing: 0.03em;
}

/* ── Divider ── */
.cert-divider {
    height: 1px;
    background: rgba(106, 165, 156, 0.15);
    margin: 40px 0;
}

/* ── Footer ── */
.cert-footer-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.cert-footer-col {
    text-align: left;
    min-width: 130px;
}

.cert-footer-right {
    text-align: right;
}

.cert-date-val {
    font-size: 0.95rem;
    font-weight: 700;
    color: #E8EAF0;
    margin-bottom: 4px;
}

.cert-site {
    font-size: 0.95rem;
    font-weight: 700;
    color: #E8EAF0;
    margin-bottom: 4px;
}

.cert-footer-label {
    font-size: 0.65rem;
    color: rgba(200, 205, 220, 0.35);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.cert-logo {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: linear-gradient(135deg, #4B7F76, #6AA59C);
    color: #fff;
    font-weight: 900;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(106, 165, 156, 0.25);
    font-family: 'DM Sans', sans-serif;
}

/* ── Coach certificate celebration modal ── */
.coach-cert-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 24px;
}

.coach-cert-modal {
    background: #1A1F2B;
    border: 1px solid rgba(106, 165, 156, 0.4);
    border-radius: 20px;
    padding: 40px 36px 32px;
    max-width: 420px;
    width: 100%;
    text-align: center;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6);
}

.coach-cert-modal-title {
    font-size: 1.3rem;
    font-weight: 800;
    color: #E8EAF0;
    margin-bottom: 10px;
}

.coach-cert-modal-body {
    font-size: 0.9rem;
    color: rgba(200, 205, 220, 0.75);
    margin-bottom: 8px;
    line-height: 1.5;
}

.coach-cert-modal-score {
    font-size: 0.85rem;
    font-weight: 600;
    color: #6AA59C;
    margin-bottom: 20px;
}

.coach-cert-modal-link {
    display: block;
    margin: 16px auto 0;
    padding: 11px 28px;
    background: #6AA59C;
    color: #0D1117;
    font-size: 0.9rem;
    font-weight: 700;
    border-radius: 999px;
    text-decoration: none;
    transition: opacity 0.15s;
    width: fit-content;
}

.coach-cert-modal-link:hover { opacity: 0.85; }

.coach-cert-modal-dismiss {
    display: block;
    margin: 12px auto 0;
    padding: 9px 24px;
    background: transparent;
    color: rgba(200, 205, 220, 0.5);
    font-size: 0.85rem;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    cursor: pointer;
    transition: color 0.15s, border-color 0.15s;
    width: fit-content;
}

.coach-cert-modal-dismiss:hover {
    color: rgba(200, 205, 220, 0.85);
    border-color: rgba(255, 255, 255, 0.25);
}

/* Legacy */
.coach-cert-banner { display: none; }

/* ── Profile certificate section ── */
.pf-cert-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.pf-cert-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 8px;
}

.pf-cert-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.pf-cert-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: #E8EAF0;
}

.pf-cert-date {
    font-size: 0.75rem;
    color: rgba(200, 205, 220, 0.5);
}

.pf-cert-score {
    font-size: 0.72rem;
    color: #6AA59C;
    font-weight: 600;
}

.pf-cert-print-link {
    font-size: 0.82rem;
    font-weight: 600;
    color: #6AA59C;
    text-decoration: none;
    white-space: nowrap;
    margin-left: 16px;
}

.pf-cert-print-link:hover { text-decoration: underline; }

/* ── Print ── */
@media print {
    .cert-no-print { display: none !important; }

    body { background: white !important; }

    .cert-shell {
        padding: 0 !important;
        min-height: unset !important;
        background: #ffffff !important;
    }

    .cert-card {
        background: #ffffff !important;
        color: #0D1117 !important;
        border: none !important;
        box-shadow: none !important;
        border-radius: 0 !important;
        max-width: 100% !important;
    }

    .cert-card::before { display: none !important; }

    .cert-name { color: #0D1117 !important; }
    .cert-intro { color: #555 !important; }
    .cert-tagline { color: #777 !important; }
    .cert-date-val, .cert-site { color: #0D1117 !important; }
    .cert-footer-label { color: #888 !important; }
    .cert-divider { background: rgba(0,0,0,0.15) !important; }
}
