/* Narrow, reversible mobile-only patch. The existing header/nav and desktop layout are untouched. */
#afmc-mobile-search-fix,
#afmc-mobile-search-fix[hidden] {
    display: none !important;
}
@media screen and (max-width: 768px) {
    #afmc-mobile-search-fix:not([hidden]) {
        display: block !important;
        position: relative;
        z-index: 2;
        box-sizing: border-box;
        width: 100%;
        padding: 10px 15px;
        background: #fff;
        border-bottom: 1px solid #dedede;
    }
    #afmc-mobile-search-fix *,
    #afmc-mobile-search-fix *::before,
    #afmc-mobile-search-fix *::after {
        box-sizing: border-box;
    }
    #afmc-mobile-search-fix .afmc-mobile-search-fix__inner {
        width: 100%;
        max-width: 1180px;
        margin: 0 auto;
    }
    #afmc-mobile-search-fix .afmc-mobile-search-fix__form {
        display: flex;
        gap: 0;
        align-items: stretch;
        width: 100%;
        margin: 0;
        padding: 0;
    }
    #afmc-mobile-search-fix input[type="search"] {
        display: block;
        flex: 1 1 auto;
        width: 100%;
        min-width: 0;
        height: 44px;
        margin: 0;
        padding: 9px 12px;
        font-family: inherit;
        font-size: 16px;
        line-height: 24px;
        font-weight: 400;
        color: #222;
        background: #fff;
        border: 1px solid #a4a4a4;
        border-radius: 4px 0 0 4px;
        outline-offset: 2px;
        appearance: none;
        -webkit-appearance: none;
    }
    #afmc-mobile-search-fix button[type="submit"] {
        display: block;
        flex: 0 0 auto;
        width: auto;
        min-width: 72px;
        height: 44px;
        margin: 0;
        padding: 8px 12px;
        font-family: inherit;
        font-size: 14px;
        line-height: 26px;
        color: #fff;
        background: #333;
        border: 1px solid #333;
        border-radius: 0 4px 4px 0;
        cursor: pointer;
        -webkit-appearance: none;
    }
    #afmc-mobile-search-fix button[type="submit"]:focus-visible,
    #afmc-mobile-search-fix input[type="search"]:focus-visible {
        outline: 2px solid #0066aa;
        outline-offset: 2px;
    }
    #afmc-mobile-search-fix .afmc-mobile-search-fix__sr-only {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }
}
