/* ============================================================
NEWSPAPER.CSS - Versione Tre Colonne (Wide Container)
============================================================ */

/* 0. RESET & CONTAINER */
#container {
    max-width: 1400px;
    /* Allargato per ospitare 3 colonne */
    margin: 0 auto;
    padding: 0 20px;
}

/* 1. LAYOUT STRUTTURALE */
#main-content {
    display: grid !important;
    /* Su Mobile: 1 sola colonna */
    grid-template-columns: 1fr !important;
    gap: 40px !important;
    align-items: start !important;
    width: 100% !important;
}

/* Regole per Desktop (min-widtha: 1024px) */
@media (min-width: 1024px) {
    #main-content {
        grid-template-columns: 200px minmax(0, 1fr) 280px !important;
    }
}

.article-section {
    min-width: 0 !important;
    border-left: 1px solid #000;
    border-right: 1px solid #000;
    padding: 0 30px;
    box-sizing: border-box;
}

/* Gestione Sidebar Destra */
.sidebar-right {

    min-width: 280px !important;
    flex-shrink: 0;
}

/* Gestione Sidebar Sinistra (Visibile solo su PC) */
.sidebar-left {


    min-width: 200px !important;
}

@media (min-width: 1024px) {
    .sidebar-left {
        display: block;
        /* Visibile su PC */
    }
}

/* Se la pagina non ha sidebar (es. post.show) */
#main-content.no-sidebar {
    display: block !important;
    max-width: 900px;
    margin: 0 auto;
}

#main-content.no-sidebar .article-section {
    border: none;
    padding: 0;
}

/* 2. MASTHEAD */
.masthead {
    text-align: center;
    border-bottom: 5px solid #000;
    margin-bottom: 30px;
}

.main-title {
    font-family: 'Playfair Display', serif !important;
    font-size: clamp(45px, 8vw, 110px) !important;
    font-weight: 900 !important;
    color: #000 !important;
    letter-spacing: -2px !important;
    line-height: 0.8 !important;
    margin: 25px 0 10px 0 !important;
    text-align: center;
}

.main-title span.ampersand {
    font-family: 'Georgia', serif;
    font-style: italic;
    font-weight: 400;
    font-size: 0.8em;
    margin: 0 10px;
}

.info-bar {
    border-top: 2px solid #000;
    border-bottom: 2px solid #000;
    padding: 8px 0;
    display: flex;
    justify-content: space-between;
    font-size: 10pt;
    font-weight: bold;
    text-transform: uppercase;
    font-family: 'Courier Prime', monospace;
    margin-bottom: 10px;
}

/* 3. TIPOGRAFIA */
.post-title {
    font-family: 'Playfair Display', serif;
    font-weight: 900;
    font-size: 35px;
    line-height: 1.1;
    margin-bottom: 10px;
    text-transform: uppercase;
    font-style: italic;
}

.post-subtitle {
    font-size: 18pt;
    border-bottom: 1px solid black;
    padding-bottom: 5px;
    margin-bottom: 10px;
    font-style: italic;
    font-family: 'Lora', serif;
}

.article-body {
    font-family: 'Lora', serif;
    font-size: 18px;
    line-height: 1.6;
    color: #000;
}

/* 4. GRIGLIA INTERNA */
.newspaper-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 2.5rem !important;
    margin: 1.5rem 0 !important;
}

@media (max-width: 768px) {
    .newspaper-grid {
        grid-template-columns: 1fr !important;
    }

    .article-section {
        border-left: none;
        border-right: none;
        padding: 0;
    }

    .avviso-bureau {
        max-width: 260px;
        padding: 30px 15px;
        transform: scale(0.9);
        /* Evita che rompa il layout su iPhone */
    }

}

/* 5. IMMAGINI */
img {
    filter: grayscale(100%) contrast(110%);
    border: 1px solid #000;
    padding: 3px;
    background: #fff;
    box-shadow: 4px 4px 0px #000;
    margin: 20px auto;
    display: block;
}

/* 6. SIDEBAR COMPONENTI */
.segnalazione-box {
    border: 4px solid #000;
    padding: 20px;
    background: #fff;
    box-shadow: 6px 6px 0px 0px #000;
    position: relative;
}

.segnalazione-box::after {
    content: "STOP.";
    position: absolute;
    bottom: 5px;
    right: 10px;
    font-family: 'Courier Prime', monospace;
    font-size: 8px;
    color: #ccc;
}

.sidebar-left button {
    cursor: pointer;
    transition: color 0.2s;
}

.sidebar-left a {
    text-decoration: none;
    color: #444;
}

.sidebar-left a:hover {
    color: #b91c1c;
    /* Rosso giornale */
    padding-left: 4px;
    transition: all 0.2s;
}

.weather-widget {
    position: relative;
    overflow: hidden;
}

.weather-widget table td {
    font-family: 'Courier Prime', monospace;
}

.main-footer {
    border-top: 4px solid #000;
    padding: 40px 0;
    margin-top: 60px;
    text-align: center;
}

.newspaper-subtitle {
    text-align: center;
    margin: 1.5rem 0;
    width: 100%;
}

.newspaper-subtitle hr {
    border: none;
    border-top: 1px solid #000 !important;
    margin: 0.3rem 0;
    opacity: 1 !important;
}

.newspaper-subtitle h4 {
    font-family: 'Playfair Display', serif;
    font-weight: 900;
    text-transform: uppercase;
    /* Fondamentale per l'effetto dell'immagine */
    font-size: 1.2rem;
    letter-spacing: 0.05em;
    padding: 0.4rem 0;
    margin: 0;
    line-height: 1.2;
}

/* Stile Link Navigazione */
.nav-link {
    color: #000;
    text-decoration: none;
    padding: 4px 8px;
    transition: all 0.2s ease;
    position: relative;
}

.nav-link:hover {
    color: #b91c1c;
    /* Rosso Giornale */
}

/* Stile per la pagina attiva */
.nav-link.active {
    background-color: #000;
    color: #fff !important;
    box-shadow: 3px 3px 0px #b91c1c;
}

/* Effetto Hover sofisticato */
.nav-link:not(.active)::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 1px;
    background: #b91c1c;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after {
    width: 80%;
}

/* Responsive: nasconde i diamanti su schermi molto piccoli */
@media (max-width: 640px) {
    .main-nav ul li:nth-child(even) {
        display: none;
    }

    .main-nav ul {
        flex-wrap: wrap;
        gap: 10px;
    }

}

.avviso-bureau {
    font-family: "Courier New", Courier, monospace;
    border: 3px solid #000;
    padding: 35px 20px;
    background-color: #f9f9f7;
    color: #000;
    position: relative;
    box-shadow: 10px 10px 0px #000;
    max-width: 300px;
    margin: 0 auto;
    text-align: center;
    line-height: 1.4;
}

/* Puntina rossa Bureau */
.avviso-bureau::before {
    content: "";
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 20px;
    background: #b91c1c;
    /* Rosso Fondina */
    border-radius: 50%;
    box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5), inset -2px -2px 4px rgba(0, 0, 0, 0.3);
    z-index: 10;
}

.moka-nota-nera {
    background: #000;
    color: #fff !important;
    padding: 12px 10px;
    font-size: 11px;
    font-style: italic;
    display: block;
    margin: 20px -5px;
    transform: rotate(-1.5deg);
    line-height: 1.2;
}