/* ------------------------------------------------------------------
   joern.vehoff.net — stylesheet
   Single file, no build step, no external requests.
   Fonts are system stacks on purpose: no Google Fonts CDN means no
   third-party transfer of visitor IP addresses (GDPR).
   ------------------------------------------------------------------ */

:root {
  --paper:      #fbfbfa;
  --paper-alt:  #f2f3f1;
  --ink:        #16202b;
  --muted:      #5c6772;
  --rule:       #e0e4e2;
  --accent:     #12615f;
  --accent-ink: #0d4a48;
  --accent-bg:  #e9f1f0;

  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;

  --wrap: 62rem;
  --prose: 40rem;
}

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

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: 1.5rem;
}

/* ---------- links ---------- */

a { color: var(--accent-ink); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { color: var(--ink); }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: var(--paper);
  padding: 0.6rem 1rem;
  z-index: 10;
}
.skip:focus { left: 0.5rem; top: 0.5rem; }

/* ---------- header ---------- */

.site-header {
  border-bottom: 1px solid var(--rule);
  background: var(--paper);
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem 2rem;
  padding-block: 1.35rem;
}

.wordmark {
  font-family: var(--serif);
  font-size: 1.3rem;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-decoration: none;
}
.wordmark:hover { color: var(--accent); }

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 1.4rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.94rem;
  padding-block: 0.15rem;
  border-bottom: 1.5px solid transparent;
}
.site-nav a:hover { color: var(--ink); }
.site-nav a[aria-current="page"] {
  color: var(--ink);
  border-bottom-color: var(--accent);
}

/* ---------- main ---------- */

main { flex: 1 0 auto; padding-block: 3.5rem 4.5rem; }

.prose { max-width: var(--prose); }

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.2;
  color: var(--ink);
}

h1 { font-size: clamp(1.9rem, 1.3rem + 2.4vw, 2.85rem); margin: 0 0 0.75rem; }
h2 { font-size: 1.5rem; margin: 3rem 0 1rem; }
h3 { font-size: 1.1rem; margin: 2rem 0 0.35rem; font-family: var(--sans); font-weight: 650; letter-spacing: 0; }

p { margin: 0 0 1.1rem; }
strong { font-weight: 650; }

.eyebrow {
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1rem;
}

.lead { font-size: 1.2rem; line-height: 1.55; color: var(--ink); }
.muted { color: var(--muted); }
.small { font-size: 0.9rem; }

hr.rule {
  border: 0;
  border-top: 1px solid var(--rule);
  margin: 3rem 0;
}

/* ---------- buttons ---------- */

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-top: 2rem;
}

.btn {
  display: inline-block;
  padding: 0.6rem 1.15rem;
  border: 1px solid var(--accent);
  border-radius: 2px;
  font-size: 0.95rem;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-ink); color: #fff; }

.btn-ghost { background: transparent; color: var(--accent-ink); }
.btn-ghost:hover { background: var(--accent-bg); color: var(--accent-ink); }

/* ---------- CV timeline ---------- */

.cv-summary p { max-width: var(--prose); }

.timeline {
  border-left: 2px solid var(--rule);
  padding-left: 1.75rem;
  margin-left: 0.25rem;
}

.role { position: relative; padding-bottom: 2.5rem; }
.role:last-child { padding-bottom: 0; }

.role::before {
  content: "";
  position: absolute;
  left: calc(-1.75rem - 6px);
  top: 0.55rem;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--paper);
  border: 2px solid var(--accent);
}

.role-dates {
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  color: var(--muted);
  display: block;
  margin-bottom: 0.2rem;
}

.role-title {
  font-size: 1.08rem;
  font-weight: 650;
  margin: 0 0 0.15rem;
  line-height: 1.35;
}

.role-org {
  font-size: 0.95rem;
  color: var(--muted);
  margin: 0 0 0.8rem;
}

.role ul {
  margin: 0;
  padding-left: 1.15rem;
  max-width: var(--prose);
}
.role li { margin-bottom: 0.4rem; }
.role li::marker { color: var(--accent); }

.award {
  display: inline-block;
  background: var(--accent-bg);
  color: var(--accent-ink);
  font-size: 0.82rem;
  padding: 0.15rem 0.5rem;
  border-radius: 2px;
}

/* ---------- fact list (education, languages) ---------- */

.facts { max-width: var(--prose); }
.facts dt { font-weight: 650; margin-top: 1.4rem; }
.facts dd { margin: 0.2rem 0 0; color: var(--muted); }

/* ---------- blog ---------- */

.post-list { list-style: none; margin: 0; padding: 0; max-width: var(--prose); }

.post-item {
  padding-block: 1.6rem;
  border-bottom: 1px solid var(--rule);
}
.post-item:first-child { padding-top: 0; }

.post-item h2 {
  font-family: var(--sans);
  font-size: 1.2rem;
  font-weight: 650;
  letter-spacing: 0;
  margin: 0.35rem 0 0.4rem;
}
.post-item h2 a { text-decoration: none; }
.post-item h2 a:hover { text-decoration: underline; }

.post-meta {
  font-family: var(--mono);
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.post-body { max-width: var(--prose); }
.post-body h2 { font-size: 1.25rem; }

/* ---------- contact ---------- */

.contact-list {
  list-style: none;
  margin: 1.5rem 0 0;
  padding: 0;
  max-width: var(--prose);
}
.contact-list li {
  display: flex;
  gap: 1rem;
  padding-block: 0.55rem;
  border-bottom: 1px solid var(--rule);
}
.contact-list .label {
  font-family: var(--mono);
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  min-width: 7rem;
  padding-top: 0.2rem;
}

/* ---------- legal pages ---------- */

.legal { max-width: var(--prose); }
.legal h2 { font-size: 1.2rem; font-family: var(--sans); font-weight: 650; letter-spacing: 0; }
.legal h3 { font-size: 1rem; }

.todo {
  background: #fff8e1;
  border-left: 3px solid #c9911f;
  padding: 0.9rem 1.1rem;
  margin: 1.5rem 0;
  font-size: 0.92rem;
}
.todo p:last-child { margin-bottom: 0; }

/* ---------- footer ---------- */

.site-footer {
  border-top: 1px solid var(--rule);
  background: var(--paper-alt);
  padding-block: 1.6rem;
  font-size: 0.88rem;
  color: var(--muted);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  justify-content: space-between;
  align-items: center;
}

.footer-inner p { margin: 0; }

.footer-inner ul {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.footer-inner a { color: var(--muted); text-decoration: none; }
.footer-inner a:hover { color: var(--ink); text-decoration: underline; }

/* ---------- responsive & motion ---------- */

@media (max-width: 34rem) {
  body { font-size: 1rem; }
  main { padding-block: 2.5rem 3rem; }
  .timeline { padding-left: 1.25rem; }
  .role::before { left: calc(-1.25rem - 6px); }
  .contact-list li { flex-direction: column; gap: 0.1rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

@media print {
  .site-header, .site-footer, .actions, .skip { display: none; }
  body { font-size: 11pt; }
  a { color: inherit; text-decoration: none; }
  .role { page-break-inside: avoid; }
}

/* ---------- background image ---------- */
/* The URL is relative to this stylesheet, so it works from every page depth. */

body {
  background-image:
    linear-gradient(rgba(251, 251, 250, 0.90), rgba(251, 251, 250, 0.90)),
    url("background.jpg");
  background-size: cover;
  background-position: center center;
  background-attachment: fixed;
  background-repeat: no-repeat;
}

.site-header { background: rgba(251, 251, 250, 0.72); backdrop-filter: blur(8px); }
.site-footer { background: rgba(242, 243, 241, 0.72); backdrop-filter: blur(8px); }

@media (max-width: 48rem) {
  body { background-attachment: scroll; }
}

@media print {
  body { background-image: none; }
}
