:root {
  color-scheme: dark;
  --ink: #f6f4ee;
  --muted: #c6c0b7;
  --quiet: #918b83;
  --paper: #090909;
  --graphite: #101010;
  --panel: rgba(22, 21, 20, 0.82);
  --panel-solid: #171615;
  --line: rgba(246, 244, 238, 0.13);
  --line-strong: rgba(255, 207, 0, 0.25);
  --accent: #d7342c;
  --accent-deep: #9f211d;
  --accent-soft: #ff6a5f;
  --gold: #ffcf00;
  --gold-soft: #f0c85a;
  --silver: #d8d6cf;
  --shadow: 0 26px 80px rgba(0, 0, 0, 0.42);
  --radius: 8px;
  --max: 1240px;
  --tile-overlap: 24px;
  --font-main: Bahnschrift, "Aptos", "Segoe UI", ui-sans-serif, system-ui, sans-serif;
  --font-technical: Bahnschrift, "Arial Narrow", "Aptos Narrow", "Roboto Condensed", "Segoe UI", ui-sans-serif,
    system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--paper);
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 16% 10%, rgba(255, 207, 0, 0.11), transparent 24rem),
    radial-gradient(circle at 82% 2%, rgba(215, 52, 44, 0.14), transparent 22rem),
    var(--paper);
  color: var(--ink);
  font-family: var(--font-main);
  line-height: 1.5;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(90deg, rgba(255, 207, 0, 0.028) 1px, transparent 1px),
    linear-gradient(0deg, rgba(215, 52, 44, 0.028) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.75), transparent 48rem);
}

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

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: 1rem;
  z-index: 30;
  transform: translateY(-160%);
  background: var(--ink);
  color: var(--paper);
  padding: 0.7rem 1rem;
  border-radius: var(--radius);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  min-height: 112px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 20px;
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 18px clamp(18px, 4vw, 48px);
  border-bottom: 1px solid var(--line);
  background: rgba(9, 9, 9, 0.78);
  backdrop-filter: blur(22px);
}

.brand {
  grid-column: 2;
  justify-self: center;
  display: inline-flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}

.brand-mark {
  width: clamp(52px, 5vw, 76px);
  height: clamp(52px, 5vw, 76px);
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: var(--radius);
  transform: translateY(-4px);
}

.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 0 18px rgba(255, 207, 0, 0.22));
}

.brand-copy {
  display: flex;
  align-items: center;
  line-height: 0.9;
}

.brand-name {
  color: #fffaf1;
  font-family: var(--font-technical);
  font-size: clamp(2rem, 4.2vw, 4.1rem);
  font-stretch: 78%;
  font-weight: 760;
  line-height: 0.9;
  letter-spacing: 0;
  text-shadow: 0 10px 34px rgba(0, 0, 0, 0.4);
}

.menu-control {
  grid-column: 3;
  justify-self: end;
  position: relative;
}

.menu-control summary {
  min-width: 132px;
  min-height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  list-style: none;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  color: var(--ink);
  background: rgba(18, 17, 16, 0.62);
  font-family: var(--font-technical);
  font-size: 1rem;
  font-stretch: 82%;
  font-weight: 720;
  cursor: pointer;
  transition:
    background 160ms ease,
    border-color 160ms ease;
}

.menu-control summary::-webkit-details-marker {
  display: none;
}

.menu-control summary:hover,
.menu-control[open] summary {
  border-color: rgba(255, 207, 0, 0.42);
  background: rgba(28, 25, 22, 0.86);
}

.menu-icon {
  width: 24px;
  height: 15px;
  position: relative;
}

.menu-icon::before,
.menu-icon::after {
  content: "";
  position: absolute;
  right: 0;
  width: 100%;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transition:
    transform 160ms ease,
    top 160ms ease;
}

.menu-icon::before {
  top: 2px;
}

.menu-icon::after {
  top: 11px;
}

.menu-control[open] .menu-icon::before {
  top: 7px;
  transform: rotate(38deg);
}

.menu-control[open] .menu-icon::after {
  top: 7px;
  transform: rotate(-38deg);
}

.dropdown-nav {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  width: min(280px, calc(100vw - 32px));
  display: grid;
  gap: 2px;
  padding: 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: rgba(16, 15, 14, 0.95);
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px);
}

.dropdown-nav a {
  display: flex;
  align-items: center;
  min-height: 56px;
  padding: 0 16px;
  border-radius: 6px;
  color: var(--ink);
  font-family: var(--font-technical);
  font-size: 1rem;
  font-stretch: 82%;
  font-weight: 700;
}

.dropdown-nav a:hover {
  background: rgba(215, 52, 44, 0.13);
}

.section-shell {
  width: min(calc(100% - 36px), var(--max));
  margin-inline: auto;
}

#services,
#contact {
  scroll-margin-top: 132px;
}

.hero {
  width: 100%;
  min-height: calc(100svh - 112px);
  display: grid;
  align-items: center;
  margin-top: 0;
  padding: clamp(80px, 9vw, 142px) max(18px, calc((100vw - var(--max)) / 2)) clamp(92px, 9vw, 140px);
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  isolation: isolate;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image: url("/assets/engineering-hero-clean.png");
  background-size: cover;
  background-position: 63% 50%;
  filter: grayscale(0.34) saturate(0.72) brightness(0.68) contrast(1.14);
  transform: scale(1.02);
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(circle at 78% 48%, transparent 0, rgba(9, 9, 9, 0.06) 32%, rgba(9, 9, 9, 0.62) 78%),
    linear-gradient(90deg, rgba(9, 9, 9, 0.97), rgba(9, 9, 9, 0.74) 38%, rgba(9, 9, 9, 0.14) 74%),
    linear-gradient(0deg, rgba(9, 9, 9, 0.76), transparent 38%, rgba(9, 9, 9, 0.42));
}

.hero-copy {
  width: min(760px, 62vw);
  position: relative;
  z-index: 1;
}

.hero-copy::after {
  content: "";
  position: absolute;
  left: -8vw;
  bottom: -130px;
  width: min(680px, 78vw);
  height: 300px;
  pointer-events: none;
  opacity: 0.34;
  background:
    radial-gradient(ellipse at 28% 52%, rgba(255, 207, 0, 0.2), transparent 58%),
    repeating-radial-gradient(ellipse at 20% 45%, rgba(215, 52, 44, 0.34) 0 1px, transparent 1px 15px);
  mask-image: linear-gradient(90deg, #000, transparent);
  transform: rotate(-8deg);
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 14ch;
  margin-bottom: 26px;
  color: #fffaf1;
  font-family: var(--font-technical);
  font-size: clamp(3.2rem, 5.6vw, 5.45rem);
  font-stretch: 76%;
  line-height: 1.02;
  letter-spacing: 0;
  font-weight: 760;
  text-shadow: 0 18px 52px rgba(0, 0, 0, 0.55);
}

.hero-copy p {
  max-width: 56ch;
  margin-bottom: 0;
  color: rgba(246, 244, 238, 0.82);
  font-size: clamp(1.04rem, 1.55vw, 1.33rem);
  line-height: 1.65;
}

.services {
  position: relative;
  z-index: 4;
  margin-top: calc(var(--tile-overlap) * -1);
  margin-bottom: calc(var(--tile-overlap) * -1);
  padding: 0;
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(280px, 0.55fr);
  gap: 28px;
  align-items: end;
  margin-bottom: 34px;
}

h2 {
  max-width: 12ch;
  margin-bottom: 0;
  color: #fffaf1;
  font-family: var(--font-technical);
  font-size: clamp(2.4rem, 4.4vw, 4.4rem);
  font-stretch: 76%;
  line-height: 1.04;
  letter-spacing: 0;
  font-weight: 760;
}

.section-heading p,
.capability-copy p,
.contact-copy p {
  color: var(--muted);
  font-size: 1.04rem;
  margin-bottom: 0;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.service-card,
.process-steps article,
.motion-card,
.contact-form {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(20, 19, 18, 0.76);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.22);
}

.service-card {
  min-height: 450px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 16px;
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 82% 18%, rgba(255, 207, 0, 0.14), transparent 32%),
    radial-gradient(circle at 12% 90%, rgba(215, 52, 44, 0.12), transparent 34%),
    repeating-linear-gradient(90deg, rgba(255, 207, 0, 0.055) 0 1px, transparent 1px 34px);
  opacity: 0.78;
}

.service-card::after {
  content: none;
}

.service-card > * {
  position: relative;
  z-index: 1;
}

.service-card-head {
  display: grid;
  place-items: center;
  min-height: 112px;
}

.service-symbol {
  width: 98px;
  height: 98px;
  display: grid;
  place-items: center;
  color: var(--gold);
  border: none;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, rgba(255, 207, 0, 0.16), transparent 58%),
    radial-gradient(circle at 50% 50%, rgba(215, 52, 44, 0.12), transparent 72%);
}

.service-symbol svg {
  width: 66px;
  height: 66px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.service-card h3,
.process-steps h3 {
  color: var(--ink);
  margin-bottom: 0;
  font-family: var(--font-technical);
  font-size: 1.34rem;
  font-stretch: 78%;
  font-weight: 760;
  line-height: 1.12;
}

.service-card p,
.process-steps p,
.capability-list {
  color: var(--muted);
  margin-bottom: 0;
}

.service-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
  font-size: 0.96rem;
  line-height: 1.45;
}

.service-list li::marker {
  color: var(--gold);
}

.capabilities {
  background:
    radial-gradient(circle at 78% 16%, rgba(255, 207, 0, 0.12), transparent 28rem),
    linear-gradient(180deg, #101010, #151312);
  border-block: 1px solid var(--line);
}

.capability-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.75fr) minmax(420px, 1fr);
  align-items: center;
  gap: clamp(32px, 6vw, 86px);
  min-height: 760px;
  padding: clamp(76px, 10vw, 126px) 0;
}

.capability-copy {
  position: sticky;
  top: 138px;
  align-self: start;
}

.capability-copy h2 {
  margin-bottom: 22px;
}

.capability-list {
  display: grid;
  gap: 12px;
  margin-top: 24px;
  padding-left: 19px;
}

.motion-stage {
  display: grid;
  gap: 18px;
  perspective: 1000px;
}

.motion-card {
  min-height: 172px;
  padding: 24px;
  display: grid;
  align-content: end;
  position: relative;
  overflow: hidden;
}

.motion-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 82% 18%, rgba(255, 207, 0, 0.18), transparent 34%),
    repeating-linear-gradient(90deg, rgba(255, 207, 0, 0.08) 0 1px, transparent 1px 34px),
    repeating-linear-gradient(0deg, rgba(215, 52, 44, 0.06) 0 1px, transparent 1px 34px);
}

.motion-card::after {
  content: "";
  position: absolute;
  width: 230px;
  height: 150px;
  right: 22px;
  top: 22px;
  border: 1px solid rgba(255, 207, 0, 0.34);
  border-radius: var(--radius);
  transform: skewX(-9deg);
}

.motion-card span,
.motion-card strong {
  position: relative;
  z-index: 1;
}

.hero-readout span,
.motion-card span,
.privacy-note {
  color: var(--quiet);
  font-size: 0.77rem;
  font-weight: 760;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.motion-card strong {
  max-width: 390px;
  margin-top: 8px;
  color: var(--ink);
  font-size: clamp(1.3rem, 2.3vw, 2rem);
  line-height: 1.06;
}

.card-product,
.card-medical,
.card-testing,
.card-inspection {
  background: linear-gradient(120deg, rgba(24, 23, 22, 0.92), rgba(12, 12, 12, 0.74));
}

.process-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.process-steps article {
  min-height: 225px;
  padding: 26px;
}

.process-steps span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  margin-bottom: 52px;
  border-radius: 50%;
  background: rgba(255, 207, 0, 0.12);
  color: var(--gold);
  border: 1px solid rgba(255, 207, 0, 0.28);
  font-weight: 780;
}

.contact-section {
  position: relative;
  z-index: 1;
  background:
    radial-gradient(circle at 20% 0%, rgba(215, 52, 44, 0.12), transparent 22rem),
    #080808;
  color: #fff;
  border-top: 1px solid var(--line);
}

.contact-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.78fr) minmax(420px, 1fr);
  gap: clamp(32px, 7vw, 90px);
  padding: clamp(72px, 10vw, 120px) 0;
}

.contact-copy {
  align-self: start;
  position: sticky;
  top: 138px;
}

.contact-copy h2 {
  margin-bottom: 22px;
}

.contact-copy p {
  color: rgba(246, 244, 238, 0.72);
}

.privacy-note {
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  color: rgba(246, 244, 238, 0.58);
  line-height: 1.65;
}

.contact-form {
  padding: clamp(22px, 4vw, 34px);
  color: var(--ink);
  background: rgba(246, 244, 238, 0.97);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.34);
}

.field-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

label {
  display: grid;
  gap: 8px;
  margin-bottom: 14px;
}

label span {
  color: #211f1d;
  font-family: var(--font-technical);
  font-size: 0.86rem;
  font-weight: 740;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid rgba(13, 24, 23, 0.2);
  border-radius: var(--radius);
  background: #fff;
  color: #101816;
  padding: 13px 14px;
  outline: none;
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease;
}

textarea {
  resize: vertical;
  min-height: 150px;
}

label:has(textarea) {
  margin-bottom: 10px;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent-deep);
  box-shadow: 0 0 0 4px rgba(215, 52, 44, 0.14);
}

.honeypot {
  position: absolute;
  left: -100vw;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.cf-turnstile {
  min-height: 70px;
  margin: 4px 0 12px;
}

.cf-turnstile[hidden] {
  display: none;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 0 18px;
  font-family: var(--font-technical);
  font-size: 0.92rem;
  font-weight: 760;
  letter-spacing: 0;
  cursor: pointer;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease,
    color 160ms ease;
}

.button-primary {
  background: linear-gradient(180deg, var(--accent), var(--accent-deep));
  color: #fff;
  box-shadow: 0 14px 28px rgba(159, 33, 29, 0.24);
}

.button:hover {
  transform: translateY(-1px);
}

.form-submit {
  width: 100%;
}

.form-status {
  min-height: 0;
  margin: 0;
  color: #536260;
  font-size: 0.94rem;
}

.form-status:not(:empty) {
  min-height: 24px;
  margin-top: 14px;
}

.form-status.is-success {
  color: #7a5a00;
}

.form-status.is-error {
  color: #9b2c2c;
}

.site-footer {
  width: min(calc(100% - 36px), var(--max));
  margin: 0 auto;
  min-height: 118px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  color: var(--quiet);
}

.site-footer div {
  display: grid;
  gap: 4px;
}

.site-footer strong {
  color: var(--ink);
  font-family: var(--font-technical);
}

.footer-links {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-links a:hover {
  color: var(--gold);
}

.legal-page {
  background:
    radial-gradient(circle at 18% 0%, rgba(215, 52, 44, 0.12), transparent 24rem),
    var(--paper);
}

.legal-hero {
  padding: clamp(76px, 9vw, 132px) 0 clamp(34px, 5vw, 62px);
}

.legal-hero p {
  margin-bottom: 18px;
  color: var(--gold);
  font-family: var(--font-technical);
  font-size: 0.92rem;
  font-weight: 760;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.legal-hero h1 {
  max-width: 12ch;
  margin-bottom: 0;
}

.legal-content {
  max-width: 860px;
  padding-bottom: clamp(76px, 10vw, 126px);
}

.legal-content h2 {
  max-width: none;
  margin: 42px 0 12px;
  font-size: clamp(1.5rem, 2.6vw, 2.25rem);
}

.legal-content p {
  color: var(--muted);
  font-size: 1.04rem;
  line-height: 1.72;
}

.legal-content a {
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.reveal-enabled [data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity 640ms ease,
    transform 640ms ease;
}

.reveal-enabled [data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 980px) {
  .site-header {
    min-height: 96px;
    grid-template-columns: 1fr auto;
  }

  .brand {
    grid-column: 1;
    justify-self: start;
  }

  .brand-name {
    font-size: clamp(1.65rem, 7vw, 3rem);
  }

  .menu-control {
    grid-column: 2;
  }

  .menu-control summary {
    min-width: 54px;
    padding: 0 16px;
  }

  .menu-control summary span:first-child {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }

  .hero {
    min-height: calc(100svh - 96px);
    padding-block: 72px 90px;
  }

  .hero-copy {
    width: min(720px, 100%);
  }

  .section-heading,
  .capability-layout,
  .contact-layout {
    grid-template-columns: 1fr;
  }

  .service-grid,
  .process-steps {
    grid-template-columns: repeat(2, 1fr);
  }

  .services {
    margin-top: -18px;
    margin-bottom: -18px;
  }

  .capability-copy,
  .contact-copy {
    position: static;
  }
}

@media (max-width: 720px) {
  .site-header {
    padding: 14px 12px;
  }

  .brand {
    gap: 10px;
  }

  .brand-mark {
    width: 46px;
    height: 46px;
    transform: translateY(-2px);
  }

  .brand-name {
    font-size: clamp(1.42rem, 7.4vw, 2.15rem);
  }

  .dropdown-nav {
    right: -2px;
  }

  .section-shell,
  .site-footer {
    width: min(calc(100% - 24px), var(--max));
  }

  .hero {
    min-height: calc(100svh - 88px);
    padding: 54px 12px 74px;
  }

  .hero::before {
    background-position: 64% 48%;
  }

  .hero::after {
    background:
      linear-gradient(90deg, rgba(8, 16, 15, 0.96), rgba(8, 16, 15, 0.72) 58%, rgba(8, 16, 15, 0.22)),
      linear-gradient(0deg, rgba(8, 16, 15, 0.82), transparent 38%, rgba(8, 16, 15, 0.58));
  }

  h1 {
    max-width: 11ch;
    font-size: clamp(2.45rem, 11.6vw, 3.72rem);
  }

  .hero-copy p {
    max-width: 35ch;
    font-size: 1rem;
  }

  .service-grid,
  .process-steps,
  .field-row {
    grid-template-columns: 1fr;
  }

  .services,
  .process {
    padding: 0;
  }

  .services {
    margin-top: -16px;
    margin-bottom: -16px;
  }

  .service-card {
    min-height: 0;
  }

  .capability-layout,
  .contact-layout {
    padding: 76px 0;
  }

  .motion-card {
    min-height: 190px;
  }

  .motion-card::after {
    width: 140px;
    height: 110px;
  }

  .site-footer {
    min-height: 150px;
    align-items: start;
    justify-content: center;
    flex-direction: column;
  }

  .footer-links {
    justify-content: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.001ms !important;
    animation-duration: 0.001ms !important;
  }

  .reveal-enabled [data-reveal] {
    opacity: 1;
    transform: none;
  }
}
