* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

body {
    line-height: 1.6;
    color: #333;
}

/* Barra di navigazione */
.navbar {
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    width: 50px;
    height: 50px;
    margin-right: 10px;
}

.company-name {
    font-size: 1.5em;
    font-weight: bold;
    color: #222;
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 20px;
}

.nav-links a {
    text-decoration: none;
    color: #333;
    font-size: 1.1em;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: #007bff;
}

.menu-toggle {
    display: none;
    font-size: 1.8em;
    cursor: pointer;
}

/* Slideshow (per homepage) */
.slideshow-container {
    max-width: 100%;
    position: relative;
    margin: auto;
    overflow: hidden;
}

.slide {
    display: none;
}

.slide img {
    width: 100%;
    height: auto;
    object-fit: cover;
}

.prev, .next {
    cursor: pointer;
    position: absolute;
    top: 50%;
    width: auto;
    padding: 16px;
    margin-top: -22px;
    color: white;
    font-weight: bold;
    font-size: 18px;
    transition: 0.6s ease;
    border-radius: 0 3px 3px 0;
    user-select: none;
    background-color: rgba(0,0,0,0.5);
}

.next {
    right: 0;
    border-radius: 3px 0 0 3px;
}

.prev:hover, .next:hover {
    background-color: rgba(0,0,0,0.8);
}

.fade {
    animation: fade 1.5s;
}

@keyframes fade {
    from {opacity: .4} 
    to {opacity: 1}
}

/* Carousel (per prodotti) */
.carousel-section {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
    text-align: center;
}

.carousel-section h2 {
    font-size: 2em;
    margin-bottom: 20px;
    color: #222;
}

.carousel-container {
    position: relative;
    overflow: hidden;
    border: 2px dashed blue; /* Debug: Bordo per container */
}

.carousel {
    display: flex;
    transition: transform 0.5s ease;
    background-color: rgba(0, 255, 0, 0.1); /* Debug: Sfondo per carousel */
}

.carousel-item {
    flex: 0 0 33.33%; /* Mostra 3 immagini per volta su desktop */
    padding: 10px;
    border: 1px solid red; /* Debug: Bordo per ogni item */
}

.carousel-item img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.carousel-prev, .carousel-next {
    cursor: pointer;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0,0,0,0.5);
    color: white;
    border: none;
    padding: 10px;
    font-size: 18px;
    border-radius: 5px;
    transition: background-color 0.3s;
}

.carousel-prev {
    left: 10px;
}

.carousel-next {
    right: 10px;
}

.carousel-prev:hover, .carousel-next:hover {
    background-color: rgba(0,0,0,0.8);
}

/* Sezione Acquista */
.products-section {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
    text-align: center;
}

.products-section h1 {
    font-size: 2.5em;
    margin-bottom: 30px;
    color: #222;
}

.products-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

.product-card {
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 20px;
    width: 300px;
    text-align: center;
    border: 1px solid purple; /* Debug: Bordo per product-card */
}

.product-card img {
    width: 100%;
    height: auto;
    border-radius: 10px;
    margin-bottom: 15px;
}

.product-card h2 {
    font-size: 1.5em;
    margin-bottom: 10px;
    color: #222;
}

.product-card p {
    font-size: 1em;
    margin-bottom: 15px;
    color: #555;
}

.product-card .price {
    font-size: 1.2em;
    font-weight: bold;
    color: #007bff;
    margin-bottom: 20px;
}

.buy-button {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 1em;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.buy-button:hover {
    background-color: #0056b3;
}

/* Sezione Successo */
.success-section {
    max-width: 800px;
    margin: 40px auto;
    padding: 0 20px;
    text-align: center;
}

.success-section h1 {
    font-size: 2.5em;
    margin-bottom: 20px;
    color: #222;
}

.success-section p {
    font-size: 1.1em;
    margin-bottom: 20px;
    color: #555;
}

.success-section .button {
    display: inline-block;
    background-color: #007bff;
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s;
}

.success-section .button:hover {
    background-color: #0056b3;
}

/* Descrizione (per homepage) */
.description {
    max-width: 800px;
    margin: 40px auto;
    padding: 0 20px;
    text-align: center;
}

.description h1 {
    font-size: 2.5em;
    margin-bottom: 20px;
    color: #222;
}

.description h2 {
    font-size: 1.8em;
    margin: 20px 0 10px;
    color: #222;
}

.description p, .description li {
    font-size: 1.1em;
    margin-bottom: 15px;
}

.description ol, .description ul {
    text-align: left;
    margin: 20px auto;
    max-width: 600px;
}

.description li {
    margin-bottom: 10px;
}

/* Sezione Social (per homepage) */
.social-contacts {
    background-color: #f9f9f9;
    padding: 40px 20px;
    text-align: center;
}

.social-contacts h2 {
    font-size: 2em;
    margin-bottom: 30px;
}

.social-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

.social-item {
    max-width: 250px;
    text-align: center;
}

.social-item img {
    width: 50px;
    height: 50px;
    margin-bottom: 10px;
}

.social-item p {
    font-size: 1em;
    margin-bottom: 10px;
}

.social-item a {
    display: inline-block;
    padding: 10px 20px;
    background-color: #007bff;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s;
}

.social-item a:hover {
    background-color: #0056b3;
}

/* Responsive Design */
@media (max-width: 768px) {
    .navbar {
        flex-wrap: wrap;
    }

    .menu-toggle {
        display: block;
    }

    .nav-links {
        display: none;
        width: 100%;
        flex-direction: column;
        text-align: center;
        margin-top: 10px;
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links li {
        margin: 10px 0;
    }

    .carousel-item {
        flex: 0 0 50%; /* Mostra 2 immagini per volta su tablet */
    }

    .description h1 {
        font-size: 2em;
    }

    .description h2 {
        font-size: 1.5em;
    }

    .social-item {
        max-width: 100%;
    }

    .product-card {
        width: 100%;
        max-width: 350px;
    }
}

@media (max-width: 480px) {
    .carousel-item {
        flex: 0 0 100%; /* Mostra 1 immagine per volta su mobile */
    }

    .products-container {
        flex-direction: column;
        align-items: center;
    }
}