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

:root {
    --nero: #000000;
    --bianco: #ffffff;
    --grigio-chiaro: #f5f5f5;
    --grigio-medio: #cccccc;
    --grigio-scuro: #333333;
    --rosso-accento: #dc143c;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--grigio-scuro);
    background-color: var(--bianco);
}

h1, h2, h3, .logo {
    font-family: 'Bebas Neue', 'Anton', Impact, sans-serif;
    letter-spacing: 1px;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes glowPulse {
    0%, 100% { text-shadow: 0 0 10px rgba(220, 20, 60, 0.5), 0 0 20px rgba(220, 20, 60, 0.3); }
    50% { text-shadow: 0 0 20px rgba(220, 20, 60, 0.8), 0 0 40px rgba(220, 20, 60, 0.6); }
}

@keyframes shimmer {
    0% { background-position: -1000px 0; }
    100% { background-position: 1000px 0; }
}

.hero-content h1, .page-hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    font-weight: bold;
    background: linear-gradient(90deg, #dc143c, #ff6b6b, #dc143c, #ff1744);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientShift 4s ease infinite, glowPulse 2s ease-in-out infinite;
    filter: drop-shadow(0 0 10px rgba(220, 20, 60, 0.3));
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--nero);
    font-weight: bold;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 100px;
    height: 4px;
    background: linear-gradient(90deg, transparent, #dc143c, transparent);
    margin: 1rem auto 0;
    animation: shimmer 3s infinite;
}

.logo {
    color: var(--bianco);
    font-size: 1.8rem;
    font-weight: bold;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s;
    text-shadow: 0 0 15px rgba(220, 20, 60, 0.6);
    animation: glowPulse 3s ease-in-out infinite;
}

.logo:hover { opacity: 1; text-shadow: 0 0 25px rgba(220, 20, 60, 0.9); }

.navbar {
    background-color: var(--nero);
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    color: var(--bianco);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
    position: relative;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--rosso-accento);
    transition: width 0.3s;
    box-shadow: 0 0 8px rgba(220, 20, 60, 0.6);
}

.nav-menu a:hover::after { width: 100%; }
.nav-menu a:hover, .nav-menu a[aria-current="page"] {
    color: var(--rosso-accento);
    text-shadow: 0 0 10px rgba(220, 20, 60, 0.5);
}
.nav-menu a[aria-current="page"]::after { width: 100%; }

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--bianco);
    font-size: 1.8rem;
    cursor: pointer;
    transition: color 0.3s;
}

.mobile-menu-toggle:hover { color: var(--rosso-accento); }

main {
    margin-top: 80px;
    background: black;
}

.section {
    padding: 8rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.section-subtitle {
    text-align: center;
    font-size: 1.2rem;
    margin-bottom: 3rem;
    color: #fff;
}

.hero {
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)),
        url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><rect fill="%23000" width="1200" height="600"/><path fill="%23111" d="M0 400l50-16.7c50-16.3 150-50 250-50s200 33.7 300 50 200 16.7 300 0 200-50 250-66.7L1200 300v300H0z"/></svg>');
    background-size: cover;
    background-position: center;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--bianco);
    position: relative;
    overflow: hidden;
}

.page-hero {
    background: linear-gradient(135deg, rgba(0,0,0,.85), rgba(220,20,60,.4)), #000;
    padding: 8rem 2rem 4rem;
    text-align: center;
    color: var(--bianco);
}

.page-hero h1 { font-size: 3rem; }
.page-hero p { font-size: 1.2rem; max-width: 700px; margin: 1rem auto 0; }

.hero-content {
    max-width: 800px;
    padding: 2rem;
}

.hero-content .hero-emoji { font-size: 4rem; margin-bottom: 1rem; }

.hero-content p {
    font-size: 1.3rem;
    margin-bottom: 2rem;
    animation: glowPulse 3s ease-in-out infinite;
    text-shadow: 0 0 10px rgba(220, 20, 60, 0.4);
}

.cta-button {
    display: inline-block;
    padding: 1rem 2.5rem;
    background: linear-gradient(135deg, var(--rosso-accento), #ff6b6b);
    color: var(--bianco);
    text-decoration: none;
    font-weight: bold;
    border-radius: 50px;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(220, 20, 60, 0.4), 0 0 20px rgba(220, 20, 60, 0.3);
    animation: glowPulse 2s ease-in-out infinite;
}

.cta-button:hover {
    background: linear-gradient(135deg, #ff6b6b, var(--rosso-accento));
    color: var(--nero);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(220, 20, 60, 0.6), 0 0 40px rgba(220, 20, 60, 0.5);
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 3rem;
    margin-top: 5rem;
    font-size: 20px;
}

.card {
    background: var(--bianco);
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    transition: all 0.3s;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--nero), var(--rosso-accento));
    transform: scaleX(0);
    transition: transform 0.3s;
}

.card:hover::before { transform: scaleX(1); }
.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(220, 20, 60, 0.2);
    border-color: var(--rosso-accento);
}

.card-icon {
    width: 70px; height: 70px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, var(--nero), var(--rosso-accento));
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 2rem; color: var(--bianco);
    transition: all 0.3s;
    box-shadow: 0 0 15px rgba(220, 20, 60, 0.4);
}

.card:hover .card-icon { transform: rotate(360deg) scale(1.1); }

.card h2, .card h3 {
    text-align: center;
    margin-bottom: 1rem;
    color: var(--nero);
    font-size: 1.8rem;
}

.card p { text-align: center; color: var(--grigio-scuro); line-height: 1.8; }

.course-card {
    background: var(--bianco);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.3s;
    border: 3px solid transparent;
    display: flex;
    flex-direction: column;
}

.course-card a.course-link {
    color: inherit; text-decoration: none; display: flex; flex-direction: column; flex: 1;
}

.course-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 50px rgba(220, 20, 60, 0.2);
    border-color: var(--rosso-accento);
}

.course-header {
    color: var(--bianco);
    padding: 1.5rem;
    font-size: 1.5rem;
    font-weight: bold;
    text-align: center;
    position: relative;
    overflow: hidden;
    min-height: 10rem;
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center center;
}

.course-body { padding: 2rem; flex: 1; }

.course-body h2, .course-body h3 {
    color: var(--nero);
    margin-bottom: 1rem;
    font-size: 1.8rem;
    background: linear-gradient(135deg, var(--nero), var(--rosso-accento));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.course-body p {
    color: var(--grigio-scuro);
    margin-bottom: 1.5rem;
    line-height: 1.8;
    font-size: 1rem;
}

.course-link-more {
    display: inline-block;
    color: var(--rosso-accento);
    font-weight: bold;
    text-decoration: none;
    margin-top: 1rem;
}
.course-link-more:hover { text-decoration: underline; }

.contact-section { background: var(--nero); color: var(--bianco); }

.contact-section .section-title {
    color: var(--bianco);
    background: linear-gradient(90deg, #dc143c, #ff6b6b, #dc143c);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.contact-section .section-subtitle { color: var(--grigio-medio); }

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 4rem;
    margin-top: 2rem;
}

.contact-card {
    background: var(--grigio-scuro);
    border-radius: 15px;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 5px 20px rgba(255, 255, 255, 0.1);
    transition: all 0.3s;
    border: 2px solid transparent;
}

.contact-card:hover {
    transform: translateY(-5px);
    border-color: var(--rosso-accento);
    box-shadow: 0 10px 30px rgba(220, 20, 60, 0.4);
}

.contact-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    animation: glowPulse 2s ease-in-out infinite;
}

.contact-card h3 { color: var(--bianco); margin-bottom: 1rem; font-size: 1.3rem; }
.contact-card p { color: var(--grigio-medio); line-height: 1.8; font-size: 1rem; }
.contact-card a { color: #fff; text-decoration: none; font-weight: 500; transition: all 0.3s; }
.contact-card a:hover { opacity: 0.8; text-decoration: underline; }

.map-card {
    background: var(--grigio-scuro);
    border-radius: 15px;
    padding: 0;
    box-shadow: 0 5px 20px rgba(255, 255, 255, 0.1);
    transition: all 0.3s;
    border: 2px solid transparent;
    overflow: hidden;
}

.map-card:hover { border-color: var(--rosso-accento); }
.map-card-header { padding: 1.5rem 2rem; text-align: center; background: rgba(0, 0, 0, 0.3); }
.map-card-header h2, .map-card-header h3 { color: var(--bianco); margin-bottom: 0.5rem; font-size: 1.5rem; }
.map-card-header p { color: var(--grigio-medio); margin: 0; font-size: 1rem; }
#map { width: 100%; height: 400px; }

.mission-section {
    background: linear-gradient(135deg, var(--rosso-accento), var(--nero));
    color: var(--bianco);
    text-align: center;
    padding: 5rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
}

.mission-content { max-width: 800px; margin: 0 auto; }
.mission-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    background: linear-gradient(90deg, #ffffff, #ffcccc, #ffffff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.mission-content p { font-size: 1.5rem; line-height: 1.8; }

.footer {
    background-color: var(--nero);
    color: var(--bianco);
    text-align: center;
    padding: 3rem 2rem 2rem;
}

.footer-content h2, .footer-content h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.footer-content p { margin-bottom: 1.5rem; opacity: 0.9; font-size: 1rem; }

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.footer-links a {
    color: var(--bianco);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    border: 1px solid transparent;
    font-size: 0.9rem;
}

.footer-links a:hover { color: var(--rosso-accento); border-color: var(--rosso-accento); }

.social-icons { display: flex; justify-content: center; gap: 1rem; margin-bottom: 1.5rem; }
.social-icons a img { max-width: 50px; max-height: 50px; border-radius: 100px; transition: all 0.3s; }
.social-icons a:hover img { transform: scale(1.1); }

.breadcrumbs {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.5rem 2rem 0;
    color: var(--grigio-medio);
    font-size: 0.9rem;
}
.breadcrumbs a { color: var(--rosso-accento); text-decoration: none; }
.breadcrumbs a:hover { text-decoration: underline; }

.course-detail {
    max-width: 900px;
    margin: 0 auto;
    padding: 4rem 2rem;
    color: var(--bianco);
}
.course-detail h2 { font-size: 2rem; margin: 2rem 0 1rem; color: var(--rosso-accento); }
.course-detail p, .course-detail li { font-size: 1.1rem; line-height: 1.8; }
.course-detail ul { margin: 1rem 0 1.5rem 2rem; }
.course-detail .lead { font-size: 1.3rem; margin-bottom: 2rem; }
.course-detail img.hero-img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 15px;
    margin-bottom: 2rem;
    box-shadow: 0 10px 30px rgba(220,20,60,.3);
}

.schedule-table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
    background: rgba(255,255,255,0.05);
    border-radius: 10px;
    overflow: hidden;
}
.schedule-table th, .schedule-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}
.schedule-table th {
    background: var(--rosso-accento);
    color: var(--bianco);
    font-weight: bold;
}

.related-courses {
    background: #111;
    padding: 4rem 2rem;
}
.related-courses h2 { color: var(--bianco); text-align: center; margin-bottom: 2rem; }
.related-list {
    max-width: 1000px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}
.related-list a {
    display: block;
    padding: 1.5rem;
    background: var(--grigio-scuro);
    color: var(--bianco);
    text-decoration: none;
    border-radius: 10px;
    text-align: center;
    transition: all 0.3s;
    border: 2px solid transparent;
}
.related-list a:hover { border-color: var(--rosso-accento); transform: translateY(-3px); }

.faq-list { max-width: 900px; margin: 0 auto; }
.faq-item {
    background: rgba(255,255,255,0.05);
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    color: var(--bianco);
}
.faq-item h3 { color: var(--rosso-accento); margin-bottom: 0.5rem; font-size: 1.3rem; }
.faq-item p { color: var(--grigio-medio); }

.faq-section { max-width: 900px; margin: 1.5rem auto 0; }
.faq-section details {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(220,20,60,0.2);
    border-radius: 10px;
    padding: 1.2rem 1.5rem;
    margin-bottom: 0.8rem;
    transition: border-color 0.3s;
}
.faq-section details[open] {
    border-color: var(--rosso-accento);
}
.faq-section summary {
    cursor: pointer;
    color: var(--grigio-scuro);
    font-size: 1.05rem;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.faq-section summary::-webkit-details-marker { display: none; }
.faq-section summary::after {
    content: '+';
    font-size: 1.4rem;
    font-weight: bold;
    color: var(--rosso-accento);
    transition: transform 0.3s;
    flex-shrink: 0;
    margin-left: 1rem;
}
.faq-section details[open] summary::after {
    content: '−';
}
.faq-section details p {
    margin-top: 0.8rem;
    color: #666;
    line-height: 1.7;
}

.stats-section {
    padding: 100px 20px;
    text-align: center;
    color: white;
    background: linear-gradient(135deg, #111, #dc143c);
}
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    max-width: 1000px;
    margin: auto;
}
.stat-number { font-size: 3rem; font-weight: bold; }

html { scroll-behavior: smooth; }

@media (max-width: 768px) {
    .nav-container { padding: 0 1rem; }
    .logo { font-size: 1.3rem; }
    .nav-menu {
        display: none;
        position: absolute;
        top: 100%; left: 0;
        width: 100%;
        background-color: var(--nero);
        flex-direction: column;
        padding: 1rem 0;
        gap: 0;
    }
    .nav-menu.active { display: flex; }
    .nav-menu li { padding: 0.75rem 0; text-align: center; }
    .nav-menu a::after { display: none; }
    .mobile-menu-toggle { display: block; }
    main { margin-top: 70px; }
    .section { padding: 4rem 1rem; }
    .section-title { font-size: 1.8rem; }
    .section-subtitle { font-size: 1rem; margin-bottom: 2rem; }
    .hero { min-height: 450px; }
    .hero-content h1, .page-hero h1 { font-size: 2rem; }
    .hero-content p { font-size: 0.95rem; }
    .cta-button { padding: 0.8rem 2rem; font-size: 0.95rem; }
    .cards-grid { grid-template-columns: 1fr; gap: 1.5rem; margin-top: 3rem; }
    .contact-grid { grid-template-columns: 1fr; gap: 1.5rem; }
    .mission-section { padding: 3rem 1.5rem; gap: 2rem; flex-direction: column; }
    .mission-section img { max-width: 250px; height: auto; }
    #map { height: 300px; }
}

@media (max-width: 480px) {
    .logo span { display: none; }
    .section { padding: 3rem 1rem; }
    .hero-content h1, .page-hero h1 { font-size: 1.5rem; }
}
