/* Importazione font Google per migliorare la tipografia */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700;800&family=Poppins:wght@300;400;500;600;700&display=swap');

/* Reset di base e stili generali */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --colore-hover-base: #3f51b5;
    --colore-chiaro: #f4f4f6;
    --colore-scuro: #111;
    --colore-confronto: #ff9800; 
    

}

body {
    font-family: 'Poppins', 'Franklin Gothic Medium', 'Arial Narrow', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    background: #fff;
}

ul {
    list-style: none;
}

a {
    text-decoration: none;
    color: #333;
}

img {
    max-width: 100%;
}

/* Navbar */
.navbar {
    background-color: #fff;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    padding: 15px 20px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 50px;
    transition: transform 0.3s ease;
}

.logo img:hover {
    transform: scale(1.05);
}

.navbar .main-menu ul {
    display: flex;
    align-items: center;
}

.navbar ul li a {
    position: relative;
    text-decoration: none;
    color: var(--colore-scuro);
    padding-bottom: 4px; 

    padding: 10px 20px;
    display: block;
    font-weight: 600;
    transition: all 0.2s ease;
}

.navbar ul li a::after{
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0%;
    height: 3px;
    background-color: var(--colore-hover-base);
    transition: width 0.3s ease;
}

.navbar ul li a:hover::after{
    width: 100%;
}

.navbar ul li a:hover {
    color: var(--colore-hover-base);
}

.navbar ul li a i {
    margin-right: 10px;
}

/*Gestione Social Dropdown*/

.navbar ul li.social-item {
    position: relative;
}

 .social-Dropdown {
            position: absolute;
            top: 100%;
            left: 50%;
            transform: translateX(-50%);
            background: white;
            border-radius: 12px;
            box-shadow: 0 10px 30px rgba(0,0,0,0.15);
            padding: 15px;
            min-width: 200px;
            opacity: 0;
            visibility: hidden;
            transition: all 0.3s ease;
            z-index: 1000;
            margin-top: 10px;
        }

    .social-Dropdown.active {
       opacity: 1;
        visibility: visible;
        transform: translateX(-50%) translateY(0);
    }

    .social-Dropdown::before {
        content: '';
        position: absolute;
        top: -8px;
        left: 50%;
        transform: translateX(-50%);
        width: 0;
        height: 0;
        border-left: 8px solid transparent;
        border-right: 8px solid transparent;
        border-bottom: 8px solid white;
    }

    .social-Links {
        display: flex;
        flex-direction: column;
        gap: 8px;
    }

    .social-Links a {
        display: flex;
        align-items: center;
        padding: 12px 15px;
        border-radius: 8px;
        transition: all 0.3s ease;
        font-weight: 500;
        color: var(--colore-scuro);
    }

    .social-Links a:hover {
         background-color: #f8f9fa;
        transform: translateX(5px);
        }

    .social-Links a::after {
        display: none;
        }

    .social-Links a i {
       font-size: 18px;
        margin-right: 12px;
        width: 20px;
        text-align: center;
    }

    .social-Links a.facebook i {
            color: #1877f2;
    }

    .social-Links a.instagram i {
            color: #e4405f;
    }

    .social-Links a.twitter i {
            color: #0e0f0f;
    }


    .social-Links a.facebook:hover {
            color: #1877f2;
            background-color: rgba(24, 119, 242, 0.1);
    }

    .social-Links a.instagram:hover {
            color: #e4405f;
            background-color: rgba(228, 64, 95, 0.1);
    }

    .social-Links a.twitter:hover {
         color: #0e0f0f;
        background-color: rgba(29, 161, 242, 0.1);
    }

    /*Modal "Scopri di Più"*/
     .scopri-modal-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.5);
            backdrop-filter: blur(5px);
            display: flex;
            justify-content: center;
            align-items: center;
            z-index: 2000;
            opacity: 0;
            visibility: hidden;
            transition: all 0.3s ease;
        }

        .scopri-modal-overlay.active {
            opacity: 1;
            visibility: visible;
        }

        .scopri-modal {
            background: white;
            border-radius: 15px;
            padding: 40px;
            max-width: 500px;
            width: 90%;
            box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
            transform: scale(0.8) translateY(50px);
            transition: all 0.3s ease;
            position: relative;
        }

        .scopri-modal-overlay.active .scopri-modal {
            transform: scale(1) translateY(0);
        }

        .scopri-modal-close {
            position: absolute;
            top: 15px;
            right: 20px;
            background: none;
            border: none;
            font-size: 24px;
            cursor: pointer;
            color: #999;
            transition: color 0.3s ease;
            width: 30px;
            height: 30px;
            display: flex;
            align-items: center;
            justify-content: center;
            border-radius: 50%;
        }

        .scopri-modal-close:hover {
            color: var(--colore-hover-base);
            background-color: rgba(63, 81, 181, 0.1);
        }

        .scopri-modal h2 {
            font-family: 'Montserrat', sans-serif;
            font-weight: 700;
            color: var(--colore-scuro);
            margin-bottom: 20px;
            font-size: 1.8rem;
        }

        .scopri-modal p {
            color: #555;
            line-height: 1.8;
            margin-bottom: 15px;
        }

        .scopri-modal .highlight {
            color: var(--colore-hover-base);
            font-weight: 600;
        }

        .scopri-modal-footer {
            margin-top: 30px;
            padding-top: 20px;
            border-top: 1px solid #eee;
            text-align: center;
        }

        .scopri-modal-footer p {
            font-size: 0.9rem;
            color: #888;
            margin: 0;
        }

/* Hero Section */
.hero {
    background-color: #f9f9f9;
    padding: 100px 0 80px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 80vh;
    background: linear-gradient(135deg, rgba(244,244,246,1) 0%, rgba(233,233,240,1) 100%);
}

.hero-content {
    max-width: 1000px;
    margin: 0 auto;
}

.hero-heading {
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    letter-spacing: -1px;
    margin-bottom: 30px;
    color: var(--colore-scuro);
    text-shadow: 2px 2px 0px rgba(39, 159, 193, 0.2);
}

.hero-text {
    font-size: 1.2rem;
    margin-bottom: 30px;
    width: 100%;
    max-width: 700px;
    margin: 0 auto 40px;
    color: #555;
}

/* Sezione introduttiva */
.intro-section {
    padding: 80px 0;
    background-color: #fff;
}

.intro-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.intro-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.intro-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

.intro-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.intro-card-content {
    padding: 25px;
}

.intro-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--colore-scuro);
}

.intro-card p {
    color: #666;
    margin-bottom: 20px;
}

/* Hero Buttons  */
.hero-buttons {
    display: flex;
    flex-direction: row;
    justify-content: center;
    gap: 40px; 
    margin-top: 60px;
    width: 100%;
}

.image-button {
    position: relative;
    flex: 0 0 auto;
    width: 350px; 
    height: 250px; 
    background-size: cover;
    background-position: center;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
}

/* Testo dei pulsanti */
.image-button span {
    position: relative;
    z-index: 10;
    color: white;
    font-size: 2.2rem;
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8);
    transition: transform 0.3s ease;
}

/* Effetto hover migliorato */
.image-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.4); /* Overlay scuro iniziale leggermente più intenso */
    z-index: 1;
    transition: background-color 0.3s ease;
}

.image-button:hover::before {
    background-color: inherit; /* Overlay colorato al passaggio del mouse */
}

.image-button:hover span {
    transform: scale(1.1);
}

.image-button:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Transizione fluida per tutti gli effetti */
.image-button {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Footer */
.footer {
    padding: 60px 0 40px;
    background-color: var(--colore-scuro);
    color: #fff;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.footer img {
    height: 40px;
    margin-bottom: 20px;
}

.card {
    background: #222;
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 25px;
}

.card h4 {
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.card form input {
    width: 100%;
    padding: 12px 15px;
    margin-bottom: 15px;
    border-radius: 8px;
    border: none;
    font-family: 'Poppins', sans-serif;
}

.card form input:focus {
    outline: 2px solid var(--colore-hover-base);
}

.social-icons {
    display: flex;
    gap: 20px;
}

.fab {
    font-size: 24px;
    color: #fff;
    transition: transform 0.3s ease, color 0.3s ease;
}

.fab:hover {
    color: var(--colore-hover-base);
    transform: translateY(-5px);
}

/* Utility Classes */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.container-sm {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

.btn {
    display: inline-block;
    padding: 13px 25px;
    background: var(--colore-chiaro);
    color: #333;
    font-weight: 600;
    text-decoration: none;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.btn-primary {
    background: var(--colore-hover-base);
    color: #fff;
}

.btn-dark {
    background: var(--colore-scuro);
    color: #fff;
}

.btn-accent {
    background: linear-gradient(to right, var(--colore-hover-base), var(--colore-confronto));
    color: #fff;
}

.btn-block {
    display: block;
    width: 100%;
}

/* Text Classes */
.text-xxl{
    font-size: 4rem; 
    line-height: 1.1;
    font-weight: 800;
    margin: 40px 0 20px;
}

.text-xl{
    font-size: 2.4rem;
    line-height: 1.3;
    font-weight: 700;
    margin: 40px 0 20px;
}

.text-lg{
    font-size: 1.8rem;
    line-height: 1.4;
    font-weight: 600;
    margin: 30px 0 20px;
}

.text-md{
    font-size: 1.2rem;
    line-height: 1.4;
    font-weight: normal;
    margin: 20px 0 10px;
}

.text-sm{
    font-size: 0.9rem;
    line-height: 1.4;
    font-weight: normal;
    margin: 10px 0 5px;
}

.text-center{
    text-align: center;
}

/* Media queries per responsività */
@media(max-width: 768px) {
    .navbar .container {
        flex-direction: column;
    }
    
    .main-menu ul {
        margin-top: 15px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .text-xxl {
        font-size: 3rem;
    }
    
    /* Responsività per i bottoni su schermi piccoli */
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .image-button {
        width: 100%;
        max-width: 350px;
        margin-bottom: 30px;
    }
    
    .intro-cards {
        grid-template-columns: 1fr;
       }

    /*Flip Card Animation*/

    .flip-cards-container {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-grow: 1; 
    padding-top: 50px; 
    width: 100%; 
    gap: 30px;
    justify-content: center;
    flex-wrap: wrap;
}
.flip-card {
    background-color: transparent;
    width: 250px;
    height: 275px;
    perspective: 1000px;
}

.flip-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.35s;
    transform-style: preserve-3d;
}

.flip-card:hover .flip-card-inner {
    transform: rotateY(180deg);
}

.flip-card-front, .flip-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 16px;
    overflow: hidden;
}


.flip-card-back {
    transform: rotateY(180deg); 
}

.flip-card-front img, .flip-card-back img {
    width: 100%; 
    height: 100%; /
}

.glass-effect {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0));
    -webkit-backdrop-filter: blur(15px);
    backdrop-filter: blur(15px);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 16px;
    display: flex;
    justify-content: center; 
    align-items: center; 
    color: white;
    padding: 16px;
    box-sizing: border-box;
}

.flip-card-back .glass-effect p {
    font-size: 14px;
    font-family: 'Roboto', sans-serif;
    margin: 0;  
    text-align: center;  
}
}