/* Heijdens Performance Engineering — brand colours taken from the logo artwork. */
:root {
  --navy: #1a323f;
  --navy-deep: #12242e;
  --yellow: #fae42a;
  --blue: #0080c6;

  --bg: #f3f5f7;
  --surface: #ffffff;
  --text: #1a323f;
  --muted: #4d6170;
  --line: #d9e0e5;
  --link: #0068a3;

  --slant: -10deg; /* matches the slant of the logo mark */
  --wrap: 68rem;
  --gutter: clamp(1rem, 5vw, 3rem);

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1d25;
    --surface: #16293a;
    --text: #e8eef2;
    --muted: #9fb2bf;
    --line: #26404f;
    --link: #5cb8ea;
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --bg: #0f1d25;
  --surface: #16293a;
  --text: #e8eef2;
  --muted: #9fb2bf;
  --line: #26404f;
  --link: #5cb8ea;
  color-scheme: dark;
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--link);
  text-underline-offset: 0.2em;
}

a:focus-visible,
.btn:focus-visible {
  outline: 3px solid var(--yellow);
  outline-offset: 3px;
}

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

.skip {
  position: absolute;
  left: -999px;
}

.skip:focus {
  left: 1rem;
  top: 1rem;
  z-index: 10;
  background: var(--yellow);
  color: var(--navy);
  padding: 0.5rem 1rem;
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  background: var(--navy);
  color: #fff;
  padding: clamp(2rem, 5vw, 3rem) 0 clamp(4rem, 10vw, 7rem);
}

/* Slanted bars echoing the logo mark; only on wide screens where they clear the text */
.hero::before,
.hero::after {
  content: none;
  position: absolute;
  top: -10%;
  bottom: -10%;
  transform: skewX(var(--slant));
  pointer-events: none;
}

.hero::before {
  right: -4rem;
  width: clamp(5rem, 14vw, 12rem);
  background: var(--blue);
  opacity: 0.22;
}

.hero::after {
  right: clamp(3rem, 13vw, 11rem);
  width: clamp(0.5rem, 1.4vw, 1.1rem);
  background: var(--yellow);
}

@media (min-width: 64rem) {
  .hero::before,
  .hero::after {
    content: "";
  }
}

.hero .wrap {
  position: relative;
  z-index: 1;
}

.hero__logo {
  width: clamp(14rem, 40vw, 20rem);
  margin-bottom: clamp(3rem, 9vw, 6rem);
}

.eyebrow {
  margin: 0 0 1rem;
  text-wrap: balance;
  font-size: 0.8125rem;
  font-weight: 700;
  font-style: italic;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--yellow);
}

.hero h1 {
  max-width: 24ch;
  text-wrap: balance;
  margin: 0 0 1.5rem;
  font-size: clamp(2.25rem, 6.5vw, 4rem);
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.lede {
  max-width: 38rem;
  margin: 0 0 2.5rem;
  font-size: clamp(1.0625rem, 2vw, 1.25rem);
  color: #c9d6de;
}

.cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
}

.cta__mail {
  display: inline-flex;
}

/* Icon tile, slanted like the logo mark */
.cta__icon {
  box-sizing: content-box;
  flex: none;
  padding: 0.95rem; /* same height as .btn */
  color: var(--yellow);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 0.3rem;
  transform: skewX(var(--slant));
  transition: border-color 0.15s ease;
}

.cta__mail:hover .cta__icon {
  border-color: var(--yellow);
}

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

.btn {
  display: inline-block;
  position: relative;
  padding: 0.85rem 1.9rem;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.02em;
  color: var(--navy);
  text-decoration: none;
  isolation: isolate;
}

.btn::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--yellow);
  border-radius: 0.3rem;
  transform: skewX(var(--slant));
  transition: transform 0.15s ease, background-color 0.15s ease;
}

.btn:hover::before {
  background: #fff176;
  transform: skewX(var(--slant)) translateX(3px);
}

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

.section {
  padding: clamp(3.5rem, 9vw, 6rem) 0;
}

.section + .section {
  border-top: 1px solid var(--line);
}

.section__label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0 0 2rem;
  font-size: 0.8125rem;
  font-weight: 700;
  font-style: italic;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.section__label::before {
  content: "";
  width: 1.25rem;
  height: 0.75rem;
  background: var(--yellow);
  border-radius: 2px;
  transform: skewX(var(--slant));
}

.services {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.service {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 0.5rem;
  padding: 1.75rem 1.5rem;
}

.service__num {
  display: block;
  margin-bottom: 1rem;
  font-size: 0.875rem;
  font-weight: 800;
  font-style: italic;
  color: var(--link);
}

.service h3 {
  margin: 0 0 0.5rem;
  font-size: 1.25rem;
  line-height: 1.3;
}

.service p {
  margin: 0;
  color: var(--muted);
}

.contact {
  display: grid;
  gap: 1.5rem 3rem;
  align-items: end;
}

@media (min-width: 48rem) {
  .contact {
    grid-template-columns: 1.4fr 1fr;
  }
}

.contact h2 {
  margin: 0 0 1rem;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
}

.contact p {
  max-width: 36rem;
  margin: 0;
  color: var(--muted);
}

.contact .btn {
  justify-self: start;
}

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

.footer {
  background: var(--navy-deep);
  color: #b4c3cd;
  font-size: 0.9375rem;
  padding: 2.5rem 0;
}

.footer .wrap {
  display: grid;
  gap: 1.5rem 3rem;
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
}

.footer strong {
  display: block;
  color: #fff;
  margin-bottom: 0.25rem;
}

.footer address {
  font-style: normal;
}

.footer a {
  color: #fff;
}

.footer dl {
  margin: 0;
}

.footer dt {
  display: inline;
}

.footer dd {
  display: inline;
  margin: 0;
}

/* ---------- 404 ---------- */

.notfound {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.notfound .hero__logo {
  margin-bottom: 3rem;
}

@media (prefers-reduced-motion: reduce) {
  .btn::before,
  .cta__icon {
    transition: none;
  }
}
