@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Poppins", sans-serif;
}

body {
    min-height: 100vh;
    background: #f5f5f5;
}

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 65px;
    padding: 1.3rem 5%;
    display: flex;
    align-items: center;
    background: #333;
    box-shadow: 0 5px 10px rgba(0, 0, 0, .3);
    z-index: 3;
}

.logo {
    text-decoration: none;
    color: #e0e0e0;
    font-weight: 700;
    font-size: large;
}

.check {
    display: none;
}

#close-check {
    display: none;
}

.icons {
    font-size: 2.2rem;
    display: flex;
    position: absolute;
    right: 5%;
    color: #e0e0e0;
    cursor: pointer;
}

.navbar a {
    text-decoration: none;
    color: #e0e0e0;
    display: flex;
    justify-content: center;
    padding: 0.6rem;
    font-weight: 500;
}

.navbar a:hover {
    background: rgba(0, 0, 0, .2);
}

.navbar {
    width: 100%;
    top: 0;
    left: 0;
    display: block;
    position: absolute;
    top: 100%;
    background: #4d4d4d; /* colore pieno */
    opacity: 1;
    padding: 0;
    height: 0;
    overflow: hidden;
    transition: .3s ease;
    box-shadow: 0 5px 10px rgba(0, 0, 0, .3);
    z-index: 2;
}

#check:checked~.navbar {
    height: 10.8rem;
}

#check:checked~.header {
    box-shadow: 0 0px 0px rgba(0, 0, 0, 0);
}

#check:checked+label #menu-check {
    display: none;
}

#check:checked+label #close-check {
    display: block;
}

.hero {
    margin-top: 65px;
    padding: 2%;
    background: url('img/serramenti.jpg') center/cover no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    transition: .3s ease;
    box-shadow: 0 5px 10px rgba(0, 0, 0, .3);
}

.hero::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #666666;
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 1; /* sopra l'overlay */
}

.hero-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
}

.hero-form input,
.hero-form textarea {
    padding: 12px;
    border: none;
    border-radius: 5px;
    font-size: 1rem;
}

.hero-form button {
    background: #1e90ff;
    color: #fff;
    border: none;
    padding: 12px;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
}

.hero-form button:hover {
    background: #187bcd;
}

/* Pulsante popup */
.btn-popup {
    padding: 0.8rem 1.5rem;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    position: relative;
    z-index: 1; /* sopra header se necessario */
}

/* Overlay del popup */
.popup {
    display: none; /* nascosto di default */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 1000;
}

/* Mostra popup */
.popup.show {
    display: flex;
    opacity: 1;
    pointer-events: auto;
}

/* Contenitore del form */
.popup-content {
    background: #fff;
    padding: 2rem;
    border-radius: 10px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 5px 20px rgba(0,0,0,0.3);
    position: relative;
    z-index: 1001; /* sopra overlay */
}

/* Pulsante chiudi */
.popup-content .close {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 1.5rem;
    cursor: pointer;
    color: #333;
    background: transparent;
    border: none;
}

/* Stili form interni (opzionale) */
.popup-content input,
.popup-content textarea,
.popup-content button {
    width: 100%;
    margin-bottom: 1rem;
    padding: 0.8rem;
    border-radius: 5px;
    border: 1px solid #ccc;
    font-size: 1rem;
}
/* .hero{
    display: block;
} */

.titolo {
    color: white;
    font-weight: 600;
    font-size: 2rem;
    margin-bottom: 20px;
}

.hero-content {
    z-index: 1; /* sopra overlay */
    text-align: center;
    color: white;
}

.sezione{
    margin-top: 2rem;
    padding: 0rem 2rem;
    scroll-margin-top: 70px;
}

.presentazione{
    text-align: center;
    font-weight: 700;
    color: #222;
    margin-top: -0.7rem;
}

.descrizione{
    font-weight: 500;
    text-align: center;
    list-style-position: inside;
}

li{
    margin-top: 0.5rem;
}

img{
    width: 100%;
    height: auto;
}

.swiper {
  width: 100%;
  height: 400px; /* regola l’altezza come preferisci */
}

.swiper-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* mantiene proporzioni */
  border-radius: 12px; /* angoli arrotondati */
  object-fit: contain;
}

.footer{
    width: 100%;
    background: #333;
    padding: 1rem;
}

footer p {
    color: #e0e0e0;
    margin-bottom: -1rem;
    font-size: small;
}

.contatti{
    font-size: x-large;
    font-weight: 700;
    color: #e0e0e0;
    text-align: center;
}

footer div div p{
    font-weight: 500;
    text-align: center;
    margin-bottom: 0rem;
}

.contenitore{
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: space-around;

}
a img{
    width: 3rem;
}

.contenitore2{
    width: 100%;
    margin-bottom: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    
    

}

.contenitore3{
    text-align: center;
    padding: 1rem;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

#servizi{
    padding-bottom: 2rem;
}


@media (min-width: 800px) {
    .icons {
        display: none;
    }

    .navbar {
        width: auto;
        display: inline;
        position: static;
        height: 100%;
        background: rgba(0, 0, 0, 0);
        box-shadow: 0 0px 0px rgba(0, 0, 0, 0);
    }

    .navbar a {
        display: inline;
    }

    .header {
        display: flex;
        justify-content: space-between;

    }

    .navbar a:hover {
        background: rgba(0, 0, 0, 0);
        text-decoration: underline;
        color: #ddd;
        filter: brightness(1.2);
    }

    .header a:hover {
        background: rgba(0, 0, 0, 0);
        color: #ddd;
        filter: brightness(1.2);
    }

    div a{
    padding-left: 1rem;
    }

    .contenitore{
        padding: 0% 25% 0% 23%;
    }

    .contenitore2{
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
    }

    .contenitore3{
        width: 48%;
        justify-content: flex-start; /* assicura che elementi partano dall'alto */
        align-items: center;
    }

    /* rende lo swiper più prevedibile in altezza */
    .swiper {
        height: 400px;      /* mantenere altezza fissa uguale per entrambi */
        max-height: 100%;
    }

    /* assicurati che lo slider occupi tutta la larghezza disponibile */
    .contenitore3 .swiper {
        width: 100%;
    }
    
}

@media (min-width: 950px) {
    .header {
        padding: 1.3rem 10%;
    }
}