/*
Theme Name: Tema Antigravity SPA
Description: Portale Segreteria Medica Vanilla convertito per WordPress
Author: Antigravity & Tu
Version: 1.0
*/
/* 
   ==========================================================================
   Premium CSS Stylesheet for Medical Area Secretariat Website (SPA)
   ==========================================================================
*/

:root {
    --primary-medical: #007D34;      /* Verde brand (#007D34) - Usato con equilibrio per accenti ed elementi attivi */
    --accent-medical: #007D34;       /* Verde per bottoni e link primari */
    --accent-hover: #005c26;         /* Verde scuro per stati hover */
    --bg-main: #ffffff;              /* Bianco puro - Sfondo del contenuto principale */
    --bg-card: #ffffff;              /* Sfondo delle card */
    --bg-light: #f8fafc;             /* Sfondo grigio chiarissimo */
    --bg-dark-section: #f8fafc;      /* Sfondo barra laterale (Chiaro ed equilibrato) */
    --text-dark: #0f172a;            /* Ardesia scuro per titoli principali (Rimpiazza il Blu Notte) */
    --text-light: #475569;           /* Grigio ardesia medio per testi secondari (Molto leggibile) */
    --border-color: rgba(71, 85, 105, 0.12); /* Bordi discreti ardesia */
    --success-color: #007D34;
    --warning-color: #d97706;
    
    /* Variabili Sidebar (Chiara e minimale) */
    --text-sidebar: #0f172a;
    --text-sidebar-inactive: #475569;
    --border-sidebar: rgba(71, 85, 105, 0.08);
    --logo-bg: rgba(0, 125, 52, 0.08);
    --sidebar-item-hover: rgba(0, 125, 52, 0.04);
    --sidebar-active-bg: rgba(0, 125, 52, 0.08);
    --sidebar-active-text: #007D34;
    
    --radius-premium: 16px;
    --radius-pill: 30px;
    --shadow-premium: 0 4px 6px -1px rgba(15, 23, 42, 0.02), 0 2px 4px -2px rgba(15, 23, 42, 0.02);
    --shadow-hover: 0 16px 30px -5px rgba(15, 23, 42, 0.05), 0 8px 16px -4px rgba(15, 23, 42, 0.02);
    --transition-smooth: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
}

/* --- RESET & BASIC STYLES --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    font-family: var(--font-body);
    color: var(--text-dark);
    background: radial-gradient(at 0% 0%, rgba(0, 125, 52, 0.04) 0px, transparent 50%),
                radial-gradient(at 80% 20%, rgba(10, 25, 47, 0.03) 0px, transparent 50%),
                radial-gradient(at 100% 100%, rgba(0, 125, 52, 0.05) 0px, transparent 40%),
                #ffffff;
    background-attachment: fixed;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    height: 100%;
}

a {
    color: var(--accent-medical);
    text-decoration: none;
    transition: var(--transition-smooth);
}

a:hover {
    color: var(--accent-hover);
}

/* --- LAYOUT GRID --- */
.app-container {
    display: grid;
    grid-template-columns: 300px 1fr;
    min-height: 100vh;
}

/* --- SIDEBAR (FLOATING GLASS PANELS) --- */
.sidebar {
    background-color: var(--bg-dark-section);
    border: 1px solid var(--border-sidebar);
    display: flex;
    flex-direction: column;
    padding: 30px 24px;
    height: calc(100vh - 40px);
    position: fixed;
    top: 20px;
    left: 20px;
    width: 260px;
    border-radius: 20px;
    z-index: 100;
    box-shadow: 0 12px 30px -5px rgba(10, 25, 47, 0.1), 0 4px 12px -5px rgba(0, 125, 52, 0.15);
    transition: var(--transition-smooth);
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-sidebar);
}

.brand-logo {
    background-color: var(--logo-bg);
    color: var(--accent-medical);
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-text h1 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-sidebar);
    line-height: 1.2;
}

.brand-text span {
    font-size: 0.75rem;
    color: var(--text-sidebar-inactive);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-grow: 1;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--text-sidebar-inactive);
    font-weight: 500;
    border-radius: 10px;
    transition: var(--transition-smooth);
    cursor: pointer;
}

.nav-item svg {
    transition: var(--transition-smooth);
}

.nav-item:hover {
    background-color: var(--sidebar-item-hover);
    color: var(--text-sidebar);
}

.nav-item.active {
    background-color: var(--sidebar-active-bg);
    color: var(--sidebar-active-text);
    box-shadow: 0 8px 16px rgba(0, 125, 52, 0.12);
    transform: translateY(-1px);
}

.nav-item.active svg {
    color: var(--sidebar-active-text);
}

/* --- SIDEBAR DROPDOWN & SUBMENUS --- */
.nav-dropdown {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.dropdown-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    cursor: pointer;
}

.dropdown-label {
    display: flex;
    align-items: center;
    gap: 12px;
}

.submenu-chevron {
    transition: transform 0.25s ease;
    color: var(--text-sidebar-inactive);
}

.nav-dropdown.expanded .submenu-chevron {
    transform: rotate(180deg);
    color: var(--primary-medical);
}

.submenu-list {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-left: 32px;
    margin-top: 2px;
}

.nav-dropdown.expanded .submenu-list {
    max-height: 250px; /* Altezza massima sufficiente per contenere i sottomenu */
}

.submenu-item {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    color: var(--text-sidebar-inactive);
    font-size: 0.9rem;
    font-weight: 500;
    border-radius: 8px;
    transition: var(--transition-smooth);
    cursor: pointer;
}

.submenu-item:hover {
    background-color: var(--sidebar-item-hover);
    color: var(--text-sidebar);
}

.submenu-item.active {
    background-color: var(--sidebar-active-bg);
    color: var(--sidebar-active-text);
    font-weight: 600;
}

.sidebar-footer {
    margin-top: auto;
    border-top: 1px solid var(--border-sidebar);
    padding-top: 20px;
    font-size: 0.75rem;
    color: var(--text-sidebar-inactive);
}


/* --- MAIN CONTENT --- */
.main-content {
    grid-column: 2;
    padding: 40px 50px 40px 20px;
    margin: 0 auto; /* Centra automaticamente il contenuto nello spazio a destra del menu */
    max-width: 1100px; /* Limite di larghezza che volevi tu */
    width: 100%;
}

.mobile-header {
    display: none; /* Nascosto su desktop */
}

/* --- SECTIONS (SPA SWITCH) --- */
.content-section {
    display: none;
    opacity: 0;
}

.content-section.active {
    display: block;
    opacity: 1;
    animation: fadeInUpScale 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes fadeInUpScale {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* --- HEADER DELLE SEZIONI --- */
.section-header {
    margin-bottom: 35px;
}

.badge {
    background-color: rgba(14, 165, 233, 0.1);
    color: var(--accent-medical);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 6px 12px;
    border-radius: 20px;
    display: inline-block;
    margin-bottom: 10px;
}

.section-header h2 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--primary-medical);
    margin-bottom: 6px;
}

.subtitle {
    color: var(--text-light);
    font-size: 1.1rem;
    font-weight: 400;
}

/* --- CARDS --- */
.card {
    background-color: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-premium);
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-premium);
    transition: var(--transition-smooth);
}

.card:hover {
    transform: translateY(-5px);
    background-color: rgba(255, 255, 255, 0.95);
    border-color: rgba(0, 125, 52, 0.25);
    box-shadow: 0 16px 30px rgba(0, 125, 52, 0.06), 0 8px 16px rgba(0, 125, 52, 0.03);
}

.card-header {
    margin-bottom: 20px;
}

.card-header h3 {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--primary-medical);
    display: flex;
    align-items: center;
    gap: 10px;
}

.card-header h3 svg {
    color: var(--accent-medical);
    flex-shrink: 0;
}

.card-subtitle {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-top: 4px;
    padding-left: 32px; /* Allineamento per saltare l'icona */
}

/* --- HERO CARD (Cos'è il semestre filtro) --- */
.card-hero {
    background: linear-gradient(135deg, #007D34 0%, #166534 100%);
    color: #ffffff;
    display: flex;
    gap: 20px;
    align-items: flex-start;
    border: none;
}

.card-hero:hover {
    box-shadow: 0 15px 30px rgba(0, 125, 52, 0.15);
}

.card-hero-icon {
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--accent-medical);
    width: 60px;
    height: 60px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.card-hero-body h3 {
    font-family: var(--font-heading);
    color: #ffffff;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.card-hero-body p {
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.7;
    font-size: 1.05rem;
}

.card-hero-body p strong {
    color: #ffffff;
    font-weight: 600;
}

/* --- TABLES --- */
.table-responsive {
    overflow-x: auto;
    width: 100%;
}

.premium-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin-top: 10px;
}

.premium-table th {
    background-color: var(--bg-light);
    color: var(--primary-medical);
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 16px 20px;
    border-bottom: 2px solid var(--border-color);
    text-align: left;
}

.premium-table td {
    padding: 18px 20px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-dark);
    font-size: 0.95rem;
    transition: var(--transition-smooth);
}

.premium-table tr:last-child td {
    border-bottom: none;
}

.premium-table tr:hover td {
    background-color: rgba(14, 165, 233, 0.02);
}

.test-badge {
    background-color: var(--primary-medical);
    color: #ffffff;
    padding: 6px 12px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 0.02em;
    display: inline-block;
}

.btn-download {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: rgba(14, 165, 233, 0.08);
    color: var(--accent-medical);
    padding: 8px 14px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.85rem;
}

.btn-download:hover {
    background-color: var(--accent-medical);
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(14, 165, 233, 0.15);
}

/* --- RESULTS GRID --- */
.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 15px;
}

.results-card {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    background-color: var(--bg-light);
    transition: var(--transition-smooth);
}

.results-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-premium);
    border-color: rgba(14, 165, 233, 0.2);
}

.results-card.highlight {
    background: linear-gradient(135deg, rgba(15, 44, 89, 0.02) 0%, rgba(14, 165, 233, 0.03) 100%);
    border: 2px solid rgba(14, 165, 233, 0.3);
}

.results-card .file-icon {
    font-size: 2.2rem;
    display: block;
    margin-bottom: 12px;
}

.results-card h4 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-medical);
    margin-bottom: 8px;
}

.status {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
    display: inline-block;
}

.status-pending {
    background-color: rgba(245, 158, 11, 0.1);
    color: var(--warning-color);
}

.status-active {
    background-color: rgba(16, 185, 129, 0.1);
    color: var(--success-color);
}

/* --- FAQ / ACCORDION --- */
.accordion {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 10px;
}

.accordion-item {
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    background-color: #ffffff;
    transition: var(--transition-smooth);
}

.accordion-item:hover {
    border-color: var(--accent-medical);
    box-shadow: 0 4px 12px rgba(15, 44, 89, 0.03);
}

.accordion-header {
    width: 100%;
    background: none;
    border: none;
    padding: 18px 20px;
    text-align: left;
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-medical);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    outline: none;
}

.accordion-header .chevron {
    color: var(--text-light);
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.accordion-item.active {
    border-color: var(--accent-medical);
}

.accordion-item.active .accordion-header {
    background-color: var(--bg-light);
    border-bottom: 1px solid var(--border-color);
}

.accordion-item.active .chevron {
    transform: rotate(180deg);
    color: var(--accent-medical);
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, padding 0.3s ease;
    background-color: var(--bg-light);
}

.accordion-content p {
    padding: 20px;
    color: var(--text-dark);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* --- TABS --- */
.tabs-nav {
    display: flex;
    gap: 10px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 30px;
    padding-bottom: 2px;
}

.tab-btn {
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    padding: 12px 24px;
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-light);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition-smooth);
    outline: none;
}

.tab-btn:hover {
    color: var(--primary-medical);
}

.tab-btn.active {
    color: var(--primary-medical);
    border-bottom-color: var(--accent-medical);
}

.tab-content {
    display: none;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.tab-content.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

/* --- GRID 2 COLONNE --- */
.grid-2col {
    display: grid;
    grid-template-columns: 1.6fr 1fr;
    gap: 30px;
}

.info-list {
    list-style: none;
    margin-top: 20px;
}

.info-list li {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.95rem;
}

.info-list li:last-child {
    border-bottom: none;
}

.info-label {
    font-weight: 600;
    color: var(--text-light);
}

.info-val {
    color: var(--primary-medical);
    font-weight: 500;
}

/* --- SIDEBAR CARD PROFILE --- */
.sidebar-card {
    background-color: var(--bg-light);
}

.contact-profile {
    display: flex;
    gap: 15px;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid var(--border-color);
}

.contact-profile:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.contact-profile:first-of-type {
    padding-top: 0;
}

.profile-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: var(--primary-medical);
    color: #ffffff;
    font-weight: 700;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.profile-info h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--primary-medical);
}

.profile-info span {
    display: block;
    font-size: 0.75rem;
    color: var(--text-light);
    margin-bottom: 2px;
}

.profile-info a {
    font-size: 0.85rem;
    font-weight: 500;
}

/* --- CURRICULUM GRID --- */
.curriculum-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-top: 15px;
}

.curriculum-year {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
    background-color: var(--bg-light);
    position: relative;
    overflow: hidden;
}

.year-num {
    position: absolute;
    top: -15px;
    right: -10px;
    font-family: var(--font-heading);
    font-size: 6rem;
    font-weight: 800;
    color: rgba(15, 44, 89, 0.03);
    line-height: 1;
}

.curriculum-year h4 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--primary-medical);
    margin-bottom: 15px;
    border-bottom: 2px solid var(--accent-medical);
    padding-bottom: 8px;
    display: inline-block;
}

.curriculum-year ul {
    list-style: none;
}

.curriculum-year ul li {
    font-size: 0.9rem;
    padding: 8px 0 8px 15px;
    position: relative;
    border-bottom: 1px solid rgba(226, 232, 240, 0.5);
}

.curriculum-year ul li:last-child {
    border-bottom: none;
}

.curriculum-year ul li::before {
    content: "•";
    color: var(--accent-medical);
    font-weight: bold;
    font-size: 1.2rem;
    position: absolute;
    left: 0;
    top: 4px;
}

/* --- STEPS FLOW (DOMANDA DI LAUREA) --- */
.steps-flow {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 15px;
}

.step-card {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    background-color: var(--bg-light);
    position: relative;
}

.step-num {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: var(--accent-medical);
    color: #ffffff;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
}

.step-card h4 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-medical);
    margin-bottom: 8px;
}

.step-card p {
    font-size: 0.85rem;
    color: var(--text-light);
    line-height: 1.5;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    border-radius: var(--radius-pill);
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.95rem;
    border: none;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.btn-primary {
    background-color: var(--accent-medical);
    color: #ffffff;
}

.btn-primary:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(14, 165, 233, 0.2);
}

/* --- DEADLINES (HIGHLIGHT SESSION) --- */
.card-highlight {
    border: 2px solid rgba(14, 165, 233, 0.4);
    background-color: rgba(14, 165, 233, 0.02);
}

.session-status {
    background-color: rgba(16, 185, 129, 0.1);
    color: var(--success-color);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 4px 10px;
    border-radius: 10px;
    float: right;
    margin-top: -30px;
}

.deadlines-list {
    list-style: none;
    margin-top: 10px;
}

.deadlines-list li {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
    font-size: 0.95rem;
}

.deadlines-list li:last-child {
    border-bottom: none;
}

.deadlines-list li strong {
    color: var(--primary-medical);
    font-weight: 600;
}

.deadlines-list li span {
    color: var(--accent-hover);
    font-weight: 600;
}

.btn-link {
    font-size: 0.9rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.accordion-actions {
    display: flex;
    gap: 20px;
    margin-top: 15px;
    border-top: 1px solid var(--border-color);
    padding-top: 15px;
}

/* --- MOCK MAP --- */
.mock-map {
    background-color: #e2e8f0;
    height: 220px;
    border-radius: 10px;
    margin-top: 20px;
    position: relative;
    overflow: hidden;
    background-image: radial-gradient(#cbd5e1 20%, transparent 20%),
                      radial-gradient(#cbd5e1 20%, transparent 20%);
    background-size: 20px 20px;
    background-position: 0 0, 10px 10px;
}

.map-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #ffffff;
    padding: 15px 20px;
    border-radius: 10px;
    box-shadow: 0 10px 25px rgba(15, 44, 89, 0.1);
    text-align: center;
    border: 1px solid var(--border-color);
}

.map-pin {
    color: #ef4444;
    animation: bounce 2s infinite;
    display: block;
    margin: 0 auto 5px;
}

.map-overlay h4 {
    font-size: 0.9rem;
    color: var(--primary-medical);
    font-weight: 750;
}

.map-overlay span {
    font-size: 0.75rem;
    color: var(--text-light);
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

/* --- HOURS BOX --- */
.hours-box {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.hours-item {
    border-left: 3px solid var(--accent-medical);
    padding-left: 15px;
}

.hours-days {
    font-weight: 600;
    color: var(--primary-medical);
    font-size: 0.95rem;
    margin-bottom: 4px;
}

.hours-time {
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.6;
}

.badge-fast {
    background-color: rgba(16, 185, 129, 0.1);
    color: var(--success-color);
}

.badge-normal {
    background-color: rgba(14, 165, 233, 0.1);
    color: var(--accent-medical);
}

.email-link {
    font-weight: 550;
}

/* --- FORM --- */
.premium-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 10px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-light);
}

.form-group input, 
.form-group select, 
.form-group textarea {
    font-family: var(--font-body);
    font-size: 0.95rem;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    outline: none;
    transition: var(--transition-smooth);
    background-color: #ffffff;
}

.form-group input:focus, 
.form-group select:focus, 
.form-group textarea:focus {
    border-color: var(--accent-medical);
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.12);
}

.form-actions {
    display: flex;
    justify-content: flex-end;
}

.btn-submit {
    border: none;
    font-size: 1rem;
    padding: 14px 30px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.form-success-alert {
    display: none;
    align-items: center;
    gap: 12px;
    background-color: rgba(16, 185, 129, 0.08);
    color: var(--success-color);
    padding: 16px 20px;
    border-radius: 8px;
    border: 1px solid rgba(16, 185, 129, 0.2);
    font-weight: 600;
    font-size: 0.95rem;
    margin-top: 20px;
    animation: fadeIn 0.4s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- HERO SLIDER (HOMEPAGE) --- */
.hero-slider {
    position: relative;
    height: 420px;
    border-radius: 20px;
    overflow: hidden;
    margin-bottom: 40px;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.04);
}

.slides-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    z-index: 1;
    transition: opacity 0.8s ease-in-out;
    display: flex;
    align-items: center;
    padding: 40px 60px;
    box-sizing: border-box;
}

.slide.active {
    opacity: 1;
    z-index: 2;
}

/* Gradianti eleganti istituzionali per le slide */
.slide-welcome {
    background: linear-gradient(135deg, #007D34 0%, #15803d 50%, #166534 100%);
}

.slide-graduation {
    background: linear-gradient(135deg, #334155 0%, #1e293b 50%, #0f172a 100%);
}

.slide-admissions {
    background: linear-gradient(135deg, #0d9488 0%, #0f766e 50%, #115e59 100%);
}

.slide-content {
    position: relative;
    z-index: 2;
    max-width: 550px;
    color: #ffffff;
}

.slide-content h2 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 750;
    margin-bottom: 15px;
    line-height: 1.2;
    color: #ffffff;
}

.slide-content p {
    font-size: 1.05rem;
    margin-bottom: 25px;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.6;
}

/* Slider Controls */
.slider-controls {
    position: absolute;
    bottom: 30px;
    left: 60px;
    display: flex;
    gap: 8px;
    z-index: 10;
}

.slider-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.4);
    border: none;
    cursor: pointer;
    transition: var(--transition-smooth);
    padding: 0;
}

.slider-dot.active {
    background-color: #ffffff;
    width: 28px;
    border-radius: 5px;
}

/* --- QUICK LINKS GRID --- */
.quick-links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 25px;
    margin-bottom: 45px;
}

.quick-link-card {
    background-color: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-premium);
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    transition: var(--transition-smooth);
    cursor: pointer;
}

.quick-link-card:hover {
    transform: translateY(-6px);
    border-color: rgba(0, 125, 52, 0.25);
    box-shadow: 0 16px 30px rgba(0, 125, 52, 0.05);
    background-color: rgba(255, 255, 255, 0.95);
}

.quick-link-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background-color: rgba(0, 125, 52, 0.06);
    color: var(--primary-medical);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 18px;
    transition: var(--transition-smooth);
}

.quick-link-card:hover .quick-link-icon {
    background-color: var(--primary-medical);
    color: #ffffff;
}

.quick-link-card h4 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.quick-link-card p {
    font-size: 0.88rem;
    color: var(--text-light);
    line-height: 1.5;
}

/* --- BACHECA AVVISI (NEWS) --- */
.news-section {
    margin-top: 15px;
}

.news-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.news-item {
    background-color: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 20px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    transition: var(--transition-smooth);
}

.news-item:hover {
    background-color: rgba(255, 255, 255, 0.95);
    border-color: rgba(0, 125, 52, 0.2);
    transform: translateX(6px);
    box-shadow: 0 8px 20px rgba(0, 125, 52, 0.02);
}

.news-meta {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex-grow: 1;
}

.news-date-badge {
    display: flex;
    align-items: center;
    gap: 8px;
}

.news-date {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-light);
}

.news-tag {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 2px 8px;
    border-radius: 6px;
    letter-spacing: 0.05em;
}

.tag-avviso {
    background-color: rgba(217, 119, 6, 0.08);
    color: var(--warning-color);
}

.tag-scadenza {
    background-color: rgba(239, 68, 68, 0.08);
    color: #ef4444;
}

.tag-amministrazione {
    background-color: rgba(0, 125, 52, 0.08);
    color: var(--primary-medical);
}

.news-title {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-dark);
    line-height: 1.45;
}

.news-action {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: rgba(71, 85, 105, 0.05);
    color: var(--text-light);
    transition: var(--transition-smooth);
    flex-shrink: 0;
}

.news-item:hover .news-action {
    background-color: var(--primary-medical);
    color: #ffffff;
    transform: translateX(4px);
}

/* --- RESPONSIVE RESPONSIVENESS --- */
@media (max-width: 1024px) {
    .app-container {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        transform: translateX(-100%);
        box-shadow: 10px 0 30px rgba(0,0,0,0.1);
        height: 100vh;
        position: fixed;
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .main-content {
        grid-column: 1;
        margin-left: 0;
        width: 100%;
        padding: 80px 24px 40px;
    }
    
    .mobile-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        background-color: var(--bg-dark-section);
        border-bottom: 1px solid var(--border-sidebar);
        padding: 15px 24px;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 99;
        height: 64px;
    }
    
    .mobile-brand {
        display: flex;
        align-items: center;
        gap: 10px;
        color: var(--text-sidebar);
    }
    
    .mobile-brand svg {
        color: var(--accent-medical);
    }
    
    .mobile-brand h2 {
        font-family: var(--font-heading);
        font-size: 1.15rem;
        font-weight: 750;
    }
    
    .menu-toggle {
        background: none;
        border: none;
        color: var(--text-sidebar);
        cursor: pointer;
        outline: none;
    }
    
    .grid-2col {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}