/* ==========================================================================
   British-American Coatings Design System  (light / corporate)
   Clean, photography-led look inspired by the global coatings leaders.
   Font: Open Sans (single family, weighted for hierarchy) via Google Fonts.
   ========================================================================== */

:root {
  /* --- Brand palette (light-first) --- */
  --paper:      #FFFFFF;   /* primary background */
  --mist:       #F4F6F8;   /* alternating light section */
  --cloud:      #E9EDF1;   /* subtle surface / placeholder */
  --line:       #DEE4EA;   /* hairline borders on light */

  --navy:       #14305B;   /* corporate anchor — matched to BAC logo navy */
  --navy-700:   #1D3F6E;   /* raised navy surface */
  --navy-600:   #27518A;   /* navy accents / links */
  --ink:        #152743;   /* primary text (deep navy) */
  --slate:      #5A6676;   /* secondary text */
  --slate-400:  #8793A2;   /* muted text */
  --on-navy:    #E7EDF4;   /* body text on navy */
  --on-navy-mut:#9FB0C4;   /* muted text on navy */
  --line-navy:  rgba(255,255,255,.14);

  --red:        #D2081B;   /* BAC vivid accent */
  --red-600:    #b00616;
  --red-050:    rgba(210,8,27,.08);

  /* --- Typography --- */
  --font-display: "Open Sans", Arial, Helvetica, sans-serif;
  --font-body: "Open Sans", Arial, Helvetica, sans-serif;

  --fs-display: clamp(2.75rem, 1.4rem + 5.2vw, 5.5rem);
  --fs-h1:      clamp(2.2rem, 1.4rem + 3.2vw, 3.6rem);
  --fs-h2:      clamp(1.85rem, 1.25rem + 2.2vw, 2.9rem);
  --fs-h3:      clamp(1.25rem, 1.05rem + .9vw, 1.6rem);
  --fs-lead:    clamp(1.08rem, 1rem + .45vw, 1.35rem);
  --fs-body:    1.05rem;
  --fs-small:   0.9rem;

  /* --- Layout --- */
  --container: 1340px;
  --container-wide: 1540px;
  --gutter: clamp(1.25rem, 4vw, 3.25rem);
  --section-y: clamp(4rem, 7vw, 7.5rem);
  --radius: 10px;
  --radius-lg: 16px;
  --btn-radius: 6px;
  --pill: 50px;

  --shadow-sm: 0 1px 3px rgba(22,35,59,.06), 0 6px 20px rgba(22,35,59,.06);
  --shadow-md: 0 10px 30px rgba(22,35,59,.10);
  --shadow-lg: 0 24px 60px rgba(22,35,59,.16);

  --ease: cubic-bezier(.22,.61,.36,1);
}

/* --------------------------------------------------------------- Reset */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.62;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg, video { display: block; max-width: 100%; height: auto; }
[hidden] { display: none !important; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; padding: 0; }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--red); outline-offset: 3px; border-radius: 4px; }

/* Skip-to-content link (injected by main.js) — visible on keyboard focus */
.skip-link { position: fixed; top: 0; left: 0; z-index: 200; transform: translateY(-120%); background: var(--navy); color: #fff; padding: .8rem 1.25rem; border-radius: 0 0 10px 0; font-family: var(--font-display); font-weight: 600; transition: transform .2s var(--ease); }
.skip-link:focus { transform: translateY(0); outline-offset: -3px; }

/* --------------------------------------------------------- Typography */
h1,h2,h3,h4 { font-family: var(--font-display); font-weight: 800; line-height: 1.1; letter-spacing: -.015em; color: var(--ink); }
h3 { line-height: 1.18; }
p { max-width: 66ch; }

.eyebrow {
  --stripe: var(--red);
  font-family: var(--font-display); font-weight: 700;
  font-size: .78rem; letter-spacing: .08em; text-transform: uppercase;
  color: var(--red); display: inline-flex; align-items: center; gap: .65rem;
}
/* BAC mark before each eyebrow (the site favicon) */
.eyebrow::before {
  content: ""; flex: none; width: 17px; height: 17px;
  background: url("../img/favicon.webp") no-repeat center / contain;
}
.on-navy .eyebrow, .eyebrow--onnavy, .section--navy .eyebrow { color: #ff5a67; --stripe: #ff5a67; }

/* ----------------------------------------------------------- Layout util */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.container--wide { max-width: var(--container-wide); }
.section { padding-block: var(--section-y); }
.section--mist { background: var(--mist); }
.section--navy { background: var(--navy); color: var(--on-navy); }
.section--navy h1,.section--navy h2,.section--navy h3,.section--navy h4 { color: #fff; }
.on-navy, .section--navy { }
.lead { font-size: var(--fs-lead); color: var(--slate); line-height: 1.55; }
.section--navy .lead { color: var(--on-navy-mut); }
.muted { color: var(--slate); }
.center { text-align: center; }
.sec-head { max-width: 680px; margin-bottom: clamp(2.25rem, 4vw, 3.5rem); }
.sec-head.center { margin-inline: auto; }
.sec-head h2 { margin-top: .9rem; }
.sec-head p { margin-top: 1rem; }
.sec-head.center p { margin-inline: auto; }

/* --------------------------------------------------------------- Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  padding: .95rem 1.7rem; border-radius: var(--btn-radius);
  font-family: var(--font-display); font-weight: 700; font-size: .98rem; line-height: 1;
  letter-spacing: .005em; border: 1.5px solid transparent; white-space: nowrap;
  transition: background .18s var(--ease), color .18s var(--ease), border-color .18s var(--ease), box-shadow .18s var(--ease), transform .18s var(--ease);
}
.btn svg { width: 1.1em; height: 1.1em; transition: transform .2s var(--ease); }
.btn:hover svg { transform: translateX(3px); }
.btn--primary { background: var(--red); color: #fff; }
.btn--primary:hover { background: var(--red-600); box-shadow: 0 6px 18px rgba(176,6,22,.28); transform: translateY(-1px); }
.btn--navy { background: var(--navy); color: #fff; }
.btn--navy:hover { background: var(--navy-700); box-shadow: 0 6px 18px rgba(20,48,91,.26); transform: translateY(-1px); }
.btn--outline { background: transparent; border-color: #c7d0d9; color: var(--ink); }
.btn--outline:hover { border-color: var(--navy); background: var(--navy); color: #fff; }
.btn--ghost { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.5); color: #fff; backdrop-filter: blur(2px); }
.btn--ghost:hover { background: rgba(255,255,255,.18); border-color: #fff; }
.btn--lg { padding: 1.1rem 2.1rem; font-size: 1.05rem; }

.link-arrow {
  display: inline-flex; align-items: center; gap: .45rem;
  font-family: var(--font-display); font-weight: 600; color: var(--red);
}
.link-arrow svg { width: 1.05em; height: 1.05em; transition: transform .2s var(--ease); }
.link-arrow:hover svg { transform: translateX(4px); }
.section--navy .link-arrow { color: #ff6b77; }

/* ---------------------------------------------------- Utility top bar */
.util-bar { background: var(--navy); color: var(--on-navy-mut); font-size: .83rem; }
.util-bar__inner { display: flex; justify-content: flex-end; align-items: center; gap: 1.5rem; min-height: 40px; }
.util-bar a { color: var(--on-navy-mut); transition: color .2s; display: inline-flex; align-items: center; gap: .4rem; }
.util-bar a:hover { color: #fff; }
.util-bar svg { width: 15px; height: 15px; }
@media (max-width: 680px) { .util-bar { display: none; } }

/* ----------------------------------------------------------- Header */
.site-header { position: sticky; top: 0; z-index: 100; background: rgba(255,255,255,.92); backdrop-filter: saturate(140%) blur(12px); border-bottom: 1px solid var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 2rem; min-height: 78px; }
.brand { display: inline-flex; align-items: center; gap: .75rem; }
.brand__mark { width: 42px; height: 42px; flex: none; }
.brand__logo { height: 42px; width: auto; display: block; }
.site-header .brand__logo { height: 40px; }
@media (max-width: 420px){ .site-header .brand__logo { height: 34px; } }
.brand__name { font-family: var(--font-display); font-weight: 700; font-size: 1.08rem; line-height: 1.05; letter-spacing: -.01em; color: var(--ink); }
.brand__name small { display: block; font-size: .6rem; font-weight: 500; letter-spacing: .2em; color: var(--slate-400); text-transform: uppercase; font-family: var(--font-body); margin-top: 2px; }

.nav__links { display: flex; align-items: center; gap: .15rem; }
.nav__links a { padding: .55rem .9rem; border-radius: 8px; font-weight: 500; font-size: .98rem; color: var(--ink); transition: color .2s, background .2s; }
.nav__links a:hover, .nav__links a[aria-current="page"] { color: var(--red); background: var(--red-050); }
.nav__cta { margin-left: .6rem; }
.nav__toggle { display: none; background: none; border: 0; color: var(--ink); padding: .5rem; min-width: 44px; min-height: 44px; align-items: center; justify-content: center; }
.nav__toggle svg { width: 28px; height: 28px; }

@media (max-width: 960px) {
  .nav__toggle { display: inline-flex; }
  .nav__links {
    position: fixed; inset: 118px 0 auto 0; flex-direction: column; align-items: stretch; gap: .2rem;
    background: var(--paper); border-bottom: 1px solid var(--line); box-shadow: var(--shadow-md);
    padding: 1rem var(--gutter) 1.5rem; transform: translateY(-130%); transition: transform .35s var(--ease);
  }
  .nav__links.is-open { transform: translateY(0); }
  .nav__links a { padding: .95rem 1rem; }
  .nav__cta { margin: .6rem 0 0; justify-content: center; }
}
/* Below 680px the util-bar is hidden, so the header is shorter —
   anchor the mobile menu directly under the 78px header. */
@media (max-width: 680px) {
  .nav__links { inset: 78px 0 auto 0; }
}

/* ------------------------------------------------------------- Hero */
.hero { position: relative; color: #fff; overflow: hidden; background: var(--navy); isolation: isolate; }
.hero__bg { position: absolute; inset: 0; z-index: -2; }
.hero__bg img { width: 100%; height: 100%; object-fit: cover; }
/* professional fallback: layered navy gradient + subtle grid */
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -2;
  background:
    radial-gradient(120% 90% at 78% 10%, rgba(39,81,138,.9), transparent 55%),
    radial-gradient(90% 80% at 10% 90%, rgba(210,8,27,.26), transparent 55%),
    linear-gradient(160deg, #0f2448 0%, #14305b 55%, #0d203f 100%);
}
.hero__overlay { position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(10,26,48,.9) 0%, rgba(10,26,48,.68) 45%, rgba(10,26,48,.35) 100%); }
.hero__inner { position: relative; padding-block: clamp(5rem, 11vw, 10rem); max-width: 940px; }
.hero h1 { font-size: var(--fs-display); color: #fff; margin-top: 1.2rem; }
.hero .lead { margin-top: 1.5rem; max-width: 56ch; color: #cfdae8; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 2.4rem; }
.hero__scrim-line { position: absolute; left: 0; right: 0; bottom: 0; height: 5px; background: linear-gradient(90deg, var(--red) 0%, var(--red) 28%, transparent 28%); z-index: 0; }

/* page (sub) hero */
.page-hero { position: relative; background: var(--navy); color: #fff; overflow: hidden; isolation: isolate; }
.page-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(100% 120% at 85% 0%, rgba(39,81,138,.8), transparent 60%), linear-gradient(160deg, #0f2448, #14305b); }
.page-hero__inner { padding-block: clamp(3.25rem, 7vw, 6rem) clamp(2.75rem, 5vw, 4.5rem); }
.page-hero h1 { color: #fff; margin-top: .9rem; font-size: var(--fs-h1); max-width: 20ch; }
.page-hero .lead { margin-top: 1.1rem; max-width: 56ch; color: #cfdae8; }
.crumbs { font-size: .85rem; color: var(--on-navy-mut); display: flex; gap: .5rem; align-items: center; }
.crumbs a:hover { color: #fff; }
.crumbs span { opacity: .5; }

/* ------------------------------------------------------- Grid helpers */
.grid { display: grid; gap: clamp(1.25rem, 2.5vw, 1.9rem); }
.grid--2 { grid-template-columns: repeat(2,1fr); }
.grid--3 { grid-template-columns: repeat(3,1fr); }
.grid--4 { grid-template-columns: repeat(4,1fr); }
@media (max-width: 960px){ .grid--4{grid-template-columns:repeat(2,1fr);} .grid--3{grid-template-columns:repeat(2,1fr);} }
@media (max-width: 680px){ .grid--2,.grid--3,.grid--4{grid-template-columns:1fr;} }

/* ------------------------------------------------- Market / segment card */
.mcard { position: relative; border-radius: var(--radius-lg); overflow: hidden; background: var(--cloud); min-height: 320px; display: flex; flex-direction: column; justify-content: flex-end; color: #fff; isolation: isolate; box-shadow: var(--shadow-sm); transition: transform .3s var(--ease), box-shadow .3s var(--ease); }
.mcard:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.mcard__media { position: absolute; inset: 0; z-index: -2; }
.mcard__media img { width: 100%; height: 100%; object-fit: cover; }
.mcard::before { content: ""; position: absolute; inset: 0; z-index: -2; background: linear-gradient(155deg, var(--navy-600), var(--navy)); }
.mcard::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(14,36,64,0) 30%, rgba(10,24,44,.9) 100%); }
.mcard__body { padding: clamp(1.4rem, 2.2vw, 1.9rem); }
.mcard h3 { color: #fff; font-size: var(--fs-h3); }
.mcard p { color: rgba(255,255,255,.82); margin-top: .5rem; font-size: 1rem; }
.mcard .link-arrow { margin-top: 1rem; color: #fff; }
.mcard .link-arrow:hover { color: #ff8a93; }

/* ------------------------------------------------------- Brand card (big) */
.brands { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.25rem,2.5vw,1.9rem); }
@media (max-width: 820px){ .brands { grid-template-columns: 1fr; } }
.bcard { border: 1px solid var(--line); border-top: 3px solid var(--red); border-radius: var(--radius-lg); overflow: hidden; background: var(--paper); display: flex; flex-direction: column; box-shadow: var(--shadow-md); transition: transform .3s var(--ease), box-shadow .3s var(--ease); }
.bcard:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.bcard__top { position: relative; aspect-ratio: 16/7; background: var(--mist); border-bottom: 1px solid var(--line); overflow: hidden; display: grid; place-items: center; padding: clamp(1.25rem, 3vw, 2.25rem); }
.bcard__logo { position: relative; z-index: 1; max-height: 64px; width: auto; max-width: 80%; }
.bcard__top img.bcard__photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; padding: 0; max-width: none; }
.bcard__badge { position: relative; z-index: 1; font-family: var(--font-display); font-weight: 700; font-size: 1.7rem; color: var(--navy); letter-spacing: .02em; }
.bcard__badge .a-red { color: var(--red); }
.bcard__badge .a-blue { color: var(--navy-600); }
.bcard__body { padding: clamp(1.5rem, 2.5vw, 2.1rem); display: flex; flex-direction: column; flex: 1; }
.bcard__body h3 { font-size: var(--fs-h3); }
.bcard__body p { margin-top: .75rem; color: var(--slate); flex: 1; }
.bcard__body .btn { margin-top: 1.6rem; align-self: flex-start; }

/* --------------------------------------------------------- Feature split */
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem,5vw,4.5rem); align-items: center; }
.feature--rev .feature__media { order: -1; }
@media (max-width: 860px){ .feature { grid-template-columns: 1fr; } .feature--rev .feature__media { order: 0; } }
.feature h2 { margin-top: .9rem; }
.feature p { margin-top: 1.15rem; }
.feature__list { margin-top: 1.5rem; display: grid; gap: .85rem; }
.feature__list li { display: flex; gap: .7rem; align-items: flex-start; color: var(--slate); }
.feature__list svg { width: 22px; height: 22px; flex: none; color: var(--red); margin-top: 2px; }
.feature__media { border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 4/3; background: linear-gradient(135deg, var(--navy-700), var(--navy)); box-shadow: var(--shadow-md); }
.feature__media img { width: 100%; height: 100%; object-fit: cover; }
.feature__media--product { background: var(--mist); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.feature__media--product img { object-fit: contain; padding: clamp(1.5rem, 4vw, 3rem); }
.feature__actions { margin-top: 1.9rem; display:flex; gap:.9rem; flex-wrap:wrap; }

/* --------------------------------------------------------------- Pillars */
.pillar { padding: 1.75rem; border-radius: var(--radius); background: var(--paper); border: 1px solid var(--line); box-shadow: none; height: 100%; }
.section--navy .pillar { background: var(--navy-700); border-color: var(--line-navy); }
.pillar__icon { width: 50px; height: 50px; border-radius: 12px; display: grid; place-items: center; background: var(--red-050); color: var(--red); margin-bottom: 1.1rem; }
.section--navy .pillar__icon { background: rgba(255,90,103,.14); color: #ff6b77; }
.pillar__icon svg { width: 26px; height: 26px; }
.pillar h3 { font-size: 1.22rem; }
.section--navy .pillar h3 { color: #fff; }
.pillar p { margin-top: .55rem; color: var(--slate); font-size: 1rem; }
.section--navy .pillar p { color: var(--on-navy-mut); }

/* ------------------------------------------------------------ Stat strip */
.stats { display: grid; grid-template-columns: repeat(4,1fr); gap: 2rem; }
@media (max-width: 820px){ .stats { grid-template-columns: repeat(2,1fr); gap: 2.5rem; } }
.stat { text-align: center; }
.stat__num { font-family: var(--font-display); font-weight: 700; font-size: clamp(2.3rem,4vw,3.2rem); color: #fff; line-height: 1; }
.section:not(.section--navy) .stat__num { color: var(--navy); }
.stat__num .u { color: var(--red); }
.stat__label { margin-top: .55rem; color: var(--on-navy-mut); font-size: .98rem; }
.section:not(.section--navy) .stat__label { color: var(--slate); }

/* ------------------------------------------------------------ Logo strip */
.logos { display:flex; flex-wrap:wrap; align-items:center; justify-content:center; gap:clamp(1.5rem,4vw,3.5rem); opacity:.7; }
.logos span { font-family: var(--font-display); font-weight:700; color: var(--slate-400); font-size:1.1rem; letter-spacing:.02em; }

/* ---------------------------------------------------------------- Quote */
.quote { max-width: 860px; margin-inline: auto; text-align: center; }
.quote blockquote { font-family: var(--font-display); font-weight: 500; font-size: clamp(1.4rem,2.5vw,2rem); line-height: 1.3; letter-spacing:-.01em; }
.section--navy .quote blockquote { color: #fff; }
.quote cite { display: block; margin-top: 1.5rem; font-style: normal; color: var(--slate); font-size: 1rem; }
.section--navy .quote cite { color: var(--on-navy-mut); }
.quote__mark { color: var(--red); font-size: 3rem; line-height: 1; font-family: var(--font-display); }

/* ---------------------------------------------------------------- CTA band */
.cta-band { background: var(--red); color: #fff; border-radius: var(--radius-lg); padding: clamp(2.5rem,5vw,4.25rem); text-align: center; box-shadow: var(--shadow-md); }
.cta-band h2 { color: #fff; font-size: var(--fs-h2); }
.cta-band p { margin: 1rem auto 2rem; color: rgba(255,255,255,.92); }
.cta-band .btn--primary { background: #fff; color: var(--red); box-shadow:none; }
.cta-band .btn--primary:hover { background: var(--navy); color: #fff; }

/* ----------------------------------------------------------------- Footer */
.site-footer { background: var(--navy); color: var(--on-navy-mut); padding-block: clamp(3.5rem,6vw,5rem) 2rem; }
.footer-grid { display: grid; grid-template-columns: 1.7fr 1fr 1fr 1fr; gap: 2.5rem; }
@media (max-width: 820px){ .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px){ .footer-grid { grid-template-columns: 1fr; } }
.site-footer .brand__name { color: #fff; }
.site-footer .brand__logo { height: 40px; background: #fff; padding: 8px 12px; border-radius: 9px; box-shadow: var(--shadow-sm); }
.site-footer h4 { font-family: var(--font-display); color: #fff; font-size: .92rem; letter-spacing: .04em; margin-bottom: 1rem; }
.site-footer a { color: var(--on-navy-mut); font-size: .96rem; line-height: 2.05; transition: color .2s; }
.site-footer a:hover { color: #fff; }
.footer-about p { margin-top: 1rem; max-width: 36ch; font-size: .96rem; }
.footer-bottom { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--line-navy); display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; align-items: center; font-size: .86rem; }
.footer-bottom nav { display: flex; gap: 1.5rem; }

/* Scroll reveal disabled — content is shown immediately, no fade-in on scroll. */

/* ------------------------------------------------------------- Prose (legal) */
.prose { max-width: 760px; }
.prose h2 { font-size: var(--fs-h3); margin-top: 2.5rem; }
.prose h3 { font-size: 1.2rem; margin-top: 1.75rem; }
.prose p, .prose li { color: var(--slate); margin-top: 1rem; }
.prose ul { list-style: disc; padding-left: 1.3rem; }
.prose li { margin-top: .5rem; }
.prose a { color: var(--red); text-decoration: underline; }

/* ---------------------------------------------------------------- Contact */
.contact-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(2rem,5vw,4rem); align-items: start; }
@media (max-width: 860px){ .contact-grid { grid-template-columns: 1fr; } }
.card-panel { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(1.75rem,3vw,2.5rem); box-shadow: var(--shadow-sm); }
.field { margin-bottom: 1.1rem; }
.field label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: .4rem; font-family: var(--font-display); }
.field input, .field textarea, .field select { width: 100%; padding: .85rem 1rem; border: 1px solid var(--line); border-radius: 10px; font: inherit; background: var(--paper); color: var(--ink); transition: border-color .2s, box-shadow .2s; }
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--red); box-shadow: 0 0 0 3px var(--red-050); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 520px){ .field-row { grid-template-columns: 1fr; } }
.contact-detail { display: flex; gap: 1rem; align-items: flex-start; margin-bottom: 1.6rem; }
.contact-detail__icon { width: 46px; height: 46px; flex: none; border-radius: 12px; display: grid; place-items: center; background: var(--red-050); color: var(--red); }
.contact-detail h4 { font-family: var(--font-display); font-size: 1.02rem; }
.contact-detail a, .contact-detail span { color: var(--slate); }
.contact-detail a:hover { color: var(--red); }

/* small helpers */
.stack-sm > * + * { margin-top: .75rem; }
.mt-cta { margin-top: clamp(2.5rem,5vw,4rem); }

/* ---------------------------------------------------------- Form alerts */
.form-alert { display: flex; gap: .7rem; align-items: flex-start; padding: .9rem 1.1rem; border-radius: 10px; margin-bottom: 1.25rem; font-size: .96rem; }
.form-alert svg { width: 22px; height: 22px; flex: none; margin-top: 1px; }
.form-alert--ok { background: #e7f6ec; color: #136c34; border: 1px solid #b7e2c4; }
.form-alert--err { background: #fdeced; color: #a21420; border: 1px solid #f3c2c6; }
.form-alert a { color: inherit; text-decoration: underline; }

/* ------------------------------------------------ "Find the product" band */
.promo-band { background: var(--mist); border-radius: var(--radius-lg); overflow: hidden; display: grid; grid-template-columns: 1fr 1fr; align-items: center; border: 1px solid var(--line); }
@media (max-width: 760px){ .promo-band { grid-template-columns: 1fr; } }
.promo-band__media { background: var(--paper); aspect-ratio: 16/10; display: grid; place-items: center; padding: clamp(1.5rem,4vw,3rem); }
.promo-band__media img { max-height: 280px; width: auto; object-fit: contain; }
.promo-band__body { padding: clamp(2rem,4vw,3.5rem); }
.promo-band__body h2 { font-size: var(--fs-h2); }
.promo-band__body p { margin-top: .9rem; color: var(--slate); }
.promo-band__body .btn { margin-top: 1.75rem; }

/* ------------------------------------------------------- Vessel segments */
.seg-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: clamp(1rem,2vw,1.5rem); }
@media (max-width: 900px){ .seg-grid { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 520px){ .seg-grid { grid-template-columns: 1fr; } }
.seg { position: relative; border-radius: var(--radius); overflow: hidden; min-height: 240px; display: flex; flex-direction: column; justify-content: flex-end; color: #fff; padding: 1.4rem; isolation: isolate; box-shadow: var(--shadow-sm); transition: transform .3s var(--ease); }
.seg:hover { transform: translateY(-4px); }
.seg::before { content:""; position:absolute; inset:0; z-index:-2; background: linear-gradient(155deg, var(--navy-600), var(--navy)); }
.seg__media { position:absolute; inset:0; z-index:-2; }
.seg__media img { width:100%; height:100%; object-fit:cover; }
.seg::after { content:""; position:absolute; inset:0; z-index:-1; background: linear-gradient(180deg, rgba(15,36,72,0) 35%, rgba(10,24,44,.88) 100%); }
.seg h3 { color:#fff; font-size: 1.25rem; }
.seg__link { margin-top:.5rem; font-family:var(--font-display); font-weight:600; color:#ff8a93; display:inline-flex; align-items:center; gap:.4rem; }

/* ------------------------------------------------------- Product listing */
.filter-bar { display: flex; flex-wrap: nowrap; gap: .5rem; align-items: center; margin-bottom: 1.5rem; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; padding-bottom: 2px; }
.filter-bar::-webkit-scrollbar { display: none; }
.chip { flex: 0 0 auto; display: inline-flex; align-items: center; gap: .4rem; padding: .6rem 1rem; border-radius: var(--btn-radius); border: 1.5px solid var(--line); background: var(--paper); color: var(--ink); font-family: var(--font-display); font-weight: 600; font-size: .9rem; white-space: nowrap; cursor: pointer; transition: border-color .18s var(--ease), color .18s var(--ease), background .18s var(--ease); min-height: 44px; }
.chip:hover { border-color: var(--navy-600); color: var(--navy-600); }
.chip[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: #fff; }
.chip__count { font-size: .78rem; opacity: .7; }
.result-count { color: var(--slate); font-size: .95rem; margin-bottom: 1.5rem; }

.product-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: clamp(1rem,2vw,1.5rem); }
@media (max-width: 920px){ .product-grid { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 560px){ .product-grid { grid-template-columns: 1fr; } }
.pcard { display: flex; flex-direction: column; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; box-shadow: var(--shadow-sm); transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s var(--ease); }
.pcard:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--cloud); }
.pcard__tag { align-self: flex-start; font-family: var(--font-display); font-weight: 700; font-size: .68rem; letter-spacing: .1em; text-transform: uppercase; color: var(--red); background: var(--red-050); padding: .35rem .7rem; border-radius: 6px; }
.pcard h3 { font-size: 1.3rem; margin-top: 1rem; }
.pcard__desc { margin-top: .6rem; color: var(--slate); font-size: .98rem; }
.pcard__feats { margin-top: 1rem; display: grid; gap: .5rem; }
.pcard__feats li { display: flex; gap: .55rem; align-items: flex-start; font-size: .92rem; color: var(--ink); }
.pcard__feats svg { width: 18px; height: 18px; flex: none; color: var(--navy-600); margin-top: 2px; }
.pcard__foot { margin-top: auto; padding-top: 1.25rem; }
.pcard__foot .link-arrow { font-size: .95rem; }
.pcard.is-hidden { display: none; }
.no-results { padding: 3rem 1rem; text-align: center; color: var(--slate); }

/* datasheet request button (replaces the old link) */
.pcard__req { background: none; border: 0; padding: 0; cursor: pointer; }

/* ---------------------------------------------------- Datasheet modal */
.modal { position: fixed; inset: 0; margin: auto; border: 0; padding: 0; width: min(540px, calc(100% - 2rem)); max-height: calc(100dvh - 2rem); border-radius: 14px; overflow: hidden; color: var(--ink); box-shadow: var(--shadow-lg); }
/* Only lay out as flex when actually open — otherwise the UA rule
   dialog:not([open]){display:none} must win so it stays hidden. */
.modal[open] { display: flex; flex-direction: column; }
.modal::backdrop { background: rgba(10,24,44,.6); backdrop-filter: blur(2px); }
.modal[open] { animation: modal-in .22s var(--ease); }
@keyframes modal-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.modal__head { background: var(--navy); color: #fff; padding: 1.5rem 1.6rem; display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; flex: none; }
.modal__head .eyebrow { color: #ff8a93; --stripe: #ff8a93; }
.modal__head h3 { color: #fff; font-size: 1.35rem; margin-top: .5rem; }
.modal__close { flex: none; background: rgba(255,255,255,.14); border: 0; color: #fff; width: 38px; height: 38px; border-radius: 8px; display: grid; place-items: center; cursor: pointer; transition: background .18s var(--ease); }
.modal__close:hover { background: rgba(255,255,255,.26); }
.modal__close svg { width: 20px; height: 20px; }
.modal__body { padding: 1.6rem; overflow-y: auto; }
.modal__body .btn { width: 100%; margin-top: .25rem; }

/* ====================================================================
   Interaction polish: press feedback, interactive-card hover,
   backdrop fade, and touch + reduced-motion safety.
   ==================================================================== */

/* No blue tap flash on mobile (paired with the :active states below) */
* { -webkit-tap-highlight-color: transparent; }

/* Press feedback: buttons and controls respond to the press */
.btn:active,
.btn--primary:active, .btn--navy:active, .btn--outline:active, .btn--ghost:active { transform: scale(.97); box-shadow: none; }
.chip:active { transform: scale(.97); }
.pcard__req:active, .link-arrow:active { transform: scale(.97); }
.modal__close:active { transform: scale(.94); }

/* Clickable range cards get a hover state; static capability pillars stay flat */
a.pillar { transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease); }
a.pillar:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--navy-600); }
a.pillar:hover .link-arrow svg { transform: translateX(4px); }
a.pillar:active { transform: translateY(-1px); }

/* Datasheet modal backdrop fades in */
.modal[open]::backdrop { animation: backdrop-in .2s ease; }
@keyframes backdrop-in { from { opacity: 0; } to { opacity: 1; } }

/* Touch devices: no sticky hover lift after a tap */
@media (hover: none) {
  .btn:hover, .bcard:hover, .pcard:hover, a.pillar:hover { transform: none; box-shadow: var(--shadow-sm); }
  .btn--primary:hover, .btn--navy:hover { box-shadow: none; }
}

/* Respect reduced motion: keep color/opacity, drop movement */
@media (prefers-reduced-motion: reduce) {
  .btn:hover, .btn:active, .btn--primary:active, .btn--navy:active, .btn--outline:active, .btn--ghost:active,
  .bcard:hover, .pcard:hover, a.pillar:hover, a.pillar:active,
  .chip:active, .pcard__req:active, .link-arrow:active, .modal__close:active { transform: none; }
  .btn:hover svg, .link-arrow:hover svg, a.pillar:hover .link-arrow svg { transform: none; }
  .modal[open], .modal[open]::backdrop { animation: none; }
}

/* Mobile: fade the right edge of the one-line filter to hint it scrolls */
@media (max-width: 760px) {
  .filter-bar { -webkit-mask-image: linear-gradient(90deg, #000 86%, transparent); mask-image: linear-gradient(90deg, #000 86%, transparent); }
}
