/* Van der Have Engineering: colours and fonts from the logo (#77). */

@font-face {
  font-family: "Source Sans 3";
  src: url("../fonts/source-sans-3-regular.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("../fonts/source-sans-3-italic.woff") format("woff");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("../fonts/source-sans-3-semibold.woff") format("woff");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("../fonts/jetbrains-mono-regular.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink: #1B2430;
  --ground: #FBFBFA;
  --muted: #4A5568;
  --rule: #DDE1E6;
  --accent: #C2650F;      /* logo voxel; decoration only (3.9:1 on the ground) */
  --accent-text: #A0520B; /* accent for text and links (5.4:1) */
  --max-width: 52rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #E8EBEF;
    --ground: #141A22;
    --muted: #A9B3C0;
    --rule: #2C3542;
    --accent-text: #E08A3C;
  }
}

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

html { font-size: 100%; }

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: "Source Sans 3", "Source Sans Pro", system-ui, sans-serif;
  font-size: 1.125rem;
  line-height: 1.6;
}

code, pre { font-family: "JetBrains Mono", ui-monospace, monospace; font-size: 0.9em; }

a { color: var(--accent-text); text-underline-offset: 0.15em; }
a:hover { color: var(--ink); }

h1, h2, h3 { font-weight: 600; line-height: 1.2; }
h1 { font-size: 2.25rem; margin: 0 0 1rem; }
h2 { font-size: 1.5rem; margin: 2.5rem 0 0.75rem; }
h3 { font-size: 1.2rem; margin: 1.75rem 0 0.5rem; }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 1rem; }

/* Header */
.site-header { border-bottom: 1px solid var(--rule); }
.header-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  padding-top: 1rem;
  padding-bottom: 1rem;
}
.brand { display: flex; align-items: center; gap: 0.75rem; color: var(--ink); text-decoration: none; }
.brand-name { font-weight: 600; font-size: 1.2rem; }
.logo-mark { width: 2.25rem; height: 2.25rem; flex: none; }
.logo-ink { fill: var(--ink); }
.logo-accent { fill: var(--accent); }

.menu { display: flex; flex-wrap: wrap; gap: 0.25rem 1.5rem; margin: 0; padding: 0; list-style: none; }
.menu a { color: var(--ink); text-decoration: none; padding: 0.5rem 0; display: inline-block; }
.menu a:hover, .menu a[aria-current="page"] { color: var(--accent-text); }
.menu a[aria-current="page"] { text-decoration: underline; text-decoration-thickness: 2px; }

/* Content */
main { padding-top: 2.5rem; padding-bottom: 4rem; }
.hero { padding: 1rem 0 1.5rem; display: flex; align-items: center; gap: 2rem; }
.hero-text { flex: 1; }
.hero-logo { flex: none; width: 15rem; height: auto; }
.hero h1 { font-size: 2.75rem; }
.tagline { font-size: 1.35rem; color: var(--muted); margin: 0; }

.card-list { list-style: none; padding: 0; display: grid; gap: 1rem; }
.card { border: 1px solid var(--rule); border-radius: 6px; padding: 1rem 1.25rem; }
.card h2 { margin: 0 0 0.25rem; font-size: 1.25rem; }
.card p { margin: 0; color: var(--muted); }

/* Footer */
.site-footer { border-top: 1px solid var(--rule); color: var(--muted); font-size: 0.95rem; }
.footer-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0 2rem; padding-top: 1rem; padding-bottom: 1rem; }
.footer-row p { margin: 0.25rem 0; }

@media (max-width: 40rem) {
  body { font-size: 1.0625rem; }
  h1, .hero h1 { font-size: 2rem; }
  .hero { flex-direction: column-reverse; align-items: flex-start; gap: 1rem; }
  .hero-logo { width: 10rem; }
}
