@font-face {
  font-family: "Schibsted Grotesk";
  src: url("/fonts/schibsted-grotesk-latin-wght-normal.woff2") format("woff2-variations");
  font-weight: 400 900;
  font-display: swap;
}
@font-face {
  font-family: "Literata";
  src: url("/fonts/literata-latin-wght-normal.woff2") format("woff2-variations");
  font-weight: 200 900;
  font-display: swap;
}
@font-face {
  font-family: "Literata";
  src: url("/fonts/literata-latin-wght-italic.woff2") format("woff2-variations");
  font-weight: 200 900;
  font-style: italic;
  font-display: swap;
}

:root {
  --paper: #f5f6f3;
  --ink: #1d2228;
  --ink-2: #505862;
  --rule: #d3d8d2;
  --green: #2f7a4d;
  --blue: #2a55a3;
  --red: #b23a2e;
  --gold: #a87a1c;
  --sans: "Schibsted Grotesk", system-ui, sans-serif;
  --serif: "Literata", Georgia, serif;
  --measure: 66ch;
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --wide: 76rem;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.65;
  font-optical-sizing: auto;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 2px; }

.skip { position: absolute; left: -999px; }
.skip:focus { left: var(--gutter); top: 0.75rem; background: var(--ink); color: var(--paper); padding: 0.4rem 0.8rem; z-index: 10; }

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

/* Header */
.site-head { padding: 1.5rem 0; }
.site-head .wrap { display: flex; justify-content: space-between; align-items: baseline; gap: 1.5rem; flex-wrap: wrap; }
.wordmark { font-family: var(--sans); font-weight: 700; font-size: 1.05rem; text-decoration: none; letter-spacing: -0.01em; }
.nav { display: flex; gap: 1.5rem; font-family: var(--sans); font-size: 0.95rem; }
.nav a { text-decoration: none; color: var(--ink-2); }
.nav a:hover, .nav a[aria-current] { color: var(--ink); text-decoration: underline; }

/* Headings */
h1, h2, h3 { font-family: var(--sans); line-height: 1.1; letter-spacing: -0.02em; margin: 0; }
.section-title { font-size: clamp(1.6rem, 3vw, 2.1rem); font-weight: 700; margin-bottom: 2rem; }

/* Hero */
.hero { padding: clamp(3rem, 9vw, 7rem) 0 clamp(2.5rem, 6vw, 4.5rem); }
.hero h1 { font-size: clamp(3rem, 9vw, 6.75rem); font-weight: 800; letter-spacing: -0.045em; line-height: 0.95; }
.lede { font-size: clamp(1.25rem, 2.2vw, 1.6rem); line-height: 1.45; max-width: 34em; margin: 1.75rem 0 0; color: var(--ink); }

/* Bead chain */
.chain { margin-top: clamp(3rem, 7vw, 5rem); }
.chain-list { list-style: none; margin: 0; padding: 0; display: flex; gap: 0; }
.link { flex: var(--n) 1 0; min-width: 0; padding-right: 1rem; }
.beads { display: flex; gap: 6px; align-items: center; height: 26px; position: relative; }
.beads::before { content: ""; position: absolute; left: 0; right: -1rem; top: 50%; height: 1px; background: var(--rule); z-index: 0; }
.link:last-child .beads::before { right: 0; }
.bead { width: 22px; height: 22px; border-radius: 50%; background: var(--c); position: relative; z-index: 1;
  box-shadow: inset -3px -4px 0 rgba(0,0,0,0.16), inset 3px 3px 0 rgba(255,255,255,0.22); }
.link-meta { margin-top: 1rem; font-family: var(--sans); font-size: 0.86rem; line-height: 1.35; padding-right: 0.5rem; }
.link-meta .m-org { font-weight: 700; display: block; }
.link-meta .m-role, .link-meta .m-yrs { color: var(--ink-2); display: block; }
.link-meta .m-fact { display: block; margin-top: 0.5rem; font-weight: 600; color: var(--c); }
.legend { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; margin-top: 2rem; font-family: var(--sans); font-size: 0.85rem; color: var(--ink-2); }
.legend span { display: inline-flex; align-items: center; gap: 0.45rem; }
.legend i { width: 11px; height: 11px; border-radius: 50%; background: var(--c); display: inline-block; }

@media (prefers-reduced-motion: no-preference) {
  .js .bead { animation: string 420ms cubic-bezier(.2,.7,.3,1) both; animation-delay: calc(var(--i) * 55ms + 150ms); }
  @keyframes string { from { opacity: 0; transform: translateX(-14px) scale(.6); } to { opacity: 1; transform: none; } }
}

@media (max-width: 760px) {
  .chain-list { flex-direction: column; gap: 1.25rem; }
  .link { display: grid; grid-template-columns: 9.5rem 1fr; gap: 1rem; align-items: start; padding: 0; }
  .beads { flex-wrap: wrap; height: auto; gap: 5px; padding-top: 0.15rem; }
  .beads::before { display: none; }
  .bead { width: 16px; height: 16px; }
  .link-meta { margin-top: 0; }
}

/* Sections */
section.block { padding: clamp(3rem, 7vw, 5.5rem) 0; border-top: 1px solid var(--rule); }

/* About */
.about-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: clamp(1.5rem, 4vw, 4rem); }
.about-grid .prose p:first-child { margin-top: 0; }

@media (max-width: 760px) { .about-grid { grid-template-columns: 1fr; } .portrait { max-width: 18rem; } }

.prose { max-width: var(--measure); }
.prose p { margin: 0 0 1.1em; }
.prose h2 { font-size: 1.3rem; font-weight: 700; margin: 2.4em 0 0.7em; }

/* Work index */
.work-list { list-style: none; margin: 0; padding: 0; }
.work-item a { display: grid; grid-template-columns: 1.5rem minmax(0, 1.4fr) minmax(0, 2fr) auto; gap: 1rem 1.5rem; align-items: baseline;
  padding: 1.5rem 0; border-bottom: 1px solid var(--rule); text-decoration: none; }
.work-item:first-child a { border-top: 1px solid var(--rule); }
.work-item .dot { width: 12px; height: 12px; border-radius: 50%; background: var(--c); transform: translateY(-1px); }
.work-item h3 { font-size: clamp(1.2rem, 2vw, 1.45rem); font-weight: 700; }
.work-item p { margin: 0; color: var(--ink-2); font-size: 1rem; }
.work-item .yrs { font-family: var(--sans); font-size: 0.9rem; color: var(--ink-2); white-space: nowrap; }
.work-item a:hover h3 { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 0.15em; }
@media (max-width: 760px) {
  .work-item a { grid-template-columns: 1.25rem 1fr; }
  .work-item p, .work-item .yrs { grid-column: 2; }
}

/* Experience */
.roles { list-style: none; padding: 0; margin: 0; }
.role { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 1rem clamp(1.5rem, 4vw, 4rem); padding: 2rem 0; border-bottom: 1px solid var(--rule); }
.role:first-child { padding-top: 0; }
.role-head h3 { font-size: 1.25rem; font-weight: 700; display: flex; gap: 0.6rem; align-items: baseline; }
.role-head h3::before { content: ""; flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--c); transform: translateY(-2px); }
.role-head .r { font-family: var(--sans); margin: 0.35rem 0 0 1.05rem; }
.role-head .d { font-family: var(--sans); font-size: 0.9rem; color: var(--ink-2); margin: 0.2rem 0 0 1.05rem; }
.role-body { max-width: var(--measure); }
.role-body .about { margin: 0 0 0.75rem; color: var(--ink-2); font-style: italic; }
.role-body ul { margin: 0; padding-left: 1.1rem; }
.role-body li { margin-bottom: 0.45rem; }
.role-body li::marker { color: var(--ink-2); }
.role-body .more { display: inline-block; margin-top: 0.75rem; font-family: var(--sans); font-size: 0.95rem; }
@media (max-width: 760px) { .role { grid-template-columns: 1fr; } }

.creds { margin-top: 3rem; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 1rem clamp(1.5rem, 4vw, 4rem); }
.creds h3 { font-size: 1.25rem; }
.creds ul { list-style: none; padding: 0; margin: 0; }
.creds li { padding: 0.15rem 0; }
@media (max-width: 760px) { .creds { grid-template-columns: 1fr; } }

/* Media */
.media-list { list-style: none; padding: 0; margin: 0; max-width: 56rem; }
.media-list li { display: grid; grid-template-columns: 6.5rem minmax(0, 1fr) auto; gap: 0.25rem 1.5rem; padding: 1rem 0; border-bottom: 1px solid var(--rule); align-items: baseline; }
.media-list .k { font-family: var(--sans); font-size: 0.88rem; color: var(--ink-2); }
.media-list .w { display: block; font-family: var(--sans); font-size: 0.88rem; color: var(--ink-2); }
.media-list .y { font-family: var(--sans); font-size: 0.88rem; color: var(--ink-2); }
@media (max-width: 760px) { .media-list li { grid-template-columns: 1fr auto; } .media-list .k { grid-column: 1 / -1; } }

.video { aspect-ratio: 16 / 9; width: 100%; max-width: 36rem; margin-bottom: 1rem; background: #000; }
.video iframe { width: 100%; height: 100%; border: 0; }
.video-btn { all: unset; cursor: pointer; display: grid; place-items: center; width: 100%; height: 100%; position: relative; color: #fff; font-family: var(--sans); }
.video-btn img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0.75; }
.video-btn span { position: relative; background: var(--ink); padding: 0.75rem 1.25rem; font-weight: 600; }
.video-btn:focus-visible span { outline: 2px solid #fff; outline-offset: 3px; }

/* Contact */
.contact-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 1.5rem clamp(1.5rem, 4vw, 4rem); }
.contact-grid .note { color: var(--ink-2); max-width: 26em; }
form { max-width: 40rem; display: grid; gap: 1.25rem; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
label { display: grid; gap: 0.35rem; font-family: var(--sans); font-size: 0.92rem; font-weight: 600; }
input, select, textarea { font: inherit; font-family: var(--serif); font-weight: 400; font-size: 1.05rem; color: var(--ink);
  background: #fff; border: 1px solid #b9c0b8; border-radius: 3px; padding: 0.65rem 0.75rem; width: 100%; }
textarea { min-height: 9rem; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--blue); outline-offset: 0; border-color: var(--blue); }
button[type="submit"] { justify-self: start; font-family: var(--sans); font-weight: 700; font-size: 1rem; background: var(--ink); color: var(--paper);
  border: 0; border-radius: 3px; padding: 0.85rem 1.4rem; cursor: pointer; }
button[type="submit"]:hover { background: var(--blue); }
.hp { position: absolute; left: -9999px; }
@media (max-width: 760px) { .contact-grid, .row2 { grid-template-columns: 1fr; } }

/* Case study */
.cs-head { padding: clamp(2.5rem, 7vw, 5rem) 0 2.5rem; }
.cs-head .back { font-family: var(--sans); font-size: 0.95rem; color: var(--ink-2); }
.cs-head h1 { font-size: clamp(2.4rem, 6vw, 4.5rem); font-weight: 800; letter-spacing: -0.04em; line-height: 1; margin-top: 1.5rem; max-width: 14em; }
.cs-head .short { font-size: clamp(1.15rem, 2vw, 1.4rem); max-width: 34em; margin: 1.25rem 0 0; color: var(--ink-2); }
.cs-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 2rem clamp(1.5rem, 4vw, 4rem); padding: 2.5rem 0 5rem; border-top: 1px solid var(--rule); }
.facts { font-family: var(--sans); font-size: 0.95rem; margin: 0; }
.facts dt { color: var(--ink-2); margin-top: 1rem; }
.facts dt:first-child { margin-top: 0; }
.facts dd { margin: 0.15rem 0 0; }
.facts .sw { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--c); margin-right: 0.45rem; }
.cs-links { margin-top: 3rem; }
.cs-links h2 { margin-top: 0; }
.cs-links ul { list-style: none; padding: 0; margin: 0; }
.cs-links li { padding: 0.7rem 0; border-bottom: 1px solid var(--rule); }
.cs-links .src { display: block; font-family: var(--sans); font-size: 0.88rem; color: var(--ink-2); }
.next { border-top: 1px solid var(--rule); padding: 2.5rem 0 4rem; font-family: var(--sans); }
.next a { font-weight: 700; font-size: 1.2rem; }
@media (max-width: 760px) { .cs-body { grid-template-columns: 1fr; } }

/* Footer */
.site-foot { border-top: 1px solid var(--rule); padding: 2rem 0 3rem; font-family: var(--sans); font-size: 0.9rem; color: var(--ink-2); }
.site-foot .wrap { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.site-foot a { color: var(--ink-2); }

/* Thanks */
.thanks { padding: clamp(4rem, 12vw, 9rem) 0; }
.thanks h1 { font-size: clamp(2.4rem, 6vw, 4rem); font-weight: 800; letter-spacing: -0.04em; }
.thanks p { max-width: 32em; }

/* How I lead */
.prose .coda { font-family: var(--sans); font-weight: 700; font-size: 1.25rem; letter-spacing: -0.01em; margin-top: 1.6em; }

/* Experience additions */
.role-head .sec { font-family: var(--sans); font-size: 0.85rem; color: var(--c); font-weight: 600; margin: 0.5rem 0 0 1.05rem; }
.role-head .site { display: inline-block; font-family: var(--sans); font-size: 0.9rem; margin: 0.35rem 0 0 1.05rem; color: var(--ink-2); }
.role-body .entities { margin: 0.9rem 0 0; font-size: 1rem; }
.role-body .entities span { font-family: var(--sans); font-weight: 600; font-size: 0.9rem; }
.role-body .cases { margin: 0.9rem 0 0; display: grid; gap: 0.35rem; font-family: var(--sans); font-size: 0.95rem; font-weight: 600; }

/* In the news */
.news-group { margin-top: 2.75rem; }
.ng-head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding-bottom: 0.75rem; border-bottom: 2px solid var(--c); }
.ng-head h3 { font-size: 1.2rem; display: flex; align-items: center; gap: 0.55rem; }
.ng-head h3 i { width: 14px; height: 14px; border-radius: 50%; background: var(--c); display: inline-block;
  box-shadow: inset -2px -3px 0 rgba(0,0,0,0.16), inset 2px 2px 0 rgba(255,255,255,0.22); }
.ng-head .n { font-weight: 500; color: var(--ink-2); font-size: 0.95rem; }
.ng-ctrl { display: flex; gap: 0.4rem; }
.ng-ctrl button { font: inherit; font-family: var(--sans); font-size: 1.3rem; line-height: 1; width: 2.25rem; height: 2.25rem; border-radius: 50%;
  border: 1px solid #b9c0b8; background: transparent; color: var(--ink); cursor: pointer; }
.ng-ctrl button:hover { background: var(--c); border-color: var(--c); color: #fff; }
.ng-ctrl button:disabled { opacity: 0.35; cursor: default; background: transparent; color: var(--ink); border-color: #b9c0b8; }
.rail { list-style: none; margin: 0; padding: 1.25rem 0 0.5rem; display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 3rem) / 3);
  gap: 1.5rem; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: thin; overscroll-behavior-x: contain; }
.rail li { scroll-snap-align: start; }
.rail a { display: grid; gap: 0.45rem; text-decoration: none; padding-right: 0.5rem; }
.rail .src { font-family: var(--sans); font-size: 0.86rem; color: var(--ink-2); }
.rail .t { font-size: 1.05rem; line-height: 1.4; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.18em; text-decoration-color: color-mix(in srgb, var(--ink) 35%, transparent); }
.rail a:hover .t { text-decoration-color: var(--c); text-decoration-thickness: 2px; }
.news-group .empty { color: var(--ink-2); padding-top: 1rem; margin: 0; max-width: 40em; }
@media (max-width: 900px) { .rail { grid-auto-columns: calc((100% - 1.5rem) / 2); } }
@media (max-width: 560px) { .rail { grid-auto-columns: 82%; } }
@media (prefers-reduced-motion: no-preference) { .rail { scroll-behavior: smooth; } }
.cs-video { margin-bottom: 2rem; }

/* Portraits */
.portrait { display: block; margin-top: 2rem; max-width: 22rem; }
.portrait img { width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; background: #e3e7e1; border-radius: 2px; }
.portrait-sm { max-width: 15rem; margin-top: 2.5rem; }
@media (max-width: 760px) { .portrait { max-width: 16rem; margin-top: 1.25rem; } .portrait-sm { display: none; } }
