/* Maxplus P2: Products hub + product family pages. Extends home-v67 tokens. */

html,
body {
  overflow-x: clip;
}

.mp-breadcrumb {
  padding-block: 0 0.35rem;
}

.mp-breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.55rem;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--steel);
  font-size: 0.82rem;
  font-weight: 650;
}

.mp-breadcrumb li:not(:last-child)::after {
  content: "/";
  margin-left: 0.55rem;
  color: var(--steel-light);
}

.mp-breadcrumb a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--hazard);
  text-underline-offset: 3px;
}

.mp-breadcrumb a:hover {
  color: var(--hazard-deep);
}

.family-page,
.products-hub {
  padding-bottom: 0;
}

/* Override home-v67 .heading-inline { align-items: end } which left empty bands. */
.family-page .heading-inline,
.products-hub .heading-inline,
.inner-page .heading-inline {
  align-items: start;
}

.family-identity {
  padding-block: 0.35rem clamp(1.5rem, 3vw, 2.25rem);
}

.family-identity-crumb {
  margin-bottom: 0.65rem;
}

.family-identity-crumb {
  margin-bottom: 1rem;
}

.family-identity-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  gap: clamp(1.25rem, 3vw, 2.5rem);
  align-items: start;
}

.family-identity-copy .section-index {
  margin-bottom: 0.55rem;
}

.family-identity h1 {
  max-width: 16ch;
  font-size: var(--step-3);
}

.family-intro {
  margin-top: 0.85rem;
  max-width: 58ch;
  color: var(--body);
  font-size: var(--step-1);
  line-height: 1.55;
}

.family-key-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem 1rem;
  margin: 1.15rem 0 0;
  padding: 0.85rem 1rem;
  border: 1px solid var(--line);
  background: var(--surface);
}

.family-key-fact {
  min-width: 0;
}

.family-key-fact dt {
  color: var(--steel);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.family-key-fact dd {
  margin: 0.2rem 0 0;
  color: var(--ink);
  font-size: 0.88rem;
  font-weight: 750;
}

.family-identity-cta {
  margin-top: 1.15rem;
}

.family-identity-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.15rem;
}

.family-identity-cta-row .family-identity-cta {
  margin-top: 0;
}

.family-identity-visual {
  margin: 0;
  align-self: start;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: 0 14px 36px rgb(20 35 59 / 7%);
}

.family-identity-visual img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 28rem;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: center;
}

.family-identity-visual figcaption {
  border-top: 1px solid var(--line);
  padding: 0.6rem 0.85rem;
  color: var(--steel);
  font-size: 0.72rem;
  line-height: 1.4;
}

.family-standards,
.family-range,
.family-specs,
.family-applications,
.family-docs,
.family-certs {
  padding-block: clamp(2rem, 4vw, 3.25rem);
}

.family-standards {
  border-block: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgb(241 244 247 / 70%), rgb(250 251 252 / 0%)),
    var(--paper);
}

.standards-lede {
  max-width: 58ch;
  color: var(--steel);
  font-size: 0.95rem;
}

.standards-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  margin: 1.25rem 0 0;
  border: 1px solid var(--line);
  background: var(--white);
}

.standards-grid-item {
  padding: 0.95rem 1.1rem;
  border-bottom: 1px solid var(--line);
}

.standards-grid-item:nth-child(odd) {
  border-right: 1px solid var(--line);
}

.standards-grid-item:nth-last-child(-n+2) {
  border-bottom: 0;
}

.standards-grid-item dt {
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 800;
  font-variation-settings: "wdth" 108;
}

.standards-grid-item dd {
  margin: 0.45rem 0 0;
  color: var(--body);
  font-size: 0.9rem;
  line-height: 1.5;
}

.range-table-wrap {
  margin-top: 1.15rem;
  border: 1px solid var(--line);
  background: var(--white);
}

.range-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.range-table th,
.range-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.range-table thead th {
  background: var(--ink);
  color: var(--white);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.range-table tbody th {
  width: 28%;
  color: var(--ink);
  font-weight: 800;
}

.range-table tbody td {
  color: var(--steel);
}

.range-table tbody tr:last-child th,
.range-table tbody tr:last-child td {
  border-bottom: 0;
}

.range-quote-link {
  margin-top: 1rem;
}

.range-quote-link .text-action {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  color: var(--ink);
  font-weight: 800;
  text-decoration: underline;
  text-decoration-color: var(--hazard);
  text-underline-offset: 5px;
}

.spec-intro {
  max-width: 58ch;
  color: var(--steel);
  font-size: 0.92rem;
}

.spec-tablist {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 1.15rem;
}

.spec-tab {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: var(--white);
  color: var(--ink);
  cursor: pointer;
  padding: 0.5rem 0.9rem;
  font-size: 0.8rem;
  font-weight: 800;
  transition: border-color 160ms ease-out, background-color 160ms ease-out, color 160ms ease-out;
}

.spec-tab:hover {
  border-color: var(--ink-2);
}

.spec-tab.is-active,
.spec-tab[aria-selected="true"] {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--white);
}

.spec-panels {
  margin-top: 0.85rem;
}

.spec-note {
  margin-top: 0.75rem;
  max-width: 70ch;
  color: var(--steel);
  font-size: 0.86rem;
}

.spec-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  background: var(--white);
  -webkit-overflow-scrolling: touch;
}

.spec-table {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
  font-size: 0.84rem;
}

.spec-table caption {
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid var(--line);
  color: var(--steel);
  font-size: 0.78rem;
  line-height: 1.45;
  text-align: left;
}

.spec-table th,
.spec-table td {
  padding: 0.55rem 0.75rem;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
  white-space: nowrap;
}

.spec-table thead {
  position: sticky;
  top: 0;
  z-index: 1;
}

.spec-table thead th {
  background: var(--ink);
  color: var(--white);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.spec-table tbody tr:nth-child(even) {
  background: rgb(241 244 247 / 45%);
}

.family-app-list {
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
  border: 1px solid var(--line);
  background: var(--white);
}

.family-app-list li {
  display: grid;
  gap: 0.35rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--line);
  color: var(--body);
  font-size: 0.92rem;
}

.family-app-list li:last-child {
  border-bottom: 0;
}

.family-app-list a {
  color: var(--ink);
  font-size: 0.8rem;
  font-weight: 800;
  text-decoration: underline;
  text-decoration-color: var(--hazard);
  text-underline-offset: 4px;
}

.family-docs {
  background: var(--surface);
  border-block: 1px solid var(--line);
}

.family-docs-layout,
.hub-catalogue-layout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}

.family-docs h2,
.hub-catalogue-layout h2,
.family-certs h2 {
  max-width: 20ch;
  font-size: var(--step-2);
}

.family-docs p,
.hub-catalogue-layout p,
.family-certs p {
  margin-top: 0.65rem;
  max-width: 58ch;
  color: var(--steel);
  font-size: 0.92rem;
}

.family-certs {
  padding-block: clamp(1.75rem, 3vw, 2.5rem);
}

.family-honesty {
  margin-top: 0.65rem !important;
  color: var(--body) !important;
  font-weight: 650;
}

.family-certs .text-action {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  color: var(--ink);
  font-weight: 800;
  text-decoration: underline;
  text-decoration-color: var(--hazard);
  text-underline-offset: 5px;
}

.family-quote .quote-layout {
  gap: 1.25rem;
}

.products-hub-intro {
  padding-block: clamp(1.25rem, 2.5vw, 2rem) 0.75rem;
}

.products-hub-intro h1 {
  max-width: 12ch;
  font-size: var(--step-3);
}

.products-hub-lede {
  margin-top: 0.75rem;
  max-width: 52ch;
  color: var(--body);
  font-size: var(--step-1);
}

.products-hub-intro-note {
  margin-top: 0.85rem;
  max-width: 62ch;
  color: var(--steel);
  font-size: 0.9rem;
}

.products-hub-finder,
.products-hub-families,
.products-hub-catalogue {
  padding-block: clamp(1.5rem, 3vw, 2.5rem);
}

.products-hub-finder .family-finder-bar {
  margin-top: 0.35rem;
}

.hub-family-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.85rem;
  margin: 1.15rem 0 0;
  padding: 0;
  list-style: none;
}

.hub-family-card {
  grid-column: span 2;
  min-width: 0;
  border: 1px solid var(--line);
  background: var(--white);
  transition: border-color 180ms ease-out, box-shadow 180ms ease-out;
}

.hub-family-card:nth-child(n+4) {
  grid-column: span 3;
}

.hub-family-card:hover {
  border-color: var(--ink-2);
  box-shadow: 0 10px 28px rgb(20 35 59 / 8%);
}

.hub-family-link {
  display: flex;
  height: 100%;
  flex-direction: column;
  color: inherit;
}

.hub-family-visual {
  margin: 0;
  overflow: hidden;
  background: var(--surface);
}

.hub-family-visual img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: scale 280ms ease-out;
}

.hub-family-card:hover img {
  scale: 1.02;
}

.hub-family-copy {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  padding: clamp(0.95rem, 1.8vw, 1.2rem);
}

.hub-family-copy h3 {
  font-size: clamp(1.02rem, 1.1vw, 1.18rem);
}

.hub-family-copy p {
  margin-top: 0.45rem;
  color: var(--steel);
  font-size: 0.86rem;
}

.hub-family-fact {
  margin-top: 0.55rem;
  color: var(--ink);
  font-size: 0.76rem;
  font-weight: 750;
  letter-spacing: 0.01em;
}

.hub-family-cta {
  margin-top: auto;
  padding-top: 0.85rem;
  color: var(--ink);
  font-size: 0.76rem;
  font-weight: 800;
  text-decoration: underline;
  text-decoration-color: var(--hazard);
  text-underline-offset: 5px;
}

.hub-family-empty {
  grid-column: 1 / -1;
  border: 1px dashed var(--line);
  background: var(--surface);
  padding: 1.15rem;
}

@media (max-width: 1100px) {
  .family-identity-layout {
    grid-template-columns: 1fr;
  }

  .standards-grid {
    grid-template-columns: 1fr;
  }

  .standards-grid-item:nth-child(odd) {
    border-right: 0;
  }

  .standards-grid-item:nth-last-child(-n+2) {
    border-bottom: 1px solid var(--line);
  }

  .standards-grid-item:last-child {
    border-bottom: 0;
  }

  .family-key-facts {
    grid-template-columns: 1fr;
  }

  .hub-family-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hub-family-card,
  .hub-family-card:nth-child(n+4) {
    grid-column: auto;
  }
}

@media (max-width: 720px) {
  .family-docs-layout,
  .hub-catalogue-layout,
  .quote-layout {
    flex-direction: column;
    align-items: flex-start;
  }

  .hub-family-grid {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hub-family-card,
  .hub-family-visual img,
  .spec-tab {
    transition: none;
  }

  .hub-family-card:hover img {
    scale: none;
  }

  .mp-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* At a glance + cert trust + compact tables + sticky quote */
.family-glance-label {
  margin: 1.15rem 0 0.45rem;
  color: var(--hazard-deep);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.family-cert-trust {
  margin: 0 0 1.25rem;
  padding: 1rem 1.15rem;
  border: 1px solid var(--line);
  background: var(--white);
}

.family-cert-trust-label {
  margin: 0 0 0.65rem;
  color: var(--hazard-deep);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.family-cert-trust-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.family-cert-trust-list li {
  display: grid;
  gap: 0.2rem;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--line);
  background: var(--surface);
}

.family-cert-trust-list strong {
  color: var(--ink);
  font-size: 0.86rem;
  font-variation-settings: "wdth" 108;
}

.family-cert-trust-list span {
  color: var(--steel);
  font-size: 0.76rem;
}

.family-cert-trust-note {
  margin: 0.75rem 0 0;
  color: var(--steel);
  font-size: 0.82rem;
}

.spec-table-block { margin-top: 0.35rem; }

.spec-table-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
}

.spec-table-meta {
  margin: 0;
  color: var(--steel);
  font-size: 0.8rem;
  font-weight: 650;
}

.spec-table-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.family-quote-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.family-related { padding-block: 2rem 1rem; }

.family-related-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.family-related-list a {
  display: grid;
  gap: 0.35rem;
  min-height: 100%;
  padding: 1rem 1.1rem;
  border: 1px solid var(--line);
  background: var(--white);
  color: inherit;
  text-decoration: none;
}

.family-related-list a:hover { border-color: rgb(20 35 59 / 35%); }
.family-related-list strong { color: var(--ink); font-size: 1rem; }
.family-related-list span { color: var(--steel); font-size: 0.86rem; line-height: 1.45; }

.range-cutout-cell {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.range-cutout-cell img {
  flex: 0 0 auto;
  width: 72px;
  height: 54px;
  object-fit: cover;
  background: var(--surface);
  border: 1px solid var(--line);
}

.family-sticky-quote {
  position: sticky;
  bottom: 0;
  z-index: 40;
  border-top: 1px solid var(--line);
  background: rgb(255 255 255 / 96%);
  backdrop-filter: blur(8px);
  box-shadow: 0 -10px 28px rgb(20 35 59 / 8%);
}

.family-sticky-quote[hidden] { display: none !important; }

.family-sticky-quote-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.7rem;
}

.family-sticky-quote-inner > p {
  margin: 0;
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 800;
}

.family-sticky-quote-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }

.mp-reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.mp-reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* Single product detail (flagship P2). */

.product-detail-page {
  padding-bottom: 0;
}

.product-detail-page .heading-inline {
  align-items: start;
}

.product-identity {
  padding-block: 0.35rem clamp(1.5rem, 3vw, 2.25rem);
}

.product-identity-crumb {
  margin-bottom: 1rem;
}

.product-identity-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  gap: clamp(1.25rem, 3vw, 2.5rem);
  align-items: start;
}

.product-identity-copy .section-index {
  margin-bottom: 0.55rem;
}

.product-identity h1 {
  max-width: 18ch;
  font-size: var(--step-3);
  text-wrap: balance;
}

.product-intro {
  margin-top: 0.85rem;
  max-width: 58ch;
  color: var(--body);
  font-size: var(--step-1);
  line-height: 1.55;
  text-wrap: pretty;
}

.product-identity-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.15rem;
}

.product-identity-visual {
  margin: 0;
  align-self: start;
  overflow: hidden;
  border: 1px solid var(--line);
  background:
    radial-gradient(ellipse at 30% 20%, rgb(30 51 80 / 18%), transparent 55%),
    linear-gradient(165deg, #1a2c45 0%, #14233b 55%, #0f1a2c 100%);
  box-shadow: 0 14px 36px rgb(20 35 59 / 7%);
}

.product-identity-visual img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 28rem;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: center;
}

.product-identity-visual figcaption {
  border-top: 1px solid rgb(255 255 255 / 12%);
  padding: 0.6rem 0.85rem;
  color: rgb(241 244 247 / 78%);
  font-size: 0.72rem;
  line-height: 1.4;
  background: rgb(15 26 44 / 55%);
}

.product-standards,
.product-specs,
.product-certs {
  padding-block: clamp(2rem, 4vw, 3.25rem);
}

.product-standards {
  border-block: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgb(241 244 247 / 70%), rgb(250 251 252 / 0%)),
    var(--paper);
}

.product-spec-family-link {
  margin-top: 1rem;
}

.product-spec-family-link .text-action {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  color: var(--ink);
  font-weight: 800;
  text-decoration: underline;
  text-decoration-color: var(--hazard);
  text-underline-offset: 5px;
}

.product-certs {
  background: var(--surface);
  border-block: 1px solid var(--line);
}

.product-certs h2 {
  max-width: 22ch;
  font-size: var(--step-2);
}

.product-certs > p {
  margin-top: 0.65rem;
  max-width: 62ch;
  color: var(--steel);
  font-size: 0.92rem;
}

.product-quote {
  margin-top: 0;
}

@media (max-width: 900px) {
  .product-identity-layout {
    grid-template-columns: 1fr;
  }

  .product-identity-visual {
    order: -1;
  }

  .family-cert-trust-list,
  .family-related-list { grid-template-columns: 1fr; }
}
