/* RE-461: loaded only on the homepage. All rules belong to its hero/search.
   Text grounds, control borders and focus use neutral tokens: brand colours are
   client-chosen and are not assumed readable (see the shared UI catalogue). */
.re-home .re-home-hero,
.re-layout-home .re-home-hero { position: relative; isolation: isolate; background: #343b36; padding: clamp(2.5rem, 6vw, 5rem) max(var(--re-page-gutter), calc((100% - var(--re-page-max)) / 2 + var(--re-page-gutter))) 2rem; border-radius: 0; }
.re-home-hero .re-home-hero-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 55%; border-radius: inherit; z-index: -2; }
.re-home-hero::before { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgb(20 30 28 / .7), rgb(20 30 28 / .65)); border-radius: inherit; z-index: -1; pointer-events: none; }
.re-home-hero .re-hero-copy,
.re-layout-home[data-home-preset] .re-home-hero .re-hero-copy { max-width: 52rem; margin: 0 auto 2rem; text-align: center; color: #fff; }
.re-home-hero .re-hero-copy h1 { font-size: clamp(2rem, 4vw, 3.75rem); line-height: 1.12; letter-spacing: -.035em; margin-bottom: 1rem; }
.re-home-hero .re-hero-copy > p,
.re-layout-home[data-home-preset] .re-home-hero .re-hero-copy > p:last-child,
.re-home-hero > .re-hero-trust { color: #fff; }
.re-home-hero .re-hero-trust { font-size: .875rem; margin-top: 1rem; text-align: center; }
.re-home-search { position: relative; min-width: 0; color: var(--appearance-ink, #0f172a); }
.re-home-search .re-hero-categories { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; margin-bottom: 1rem; }
.re-home-search .re-hero-categories a { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: .625rem 1.25rem; border: 1px solid var(--appearance-border, #e1e7e3); border-radius: 999px; color: var(--appearance-ink, #0f172a); background: var(--appearance-panel, #fff); font-weight: 650; }
.re-home-search .re-hero-categories a.is-active { background: var(--brand-primary); color: var(--re-primary-contrast, #fff); border-color: var(--brand-primary); box-shadow: inset 0 -3px 0 currentColor; }
.re-home-search .re-hero-categories a:not(.is-active):hover { text-decoration: underline; text-underline-offset: .2em; box-shadow: inset 0 0 0 1px currentColor; }
.re-home-search .re-hero-form { background: var(--appearance-panel, #fff); padding: clamp(1rem, 2vw, 1.5rem); border: 1px solid var(--appearance-border, #e1e7e3); border-radius: var(--appearance-radius, 1rem); box-shadow: var(--re-shadow-overlay, 0 16px 40px #0002); }
.re-home-search .re-search-tabs { display: flex; gap: .5rem; margin-bottom: 1rem; padding-bottom: 1rem; }
/* Buy/Rent follow the shared UI choice chip: neutral border, and a checked state
   that does not depend on the brand colour (native radio stays visible). */
.re-home-search .re-search-tabs label { position: relative; min-height: 44px; display: flex; align-items: center; gap: .5rem; padding: .5rem 1rem; border: 1px solid var(--re-border, #64748b); border-radius: 999px; background: var(--appearance-panel, #fff); cursor: pointer; }
.re-home-search .re-search-tabs label:hover { border-color: var(--appearance-ink, #0f172a); }
.re-home-search .re-search-tabs label:has(input:checked) { background: var(--re-surface-muted, #f1f5f9); border-color: var(--appearance-ink, #0f172a); box-shadow: inset 0 0 0 1px var(--appearance-ink, #0f172a); font-weight: 700; }
.re-home-search .re-search-tabs label:has(input:focus-visible) { outline: 3px solid var(--re-focus, #0f172a); outline-offset: 3px; }
.re-home-search .re-search-tabs input { flex-shrink: 0; accent-color: var(--appearance-ink, #0f172a); }
.re-home-search .re-search-tabs input:focus-visible { outline: none; }
.re-home-search .re-search-fields { display: grid; grid-template-columns: minmax(0, 1fr) minmax(11rem, 1fr) repeat(2, minmax(0, 1fr)); gap: 1rem; align-items: end; }
.re-home-search .re-search-fields > * { min-width: 0; }
.re-home-search .re-search-fields > label { margin: 0; }
.re-home-search .re-location { grid-column: auto; }
.re-home-search .re-search-fields label { display: block; font-size: .8125rem; font-weight: 650; }
.re-home-search .re-search-fields input,
.re-home-search .re-search-fields select { width: 100%; min-width: 0; min-height: 44px; margin-top: .5rem; border: 1px solid var(--re-border, #64748b); border-radius: var(--appearance-button-radius, .5rem); background-color: var(--appearance-panel, #fff); color: var(--appearance-ink, #0f172a); }
.re-home-search .re-search-fields select { font-size: .875rem; }
.re-home-search .re-search-fields > button { min-height: 44px; justify-content: center; background: var(--brand-primary); color: var(--re-primary-contrast, #fff); font-weight: 700; border-radius: var(--appearance-button-radius, .5rem); }
.re-home-search :is(a, input, select, button):focus-visible { outline: 3px solid var(--re-focus, #0f172a); outline-offset: 3px; }
.re-home-hero .re-hero-categories a:focus-visible { outline-color: #fff; }
/* The location suggestions take the card's surface and the shared UI border, radius and shadow. */
.re-home-search .re-suggest > .re-label .re-icon { width: 1em; height: 1em; }
.re-home-search .re-suggest > .absolute { margin-top: .25rem; border-color: var(--re-border, #64748b); border-radius: var(--appearance-button-radius, .5rem); background: var(--appearance-panel, #fff); color: var(--appearance-ink, #0f172a); box-shadow: var(--re-shadow, 0 2px 8px #0000001a); }
.re-home-search .re-suggest mark { background: var(--re-surface-muted, #f1f5f9); color: inherit; font-weight: 700; }
/* Reserve the translated select values plus dropdown-arrow padding before
   sharing remaining desktop space with location and price fields. */
@media (min-width: 1280px) {
    .re-home-search .re-search-fields { grid-template-columns: minmax(0, 1.4fr) minmax(11rem, 1.5fr) repeat(2, minmax(8.25rem, 1fr)) repeat(3, minmax(7.75rem, 1fr)) minmax(0, .9fr); gap: .75rem; }
    .re-home-search .re-location { grid-column: auto; }
}
@media (max-width: 767px) {
    .re-home-search .re-search-fields { grid-template-columns: minmax(0, 1fr); gap: .875rem; }
    .re-home-search .re-search-fields > button { grid-column: 1 / -1; }
    .re-home-search .re-hero-categories a { flex: 1 1 auto; padding-inline: .75rem; }
    .re-home-hero .re-hero-copy > p { font-size: .9375rem; }
}

/* RE-498: the homepage owns full-width surfaces; each content region owns one
   shared page gutter. Override Brand home.css .re-home/.re-section/.re-cta here
   without changing the container contract on other routes. No viewport units:
   a reserved scrollbar must not create horizontal overflow. */
.cms-index-index #maincontent { margin-block-start: 0; }
.cms-index-index #maincontent > .columns,
.cms-index-index #maincontent > .columns .column.main > .re-layout-home,
.cms-index-index .re-home {
    width: 100%; max-width: none; padding-inline: 0; margin-inline: 0;
}
.cms-index-index .re-layout-home[data-home-preset] { padding-block-start: 0; }
.cms-index-index .re-home > .re-section,
.cms-index-index .re-layout-home > [data-layout-section]:not([data-layout-section="hero"]) {
    box-sizing: border-box; width: 100%; max-width: var(--re-page-max);
    margin-inline: auto; padding-inline: var(--re-page-gutter);
}
.cms-index-index .re-home > .re-cta {
    box-sizing: border-box; width: calc(100% - 2 * var(--re-page-gutter));
    max-width: calc(var(--re-page-max) - 2 * var(--re-page-gutter)); margin-inline: auto;
}
.cms-index-index .re-layout-home[data-home-preset] > [data-layout-section="property-search"] {
    border: 0; border-radius: 0; background: none;
}
.cms-index-index .re-layout-home :is(.re-layout-agencies, .re-layout-stats, .re-layout-testimonials, .re-layout-map) {
    padding-inline: 0; border-inline-width: 0;
}
