﻿
.cert-card {
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.05);
    padding: 22px 24px;
    position: relative;
    overflow: hidden;
}

.cert-card-content {
    position: relative;
    font-size: 0.95rem;
}

.cert-logo {
    width: 52px;
    height: 52px;
    object-fit: cover;
}

.cert-brand {
    font-weight: 700;
    font-size: 0.95rem;
    color: #6c4960;
}

.cert-brand-sub {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #b28aa8;
}

.cert-title-main {
    font-weight: 800;
    font-size: 1.1rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #f8b7d8;
    text-align: center;
}

.cert-line {
    height: 1px;
    background: linear-gradient(to right, transparent, #f8b7d8, transparent);
    margin: 12px 0 16px;
}

.cert-row .cert-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #9b8a98;
    margin-bottom: 2px;
}

.cert-row .cert-value {
    font-size: 0.95rem;
    color: #4a2d40;
}

.cert-amount {
    font-weight: 700;
    font-size: 1rem;
    color: #d62372;
}

.cert-footer {
    margin-top: 14px;
    padding-top: 10px;
    border-top: 1px dashed #f0e1ee;
    display: flex;
    justify-content: space-between;
    gap: 10px;
    font-size: 0.8rem;
    color: #9b8a98;
}

.cert-status {
    font-size: 0.8rem;
    padding: 4px 10px;
    border-radius: 999px;
    font-weight: 600;
    white-space: nowrap;
}

.cert-status-pending {
    background: #fff4e0;
    color: #d68721;
    border: 1px solid #f3c274;
}

.cert-download-btn {
    background: #d62335;
    color: #ffffff;
    border-radius: 999px;
    padding: 6px 16px;
    font-size: 0.8rem;
    white-space: nowrap;
}

    .cert-download-btn:hover {
        background: #b81d2c;
        color: #ffffff;
    }

.cert-footer-admin {
    margin-top: 18px;
    padding-top: 12px;
    border-top: 1px dashed #f2dcea;
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 0.8rem;
    color: #9b8a98;
}

.cert-download-btn {
    background: #d62335;
    color: white;
    border-radius: 999px;
    box-shadow: 0 6px 14px rgba(214,35,53,0.15);
    transition: all 0.2s ease;
}

    .cert-download-btn:hover {
        background: #b81d2c;
        transform: translateY(-1px);
    }



/* ===================== АДАПТИВ ===================== */

@media (max-width: 768px) {
    .cert-card {
        padding: 18px 16px;
        border-radius: 20px;
    }

    .cert-card-content {
        font-size: 0.9rem;
    }

    .cert-logo {
        width: 44px;
        height: 44px;
    }

    .cert-brand {
        font-size: 0.9rem;
    }

    .cert-brand-sub {
        font-size: 0.75rem;
        letter-spacing: 0.1em;
    }

    .cert-title-main {
        font-size: 1rem;
        letter-spacing: 0.14em;
    }
    /* Ряди підряд, без сильного притискання вправо */
    .cert-row.d-flex {
        flex-direction: column;
        align-items: flex-start;
    }

    .cert-row .cert-right {
        text-align: left !important;
        margin-top: 6px;
    }

    .cert-footer {
        flex-direction: column;
        align-items: flex-start;
        font-size: 0.78rem;
    }

        .cert-footer span:last-child {
            order: -1; /* назву студії можна показати першою */
        }
}

@media (max-width: 576px) {
    .cert-card {
        padding: 16px 14px;
    }

    .cert-title-main {
        font-size: 0.95rem;
        letter-spacing: 0.12em;
    }

    .cert-brand {
        font-size: 0.85rem;
    }

    .cert-brand-sub {
        font-size: 0.7rem;
    }

    .cert-download-btn,
    .cert-status {
        font-size: 0.75rem;
        padding: 4px 12px;
    }
    /* Верхній рядок — у дві лінії, щоб не ламати верстку */
    .cert-card-content > .d-flex {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

        .cert-card-content > .d-flex > div:last-child {
            align-self: flex-end;
        }
}

.cert-header {
    padding-bottom: 8px;
    border-bottom: 1px solid #f3e6ef;
}

.cert-logo {
    width: 52px;
    height: 52px;
    object-fit: cover;
}

.cert-brand {
    font-weight: 700;
    font-size: 0.95rem;
    color: #6c4960;
}

.cert-brand-sub {
    font-size: 0.75rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #b28aa8;
}

.cert-status {
    font-size: 0.75rem;
    padding: 4px 12px;
    border-radius: 999px;
    font-weight: 600;
    white-space: nowrap;
}

.cert-status-pending {
    background: #fff4e0;
    color: #b26a12;
    border: 1px solid #f3c274;
}

.cert-status-approved {
    background: #e4f6ec;
    color: #1e8b4c;
    border: 1px solid #6bcf97;
}

/* ================= АДАПТАЦІЯ ================= */

@media (max-width: 768px) {

    .cert-header {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 10px;
    }        
        .cert-header > div:first-child {
            gap: 10px;
        }
        
        .cert-header > div:last-child {
            align-self: flex-start;
        }

    .cert-logo {
        width: 44px;
        height: 44px;
    }

    .cert-brand {
        font-size: 0.9rem;
    }

    .cert-brand-sub {
        font-size: 0.7rem;
        letter-spacing: 0.1em;
    }
}

@media (max-width: 480px) {

    .cert-logo {
        width: 40px;
        height: 40px;
    }

    .cert-status {
        font-size: 0.7rem;
        padding: 3px 10px;
    }

    .cert-brand {
        font-size: 0.85rem;
    }
}

.admin-cert-card {
    border-radius: 20px;
    overflow: hidden;
    background: #ffffff;
}

.admin-cert-brand {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 700;
    color: #6c757d;
}

.admin-cert-brand-sub {
    font-size: 0.75rem;
    color: #adb5bd;
}

.admin-cert-title-main {
    font-size: 0.9rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    font-weight: 600;
    color: #343a40;
}

.admin-cert-line {
    height: 2px;
    border-radius: 999px;
    background: linear-gradient(90deg, #f8b7d8, #ffe8f3);
    opacity: 0.7;
}


.admin-cert-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #6c757d;
    margin-bottom: 2px;
}

.admin-cert-value {
    font-size: 0.9rem;
    color: #212529;
}

.admin-cert-amount {
    font-size: 1rem;
    font-weight: 700;
    color: #e26da6; 
}


.admin-cert-status {
    font-size: 0.7rem;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    font-weight: 600;
    white-space: nowrap;
}

.admin-cert-status-approved {
    background-color: #d1e7dd;
    color: #0f5132;
}

.admin-cert-status-pending {
    background-color: #fff3cd;
    color: #664d03;
}


.cert-row {
    display: flex;
    gap: 0.25rem;
    font-size: 0.85rem;
}

.cert-label {
    font-weight: 600;
    color: #6c757d;
}

.cert-value {
    color: #212529;
}

.cert-action-btn {
    border: 1px solid #f8b7d8;
    background-color: #f8b7d8;
    color: #fff;
    font-size: 0.8rem;
    padding: 0.25rem 0.9rem;
}

    .cert-action-btn:disabled {
        background-color: #e9ecef;
        border-color: #dee2e6;
        color: #6c757d;
    }

.btn-icon-danger {
    border-radius: 999px;
    padding: 0.1rem 0.45rem;
    line-height: 1;
    border: none;
    background-color: #ffe3e6;
    color: #dc3545;
}

    .btn-icon-danger:hover {
        background-color: #ffc2ca;
        color: #b02a37;
    }
