.article-mobile-contact { display: none; }

@media (max-width: 992px) {
    body.has-mobile-contact {
        --article-contact-space: calc(80px + env(safe-area-inset-bottom, 0px));
        padding-bottom: var(--article-contact-space);
    }
    .article-mobile-contact {
        position: fixed;
        inset: auto 0 0;
        z-index: 1100;
        display: flex;
        gap: 8px;
        padding: 12px 12px calc(12px + env(safe-area-inset-bottom, 0px));
        background: #fff;
        border-top: 1px solid #dce6e5;
        box-shadow: 0 -4px 20px rgba(0, 0, 0, .12);
    }
    .article-mobile-contact > a,
    .article-mobile-contact > button {
        box-sizing: border-box;
        display: flex;
        flex: 1;
        align-items: center;
        justify-content: center;
        gap: 7px;
        min-width: 0;
        min-height: 52px;
        margin: 0;
        padding: 10px 8px;
        border: 2px solid var(--primary-blue, #447196);
        border-radius: 40px;
        font-family: inherit;
        font-size: 15px;
        font-weight: 700;
        line-height: 1.25;
        text-align: center;
        text-decoration: none;
        cursor: pointer;
    }
    .article-mobile-contact__call { background: var(--primary-blue, #447196); color: #fff; }
    .article-mobile-contact__doctor { background: #fff; color: var(--primary-blue, #447196); }
    .article-mobile-contact > :hover { background: #365e80; border-color: #365e80; color: #fff; }
    .article-mobile-contact > :focus-visible { outline: 3px solid var(--primary-red, #F45349); outline-offset: 2px; }
    .article-mobile-contact svg { flex-shrink: 0; }
    body.has-mobile-contact #cookie-notice { bottom: var(--article-contact-space); }
    body.has-mobile-contact.modal-open .article-mobile-contact { visibility: hidden; }
    body.has-mobile-contact.menu-open .article-mobile-contact { visibility: hidden; }
}

/* Article layout, including tablet and landscape screens. Higher specificity
   keeps these rules effective after the template's inline stylesheet. */
@media (max-width: 992px) {
    main.single-post .post-container,
    main.single-post .post-hero-content { box-sizing: border-box; width: 100%; margin-left: auto; margin-right: auto; padding-left: 16px; padding-right: 16px; }
    main.single-post .post-layout { grid-template-columns: minmax(0, 1fr); }
    main.single-post .post-layout > *,
    main.single-post .post-body { min-width: 0; }
    main.single-post .post-title,
    main.single-post .post-body,
    main.single-post .post-breadcrumbs,
    main.single-post .post-toc { overflow-wrap: anywhere; }
    main.single-post .post-body { font-size: 16px; line-height: 1.75; }
    main.single-post .post-body h2 { font-size: 1.4rem; }
    main.single-post .post-body h3 { font-size: 1.15rem; }
    main.single-post .post-body table { display: block; max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
    main.single-post .post-body pre { max-width: 100%; overflow-x: auto; }
    main.single-post .post-body iframe,
    main.single-post .post-body video { max-width: 100%; }
    main.single-post .post-body figure { max-width: 100%; margin-left: 0; margin-right: 0; }
    main.single-post .post-help-btn { box-sizing: border-box; }
    body.single-post .header_mobile_logo { min-width: 0; max-width: calc(100% - 56px); }
    body.single-post .header_mobile_logo img { max-width: 100%; height: auto; }
    body.single-post .header_mobile_toggle { flex-shrink: 0; width: 44px; height: 44px; padding: 11px 8px; }
    body.single-post #cookie-notice { box-sizing: border-box; max-height: 50vh; max-height: 50dvh; overflow-y: auto; }
    body.single-post .modal-overlay { box-sizing: border-box; padding: 12px; }
    body.single-post .modal-container { box-sizing: border-box; margin: 0; max-height: calc(100vh - 24px); max-height: calc(100dvh - 24px); }
    body.single-post .modal-content input,
    body.single-post .modal-content select,
    body.single-post .modal-content textarea { box-sizing: border-box; max-width: 100%; font-size: 16px; }
}

/* Older articles store card grids directly in the editor's HTML. Inline
   column counts need an explicit override on narrow screens. */
@media (max-width: 600px) {
    main.single-post .post-body [style*="grid-template-columns" i] {
        grid-template-columns: minmax(0, 1fr) !important;
        gap: 14px !important;
    }
    main.single-post .post-body [style*="grid-template-columns" i] > * {
        box-sizing: border-box;
        min-width: 0 !important;
        max-width: 100%;
        grid-column: auto !important;
        grid-row: auto !important;
    }
    main.single-post .post-body .wp-block-columns {
        flex-direction: column;
        flex-wrap: wrap !important;
    }
    main.single-post .post-body .wp-block-columns > .wp-block-column {
        flex-basis: 100% !important;
        min-width: 0;
    }
}
