/* =========================================================================
   IRA BIOTECH — Products page
   Editorial catalog: dense typographic rows, hairline dividers, no cards.
   ========================================================================= */

/* ---- Intro ---- */
.products-intro { padding-top: clamp(6rem, 12vw, 8rem); padding-bottom: var(--s-10); background: var(--bg); }
.products-intro h1 { margin-block: var(--s-5); max-width: 16ch; }
.products-intro .lede { max-width: 58ch; font-size: 1.1rem; }

/* ---- Intro with background photo + dark overlay (same recipe as
   .page-intro.has-image in pages.css, duplicated here since product pages
   don't load pages.css) ---- */
.products-intro.has-image {
  position: relative;
  padding-top: clamp(9rem, 16vw, 12rem);
  padding-bottom: var(--s-20);
  background-color: var(--charcoal);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  overflow: hidden;
}
.products-intro.has-image::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(16,32,25,.6) 0%, rgba(16,32,25,.4) 45%, rgba(16,32,25,.88) 100%);
}
.products-intro.has-image > .wrap { position: relative; }
.products-intro.has-image h1, .products-intro.has-image .eyebrow { color: var(--on-dark); }
.products-intro.has-image .lede { color: var(--on-dark-soft); }
@media (max-width: 640px) { .products-intro.has-image { padding-bottom: var(--s-16); } }

.filter-bar { display: flex; gap: var(--s-3); flex-wrap: wrap; margin-top: var(--s-10); }
.filter-btn {
  display: inline-flex; align-items: center; gap: var(--s-2);
  padding: .7rem 1.2rem;
  border: 1.5px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: transparent;
  font-weight: 700; font-size: .88rem; color: var(--ink);
  transition: background-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}
.filter-btn span { color: var(--ink-faint); font-weight: 600; }
.filter-btn.is-active { background: var(--ink); color: var(--white); border-color: var(--ink); }
.filter-btn.is-active span { color: var(--on-dark-soft); }
.filter-btn:not(.is-active):hover { background: var(--sage); }

/* ---- Platform section ---- */
.platform-section:nth-of-type(odd) { background: var(--bg); }
.platform-section:nth-of-type(even) { background: var(--bg-alt); }
.platform-head { max-width: 62ch; margin-bottom: var(--s-10); }
.platform-head h2 { margin-block: var(--s-4); }
.platform-head .lede { font-size: 1.05rem; }
.platform-count {
  display: inline-block; margin-top: var(--s-5);
  font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent-ink);
}

/* ---- Subcategory ---- */
.subcat { margin-bottom: var(--s-10); scroll-margin-top: 6.5rem; }
.subcat:last-child { margin-bottom: 0; }
.subcat-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: var(--s-4);
  border-bottom: 1.5px solid var(--line-strong);
  padding-bottom: var(--s-3);
  margin-bottom: var(--s-2);
}
.subcat-head h3 { font-size: 1.15rem; font-weight: 700; }
.subcat-count { font-size: .8rem; color: var(--ink-faint); font-weight: 600; white-space: nowrap; }

/* ---- Product row ---- */
.product-row {
  display: grid; grid-template-columns: 96px 1.5fr 1fr; gap: var(--s-6);
  align-items: center;
  padding-block: var(--s-5);
  border-bottom: 1px solid var(--line);
}
.product-row:hover { background: var(--bg-alt); }
.p-thumb {
  width: 96px; height: 96px; border-radius: var(--radius-sm);
  background: var(--white); border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; flex-shrink: 0;
}
.p-thumb img { width: 100%; height: 100%; object-fit: contain; padding: var(--s-2); }
.p-thumb.is-fallback::after {
  content: "";
  width: 22px; height: 22px;
  background: var(--sage);
  border: 1.5px solid var(--accent);
  border-radius: 2px;
}
.p-main h4 { font-size: 1.02rem; font-weight: 700; display: flex; align-items: center; gap: var(--s-3); flex-wrap: wrap; }
.p-main h4 a { color: var(--ink); border-bottom: 1px solid transparent; transition: border-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease); }
.p-main h4 a:hover { color: var(--accent-ink); border-color: var(--accent-ink); }
.p-main p { margin-top: var(--s-2); font-size: .92rem; max-width: 58ch; }
.p-thumb[href] { cursor: pointer; transition: border-color var(--dur-fast) var(--ease); }
.p-thumb[href]:hover { border-color: var(--accent); }
.p-tag {
  font-size: .68rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  color: var(--precision); border: 1px solid var(--precision); border-radius: var(--radius-sm);
  padding: .15rem .45rem;
}
.p-meta { display: flex; flex-direction: column; gap: var(--s-2); padding-top: .15rem; }
.p-spec { font-size: .85rem; font-weight: 600; color: var(--ink); }
.p-dosage { font-size: .82rem; color: var(--ink-faint); }

@media (max-width: 700px) {
  .product-row { grid-template-columns: 72px 1fr; grid-template-areas: "thumb main" "meta meta"; gap: var(--s-2) var(--s-4); }
  .p-thumb { width: 72px; height: 72px; grid-area: thumb; }
  .p-main { grid-area: main; }
  .p-meta { grid-area: meta; flex-direction: row; flex-wrap: wrap; gap: var(--s-4); padding-top: var(--s-2); }
}

/* ---- Scope note ---- */
.scope-note { background: var(--bg); }
.note-box {
  border: 1.5px solid var(--line-strong); border-radius: var(--radius);
  padding: var(--s-8); max-width: 74ch;
}
.note-box h3 { font-size: 1.05rem; margin-bottom: var(--s-3); }
.note-box p { font-size: .92rem; }
.note-box .link-arrow { display: inline-flex; margin-left: var(--s-1); }

/* ---- Final CTA (shared look with homepage) ---- */
.final-cta { background: var(--sage); text-align: center; }
.final-cta h2 { max-width: 18ch; margin-inline: auto; }
.final-cta .btn { margin-top: var(--s-8); }

/* ---- Platform picker (products hub — links out to the two catalog pages) ---- */
.platform-picker { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-8); margin-top: var(--s-10); }
.platform-card {
  display: block;
  border: 1.5px solid var(--line-strong); border-radius: var(--radius);
  padding: var(--s-10);
  transition: background-color var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease);
}
.platform-card:hover { background: var(--sage); border-color: var(--accent); }
.platform-card .eyebrow { margin-bottom: var(--s-4); }
.platform-card h3 { font-size: 1.6rem; margin-bottom: var(--s-3); }
.platform-card p { font-size: .95rem; max-width: 42ch; color: var(--ink-soft); }
.platform-card .pc-count {
  display: block; margin-top: var(--s-6);
  font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent-ink);
}
.platform-card .link-arrow { margin-top: var(--s-6); display: inline-flex; }
@media (max-width: 780px) { .platform-picker { grid-template-columns: 1fr; gap: var(--s-6); } }

/* ---- Cross-link panel (Agriculture/Aquaculture pages — links to the sibling platform) ---- */
.cross-link { background: var(--bg-alt); }
