* { margin: 0; padding: 0 }

body {
    font-family: Arial, sans-serif;
    background-color: #fff;
    color: #333;
    text-align: center;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

body.no-scroll {
    overflow: hidden;
}


main {
    flex: 1; /* Spinge il footer in basso */
    padding: 20px;
}

.loghi{
    display: flex;
    justify-content: center;
}


.loghi-col img{
    max-width: 150px;
}

/* --- nuovo stile pulsante installa app --- */
#wrapInstallaAppLink {
    padding-top:30px
}

#installAppLink {
    display: none;
    background-color: #2bace3;
    color: white;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    padding: 10px 20px;
    border: none;
    border-radius: 25px;
    text-decoration: none;
    cursor: pointer;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2);
    transition: background-color 0.3s ease, transform 0.2s ease;
}

#installAppLink:hover {
    background-color: #229bcf;
    transform: scale(0.98);
    box-shadow: 0 0 0 0;
}

.closePopUp span {
    position: relative;
    top: 10px;
    color: #fff;
    font-size: 22px;
    font-weight: bold;
    text-shadow: 2px 1px 2px rgba(0,0,0,0.39);
    transition: text-shadow 0.3s ease; /* transizione morbida di 0.3 secondi */
}

.closePopUp span:hover {
    text-shadow: none;
}

#loghi-verticali {
    display: none
}

footer {
    height: 70px;
    background-color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 40px;
}

footer a {
    color: #fff;
    text-decoration: none;
    font-size: 16px;
    transition: color 0.3s ease;
}

footer a:hover {
    color: #ccc;
}



.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; width: 100%; margin: 0 auto; }
.cell { background-color: #fff; padding: 10px; text-align: center; font-weight: bold; }
.cell img { max-width: 150px; }

/* ---- immagini principali ---- */
/*   #wrap-img-row { display: flex; height: 70vh; align-items: center; justify-content: center; width: 100%; }*/

#wrap-img-row {
    height: 55vh;
    position: relative;
    top: 50px;
}


.img-row { display: flex; justify-content: center; align-items: center; gap: 30px; text-align: center; }
.img-container { position: relative;  width: 37%; border-radius: 20px; box-shadow: 0 6px 12px rgba(0, 0, 0, 0.6); cursor: pointer; transition: box-shadow 0.2s ease, transform 0.2s ease; }
.img-container:hover { box-shadow: none; transform: scale(0.98); }
.img-container img { width: 100%; height: auto; border-radius: 20px; }
.caption { position: absolute; bottom: 0; left: 0; width: 100%; background-color: rgba(0, 0, 0, 0.5); color: white; padding: 10px 0; font-size: 1.1em; border-bottom-left-radius: 20px; border-bottom-right-radius: 20px; }

.loghi {
    margin-top:90px;
    gap:20px
}

.loghi-col img {
    max-width: 120px;
}



/* ---- popup installazione ---- */
.popup-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .65);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000000;
    opacity: 0;
    pointer-events: none;
    transition: opacity .3s ease;
}

.popup-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.popup-box {
    width: 80%;
 /*   height: 85%;*/
    height: auto;
    max-width: 95vw; /* un minimo di “respiro” sugli schermi piccoli */
    /*max-height: 82vh;*/
    background: #fff;
    border-radius: 12px;
    padding: 20px 30px 0 30px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, .35);
    position: relative;
    overflow-y: auto;
    scroll-behavior: smooth;

}




#android p, #ios p{
    text-align: justify;
}

#android h2, #ios h2{
    margin:15px 0;
}

.choose-app {
    margin: 6px 0 0 0;
    display: flex;
    justify-content: center;
}

.close-btn {
    position: absolute;
    top: 12px;
    right: 18px;
    font-size: 2rem;
    background: none;
    border: none;
    cursor: pointer;
    line-height: 1;
    color: #666;
}

.close-btn:hover { color: #000; }

.closePopUp {
    position: relative;
    margin-bottom:55px
}

/* Sovrapposizione immagini */
.closePopUp img {
    width:170px;
    position: absolute;
    top: 0;
    left: calc(50% - 82px); /* metà pagina - metà larghezza pulsante */
    display: block;
}


/* Hover: cambia immagine */
.closePopUp > div span {
    cursor: pointer;
}



/* START TAB **********************************************************************************************************/

#android, #ios {
    padding: 0 2% 2% 2%;
}

.tabs {
    display: flex;
    gap: 8px;
    margin: 10px 0;
    justify-content: center;
}

.tab-flag {
    width: 32px;
    height: 32px;
    border-radius: 4px;
    cursor: pointer;
    transition: transform 0.2s, border-color 0.2s;
}

.tab-flag:hover {
    transform: scale(1.1);
}

.tab-flag.active {
    border-color: #007bff; /* bordo blu quando attivo */
}

.tab-content {
    display: none;
    margin-top: 10px;
    padding: 10px 0 2% 0;
}

.tab-content.active {
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
}

.tab-content p {
    display: contents;
}

/* Correzione per elenchi numerati */
.tab-content ol {
    text-align: left;
    margin-left: 0px;      /* distanza naturale dal bordo sinistro */
    padding-left: 0px;     /* spazio per i numeri */
    list-style-position: inside; /* il numero resta vicino al testo */
}

.tab-content li {
    margin-bottom: 8px;     /* spazio verticale tra i punti elenco */
    line-height: 1.5;       /* leggibilità migliore */
}


/* END TAB ************************************************************************************************************/



/* ******************************* RESPONSIVE *************************************************************************/

/* VERSIONE NOTEBOOK 15 POLLICI (DI SOLITO 1336 X 768 oppure 1536 x 738)*/
@media screen and (min-width: 1300px) and (max-width: 1536px) {

    .img-container {
        width: 34%;
    }

    #wrap-img-row {
        height: 55vh;
        position: relative;
        top: 45px;
    }

    .loghi {
        margin-top: 30px;
        position: relative;
        top: 20px;
    }

    .loghi-col img {
        max-width: 100px;
    }

}

@media screen and (max-width: 1299px)  {


}

@media screen and (max-width: 1024px) {

    #wrap-img-row {
        height: auto;
        position: relative;
        top: 50px;
    }

    .loghi {
        margin-top: 115px;
        gap: 20px;
    }

    .img-row { flex-direction: column; align-items: center; }
    .img-container { width: 80%; }
}

@media screen and (max-width: 850px) {
    .loghi {
        margin-top: 130px;
        gap: 0;
    }
}

@media screen and (max-width: 750px) {
    .loghi {
        display: none;
    }

    #loghi-verticali {
        display: block;
        margin-top: 100px;
        margin-bottom: 0;
    }

    .cell img {max-width: 120px;}
}

@media (max-width: 600px) {
    #wrapInstallaAppLink {
        top: 10px;
        right: 10px;
    }

    #installAppLink {
        font-size: 0.9rem;
        padding: 8px 16px;
    }
}

@media (max-width: 450px) {
    footer {
        gap:18px;
    }
}

@media (max-height: 450px) {
   .popup-box {
       padding-top: 50px;
   }
}