/*
Theme Name: Matthew Agronin
Theme URI: https://magronin.com
Author: Matthew Agronin
Author URI: https://magronin.com
Description: Editorial portfolio theme for Matthew Agronin. Block theme: every page is editable in the WordPress editor (WYSIWYG). No JavaScript dependencies. Cream + ink + terracotta palette with Instrument Serif display + Inter body.
Version: 3.0.0
Requires at least: 6.4
Requires PHP: 7.4
License: All rights reserved
Text Domain: matt-agronin
*/

/* ============================================================
   Tokens
   ============================================================ */
:root {
  --paper:   #F2EDE3;
  --paper-2: #E8E1D2;
  --ink:     #14130F;
  --ink-2:   #5C574E;
  --ink-3:   #9A9388;
  --rule:    rgba(20,19,15,0.16);
  --rule-2:  rgba(20,19,15,0.08);
  --accent:  #B8412C;
  --accent-deep: #8E2F1F;
  --maxw: 1280px;
  --pad: 32px;
}

/* ============================================================
   Reset / base
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  letter-spacing: -0.011em;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
a { color: inherit; }
img { max-width: 100%; display: block; height: auto; }
button { font-family: inherit; }
figure { margin: 0; }

/* ============================================================
   Typography utility classes
   ============================================================ */
.display    { font-family: 'Instrument Serif', 'Times New Roman', serif; font-weight: 400; letter-spacing: -0.025em; }
.display-i  { font-family: 'Instrument Serif', serif; font-style: italic; font-weight: 400; letter-spacing: -0.018em; }
.sans       { font-family: 'Inter', sans-serif; }
.sans-tight { font-family: 'Inter', sans-serif; letter-spacing: -0.022em; }
.eyebrow    { font-family: 'Inter', sans-serif; font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; font-weight: 500; color: var(--ink-2); }
.num-feat   { font-feature-settings: "tnum" 1, "lnum" 1; }
.lead       { font-size: 22px; line-height: 1.45; letter-spacing: -0.012em; color: var(--ink); }
.body       { font-size: 17px; line-height: 1.65; color: var(--ink-2); }
.body-ink   { font-size: 17px; line-height: 1.65; color: var(--ink); }

/* ============================================================
   Layout primitives
   ============================================================ */
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--pad); }
/* Mobile overflow guards — nothing should ever cause horizontal scroll */
html, body { overflow-x: hidden; max-width: 100%; }
img, svg, video, canvas { max-width: 100%; height: auto; }
.container, .section, main, .bg-accent { max-width: 100%; }
.section   { padding: 96px 0; }
.section-tight   { padding: 56px 0; }
.section-roomy   { padding: 120px 0; }
.bg-paper-2 { background: var(--paper-2); }
.bg-accent  { background: var(--accent); color: var(--paper); }
.bg-accent-deep { background: var(--accent-deep); color: var(--paper); }
.bg-ink     { background: var(--ink); color: var(--paper); }
.rule       { height: 1px; background: var(--rule); width: 100%; }
.rule-ink   { height: 1px; background: var(--ink); width: 100%; }

/* ============================================================
   Top bar
   ============================================================ */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(242,237,227,0.92);
  backdrop-filter: saturate(140%) blur(8px);
  -webkit-backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--rule);
}
.topbar-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  padding: 18px var(--pad);
  gap: 24px;
}
.topbar-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: inherit;
}
.topbar-brand .wordmark {
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.022em;
  font-size: 16px;
  font-weight: 600;
}
.topbar-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}
.topbar-nav a {
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.022em;
  font-size: 14px;
  font-weight: 500;
  padding: 10px 14px;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  color: var(--ink);
}
.topbar-nav a.is-current {
  border-bottom-color: var(--ink);
}
.topbar-nav a.contact-cta {
  margin-left: 8px;
  padding: 10px 18px;
  background: transparent;
  border: 1px solid var(--ink);
  border-radius: 999px;
  border-bottom-color: var(--ink);
}
.topbar-nav a.contact-cta.is-current {
  background: var(--ink);
  color: var(--paper);
}

/* Logo SVG */
.logomark { display: block; }

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 24px;
  border-radius: 999px;
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.022em;
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
}
.btn-ink     { background: var(--ink);   color: var(--paper); border-color: var(--ink); }
.btn-outline { background: transparent;  color: var(--ink);   border-color: var(--ink); }
.btn-paper   { background: var(--paper); color: var(--accent-deep); border-color: var(--paper); }
.btn-pill-sm { padding: 12px 20px; font-size: 14px; }
.btn-lg      { padding: 16px 28px; font-size: 16px; }
.btn-xl      { padding: 18px 28px; font-size: 18px; }

/* ============================================================
   Home page
   ============================================================ */
.home-hero {
  position: relative;
}
.home-hero-bg {
  position: absolute;
  top: 0; bottom: 0; right: 0;
  width: 44%;
  background: var(--accent);
  z-index: 0;
}
.home-hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: end;
  padding-top: 56px;
  padding-bottom: 96px;
}
.home-hero h1 {
  font-family: 'Instrument Serif', serif;
  font-weight: 400;
  font-size: 132px;
  line-height: 0.92;
  letter-spacing: -0.045em;
  margin: 20px 0 0;
}
.home-hero .lead { margin: 32px 0 0; max-width: 34ch; }
.home-hero-actions {
  margin-top: 36px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.home-hero-prevs {
  margin-top: 56px;
  margin-bottom: 16px;
  color: var(--ink-3);
}
.home-hero-portrait {
  margin: 0;
  aspect-ratio: 4 / 5;
  background: var(--ink);
  overflow: hidden;
  align-self: stretch;
}
.home-hero-portrait img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: center 18%;
}

.tr-head {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: end;
  margin-bottom: 56px;
}
.tr-head h2 {
  font-family: 'Instrument Serif', serif;
  font-weight: 400;
  font-size: 72px;
  line-height: 0.98;
  letter-spacing: -0.035em;
  margin: 16px 0 0;
  max-width: 16ch;
}
.tr-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  border-top: 1px solid var(--ink);
}
.tr-stat {
  padding: 32px 24px 32px 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.tr-stat:first-child { border-right: 1px solid var(--rule); }
.tr-stat:last-child  { padding-left: 24px; }
.tr-stat .num {
  font-family: 'Instrument Serif', serif;
  font-size: 112px;
  line-height: 0.95;
  letter-spacing: -0.04em;
  color: var(--accent);
  font-feature-settings: "tnum" 1, "lnum" 1;
}
.tr-stat .label {
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.015em;
  font-size: 18px;
  font-weight: 600;
}
.tr-stat .desc {
  font-size: 14px;
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 44ch;
}
.tr-mini {
  margin-top: 64px;
  padding-top: 40px;
  border-top: 1px solid var(--rule);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}
.tr-mini-item {
  display: flex;
  align-items: baseline;
  gap: 20px;
}
.tr-mini-item .num {
  font-family: 'Instrument Serif', serif;
  font-size: 72px;
  line-height: 0.95;
  letter-spacing: -0.035em;
  color: var(--ink);
  font-feature-settings: "tnum" 1, "lnum" 1;
}
.tr-mini-item .label {
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.015em;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.25;
}
.tr-mini-item .note {
  font-size: 13px;
  color: var(--ink-2);
  margin-top: 4px;
  line-height: 1.4;
}

.work-head {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 24px;
  margin-bottom: 40px;
}
.work-head h2 {
  font-family: 'Instrument Serif', serif;
  font-weight: 400;
  font-size: 72px;
  line-height: 0.98;
  letter-spacing: -0.035em;
  margin: 16px 0 0;
  max-width: 20ch;
}
.work-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.work-tile {
  text-decoration: none;
  color: inherit;
  display: block;
}
.work-tile figure {
  aspect-ratio: 16 / 11;
  background: var(--ink);
  overflow: hidden;
  border-radius: 4px;
}
.work-tile img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: center;
}
.work-tile.crop-30 img { object-position: center 30%; }
.work-tile-meta {
  padding-top: 20px;
  display: grid;
  gap: 10px;
}
.work-tile-meta .row {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--ink-2);
}
.work-tile-meta .row .client {
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.015em;
  font-weight: 600;
  color: var(--ink);
}
.work-tile h3 {
  font-family: 'Instrument Serif', serif;
  font-weight: 400;
  font-size: 28px;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0;
  max-width: 30ch;
}

.howiwork-grid {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 64px;
  align-items: start;
}
.howiwork-grid .eyebrow {
  padding-top: 14px;
  color: rgba(242,237,227,0.65);
}
.howiwork-grid .pull {
  font-family: 'Instrument Serif', serif;
  font-size: 56px;
  line-height: 1.1;
  letter-spacing: -0.025em;
  margin: 0;
  color: var(--paper);
  max-width: 880px;
}
.howiwork-grid .body {
  margin-top: 36px;
  max-width: 62ch;
  font-size: 19px;
  line-height: 1.6;
  color: rgba(242,237,227,0.85);
  font-family: 'Inter', sans-serif;
}

/* ============================================================
   About page
   ============================================================ */
.about-hero h1 {
  font-family: 'Instrument Serif', serif;
  font-weight: 400;
  font-size: 144px;
  line-height: 0.9;
  letter-spacing: -0.05em;
  margin: 24px 0 0;
  max-width: 14ch;
}
.about-hero .lead {
  margin-top: 40px;
  max-width: 44ch;
  color: var(--ink-2);
}
.col-aside {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 64px;
}
.col-aside .eyebrow { padding-top: 14px; }
.col-aside .body-block { max-width: 760px; }
.col-aside .body-block p.display {
  font-size: 38px;
  line-height: 1.25;
  letter-spacing: -0.02em;
  margin: 0;
  color: var(--ink);
}
.col-aside .body-block p.body-ink {
  margin-top: 24px;
  font-size: 18px;
  line-height: 1.65;
}
.col-aside .body-block p.body-ink:first-of-type {
  margin-top: 36px;
}
.principles {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 96px;
  align-items: start;
}
.principles h2 {
  font-family: 'Instrument Serif', serif;
  font-size: 72px;
  line-height: 0.98;
  letter-spacing: -0.035em;
  margin: 20px 0 0;
  color: var(--paper);
}
.principles .list { display: grid; gap: 44px; }
.principles .list h3 {
  font-family: 'Instrument Serif', serif;
  font-size: 28px;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 0;
  max-width: 32ch;
  color: var(--paper);
}
.principles .list p {
  margin-top: 12px;
  font-size: 16px;
  line-height: 1.65;
  max-width: 60ch;
  color: rgba(242,237,227,0.82);
  font-family: 'Inter', sans-serif;
}

/* ============================================================
   Work page
   ============================================================ */
.work-hero h1, .resume-hero h1, .contact-hero h1 {
  font-family: 'Instrument Serif', serif;
  font-weight: 400;
  font-size: 108px;
  line-height: 0.94;
  letter-spacing: -0.04em;
  margin: 20px 0 28px;
  max-width: 16ch;
}
.work-hero .lead { max-width: 62ch; margin: 0; }

.case {
  padding: 56px 0;
}
.case-head {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 32px;
  align-items: baseline;
  border-top: 1px solid var(--ink);
  padding-top: 32px;
}
.case-head .num {
  font-family: 'Instrument Serif', serif;
  font-size: 64px;
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--accent);
  font-feature-settings: "tnum" 1, "lnum" 1;
}
.case-head h2 {
  font-family: 'Instrument Serif', serif;
  font-weight: 400;
  font-size: 56px;
  line-height: 1.02;
  letter-spacing: -0.03em;
  margin: 12px 0 0;
  max-width: 22ch;
}
.case-hero {
  margin-top: 40px;
  aspect-ratio: 16 / 9;
  background: var(--ink);
  overflow: hidden;
  border-radius: 4px;
}
.case-hero img { width: 100%; height: 100%; object-fit: cover; }
.case-hero iframe { width: 100%; height: 100%; border: 0; display: block; }
.case-body {
  margin-top: 48px;
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 64px;
  align-items: start;
}
.case-prose { display: grid; gap: 20px; }
.case-prose p { margin: 0; font-size: 18px; line-height: 1.6; }
.case-aside { display: grid; gap: 28px; }
.case-aside .body { font-size: 15px; }
.case-outcomes { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.case-outcomes li {
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.022em;
  font-size: 15px;
  line-height: 1.45;
  padding-top: 6px;
  border-top: 1px solid var(--rule-2);
  display: flex;
  gap: 10px;
}
.case-outcomes li:first-child { border-top: none; padding-top: 0; }
.case-outcomes .arrow { color: var(--accent); }
.case-gallery {
  margin-top: 48px;
  display: grid;
  gap: 16px;
}
.case-gallery.cols-2 { grid-template-columns: 1fr 1fr; }
.case-gallery.cols-3 { grid-template-columns: 1fr 1fr 1fr; }
.case-gallery figure {
  aspect-ratio: 4 / 3;
  background: var(--ink);
  overflow: hidden;
  border-radius: 4px;
}
.case-gallery img { width: 100%; height: 100%; object-fit: cover; }
.case-wide {
  margin: 16px 0 0;
  aspect-ratio: 16 / 7;
  background: var(--ink);
  overflow: hidden;
  border-radius: 4px;
}
.case-wide img { width: 100%; height: 100%; object-fit: cover; }

/* ============================================================
   Resume page
   ============================================================ */
.resume-hero .lead { max-width: 64ch; margin: 0; }
.competencies {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  gap: 24px;
  border-top: 1px solid var(--ink);
}
.competencies > div {
  padding-top: 24px;
  padding-right: 16px;
}
.competencies > div + div {
  border-left: 1px solid var(--rule);
  padding-left: 16px;
}
.competencies .roman {
  font-family: 'Instrument Serif', serif;
  font-size: 24px;
  color: var(--accent);
  margin-bottom: 12px;
}
.competencies .label {
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.015em;
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
}
.competencies .desc {
  font-size: 14px;
  line-height: 1.55;
  color: var(--ink-2);
  margin: 0;
}
.section-h {
  font-family: 'Instrument Serif', serif;
  font-weight: 400;
  font-size: 56px;
  line-height: 1.02;
  letter-spacing: -0.03em;
  margin: 12px 0 40px;
  max-width: 22ch;
}
.timeline { border-top: 1px solid var(--ink); }
.timeline-row {
  display: grid;
  grid-template-columns: 220px 1fr 140px;
  gap: 24px;
  align-items: baseline;
  padding: 20px 0;
  border-bottom: 1px solid var(--rule);
}
.timeline-row .yrs {
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.022em;
  font-size: 14px;
  color: var(--ink-2);
  font-feature-settings: "tnum" 1;
}
.timeline-row .role {
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.015em;
  font-size: 18px;
  font-weight: 600;
}
.timeline-row .co {
  font-size: 15px;
  margin-top: 2px;
  color: var(--ink-2);
}
.timeline-row .note {
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.022em;
  font-size: 13px;
  color: var(--ink-2);
  text-align: right;
}
.chapters { display: grid; gap: 56px; }
.chapter {
  border-top: 1px solid var(--ink);
  padding-top: 32px;
}
.chapter-head {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 32px;
  align-items: baseline;
  margin-bottom: 24px;
}
.chapter-mark {
  font-family: 'Instrument Serif', serif;
  font-size: 36px;
  letter-spacing: -0.02em;
  color: var(--accent);
}
.chapter-role {
  font-family: 'Instrument Serif', serif;
  font-weight: 400;
  font-size: 32px;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0;
}
.chapter-dates {
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.022em;
  font-size: 14px;
  color: var(--ink-2);
  margin-top: 6px;
  font-feature-settings: "tnum" 1;
}
.chapter-summary {
  margin: 0 0 20px;
  max-width: 76ch;
  font-size: 17px;
  line-height: 1.6;
}
.chapter-points {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 14px;
}
.chapter-points li {
  font-size: 16px;
  line-height: 1.55;
  padding-left: 18px;
  position: relative;
  max-width: 82ch;
}
.chapter-points li::before {
  content: "→";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--accent);
}
.chapter-points li b {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
}
.testimonials {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 24px;
}
.testimonial {
  margin: 0;
  background: var(--paper);
  padding: 32px 28px;
  border: 1px solid var(--rule);
  border-radius: 4px;
}
.testimonial blockquote {
  margin: 0;
  font-family: 'Instrument Serif', serif;
  font-size: 24px;
  line-height: 1.25;
  letter-spacing: -0.015em;
  color: var(--ink);
}
.testimonial figcaption {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--rule);
}
.testimonial .who {
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.022em;
  font-size: 14px;
  font-weight: 600;
}
.testimonial .what {
  font-size: 13px;
  margin-top: 2px;
  color: var(--ink-2);
}
.bio-aside {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 64px;
  align-items: start;
}
.bio-aside .bio { display: grid; gap: 18px; }
.bio-aside .bio p { margin: 0; font-size: 19px; line-height: 1.6; max-width: 62ch; }
.bio-aside aside {
  display: grid;
  gap: 24px;
  padding-left: 32px;
  border-left: 1px solid var(--rule);
}
.closing {
  border-top: 1px solid var(--ink);
  padding-top: 56px;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 64px;
  align-items: end;
}
.closing h2 {
  font-family: 'Instrument Serif', serif;
  font-weight: 400;
  font-size: 64px;
  line-height: 1.0;
  letter-spacing: -0.03em;
  margin: 0;
  max-width: 22ch;
}
.closing-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

/* ============================================================
   Contact page
   ============================================================ */
.contact-hero .lead { max-width: 62ch; margin: 0; }
.contact-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 64px;
  align-items: start;
}
.contact-aside {
  display: flex;
  flex-direction: column;
  gap: 32px;
}
.contact-aside .block-top { border-top: 1px solid var(--ink); padding-top: 24px; }
.contact-aside .links {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 12px;
}
.contact-aside .links a {
  font-family: 'Inter', sans-serif;
  letter-spacing: -0.022em;
  font-size: 16px;
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.contact-aside .links a span.arrow { color: var(--accent); }
.contact-aside ul.bullets {
  margin: 12px 0 0;
  padding-left: 18px;
  line-height: 1.6;
  font-size: 15px;
  color: var(--ink-2);
}
.contact-note {
  background: var(--paper-2);
  padding: 20px 22px;
  border-radius: 4px;
}
.contact-note p {
  margin: 8px 0 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink-2);
}

/* Contact form (Jetpack styling override) */
.ma-contact-form { display: flex; flex-direction: column; gap: 24px; }
.ma-contact-form .grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.ma-contact-form label,
.ma-contact-form .grunion-field-label {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin-bottom: 8px;
  display: block;
}
.ma-contact-form input[type="text"],
.ma-contact-form input[type="email"],
.ma-contact-form select,
.ma-contact-form textarea {
  width: 100%;
  padding: 16px 18px;
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  letter-spacing: -0.011em;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 4px;
  outline: none;
}
.ma-contact-form input:focus,
.ma-contact-form select:focus,
.ma-contact-form textarea:focus {
  border-color: var(--ink);
}
.ma-contact-form select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path d='M1 1l5 5 5-5' fill='none' stroke='%2314130F' stroke-width='1.5'/></svg>");
  background-repeat: no-repeat;
  background-position: right 18px center;
  padding-right: 44px;
}
.ma-contact-form textarea {
  resize: vertical;
  min-height: 180px;
}
.ma-contact-form .submit-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.ma-contact-form .submit-note {
  font-size: 13px;
  color: var(--ink-2);
  max-width: 44ch;
}
.ma-contact-form button[type="submit"],
.ma-contact-form input[type="submit"] {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.022em;
  padding: 16px 28px;
  background: var(--ink);
  color: var(--paper);
  border: 1px solid var(--ink);
  border-radius: 999px;
  cursor: pointer;
}

/* Confirmation message */
.contact-thanks {
  border: 1px solid var(--ink);
  background: var(--paper-2);
  padding: 48px 40px;
  border-radius: 4px;
}
.contact-thanks h2 {
  font-family: 'Instrument Serif', serif;
  font-size: 48px;
  line-height: 1.02;
  letter-spacing: -0.025em;
  margin: 12px 0 16px;
  max-width: 20ch;
}
.contact-thanks p {
  margin: 0;
  max-width: 60ch;
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink-2);
}

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
  background: var(--ink);
  color: var(--paper);
  padding: 96px var(--pad) 56px;
}
.site-footer-inner {
  max-width: var(--maxw);
  margin: 0 auto;
}
.site-footer .eyebrow { color: rgba(242,237,227,0.55); }
.site-footer h2 {
  font-family: 'Instrument Serif', serif;
  font-weight: 400;
  font-size: 88px;
  line-height: 0.98;
  letter-spacing: -0.035em;
  margin: 20px 0 40px;
  max-width: 18ch;
}
.site-footer .meta {
  margin-top: 96px;
  padding-top: 32px;
  border-top: 1px solid rgba(242,237,227,0.16);
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  gap: 24px;
  font-size: 13px;
  color: rgba(242,237,227,0.78);
}
.site-footer .meta .eyebrow {
  color: rgba(242,237,227,0.45);
  margin-bottom: 6px;
}
.site-footer .meta a {
  text-decoration: underline;
  text-underline-offset: 4px;
}
.site-footer .meta .right { text-align: right; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 1024px) {
  .home-hero h1 { font-size: 96px; }
  .about-hero h1 { font-size: 96px; }
  .work-hero h1, .resume-hero h1, .contact-hero h1 { font-size: 80px; }
  .tr-head h2, .work-head h2 { font-size: 56px; }
  .case-head h2 { font-size: 44px; }
  .site-footer h2 { font-size: 64px; }
  .principles { grid-template-columns: 1fr; gap: 48px; }
  .principles h2 { font-size: 56px; }
  .competencies { grid-template-columns: 1fr 1fr; }
  .competencies > div:nth-child(3) { border-left: none; padding-left: 0; }
}
@media (max-width: 768px) {
  :root { --pad: 20px; }
  .home-hero-bg { display: none; }
  .home-hero-grid { grid-template-columns: 1fr; gap: 40px; padding-bottom: 40px; }
  .home-hero h1 { font-size: 64px; }
  .home-hero-portrait { aspect-ratio: 4 / 5; max-width: 480px; }
  .about-hero h1 { font-size: 64px; }
  .work-hero h1, .resume-hero h1, .contact-hero h1 { font-size: 56px; }
  .tr-head, .tr-stats, .tr-mini, .work-head, .work-grid,
  .case-body, .case-gallery.cols-2, .case-gallery.cols-3,
  .testimonials, .bio-aside, .closing, .contact-grid,
  .col-aside, .howiwork-grid { grid-template-columns: 1fr; gap: 32px; }
  .howiwork-grid .eyebrow { padding-top: 0; }
  .howiwork-grid .pull { font-size: 36px; }
  .tr-stat:first-child { border-right: none; border-bottom: 1px solid var(--rule); padding-bottom: 32px; }
  .tr-stat:last-child { padding-left: 0; }
  .tr-head h2, .work-head h2 { font-size: 44px; }
  .tr-stat .num { font-size: 84px; }
  .case-head { grid-template-columns: 1fr; gap: 8px; }
  .case-head .num { font-size: 40px; }
  .case-head h2 { font-size: 36px; }
  .competencies { grid-template-columns: 1fr; }
  .competencies > div + div { border-left: none; padding-left: 0; padding-top: 24px; border-top: 1px solid var(--rule); }
  .timeline-row { grid-template-columns: 1fr; gap: 4px; }
  .timeline-row .note { text-align: left; }
  .chapter-head { grid-template-columns: 1fr; gap: 8px; }
  .closing-actions { justify-content: flex-start; }
  .ma-contact-form .grid-2 { grid-template-columns: 1fr; }
  .site-footer h2 { font-size: 44px; }
  .site-footer .meta { grid-template-columns: 1fr 1fr; }
  .site-footer .meta .right { text-align: left; }
  .topbar-inner { padding: 14px var(--pad); }
  .topbar-brand .wordmark { display: none; }
  .topbar-nav a { padding: 8px 10px; font-size: 13px; }
  .topbar-nav a.contact-cta { padding: 8px 14px; }
  .section { padding: 64px 0; }
  .section-roomy { padding: 80px 0; }
  .site-footer h2 { font-size: 40px; }
  .tr-stat .num { font-size: 72px; }
  /* Soft-wrap long words/links so nothing pushes the page wide */
  h1, h2, h3, p, a { overflow-wrap: anywhere; word-break: normal; }
}
@media (max-width: 420px) {
  .home-hero h1 { font-size: 52px; }
  .about-hero h1 { font-size: 52px; }
  .work-hero h1, .resume-hero h1, .contact-hero h1 { font-size: 44px; }
  .howiwork-grid .pull { font-size: 30px; }
  .tr-head h2, .work-head h2 { font-size: 36px; }
  .site-footer h2 { font-size: 34px; }
  .tr-stat .num { font-size: 60px; }
}


/* ============================================================
   Block theme compatibility layer (v3.0.0)
   Everything below adapts the original design to Gutenberg
   block markup. The visual design itself is unchanged.
   ============================================================ */

/* --- Template part shells -----------------------------------
   The header/footer template parts carry .topbar / .site-footer
   on their wrappers. The :has() fallbacks cover WP versions that
   drop custom classes on template parts. */
header.wp-block-template-part:has(> .topbar-inner) {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(242,237,227,0.92);
  backdrop-filter: saturate(140%) blur(8px);
  -webkit-backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--rule);
}
footer.wp-block-template-part:has(> .site-footer-inner) {
  background: var(--ink);
  color: var(--paper);
  padding: 96px var(--pad) 56px;
}

/* Nav current-page state (replaces the old PHP is-current logic) */
body.ma-page-about   .topbar-nav a[href="/about/"],
body.ma-page-work    .topbar-nav a[href="/work/"],
body.ma-page-resume  .topbar-nav a[href="/resume/"] {
  border-bottom-color: var(--ink);
}
body.ma-page-contact .topbar-nav a.contact-cta {
  background: var(--ink);
  color: var(--paper);
}

/* --- Never let WP constrain or space the page content -------- */
.wp-block-post-content > * { max-width: none; }
.wp-block-image { margin: 0; }

/* --- Section padding utilities (replace old inline styles) --- */
.sect-88-48  { padding-top: 88px;  padding-bottom: 48px; }
.sect-56-48  { padding-top: 56px;  padding-bottom: 48px; }
.sect-64-80  { padding-top: 64px;  padding-bottom: 80px; }
.sect-80-56  { padding-top: 80px;  padding-bottom: 56px; }
.sect-72-56  { padding-top: 72px;  padding-bottom: 56px; }
.sect-72-48  { padding-top: 72px;  padding-bottom: 48px; }
.sect-88     { padding-top: 88px;  padding-bottom: 88px; }
.sect-88-64  { padding-top: 88px;  padding-bottom: 64px; }
.sect-64     { padding-top: 64px;  padding-bottom: 64px; }
.sect-32-120 { padding-top: 32px;  padding-bottom: 120px; }
.sect-32-96  { padding-top: 32px;  padding-bottom: 96px; }

/* Margin utilities */
.mt-40 { margin-top: 40px; display: inline-flex; }
.mb-48 { margin-bottom: 48px; }

/* --- Elements that used to be <div>s are now <p> blocks ------
   Zero-specificity reset so purposeful margins still win. */
:where(p.eyebrow,
  .tr-stat .num, .tr-stat .label, .tr-stat .desc,
  .tr-mini-item .num, .tr-mini-item .label, .tr-mini-item .note,
  .case-head .num,
  .competencies .roman, .competencies .label, .competencies .desc,
  .timeline-row .yrs, .timeline-row .role, .timeline-row .co, .timeline-row .note,
  .chapter-mark, .chapter-dates,
  .testimonial .who, .testimonial .what,
  .site-footer .meta p,
  .case-aside .body,
  .bio-aside aside .body) {
  margin: 0;
}

/* Contextual margins that used to be inline styles */
.tr-head .body            { margin: 0 0 8px; max-width: 44ch; }
.case-aside .eyebrow      { margin-bottom: 8px; }
.bio-aside aside .eyebrow { margin-bottom: 8px; }
.body-sm                  { font-size: 14px; }
.col-aside .body-block p.display.display-sm { font-size: 32px; line-height: 1.3; }

/* --- Work tiles (tile links now live on image + title) ------- */
.work-tile a { text-decoration: none; color: inherit; }
.work-tile figure a { display: block; width: 100%; height: 100%; }

/* --- Case outcomes: arrow via CSS so list items stay plain --- */
.case-outcomes li::before { content: "\2192"; color: var(--accent); flex: none; }

/* --- Testimonials: quote + caption as blocks ------------------ */
.testimonial blockquote { margin: 0; border: none; padding: 0; }
.testimonial blockquote p {
  margin: 0;
  font-family: 'Instrument Serif', serif;
  font-size: 24px;
  line-height: 1.25;
  letter-spacing: -0.015em;
  color: var(--ink);
}
.testimonial .caption {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--rule);
}

/* --- Italic serif accents survive editing ---------------------
   Even if the editor strips class="display-i" from an <em>, the
   look is preserved. */
h1 em, h2 em, h3 em, .pull em, .display em, .lead em {
  font-family: 'Instrument Serif', serif;
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.018em;
}
