/*
Theme Name: Cook — Operator's Almanac
Theme URI: https://kevinbarrycook.com
Author: Kevin Barry Cook
Description: A custom WordPress theme positioning Kevin Barry Cook as a Director of AI Visibility & Growth Strategy. Editorial-operator aesthetic: serif display, sans body, mono accents. Built to be its own demo of AI-readable, schema-rich, performance-tuned modern discoverability.
Version: 1.0
License: Proprietary — All rights reserved.
Text Domain: cook-almanac
*/

/* ============================================================
   01 / TOKENS
   Three-color discipline. No gradients. Mono for data.
   ============================================================ */
:root {
  /* Color */
  --ink: #0E0E0C;
  --ink-soft: #2B2A28;
  --bone: #F4F1EA;
  --bone-warm: #EDE8DD;
  --rule: #1A1A18;        /* Hairlines on light bg should be near-black, not gray */
  --rule-soft: #D9D2C5;   /* When near-black is too loud */
  --mute: #6B6760;
  --ember: #E55A2B;
  --paper: #FBF9F4;

  /* Type */
  --display: 'Fraunces', 'Times New Roman', Georgia, serif;
  --body: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;

  /* Spacing — based on a 4pt grid */
  --s-1: 0.25rem;
  --s-2: 0.5rem;
  --s-3: 0.75rem;
  --s-4: 1rem;
  --s-6: 1.5rem;
  --s-8: 2rem;
  --s-12: 3rem;
  --s-16: 4rem;
  --s-24: 6rem;
  --s-32: 8rem;
  --s-48: 12rem;

  /* Layout */
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --max: 1280px;
  --measure: 64ch;
  --header-h: 64px;

  /* Motion */
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --t-fast: 160ms;
  --t-med: 320ms;
  --t-slow: 640ms;
}

/* ============================================================
   02 / RESET & BASE
   ============================================================ */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  background: var(--bone);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.55;
  font-feature-settings: "kern", "liga", "ss01";
  /* Subtle dot-grid — the 'operator' texture. Almost invisible but there. */
  background-image: radial-gradient(
    circle at 1px 1px,
    rgba(14, 14, 12, 0.06) 1px,
    transparent 0
  );
  background-size: 24px 24px;
}

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

a {
  color: inherit;
  text-decoration: none;
}

ul,
ol {
  list-style: none;
}

button {
  font: inherit;
  background: none;
  border: none;
  cursor: pointer;
  color: inherit;
}

::selection {
  background: var(--ember);
  color: var(--paper);
}

/* ============================================================
   03 / TYPOGRAPHY
   Display = Fraunces. Body = Plex Sans. Data = JetBrains Mono.
   ============================================================ */
h1,
h2,
h3,
h4 {
  font-family: var(--display);
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.02;
  font-feature-settings: "ss01", "ss02";
}

h1 {
  font-size: clamp(2.75rem, 7vw, 6.5rem);
  font-weight: 350;
}

h2 {
  font-size: clamp(2rem, 4.5vw, 4rem);
  font-weight: 350;
}

h3 {
  font-size: clamp(1.5rem, 2.5vw, 2.25rem);
  font-weight: 400;
}

h4 {
  font-size: 1.125rem;
  font-weight: 500;
}

p {
  max-width: var(--measure);
}

em {
  font-style: italic;
  /* Fraunces italics are gorgeous — give them room */
  font-feature-settings: "ss01";
}

strong {
  font-weight: 600;
}

/* The system marker — Section ID in monospace, the signature element */
.marker {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--mute);
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
}

.marker::before {
  content: "§";
  color: var(--ember);
  font-weight: 600;
}

.marker--bare::before {
  display: none;
}

/* Mono utility — for any data, metadata, or "system UI" */
.mono {
  font-family: var(--mono);
  font-size: 0.82rem;
  letter-spacing: 0.01em;
}

/* Eyebrow / kicker text */
.kicker {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mute);
}

/* Pull quote / thesis statement */
.thesis {
  font-family: var(--display);
  font-size: clamp(1.5rem, 2.6vw, 2.25rem);
  font-weight: 350;
  line-height: 1.25;
  letter-spacing: -0.015em;
  max-width: 28ch;
}

.thesis em {
  color: var(--ember);
}

/* ============================================================
   04 / LAYOUT
   ============================================================ */
.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  position: relative;
  padding-block: clamp(var(--s-16), 10vw, var(--s-32));
  border-top: 1px solid var(--rule);
}

.section:first-of-type {
  border-top: none;
}

.section__head {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: var(--s-8);
  margin-bottom: var(--s-12);
  align-items: baseline;
}

@media (max-width: 720px) {
  .section__head {
    grid-template-columns: 1fr;
    gap: var(--s-3);
  }
}

.section__title {
  max-width: 18ch;
}

/* Hairline rule — used everywhere, the "page" feel */
.rule {
  border: 0;
  border-top: 1px solid var(--rule);
  margin: 0;
}

.rule--soft {
  border-color: var(--rule-soft);
}

/* ============================================================
   05 / HEADER & NAVIGATION
   ============================================================ */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(244, 241, 234, 0.85);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--t-med) var(--ease);
}

.site-header.is-scrolled {
  border-bottom-color: var(--rule);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: baseline;
  gap: var(--s-2);
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  color: var(--ink);
}

.brand__mark {
  font-family: var(--display);
  font-size: 1.4rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  font-style: italic;
}

.brand__role {
  color: var(--mute);
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

@media (max-width: 540px) {
  .brand__role {
    display: none;
  }
}

.nav {
  display: flex;
  align-items: center;
  gap: var(--s-8);
}

.nav a {
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  position: relative;
  padding-block: var(--s-2);
  transition: color var(--t-fast) var(--ease);
}

.nav a:hover,
.nav a.is-active {
  color: var(--ember);
}

.nav a::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: 2px;
  height: 1px;
  width: 0;
  background: var(--ember);
  transition: width var(--t-med) var(--ease);
}

.nav a:hover::before,
.nav a.is-active::before {
  width: 100%;
}

.nav-cta {
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--paper) !important;
  background: var(--ink);
  padding: 0.55rem 0.9rem !important;
  border: 1px solid var(--ink);
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}

.nav-cta:hover {
  background: var(--ember);
  border-color: var(--ember);
  color: var(--paper) !important;
}

.nav-cta::before {
  display: none !important;
}

.nav-toggle {
  display: none;
  width: 32px;
  height: 32px;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 1px;
  background: var(--ink);
  transition: transform var(--t-fast) var(--ease);
}

@media (max-width: 880px) {
  .nav {
    display: none;
  }
  .nav-toggle {
    display: flex;
  }
  .nav.is-open {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    position: fixed;
    inset: var(--header-h) 0 0 0;
    background: var(--bone);
    padding: var(--s-12) var(--gutter);
    gap: var(--s-6);
    z-index: 99;
    border-top: 1px solid var(--rule);
  }
  .nav.is-open a {
    font-size: 1rem;
  }
}

/* ============================================================
   06 / HERO — the thesis
   ============================================================ */
.hero {
  padding-top: calc(var(--header-h) + var(--s-16));
  padding-bottom: var(--s-24);
  position: relative;
}

.hero__meta {
  display: grid;
  grid-template-columns: 200px 1fr 200px;
  gap: var(--s-8);
  align-items: baseline;
  margin-bottom: var(--s-16);
  padding-bottom: var(--s-4);
  border-bottom: 1px solid var(--rule);
}

@media (max-width: 880px) {
  .hero__meta {
    grid-template-columns: 1fr;
    gap: var(--s-2);
  }
}

.hero__meta-item {
  font-family: var(--mono);
  font-size: 0.74rem;
  color: var(--mute);
  letter-spacing: 0.02em;
}

.hero__meta-item:nth-child(2) {
  text-align: center;
}

.hero__meta-item:nth-child(3) {
  text-align: right;
}

@media (max-width: 880px) {
  .hero__meta-item:nth-child(2),
  .hero__meta-item:nth-child(3) {
    text-align: left;
  }
}

.hero__meta-item strong {
  color: var(--ink);
  font-weight: 500;
}

.hero__lede {
  font-family: var(--display);
  font-weight: 350;
  font-size: clamp(2.5rem, 6.5vw, 6rem);
  line-height: 0.98;
  letter-spacing: -0.025em;
  max-width: 18ch;
  margin-bottom: var(--s-8);
}

.hero__lede em {
  color: var(--ember);
  font-feature-settings: "ss01";
}

.hero__sub {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: var(--s-8);
  margin-top: var(--s-12);
  padding-top: var(--s-6);
  border-top: 1px solid var(--rule);
}

@media (max-width: 720px) {
  .hero__sub {
    grid-template-columns: 1fr;
    gap: var(--s-3);
  }
}

.hero__sub p {
  font-size: 1.0625rem;
  line-height: 1.55;
  max-width: 60ch;
  color: var(--ink-soft);
}

.hero__cta {
  margin-top: var(--s-8);
  display: flex;
  gap: var(--s-3);
  flex-wrap: wrap;
}

/* ============================================================
   07 / TICKER — the capability marquee, repositioned
   ============================================================ */
.ticker {
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  background: var(--ink);
  color: var(--paper);
  padding-block: var(--s-3);
  overflow: hidden;
  white-space: nowrap;
}

.ticker__track {
  display: inline-flex;
  gap: var(--s-12);
  animation: ticker-scroll 60s linear infinite;
  padding-left: var(--s-12);
}

.ticker__item {
  font-family: var(--mono);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  color: var(--paper);
  display: inline-flex;
  align-items: center;
  gap: var(--s-12);
}

.ticker__item::after {
  content: "/";
  color: var(--ember);
  margin-left: var(--s-12);
}

@keyframes ticker-scroll {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

/* ============================================================
   08 / BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.85rem 1.4rem;
  border: 1px solid var(--ink);
  cursor: pointer;
  transition: all var(--t-fast) var(--ease);
  text-decoration: none;
  position: relative;
}

.btn--primary {
  background: var(--ink);
  color: var(--paper);
}

.btn--primary:hover {
  background: var(--ember);
  border-color: var(--ember);
}

.btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--ink);
}

.btn--ghost:hover {
  background: var(--ink);
  color: var(--paper);
}

.btn .arrow {
  transition: transform var(--t-fast) var(--ease);
}

.btn:hover .arrow {
  transform: translateX(3px);
}

/* ============================================================
   09 / CASE STUDIES (Work)
   Editorial card with mono metadata.
   ============================================================ */
.cases {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

.case {
  display: grid;
  grid-template-columns: 200px 1fr 1fr;
  gap: var(--s-8);
  padding-block: var(--s-8);
  border-bottom: 1px solid var(--rule);
  align-items: start;
  transition: background var(--t-fast) var(--ease);
}

.case:hover {
  background: var(--paper);
}

@media (max-width: 880px) {
  .case {
    grid-template-columns: 1fr;
    gap: var(--s-4);
  }
}

.case__index {
  font-family: var(--mono);
  font-size: 0.74rem;
  color: var(--mute);
  letter-spacing: 0.02em;
}

.case__index strong {
  display: block;
  color: var(--ink);
  font-weight: 500;
  margin-bottom: var(--s-2);
}

.case__body h3 {
  margin-bottom: var(--s-3);
}

.case__body h3 a {
  background-image: linear-gradient(var(--ember), var(--ember));
  background-size: 0 1px;
  background-position: 0 100%;
  background-repeat: no-repeat;
  transition: background-size var(--t-med) var(--ease);
}

.case:hover .case__body h3 a {
  background-size: 100% 1px;
}

.case__thesis {
  font-family: var(--display);
  font-style: italic;
  font-size: 1.0625rem;
  color: var(--ink-soft);
  line-height: 1.45;
  max-width: 50ch;
  margin-bottom: var(--s-3);
}

.case__excerpt {
  color: var(--ink-soft);
  font-size: 0.95rem;
  line-height: 1.55;
}

.case__metrics {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  font-family: var(--mono);
  font-size: 0.82rem;
}

.metric {
  display: flex;
  justify-content: space-between;
  padding-bottom: var(--s-2);
  border-bottom: 1px dashed var(--rule-soft);
  gap: var(--s-4);
}

.metric__label {
  color: var(--mute);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  font-size: 0.7rem;
  align-self: end;
}

.metric__value {
  color: var(--ink);
  font-weight: 500;
  text-align: right;
  font-size: 0.95rem;
}

.metric__value--ember {
  color: var(--ember);
}

/* ============================================================
   10 / FRAMEWORKS — the differentiator section
   Cards that look like documentation/spec sheets.
   ============================================================ */
.frameworks {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
}

@media (max-width: 720px) {
  .frameworks {
    grid-template-columns: 1fr;
  }
}

.framework {
  background: var(--bone);
  padding: var(--s-8);
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  transition: background var(--t-fast) var(--ease);
  position: relative;
}

.framework:hover {
  background: var(--paper);
}

.framework__id {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--ember);
  letter-spacing: 0.05em;
}

.framework__title {
  font-family: var(--display);
  font-size: 1.75rem;
  line-height: 1.1;
  letter-spacing: -0.02em;
  font-weight: 400;
  margin-bottom: var(--s-2);
}

.framework__desc {
  color: var(--ink-soft);
  font-size: 0.95rem;
  line-height: 1.55;
}

.framework__spec {
  margin-top: var(--s-4);
  padding-top: var(--s-4);
  border-top: 1px dashed var(--rule-soft);
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--mute);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--s-2);
}

.framework__spec strong {
  color: var(--ink);
  font-weight: 500;
}

/* ============================================================
   11 / AI VISIBILITY DEMO BLOCK
   The meta proof. The site IS the demo.
   ============================================================ */
.ai-demo {
  background: var(--ink);
  color: var(--paper);
  padding-block: var(--s-24);
  position: relative;
  overflow: hidden;
}

.ai-demo .marker {
  color: var(--bone-warm);
}

.ai-demo .marker::before {
  color: var(--ember);
}

.ai-demo h2 {
  color: var(--paper);
  margin-bottom: var(--s-6);
}

.ai-demo h2 em {
  color: var(--ember);
}

.ai-demo__intro {
  color: var(--bone-warm);
  font-size: 1.0625rem;
  max-width: 60ch;
  margin-bottom: var(--s-12);
}

.terminal {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.12);
  font-family: var(--mono);
  font-size: 0.875rem;
  line-height: 1.7;
  position: relative;
}

.terminal__chrome {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.6rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.02);
}

.terminal__chrome-dots {
  display: flex;
  gap: 6px;
}

.terminal__chrome-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
}

.terminal__chrome-label {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.74rem;
  letter-spacing: 0.04em;
}

.terminal__body {
  padding: var(--s-6);
  color: var(--bone-warm);
}

.terminal .prompt {
  color: var(--ember);
  font-weight: 500;
}

.terminal .you {
  color: var(--paper);
}

.terminal .ai {
  color: var(--bone-warm);
  display: block;
  margin-top: var(--s-3);
  margin-bottom: var(--s-4);
  padding-left: var(--s-4);
  border-left: 2px solid var(--ember);
}

.terminal .blink::after {
  content: "▍";
  color: var(--ember);
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  50% {
    opacity: 0;
  }
}

/* ============================================================
   12 / BIO / ABOUT
   Two-column editorial — sticky portrait, running text.
   ============================================================ */
.bio__grid {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: var(--s-12);
  align-items: start;
}

@media (max-width: 880px) {
  .bio__grid {
    grid-template-columns: 1fr;
  }
}

.bio__rail {
  position: sticky;
  top: calc(var(--header-h) + var(--s-8));
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}

.bio__portrait {
  width: 100%;
  aspect-ratio: 4/5;
  background: var(--rule-soft);
  object-fit: cover;
  filter: grayscale(100%);
  transition: filter var(--t-slow) var(--ease);
}

.bio__portrait:hover {
  filter: grayscale(0%);
}

.bio__rail-meta {
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--mute);
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  padding-top: var(--s-3);
  border-top: 1px solid var(--rule);
}

.bio__rail-meta div {
  display: flex;
  justify-content: space-between;
  gap: var(--s-3);
}

.bio__rail-meta strong {
  color: var(--ink);
  font-weight: 500;
}

.bio__body {
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink-soft);
}

.bio__body p {
  margin-bottom: var(--s-4);
  max-width: 64ch;
}

.bio__body p:first-of-type::first-letter {
  font-family: var(--display);
  font-size: 4.5rem;
  font-weight: 350;
  float: left;
  line-height: 0.85;
  margin-right: 0.6rem;
  margin-top: 0.4rem;
  color: var(--ember);
}

.bio__numbers {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
  margin-top: var(--s-12);
}

@media (max-width: 720px) {
  .bio__numbers {
    grid-template-columns: repeat(2, 1fr);
  }
}

.num {
  background: var(--bone);
  padding: var(--s-6);
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

.num__value {
  font-family: var(--display);
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1;
  font-weight: 350;
  letter-spacing: -0.02em;
}

.num__value span {
  color: var(--ember);
}

.num__label {
  font-family: var(--mono);
  font-size: 0.74rem;
  color: var(--mute);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ============================================================
   13 / FIELD NOTES (Blog)
   ============================================================ */
.notes {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

.note {
  display: grid;
  grid-template-columns: 200px 1fr 220px;
  gap: var(--s-8);
  padding-block: var(--s-6);
  border-bottom: 1px solid var(--rule);
  align-items: start;
  transition: background var(--t-fast) var(--ease);
}

.note:hover {
  background: var(--paper);
}

@media (max-width: 880px) {
  .note {
    grid-template-columns: 1fr;
    gap: var(--s-3);
  }
}

.note__date {
  font-family: var(--mono);
  font-size: 0.74rem;
  color: var(--mute);
  letter-spacing: 0.02em;
}

.note__title {
  font-family: var(--display);
  font-size: 1.5rem;
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 1.2;
  transition: color var(--t-fast) var(--ease);
}

.note:hover .note__title {
  color: var(--ember);
}

.note__excerpt {
  font-size: 0.92rem;
  color: var(--mute);
  margin-top: var(--s-2);
  line-height: 1.55;
}

.note__tags {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--mute);
  text-align: right;
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
}

@media (max-width: 880px) {
  .note__tags {
    text-align: left;
  }
}

/* ============================================================
   14 / CONTACT / DUAL CTA
   Split for both audiences: hiring & consulting.
   ============================================================ */
.contact {
  background: var(--paper);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding-block: var(--s-24);
}

.contact__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}

@media (max-width: 880px) {
  .contact__grid {
    grid-template-columns: 1fr;
  }
}

.contact__card {
  padding: var(--s-12) var(--s-8);
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  border-right: 1px solid var(--rule);
  transition: background var(--t-fast) var(--ease);
}

.contact__card:last-child {
  border-right: none;
}

@media (max-width: 880px) {
  .contact__card {
    border-right: none;
    border-bottom: 1px solid var(--rule);
  }
  .contact__card:last-child {
    border-bottom: none;
  }
}

.contact__card:hover {
  background: var(--bone);
}

.contact__id {
  font-family: var(--mono);
  font-size: 0.74rem;
  color: var(--ember);
  letter-spacing: 0.05em;
}

.contact__title {
  font-family: var(--display);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  line-height: 1.1;
  font-weight: 400;
  letter-spacing: -0.015em;
}

.contact__desc {
  color: var(--ink-soft);
  font-size: 1rem;
  line-height: 1.55;
  margin-bottom: var(--s-4);
}

.contact__action {
  font-family: var(--mono);
  font-size: 0.92rem;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  border-bottom: 1px solid var(--ember);
  padding-bottom: 2px;
  align-self: start;
  transition: color var(--t-fast) var(--ease);
}

.contact__action:hover {
  color: var(--ember);
}

.contact__action::after {
  content: "→";
  transition: transform var(--t-fast) var(--ease);
}

.contact__action:hover::after {
  transform: translateX(3px);
}

/* ============================================================
   15 / SINGLE PROJECT (Case study page)
   ============================================================ */
.case-hero {
  padding-top: calc(var(--header-h) + var(--s-12));
  padding-bottom: var(--s-12);
  border-bottom: 1px solid var(--rule);
}

.case-hero__back {
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--mute);
  margin-bottom: var(--s-8);
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  transition: color var(--t-fast) var(--ease);
}

.case-hero__back:hover {
  color: var(--ember);
}

.case-hero__title {
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 350;
  max-width: 22ch;
  margin-bottom: var(--s-8);
}

.case-hero__thesis {
  font-family: var(--display);
  font-style: italic;
  font-size: clamp(1.25rem, 2.5vw, 1.75rem);
  font-weight: 400;
  color: var(--ink-soft);
  max-width: 36ch;
  line-height: 1.35;
  padding-left: var(--s-4);
  border-left: 2px solid var(--ember);
  margin-bottom: var(--s-12);
}

.case-meta {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--s-6);
  padding-top: var(--s-6);
  border-top: 1px solid var(--rule);
  font-family: var(--mono);
  font-size: 0.82rem;
}

@media (max-width: 720px) {
  .case-meta {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--s-4);
  }
}

.case-meta__item .kicker {
  display: block;
  margin-bottom: var(--s-1);
}

.case-meta__item strong {
  font-family: var(--mono);
  color: var(--ink);
  font-weight: 500;
}

.case-content {
  max-width: 720px;
  margin-inline: auto;
  padding-block: var(--s-16);
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--ink-soft);
}

.case-content p {
  margin-bottom: var(--s-6);
  max-width: none;
}

.case-content h2 {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  margin-top: var(--s-12);
  margin-bottom: var(--s-4);
  color: var(--ink);
}

.case-content h3 {
  font-size: 1.4rem;
  margin-top: var(--s-8);
  margin-bottom: var(--s-3);
  color: var(--ink);
}

.case-content ul,
.case-content ol {
  margin-bottom: var(--s-6);
  padding-left: var(--s-6);
}

.case-content ul li {
  list-style: none;
  position: relative;
  margin-bottom: var(--s-2);
}

.case-content ul li::before {
  content: "—";
  color: var(--ember);
  position: absolute;
  left: -1.25rem;
}

.case-content ol {
  list-style: decimal;
}

.case-content ol li {
  margin-bottom: var(--s-2);
  padding-left: var(--s-2);
}

.case-content blockquote {
  font-family: var(--display);
  font-size: 1.5rem;
  font-style: italic;
  font-weight: 350;
  color: var(--ink);
  padding: var(--s-6) 0 var(--s-6) var(--s-6);
  border-left: 2px solid var(--ember);
  margin-block: var(--s-8);
  line-height: 1.35;
  letter-spacing: -0.01em;
}

.case-content img {
  width: 100%;
  margin-block: var(--s-8);
  border: 1px solid var(--rule);
}

.case-content code {
  font-family: var(--mono);
  font-size: 0.9em;
  background: var(--paper);
  padding: 0.15em 0.4em;
  border: 1px solid var(--rule-soft);
}

.case-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s-4);
  padding-block: var(--s-12);
  border-top: 1px solid var(--rule);
}

@media (max-width: 720px) {
  .case-nav {
    grid-template-columns: 1fr;
  }
}

.case-nav__link {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  padding: var(--s-6);
  background: var(--paper);
  transition: background var(--t-fast) var(--ease);
}

.case-nav__link:hover {
  background: var(--bone-warm);
}

.case-nav__link--next {
  text-align: right;
}

.case-nav__link span {
  font-family: var(--mono);
  font-size: 0.74rem;
  color: var(--mute);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.case-nav__link strong {
  font-family: var(--display);
  font-size: 1.4rem;
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--ink);
}

/* ============================================================
   16 / FOOTER
   ============================================================ */
.site-footer {
  background: var(--ink);
  color: var(--bone-warm);
  padding-block: var(--s-16);
  position: relative;
}

.site-footer .marker {
  color: var(--bone-warm);
}

.site-footer__top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: var(--s-8);
  padding-bottom: var(--s-12);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

@media (max-width: 720px) {
  .site-footer__top {
    grid-template-columns: 1fr;
    gap: var(--s-6);
  }
}

.site-footer h3 {
  font-family: var(--display);
  font-size: clamp(2rem, 4vw, 3.25rem);
  line-height: 1.05;
  font-weight: 350;
  color: var(--paper);
  letter-spacing: -0.02em;
  max-width: 16ch;
  margin-bottom: var(--s-3);
}

.site-footer h3 em {
  color: var(--ember);
}

.site-footer__col h4 {
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--bone-warm);
  margin-bottom: var(--s-3);
  font-weight: 500;
}

.site-footer__col ul {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

.site-footer__col a {
  font-family: var(--mono);
  font-size: 0.85rem;
  color: var(--paper);
  transition: color var(--t-fast) var(--ease);
}

.site-footer__col a:hover {
  color: var(--ember);
}

.site-footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--s-6);
  font-family: var(--mono);
  font-size: 0.74rem;
  color: rgba(255, 255, 255, 0.5);
  flex-wrap: wrap;
  gap: var(--s-3);
}

/* ============================================================
   17 / GENERIC PAGES & POSTS
   ============================================================ */
.page-wrap,
.post-wrap {
  padding-top: calc(var(--header-h) + var(--s-12));
  padding-bottom: var(--s-16);
}

.post-hero {
  max-width: 720px;
  margin-inline: auto;
  margin-bottom: var(--s-8);
  padding-bottom: var(--s-6);
  border-bottom: 1px solid var(--rule);
}

.post-hero h1 {
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  margin-bottom: var(--s-4);
  max-width: 24ch;
}

.post-hero__meta {
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--mute);
  display: flex;
  gap: var(--s-4);
}

/* ============================================================
   18 / ANIMATIONS
   ============================================================ */
.fade-up {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity var(--t-slow) var(--ease),
    transform var(--t-slow) var(--ease);
}

.fade-up.is-in {
  opacity: 1;
  transform: translateY(0);
}

.fade-up.delay-1 {
  transition-delay: 80ms;
}
.fade-up.delay-2 {
  transition-delay: 160ms;
}
.fade-up.delay-3 {
  transition-delay: 240ms;
}
.fade-up.delay-4 {
  transition-delay: 320ms;
}
.fade-up.delay-5 {
  transition-delay: 400ms;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .ticker__track {
    animation: none;
  }
}

/* ============================================================
   19 / WP CORE
   ============================================================ */
.aligncenter {
  display: block;
  margin-inline: auto;
}
.alignleft {
  float: left;
  margin-right: var(--s-6);
}
.alignright {
  float: right;
  margin-left: var(--s-6);
}
.wp-caption-text {
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--mute);
  margin-top: var(--s-2);
}
.screen-reader-text {
  position: absolute !important;
  clip: rect(1px, 1px, 1px, 1px);
  width: 1px;
  height: 1px;
  overflow: hidden;
}
