/* Container della galleria per layout responsive */
.pdf-gallery-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    /* Centra gli elementi */
    gap: 20px;
    /* Spazio tra gli elementi */
    padding: 10px;
}

/* Stile per ogni singolo elemento PDF nella galleria */
.pdf-gallery-item {
    width: 150px;
    text-align: center;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 10px;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
    font-family: Arial, sans-serif;
    transition: transform 0.3s ease;
    /* Aggiunge un effetto hover */
}

.pdf-gallery-item:hover {
    transform: scale(1.05);
    /* Effetto ingrandimento al passaggio del mouse */
}

.pdf-icon img {
    width: 100%;
    height: auto;
    max-width: 80px;
    margin: 0 auto;
    display: block;
    border-radius: 4px;
}

.pdf-view-link {
    color: #007bff;
    font-size: 14px;
    text-decoration: none;
    margin-top: 5px;
    display: block;
}

.pdf-view-link:hover {
    text-decoration: underline;
}

.pdf-title {
    margin-top: 5px;
    font-size: 14px;
    font-weight: bold;
}

/* Media query per rendere il layout più flessibile su dispositivi piccoli */
@media (max-width: 600px) {
    .pdf-gallery-item {
        width: 100px;
    }
}

@media (min-width: 600px) and (max-width: 900px) {
    .pdf-gallery-item {
        width: 120px;
    }
}

.pdf-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    padding-top: 60px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.7);
}

.pdf-modal-content {
    background-color: #fff;
    margin: auto;
    padding: 20px;
    width: 90%;
    max-width: 800px;
    border-radius: 8px;
    position: relative;
}

.pdf-modal-close {
    color: #aaa;
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.pdf-modal-close:hover {
    color: #000;
}

.pdf-modal-navigation {
    text-align: center;
    margin-top: 15px;
}

.pdf-modal-navigation button {
    background-color: #007bff;
    color: #fff;
    border: none;
    padding: 6px 12px;
    margin: 0 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.pdf-modal-navigation button:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

.pdf-modal-controls {
    text-align: center;
    margin-bottom: 10px;
}

.pdf-modal-controls button,
.pdf-modal-controls a {
    background-color: rgb(125, 179, 218);
    color: #fff;
    border: none;
    padding: 6px 10px;
    margin: 0 5px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    text-decoration: none;
}

.pdf-modal-controls button:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

.pdf-modal-controls button i,
.pdf-modal-controls a i,
.pdf-modal-close i {
    font-size: 18px;
    color: #333;
}

.pdf-modal-close {
    cursor: pointer;
    font-size: 24px;
    position: absolute;
    top: 10px;
    right: 15px;
}