/* ==========================================================================
   GLOBAL STYLES — Stabplast
   Import order: tokens → reset/base → layout → components → utilities
   ========================================================================== */
@import "tokens.css";

/* ---------- Reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
img, picture, svg, video { display: block; max-width: 100%; height: auto; }
ul[class], ol[class] { list-style: none; padding: 0; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }

/* ---------- Base ---------- */
body {
  font-family: var(--font-sans);
  font-size: var(--fs-base);
  line-height: var(--lh-body);
  color: var(--color-body);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  line-height: var(--lh-heading);
  color: var(--color-ink);
  font-weight: var(--fw-bold);
  letter-spacing: -0.01em;
}
h1 { font-size: var(--fs-h1); font-weight: var(--fw-black); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }
h4 { font-size: var(--fs-h4); }
p { max-width: 68ch; }
a:not([class]) { color: var(--color-primary-dark); text-decoration: underline; text-underline-offset: 2px; }
a:not([class]):hover { color: var(--color-primary-darker); }

:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: 2px;
  border-radius: 3px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--color-primary);
  color: #fff;
  padding: 0.75rem 1.25rem;
  z-index: 200;
  border-radius: 0 0 var(--radius-sm) 0;
}
.skip-link:focus { left: 0; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* ---------- Layout ---------- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container--narrow { max-width: var(--container-narrow); }
.section { padding-block: clamp(3rem, 8vw, 6rem); }
.section--alt { background: var(--color-bg-alt); }
.section--tint { background: var(--color-primary-tint); }

.section__head { max-width: 60ch; margin-bottom: var(--space-4); }
.section__head--center { margin-inline: auto; text-align: center; }
.eyebrow {
  display: inline-block;
  font-size: var(--fs-eyebrow);
  font-weight: var(--fw-bold);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-primary-dark);
  margin-bottom: var(--space-1);
}
.lead { font-size: var(--fs-lg); color: var(--color-muted); }

.grid { display: grid; gap: var(--space-3); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.6rem;
  border-radius: var(--radius-sm);
  font-weight: var(--fw-semibold);
  font-size: var(--fs-sm);
  line-height: 1;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background var(--transition), color var(--transition), transform var(--transition);
  min-height: 44px;
}
.btn:hover { transform: translateY(-1px); }
.btn--primary { background: var(--color-primary); color: #fff; }
.btn--primary:hover { background: var(--color-primary-dark); }
.btn--ghost { background: transparent; color: var(--color-primary-dark); border-color: currentColor; }
.btn--ghost:hover { background: var(--color-primary); color: #fff; border-color: var(--color-primary); }
.btn--white { background: #fff; color: var(--color-primary-dark); }
.btn--white:hover { background: var(--color-primary-tint); }
.btn--accent { background: var(--color-yellow); color: var(--color-ink); }
.btn--accent:hover { background: var(--color-yellow-hover); }
.btn--lg { padding: 1rem 2rem; font-size: var(--fs-base); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--color-line);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  min-height: var(--header-h);
}
.brand { display: flex; align-items: center; gap: 0.6rem; font-weight: var(--fw-black); color: var(--color-ink); font-size: 1.2rem; }
.brand__mark { width: 34px; height: 34px; flex: none; color: var(--color-primary); }
.brand__name { line-height: 1.05; }
.brand__name small { display: block; font-size: 0.62rem; font-weight: var(--fw-medium); letter-spacing: 0.14em; text-transform: uppercase; color: var(--color-muted); }

.nav { display: flex; align-items: center; gap: var(--space-3); }
.nav__list { display: flex; align-items: center; gap: 0.35rem; }
.nav__link {
  position: relative;
  display: inline-block;
  padding: 0.55rem 0.7rem;
  font-weight: var(--fw-semibold);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-ink);
  transition: color var(--transition);
}
/* Distinct active/hover: amber underline instead of the generic pill */
.nav__link::after {
  content: "";
  position: absolute;
  left: 0.7rem;
  right: 0.7rem;
  bottom: 0.15rem;
  height: 2px;
  background: var(--color-yellow);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition);
}
.nav__link:hover, .nav__link[aria-current="page"] { color: var(--color-primary-dark); }
.nav__link:hover::after, .nav__link[aria-current="page"]::after { transform: scaleX(1); }

/* ---------- Top utility strip (two-tier industrial header) ---------- */
.utility-bar {
  background: var(--color-bg-dark);
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.78rem;
}
.utility-bar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  min-height: 34px;
}
.utility-bar__group { display: flex; align-items: center; gap: var(--space-3); }
.utility-bar a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: rgba(255, 255, 255, 0.85);
  font-weight: var(--fw-medium);
}
.utility-bar a:hover { color: var(--color-yellow-bright); }
.utility-bar svg { flex: none; opacity: 0.8; }
.utility-bar__note { color: var(--color-yellow-bright); font-weight: var(--fw-semibold); letter-spacing: 0.03em; }
@media (max-width: 900px) {
  /* Keep the dark contact strip on phones — phone + email only, drop the
     right-hand note and centre the pair */
  .utility-bar { font-size: 0.68rem; }
  .utility-bar__inner { justify-content: center; min-height: 30px; }
  .utility-bar__group:first-child { gap: var(--space-2); }
  .utility-bar__group:last-child { display: none; }
}

/* "Technical Services" is the longest label and wraps to two lines on
   desktop — center the wrapped text and size it down 2px so it sits balanced.
   "Knowledge Hub" matches it (same size + centered) for a consistent pair. */
@media (min-width: 901px) {
  .nav__link[href*="technical-services"],
  .nav__link[href="/articles/"],
  .nav__link[href="/contact/"] {
    font-size: calc(0.85rem - 2px);
    text-align: center;
    line-height: 1.35;
  }
}

.nav-toggle { display: none; }
.header-actions { display: flex; align-items: center; gap: var(--space-2); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  color: #fff;
  background: linear-gradient(115deg, var(--color-primary-darker) 0%, var(--color-primary) 70%);
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='104' viewBox='0 0 120 104'%3E%3Cpath fill='none' stroke='%23ffffff' stroke-opacity='0.08' stroke-width='2' d='M30 2 L60 19 L60 53 L30 70 L0 53 L0 19 Z M90 2 L120 19 L120 53 L90 70 L60 53 L60 19 Z M60 53 L90 70 L90 104'/%3E%3C/svg%3E");
  opacity: 0.6;
  pointer-events: none;
}
.hero__inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: var(--space-4);
  align-items: center;
  padding-block: clamp(3rem, 7vw, 5.5rem);
}
.hero__eyebrow { color: rgba(255,255,255,0.85); }
.hero h1 { color: #fff; max-width: 16ch; }
.hero__text { color: rgba(255,255,255,0.9); font-size: var(--fs-lg); margin-top: var(--space-2); max-width: 46ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-top: var(--space-4); }
.hero__media img { border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); }
.hero__stats { display: flex; gap: var(--space-4); margin-top: var(--space-4); flex-wrap: wrap; }
.hero__stat b { display: block; font-size: 2rem; font-weight: var(--fw-black); color: #fff; line-height: 1; }
.hero__stat span { font-size: var(--fs-sm); color: rgba(255,255,255,0.8); }

/* ---------- Cards ---------- */
.card {
  background: #fff;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
  height: 100%;
  display: flex;
  flex-direction: column;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.card__media { aspect-ratio: 4 / 3; overflow: hidden; background: var(--color-bg-alt); }
.card__media img { width: 100%; height: 100%; object-fit: cover; }
.card__body { padding: var(--space-3); display: flex; flex-direction: column; gap: 0.5rem; flex: 1; }
.card__title { font-size: 1.15rem; }
.card__link { margin-top: auto; color: var(--color-primary-dark); font-weight: var(--fw-semibold); font-size: var(--fs-sm); }

/* Feature (icon) card */
.feature { text-align: left; }
.feature__icon {
  width: 52px; height: 52px; display: grid; place-items: center;
  border-radius: var(--radius-sm); background: var(--color-primary-tint); color: var(--color-primary-dark);
  margin-bottom: var(--space-2);
}
.feature__icon svg { width: 26px; height: 26px; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--color-primary); color: #fff; }
.cta-band__inner {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap;
  gap: var(--space-3); padding-block: clamp(2.5rem, 6vw, 4rem);
}
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,0.95); }
.cta-band__actions { display: flex; gap: var(--space-2); flex-wrap: wrap; }

/* ---------- Footer ---------- */
.site-footer { background: var(--color-bg-dark); color: rgba(255,255,255,0.75); }
.site-footer a { color: rgba(255,255,255,0.75); }
.site-footer a:hover { color: #fff; }
.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: var(--space-4);
  padding-block: var(--space-5);
}
.footer__brand .brand { color: #fff; }
.footer__brand .brand__name small { color: rgba(255,255,255,0.6); }
.footer__about { margin-top: var(--space-2); font-size: var(--fs-sm); max-width: 34ch; }
.footer__col h3 { color: #fff; font-size: 0.95rem; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: var(--space-2); }
.footer__col ul { display: grid; gap: 0.6rem; font-size: var(--fs-sm); }
.footer__contact li { display: flex; gap: 0.6rem; margin-bottom: 0.6rem; font-size: var(--fs-sm); }
.footer__bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-block: var(--space-3);
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: var(--space-2);
  font-size: var(--fs-sm);
}
.footer__social { display: flex; gap: 0.75rem; }
.footer__social a { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 50%; background: rgba(255,255,255,0.08); }
.footer__social a:hover { background: var(--color-primary); }
.footer__social svg { width: 18px; height: 18px; }

/* ---------- Scroll-to-top ---------- */
.to-top {
  position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 90;
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--color-primary); color: #fff; display: grid; place-items: center;
  box-shadow: var(--shadow); opacity: 0; visibility: hidden; transition: opacity var(--transition), visibility var(--transition);
}
.to-top.is-visible { opacity: 1; visibility: visible; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero__inner { grid-template-columns: 1fr; }
  .hero__media { order: -1; max-width: 460px; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

/* Drawer CTA + accordion subtoggles exist only in the mobile drawer */
.nav__cta { display: none; }
.nav__subtoggle { display: none; }

@media (max-width: 900px) {
  /* Full-height off-canvas drawer — independent of page scroll position,
     internally scrollable so every entry is always reachable */
  .nav {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: auto;
    height: 100dvh;
    width: min(340px, 86vw);
    flex-direction: column;
    align-items: stretch;
    gap: var(--space-1);
    background: #fff;
    padding: var(--space-3);
    box-shadow: var(--shadow-lg);
    transform: translateX(100%);
    transition: transform var(--transition);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
  }
  .nav[data-open="true"] { transform: translateX(0); }
  .nav__list { flex-direction: column; align-items: stretch; gap: 0.25rem; }
  .nav__link { padding: 0.8rem 0.85rem; display: block; font-size: 0.9rem; }
  .nav__link::after { display: none; } /* desktop underline animation off in drawer */

  /* Parent rows: link + tap-to-expand chevron side by side */
  .nav__item--has-children { display: flex; flex-wrap: wrap; align-items: center; }
  .nav__item--has-children > .nav__link { flex: 1; }
  .nav__subtoggle {
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    flex: none;
    border: 1px solid var(--color-line);
    border-radius: var(--radius-sm);
    background: var(--color-bg-alt);
    color: var(--color-ink);
    cursor: pointer;
  }
  .nav__subtoggle svg { transition: transform var(--transition); }
  .nav__item.is-open .nav__subtoggle svg { transform: rotate(180deg); }

  /* Quote CTA inside the drawer */
  .nav__cta { display: block; margin-top: var(--space-2); }
  .nav__cta .btn--quote { display: inline-flex; justify-content: center; width: 100%; padding: 0.8rem 1.3rem; }

  /* Minimal hamburger — just the 3 bars, no border/background */
  .nav-toggle {
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--color-ink);
    cursor: pointer;
  }

  /* Two-class selector (0,2,0) so this wins regardless of source order —
     the base .btn--quote rule lives later in the file and would otherwise
     override a single-class hide here, leaving the CTA overflowing the bar. */
  .header-utility .btn--quote-desktop { display: none; }
}
@media (max-width: 768px) {
  .footer__grid { grid-template-columns: 1fr; gap: var(--space-3); }
}

/* ==========================================================================
   YELLOW ACCENTS (safety amber) — decorative + CTA emphasis
   ========================================================================== */

/* Accent bar under section headings */
.section__head h2 { position: relative; }
.section__head h2::after {
  content: "";
  display: block;
  width: 56px;
  height: 4px;
  border-radius: 2px;
  background: var(--color-yellow);
  margin-top: var(--space-2);
}
.section__head--center h2::after { margin-inline: auto; }

/* Hero stat numbers pop in amber (large + bold => AA large-text) */
.hero__stat b { color: var(--color-yellow-bright); }

/* Card top-accent reveal on hover */
.card { position: relative; }
.card::after {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--color-yellow);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition);
  z-index: 1;
}
.card:hover::after { transform: scaleX(1); }

/* Feature icon warms to amber on hover */
.feature:hover .feature__icon { background: var(--color-yellow); color: var(--color-ink); }

/* Footer heading gets a short amber underline; links warm on hover */
.footer__col h3 {
  display: inline-block;
  padding-bottom: 6px;
  border-bottom: 3px solid var(--color-yellow);
}
.site-footer a:hover { color: var(--color-yellow-bright); }

/* Scroll-to-top warms to amber on hover */
.to-top:hover { background: var(--color-yellow); color: var(--color-ink); }

/* ==========================================================================
   INTERIOR PAGES — page hero, breadcrumbs, card tag
   ========================================================================== */
.page-hero {
  position: relative;
  background: linear-gradient(115deg, var(--color-primary-darker) 0%, var(--color-primary) 75%);
  color: #fff;
  overflow: hidden;
}
.page-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='104' viewBox='0 0 120 104'%3E%3Cpath fill='none' stroke='%23ffffff' stroke-opacity='0.08' stroke-width='2' d='M30 2 L60 19 L60 53 L30 70 L0 53 L0 19 Z M90 2 L120 19 L120 53 L90 70 L60 53 L60 19 Z M60 53 L90 70 L90 104'/%3E%3C/svg%3E");
  opacity: 0.5;
  pointer-events: none;
}
.page-hero__inner { position: relative; z-index: 1; padding-block: clamp(2.25rem, 5vw, 3.5rem); }
.page-hero h1 { color: #fff; max-width: 20ch; }
.page-hero p { color: rgba(255,255,255,0.92); font-size: var(--fs-lg); margin-top: var(--space-2); max-width: 60ch; }

.breadcrumbs { font-size: var(--fs-sm); margin-bottom: var(--space-2); color: rgba(255,255,255,0.8); }
.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: center; list-style: none; }
.breadcrumbs a { color: rgba(255,255,255,0.85); text-decoration: underline; text-underline-offset: 2px; }
.breadcrumbs a:hover { color: var(--color-yellow-bright); }
.breadcrumbs li[aria-current] { color: #fff; }
.breadcrumbs .sep { opacity: 0.6; }

.card__tag {
  font-size: 0.72rem;
  font-weight: var(--fw-bold);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-primary-dark);
}

/* Category block (products index grouped by category) */
.category-block + .category-block { margin-top: var(--space-5); }
.category-block__head { display: flex; align-items: baseline; justify-content: space-between; gap: var(--space-2); flex-wrap: wrap; margin-bottom: var(--space-3); }
.category-block__head p { color: var(--color-muted); max-width: 60ch; margin-top: 0.25rem; }

/* Related-product chips */
.chips { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: auto; padding-top: 0.5rem; }
.chip {
  display: inline-block;
  padding: 0.3rem 0.7rem;
  font-size: 0.8rem;
  font-weight: var(--fw-semibold);
  color: var(--color-primary-dark);
  background: var(--color-primary-tint);
  border-radius: 999px;
  transition: background var(--transition), color var(--transition);
}
.chip:hover { background: var(--color-primary); color: #fff; }

/* ---------------------------------------------------------------------------
   PRODUCT DETAIL PAGE (M4)
   --------------------------------------------------------------------------- */
.page-hero__eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: var(--fw-bold);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-yellow-bright);
  margin-bottom: 0.5rem;
}
.page-hero__actions { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-top: var(--space-3); }

.product-detail {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: start;
}
.product-detail__media {
  position: sticky;
  top: calc(var(--header-h) + 1rem);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--color-primary-tint);
  box-shadow: var(--shadow-sm);
}
.product-detail__media img { display: block; width: 100%; height: auto; }
.product-detail__heading { font-size: var(--fs-h4); }
.product-detail__lead { color: var(--color-body); max-width: 65ch; margin-top: 0.5rem; }

.spec-group { margin-top: var(--space-4); }
.spec-group h3 { font-size: var(--fs-lg); margin-bottom: 0.75rem; }
.prop-list { list-style: none; display: grid; gap: 0.6rem; }
.prop-list li {
  position: relative;
  padding-left: 1.75rem;
  color: var(--color-body);
}
.prop-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.35em;
  width: 1.1rem;
  height: 1.1rem;
  background: var(--color-primary-tint);
  border-radius: 50%;
  box-shadow: inset 0 0 0 2px var(--color-primary);
}
.prop-list li::after {
  content: "";
  position: absolute;
  left: 0.34rem;
  top: 0.6em;
  width: 0.42rem;
  height: 0.22rem;
  border-left: 2px solid var(--color-primary);
  border-bottom: 2px solid var(--color-primary);
  transform: rotate(-45deg);
}

.spec-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: var(--space-2);
  margin-top: var(--space-4);
  border-top: 1px solid var(--color-line);
  padding-top: var(--space-3);
}
.spec-item { display: flex; flex-direction: column; gap: 0.2rem; }
.spec-item__label {
  font-size: 0.72rem;
  font-weight: var(--fw-bold);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-muted);
}
.spec-item__value { color: var(--color-ink); font-weight: var(--fw-medium); }

.product-note {
  margin-top: var(--space-3);
  padding: 0.85rem 1rem;
  font-size: var(--fs-sm);
  color: var(--color-body);
  background: #fff9e6;
  border-left: 3px solid var(--color-yellow);
  border-radius: 6px;
}

.product-detail__cta { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-top: var(--space-4); }
.btn--ghost-dark {
  color: var(--color-primary-dark);
  border: 1px solid var(--color-line);
  background: transparent;
}
.btn--ghost-dark:hover { border-color: var(--color-primary); background: var(--color-primary-tint); }

.section--tint { background: var(--color-primary-tint); }
.section--tint .chips { margin-top: 0; padding-top: 0; }

@media (max-width: 900px) {
  .product-detail { grid-template-columns: 1fr; }
  .product-detail__media { position: static; max-width: 480px; }
}

/* ---------------------------------------------------------------------------
   CONTACT / REQUEST-A-QUOTE PAGE (M5)
   --------------------------------------------------------------------------- */
.contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: start;
}

/* ---- Form ---- */
.contact-form__title { font-size: var(--fs-h3); }
.contact-form__intro { color: var(--color-muted); margin-top: 0.35rem; margin-bottom: var(--space-3); }
.contact-form { display: grid; gap: var(--space-3); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-3); }
.field { display: flex; flex-direction: column; gap: 0.4rem; }
.field label { font-size: var(--fs-sm); font-weight: var(--fw-semibold); color: var(--color-ink); }
.req { color: var(--color-primary-dark); }

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-sm);
  background: #fff;
  color: var(--color-ink);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.field textarea { resize: vertical; min-height: 7.5rem; }
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px var(--color-primary-tint);
}
.field input::placeholder,
.field textarea::placeholder { color: var(--color-muted); }

/* Checkbox row */
.field--check label { display: flex; align-items: flex-start; gap: 0.6rem; font-weight: var(--fw-medium); }
.field--check input { width: 1.15rem; height: 1.15rem; margin-top: 0.15rem; flex: none; accent-color: var(--color-primary); }

/* Honeypot — visually removed, still in DOM for bots */
.form-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.contact-form__actions { display: flex; align-items: center; gap: var(--space-3); flex-wrap: wrap; }
.form-note { font-size: var(--fs-sm); color: var(--color-muted); margin: 0; }

/* ---- Aside / contact card ---- */
.contact-aside { display: grid; gap: var(--space-3); }
.contact-card {
  background: var(--color-primary-tint);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  padding: clamp(1.25rem, 3vw, 1.75rem);
}
.contact-card__title { font-size: var(--fs-h4); }
.contact-card__tagline { color: var(--color-muted); font-size: var(--fs-sm); margin-top: 0.35rem; }

.contact-list { list-style: none; display: grid; gap: var(--space-3); margin-top: var(--space-3); }
.contact-list li { display: flex; gap: 0.75rem; }
.contact-list svg { color: var(--color-primary-dark); flex: none; margin-top: 0.15rem; }
.contact-list__label {
  display: block;
  font-size: 0.72rem;
  font-weight: var(--fw-bold);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-muted);
  margin-bottom: 0.15rem;
}
.contact-list address { font-style: normal; color: var(--color-ink); }
.contact-list a { color: var(--color-primary-dark); font-weight: var(--fw-medium); }
.contact-list a:hover { color: var(--color-primary-darker); }

.contact-card__cta { display: flex; gap: var(--space-2); flex-wrap: wrap; margin-top: var(--space-4); }

.contact-map { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--color-line); }
.contact-map iframe { display: block; width: 100%; height: 320px; border: 0; }

@media (max-width: 900px) {
  .contact-layout { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .form-row { grid-template-columns: 1fr; }
}

/* ---------------------------------------------------------------------------
   HEADER LOGO, PERMANENT PHONE, WHATSAPP FLOAT (M9)
   --------------------------------------------------------------------------- */
/* Brand logo with a white plate so the dark wordmark reads on any background
   (white solid header, transparent hero header, dark footer). */
.brand__logo {
  display: block;
  height: 52px;
  width: auto;
}

/* Adaptive logo: no plate anywhere. Over the transparent hero header (all
   widths) the dark wordmark renders pure white for contrast; on the solid/white
   header (scrolled, or interior pages) it shows its original colours; the dark
   footer whitens it too. */
.site-header--overlay:not(.is-solid) .brand__logo,
.site-footer .brand__logo {
  filter: brightness(0) invert(1);
}

/* Header row: brand left, nav + utility cluster pushed right */
.site-header__inner { justify-content: flex-start; }
.brand { margin-right: auto; flex: none; }
.header-utility { display: flex; align-items: center; gap: var(--space-2); }

/* Request a Quote — pill CTA: amber gradient, arrow nudge, hover lift */
.btn--quote {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1.3rem;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--color-yellow-bright) 0%, var(--color-yellow-hover) 100%);
  color: var(--color-ink);
  font-weight: var(--fw-bold);
  font-size: var(--fs-sm);
  white-space: nowrap;
  box-shadow: 0 4px 14px rgba(255, 178, 0, 0.35);
  transition: transform var(--transition), box-shadow var(--transition);
}
.btn--quote:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(255, 178, 0, 0.5);
}
.btn--quote svg { flex: none; transition: transform var(--transition); }
.btn--quote:hover svg { transform: translateX(3px); }

/* WhatsApp floating button — clean circle, bottom-right on every page */
.wa-float {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 95;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #25d366;
  color: #fff;
  box-shadow: var(--shadow-lg);
  transition: transform var(--transition), box-shadow var(--transition);
}
.wa-float:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(37, 211, 102, 0.45); }
.wa-float svg { width: 30px; height: 30px; }
/* "Chat with us" tooltip slides in on the left; never distorts the circle */
.wa-float__label {
  position: absolute;
  right: calc(100% + 12px);
  top: 50%;
  transform: translateY(-50%);
  background: var(--color-ink);
  color: #fff;
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
  padding: 0.4rem 0.7rem;
  border-radius: var(--radius-sm);
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition);
}
.wa-float:hover .wa-float__label,
.wa-float:focus-visible .wa-float__label { opacity: 1; }

/* Email floating button — same circle language, sits left of WhatsApp */
.email-float {
  position: fixed;
  right: 5.5rem;
  bottom: 1.25rem;
  z-index: 95;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--color-primary);
  color: #fff;
  box-shadow: var(--shadow-lg);
  transition: transform var(--transition), box-shadow var(--transition);
}
.email-float:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(22, 104, 245, 0.45); }
.email-float svg { width: 26px; height: 26px; }
.email-float:hover .wa-float__label,
.email-float:focus-visible .wa-float__label { opacity: 1; }

/* Non-interactive chips (spec/system badges) */
.chip--static { cursor: default; }
.chip--static:hover { background: var(--color-primary-tint); color: var(--color-primary-dark); }

/* Multi-column checklist (key advantages) */
.prop-list--cols { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }

/* Description-only category note */
.category-note {
  color: var(--color-muted);
  background: var(--color-bg-alt);
  border: 1px dashed var(--color-line);
  border-radius: var(--radius);
  padding: var(--space-3);
}
.category-note a { color: var(--color-primary-dark); font-weight: var(--fw-semibold); }

/* Lift the scroll-to-top button above the WhatsApp float */
.to-top { bottom: 5.5rem; }

/* Minimal cookie notice — bottom-left, dismissible */
.cookie-notice {
  position: fixed;
  left: 1rem;
  bottom: 1rem;
  z-index: 94;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  max-width: min(340px, calc(100vw - 2rem));
  padding: 0.7rem 0.9rem;
  background: var(--color-bg-dark);
  color: rgba(255, 255, 255, 0.92);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  font-size: var(--fs-sm);
}
.cookie-notice[hidden] { display: none; }
.cookie-notice p { margin: 0; }
.cookie-notice button {
  flex: none;
  padding: 0.4rem 0.85rem;
  border: 0;
  border-radius: var(--radius-sm);
  background: var(--color-yellow);
  color: var(--color-ink);
  font-weight: var(--fw-bold);
  font-size: var(--fs-sm);
  cursor: pointer;
}
.cookie-notice button:hover { background: var(--color-yellow-hover); }

/* Reserve space for the captcha widget so layout doesn't jump */
.cf-captcha { min-height: 66px; }

/* Contact-form submit status message */
.form-status {
  margin-top: var(--space-2);
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
}
.form-status:empty { display: none; }
.form-status--ok {
  color: #0f7b3f;
  background: #e9f9ef;
  border-left: 3px solid #1aa95a;
  padding: 0.7rem 0.9rem;
  border-radius: 6px;
}
.form-status--error {
  color: #b42318;
  background: #fdeceb;
  border-left: 3px solid #d92d20;
  padding: 0.7rem 0.9rem;
  border-radius: 6px;
}

@media (max-width: 768px) {
  .brand__logo { height: 40px; }
}
/* Article body typography (article pages) */
.prose { max-width: var(--container-narrow); margin-inline: auto; }
.prose h2 { margin-top: var(--space-4); margin-bottom: var(--space-2); }
.prose h3 { margin-top: var(--space-3); margin-bottom: var(--space-1); }
.prose p { margin-bottom: var(--space-2); color: var(--color-body); }
.prose ul, .prose ol { padding-left: 1.4rem; margin-bottom: var(--space-2); }
.prose li { margin-bottom: 0.35rem; list-style: disc; color: var(--color-body); }
.prose ol li { list-style: decimal; }
.prose table { width: 100%; border-collapse: collapse; margin-block: var(--space-3); font-size: var(--fs-sm); }
.prose th, .prose td { border: 1px solid var(--color-line); padding: 0.6rem 0.8rem; text-align: left; vertical-align: top; }
.prose th { background: var(--color-bg-alt); }
.article-meta { color: var(--color-muted); font-size: var(--fs-sm); }

/* ---------------------------------------------------------------------------
   NAV DROPDOWN (Products → categories) — M12
   --------------------------------------------------------------------------- */
.nav__item { position: relative; }
.nav__item--has-children > .nav__link { display: inline-flex; align-items: center; gap: 0.25rem; }
.nav__caret { transition: transform var(--transition); }
.nav__item--has-children:hover .nav__caret,
.nav__item--has-children:focus-within .nav__caret { transform: rotate(180deg); }

.nav__dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 250px;
  background: #fff;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 0.4rem;
  display: grid;
  gap: 2px;
  list-style: none;
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity var(--transition), transform var(--transition), visibility var(--transition);
  z-index: 120;
}
.nav__item--has-children:hover .nav__dropdown,
.nav__item--has-children:focus-within .nav__dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.nav__dropdown-link {
  display: block;
  padding: 0.55rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--color-ink);
  white-space: nowrap;
}
.nav__dropdown-link:hover { background: var(--color-primary-tint); color: var(--color-primary-dark); }

/* Mobile: dropdown becomes a collapsed accordion inside the off-canvas menu —
   hidden until its .nav__subtoggle is tapped (JS toggles .is-open) */
@media (max-width: 900px) {
  .nav__dropdown {
    position: static;
    display: none;
    opacity: 1;
    visibility: visible;
    transform: none;
    min-width: 0;
    width: 100%;
    padding: 0.1rem 0 0.3rem 0.9rem;
    background: transparent;
    border: 0;
    box-shadow: none;
  }
  .nav__item.is-open > .nav__dropdown { display: grid; }
  .nav__item--has-children:hover .nav__dropdown:not(.is-open) { /* no hover-open on touch */ }
  .nav__dropdown-link { color: var(--color-ink); padding: 0.6rem 0.75rem; white-space: normal; }
  .nav__caret { display: none; }
}

/* ---------------------------------------------------------------------------
   MOBILE MENU ROBUSTNESS + iOS TAP FIX (M13)
   --------------------------------------------------------------------------- */
/* Keep header controls above the fixed header's backdrop-filter layer — iOS
   Safari can otherwise swallow taps on buttons inside a blurred fixed header. */
.brand,
.nav-toggle,
.header-utility { position: relative; z-index: 2; }

/* Dark scrim behind the open mobile menu */
.nav-backdrop {
  position: fixed;
  inset: 0;
  z-index: 96;
  background: rgba(9, 20, 43, 0.5);
  opacity: 0;
  transition: opacity var(--transition);
}
.nav-backdrop[hidden] { display: none; }
.nav-backdrop.is-open { opacity: 1; }

/* Lock body scroll while the menu is open */
body.nav-open { overflow: hidden; }

/* Close (×) button inside the mobile panel — hidden on desktop */
.nav__close {
  display: none;
  position: absolute;
  top: 0.6rem;
  right: 0.8rem;
  width: 40px;
  height: 40px;
  border: 0;
  background: transparent;
  color: var(--color-ink);
  cursor: pointer;
  border-radius: var(--radius-sm);
}

@media (max-width: 900px) {
  .nav { z-index: 110; }
  .nav__close { display: inline-grid; place-items: center; }
  .nav__list { margin-top: 2.25rem; }
}

