/* Fraunces (SIL Open Font License), latin subset, self-hosted */
@font-face {
  font-family: Fraunces;
  font-style: normal;
  font-weight: 500 650;
  font-display: swap;
  src: url(fonts/fraunces-latin.woff2) format("woff2");
}

:root {
  --bg: #faf6f0;
  --surface: #ffffff;
  --text: #29241f;
  --muted: #5e564e;
  --accent: #1e6b5f;
  --accent-ink: #ffffff;
  --accent-soft: #e2efeb;
  --line: #e9e1d5;
  --shadow: 0 1px 2px rgb(41 36 31 / 0.05), 0 8px 24px rgb(41 36 31 / 0.06);
  --serif: Fraunces, Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #171513;
    --surface: #211e1b;
    --text: #efe9e1;
    --muted: #b3a99e;
    --accent: #6fc6b3;
    --accent-ink: #10201c;
    --accent-soft: #1d322d;
    --line: #36312b;
    --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 8px 24px rgb(0 0 0 / 0.25);
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 1.0625rem/1.7 var(--sans);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 650;
  line-height: 1.15;
  margin: 0 0 0.5rem;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2.6rem, 9vw, 3.75rem); }
h2 { font-size: clamp(1.7rem, 5vw, 2.1rem); margin-bottom: 1.5rem; }
h3 { font-size: 1.3rem; font-weight: 500; }

a { color: var(--accent); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
a:focus-visible, summary:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

.wrap { width: min(50rem, 100% - 2rem); margin-inline: auto; }

section { padding-block: 2.5rem; }
@media (min-width: 42rem) { section { padding-block: 3.5rem; } }

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--surface);
  padding: 0.5rem 1rem;
  border-radius: 6px;
  z-index: 1;
}
.skip:focus { top: 1rem; }

/* Intro */

.intro {
  padding-block: 4rem 2rem;
  display: grid;
  gap: 1.75rem;
}
@media (min-width: 42rem) {
  .intro { grid-template-columns: auto 1fr; align-items: center; gap: 2.5rem; padding-top: 5.5rem; }
}

.portrait {
  display: block;
  width: 13rem;
  height: auto;
  border-radius: 18px;
  background: var(--line);
  border: 5px solid var(--surface);
  box-shadow: 0 0 0 2px var(--accent-soft), var(--shadow);
}
@media (min-width: 42rem) { .portrait { width: 16rem; } }

.eyebrow {
  margin: 0 0 0.4rem;
  color: var(--accent);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.lede { margin: 0.75rem 0 1.5rem; font-size: 1.125rem; }

.links { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 0.6rem; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.15rem;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font-weight: 600;
  font-size: 0.95rem;
  line-height: 1.2;
  text-decoration: none;
  box-shadow: 0 1px 2px rgb(41 36 31 / 0.06);
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}
.btn-icon {
  width: 1.15rem;
  height: 1.15rem;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.btn:not(.btn-primary) .btn-icon { color: var(--accent); }
.btn:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgb(41 36 31 / 0.12);
}
.btn:active { transform: translateY(0); box-shadow: none; }
.btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { background: var(--accent); filter: brightness(1.1); }
.btn-tag {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  padding: 0.1rem 0.4rem;
  border-radius: 999px;
  border: 1px solid currentColor;
}
@media (max-width: 26rem) {
  .links { display: grid; grid-template-columns: 1fr 1fr; }
  .links li:first-child { grid-column: 1 / -1; }
  .btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .btn, .btn:hover { transition: none; transform: none; }
}

/* Case studies */

.case {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1.5rem 1.25rem;
  margin-bottom: 1.25rem;
  box-shadow: var(--shadow);
}
@media (min-width: 42rem) { .case { padding: 2rem 2.25rem; } }

.case-num {
  margin: 0 0 0.25rem;
  font-family: var(--serif);
  font-size: 0.95rem;
  font-weight: 650;
  color: var(--accent);
}
.case h3 { font-size: 1.4rem; margin-bottom: 1.25rem; }

.case-body dl { margin: 0; display: grid; gap: 0.35rem 1.5rem; }
.case-body dt {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-top: 0.6rem;
}
.case-body dd { margin: 0; }
@media (min-width: 42rem) {
  .case-body dl { grid-template-columns: 8.5rem 1fr; gap: 1rem 1.5rem; }
  .case-body dt { margin-top: 0.3rem; }
}

.case-photos { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; margin-top: 1.25rem; }
@media (min-width: 42rem) { .case-photos { gap: 0.75rem; margin-top: 1.5rem; } }
.case-photos figure { margin: 0; }
.case-photos figcaption { margin-top: 0.4rem; font-size: 0.85rem; line-height: 1.35; color: var(--muted); }
.case-photos img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 8px;
  background: var(--line);
}

.case-next {
  display: inline-block;
  margin-top: 1.25rem;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--accent);
  text-decoration: none;
}
.case-next:hover { text-decoration: underline; text-underline-offset: 0.18em; }
.case[id] { scroll-margin-top: 4rem; }

.handoff { margin: 2rem 0 0; color: var(--muted); }
.handoff a { font-weight: 600; white-space: nowrap; }

.made-it {
  font-family: var(--serif);
  font-style: italic;
  color: var(--accent);
  margin-bottom: 0.25rem !important;
}
@media (prefers-reduced-motion: no-preference) {
  .made-it { animation: made-it-in 0.8s ease both; }
  @keyframes made-it-in { from { opacity: 0; transform: translateY(0.5rem); } }
}

.chips { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 0.4rem; }
.chips li, .chips > span:not(.visually-hidden) {
  background: var(--accent-soft);
  color: var(--text);
  border-radius: 999px;
  padding: 0.15rem 0.7rem;
  font-size: 0.85rem;
}

/* Built cards */

.cards { display: grid; gap: 1rem; }
@media (min-width: 42rem) { .cards { grid-template-columns: repeat(2, 1fr); } }

.card {
  display: block;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1.25rem;
  color: var(--text);
  text-decoration: none;
  box-shadow: var(--shadow);
}
.card:hover { border-color: var(--accent); }
.card h3 { margin-top: 0.75rem; font-size: 1.2rem; }
.card p { margin: 0; color: var(--muted); font-size: 0.95rem; line-height: 1.6; }

.status {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-soft);
  border-radius: 999px;
  padding: 0.15rem 0.6rem;
}
.status-muted { color: var(--muted); background: var(--line); }

/* How I work */

.plain { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.9rem; }
.plain li { position: relative; padding-left: 1.6rem; }
.plain li::before {
  content: "";
  position: absolute;
  left: 0.2rem;
  top: 0.62em;
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: var(--accent);
}

/* Photos */

.photos {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem 0.9rem;
  padding: 0.25rem;
}
@media (min-width: 42rem) {
  .photos { grid-template-columns: repeat(3, 1fr); gap: 1.75rem 1.5rem; padding: 0.5rem; }
}
.photos figure {
  margin: 0;
  background: var(--surface);
  padding: 0.4rem 0.4rem 0.6rem;
  border-radius: 4px;
  box-shadow: var(--shadow);
}
.photos figure:nth-child(1) { transform: rotate(-1.5deg); }
.photos figure:nth-child(2) { transform: rotate(1deg); }
.photos figure:nth-child(3) { transform: rotate(-0.75deg); }
.photos figure:nth-child(4) { transform: rotate(1.25deg); }
.photos figure:nth-child(5) { transform: rotate(-1deg); }
.photos figure:nth-child(6) { transform: rotate(0.75deg); }
.photos img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 2px;
  background: var(--line);
}
.photos figcaption {
  margin-top: 0.5rem;
  font-family: var(--serif);
  font-size: 0.85rem;
  line-height: 1.35;
  text-align: center;
}
@media (min-width: 42rem) {
  .photos figure { padding: 0.6rem 0.6rem 0.9rem; }
  .photos figcaption { margin-top: 0.7rem; font-size: 1rem; line-height: 1.4; }
}

/* Experience */

.timeline { list-style: none; padding: 0; margin: 0 0 1.5rem; border-left: 2px solid var(--line); }
.timeline li { position: relative; padding: 0 0 1.25rem 1.5rem; }
.timeline li::before {
  content: "";
  position: absolute;
  left: -7px;
  top: 0.45em;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--accent);
}
.timeline li:first-child::before { background: var(--accent); }
.when { display: block; font-size: 0.85rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.what { font-weight: 600; }
.org { display: block; font-weight: 400; color: var(--muted); }

/* FAQ */

.faqs { display: grid; gap: 0.6rem; }
details {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 1.25rem;
}
details[open] { box-shadow: var(--shadow); }
summary {
  cursor: pointer;
  list-style: none;
  padding: 1rem 0;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}
summary::-webkit-details-marker { display: none; }
summary::after {
  content: "+";
  flex: none;
  display: grid;
  place-items: center;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 1.1rem;
  line-height: 1;
}
details[open] summary::after { content: "\2212"; }
details p { margin: 0 0 1.1rem; color: var(--muted); }

/* Contact */

.contact {
  text-align: center;
  background: var(--accent-soft);
  border-radius: 18px;
  padding: 2.5rem 1.25rem;
}
.contact h2 { margin-bottom: 0.5rem; }
.contact p { margin: 0.4rem 0; }
.contact-email { font-family: var(--serif); font-size: clamp(1.25rem, 5vw, 1.6rem); margin: 0.75rem 0 1rem !important; }
.contact-email a { text-decoration: none; overflow-wrap: anywhere; }
.contact-email a:hover { text-decoration: underline; }

footer { padding-block: 1rem 3rem; color: var(--muted); font-size: 0.9rem; text-align: center; }
footer p { margin: 0; }

/* Results */

.case-body dd p { margin: 0 0 0.5rem; }
.case-body dd p:last-child { margin-bottom: 0; }

.stat { display: flex; align-items: baseline; gap: 0.6rem; flex-wrap: wrap; margin-bottom: 0.4rem !important; }
.stat-num {
  font-family: var(--serif);
  font-size: 2.6rem;
  font-weight: 650;
  line-height: 1;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
  min-width: 1.3ch;
}
.stat-label { color: var(--muted); font-size: 0.95rem; }

.meter {
  height: 0.5rem;
  background: var(--line);
  border-radius: 999px;
  overflow: hidden;
  margin: 0.25rem 0 0.75rem;
  max-width: 22rem;
}
.meter span {
  display: block;
  height: 100%;
  width: var(--fill);
  background: var(--accent);
  border-radius: inherit;
  transition: width 2.6s cubic-bezier(.45, 0, .55, 1);
}
.meter-empty span { width: 0; }

/* Things settle in as you reach them. Only when JS is on and motion is welcome. */

@media (prefers-reduced-motion: no-preference) {
  .rise { transition: opacity 0.7s ease, transform 0.7s cubic-bezier(.2, .7, .3, 1); }
  .rise.waiting { opacity: 0; transform: translateY(1.5rem); }
}

/* Photos you can pick up */

.photos figure { transition: transform 0.25s ease, box-shadow 0.25s ease; }
.photos figure:hover {
  transform: rotate(0) translateY(-6px) scale(1.03);
  box-shadow: 0 2px 4px rgb(41 36 31 / 0.08), 0 18px 40px rgb(41 36 31 / 0.16);
}

.fairy { position: relative; cursor: pointer; }
.sparkle {
  position: absolute;
  pointer-events: none;
  line-height: 1;
  text-shadow: 0 0 6px rgb(255 255 255 / 0.8);
  z-index: 2;
}

/* Contact extras */

.contact-email { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 0.6rem; }
.copy-btn {
  font: 600 0.8rem var(--sans);
  color: var(--accent);
  background: var(--surface);
  border: 1.5px solid var(--accent);
  border-radius: 999px;
  padding: 0.3rem 0.8rem;
  cursor: pointer;
}
.copy-btn:hover { background: var(--accent); color: var(--accent-ink); }
.copy-btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.local-time { color: var(--muted); font-size: 0.95rem; }

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

/* Smooth FAQ (browsers without support just snap open) */

:root { interpolate-size: allow-keywords; }
details::details-content {
  height: 0;
  overflow: clip;
  transition: height 0.3s ease, content-visibility 0.3s allow-discrete;
}
details[open]::details-content { height: auto; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after, ::details-content { transition: none !important; }
}

/* About */

.about { padding-top: 1rem; }
.about p { font-size: 1.125rem; margin: 0 0 1rem; }

/* Bigger photos */

.wrap-wide { width: min(68rem, 100% - 2rem); }
.wrap-wide > h2 { width: min(50rem, 100%); margin-inline: auto; }
.photos { grid-auto-flow: dense; }
.photos .big { grid-column: span 2; }
@media (min-width: 42rem) {
  .photos { gap: 2.25rem 2rem; }
  .photos .big { grid-row: span 2; }
  .photos .big.right { grid-column: 2 / span 2; }
  .photos .big figcaption { font-size: 1.15rem; }
  .photos .big { display: flex; flex-direction: column; }
  .photos .big img { flex: 1; aspect-ratio: auto; min-height: 0; }
}
.photos figure:nth-child(3n+1) { transform: rotate(-1.25deg); }
.photos figure:nth-child(3n+2) { transform: rotate(1deg); }
.photos figure:nth-child(3n) { transform: rotate(-0.5deg); }
.photos figure:hover { transform: rotate(0) translateY(-6px) scale(1.02); }
.card:last-child:nth-child(odd) { grid-column: 1 / -1; }

.section-lede { margin: -0.75rem 0 1.5rem; color: var(--muted); }
.card { display: flex; flex-direction: column; }
.card p { flex: 1; }
.visit { margin-top: 1rem; font-weight: 600; font-size: 0.95rem; color: var(--accent); overflow-wrap: anywhere; }
.card:hover .visit, .card:focus-visible .visit { text-decoration: underline; text-underline-offset: 0.18em; }
.card .status { align-self: flex-start; }

/* Intro aside */

.aside { margin: 1.25rem 0 0; color: var(--muted); font-size: 0.95rem; }
.print-only { display: none; }

/* Jump nav */

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
section[id] { scroll-margin-top: 3.25rem; }

.jump {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.jump-inner {
  width: min(50rem, 100% - 1rem);
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: center;
}
.jump-name { display: none; }
.jump ul { list-style: none; margin: 0; padding: 0.4rem 0; display: flex; gap: 0.15rem; }
.jump ul a {
  display: block;
  padding: 0.35rem 0.6rem;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
}
.jump ul a:hover { color: var(--text); background: var(--accent-soft); }
.jump ul a[aria-current="true"] { color: var(--accent); background: var(--accent-soft); }

/* A thin line under the nav that fills as you read. No JS needed where supported. */
@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion: no-preference) {
    .jump::after {
      content: "";
      position: absolute;
      left: 0;
      bottom: -1px;
      height: 2px;
      width: 100%;
      background: var(--accent);
      transform-origin: left;
      animation: read-progress linear both;
      animation-timeline: scroll(root);
    }
    @keyframes read-progress { from { transform: scaleX(0); } to { transform: scaleX(1); } }
  }
}
@media (min-width: 42rem) {
  .jump-inner { justify-content: space-between; width: min(50rem, 100% - 2rem); }
  .jump-name {
    display: block;
    font-family: var(--serif);
    font-weight: 650;
    font-size: 1.05rem;
    color: var(--text);
    text-decoration: none;
    opacity: 0;
    transition: opacity 0.2s ease;
  }
  .jump-name.shown, .jump-name:focus-visible { opacity: 1; }
  .jump ul a { padding-inline: 0.8rem; }
}

/* Section divider */

main > section + section::before {
  content: "";
  display: block;
  width: 7rem;
  height: 9px;
  margin: 0 auto 2.5rem;
  background:
    radial-gradient(circle, var(--accent) 3px, transparent 3.5px) center / 9px 9px no-repeat,
    linear-gradient(var(--line), var(--line)) left center / calc(50% - 0.9rem) 1px no-repeat,
    linear-gradient(var(--line), var(--line)) right center / calc(50% - 0.9rem) 1px no-repeat;
}
@media (min-width: 42rem) { main > section + section::before { margin-bottom: 3.5rem; } }
main > section:first-child { padding-top: 1.5rem; }

/* Enlarged photos */

.zoomable { cursor: zoom-in; }
.zoom-btn {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: zoom-in;
  border-radius: 2px;
}
.zoom-btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.photos .big .zoom-btn { flex: 1; min-height: 0; display: flex; }
.photos .big .zoom-btn img { flex: 1; min-height: 0; }
.case-photos .zoom-btn { border-radius: 8px; }

.lightbox {
  width: min(56rem, 100% - 1.5rem);
  max-width: none;
  max-height: calc(100dvh - 1.5rem);
  padding: 0.75rem 0.75rem 1rem;
  border: 0;
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 24px 80px rgb(0 0 0 / 0.4);
  overflow: visible;
}
.lightbox::backdrop { background: rgb(20 17 15 / 0.82); }
.lightbox[open] { animation: lb-in 0.22s ease; }
@keyframes lb-in { from { opacity: 0; transform: scale(0.97); } }
.lightbox figure { margin: 0; }
.lb-stage { position: relative; }
.lightbox img {
  display: block;
  width: 100%;
  height: auto;
  max-height: calc(100dvh - 7.5rem);
  object-fit: contain;
  background: var(--line);
  border-radius: 3px;
}
.lightbox figcaption {
  margin-top: 0.75rem;
  font-family: var(--serif);
  font-size: clamp(1rem, 3.5vw, 1.2rem);
  line-height: 1.4;
  text-align: center;
  padding-inline: 0.5rem;
}
.lb-btn {
  position: absolute;
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border: 0;
  border-radius: 50%;
  background: var(--surface);
  color: var(--text);
  font: 600 1.3rem/1 var(--sans);
  box-shadow: var(--shadow);
  cursor: pointer;
}
.lb-btn:hover { background: var(--accent); color: var(--accent-ink); }
.lb-btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.lb-close { top: -0.9rem; right: -0.9rem; }
.lb-prev, .lb-next { top: 50%; translate: 0 -50%; opacity: 0.9; }
.lb-prev { left: 0.5rem; }
.lb-next { right: 0.5rem; }
.lightbox .sparkle { z-index: 3; }

/* Footer print button */

.print-btn {
  margin-top: 0.75rem;
  font: 600 0.85rem var(--sans);
  color: var(--muted);
  background: none;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  padding: 0.35rem 0.9rem;
  cursor: pointer;
}
.print-btn:hover { color: var(--accent); border-color: var(--accent); }
.print-btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

/* Print: a clean, black-on-white version for interview packets */

@media print {
  :root {
    --bg: #fff; --surface: #fff; --text: #111; --muted: #444;
    --accent: #1e6b5f; --accent-soft: #eef5f3; --line: #ccc; --shadow: none;
  }
  @page { margin: 0.6in; }
  body { font-size: 10.5pt; line-height: 1.5; background: #fff; }
  .skip, .jump, .links, .aside, #photos, .case-photos,
  .copy-btn, .local-time, .print-btn, .lightbox, .case-next, .handoff, .made-it, main > section + section::before { display: none !important; }
  .print-only { display: block; margin: 0.25rem 0 0; color: var(--muted); }
  .wrap, .wrap-wide { width: 100%; }
  section { padding-block: 0.9rem; }
  h1 { font-size: 24pt; }
  h2 { font-size: 15pt; margin-bottom: 0.6rem; break-after: avoid; }
  h3 { break-after: avoid; }
  .intro { padding-block: 0 0.5rem; grid-template-columns: auto 1fr; gap: 1.25rem; align-items: center; }
  .portrait { width: 1in; height: auto; margin: 0; }
  .lede { font-size: 10.5pt; margin-bottom: 0; }
  .case, .card, details, .contact { box-shadow: none; border: 1px solid var(--line); break-inside: avoid; }
  .case { padding: 0.8rem 1rem; margin-bottom: 0.6rem; }
  .case-body dl { grid-template-columns: 7.5rem 1fr; gap: 0.35rem 1rem; }
  .case-body dt { margin-top: 0.15rem; }
  .stat-num { font-size: 18pt; }
  .meter, .meter span, .chips li, .status { print-color-adjust: exact; -webkit-print-color-adjust: exact; }
  .meter span { width: var(--fill) !important; transition: none; }
  .cards { grid-template-columns: 1fr 1fr; gap: 0.5rem; }
  .card { padding: 0.7rem 0.9rem; }
  .card:last-child:nth-child(odd) { grid-column: auto; }
  .about p { font-size: 10.5pt; }
  .timeline li::before { display: none; }
  details { padding: 0 0.9rem; }
  details::details-content { height: auto; content-visibility: visible; }
  summary { padding: 0.5rem 0 0.25rem; }
  summary::after { display: none; }
  .contact { padding: 1rem; text-align: left; background: none; }
  .contact-email { justify-content: flex-start; }
  a { color: var(--text); }
  main a[href^="http"]:not(.card)::after { content: " (" attr(href) ")"; font-size: 0.85em; color: var(--muted); overflow-wrap: anywhere; }
  footer { padding-block: 0.5rem 0; }
}

/* 404 */

.notfound { min-height: 100dvh; display: flex; flex-direction: column; justify-content: center; padding-block: 3rem; }
.notfound h1 { font-size: clamp(2rem, 7vw, 3rem); }
.notfound .links { margin-top: 0.5rem; }
.notfound .aside { margin-top: 2rem; }

/* Quotes */

.quotes {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: 0.25rem;
  overscroll-behavior-x: contain;
  padding: 0.25rem 0.25rem 1.25rem;
  margin-inline: -0.25rem;
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}
.quotes:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 14px; }
.quote {
  flex: 0 0 85%;
  scroll-snap-align: start;
  margin: 0;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1.1rem 1.15rem;
  box-shadow: var(--shadow);
}
@media (min-width: 42rem) { .quote { flex-basis: calc((100% - 2rem) / 2.5); padding: 1.25rem 1.35rem; } }
.quote blockquote { margin: 0; flex: 1; font-family: var(--serif); font-weight: 500; font-size: 0.98rem; line-height: 1.55; }
.quote blockquote::before {
  content: "\201C";
  display: block;
  height: 1.3rem;
  font-size: 2.3rem;
  line-height: 1;
  color: var(--accent);
}
.quote blockquote p { margin: 0; }
.quote figcaption { margin-top: 1rem; font-size: 0.9rem; font-weight: 600; color: var(--muted); }

.quotes-nav { display: flex; justify-content: flex-end; gap: 0.5rem; }
.quotes-nav[hidden] { display: none; }
.quotes-nav button {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 1.5px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  color: var(--accent);
  font: 600 1.4rem/1 var(--sans);
  cursor: pointer;
}
.quotes-nav button:hover:not(:disabled) { border-color: var(--accent); background: var(--accent-soft); }
.quotes-nav button:disabled { opacity: 0.4; cursor: default; }
.quotes-nav button:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

.case-quotes { display: grid; gap: 1rem; margin-top: 1.5rem; padding-top: 1.25rem; border-top: 1px solid var(--line); }
@media (min-width: 42rem) { .case-quotes.two { grid-template-columns: 1fr 1fr; gap: 1.25rem 1.75rem; } }
.case-quotes figure { margin: 0; padding-left: 0.9rem; border-left: 2px solid var(--accent); }
.case-quotes blockquote { margin: 0; font-size: 0.95rem; line-height: 1.55; font-style: italic; }
.case-quotes blockquote p { margin: 0; }
.case-quotes figcaption { margin-top: 0.35rem; font-size: 0.85rem; color: var(--muted); }

.card p.card-quote {
  flex: none;
  margin-top: 1rem;
  padding-left: 0.8rem;
  border-left: 2px solid var(--accent);
  font-family: var(--serif);
  font-weight: 500;
  color: var(--text);
}
.card-quote span { display: block; font-family: var(--sans); font-weight: 400; font-size: 0.85rem; color: var(--muted); }

@media print {
  .quotes { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; overflow: visible; padding: 0; margin: 0; }
  .quote { padding: 0.7rem 0.9rem; box-shadow: none; break-inside: avoid; }
  .quote blockquote { font-size: 10.5pt; }
  .quote blockquote::before { display: none; }
  .quotes-nav { display: none !important; }
  .case-quotes { break-inside: avoid; }
}

/* Six nav links on a 360px phone */
@media (max-width: 26rem) {
  .jump ul { gap: 0; }
  .jump ul a { padding-inline: 0.4rem; font-size: 0.82rem; }
}

/* Print, take two: fewer pages, and a routing slip that only exists on paper */
@media print {
  .rise.waiting { opacity: 1 !important; transform: none !important; }

  /* Long cases may break between parts instead of each starting a new page. */
  .case { break-inside: auto; }
  .case h3 { break-after: avoid; }
  .case-body dl, .case-quotes figure { break-inside: avoid; }
  .case-quotes { break-inside: auto; grid-template-columns: 1fr 1fr; gap: 0.5rem 1rem; margin-top: 0.6rem; padding-top: 0.6rem; }
  .case-quotes figure:only-child { grid-column: 1 / -1; }
  .case-quotes blockquote, .quote blockquote { font-size: 9.5pt; line-height: 1.4; }
  .case-quotes figcaption, .quote figcaption { margin-top: 0.25rem; font-size: 8.5pt; }

  .quotes { grid-template-columns: repeat(3, 1fr); }
  .quote { padding: 0.55rem 0.7rem; }

  .card[href^="#"] .visit { display: none; }

  .timeline { border-left: 0; margin-bottom: 0.6rem; }
  .timeline li { display: grid; grid-template-columns: 7rem 1fr; padding: 0 0 0.2rem; }
  .timeline .org { display: inline; }
  .timeline .org::before { content: " · "; }

  .routing-slip {
    width: 3.4in;
    margin: 1.25rem auto 0;
    padding: 0.7rem 0.9rem 0.6rem;
    border: 1.5px dashed var(--muted);
    text-align: left;
    color: var(--text);
    font-size: 10pt;
    transform: rotate(-1.5deg);
    break-inside: avoid;
  }
  .routing-slip p { margin: 0 0 0.35rem; }
  .slip-title { font-family: var(--serif); font-weight: 650; font-size: 12pt; letter-spacing: 0.08em; text-transform: uppercase; text-align: center; }
  .slip-field { display: flex; gap: 0.4rem; }
  .slip-field span { flex: 1; border-bottom: 1px solid var(--muted); }
  .routing-slip ul { list-style: none; margin: 0.5rem 0; padding: 0; }
  .routing-slip li { margin-bottom: 0.25rem; }
  .routing-slip li::before {
    content: "";
    display: inline-block;
    width: 0.8em;
    height: 0.8em;
    margin-right: 0.5em;
    vertical-align: -0.05em;
    border: 1px solid var(--text);
  }
  .slip-foot { font-size: 8.5pt; color: var(--muted); margin: 0 !important; }
}
@media print {
  .case-num, .section-lede { break-after: avoid; }
  .case-num + h3 { break-before: avoid; }
  .cards { grid-template-columns: repeat(3, 1fr); }
  .card p { font-size: 9pt; line-height: 1.45; }
  .card h3 { font-size: 11pt; margin-top: 0.4rem; }
  main a[href$=".pdf"]::after { content: " (hire-meg-kennedy.com/meg-kennedy-resume.pdf)"; font-size: 0.85em; color: var(--muted); }
}

.quotes-nav button.quotes-pause {
  width: auto;
  height: 2.75rem;
  margin-right: auto;
  padding: 0 1rem;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.85rem;
}

/* Case studies as cards: scan them closed, open the ones you want */


.cases { display: grid; gap: 0.75rem; }
@media (min-width: 47.5rem) {
  .cases { grid-template-columns: 1fr 1fr; gap: 1rem; }
  .case[open], .case:last-child:nth-child(odd) { grid-column: 1 / -1; }
}

.case { padding: 0; margin: 0; transition: border-color 0.15s ease; }
.case:hover { border-color: var(--accent); }
.case[open] { box-shadow: var(--shadow); }
.case > summary {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 0;
  height: 100%;
  padding: 1rem 1.15rem 0.95rem;
  font-weight: inherit;
  border-radius: 14px;
}
.case[open] > summary { height: auto; }
.case > summary::after { display: none; }
@media (min-width: 42rem) { .case > summary { padding: 1.5rem 1.75rem 1.35rem; } }
.case h3 { font-size: 1.2rem; margin-bottom: 0.5rem; }
@media (min-width: 42rem) { .case h3 { font-size: 1.3rem; } }
@media (min-width: 47.5rem) { .case[open] h3 { font-size: 1.4rem; } }
:is(.case > summary, .case-modal-head) .stat { margin: 0 0 0.15rem; gap: 0.15rem 0.5rem; }
:is(.case > summary, .case-modal-head) .stat-num { font-size: 2rem; }
:is(.case > summary, .case-modal-head) .meter { display: block; width: 100%; margin: 0.35rem 0 0.25rem; }
:is(.case > summary, .case-modal-head) .chips { margin-top: 0.5rem; gap: 0.3rem; }
:is(.case > summary, .case-modal-head) .chips > span:not(.visually-hidden) { font-size: 0.78rem; padding: 0.1rem 0.6rem; }
.case-cue {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin-top: auto;
  padding-top: 0.65rem;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--accent);
}
.case-cue svg {
  width: 1.1rem;
  height: 1.1rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.2s ease;
}
.case[open] .case-cue svg { transform: rotate(180deg); }
.case > summary:hover .case-cue { text-decoration: underline; text-underline-offset: 0.18em; }
.case-body { padding: 1.25rem 1.25rem 1.5rem; border-top: 1px solid var(--line); }
@media (min-width: 42rem) { .case-body { padding: 1.75rem 2.25rem 2rem; } }

@media print {
  .cases { display: block; }
  .case { padding: 0; margin-bottom: 0.6rem; }
  .case > summary { height: auto; padding: 0.8rem 1rem 0.3rem; }
  .case-body { padding: 0.3rem 1rem 0.8rem; border-top: 0; }
  .case-cue { display: none !important; }
  .case > summary .stat-num { font-size: 18pt; }
  .case > summary .meter { max-width: 22rem; }
}

/* Very narrow screens: keep the six nav links inside the page */
@media (max-width: 22rem) {
  .jump ul a { padding-inline: 0.22rem; font-size: 0.78rem; }
}

/* Case study pop-out window. Without JS, cards still expand in place. */

.case-pop .case-cue svg { transform: rotate(-90deg); }
.case-modal {
  width: min(46rem, 100% - 1rem);
  max-width: none;
  max-height: calc(100dvh - 1rem);
  padding: 0;
  overflow: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 24px 80px rgb(0 0 0 / 0.35);
}
.case-modal::backdrop { background: rgb(20 17 15 / 0.6); }
html:has(.case-modal[open]) { overflow: hidden; }
@media (prefers-reduced-motion: no-preference) {
  .case-modal[open] { animation: case-in 0.22s ease; }
  @keyframes case-in { from { opacity: 0; transform: translateY(0.75rem); } }
}
.case-modal-bar {
  position: sticky;
  top: 0;
  z-index: 1;
  height: 0;
  display: flex;
  justify-content: flex-end;
}
.case-modal-close {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  margin: 0.6rem 0.6rem 0 0;
  border: 1.5px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text);
  font: 600 1.3rem/1 var(--sans);
  cursor: pointer;
  box-shadow: var(--shadow);
}
.case-modal-close:hover { border-color: var(--accent); background: var(--accent-soft); }
.case-modal-close:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.case-modal-head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 1.25rem 1.25rem 1.1rem;
}
.case-modal-head h3 { font-size: 1.4rem; margin: 0 3rem 0.6rem 0; }
@media (min-width: 42rem) {
  .case-modal-head { padding: 2rem 2.25rem 1.35rem; }
  .case-modal-head h3 { font-size: 1.6rem; }
}
/* Inside the window, Next moves sideways to the next case instead of down the page. */
.case-pop .case-next > span[aria-hidden] { display: none; }
.case-pop .case-next::after { content: " \2192"; }

/* Print, take three: case cards and FAQ sized for paper, not screens */
@media print {
  section { padding-block: 0.6rem; }
  .case > summary { display: block; padding: 0.55rem 0.9rem 0.15rem; }
  .case-num { display: block; font-size: 9pt; margin: 0; }
  .case h3 { font-size: 12.5pt; margin: 0 0 0.15rem; }
  .case > summary .stat { display: block; margin: 0; }
  .case > summary .stat-num { font-size: 13pt; min-width: 0; }
  .case > summary .stat-label { font-size: 9.5pt; }
  .case > summary .meter { display: none; }
  .case > summary .chips { margin-top: 0.25rem; }
  .case > summary .chips > span:not(.visually-hidden) { font-size: 7.5pt; padding: 0 0.45rem; }
  .case-body { padding: 0.25rem 0.9rem 0.55rem; }
  .case-body dl { gap: 0.2rem 0.8rem; grid-template-columns: 6.5rem 1fr; }
  .case-body dt { font-size: 7.5pt; margin-top: 0.1rem; }
  .case-body dd { font-size: 9.5pt; line-height: 1.4; }
  .case-quotes { margin-top: 0.4rem; padding-top: 0.4rem; }
  .case-quotes.two { grid-template-columns: 1fr 1fr; }

  .faqs { display: grid; grid-template-columns: 1fr 1fr; gap: 0.4rem; }
  .faqs details { break-inside: avoid; }
  .faqs summary { font-size: 9.5pt; padding: 0.4rem 0 0.15rem; }
  .faqs details p { font-size: 9pt; line-height: 1.4; margin-bottom: 0.5rem; }
  .plain { gap: 0.35rem; }
  .plain li { font-size: 9.5pt; line-height: 1.45; }
}
