/* Self-hosted fonts (SIL Open Font License, see assets/fonts/LICENSE-fonts.txt) */

@font-face {
  font-family: "Newsreader";
  src: url("assets/fonts/newsreader-latin-var.woff2") format("woff2");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Newsreader";
  src: url("assets/fonts/newsreader-latin-var-italic.woff2") format("woff2");
  font-weight: 400 700;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Inter Tight";
  src: url("assets/fonts/inter-tight-latin-400-600.woff2") format("woff2");
  font-weight: 400 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter Tight";
  src: url("assets/fonts/inter-tight-latin-400-italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

/* Palette: ink and paper — near-white ground, near-black ink, and terracotta
   kept scarce: italic serif accent words, scribbles, rules. */

:root {
  --paper: #fafaf7;
  --paper-raised: #f0efe9;
  --ink: #15171f;
  --terra: #a0583a;
  --terra-deep: #87462e;
  --muted: #54575f;
  --rule: rgb(21 23 31 / 0.14);
  --field-stroke: rgb(21 23 31 / 0.3);
  /* Ink band */
  --night-text: #f0ede5;
  --night-muted: #aeb1bc;
  --night-rule: rgb(240 237 229 / 0.18);
  --night-terra: #d18e6d;
  --display: "Bricolage Grotesque", system-ui, -apple-system, sans-serif;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --text: "Inter Tight", system-ui, -apple-system, "Segoe UI", sans-serif;
  --gutter: clamp(1.25rem, 4vw, 3.5rem);
  --measure: 66ch;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 5rem;
  -webkit-text-size-adjust: 100%;
  scrollbar-color: rgb(28 32 48 / 0.35) var(--paper);
  accent-color: var(--terra-deep);
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--text);
  font-size: clamp(1.03rem, 0.3vw + 0.97rem, 1.125rem);
  line-height: 1.6;
  overflow-x: clip;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--terra);
  color: #fff;
}

a {
  color: var(--terra-deep);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}
a:hover {
  color: var(--ink);
}
:focus-visible {
  outline: 2px solid var(--terra-deep);
  outline-offset: 3px;
  border-radius: 4px;
}

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

h1,
h2,
h3 {
  font-family: var(--display);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.03em;
  text-wrap: balance;
  margin: 0;
}
h1,
.section-head h2,
.band-title {
  font-weight: 800;
}

.skip {
  position: absolute;
  left: -999px;
}
.skip:focus {
  left: var(--gutter);
  top: 1rem;
  background: var(--paper-raised);
  padding: 0.5rem 1rem;
  z-index: 10;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.wrap {
  width: 100%;
  max-width: 76rem;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* Accent word: terracotta serif italic inside the grotesque headline.
   The hero one also gets the hand-drawn stroke underneath. */

em.accent {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 500;
  font-size: 1.04em;
  color: var(--terra-deep);
  position: relative;
  white-space: nowrap;
}
.scribble {
  position: absolute;
  left: -2%;
  bottom: -0.12em;
  width: 104%;
  height: 0.26em;
  overflow: visible;
  pointer-events: none;
  color: var(--terra);
}
.scribble path {
  fill: none;
  stroke: currentColor;
  stroke-width: 3;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
}
.draw-ready .scribble path {
  stroke-dashoffset: 1;
  transition: stroke-dashoffset 1.1s var(--ease-expo) 0.25s;
}
.draw-ready .scribble.drawn path {
  stroke-dashoffset: 0;
}

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 6;
  background: var(--paper);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease-out);
}
.site-header.scrolled {
  border-bottom-color: var(--rule);
}
.site-header .wrap {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1.5rem;
  padding-top: 1.2rem;
  padding-bottom: 1.2rem;
}
.name {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.2rem;
  letter-spacing: -0.02em;
  color: var(--ink);
  text-decoration: none;
}
.site-nav {
  display: flex;
  gap: clamp(1rem, 2.5vw, 2rem);
  font-size: 0.98rem;
}
.site-nav {
  flex-wrap: wrap;
}
.site-nav a {
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}
.site-nav a:hover {
  color: var(--terra-deep);
}

/* Buttons */

.button {
  display: inline-block;
  font-family: var(--text);
  font-size: 1rem;
  font-weight: 600;
  color: var(--paper);
  background: var(--ink);
  border: 1px solid var(--ink);
  padding: 0.85rem 1.5rem;
  border-radius: 999px;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s var(--ease-out), color 0.2s var(--ease-out), transform 0.16s var(--ease-out);
}
.button:hover {
  background: var(--terra-deep);
  border-color: var(--terra-deep);
  color: #fff;
}
.button:active {
  transform: scale(0.97);
}
.button--quiet {
  color: var(--ink);
  background: transparent;
  border-color: var(--field-stroke);
}
.button--quiet:hover {
  color: var(--ink);
  background: transparent;
  border-color: var(--ink);
}

/* Hero: the work leads. Portrait on an ink field that bleeds to the right edge. */

.hero {
  border-bottom: 1px solid var(--rule);
}
.hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr);
  gap: 0 clamp(2rem, 5vw, 5rem);
  align-items: stretch;
}
.hero-copy {
  padding: clamp(2.5rem, 7vh, 5rem) 0 clamp(2.5rem, 7vh, 4.5rem);
  max-width: 34em;
}
.kicker-rule {
  display: block;
  width: 3.25rem;
  height: 3px;
  background: var(--terra);
  margin-bottom: clamp(1.25rem, 3vh, 2rem);
  transform-origin: left center;
}
.hero h1 {
  font-size: clamp(2.4rem, 5.2vw, 4.5rem);
  line-height: 1;
  letter-spacing: -0.035em;
}
.hero .line {
  display: block;
  overflow: hidden;
  padding-bottom: 0.08em;
  margin-bottom: -0.08em;
}
.hero .line-inner {
  display: block;
}
.hero .lede {
  margin: 1.5rem 0 2rem;
  color: var(--muted);
  max-width: 48ch;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}
.hero-media {
  position: relative;
  min-height: 26rem;
}
.hero-media img {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(108%, 30rem);
  max-width: none;
}

/* Hero entrance: one orchestrated moment, finished by ~1.2s */

@media (prefers-reduced-motion: no-preference) {
  .hero .line-inner {
    transform: translateY(112%);
    animation: rise 0.85s var(--ease-expo) forwards;
  }
  .hero .line:nth-child(2) .line-inner {
    animation-delay: 0.1s;
  }
  .kicker-rule {
    transform: scaleX(0);
    animation: grow-x 0.7s var(--ease-expo) 0.05s forwards;
  }
  .hero .lede,
  .hero-actions {
    opacity: 0;
    transform: translateY(14px);
    animation: fade-rise 0.7s var(--ease-out) 0.4s forwards;
  }
  .hero-actions {
    animation-delay: 0.5s;
  }
  .hero-media img {
    opacity: 0;
    transform: translate(-50%, 20px);
    animation: portrait-in 0.9s var(--ease-expo) 0.3s forwards;
  }
  .draw-ready .hero .scribble path {
    transition-delay: 0.9s;
  }
}
@keyframes rise {
  to {
    transform: translateY(0);
  }
}
@keyframes grow-x {
  to {
    transform: scaleX(1);
  }
}
@keyframes fade-rise {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes portrait-in {
  to {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

/* Simple page intro (thanks page) */

.intro {
  padding: clamp(2.5rem, 9vh, 5.5rem) 0;
}
.intro h1 {
  font-size: clamp(2.1rem, 4vw, 3.4rem);
  margin-bottom: 1.25rem;
}

/* What I do: six capabilities, each with a hand-drawn doodle that draws itself */

.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(2rem, 5vh, 3rem) clamp(2rem, 4vw, 3.5rem);
  list-style: none;
  margin: 0;
  padding: 0;
}
.skill {
  transition: transform 0.25s var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .skill:hover {
    transform: translateY(-3px);
  }
}
.doodle {
  display: block;
  width: 3.6rem;
  height: 2rem;
  overflow: visible;
  color: var(--terra);
  margin-bottom: 0.85rem;
}
.doodle path {
  fill: none;
  stroke: currentColor;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
}
.draw-ready .doodle path {
  stroke-dashoffset: 1;
  transition: stroke-dashoffset 0.9s var(--ease-expo) 0.1s;
}
.draw-ready .doodle.drawn path {
  stroke-dashoffset: 0;
}
.skill h3 {
  font-size: 1.3rem;
  letter-spacing: -0.02em;
  margin-bottom: 0.4rem;
}
.skill p {
  margin: 0;
  color: var(--muted);
  font-size: 0.98rem;
  max-width: 34ch;
}

/* Logos */

.logos {
  background: var(--paper-raised);
  border-bottom: 1px solid var(--rule);
  padding: 1.75rem 0 1.5rem;
}
.logos-title {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--muted);
  margin: 0 0 1.25rem;
}
.logo-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem 2rem;
}
.logo-list img {
  height: 1.55rem;
  width: auto;
  max-width: 6.75rem;
  object-fit: contain;
  filter: brightness(0);
  opacity: 0.68;
  transition: opacity 0.3s var(--ease-out);
}
.logo-list img.tall {
  height: 2.1rem;
}
.logo-list img.wide {
  height: 2.4rem;
  max-width: 7.5rem;
}
.logo-list li:hover img {
  opacity: 1;
}
.logo-text {
  font-weight: 600;
  font-size: 0.95rem;
  opacity: 0.8;
}
.logos-note {
  margin: 1.25rem 0 0;
  font-size: 0.92rem;
  color: var(--muted);
}

/* Statement, with the tangle that clears: the one signature interaction */

.statement {
  padding: clamp(4.5rem, 12vh, 8rem) 0 clamp(3.5rem, 9vh, 6rem);
}
.statement-lead {
  margin: 0;
  max-width: 26em;
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(1.6rem, 2.7vw + 0.6rem, 2.8rem);
  line-height: 1.16;
  letter-spacing: -0.025em;
  text-wrap: pretty;
}
.statement-lead em.accent {
  color: var(--terra-deep);
}
.thread-band {
  margin: clamp(1.5rem, 4vh, 2.5rem) 0 0;
}
.thread {
  display: block;
  width: 100%;
  height: clamp(5rem, 12vw, 8.5rem);
  overflow: visible;
}
.thread path {
  fill: none;
  stroke: var(--terra);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}
.thread-hint {
  margin: 0.25rem 0 0;
  font-size: 0.9rem;
  color: var(--muted);
  font-style: italic;
  font-family: var(--serif);
}
.statement-body {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 46ch));
  gap: 0 clamp(2rem, 5vw, 4.5rem);
  margin-top: clamp(1.75rem, 4.5vh, 2.5rem);
}
.statement-follow {
  margin: 0;
  font-size: clamp(1.08rem, 0.5vw + 1rem, 1.28rem);
  color: var(--muted);
}

/* Strip: Currently */

.strip {
  border-top: 1px solid var(--rule);
  padding: clamp(2rem, 5vh, 3rem) 0;
}
.strip-grid {
  display: grid;
  grid-template-columns: 12rem minmax(0, 1fr);
  gap: 1rem 2rem;
  align-items: baseline;
}
.strip-title {
  font-size: 1.45rem;
  letter-spacing: -0.01em;
}
.now {
  list-style: none;
  margin: 0;
  padding: 0;
}
.now li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.5rem 2rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--rule);
}
.now li:last-child {
  border-bottom: 0;
}
.now .status {
  flex: none;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--terra-deep);
  border: 1px solid rgb(160 88 58 / 0.45);
  padding: 0.15rem 0.65rem;
  border-radius: 999px;
}

/* Sections */

.section {
  padding: clamp(4.5rem, 11vh, 7.5rem) 0;
  border-top: 1px solid var(--rule);
}
.section-head {
  max-width: var(--measure);
  margin-bottom: clamp(2.5rem, 6vh, 4rem);
}
.section-head h2 {
  font-size: clamp(2.3rem, 3.4vw + 0.8rem, 3.8rem);
  line-height: 1.02;
}
.section-head p {
  margin: 1.5rem 0 0;
}
.subhead {
  font-size: clamp(1.5rem, 1vw + 1.2rem, 1.9rem);
  margin: clamp(3.5rem, 8vh, 5rem) 0 1.5rem;
}
.section--record {
  border-top: 0;
}
.section--record .subhead:first-child {
  margin-top: 0;
}

/* Case studies */

.cases {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--rule);
}
.case {
  border-bottom: 1px solid var(--rule);
}
.case summary {
  list-style: none;
  cursor: pointer;
  display: grid;
  grid-template-columns: 7rem minmax(0, 1fr) auto;
  gap: 0.4rem 1.75rem;
  align-items: center;
  padding: 1.75rem 0;
}
.case summary h3,
.case summary .meta {
  grid-column: 2;
}
.case summary .artifact {
  grid-column: 1;
  grid-row: 1 / span 2;
  align-self: center;
  width: 100%;
  margin: 0;
}
.case summary::-webkit-details-marker {
  display: none;
}
.case h3 {
  font-size: clamp(1.45rem, 1vw + 1.1rem, 1.9rem);
  letter-spacing: -0.012em;
  line-height: 1.12;
  transition: color 0.25s var(--ease-out);
}
.case summary:hover h3 {
  color: var(--terra-deep);
}
.case .meta {
  color: var(--muted);
  font-size: 0.98rem;
  max-width: 64ch;
}
.case .toggle {
  grid-column: 3;
  grid-row: 1 / span 2;
  align-self: center;
  position: relative;
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid var(--field-stroke);
  border-radius: 50%;
  transition: background-color 0.3s var(--ease-out), border-color 0.3s var(--ease-out);
}
.case summary:hover .toggle {
  border-color: var(--ink);
}
.case[open] .toggle {
  background: var(--ink);
  border-color: var(--ink);
}
.case .toggle::before,
.case .toggle::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 0.9rem;
  height: 1.5px;
  margin: -0.75px 0 0 -0.45rem;
  background: var(--ink);
  transition: transform 0.35s var(--ease-out), background-color 0.3s;
}
.case .toggle::after {
  transform: rotate(90deg);
}
.case[open] .toggle::before,
.case[open] .toggle::after {
  background: var(--paper);
}
.case[open] .toggle::after {
  transform: rotate(0deg);
}
.case-body {
  max-width: var(--measure);
  padding-bottom: 2.25rem;
}

/* Case artifacts: a static hand-sketched abstract of the work, visible in the list */

.artifact svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}
.artifact path {
  fill: none;
  stroke: var(--ink);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}
.artifact path.t {
  stroke: var(--terra);
  stroke-width: 2.5;
}

/* Quotes band: a drawn quotation mark, in the night terracotta */

.doodle--quote {
  width: 3.4rem;
  height: 2.4rem;
  margin-bottom: 1rem;
}
.band--ink .doodle {
  color: var(--night-terra);
}
.case-body .rule {
  display: block;
  width: 3rem;
  height: 3px;
  background: var(--terra);
  margin-bottom: 1.5rem;
  transform-origin: left center;
}
.case-body h4 {
  font-family: var(--serif);
  font-weight: 500;
  font-style: italic;
  font-size: 1.15rem;
  letter-spacing: 0;
  color: var(--terra-deep);
  margin: 1.5rem 0 0.35rem;
}
.case-body h4:first-of-type {
  margin-top: 0;
}
.case-body p {
  margin: 0;
}

/* Bands */

.band--ink {
  background: var(--ink);
  color: var(--night-text);
  border-top: 0;
  padding: clamp(4.5rem, 11vh, 7.5rem) 0;
  --muted: var(--night-muted);
  --rule: var(--night-rule);
  --field-stroke: rgb(240 237 229 / 0.3);
}
.band--ink ::selection {
  background: var(--night-terra);
  color: var(--ink);
}
.band--ink a {
  color: var(--night-terra);
}
.band--ink a:hover {
  color: var(--night-text);
}
.band--ink :focus-visible {
  outline-color: var(--night-terra);
}
.band--ink em.accent,
.band--ink .scribble {
  color: var(--night-terra);
}
.band--raised {
  background: var(--paper-raised);
}
.band-title {
  font-size: clamp(2rem, 2.6vw + 1rem, 3.1rem);
  margin-bottom: clamp(2rem, 5vh, 3rem);
}

/* Quotes */

.quotes {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 clamp(2rem, 5vw, 4rem);
}
.quote {
  margin: 0;
  padding: 1.75rem 0 2.25rem;
  border-top: 1px solid var(--rule);
}
.quote blockquote {
  margin: 0;
}
.quote blockquote p {
  margin: 0;
  font-family: var(--serif);
  font-weight: 450;
  font-size: clamp(1.2rem, 0.5vw + 1.05rem, 1.45rem);
  line-height: 1.42;
  letter-spacing: 0;
}
.quote figcaption {
  margin-top: 1rem;
  font-size: 0.92rem;
  color: var(--muted);
}
.source-note {
  margin: 1rem 0 0;
  font-size: 0.92rem;
  color: var(--muted);
}

/* Experience */

.timeline {
  list-style: none;
  margin: 0;
  padding: 0;
}
.timeline li {
  display: grid;
  grid-template-columns: 9.5rem minmax(0, 1fr);
  gap: 0.25rem 2rem;
  padding: 1.4rem 0;
  border-top: 1px solid var(--rule);
}
.timeline li:last-child {
  border-bottom: 1px solid var(--rule);
}
.timeline .when {
  color: var(--muted);
  font-variant-numeric: tabular-nums lining-nums;
  font-size: 0.95rem;
  font-weight: 500;
  padding-top: 0.15rem;
}
.timeline .what strong {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}
.timeline .role {
  color: var(--muted);
}
.timeline .what p {
  margin: 0.5rem 0 0;
  max-width: 64ch;
}
.timeline .lesson {
  color: var(--muted);
}
.timeline .lesson span {
  font-style: italic;
  font-family: var(--serif);
  font-size: 1.08em;
  color: var(--terra-deep);
}

.plain-list {
  list-style: none;
  margin: 0;
  padding: 0;
  max-width: var(--measure);
}
.plain-list li {
  padding: 0.95rem 0;
  border-top: 1px solid var(--rule);
}
.plain-list li:last-child {
  border-bottom: 1px solid var(--rule);
}
.plain-list a {
  color: var(--ink);
  font-weight: 500;
  text-decoration-color: var(--field-stroke);
  transition: color 0.2s var(--ease-out), text-decoration-color 0.2s var(--ease-out);
}
.plain-list a:hover {
  color: var(--terra-deep);
  text-decoration-color: currentColor;
}
.plain-list .muted {
  display: block;
  color: var(--muted);
  font-size: 0.95rem;
}

/* Exploring */

.exploring-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}
.exploring-body p {
  margin: 0 0 1.25rem;
}
.exploring-body p:last-child {
  margin-bottom: 0;
}
.posts {
  list-style: none;
  margin: 0;
  padding: 0;
}
.posts li {
  padding: 1.15rem 0;
  border-top: 1px solid var(--rule);
}
.posts li:last-child {
  border-bottom: 1px solid var(--rule);
}
.posts a {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(1.15rem, 0.6vw + 0.95rem, 1.35rem);
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--ink);
  text-decoration: none;
}
.posts a:hover {
  color: var(--terra-deep);
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
}
.posts .date {
  display: block;
  color: var(--muted);
  font-size: 0.92rem;
  margin-top: 0.3rem;
}
.more {
  margin-top: 1.25rem;
  font-weight: 600;
}
.subscribe {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 2rem;
  max-width: 28rem;
}
.subscribe input {
  flex: 1;
  min-width: 12rem;
}
.subscribe-note {
  margin: 0.6rem 0 0;
  font-size: 0.85rem;
  color: var(--muted);
}

/* Contact */

.contact .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
  gap: clamp(2.5rem, 6vw, 6rem);
  align-items: start;
}
.contact .section-head {
  margin-bottom: 0;
}
.elsewhere {
  margin-top: 2rem;
}
.form {
  display: grid;
  gap: 1.35rem;
}
.field {
  display: grid;
  gap: 0.4rem;
}
.field label,
.field legend {
  font-size: 0.95rem;
  font-weight: 600;
}
.field .optional {
  font-weight: 400;
  color: var(--muted);
}
input[type="text"],
input[type="email"],
textarea {
  font: inherit;
  color: var(--ink);
  background: var(--paper-raised);
  border: 1px solid var(--field-stroke);
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
  width: 100%;
  caret-color: var(--terra);
  transition: border-color 0.2s var(--ease-out), background-color 0.2s var(--ease-out);
}
input:hover,
textarea:hover {
  border-color: rgb(28 32 48 / 0.5);
}
input:focus,
textarea:focus {
  outline: 2px solid var(--terra-deep);
  outline-offset: 1px;
}
textarea {
  min-height: 9rem;
  resize: vertical;
}
fieldset.field {
  border: 0;
  margin: 0;
  padding: 0;
}
.choices {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.4rem;
}
.choices label {
  font-weight: 400;
  position: relative;
}
.choices input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.choices span {
  display: inline-block;
  padding: 0.5rem 1rem;
  border: 1px solid var(--field-stroke);
  border-radius: 999px;
  cursor: pointer;
  transition: background-color 0.2s var(--ease-out), color 0.2s var(--ease-out), border-color 0.2s var(--ease-out);
}
.choices span:hover {
  border-color: currentColor;
}
.choices input:focus-visible + span {
  outline: 2px solid var(--terra-deep);
  outline-offset: 2px;
}
.hidden-field {
  position: absolute;
  left: -9999px;
}
.privacy {
  font-size: 0.9rem;
  color: var(--muted);
  margin: 0;
  max-width: 60ch;
}

/* Form on the ink band */

.band--ink input[type="text"],
.band--ink input[type="email"],
.band--ink textarea {
  color: var(--night-text);
  background: rgb(240 237 229 / 0.06);
  caret-color: var(--night-terra);
}
.band--ink input:hover,
.band--ink textarea:hover {
  border-color: rgb(240 237 229 / 0.6);
}
.band--ink input:focus,
.band--ink textarea:focus {
  outline-color: var(--night-terra);
  background: rgb(240 237 229 / 0.1);
}
.band--ink input:user-invalid,
.band--ink textarea:user-invalid {
  border-color: var(--night-terra);
}
.band--ink .choices input:checked + span {
  background: var(--night-terra);
  border-color: var(--night-terra);
  color: var(--ink);
}
.band--ink .choices input:focus-visible + span {
  outline-color: var(--night-terra);
}
.band--ink .button {
  color: var(--ink);
  background: var(--night-terra);
  border-color: var(--night-terra);
}
.band--ink .button:hover {
  color: var(--ink);
  background: var(--night-text);
  border-color: var(--night-text);
}

/* Footer */

.site-footer {
  background: var(--ink);
  border-top: 1px solid var(--night-rule);
  padding: 2rem 0 2.5rem;
  font-size: 0.9rem;
  color: var(--night-muted);
}
.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 2rem;
}
.site-footer p {
  margin: 0;
}

/* Motion: scroll reveals (JS adds .reveal and .in; hidden state only when both
   JS and motion are available, so nothing can stay invisible) */

@media (prefers-reduced-motion: no-preference) {
  .js-reveal .reveal {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.6s var(--ease-out), transform 0.7s var(--ease-expo);
    transition-delay: calc(var(--d, 0) * 70ms);
  }
  .js-reveal .reveal.in {
    opacity: 1;
    transform: none;
  }
}

/* Case studies open with an eased height, where the browser supports it */

@supports (interpolate-size: allow-keywords) {
  :root {
    interpolate-size: allow-keywords;
  }
  @media (prefers-reduced-motion: no-preference) {
    .case::details-content {
      opacity: 0;
      height: 0;
      overflow: clip;
      transition: height 0.45s var(--ease-expo), opacity 0.3s var(--ease-out), content-visibility 0.45s allow-discrete;
    }
    .case[open]::details-content {
      opacity: 1;
      height: auto;
    }
  }
}

/* Nav: the terracotta underline follows the section you are in */

.site-nav a {
  position: relative;
}
.site-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -4px;
  height: 2px;
  background: var(--terra);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.25s var(--ease-out);
}
.site-nav a.active::after,
.site-nav a:hover::after {
  transform: scaleX(1);
}

/* Drawn ring around the contact accent word */

.scribble--ring {
  left: -7%;
  top: -22%;
  bottom: auto;
  width: 114%;
  height: 144%;
}

/* Beyond work: a hand-drawn frequency wave above the heading */

.doodle--wave {
  width: 5rem;
  margin-bottom: 1rem;
}

/* Footer ends the page with the name at full size */

.site-footer {
  padding-top: clamp(3rem, 8vh, 5rem);
}
.big-name {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2.6rem, 8.5vw, 7rem);
  line-height: 0.95;
  letter-spacing: -0.04em;
  color: var(--night-text);
  margin: 0 0 clamp(2rem, 6vh, 3.5rem);
  text-wrap: balance;
}
.site-footer .wrap {
  display: block;
}
.footer-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  border-top: 1px solid var(--night-rule);
  padding-top: 1.5rem;
}

/* Motion */

@media (prefers-reduced-motion: no-preference) {
  .case[open] .case-body .rule {
    animation: grow-x-soft 0.7s var(--ease-out) both;
  }
}
@keyframes grow-x-soft {
  from {
    transform: scaleX(0.3);
  }
  to {
    transform: scaleX(1);
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after,
  .case::details-content {
    transition: none !important;
    animation: none !important;
  }
}

/* Responsive */

@media (max-width: 54rem) {
  .hero .wrap {
    grid-template-columns: 1fr;
  }
  .hero-copy {
    padding-bottom: clamp(2rem, 5vh, 3rem);
  }
  .hero-media {
    min-height: 0;
    height: 19rem;
  }
  .hero-media img {
    width: min(72%, 18rem);
  }
  .contact .wrap,
  .exploring-grid {
    grid-template-columns: 1fr;
  }
  .skills-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .strip-grid {
    grid-template-columns: 1fr;
  }
  .quotes {
    grid-template-columns: 1fr;
  }
  .statement-body {
    grid-template-columns: minmax(0, 46ch);
    gap: clamp(1.5rem, 4vh, 2.25rem);
  }
}
@media (max-width: 48rem) {
  .site-header .wrap {
    flex-direction: column;
    gap: 0.2rem;
    padding-top: 0.7rem;
    padding-bottom: 0.7rem;
  }
  .site-nav {
    font-size: 0.94rem;
  }
  .logo-list {
    justify-content: flex-start;
    gap: 1.25rem 1.75rem;
  }
}
@media (max-width: 36rem) {
  .timeline li {
    grid-template-columns: 1fr;
  }
  .skills-grid {
    grid-template-columns: 1fr;
  }
  .now li {
    flex-direction: column;
    gap: 0.35rem;
  }
  .case summary {
    grid-template-columns: 5rem minmax(0, 1fr) auto;
    gap: 0.4rem 1rem;
  }
}
