/*
 * Hero search box + trust bar, shared across every page that opens on a
 * search entry point: home, self-drive portal, country hub. One definition
 * here instead of near-identical copies drifting apart page by page.
 */

.home-hero-search {
    background: white;
    border-radius: var(--r2e-radius-lg);
    padding: var(--r2e-space-6) var(--r2e-space-6);
    /* width: fit-content because this form is a direct flex child of
       Bootstrap's .row (no .col wrapper) on some pages: inline-flex
       blockifies to flex there, and a block-level flex item stretches to
       the row's full width by default, leaving a wide empty strip past
       the controls. */
    display: inline-flex;
    width: fit-content;
    align-items: flex-start;
    gap: var(--r2e-space-6);
    flex-wrap: wrap;
    box-shadow: var(--r2e-shadow-lg);
}
.home-hero-search .hhs-group { min-width: 200px; }
.home-hero-search .hhs-group-dates { min-width: 320px; }
/* min-width override: this column still inherits .hhs-group's 200px,
   wider than the icon-only button itself, which left a gap between the
   button and the box's right padding. */
.home-hero-search .hhs-group-btn { flex: 0 0 auto; min-width: 0; }
.home-hero-search .hhs-label { font-size: var(--r2e-text-xs); font-weight: 700; text-transform: uppercase; letter-spacing: var(--r2e-tracking-caps); color: var(--bs-secondary); display: block; margin-bottom: var(--r2e-space-1); line-height: var(--r2e-leading-tight); text-align: center; }
.home-hero-search .hhs-input { height: 46px; box-sizing: border-box; border: 1px solid var(--bs-gray-200) !important; border-radius: var(--r2e-radius); padding: var(--r2e-space-2) var(--r2e-space-3) !important; font-size: var(--r2e-text-sm); font-weight: 500; color: var(--bs-secondary); background: white !important; box-shadow: none !important; cursor: pointer; }
.home-hero-search .hhs-input:focus { border-color: var(--bs-primary) !important; }
/* The country list (Choices, <x-country-select class="hhs-input">) hides its select and draws the closed
   field itself, so the .hhs-input type above never reached it: it read 16px, regular, near black beside the
   dates field. The closed field and its placeholder take the dates field's type (family, size, weight,
   leading, colour); the dropdown list keeps its own. */
.home-hero-search .r2e-country-choices .choices__inner,
.home-hero-search .r2e-country-choices .choices__list--single .choices__item {
    font-family: inherit;
    font-size: var(--r2e-text-sm);
    font-weight: 500;
    line-height: var(--r2e-leading-body);
    color: var(--bs-secondary);
}
.home-hero-search .r2e-country-choices .choices__list--single .choices__item.choices__placeholder { opacity: 1; }
/* The closed field's box is the dates field's box: same 1px gray-200 border, same 46px height, text centred in
   it. Choices drew gray-300, 47.7px (its padding plus the list's own 4px) and padded the text off centre.
   Focus and open keep the primary border (style.css sets it with !important). */
.home-hero-search .r2e-country-choices .choices__inner {
    box-sizing: border-box;
    height: 46px;
    min-height: 46px;
    display: flex;
    align-items: center;
    border-color: var(--bs-gray-200);
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}
/* The country text starts where the dates text does: 12px in, as the dates field's own padding says (the closed
   field had 16px of padding and Choices' 4px more on its list). The flag stays in front of the name. */
.home-hero-search .r2e-country-choices .choices__inner { padding-left: var(--r2e-space-3) !important; }
.home-hero-search .r2e-country-choices .choices__list--single { padding: 0; }
/* The open list reads like the dates field too: its rows and its search box take the same family, size, weight
   and colour. The grey "Country" header row keeps its muted colour; the highlight tint is unchanged. */
.home-hero-search .r2e-country-choices .choices__list--dropdown .choices__item,
.home-hero-search .r2e-country-choices .choices__list--dropdown .choices__input {
    font-family: inherit;
    font-size: var(--r2e-text-sm);
    font-weight: 500;
    line-height: var(--r2e-leading-body);
}
.home-hero-search .r2e-country-choices .choices__list--dropdown .choices__item:not(.choices__placeholder),
.home-hero-search .r2e-country-choices .choices__list--dropdown .choices__input {
    color: var(--bs-secondary) !important;
}
/* The search box is typed into: under 16px, iOS Safari zooms the page on focus. */
@media (max-width: 991px), (pointer: coarse) {
    .home-hero-search .r2e-country-choices .choices__list--dropdown .choices__input { font-size: var(--r2e-text-base); }
}
.home-hero-search .hhs-btn { height: 46px; box-sizing: border-box; border-radius: var(--r2e-radius); padding: 0 var(--r2e-space-4); display: flex; align-items: center; justify-content: center; }
@media (max-width: 575px) {
    .home-hero-search { display: flex; flex-direction: column; align-items: stretch; width: 100%; }
    .home-hero-search .hhs-group, .home-hero-search .hhs-group-dates { min-width: 0; width: 100%; }
    .home-hero-search .hhs-group-btn .hhs-label { display: none; }
    .home-hero-search .hhs-btn { width: 100%; height: auto; padding-top: var(--r2e-space-3); padding-bottom: var(--r2e-space-3); }
}

.home-trust-bar { background: var(--bs-secondary); padding: var(--r2e-space-3) 0; }
.home-trust-bar .trust-item { display: flex; align-items: center; gap: var(--r2e-space-2); color: rgba(255, 255, 255, 0.9); font-size: var(--r2e-text-xs); font-weight: 500; }
.home-trust-bar .trust-item i { color: var(--bs-danger); position: relative; top: -1px; }
.home-trust-bar .trust-item span { position: relative; top: 1px; }
@media (max-width: 991px) {
    .home-trust-bar .row { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; justify-content: flex-start !important; scrollbar-width: none; padding-bottom: var(--r2e-space-1); }
    .home-trust-bar .row::-webkit-scrollbar { display: none; }
    .home-trust-bar .col-auto { flex-shrink: 0; }
}
