/* =============================================================
   Arch Buys Houses — editorial styles
   Set in Fraunces (display) & Instrument Sans (body).
   Published from St. Louis, Missouri.
============================================================= */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,400..700;1,9..144,400..600&family=Instrument+Sans:wght@400;500;600&display=swap');

:root {
  --paper:       #F7F3EA;
  --paper-2:     #EFE9DB;
  --stone:       #E2DBC9;
  --ink:         #14110D;
  --ink-muted:   #50483B;
  --ink-soft:    #7A725F;
  --accent:      #C25B32;
  --accent-ink:  #7A2E17;
  --hairline:    #CBC3B0;

  --measure:     60ch;
  --frame-max:   1260px;
  --frame-pad:   clamp(20px, 5vw, 72px);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Instrument Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-feature-settings: 'ss01', 'liga' 1, 'kern' 1;
  hanging-punctuation: first last;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a {
  color: var(--accent-ink);
  text-decoration-line: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color 160ms ease, text-decoration-thickness 160ms ease;
}
a:hover { color: var(--accent); text-decoration-thickness: 1.5px; }
::selection { background: var(--ink); color: var(--paper); }

/* --- Heading scale --- */
h1, h2, h3, h4 {
  font-family: 'Fraunces', 'Times New Roman', Georgia, serif;
  font-weight: 700;
  line-height: 1.0;
  letter-spacing: -0.025em;
  color: var(--ink);
  font-variation-settings: 'opsz' 144;
  text-wrap: balance;
}
h1 { font-size: clamp(48px, 8vw, 132px); line-height: 0.95; letter-spacing: -0.035em; }
h2 { font-size: clamp(32px, 4.6vw, 60px); line-height: 1.02; letter-spacing: -0.025em; font-variation-settings: 'opsz' 96; }
h3 { font-size: clamp(20px, 2vw, 26px); line-height: 1.15; letter-spacing: -0.012em; font-variation-settings: 'opsz' 32; }
h4 { font-size: clamp(16px, 1.3vw, 18px); line-height: 1.3; font-variation-settings: 'opsz' 24; }
em, i, .italic {
  font-family: 'Fraunces', Georgia, serif;
  font-style: italic;
  font-variation-settings: 'opsz' 72;
  font-weight: 400;
}
p { max-width: var(--measure); margin: 0 0 1em; }
strong, b { font-weight: 600; }

/* --- Eyebrow labels --- */
.label {
  font-family: 'Instrument Sans', sans-serif;
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-soft);
  display: inline-block;
}
.label--accent { color: var(--accent); }
.label--ink    { color: var(--ink); }

/* --- Frame --- */
.frame {
  max-width: var(--frame-max);
  margin: 0 auto;
  padding: 0 var(--frame-pad);
  width: 100%;
}

/* --- Masthead --- */
.mast { padding: 24px 0 18px; border-bottom: 1px solid var(--hairline); position: relative; z-index: 5; }
.mast__inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: baseline;
  gap: clamp(12px, 3vw, 32px);
}
.mast__left, .mast__right {
  font-family: 'Instrument Sans', sans-serif;
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.mast__right { text-align: right; }
.mast__title {
  font-family: 'Fraunces', serif;
  font-weight: 700;
  font-size: clamp(22px, 2.6vw, 30px);
  letter-spacing: -0.025em;
  color: var(--ink);
  text-decoration: none;
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  white-space: nowrap;
  font-variation-settings: 'opsz' 60;
}
.mast__title:hover { color: var(--ink); }
.mast__glyph { width: 18px; height: 22px; display: inline-block; vertical-align: -2px; }
.mast__glyph path { stroke: var(--accent); }

@media (max-width: 640px) {
  .mast__inner {
    grid-template-columns: 1fr;
    grid-template-areas: "title" "meta";
    gap: 8px;
    text-align: left;
  }
  .mast__title { grid-area: title; font-size: 20px; }
  .mast__left { grid-area: meta; font-size: 10px; }
  .mast__right { display: none; }
}

/* --- Hero --- */
.hero { padding: clamp(80px, 12vw, 176px) 0 clamp(56px, 9vw, 120px); position: relative; overflow: hidden; }
.hero__ornament {
  position: absolute;
  right: clamp(-140px, -6vw, -40px);
  top: 10%;
  width: min(640px, 52vw);
  height: auto;
  opacity: 0;
  pointer-events: none;
  z-index: 0;
}
.hero__ornament path { stroke: var(--accent); }
.hero__inner { position: relative; z-index: 1; max-width: 900px; }
.hero__label {
  margin-bottom: 36px;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  color: var(--accent);
}
.hero__label::before {
  content: "";
  display: inline-block;
  width: 48px;
  height: 1px;
  background: var(--accent);
}
.hero h1 { max-width: 13ch; margin-bottom: 40px; }
.hero h1 em { color: var(--accent-ink); }
.hero__sub {
  font-size: clamp(18px, 1.65vw, 22px);
  color: var(--ink-muted);
  max-width: 50ch;
  line-height: 1.45;
  margin-bottom: 44px;
}
.hero__sub em { color: var(--ink); }
.hero__cta, .final__cta, .ghost__cta {
  font-family: 'Instrument Sans', sans-serif;
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 18px 28px;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  transition: gap 180ms ease, background 180ms ease, color 180ms ease, border-color 180ms ease;
  cursor: pointer;
  border-radius: 0;
  font: inherit;
  font-family: 'Instrument Sans', sans-serif;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 500;
  line-height: 1;
}
button.hero__cta, button.final__cta, button.ghost__cta { appearance: none; }
.hero__cta { color: var(--ink); background: transparent; border: 1px solid var(--ink); }
.hero__cta:hover { background: var(--ink); color: var(--paper); gap: 18px; text-decoration: none; }
.cta__arrow { font-family: 'Fraunces', serif; font-style: italic; font-size: 18px; line-height: 1; transform: translateY(-1px); transition: transform 180ms ease; font-variation-settings: 'opsz' 48; }
.hero__cta:hover .cta__arrow, .final__cta:hover .cta__arrow { transform: translate(3px, -3px); }

/* --- Phone "or call" alternative beneath a CTA --- */
.alt-call {
  margin-top: 22px;
  font-family: 'Instrument Sans', sans-serif;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-soft);
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}
.alt-call a {
  color: var(--ink);
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
  font-size: 18px;
  text-decoration: none;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 1px;
  font-variation-settings: 'opsz' 48;
  transition: color 160ms ease, border-color 160ms ease;
}
.alt-call a:hover { color: var(--accent-ink); border-bottom-color: var(--accent-ink); }
.final .alt-call { justify-content: center; }

/* --- Chapters --- */
.chapter { padding: clamp(88px, 11vw, 160px) 0; border-top: 1px solid var(--hairline); }
.chapter__grid { display: grid; grid-template-columns: 1fr; gap: 32px; }
.chapter__num {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: clamp(88px, 14vw, 180px);
  line-height: 0.78;
  color: var(--accent);
  font-variation-settings: 'opsz' 144;
  font-feature-settings: 'onum';
  letter-spacing: -0.04em;
  display: block;
}
.chapter__head { display: flex; flex-direction: column; gap: 14px; margin-bottom: 32px; }
.chapter__eyebrow { color: var(--ink-soft); }
.chapter h2 { max-width: 18ch; }
.chapter__lede {
  font-size: clamp(20px, 1.8vw, 25px);
  color: var(--ink);
  line-height: 1.35;
  margin-bottom: 28px;
  max-width: 42ch;
  letter-spacing: -0.005em;
}
.chapter__lede em { color: var(--accent-ink); }
.chapter__body { font-size: clamp(17px, 1.3vw, 19px); line-height: 1.55; }
.chapter__body p { color: var(--ink-muted); max-width: 54ch; }
.chapter__body em { color: var(--accent-ink); }

/* Drop cap for the first chapter */
.dropcap::first-letter {
  font-family: 'Fraunces', serif;
  font-weight: 700;
  font-variation-settings: 'opsz' 144;
  font-size: 6em;
  line-height: 0.82;
  float: left;
  padding: 6px 14px 0 0;
  color: var(--ink);
}

/* --- Three-step list --- */
.steps { margin-top: 40px; list-style: none; border-top: 1px solid var(--hairline); }
.step {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 28px;
  padding: 36px 0;
  border-bottom: 1px solid var(--hairline);
  align-items: baseline;
}
.step__num { font-family: 'Instrument Sans', sans-serif; font-size: 12px; font-weight: 500; letter-spacing: 0.2em; color: var(--accent); padding-top: 8px; }
.step__title {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 400;
  font-size: clamp(24px, 2.6vw, 34px);
  line-height: 1.15;
  margin-bottom: 8px;
  color: var(--ink);
  font-variation-settings: 'opsz' 72;
  letter-spacing: -0.01em;
}
.step p { color: var(--ink-muted); margin: 0; max-width: 48ch; font-size: 16px; line-height: 1.55; }

/* --- Pull quote --- */
.pullquote {
  padding: clamp(96px, 12vw, 168px) var(--frame-pad);
  text-align: center;
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
  background: var(--paper-2);
  position: relative;
}
.pullquote__mark {
  font-family: 'Fraunces', serif;
  font-size: 80px;
  line-height: 0;
  color: var(--accent);
  display: block;
  margin: 0 auto 44px;
  letter-spacing: -0.04em;
  height: 40px;
}
.pullquote__text {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 400;
  font-size: clamp(34px, 5.6vw, 84px);
  line-height: 1.0;
  letter-spacing: -0.03em;
  max-width: 18ch;
  margin: 0 auto;
  color: var(--ink);
  font-variation-settings: 'opsz' 144;
  text-wrap: balance;
}
.pullquote__attr { margin-top: 48px; color: var(--ink-soft); }

/* --- Negations list --- */
.negs { list-style: none; padding: 0; margin: 40px 0 0; border-top: 1px solid var(--hairline); }
.negs li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 24px;
  padding: 28px 0;
  border-bottom: 1px solid var(--hairline);
  align-items: baseline;
}
.negs__mark { font-family: 'Fraunces', serif; font-size: 28px; line-height: 1; color: var(--accent); padding-top: 2px; }
.negs strong {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 400;
  font-size: clamp(19px, 1.7vw, 24px);
  display: block;
  color: var(--ink);
  margin-bottom: 8px;
  font-variation-settings: 'opsz' 72;
  letter-spacing: -0.01em;
}
.negs span { color: var(--ink-muted); font-size: 16px; line-height: 1.55; max-width: 56ch; display: block; }

/* --- Final CTA band --- */
.final { padding: clamp(96px, 13vw, 180px) 0; text-align: center; border-top: 1px solid var(--hairline); }
.final__label { margin-bottom: 28px; color: var(--accent); }
.final h2 { max-width: 18ch; margin: 0 auto 32px; font-size: clamp(36px, 5.2vw, 76px); }
.final p { color: var(--ink-muted); max-width: 44ch; margin: 0 auto 44px; font-size: 18px; line-height: 1.55; }
.ghost__cta { color: var(--accent); background: transparent; border: 1px solid var(--accent); }
.ghost__cta:hover { background: var(--accent); color: var(--paper); gap: 18px; }
.ghost__cta:hover .cta__arrow { transform: translate(3px, -3px); }

/* --- Footer / colophon --- */
.foot { padding: 72px 0 80px; border-top: 1px solid var(--hairline); background: var(--paper); }
.foot__grid { display: grid; grid-template-columns: 1fr; gap: 48px; margin-bottom: 48px; }
.foot__brand h3 {
  font-family: 'Fraunces', serif;
  font-weight: 700;
  font-size: 28px;
  letter-spacing: -0.025em;
  color: var(--ink);
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  font-variation-settings: 'opsz' 60;
  margin-bottom: 16px;
}
.foot__tag { color: var(--ink-muted); max-width: 42ch; font-size: 15px; line-height: 1.55; }
.foot__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.foot__col h4 {
  font-family: 'Instrument Sans', sans-serif;
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink);
  margin-bottom: 14px;
}
.foot__col ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.foot__col a { color: var(--ink-muted); text-decoration: none; font-size: 15px; border-bottom: 1px solid transparent; }
.foot__col a:hover { color: var(--ink); border-bottom-color: var(--ink-muted); }
.foot__col p { color: var(--ink-muted); font-size: 15px; margin: 0 0 6px; max-width: 30ch; }
.foot__colophon {
  padding-top: 32px;
  border-top: 1px solid var(--hairline);
  display: flex;
  flex-wrap: wrap;
  gap: 16px 32px;
  justify-content: space-between;
  align-items: baseline;
  font-family: 'Instrument Sans', sans-serif;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.foot__colophon em {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-size: 13px;
  letter-spacing: 0.02em;
  text-transform: none;
  color: var(--ink-muted);
  font-variation-settings: 'opsz' 48;
}

/* --- Legal pages --- */
.legal-head { padding: clamp(64px, 10vw, 128px) 0 clamp(32px, 4vw, 56px); border-bottom: 1px solid var(--hairline); }
.legal-head__label { color: var(--accent); margin-bottom: 28px; }
.legal-head h1 { font-size: clamp(40px, 5.8vw, 96px); max-width: 16ch; margin-bottom: 16px; letter-spacing: -0.035em; }
.legal-head__date { color: var(--ink-soft); font-size: 13px; letter-spacing: 0.16em; text-transform: uppercase; font-weight: 500; }
.legal-head__date em {
  font-family: 'Fraunces', serif;
  font-style: italic;
  text-transform: none;
  letter-spacing: 0;
  color: var(--ink-muted);
  font-size: 17px;
  font-variation-settings: 'opsz' 48;
  margin-left: 10px;
}

.prose { max-width: 700px; padding: clamp(48px, 7vw, 96px) 0 clamp(64px, 10vw, 128px); }
.prose > p:first-of-type { font-size: 20px; color: var(--ink); line-height: 1.45; max-width: 52ch; margin-bottom: 1.5em; letter-spacing: -0.005em; }
.prose h2 {
  font-family: 'Fraunces', serif;
  font-size: clamp(24px, 2.6vw, 34px);
  margin-top: 3.2em;
  margin-bottom: 0.7em;
  letter-spacing: -0.02em;
  font-variation-settings: 'opsz' 48;
}
.prose h2:first-of-type { margin-top: 0.2em; }
.prose h3 {
  font-family: 'Instrument Sans', sans-serif;
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-top: 2.5em;
  margin-bottom: 0.6em;
}
.prose p, .prose li { color: var(--ink-muted); font-size: 17px; line-height: 1.65; }
.prose p { margin: 0 0 1em; max-width: 60ch; }
.prose ul, .prose ol { padding-left: 1.4em; margin: 0 0 1.2em; }
.prose li { margin-bottom: 0.5em; max-width: 58ch; }
.prose strong { color: var(--ink); font-weight: 600; }

/* --- Callout (SMS subsection) --- */
.callout {
  padding: clamp(32px, 4vw, 52px);
  background: var(--paper-2);
  border-left: 3px solid var(--accent);
  margin: 3em 0;
  position: relative;
}
.callout::before {
  content: "";
  position: absolute;
  left: 0; top: 0;
  width: 3px; height: 32px;
  background: var(--ink);
}
.callout > h2:first-child { margin-top: 0 !important; }
.callout p { max-width: 56ch; font-size: 16.5px; }
.callout strong { color: var(--ink); }

/* --- SMS definition grid (on sms-terms.html) --- */
.sms-def {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border-top: 1px solid var(--hairline);
  margin: 2.5em 0 2em;
}
.sms-def li { padding: 24px 0; border-bottom: 1px solid var(--hairline); display: grid; gap: 6px; }
.sms-def strong {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 400;
  font-size: 19px;
  color: var(--ink);
  font-variation-settings: 'opsz' 48;
  letter-spacing: -0.005em;
}
.sms-def span { color: var(--ink-muted); font-size: 16px; line-height: 1.5; max-width: 56ch; }

/* --- Contact card on legal pages --- */
.contact-card {
  margin-top: 2.5em;
  padding: clamp(28px, 3.6vw, 44px);
  background: var(--stone);
  display: grid;
  gap: 8px;
}
.contact-card h3 {
  font-family: 'Fraunces', serif;
  font-weight: 700;
  font-size: 20px;
  color: var(--ink);
  font-variation-settings: 'opsz' 32;
  letter-spacing: -0.01em;
  margin-bottom: 12px;
  font-style: normal;
  text-transform: none;
}
.contact-card p { color: var(--ink-muted); margin: 0; font-size: 15px; line-height: 1.6; max-width: none; }
.contact-card a { color: var(--accent-ink); }

/* --- Animations --- */
@media (prefers-reduced-motion: no-preference) {
  @keyframes up {
    from { opacity: 0; transform: translate3d(0, 32px, 0); }
    to   { opacity: 1; transform: translate3d(0, 0, 0); }
  }
  @keyframes fade35 {
    from { opacity: 0; }
    to   { opacity: 0.35; }
  }
  @keyframes draw {
    from { stroke-dashoffset: 1200; }
    to   { stroke-dashoffset: 0; }
  }
  .hero__label, .hero h1, .hero__sub, .hero__cta {
    opacity: 0;
    animation: up 900ms cubic-bezier(.2,.6,.2,1) forwards;
  }
  .hero__label { animation-delay: 120ms; }
  .hero h1    { animation-delay: 280ms; }
  .hero__sub  { animation-delay: 560ms; }
  .hero__cta  { animation-delay: 780ms; }
  .hero__ornament { animation: fade35 1400ms ease 300ms forwards; }
  .hero__ornament path {
    stroke-dasharray: 1200;
    stroke-dashoffset: 1200;
    animation: draw 2400ms cubic-bezier(.2,.6,.2,1) 400ms forwards;
  }
}

/* --- Breakpoints --- */
@media (min-width: 720px) {
  .chapter__grid { grid-template-columns: 0.8fr 2fr; gap: 56px; }
  .foot__grid { grid-template-columns: 1.2fr 2fr; align-items: start; }
  .foot__cols { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 1024px) {
  .chapter__grid { grid-template-columns: 0.7fr 2.8fr; gap: 96px; }
  .chapter__num { position: sticky; top: 40px; align-self: start; }
  .foot__cols { grid-template-columns: repeat(3, 1fr); }
  .pullquote__text { max-width: 16ch; }
}

@media (max-width: 720px) {
  .dropcap::first-letter { font-size: 5em; padding-right: 10px; }
  .pullquote__mark { font-size: 56px; margin-bottom: 28px; height: 28px; }
  .hero h1 { max-width: none; }
}
