/* ===== GALERÍA ===== */

.gpd-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
    justify-items: center;
}

.gpd-card {
    cursor: pointer;
    text-align: center;
    outline: none;
}

.gpd-card-image {
    width: 260px;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: 50%;
    margin: 0 auto;
}

.gpd-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gpd-card-caption {
    background: rgba(0, 0, 0, 0.85);
    color: #fff;
    padding: 6px 10px;
    margin-top: 10px;
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: 4px;
    display: inline-block;
}


/* ===== MODAL ===== */

.gpd-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.82);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    padding: 2rem;
}

.gpd-modal.gpd-modal-open {
    display: flex;
}

.gpd-modal-content {
    background: #fff;
    position: relative;
    padding: 25px;
    max-width: 1000px;
    width: 100%;
    box-sizing: border-box;
    border-radius: 12px;
    max-height: 90vh;
    overflow-y: auto;
}

.gpd-modal-close {
    position: absolute;
    top: 12px;
    right: 18px;
    border: none;
    background: transparent;
    font-size: 32px;
    line-height: 1;
    cursor: pointer;
    opacity: 0.75;
    transition: opacity .2s;
}

.gpd-modal-close:hover {
    opacity: 1;
}

.gpd-modal-inner {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 2rem;
    align-items: start;
}


/* ===== FOTO DEL POPUP ===== */

.gpd-modal-photo img {
    width: 100%;
    border-radius: 50%;
    object-fit: cover;
}


/* ===== TEXTO DEL POPUP ===== */

.gpd-modal-title {
    margin: 0 0 1rem 0;
    font-size: 1.8rem;
    font-weight: 700;
}

.gpd-modal-text {
    font-size: 1rem;
    line-height: 1.5;
}

.gpd-modal-small {
    font-weight: 600;
    color: #444;
    margin-bottom: 0.5rem;
}


/* ===== RESPONSIVE ===== */

@media (max-width: 768px) {

    .gpd-modal-content {
        padding: 1.2rem;
        max-height: 90vh;
        overflow-y: auto;
    }

    .gpd-modal-inner {
        grid-template-columns: 1fr !important;
        gap: 1.5rem;
    }

    .gpd-modal-photo img {
        width: 70%;
        max-width: 260px;
        margin: 0 auto;
        display: block;
    }

    .gpd-modal-title {
        text-align: center;
        font-size: 1.5rem;
    }

    .gpd-modal-small {
        text-align: center;
    }
}