/*
 * Mobile product-page contract.
 * Loaded after styles.css on every generated product page.
 */

@media (max-width: 760px) {
  .product-detail-page {
    width: 100%;
    padding: 10px 10px 42px;
  }

  .product-detail-hero {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .product-buy-panel {
    order: 1;
    position: static;
    gap: 10px;
    padding: 14px;
    border-radius: 10px;
    box-shadow: none;
  }

  .product-buy-panel .eyebrow {
    font-size: 10px;
    line-height: 1.25;
  }

  .product-buy-panel h1 {
    margin: 0;
    font-size: clamp(22px, 6.8vw, 28px);
    line-height: 1.08;
    letter-spacing: -.025em;
    overflow-wrap: anywhere;
    text-wrap: pretty;
  }

  .product-detail-description {
    gap: 6px;
  }

  .product-detail-summary {
    display: -webkit-box;
    overflow: hidden;
    font-size: 13px;
    line-height: 1.42;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
  }

  .product-detail-more summary {
    font-size: 12px;
  }

  .product-price-box {
    gap: 5px;
    padding: 11px 12px;
    border-radius: 7px;
  }

  .product-price-box strong {
    font-size: 29px;
  }

  .product-price-meta {
    align-items: flex-start;
    gap: 8px;
  }

  .product-price-meta > span,
  .product-price-meta > small {
    font-size: 10px;
    line-height: 1.25;
  }

  .product-stock-status {
    font-weight: 900;
  }

  .product-purchase-row {
    grid-template-columns: 112px minmax(0, 1fr) !important;
    align-items: end;
    gap: 8px;
  }

  .product-quantity-control {
    gap: 5px;
  }

  .product-quantity-control > span {
    font-size: 10px;
  }

  .product-quantity-control button,
  .product-quantity-control input,
  .product-cart-button {
    min-height: 44px;
  }

  .product-cart-button {
    padding-inline: 9px;
    font-size: 12px;
  }

  .product-action-row {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 6px;
  }

  .product-action-row button,
  .product-action-row .product-request-link {
    min-height: 40px;
    padding: 7px 5px;
    font-size: 10px;
    line-height: 1.15;
    text-align: center;
  }

  .product-detail-gallery {
    order: 2;
    gap: 8px;
    padding: 10px;
    border-radius: 10px;
    box-shadow: none;
  }

  .product-detail-main {
    min-height: clamp(220px, 68vw, 280px);
    padding: 12px;
  }

  .product-detail-main img {
    max-height: clamp(196px, 60vw, 250px);
  }

  .product-zoom-badge {
    right: 9px;
    bottom: 9px;
    min-height: 30px;
    padding: 6px 8px;
    font-size: 10px;
  }

  .product-detail-thumbs {
    display: flex;
    gap: 7px;
    overflow-x: auto;
    padding-bottom: 2px;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
  }

  .product-detail-thumbs::-webkit-scrollbar {
    display: none;
  }

  .product-detail-thumbs button {
    flex: 0 0 72px;
    min-height: 62px;
    scroll-snap-align: start;
  }

  .product-detail-thumbs img {
    max-height: 50px;
  }
}

@media (max-width: 350px) {
  .product-purchase-row {
    grid-template-columns: 100px minmax(0, 1fr) !important;
  }

  .product-cart-button span {
    font-size: 11px;
  }
}
