﻿/* ==========================================================================
   1. STILI GENERALI E RESET
   ========================================================================== */
html { scroll-behavior: smooth; }

.contenuti .path { display: none; }
.contenuti ul, .contenuti ul li { list-style: none; padding: 0; margin: 0; }
cartelli_1.contenuti { margin-bottom: 1rem; }

/* ==========================================================================
   2. HEADER
   ========================================================================== */
header .BG { display: none; }

/* ==========================================================================
   3. SEZIONI PRINCIPALI (Presentazione, Profile, Why)
   ========================================================================== */

/* Presentazione Generale */
#presentazione-generale .img-boxwall-all-wrapper { padding: 1rem; margin: 0rem auto; list-style: none; }
#presentazione-generale .img-boxwall-all-wrapper ul { display: -webkit-box; display: -ms-flexbox; display: flex; -ms-flex-wrap: wrap; flex-wrap: wrap; -webkit-box-pack: center; -ms-flex-pack: center; justify-content: center; list-style: none; }
#presentazione-generale .img-boxwall-all-wrapper ul li { padding: 0.5rem; }
#presentazione-generale .img-boxwall-all-wrapper .img-wrapper { max-width: 440px; border-radius: 0px; overflow: hidden; }

/* Profilo Aziendale */
#company-profile .img-wrapper { width: 100%; max-width: 35rem; margin: 0 auto; }
#company-profile p { margin-bottom: 1rem; }

/* Sezione "Why" (Perché sceglierci) */
#why { margin-top: 2rem; }
#why ul { display: -webkit-box; display: -ms-flexbox; display: flex; -ms-flex-wrap: wrap; flex-wrap: wrap; -webkit-box-pack: center; -ms-flex-pack: center; justify-content: center; }
#why ul li { margin: 0 auto 2rem; }
#why .img-wrapper { width: 100%; max-width: 300px; border-radius: 0px; overflow: hidden; margin: 0 auto; }
#why .text-wrapper { text-align: center; padding-top: 0; padding-bottom: 0; line-height: 125%; }

/* ==========================================================================
   4. SISTEMA DELLE CARDS (Categorie e Prodotti)
   ========================================================================== */

/* Struttura base della Card */
.cards-wrapper { padding: 1rem; margin: 0 auto; }
.card { border-radius: 0 !important; width: 100%; max-width: 350px; overflow: hidden; margin: 0 auto; display: flex; flex-direction: column; justify-content: space-between; align-items: center; }
.card-body { display: flex; flex-direction: column; justify-content: space-between; align-items: center; margin-top: 1rem; }
.card .pittogrammi-wrapper { display: flex; flex-wrap: wrap; padding: 0 1rem; margin-top: 1rem; justify-content: center; align-items: center; }
.card .pittogrammi-wrapper .icon-wrapper { padding: 0.25rem; width: unset; max-width: unset; height: unset; max-height: unset; }
.card .pittogrammi-wrapper .icon-wrapper img { max-width: unset; height: unset; max-height: unset; width: 1.5rem; height: auto; }

/* Varianti Sezioni Cards */
#categorie-all-section .card-body .img-wrapper, 
#altri-prodotti-segnaletica .card-body .img-wrapper { border-radius: 0; max-width: 500px; padding: 0; margin: 0; }
#categorie-all-section .card .text-wrapper { padding: 0 1rem; }
#categorie-all-section .card h4, 
#altri-prodotti-segnaletica .card h4 { margin: 0.5rem auto; }
#categorie-all-section .card .button:hover { background-color: #333; }

/* Cards Generali (Griglia) */
.general-cards-wrapper { display: flex; flex-wrap: wrap; margin: 1rem auto; justify-content: center; }
.general-cards-wrapper .card { max-width: 125px; padding: 0.25rem; margin: 0.5rem; -webkit-box-sizing: border-box; box-sizing: border-box; overflow: hidden; box-shadow: 0 0 1px #666; }
.general-cards-wrapper .card:hover { box-shadow: 0 0 2px #333333; }
#categorie-all-section .general-cards-wrapper .card .img-wrapper { max-width: 100px; }

/* Cards Small e Big */
#categorie-all-section .small-cards-wrapper .card .button { margin: 1rem; }
.big-cards-wrapper .card { max-width: 200px; padding-bottom: 0.5rem; }
#categorie-all-section .big-cards-wrapper .card .img-wrapper, 
#altri-prodotti-segnaletica .big-cards-wrapper .card .img-wrapper { max-width: 200px; }
#categorie-all-section .big-cards-wrapper, 
#altri-prodotti-segnaletica .big-cards-wrapper { margin-top: 0.5rem; }
#categorie-all-section .big-cards-wrapper .card .button { margin-top: 0; }

/* Stili specifici per Pulsanti-Card */
.card-container { display: flex; flex-direction: column; gap: 10px; }
.card-link { text-decoration: none; display: block; }
.card { background-color: #666; color: #ffffff; padding: 12px 20px; text-align: center; }
.card:hover { background-color: #444; cursor: pointer; }
.card-text { margin: 0; font-size: 1rem; color: #ffffff !important; }
.card-content p { margin-bottom: 0 !important; }

/* ==========================================================================
   5. COMPONENTI UI (Bottoni, Video, Slider, Contenitori)
   ========================================================================== */

/* Bottoni */
.button { background-color: #666; border-radius: 0rem; padding: 1rem; margin-top: 1rem; display: inline-block; }

/* Video */
.video-wrapper { width: 100%; max-width: 800px; margin: 1rem auto 0; }
.video-wrapper iframe { width: 100%; height: 250px; box-sizing: border-box; }

/* Slider */
.slider-container { width: 100%; max-width: 800px; margin: auto; overflow: hidden; }
.slider { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; }
.slider img { width: 100%; flex-shrink: 0; scroll-snap-align: start; object-fit: cover; }

/* Wrapper Testuali e Sfondi */
.text-wrapper { padding: 1rem; margin: 0 auto; max-width: 50rem; text-align: justify; }
.bg-dark-wrapper { margin: 2rem auto; background-color: #666; color: #fff; padding: 2rem; }
.bg-dark-wrapper div { margin: 0 auto 2rem; }
.bg-dark-wrapper div:last-of-type { margin-bottom: 0; }
.bg-dark-wrapper h3 { color: #fff; margin: 0 auto 0.5rem; }
.bg-dark-wrapper p { color: #fff; }

.bg-grey-wrapper { margin: 1rem auto; background-color: #f5f5f5; color: #666; padding: 1rem; }
.bg-grey-wrapper div { margin: 0 auto 1rem; }
.bg-grey-wrapper div:last-of-type { margin-bottom: 0; }
.bg-grey-wrapper h3 { color: #666; margin: 0 auto 0.5rem; }
.bg-grey-wrapper p { color: #666; }

/* Specifici */
#cat-identificazione { background-color: #f1f2f3; }
#materiale-wrapper .materiale-classe { margin-top: 1.5rem; }

/* ==========================================================================
   MODERNA GALLERIA E MODAL (Lightbox)
   ========================================================================== */

/* Layout Griglia */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 10px;
    margin-top: 1rem;
}

.gallery-grid img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    cursor: pointer;
    transition: opacity 0.3s ease;
    border-radius: 0 !important; /* No bordi arrotondati */
}

.gallery-grid img:hover {
    opacity: 0.8;
}

/* Overlay Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.9);
    cursor: zoom-out;
}

/* Immagine al centro */
.modal-content {
    margin: auto;
    display: block;
    width: 90%;
    max-width: 800px; /* Larghezza richiesta */
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 0 !important;
}

/* Pulsante chiusura */
.close-modal {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
}

/* Mobile: adatta la griglia */
@media only screen and (max-width: 480px) {
    .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}



/* ==========================================================================
   6. RESPONSIVE (Media Queries)
   ========================================================================== */

/* Da 450px in su */
@media only screen and (min-width: 450px) {
    .video-wrapper iframe { height: 300px; padding: 0 1rem; }
    .card { margin: 1rem; }
    #why .img-wrapper img[src$=".svg"] { max-width: 120px; margin: 0 auto; }
}

/* Da 600px in su */
@media only screen and (min-width: 600px) {
    #clienti-loghi ul { display: flex; flex-wrap: wrap; max-width: 35rem; }
    #clienti-loghi ul li { margin-top: 0; padding: 1rem; }
    #clienti-loghi .img-wrapper { height: 50px; width: auto; }
    #clienti-loghi .img-wrapper img { height: 100%; width: auto; }
    .video-wrapper iframe { height: 350px; }
    #settore-wrapper .cards-wrapper { display: flex; flex-wrap: wrap; justify-content: center; align-items: stretch; margin: auto; margin-bottom: 1rem; }
    .card { margin: 1rem; align-self: stretch; max-width: 35rem; }
}

/* Da 768px in su (Tablet) */
@media only screen and (min-width: 768px) {
    .video-wrapper iframe { height: 440px; }
}

/* Da 900px in su (Desktop) */
@media only screen and (min-width: 900px) {
    header .img-wrapper { content: url(/img/Approfondimenti/Prodotti/Segnaletica/Segnaletica_intro.png); padding: 0; width: 100%; }
    header img { content: url(/img/Approfondimenti/Prodotti/Segnaletica/Segnaletica_intro.png); }
    #presentazione-generale .img-protos-all-wrapper ul { flex-wrap: nowrap; }
    #presentazione-generale .img-protos-all-wrapper .img-wrapper { max-width: 350px; }
    #why ul { padding: 2rem; }
    #why .img-wrapper img[src$=".svg"] { max-width: 120px; margin: 0 auto; }
    #why ul li { display: flex; justify-content: flex-start; align-content: center; }
    #why .img-wrapper { max-width: 150px; margin: 0; }
    #why .text-wrapper { align-self: center; text-align: justify; margin: 0 0 0 1rem; }
    #why .text-wrapper h3 { margin-top: 0; }
    #why .text-wrapper a { text-decoration: underline; }
    #affiliazioni > div { max-width: 40rem; margin-left: auto; margin-right: auto; }
}

/* Da 1200px in su (Desktop Wide) */
@media only screen and (min-width: 1200px) {
    /* Esempio commentato nel codice originale:
    header .BG { display: block; ... } */
}