/* Final mobile layout guardrails. Loaded after feature styles. */
html, body { max-width: 100%; overflow-x: clip; }
img, svg, video, iframe { max-width: 100%; }
input, select, textarea, button { max-width: 100%; }

@media (max-width: 760px) {
  /* Catalogue content is populated after load; never leave it transparent if
     an Android browser misses the reveal observer transition. */
  .live-catalogue .reveal { opacity: 1; transform: none; }
  .section-pad { width: 100%; min-width: 0; padding-left: 1rem; padding-right: 1rem; }
  .site-header { left: 0; right: 0; width: 100%; max-width: 100%; min-width: 0; }
  .site-header > * { min-width: 0; }
  .site-header .brand { overflow: hidden; }
  .site-header .wordmark { overflow: hidden; text-overflow: ellipsis; }
  .site-nav { left: 0; right: 0; width: 100%; max-width: 100%; max-height: calc(100dvh - 74px); overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; }
  .site-nav a, .site-nav button, .live-nav-menu, .live-nav-groups, .live-nav-groups > div { min-width: 0; max-width: 100%; }
  .live-nav-menu { max-height: calc(100dvh - 180px); overflow-y: auto; }

  .hero-content, .story-copy, .live-catalogue-head, .live-tools, .live-filter-summary,
  .order-heading, .order-grid, .faq-list, .reviews-heading, .trust-grid,
  .approved-reviews, .review-form, .collection-cta, .contact-intro,
  .contact-details, .contact-map, footer { min-width: 0; max-width: 100%; }

  .live-catalogue h2, .order-heading h2, .reviews-heading h2,
  .contact-intro h2, .faq-heading h2 { overflow-wrap: anywhere; }
  .live-collection-showcase { min-width: 0; overflow: visible; }
  /* A vertical list is deliberately used on phones. It avoids Android WebView
     grid/scroll-snap sizing bugs and lets every collection remain readable. */
  .live-collection-showcase-head { align-items: flex-end; }
  .live-collection-controls { display: none; }
  .live-collection-slider {
    display: grid;
    grid-auto-flow: row;
    grid-template-columns: minmax(0, 1fr);
    grid-auto-columns: auto;
    gap: .85rem;
    width: 100%;
    max-width: 100%;
    padding: 0;
    overflow: visible;
    scroll-snap-type: none;
  }
  .live-collection-slide {
    display: grid;
    grid-template-columns: minmax(112px, 34%) minmax(0, 1fr);
    width: 100%;
    max-width: 100%;
    min-height: 150px;
    scroll-snap-align: none;
  }
  .live-collection-image { aspect-ratio: 4 / 5; height: 100%; }
  .live-collection-copy { align-content: center; }
  .live-collection-slide, .live-product, .live-product-open,
  .live-product-copy, .live-product-row { min-width: 0; max-width: 100%; }
  .live-product-name, .live-product-brand, .live-price, .live-sync-meta,
  .live-results, .order-note, .review-card, .review-consent,
  .contact-details strong { overflow-wrap: anywhere; }

  .booking-dialog, .live-product-dialog, .checkout-dialog {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    min-height: 0;
    margin: 0;
    border-width: 0;
    border-radius: 0;
    box-sizing: border-box;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
  }
  .booking-dialog[open], .live-product-dialog[open], .checkout-dialog[open] { display: block; }
  .checkout-dialog { overflow: hidden; }
  .checkout-wrap {
    height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    padding-top: max(1.2rem, env(safe-area-inset-top));
    padding-bottom: max(2rem, env(safe-area-inset-bottom));
  }
  .live-product-dialog { overflow: hidden; }
  .live-product-dialog > [data-live-dialog-content] {
    display: block;
    width: 100%;
    height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
  }
  .booking-dialog { padding-top: max(1.35rem, env(safe-area-inset-top)); padding-bottom: max(2rem, env(safe-area-inset-bottom)); }
  .booking-dialog > *, .checkout-dialog > *, .live-product-dialog > * { min-width: 0; max-width: 100%; }
  .booking-dialog form, .booking-dialog label, .captcha-field,
  .checkout-wrap, .checkout-form, .checkout-form label, .checkout-total,
  .live-dialog-layout, .live-dialog-gallery, .live-dialog-stage,
  .live-dialog-copy, .live-dialog-copy dl, .live-dialog-copy dl div { min-width: 0; max-width: 100%; }
  .booking-dialog input, .booking-dialog select,
  .checkout-form input, .checkout-form select, .checkout-form textarea,
  .review-form input, .review-form textarea { width: 100%; min-width: 0; max-width: 100%; }
  .captcha-field > div { grid-template-columns: minmax(0, 1fr) minmax(64px, 76px); }
  .live-dialog-gallery { min-height: 0; height: auto; }
  .live-dialog-stage { min-height: 44vh; }
  .live-dialog-stage img { width: 100%; height: auto; max-height: 56vh; }
  .live-dialog-copy dl div { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); }
  .live-dialog-copy dd { overflow-wrap: anywhere; }
  .live-dialog-actions > * { width: 100%; text-align: center; }

  .cart-drawer { left: 0; right: 0; width: 100%; max-width: 100%; min-width: 0; padding-left: 1rem; padding-right: 1rem; }
  .cart-drawer *, .cart-item, .cart-item > div, .cart-summary { min-width: 0; max-width: 100%; }
  .cart-item { grid-template-columns: 58px minmax(0, 1fr); }
  .cart-item img { width: 58px; }
  .cart-qty { grid-column: 2; flex-wrap: wrap; }

  .chat-panel { left: max(.5rem, env(safe-area-inset-left)); right: max(.5rem, env(safe-area-inset-right)); width: auto; max-width: none; min-width: 0; height: calc(100dvh - 5.8rem); max-height: 620px; }
  .chat-panel > *, .chat-panel > header > div, .chat-messages,
  .chat-message, .chat-actions, .chat-form { min-width: 0; max-width: 100%; }
  .chat-message, .chat-actions a { overflow-wrap: anywhere; }
  .chat-form { grid-template-columns: minmax(0, 1fr) 42px; }

  .review-form { padding: 1.1rem; }
  .review-form-head { min-width: 0; gap: .75rem; }
  .rating-input { flex-wrap: wrap; }
  .contact-section { width: 100%; min-width: 0; max-width: 100%; margin-left: 0; margin-right: 0; }
  .contact-details a, .social-contact a { min-width: 0; max-width: 100%; }
  .social-contact a { grid-template-columns: 42px minmax(0, 1fr); }
  .social-contact i { grid-column: 2; }
  .contact-map { grid-template-columns: minmax(0, 1fr); }
  .footer-links { max-width: 100%; flex-wrap: wrap; row-gap: .75rem; }

  .button, .cart-checkout, .checkout-submit, .review-form button,
  .live-add-cart, .live-enquire, .dialog-close, .live-dialog-close,
  .cart-close, .checkout-close, .menu-toggle { min-height: 44px; }
}

@media (max-width: 390px) {
  .site-header { padding-left: .55rem; padding-right: .55rem; }
  .site-header .wordmark { font-size: .82rem; }
  .site-header .wordmark small { letter-spacing: .22em; }
  .site-header .cart-launcher { padding: .42rem .46rem; }
  .site-header .menu-toggle { flex-basis: 38px; width: 38px; }
  .hero-content, .section-pad { padding-left: .85rem; padding-right: .85rem; }
  .live-product-grid { grid-template-columns: minmax(0, 1fr); }
  .live-collection-slide { grid-template-columns: 104px minmax(0, 1fr); min-height: 138px; }
  .live-dialog-gallery { grid-template-columns: 48px minmax(0, 1fr); }
  .live-dialog-copy { padding: 1.1rem; }
  .live-dialog-copy dl div { grid-template-columns: minmax(0, 1fr); gap: .3rem; }
  .live-dialog-copy dd { text-align: left; }
  .checkout-wrap, .booking-dialog { padding-left: .9rem; padding-right: .9rem; }
  .review-form { padding: .9rem; }
  .contact-section { padding-left: .9rem; padding-right: .9rem; }
  .contact-details a { grid-template-columns: minmax(0, 1fr); }
  .contact-details i, .contact-details strong { grid-column: 1; grid-row: auto; }
}
