.ka-home-main { margin-block: 0 !important; }
.ka-home-intro { padding-bottom: 24px; }
.ka-hero { position: relative; width: min(var(--ka-frame-max), calc(100% - 2 * var(--ka-outer-gutter))); height: 550px; margin: 0 auto; overflow: hidden; border-radius: 20px; background: var(--ka-primary); color: #fff; }
.ka-hero__image { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center 62%; }
.ka-hero::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgb(17 31 70 / 60%), rgb(17 31 70 / 25%)), linear-gradient(0deg, rgb(17 31 70 / 25%), transparent 65%); }
.ka-hero__copy { position: absolute; z-index: 1; inset: 0; display: flex; flex-direction: column; justify-content: center; gap: 18px; width: min(var(--ka-content-max), calc(100% - 2 * var(--ka-inner-gutter))); margin-inline: auto; padding-bottom: 50px; }
.ka-hero h1 { margin: 0; color: #fff; font-size: 64px; font-weight: 600; line-height: 1.2; letter-spacing: -.035em; }
.ka-hero p { margin: 0; color: #fff; font-size: 38px; font-weight: 600; line-height: 1.15; letter-spacing: -.025em; }
.ka-hero__subtitle-mobile { display: none; }
.ka-search-panel { box-sizing: border-box; position: relative; z-index: 2; padding: 30px var(--ka-inner-gutter); border-radius: 20px; background: #fff; color: var(--ka-primary); }
.ka-search-panel--home { width: min(var(--ka-frame-max), calc(100% - 2 * var(--ka-outer-gutter))); margin: -100px auto 0; box-shadow: 0 12px 40px rgb(17 31 70 / 8%); }
.ka-search-panel__inner { max-width: var(--ka-content-max); margin-inline: auto; }
.ka-search-panel h2 { margin: 0 0 14px; color: var(--ka-primary); font-size: 32px; font-weight: 600; line-height: 1.2; letter-spacing: -.035em; }
.ka-vehicle-search { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) 230px; align-items: end; gap: 15px; }
.ka-vehicle-search * { box-sizing: border-box; }
.ka-vehicle-search__field { display: grid; gap: 5px; min-width: 0; }
.ka-vehicle-search label { color: #646974; font-size: 16px; font-weight: 600; line-height: 24px; }
.ka-vehicle-search select { display: block; width: 100%; min-width: 0; height: 58px; margin: 0; padding: 0 42px 0 15px; border: 1px solid #e1e3e8; border-radius: 5px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14'%3E%3Cpath d='m3 5 4 4 4-4' fill='none' stroke='%23111F46' stroke-width='2'/%3E%3C/svg%3E") right 16px center / 14px no-repeat; color: #242934; font-family: inherit; font-size: 16px; font-weight: 400; appearance: none; cursor: pointer; }
.ka-vehicle-search select:disabled { color: #a2a5ac; background-color: #fafafa; opacity: .65; cursor: not-allowed; }
.ka-vehicle-search select:focus-visible, .ka-vehicle-search button:focus-visible { outline: 3px solid var(--ka-secondary); outline-offset: 3px; }
.ka-vehicle-search__submit { position: relative; }
.ka-vehicle-search button[type="submit"] { display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%; min-height: 58px; padding: 12px 16px; border: 0; border-radius: 5px; background: var(--ka-primary); color: #fff; font-family: inherit; font-size: 16px; font-weight: 600; line-height: 24px; white-space: nowrap; cursor: pointer; }
.ka-vehicle-search button[type="submit"]:hover { background: #223563; }
.ka-search-arrow { display: flex; align-items: center; justify-content: center; flex: 0 0 24px; width: 24px; height: 24px; border-radius: 4px; background: var(--ka-secondary); color: var(--ka-primary); }
.ka-search-arrow svg { display: block; width: 16px; height: 16px; }
.ka-search-note { position: absolute; right: 0; bottom: calc(100% + 6px); display: flex; align-items: flex-start; gap: 8px; color: var(--ka-primary); font-size: 18px; font-style: italic; line-height: 1.3; white-space: nowrap; pointer-events: none; }
.ka-search-note svg { position: static; display: block; flex: 0 0 36px; width: 36px; height: 36px; color: var(--ka-secondary); }
.ka-inventory-note { margin: 16px 0 0; color: #727784; font-size: 12px; line-height: 1.6; }
.ka-home-intro > .ka-inventory-note { width: min(var(--ka-content-max), calc(100% - 2 * (var(--ka-outer-gutter) + var(--ka-inner-gutter)))); margin-inline: auto; }
.ka-search-panel--catalogue { margin-block: 28px 36px; padding: 24px 0; border-block: 1px solid #e1e3e8; border-radius: 0; }
.ka-search-panel--catalogue h2 { font-size: 26px; }
.ka-results { margin-top: 32px; }
.ka-results__heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.ka-results__heading h2 { margin: 0; color: var(--ka-primary); font-size: 30px; line-height: 1.3; }
.ka-results__heading a { color: var(--ka-primary); font-size: 15px; text-underline-offset: 4px; }
.ka-results__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; margin-top: 24px; }
.ka-car { overflow: hidden; border: 1px solid #e1e3e8; border-radius: 14px; background: #fff; }
.ka-car__image { display: block; aspect-ratio: 4 / 3; }
.ka-car__image img { display: block; width: 100%; height: 100%; object-fit: cover; }
.ka-car__info { padding: 22px; }
.ka-car h3 { margin: 0 0 8px; font-size: 22px; line-height: 1.3; }
.ka-car h3 a { color: var(--ka-primary); text-decoration: none; }
.ka-car p { margin: 0; }
.ka-car__description { display: -webkit-box; overflow: hidden; -webkit-line-clamp: 2; -webkit-box-orient: vertical; min-height: 44px; color: #636977; font-size: 14px; line-height: 22px; }
.ka-car__specs { margin-top: 16px !important; font-size: 13px; line-height: 1.7; }
.ka-car__price { display: block; margin-top: 16px; font-size: 24px; line-height: 1.3; }
.ka-car__link { display: flex; justify-content: space-between; margin-top: 18px; color: var(--ka-primary); font-size: 15px; font-weight: 600; text-decoration: none; }
.ka-car__link:hover { text-decoration: underline; }
.ka-results__empty { margin-top: 24px; padding: 36px; border-radius: 16px; background: #f5f4f0; }
.ka-results__empty h3 { margin: 0 0 12px; font-size: 24px; }
.ka-results__empty p { margin: 0 0 16px; font-size: 16px; line-height: 1.6; }
.ka-results__empty a { color: var(--ka-primary); font-weight: 600; }
@media (max-width: 1100px) and (min-width: 641px) {
    .ka-hero h1 { font-size: 52px; }
    .ka-hero p { font-size: 30px; }
    .ka-vehicle-search { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .ka-search-note { display: none; }
    .ka-results__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
    .ka-hero { width: 100%; height: 225px; border-radius: 0 0 20px 20px; }
    .ka-hero__copy { gap: 14px; padding-bottom: 0; }
    .ka-hero h1 { font-size: 32px; line-height: 1; }
    .ka-hero p { font-size: 28px; font-weight: 400; line-height: 1; }
    .ka-hero__subtitle-desktop { display: none; }
    .ka-hero__subtitle-mobile { display: inline; }
    .ka-search-panel--home { margin-top: 0; padding-block: 40px; box-shadow: none; }
    .ka-search-panel h2 { margin-bottom: 20px; font-size: 32px; line-height: 1; }
    .ka-vehicle-search { grid-template-columns: minmax(0, 1fr); gap: 15px; }
    .ka-vehicle-search label { font-size: 16px; }
    .ka-vehicle-search button[type="submit"] { justify-content: space-between; padding: 16px 20px; font-size: 18px; }
    .ka-vehicle-search__field { gap: 3px; }
    .ka-search-note { display: none; }
    .ka-search-panel--catalogue { padding: 20px 0; border: 0; border-radius: 0; }
    .ka-search-panel--catalogue h2 { font-size: 24px; }
    .ka-results__grid { grid-template-columns: minmax(0, 1fr); }
    .ka-results__heading h2 { font-size: 26px; }
    .ka-results__empty { padding: 24px; }
}
@media (max-width: 359px) {
    .ka-search-panel--home h2 { font-size: 28px; line-height: 32px; }
}
/* HTML pickers stay anchored to their field in embedded/mobile browsers. */
.ka-picker { position: relative; min-width: 0; }
.ka-picker .ka-picker__native { display: none; }
.ka-vehicle-search .ka-picker__trigger { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; height: 58px; min-height: 58px; padding: 0 15px; border: 1px solid #e1e3e8; border-radius: 5px; background: #fff; color: #242934; font-family: inherit; font-size: 16px; font-weight: 400; line-height: 24px; text-align: left; cursor: pointer; }
.ka-picker__trigger > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ka-picker__trigger > svg { display: block; flex: 0 0 16px; color: var(--ka-primary); }
.ka-vehicle-search .ka-picker__trigger:hover { background: #fff; border-color: #9ca7bc; }
.ka-vehicle-search .ka-picker__trigger:disabled { border-color: #e1e3e8; background: #fafafa; color: #a2a5ac; cursor: not-allowed; }
.ka-picker__trigger[aria-expanded="true"] > svg { transform: rotate(180deg); }
.ka-picker__list { box-sizing: border-box; position: absolute; z-index: 20; top: calc(100% + 6px); left: 0; right: 0; max-height: 280px; overflow-y: auto; overscroll-behavior: contain; margin: 0; padding: 6px; border: 1px solid #d8dce5; border-radius: 8px; background: #fff; color: var(--ka-primary); box-shadow: 0 12px 30px rgb(17 31 70 / 18%); font-size: 16px; line-height: 24px; list-style: none; }
.ka-picker__list[hidden] { display: none; }
.ka-picker.is-up .ka-picker__list { top: auto; bottom: calc(100% + 6px); }
.ka-picker__list li { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 44px; margin: 0 !important; padding: 10px; border-radius: 4px; font-size: 16px; line-height: 24px; cursor: pointer; }
.ka-picker__list li > svg { flex: 0 0 16px; }
.ka-picker__list li:hover, .ka-picker__list li.is-active { background: #f1ede4; }
.ka-picker__list li[aria-selected="true"] { color: var(--ka-primary); font-weight: 600; }

.ka-vehicle-search button:focus:not(:focus-visible) { outline: none; }

/* The homepage finder only needs a make and a submit button. */
.ka-search-panel--home .ka-vehicle-search--simple { grid-template-columns: minmax(0, 1fr) 230px; }
@media (max-width: 640px) {
    .ka-search-panel--home .ka-vehicle-search--simple { grid-template-columns: minmax(0, 1fr); }
}
