.search-box-wrapper{
    width: 100%;
}

/* Search location picker — authoritative component styles. */
.search-box-wrapper .search-primary-fields{
    display:grid!important;
    grid-template-columns:minmax(180px,1fr) 190px 190px 44px!important;
    grid-template-rows:44px!important;
    align-items:stretch!important;
    gap:0!important;
    overflow:hidden!important;
    border:1px solid rgba(100,116,139,.24)!important;
    border-radius:12px!important;
    background:var(--bs-body-bg,#fff)!important;
    box-shadow:0 6px 20px rgba(15,23,42,.07)!important;
}
.search-box-wrapper .search-primary-fields:focus-within{
    border-color:rgba(100,116,139,.38)!important;
    box-shadow:0 7px 22px rgba(15,23,42,.09)!important;
}
.search-box-wrapper .search-primary-query{
    grid-column:1!important;
    grid-row:1!important;
    width:100%!important;
    height:44px!important;
    min-width:0!important;
    padding:0 14px!important;
    border:0!important;
    background:transparent!important;
    box-shadow:none!important;
    font-size:.88rem!important;
    font-weight:500!important;
}
.search-box-wrapper .selectize-control.search-primary-country,
.search-box-wrapper .selectize-control.search-primary-region{
    position:relative!important;
    width:100%!important;
    height:44px!important;
    min-width:0!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
    box-shadow:none!important;
}
.search-box-wrapper .selectize-control.search-primary-country{grid-column:2!important;grid-row:1!important}
.search-box-wrapper .selectize-control.search-primary-region{grid-column:3!important;grid-row:1!important}
.search-box-wrapper .selectize-control.search-primary-country::before,
.search-box-wrapper .selectize-control.search-primary-region::before{
    content:"";
    position:absolute;
    z-index:2;
    left:0;
    top:9px;
    bottom:9px;
    width:1px;
    background:rgba(100,116,139,.24);
    pointer-events:none;
}
.search-box-wrapper .selectize-control .selectize-input,
.search-box-wrapper .selectize-control .selectize-input.focus,
.search-box-wrapper .selectize-control .selectize-input.dropdown-active{
    display:flex!important;
    align-items:center!important;
    width:100%!important;
    min-height:44px!important;
    height:44px!important;
    margin:0!important;
    padding:0 30px 0 13px!important;
    border:0!important;
    border-radius:0!important;
    outline:0!important;
    background:transparent!important;
    box-shadow:none!important;
    color:inherit!important;
    font-size:.8rem!important;
    font-weight:700!important;
    line-height:1.2!important;
}
.search-box-wrapper .selectize-control .selectize-input>div,
.search-box-wrapper .selectize-control .selectize-input>input{
    margin:0!important;
    padding:0!important;
    color:inherit!important;
    font-size:.8rem!important;
    font-weight:700!important;
    line-height:1.2!important;
}
.search-box-wrapper .selectize-control .selectize-input>input{width:100%!important;min-width:0!important}
.search-box-wrapper .selectize-control .selectize-input:after{right:12px!important}
.search-box-wrapper .search-primary-submit{
    grid-column:4!important;
    grid-row:1!important;
    width:44px!important;
    height:44px!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    border-left:1px solid rgba(100,116,139,.24)!important;
    border-radius:0!important;
    box-shadow:none!important;
}
body>.selectize-dropdown{
    z-index:1060!important;
    box-sizing:border-box!important;
    min-width:230px!important;
    margin-top:0!important;
    overflow:hidden!important;
    border:1px solid rgba(100,116,139,.2)!important;
    border-radius:0 0 10px 10px!important;
    background:var(--bs-body-bg,#fff)!important;
    box-shadow:0 16px 38px rgba(15,23,42,.16)!important;
}
body>.selectize-dropdown .selectize-dropdown-content{max-height:min(300px,52vh)!important;-webkit-overflow-scrolling:touch}
body>.selectize-dropdown .option{padding:9px 12px!important;font-size:.82rem!important;font-weight:600!important}
body>.selectize-dropdown .option.active{background:rgba(13,110,253,.09)!important;color:var(--primary,#0d6efd)!important}
@media(min-width:768px){
    .search-box-wrapper.search-box-compact .search-primary-fields{
        grid-template-columns:minmax(0,1fr) minmax(0,1fr) 44px!important;
        grid-template-rows:44px 42px!important;
        height:86px!important;
    }
    .search-box-wrapper.search-box-compact .search-primary-query{grid-column:1 / 3!important;grid-row:1!important;border-bottom:1px solid rgba(100,116,139,.2)!important}
    .search-box-wrapper.search-box-compact .selectize-control.search-primary-country{grid-column:1!important;grid-row:2!important;height:42px!important}
    .search-box-wrapper.search-box-compact .selectize-control.search-primary-region{grid-column:2!important;grid-row:2!important;height:42px!important}
    .search-box-wrapper.search-box-compact .selectize-control.search-primary-country::before{display:none!important}
    .search-box-wrapper.search-box-compact .selectize-control.search-primary-region::before{top:8px!important;bottom:8px!important}
    .search-box-wrapper.search-box-compact .selectize-control .selectize-input,
    .search-box-wrapper.search-box-compact .selectize-control .selectize-input.focus,
    .search-box-wrapper.search-box-compact .selectize-control .selectize-input.dropdown-active{min-height:42px!important;height:42px!important}
    .search-box-wrapper.search-box-compact .search-primary-submit{grid-column:3!important;grid-row:1 / 3!important;width:44px!important;height:auto!important}
}
@media(max-width:767.98px){
    .search-results-column>.search-page-primary-bar{
        position:relative!important;
        inset:auto!important;
        z-index:10!important;
        display:grid!important;
        grid-template-columns:minmax(0,1fr)!important;
        gap:0!important;
        width:100%!important;
        min-height:0!important;
        height:auto!important;
        padding:10px!important;
        overflow:visible!important;
        align-items:start!important;
    }
    .search-results-column>.search-page-primary-bar>.col{grid-column:1;min-width:0!important;width:100%!important;max-width:100%!important;padding:0!important}
    .search-results-column>.search-page-primary-bar .search-box-wrapper{display:block!important;width:100%!important;height:auto!important;min-height:0!important;overflow:visible!important}
    .search-box-wrapper .search-primary-fields{
        grid-template-columns:minmax(0,1fr) minmax(0,1fr) 44px!important;
        grid-template-rows:44px 42px!important;
        width:100%!important;
        height:86px!important;
        min-height:86px!important;
        overflow:hidden!important;
    }
    .search-box-wrapper .search-primary-query{grid-column:1 / 3!important;grid-row:1!important;border-bottom:1px solid rgba(100,116,139,.2)!important}
    .search-box-wrapper .selectize-control.search-primary-country{grid-column:1!important;grid-row:2!important;height:42px!important}
    .search-box-wrapper .selectize-control.search-primary-region{grid-column:2!important;grid-row:2!important;height:42px!important}
    .search-box-wrapper .selectize-control.search-primary-country::before{display:none!important}
    .search-box-wrapper .selectize-control.search-primary-region::before{left:0!important;right:auto!important;top:8px!important;bottom:8px!important;width:1px!important;height:auto!important}
    .search-box-wrapper .selectize-control .selectize-input,
    .search-box-wrapper .selectize-control .selectize-input.focus,
    .search-box-wrapper .selectize-control .selectize-input.dropdown-active{min-height:42px!important;height:42px!important;padding-left:11px!important;font-size:.76rem!important}
    .search-box-wrapper .selectize-control .selectize-input>div,
    .search-box-wrapper .selectize-control .selectize-input>input{font-size:.76rem!important}
    .search-box-wrapper .search-primary-submit{grid-column:3!important;grid-row:1 / 3!important;width:44px!important;height:86px!important}
    body>.selectize-dropdown{min-width:0!important;box-sizing:border-box!important}
    body>.selectize-dropdown .selectize-dropdown-content{max-height:45vh!important}
    .search-results-column>.mobile-search-content-offset{padding-top:0!important}
    .search-box-wrapper .search-primary-query,
    .search-box-wrapper .selectize-control .selectize-input>input{
        font-size:16px!important;
    }
    .search-box-wrapper .selectize-control .selectize-input>div{font-size:.8rem!important}
}

/* Search form — dark theme. Selectize dropdowns are appended directly to body. */
.search-page-theme-dark .search-box-wrapper .search-primary-fields{
    border-color:rgba(255,255,255,.14)!important;
    background:rgba(36,36,38,.94)!important;
    box-shadow:0 6px 20px rgba(0,0,0,.2)!important;
}
.search-page-theme-dark .search-box-wrapper .search-primary-fields:focus-within{
    border-color:rgba(255,255,255,.25)!important;
    box-shadow:0 7px 22px rgba(0,0,0,.28)!important;
}
.search-page-theme-dark .search-box-wrapper .search-primary-query,
.search-page-theme-dark .search-box-wrapper .selectize-control .selectize-input,
.search-page-theme-dark .search-box-wrapper .selectize-control .selectize-input>div,
.search-page-theme-dark .search-box-wrapper .selectize-control .selectize-input>input,
.search-page-theme-dark .search-box-wrapper select.form-control{
    color:#f8fafc!important;
}
.search-page-theme-dark .search-box-wrapper .search-primary-query::placeholder,
.search-page-theme-dark .search-box-wrapper .selectize-control .selectize-input>input::placeholder{
    color:#aeb4bd!important;
    opacity:1!important;
}
.search-page-theme-dark .search-box-wrapper .selectize-control.search-primary-country::before,
.search-page-theme-dark .search-box-wrapper .selectize-control.search-primary-region::before,
.search-page-theme-dark .search-box-wrapper .search-primary-submit,
.search-page-theme-dark .search-box-wrapper.search-box-compact .search-primary-query,
.search-page-theme-dark .search-box-wrapper .search-primary-query{
    border-color:rgba(255,255,255,.14)!important;
}
.search-page-theme-dark .search-box-wrapper .selectize-control .selectize-input.focus,
.search-page-theme-dark .search-box-wrapper .selectize-control .selectize-input.dropdown-active{
    background:rgba(255,255,255,.06)!important;
}
body.search-page-theme-dark>.selectize-dropdown{
    border-color:rgba(255,255,255,.14)!important;
    background:rgba(36,36,38,.98)!important;
    color:#e5e7eb!important;
    box-shadow:0 16px 38px rgba(0,0,0,.42)!important;
}
body.search-page-theme-dark>.selectize-dropdown .option{
    color:#e5e7eb!important;
}
body.search-page-theme-dark>.selectize-dropdown .option.active,
body.search-page-theme-dark>.selectize-dropdown .option.selected{
    background:rgba(255,255,255,.1)!important;
    color:#fff!important;
}

.search-primary-fields{
    display:grid !important;
    grid-template-columns:minmax(180px,1fr) 190px 190px 44px;
    align-items:stretch;
    gap:0;
    overflow:hidden;
    border:1px solid rgba(127,127,127,.2);
    border-radius:14px;
    background:var(--bs-body-bg,#fff);
    box-shadow:0 8px 24px rgba(15,23,42,.07);
    transition: border-color .2s ease, box-shadow .2s ease;
}

.search-primary-fields:focus-within{
    border-color:rgba(127,127,127,.28);
    box-shadow:0 8px 24px rgba(15,23,42,.08);
}

.search-primary-fields .form-control{
    height:44px;
    border: 0 !important;
    border-radius: 0 !important;
    background-clip: padding-box;
    box-shadow: none !important;
}

.search-primary-fields .form-control:focus{
    box-shadow: none !important;
}

.search-primary-fields select.search-primary-country{
    flex: 0 0 180px;
    max-width: 180px;
    margin-left: 0 !important;
    border-left: 1px solid rgba(127, 127, 127, .42) !important;
    box-shadow: none !important;
    -webkit-appearance: none;
    appearance: none;
    padding-right: 2.65rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23777' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 16px 16px;
}

.search-primary-fields select.search-primary-region{
    flex: 0 0 170px;
    max-width: 170px;
    margin-left: 0 !important;
    border-left: 1px solid rgba(127, 127, 127, .42) !important;
    box-shadow: none !important;
    -webkit-appearance: none;
    appearance: none;
    padding-right: 2.4rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23777' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 13px center;
    background-size: 15px 15px;
}

.search-primary-fields select.search-primary-region:disabled{
    opacity: .62;
}

.search-primary-fields .selectize-control.search-primary-country,
.search-primary-fields .selectize-control.search-primary-region{
    width:100%;
    max-width:none;
    height:44px;
    margin:0;
    padding:0;
    border:0;
    background:none;
    box-shadow:none;
}
.search-primary-fields .selectize-control .selectize-input{
    display:flex;
    align-items:center;
    min-height:44px;
    height:44px;
    padding:10px 30px 10px 12px;
    border:0;
    border-radius:0;
    background:transparent;
    box-shadow:inset 1px 0 rgba(127,127,127,.22);
    color:inherit;
    font-size:.8rem;
    font-weight:700;
    white-space:nowrap;
}
.search-primary-fields .selectize-control .selectize-input>input{width:100%!important;font-size:.8rem;font-weight:700}
.search-primary-fields .selectize-control .selectize-input.focus,.search-primary-fields .selectize-control .selectize-input.dropdown-active{border:0!important;background:rgba(127,127,127,.045);box-shadow:inset 1px 0 rgba(127,127,127,.22)!important;outline:0!important}
.search-primary-fields .selectize-control .selectize-input>div{font-weight:700}
.search-primary-fields .selectize-dropdown{z-index:1055;min-width:210px}
.search-primary-fields .selectize-dropdown-content{max-height:260px}
body>.selectize-dropdown{z-index:1060;min-width:230px;max-height:min(340px,55vh);margin-top:5px;border:1px solid rgba(127,127,127,.18);border-radius:12px;background:var(--bs-body-bg,#fff);box-shadow:0 18px 42px rgba(15,23,42,.18);overflow:hidden}
body>.selectize-dropdown .selectize-dropdown-content{max-height:min(300px,52vh);-webkit-overflow-scrolling:touch}
body>.selectize-dropdown .option{padding:10px 12px;font-size:.82rem;font-weight:600}
body>.selectize-dropdown .option.active{background:rgba(13,110,253,.1);color:var(--primary,#0d6efd)}

.search-primary-query{
    min-width: 0;
    padding-left:14px;
    font-size:.9rem;
}

.search-primary-submit{
    flex: 0 0 auto;
    width:44px;
    height:44px;
    padding: 0;
    align-self: stretch;
    margin-left: 0 !important;
    border: 0;
    border-left: 1px solid rgba(0, 0, 0, .14);
    border-radius: 0 !important;
    box-shadow: none;
}

.search-box-compact .search-primary-fields{
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 38px;
}

.search-box-compact .search-primary-query{
    grid-column: 1 / 3;
    grid-row: 1;
}

.search-box-compact select.search-primary-country,
.search-box-compact select.search-primary-region{
    grid-row: 2;
    width: 100%;
    max-width: none;
    border-top: 1px solid rgba(127, 127, 127, .3) !important;
    font-size: .78rem;
}

.search-box-compact select.search-primary-country{
    grid-column: 1;
    border-left: 0 !important;
}

.search-box-compact select.search-primary-region{
    grid-column: 2;
}

.search-box-compact .search-primary-submit{
    grid-column: 3;
    grid-row: 1 / 3;
    width: 38px;
    height: auto;
}

.user-search-box-item{
    box-sizing: border-box;
    clear: both;
    display: block;
    width: 100%;
}

.users-wrapper{
    box-sizing: border-box;
    display: block;
    width: 100%;
}

.users-wrapper > .user-search-box-item > .d-flex{
    box-sizing: border-box;
    margin-left: 0;
    margin-right: 0;
    width: 100%;
}

.users-wrapper > .user-search-box-item > .d-flex > .col{
    min-width: 0;
}

.user-search-box-item .avatar{
    width: 54px;
    height: 54px;
}

.search-back-button{
    width: 40px;
    height: 40px;
}

.mobile-search-filter .card{
    border-left:none!important;
    border-right:none!important;
    border-top:none!important;
    border-radius: 0px!important;
}

.search-advanced-card{
    border: 1px solid rgba(127, 127, 127, .16) !important;
    border-radius: 12px !important;
    background: rgba(127, 127, 127, .035);
    box-shadow: 0 5px 18px rgba(0, 0, 0, .045);
}

.search-advanced-title{
    font-size: .82rem;
    font-weight: 700;
    letter-spacing: .01em;
}

.search-advanced-reset{
    color: var(--primary);
    font-size: .75rem;
    font-weight: 600;
}

.search-advanced-label{
    margin-bottom: .25rem;
    color: #6c757d;
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .035em;
    text-transform: uppercase;
}

.search-advanced-grid .form-control{
    height: 36px;
    border: 1px solid rgba(127, 127, 127, .22);
    border-radius: 9px;
    box-shadow: none;
    font-size: .85rem;
}

.search-advanced-grid .form-control:focus{
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(127, 127, 127, .1);
}

.search-advanced-grid select.form-control{
    -webkit-appearance: none;
    appearance: none;
    padding-right: 2.25rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23777' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right .75rem center;
    background-size: 14px 14px;
}

@media (max-width: 767.98px){
    .feed-mobile-search .search-back-button{
        width: 30px;
        height: 30px;
    }

    .feed-mobile-search .search-box-wrapper .input-group input.mobile-search-input{
        font-size: .9rem;
    }

    .search-primary-fields{
        grid-template-columns:minmax(0,1fr) minmax(0,1fr) 44px;
        grid-template-rows:44px 42px;
        gap:0;
        border-radius:12px;
    }

    .search-primary-query{grid-column:1 / 3;grid-row:1;border-bottom:1px solid rgba(127,127,127,.18)!important}

    .search-primary-fields select.search-primary-country{
        flex-basis: 30%;
        max-width: 30%;
        font-size: .8rem;
        padding-left: .45rem;
        padding-right: 2.2rem;
        background-position: right 10px center;
        background-size: 15px 15px;
        border-left-color: rgba(127, 127, 127, .46) !important;
    }

    .search-primary-fields select.search-primary-region{
        flex-basis: 30%;
        max-width: 30%;
        padding-left: .45rem;
        padding-right: 1.8rem;
        font-size: .8rem;
        background-position: right 8px center;
    }

    .search-primary-fields .selectize-control.search-primary-country,
    .search-primary-fields .selectize-control.search-primary-region{
        width:100%;
        min-width:0;
        max-width:none;
        height:42px;
    }
    .search-primary-fields .selectize-control.search-primary-country{grid-column:1;grid-row:2;border-left:0}
    .search-primary-fields .selectize-control.search-primary-region{grid-column:2;grid-row:2}
    .search-primary-fields .selectize-control .selectize-input{min-height:42px;height:42px;padding-left:10px}
    .search-primary-fields .selectize-control.search-primary-country .selectize-input{box-shadow:none}
    .search-primary-fields .selectize-control.search-primary-country .selectize-input.focus,.search-primary-fields .selectize-control.search-primary-country .selectize-input.dropdown-active{box-shadow:none!important}
    .search-primary-fields .selectize-control .selectize-input,
    .search-primary-fields .selectize-control .selectize-input>input{font-size:.76rem}

    .search-primary-submit{
        grid-column:3;
        grid-row:1 / 3;
        width:44px;
        height:auto;
        padding:0;
    }

    .mobile-search-content-offset{
        padding-top: 65px !important;
    }

    .search-results-column{
        padding-bottom: calc(70px + env(safe-area-inset-bottom, 0px)) !important;
    }
}
