/* Use the same campaign carousel on desktop and mobile. */
.hero { display: none; }
.mobile-promotions { display: block; margin: 24px 0 0; }
.mobile-promo-track {
  display: flex; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory;
  overscroll-behavior-x: contain; scrollbar-width: none; border-radius: 18px;
}
.mobile-promo-track::-webkit-scrollbar { display: none; }
.mobile-promo {
  position: relative; isolation: isolate; flex: 0 0 100%; min-width: 0;
  height: min(48vw, 560px); min-height: 420px; max-height: 560px;
  overflow: hidden; border-radius: 18px; scroll-snap-align: start;
  background: #25232d; color: #fff; padding: clamp(34px, 5vw, 72px);
  display: flex; flex-direction: column; align-items: flex-start;
}
.mobile-promo::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, #19171ff2 0%, #19171fcf 38%, #19171f00 78%); }
.mobile-promo picture { position: absolute; inset: 0; z-index: -2; }
.mobile-promo img { width: 100%; height: 100%; object-fit: cover; object-position: 62% center; }
.mobile-promo .eyebrow { font-size: 10px; letter-spacing: 2px; color: #e0c7f3; }
.mobile-promo h1, .mobile-promo h2 { max-width: 62%; margin: 26px 0 16px; font-size: clamp(42px, 5vw, 68px); line-height: 1.08; letter-spacing: -2px; color: #fff; }
.mobile-promo h1 em, .mobile-promo h2 em { color: #d5afea; }
.mobile-promo p { max-width: 42%; font-size: 16px; line-height: 1.7; color: #e0dce4; margin: 0 0 24px; }
.mobile-promo .button { margin-top: auto; padding: 15px 18px; min-height: 48px; gap: 18px; border-radius: 8px; background: #fff; color: #302239; font-size: 13px; box-shadow: none; }
.mobile-promo-quote { background: #f0e9f5; color: #302239; }
.mobile-promo-quote::before { background: linear-gradient(90deg, #f3edf9 0%, #f3edf9f5 26%, #f3edf9b8 46%, #f3edf900 72%); }
.mobile-promo-quote img { object-position: 72% 28%; }
.mobile-promo-quote .eyebrow { color: #74518c; }
.mobile-promo-quote h2 { color: #302239; max-width: 55%; }
.mobile-promo-quote h2 em { color: #8056a5; }
.mobile-promo-quote p { max-width: 40%; color: #66566f; }
.mobile-promo-quote .button { background: #8056a5; color: #fff; }
.mobile-promo-controls { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; color: #908497; }
.mobile-promo-count { font-size: 11px; letter-spacing: 1px; }
.mobile-promo-dots { display: flex; }
.mobile-promo-dot { border: 0; background: none; width: 36px; height: 36px; padding: 13px 6px; }
.mobile-promo-dot::after { content: ""; display: block; width: 7px; height: 7px; margin: auto; background: #ded3e5; border-radius: 8px; }
.mobile-promo-dot[aria-current="true"]::after { width: 20px; background: #8056a5; }
.mobile-promo-arrows { display: flex; gap: 6px; }
.mobile-promo-arrows button { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid #eee8f2; border-radius: 50%; background: #fff; color: #8056a5; font-size: 20px; }
.mobile-header-tools { display: contents; }
.mobile-call-cta, .mobile-drawer-links, .mobile-menu-toggle, .mobile-navigation-dialog { display: none; }

@media (max-width: 600px) {
  html { scroll-padding-top: 145px; }
  .container { width: calc(100% - 32px); }

  /* Keep the store controls with the customer while the navigation scrolls away. */
  body > .header, body > .site-shell-header {
    position: sticky;
    top: 0;
    z-index: 40;
    background: #fff;
    box-shadow: 0 5px 22px #35223e0a;
  }
  .header-inner {
    display: grid;
    grid-template-columns: 36px minmax(0, 1fr) 36px auto;
    align-items: center;
    gap: 10px;
    padding: 10px 16px 12px;
  }
  .header-inner > .menu-toggle { grid-column: 1; grid-row: 1; width: 36px; height: 36px; }
  .header-inner > .brand { grid-column: 2; grid-row: 1; margin: 0; gap: 5px; font-size: 11px; }
  .header-inner .brand-symbol { width: 31px; height: 30px; }
  .header-inner .brand-symbol img { width: 47px; left: -8px; top: -6px; }
  .header-inner .brand > div:last-child > span { font-size: 10px; letter-spacing: 2.1px; }
  .header-divider { display: none; }
  .header-inner > .account-wrap { grid-column: 3; grid-row: 1; }
  .account-button { width: 36px; height: 40px; justify-content: center; }
  .account-button > span { display: none; }
  .header-inner > .cart-button { grid-column: 4; grid-row: 1; gap: 8px; padding-left: 10px; min-height: 36px; }
  .cart-button .icon { width: 21px; height: 21px; }
  .header .cart-button small { display: none; }
  .header .cart-button strong { font-size: 10px; }
  .mobile-header-tools {
    grid-column: 1 / -1; grid-row: 2; display: grid;
    grid-template-columns: minmax(0, .85fr) minmax(0, 1.4fr); gap: 8px;
  }
  .header-inner .vehicle-button {
    order: 0;
    width: 100%;
    max-width: none;
    min-width: 0;
    min-height: 45px;
    padding: 7px 9px;
    border: 1px solid #e9e1ef;
    border-radius: 9px;
    gap: 6px;
  }
  .vehicle-button > span { min-width: 0; flex: 1; }
  .header .vehicle-button small { margin-bottom: 3px; font-size: 7px; }
  .header .vehicle-button strong { display: block; max-width: none; overflow: hidden; text-overflow: ellipsis; font-size: 10px; }
  .header-inner .search-form {
    order: 0;
    min-width: 0;
    min-height: 45px;
    gap: 4px;
    padding: 4px 4px 4px 9px;
    border-radius: 9px;
  }
  .search-form > .icon { display: none; }
  .search-form input { font-size: 12px; width: 100%; height: 34px; }
  .search-form button { width: 30px; height: 34px; }

  /* Keep just the two primary actions outside the hamburger menu. */
  .navigation .nav-inner, .shell-navigation .shell-nav-inner {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    height: auto;
    min-height: 0;
    padding: 10px 0;
    overflow: visible;
    white-space: normal;
  }
  .navigation .nav-inner > *, .shell-nav-inner > a { min-width: 0; margin: 0; }
  .navigation .nav-inner > :not(.quote-cta), .shell-nav-inner > :not(.quote-cta) { display: none; }
  .navigation .nav-inner > .quote-cta, .shell-nav-inner > .quote-cta { grid-column: auto; }
  .navigation .nav-inner > .mobile-call-cta, .shell-navigation .shell-nav-inner > .mobile-call-cta { display: inline-flex; }
  .navigation .nav-inner > [data-open="categories"], .navigation .nav-trigger,
  .site-shell-header .shell-nav-inner > a:not(.quote-cta),
  .mobile-shell-navigation .shell-nav-inner > a:not(.quote-cta) {
    width: 100%; min-height: 38px; padding: 8px 10px; justify-content: space-between;
    border: 1px solid #eee8f2; border-radius: 8px; background: #faf8fc;
    font-size: 11px; font-weight: 600; gap: 6px; line-height: 1.3;
  }
  /* The shared desktop navigation styles are more specific; keep its links in the drawer on phones. */
  .mobile-shell-navigation .shell-nav-inner > a:not(.quote-cta) { display: none; }
  .navigation .nav-inner > [data-open="categories"] { justify-content: flex-start; }
  .nav-inner > [data-open="categories"] .icon:last-child { display: none; }
  .nav-dropdown { position: static; }
  .navigation .nav-offers { justify-content: center; padding: 8px 2px; font-size: 10px; min-height: 40px; gap: 5px; }
  .navigation .nav-offers .icon { width: 14px; }
  .navigation .quote-cta, .site-shell-header .quote-cta, .mobile-shell-navigation .quote-cta {
    display: inline-flex; width: 100%; min-height: 44px; margin: 0; padding: 10px; border-radius: 8px;
    font-size: 10px; letter-spacing: .3px; gap: 7px; box-shadow: none;
  }
  .quote-cta > span:last-child { font-size: 17px; }
  .navigation .nav-trigger::after, .navigation .nav-offers::after,
  .site-shell-header .shell-nav-inner > a::after { display: none; }
  .nav-submenu { left: 16px; right: 16px; max-height: 55vh; }

  /* Shared headers on contact, quote and account pages. */
  .site-shell-inner { width: calc(100% - 32px); grid-template-columns: 36px minmax(0, 1fr) 36px auto; padding: 10px 0; gap: 10px; }
  .site-shell-inner > .shell-brand { grid-column: 2; grid-row: 1; }
  .site-shell-inner > .shell-account-wrap { grid-column: 3; grid-row: 1; }
  .site-shell-inner > .site-shell-cart { grid-column: 4; grid-row: 1; }
  .site-shell-header .shell-vehicle { grid-column: 1 / 3; grid-row: 2; margin: 0; padding: 6px 8px; }
  .site-shell-header .shell-vehicle svg { display: none; }
  .site-shell-header .site-shell-search { grid-column: 3 / 5; grid-row: 2; }
  .site-shell-account > span:not(.shell-account-chevron) { display: none; }
  .site-shell-cart small { display: none; }
  .mobile-shell-navigation { border-bottom: 1px solid #eeebf1; }
  .mobile-menu-toggle { grid-column: 1; grid-row: 1; display: grid; place-items: center; width: 36px; height: 36px; padding: 7px; border: 1px solid #e9e1ef; border-radius: 10px; background: #faf8fc; color: #65427d; cursor: pointer; }
  .mobile-drawer-links { display: grid; gap: 7px; margin: 18px 0; }
  .mobile-drawer-links > a { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 46px; padding: 12px 14px; border: 1px solid #eee8f2; border-radius: 9px; background: #faf8fc; color: #493951; font-size: 12px; font-weight: 600; line-height: 1.5; }
  .mobile-drawer-links > a::after { content: "›"; font-size: 19px; color: #9471ba; }
  .mobile-drawer-links > a:hover { background: #f0e8f6; }
  .mobile-navigation-dialog[open] { display: block; position: fixed; inset: 0 auto 0 0; margin: 0; width: min(380px, 92vw); height: 100%; max-height: 100%; border: 0; border-right: 1px solid #e9e1ef; padding: 24px 16px; background: #fff; color: #25232d; box-shadow: 16px 0 50px #21162b24; }
  .mobile-navigation-dialog::backdrop { background: #23172a66; backdrop-filter: blur(4px); }
  .mobile-navigation-dialog .panel-heading { padding-bottom: 16px; border-bottom: 1px solid #eee8f2; }
  .mobile-navigation-dialog h2 { margin: 0; font-size: 23px; }
  .mobile-navigation-dialog .icon-button { min-width: 44px; min-height: 44px; font-size: 26px; }
  body.mobile-nav-open { overflow: hidden; }

  .hero { display: none; }
  .mobile-promotions { display: block; margin: 16px 0 0; }
  .mobile-promo-track {
    display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory;
    overscroll-behavior-x: contain; scrollbar-width: none; border-radius: 14px;
    -webkit-overflow-scrolling: touch;
  }
  .mobile-promo-track::-webkit-scrollbar { display: none; }
  .mobile-promo {
    position: relative; isolation: isolate; flex: 0 0 100%; min-width: 0;
    height: auto; min-height: 278px; max-height: none; overflow: hidden; border-radius: 14px; scroll-snap-align: start;
    background: #25232d; color: #fff; padding: 25px 21px;
    display: flex; flex-direction: column; align-items: flex-start;
  }
  .mobile-promo::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, #19171fe8 0%, #19171fbf 40%, #19171f00 100%); }
  .mobile-promo picture { position: absolute; inset: 0; z-index: -2; }
  .mobile-promo img { width: 100%; height: 100%; object-fit: cover; object-position: 62% center; }
  .mobile-promo .eyebrow { font-size: 7px; letter-spacing: 1.5px; color: #e0c7f3; }
  .mobile-promo h1, .mobile-promo h2 { max-width: 74%; margin: 18px 0 11px; font-size: clamp(26px, 7.4vw, 34px); line-height: 1.12; letter-spacing: -1px; color: #fff; }
  .mobile-promo h1 em, .mobile-promo h2 em { color: #d5afea; }
  .mobile-promo p { max-width: 64%; font-size: 11px; line-height: 1.7; color: #e0dce4; margin: 0 0 18px; }
  .mobile-promo .button { margin-top: auto; padding: 11px 13px; min-height: 40px; gap: 14px; border-radius: 7px; background: #fff; color: #302239; font-size: 10px; box-shadow: none; }
  .mobile-promo-quote { background: #f0e9f5; color: #302239; }
  .mobile-promo-quote::before { background: linear-gradient(90deg, #f3edf9 0%, #f3edf9f5 26%, #f3edf9b8 46%, #f3edf900 72%); }
  .mobile-promo-quote img { object-position: 65% 28%; }
  .mobile-promo-quote .eyebrow { color: #74518c; }
  .mobile-promo-quote h2 { color: #302239; max-width: 64%; }
  .mobile-promo-quote h2 em { color: #8056a5; }
  .mobile-promo-quote p { max-width: 52%; color: #66566f; }
  .mobile-promo-quote .button { background: #8056a5; color: #fff; }
  .mobile-promo-controls { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; color: #908497; }
  .mobile-promo-count { font-size: 10px; letter-spacing: 1px; }
  .mobile-promo-dots { display: flex; }
  .mobile-promo-dot { border: 0; background: none; width: 32px; height: 32px; padding: 12px 6px; }
  .mobile-promo-dot::after { content: ""; display: block; width: 7px; height: 7px; margin: auto; background: #ded3e5; border-radius: 8px; }
  .mobile-promo-dot[aria-current="true"]::after { width: 20px; background: #8056a5; }
  .mobile-promo-arrows { display: flex; gap: 4px; }
  .mobile-promo-arrows button { display: grid; place-items: center; width: 32px; height: 32px; border: 1px solid #eee8f2; border-radius: 50%; background: #fff; color: #8056a5; font-size: 18px; }

  .benefits { margin-top: 12px; padding: 16px 0; gap: 18px 12px; }
  .benefits > div { padding: 0; gap: 8px; border: 0; }
  .benefits .icon { width: 23px; height: 23px; }
  .benefits strong { font-size: 10px; }
  .benefits small { font-size: 9px; line-height: 1.5; }
  .section-heading { gap: 14px; align-items: flex-start; }
  .section-heading h2, .contact-section .section-heading h2 { font-size: 23px; line-height: 1.2; letter-spacing: -.7px; }
  .section-heading .text-button { flex-shrink: 0; font-size: 10px; max-width: 110px; gap: 8px; }
  .products-section .section-heading { flex-wrap: wrap; }
  .product-tabs { padding: 4px; }
  .product-tabs button { min-height: 36px; padding: 8px 12px; font-size: 11px; }

  /* Contact links and a small map share the same card. */
  .contact-section { padding: 24px 0 28px; }
  .contact-layout:has(.contact-methods) { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 12px; padding: 18px 14px; border-radius: 14px; }
  .contact-layout:has(.contact-methods) .contact-details { display: contents; }
  .contact-layout:has(.contact-methods) .contact-details > h3 { grid-column: 1 / -1; margin: 0; font-size: 19px; }
  .contact-layout:has(.contact-methods) .contact-details > p { grid-column: 1 / -1; margin: 0 0 3px; font-size: 11px; line-height: 1.7; }
  .contact-methods { grid-column: 1; margin: 0; gap: 8px; }
  .contact-method { padding: 8px; min-height: 57px; gap: 7px; }
  .contact-method-icon { flex-basis: 26px; width: 26px; height: 30px; border-radius: 7px; }
  .contact-method-icon svg { width: 15px; height: 15px; }
  .contact-method small { font-size: 9px; letter-spacing: 0; }
  .contact-method strong { font-size: 10px; line-height: 1.5; text-decoration: underline; text-decoration-color: #cfbadf; text-underline-offset: 3px; }
  .contact-details address { grid-column: 1; padding: 8px; margin: 0; gap: 7px; font-size: 10px; line-height: 1.6; }
  .contact-details address .contact-method-icon { flex-basis: 26px; }
  .contact-actions { grid-column: 1 / -1; gap: 14px; margin: 2px 0 0; }
  .contact-actions .button { min-height: 40px; padding: 10px 12px; font-size: 10px; }
  .contact-actions .text-button { font-size: 10px; }
  .contact-layout:has(.contact-methods) .map-panel { grid-column: 2; grid-row: 3 / 5; padding: 10px; border-radius: 10px; min-height: 0; justify-content: flex-start; }
  .contact-layout:not(:has(.contact-methods)) { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 12px; padding: 18px 14px; }
  .contact-layout:not(:has(.contact-methods)) .contact-details { display: contents; }
  .contact-layout:not(:has(.contact-methods)) .contact-details > h3,
  .contact-layout:not(:has(.contact-methods)) .contact-details > p { grid-column: 1 / -1; margin: 0; }
  .contact-layout:not(:has(.contact-methods)) .contact-details > h3 { font-size: 19px; }
  .contact-layout:not(:has(.contact-methods)) .contact-details > p { font-size: 11px; }
  .contact-layout:not(:has(.contact-methods)) .contact-details > a { grid-column: 1; min-width: 0; font-size: 11px; line-height: 1.6; padding: 8px 0; overflow-wrap: anywhere; }
  .contact-layout:not(:has(.contact-methods)) .contact-phone { font-size: 16px; }
  .contact-layout:not(:has(.contact-methods)) .map-panel { grid-column: 2; grid-row: 3 / 6; padding: 10px; border-radius: 10px; justify-content: flex-start; }
  .map-panel { min-height: 0; padding: 16px; }
  .map-panel .eyebrow { font-size: 7px; letter-spacing: .8px; line-height: 1.6; margin-bottom: 8px; }
  .map-panel iframe { height: 170px; min-height: 0; border-radius: 7px; }
  .map-panel > a { margin-top: 9px; font-size: 9px; line-height: 1.5; overflow-wrap: anywhere; }
  .map-panel > a:last-child { font-size: 8px; color: #81708d; }

  .site-footer { padding: 24px 0 72px; }
  .footer-columns { grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 24px 18px; font-size: 11px; }
  .footer-columns > div:first-child { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: 4px 12px; padding-bottom: 18px; border-bottom: 1px solid #eee8f2; }
  .footer-columns .footer-brand { font-size: 12px; align-self: end; }
  .footer-columns > div:first-child > p:first-of-type { grid-column: 1; font-size: 10px; }
  .footer-columns > div:first-child > p:last-of-type { grid-column: 2; grid-row: 1 / 3; font-size: 9px; align-self: center; text-align: right; line-height: 1.8; }
  .footer-columns h3 { color: #3b2c46; margin: 0 0 12px; font-size: 12px; line-height: 1.5; }
  .footer-columns nav a, .footer-columns > div > a:not(.footer-brand) { margin: 0; padding: 7px 0; min-height: 32px; line-height: 1.6; color: #73647e; }
  .footer-columns > div:last-child > p { margin-top: 4px; font-size: 10px; line-height: 1.7; }
  .footer-columns a[href^="tel:"], .footer-columns a[href^="mailto:"] { color: #8056a5; text-decoration: underline; text-decoration-color: #dac9e5; text-underline-offset: 3px; }
  .consumer-links { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 22px; padding: 18px 0 0; font-size: 10px; line-height: 1.7; }
  .consumer-links img { width: 100%; height: auto; }
}

@media (max-width: 360px) {
  .navigation .quote-cta, .mobile-shell-navigation .quote-cta { font-size: 9px; padding: 9px 6px; gap: 5px; }
  .header-inner { gap: 7px; padding-right: 12px; padding-left: 12px; }
  .header-inner > .brand { font-size: 10px; gap: 2px; }
  .header-inner .brand > div:last-child > span { font-size: 9px; }
  .header .cart-button strong { font-size: 9px; }
  .mobile-promo { padding: 22px 17px; min-height: 268px; }
  .mobile-promo h1, .mobile-promo h2 { font-size: 26px; }
  .mobile-promo p { font-size: 10px; }
  .contact-method-icon { display: none; }
  .footer-columns { gap: 20px 12px; }
}

/* On phones, keep the shared header compact and put every navigation action in its drawer. */
@media (max-width: 600px) {
  .mobile-shell-navigation { display: none !important; }
  .mobile-drawer-links > a.quote-cta {
    justify-content: center;
    min-height: 50px;
    border-color: #8953ae;
    background: linear-gradient(110deg, #56316f, #8953ae 55%, #a77ac7);
    color: #fff;
    font-size: 12px;
  }
  .mobile-drawer-links > a.quote-cta::after { color: currentColor; }
}

@media (prefers-reduced-motion: reduce) {
  .mobile-promo-track { scroll-behavior: auto; }
}

/* Final phone layout: give each shared-header control its own usable row. */
@media (max-width: 600px) {
  html, body { max-width: 100%; overflow-x: clip; }
  .site-shell-header { width: 100%; }
  .site-shell-inner {
    width: calc(100% - 28px);
    grid-template-columns: 40px minmax(0, 1fr) 38px auto;
    gap: 8px;
    padding: 10px 0 12px;
  }
  .site-shell-inner > .mobile-menu-toggle { grid-column: 1; grid-row: 1; }
  .site-shell-inner > .shell-brand { grid-column: 2; grid-row: 1; min-width: 0; }
  .site-shell-inner > .shell-account-wrap { grid-column: 3; grid-row: 1; }
  .site-shell-inner > .site-shell-cart { grid-column: 4; grid-row: 1; min-width: 0; padding-left: 8px; gap: 6px; }
  .site-shell-cart strong { font-size: 10px; }
  .site-shell-header .shell-vehicle {
    grid-column: 1 / -1; grid-row: 2; width: 100%; min-width: 0; min-height: 42px;
    overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
  }
  .site-shell-header .shell-vehicle strong { max-width: none; overflow: hidden; text-overflow: ellipsis; }
  .site-shell-header .site-shell-search { grid-column: 1 / -1; grid-row: 3; width: 100%; min-width: 0; }
  .site-shell-header .site-shell-search input { min-width: 0; font-size: 13px; }
  .mobile-menu-toggle { width: 40px; height: 40px; }

  /* Keep the account panel within the viewport, even on narrow phones. */
  .site-shell-header .shell-account-menu:not([hidden]) {
    position: fixed;
    z-index: 80;
    top: var(--shell-account-menu-top, 112px);
    right: max(12px, env(safe-area-inset-right, 0px));
    left: auto;
    width: min(290px, calc(100vw - 24px));
    max-width: none;
    max-height: calc(100dvh - var(--shell-account-menu-top, 112px) - 12px);
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }

  /* Contact information reads top-to-bottom instead of squeezing into columns. */
  .contact-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
    padding: 20px 16px;
  }
  .contact-layout .contact-details { display: contents; }
  .contact-layout .contact-details > *, .contact-layout .map-panel { grid-column: 1; grid-row: auto; width: 100%; min-width: 0; }
  .contact-layout .contact-details > h3 { font-size: 21px; }
  .contact-layout .contact-details > p { font-size: 13px; line-height: 1.7; }
  .contact-layout .contact-details > a { padding: 7px 0; font-size: 13px; overflow-wrap: anywhere; }
  .contact-layout .contact-details address { padding: 0; font-size: 12px; }
  .contact-layout .contact-actions { flex-wrap: wrap; margin-top: 4px; }
  .contact-layout .map-panel { padding: 12px; }
  .contact-layout .map-panel iframe { height: 220px; }

  /* Category cards keep readable labels and consistent image proportions. */
  .category-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .category-card { min-width: 0; min-height: 0; padding: 0 0 13px !important; border-radius: 12px; }
  .category-card .category-photo, .category-card .category-photo-placeholder { width: 100%; height: clamp(92px, 30vw, 132px); }
  .category-card strong, .category-card small { margin-left: 11px; margin-right: 11px; }
  .category-card strong { margin-top: 11px; font-size: 12px; line-height: 1.35; overflow-wrap: anywhere; }
  .category-card small { margin-top: 4px; font-size: 10px; line-height: 1.45; }
  .category-card .category-arrow { width: 30px; height: 30px; }
  .mobile-navigation-dialog[open] { width: min(380px, calc(100vw - 24px)); padding: 20px 16px calc(24px + env(safe-area-inset-bottom, 0px)); overflow-y: auto; }
  .mobile-drawer-links > a { min-height: 50px; font-size: 14px; }
}

@media (max-width: 360px) {
  .site-shell-inner { width: calc(100% - 24px); grid-template-columns: 38px minmax(0, 1fr) 34px auto; gap: 6px; }
  .site-shell-inner > .mobile-menu-toggle { width: 38px; height: 38px; }
  .site-shell-inner > .shell-account-wrap, .site-shell-inner > .shell-account-wrap .site-shell-account { width: 34px; }
  .site-shell-header .site-shell-cart { padding-left: 6px; }
  .shell-brand { gap: 3px; font-size: 10px; }
  .shell-brand > span:last-child > span { font-size: 9px; letter-spacing: 1.8px; }
  .shell-logo { width: 29px; height: 29px; }
  .shell-logo img { width: 45px; left: -8px; top: -7px; }
  .category-grid { gap: 9px; }
  .category-card strong { font-size: 11px; }
}

/* Consistent, usable layouts for every public page on phones and small tablets. */
@media (max-width: 850px) {
  .account-main, .information-page, .offer-page { min-width: 0; }
  .account-grid, .checkout-layout, .product-detail { min-width: 0; }
  .account-grid { grid-template-columns: minmax(0, 1fr); }
  .checkout-layout { grid-template-columns: minmax(0, 1.2fr) minmax(240px, .8fr); }
  .product-detail { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .product-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .account-card, .request-offer-form, .return-form-card { min-width: 0; }
  .account-orders { min-width: 560px; }
  .account-overflow { max-width: 100%; overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch; }
  .drawer { width: min(380px, 92vw); max-width: 92vw; }
  .drawer-category-group, .drawer-category-group > div, .drawer-category { min-width: 0; }
  .drawer-category .category-copy { overflow-wrap: anywhere; }
}

@media (max-width: 650px) {
  html { scroll-padding-top: 125px; }
  body, #app, main { min-width: 0; }
  img, video, iframe, svg { max-width: 100%; }
  .container, .information-page, .customer-document, .account-main, .offer-page {
    width: calc(100% - 32px);
    max-width: 100%;
  }

  /* Keep page controls reachable while moving through account and help pages. */
  body > .site-shell-header {
    position: sticky;
    top: 0;
    z-index: 40;
    background: #fff;
    box-shadow: 0 5px 22px #35223e0a;
  }
  .site-shell-inner { min-width: 0; }
  .site-shell-header .mobile-shell-navigation { display: none !important; }
  .mobile-navigation-dialog[open] { left: 0; right: auto; width: min(380px, calc(100vw - 24px)); max-width: calc(100vw - 24px); }

  /* Full-width contact information prevents the map and contact text colliding. */
  .information-page .contact-layout,
  .information-page .contact-layout:has(.contact-methods),
  .information-page .contact-layout:not(:has(.contact-methods)) {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
    width: 100%;
    padding: 18px 15px;
  }
  .information-page .contact-layout .contact-details { display: contents; }
  .information-page .contact-layout .contact-details > *,
  .information-page .contact-layout .map-panel {
    grid-column: 1 / -1;
    grid-row: auto;
    width: 100%;
    min-width: 0;
  }
  .information-page .contact-layout .map-panel iframe { height: 230px; }
  .information-page .contact-layout .contact-details > a { overflow-wrap: anywhere; }
  .information-page .contact-layout .contact-phone { font-size: clamp(20px, 6vw, 26px); }

  /* Stack account, checkout, product and offer content in reading order. */
  .account-main { padding: 24px 0 42px; }
  .account-layout, .account-grid, .checkout-layout, .product-detail {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }
  .account-header { align-items: stretch; gap: 12px; margin-bottom: 20px; }
  .account-header h1 { font-size: clamp(25px, 7vw, 31px); overflow-wrap: anywhere; }
  .account-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(135px, 1fr)); }
  .account-actions .button, .account-form > button, .request-offer-form > button { width: 100%; min-height: 46px; }
  .account-card { padding: clamp(16px, 5vw, 22px); }
  .account-form, .request-offer-form { min-width: 0; }
  .account-form-grid { grid-template-columns: minmax(0, 1fr); }
  .account-form-grid > *, .request-offer-form > *, .span-all { min-width: 0; }
  .account-form input:not([type="checkbox"]), .account-form select, .account-form textarea,
  .request-offer-form input:not([type="checkbox"]), .request-offer-form select, .request-offer-form textarea {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    min-height: 46px;
    font-size: 16px;
  }
  .account-form-grid .span-all, .request-offer-form .span-all { grid-column: 1 / -1; }
  .checkout-item, .checkout-total { gap: 12px; overflow-wrap: anywhere; }
  .checkout-item > :last-child, .checkout-total > :last-child { text-align: right; }
  .product-detail-art { width: 100%; height: min(88vw, 420px); min-height: 250px; }
  .product-detail-copy, .product-buy-panel { min-width: 0; }
  .product-detail h1 { font-size: clamp(25px, 7vw, 30px); overflow-wrap: anywhere; }
  .product-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .product-facts > div { min-width: 0; overflow-wrap: anywhere; }
  .product-back-link { max-width: 46%; text-align: right; }
  .offer-page .request-offer { grid-template-columns: minmax(0, 1fr); gap: 18px; margin: 18px 0; padding: 20px 15px; }
  .offer-page .request-offer-form { grid-template-columns: minmax(0, 1fr); padding: 17px 13px; }
  .offer-page .request-offer-form > * { grid-column: 1 / -1; }
  .offer-page .request-offer-copy h1 { font-size: clamp(27px, 8vw, 36px); }
  .vin-field-row { display: grid; grid-template-columns: minmax(0, 1fr); }
  .vin-field-row > * { width: 100%; min-width: 0; }

  /* Legal documents use readable body text and never create oversized headings. */
  .customer-document { padding-top: 25px; padding-bottom: 40px; }
  .customer-document > h1, .information-page > h1 { font-size: clamp(27px, 8vw, 38px); line-height: 1.13; letter-spacing: -1px; overflow-wrap: anywhere; }
  .document-company { padding: 13px; font-size: 12px; overflow-wrap: anywhere; }
  .document-copy { width: 100%; max-width: 100%; margin-top: 24px; font-size: 14px; line-height: 1.8; overflow-wrap: anywhere; }
  .document-copy h2 { margin: 25px 0 9px; font-size: clamp(17px, 5vw, 20px); line-height: 1.38; letter-spacing: -.2px; overflow-wrap: anywhere; }
  .document-copy h3 { font-size: 16px; line-height: 1.4; overflow-wrap: anywhere; }
  .document-copy p, .document-copy li { overflow-wrap: anywhere; }
  .document-callout { margin: 18px 0; padding: 15px; font-size: 13px; overflow-wrap: anywhere; }
  .return-forms { margin: 23px 0 18px; padding: 16px 12px; border-radius: 14px; }
  .return-forms-heading { align-items: flex-start; gap: 10px; }
  .return-forms-heading h2 { font-size: 22px; }
  .return-mode-switch { gap: 4px; }
  .return-mode-button { padding: 7px 5px; font-size: 11px; }
  .return-form-card { padding: 15px 12px; }
  .return-form-actions { display: grid; grid-template-columns: 1fr 1fr; }
  .return-form-actions > * { width: 100%; }
  .consumer-links { grid-template-columns: minmax(0, 1fr); }
  .consumer-links img { max-width: 100%; height: auto; }
  .account-compact-footer { gap: 12px; padding: 18px 0 calc(20px + env(safe-area-inset-bottom, 0px)); }
  .whatsapp-float { right: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); }

  /* Keep category browsing inside the viewport and avoid sideways drawer content. */
  .drawer { left: 0; right: auto; width: min(380px, calc(100vw - 24px)); max-width: calc(100vw - 24px); padding: 20px 14px calc(24px + env(safe-area-inset-bottom, 0px)); overflow-x: hidden; }
  .drawer-category-group > div { padding-right: 0; }
  .drawer-category-group .drawer-category { width: 100%; gap: 9px; padding: 8px 7px; }
  .drawer-category-group .drawer-category:hover { padding-left: 7px; }
  .category-thumb { width: 46px; height: 46px; flex-basis: 46px; }
}

@media (max-width: 600px) {
  .header-inner { width: 100%; grid-template-columns: 36px minmax(0, 1fr) 36px minmax(42px, auto); }
  .header-inner > .brand, .header-inner > .account-wrap, .header-inner > .cart-button,
  .mobile-header-tools, .nav-inner, .nav-inner > *, .benefits > div,
  .section-heading > *, .product-grid > *, .product-bottom > * { min-width: 0; }
  .header-inner > .cart-button { justify-self: end; padding-left: 7px; gap: 5px; }
  .header-inner > .cart-button strong { font-size: 9px; }
  .navigation .nav-inner {
    width: 100%;
    max-width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .navigation .nav-inner > a.quote-cta,
  .navigation .nav-inner > a.mobile-call-cta {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    white-space: normal;
    text-align: center;
    line-height: 1.3;
    overflow-wrap: anywhere;
  }
  .benefits strong, .benefits small { overflow-wrap: anywhere; }
  .section-heading { min-width: 0; flex-wrap: wrap; align-items: flex-end; }
  .section-heading h2 { min-width: 0; overflow-wrap: anywhere; }
  .section-heading .text-button { max-width: 42%; white-space: normal; overflow-wrap: anywhere; }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .product-bottom { flex-wrap: wrap; }
  .garage-modal .garage-form { grid-template-columns: minmax(0, 1fr); }
  .garage-modal .garage-form > * { grid-column: 1 / -1; min-width: 0; }
  .garage-modal .garage-field-label { flex-wrap: wrap; }
  .garage-modal .garage-field-label small { margin-left: 0; }
}

@media (max-width: 370px) {
  .container, .information-page, .customer-document, .account-main, .offer-page { width: calc(100% - 24px); }
  .account-card { padding: 15px 12px; }
  .product-facts { grid-template-columns: minmax(0, 1fr); }
  .return-form-actions { grid-template-columns: minmax(0, 1fr); }
  .return-mode-button { font-size: 10px; }
}

/* Mobile category drawer: compact navigation with deliberate, collapsed sections. */
@media (max-width: 600px) {
  .drawer {
    width: min(420px, calc(100vw - 16px));
    max-width: calc(100vw - 16px);
    height: 100vh;
    height: 100dvh;
    box-sizing: border-box;
    padding: 16px 16px calc(18px + env(safe-area-inset-bottom, 0px));
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    border-radius: 0 18px 18px 0;
  }
  .drawer .panel-heading {
    position: sticky;
    top: -16px;
    z-index: 2;
    margin: -16px -16px 12px;
    padding: calc(16px + env(safe-area-inset-top, 0px)) 16px 12px;
    background: #fff;
  }
  .drawer .panel-heading h2 { margin: 0; font-size: 22px; }
  .drawer .panel-heading .eyebrow { margin-bottom: 4px; font-size: 8px; letter-spacing: 1.5px; }
  .mobile-drawer-links {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin: 12px 0 10px;
  }
  .mobile-drawer-links > a,
  .mobile-drawer-links > a.quote-cta {
    min-width: 0;
    min-height: 44px;
    padding: 9px 11px;
    border: 1px solid #eee8f2;
    border-radius: 10px;
    background: #faf8fc;
    font-size: 12px;
    line-height: 1.3;
    text-align: left;
  }
  .mobile-drawer-links > a:first-child { grid-column: 1 / -1; }
  .mobile-drawer-links > a::after { flex: 0 0 auto; font-size: 18px; }
  .drawer-intro {
    margin: 0 0 8px;
    padding: 8px 2px;
    border: 0;
    background: transparent;
    font-size: 12px;
    line-height: 1.45;
  }
  #drawer-categories { display: grid; gap: 2px; }
  .drawer-category-group { border: 0; }
  .drawer-category-group > summary {
    min-height: 54px;
    margin: 4px 0;
    padding: 0 13px;
    border: 1px solid #eee8f2;
    border-radius: 11px;
    background: #faf8fc;
    color: #493951;
    font-size: 14px;
  }
  .drawer-category-group > summary > small { font-size: 10px; }
  .drawer-category-group[open] > summary { border-color: #ddcde8; background: #f5eff9; }
  .drawer-category-group > div { gap: 4px; padding: 2px 0 8px; }
  .drawer-category-group .drawer-category { min-height: 56px; padding: 7px 5px; border-bottom: 1px solid #f0edf2; }
  .drawer-category-group .drawer-category:hover { padding-left: 5px; }
  .drawer-category-group .category-art,
  .drawer-category-group .category-thumb { width: 40px; height: 40px; flex-basis: 40px; }
  .drawer-category .category-copy strong { font-size: 12px; line-height: 1.35; }
  .drawer-category .category-copy small { font-size: 10px; }
  .drawer-bottom { margin-top: 14px; padding: 15px; border-radius: 12px; }
  .drawer-bottom > svg { width: 22px; height: 22px; margin-bottom: 6px; }
  .drawer-bottom strong { font-size: 14px; }
  .drawer-bottom p { margin: 6px 0 10px; font-size: 12px; line-height: 1.45; }
  .drawer-bottom .button { width: 100%; min-height: 46px; justify-content: space-between; }
}
