/* Reset e stili base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

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

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Stili header con parallax */
header.parallax {
    background-image: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('img/sfondo.png');
    height: 100vh;
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

.header-content {
    padding: 20px;
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.logo {
    width: 350px;
    margin-right: 15px;
}

h1 {
    font-size: 3.5rem;
    margin-bottom: 15px;
    color: #fff;
}

h2 {
    font-size: 1.8rem;
    margin-bottom: 30px;
    font-weight: 300;
}

/* Stili sezioni */
section {
    padding: 80px 0;
}

h3 {
    font-size: 2.2rem;
    margin-bottom: 30px;
    text-align: center;
    color: #2c3e50;
}

h4 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: #2c3e50;
}

/* Stili info cards */
.info-cards {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    margin-top: 50px;
}

.card {
    flex: 1;
    min-width: 250px;
    margin: 10px;
    padding: 30px 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    text-align: center;
    transition: transform 0.3s ease;
}

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

.card i {
    font-size: 2.5rem;
    color: #3498db;
    margin-bottom: 20px;
}

/* Stili funzionalità */
.features-section.parallax {
    background-image: linear-gradient(rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.9)), url('img/sfondo.png');
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

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

.feature {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    text-align: center;
    transition: all 0.3s ease;
}

.feature:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.feature i {
    font-size: 2.5rem;
    color: #3498db;
    margin-bottom: 20px;
}

/* Stili contatti */
.contact-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin-top: 50px;
}

.contact-info, .contact-form {
    flex: 1;
    min-width: 300px;
    margin: 10px;
}

.contact-info p {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
}

.contact-info i {
    margin-right: 10px;
    color: #3498db;
    font-size: 1.2rem;
    width: 25px;
    text-align: center;
}

.social-icons {
    margin-top: 30px;
}

.social-icons a {
    display: inline-block;
    margin-right: 15px;
    color: #2c3e50;
    font-size: 1.5rem;
    transition: color 0.3s ease;
}

.social-icons a:hover {
    color: #3498db;
}

.contact-form {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.form-group {
    margin-bottom: 20px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
}

.form-group textarea {
    height: 150px;
    resize: vertical;
}

/* Stili footer */
footer {
    background: #2c3e50;
    color: white;
    padding: 50px 0 20px;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.footer-logo {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.footer-logo img {
    width: 250px;
    margin-right: 15px;
}

.footer-logo h3 {
    color: white;
    margin: 0;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
}

.footer-links a {
    color: white;
    margin-right: 20px;
    margin-bottom: 10px;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #3498db;
}

.copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Stili bottoni */
.cta-button {
    display: inline-block;
    background: #3498db;
    color: white;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.cta-button:hover {
    background: #2980b9;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Media queries per responsive design */
@media (max-width: 768px) {
    h1 {
        font-size: 2.5rem;
    }
    
    h2 {
        font-size: 1.4rem;
    }
    
    .info-cards {
        flex-direction: column;
    }
    
    .card {
        margin-bottom: 20px;
    }
    
    .contact-info, .contact-form {
        flex: 100%;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 2rem;
    }
    
    .logo-container {
        flex-direction: column;
    }
    
    .logo {
        margin-right: 0;
        margin-bottom: 15px;
    }
}
/* Stili per i messaggi di risposta del form */
.form-message {
    width: 100%;
    padding: 15px;
    margin-top: 20px;
    border-radius: 5px;
    text-align: center;
    font-weight: bold;
    font-size: 0.95rem;
    display: none; /* Nascosto di default */
}

/* Mostra il messaggio quando ha contenuto */
.form-message:not(:empty) {
    display: block;
}

.form-message.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.form-message.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}
/* Stili per il pulsante "Torna Su" */
#back-to-top-btn {
    display: none; /* Nascosto di default */
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 99; /* Assicura che sia sopra gli altri elementi */
    border: none;
    outline: none;
    background-color: #3498db;
    color: white;
    cursor: pointer;
    padding: 15px;
    border-radius: 50%; /* Lo rende circolare */
    font-size: 18px;
    width: 50px;
    height: 50px;
    line-height: 20px; /* Centra l'icona verticalmente */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transition: background-color 0.3s, opacity 0.4s, visibility 0.4s;
}

#back-to-top-btn:hover {
    background-color: #2980b9; /* Colore più scuro al passaggio del mouse */
}
/* Stili per le pagine di policy */
.policy-header {
    background: #2c3e50;
    padding: 20px 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.policy-header .container {
    display: flex;
    align-items: center;
}

.policy-header .logo {
    width: 200px;
}

.policy-container {
    padding: 80px 20px;
    max-width: 900px;
    margin: 0 auto;
    background: #fff;
    line-height: 1.8;
}

.policy-container h1 {
    font-size: 2.5rem;
    color: #2c3e50;
    margin-bottom: 30px;
    border-bottom: 2px solid #3498db;
    padding-bottom: 10px;
}

.policy-container h2 {
    font-size: 1.8rem;
    color: #2c3e50;
    margin-top: 40px;
    margin-bottom: 20px;
}

.policy-container p, .policy-container li {
    margin-bottom: 15px;
    color: #555;
}

.policy-container ul {
    list-style-position: inside;
    padding-left: 20px;
}
/* Stili per il Banner Cookie */
#cookie-banner {
    display: none; /* Nascosto di default, gestito da JS */
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: rgba(44, 62, 80, 0.97); /* Sfondo scuro semi-trasparente */
    color: white;
    padding: 20px 30px;
    z-index: 1000;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.2);
    font-size: 0.95rem;

    /* Allineamento con Flexbox */
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap; /* Permette di andare a capo su schermi piccoli */
    gap: 20px; /* Spazio tra testo e bottoni */
}

#cookie-banner p {
    margin: 0;
    flex-grow: 1; /* Fa in modo che il testo occupi lo spazio disponibile */
}

#cookie-banner a {
    color: #3498db; /* Usa il colore principale del sito per il link */
    text-decoration: underline;
    font-weight: bold;
}

#cookie-banner .cookie-banner-buttons button {
    background: #3498db;
    color: white;
    border: none;
    padding: 10px 25px;
    border-radius: 50px;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.3s;
}

#cookie-banner .cookie-banner-buttons button:hover {
    background: #2980b9;
}

/* =============================================
   SEZIONE ADMIN
   ============================================= */
.admin-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 80px 0;
}

.admin-section h3 {
    color: white;
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.admin-section h3 i {
    margin-right: 15px;
}

.section-intro {
    text-align: center;
    font-size: 1.2rem;
    margin-bottom: 50px;
    opacity: 0.9;
}

.admin-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
    margin-bottom: 50px;
}

.admin-category {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 25px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: transform 0.3s, box-shadow 0.3s;
}

.admin-category:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.admin-category h4 {
    color: white;
    font-size: 1.3rem;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.3);
}

.admin-category h4 i {
    margin-right: 10px;
}

.admin-category ul {
    list-style: none;
    padding: 0;
}

.admin-category li {
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.95rem;
}

.admin-category li:last-child {
    border-bottom: none;
}

.admin-category li strong {
    color: #ffd700;
}

.admin-extras {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin-top: 40px;
}

.extra-box {
    background: rgba(255, 255, 255, 0.95);
    color: #333;
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    transition: transform 0.3s;
}

.extra-box:hover {
    transform: scale(1.03);
}

.extra-box i {
    font-size: 2.5rem;
    color: #667eea;
    margin-bottom: 15px;
}

.extra-box h5 {
    font-size: 1.2rem;
    color: #2c3e50;
    margin-bottom: 10px;
}

.extra-box p {
    font-size: 0.95rem;
    color: #555;
    margin: 0;
}

/* =============================================
   SEZIONE DOCENTI
   ============================================= */
.docenti-section {
    background: #f6f9fc;
    padding: 80px 0;
}

.docenti-section h3 {
    color: #10b981;
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.docenti-section h3 i {
    margin-right: 15px;
}

.docenti-section .section-intro {
    color: #4a5568;
}

.docenti-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 25px;
    margin-bottom: 50px;
}

.docente-card {
    background: white;
    border-radius: 15px;
    padding: 30px 25px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    border-top: 4px solid #10b981;
    transition: transform 0.3s, box-shadow 0.3s;
}

.docente-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(16, 185, 129, 0.15);
}

.docente-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.docente-card h4 {
    color: #22304a;
    font-size: 1.15rem;
    margin-bottom: 10px;
}

.docente-card p {
    color: #6b7280;
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

.mobile-highlight {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border-radius: 15px;
    padding: 30px 40px;
    display: flex;
    align-items: center;
    gap: 30px;
    margin-top: 40px;
}

.mobile-highlight i {
    font-size: 4rem;
    opacity: 0.9;
}

.mobile-highlight h4 {
    color: white;
    font-size: 1.4rem;
    margin-bottom: 10px;
}

.mobile-highlight p {
    margin: 0;
    opacity: 0.95;
    font-size: 1.05rem;
    line-height: 1.6;
}

/* Media query per schermi più piccoli */
@media (max-width: 768px) {
    h1 {
        font-size: 2.5rem;
    }
    
    h2 {
        font-size: 1.4rem;
    }

    /* NUOVA REGOLA AGGIUNTA QUI */
    .header-content .cta-button {
        margin-bottom: 15px; /* Aggiunge spazio sotto ogni bottone */
    }
    
    .info-cards {
        flex-direction: column;
    }
    
    .card {
        margin-bottom: 20px;
    }
    
    .contact-info, .contact-form {
        flex: 100%;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links {
        justify-content: center;
    }

    /* Regola per il banner cookie già presente */
    #cookie-banner {
        flex-direction: column;
        text-align: center;
    }
    
    /* Sezione Admin responsive */
    .admin-section h3,
    .docenti-section h3 {
        font-size: 1.8rem;
    }
    
    .admin-features,
    .docenti-features {
        grid-template-columns: 1fr;
    }
    
    .mobile-highlight {
        flex-direction: column;
        text-align: center;
        padding: 25px;
    }
    
    .mobile-highlight i {
        font-size: 3rem;
    }
}