/* Phone layouts share the existing colors and controls, with a shorter path to purchase. */
#ozark-storefront #eraProductPreview { scroll-margin-top: 8rem; }
@media (max-width: 850px) {
  #ozark-storefront.product-page .hero:has(.shop-product-heading) {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
    padding-block: 16px;
  }
  #ozark-storefront.product-page .hero .shop-product-heading-main { gap: 10px; }
  #ozark-storefront.product-page .hero .hero-breadcrumb { margin-bottom: 10px; }
  #ozark-storefront.product-page .hero .shop-product-intro { margin-top: 0; }
  #ozark-storefront.product-page .hero .shop-product-intro .hero-sub { margin: 0; font-size: 14px; line-height: 1.65; }
  #ozark-storefront.product-page .hero .shop-product-heading .hero-title { margin: 0; line-height: 1.12; }
  #ozark-storefront.product-page .hero .hero-title-context { margin-top: 6px; font-size: 16px; line-height: 1.45; }

  /* A single swipeable row replaces the tall or tightly squeezed section grids. */
  #ozark-storefront.product-page .hero .shop-product-nav { display: block; min-width: 0; margin-top: 12px; padding: 4px; }
  #ozark-storefront.product-page .hero .shop-product-nav > span { display: none; }
  #ozark-storefront.product-page .hero .shop-product-nav > div {
    display: flex; flex-wrap: nowrap; align-items: stretch; gap: 4px; width: 100%; min-width: 0;
    overflow-x: auto; overscroll-behavior-inline: contain; scrollbar-width: thin;
  }
  #ozark-storefront.product-page .hero .shop-product-nav a {
    flex: 0 0 auto; min-width: 0; min-height: 44px; justify-content: center;
    padding: 9px 12px; font-size: 13px; line-height: 1.4; white-space: nowrap;
  }
  #ozark-storefront.product-page .hero .shop-product-nav a > span { display: none; }

  /* Keep reviews under the image on desktop; on phones show the price and buy action first. */
  #ozark-storefront.product-page .hero.nba > .era-art-column { display: contents; position: static; }
  #ozark-storefront.product-page .hero.nba > .shop-product-heading { grid-column: 1; grid-row: 1; order: 0; }
  #ozark-storefront.product-page .hero.nba .era-art-column > .shop-product-stage { grid-column: 1; grid-row: 2; order: 0; }
  #ozark-storefront.product-page .hero.nba > .hero-info { grid-column: 1; grid-row: 3; order: 0; }
  #ozark-storefront.product-page .hero.nba .era-art-column > .shop-product-community { grid-column: 1; grid-row: 4; order: 0; margin: 0; }
  #ozark-storefront.product-page .hero.nba > .shop-product-details { grid-column: 1; grid-row: 5; order: 0; }
  #ozark-storefront.product-page .hero .shop-product-details .era-decision { display: block; }
  #ozark-storefront.product-page .hero .era-decision__result p { min-height: 0; }

  #ozark-storefront.product-page .hero:has(.shop-product-heading) > .hero-info { padding: 18px; }
  #ozark-storefront.product-page .hero .hero-info .hero-rating { gap: 8px; margin-bottom: 12px; padding-bottom: 10px; font-size: 13px; }
  #ozark-storefront.product-page .hero .hero-info .purchase-command { display: flex; flex-direction: column; gap: 10px; margin: 0; }
  #ozark-storefront.product-page .hero .hero-info .purchase-command > * { order: 4; margin-block: 0; }
  #ozark-storefront.product-page .hero .hero-info .price-block { display: contents; }
  #ozark-storefront.product-page .hero .hero-info .price-row { order: 0; margin: 0; }
  #ozark-storefront.product-page .hero .hero-info .price-note { order: 1; margin: 0; font-size: 13px; line-height: 1.5; }
  #ozark-storefront.product-page .hero .hero-info .hero-cta { order: 2; gap: 10px; margin: 0; }
  #ozark-storefront.product-page .hero .hero-info .compat-line { order: 3; margin: 0; padding: 10px; font-size: 13px; line-height: 1.55; }
  #ozark-storefront.product-page .hero .hero-info .price-now { font-size: 32px; line-height: 1.15; }
  #ozark-storefront.product-page .hero .hero-info .btn-primary { min-height: 48px; padding: 12px 16px; font-size: 15px; }
  #ozark-storefront.product-page .hero .hero-info .purchase-headline { font-size: 14px; line-height: 1.4; }
  #ozark-storefront.product-page .hero .hero-info .checkout-disclosure { padding-block: 4px; }
  #ozark-storefront.product-page .hero .hero-info .checkout-disclosure p { font-size: 13px; line-height: 1.6; }
  #ozark-storefront.product-page .hero .hero-info .shop-secondary-info { margin-top: 12px; }
  #ozark-storefront.product-page #eraProductPreview { scroll-margin-top: 90px; }
  #ozark-storefront.gpc-page .hero.gpc-hero-v2 .gpc-access-console { grid-template-columns: minmax(0, 1fr); }
  #ozark-storefront.gpc-page .gpc-jump-nav { display: flex; flex-wrap: nowrap; gap: 6px; overflow-x: auto; scrollbar-width: thin; }
  #ozark-storefront.gpc-page .gpc-jump-nav > a { flex: 0 0 auto; min-height: 44px; padding: 8px; font-size: 13px; white-space: nowrap; }
}

@media (max-width: 680px) {
  #ozark-storefront { min-width: 0; }
  /* Browse all products vertically without a hidden sideways product rail. */
  #ozark-storefront .oz-explorer-product-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; overflow: visible; scroll-snap-type: none; }
  #ozark-storefront .oz-explorer-product { width: auto; min-width: 0; flex: none; scroll-snap-align: none; }
  #ozark-storefront .oz-explorer-product-body { padding: 10px; }
  #ozark-storefront .oz-explorer-product-body h3 { font-size: 14px; line-height: 1.35; overflow-wrap: anywhere; }
  #ozark-storefront .oz-explorer-product-body p { min-height: 0; font-size: 13px; line-height: 1.5; }
  #ozark-storefront :is(.oz-explorer-product-badge, .oz-explorer-product-facts span) { font-size: 12px; line-height: 1.4; }
  #ozark-storefront .oz-explorer-product footer { align-content: space-between; align-items: start; flex-direction: column; gap: 8px; padding: 10px; }
  #ozark-storefront .oz-explorer-product-price strong { font-size: 15px; }
  #ozark-storefront .oz-explorer-product-actions { flex-wrap: wrap; gap: 8px; }
  #ozark-storefront .oz-explorer-product-primary { min-height: 44px; padding-inline: 10px; font-size: 13px; }
  #ozark-storefront .oz-explorer-product-secondary { font-size: 13px; }

  /* Icon controls retain their accessible labels without covering half the screen. */
  #ozark-storefront.storefront-refined .store-cart,
  #ozark-storefront.storefront-refined .store-cart.is-open { right: max(12px, env(safe-area-inset-right)); width: 48px; }
  #ozark-storefront.storefront-refined .sc-toggle { width: 48px; min-height: 48px; height: 48px; padding: 8px; border-radius: 14px; }
  #ozark-storefront.storefront-refined .sc-toggle-copy { display: none !important; }
  #ozark-storefront.storefront-refined #assistantSideLauncher.assistant-side-launcher {
    right: max(70px, calc(env(safe-area-inset-right) + 70px)) !important;
    bottom: var(--sf-tools-bottom) !important;
    width: 48px !important; min-width: 48px !important; max-width: 48px !important;
    height: 48px !important; min-height: 48px !important; padding: 8px !important; border-radius: 14px !important;
  }
  #ozark-storefront.storefront-refined #assistantSideLauncher.assistant-side-launcher > span { display: none !important; }
  #ozark-storefront.storefront-refined #assistantSideLauncher.assistant-side-launcher img { width: 28px; height: 28px; }
  #ozark-storefront.storefront-refined .sc-panel { right: 0; width: min(390px, calc(100vw - 40px)); max-height: min(560px, calc(100dvh - var(--sf-tools-bottom) - 76px)); }

  /* One bottom row, including safe-area space, replaces the two-row floating dock. */
  #ozark-storefront.product-page.mobile-purchase-visible { --sf-tools-bottom: calc(82px + env(safe-area-inset-bottom)) !important; padding-bottom: calc(144px + env(safe-area-inset-bottom)); }
  #ozark-storefront.product-page .mobile-purchase-bar,
  #ozark-storefront.product-page .mobile-purchase-bar.has-headline {
    inset: auto 0 0; display: grid; grid-template-columns: 36px minmax(0, 1fr) auto;
    gap: 10px; width: 100%; min-height: 66px; margin: 0; padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
    border-radius: 16px 16px 0 0; transform: translateY(calc(100% + 20px));
  }
  #ozark-storefront.product-page .mobile-purchase-bar.is-visible { transform: translateY(0); }
  #ozark-storefront.product-page .mobile-purchase-headline { display: none; }
  #ozark-storefront.product-page .mobile-purchase-art { width: 36px; height: 36px; }
  #ozark-storefront.product-page .mobile-purchase-copy small { font-size: 13px; line-height: 1.35; }
  #ozark-storefront.product-page .mobile-purchase-copy strong { font-size: 13px; line-height: 1.35; }
  #ozark-storefront.product-page .mobile-purchase-action { min-width: 110px; min-height: 44px; gap: 6px; padding-inline: 12px; font-size: 14px; }
  #ozark-storefront .site-header .nav { max-height: calc(100dvh - 100px); overflow-y: auto; }
}

@media (max-width: 360px) {
  #ozark-storefront.product-page .mobile-purchase-bar,
  #ozark-storefront.product-page .mobile-purchase-bar.has-headline { grid-template-columns: minmax(0, 1fr) auto; }
  #ozark-storefront.product-page .mobile-purchase-art { display: none; }
}
