/* Universal Links v9: two product/category cards visible per row on mobile.
   Loaded after the existing styles so the desktop and tablet layouts stay intact. */
@media (max-width: 670px) {
  .category-grid,
  .product-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: clamp(10px, 3vw, 17px);
    row-gap: 24px;
    align-items: start;
  }

  .category-card,
  .product-card,
  .cat-info,
  .cat-info > span,
  .product-details { min-width: 0; }

  /* Square images help fit two useful, evenly sized cards per row. */
  .cat-image-wrap,
  .product-image {
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1;
    overflow: hidden;
  }
  .cat-image-wrap img,
  .product-image > img { width: 100%; height: 100%; object-fit: cover; }

  /* Keep the Universal Links stamp readable inside the narrower pictures. */
  .cat-image-wrap::after,
  .product-image::after {
    content: 'UNIVERSAL\A LINKS';
    white-space: pre;
    text-align: center;
    line-height: 1.05;
    letter-spacing: .8px;
    font-size: clamp(12px, 3.4vw, 17px);
    padding: 6px 9px;
    max-width: calc(100% - 8px);
    box-sizing: border-box;
    transform: translate(-50%, -50%) rotate(-12deg);
  }

  .cat-zoom {
    top: 8px;
    right: 8px;
    width: 27px;
    height: 27px;
    font-size: 17px;
    box-shadow: 0 3px 10px #0002;
  }
  .cat-info { display: block; padding: 11px 0 0; }
  .cat-info small { font-size: 10px; letter-spacing: .65px; margin-bottom: 5px; }
  .cat-info strong {
    font-size: clamp(15px, 3.9vw, 19px);
    line-height: 1.22;
    letter-spacing: -.25px;
    overflow-wrap: break-word;
  }
  .cat-description {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    font-size: 12px;
    line-height: 1.45;
    margin-top: 5px;
  }
  .cat-bottom-arrow { display: none; }

  .product-index {
    top: 7px;
    left: 7px;
    width: 24px;
    height: 24px;
    font-size: 10px;
  }
  .quick-view {
    transform: none;
    padding: 9px 10px;
    font-size: 11px;
    line-height: 1.2;
    gap: 5px;
    z-index: 4;
  }
  .quick-view span { font-size: 17px; line-height: 1; }
  .product-details { padding: 12px 0 0; }
  .product-type { font-size: 10px; letter-spacing: .55px; line-height: 1.4; display: block; }
  .product-details h3 {
    font-size: clamp(15px, 3.9vw, 19px);
    line-height: 1.25;
    letter-spacing: -.25px;
    margin: 7px 0;
    overflow-wrap: break-word;
  }
  .product-details p {
    font-size: 12px;
    line-height: 1.5;
    min-height: 0;
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
  }
  .product-enquire { font-size: 12px; line-height: 1.4; display: inline-flex; gap: 4px; }
  .product-enquire span { font-size: 15px; }
}
@media (max-width: 360px) {
  .category-grid, .product-grid { column-gap: 10px; row-gap: 20px; }
  .cat-info strong, .product-details h3 { font-size: 15px; }
  .cat-image-wrap::after, .product-image::after { font-size: 11.5px; letter-spacing: .4px; padding: 5px 7px; }
  .cat-description, .product-details p { font-size: 11.5px; }
}
