/* Mobile hardening layer.
   Loaded last so the mobile layout stays predictable while the older page
   styles are gradually consolidated. Desktop geometry is intentionally
   untouched. */
.home-recommendations__title-mobile {
  display: none;
}

@media (min-width: 601px) {
  .catalog-mobile-more,
  .catalog-mobile-more__content {
    display: contents;
  }

  .catalog-mobile-more > summary {
    display: none;
  }
}

/* Vehicle detail uses shared data and handlers, but keeps separate responsive presentation. */
.vehicle-title__mobile-heading,
.vehicle-facts--mobile,
.vehicle-question--mobile,
.vehicle-spec-title--mobile,
.vehicle-spec-label--mobile,
.vehicle-equipment-title--mobile,
.vehicle-cost-title--mobile,
.vehicle-cost-action--mobile {
  display: none !important;
}

@media (max-width: 600px) {
  html,
  body {
    width: 100%;
    max-width: 100%;
    overflow-x: clip;
  }

  img,
  svg {
    max-width: 100%;
  }

  .container {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    padding: 18px 14px 40px;
  }

  /* Header: logo, menu and account must always fit one row. */
  .site-header {
    width: 100%;
    padding: 6px 0;
  }

  .site-header__inner,
  .site-header__inner:has(.header-catalog-search) {
    width: calc(100% - 12px);
    max-width: calc(100% - 12px);
    min-height: 64px;
    height: auto;
    margin-inline: 6px;
    padding: 7px 9px;
    gap: 7px;
    border-radius: 18px;
  }

  .site-header__start,
  .site-header__inner:has(.header-catalog-search) .site-header__start {
    min-width: 0;
    flex: 1 1 auto;
    justify-content: flex-start;
    gap: 7px;
  }

  .site-header__logo {
    width: min(164px, calc(100vw - 150px));
    height: 46px;
    flex: 0 1 164px;
    min-width: 0;
  }

  .site-header__logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: left center;
  }

  .mega-menu {
    flex: 0 0 auto;
    margin-left: auto;
  }

  .mega-menu > summary,
  .header-account,
  .header-account.header-account--user,
  .header-account.header-account--guest {
    width: 44px;
    min-width: 44px;
    height: 44px;
    padding: 0;
    border-radius: 13px;
  }

  .site-header__actions {
    min-width: 44px;
    gap: 0;
  }

  .header-catalog-search {
    order: 3;
    width: 100%;
    max-width: 100%;
    flex: 0 0 100%;
    height: 42px;
  }

  /* Home hero and search. */
  .home-search-stage,
  .home-search-stage__intro,
  .home-search-shell,
  .home-picker,
  .home-popular-cars,
  .home-quick-services,
  .home-recommendations {
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  .home-search-stage {
    margin-inline: 0;
    padding: 22px 0 20px;
  }

  .home-search-stage__intro {
    padding-inline: 0;
  }

  .home-search-stage__intro h1 {
    width: 100%;
    max-width: 100%;
    white-space: normal;
    text-wrap: balance;
    overflow-wrap: normal;
    word-break: normal;
    font-size: clamp(30px, 9vw, 38px);
    line-height: 1.02;
    letter-spacing: -.045em;
  }

  .home-search-stage__lead,
  .home-search-stage__lead > span,
  .home-ecosystem-rotation {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow-wrap: anywhere;
  }

  /* Mobile home follows the task-first pattern: search, compact services,
     then cars. Long marketing copy and the desktop discovery dashboard stay
     on larger screens. */
  .home-search-stage__lead {
    display: none;
  }

  .home-market-summary {
    width: 100%;
    justify-content: flex-start;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 7px 12px;
  }

  .home-market-count {
    min-width: 0;
    max-width: 100%;
  }

  .home-market-count span {
    max-width: 100%;
    padding-inline: 8px;
    white-space: nowrap;
  }

  .home-mobile-service-links {
    display: flex !important;
    width: 100%;
    min-width: 0;
    gap: 18px;
    margin: 2px 0 12px;
    padding: 5px 0 7px;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scrollbar-width: none;
  }

  .home-mobile-service-links::-webkit-scrollbar {
    display: none;
  }

  .home-mobile-service-links a {
    flex: 0 0 auto;
    color: #16181d;
    font-size: 14px;
    line-height: 20px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
  }

  .home-main-search {
    width: 100%;
    max-width: 100%;
  }

  .home-picker {
    margin: 8px 0 0;
    padding: 0 0 5px;
    scroll-padding-inline: 0 14px;
  }

  .home-picker::after {
    content: "";
    flex: 0 0 6px;
  }

  /* Popular section: keep the action visible instead of clipping it. */
  .home-popular-cars {
    display: none;
  }

  .home-popular-cars__heading {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 8px;
  }

  .home-popular-cars__heading h2 {
    min-width: 0;
    margin: 0;
  }

  .home-popular-cars__heading a {
    min-height: 34px;
    max-width: 132px;
    padding-inline: 8px;
    line-height: 17px;
    white-space: normal;
    text-align: right;
  }

  .home-popular-cars__logo-strip,
  .home-popular-cars__quick,
  .home-popular-cars__filters,
  .home-quick-services__tiles {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overscroll-behavior-inline: contain;
  }

  .home-popular-cars__panel {
    width: 100%;
    min-width: 0;
    padding: 14px 12px;
  }

  .home-popular-cars__filters-wrap,
  .home-popular-cars__quick-wrap {
    min-width: 0;
    overflow: hidden;
  }

  .home-popular-cars__brands {
    width: 100%;
    min-width: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .home-popular-cars__brands a {
    min-width: 0;
  }

  .home-popular-cars__brands strong {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .home-quick-services {
    display: none;
  }

  .home-promo-carousel,
  .home-promo-carousel__viewport,
  .home-promo-slide {
    width: 100%;
    max-width: 100%;
    display: none;
  }

  .home-quick-services .home-quick-services__tiles {
    gap: 18px;
    padding: 2px 16px 8px 0;
    align-items: center;
  }

  .home-quick-services .home-quick-service {
    flex: 0 0 auto;
    display: block;
    width: auto;
    color: #16181d;
    text-align: left;
  }

  .home-quick-services .home-quick-service img {
    display: none;
  }

  .home-quick-services .home-quick-service strong {
    display: block;
    width: auto;
    min-height: 0;
    font-size: 14px;
    line-height: 20px;
    font-weight: 600;
    white-space: nowrap;
  }

  .home-quick-services .home-quick-service strong br {
    display: none;
  }

  .home-recommendations {
    padding: 22px 0 30px;
  }

  .home-recommendations .section-heading {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 8px;
    margin-bottom: 16px;
  }

  .home-recommendations .section-heading h2 {
    margin: 0;
    font-size: 24px;
    line-height: 28px;
  }

  .home-recommendations__title-desktop {
    display: none;
  }

  .home-recommendations__title-mobile {
    display: inline;
  }

  .home-recommendations .section-heading p {
    display: none;
  }

  .home-recommendations .section-heading > a {
    display: none;
  }

  .home-showcase-groups {
    gap: 34px;
  }

  .home-showcase-group__heading {
    align-items: start;
    margin-bottom: 14px;
  }

  .home-showcase-group__heading h3 {
    font-size: 20px;
    line-height: 24px;
  }

  .home-showcase-group__heading p {
    margin-top: 4px;
    font-size: 13px;
    line-height: 18px;
  }

  .home-showcase-group__heading > a {
    display: none;
  }

  .home-showcase-more {
    margin-top: 34px;
  }

  .home-car-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 9px;
    row-gap: 24px;
  }

  .home-car-item,
  .home-car-item .car-card,
  .car-card--home .car-card__link {
    min-width: 0;
  }

  .car-card--home .car-card__photo {
    border-radius: 12px;
  }

  .car-card--home .favorite-button {
    top: 5px;
    right: 5px;
    width: 28px;
    height: 28px;
  }

  .car-card--home .car-card__body {
    min-width: 0;
    padding: 7px 1px 0;
  }

  .car-card--home .car-card__price,
  .car-card--home .price-on-request {
    font-size: 15px;
    line-height: 19px;
  }

  .car-card--home .car-card__body h3 {
    margin-bottom: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 14px;
    line-height: 18px;
  }

  .car-card--home .car-card__specs {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 12px;
    line-height: 16px;
  }

  .home-feed-promo {
    display: none;
  }

  /* Keep the four service inserts in the feed, but do not let them take over
     an entire phone screen. */
  .service-promo {
    min-height: 116px;
    margin: 18px 0 22px;
    padding: 14px 112px 14px 14px;
    border-radius: 16px;
  }

  .service-promo__copy {
    width: 100%;
  }

  .service-promo__brandline {
    display: none;
  }

  .service-promo h3 {
    margin: 0 0 9px;
    font-size: 16px;
    line-height: 20px;
    letter-spacing: -.01em;
  }

  .service-promo p {
    display: none;
  }

  .service-promo .service-promo__action {
    min-height: 32px;
    padding: 5px 11px;
    border-radius: 9px;
    font-size: 12px;
    line-height: 16px;
  }

  .service-promo__illustration,
  .service-promo--reports .service-promo__illustration,
  .service-promo--inspection .service-promo__illustration,
  .service-promo--selection .service-promo__illustration,
  .service-promo--warranty .service-promo__illustration {
    right: -10px;
    bottom: -10px;
    width: 118px;
    height: 118px;
    object-position: center;
  }

  /* Catalog top and filters. */
  .container:has(> .catalog-layout) {
    width: 100%;
    max-width: 100%;
    padding: 16px 14px 40px;
  }

  .catalog-layout,
  .catalog-layout__main,
  .catalog-heading,
  .catalog-discovery--inline,
  #catalog-filters,
  .catalog-filter-main {
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  .catalog-heading {
    margin-bottom: 18px;
  }

  .catalog-heading h1 {
    max-width: 100%;
    margin-top: 12px;
    overflow-wrap: anywhere;
  }

  .catalog-heading .fx-widget {
    display: none;
  }

  .catalog-heading .fx-widget__slide img {
    right: 4px;
  }

  .catalog-popular-brands,
  .catalog-all-brands {
    display: none !important;
  }

  #catalog-filters .catalog-quick-cards {
    display: none;
  }

  #catalog-filters .catalog-quick-cards .catalog-quick-button {
    width: 100%;
    min-width: 0;
    height: 58px;
    min-height: 58px;
    padding: 0 9px;
    gap: 7px;
    white-space: normal;
    text-align: left;
    line-height: 17px;
  }

  #catalog-filters .catalog-quick-cards svg {
    width: 22px;
    height: 22px;
    flex-basis: 22px;
  }

  #catalog-filters .catalog-switch-line {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    width: 100%;
    max-width: 100%;
    gap: 8px;
    overflow: visible;
    padding: 0;
    scrollbar-width: none;
  }

  #catalog-filters .catalog-switch-line::-webkit-scrollbar {
    display: none;
  }

  #catalog-filters .catalog-switch-line > * {
    width: 100%;
    min-width: 0;
  }

  #catalog-filters .catalog-switch-line .catalog-segments {
    width: 100%;
    min-width: 0;
  }

  #catalog-filters .catalog-switch-line > .catalog-quick-button {
    display: none;
  }

  #catalog-filters .catalog-switch-line .catalog-segments label {
    flex: 1 1 0;
  }

  #catalog-filters .catalog-switch-line .catalog-segments span {
    width: 100%;
    padding-inline: 7px;
  }

  #catalog-filters .catalog-fields,
  #catalog-filters .catalog-brand-row {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 10px;
  }

  #catalog-filters .catalog-field-pair,
  #catalog-filters .catalog-range-pair {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    flex-direction: initial;
    gap: 2px;
    width: 100%;
    min-width: 0;
  }

  #catalog-filters .catalog-range-pair__divider {
    display: none;
  }

  #catalog-filters .catalog-range-pair .catalog-range-pair__start,
  #catalog-filters .catalog-range-pair .catalog-range-pair__end {
    border-radius: 12px;
  }

  #catalog-filters .catalog-filter-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
  }

  #catalog-filters [data-reset] {
    grid-column: 1;
    grid-row: 2;
    justify-self: start;
  }

  #catalog-filters .catalog-show-button {
    grid-column: 1;
    grid-row: 1;
    width: 100%;
    min-width: 0;
  }

  .catalog-mobile-more {
    display: block;
    margin-top: 2px;
  }

  .catalog-mobile-more > summary {
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 13px;
    border-radius: 12px;
    background: #e9eaec;
    color: #111;
    font-weight: 600;
    cursor: pointer;
    list-style: none;
  }

  .catalog-mobile-more > summary::-webkit-details-marker {
    display: none;
  }

  .catalog-mobile-more__label-close {
    display: none;
  }

  .catalog-mobile-more[open] .catalog-mobile-more__label-open {
    display: none;
  }

  .catalog-mobile-more[open] .catalog-mobile-more__label-close {
    display: inline;
  }

  .catalog-mobile-more > summary svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    transition: transform .18s ease;
  }

  .catalog-mobile-more[open] > summary svg {
    transform: rotate(180deg);
  }

  .catalog-mobile-more__content {
    display: grid;
    gap: 10px;
    margin-top: 10px;
  }

  /* Mobile Safari overlays the bottom browser toolbar on top of the page.
     Keep the primary action inside the visual viewport while the long advanced
     filter block is open, and reserve space so the last field stays tappable. */
  .catalog-mobile-more[open] {
    padding-bottom: calc(82px + env(safe-area-inset-bottom));
  }

  .catalog-mobile-more[open] ~ .catalog-filter-actions {
    position: fixed;
    z-index: 75;
    right: 0;
    bottom: 0;
    left: 0;
    grid-template-columns: auto minmax(0, 1fr) !important;
    gap: 12px;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
    background: #fff;
    box-shadow: 0 -8px 24px rgba(17, 17, 17, .12);
  }

  #catalog-filters .catalog-mobile-more[open] ~ .catalog-filter-actions [data-reset] {
    grid-column: 1;
    grid-row: 1;
    align-self: center;
  }

  #catalog-filters .catalog-mobile-more[open] ~ .catalog-filter-actions .catalog-show-button {
    grid-column: 2;
    grid-row: 1;
  }

  .catalog-layout > .catalog-promos,
  .catalog-sidebar.catalog-promos {
    display: none;
  }

  .catalog-popover {
    left: 8px !important;
    right: 8px !important;
    width: auto !important;
    max-width: none !important;
  }

  /* Catalog cards: true one-column mobile layout. */
  .catalog-list[data-catalog-grid] {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    gap: 26px;
  }

  .catalog-list .catalog-card--horizontal {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    grid-template-columns: minmax(0, 1fr);
  }

  .catalog-list .catalog-card--horizontal .catalog-card__photo {
    width: 100%;
    aspect-ratio: 4 / 3;
  }

  .catalog-list .catalog-card__body {
    width: 100%;
    min-width: 0;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: auto auto auto;
    gap: 12px 10px;
    padding: 0;
  }

  .catalog-list .catalog-card--horizontal .catalog-card__info {
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .catalog-list .catalog-card--horizontal .catalog-card__age {
    grid-column: 1;
    grid-row: 2;
  }

  .catalog-list .catalog-card--horizontal .catalog-card__price {
    grid-column: 2;
    grid-row: 2;
    align-items: flex-end;
    text-align: right;
  }

  .catalog-list .catalog-card__price > strong,
  .catalog-list .catalog-card__age strong {
    white-space: normal;
    font-size: 18px;
    line-height: 22px;
  }

  .catalog-list .catalog-card__footer {
    grid-column: 1 / -1;
    grid-row: 3;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    width: 100%;
    gap: 8px;
  }

  .catalog-list .catalog-card--horizontal .catalog-card__contact {
    width: 100%;
    min-width: 0;
  }

  .catalog-list .catalog-card__contact [data-show-phone],
  .catalog-list .catalog-card__contact [href^="tel:"] {
    width: auto;
    min-width: 0;
    flex: 1 1 0;
  }

  .catalog-list .catalog-card__contact [data-open-car-thread] {
    width: 44px;
    min-width: 44px;
    flex: 0 0 44px;
    padding: 0;
  }

  .catalog-list .catalog-card__contact [data-open-car-thread] span {
    display: none;
  }

  .catalog-list .catalog-card--horizontal .catalog-card__contact > a,
  .catalog-list .catalog-card--horizontal .catalog-card__contact > button {
    padding-inline: 8px;
    font-size: 12px;
  }

  .catalog-list .catalog-card--horizontal .catalog-card__actions {
    margin-left: 0 !important;
    align-self: center;
  }

  /* Vehicle page. */
  .container:has(> .vehicle-page) {
    width: 100%;
    max-width: 100%;
    padding: 16px 14px 40px;
  }

  .vehicle-page,
  .vehicle-page__layout,
  .vehicle-page__layout > *,
  .vehicle-title,
  .vehicle-title__row,
  .vehicle-gallery,
  .vehicle-sidebar,
  .vehicle-facts,
  .vehicle-sections {
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  .vehicle-breadcrumb {
    flex-wrap: nowrap;
    max-width: 100%;
    overflow-x: auto;
    padding-bottom: 3px;
    white-space: nowrap;
    scrollbar-width: none;
  }

  .vehicle-breadcrumb::-webkit-scrollbar {
    display: none;
  }

  .vehicle-title h1 {
    width: 100%;
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
    font-size: clamp(27px, 8vw, 34px);
    line-height: 1.08;
    letter-spacing: -.035em;
  }

  .vehicle-actions {
    width: 100%;
    justify-content: flex-start;
    overflow-x: auto;
  }

  .vehicle-gallery__main {
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
    border-radius: 16px;
  }

  .vehicle-thumbnails {
    display: flex;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
  }

  .vehicle-thumbnails button {
    flex: 0 0 82px;
    height: 58px;
  }

  .vehicle-lightbox__layout {
    position: relative;
    display: block;
    width: 100%;
    height: 100%;
    overflow: hidden;
  }

  .vehicle-lightbox .vehicle-gallery-viewer {
    width: 100%;
    height: 100dvh;
    margin: 0;
    padding: 0;
    overflow: hidden;
  }

  .vehicle-lightbox .vehicle-gallery-viewer figure {
    width: 100%;
    height: 100%;
    margin: 0;
    border-radius: 0;
    background: var(--ink);
  }

  .vehicle-lightbox .vehicle-gallery-viewer img {
    width: 100%;
    height: 100%;
    max-height: 100%;
    object-fit: contain;
  }

  .vehicle-lightbox__thumbs {
    position: static;
    display: block;
    width: 0;
    height: 0;
    min-height: 0;
    padding: 0;
    overflow: visible;
    background: transparent;
  }

  .vehicle-lightbox__thumbs button {
    display: none;
  }

  .vehicle-lightbox__thumbs > [data-photo-counter] {
    position: fixed;
    z-index: 3;
    top: max(14px, env(safe-area-inset-top));
    left: 16px;
    padding: 7px 10px;
    border-radius: 9px;
    background: color-mix(in srgb, var(--ink) 72%, transparent);
  }

  .vehicle-lightbox__info {
    display: contents;
  }

  .vehicle-lightbox__info > :not([data-photo-close]) {
    display: none !important;
  }

  .vehicle-lightbox [data-photo-close] {
    position: fixed;
    z-index: 3;
    top: max(8px, env(safe-area-inset-top));
    right: 8px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: color-mix(in srgb, var(--ink) 72%, transparent);
  }

  .vehicle-lightbox__nav {
    position: fixed;
    z-index: 3;
    top: 50%;
    display: grid !important;
    place-items: center;
    width: 42px;
    height: 52px;
    padding: 0;
    transform: translateY(-50%);
    border: 0;
    border-radius: 12px;
    background: color-mix(in srgb, var(--ink) 64%, transparent);
    color: var(--surface);
  }

  .vehicle-lightbox__nav--prev {
    left: 8px;
  }

  .vehicle-lightbox__nav--prev svg {
    transform: rotate(180deg);
  }

  .vehicle-lightbox__nav--next {
    right: 8px;
  }

  .vehicle-lightbox__nav:disabled {
    opacity: .28;
  }

  .vehicle-sidebar {
    padding: 18px;
    border-radius: 18px;
    overflow: visible;
  }

  .vehicle-facts {
    grid-template-columns: minmax(0, 1fr);
  }

  .vehicle-specs > div {
    grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  }

  .vehicle-tip__bubble {
    max-width: calc(100vw - 64px);
  }

  /* Dedicated mobile vehicle page. Desktop keeps the established grid. */
  body:has(.vehicle-page) {
    background: #f2f3f5;
  }

  body:has(.vehicle-page) > .site-header {
    display: none;
  }

  body:has(.vehicle-page) > .container {
    padding: 0 0 calc(92px + env(safe-area-inset-bottom));
    background: #f2f3f5;
  }

  .vehicle-page {
    background: #f2f3f5;
  }

  .vehicle-mobile-header {
    position: sticky;
    z-index: 80;
    top: 0;
    display: grid !important;
    grid-template-columns: 48px minmax(0, 1fr) auto;
    align-items: center;
    height: 56px;
    padding: env(safe-area-inset-top) 10px 0;
    background: #fff;
  }

  .vehicle-mobile-header > button,
  .vehicle-mobile-header > div > button,
  .vehicle-mobile-header summary {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    border-radius: 12px;
    background: transparent;
    color: #16181d;
    list-style: none;
  }

  .vehicle-mobile-header > button svg {
    width: 23px;
    transform: rotate(180deg);
  }

  .vehicle-mobile-header > a {
    justify-self: center;
  }

  .vehicle-mobile-header > a img {
    display: block;
    width: 116px;
    height: 32px;
    object-fit: contain;
  }

  .vehicle-mobile-header > div {
    display: flex;
    align-items: center;
  }

  .vehicle-mobile-header > div > button svg {
    width: 22px;
  }

  .vehicle-mobile-header details {
    position: relative;
  }

  .vehicle-mobile-header summary {
    font-size: 27px;
    line-height: 1;
    cursor: pointer;
  }

  .vehicle-mobile-header summary::-webkit-details-marker {
    display: none;
  }

  .vehicle-mobile-header nav {
    position: absolute;
    top: 48px;
    right: 0;
    width: 210px;
    padding: 8px;
    border: 1px solid #e2e4e8;
    border-radius: 14px;
    background: #fff;
  }

  .vehicle-mobile-header nav a {
    display: block;
    padding: 11px 12px;
    border-radius: 9px;
    color: #16181d;
    text-decoration: none;
  }

  .vehicle-breadcrumb {
    box-sizing: border-box;
    width: 100%;
    margin: 0;
    padding: 8px 14px 10px;
    background: #fff;
    color: #747983;
    font-size: 12px;
    line-height: 18px;
  }

  .vehicle-page__layout {
    display: flex !important;
    flex-direction: column;
    gap: 8px;
    width: 100%;
  }

  .vehicle-page__layout > .vehicle-gallery {
    display: none;
  }

  .vehicle-mobile-gallery {
    position: relative;
    order: 1;
    display: block !important;
    padding: 0 0 14px 14px;
    overflow: hidden;
    background: #fff;
  }

  .vehicle-mobile-gallery__track {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-left: 0;
    overscroll-behavior-inline: contain;
    scrollbar-width: none;
  }

  .vehicle-mobile-gallery__track::-webkit-scrollbar {
    display: none;
  }

  .vehicle-mobile-gallery__track button {
    position: relative;
    flex: 0 0 calc(100% - 28px);
    aspect-ratio: 4 / 3;
    padding: 0;
    overflow: hidden;
    scroll-snap-align: start;
    border: 0;
    border-radius: 15px;
    background: #e8e9eb;
  }

  .vehicle-mobile-gallery__track img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  .vehicle-mobile-gallery > span {
    position: absolute;
    z-index: 2;
    right: 44px;
    bottom: 26px;
    padding: 5px 9px;
    border-radius: 9px;
    background: rgba(18, 21, 27, .76);
    color: #fff;
    font-size: 12px;
    line-height: 16px;
  }

  .vehicle-sidebar,
  .vehicle-sections,
  .vehicle-info-pair.vehicle-services {
    display: contents !important;
  }

  .vehicle-price-card,
  .vehicle-title,
  .vehicle-facts,
  .vehicle-all-specs,
  .vehicle-mobile-history,
  .vehicle-story,
  .vehicle-question,
  .vehicle-equipment,
  .vehicle-service--calculation,
  .vehicle-credit {
    box-sizing: border-box;
    width: 100%;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: #fff !important;
    box-shadow: none !important;
  }

  .vehicle-price-card { order: 2; padding: 15px 16px 16px; }
  .vehicle-title { order: 3; padding: 16px; }
  .vehicle-facts { order: 4; padding: 14px 16px 18px !important; }
  .vehicle-all-specs { order: 5; padding: 14px 16px; }
  .vehicle-mobile-history { order: 6; display: block !important; padding: 18px 16px; }
  .vehicle-story { order: 7; padding: 18px 16px; }
  .vehicle-question { order: 8; padding: 18px 16px !important; }
  .vehicle-equipment { order: 9; padding: 18px 16px; }
  .vehicle-service--calculation { order: 10; padding: 18px 16px !important; }
  .vehicle-credit { order: 11; padding: 20px 16px 22px !important; }

  .vehicle-price-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
  }

  .vehicle-price {
    margin: 0;
    font-size: 28px;
    line-height: 34px;
    white-space: nowrap;
  }

  .vehicle-more-menu {
    position: relative;
    flex: 0 0 auto;
  }

  .vehicle-more-menu > summary {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: #f0f1f3;
    font-size: 27px;
    line-height: 1;
    list-style: none;
    cursor: pointer;
  }

  .vehicle-more-menu > summary::-webkit-details-marker { display: none; }

  .vehicle-more-menu > div {
    position: absolute;
    z-index: 12;
    top: 48px;
    right: 0;
    width: 238px;
    padding: 8px;
    border: 1px solid #e1e3e7;
    border-radius: 14px;
    background: #fff;
  }

  .vehicle-more-menu button {
    width: 100%;
    min-height: 42px;
    padding: 9px 10px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #16181d;
    font: inherit;
    text-align: left;
  }

  .vehicle-price-card .card-offer {
    margin-top: 10px;
  }

  .vehicle-price-card .vehicle-tip,
  .vehicle-price-card > p {
    margin-top: 9px;
  }

  .vehicle-price-note,
  .vehicle-source-line {
    margin-bottom: 0;
    color: #727883;
    font-size: 12px;
    line-height: 17px;
  }

  .vehicle-price-card > .vehicle-contacts {
    display: none;
  }

  .vehicle-title__row {
    display: block;
  }

  .vehicle-title__desktop-heading,
  .vehicle-facts--desktop,
  .vehicle-question--desktop,
  .vehicle-spec-title--desktop,
  .vehicle-spec-label--desktop,
  .vehicle-equipment-title--desktop,
  .vehicle-cost-title--desktop,
  .vehicle-cost-action--desktop {
    display: none !important;
  }

  .vehicle-title__mobile-heading,
  .vehicle-spec-title--mobile,
  .vehicle-spec-label--mobile,
  .vehicle-equipment-title--mobile,
  .vehicle-cost-title--mobile,
  .vehicle-cost-action--mobile {
    display: inline !important;
  }

  .vehicle-facts--mobile {
    display: grid !important;
  }

  .vehicle-question--mobile {
    display: block !important;
  }

  .vehicle-title h1 {
    margin: 0;
    font-size: 22px;
    line-height: 27px;
    letter-spacing: -.025em;
  }

  .vehicle-title .vehicle-actions,
  .vehicle-title > .vehicle-secondary {
    display: none;
  }

  .vehicle-modification {
    margin: 6px 0 0;
    color: #747983;
    font-size: 14px;
    line-height: 20px;
    overflow-wrap: anywhere;
  }

  .vehicle-page .vehicle-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 12px;
  }

  .vehicle-page .vehicle-fact {
    display: grid;
    grid-template-columns: 26px minmax(0, 1fr);
    gap: 9px;
    align-items: start;
  }

  .vehicle-page .vehicle-fact > svg {
    width: 23px;
    height: 23px;
    margin: 1px 0 0;
  }

  .vehicle-page .vehicle-fact strong {
    font-size: 15px;
    line-height: 19px;
  }

  .vehicle-page .vehicle-fact span {
    margin-top: 2px;
    color: #777d87;
    font-size: 12px;
    line-height: 16px;
  }

  .vehicle-spec-heading {
    display: block;
  }

  .vehicle-spec-heading h2 {
    display: none;
  }

  .vehicle-all-specs [data-spec-toggle] {
    width: 100%;
    min-height: 48px;
    justify-content: center;
    border: 0;
    border-radius: 13px;
    background: #eff0f2;
    color: #17191e;
    font-size: 15px;
  }

  .vehicle-all-specs.is-open {
    position: fixed;
    z-index: 2500;
    inset: 0;
    display: flex;
    flex-direction: column;
    padding: max(14px, env(safe-area-inset-top)) 16px max(18px, env(safe-area-inset-bottom));
    overflow: hidden;
  }

  .vehicle-all-specs.is-open .vehicle-spec-heading h2 {
    display: block;
    margin-bottom: 12px;
    font-size: 22px;
  }

  .vehicle-all-specs.is-open #vehicle-spec-content {
    flex: 1;
    margin-top: 14px;
    overflow-y: auto;
  }

  .vehicle-spec-groups {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .vehicle-mobile-history h2,
  .vehicle-story h2,
  .vehicle-question h2,
  .vehicle-equipment h2,
  .vehicle-credit h2 {
    margin: 0 0 14px !important;
    font-size: 21px !important;
    line-height: 26px !important;
  }

  .vehicle-mobile-history > p {
    margin: -6px 0 14px;
    color: #777d87;
    font-size: 12px;
  }

  .vehicle-mobile-history > div {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 2px 10px;
    margin-bottom: 14px;
  }

  .vehicle-mobile-history > div > span {
    grid-row: 1 / 3;
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: #eff0f2;
  }

  .vehicle-mobile-history svg { width: 20px; }
  .vehicle-mobile-history strong { font-size: 14px; line-height: 19px; }
  .vehicle-mobile-history small { color: #747983; font-size: 12px; line-height: 17px; }

  .vehicle-mobile-history > a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    border-radius: 12px;
    background: #17191e;
    color: #fff;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
  }

  .vehicle-story__heading {
    margin-bottom: 10px;
  }

  .vehicle-story:not(.is-expanded) .vehicle-story__intro {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 5;
  }

  .vehicle-story:not(.is-expanded) .vehicle-story__intro ~ .vehicle-story__intro,
  .vehicle-story:not(.is-expanded) .vehicle-story__seller {
    display: none;
  }

  .vehicle-story__toggle {
    display: inline-block !important;
    margin: 0 12px 0 0;
    padding: 8px 0;
    border: 0;
    background: transparent;
    color: #176b3c;
    font-size: 14px;
    font-weight: 600;
  }

  .vehicle-original-link {
    padding-block: 8px;
  }

  .vehicle-question__head {
    margin-bottom: 10px;
  }

  .vehicle-question__input {
    position: relative;
  }

  .vehicle-question textarea {
    box-sizing: border-box;
    width: 100%;
    height: 72px;
    min-height: 72px;
    max-height: 180px;
    padding: 13px 54px 13px 13px;
    overflow-y: auto;
    border: 1px solid #dfe2e6;
    border-radius: 14px;
    background: #f7f7f8;
    box-shadow: none;
    font-size: 15px;
    line-height: 20px;
    resize: none;
  }

  .vehicle-question__input > button {
    position: absolute;
    right: 8px;
    bottom: 8px;
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 11px;
    background: #178b4c;
    color: #fff;
  }

  .vehicle-question .vehicle-topics {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin: 12px 0 8px;
  }

  .vehicle-question .vehicle-topics button {
    min-height: 38px;
    padding: 7px 9px;
    border: 0;
    background: #eff0f2;
    color: #31353c;
    font-size: 12px;
    line-height: 16px;
  }

  .vehicle-topics__more {
    display: contents;
  }

  .vehicle-topics__more[hidden] {
    display: none;
  }

  .vehicle-question__more {
    padding: 5px 0;
    border: 0;
    background: transparent;
    color: #176b3c;
    font: inherit;
    font-size: 13px;
    font-weight: 600;
  }

  .vehicle-question .vehicle-secondary {
    margin: 8px 0 0;
    font-size: 11px;
    line-height: 15px;
  }

  .vehicle-equipment__note {
    margin: 0 0 12px;
  }

  .vehicle-equipment__categories {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 12px;
  }

  .vehicle-equipment__categories button {
    justify-content: flex-start;
    min-width: 0;
  }

  .vehicle-equipment__actions {
    display: block;
  }

  .vehicle-equipment__actions > .vehicle-secondary-button {
    width: 100%;
  }

  .vehicle-equipment__report {
    display: none;
  }

  .vehicle-service--inspection {
    display: none !important;
  }

  .vehicle-services > .vehicle-service--calculation {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 92px;
    min-height: 0;
    gap: 12px;
  }

  .vehicle-service--calculation .vehicle-service__body {
    display: contents;
  }

  .vehicle-service--calculation .vehicle-service__art {
    grid-column: 2;
    grid-row: 1 / 6;
    width: 92px;
    min-height: 0;
    padding: 0;
    background: transparent;
  }

  .vehicle-service--calculation .service-logo,
  .vehicle-service--calculation .service-stamp {
    display: none;
  }

  .vehicle-service--calculation .service-object {
    width: 92px;
    height: 110px;
    margin: auto 0;
  }

  .vehicle-service--calculation h2,
  .vehicle-service--calculation .vehicle-cost,
  .vehicle-service--calculation p,
  .vehicle-service--calculation .vehicle-secondary-button {
    grid-column: 1;
  }

  .vehicle-services .vehicle-cost {
    font-size: 20px;
    line-height: 25px;
  }

  .vehicle-services .vehicle-secondary-button {
    width: 100%;
    margin-top: 4px;
    min-height: 46px;
  }

  .vehicle-credit__heading {
    gap: 6px;
    margin-bottom: 18px;
  }

  .vehicle-credit__heading > p {
    font-size: 12px;
    line-height: 17px;
  }

  .vehicle-credit .credit-card__body {
    gap: 20px;
  }

  .vehicle-credit .credit-card__calc,
  .vehicle-credit .credit-lead-form {
    gap: 14px;
  }

  .vehicle-credit .credit-stats {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .vehicle-credit .credit-stats__divider {
    display: none;
  }

  .vehicle-credit .credit-lead-field input {
    height: 48px;
    font-size: 16px;
  }

  .vehicle-press {
    display: none;
  }

  .vehicle-page > .vehicle-similar {
    margin: 8px 0 0;
    padding: 18px 14px 24px;
    background: #fff;
  }

  .vehicle-page > .vehicle-similar h2 {
    margin: 0 0 14px;
    font-size: 21px;
  }

  .vehicle-page > .vehicle-similar .home-car-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 10px;
  }

  .vehicle-page > .vehicle-similar .car-card--home .car-card__photo {
    aspect-ratio: 4 / 3;
  }

  .vehicle-mobile-contact {
    position: fixed;
    z-index: 1200;
    right: 0;
    bottom: 0;
    left: 0;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 50px;
    gap: 8px;
    padding: 10px 14px max(10px, env(safe-area-inset-bottom));
    border-top: 1px solid #e3e5e8;
    background: rgba(255, 255, 255, .96);
    backdrop-filter: blur(14px);
  }

  .vehicle-mobile-contact .vehicle-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 50px;
    min-height: 50px;
    padding: 0 14px;
    border: 0;
    border-radius: 13px;
    background: #168b4b;
    color: #fff;
    text-decoration: none;
    font: inherit;
    font-size: 15px;
    font-weight: 600;
  }

  .vehicle-mobile-contact .vehicle-cta:last-child {
    padding: 0;
    background: #eff0f2;
    color: #16181d;
  }

  .vehicle-mobile-contact svg {
    width: 21px;
    height: 21px;
    margin-right: 8px;
  }

  .vehicle-mobile-contact .vehicle-cta:last-child svg {
    margin: 0;
  }

  body:has(dialog[open]) .vehicle-mobile-contact,
  body:has(.vehicle-all-specs.is-open) .vehicle-mobile-contact {
    display: none !important;
  }
}

@media (max-width: 600px) and (max-height: 520px) {
  .vehicle-mobile-contact {
    display: none !important;
  }
}

@media (max-width: 370px) {
  .site-header__logo {
    width: min(142px, calc(100vw - 142px));
    flex-basis: 142px;
  }

  .home-popular-cars__heading {
    grid-template-columns: minmax(0, 1fr);
  }

  .home-popular-cars__heading a {
    max-width: none;
    justify-self: start;
    text-align: left;
  }

  #catalog-filters .catalog-quick-cards {
    grid-template-columns: minmax(0, 1fr);
  }

  .catalog-list .catalog-card__footer {
    grid-template-columns: minmax(0, 1fr);
  }
}
