/* Percheron Manufacturing — site styles */

@font-face {
  font-family: "Nexa Bold";
  src: url("../fonts/Nexa-Bold.woff") format("woff");
  font-weight: 700;
  font-display: swap;
}

:root {
  --navy: #253551;
  --stone: #e0e0db;
  --charcoal: #2a2829;
  --black: #000;
  --white: #fff;
  --pad: max(20px, 3vw, calc((100vw - 1440px) / 2));
  --section-y: clamp(34px, 4.5vw, 72px);
  --gap: clamp(24px, 5vw, 80px);
  --font-body: "Work Sans", Arial, sans-serif;
  --font-head: "Nexa Bold", "Work Sans", Arial, sans-serif;
}

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

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

body {
  margin: 0;
  background: var(--white);
  color: var(--black);
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img, video, iframe { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

h1, h2, h3, h4 {
  margin: 0;
  font-family: var(--font-head);
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
}
h1 { font-size: clamp(2.2rem, 5.2vw + 0.35rem, 4.75rem); line-height: 1.03; text-wrap: balance; }
h2 { font-size: clamp(1.75rem, 3.6vw + 0.4rem, 3.5rem); line-height: 1.09; text-wrap: balance; }
h4 { font-size: clamp(1rem, 1.2vw + 0.4rem, 1.375rem); line-height: 1.19; }

.lead { font-size: clamp(1rem, 0.9vw + 0.58rem, 1.3rem); }

:focus-visible { outline: 3px solid #7fa3e0; outline-offset: 3px; }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  padding: 0.75rem 1rem;
  background: var(--white);
  color: var(--black);
}
.skip-link:focus { left: 0; }

/* ---------- Announcement bar ---------- */

.announcement {
  position: relative;
  padding: 0.5rem 3rem;
  background: var(--navy);
  color: var(--white);
  font-size: 0.875rem;
  text-align: center;
}
.announcement a { font-weight: 700; }
.announcement[hidden] { display: none; }
.announcement__close {
  position: absolute;
  top: 50%;
  right: 0.75rem;
  transform: translateY(-50%);
  padding: 0.25rem 0.5rem;
  border: 0;
  background: none;
  color: inherit;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
}

/* ---------- Header ---------- */

.site { position: relative; }

.header {
  position: absolute;
  inset: 0 0 auto 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: clamp(16px, 2vw, 32px);
  padding: clamp(14px, 2.2vw, 34px) var(--pad);
  color: var(--white);
}
.header__logo { flex: none; width: clamp(200px, 28vw, 400px); }
.header__logo img { width: 100%; height: auto; }

.nav {
  display: flex;
  flex: 1 1 0;
  justify-content: flex-end;
  gap: clamp(1rem, 1.8vw, 2.25rem);
}
.nav a {
  position: relative;
  padding: 0.5em 0;
  font-size: 0.8125rem;
  letter-spacing: 0.14em;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
}
.nav a::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}
.nav a:hover::after,
.nav a[aria-current="page"]::after { transform: scaleX(1); }

.header__cta { flex: none; letter-spacing: 0.14em; font-size: 0.8125rem; }

/* Two-line menu button that folds into a cross */
.burger {
  position: relative;
  display: none;
  flex: none;
  width: 44px;
  height: 44px;
  margin-left: auto;
  padding: 0;
  border: 0;
  background: none;
  color: var(--white);
  cursor: pointer;
}
.burger span {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}
.burger::before,
.burger::after {
  content: "";
  position: absolute;
  left: 7px;
  right: 7px;
  height: 2px;
  background: currentColor;
  transition: transform 0.3s ease, top 0.3s ease;
}
.burger::before { top: 17px; }
.burger::after { top: 26px; }
.menu-open .burger::before { top: 21px; transform: rotate(45deg); }
.menu-open .burger::after { top: 21px; transform: rotate(-45deg); }

.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 15;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 6.5rem var(--pad) 2.5rem;
  overflow-y: auto;
  background: var(--navy);
  color: var(--white);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s;
}
.mobile-menu > * {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.mobile-menu__link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
  font-family: var(--font-head);
  font-size: clamp(1.2rem, 5.2vw, 1.7rem);
  letter-spacing: 3px;
  text-decoration: none;
  text-transform: uppercase;
}
.mobile-menu__link::after {
  content: "\203A";
  font: 400 1.5em/1 var(--font-body);
  opacity: 0.5;
}
.mobile-menu__link[aria-current="page"] { color: #9fb6dc; }
.mobile-menu .btn { width: 100%; margin-top: 2.25rem; }
.mobile-menu__phone {
  margin-top: 1.25rem;
  font-size: 0.9rem;
  letter-spacing: 0.12em;
  text-align: center;
  text-decoration: none;
}
.menu-open { overflow: hidden; }
.menu-open .mobile-menu { opacity: 1; visibility: visible; }
.menu-open .mobile-menu > * { opacity: 1; transform: none; }
.menu-open .mobile-menu > :nth-child(2) { transition-delay: 0.05s; }
.menu-open .mobile-menu > :nth-child(3) { transition-delay: 0.1s; }
.menu-open .mobile-menu > :nth-child(4) { transition-delay: 0.15s; }
.menu-open .mobile-menu > :nth-child(5) { transition-delay: 0.2s; }
.menu-open .mobile-menu > :nth-child(6) { transition-delay: 0.25s; }
.menu-open .header { position: fixed; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: min(100%, 314px);
  min-height: 52px;
  padding: 0.4rem 1.5rem;
  border: 6px solid var(--navy);
  background: var(--navy);
  color: var(--white);
  font: 500 1rem/1.2 var(--font-body);
  letter-spacing: 0.02em;
  text-align: center;
  text-decoration: none;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s;
}
.btn:hover { border-color: #37507c; background: #37507c; }
.btn--outline { background: transparent; color: var(--navy); }
.btn--outline:hover { border-color: var(--navy); background: var(--navy); color: var(--white); }
.btn--white { border-color: var(--white); background: var(--white); color: var(--black); }
.btn--white:hover { border-color: var(--stone); background: var(--stone); }
.btn--white-outline { border-color: var(--white); background: transparent; color: var(--white); }
.btn--white-outline:hover { border-color: var(--white); background: var(--white); color: var(--black); }
.btn--auto { width: auto; padding-inline: 1.5rem; font-size: 0.9rem; }

.btn-row { display: flex; flex-wrap: wrap; gap: 11px; }
.btn-stack { display: flex; flex-direction: column; align-items: flex-start; gap: 11px; }
.btn-row--center { justify-content: center; }

/* ---------- Sections ---------- */

.section {
  position: relative;
  padding: var(--section-y) var(--pad);
}
.section--navy { background: var(--navy); color: var(--white); }
.section--stone { background: var(--stone); }
.section--dark { background: var(--black); color: var(--white); }
.section--tight-top,
.section--join { padding-top: 0; }

.section__bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
}
.section__bg img,
.section__bg video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.section__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--black);
  opacity: var(--overlay, 0.35);
}
.section__bg--right { left: 42%; }
.section__bg--right::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  z-index: 1;
  width: 35%;
  background: linear-gradient(90deg, var(--black), transparent);
}
.section__inner { position: relative; }

/* ---------- Heroes ---------- */

.hero { padding-top: clamp(104px, 14.5vw, 210px); }
.hero--home {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: min(85vh, 900px);
}
.hero--home h1 { max-width: 12em; }
.hero--home .lead { max-width: 30em; margin: 0.6rem 0 2.6rem; }
.hero__badges {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 11px;
}
.hero__badges img { width: auto; height: 52px; }

/* ---------- Two-column layouts ---------- */

.split {
  display: grid;
  grid-template-columns: minmax(0, var(--left, 1fr)) minmax(0, var(--right, 1fr));
  gap: var(--gap);
  align-items: start;
}
.split--center { align-items: center; }
.split h2 + p,
.split h2 + .lead { margin-top: 0.7rem; }
.split p + .btn-stack,
.split p + .btn-row { margin-top: 0.7rem; }
.measure { max-width: 22.5rem; }

.media { width: 100%; background: var(--black); }
.media--video { aspect-ratio: 16 / 13; object-fit: cover; }
.media--photo { aspect-ratio: 435 / 407; object-fit: cover; }

.map {
  width: 100%;
  height: 100%;
  min-height: 324px;
  border: 0;
  filter: grayscale(0.55);
}

/* ---------- Icon row (home) ---------- */

.icon-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.5rem;
  text-align: center;
}
.icon-row img { width: clamp(72px, 10.8vw, 132px); margin: 0 auto 0.7rem; }
.icon-row h4 { max-width: 10.5em; margin: 0 auto; }
.icon-row + .btn-row { margin-top: 1.6rem; }

/* ---------- Feature columns (process) ---------- */

.section-title { margin-bottom: clamp(1.75rem, 4vw, 2.75rem); }

.features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem clamp(24px, 5vw, 80px);
}
.feature { max-width: 17.5rem; }
.feature__head {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  min-height: 2.75rem;
  margin-bottom: 0.7rem;
}
.feature__head img { flex: none; width: 30px; height: 30px; object-fit: contain; }
.features + .btn-row { margin-top: 2.5rem; }

/* ---------- Dark image sections ---------- */

.banner { padding-block: clamp(34px, 4.5vw, 72px); }
.banner--tall { padding-block: clamp(90px, 14vw, 200px); }
.banner--right { text-align: right; }
.banner--right .section__inner { margin-left: auto; }
.banner h2 { max-width: 9.5em; }
.banner--right h2 { margin-left: auto; }
.banner h2 + p { margin-top: 1rem; }
.banner__logo { width: min(100%, 314px); margin-inline: auto; }

/* ---------- Slideshow ---------- */

.slideshow {
  position: relative;
  aspect-ratio: 395 / 322;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.25);
}
.slideshow img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.5s;
}
.slideshow img.is-active { opacity: 1; }
.slideshow__btn {
  position: absolute;
  top: 50%;
  z-index: 1;
  width: 44px;
  height: 44px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  color: var(--white);
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  transition: background-color 0.2s;
}
.slideshow__btn:hover { background: var(--navy); }
.slideshow__btn--prev { left: 12px; }
.slideshow__btn--next { right: 12px; }

/* ---------- Products ---------- */

.intro { max-width: 40rem; margin: 0 auto clamp(1.75rem, 4vw, 2.75rem); text-align: center; }
.intro h2 + p { margin-top: 1.4rem; }

.products {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 11px;
  max-width: min(100%, 78vw, 1100px);
  margin: 0 auto;
}
.product { display: flex; flex-direction: column; gap: 11px; }
.product:nth-child(5) { grid-column: 2; }
.product__image {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 192 / 202;
  overflow: hidden;
  border-radius: 10px;
  background: var(--black);
  color: var(--white);
  text-align: center;
  text-decoration: none;
}
.product__image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}
.product__image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.38);
  transition: background-color 0.3s;
}
.product__image:hover img { transform: scale(1.04); }
.product__image:hover::after { background: rgba(37, 53, 81, 0.55); }
.product__image h4 {
  position: relative;
  z-index: 1;
  padding: 0 0.5rem;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.7);
}
.product .btn { width: 100%; padding-inline: 0.5rem; }

/* ---------- Product specs ---------- */

.specs { --left: 7fr; --right: 14fr; }
.specs h2 { color: var(--navy); }
.specs__note { margin-bottom: 0.6rem; }
.table-wrap { overflow: auto; }
.spec-table {
  width: 100%;
  min-width: calc(var(--cols, 1) * 6.25rem); /* scroll sideways rather than crush columns */
  border: 1px solid #dededf;
  border-collapse: collapse;
  table-layout: fixed;
  text-align: left;
}
.spec-table th,
.spec-table td { padding: 0.6rem 0.8rem; border: 1px solid #dededf; }
.spec-table th { border-color: var(--navy); background: var(--navy); color: var(--white); font-weight: 500; }
.spec-table td { height: 2.75rem; background: var(--white); }
.spec-table tbody tr:nth-child(even) td { background: #f6f6f3; }

/* ---------- Quote ---------- */

.banner--quote { padding-block: clamp(48px, 7vw, 110px); }
.quote { margin: 0; width: 38%; min-width: 16rem; }
.quote p { font-size: clamp(1rem, 0.9vw + 0.58rem, 1.3rem); }
.quote footer { margin-top: 1rem; font-family: var(--font-head); letter-spacing: 2px; text-transform: uppercase; }

/* ---------- Contact ---------- */

.contact { --left: 11fr; --right: 12fr; align-items: stretch; }
.contact h4 { margin-bottom: 0.6rem; }
.contact__details {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(13.5rem, 1fr));
  gap: 1.75rem 2rem;
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--stone);
}
.contact__block h4 { color: var(--navy); }
.contact__block p { margin: 0 0 0.2rem; }
.contact__block--wide { grid-column: 1 / -1; }
.contact__primary { font-size: 1.25rem; }
.contact .contact__form-title { margin-bottom: 1.1rem; }
.contact .map { min-height: 420px; }

.form { display: grid; gap: 1.1rem; }
.form fieldset { margin: 0; padding: 0; border: 0; }
.form legend { margin-bottom: 0.4rem; padding: 0; }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; }
.form label { display: block; }
.form__row label { font-size: 0.75rem; }
.form .req { margin-left: 0.3em; font-size: 0.75rem; opacity: 0.6; }
.form input,
.form textarea {
  display: block;
  width: 100%;
  margin-top: 0.3rem;
  padding: 10px;
  border: 1px solid var(--black);
  border-radius: 0;
  background: #fafafa;
  font: inherit;
}
.form input { height: 48px; }
.form textarea { min-height: 140px; resize: vertical; }
.form input:focus,
.form textarea:focus { outline: 2px solid var(--navy); outline-offset: 1px; background: var(--white); }
.form__trap { position: absolute; left: -9999px; } /* spam trap, hidden from people */
.form__status { margin: 0; }
.form__status:empty { display: none; }

/* ---------- Footer ---------- */

.footer {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  padding: clamp(40px, 6.3vw, 90px) var(--pad) clamp(28px, 3.3vw, 48px);
  background: var(--charcoal);
  color: var(--white);
}
.footer__horse { width: clamp(84px, 10.8vw, 132px); margin-bottom: 0.9rem; }
.footer__copy { max-width: 16rem; }
.footer__sitemap { text-align: right; }
.footer__sitemap p { margin-bottom: 1em; font-weight: 700; }
.footer__sitemap ul { margin: 0; padding: 0; list-style: none; }

/* ---------- Responsive ---------- */

@media (max-width: 1000px) {
  .nav,
  .header__cta { display: none; }
  .burger { display: block; }
  .header__logo { width: min(62vw, 300px); }
}

@media (max-width: 800px) {
  .section--join { padding-top: var(--section-y); border-top: 1px solid var(--stone); }

  /* quote: photo on top, text underneath */
  .section__bg--right { left: 0; bottom: auto; height: 58vw; }
  .section__bg--right::before { display: none; }
  .banner--quote { padding-top: calc(58vw + 1.75rem); }
  .quote { width: auto; }

  .hero--home { min-height: 0; padding-bottom: 2.5rem; }
  .hero--home .lead { margin-bottom: 1.75rem; }

  .split { grid-template-columns: minmax(0, 1fr); }
  .split--media-first > :last-child { order: -1; }
  .measure { max-width: none; }

  .icon-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .features { grid-template-columns: minmax(0, 1fr); }
  .feature { max-width: none; }

  .products { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: none; }
  .product:nth-child(5) { grid-column: auto; }

  .banner--tall { padding-block: 72px; }
  .contact .map { min-height: 320px; }
}

@media (max-width: 480px) {
  .btn-row .btn,
  .btn-stack .btn { width: 100%; }
  .footer { flex-direction: column; }
  .footer__sitemap { text-align: left; }
}

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