/* ---------- Design tokens: change a value here, it changes everywhere ---------- */
:root {
  --navy: #033C5A;
  --text: #1a1a1a;
  --muted: #5c6670;
  --line: #e3e6e9;
  --tint: #f4f7f9;
  --white: #ffffff;

  --font: "Schibsted Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;

  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 2rem;
  --space-4: 4rem;

  --measure: 40rem;  /* width of reading text */
  --wide: 64rem;     /* width of overall page */
}

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

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.125rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--white);
}

h1, h2, h3 {
  color: var(--navy);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 var(--space-2);
}
h1 { font-size: clamp(2.25rem, 5vw + 1rem, 3.75rem); }
h2 { font-size: clamp(1.5rem, 2vw + 1rem, 2rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 var(--space-2); }

a { color: var(--navy); text-underline-offset: 0.2em; }
a:hover { text-decoration-thickness: 2px; }
a:focus-visible { outline: 3px solid var(--navy); outline-offset: 3px; }

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

/* ---------- Layout helpers ---------- */
.container { width: min(var(--wide), 100% - 3rem); margin-inline: auto; }
.prose { max-width: var(--measure); }
.section { padding-block: var(--space-4); }
.section--tint { background: var(--tint); }

/* ---------- Header ---------- */
.site-header { border-bottom: 1px solid var(--line); }
.site-header__inner {
  display: flex; flex-wrap: wrap; justify-content: space-between;
  align-items: center; gap: var(--space-2); padding-block: var(--space-2);
}
.site-name { font-weight: 700; color: var(--navy); text-decoration: none; letter-spacing: -0.01em; }
.nav { display: flex; gap: var(--space-3); list-style: none; margin: 0; padding: 0; }
.nav a { color: var(--text); font-weight: 500; text-decoration: none; }
.nav a:hover { color: var(--navy); text-decoration: underline; text-underline-offset: 0.3em; }

/* ---------- Hero ---------- */
.hero { display: grid; gap: var(--space-3); align-items: center; }
.hero__photo { width: 100%; max-width: 18rem; aspect-ratio: 1; object-fit: cover; }
.lead { font-size: 1.35rem; }
@media (min-width: 48rem) {
  .hero { grid-template-columns: 14rem 1fr; gap: var(--space-4); }
  .hero__photo { width: 100%; }
}

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding-block: var(--space-3); color: var(--muted); font-size: 0.95rem; }

/* ---------- Writing ---------- */
.post-list { list-style: none; margin: var(--space-4) 0 0; padding: 0; max-width: var(--measure); }
.post { padding-block: var(--space-3); border-top: 1px solid var(--line); }
.post h2 { margin-bottom: 0.25rem; }
.post h2 a { text-decoration: none; }
.post h2 a:hover { text-decoration: underline; }
.post-meta { color: var(--muted); font-size: 0.95rem; margin-bottom: var(--space-2); }
.post-meta a { color: var(--muted); }
article h2 { margin-top: var(--space-3); }

/* ---------- About ---------- */
.experience-list { list-style: none; margin: 0; padding: 0; }
.experience-list > li + li { margin-top: var(--space-3); }
.experience-tasks { margin: 0; padding-left: 1.25rem; }