/* General Section Styling */
.section {
    padding: 100px 50px;
    text-align: center;
    background-color: #f5f5f5;
    margin-bottom: 50px;
    opacity: 0; /* Start hidden for fade-in effect */
    transform: translateY(20px); /* Move slightly for animation */
    transition: opacity 1s ease-out, transform 1s ease-out;
}

.section.visible {
    opacity: 1;
    transform: translateY(0); /* Move to original position on scroll */
}

.section h2 {
    font-size: 2.5rem;
    color: #ff6600;
    margin-bottom: 20px;
}

.section p {
    font-size: 1.5rem;
    color: #333;
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.6;
}

.section img {
    max-width: 100%;
    height: auto;
    margin-top: 20px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Banner Section */
.banner-section {
    position: relative;
    width: 100%;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.banner-image {
    width: 100%;
    position: relative;
}

.banner-image img {
    width: 100%;
    height: auto;
    object-fit: cover;
    animation: bannerFadeIn 1.5s ease forwards;
}

/* Scritta sovrapposta all'immagine del banner */
.banner-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    text-align: center;
    font-size: 4rem;
    font-weight: bold;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.7); /* Aggiungi un'ombra al testo per renderlo più leggibile */
}

/* Animazione per far apparire il banner */
@keyframes bannerFadeIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hero Button */
.hero-btn {
    padding: 15px 30px;
    background-color: #ffcc33;
    color: white;
    border-radius: 30px;
    font-size: 1.2rem;
    text-transform: uppercase;
    text-decoration: none;
    transition: background-color 0.3s ease, color 0.3s ease;
    animation: pulse 2s infinite;
    margin-top: 20px;
}

/* Pulsazione del pulsante */
@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 rgba(255, 204, 51, 0.7);
    }
    70% {
        transform: scale(1.05);
        box-shadow: 0 0 20px rgba(255, 204, 51, 0.7);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 rgba(255, 204, 51, 0.7);
    }
}

/* Parallax Section */
.parallax-section {
    height: 400px;
    background: url('../images/parallax-image.jpg') no-repeat center center/cover;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2.5rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* Hero Section */
.hero {
    position: relative;
    height: 100vh;
    background: url('../images/hero-olio.jpg') no-repeat center center/cover;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    background-attachment: fixed; /* Parallax effect */
    animation: fadeInHero 2s ease-in-out forwards;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 153, 0, 0.6);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
}

.hero-title {
    font-size: 4rem;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.hero-subtitle {
    font-size: 1.5rem;
    margin-bottom: 30px;
}

.hero-btn {
    padding: 15px 30px;
    background-color: #ffcc33;
    color: white;
    border-radius: 30px;
    font-size: 1.2rem;
    text-transform: uppercase;
    text-decoration: none;
    transition: background-color 0.3s ease, color 0.3s ease;
    animation: pulse 2s infinite;
}

.hero-btn:hover {
    background-color: #ffdd66;
}

@keyframes fadeInHero {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 rgba(255, 204, 51, 0.7);
    }
    70% {
        transform: scale(1.05);
        box-shadow: 0 0 20px rgba(255, 204, 51, 0.7);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 rgba(255, 204, 51, 0.7);
    }
}

/* Cube Container */
.cube-container {
    position: relative;
    width: 300px;
    height: 300px;
    margin: 100px auto;
    perspective: 1500px;
}

/* The Cube */
.cube {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    transition: transform 1s ease-in-out;
    animation: rotateCube 5s infinite ease-in-out;
}

/* Cube Faces */
.cube-face {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.5rem;
    color: white;
    backface-visibility: hidden;
    border-radius: 15px;
}

.cube-face-front {
    background-color: #ff6600;
    transform: rotateY(0deg) translateZ(150px);
}
.cube-face-back {
    background-color: #ff9933;
    transform: rotateY(180deg) translateZ(150px);
}
.cube-face-left {
    background-color: #228b22;
    transform: rotateY(-90deg) translateZ(150px);
}
.cube-face-right {
    background-color: #ffcc00;
    transform: rotateY(90deg) translateZ(150px);
}
.cube-face-top {
    background-color: #1e90ff;
    transform: rotateX(90deg) translateZ(150px);
}
.cube-face-bottom {
    background-color: #ff6347;
    transform: rotateX(-90deg) translateZ(150px);
}

/* Cube Shadow */
.cube {
    box-shadow: 0px 15px 40px rgba(0, 0, 0, 0.3);
}

/* Smooth Rotation on Hover */
.cube:hover {
    transform: rotateX(20deg) rotateY(30deg);
}

/* Cube Animation */
@keyframes rotateCube {
    0% {
        transform: rotateY(0deg);
    }
    50% {
        transform: rotateY(180deg);
    }
    100% {
        transform: rotateY(360deg);
    }
}

/* Testimonial Section */
.testimonials-slider {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 30px;
    transition: transform 1s ease;
}

.testimonial {
    background-color: #fff5e6;
    padding: 20px;
    border-radius: 15px;
    width: 300px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    transform: scale(1);
    transition: transform 0.3s ease;
}

.testimonial:hover {
    transform: scale(1.05);
}

.testimonial p {
    font-size: 1.5rem;
    color: #333;
}

.testimonial h4 {
    font-size: 1.2rem;
    color: #ff6600;
    margin-top: 10px;
}

/* Sezione CTA */
.cta-section {
    padding: 80px 20px;
    background-color: #fff5e6;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
}

.cta-content {
    max-width: 800px;
    margin: 0 auto;
}

.cta-content h2 {
    font-size: 2.5rem;
    color: #ff6600;
    margin-bottom: 20px;
    font-weight: bold;
}

.cta-content p {
    font-size: 1.5rem;
    color: #ff9933;
    margin-bottom: 30px;
    line-height: 1.6;
}

.cta-btn {
    display: inline-block;
    padding: 15px 30px;
    background-color: #ffcc33;
    color: white;
    font-size: 1.2rem;
    text-decoration: none;
    border-radius: 30px;
    transition: background-color 0.3s ease;
}

.cta-btn:hover {
    background-color: #ffdd66;
}

