:root {
    --bf-bg: #f6f7fb;
    --bf-surface: #ffffff;
    --bf-text: #111827;
    --bf-muted: #6b7280;
    --bf-border: #e5e7eb;
    --bf-accent: #2563eb;
    --bf-radius: 18px;
    --bf-shadow: 0 10px 30px rgba(17, 24, 39, 0.08);
}

*, *::before, *::after { box-sizing: border-box; }
html {
    overflow-x: hidden;
}
body {
    margin: 0;
    overflow-x: hidden;
    padding-top: 71px;
    background: var(--bf-bg);
    color: var(--bf-text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    line-height: 1.65;
}
a { color: var(--bf-accent); text-decoration: none; }
a:hover, a:focus { text-decoration: underline; }
img, video, iframe, embed, object { max-width: 100%; }
img { height: auto; display: block; }
iframe, embed, object { width: 100%; }

.container {
    width: min(1120px, calc(100% - 32px));
    margin-inline: auto;
}

.screen-reader-text,
.skip-link {
    position: absolute;
    left: -9999px;
}
.skip-link:focus {
    left: 16px;
    top: 16px;
    z-index: 9999;
    padding: 10px 14px;
    background: var(--bf-text);
    color: #fff;
    border-radius: 8px;
}

.site-header {
    width: 100%;
    margin: 0;
    padding: 0;
    background: #ffffff;
    border-bottom: 1px solid var(--bf-border);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    pointer-events: auto;
}
.admin-bar .site-header { top: 32px; }
.site-header > .container {
    width: 100%;
    max-width: none;
    margin: 0;
}
.header-inner {
    min-height: 70px;
    display: flex;
    position: relative;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}
.header-top-box {
    width: 100%;
    margin: 0;
    padding: 10px clamp(16px, 3vw, 34px);
    background: #ffffff;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    backdrop-filter: none;
    pointer-events: auto;
}
.site-branding {
    display: flex;
    flex: 0 1 auto;
    align-items: center;
    gap: 10px;
    min-width: 0;
    max-width: 300px;
}
.site-branding-text { min-width: 0; }
.custom-logo-link { display: inline-flex; flex: 0 0 auto; max-width: 148px; }
.custom-logo-link img { max-height: 46px; width: auto; }
.site-title { margin: 0; font-size: 1.18rem; font-weight: 800; line-height: 1.2; overflow-wrap: anywhere; }
.site-title a { color: var(--bf-text); }
.site-title a:hover { text-decoration: none; color: var(--bf-accent); }
.site-description { margin: 0; color: var(--bf-muted); font-size: 0.82rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.main-navigation { flex: 1 1 auto; min-width: 0; }
.main-navigation ul { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin: 0; padding: 0; }
.main-navigation a {
    display: block;
    padding: 9px 11px;
    border-radius: 999px;
    color: var(--bf-text);
    font-weight: 700;
    font-size: .94rem;
    white-space: nowrap;
}
.main-navigation a:hover,
.main-navigation .current-menu-item > a { background: rgba(37, 99, 235, 0.09); color: var(--bf-accent); text-decoration: none; }
.menu-toggle { display: none; }
.header-search {
    flex: 0 0 235px;
    min-width: 180px;
    max-width: 260px;
}
.header-search .search-form {
    height: 44px;
    gap: 0;
    align-items: center;
    padding: 3px;
    border: 1px solid var(--bf-border);
    border-radius: 999px;
    background: #f8fafc;
}
.header-search .search-form label {
    min-width: 0;
}
.header-search .search-form input[type="search"] {
    height: 36px;
    padding: 8px 10px 8px 14px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    outline: 0;
}
.header-search .search-submit {
    flex: 0 0 38px;
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}
.header-search .search-submit svg { display: block; }


/* Unified top header layout: desktop now matches mobile placement. */
.header-inner {
    justify-content: flex-start;
    flex-wrap: nowrap;
}
.menu-toggle {
    order: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 42px;
    width: 42px;
    height: 42px;
    max-width: 42px;
    margin: 0;
    padding: 0;
    border-radius: 999px;
    color: var(--bf-text);
    background: #f8fafc;
    border: 1px solid var(--bf-border);
    line-height: 1;
    white-space: nowrap;
}
.menu-toggle:hover,
.menu-toggle:focus {
    color: var(--bf-accent);
    background: #eef4ff;
}
.menu-toggle-icon { display: block; }
.site-branding {
    order: 2;
    flex: 1 1 auto;
    max-width: none;
}
.header-search {
    order: 3;
    flex: 0 0 clamp(220px, 22vw, 300px);
    width: clamp(220px, 22vw, 300px);
    max-width: clamp(220px, 22vw, 300px);
    min-width: 0;
    margin-left: auto;
}
.main-navigation {
    order: 4;
    display: none;
    position: fixed;
    left: clamp(16px, 3vw, 34px);
    top: 76px;
    width: min(320px, calc(100% - 32px));
    min-width: 0;
    background: #ffffff;
    border: 1px solid var(--bf-border);
    border-radius: 16px;
    padding: 12px;
    box-shadow: var(--bf-shadow);
    overflow: hidden;
    z-index: 10000;
}
.admin-bar .main-navigation { top: 108px; }
.main-navigation.is-open { display: block; }
.main-navigation ul {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    flex-wrap: nowrap;
    gap: 4px;
}
.main-navigation a {
    padding: 10px 12px;
    border-radius: 12px;
    white-space: normal;
}

.hero-section {
    padding: 72px 0 48px;
    background: radial-gradient(circle at 20% 20%, rgba(37,99,235,.14), transparent 32%), linear-gradient(135deg, #fff, #eef4ff);
    border-bottom: 1px solid var(--bf-border);
}
.hero-inner { max-width: 820px; text-align: center; }
.hero-kicker {
    display: inline-flex;
    margin: 0 0 12px;
    color: var(--bf-accent);
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
    font-size: .78rem;
}
.hero-inner h2 { margin: 0 0 14px; font-size: clamp(2rem, 5vw, 4rem); line-height: 1.05; }
.hero-inner p:not(.hero-kicker) { margin: 0 auto; max-width: 680px; color: var(--bf-muted); font-size: 1.13rem; }

.site-main { padding: 44px 0; }
.has-sidebar { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 32px; align-items: start; }
.no-sidebar .content-area { max-width: 1040px; margin-inline: auto; }
.post-grid { display: grid; grid-template-columns: 1fr; gap: 0; }

.card {
    background: var(--bf-surface);
    border: 1px solid var(--bf-border);
    border-radius: var(--bf-radius);
    box-shadow: var(--bf-shadow);
    overflow: hidden;
}
.post-card {
    display: grid;
    grid-template-columns: minmax(260px, 34%) minmax(0, 1fr);
    align-items: center;
    column-gap: 22px;
    min-height: 0;
}
.post-card.no-thumbnail { grid-template-columns: 1fr; }
.landscape-list-card.card {
    background: transparent;
    border: 0;
    border-bottom: 1px solid var(--bf-border);
    border-radius: 0;
    box-shadow: none;
    overflow: visible;
    padding: 18px 0;
}
.post-thumbnail {
    background: #eef2f7;
    display: block;
    aspect-ratio: 16 / 9;
    height: auto;
    margin: 0;
    border-radius: 12px;
    overflow: hidden;
}
.post-thumbnail img {
    width: 100%;
    height: 100%;
    min-height: 100%;
    max-height: none;
    object-fit: cover;
}
.post-card-body { padding: 0; min-width: 0; }
.entry-title { margin: 0 0 10px; line-height: 1.25; font-size: clamp(1.15rem, 1.8vw, 1.55rem); overflow-wrap: anywhere; }
.entry-title a { color: var(--bf-text); }
.entry-title a:hover { color: var(--bf-accent); text-decoration: none; }
.entry-meta { display: flex; flex-wrap: wrap; gap: 8px; color: var(--bf-muted); font-size: .88rem; margin-bottom: 8px; }
.updated:not(.published) { display: none; }
.entry-summary p { margin: 0; color: #374151; overflow-wrap: anywhere; }
.read-more {
    display: inline-flex;
    align-items: center;
    padding: 9px 14px;
    border-radius: 999px;
    background: var(--bf-accent);
    color: #fff;
    font-weight: 700;
}
.read-more:hover { opacity: .92; text-decoration: none; }

.widget-area { display: grid; gap: 20px; }
.widget {
    background: #fff;
    border: 1px solid var(--bf-border);
    border-radius: var(--bf-radius);
    padding: 22px;
    box-shadow: var(--bf-shadow);
}
.widget-title { margin-top: 0; font-size: 1.05rem; }
.widget ul { margin-bottom: 0; padding-left: 20px; }

.single-post-card,
.page-card { padding: clamp(24px, 4vw, 44px); }
/* Single article and single page: blend the body with the page background so content does not look boxed. */
body.single-post,
body.page {
    background: var(--bf-surface);
}
body.single-post .single-layout,
body.page .single-layout,
body.page .page-layout {
    background: transparent;
}
body.single-post .single-post-card.card,
body.page .single-post-card.card,
body.page .page-card.card {
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    overflow: visible;
}
body.single-post .single-thumbnail,
body.page .single-thumbnail {
    margin: 0 0 28px;
}
body.single-post .single-thumbnail img,
body.page .single-thumbnail img {
    border-radius: 14px;
}

/* Single post/page focus layout: no sidebar/search area, content centered and blended with background. */
body.single-post .single-focus-layout,
body.page .single-focus-layout {
    display: block;
}
body.single-post .single-focus-layout .content-area,
body.page .single-focus-layout .content-area {
    max-width: 860px;
    margin-left: auto;
    margin-right: auto;
}
body.single-post .comments-area.card,
body.page .comments-area.card,
body.single-post .post-navigation .nav-links a,
body.page .post-navigation .nav-links a {
    background: transparent;
    box-shadow: none;
}
body.single-post .comments-area.card,
body.page .comments-area.card {
    border: 0;
    border-radius: 0;
    padding-left: 0;
    padding-right: 0;
}

.single-header { margin-bottom: 24px; }
.single-thumbnail { margin: 0 -44px 28px; }
.single-thumbnail img { width: 100%; border-radius: 0; }
.entry-content { font-size: 1.06rem; overflow-wrap: anywhere; max-width: 100%; }
.entry-content > *,
.entry-summary > *,
.widget > * { max-width: 100%; }
.entry-content .alignwide,
.entry-content .alignfull { width: 100%; max-width: 100%; margin-left: 0; margin-right: 0; }
.entry-content table,
.wp-block-table,
pre { max-width: 100%; overflow-x: auto; }
pre { white-space: pre-wrap; word-break: break-word; }
.entry-content h2, .entry-content h3 { line-height: 1.25; margin-top: 1.8em; }
.entry-content p { margin: 0 0 1.2em; }
.entry-content blockquote { margin: 1.5em 0; padding: 1px 0 1px 22px; border-left: 4px solid var(--bf-accent); color: #374151; }

.blogfree-social-share {
    margin-top: 30px;
    padding-top: 22px;
    border-top: 1px solid var(--bf-border);
}
.blogfree-social-share-title {
    margin: 0 0 12px;
    color: var(--bf-muted);
    font-size: .92rem;
    font-weight: 700;
    letter-spacing: .01em;
}
.blogfree-social-share-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.blogfree-social-share-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border: 1px solid var(--bf-border);
    border-radius: 999px;
    background: var(--bf-surface);
    color: var(--bf-text);
    line-height: 1;
}
.blogfree-social-share-link svg {
    width: 18px;
    height: 18px;
    display: block;
    fill: currentColor;
}
.blogfree-social-share-link:hover,
.blogfree-social-share-link:focus {
    border-color: var(--bf-accent);
    color: var(--bf-accent);
    text-decoration: none;
    transform: translateY(-1px);
}


.blogfree-author-box {
    display: grid;
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 16px;
    align-items: start;
    margin-top: 28px;
    padding-top: 24px;
    border-top: 1px solid var(--bf-border);
}
.blogfree-author-avatar img {
    width: 72px;
    height: 72px;
    border-radius: 999px;
}
.blogfree-section-eyebrow {
    margin: 0 0 4px;
    color: var(--bf-muted);
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.blogfree-author-name {
    margin: 0 0 8px;
    font-size: 1.15rem;
    line-height: 1.3;
}
.blogfree-author-name a {
    color: var(--bf-text);
}
.blogfree-author-name a:hover {
    color: var(--bf-accent);
    text-decoration: none;
}
.blogfree-author-description {
    color: #374151;
    font-size: .96rem;
    line-height: 1.75;
}
.blogfree-author-description p {
    margin: 0 0 0.95em;
}
.blogfree-author-description p:last-child {
    margin-bottom: 0;
}
.blogfree-author-description br {
    display: block;
    content: "";
    margin-bottom: .45em;
}
.blogfree-related-posts {
    margin-top: 30px;
    padding-top: 24px;
    border-top: 1px solid var(--bf-border);
}
.blogfree-related-header {
    margin-bottom: 14px;
}
.blogfree-related-header h2 {
    margin: 0;
    font-size: 1.25rem;
    line-height: 1.3;
}
.blogfree-related-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}
.blogfree-related-card {
    min-width: 0;
}
.blogfree-related-thumb {
    display: block;
    border-radius: 12px;
    overflow: hidden;
    background: #eef2f7;
    aspect-ratio: 16 / 9;
}
.blogfree-related-thumb img,
.blogfree-related-thumb-placeholder {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}
.blogfree-related-title {
    margin: 10px 0 0;
    font-size: .98rem;
    line-height: 1.35;
}
.blogfree-related-title a {
    color: var(--bf-text);
}
.blogfree-related-title a:hover {
    color: var(--bf-accent);
    text-decoration: none;
}

.entry-footer { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 10px; color: var(--bf-muted); }
.entry-footer span { display: inline-flex; gap: 6px; }

.navigation.posts-navigation,
.pagination,
.post-navigation { margin-top: 28px; }
.nav-links { display: flex; justify-content: space-between; gap: 16px; max-width: 100%; min-width: 0; }
.page-numbers,
.nav-links a {
    display: inline-flex;
    max-width: 100%;
    overflow-wrap: anywhere;
    padding: 10px 14px;
    background: #fff;
    border: 1px solid var(--bf-border);
    border-radius: 999px;
}
.page-numbers.current { background: var(--bf-accent); color: #fff; border-color: var(--bf-accent); }

.comments-area { margin-top: 28px; padding: 28px; }
.comment-list { padding-left: 20px; }
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea,
.search-form input[type="search"] {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--bf-border);
    border-radius: 12px;
    font: inherit;
}
.search-form { display: flex; gap: 8px; min-width: 0; }
.search-form label { flex: 1; min-width: 0; }
button,
input[type="submit"],
.search-submit {
    border: 0;
    border-radius: 999px;
    padding: 12px 18px;
    background: var(--bf-accent);
    color: #fff;
    font-weight: 800;
    cursor: pointer;
}

.archive-header { margin-bottom: 24px; }
.archive-header .page-title { margin: 0 0 8px; }
.archive-description { color: var(--bf-muted); }

.site-footer {
    margin-top: 20px;
    background: #0f172a;
    color: #d1d5db;
    padding: 36px 0 26px;
}
.site-footer a { color: #fff; }
.footer-widgets { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin-bottom: 28px; }
.footer-widget { background: rgba(255,255,255,.05); border-color: rgba(255,255,255,.12); box-shadow: none; }
.footer-bottom { display: flex; justify-content: center; gap: 18px; align-items: center; text-align: center; }
.footer-pages-bottom { padding-top: 2px; }
.footer-navigation { margin: 0 auto; max-width: 100%; width: 100%; }
.footer-menu,
.footer-navigation ul { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 18px; margin: 0; padding: 0; }
.footer-menu li,
.footer-navigation li { position: relative; }
.footer-menu a,
.footer-navigation a { display: inline-flex; align-items: center; gap: 6px; font-weight: 400; line-height: 1.35; opacity: .94; text-decoration: none; }
.footer-menu a:hover,
.footer-navigation a:hover { opacity: 1; text-decoration: underline; }
.footer-menu .children,
.footer-menu .sub-menu,
.footer-navigation .children,
.footer-navigation .sub-menu { flex-basis: 100%; display: flex; flex-direction: column; align-items: center; gap: 5px; margin: 4px 0 0; padding: 0; font-size: .9rem; opacity: .84; }
.footer-menu .children a,
.footer-menu .sub-menu a,
.footer-navigation .children a,
.footer-navigation .sub-menu a { font-weight: 400; color: #d1d5db; }

.footer-copyright-bottom {
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid rgba(255,255,255,.16);
    text-align: center;
    color: #cbd5e1;
    font-size: .92rem;
}
.footer-copyright-bottom p {
    margin: 0;
}



@media (max-width: 1040px) and (min-width: 721px) {
    .header-inner { gap: 12px; }
    .site-branding { max-width: none; }
    .site-description { display: none; }
    .main-navigation a { font-size: .9rem; }
    .header-search { flex: 0 0 clamp(190px, 24vw, 260px); width: clamp(190px, 24vw, 260px); max-width: clamp(190px, 24vw, 260px); min-width: 0; }
}

@media (max-width: 900px) {
    .has-sidebar { grid-template-columns: 1fr; }
    .footer-widgets { grid-template-columns: 1fr; }
}


@media (max-width: 782px) {
    .admin-bar .site-header { top: 46px; }
}

@media (max-width: 720px) {
    html,
    body {
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }
    body {
        padding-top: 58px;
    }

    .container {
        width: calc(100% - 12px);
        max-width: calc(100% - 12px);
        margin-left: auto;
        margin-right: auto;
    }

    .site-header {
        padding: 0;
        position: fixed;
        top: 0;
    }
    .admin-bar .site-header { top: 46px; }
    .site-header > .container {
        width: 100%;
        max-width: none;
    }

    .header-inner {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        flex-wrap: nowrap;
        padding: 7px 8px;
        gap: 8px;
        width: 100%;
        min-height: 58px;
        min-width: 0;
    }
    .header-top-box {
        border-radius: 0;
        box-shadow: none;
    }

    .menu-toggle {
        order: 1;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        flex: 0 0 40px;
        width: 40px;
        height: 40px;
        max-width: 40px;
        margin: 0;
        padding: 0;
        border-radius: 999px;
        color: var(--bf-text);
        background: #f8fafc;
        border: 1px solid var(--bf-border);
        line-height: 1;
        white-space: nowrap;
    }
    .menu-toggle:hover,
    .menu-toggle:focus {
        color: var(--bf-accent);
        background: #eef4ff;
    }
    .menu-toggle-icon { display: block; }

    .site-branding {
        order: 2;
        flex: 1 1 auto;
        min-width: 0;
        max-width: none;
        gap: 7px;
    }
    .custom-logo-link { max-width: 104px; }
    .custom-logo-link img { max-height: 34px; }
    .site-title {
        font-size: .98rem;
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
    .site-description { display: none; }

    .header-search {
        order: 3;
        flex: 0 0 clamp(112px, 34vw, 158px);
        width: clamp(112px, 34vw, 158px);
        max-width: clamp(112px, 34vw, 158px);
        min-width: 0;
        margin-left: auto;
    }
    .header-search .search-form {
        height: 38px;
        width: 100%;
        min-width: 0;
        flex-direction: row;
        align-items: center;
        padding: 2px;
    }
    .header-search .search-form label {
        min-width: 0;
        flex: 1 1 auto;
    }
    .header-search .search-form input[type="search"] {
        height: 32px;
        min-width: 0;
        width: 100%;
        padding: 7px 6px 7px 10px;
        font-size: .86rem;
    }
    .header-search .search-submit {
        width: 32px;
        height: 32px;
        flex: 0 0 32px;
    }

    .main-navigation {
        display: none;
        position: fixed;
        left: 8px;
        right: 8px;
        top: 64px;
        max-width: calc(100% - 16px);
        background: #fff;
        border: 1px solid var(--bf-border);
        border-radius: 16px;
        padding: 12px;
        box-shadow: var(--bf-shadow);
        overflow: hidden;
        z-index: 10000;
    }
    .admin-bar .main-navigation { top: 110px; }
    .main-navigation.is-open { display: block; }
    .main-navigation ul {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        min-width: 0;
    }
    .main-navigation li,
    .main-navigation a {
        max-width: 100%;
        min-width: 0;
        overflow-wrap: anywhere;
        white-space: normal;
    }


    .hero-section { padding: 34px 0 26px; }
    .hero-inner h2 { font-size: 1.75rem; }
    .hero-inner p:not(.hero-kicker) { font-size: .98rem; }

    .site-main { padding: 24px 0; }
    .post-grid {
        grid-template-columns: minmax(0, 1fr);
        width: 100%;
        max-width: 100%;
    }
    .post-card {
        grid-template-columns: minmax(0, 1fr);
        min-height: 0;
        row-gap: 12px;
        width: 100%;
        max-width: 100%;
        min-width: 0;
        overflow: hidden;
    }
    .landscape-list-card.card { padding: 14px 0; }
    .post-thumbnail {
        width: 100%;
        max-width: 100%;
    }
    .post-thumbnail img { width: 100%; }
    .post-content {
        min-width: 0;
        max-width: 100%;
    }
    .post-title { font-size: 1.22rem; }
    .entry-summary,
    .entry-content,
    .post-content,
    .single-post-card,
    .page-card,
    .comments-area,
    .widget {
        overflow-wrap: anywhere;
        word-break: normal;
    }
    .content-area,
    .site-main,
    .has-sidebar,
    .no-sidebar,
    .single-layout,
    .page-layout,
    .sidebar,
    .post-grid,
    .card,
    .widget,
    .entry-content,
    .entry-summary {
        max-width: 100%;
        min-width: 0;
    }
    .entry-content table,
    .entry-content pre {
        display: block;
        max-width: 100%;
        overflow-x: auto;
    }
    .entry-content img,
    .entry-content iframe,
    .entry-content embed,
    .entry-content object {
        max-width: 100%;
    }
    .single-post-card,
    .page-card { padding: 22px 14px; }
    .single-post-card .entry-title { font-size: 1.85rem; }
    .blogfree-share-links {
        justify-content: flex-start;
        gap: 8px;
    }
    .blogfree-share-link {
        width: 34px;
        height: 34px;
    }
    .blogfree-author-box {
        grid-template-columns: 54px minmax(0, 1fr);
        padding: 16px 0;
        gap: 12px;
    }
    .blogfree-author-avatar img {
        width: 54px;
        height: 54px;
    }
    .blogfree-related-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 0;
    }
    .blogfree-related-card {
        display: grid;
        grid-template-columns: 112px minmax(0, 1fr);
        gap: 12px;
        align-items: center;
    }
    .blogfree-related-thumb {
        border-radius: 10px;
    }
    .blogfree-related-title {
        margin-top: 0;
        font-size: .95rem;
    }
    .nav-links { flex-direction: column; }
    .footer-bottom { flex-direction: column; align-items: flex-start; }
    .footer-navigation,
    .footer-navigation ul {
        width: 100%;
        max-width: 100%;
        flex-wrap: wrap;
    }
    button,
    input,
    textarea,
    select { max-width: 100%; }

}

/* Mobile header: keep compact search on the right side only, not crossing the header center. */
@media (max-width: 720px) {
    .site-branding {
        flex: 1 1 0;
        min-width: 0;
        max-width: none;
    }
    .header-search {
        flex: 0 0 clamp(96px, 30vw, 132px);
        width: clamp(96px, 30vw, 132px);
        max-width: clamp(96px, 30vw, 132px);
        min-width: 0;
        margin-left: auto;
    }
    .header-search .search-form {
        width: 100%;
        max-width: 100%;
    }
    .header-search .search-form input[type="search"] {
        min-width: 0;
        width: 100%;
        padding-left: 8px;
        padding-right: 4px;
    }
}

@media (max-width: 380px) {
    body { padding-top: 56px; }
    .container {
        width: calc(100% - 8px);
        max-width: calc(100% - 8px);
    }
    .header-inner { gap: 6px; padding-inline: 6px; }
    .menu-toggle {
        flex-basis: 38px;
        width: 38px;
        height: 38px;
        max-width: 38px;
    }
    .site-title { font-size: .92rem; }
    .custom-logo-link { max-width: 88px; }
    .custom-logo-link img { max-height: 30px; }
    .header-search {
        flex-basis: 106px;
        width: 106px;
        max-width: 106px;
    }
    .header-search .search-form { height: 36px; }
    .header-search .search-form input[type="search"] {
        height: 30px;
        padding-inline: 8px 4px;
        font-size: .78rem;
    }
    .header-search .search-submit {
        width: 30px;
        height: 30px;
        flex-basis: 30px;
    }
    .main-navigation {
        left: 4px;
        right: 4px;
        top: 62px;
        max-width: calc(100% - 8px);
    }
    .admin-bar .main-navigation { top: 108px; }
    .single-post-card,
    .page-card,
    .comments-area,
    .widget { padding: 14px; }
}


/* Parent-child menu support: collapsed until the parent is clicked. */
.main-navigation li {
    position: relative;
}
.main-navigation .menu-item-has-children > a,
.main-navigation .page_item_has_children > a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}
.main-navigation .menu-item-has-children > a::after,
.main-navigation .page_item_has_children > a::after {
    content: "▾";
    display: inline-block;
    margin-left: 6px;
    font-size: .72em;
    color: var(--bf-muted);
    vertical-align: middle;
    transition: transform .18s ease;
}
.main-navigation .menu-item-has-children.is-submenu-open > a::after,
.main-navigation .page_item_has_children.is-submenu-open > a::after {
    transform: rotate(180deg);
}
.main-navigation .sub-menu,
.main-navigation .children {
    display: none;
    flex-direction: column;
    gap: 3px;
    width: 100%;
    margin: 4px 0 6px 14px;
    padding: 0 0 0 12px;
    border-left: 1px solid var(--bf-border);
    list-style: none;
}
.main-navigation .menu-item-has-children.is-submenu-open > .sub-menu,
.main-navigation .page_item_has_children.is-submenu-open > .children {
    display: flex;
}
.main-navigation .sub-menu .sub-menu,
.main-navigation .children .children {
    margin-left: 12px;
}
.main-navigation .sub-menu a,
.main-navigation .children a {
    font-size: .88rem;
    font-weight: 600;
    padding: 8px 10px;
    color: var(--bf-muted);
    background: transparent;
}
.main-navigation .sub-menu a:hover,
.main-navigation .children a:hover,
.main-navigation .sub-menu .current-menu-item > a,
.main-navigation .children .current-menu-item > a {
    color: var(--bf-accent);
    background: rgba(37, 99, 235, 0.08);
}
.main-navigation .current-menu-ancestor > .sub-menu,
.main-navigation .current-menu-parent > .sub-menu,
.main-navigation .current_page_ancestor > .children,
.main-navigation .current_page_parent > .children {
    display: flex;
}
.main-navigation .current-menu-ancestor,
.main-navigation .current-menu-parent,
.main-navigation .current_page_ancestor,
.main-navigation .current_page_parent {
    /* Keep the active path visible even before JavaScript runs. */
}

@media (max-width: 720px) {
    .main-navigation .sub-menu,
    .main-navigation .children {
        margin-left: 10px;
        padding-left: 10px;
    }
    .main-navigation .sub-menu a,
    .main-navigation .children a {
        font-size: .86rem;
        padding: 8px 10px;
    }
}


/* Search form without submit button: users can press Enter in the field. */
.search-form .search-submit {
    display: none;
}
.header-search .search-form {
    padding: 3px 8px;
}
.header-search .search-form label {
    flex: 1 1 100%;
    width: 100%;
}
.header-search .search-form input[type="search"] {
    width: 100%;
}
@media (max-width: 720px) {
    .header-search .search-form {
        padding: 2px 6px;
    }
    .header-search .search-form input[type="search"] {
        padding-right: 8px;
    }
}


/* Robust top menu toggle: keep the dropdown hidden until the menu button is clicked. */
#site-navigation.main-navigation {
    transition: opacity .16s ease, transform .16s ease;
}
#site-navigation.main-navigation.is-open,
body.blogfree-menu-open #site-navigation.main-navigation,
.menu-toggle[aria-expanded="true"] + #site-navigation.main-navigation {
    display: block !important;
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}
#blogfree-menu-toggle[aria-expanded="true"] {
    color: var(--bf-accent);
    background: #eef4ff;
}
.primary-menu.page-menu-fallback {
    margin: 0;
    padding: 0;
}
