/**
 * Product collection page
 * Layout from category.html; type/spacing from site tokens.
 */

body.is-catalog {
  overflow-x: hidden;
}

body.is-catalog .site-footer {
  margin-top: 0;
}

.hm-cat {
  --hm-cat-blue: var(--blue);
  background: var(--surface);
  color: var(--ink);
}

.hm-cat a {
  color: inherit;
  text-decoration: none;
}

/* Hero */
.hm-cat-hero {
  position: relative;
  overflow: hidden;
  min-height: 280px;
  background: var(--navy);
  color: #fff;
}

.hm-cat-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(90deg, rgba(5, 31, 56, 0.88) 0%, rgba(5, 31, 56, 0.42) 36%, rgba(5, 31, 56, 0.64) 66%, rgba(5, 31, 56, 0.97) 100%),
    var(--hm-cat-hero-image);
  background-size: cover;
  background-position: center;
}

.hm-cat-hero-inner {
  position: relative;
  min-height: 280px;
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 2.5rem;
  align-items: center;
  direction: ltr;
  padding: 1.75rem 0;
}

.hm-cat-quote {
  direction: rtl;
  width: 100%;
  background: rgba(255, 255, 255, 0.13);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-sm);
  backdrop-filter: blur(4px);
  padding: 1.25rem 1.1rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hm-cat-quote-icon {
  font-size: 1.75rem;
  line-height: 1;
  margin: 0 0 0.75rem;
}

.hm-cat-quote-title {
  font-size: var(--fs-lg);
  margin: 0 0 0.5rem;
  font-weight: 800;
  color: #fff;
}

.hm-cat-quote p {
  font-size: var(--fs-sm);
  color: #d6e1eb;
  line-height: 1.8;
  margin: 0 0 1rem;
}

.hm-cat-quote a {
  margin-top: auto;
  width: 100%;
  min-height: var(--tap);
  border-radius: var(--radius-sm);
  background: var(--hm-cat-blue);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--fs-sm);
  font-weight: 700;
}

.hm-cat-copy {
  direction: rtl;
  text-align: right;
  align-self: center;
}

.hm-cat-crumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  list-style: none;
  margin: 0 0 0.75rem;
  padding: 0;
  font-size: var(--fs-sm);
  color: #d0d9e4;
}

.hm-cat-crumb li:not(:last-child)::after {
  content: "/";
  margin-inline-start: 0.35rem;
  opacity: 0.7;
}

.hm-cat-copy h1 {
  font-size: clamp(1.6rem, 3vw, var(--fs-3xl));
  line-height: var(--lh-tight);
  margin: 0 0 0.5rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: var(--tracking-tight);
}

.hm-cat-copy > p {
  font-size: var(--fs-base);
  color: #f2f6fa;
  max-width: 38em;
  margin: 0;
  line-height: 1.85;
}

.hm-cat-benefits {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
  margin-top: 1.25rem;
  justify-content: flex-start;
  font-size: var(--fs-sm);
}

.hm-cat-benefit {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #eef5fb;
}

.hm-cat-benefit-icon {
  width: 28px;
  height: 28px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: var(--fs-sm);
}

/* Quick nav — anchors only */
.hm-cat-quick-wrap {
  min-height: 64px;
  border-bottom: 1px solid var(--line-soft);
  background: #fff;
  display: flex;
  align-items: center;
}

.hm-cat-quick {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding: 0.75rem 0;
}

.hm-cat-quick-title {
  font-size: var(--fs-md);
  font-weight: 800;
  white-space: nowrap;
  margin-left: 0.25rem;
}

.hm-cat-quick a {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  color: var(--ink);
  display: flex;
  align-items: center;
  padding: 0 0.9rem;
  font-size: var(--fs-sm);
  font-weight: 600;
  white-space: nowrap;
}

.hm-cat-quick a.is-primary {
  background: var(--navy);
  border-color: var(--navy);
  color: #fff;
  font-weight: 700;
}

.hm-cat-quick a:hover {
  border-color: rgba(26, 95, 255, 0.35);
  color: var(--blue);
}

.hm-cat-quick a.is-primary:hover {
  color: #fff;
}

/* Product rows — all in DOM, no tabs */
.hm-cat-catalog {
  padding: 1rem 0 1.25rem;
}

.hm-cat-row {
  min-height: 200px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm);
  background: #fff;
  margin-bottom: 0.85rem;
  padding: 0.85rem;
  display: grid;
  grid-template-columns: 47% 28% 23%;
  gap: 1%;
  direction: rtl;
  align-items: stretch;
  box-shadow: var(--elev-1);
  overflow: hidden;
}

.hm-cat-row.is-first {
  margin-top: 0;
}

.hm-cat-price {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hm-cat-price h3 {
  font-size: var(--fs-md);
  line-height: 1.3;
  margin: 0 0 0.55rem;
  font-weight: 800;
  text-align: right;
}

.hm-cat-price-scroll {
  overflow: hidden;
}

.hm-cat-table {
  border-collapse: collapse;
  width: 100%;
  font-size: var(--fs-sm);
  table-layout: fixed;
}

.hm-cat-table th {
  background: var(--surface-2);
  color: var(--muted);
  font-weight: 700;
}

.hm-cat-table th,
.hm-cat-table td {
  border: 1px solid var(--line);
  text-align: center;
  padding: 0.45rem 0.4rem;
}

.hm-cat-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 3.5rem;
  min-height: 1.4rem;
  padding: 0 0.45rem;
  border-radius: 999px;
  background: #e8f9ef;
  color: var(--green);
  font-size: var(--fs-xs);
  font-weight: 800;
}

.hm-cat-all-price {
  font-size: var(--fs-sm);
  color: var(--blue);
  font-weight: 700;
  margin-top: 0.4rem;
  align-self: flex-start;
}

.hm-cat-info {
  padding: 0.4rem 1rem;
  border-left: 1px solid var(--line-soft);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hm-cat-info h2 {
  font-size: var(--fs-xl);
  line-height: var(--lh-tight);
  margin: 0 0 0.5rem;
  font-weight: 800;
}

.hm-cat-info p {
  font-size: var(--fs-sm);
  line-height: 1.75;
  color: var(--muted);
  margin: 0 0 0.85rem;
}

.hm-cat-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.hm-cat-btn {
  min-height: 40px;
  border: 1px solid #d6e4fb;
  border-radius: var(--radius-sm);
  background: #fff;
  color: var(--blue);
  padding: 0 0.95rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--fs-sm);
  font-weight: 700;
}

.hm-cat-btn.is-phone {
  border-color: var(--blue);
}

.hm-cat-image {
  overflow: hidden;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  min-height: 100%;
}

.hm-cat-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hm-cat-all {
  text-align: center;
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hm-cat-all a {
  min-height: 40px;
  padding: 0 1.25rem;
  border: 1px solid #dce6f5;
  border-radius: var(--radius-sm);
  color: var(--blue);
  background: #fff;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: var(--fs-sm);
  font-weight: 700;
}

/* Steps */
.hm-cat-steps {
  background: linear-gradient(180deg, #f2f7fd 0%, #f7faff 70%, #fff 100%);
  padding: 1.5rem 0 1.75rem;
}

.hm-cat-steps-head {
  font-size: var(--fs-xl);
  font-weight: 800;
  margin: 0 0 1rem;
  text-align: right;
}

.hm-cat-steps-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  align-items: start;
  direction: rtl;
}

.hm-cat-step {
  text-align: center;
  position: relative;
  padding: 0 0.5rem;
}

.hm-cat-step:not(:last-child)::after {
  content: "›";
  position: absolute;
  left: -4px;
  top: 1.1rem;
  color: var(--blue);
  font-size: 1.6rem;
  font-weight: 300;
}

.hm-cat-step-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 0.45rem;
  border-radius: 50%;
  background: #fff;
  border: 1px solid #dce8f7;
  color: var(--blue);
  display: grid;
  place-items: center;
  font-size: 1.25rem;
}

.hm-cat-step b {
  font-size: var(--fs-sm);
  display: block;
  margin-bottom: 0.2rem;
}

.hm-cat-step small {
  font-size: var(--fs-xs);
  line-height: 1.6;
  color: var(--muted);
  display: block;
}

/* Bottom panels */
.hm-cat-bottom {
  padding: 1.25rem 0 1.75rem;
}

.hm-cat-bottom-grid {
  display: grid;
  grid-template-columns: 45% 25% 30%;
  direction: rtl;
  gap: 0;
}

.hm-cat-panel {
  padding: 0 1rem;
  border-left: 1px solid var(--line-soft);
}

.hm-cat-panel:last-child {
  border-left: 0;
}

.hm-cat-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 2rem;
  gap: 0.5rem;
}

.hm-cat-panel h3 {
  font-size: var(--fs-lg);
  margin: 0;
  font-weight: 800;
}

.hm-cat-panel-head a {
  font-size: var(--fs-sm);
  color: var(--blue);
  font-weight: 700;
  white-space: nowrap;
}

.hm-cat-panel-sub {
  font-size: var(--fs-xs);
  color: var(--muted);
  margin: 0.15rem 0 0.7rem;
}

.hm-cat-faq-list {
  display: grid;
  gap: 0.5rem;
}

.hm-cat-faq {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: #fff;
}

.hm-cat-faq summary {
  min-height: 42px;
  padding: 0.45rem 0.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  font-size: var(--fs-sm);
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}

.hm-cat-faq summary::-webkit-details-marker {
  display: none;
}

.hm-cat-faq summary::after {
  content: "+";
  font-size: 1.1rem;
  color: var(--muted);
}

.hm-cat-faq[open] summary::after {
  content: "–";
}

.hm-cat-faq p {
  margin: 0;
  padding: 0 0.75rem 0.75rem;
  color: var(--muted);
  font-size: var(--fs-sm);
  line-height: 1.7;
}

.hm-cat-experts {
  display: grid;
  gap: 0.5rem;
}

.hm-cat-expert {
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  display: grid;
  grid-template-columns: 48px 1fr 24px;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.5rem;
  direction: ltr;
}

.hm-cat-expert img {
  width: 40px;
  height: 40px;
  border-radius: 6px;
  object-fit: cover;
}

.hm-cat-expert-txt {
  direction: rtl;
  text-align: right;
}

.hm-cat-expert b {
  font-size: var(--fs-sm);
  display: block;
}

.hm-cat-expert small {
  font-size: var(--fs-xs);
  color: var(--muted);
}

.hm-cat-expert-call {
  color: var(--blue);
  font-size: 1rem;
}

.hm-cat-articles {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0;
}

.hm-cat-articles li {
  border-bottom: 1px solid var(--line-soft);
}

.hm-cat-articles li:last-child {
  border-bottom: 0;
}

.hm-cat-article {
  display: block;
  padding: 0.7rem 0;
  font-size: var(--fs-sm);
  font-weight: 700;
  line-height: 1.6;
  color: var(--ink);
}

.hm-cat-article:hover {
  color: var(--blue);
}

@media (max-width: 1000px) {
  .hm-cat-hero-inner {
    grid-template-columns: 220px 1fr;
    gap: 1.5rem;
  }

  .hm-cat-row {
    grid-template-columns: 1.1fr 0.9fr 0.8fr;
  }

  .hm-cat-bottom-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .hm-cat-panel {
    border: 0;
    padding: 0;
  }
}

@media (max-width: 800px) {
  .hm-cat-hero-inner {
    grid-template-columns: 1fr;
    min-height: 0;
    padding: 1.5rem 0;
    gap: 1.15rem;
  }

  .hm-cat-copy {
    grid-row: 1;
  }

  .hm-cat-quote {
    grid-row: 2;
  }

  .hm-cat-quick-title {
    display: none;
  }

  .hm-cat-row {
    min-height: 0;
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .hm-cat-image {
    height: 200px;
    min-height: 200px;
    grid-row: 1;
  }

  .hm-cat-info {
    grid-row: 2;
    border: 0;
    padding: 0.25rem 0;
  }

  .hm-cat-price {
    grid-row: 3;
  }

  .hm-cat-price-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .hm-cat-table {
    min-width: 480px;
    table-layout: auto;
  }

  .hm-cat-btn {
    min-height: var(--tap);
  }

  .hm-cat-steps-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .hm-cat-step:not(:last-child)::after {
    display: none;
  }
}
