/* =========================================================================
   iQit — Software op maat
   Design tokens and layout per the iQit design handoff.
   No build step: this file is served as authored.
   ========================================================================= */

/* Instrument Sans Variable: self-hosted, no CDN.
   Uncomment when assets/fonts/InstrumentSans-Variable.woff2 is delivered,
   together with the <link rel="preload"> in index.html.

@font-face {
  font-family: "Instrument Sans";
  src: url("../fonts/InstrumentSans-Variable.woff2") format("woff2-variations");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}
*/

/* ---------- Tokens ---------- */
:root {
  /* Ink (navy neutrals) */
  --ink-900: #0c1626;
  --ink-800: #152438;
  --ink-600: #4a5a6f;
  --ink-500: #6b7b90;
  --ink-300: #c3ccd8;
  --ink-200: #dde3ec;
  --ink-100: #e8edf4;
  --ink-050: #f6f8fb;
  --white:   #fff;

  /* Signal blue — CTAs only */
  --blue-900: #22467a;
  --blue-800: #284f8a;
  --blue-600: #2e5c9c;
  --blue-500: #3d74c4;
  --blue-200: #c2d5ef;
  --blue-100: #dde8f8;
  --blue-050: #eef4fc;
  --blue-focus-navy: #a2c0ef;

  /* Copper — accent only */
  --copper-800: #8d4810;
  --copper-600: #a85714;
  --copper-500: #c9721f;
  --copper-050: #f8ecdf;

  /* Feedback */
  --green-600: #1f6b45;
  --green-050: #e2f4ea;
  --red-600:   #9a2a2a;
  --red-050:   #fbe6e6;

  /* Radii */
  --r-input: 6px;
  --r-md: 10px;
  --r-card: 14px;

  /* Navy-tinted shadows, never pure black */
  --shadow-1: 0 1px 2px rgba(12, 22, 38, .06), 0 1px 3px rgba(12, 22, 38, .05);
  --shadow-2: 0 4px 10px rgba(12, 22, 38, .07), 0 2px 4px rgba(12, 22, 38, .05);
  --shadow-3: 0 10px 28px rgba(12, 22, 38, .11), 0 3px 8px rgba(12, 22, 38, .06);

  /* Motion */
  --t-fast: 90ms;
  --t-base: 140ms;
  --t-slow: 200ms;
  --ease: cubic-bezier(.2, .7, .3, 1);

  /* Spacing — 4px scale */
  --s-1: 4px;   --s-2: 8px;   --s-3: 12px;  --s-4: 16px;
  --s-5: 20px;  --s-6: 24px;  --s-8: 32px;  --s-10: 40px;
  --s-12: 48px; --s-16: 64px; --s-20: 80px;

  --container: 1200px;
  --gutter: clamp(20px, 5vw, 40px);
  --section-y: clamp(56px, 8vw, 112px);
  --header-h: 68px;

  --font-sans: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto,
               "Helvetica Neue", Arial, "Noto Sans", sans-serif;
}

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

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

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.62;
  color: var(--ink-800);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  margin: 0;
  font-weight: 600;        /* weight 700 is never used */
  line-height: 1.14;
  letter-spacing: -0.02em;
  color: var(--ink-900);
  text-wrap: balance;
}

p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
address { font-style: normal; }

img, svg { max-width: 100%; }

a { color: var(--blue-800); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--blue-600); }

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

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

.sprite {
  position: absolute;
  width: 0; height: 0;
  overflow: hidden;
}

/* Icons inherit stroke from the sprite symbols' currentColor */
.icon {
  width: 22px; height: 22px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.icon--inline {
  width: 15px; height: 15px;
  margin-left: 6px;
  vertical-align: -1px;
}

/* ---------- Focus ---------- */
:focus-visible {
  outline: 2px solid var(--blue-600);
  outline-offset: 2px;
  border-radius: 3px;
}
.section--navy :focus-visible,
.site-footer :focus-visible {
  outline-color: var(--blue-focus-navy);
}

.skip-link {
  position: absolute;
  left: var(--s-4);
  top: var(--s-4);
  z-index: 100;
  transform: translateY(-200%);
  display: inline-block;
  padding: 12px 18px;
  min-height: 44px;
  background: var(--ink-900);
  color: var(--white);
  font-weight: 500;
  text-decoration: none;
  border-radius: var(--r-md);
  box-shadow: var(--shadow-3);
  transition: transform var(--t-base) var(--ease);
}
.skip-link:focus { transform: translateY(0); color: var(--white); }

main:focus { outline: none; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 11px 22px;
  border: 1px solid transparent;
  border-radius: var(--r-md);
  font: inherit;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color var(--t-base) var(--ease),
              border-color var(--t-base) var(--ease),
              color var(--t-base) var(--ease),
              box-shadow var(--t-base) var(--ease),
              transform var(--t-fast) var(--ease);
}

.btn--primary {
  background: var(--blue-600);
  border-color: var(--blue-600);
  color: var(--white);
  box-shadow: var(--shadow-1);
}
.btn--primary:hover {
  background: var(--blue-800);
  border-color: var(--blue-800);
  color: var(--white);
  box-shadow: var(--shadow-2);
  transform: translateY(-2px);
}
.btn--primary:active { transform: translateY(0); background: var(--blue-900); }

.btn--secondary {
  background: var(--white);
  border-color: var(--ink-300);
  color: var(--ink-900);
}
.btn--secondary:hover {
  border-color: var(--ink-600);
  color: var(--ink-900);
  box-shadow: var(--shadow-2);
  transform: translateY(-2px);
}
.btn--secondary:active { transform: translateY(0); }

.btn--block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--white);
  border-bottom: 1px solid var(--ink-200);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-6);
  min-height: var(--header-h);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--ink-900);
  text-decoration: none;
}
.wordmark:hover { color: var(--ink-900); }
.wordmark__dot { color: var(--copper-600); }

.primary-nav {
  display: flex;
  align-items: center;
  gap: var(--s-8);
}

.primary-nav__list {
  display: flex;
  align-items: center;
  gap: var(--s-6);
}

.primary-nav__list a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 2px;
  font-size: 16px;
  font-weight: 500;
  color: var(--ink-600);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: color var(--t-base) var(--ease), border-color var(--t-base) var(--ease);
}
.primary-nav__list a:hover { color: var(--ink-900); }
.primary-nav__list a[aria-current="true"] {
  color: var(--ink-900);
  border-bottom-color: var(--copper-600);
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 8px 14px 8px 12px;
  background: var(--white);
  border: 1px solid var(--ink-200);
  border-radius: var(--r-md);
  font: inherit;
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-900);
  cursor: pointer;
  transition: border-color var(--t-base) var(--ease);
}
.nav-toggle:hover { border-color: var(--ink-300); }

.nav-toggle__bars {
  display: grid;
  gap: 4px;
  width: 18px;
}
.nav-toggle__bars span {
  display: block;
  height: 2px;
  background: var(--ink-900);
  border-radius: 2px;
  transition: transform var(--t-base) var(--ease), opacity var(--t-fast) var(--ease);
}
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ---------- Sections ---------- */
.section {
  padding-block: var(--section-y);
  scroll-margin-top: calc(var(--header-h) + 8px);
}
.section--tint { background: var(--ink-050); }
.section--navy { background: var(--ink-900); color: var(--ink-200); }
.section--navy .section__title { color: var(--white); }
.section--navy .section__intro { color: var(--ink-300); }

.overline {
  margin-bottom: var(--s-3);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--copper-600);
}
.overline--on-navy { color: var(--copper-500); }

.section__title {
  font-size: clamp(28px, 4vw, 36px);
  max-width: 20ch;
}
.section__intro {
  margin-top: var(--s-4);
  max-width: 66ch;
  color: var(--ink-600);
}

/* ---------- Hero ---------- */
.hero {
  padding-block: clamp(48px, 7vw, 96px) var(--section-y);
  scroll-margin-top: var(--header-h);
}

.hero__grid {
  display: grid;
  gap: clamp(32px, 5vw, 56px);
  align-items: start;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  margin-bottom: var(--s-5);
  background: var(--copper-050);
  color: var(--copper-800);
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
}

.hero__title {
  font-size: clamp(42px, 7.6vw, 76px);
  letter-spacing: -0.035em;
  line-height: 1.02;
}
.accent-dot { color: var(--copper-600); }

.lead {
  margin-top: var(--s-6);
  max-width: 62ch;
  font-size: clamp(17px, 2.2vw, 20px);
  line-height: 1.6;
  color: var(--ink-600);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3);
  margin-top: var(--s-8);
}

.proof {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: var(--s-6);
  margin-top: var(--s-12);
  padding-top: var(--s-8);
  border-top: 1px solid var(--ink-200);
}
.proof__figure {
  display: block;
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--ink-900);
}
.proof__label {
  display: block;
  margin-top: 2px;
  font-size: 15px;
  color: var(--ink-500);
}

/* Hero contact panel */
.contact-panel {
  padding: var(--s-8);
  background: var(--ink-050);
  border: 1px solid var(--ink-200);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-1);
}
.contact-panel__title {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-500);
}
.contact-panel__list {
  display: grid;
  gap: var(--s-4);
  margin-top: var(--s-6);
}
.contact-panel__list li {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  color: var(--ink-600);
}
.contact-panel__list .icon { color: var(--blue-600); }
.contact-panel__list a {
  color: var(--ink-900);
  text-decoration: none;
  font-weight: 500;
}
.contact-panel__list a:hover { text-decoration: underline; }
.contact-panel__phone {
  font-size: 19px;
  font-weight: 600 !important;
  letter-spacing: -0.01em;
}

/* ---------- Cards ---------- */
.card-grid {
  display: grid;
  gap: var(--s-6);
  margin-top: var(--s-12);
}
.card-grid--2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.card-grid--4 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }

.card {
  padding: var(--s-8);
  background: var(--white);
  border: 1px solid var(--ink-200);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-1);
  transition: transform var(--t-slow) var(--ease), box-shadow var(--t-slow) var(--ease),
              border-color var(--t-slow) var(--ease);
}
.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-3);
  border-color: var(--ink-300);
}
.card__icon {
  width: 26px; height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  color: var(--blue-600);
}
.card__title {
  margin-top: var(--s-5);
  font-size: 22px;
}
.card__text {
  margin-top: var(--s-3);
  max-width: 66ch;
  color: var(--ink-600);
}

.card--navy {
  background: var(--ink-800);
  border-color: #24354d;
  box-shadow: none;
}
.card--navy:hover { border-color: #354863; box-shadow: 0 10px 28px rgba(0, 0, 0, .3); }
.card--navy .card__title { color: var(--white); }
.card--navy .card__text { color: var(--ink-300); }
.card--navy .card__icon { color: var(--blue-200); }

/* ---------- Realisaties ---------- */
.work {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--s-6);
  margin-top: var(--s-12);
}
.work__item {
  padding: var(--s-6) var(--s-6) var(--s-8);
  background: var(--white);
  border: 1px solid var(--ink-200);
  border-radius: var(--r-card);
  border-top: 3px solid var(--blue-600);
  transition: transform var(--t-slow) var(--ease), box-shadow var(--t-slow) var(--ease);
}
.work__item:hover { transform: translateY(-2px); box-shadow: var(--shadow-3); }
.work__item--quiet { border-top-color: var(--ink-300); }

.work__name { font-size: 20px; }
.work__name a {
  color: var(--ink-900);
  text-decoration: none;
}
.work__name a:hover { color: var(--blue-800); text-decoration: underline; }
.work__name .icon--inline { color: var(--blue-600); }

.work__text {
  margin-top: var(--s-2);
  max-width: 66ch;
  color: var(--ink-600);
}
.work__meta {
  margin-top: var(--s-4);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-500);
}

/* ---------- Contact ---------- */
.contact__grid {
  display: grid;
  gap: clamp(32px, 5vw, 64px);
  margin-top: var(--s-12);
  align-items: start;
}

.contact__list { display: grid; gap: var(--s-8); }
.contact__list li {
  display: grid;
  grid-template-columns: 22px 1fr;
  gap: 2px var(--s-3);
}
.contact__list .icon { grid-row: span 3; color: var(--blue-600); margin-top: 3px; }
.contact__label {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-500);
}
.contact__list a {
  color: var(--ink-900);
  text-decoration: none;
  font-weight: 500;
  justify-self: start;
}
.contact__list a:hover { text-decoration: underline; }
.contact__phone {
  font-size: 19px;
  font-weight: 600 !important;
  letter-spacing: -0.01em;
}
.contact__hint { font-size: 15px; color: var(--ink-500); }
.contact__list address { color: var(--ink-600); }

/* ---------- Form ---------- */
.form {
  padding: clamp(24px, 4vw, 36px);
  background: var(--white);
  border: 1px solid var(--ink-200);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-2);
}

.field { margin-bottom: var(--s-5); }
.field label {
  display: block;
  margin-bottom: 6px;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink-900);
}
.req { color: var(--copper-600); }

.field input,
.field textarea {
  width: 100%;
  min-height: 44px;
  padding: 11px 13px;
  font: inherit;
  font-size: 16px;
  color: var(--ink-900);
  background: var(--white);
  border: 1px solid var(--ink-300);
  border-radius: var(--r-input);
  transition: border-color var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease);
}
.field textarea { resize: vertical; line-height: 1.55; }

.field input:hover,
.field textarea:hover { border-color: var(--ink-500); }

.field input:focus,
.field textarea:focus {
  border-color: var(--blue-600);
  box-shadow: 0 0 0 3px var(--blue-100);
  outline: none;
}
.field input:focus-visible,
.field textarea:focus-visible { outline: 2px solid var(--blue-600); outline-offset: 1px; }

.field input[aria-invalid="true"],
.field textarea[aria-invalid="true"] { border-color: var(--red-600); background: var(--red-050); }

.field__error {
  margin-top: 6px;
  font-size: 15px;
  font-weight: 500;
  color: var(--red-600);
}

.form__subline {
  margin-top: var(--s-3);
  font-size: 15px;
  color: var(--ink-500);
  text-align: center;
}

.form__status {
  margin-top: var(--s-5);
  padding: var(--s-4);
  border-radius: var(--r-md);
  font-size: 16px;
}
.form__status--ok { background: var(--green-050); color: var(--green-600); }
.form__status--error { background: var(--red-050); color: var(--red-600); }
.form__status a { color: inherit; font-weight: 600; }

.form__note {
  margin-top: var(--s-5);
  padding: var(--s-4);
  background: var(--ink-050);
  border-radius: var(--r-md);
  font-size: 15px;
  color: var(--ink-600);
}

/* Handoff rule: every interactive target is at least 44px high. Links set in
   running prose are exempt; these standalone links are real tap targets, so
   they get the height even though their text is smaller. */
.contact-panel__list a,
.contact__list a,
.site-footer__meta a,
.work__name a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

/* Absorb the added height so the vertical rhythm stays put. */
.contact-panel__list { gap: var(--s-1); }
.contact__list { gap: var(--s-5); }
.site-footer__meta { gap: 0; }

/* ---------- Footer ---------- */
.site-footer {
  padding-block: var(--s-16) var(--s-8);
  background: var(--ink-900);
  color: var(--ink-300);
}
.site-footer__inner {
  display: grid;
  gap: var(--s-10);
  padding-bottom: var(--s-10);
  border-bottom: 1px solid #24354d;
}
.wordmark--footer {
  font-size: 28px;
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--white);
}
.site-footer__line {
  margin-top: var(--s-4);
  max-width: 34ch;
  color: var(--ink-500);
}
.site-footer__meta { display: grid; gap: var(--s-3); }
.site-footer__meta a,
.site-footer__meta address { color: var(--ink-200); text-decoration: none; }
.site-footer__meta a { font-weight: 500; }
.site-footer__meta a:hover { color: var(--white); text-decoration: underline; }

.site-footer__legal {
  margin-top: var(--s-6);
  font-size: 15px;
  color: var(--ink-500);
}

/* =========================================================================
   Responsive
   ========================================================================= */

@media (min-width: 760px) {
  .contact__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); }
  .site-footer__inner {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
  }
  .site-footer__meta { text-align: right; }
}

@media (min-width: 1000px) {
  .hero__grid { grid-template-columns: minmax(0, 1fr) 360px; }
  .contact__grid { grid-template-columns: minmax(0, 380px) minmax(0, 1fr); }
}

/* Realisaties holds four entries. The column count steps 1 -> 2 -> 4 and skips
   three deliberately: at three columns the fourth card sits alone on a last row.
   Four across matches the Troeven row, which the handoff also sets at ~240px. */
@media (min-width: 620px) {
  .work { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 1100px) {
  .work { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* ---------- Mobile navigation ----------
   The collapsing drawer only exists when JS is present (html.js). Without
   JS the nav renders as a plain, always-visible list, so it is never
   unreachable. Closed state uses visibility:hidden so the links leave the
   tab order and the accessibility tree entirely; main.js additionally
   marks the drawer inert. */
@media (max-width: 860px) {
  .js .nav-toggle { display: inline-flex; }

  .js .primary-nav {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    display: block;
    padding: var(--s-4) var(--gutter) var(--s-6);
    background: var(--white);
    border-bottom: 1px solid var(--ink-200);
    box-shadow: var(--shadow-3);

    /* visibility (not opacity/pointer-events) is what takes the links out of
       the tab order and the accessibility tree. It is deliberately NOT
       transitioned: a delayed visibility transition can stay stuck on
       "visible" after an open/close cycle, which would silently restore
       five focusable invisible links. */
    visibility: hidden;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity var(--t-base) var(--ease),
                transform var(--t-base) var(--ease);
  }

  .js .primary-nav.is-open {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
  }

  .js .primary-nav__list { display: block; }
  .js .primary-nav__list a {
    display: flex;
    padding: var(--s-2) 0;
    font-size: 17px;
    border-bottom: none;
  }
  .js .primary-nav__list a[aria-current="true"] { color: var(--blue-800); }
  .js .primary-nav__cta { margin-top: var(--s-4); width: 100%; }

  .site-header__inner { position: relative; }
}

/* Without JS the nav sits under the wordmark as a normal wrapped row. */
@media (max-width: 860px) {
  html:not(.js) .site-header__inner { flex-wrap: wrap; padding-bottom: var(--s-3); }
  html:not(.js) .primary-nav { flex-wrap: wrap; gap: var(--s-4); width: 100%; }
  html:not(.js) .primary-nav__list { flex-wrap: wrap; gap: var(--s-4); }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .btn:hover, .card:hover, .work__item:hover { transform: none; }
  .skip-link { transition: none; }
}
