/*
 * RRMA site-wide theme overrides.
 * Loaded on every public page (includes/user/dashboard/head.blade.php).
 * Page CSS files load asynchronously after this one, so selectors here are
 * deliberately more specific (html body ...) to win reliably.
 */

/* ── Page title bands: brand teal instead of purple (#9774b3) ─────────── */
html body .bg-light-purple-background:not(.subscription-section) {
    background: linear-gradient(135deg, #1f3d3f 0%, #2f5f62 55%, #4d898c 100%) !important;
    color: #fff;
}

html body h1.bg-light-purple-background,
html body h3.bg-light-purple-background {
    margin: 0;
    padding: 40px 16px !important;
    color: #fff !important;
    font-size: clamp(24px, 2.8vw, 32px);
    font-weight: 700;
    letter-spacing: -.01em;
}

/* a title nested inside a search band shouldn't paint a second band */
html body section.top-serach h1.bg-light-purple-background {
    background: transparent !important;
    padding: 0 !important;
}

/* ── Search / filter header (News, Events, Forum, GHS, Regulatory Updates…) ──
   Dropdowns used to be "folder tabs" overlapping the band's bottom edge;
   now they sit inside the band as rounded white controls. */
html body section.top-serach.bg-light-purple-background {
    padding-top: 34px !important;
    padding-bottom: 34px !important;
    overflow: visible !important;
}

html body section.top-serach h1,
html body section.top-serach .ghs-title-bar h1 {
    margin: 0 0 22px;
    color: #fff !important;
    font-size: clamp(24px, 2.8vw, 32px) !important;
    font-weight: 700 !important;
    letter-spacing: -.01em;
}

html body section.top-serach .top-dropdown-country,
html body section.top-serach .top-dropdown-sort-by,
html body section.top-serach .search-box {
    width: 100%;
    margin: 0 0 12px !important;
    padding: 4px !important;
    background: #fff;
    border-radius: 12px !important;
    box-shadow: 0 10px 24px rgba(0, 0, 0, .14);
}

html body section.top-serach .select2-container--default .select2-selection--single {
    height: 46px;
    border: 0;
    border-radius: 10px;
    background: #fff;
}

html body section.top-serach .select2-container--default .select2-selection--single .select2-selection__rendered {
    padding-left: 14px;
    line-height: 46px;
    color: #1f3436;
    font-size: 15px;
}

html body section.top-serach .select2-container--default .select2-selection--single .select2-selection__placeholder {
    color: #5f7375;
}

html body section.top-serach .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 46px;
    right: 10px;
}

html body section.top-serach .search-box input,
html body section.top-serach .search-box .form-control {
    height: 46px;
    border: 0;
    box-shadow: none;
    font-size: 15px;
}

/* Select2 dropdown lists everywhere: brand highlight instead of default blue */
html body .select2-container--default .select2-results__option--highlighted[aria-selected],
html body .select2-container--default .select2-results__option--highlighted.select2-results__option--selectable {
    background: #4d898c;
    color: #fff;
}

html body .select2-container--default .select2-dropdown {
    border-color: #cfe3e3;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 12px 28px rgba(31, 52, 54, .12);
}

html body .select2-container--default .select2-search--dropdown .select2-search__field {
    border: 1px solid #d3e2e2;
    border-radius: 8px;
    padding: 6px 10px;
}
