/*
 * Stili della sola pagina Blog (/{culture}/blog), caricati da Views/Home/Blog.cshtml.
 * Palette e font allineati a assets/sass/libs/_vars.scss (tema Forty).
 */

/* ------------------------------------------------------------------
 * Banner compatto: altezza data dal contenuto invece di 75vh.
 * Sotto 736px il tema usa già height:auto, quindi si interviene solo sopra.
 * ------------------------------------------------------------------ */
@media screen and (min-width: 737px) {
    #banner.major.compact {
        height: auto;
        min-height: 0;
        max-height: none;
        padding: 7em 0 1em 0;
    }
}

/* ------------------------------------------------------------------
 * Widget blog Soro adattato al tema scuro.
 * Soro inietta a runtime il proprio CSS (<style id="soro-blog-styles-light|dark">) con selettori a classe:
 * ogni regola qui è prefissata da #soro-blog e vince per specificità, senza !important,
 * qualunque tema (Light/Dark) sia selezionato nella dashboard Soro.
 * ------------------------------------------------------------------ */

/* Riserva spazio mentre lo script carica gli articoli (evita layout shift) */
#soro-blog {
    min-height: 12em;
}

/* Elenco e articolo occupano tutta la larghezza di .inner, centrata nella pagina */
#soro-blog .soro-blog {
    max-width: none;
    margin: 0;
    color: #ffffff;
    font-family: 'Source Sans Pro', Helvetica, sans-serif;
    letter-spacing: 0.025em;
}

/* Pulsante "indietro": stesso stile di .button del tema */
#soro-blog .soro-blog-header {
    margin-bottom: 2em;
}

#soro-blog .soro-blog-back {
    gap: 0.75em;
    height: 3.5em;
    padding: 0 1.75em;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: inset 0 0 0 2px #ffffff;
    color: #ffffff;
    font-size: 0.8em;
    font-weight: 600;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    transition: box-shadow 0.2s ease-in-out, color 0.2s ease-in-out;
}

#soro-blog .soro-blog-back:hover {
    background: transparent;
    box-shadow: inset 0 0 0 2px #9bf1ff;
    color: #9bf1ff;
}

/* Elenco articoli */
#soro-blog .soro-blog-list {
    gap: 1.5em;
}

#soro-blog .soro-blog-card {
    gap: 1.75em;
    padding: 1.5em;
    background-color: rgba(212, 212, 255, 0.035);
    border: solid 1px rgba(212, 212, 255, 0.1);
    border-radius: 4px;
    transition: background-color 0.2s ease-in-out, border-color 0.2s ease-in-out;
}

#soro-blog .soro-blog-card:hover {
    background-color: rgba(212, 212, 255, 0.07);
    border-color: #9bf1ff;
    box-shadow: none;
}

#soro-blog .soro-blog-card-image {
    width: 13em;
    height: 9em;
    border-radius: 4px;
}

#soro-blog .soro-blog-card-content {
    display: flex;
    flex-direction: column;
}

#soro-blog .soro-blog-card-title {
    margin: 0 0 0.5em 0;
    color: #ffffff;
    font-size: 1.35em;
    font-weight: 600;
    line-height: 1.4;
    transition: color 0.2s ease-in-out;
}

#soro-blog .soro-blog-card:hover .soro-blog-card-title {
    color: #9bf1ff;
}

#soro-blog .soro-blog-card-excerpt {
    margin: 0 0 1em 0;
    color: rgba(244, 244, 255, 0.75);
    font-size: 0.9em;
    line-height: 1.65;
}

#soro-blog .soro-blog-card-date,
#soro-blog .soro-blog-article-date {
    display: block;
    color: rgba(244, 244, 255, 0.55);
    font-size: 0.7em;
    font-weight: 600;
    letter-spacing: 0.25em;
    text-transform: uppercase;
}

#soro-blog .soro-blog-card-date {
    margin-top: auto;
}

/* Articolo */
#soro-blog .soro-blog-article-title {
    margin: 0 0 0.5em 0;
    color: #ffffff;
    font-size: 2.25em;
    font-weight: 600;
    line-height: 1.3;
}

#soro-blog .soro-blog-article-date {
    margin-bottom: 2.5em;
}

#soro-blog .soro-blog-article-image {
    max-height: 28em;
    margin-bottom: 2.5em;
    border-radius: 4px;
}

#soro-blog .soro-blog-article-content {
    color: rgba(244, 244, 255, 0.85);
    font-size: 1em;
    line-height: 1.8;
}

#soro-blog .soro-blog-article-content p {
    margin: 0 0 1.5em 0;
}

#soro-blog .soro-blog-article-content h1,
#soro-blog .soro-blog-article-content h2,
#soro-blog .soro-blog-article-content h3 {
    margin: 2em 0 0.75em 0;
    color: #ffffff;
    font-weight: 600;
    line-height: 1.4;
}

#soro-blog .soro-blog-article-content h2 {
    font-size: 1.6em;
}

#soro-blog .soro-blog-article-content h3 {
    font-size: 1.25em;
}

#soro-blog .soro-blog-article-content strong,
#soro-blog .soro-blog-article-content b {
    color: #ffffff;
    font-weight: 600;
}

#soro-blog .soro-blog-article-content a {
    color: #9bf1ff;
    border-bottom: dotted 1px;
}

#soro-blog .soro-blog-article-content a:hover {
    border-bottom-color: transparent;
}

#soro-blog .soro-blog-article-content ul,
#soro-blog .soro-blog-article-content ol {
    margin: 0 0 1.5em 0;
    padding-left: 1.25em;
}

#soro-blog .soro-blog-article-content li {
    margin-bottom: 0.5em;
}

#soro-blog .soro-blog-article-content img {
    border-radius: 4px;
}

/* Stati di caricamento / vuoto / errore */
#soro-blog .soro-blog-loading,
#soro-blog .soro-blog-empty {
    color: rgba(244, 244, 255, 0.55);
}

#soro-blog .soro-blog-spinner {
    border-color: rgba(212, 212, 255, 0.1);
    border-top-color: #9bf1ff;
}

#soro-blog .soro-blog-error {
    color: #ec8d81;
}

/* Mobile (breakpoint "small" del tema) */
@media screen and (max-width: 736px) {
    #soro-blog .soro-blog-card {
        flex-direction: column;
        gap: 1em;
        padding: 1em;
    }

    #soro-blog .soro-blog-card-image {
        width: 100%;
        height: 12em;
    }

    #soro-blog .soro-blog-article-title {
        font-size: 1.75em;
    }

    #soro-blog .soro-blog-article-content h2 {
        font-size: 1.35em;
    }
}
