/* ==========================================================================
   Anke du Randt — soft pastel, structured, gently animated
   One stylesheet for the home page and the case studies. Light only.
   ========================================================================== */

/* ---------- Tokens ---------- */

:root {
  --bg: #FCF9FD;          /* lilac-white page */
  --surface: #F4EFF9;     /* lavender mist: tags, chips, placeholders */
  --card: #FFFFFF;        /* cards */
  --glass: rgba(255, 255, 255, 0.72); /* panels over the pastel wash */
  --line: #ECE4F2;        /* dividers */
  --text: #2D2438;        /* deep aubergine */
  --muted: #72677C;       /* secondary text */
  --accent: #B597EA;      /* lavender: strokes, dots, selection box */
  --accent-text: #6D4BB0; /* lavender for small text (AA on white and the page) */
  --accent-soft: #EFE7FB; /* lavender tint */
  --pink: #EFA3C4;        /* blush */
  --pink-soft: #FCE7F0;
  --peach: #F6BF9C;       /* peach */
  --peach-soft: #FDEDE2;
  --sky: #AFC8F1;         /* powder blue */
  --sky-soft: #E6EEFB;
  --on-dark: #FFFFFF;

  --grad-soft: linear-gradient(125deg, var(--pink-soft) 0%, var(--accent-soft) 48%, var(--sky-soft) 100%);
  --grad-ring: conic-gradient(from 0deg, var(--pink), var(--accent), var(--sky), var(--peach), var(--pink));

  --shadow-sm: 0 1px 2px rgba(45, 36, 56, 0.04), 0 8px 24px rgba(109, 75, 176, 0.06);
  --shadow-md: 0 2px 6px rgba(45, 36, 56, 0.05), 0 20px 50px rgba(109, 75, 176, 0.12);

  --r-sm: 12px;
  --r-md: 20px;
  --r-lg: 28px;
  --r-xl: 40px;
  --r-pill: 999px;

  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Geist", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-hand: "Caveat", "Comic Sans MS", cursive;

  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --fast: 150ms;
  --mid: 220ms;
  --slow: 320ms;

  --maxw: 1200px;
  --gutter: 24px;
  --side: 16px;
  --nav-h: 64px;
  --section-pad: clamp(72px, 9vw, 120px);

  color-scheme: light;
}

@media (min-width: 720px) {
  :root { --side: 32px; --nav-h: 72px; }
}

/* ---------- Reset ---------- */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 16px);
}

body {
  position: relative;
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* The pastel wash behind every page: soft blobs that drift very slowly */
body::before {
  content: "";
  position: fixed;
  inset: -20%;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(38% 34% at 12% 14%, rgba(239, 163, 196, 0.38), transparent 70%),
    radial-gradient(34% 32% at 88% 10%, rgba(181, 151, 234, 0.34), transparent 70%),
    radial-gradient(36% 34% at 82% 62%, rgba(246, 191, 156, 0.30), transparent 70%),
    radial-gradient(40% 36% at 14% 82%, rgba(175, 200, 241, 0.34), transparent 70%);
  animation: drift 38s ease-in-out infinite alternate;
}
/* Fine grain over the wash, like the printed gradients in the CV references */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.35;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.45  0 0 0 0 0.38  0 0 0 0 0.55  0 0 0 0.10 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}
@keyframes drift {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(3%, -2%, 0) scale(1.05); }
  100% { transform: translate3d(-3%, 2%, 0) scale(1.02); }
}

@media (min-width: 1024px) {
  body { font-size: 18px; }
}

h1, h2, h3, h4, h5, p, ul, ol, dl, dd, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg, video { display: block; max-width: 100%; }
img, video { height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
dialog { color: inherit; }
p { text-wrap: pretty; }

::selection { background: var(--accent-soft); color: var(--text); }

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

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 12px; left: 12px;
  z-index: 200;
  padding: 10px 18px;
  background: var(--text);
  color: var(--on-dark);
  font: 500 14px/1 var(--font-body);
  border-radius: var(--r-pill);
  transform: translateY(-200%);
  transition: transform var(--mid) var(--ease);
}
.skip-link:focus-visible { transform: none; }

/* ---------- Type ---------- */

.display {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1;
  font-optical-sizing: auto;
  text-wrap: balance;
}
/* Italic, lavender emphasis inside headings */
.display em {
  font-style: italic;
  font-weight: 400;
  color: var(--accent-text);
}

.h1 { font-size: clamp(48px, 8vw, 112px); }
.h2 { font-size: clamp(38px, 5vw, 64px); }
.h3 { font-size: clamp(24px, 2.4vw, 30px); letter-spacing: -0.015em; line-height: 1.1; }

/* Small supporting text: dates, metadata, captions */
.label {
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 500;
  line-height: 1.45;
  letter-spacing: -0.005em;
}
.label--sm { font-size: 14px; }
.label--md { font-size: 16px; }

.muted { color: var(--muted); }
.accent { color: var(--accent-text); }

.lede {
  font-size: clamp(18px, 1.5vw, 20px);
  line-height: 1.55;
  max-width: 54ch;
}

.prose p { max-width: 62ch; }
.prose p + p { margin-top: 1em; }

/* Text the site still needs from Anke. Search the HTML for class="todo". */
.todo {
  color: var(--muted);
  border-bottom: 1.5px dashed rgba(114, 103, 124, 0.55);
  padding-bottom: 1px;
}

/* ---------- Layout ---------- */

.wrap {
  position: relative;
  width: 100%;
  max-width: calc(var(--maxw) + var(--side) * 2);
  margin-inline: auto;
  padding-inline: var(--side);
}

.section > .wrap { padding-block: var(--section-pad); }
.section ~ .section > .wrap { padding-top: 0; }

/* Section header: eyebrow and title on the left, a short line (and controls) on the right */
.sec-head {
  display: grid;
  gap: 20px 48px;
  align-items: end;
  margin-bottom: clamp(32px, 4vw, 48px);
  padding-bottom: clamp(24px, 3vw, 32px);
  border-bottom: 1px solid var(--line);
}
.sec-head__aside { color: var(--muted); max-width: 46ch; }
@media (min-width: 900px) {
  .sec-head { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .sec-head__aside { justify-self: end; }
}

/* Section eyebrow: a soft pill with a sparkle */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 7px 15px 7px 12px;
  border-radius: var(--r-pill);
  background: var(--glass);
  box-shadow: inset 0 0 0 1px rgba(181, 151, 234, 0.28);
  color: var(--accent-text);
  font: 600 14px/1.2 var(--font-body);
}
.eyebrow::before {
  content: "";
  width: 11px; height: 11px;
  background: linear-gradient(135deg, var(--pink), var(--accent));
  -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 0C12.6 6.6 17.4 11.4 24 12 17.4 12.6 12.6 17.4 12 24 11.4 17.4 6.6 12.6 0 12 6.6 11.4 11.4 6.6 12 0Z'/></svg>") center / contain no-repeat;
  mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 0C12.6 6.6 17.4 11.4 24 12 17.4 12.6 12.6 17.4 12 24 11.4 17.4 6.6 12.6 0 12 6.6 11.4 11.4 6.6 12 0Z'/></svg>") center / contain no-repeat;
}

/* Glass panel: the building block of the CV */
.panel {
  padding: clamp(22px, 2.6vw, 32px);
  background: var(--glass);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm), inset 0 0 0 1px rgba(255, 255, 255, 0.7);
}
.panel__title {
  font: 500 clamp(22px, 2vw, 26px)/1.1 var(--font-display);
  letter-spacing: -0.015em;
  margin-bottom: 18px;
}

/* ---------- Sparkles ---------- */

.sparkle {
  position: absolute;
  z-index: 3;
  width: 22px; height: 22px;
  fill: var(--accent);
  pointer-events: none;
  animation: twinkle 3.6s var(--ease) infinite;
}
@keyframes twinkle {
  0%, 100% { transform: scale(1) rotate(0deg); opacity: 1; }
  50% { transform: scale(0.6) rotate(45deg); opacity: 0.55; }
}

/* ---------- Buttons, chips, tags ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 50px;
  padding: 0 26px;
  border: 1px solid transparent;
  border-radius: var(--r-pill);
  font: 500 16px/1.2 var(--font-body);
  white-space: nowrap;
  transition:
    background-color var(--mid) var(--ease),
    border-color var(--mid) var(--ease),
    color var(--mid) var(--ease),
    box-shadow var(--mid) var(--ease),
    transform var(--mid) var(--ease);
}
.btn--primary { background: var(--text); color: var(--on-dark); }
.btn--primary:hover { background: #45385A; box-shadow: 0 10px 28px rgba(109, 75, 176, 0.28); transform: translateY(-2px); }
.btn--outline { background: var(--card); border-color: var(--line); color: var(--text); box-shadow: var(--shadow-sm); }
.btn--outline:hover { border-color: #DACDEB; box-shadow: var(--shadow-md); transform: translateY(-2px); }
.btn--soft { background: var(--glass); color: var(--text); box-shadow: var(--shadow-sm); }
.btn--soft:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.btn--sm { min-height: 40px; padding: 0 18px; font-size: 15px; }
.btn:active { transform: scale(0.98); }
.btn small { font-size: 0.86em; opacity: 0.72; font-weight: 400; }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent-text);
  font-weight: 500;
  white-space: nowrap;
  transition: gap var(--mid) var(--ease), color var(--mid) var(--ease);
}
.link-arrow:hover { gap: 10px; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 0 14px;
  border-radius: var(--r-pill);
  background: var(--card);
  box-shadow: inset 0 0 0 1px var(--line);
  font: 500 14px/1 var(--font-body);
  color: var(--text);
  white-space: nowrap;
  transition: color var(--fast) var(--ease), background-color var(--fast) var(--ease), box-shadow var(--fast) var(--ease), transform var(--fast) var(--ease);
}
button.chip:hover { box-shadow: inset 0 0 0 1px #D8CAEC; transform: translateY(-1px); }
.chip[aria-pressed="true"],
button.chip[aria-pressed="true"]:hover {
  background: var(--text);
  color: var(--on-dark);
  box-shadow: none;
}

.chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
/* Filter chips scroll sideways on small screens */
.chips--scroll {
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: none;
  margin-inline: calc(var(--side) * -1);
  padding: 4px var(--side);
}
.chips--scroll::-webkit-scrollbar { display: none; }
@media (min-width: 1024px) {
  .chips--scroll { flex-wrap: wrap; overflow: visible; margin-inline: 0; padding-inline: 0; }
}

.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags li,
.tags .tag-li {
  font: 500 13px/1 var(--font-body);
  padding: 7px 11px;
  border-radius: var(--r-pill);
  background: var(--surface);
  color: var(--muted);
  transition: color var(--fast) var(--ease), background-color var(--fast) var(--ease);
}
.tags li.is-match { background: var(--accent-soft); color: var(--accent-text); }

/* Pulsing "live" dot */
.dot-live {
  position: relative;
  display: inline-block;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--pink);
  flex: none;
}
.dot-live::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: var(--pink);
  animation: pulse 2s var(--ease) infinite;
}
@keyframes pulse {
  0% { transform: scale(1); opacity: 0.6; }
  80%, 100% { transform: scale(3); opacity: 0; }
}

/* ---------- Margin notes (handwriting) ---------- */

.note {
  position: absolute;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-hand);
  font-weight: 600;
  font-size: clamp(23px, 2vw, 28px);
  line-height: 1;
  letter-spacing: 0;
  color: var(--accent-text);
  white-space: nowrap;
  transform: rotate(-3deg);
  pointer-events: none;
}
.note__arrow {
  width: 56px;
  height: 40px;
  flex: none;
  overflow: visible;
  fill: none;
  stroke: var(--pink);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
/* When the handwriting photos arrive, put an <img class="note__img"> inside the note. */
.note__img { height: 1.6em; width: auto; }
.note__img + .note__text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- Media and placeholders ---------- */

/*
  Every image, video and portrait slot is a .media frame. While the real file
  is missing it holds a .ph placeholder; swap the .ph for an <img> or <video>.
*/
.media {
  position: relative;
  overflow: hidden;
  background: var(--surface);
  border-radius: var(--r-lg);
  aspect-ratio: var(--ar, 16 / 9);
  isolation: isolate;
}
.media > img,
.media > video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.ar-16x9 { --ar: 16 / 9; }
.ar-4x3 { --ar: 4 / 3; }
.ar-4x5 { --ar: 4 / 5; }
.ar-a4 { --ar: 210 / 297; }
.ar-1x1 { --ar: 1 / 1; }

.ph {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 16px;
  color: var(--muted);
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='48' height='48' viewBox='0 0 24 24' fill='none' stroke='%23B9A6D6' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'><rect x='3' y='4' width='18' height='16' rx='4'/><circle cx='9' cy='10' r='1.8'/><path d='M21 16l-5-5-8.5 8.5'/></svg>") center / 48px no-repeat,
    var(--ph-bg, var(--grad-soft));
}
.ph__top, .ph__bottom { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.ph__top > :nth-child(2) { display: none; }
.ph__label {
  padding: 6px 12px;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.75);
  color: var(--text);
  font-size: 13px;
}
.ph__bottom { font-size: 14px; }
.ph__play {
  position: absolute;
  top: 50%; left: 50%;
  z-index: 1;
  width: 64px; height: 64px;
  margin: -32px 0 0 -32px;
  border-radius: 50%;
  background: var(--card);
  box-shadow: var(--shadow-md);
  display: grid;
  place-items: center;
}
.ph:has(.ph__play) { background-image: var(--ph-bg, var(--grad-soft)); }
.ph__play::before {
  content: "";
  margin-left: 4px;
  border-left: 15px solid var(--text);
  border-top: 9px solid transparent;
  border-bottom: 9px solid transparent;
  border-radius: 2px;
}

/* ---------- Nav ---------- */

.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 60;
  height: var(--nav-h);
  transition: background-color var(--mid) var(--ease), box-shadow var(--mid) var(--ease);
}
.nav.is-scrolled,
.nav.is-open {
  background: rgba(252, 249, 253, 0.78);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
  backdrop-filter: saturate(160%) blur(18px);
  box-shadow: 0 1px 0 rgba(109, 75, 176, 0.08);
}
.nav__inner {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 24px;
}
.wordmark {
  font: 500 22px/1 var(--font-display);
  letter-spacing: -0.02em;
  white-space: nowrap;
  margin-right: auto;
}
.wordmark span { color: var(--pink); }
.nav__links {
  display: none;
  gap: 4px;
  font-size: 15px;
  font-weight: 500;
}
.nav__links a {
  padding: 8px 16px;
  border-radius: var(--r-pill);
  color: var(--muted);
  transition: color var(--fast) var(--ease), background-color var(--fast) var(--ease), box-shadow var(--fast) var(--ease);
}
.nav__links a:hover { color: var(--text); }
.nav__links a[aria-current="true"] { color: var(--text); background: var(--card); box-shadow: var(--shadow-sm); }
.nav__actions { display: flex; align-items: center; gap: 12px; }
.nav__cv { display: none; }

.icon-btn {
  display: grid;
  place-items: center;
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--card);
  box-shadow: var(--shadow-sm);
  color: var(--text);
  transition: box-shadow var(--fast) var(--ease);
}
.icon-btn:hover { box-shadow: var(--shadow-md); }
.icon-btn svg { width: 18px; height: 18px; }

.menu-btn .i-close { display: none; }
.nav.is-open .menu-btn .i-close { display: block; }
.nav.is-open .menu-btn .i-menu { display: none; }

@media (min-width: 960px) {
  .nav__links { display: flex; }
  .nav__cv { display: inline-flex; }
  .menu-btn { display: none; }
}

.mobile-menu {
  position: fixed;
  inset: var(--nav-h) 0 0 0;
  z-index: 59;
  background: var(--bg) var(--grad-soft);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 24px var(--side) calc(32px + env(safe-area-inset-bottom));
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity var(--mid) var(--ease), transform var(--mid) var(--ease), visibility 0s linear var(--mid);
}
.mobile-menu.is-open {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity var(--mid) var(--ease), transform var(--mid) var(--ease), visibility 0s;
}
.mobile-menu__links { display: flex; flex-direction: column; gap: 2px; }
.mobile-menu__links a {
  font-size: clamp(44px, 12vw, 72px);
  padding: 6px 0;
}
.mobile-menu__foot { display: flex; flex-direction: column; gap: 14px; }
@media (min-width: 960px) {
  .mobile-menu { display: none; }
}

/* ---------- Hero ---------- */

.hero { position: relative; padding-top: var(--nav-h); overflow-x: clip; }
.hero > .wrap { padding-block: clamp(28px, 5vw, 64px) clamp(64px, 8vw, 104px); }

.hero__grid {
  display: grid;
  gap: 40px;
  align-items: center;
}
@media (min-width: 900px) {
  .hero__grid { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 56px; }
}

.hero__text .eyebrow { margin-bottom: 22px; }
.hero__name {
  font-size: clamp(54px, 8.4vw, 116px);
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 0.92;
}

.hero__title {
  position: relative;
  margin-top: clamp(18px, 2.4vw, 28px);
  font-size: clamp(26px, 3vw, 40px);
  font-weight: 400;
  line-height: 1.18;
  letter-spacing: -0.015em;
  max-width: 17em;
}
.hero__title .line { display: inline; }
/* Keep the cursor above the next line of type */
.hero__title .line:nth-child(2) { position: relative; z-index: 2; }
@media (min-width: 720px) {
  .hero__title .line { display: block; }
}

/* Selection box around "look good" */
.sel { position: relative; display: inline-block; }
.sel__box {
  position: absolute;
  top: 0.06em; bottom: -0.04em;
  left: -0.12em; right: -0.12em;
  border: 1.5px solid var(--accent);
  border-radius: 8px;
  background: rgba(239, 231, 251, 0.75);
  z-index: -1;
  pointer-events: none;
}
.sel__h {
  position: absolute;
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--card);
  border: 1.5px solid var(--accent);
}
.sel__h--tl { top: -5px; left: -5px; }
.sel__h--tr { top: -5px; right: -5px; }
.sel__h--bl { bottom: -5px; left: -5px; }
.sel__h--br { bottom: -5px; right: -5px; }

/* The "Anke" cursor parks its tip on the bottom-right handle */
.cursor {
  position: absolute;
  left: calc(100% + 0.12em);
  top: calc(100% + 0.04em);
  z-index: 4;
  display: none;
  pointer-events: none;
}
.cursor svg {
  width: 22px; height: 22px;
  max-width: none;
  margin: -2px 0 0 -2px;
  filter: drop-shadow(0 3px 8px rgba(45, 36, 56, 0.22));
}
.cursor__tag {
  position: absolute;
  left: 15px; top: 19px;
  padding: 5px 11px 6px;
  border-radius: var(--r-pill);
  background: linear-gradient(120deg, var(--pink), var(--accent));
  color: var(--on-dark);
  font: 600 13px/1 var(--font-body);
  letter-spacing: 0;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(181, 151, 234, 0.4);
}
@media (min-width: 900px) and (hover: hover) {
  .cursor { display: block; }
}

/* Hand-drawn underline under "sound human". The SVG scales with the type. */
.ul { position: relative; display: inline-block; white-space: nowrap; font-style: italic; color: var(--accent-text); }
.ul__svg {
  position: absolute;
  left: -2%;
  bottom: -0.12em;
  width: 104%;
  height: 0.22em;
  overflow: visible;
  pointer-events: none;
}
.ul__svg path {
  fill: none;
  stroke: var(--pink);
  stroke-width: 4;
  stroke-linecap: round;
}

.hero__lede { margin-top: clamp(22px, 2.6vw, 30px); color: #54485F; }
/* Leave room for the "Anke" cursor tag under the selection box */
@media (min-width: 900px) and (hover: hover) {
  .hero__lede { margin-top: 52px; }
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

/* Portrait: a circle inside a slowly turning pastel ring */
.hero__portrait {
  position: relative;
  width: min(100%, 440px);
  margin-inline: auto;
}
@media (max-width: 899px) {
  .hero__portrait { order: -1; width: min(64%, 280px); margin-inline: 0; }
}
.portrait {
  position: relative;
  aspect-ratio: 1;
  border-radius: 50%;
  padding: 12px;
  animation: float 7s ease-in-out infinite;
}
.portrait__ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: var(--grad-ring);
  opacity: 0.85;
  animation: spin 24s linear infinite;
}
.portrait__ring::after {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  background: var(--bg);
}
.portrait img {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  object-position: 50% 22%;
  box-shadow: var(--shadow-md);
}
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.sparkle--a { top: 4%; right: 6%; width: 34px; height: 34px; fill: var(--pink); }
.sparkle--b { bottom: 10%; right: 2%; width: 22px; height: 22px; animation-delay: -1.2s; }
.sparkle--c { top: 30%; left: -6%; width: 14px; height: 14px; fill: var(--peach); animation-delay: -2.4s; }

.note--hero {
  display: none;
  right: 92%;
  bottom: 6%;
  flex-direction: column-reverse;
  align-items: flex-end;
  gap: 0;
}
.note--hero .note__arrow { transform: scale(-1, -1) rotate(-12deg); margin: 0 -40px -4px 0; }
@media (min-width: 1100px) {
  .note--hero { display: inline-flex; }
}

.hero__foot { margin-top: clamp(36px, 5vw, 56px); }

/* Status chip */
.status {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  max-width: 100%;
  min-height: 46px;
  padding: 10px 20px 10px 16px;
  border-radius: var(--r-pill);
  background: var(--glass);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow-sm);
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
}
.status__now { color: var(--text); font-weight: 600; white-space: nowrap; }
.status__items { display: flex; flex-wrap: wrap; row-gap: 2px; }
.status__item { white-space: nowrap; }
.status__item + .status__item::before { content: "·"; margin-inline: 0.6em; color: #CDBFDD; }
.status__item b { font-weight: 500; color: var(--muted); }
.status__item span { color: var(--text); }

@media (max-width: 899px) {
  .status { border-radius: var(--r-md); }
  .status__items { position: relative; display: grid; overflow: hidden; }
  .status__item { grid-area: 1 / 1; overflow: hidden; text-overflow: ellipsis; transition: opacity var(--slow) var(--ease), transform var(--slow) var(--ease); }
  .status__item + .status__item::before { content: none; }
  .js .status__item { opacity: 0; transform: translateY(6px); }
  .js .status__item.is-active { opacity: 1; transform: none; }
}

/* At-a-glance figures */
.facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 20px;
  background: var(--glass);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm), inset 0 0 0 1px rgba(255, 255, 255, 0.7);
}
.fact { position: relative; padding: 24px 20px; }
.fact:nth-child(odd) { box-shadow: 1px 0 0 var(--line); }
.fact:nth-child(-n + 2) { border-bottom: 1px solid var(--line); }
.fact__fig {
  font-size: clamp(32px, 3.6vw, 48px);
  font-weight: 500;
  white-space: nowrap;
  font-variant-numeric: lining-nums tabular-nums;
}
.fact__fig small { font-family: var(--font-body); font-size: 0.4em; letter-spacing: 0; margin-left: 0.2em; color: var(--muted); }
.fact__label { margin-top: 8px; color: var(--muted); font-size: 15px; line-height: 1.45; max-width: 28ch; }

.note--proof {
  position: relative;
  margin-top: 12px;
  flex-direction: row-reverse;
  justify-content: flex-end;
  align-items: flex-start;
}
.note--proof .note__arrow { width: 34px; height: 26px; margin-top: -10px; transform: scaleY(-1); }

@media (min-width: 900px) {
  .facts { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .fact { padding: 30px 28px; border-bottom: 0 !important; box-shadow: none !important; }
  .fact + .fact::before {
    content: "";
    position: absolute;
    left: 0; top: 26px; bottom: 26px;
    width: 1px;
    background: var(--line);
  }
  .note--proof { position: absolute; margin: 0; top: 4px; right: 8px; }
  .note--proof .note__arrow { transform: none; }
}

/* Hero entrance — under 2 seconds in total */
@media (prefers-reduced-motion: no-preference) {
  .js .hero [data-rise],
  .js .sel__box,
  .js .sel__h,
  .js .ul__svg path,
  .js .cursor,
  .js .note--hero { animation-play-state: paused; }

  .js .hero [data-rise] {
    opacity: 0;
    animation: rise 800ms var(--ease) both;
    animation-delay: calc(var(--i, 0) * 90ms);
  }
  .js .sel__box { animation: draw-box 420ms var(--ease) 700ms both; }
  .js .sel__h { animation: pop 240ms var(--ease) 1000ms both; }
  .js .ul__svg path {
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
    animation: draw-line 520ms var(--ease) 960ms forwards;
  }
  .js .cursor { animation: glide 700ms var(--ease) 1150ms both; }
  .js .note--hero { animation: fade-in 300ms var(--ease) 1500ms both; }

  .is-ready .hero [data-rise],
  .is-ready .sel__box,
  .is-ready .sel__h,
  .is-ready .ul__svg path,
  .is-ready .cursor,
  .is-ready .note--hero { animation-play-state: running; }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}
@keyframes draw-box {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: none; }
}
@keyframes pop {
  from { transform: scale(0); }
  to { transform: scale(1); }
}
@keyframes draw-line {
  to { stroke-dashoffset: 0; }
}
@keyframes glide {
  0% { opacity: 0; transform: translate(200px, 120px); }
  15% { opacity: 1; }
  100% { opacity: 1; transform: translate(0, 0); }
}
@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ---------- Scroll reveal ---------- */

@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 700ms var(--ease), transform 700ms var(--ease);
    transition-delay: calc(var(--d, 0) * 110ms);
  }
  .js [data-reveal].is-in { opacity: 1; transform: none; }
}

/* ---------- Selected work ---------- */

.work-grid {
  display: grid;
  gap: var(--gutter);
}
@media (min-width: 720px) {
  .work-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.card {
  display: flex;
  flex-direction: column;
  width: 100%;
  padding: 12px;
  text-align: left;
  font: inherit;
  color: inherit;
  background: var(--glass);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm), inset 0 0 0 1px rgba(255, 255, 255, 0.7);
  transition: box-shadow var(--slow) var(--ease), transform var(--slow) var(--ease), opacity 700ms var(--ease);
}
.card:hover,
.card:focus-visible { box-shadow: var(--shadow-md); transform: translateY(-4px); }
.card__media { position: relative; display: block; }
.card .media { display: block; border-radius: var(--r-md); }
.card__media .media > * { transition: transform 600ms var(--ease); }
.card:hover .card__media .media > *,
.card:focus-visible .card__media .media > * { transform: scale(1.03); }

/* Each card gets its own pastel */
.card--pink  { --ph-bg: linear-gradient(135deg, var(--pink-soft), #F8D6E5); }
.card--lilac { --ph-bg: linear-gradient(135deg, var(--accent-soft), #DED0F6); }
.card--peach { --ph-bg: linear-gradient(135deg, var(--peach-soft), #F9DCC9); }
.card--sky   { --ph-bg: linear-gradient(135deg, var(--sky-soft), #D3E1F8); }

.card__cta {
  position: absolute;
  right: 14px; bottom: 14px;
  z-index: 2;
  padding: 10px 16px;
  border-radius: var(--r-pill);
  background: var(--card);
  color: var(--text);
  font: 500 14px/1 var(--font-body);
  box-shadow: var(--shadow-md);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity var(--mid) var(--ease), transform var(--mid) var(--ease);
}
.card:hover .card__cta,
.card:focus-visible .card__cta { opacity: 1; transform: none; }
@media (hover: none) {
  .card__cta { opacity: 1; transform: none; }
}

.card__body { display: block; padding: 18px 10px 10px; }
.card__label { display: block; color: var(--muted); }
.card__label b {
  display: inline-block;
  margin-right: 8px;
  color: var(--accent-text);
  font-weight: 600;
}
.card__title {
  display: block;
  margin-top: 6px;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(24px, 2.3vw, 30px);
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.card .tags { margin-top: 14px; }

/* Writing card: type instead of an image */
.writing-art {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.06em;
  padding: 0 9%;
  background: var(--ph-bg);
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(32px, 4vw, 52px);
  letter-spacing: -0.02em;
  line-height: 1.02;
}
.writing-art span:nth-child(2) { color: #7E92BE; font-style: italic; }
.writing-art span:nth-child(3) { color: #A5B6D9; }
.writing-art .caret {
  display: inline-block;
  width: 0.06em;
  height: 0.8em;
  margin-left: 0.06em;
  vertical-align: -0.04em;
  border-radius: 4px;
  background: var(--accent);
  animation: blink 1.1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* Writing modal */
.modal {
  width: min(880px, calc(100% - 32px));
  max-height: min(86vh, 900px);
  padding: 0;
  background: var(--bg) var(--grad-soft);
  border: 0;
  border-radius: var(--r-xl);
  box-shadow: 0 30px 80px rgba(45, 36, 56, 0.25);
  overflow: hidden;
}
.modal[open] { display: flex; flex-direction: column; animation: modal-in var(--slow) var(--ease); }
.modal::backdrop { background: rgba(45, 36, 56, 0.28); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
@keyframes modal-in { from { opacity: 0; transform: translateY(12px) scale(0.98); } to { opacity: 1; transform: none; } }
.modal__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 20px 20px 0 28px;
}
.modal__body { overflow-y: auto; padding: 8px 28px 28px; }
.modal__title { font-size: clamp(32px, 4vw, 48px); margin-bottom: 8px; }
.samples { display: grid; gap: 14px; margin-top: 24px; }
@media (min-width: 720px) { .samples { grid-template-columns: 1fr 1fr; } }
.sample {
  padding: 22px 24px;
  background: var(--card);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-sm);
}
.sample__label { color: var(--accent-text); }
.sample__text { margin-top: 10px; font-size: 1.05em; }

/* ---------- The CV ---------- */

.cv-mode {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  margin-top: 16px;
}

/* Segmented control */
.seg {
  display: inline-flex;
  padding: 4px;
  border-radius: var(--r-pill);
  background: var(--glass);
  box-shadow: inset 0 0 0 1px var(--line);
}
.seg button {
  min-height: 36px;
  padding: 0 20px;
  border-radius: var(--r-pill);
  font: 500 14px/1 var(--font-body);
  color: var(--muted);
  transition: background-color var(--mid) var(--ease), color var(--mid) var(--ease), box-shadow var(--mid) var(--ease);
}
.seg button[aria-pressed="true"] { background: var(--text); color: var(--on-dark); box-shadow: 0 2px 8px rgba(45, 36, 56, 0.18); }

/* Two columns, like a printed CV: details on the side, experience in the main column */
.cv-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--gutter);
  align-items: start;
}
.cv-side, .cv-col { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--gutter); min-width: 0; }
@media (min-width: 1024px) {
  .cv-layout { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); }
  .cv-col { grid-column: 2; grid-row: 1; }
  .cv-side { grid-column: 1; grid-row: 1; position: sticky; top: calc(var(--nav-h) + 24px); }
}

.contact-list { display: grid; gap: 12px; font-size: 15px; }
.contact-list li { display: flex; align-items: center; gap: 12px; min-width: 0; }
.contact-list svg {
  flex: none;
  width: 34px; height: 34px;
  padding: 8px;
  border-radius: 50%;
  background: var(--accent-soft);
  fill: none;
  stroke: var(--accent-text);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.contact-list a { overflow-wrap: anywhere; transition: color var(--fast) var(--ease); }
.contact-list a:hover { color: var(--accent-text); }

.rows li { padding-block: 14px; }
.rows li:first-child { padding-top: 0; }
.rows li:last-child { padding-bottom: 0; }
.rows li + li { border-top: 1px solid var(--line); }
.rows__year { color: var(--accent-text); }
.rows__title { margin-top: 2px; font-weight: 600; font-size: 16px; line-height: 1.4; }
.rows__meta { color: var(--muted); font-size: 15px; }
.rows__note { margin-top: 6px; font-size: 15px; line-height: 1.5; color: #54485F; }

.toolkit__grid { display: grid; gap: 18px 28px; }
@media (min-width: 720px) {
  .toolkit__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.toolkit__cat h4 { color: var(--muted); margin-bottom: 10px; }
.toolkit .chips { gap: 6px; }
.toolkit .chip { min-height: 30px; padding: 0 12px; font-size: 13px; background: var(--surface); box-shadow: none; }

.cv-main { padding: clamp(22px, 3vw, 40px); }
.cv-main__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
}
.cv-main__head .panel__title { margin: 0; }
.cv-filter { min-width: 0; max-width: 100%; }
.cv-filter .chip { min-height: 32px; padding: 0 13px; font-size: 13px; }
@media (max-width: 1023px) {
  .cv-filter { flex-basis: 100%; }
  .cv-filter .chips--scroll { margin-inline: -22px; padding-inline: 22px; }
}

.cv-readout {
  display: inline-flex;
  margin-top: 18px;
  padding: 7px 14px;
  border-radius: var(--r-pill);
  background: var(--accent-soft);
  color: var(--accent-text);
}
.cv-readout[hidden] { display: none; }

/* Timeline */
.timeline { position: relative; margin-top: 8px; }
.tl-item {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
  padding-block: 24px;
}
.tl-item + .tl-item { border-top: 1px solid var(--line); }
.tl-year { color: var(--muted); }
.tl-year b { color: var(--text); font-weight: 600; }

@media (min-width: 720px) {
  .tl-item { grid-template-columns: 112px minmax(0, 1fr); gap: 24px; padding-block: 28px; }
  .tl-year { position: relative; padding-left: 20px; padding-top: 4px; }
  .tl-year::before {
    content: "";
    position: absolute;
    left: 0; top: 11px;
    width: 9px; height: 9px;
    border-radius: 50%;
    background: var(--card);
    box-shadow: inset 0 0 0 2px var(--accent);
  }
  .tl-item:first-child .tl-year::before { background: var(--pink); box-shadow: 0 0 0 4px var(--pink-soft); }
}

.role-card { transition: opacity var(--slow) var(--ease); }
.role-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(21px, 2vw, 26px);
  letter-spacing: -0.015em;
  line-height: 1.15;
}
.role-title .at { color: var(--muted); font-style: italic; font-weight: 400; }
.role-meta { margin-top: 6px; color: var(--muted); }
.role-context { margin-top: 2px; color: var(--muted); }
.role-skim { margin-top: 12px; max-width: 62ch; color: #4A3F55; }
.role-card > .tags,
.sub > .tags { margin-top: 16px; }

/* Skim / Full: the Full bullets expand in place */
.role-full {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 450ms var(--ease);
}
.role-full > div {
  min-height: 0;
  overflow: hidden;
  visibility: hidden;
  opacity: 0;
  transition: visibility 0s linear 450ms, opacity 300ms var(--ease);
}
[data-mode="full"] .role-full { grid-template-rows: 1fr; }
[data-mode="full"] .role-full > div { visibility: visible; opacity: 1; transition: visibility 0s, opacity 400ms var(--ease) 120ms; }
[data-mode="full"] .skim-only { display: none; }
.role-full > div > .role-context:first-child { margin-top: 12px; }

.bullets { margin-top: 14px; display: grid; gap: 10px; }
.bullets li {
  position: relative;
  padding-left: 22px;
  max-width: 66ch;
  font-size: 16px;
  transition: color var(--fast) var(--ease);
}
.bullets li::before {
  content: "";
  position: absolute;
  left: 3px; top: 0.6em;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #D8CAEC;
  transition: background-color var(--fast) var(--ease);
}
.is-filtered .bullets li { color: var(--muted); }
.is-filtered .bullets li.is-match { color: var(--accent-text); }
.is-filtered .bullets li.is-match::before { background: var(--accent); }

.is-dim { opacity: 0.35; }

.role-clients { margin-top: 10px; color: var(--muted); }

.sub { padding-top: 20px; margin-top: 20px; border-top: 1px dashed var(--line); transition: opacity var(--slow) var(--ease); }
.sub-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(18px, 1.6vw, 21px);
  letter-spacing: -0.01em;
  line-height: 1.2;
}
.sub-title .at { color: var(--muted); font-style: italic; font-weight: 400; }

.cv-foot { margin-top: 8px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--muted); }

/* ---------- About ---------- */

.about {
  display: grid;
  gap: 48px;
  align-items: start;
}
@media (min-width: 1024px) {
  .about { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 72px; }
  .about-photos { position: sticky; top: calc(var(--nav-h) + 32px); }
}
.about-photos { position: relative; max-width: 460px; }
.about-photos .media {
  border-radius: 220px 220px var(--r-xl) var(--r-xl); /* arch */
  box-shadow: var(--shadow-md);
  outline: 10px solid rgba(255, 255, 255, 0.7);
  outline-offset: -1px;
}
.about-photos .media img { object-position: 50% 30%; }
.sparkle--d { top: 6%; right: -10px; width: 30px; height: 30px; fill: var(--pink); }

.about-text .h2 { margin-bottom: 22px; }
.about-text .prose { font-size: clamp(17px, 1.4vw, 19px); color: #4A3F55; }

.subhead {
  font: 500 clamp(22px, 2vw, 26px)/1.1 var(--font-display);
  letter-spacing: -0.015em;
  margin: clamp(40px, 5vw, 56px) 0 18px;
}

.principles { display: grid; gap: 14px; }
@media (min-width: 720px) {
  .principles { grid-template-columns: 1fr 1fr; }
}
.principle {
  padding: 22px 22px 24px;
  background: var(--glass);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-sm), inset 0 0 0 1px rgba(255, 255, 255, 0.7);
  transition: transform var(--slow) var(--ease), box-shadow var(--slow) var(--ease), opacity 700ms var(--ease);
}
.principle:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.principle__title {
  display: flex;
  align-items: center;
  gap: 10px;
  font: 500 19px/1.2 var(--font-display);
  letter-spacing: -0.01em;
}
.principle__title span {
  display: grid;
  place-items: center;
  flex: none;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--grad-soft);
  box-shadow: inset 0 0 0 1px rgba(181, 151, 234, 0.35);
  color: var(--accent-text);
  font: 600 13px/1 var(--font-body);
}
.principle:nth-child(2) .principle__title span { background: var(--pink-soft); }
.principle:nth-child(3) .principle__title span { background: var(--peach-soft); }
.principle:nth-child(4) .principle__title span { background: var(--sky-soft); }
.principle p { margin-top: 10px; color: var(--muted); font-size: 15px; line-height: 1.55; }

.offclock {
  margin-top: 28px;
  padding: 20px 22px;
  border-radius: var(--r-md);
  background: var(--grad-soft);
  font-size: 15px;
  line-height: 1.6;
  color: #4A3F55;
}
.offclock b { color: var(--accent-text); font-weight: 600; }

/* ---------- Contact ---------- */

.contact-panel {
  position: relative;
  overflow: hidden;
  padding: clamp(40px, 7vw, 96px) clamp(24px, 6vw, 88px) clamp(64px, 8vw, 112px);
  background:
    radial-gradient(60% 80% at 100% 0%, rgba(239, 163, 196, 0.45), transparent 70%),
    radial-gradient(60% 80% at 0% 100%, rgba(175, 200, 241, 0.5), transparent 70%),
    radial-gradient(50% 60% at 70% 100%, rgba(246, 191, 156, 0.4), transparent 70%),
    var(--accent-soft);
  border-radius: var(--r-xl);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.7);
}
.contact-panel .eyebrow { background: rgba(255, 255, 255, 0.8); }
.contact__title { font-size: clamp(40px, 6vw, 88px); letter-spacing: -0.01em; max-width: 12em; }
.contact__line { margin-top: 24px; color: #54485F; }
.contact__actions {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 36px;
}
.contact__email { position: relative; }
.sparkle--e { top: 14%; right: 9%; width: 44px; height: 44px; fill: #fff; }
.sparkle--f { top: 30%; right: 16%; width: 20px; height: 20px; fill: var(--accent); animation-delay: -1.8s; }

.note--contact {
  position: relative;
  margin-top: 16px;
  flex-direction: row-reverse;
  justify-content: flex-end;
  align-items: flex-start;
}
.note--contact .note__arrow { width: 34px; height: 28px; margin-top: -12px; }
@media (min-width: 900px) {
  .note--contact {
    position: absolute;
    left: 30px;
    top: calc(100% + 14px);
    margin: 0;
  }
}

/* ---------- Footer ---------- */

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  padding-block: 32px calc(36px + env(safe-area-inset-bottom));
  color: var(--muted);
}

/* ---------- Case studies ---------- */

.case-head { padding-top: calc(var(--nav-h) + clamp(28px, 5vw, 56px)); }
.case-head .back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px 8px 12px;
  border-radius: var(--r-pill);
  background: var(--glass);
  box-shadow: var(--shadow-sm);
  color: var(--text);
  transition: box-shadow var(--fast) var(--ease), transform var(--fast) var(--ease);
}
.case-head .back:hover { box-shadow: var(--shadow-md); transform: translateX(-3px); }
.case-title {
  margin-top: clamp(32px, 5vw, 64px);
  font-size: clamp(54px, 10vw, 144px);
  letter-spacing: -0.035em;
}
.case-lede { margin-top: 22px; font-size: clamp(20px, 2vw, 25px); line-height: 1.4; max-width: 36ch; color: #4A3F55; }

.case-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin-top: clamp(32px, 5vw, 52px);
  padding: 8px;
  background: var(--glass);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm), inset 0 0 0 1px rgba(255, 255, 255, 0.7);
}
.case-meta div { padding: 14px 16px; }
.case-meta dt { color: var(--muted); }
.case-meta dd { margin-top: 4px; color: var(--text); font-weight: 600; }
@media (min-width: 900px) {
  .case-meta { grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 10px; }
  .case-meta div { padding: 18px 22px; }
  .case-meta div + div { box-shadow: -1px 0 0 var(--line); }
}

.case-hero { margin-top: clamp(24px, 4vw, 44px); }
.case-hero .media { border-radius: var(--r-xl); }

.case-body { padding-block: clamp(56px, 8vw, 104px); }
.case-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px var(--gutter);
  padding-block: clamp(28px, 4vw, 44px);
}
.case-row + .case-row { border-top: 1px solid var(--line); }
.case-row:first-child { padding-top: 0; }
.case-row__label { color: var(--text); font: 500 22px/1.2 var(--font-display); letter-spacing: -0.015em; padding-top: 3px; }
.case-row__label b {
  display: inline-grid;
  place-items: center;
  width: 32px; height: 32px;
  margin-right: 10px;
  border-radius: 50%;
  background: var(--grad-soft);
  box-shadow: inset 0 0 0 1px rgba(181, 151, 234, 0.35);
  color: var(--accent-text);
  font: 600 13px/1 var(--font-body);
  vertical-align: 2px;
}
.case-row__content { font-size: clamp(17px, 1.4vw, 19px); }
.case-row__content > p { max-width: 60ch; }
.case-row__content > p + p { margin-top: 1em; }
@media (min-width: 900px) {
  .case-row { grid-template-columns: repeat(12, minmax(0, 1fr)); }
  .case-row__label { grid-column: span 3; position: sticky; top: calc(var(--nav-h) + 24px); align-self: start; }
  .case-row__content { grid-column: span 9; }
}

.owned { display: grid; gap: 12px; }
.owned li {
  position: relative;
  padding-left: 28px;
  max-width: 60ch;
}
.owned li::before {
  content: "";
  position: absolute;
  left: 2px; top: 0.4em;
  width: 13px; height: 13px;
  background: linear-gradient(135deg, var(--pink), var(--accent));
  -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 0C12.6 6.6 17.4 11.4 24 12 17.4 12.6 12.6 17.4 12 24 11.4 17.4 6.6 12.6 0 12 6.6 11.4 11.4 6.6 12 0Z'/></svg>") center / contain no-repeat;
  mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 0C12.6 6.6 17.4 11.4 24 12 17.4 12.6 12.6 17.4 12 24 11.4 17.4 6.6 12.6 0 12 6.6 11.4 11.4 6.6 12 0Z'/></svg>") center / contain no-repeat;
}

.sub-label { color: var(--muted); margin-bottom: 14px; }

.gallery {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--gutter);
  margin-top: 8px;
}
.gallery figure { grid-column: 1 / -1; }
.gallery figcaption { display: flex; justify-content: space-between; gap: 12px; margin: 10px 4px 0; color: var(--muted); }
.gallery .media { transition: transform var(--slow) var(--ease), box-shadow var(--slow) var(--ease); }
.gallery figure:hover .media { transform: translateY(-3px); box-shadow: var(--shadow-md); }
@media (min-width: 720px) {
  .gallery .g-3 { grid-column: span 4; }
  .gallery .g-2 { grid-column: span 6; }
  .gallery .g-1 { grid-column: 1 / -1; }
}
/* Alternate the placeholder pastels so a gallery reads as a set */
.gallery figure:nth-child(4n + 1) { --ph-bg: linear-gradient(135deg, var(--pink-soft), var(--accent-soft)); }
.gallery figure:nth-child(4n + 2) { --ph-bg: linear-gradient(135deg, var(--accent-soft), var(--sky-soft)); }
.gallery figure:nth-child(4n + 3) { --ph-bg: linear-gradient(135deg, var(--peach-soft), var(--pink-soft)); }
.gallery figure:nth-child(4n + 4) { --ph-bg: linear-gradient(135deg, var(--sky-soft), var(--accent-soft)); }

.callout {
  position: relative;
  padding: clamp(28px, 4vw, 48px);
  background: var(--grad-soft);
  border-radius: var(--r-lg);
}
.callout p {
  font-family: var(--font-display);
  font-weight: 400;
  font-style: italic;
  font-size: clamp(24px, 2.6vw, 34px);
  letter-spacing: -0.015em;
  line-height: 1.2;
  max-width: 28ch;
}

/* SAEV: "Make it human" microcopy flips */
.microcopy { display: grid; gap: 16px; margin-bottom: 40px; }
@media (min-width: 900px) { .microcopy { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.mc {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 28px;
  padding: 24px;
  background: var(--glass);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm), inset 0 0 0 1px rgba(255, 255, 255, 0.7);
  min-height: 230px;
  transition: background-color var(--mid) var(--ease);
}
.mc[data-human="true"] { background: var(--accent-soft); }
.mc__label { color: var(--muted); }
.mc__text {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(22px, 2vw, 27px);
  letter-spacing: -0.015em;
  line-height: 1.18;
  transition: opacity var(--fast) var(--ease);
}
.mc__text.is-swapping { opacity: 0; }
.mc__foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.mc__state { color: var(--muted); }
.mc[data-human="true"] .mc__state { color: var(--accent-text); }

/* iOS-style switch */
.switch {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font: 500 14px/1 var(--font-body);
  color: var(--text);
}
.switch__track {
  position: relative;
  width: 46px; height: 28px;
  border-radius: var(--r-pill);
  background: #E2D9EC;
  transition: background-color var(--mid) var(--ease);
}
.switch__track::after {
  content: "";
  position: absolute;
  top: 3px; left: 3px;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--card);
  box-shadow: 0 2px 4px rgba(45, 36, 56, 0.2);
  transition: transform var(--mid) var(--ease);
}
.switch[aria-pressed="true"] .switch__track { background: var(--accent); }
.switch[aria-pressed="true"] .switch__track::after { transform: translateX(18px); }

.text-samples { display: grid; gap: 16px; margin-top: 14px; }
@media (min-width: 900px) { .text-samples { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.next-case { padding-bottom: clamp(24px, 4vw, 48px); }
.next-case a {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 32px;
  padding: clamp(32px, 6vw, 72px) clamp(24px, 5vw, 64px);
  background: var(--grad-soft);
  border-radius: var(--r-xl);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.7);
  transition: box-shadow var(--mid) var(--ease), transform var(--mid) var(--ease);
}
.next-case a:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.next-case .label { color: var(--muted); display: block; margin-bottom: 12px; }
.next-case .display { font-size: clamp(40px, 6.6vw, 96px); }
.next-case .arrow {
  display: grid;
  place-items: center;
  width: clamp(56px, 7vw, 88px);
  height: clamp(56px, 7vw, 88px);
  border-radius: 50%;
  background: var(--text);
  color: var(--on-dark);
  font-size: clamp(24px, 3vw, 36px);
  transition: transform var(--mid) var(--ease), background-color var(--mid) var(--ease);
}
.next-case a:hover .arrow { transform: translateX(6px); background: var(--accent-text); }

/* ---------- 404 ---------- */

.lost { min-height: 100svh; display: flex; align-items: center; padding-top: var(--nav-h); }
.lost .h1 { margin: 8px 0 32px; }

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  body::before, .dot-live::after, .writing-art .caret, .sparkle, .portrait, .portrait__ring { animation: none; }
}
