/* NABAT 7.5 — mobile catalogue UX. Applied after existing styles. No business logic changes. */
/* Keep CTA sizes intrinsic; legacy flex rules sometimes stretched actions to card height. */
.products .nabat-product-card .product-actions {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  align-items:stretch;
  gap:8px;
  padding-top:12px;
  margin-top:auto;
}
.products .nabat-product-card .product-actions > a,
.products .nabat-product-card .product-actions > button {
  box-sizing:border-box;
  display:inline-flex;
  justify-content:center;
  align-items:center;
  width:100%;
  min-width:0;
  min-height:44px;
  height:auto;
  flex:none;
  margin:0;
  padding:8px 9px;
  line-height:1.45;
  font-size:12px;
  font-weight:800;
  border-radius:8px;
  text-align:center;
  white-space:normal;
}
.products .nabat-product-card .product-info {min-width:0;}
.products .nabat-product-card .product-info h3 {margin:3px 0 0;line-height:1.5;}
.products .nabat-product-card .product-info p {margin:0 0 7px;line-height:1.5;}
@media (max-width:700px) {
  /* Single-height compact header: logo, RFQ, menu; flyout does not push products down. */
  .top .nav {
    display:grid;
    grid-template-columns:minmax(0,1fr) auto 44px;
    grid-template-rows:auto;
    align-items:center;
    gap:8px;
    min-height:68px;
    padding-top:8px;
    padding-bottom:8px;
    position:relative;
    flex-wrap:initial;
  }
  .top .nav > .nabat-brand {
    grid-row:1;
    grid-column:1;
    min-width:0;
    max-width:100%;
    width:auto;
    padding:0;
    justify-self:start;
  }
  .top .nav .nabat-brand-image {
    display:block;
    width:clamp(95px,29vw,138px);
    max-height:54px;
    height:auto;
    object-fit:contain;
  }
  .top .nav > .basket {
    grid-row:1;
    grid-column:2;
    min-width:0;
    min-height:43px;
    margin:0;
    padding:7px 9px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    white-space:nowrap;
    font-size:11px;
    line-height:1.4;
    border-radius:8px;
  }
  .top .nav > .basket span {
    font-size:10px;
    line-height:19px;
    display:inline-block;
    min-width:19px;
    height:19px;
    text-align:center;
    padding:0 4px;
  }
  .top .nav > .mobile-nav-toggle {
    grid-row:1;
    grid-column:3;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    width:44px;
    height:44px;
    padding:0;
    margin:0;
    font-size:0;
    line-height:1;
    border-radius:8px;
    white-space:nowrap;
  }
  .top .nav > .mobile-nav-toggle::after {
    content:'☰';
    font-family:Arial,sans-serif;
    font-size:21px;
    line-height:1;
  }
  .top .nav > nav {
    display:none;
    position:absolute;
    top:calc(100% + 3px);
    inset-inline-start:16px;
    inset-inline-end:16px;
    width:auto;
    order:initial;
    margin:0;
    padding:10px;
    border:1px solid #dfe4df;
    border-radius:12px;
    background:#fff;
    box-shadow:0 14px 35px rgba(20,28,23,.13);
    z-index:100;
    white-space:normal;
    max-height:min(65vh,420px);
    overflow-y:auto;
  }
  .top .nav > nav.is-open {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:4px;}
  .top .nav > nav a {width:100%;min-height:44px;justify-content:center;padding:10px 8px;border:0;border-radius:7px;}
  .top .nav > nav a:hover,.top .nav > nav a:focus-visible{background:#f0f3f0;}
  .products {grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;}
  .nabat-product-card .product-info {padding:13px 11px;}
  .nabat-product-card .product-info h3 {font-size:15px;}
  .nabat-product-card .product-info p {font-size:12px;}
  .filters {display:grid;grid-template-columns:minmax(0,1fr) auto;gap:10px;}
  .filters input {grid-column:1 / -1;min-width:0;width:100%;}
  .filters select {min-width:0;width:100%;}
  .filters button {min-height:44px;}
  .section {padding-top:38px;padding-bottom:44px;}
  .section-head {gap:10px;align-items:baseline;}
  .section-head h2 {font-size:clamp(22px,5.4vw,29px);}
  .section-head a,.section-head span {font-size:12px;}
  .detail-main.nabat-product-image {height:auto;aspect-ratio:1 / 1;object-fit:contain;}
  .nabat-product-ctas > button {min-height:46px;}
}
@media (max-width:560px) {
  /* Product-list cards make product names and buttons readable even at 320–390 CSS px. */
  .products {grid-template-columns:minmax(0,1fr);gap:12px;}
  .products .nabat-product-card {
    display:grid;
    grid-template-columns:clamp(108px,31vw,140px) minmax(0,1fr);
    gap:0;
    align-items:stretch;
    border-radius:12px;
    box-shadow:0 2px 9px rgba(0,0,0,.025);
  }
  .products .nabat-product-card > a:first-child {
    grid-column:1;
    grid-row:1;
    min-width:0;
    min-height:150px;
    height:100%;
    aspect-ratio:auto;
    background:#f6f3ed;
  }
  .products .nabat-product-card > a:first-child img,
  .products .nabat-product-card > a:first-child .no-photo {
    width:100%;
    height:100%;
    min-height:150px;
    max-height:none;
    object-fit:contain !important;
    object-position:center;
  }
  .products .nabat-product-card .product-info {
    grid-column:2;
    grid-row:1;
    padding:11px 11px 12px;
    display:flex;
    flex-direction:column;
    gap:2px;
    min-width:0;
  }
  .products .nabat-product-card .product-info > small {font-size:11px;line-height:1.35;}
  .products .nabat-product-card .product-info h3 {font-size:15px;line-height:1.5;}
  .products .nabat-product-card .product-info p {font-size:11px;margin:0 0 5px;}
  .products .nabat-product-card .product-actions {gap:6px;padding-top:8px;margin-top:auto;}
  .products .nabat-product-card .product-actions > a,
  .products .nabat-product-card .product-actions > button {
    font-size:11px;
    min-height:40px;
    padding:7px 3px;
    line-height:1.4;
    border-radius:7px;
  }
  .products .nabat-product-card .product-info > strong {font-size:12px;line-height:1.5;}
  .category-grid {grid-template-columns:minmax(0,1fr);}
  .category-grid .nabat-category-card {min-height:110px;padding:12px;}
  .category-grid .nabat-category-card .nabat-category-title {font-size:clamp(24px,7vw,32px);}
  .hero h1 {font-size:clamp(29px,8vw,37px);}
  .hero p {font-size:14px;line-height:1.9;}
  .actions .btn {min-height:44px;padding:10px 13px;font-size:12px;}
  .form label,.quote-row{min-width:0;}
}
@media (max-width:350px) {
  .top .nav {grid-template-columns:minmax(0,1fr) auto 40px;gap:5px;}
  .top .nav .nabat-brand-image {width:90px;}
  .top .nav > .basket {font-size:10px;padding:6px;}
  .top .nav > .mobile-nav-toggle {width:40px;height:42px;}
  .products .nabat-product-card {grid-template-columns:100px minmax(0,1fr);}
  .products .nabat-product-card .product-actions {grid-template-columns:minmax(0,1fr);}
  .products .nabat-product-card .product-actions > a,
  .products .nabat-product-card .product-actions > button {min-height:36px;}
}
@media (prefers-reduced-motion:reduce) {
  .products .nabat-product-card {transition:none!important;}
}
