* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}



*, *::before, *::after {
    box-sizing: border-box;
}


p
{
    margin-left: 0px;
}

.hero-content {
    max-width: 100%;
    width: 100%;
    padding: 0 20px;
    justify-content: center;
}

.title, .subtitle, .cta-button {
    max-width: 100%;
    word-wrap: break-word;
    padding-bottom: 20px;
    margin-left: 0px;
}

@media (max-width: 768px) {
    .hero-content {
        padding: 0 10px;
    }
}



.contact-section {
    padding: 40px 20px;
    box-sizing: border-box;
    max-width: 100%;
    overflow-x: hidden;
}

.contact-methods {
    max-width: 100%;
    word-wrap: break-word;
}

.contact-methods p {
    margin: 10px 0;
}

.contact-methods a {
    word-break: break-all; /* Assicura che il testo si adatti alla larghezza */
}


.footer {
    background: #222;
    color: #bbb;
    text-align: center;
    padding: 20px;
    margin-top: 0;
    border-top: 1px solid #444;
    transition: all 0.5s ease;
    box-sizing: border-box;
    max-width: 100%;
    overflow-x: hidden;
}

.footer p {
    margin: 0;
    padding: 0 20px;
    word-wrap: break-word;
}








.about-section, .lessons-section, .booking-section, .contact-section {
    padding: 40px 10px; /* Riduci il padding orizzontale */
    text-align: center;
    transition: opacity 0.5s ease;
    opacity: 0;
    transform: translateY(50px);
}

@media (min-width: 769px) {
    .about-section, .lessons-section, .booking-section, .contact-section {
        padding: 50px 20px; /* Ripristina il padding per schermi più grandi */
    }
}


html {
    overflow-x: hidden;
    scroll-behavior: smooth;
}



/* Stili generali */
body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    color: #223;
    scroll-behavior: smooth;
    transition: all 0.5s ease-in-out;
    overflow-x: hidden;
}

h1, h2, h3 {
    font-weight: 700;
}

p {
    font-weight: 400;
}


.cta-button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #ff4500;
    color: #fff;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s ease;
    margin-bottom: 10px;
    margin-top: 20px;
}

.cta-button:hover {
    background-color: #e03e00;
}

/* Stili per l'header */
.hero {
    position: relative;
    height: 100vh;
    background: url('bg-hero.avif') no-repeat center center/cover;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: #fff;
}

.hero .overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
}

.hero-content {
    position: relative;
    z-index: 1;
}

/* Stili per la navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0; /* Assicurati che la navbar inizi dal lato sinistro */
    width: 100%; /* Imposta la larghezza al 100% per i dispositivi mobili */
    background: #223;
    color: #fff;
    padding: 30px;
    box-sizing: border-box; /* Assicurati che il padding sia incluso nella larghezza */
    z-index: 10;
    transition: background 0.5s ease;
}


.navbar ul {
    list-style: none;
    display: flex;
    justify-content: center;
    padding: 0;
    margin: 0;
}

.navbar ul li {
    margin: 0 20px;
}

.navbar ul li a {
    color: #fff;
    text-decoration: none;
    transition: color 0.3s ease;
}

.navbar ul li a:hover {
    color: #ff4500;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    position: absolute;
    left: 20px;
    top: 15px;
    z-index: 20;
}


.hamburger div {
    width: 25px;
    height: 3px;
    background-color: #fff;
    margin: 4px 0;
    transition: all 0.3s ease;
}


@media (max-width: 768px) {
    .navbar ul {
        display: none;
        flex-direction: column;
        background: #223;
        position: fixed;
        top: 60px;
        right: 0;
        width: 200px;
        padding: 30px !important;
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    }

    .navbar ul.active {
        display: flex;
        left:0;
    }

    .hamburger {
        display: flex;
    }

     li{
         padding-top:5px;
         font-size:1.5em;
     }

}


/* Stili per le sezioni */
.about-section, .lessons-section, .booking-section, .contact-section {
    padding: 50px 20px;
    text-align: center;
    transition: opacity 0.5s ease;
    opacity: 0;
    transform: translateY(50px);
}

.about-section {
    background: #f9f9f9;
}

.about-content {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    max-width: 1200px;
    margin: auto;
}

@media (max-width: 768px) {
    .about-content {
        flex-direction: column;
        padding: 0 20px;
    }

    .profile-img {
        margin-bottom: 20px;
        padding: 0 10px;
        margin-right: 0 !important; /* Aggiungi questa linea */
    }
}


.profile-img {
    width: 100%; /* Assicurati che l'immagine sia responsive */
    max-width: 500px; /* Imposta una larghezza massima ragionevole */
    margin-right: 100px;
    justify-content: center;
}

@media (max-width: 768px) {
    .profile-img {
        margin-bottom: 20px;
        padding: 0 10px;
        margin-right: 0 !important;
        max-width: 90%; /* Assicurati che l'immagine non superi il 90% del viewport */
    }
}


.text-content {
    flex: 1;
}

.lessons-section {
    margin-top: 30px;
}

.lessons-section .lessons-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.lesson-card {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    position: relative;
    overflow: hidden;
}

.lesson-card img {
    width: 75%;
    object-fit: cover;
    border-radius: 8px 8px 0 0;
}

.lesson-card:hover {
    transform: translateY(-5px);
}

.lesson-card-content {
    padding-top: 15px;
}

/* Stili per la sezione di prenotazione */
.booking-section {
    background: #f9f9f9;
}

/* Stili per la sezione contatti */
.contact-section {
    background: #223;
    color: #fff;
}

.contact-methods a {
    color: #ff4500;
    text-decoration: none;
}

/* Stili per il footer */
.footer {
    background: #111;
    color: #bbb;
    text-align: center;
    padding: 20px;
    margin-top: 0;
    border-top: 1px solid #223;
    transition: all 0.5s ease;
}

/* Aggiungi animazioni per l'entrata delle sezioni */
@keyframes slideIn {
    0% {
        opacity: 0;
        transform: translateY(50px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Utilizzo di Intersection Observer per far apparire le sezioni al momento giusto */
.visible {
    opacity: 1;
    transform: translateY(0);
    animation: slideIn 1s ease forwards;
}





/* Stile per il menu mobile */
.nav-list {
    display: none; /* Nascondi di default */
    flex-direction: column;
    position: fixed; /* Posizione fissa per sovrapporsi */
    top: 0;
    right: 0;
    width: 250px; /* Larghezza del menu */
    background-color: #fff;
    z-index: 1001; /* Sopra altri contenuti */
    padding: 20px;
    box-shadow: -2px 0 5px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    transform: translateX(100%); /* Nascondi fuori dallo schermo */
}

.nav-list.active {
    display: flex; /* Mostra il menu */
    transform: translateX(0); /* Porta il menu nella visuale */
}

/* Stile per l'hamburger */
.hamburger {
    display: block; /* Mostra di default (mobile) */
    cursor: pointer;
    z-index: 1002; /* Sopra il menu */
}

.hamburger div {
    width: 25px;
    height: 3px;
    background-color: #fff;
    margin: 5px 0;
    transition: all 0.3s ease;
}

/* Media Query per Desktop */
@media (min-width: 768px) {
    .nav-list {
        position: static; /* Rimuove la posizione fissa */
        flex-direction: row;
        width: auto;
        height: auto;
        background-color: transparent;
        box-shadow: none;
        transform: translateX(0);
        display: flex !important; /* Mostra il menu */
    }

    .nav-list.active {
        transform: translateX(0);
    }

    .hamburger {
        display: none; /* Nascondi l'hamburger su desktop */
    }

    .nav-list li {
        margin-left: 20px; /* Spaziatura tra i menu items */
    }

    .nav-list li a {
        color: #333;
        text-decoration: none;
        font-weight: bold;
    }
}






















/* Flash Messages Styles */
.flash-messages {
    position: fixed;
    top: 80px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    width: 90%;
    max-width: 600px;
}

.alert {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    margin-bottom: 10px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    font-family: 'Roboto', sans-serif;
    font-size: 16px;
    line-height: 1.4;
    animation: slideDown 0.3s ease-out;
}

.alert-icon {
    font-size: 20px;
    margin-right: 12px;
    flex-shrink: 0;
}

.alert-message {
    flex-grow: 1;
    margin-right: 12px;
}

.alert-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s;
}

.alert-close:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.alert-success {
    background: linear-gradient(135deg, #4CAF50, #45a049);
    color: white;
    border-left: 4px solid #2e7d32;
}

.alert-warning {
    background: linear-gradient(135deg, #ff9800, #f57c00);
    color: white;
    border-left: 4px solid #ef6c00;
}

.alert-danger {
    background: linear-gradient(135deg, #f44336, #d32f2f);
    color: white;
    border-left: 4px solid #c62828;
}

.alert-info {
    background: linear-gradient(135deg, #2196F3, #1976D2);
    color: white;
    border-left: 4px solid #1565C0;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .flash-messages {
        width: 95%;
        top: 70px;
    }

    .alert {
        padding: 12px 16px;
        font-size: 14px;
    }
}