/* ESIENA — V4 "Threshold"
   One family (Newsreader, optical sizes), limewash stone + chalk, plum ink, sage support, gold only for the dot. */

:root {
  --chalk: #FAF9F7;
  --stone: #EAE6E1;
  --stone-deep: #DDD7CF;
  --plum: #4F1B35;
  --plum-soft: #6B5560;   /* secondary text, 6.4:1 on chalk */
  --sage: #6E7560;        /* rules, large text */
  --sage-ink: #5B624F;    /* sage band background / small sage text */
  --gold: #A87A3D;        /* the dot. nothing else. */
  --line: rgba(79, 27, 53, 0.16);

  --serif: "Newsreader", "Iowan Old Style", Georgia, serif;

  --t-sm: 0.9375rem;
  --t-base: 1.125rem;
  --t-lead: clamp(1.25rem, 1.1rem + 0.6vw, 1.5rem);
  --t-h3: clamp(1.5rem, 1.3rem + 0.8vw, 2rem);
  --t-h2: clamp(2rem, 1.5rem + 2vw, 3.25rem);
  --t-statement: clamp(1.75rem, 1.2rem + 2.2vw, 3rem);
  --t-display: clamp(2.5rem, 1.5rem + 3.4vw, 4.5rem);

  --gutter: clamp(1rem, 4vw, 3.5rem);
  --max: 76rem;
  --hh: 4.5rem; /* header height */
  --space: clamp(5rem, 4rem + 6vw, 10rem);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--hh) + 1rem); }
body {
  margin: 0;
  background: var(--chalk);
  color: var(--plum);
  font-family: var(--serif);
  font-size: var(--t-base);
  font-optical-sizing: auto;
  font-variation-settings: "opsz" 12;
  line-height: 1.62;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.22em; }
p { margin: 0 0 1em; }
h1, h2, h3 { text-wrap: balance; margin: 0; font-weight: 400; line-height: 1.08; letter-spacing: -0.01em; font-variation-settings: "opsz" 72; }
h2 { font-size: var(--t-h2); }
h3 { font-size: var(--t-h3); line-height: 1.18; font-variation-settings: "opsz" 36; }

:focus-visible { outline: 2px solid var(--plum); outline-offset: 3px; border-radius: 2px; }
.sage-band :focus-visible, .closing-door :focus-visible { outline-color: var(--chalk); }

.skip {
  position: absolute; left: 1rem; top: -4rem; z-index: 100;
  background: var(--plum); color: var(--chalk); padding: 0.6rem 1rem; text-decoration: none;
}
.skip:focus { top: 1rem; }

.wrap { width: 100%; max-width: calc(var(--max) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 3rem; padding: 0.7rem 1.6rem;
  border-radius: 999px; border: 1px solid var(--plum);
  background: var(--plum); color: var(--chalk);
  font: inherit; font-size: 1.0625rem; line-height: 1.2; text-decoration: none; cursor: pointer;
  transition: background-color .2s ease, color .2s ease;
}
.btn:hover { background: #3C1428; }
.btn--quiet { background: transparent; color: var(--plum); }
.btn--quiet:hover { background: var(--plum); color: var(--chalk); }
.btn--light { background: var(--chalk); color: var(--plum); border-color: var(--chalk); }
.btn--light:hover { background: var(--stone); }
.textlink { text-decoration: underline; text-decoration-color: var(--sage); }
.textlink:hover { text-decoration-color: var(--plum); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  height: var(--hh);
  background: var(--chalk);
  border-bottom: 1px solid transparent;
  transition: border-color .3s ease;
}
.site-header.is-scrolled { border-bottom-color: var(--line); }
.site-header .wrap { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.brand { display: inline-flex; align-items: center; gap: 0.65rem; text-decoration: none; }
.brand img { width: 2.4rem; height: auto; }
.brand span {
  font-size: 1.45rem; letter-spacing: 0.14em; text-transform: uppercase;
  font-variation-settings: "opsz" 72; line-height: 1;
}
.nav { display: flex; align-items: center; gap: 2rem; }
.nav ul { display: flex; gap: 1.75rem; list-style: none; margin: 0; padding: 0; }
.nav a:not(.btn) { text-decoration: none; font-size: 1.0625rem; padding: 0.4rem 0; }
.nav a:not(.btn):hover, .nav a[aria-current="page"] { text-decoration: underline; text-decoration-color: var(--sage); }
.nav .btn { min-height: 2.6rem; padding: 0.5rem 1.2rem; font-size: 1rem; }
.nav-toggle {
  display: none; background: none; border: 0; padding: 0.6rem 0.2rem; color: var(--plum);
  font: inherit; font-size: 1.0625rem; cursor: pointer; min-height: 44px;
}

@media (max-width: 860px) {
  :root { --hh: 4rem; }
  .brand img { width: 2rem; }
  .brand span { font-size: 1.25rem; }
  .nav-toggle { display: block; }
  .nav {
    position: fixed; inset: var(--hh) 0 0 0;
    flex-direction: column; align-items: stretch; justify-content: flex-start; gap: 2rem;
    padding: 2.5rem var(--gutter);
    background: var(--chalk);
    visibility: hidden; opacity: 0; transition: opacity .2s ease, visibility 0s linear .2s;
  }
  .nav.is-open { visibility: visible; opacity: 1; transition: opacity .2s ease; }
  .nav ul { flex-direction: column; gap: 0; }
  .nav ul a:not(.btn) { display: block; font-size: 2rem; font-variation-settings: "opsz" 60; padding: 0.55rem 0; border-bottom: 1px solid var(--line); }
  .nav .btn { min-height: 3.25rem; font-size: 1.125rem; }
  body.nav-locked { overflow: hidden; }
}

/* ---------- The doorway ---------- */
.door { position: relative; }
.door-stage {
  position: relative;
  min-height: calc(100svh - var(--hh));
  display: grid;
  grid-template-columns: 1fr minmax(15rem, 25rem) 1fr;
  grid-template-rows: 1fr auto;
  align-items: end;
  column-gap: clamp(2rem, 4vw, 4.5rem);
  padding: clamp(1.5rem, 4vh, 3rem) var(--gutter) clamp(1.5rem, 5vh, 3.5rem);
  max-width: 100rem; margin: 0 auto;
}
.door-frame {
  grid-column: 2; grid-row: 1 / 3; align-self: stretch;
  position: relative;
  min-height: 22rem;
  max-height: 44rem;
  border-radius: 999px 999px 0 0;
  overflow: hidden;
  background: var(--stone);
}
.door-media {
  position: absolute; inset: 0; overflow: hidden;
}
.door-media img {
  width: 100%; height: 100%; object-fit: cover; object-position: 38% 55%;
}
.door-left { grid-column: 1; grid-row: 1 / 3; align-self: end; padding-bottom: 0.25rem; }
.door-right { grid-column: 3; grid-row: 1 / 3; align-self: end; padding-bottom: 0.4rem; max-width: 27rem; }
.door-left, .door-right { position: relative; z-index: 2; }

.door-tag {
  font-style: italic; font-size: var(--t-lead); color: var(--plum-soft);
  margin: 0 0 1.25rem; font-variation-settings: "opsz" 24;
}
.door-title { font-size: var(--t-display); line-height: 1.02; letter-spacing: -0.02em; max-width: 9.5ch; margin-left: auto; text-align: right; }
.door-tag { text-align: right; }
.door-right p { color: var(--plum-soft); font-size: var(--t-lead); line-height: 1.4; margin-bottom: 1.75rem; font-variation-settings: "opsz" 24; }
.door-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

/* Static open room (no JS / reduced motion) */
.room-open { display: block; margin: 0; }
.room-open img { width: 100%; height: clamp(22rem, 70vh, 48rem); object-fit: cover; object-position: 40% 55%; }

/* Motion version: one image, clip-path driven by scroll */
.door-motion .door { height: calc(100svh - var(--hh) + 130svh); }
.door-motion .door-sticky { position: sticky; top: var(--hh); height: calc(100svh - var(--hh)); overflow: hidden; }
.door-motion .door-stage { height: 100%; min-height: 0; }
.door-motion .door-frame { background: transparent; border-radius: 0; overflow: visible; }
.door-motion .door-media {
  position: absolute; z-index: 1;
  /* positioned by JS to cover the sticky viewport; clip-path draws the arch */
  will-change: clip-path;
}
.door-motion .door-media img { position: absolute; max-width: none; }
.door-motion .room-open { display: none; }
.door-motion .door-left, .door-motion .door-right { will-change: transform, opacity; }

@media (max-width: 860px) {
  .door-stage {
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr auto;
    row-gap: 1.25rem;
    align-items: stretch;
    padding-top: 1.25rem; padding-bottom: 1.25rem;
    text-align: center;
  }
  .door-left { grid-column: 1; grid-row: 1; padding: 0; }
  .door-frame { grid-column: 1; grid-row: 2; justify-self: center; width: min(74vw, 20rem); min-height: 15rem; max-height: none; }
  .door-right { grid-column: 1; grid-row: 3; justify-self: center; max-width: none; padding: 0; }
  .door-right p { display: none; }
  .door-tag, .door-title { text-align: center; margin-left: auto; margin-right: auto; }
  .door-tag { margin-bottom: 0.5rem; font-size: 1.125rem; }
  .door-title { font-size: clamp(2.1rem, 8.6vw, 3rem); max-width: 14ch; }
  .door-actions { justify-content: center; }
  .door-actions .btn--quiet { display: none; }
}

/* ---------- Sections ---------- */
.section { padding: var(--space) 0; }
.section--stone { background: var(--stone); }

.statement { text-align: center; }
.statement p {
  font-size: var(--t-statement); line-height: 1.28; letter-spacing: -0.01em;
  font-variation-settings: "opsz" 60; max-width: 30ch; margin: 0 auto; text-wrap: balance;
}
.statement .statement-note { font-size: var(--t-lead); color: var(--plum-soft); margin-top: 2.25rem; font-variation-settings: "opsz" 16; max-width: none; font-style: italic; }

/* Two images, set on the centre axis like a gallery wall */
.gallery {
  display: grid; grid-template-columns: 5fr 4fr; gap: clamp(1rem, 3vw, 2.5rem);
  align-items: end; max-width: 58rem; margin: var(--space) auto 0;
}
.gallery figure { margin: 0; }
.gallery img { width: 100%; object-fit: cover; }
.gallery .g-a img { aspect-ratio: 600 / 672; max-height: 34rem; }
.gallery .g-b img { aspect-ratio: 4 / 5; object-position: 62% 50%; }
.gallery figcaption { font-size: var(--t-sm); color: var(--plum-soft); margin-top: 0.75rem; font-style: italic; }

/* Section head: heading left, short intro beneath */
.head { display: grid; grid-template-columns: 1fr; gap: 1.25rem; margin-bottom: clamp(2.5rem, 5vw, 4.5rem); }
.head p { color: var(--plum-soft); max-width: 34rem; margin: 0; font-size: var(--t-lead); line-height: 1.45; font-variation-settings: "opsz" 20; }
@media (min-width: 861px) {
  .head { grid-template-columns: 5fr 7fr; align-items: end; gap: 4rem; }
}

/* Services index */
.index { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.index > li {
  display: grid; grid-template-columns: 1fr; gap: 0.5rem 4rem;
  padding: clamp(1.5rem, 3vw, 2.5rem) 0;
  border-bottom: 1px solid var(--line);
}
.index h3 { font-size: clamp(1.75rem, 1.3rem + 1.6vw, 2.75rem); line-height: 1.1; font-variation-settings: "opsz" 60; }
.index p { margin: 0; color: var(--plum-soft); max-width: 36rem; }
.index p + p { margin-top: 0.9rem; }
@media (min-width: 861px) {
  .index > li { grid-template-columns: 5fr 7fr; align-items: baseline; }
}
.index-more { margin-top: 2rem; }

/* What people come for — sage band */
.sage-band { background: var(--sage-ink); color: var(--chalk); }
.sage-band .reasons-grid { display: grid; gap: 3rem; align-items: center; }
.reasons h2 { margin-bottom: 1rem; }
.reasons > p { color: #E6E7DF; max-width: 30rem; }
.reasons ul {
  list-style: none; margin: 2.25rem 0 0; padding: 0;
  columns: 2; column-gap: 2.5rem;
}
.reasons li {
  break-inside: avoid;
  font-size: clamp(1.2rem, 1.05rem + 0.5vw, 1.5rem); line-height: 1.25; font-variation-settings: "opsz" 30;
  padding: 0.85rem 0; border-top: 1px solid rgba(250, 249, 247, 0.22);
}
.reasons-figure { margin: 0; justify-self: center; width: min(100%, 26rem); }
.reasons-figure img { width: 100%; aspect-ratio: 600 / 672; object-fit: cover; object-position: 42% 40%; border-radius: 999px 999px 0 0; }
@media (min-width: 861px) {
  .sage-band .reasons-grid { grid-template-columns: 5fr 6fr; gap: clamp(3rem, 7vw, 7rem); }
}
@media (max-width: 420px) { .reasons ul { columns: 1; } }

/* Approach — calm two-column text */
.values { display: grid; grid-template-columns: 1fr; gap: 2.5rem clamp(3rem, 7vw, 7rem); }
.values h3 { margin-bottom: 0.7rem; }
.values p { color: var(--plum-soft); margin: 0; max-width: 32rem; }
@media (min-width: 720px) { .values { grid-template-columns: 1fr 1fr; } }
.approach-foot { margin-top: clamp(3rem, 6vw, 5rem); display: flex; gap: 1.5rem; flex-wrap: wrap; align-items: center; }

/* How to start — the only numbered thing on the page */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr; gap: 2.5rem; counter-reset: step; }
.steps li { position: relative; counter-increment: step; padding-top: 1rem; }
.steps li::before {
  content: counter(step);
  display: block; font-size: clamp(3.5rem, 2.8rem + 2.5vw, 5.5rem); line-height: 1;
  font-variation-settings: "opsz" 72; font-weight: 300; color: var(--sage);
  margin-bottom: 1.25rem;
}
.steps h3 { font-size: clamp(1.35rem, 1.2rem + 0.5vw, 1.65rem); margin-bottom: 0.5rem; }
.steps p { color: var(--plum-soft); margin: 0; max-width: 22rem; }
@media (min-width: 861px) {
  .steps { grid-template-columns: repeat(3, 1fr); gap: clamp(2rem, 4vw, 4rem); }
  .steps li { border-top: 1px solid var(--sage); padding-top: 2rem; }
  .steps li::after {
    content: ""; position: absolute; top: -5px; left: 0;
    width: 9px; height: 9px; border-radius: 50%; background: var(--sage);
  }
  .steps li:first-child::after { background: var(--gold); }
}
@media (max-width: 860px) {
  .steps li { padding-left: 0; border-top: 1px solid var(--line); padding-top: 1.5rem; }
}

/* Closing doorway */
.closing { text-align: center; }
.closing-door {
  margin: 0 auto; width: min(100%, 36rem);
  background: var(--plum); color: var(--chalk);
  border-radius: 999px 999px 0 0;
  padding: clamp(6rem, 14vw, 9rem) clamp(1.5rem, 6vw, 4rem) clamp(3rem, 6vw, 4.5rem);
}
.closing-door img { width: 3.25rem; margin: 0 auto 2rem; }
.closing-door h2 { font-size: clamp(2.1rem, 1.6rem + 2vw, 3.25rem); margin-bottom: 1.1rem; }
.closing-door p { color: #E8DCE2; font-size: var(--t-lead); line-height: 1.45; max-width: 24rem; margin: 0 auto 2.25rem; font-variation-settings: "opsz" 20; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); background: var(--stone); padding: clamp(3.5rem, 7vw, 5.5rem) 0 2rem; font-size: 1.0625rem; }
.footer-grid { display: grid; grid-template-columns: 1fr; gap: 2.5rem; }
.footer-grid h2 { font-size: 1.0625rem; font-weight: 600; letter-spacing: 0; margin-bottom: 0.8rem; font-variation-settings: "opsz" 12; line-height: 1.3; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li { margin-bottom: 0.4rem; }
.footer-grid a { text-decoration: none; }
.footer-grid a:hover { text-decoration: underline; }
.footer-brand .brand span { font-size: 1.35rem; }
.footer-brand p { margin-top: 1rem; color: var(--plum-soft); font-style: italic; }
.crisis { color: var(--plum); max-width: 26rem; }
.crisis strong { font-weight: 600; }
.legal p { margin: 0; }
.legal {
  display: flex; flex-wrap: wrap; gap: 0.5rem 1.75rem; justify-content: space-between;
  margin-top: clamp(3rem, 6vw, 4.5rem); padding-top: 1.5rem; border-top: 1px solid var(--line);
  font-size: var(--t-sm); color: var(--plum-soft);
}
.legal ul { display: flex; gap: 1.5rem; list-style: none; margin: 0; padding: 0; }
.legal a { text-decoration: none; }
.legal a:hover { text-decoration: underline; }
@media (min-width: 861px) { .footer-grid { grid-template-columns: 4fr 2fr 3fr 3fr; gap: 3rem; } }

/* ---------- Services page ---------- */
.page-intro { padding: clamp(3rem, 8vw, 7rem) 0 clamp(3rem, 6vw, 5rem); }
.page-intro .wrap { display: grid; gap: 2.5rem; align-items: end; }
.page-intro h1 { font-size: var(--t-display); line-height: 1.02; letter-spacing: -0.02em; margin-bottom: 1.5rem; }
.page-intro p { font-size: var(--t-lead); line-height: 1.45; color: var(--plum-soft); max-width: 34rem; font-variation-settings: "opsz" 20; }
.page-intro figure { margin: 0; justify-self: center; width: min(100%, 22rem); }
.page-intro figure img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; object-position: 30% 50%; border-radius: 999px 999px 0 0; }
@media (min-width: 861px) { .page-intro .wrap { grid-template-columns: 7fr 4fr; gap: 5rem; } .page-intro figure { justify-self: end; } }

.faq { max-width: 50rem; margin: 0 auto; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer;
  display: flex; justify-content: space-between; align-items: baseline; gap: 1.5rem;
  padding: 1.4rem 0; font-size: clamp(1.25rem, 1.1rem + 0.5vw, 1.55rem); line-height: 1.3; font-variation-settings: "opsz" 30;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 0.7rem; height: 0.7rem; margin-right: 0.3rem;
  border-right: 1.5px solid var(--plum); border-bottom: 1.5px solid var(--plum);
  transform: translateY(-0.2rem) rotate(45deg); transition: transform .25s ease;
}
.faq details[open] summary::after { transform: translateY(0.1rem) rotate(225deg); }
.faq details p { color: var(--plum-soft); max-width: 40rem; padding-bottom: 1.4rem; margin: 0; }
.faq-head { text-align: center; margin-bottom: clamp(2.5rem, 5vw, 4rem); }

.contact-grid { display: grid; gap: 3rem; }
.contact-copy h2 { margin-bottom: 1.25rem; }
.contact-copy p { color: var(--plum-soft); max-width: 28rem; }
.contact-copy .contact-email { color: var(--plum); font-size: var(--t-lead); }
.contact-copy .note { font-size: var(--t-sm); margin-top: 2rem; border-top: 1px solid var(--line); padding-top: 1.25rem; }
@media (min-width: 861px) { .contact-grid { grid-template-columns: 5fr 6fr; gap: clamp(3rem, 7vw, 7rem); } }

.form { display: grid; gap: 1.5rem; }
.field label, .field legend { display: block; font-size: 1.0625rem; margin-bottom: 0.45rem; padding: 0; }
.field input[type="text"], .field input[type="email"], .field textarea {
  width: 100%; font: inherit; font-size: 1.0625rem; color: var(--plum);
  background: var(--chalk); border: 1px solid rgba(79, 27, 53, 0.35); border-radius: 4px;
  padding: 0.8rem 0.9rem; min-height: 3rem;
}
.field textarea { min-height: 8.5rem; resize: vertical; line-height: 1.5; }
.field input:focus-visible, .field textarea:focus-visible { outline: 2px solid var(--plum); outline-offset: 1px; border-color: var(--plum); }
.field fieldset { border: 0; margin: 0; padding: 0; }
.choices { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.choice { position: relative; }
.choice input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.choice span {
  display: inline-flex; align-items: center; min-height: 2.9rem; padding: 0.55rem 1.25rem;
  border: 1px solid rgba(79, 27, 53, 0.35); border-radius: 999px; background: var(--chalk);
}
.choice input:checked + span { background: var(--plum); color: var(--chalk); border-color: var(--plum); }
.choice input:focus-visible + span { outline: 2px solid var(--plum); outline-offset: 3px; }
.form-hint { font-size: var(--t-sm); color: var(--plum-soft); margin: 0.4rem 0 0; }
.form-thanks { font-size: var(--t-lead); margin: 0; padding: 1.25rem 0; border-top: 1px solid var(--sage); border-bottom: 1px solid var(--sage); }
.form-thanks:focus { outline: none; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; scroll-behavior: auto !important; }
}

/* motion mode: the media escapes the frame and is measured against the sticky viewport */
.door-motion .door-sticky .door-stage, .door-motion .door-sticky .door-frame { position: static; }
.door-motion .door-media { inset: 0; }
a[href^="mailto:"] { overflow-wrap: anywhere; }
