/* INFOLORÈLECA — Tema Rowling — grafica chiara */

/* 01. Sfondo e colori generali */
body, .site, .site-content, .content-area, #page,
.wrapper.section-inner, .wrapper.section-inner::before,
.wrapper.section-inner::after {
    background-color: #fff !important;
}
.wrapper.section-inner, .wrapper .post-inner {
    color: #222 !important;
}

/* 02. Testata, logo e navigazione */
#masthead, .site-header, .site-branding, .header-wrapper,
.header-inner, .header-area {
    background: #202020 !important;
}
.site-header { padding: 20px 0 !important; }
.header-wrapper { padding: 15px 0 !important; }
.header-wrapper .header, .header-wrapper .section-inner {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    min-height: 0 !important;
}
.site-branding {
    margin: 0 0 15px !important;
    padding: 0 !important;
}
.site-title, .site-title a { color: #fff !important; }
.site-title {
    font-size: 32px !important;
    font-weight: 700 !important;
    letter-spacing: 1px;
    margin-top: 8px !important;
}
.site-description { color: #d0d0d0 !important; font-size: 16px !important; }
.site-logo-link { margin: 0 !important; padding: 0 !important; display: inline-block !important; }
.custom-logo { max-width: 85px !important; height: auto !important; }
.site-header .custom-logo, .header-wrapper .site-logo-link img, .site-logo-link img {
    width: auto !important;
    height: auto !important;
    max-width: 520px !important;
    max-height: 125px !important;
}
.site-logo-link img.site-logo, .header-wrapper .site-logo-link img.site-logo {
    width: 420px !important;
    max-width: 100% !important;
    height: auto !important;
    max-height: none !important;
}
.main-navigation, .main-navigation ul { background: #c51b0b !important; }
.main-navigation, .navigation { margin-top: 10px !important; }
nav.top-nav { display: none !important; }

/* 03. Titoli e metadati */
.wrapper .post-title, .wrapper .post-title a,
.wrapper .entry-title, .wrapper .entry-title a,
.home article h2, .home article h2 a {
    color: #222 !important;
}
.wrapper .post-title:hover, .wrapper .post-title a:hover,
.wrapper .entry-title:hover, .wrapper .entry-title a:hover,
.home article h2 a:hover { color: #d92005 !important; }
.single-post .wrapper h1, .single-post .wrapper .post-title,
.single-post .wrapper .entry-title {
    color: #222 !important;
    font-size: 40px !important;
    line-height: 1.18 !important;
    font-weight: 500 !important;
}
.wrapper .post-meta, .wrapper .post-meta a,
.single-post .entry-meta, .single-post .entry-meta a { color: #666 !important; }
.single-post .post-meta, .single-post .entry-meta {
    font-size: 14px !important;
    line-height: 1.6 !important;
}
.single-post .post-meta a, .single-post .entry-meta a { font-weight: 600 !important; }
.single-post .post-meta > *, .single-post .entry-meta > * { margin-bottom: 4px !important; }

/* 04. Testo degli articoli */
.wrapper .post-content, .wrapper .entry-content,
.wrapper .post-content p, .wrapper .entry-content p,
.wrapper .post-content li, .wrapper .entry-content li,
.wrapper .post-content strong, .wrapper .post-content b,
.wrapper .post-content h2, .wrapper .post-content h3,
.wrapper .post-content h4, .wrapper .entry-content h2,
.wrapper .entry-content h3, .wrapper .entry-content h4 {
    color: #222 !important;
}
.post-content, .post-content p, .post-content p.wp-block-paragraph {
    font-size: 18px !important;
    line-height: 1.75 !important;
}
.single-post .post-content {
    max-width: 760px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-top: 10px !important;
}
.single-post .post-content p { margin: 0 0 1.45em !important; }
.post-content h2, .post-content h3 { line-height: 1.3 !important; }
.single-post .post-content h2 { margin: 1.8em 0 .7em !important; }
.single-post .post-content h3 { margin: 1.5em 0 .6em !important; }
.wrapper .post-content a, .wrapper .entry-content a { color: #b51c00 !important; }
/* Il primo paragrafo non viene scambiato per un sommario o una didascalia. */

/* 05. Immagini, didascalie e visite */
.single-post .post-content figure, .single-post .post-content img {
    margin-left: auto !important;
    margin-right: auto !important;
}
.wrapper .post-content figcaption, .wrapper .post-content .wp-element-caption,
.wrapper .post-content figcaption *, .wrapper .wp-caption-text {
    color: #555 !important;
    opacity: 1 !important;
    font-size: 15px !important;
    line-height: 1.4 !important;
}
body.single-post .wrapper .post-content p em { color: #555 !important; opacity: 1 !important; }
body .wrapper .post-content .infoloreleca-post-views,
body .wrapper .post-content .infoloreleca-post-views * { color: #666 !important; opacity: 1 !important; }

/* 06. Tabelle e citazioni */
body.single-post .post-content table {
    width: 100% !important;
    border-collapse: collapse !important;
    background-color: #fff !important;
}
body.single-post .post-content td, body.single-post .post-content th {
    color: #222 !important;
    border: 1px solid #ddd !important;
    padding: 10px !important;
}
body.single-post .post-content th { background-color: #eee !important; }
.single-post .post-content blockquote, .single-post .post-content .wp-block-quote {
    background: #f5f5f5 !important;
    color: #222 !important;
    border-left: 5px solid #e5220c !important;
    padding: 24px 28px !important;
    margin: 28px 0 !important;
}
.single-post .post-content blockquote p, .single-post .post-content .wp-block-quote p {
    color: #222 !important;
    font-size: 20px !important;
    line-height: 1.55 !important;
    font-style: italic !important;
}
.single-post .post-content blockquote::before, .single-post .post-content .wp-block-quote::before { color: #e5220c !important; }

/* 07. Barra laterale e ricerca */
#secondary, .sidebar, .sidebar-wrapper, .widget-area,
.sidebar .widget, .widget-area .widget { background-color: #fff !important; }
#secondary, .sidebar, .widget-area,
#secondary p, .sidebar p, .widget-area p,
#secondary li, .sidebar li, .widget-area li,
#secondary .widget-title, .sidebar .widget-title, .widget-area .widget-title,
.sidebar .widget, #secondary a, .sidebar .widget a, .widget-area a { color: #222 !important; }
#secondary a:hover, .sidebar .widget a:hover, .widget-area a:hover { color: #d92005 !important; }
#secondary li, .sidebar li, .widget-area li { border-color: #ddd !important; }
#secondary input[type="search"], .sidebar input[type="search"], .widget-area input[type="search"] {
    background: #fff !important;
    color: #222 !important;
    border-color: #aaa !important;
}
#secondary button, .sidebar button, .widget-area button, #secondary input[type="submit"] {
    background: #e5220c !important;
    color: #fff !important;
}

/* 08. Articoli correlati Jetpack: fondo articolo e sidebar */
body #jp-relatedposts .jp-relatedposts-items .jp-relatedposts-post .jp-relatedposts-post-date,
body #jp-relatedposts .jp-relatedposts-items .jp-relatedposts-post .jp-relatedposts-post-context,
body .jp-relatedposts-post-date, body .jp-relatedposts-post-context,
body .sidebar .jp-related-posts-i2__post-date { color: #555 !important; opacity: 1 !important; }
.sidebar .jp-related-posts-i2__list {
    display: flex !important;
    flex-direction: column !important;
    gap: 15px !important;
}
.sidebar .jp-related-posts-i2__post {
    width: 100% !important;
    max-width: 100% !important;
    padding-bottom: 12px !important;
    border-bottom: 1px solid #ddd !important;
}
.sidebar .jp-related-posts-i2__post-link {
    font-size: 15px !important;
    line-height: 1.4 !important;
    font-weight: 500 !important;
}
.sidebar .jp-related-posts-i2__post-date { font-size: 12px !important; }

/* 09. Condivisione a fondo articolo */
.single-post .sharedaddy {
    margin-top: 40px !important;
    padding-top: 22px !important;
    border-top: 1px solid #ddd !important;
}
.single-post .sharedaddy h3.sd-title {
    color: #222 !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    margin-bottom: 15px !important;
}
.single-post .sharedaddy h3.sd-title::before {
    border-top: 3px solid #e5220c !important;
    width: 55px !important;
    margin-bottom: 10px !important;
}
.single-post .sd-content ul li { margin: 0 7px 8px 0 !important; }
.single-post .sd-social-icon-text .sd-content ul li a.sd-button,
.single-post .sd-social-text .sd-content ul li a.sd-button,
.single-post .sd-content ul li a.sd-button {
    font-size: 15px !important;
    padding: 7px 11px !important;
    line-height: 1.2 !important;
}

/* 10. Pulsanti social Infoloreleca */
.single-post .post-content .infoloreleca-share-top {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    flex-wrap: nowrap !important;
    margin: 12px 0 18px !important;
}
.single-post .post-content .infoloreleca-share-top .share-label {
    color: #222 !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    margin-right: 4px !important;
}
.single-post .post-content .infoloreleca-share-top > a {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 36px !important;
    height: 36px !important;
    min-width: 36px !important;
    min-height: 36px !important;
    max-width: 36px !important;
    max-height: 36px !important;
    padding: 0 !important;
    margin: 0 !important;
    background-color: #e5220c !important;
    border-radius: 50% !important;
    text-decoration: none !important;
}
.single-post .post-content .infoloreleca-share-top > a > span {
    color: #fff !important;
    background: transparent !important;
    margin: 0 !important;
    padding: 0 !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
}
.single-post .post-content .infoloreleca-share-top > a.share-facebook > span { font-size: 20px !important; }
.single-post .post-content .infoloreleca-share-top > a.share-x > span { font-size: 16px !important; }
.single-post .post-content .infoloreleca-share-top > a:hover { background-color: #fff !important; }
.single-post .post-content .infoloreleca-share-top > a:hover > span { color: #e5220c !important; }

/* 11. Tablet */
@media screen and (max-width: 900px) {
    .site-header .custom-logo, .site-logo-link img, .header-wrapper .site-logo-link img {
        max-width: 400px !important;
        max-height: 100px !important;
    }
    .site-logo-link img.site-logo, .header-wrapper .site-logo-link img.site-logo {
        width: 340px !important;
        max-width: 100% !important;
        max-height: none !important;
    }
}

/* 12. Smartphone */
@media screen and (max-width: 600px) {
    .site-header { padding: 12px 0 !important; }
    .header-wrapper { padding: 10px 0 !important; }
    .site-branding { margin-bottom: 8px !important; }
    .site-title { font-size: 25px !important; line-height: 1.05 !important; }
    .site-description { font-size: 14px !important; line-height: 1.25 !important; }
    .custom-logo { max-width: 70px !important; }
    .site-header .custom-logo, .site-logo-link img, .header-wrapper .site-logo-link img {
        max-width: 290px !important;
        max-height: 80px !important;
    }
    .site-logo-link img.site-logo, .header-wrapper .site-logo-link img.site-logo {
        width: 250px !important;
        max-width: 72vw !important;
        max-height: none !important;
    }
    .navigation { margin-top: 5px !important; }
    .single-post .wrapper h1, .single-post .wrapper .post-title,
    .single-post .wrapper .entry-title { font-size: 29px !important; line-height: 1.18 !important; }
    .single-post .post-content, .single-post .post-content p,
    .single-post .post-content p.wp-block-paragraph {
        font-size: 16.5px !important;
        line-height: 1.65 !important;
    }
    .single-post .post-content p { margin-bottom: 1.35em !important; }
    .single-post .post-content strong, .single-post .post-content b { font-size: inherit !important; }
    .single-post .post-content img { max-width: 100% !important; height: auto !important; }
    .jetpack-subscribe-floating-button { display: none !important; }
    .single-post .post-content .infoloreleca-share-top { gap: 6px !important; }
    .single-post .post-content .infoloreleca-share-top > a {
        width: 32px !important; height: 32px !important;
        min-width: 32px !important; min-height: 32px !important;
        max-width: 32px !important; max-height: 32px !important;
    }
    .single-post .post-content .infoloreleca-share-top .share-label { font-size: 13px !important; }
    .single-post .post-content blockquote, .single-post .post-content .wp-block-quote {
        padding: 18px 20px !important; margin: 22px 0 !important;
    }
    .single-post .post-content blockquote p, .single-post .post-content .wp-block-quote p { font-size: 18px !important; }
    .home .section-inner.content { max-width: 98% !important; width: 98% !important; }
    .home .posts { width: 100% !important; }
    .home .posts .post {
        width: 100% !important; max-width: 100% !important;
        float: none !important; margin: 0 0 32px !important;
    }
    .home .posts .post-image, .home .posts .post-image img { width: 100% !important; height: auto !important; }
    .posts .post-title, .post-container .post-title, .home .posts .post-title a,
    .home .posts article h2, .home .posts article h2 a {
        font-size: 24px !important; line-height: 1.25 !important;
        margin-top: 8px !important; margin-bottom: 8px !important;
    }
    .post-categories { font-size: 14px !important; line-height: 1.2 !important; margin-bottom: 7px !important; }
    .post-meta { font-size: 14px !important; line-height: 1.3 !important; }
}