/* ---------------------------------------------------------------
   Materconceição — design tokens
   Palette sampled from logo-extracted.png, the yard canopy and the
   fleet, so photography sits on backgrounds matching its subject.
   --------------------------------------------------------------- */

/* Two subsets per family and weight, as emitted by tools/fetch_fonts.py.
   `latin` (U+0000-00FF) is the one Portuguese actually needs; `latin-ext`
   is declared so the browser can fetch it only if a page ever uses a
   character outside Latin-1. The unicode-range values are copied verbatim
   from the Google css2 response, so nothing is downloaded needlessly. */
@font-face {
  font-family: "Barlow Semi Condensed";
  src: url("./fonts/barlow-semi-condensed-600-latin.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Barlow Semi Condensed";
  src: url("./fonts/barlow-semi-condensed-600-latin-ext.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Barlow Semi Condensed";
  src: url("./fonts/barlow-semi-condensed-700-latin.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Barlow Semi Condensed";
  src: url("./fonts/barlow-semi-condensed-700-latin-ext.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("./fonts/source-sans-3-400-latin.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("./fonts/source-sans-3-400-latin-ext.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("./fonts/source-sans-3-600-latin.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("./fonts/source-sans-3-600-latin-ext.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --blue-accent: #3682c4;
  --blue-mid: #0758b3;
  --blue-deep: #043c7e;
  --navy: #1c2d40;
  --warm-grey: #807f77;
  --concrete-50: #f5f4f2;
  --concrete-200: #d9d6d0;

  --font-display: "Barlow Semi Condensed", "Arial Narrow", sans-serif;
  --font-body: "Source Sans 3", system-ui, sans-serif;

  --measure: 68ch;
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --container: 1280px;
  --step: clamp(3rem, 7vw, 6rem);
}

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

/* `[hidden] { display: none }` lives in the user-agent stylesheet, which
   loses to any author rule of equal or higher specificity that also sets
   `display` — e.g. `.button { display: inline-flex }` below. Without
   `!important` here, a hidden `<button class="button" hidden>` still
   renders. */
[hidden] { display: none !important; }

html {
  /* The site header is sticky and occupies 0–91.7px at both 375px and
     1440px, so without this every in-page anchor lands *behind* it.
     6.5rem (104px) clears it with ~12px of air above the target. */
  scroll-padding-top: 6.5rem;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  /* 12.75:1 against --concrete-50 */
  color: var(--navy);
  background: #fff;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  line-height: 1.05;
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(2.5rem, 6vw, 4.5rem); }
h2 { font-size: clamp(1.875rem, 4vw, 3rem); }
h3 { font-size: clamp(1.25rem, 2vw, 1.5rem); }

p { max-width: var(--measure); }

a { color: var(--blue-mid); }            /* 6.87:1 inverted; underlined below */
a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--blue-accent);
  outline-offset: 2px;
}

img { max-width: 100%; height: auto; display: block; }

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

.section { padding-block: var(--step); }

.section--dark {
  background: var(--blue-deep);
  color: #fff;                            /* 10.75:1 */
}
.section--dark a { color: #fff; }

.section--tint { background: var(--concrete-50); }

.eyebrow {
  font-family: var(--font-display);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.8125rem;
  /* never --warm-grey on light: 4.02:1 fails AA for text this size */
  color: var(--blue-mid);
  margin: 0 0 0.75rem;
}
.section--dark .eyebrow { color: #9fc6ec; }

.button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-display);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 1rem;
  padding: 0.85rem 1.6rem;
  border: 2px solid transparent;
  border-radius: 2px;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.button--primary { background: var(--blue-mid); color: #fff; }
.button--primary:hover { background: var(--blue-deep); }

.button--ghost {
  background: transparent;
  border-color: currentColor;
  color: inherit;
}
.button--ghost:hover { background: rgb(255 255 255 / 0.12); }

.section--tint .button--ghost,
.section:not(.section--dark) .button--ghost { color: var(--navy); }

/* Small print: --warm-grey would be 4.02:1, so use navy at reduced opacity
   to stay secondary while remaining above 4.5:1. */
.legal-note { font-size: 0.8125rem; color: rgb(28 45 64 / 0.75); }

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* --- chrome ---------------------------------------------------- */

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

.skip-link {
  position: absolute;
  left: -9999px;
  background: var(--navy);
  color: #fff;
  padding: 0.75rem 1.25rem;
  z-index: 100;
}
.skip-link:focus { left: 1rem; top: 1rem; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: #fff;
  border-bottom: 1px solid var(--concrete-200);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.75rem;
}

.brand__logo { width: 168px; height: auto; }

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(0.75rem, 2vw, 1.75rem);
}

.site-nav a {
  font-family: var(--font-display);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--navy);
  text-decoration: none;
}
.site-nav a:hover { color: var(--blue-mid); }
.site-nav a[aria-current="page"] {
  color: var(--blue-mid);
  box-shadow: inset 0 -3px 0 var(--blue-accent);
}
.site-nav__cta { color: #fff !important; }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: 0;
  padding: 0.5rem;
}
.nav-toggle__bar {
  display: block;
  width: 26px; height: 2px;
  background: var(--navy);
}

.site-footer {
  background: var(--navy);
  color: #fff;                            /* 14.01:1 */
  padding-block: var(--step);
}
.site-footer a { color: #fff; }
.site-footer .legal-note { color: rgb(255 255 255 / 0.72); }
.site-footer__logo {
  width: 168px;
  height: auto;
  background: #fff;
  padding: 0.5rem;
  margin-bottom: 1rem;
}
.site-footer__inner {
  display: grid;
  gap: 2.5rem;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.mobile-bar { display: none; }

@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .site-nav {
    display: none;
    position: absolute;
    inset-inline: 0;
    top: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: #fff;
    border-bottom: 1px solid var(--concrete-200);
    padding: 0.5rem var(--gutter) 1.25rem;
  }
  .site-nav.is-open { display: flex; }
  .site-nav a { padding-block: 0.85rem; }

  .mobile-bar {
    position: fixed;
    inset-inline: 0;
    bottom: 0;
    z-index: 60;
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-top: 1px solid var(--concrete-200);
  }
  .mobile-bar__item {
    padding: 0.9rem;
    text-align: center;
    font-family: var(--font-display);
    font-weight: 600;
    text-transform: uppercase;
    background: #fff;
    color: var(--navy);
    text-decoration: none;
  }
  .mobile-bar__item--cta { background: var(--blue-mid); color: #fff; }
  body { padding-bottom: 3.5rem; }
}

/* --- homepage patterns ----------------------------------------- */

.hero { display: grid; isolation: isolate; }
.hero > * { grid-area: 1 / 1; }

.hero__media { display: block; }
.hero__media img {
  width: 100%;
  height: 100%;
  min-height: clamp(420px, 68vh, 760px);
  object-fit: cover;
  object-position: center 42%;
}

.hero::after {
  content: "";
  grid-area: 1 / 1;
  z-index: 1;
  background: linear-gradient(
    to top,
    rgb(4 60 126 / 0.94) 0%,
    rgb(4 60 126 / 0.72) 45%,
    rgb(4 60 126 / 0.30) 100%
  );
}

.hero__copy {
  position: relative;
  z-index: 2;
  align-self: end;
  padding-top: clamp(3rem, 12vw, 7rem);
  padding-bottom: clamp(2rem, 6vw, 4.5rem);
  color: #fff;
}
/* White, not #9fc6ec: over a photograph the scrim opacity varies and
   #9fc6ec measured 3.73:1 against the brightest background it lands on,
   below the 4.5:1 AA threshold for 13px text. #9fc6ec stays fine on the
   solid --blue-deep of .section--dark, where it measures about 6:1. */
.hero__copy .eyebrow { color: #fff; }
.hero__text { font-size: clamp(1.0625rem, 1.6vw, 1.25rem); }

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1.75rem;
}

.stats__grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}
.stat { display: flex; flex-direction: column; gap: 0.25rem; }
.stat__value {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1;
}
.stat__label {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.8125rem;
  color: rgb(255 255 255 / 0.8);
}

.feature__grid {
  display: grid;
  gap: clamp(2rem, 5vw, 4rem);
  grid-template-columns: 1fr;
  align-items: center;
}
@media (min-width: 900px) {
  .feature__grid { grid-template-columns: 1fr 1fr; }
  .feature__grid--reverse > picture { order: 2; }
}
.feature__grid img { width: 100%; object-fit: cover; }

.cards {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  margin-top: 2.5rem;
}
.card {
  display: block;
  padding: 1.75rem;
  background: #fff;
  border: 1px solid var(--concrete-200);
  border-left: 4px solid var(--blue-accent);
  text-decoration: none;
  color: inherit;
  transition: transform 0.15s ease, border-color 0.15s ease;
}
.card:hover { transform: translateY(-3px); border-left-color: var(--blue-mid); }
.card h3 { margin-bottom: 0.35rem; }
.card p { margin: 0; font-size: 0.9375rem; }

/* --- interior pages -------------------------------------------- */

/* Single-cell grid, NOT absolute positioning with a negative-z-index
   pseudo-element. A z-index:-1 ::after inside a stacking context paints
   BELOW in-flow descendants, so the scrim would render behind the <img>
   and the headline would sit unreadably on the bare photograph. This was
   a real defect caught on the homepage; do not reintroduce it.
   The grid also lets copy contribute to height, so tall headings on
   narrow viewports cannot overflow a fixed-height image. */
.page-hero { display: grid; isolation: isolate; }
.page-hero > * { grid-area: 1 / 1; }

.page-hero__media { display: block; }
.page-hero__media img {
  width: 100%;
  height: 100%;
  min-height: clamp(280px, 42vh, 460px);
  object-fit: cover;
}

.page-hero::after {
  content: "";
  grid-area: 1 / 1;
  z-index: 1;
  background: linear-gradient(to top, rgb(28 45 64 / 0.92), rgb(28 45 64 / 0.45));
}

.page-hero__copy {
  position: relative;
  z-index: 2;
  align-self: end;
  padding-top: clamp(2rem, 8vw, 4rem);
  padding-bottom: clamp(1.5rem, 4vw, 3rem);
  color: #fff;
}

/* White, NOT the #9fc6ec used on opaque dark sections. Over a photograph
   the scrim opacity varies, and #9fc6ec was measured at only 3.73:1 against
   the brightest background it actually lands on — below the 4.5:1 AA
   threshold for 13px text. #9fc6ec stays fine on the solid --blue-deep of
   .section--dark, where it measures about 6:1. */
.page-hero__copy .eyebrow { color: #fff; }

.product-rows { display: grid; gap: 1.5rem; margin-top: 2.5rem; }

.product-row {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: 1fr;
  align-items: center;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--concrete-200);
}
.product-row:last-child { border-bottom: 0; }
.product-row img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
@media (min-width: 720px) {
  .product-row { grid-template-columns: 280px 1fr; gap: 2.5rem; }
}

.cta-band {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

/* .card is normally a link (index, produtos); the Serviços cards are plain
   divs with no destination, so drop the hover lift that implies they're
   clickable. */
.cards > div.card { cursor: default; }
.cards > div.card:hover { transform: none; border-left-color: var(--blue-accent); }
.cta-band p { margin-bottom: 0; }

/* --- empresa: timeline and gallery ------------------------------ */

.timeline {
  list-style: none;
  margin: 2.5rem 0 0;
  padding: 0;
  display: grid;
  gap: 0;
}
.timeline li {
  position: relative;
  padding: 0 0 2rem 2.25rem;
  border-left: 2px solid var(--concrete-200);
}
.timeline li:last-child { border-left-color: transparent; padding-bottom: 0; }
.timeline li::before {
  content: "";
  position: absolute;
  left: -9px;
  top: 0.35rem;
  width: 16px;
  height: 16px;
  background: var(--blue-mid);
  border-radius: 50%;
}
.timeline h3 { margin-bottom: 0.25rem; }

.gallery {
  list-style: none;
  margin: 2.5rem 0 0;
  padding: 0;
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}
.gallery img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }

/* --- contacts page ----------------------------------------------- */

.contact-details {
  display: grid;
  gap: 1.5rem;
  margin-top: 1.5rem;
}
.contact-details h3 { margin-bottom: 0.25rem; }
.contact-details p { margin: 0; }

.map-frame {
  width: 100%;
  aspect-ratio: 4 / 3;
  border: 0;
}

/* Click-to-load map. The placeholder occupies roughly the space the iframe
   will take, so the click does not throw the rest of the page around. */
.map-block__placeholder {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 0.9rem;
  min-height: 18rem;
  padding: clamp(1.25rem, 4vw, 2rem);
  background: var(--concrete-50);
  border: 1px solid var(--concrete-200);
}
.map-block__placeholder h3 { margin: 0; }
.map-block__placeholder p { margin: 0; }
.map-block__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.form-layout {
  display: grid;
  gap: clamp(2rem, 5vw, 4rem);
  grid-template-columns: 1fr;
}
@media (min-width: 900px) { .form-layout { grid-template-columns: 1fr 1fr; } }

.form__field { display: grid; gap: 0.35rem; margin: 0 0 1.25rem; max-width: none; }
.form__field label {
  font-family: var(--font-display);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.8125rem;
}
.form__field input,
.form__field textarea {
  font: inherit;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--warm-grey);
  border-radius: 2px;
  background: #fff;
  color: var(--navy);
}
.form__field input:focus-visible,
.form__field textarea:focus-visible {
  outline: 3px solid var(--blue-accent);
  outline-offset: 1px;
}
.form__honeypot { position: absolute; left: -9999px; }
.form__status { margin-top: 1rem; font-weight: 600; }
/* RGPD Art. 13 notice, shown at the point of collection rather than behind
   a link. Sits directly under the submit button. */
.form__privacidade { margin-top: 1rem; max-width: var(--measure); }
