.certificates-container {
    margin-top: 120px; /* ← увеличь по вкусу */
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    padding: 4rem 2rem;
}

.certificate-card {
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    padding: 1.5rem;
    width: 500px; /* Увеличена ширина карточки */
    text-align: center;
    color: #fff;
    box-shadow: 0 0 10px rgba(0,0,0,0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.certificate-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 20px rgba(0,255,0,0.3);
}

.certificate-card img {
    width: 100%;
    max-height: 600px; /* Увеличена высота превью */
    object-fit: contain;
    border-radius: 8px;
    margin-bottom: 1rem;
    border: 1px solid rgba(255,255,255,0.1);
    cursor: zoom-in; /* Добавлен курсор увеличения */
}

.certificate-card h3 {
    margin: 0.5rem 0;
    font-size: 1.4rem;
}

.certificate-card p {
    font-size: 1rem;
    color: #ccc;
    margin-bottom: 1rem;
}

.certificate-card a {
    color: #00ffcc;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.certificate-card a:hover {
    color: #00ffaa;
}

/* Модальное окно */
.modal {
    display: none;
    position: fixed;
    z-index: 999;
    padding-top: 60px;
    left: 0;
    top: 0;
    width: 100vw;
    height: 100vh;
    overflow: auto;
    background-color: rgba(0,0,0,0.9);
}

.modal-content {
    margin: auto;
    display: block;
    max-width: 90%;
    max-height: 90vh;
    border-radius: 10px;
    box-shadow: 0 0 25px rgba(0, 255, 100, 0.3);
}

.modal-close {
    position: absolute;
    top: 30px;
    right: 40px;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1000;
    transition: 0.3s;
}

.modal-close:hover {
    color: #0f0;
}

/* Добавим анимацию появления */
.certificate-card {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease forwards;
}

/* Если несколько карточек — сделаем задержку через nth-child */
.certificate-card:nth-child(1) { animation-delay: 0.1s; }
.certificate-card:nth-child(2) { animation-delay: 0.2s; }
.certificate-card:nth-child(3) { animation-delay: 0.3s; }
/* И так далее, по количеству карточек */

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