/* De Jong Manufacturing – site styles
   Colors come from the logo: red, black, and the yellow spark. */

/* ---------- Fonts (self-hosted, see fonts/OFL-LICENSE.txt) ---------- */
@font-face { font-family: "Barlow"; font-weight: 400; font-style: normal; font-display: swap; src: url("../fonts/barlow-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-weight: 500; font-style: normal; font-display: swap; src: url("../fonts/barlow-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-weight: 600; font-style: normal; font-display: swap; src: url("../fonts/barlow-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-weight: 700; font-style: normal; font-display: swap; src: url("../fonts/barlow-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 600; font-style: normal; font-display: swap; src: url("../fonts/barlow-condensed-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 700; font-style: normal; font-display: swap; src: url("../fonts/barlow-condensed-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 800; font-style: normal; font-display: swap; src: url("../fonts/barlow-condensed-latin-800-normal.woff2") format("woff2"); }

/* ---------- Colors and sizes (from the De Jong design system) ---------- */
:root {
  --red: #b32f2a;        /* brand red: buttons, links, dividers */
  --red-dark: #8e2420;
  --ink: #171717;        /* brand black: text */
  --charcoal: #232425;
  --steel: #f2f2f0;      /* light section background */
  --line: #d9d9d6;
  --muted: #55595e;
  --spark-core: #e7503e; /* starburst colors: decoration only, never small text */
  --spark-mid: #f2803d;
  --spark: #ffd23d;      /* starburst tip: thin accent lines only */
  --white: #fff;
  --max: 1140px;
  --gutter: 16px;
  --radius: 4px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Barlow", Arial, sans-serif;
  font-size: 1.125rem;   /* 18px: easy to read on phones */
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--red); text-underline-offset: 2px; }
a:hover { color: var(--red-dark); }
:focus-visible { outline: 3px solid var(--spark); outline-offset: 2px; }

h1, h2, h3 {
  font-family: "Barlow Condensed", "Arial Narrow", Arial, sans-serif;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: .01em;
  margin: 0 0 .5em;
}
h1 { font-size: clamp(2.25rem, 7vw, 3.75rem); font-weight: 800; text-transform: uppercase; }
h2 { font-size: clamp(1.75rem, 5vw, 2.5rem); font-weight: 800; text-transform: uppercase; }
h3, h2.h3 { font-size: 1.5rem; font-weight: 600; text-transform: none; }
p { margin: 0 0 1em; }
ul { padding-left: 1.25em; }

.container { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: 56px 0; }
.section--steel { background: var(--steel); }
.section--dark { background: var(--charcoal); color: var(--white); }
.section--dark a { color: var(--white); }
.lead { font-size: 1.25rem; color: var(--muted); max-width: 46em; }
.section--dark .lead { color: #d6d6d6; }
.eyebrow {
  display: inline-block;
  font-family: "Barlow Condensed", Arial, sans-serif;
  font-weight: 600; font-size: 1rem;
  text-transform: uppercase; letter-spacing: .12em;
  color: var(--red);
  border-top: 3px solid var(--spark);
  padding-top: 6px; margin-bottom: 12px;
}
.skip-link { position: absolute; left: -9999px; }
.skip-link:focus { left: 8px; top: 8px; z-index: 10; background: var(--white); padding: 8px 12px; }

/* Placeholder text that still needs real information. Remove before launch. */
.todo { background: #fff3b0; color: var(--ink); padding: 0 .2em; border-radius: 2px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: "Barlow Condensed", Arial, sans-serif;
  font-weight: 700; font-size: 1.25rem;
  text-transform: uppercase; letter-spacing: .04em; text-decoration: none;
  padding: 12px 24px; border-radius: var(--radius);
  background: var(--red); color: var(--white); border: 2px solid var(--red);
}
.btn:hover { background: var(--red-dark); border-color: var(--red-dark); color: var(--white); }
.btn--outline { background: transparent; color: var(--white); border-color: var(--white); }
.btn--outline:hover { background: var(--white); color: var(--ink); border-color: var(--white); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Header and navigation (no JavaScript needed) ---------- */
.site-header { background: var(--white); border-bottom: 4px solid var(--red); }
.site-header .container {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 8px 24px; padding-top: 10px; padding-bottom: 10px;
}
.logo img { width: 170px; }
.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 20px; }
.site-nav a {
  font-family: "Barlow Condensed", Arial, sans-serif;
  font-weight: 600; font-size: 1.2rem;
  text-transform: uppercase; letter-spacing: .04em;
  color: var(--ink); text-decoration: none;
  display: inline-block; padding: 6px 0;
  border-bottom: 3px solid transparent;
}
.site-nav a:hover { color: var(--red); }
.site-nav a[aria-current="page"] { border-bottom-color: var(--red); }
.site-nav .nav-careers { color: var(--red); }
@media (max-width: 639px) {
  /* Phones: menu becomes a compact 3 x 2 grid of buttons */
  .site-header .container { gap: 6px 24px; padding-top: 8px; padding-bottom: 8px; }
  .logo img { width: 150px; }
  .site-nav { width: 100%; }
  .site-nav ul { display: grid; grid-template-columns: repeat(3, 1fr); gap: 3px; }
  .site-nav a {
    display: block; text-align: center; font-size: .9rem; line-height: 1.2; letter-spacing: .02em;
    padding: 5px 2px 4px; background: var(--steel); border-bottom-width: 2px;
  }
  .site-nav a[aria-current="page"] { background: var(--ink); color: var(--white); border-bottom-color: var(--red); }
}

/* ---------- Hiring banner ---------- */
.hiring-bar { background: var(--ink); color: var(--white); text-align: center; font-weight: 500; }
.hiring-bar p { margin: 0; padding: 10px var(--gutter); }
.hiring-bar a { color: var(--white); font-weight: 700; text-decoration-color: var(--spark); text-decoration-thickness: 2px; }

/* ---------- Big photo heading ---------- */
.hero { position: relative; background: var(--ink); color: var(--white); overflow: hidden; }
.hero img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .45; }
.hero .container { position: relative; padding-top: 72px; padding-bottom: 72px; }
.hero h1 { max-width: 14em; }
.hero .eyebrow { color: var(--white); }
/* The photo starts zoomed in and settles back when the page opens, then drifts slowly */
.hero--laser img {
  opacity: .7; object-position: 70% 50%; transform-origin: 70% 55%;
  animation: settle 3.5s cubic-bezier(.2,.7,.2,1) both, drift 18s 3.5s ease-in-out infinite alternate;
}
.hero--laser::after { /* darkens the left side so the text stays readable */
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(23,23,23,.92) 0%, rgba(23,23,23,.75) 40%, rgba(23,23,23,.2) 75%, rgba(23,23,23,0) 100%);
}
.hero-video { /* laser clip fades in over the photo once it starts playing */
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 70% 50%;
  opacity: 0; transition: opacity 1.2s ease;
}
.hero-video.is-playing { opacity: .7; }
@media (min-width: 900px) {
  /* Wide screens: the clip sits on the right side, beside the headline, and fades in from the left */
  .hero-video { left: auto; right: 0; width: 62%; object-position: 50% 50%;
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 30%); mask-image: linear-gradient(90deg, transparent 0%, #000 30%); }
  .hero-video.is-playing { opacity: .9; }
}
.hero--laser.video-on picture img { opacity: 0; transition: opacity 1.2s ease; } /* still photo fades out once the clip plays */
.hero--laser .container { z-index: 1; }
.hero--laser h1, .hero--laser p { text-shadow: 0 2px 12px rgba(0,0,0,.7); }
.hero--laser p { font-weight: 500; max-width: 28em; }
@media (max-width: 639px) {
  .hero--laser img { opacity: .75; object-position: 50% 50%; transform-origin: 50% 55%; }
  .hero-video { object-position: 62% 50%; }
  .hero--laser::after { background: linear-gradient(180deg, rgba(23,23,23,.55) 0%, rgba(23,23,23,.8) 100%); }
}
@keyframes settle { from { transform: scale(1.25); } to { transform: scale(1); } }
@keyframes drift { from { transform: scale(1); } to { transform: scale(1.07); } }
.hero p { font-size: 1.25rem; max-width: 34em; }
.hero--short .container { padding-top: 48px; padding-bottom: 48px; }

/* ---------- Cards and grids ---------- */
.grid { display: grid; gap: 20px; grid-template-columns: 1fr; }
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.card h3 { margin-bottom: .3em; }
.card :last-child { margin-bottom: 0; }

.tile { display: block; text-decoration: none; color: var(--ink); background: var(--white); overflow: hidden; border: 1px solid var(--line); }
.tile img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transition: transform .5s ease; }
.tile:hover img, .tile:focus-visible img { transform: scale(1.05); }
.tile span {
  display: block; padding: 12px 16px;
  font-family: "Barlow Condensed", Arial, sans-serif; font-weight: 700; font-size: 1.3rem;
  text-transform: uppercase; border-top: 3px solid var(--red);
}
.tile:hover span { color: var(--red); }

.stats { list-style: none; padding: 0; margin: 0; display: grid; gap: 20px; grid-template-columns: repeat(2, 1fr); }
.stats li { border-top: 3px solid var(--spark-mid); padding-top: 10px; }
.stats strong { display: block; font-family: "Barlow Condensed", Arial, sans-serif; font-weight: 800; font-size: 2.75rem; line-height: 1; color: var(--white); }

.stats--light { margin-top: 32px; grid-template-columns: repeat(2, 1fr) !important; }
.stats--light li { border-top-color: var(--red); }
.stats--light strong { color: var(--ink); }
.stats--stack { grid-template-columns: 1fr 1fr !important; margin-top: 0; }
.about-intro { display: grid; gap: 24px; align-items: center; }
.photo-feature { margin: 0; max-width: 560px; }
.photo-feature img { width: 100%; border-bottom: 4px solid var(--red); }
.photo-feature figcaption { font-size: 1rem; color: var(--muted); margin-top: 10px; }
.prose .photo-feature { max-width: none; margin: 1.5em 0 2em; }
.mission { font-family: "Barlow Condensed", Arial, sans-serif; font-weight: 700; font-size: clamp(1.6rem, 4vw, 2.4rem); line-height: 1.25; max-width: 30em; margin: 0; }
.section--dark .eyebrow { color: var(--white); }
.btn--dark { background: var(--ink); border-color: var(--ink); }
.btn--dark:hover { background: #000; border-color: #000; }

/* ---------- Iowa map ---------- */
.iowa-map { width: 100%; height: auto; overflow: visible; }
.iowa-plate-back { fill: var(--red); }
.iowa-plate { fill: var(--ink); }
.iowa-cut { fill: none; stroke: var(--spark); stroke-width: 2; stroke-dasharray: 4 3; opacity: .9; transform: scale(.965); transform-origin: 300px 201px; }
.map-city circle { fill: #9a9a9a; }
.map-city text { fill: #c9c9c9; font: 600 18px "Barlow", Arial, sans-serif; }
.map-label { fill: var(--white); font: 800 30px "Barlow Condensed", Arial, sans-serif; text-transform: uppercase; letter-spacing: .02em; }
.map-sublabel { fill: #d6d6d6; font: 600 16px "Barlow", Arial, sans-serif; }
.map-pulse { fill: none; stroke: var(--spark-mid); stroke-width: 3; opacity: 0; transform-box: fill-box; transform-origin: center; }

/* Map motion: the "laser" traces the border, then the star lands and pulses */
.js-motion .iowa-cut { stroke-dasharray: 1000; stroke-dashoffset: 1000; }
.js-motion .is-visible .iowa-cut { animation: trace 2.4s ease-in-out forwards, dashes 0s 2.4s forwards; }
.js-motion .map-burst, .js-motion .map-label, .js-motion .map-sublabel { opacity: 0; }
.js-motion .is-visible .map-burst { transform-box: fill-box; transform-origin: center; animation: burst-in .7s 1.8s cubic-bezier(.2,1.6,.4,1) forwards, spin 40s 2.5s linear infinite; }
.js-motion .is-visible .map-label, .js-motion .is-visible .map-sublabel { animation: fade-in .6s 2.2s forwards; }
.js-motion .is-visible .map-pulse { animation: pulse 2.6s 2.5s ease-out infinite; }
.js-motion .is-visible .map-pulse--late { animation-delay: 3.8s; }
@keyframes trace { to { stroke-dashoffset: 0; } }
@keyframes dashes { to { stroke-dasharray: 4 3; } }
@keyframes burst-in { from { opacity: 0; transform: scale(0) rotate(-90deg); } to { opacity: 1; transform: scale(1) rotate(0); } }
@keyframes spin { from { transform: rotate(0); opacity: 1; } to { transform: rotate(360deg); opacity: 1; } }
@keyframes fade-in { to { opacity: 1; } }
@keyframes pulse { 0% { opacity: .9; transform: scale(.6); } 100% { opacity: 0; transform: scale(3.2); } }

/* Sections fade up as they scroll into view (added by js/site.js) */
.js-motion .reveal > .container { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.js-motion .reveal.is-visible > .container { opacity: 1; transform: none; }

/* Respect visitors who ask their device for less motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------- Careers ---------- */
.job { border-left: 6px solid var(--red); }
.job-meta { list-style: none; padding: 0; margin: 0 0 1em; display: flex; flex-wrap: wrap; gap: 6px 16px; color: var(--muted); font-weight: 500; }
.job-meta li::before { content: "■ "; color: var(--ink); }
.job h4 { font-size: 1.05rem; text-transform: uppercase; letter-spacing: .04em; margin: 1em 0 .25em; }
.job ul { margin-top: 0; }
/* Careers: job cards show title, shift/pay and summary; "See details" opens the rest */
.grid--jobs { align-items: start; } /* opening one card doesn't stretch the card beside it */
.job-details { margin: 0 0 1.2em; }
.job-details summary {
  display: inline-flex; align-items: center; gap: .5em; cursor: pointer; list-style: none;
  font-weight: 700; color: var(--red); padding: 4px 0;
}
.job-details summary::-webkit-details-marker { display: none; }
.job-details summary::before { /* square + / − sign */
  content: "+"; display: inline-grid; place-items: center; width: 1.3em; height: 1.3em;
  border: 2px solid currentColor; font-size: .95em; line-height: 1;
}
.job-details[open] summary::before { content: "\2212"; }
.job-details summary:hover { text-decoration: underline; }
.job-details h4:first-of-type { margin-top: .6em; }
.badge { display: inline-block; background: var(--red); color: var(--white); font-weight: 700; font-size: .9rem; text-transform: uppercase; letter-spacing: .05em; padding: 2px 8px; border-radius: 0; vertical-align: middle; }
.badge--dark { background: var(--ink); color: var(--white); }

/* Careers: How to apply (online only) */
.apply-panel { display: grid; gap: 28px; background: var(--white); border: 1px solid var(--line); border-left: 6px solid var(--red); padding: 28px 24px; }
.apply-main h3 { font-size: 2rem; margin-bottom: .2em; }
.apply-main p { font-size: 1.15rem; margin: 0 0 1.2em; }
.apply-main .btn { font-size: 1.4rem; padding: 14px 32px; }
.apply-steps { list-style: none; counter-reset: step; margin: 0; padding: 0; display: grid; gap: 18px; }
.apply-steps li { counter-increment: step; position: relative; padding-left: 52px; color: var(--muted); }
.apply-steps li::before {
  content: counter(step); position: absolute; left: 0; top: 2px; width: 36px; height: 36px;
  display: grid; place-items: center; background: var(--ink); color: var(--white);
  font-family: "Barlow Condensed", Arial, sans-serif; font-weight: 800; font-size: 1.3rem;
}
.apply-steps strong { display: block; color: var(--ink); font-family: "Barlow Condensed", Arial, sans-serif; font-weight: 700; font-size: 1.3rem; text-transform: uppercase; letter-spacing: .03em; line-height: 1.2; }
@media (min-width: 900px) {
  .apply-panel { grid-template-columns: 1.1fr 1fr; align-items: center; gap: 48px; padding: 36px 40px; }
}

/* ---------- Capabilities ---------- */
.jump { list-style: none; padding: 0; margin: 24px 0 0; display: flex; flex-wrap: wrap; gap: 8px; }
.jump a {
  display: inline-block; padding: 6px 12px; border: 1px solid var(--line); background: var(--white);
  font-family: "Barlow Condensed", Arial, sans-serif; font-weight: 700; text-transform: uppercase; letter-spacing: .03em;
  color: var(--ink); text-decoration: none;
}
.jump a:hover { border-color: var(--red); color: var(--red); }
.process { display: grid; gap: 0; background: var(--white); border: 1px solid var(--line); scroll-margin-top: 16px; }
.process img, .process video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; background: var(--ink); }
.clip-wrap { position: relative; } /* added by site.js: holds a clip plus a poster copy on top (no black flash on iPhone) */
.clip-wrap .clip-cover { position: absolute; inset: 0; width: 100%; height: 100%; aspect-ratio: auto; object-fit: cover;
  pointer-events: none; transition: opacity .4s ease; }
.clip-wrap.is-ready .clip-cover { opacity: 0; }
.process-body { padding: 24px; border-top: 4px solid var(--red); }
.process-body ul { margin: 0; }
.process--text .process-body { border-top: 0; border-left: 4px solid var(--red); }
.cert { border: 1px solid var(--line); background: var(--white); padding: 12px; max-width: 360px; }
.check-list { list-style: none; padding: 0; }
.check-list li { padding-left: 1.5em; position: relative; margin-bottom: .4em; }
.check-list li::before { content: ""; position: absolute; left: 0; top: .55em; width: .65em; height: .65em; background: var(--red); }
.act-cards .card { border-top: 4px solid var(--red); }
.act-letter {
  display: block; font-family: "Barlow Condensed", Arial, sans-serif; font-weight: 800;
  font-size: 4.5rem; line-height: 1; color: var(--red); margin-bottom: 8px;
}

/* ---------- About: milestones ---------- */
.timeline { list-style: none; margin: 0; padding: 0 0 0 28px; border-left: 3px solid var(--line); }
.timeline li { position: relative; padding-bottom: 24px; }
.timeline li::before { content: ""; position: absolute; left: -36px; top: 6px; width: 13px; height: 13px; background: var(--red); transform: rotate(45deg); }
.timeline .year { display: block; font-family: "Barlow Condensed", Arial, sans-serif; font-weight: 800; font-size: 1.5rem; line-height: 1.2; color: var(--red); }

/* ---------- Contact ---------- */
.map-embed { width: 100%; height: 380px; border: 1px solid var(--line); display: block; }
.contact-big { font-size: 1.5rem; font-weight: 700; }
/* Contact page: message form with the contact details box beside it.
   Phones: details box first (tap to call), form below. Wide screens: form left, box right. */
.contact-layout { display: grid; gap: 0 48px; grid-template-columns: 1fr; margin-top: 32px; }
.contact-form { border: 0; display: block; margin-top: 16px; }
.contact-info { border-top: 6px solid var(--red); font-size: 1.15rem; margin-bottom: 40px; }
.contact-info h2 { font-size: 1.5rem; font-weight: 700; margin: 0 0 .3em; }
.contact-info h2:not(:first-child) { border-top: 1px solid var(--line); padding-top: 24px; margin-top: 24px; }
.contact-info .contact-big { font-size: 2rem; margin-bottom: .3em; }
@media (min-width: 960px) {
  .contact-layout { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); align-items: start; }
  /* Heading and text on top left; form below it; details box beside the form (its top lines up with the form) */
  .contact-intro { grid-column: 1; grid-row: 1; }
  .contact-form { grid-column: 1; grid-row: 2; }
  /* The details box follows along while the visitor scrolls down the long form */
  .contact-info { grid-column: 2; grid-row: 2; margin: 16px 0 0; padding: 36px; position: sticky; top: 24px; }
}

/* ---------- Long text (policies) ---------- */
.prose { max-width: 46em; }
.policy h3 { font-family: "Barlow Condensed", Arial, sans-serif; font-size: 1.4rem; font-weight: 700; margin: 1.6em 0 .4em; text-transform: uppercase; }
.policy h4 { font-size: 1.05rem; margin: 1.2em 0 .3em; }
.policy { padding: 40px 0; border-top: 1px solid var(--line); scroll-margin-top: 16px; }
.policy:first-of-type { border-top: 0; }
.download { display: inline-block; font-weight: 700; padding: 10px 16px; border: 2px solid var(--red); text-decoration: none; }
.download::before { content: "PDF  "; font-size: .8em; letter-spacing: .08em; }

/* ---------- Footer ---------- */
.site-footer { background: var(--charcoal); color: #e4e4e4; font-size: 1rem; }
.site-footer a { color: var(--white); }
.site-footer .container { display: grid; gap: 28px; grid-template-columns: 1fr; padding-top: 40px; padding-bottom: 24px; }
.site-footer h2 { font-size: 1.25rem; color: var(--white); border-top: 3px solid var(--spark); padding-top: 8px; display: inline-block; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer address { font-style: normal; }
.footer-bottom { border-top: 1px solid #44474b; font-size: .9rem; color: #b9b9b9; }
.footer-bottom .container { display: block; padding-top: 14px; padding-bottom: 14px; }

/* ---------- Wider screens ---------- */
@media (min-width: 640px) {
  .grid--2 { grid-template-columns: repeat(2, 1fr); }
  .grid--3, .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .stats { grid-template-columns: repeat(4, 1fr); }
  .process { grid-template-columns: 2fr 3fr; }
  .process img { height: 100%; aspect-ratio: auto; }
  .process video { height: 100%; min-height: 260px; aspect-ratio: auto; }
  .process .clip-wrap { height: 100%; }
  .process-body { border-top: 0; border-left: 4px solid var(--red); }
  .process--text { grid-template-columns: 1fr; }
  .site-footer .container { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 960px) {
  .section { padding: 80px 0; }
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
  .grid--4 { grid-template-columns: repeat(4, 1fr); }
  .grid--about { grid-template-columns: 2fr 1fr; gap: 48px; }
  .about-intro { grid-template-columns: 1fr 1fr; gap: 48px; }
  .about-intro .photo-feature { justify-self: end; }
  .stats--stack { grid-template-columns: 1fr !important; position: sticky; top: 24px; }
  .hero .container { padding-top: 120px; padding-bottom: 120px; }
  .logo img { width: 200px; }
}
