/* SAFFINS — uPVC duct covering fins
   Concrete, graphite and logo gold. One family (Archivo): expanded for headings, normal for text. */

@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 400 700;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url("../fonts/archivo-variable-latin.woff2") format("woff2");
}
@font-face {
  font-family: "Roboto Slab";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/roboto-slab-700-latin.woff2") format("woff2");
}

:root {
  --concrete: #ecedea;
  --white: #ffffff;
  --graphite: #2b2e33;
  --graphite-2: #3a3e44;
  --steel: #62676e;
  --steel-light: #a7abb1;
  --rule: #d5d7d3;
  --gold: #e0a40a;
  --gold-hover: #f0b625;
  --gold-text: #7d5a00;
  --header-bg: #f5e7c6;
  --header-rule: #e5d0a2;

  --font: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --font-slab: "Roboto Slab", Georgia, serif;

  /* 1.25 scale on a 17px body */
  --step--1: 0.8125rem;
  --step-0: 1.0625rem;
  --step-1: 1.3125rem;
  --step-3: clamp(1.75rem, 3vw, 2.125rem);
  --step-4: clamp(2.1rem, 4vw, 2.75rem);
  --step-5: clamp(2.4rem, 5vw, 3.5rem);

  --wrap: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  --header-h: 88px;
  --mm: 0.86px; /* hero plate scale: 1 mm of profile */
}

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--concrete);
  color: var(--graphite);
  font-family: var(--font);
  font-size: var(--step-0);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
p { margin: 0 0 1em; }
p, li, dd { max-width: 66ch; }

h1, h2, h3 {
  font-family: var(--font);
  font-stretch: 125%;
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.015em;
  margin: 0 0 0.6em;
  text-wrap: balance;
}
h1 { font-size: var(--step-5); line-height: 1.04; }
h2 { font-size: var(--step-4); }
h3 { font-size: var(--step-1); font-stretch: 112%; font-weight: 650; letter-spacing: -0.005em; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--gold); color: var(--graphite); padding: 10px 16px; font-weight: 700;
}
.skip-link:focus { top: 12px; }

:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

.lead { font-size: var(--step-1); line-height: 1.55; color: var(--graphite-2); }
.muted { color: var(--steel); }
.mb-0 { margin-bottom: 0; }

/* ---------- Buttons & links ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 24px; border-radius: 2px;
  font-family: var(--font); font-size: 1rem; font-weight: 650;
  text-decoration: none; border: 2px solid transparent; cursor: pointer;
  transition: background-color 0.15s, color 0.15s, border-color 0.15s;
}
.btn svg { width: 20px; height: 20px; flex: none; }
.btn-gold { background: var(--gold); color: var(--graphite); }
.btn-gold:hover { background: var(--gold-hover); }
.btn-dark { background: var(--graphite); color: var(--white); }
.btn-dark:hover { background: var(--graphite-2); }
.btn-line { border-color: var(--graphite); color: var(--graphite); }
.btn-line:hover { background: var(--graphite); color: var(--white); }

.text-link {
  font-weight: 650; color: var(--gold-text);
  text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 5px;
}
.text-link:hover { color: var(--graphite); }
.on-dark .text-link { color: var(--gold); }
.on-dark .text-link:hover { color: var(--white); }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--header-bg); border-bottom: 1px solid var(--header-rule); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); gap: 24px; }
.brand img { width: 240px; height: auto; }

.nav-list { display: flex; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav-list li { max-width: none; }
.nav-list a { display: block; padding: 10px 14px; font-size: 0.97rem; font-weight: 550; text-decoration: none; color: var(--graphite-2); }
.nav-list a:hover { color: var(--gold-text); }
.nav-list a[aria-current="page"] { color: var(--graphite); font-weight: 700; box-shadow: inset 0 -3px 0 var(--gold); }
.nav-cta { margin-left: 12px; }
.nav-list .nav-cta a.btn { display: inline-flex; min-height: 44px; padding: 0 18px; color: var(--white); font-weight: 650; }
.nav-list .nav-cta a.btn:hover { color: var(--white); }

.nav-toggle { display: none; width: 46px; height: 46px; border: 0; background: transparent; cursor: pointer; padding: 11px; }
.nav-toggle span { display: block; height: 2px; background: var(--graphite); margin: 5px 0; transition: transform 0.2s, opacity 0.2s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 880px) {
  .nav-toggle { display: block; }
  .site-nav {
    position: fixed; inset: var(--header-h) 0 auto 0;
    background: var(--header-bg); border-bottom: 1px solid var(--header-rule);
    padding: 8px var(--gutter) 24px; display: none;
  }
  .site-nav.is-open { display: block; }
  .nav-list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-list a { padding: 14px 0; font-size: 1.1rem; border-bottom: 1px solid var(--header-rule); }
  .nav-list a[aria-current="page"] { box-shadow: inset 4px 0 0 var(--gold); padding-left: 14px; }
  .nav-cta { margin: 18px 0 0; }
  .nav-list .nav-cta a.btn { width: 100%; border-bottom: 0; }
  :root { --header-h: 72px; }
  .brand img { width: 184px; }
}

/* ---------- Sections ---------- */
.section { padding: clamp(64px, 9vw, 112px) 0; }
.section-white { background: var(--white); }
.on-dark { background: var(--graphite); color: #d6d8db; }
.on-dark h1, .on-dark h2, .on-dark h3 { color: var(--white); }
.on-dark .lead { color: #d6d8db; }
.on-dark .muted { color: var(--steel-light); }

.section-head { margin-bottom: clamp(32px, 5vw, 52px); max-width: 760px; }
.section-head p { color: var(--steel); }
.on-dark .section-head p { color: var(--steel-light); }
.section-head-row { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 20px 40px; margin-bottom: clamp(32px, 5vw, 52px); }
.section-head-row .section-head { margin-bottom: 0; }

/* ---------- Home hero ---------- */
.hero { background: var(--white); border-bottom: 1px solid var(--rule); }
.hero-inner {
  display: grid; grid-template-columns: minmax(260px, 0.72fr) 1.28fr; gap: clamp(28px, 5vw, 72px);
  padding-top: clamp(28px, 4vw, 48px); padding-bottom: clamp(28px, 4vw, 48px);
}
.hero-photo { margin: 0; }
.hero-photo img { width: 100%; height: 100%; max-height: 680px; object-fit: cover; }
.hero-copy { display: flex; flex-direction: column; justify-content: center; padding: clamp(8px, 3vw, 32px) 0; }
.hero-copy .lead { margin-bottom: 26px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

.plate { margin-top: clamp(32px, 4vw, 44px); padding-top: 22px; border-top: 1px solid var(--rule); }
.plate-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-items: flex-end; gap: 22px 12px; }
.plate-list li { display: flex; flex-direction: column; align-items: center; gap: 8px; max-width: none; }
.plate-list svg { width: calc(var(--w) * var(--mm)); height: auto; overflow: visible; }
.plate-list svg * { fill: none; stroke: var(--graphite); stroke-width: 3.5; stroke-linejoin: miter; }
.plate-list svg .thick { stroke-width: 6; }
.plate-list span { font-size: var(--step--1); color: var(--steel); font-variant-numeric: tabular-nums; white-space: nowrap; }
.plate-note { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px 24px; margin-top: 22px; font-size: 0.94rem; color: var(--steel); }
.plate-note p { margin: 0; }

/* The one orchestrated motion: the profiles draw themselves on load */
@media (prefers-reduced-motion: no-preference) {
  .plate-list svg * { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 0.9s cubic-bezier(0.55, 0, 0.25, 1) forwards; animation-delay: calc(0.3s + var(--i) * 0.07s); }
  .plate-list span { opacity: 0; animation: label-in 0.4s ease forwards; animation-delay: calc(0.85s + var(--i) * 0.07s); }
}
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes label-in { to { opacity: 1; } }

@media (max-width: 900px) {
  :root { --mm: 0.82px; }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-photo { order: 2; }
  .hero-photo img { aspect-ratio: 16 / 10; max-height: 420px; }
}
@media (max-width: 480px) {
  :root { --mm: 0.6px; }
  .plate-list { gap: 16px 12px; }
}

/* ---------- Inner page header ---------- */
.page-hero { background: var(--white); border-bottom: 1px solid var(--rule); }
.page-hero .wrap { padding-top: clamp(40px, 7vw, 88px); padding-bottom: clamp(40px, 6vw, 72px); }
.page-hero h1 { max-width: 16em; }
.page-hero .lead { margin: 0; }
.crumbs { font-size: 0.92rem; margin-bottom: 22px; color: var(--steel); }
.crumbs a { color: var(--steel); }
.crumbs a:hover { color: var(--gold-text); }

/* ---------- Split ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 88px); align-items: center; }
.split-media img { width: 100%; }
.split-media.tall img { aspect-ratio: 4 / 5; object-fit: cover; }
@media (max-width: 880px) {
  .split { grid-template-columns: 1fr; }
  .split-media.tall img { aspect-ratio: 4 / 3; }
}

/* ---------- Reason list (Why SAFFINS) ---------- */
.reasons { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 clamp(32px, 5vw, 72px); margin: 0; }
.reasons div { padding: 26px 0 24px; border-top: 1px solid var(--rule); }
.reasons dt { font-stretch: 112%; font-size: var(--step-1); font-weight: 650; margin-bottom: 8px; }
.reasons dd { margin: 0; color: var(--steel); }
.on-dark .reasons div { border-color: var(--graphite-2); }
.on-dark .reasons dd { color: var(--steel-light); }
@media (max-width: 760px) { .reasons { grid-template-columns: 1fr; } }

/* ---------- Profile catalogue (products) ---------- */
.profile-group + .profile-group { margin-top: 56px; }
.profile-group h3 { margin-bottom: 4px; }
.profile-group > p { color: var(--steel); margin-bottom: 20px; }
.profiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; list-style: none; margin: 0; padding: 0; }
.profile { background: var(--white); border: 1px solid var(--rule); padding: 18px 18px 14px; max-width: none; }
.profile svg { width: 100%; height: auto; aspect-ratio: 170 / 90; color: var(--graphite); }
.profile svg .dim { stroke: var(--steel-light); stroke-width: 0.6; fill: none; }
.profile-size { display: flex; flex-direction: column; gap: 2px; margin-top: 10px; }
.profile-size strong { white-space: nowrap; font-stretch: 112%; font-size: var(--step-1); font-weight: 650; font-variant-numeric: tabular-nums; }
.profile-size span { font-size: var(--step--1); color: var(--steel); }
.note { font-size: 0.94rem; color: var(--steel); margin-top: 24px; }

/* ---------- Lists ---------- */
.tick-list { list-style: none; margin: 0; padding: 0; columns: 2 300px; column-gap: clamp(32px, 5vw, 72px); }
.tick-list li { break-inside: avoid; position: relative; padding: 14px 0 14px 26px; border-top: 1px solid var(--rule); }
.tick-list li::before { content: ""; position: absolute; left: 0; top: 23px; width: 10px; height: 10px; background: var(--gold); }

.app-list { list-style: none; margin: 0; padding: 0; columns: 3 200px; column-gap: 40px; }
.app-list li { break-inside: avoid; padding: 11px 0; border-top: 1px solid var(--graphite-2); font-size: 1.06rem; color: var(--white); }

.def-list { margin: 28px 0 0; }
.def-list div { display: grid; grid-template-columns: minmax(160px, 0.42fr) 1fr; gap: 20px; padding: 20px 0; border-top: 1px solid var(--rule); }
.def-list dt { font-stretch: 112%; font-weight: 650; font-size: 1.12rem; }
.def-list dd { margin: 0; color: var(--steel); }
.on-dark .def-list div { border-color: var(--graphite-2); }
.on-dark .def-list dt { color: var(--white); }
.on-dark .def-list dd { color: var(--steel-light); }
@media (max-width: 600px) { .def-list div { grid-template-columns: 1fr; gap: 4px; } }

/* ---------- Photos ---------- */
.photo-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.photo-row img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; }
@media (max-width: 760px) { .photo-row { grid-template-columns: 1fr 1fr; } }

.masonry { columns: 3 280px; column-gap: 16px; }
.masonry figure { margin: 0 0 22px; break-inside: avoid; }
.masonry button { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; }
.masonry figcaption { font-size: 0.94rem; color: var(--steel); padding-top: 10px; }

.lightbox { border: 0; padding: 0; background: transparent; max-width: min(92vw, 900px); max-height: 92vh; overflow: visible; }
.lightbox::backdrop { background: rgba(28, 30, 33, 0.92); }
.lightbox img { max-width: 100%; max-height: 82vh; margin: 0 auto; }
.lightbox p { color: #d6d8db; text-align: center; margin: 12px auto 0; font-size: 0.95rem; }
.lightbox-close {
  position: absolute; top: -50px; right: 0; width: 42px; height: 42px; border: 0;
  background: var(--white); color: var(--graphite); font-size: 1.5rem; line-height: 1; cursor: pointer;
}

/* ---------- Quote band ---------- */
.cta-band { background: var(--gold); color: var(--graphite); padding: clamp(48px, 7vw, 80px) 0; }
.cta-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 28px 48px; }
.cta-inner h2 { margin-bottom: 10px; }
.cta-inner p { margin: 0; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: clamp(32px, 5vw, 72px); align-items: start; }
@media (max-width: 880px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-list { margin: 0; }
.contact-list div { padding: 20px 0; border-top: 1px solid var(--rule); }
.contact-list div:last-child { border-bottom: 1px solid var(--rule); }
.contact-list dt { font-size: 0.94rem; color: var(--steel); margin-bottom: 4px; }
.contact-list dd { margin: 0; font-size: 1.15rem; font-weight: 600; }
.contact-list dd a { text-decoration: none; }
.contact-list dd a:hover { color: var(--gold-text); text-decoration: underline; text-underline-offset: 4px; }
.contact-list address { font-style: normal; font-weight: 500; font-size: 1.05rem; }

.form-card { background: var(--white); border: 1px solid var(--rule); padding: clamp(24px, 4vw, 40px); }
.form-card h2 { font-size: var(--step-3); }
.form-card > p { color: var(--steel); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 560px) { .form-grid { grid-template-columns: 1fr; } }
.field label { display: block; font-size: 0.94rem; font-weight: 600; margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 50px; padding: 12px 14px; font: inherit; color: var(--graphite);
  background: var(--concrete); border: 1px solid #c9ccc7; border-radius: 2px;
}
.field textarea { min-height: 120px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--gold); outline-offset: 0; border-color: var(--gold); background: var(--white); }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-top: 22px; }
.form-actions small { color: var(--steel); font-size: 0.94rem; }
.form-actions small a { color: var(--gold-text); }

.map-embed { margin-top: clamp(40px, 6vw, 72px); border: 1px solid var(--rule); background: var(--rule); }
.map-embed iframe { display: block; width: 100%; height: clamp(300px, 40vw, 440px); border: 0; }

/* ---------- Footer ---------- */
.site-footer { background: var(--graphite); color: var(--steel-light); font-size: 0.97rem; }
.footer-top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.3fr; gap: 40px; padding: 72px 0 56px; }
.footer-logo { display: inline-block; background: #f7f7f5; border-radius: 8px; padding: 14px 18px; margin-bottom: 22px; }
.footer-logo img { width: 240px; }
.footer-brand p { max-width: 26em; }
.brand-badge {
  display: inline-flex; align-items: baseline; gap: 10px; margin: 8px 0 0;
  padding: 16px 24px; border: 1px solid var(--gold); border-radius: 6px; color: #e6e7e9;
}
.brand-badge a, .brand-of a { text-decoration: none; }
.brand-badge strong, .brand-of strong { font-family: var(--font-slab); font-weight: 700; color: var(--gold); }
.brand-badge strong { font-size: 1.4rem; line-height: 1; }
.brand-badge a:hover strong, .brand-of a:hover strong { color: var(--white); text-decoration: underline; text-underline-offset: 3px; }
.site-footer h2 { font-size: 1.02rem; font-stretch: 112%; font-weight: 650; letter-spacing: 0; color: var(--white); margin-bottom: 16px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.site-footer a { text-decoration: none; }
.site-footer ul a:hover { color: var(--gold); }
.site-footer address { font-style: normal; }
.footer-bottom { border-top: 1px solid var(--graphite-2); padding: 22px 0; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; font-size: 0.9rem; }
@media (max-width: 900px) { .footer-top { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 520px) { .footer-top { grid-template-columns: 1fr; } }

/* ---------- WhatsApp ---------- */
.wa-float {
  position: fixed; right: 18px; bottom: 18px; z-index: 60;
  display: inline-flex; align-items: center; gap: 10px; height: 56px; padding: 0 20px 0 16px;
  background: #1c8f4a; color: var(--white); border-radius: 999px; text-decoration: none; font-weight: 650;
  box-shadow: 0 8px 24px -8px rgba(0, 0, 0, 0.5);
}
.wa-float:hover { background: #167a3e; }
.wa-float svg { width: 26px; height: 26px; }
@media (max-width: 520px) { .wa-float { width: 56px; padding: 0; justify-content: center; } .wa-float span { display: none; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
