/* ------------------------------
   VARIABILI GLOBALI
------------------------------ */
:root {
    --colore-primario: #2c3e50;
    --colore-secondario: #34495e;
    --colore-accento: #1abc9c;
    --colore-testo: #2c3e50;
    --colore-bg: #ffffff;
    --colore-menu-bg: #ecf0f1;
    --spazio: 1rem;
    --font-base: "Arial", sans-serif;
}

/* ------------------------------
   RESET BASE
------------------------------ */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

body {
    display: flex;
    flex-direction: column;
    font-family: var(--font-base);
    overflow: hidden;
}

/* ------------------------------
   HEADER
------------------------------ */
header {
    background: var(--colore-primario);
    color: white;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo {
    width: 50px;
    height: 50px;
    object-fit: cover;
    border-radius: 6px;
}

/* ------------------------------
   MENU ORIZZONTALE
------------------------------ */
.menu {
    display: flex;
    gap: 15px;
    align-items: center;
}

.home-btn,
.menu-btn,
.dropbtn {
    background: var(--colore-secondario);
    color: white;
    padding: 10px 15px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: bold;
    border: none;
    cursor: pointer;
}

.home-btn {
    background: var(--colore-accento);
}

.home-btn:hover {
    background: #16a085;
}

.menu-btn:hover,
.dropbtn:hover {
    background: #3d5a73;
}

/* Dropdown */
.dropdown {
    position: relative;
}

.dropdown-content {
    display: none;
    position: absolute;
    background: var(--colore-menu-bg);
    min-width: 160px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
    border-radius: 4px;
    z-index: 1000;
}

.dropdown-content a {
    display: block;
    padding: 10px 15px;
    color: var(--colore-testo);
    text-decoration: none;
}

.dropdown-content a:hover {
    background: #d0d7de;
}

.dropdown:hover .dropdown-content {
    display: block;
}

/* ------------------------------
   LAYOUT PRINCIPALE
------------------------------ */
.container {
    flex: 1;
    display: flex;
    gap: 20px;
    padding: 20px;
    overflow: hidden;
}

.colonna {
    background: var(--colore-bg);
    padding: 1px;
    border: 1px solid #bdc3c7;
    overflow-y: auto;
}

.colonna-sx { flex: 0 0 16%; }
.colonna-centro { flex: 0 0 62%; }
.colonna-dx { flex: 0 0 22%; }

/* ------------------------------
   MENU LATERALE
------------------------------ */
.menu-colonna {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.menu-colonna a {
    text-decoration: none;
    color: var(--colore-testo);
    font-weight: normal;
}

.menu-colonna a:hover {
    text-decoration: underline;
}

.titolo-sezione {
    color: red;
    font-weight: bold;
    font-style: italic;
    margin-bottom: 5px;
}

/* ------------------------------
   BLOCCHI CONTENUTO
------------------------------ */
.blocco {
    margin-bottom: 40px;
    overflow: hidden;
}

.blocco img {
    float: left;
    margin-right: 15px;
    width: 190px;
    height: auto;
}

.blocco h2 {
    color: red;
    font-size: 1.8rem;
    margin: 0;
}

.blocco p {
    text-align: justify;
    font-size: 1.1rem;
}

.blocco a {
    text-decoration: none;

}


/* ------------------------------
   FOOTER
------------------------------ */
footer {
    background: var(--colore-primario);
    color: white;
    text-align: center;
    padding: 15px;
}

/* ------------------------------
   RESPONSIVE
------------------------------ */
@media (max-width: 768px) {

    .menu { display: none; }

    header {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }

    .container {
        flex-direction: column;
    }

    .colonna-sx,
    .colonna-dx {
        display: none;
    }

    .colonna-centro {
        flex: 1 0 auto;
        width: 100%;
    }

    .blocco img {
        float: none;
        display: block;
        margin: 0 auto 15px;
        width: 70%;
    }
}

