/* Allow vertical scrolling and pinch zoom, without double-tap zoom or sideways dragging.
   Keep the viewport zoomable; clip does not create a scroll container around sticky nav. */
html,
body {
  overflow-x: clip !important;
  overscroll-behavior-x: none;
  touch-action: manipulation;
  touch-action: pan-y pinch-zoom;
}

/* Keep the navigation surface full width, including wide desktop screens. */
body .sf-nav { width: 100% !important; max-width: none !important; top: 0 !important; }

/* Mobile navigation is intentionally isolated from the desktop navigation rules. */
@media (max-width: 768px) {
  /* Lock the root only: hiding overflow on body creates a new sticky container. */
  html.mobile-nav-locked {
    overflow: hidden !important;
    overscroll-behavior: none;
  }

  body.mobile-nav-locked { overscroll-behavior: none; }

  .sf-nav {
    position: sticky;
    z-index: 510 !important;
  }

  .nav-mobile {
    position: fixed !important;
    z-index: 500 !important;
    inset: var(--mobile-nav-top, 76px) 0 0 !important;
    display: flex !important;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    box-sizing: border-box;
    min-height: 0;
    padding: 8px max(24px, 7vw) 24px !important;
    overflow-y: auto;
    background: #fff !important;
    border: 0 !important;
    box-shadow: none !important;
    opacity: 0;
    pointer-events: none;
    transform: none !important;
    visibility: hidden;
    transition: opacity 160ms ease, visibility 0s linear 160ms;
  }

  .nav-mobile.open {
    opacity: 1;
    pointer-events: auto;
    visibility: visible;
    transition: opacity 160ms ease;
  }

  .nav-mobile a {
    display: flex !important;
    align-items: center;
    min-height: 58px;
    padding: 12px 0 !important;
    border: 0 !important;
    border-bottom: 1px solid #dbe2d8 !important;
    color: #122319 !important;
    font-family: var(--fd, inherit) !important;
    font-size: clamp(22px, 6vw, 28px) !important;
    font-weight: 700 !important;
    letter-spacing: -.025em;
    line-height: 1.15;
    text-decoration: none;
    border-radius: 0 !important;
    box-shadow: none !important;
  }

  .nav-mobile a:first-child { border-top: 0 !important; }
  .nav-mobile a:hover,
  .nav-mobile a:focus-visible { color: #075d3c !important; }

  .nav-toggle[aria-expanded="true"] {
    background: #f2f6ed !important;
    border-color: #075d3c !important;
    color: #075d3c !important;
  }

  .cart-drawer .ci-img {
    box-sizing: border-box;
    object-fit: contain !important;
    object-position: center;
    padding: 6px;
    background: #f0f3ed !important;
  }
}

.cart-drawer .ci-img { object-fit: contain !important; object-position: center; background: #f0f3ed !important; }

/* A compact product summary: model, name/volume, then quantity and line total. */
body .cart-drawer .cart-item {
  position: relative;
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 12px;
  margin: 0 0 12px;
  border: 1px solid #e0e6dd;
  border-radius: 14px;
  background: #f8faf6;
}
body .cart-drawer .ci-img {
  width: 84px;
  height: 110px;
  padding: 4px;
  border-radius: 8px;
}
body .cart-drawer .ci-body { min-width: 0; gap: 10px; }
body .cart-drawer .ci-heading { padding-right: 24px; }
body .cart-drawer .ci-name { font-size: 17px; font-weight: 700; line-height: 1.3; }
body .cart-drawer .ci-vol { font-size: 14px; line-height: 1.4; letter-spacing: 0; margin-top: 3px; }
body .cart-drawer .ci-controls { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 6px 8px; }
body .cart-drawer .ci-qty { margin: 0; gap: 0; border: 1px solid #dbe2d6; border-radius: 9px; background: white; }
body .cart-drawer .qty-btn { width: 34px; height: 44px; min-height: 44px; padding: 0; border: 0; background: transparent; }
body .cart-drawer .qty-num { min-width: 24px; padding: 0 2px; text-align: center; font-size: 15px; }
body .cart-drawer .ci-line-total { text-align: right; margin-left: auto; }
body .cart-drawer .ci-price-label { display: block; font-size: 11px; line-height: 1.25; color: #526352; }
body .cart-drawer .ci-price { font-size: 18px; font-weight: 700; line-height: 1.3; margin: 2px 0 0; white-space: nowrap; }
body .cart-drawer .ci-remove { position: absolute; top: 4px; right: 4px; width: 32px; padding: 0; }
@media (max-width: 360px) {
  body .cart-drawer .cart-item { grid-template-columns: 64px minmax(0, 1fr); gap: 10px; padding: 10px; }
  body .cart-drawer .ci-img { width: 64px; height: 96px; }
  body .cart-drawer .ci-name { font-size: 16px; }
}

/* Products page: the supplied <br> is the only line break at a 390 px viewport. */
@media (max-width: 600px) {
  body .page-intro .products-intro-title {
    max-width: 100%;
    font-size: clamp(25px, 8.1vw, 33px) !important;
    letter-spacing: -.055em !important;
    line-height: 1.04 !important;
    white-space: nowrap;
  }

  body .site-footer {
    padding: 34px 22px 22px !important;
  }

  body .site-footer .footer-main {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 25px !important;
  }

  body .site-footer .footer-brand { grid-column: 1 !important; order: 1; }
  body .site-footer .footer-main > div:nth-child(2) { order: 2; }
  body .site-footer .footer-main > div:nth-child(3) { order: 3; }
  body .site-footer .footer-main > div:nth-child(4) { order: 4; }

  body .site-footer h3 { margin-bottom: 10px !important; }
  body .site-footer p { margin: 6px 0 !important; line-height: 1.65 !important; }
  body .site-footer a { margin: 7px 0 !important; }
  body .site-footer .footer-main > div > a {
    display: flex !important;
    align-items: center;
    width: 100%;
    min-height: 44px;
    padding: 5px 0 !important;
    margin: 0 !important;
    line-height: 1.4;
  }

  body .site-footer .footer-bottom {
    display: flex !important;
    flex-direction: column;
    align-items: flex-start !important;
    gap: 16px !important;
    margin-top: 28px !important;
    padding-top: 20px !important;
  }

  body .site-footer .footer-bottom > div {
    order: 1;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 8px !important;
  }

  body .site-footer .footer-bottom > span { order: 2; }
  body .site-footer .footer-bottom a { margin: 0 !important; }
}

@media (min-width: 769px) {
  .nav-mobile {
    display: none !important;
    opacity: 0 !important;
    pointer-events: none !important;
    visibility: hidden !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .nav-mobile { transition: none !important; }
}
