/* ============================================================
   Dr Keith O'Brien — drkeithobrien.com
   Editorial authority: ivory ground, deep ink anchor, brass accent.
   Hand-written CSS. No framework. No external requests.
   ============================================================ */

@font-face {
  font-family: 'Fraunces';
  src: url('assets/fonts/fraunces-latin.woff2') format('woff2');
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --ivory: #F7F3EA;
  --ivory-deep: #EFE9DB;
  --ink: #17293D;
  --ink-soft: #22374F;
  --text: #2A3644;
  --text-muted: #55616F;
  --brass: #9A6B21;
  --brass-deep: #7E5717;
  --line: #DCD4C3;
  --line-dark: rgba(247, 243, 234, 0.18);
  --serif: 'Fraunces', 'Iowan Old Style', Palatino, Georgia, serif;
  --sans: 'Avenir Next', 'Segoe UI', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --wrap: 1120px;
  --radius: 6px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 5rem; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
}

body {
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--ivory);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 1.5rem; }
.narrow { max-width: 760px; }
.centered { text-align: center; }
.section { padding: 6rem 0; }
.section-alt { background: var(--ivory-deep); }
.section-dark { background: var(--ink); color: var(--ivory); }

h1, h2, h3 { font-family: var(--serif); font-weight: 600; color: var(--ink); letter-spacing: -0.01em; }
.section-dark h2, .section-dark h3 { color: var(--ivory); }
h2 { font-size: clamp(1.9rem, 4vw, 2.6rem); line-height: 1.15; margin-bottom: 1.5rem; }
h3 { font-size: 1.25rem; margin-bottom: 0.6rem; }

.eyebrow {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brass-deep);
  margin-bottom: 1.2rem;
}

.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 100;
  background: var(--ink); color: var(--ivory); padding: 0.6rem 1rem;
}
.skip-link:focus { left: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--sans);
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius);
  transition: background-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}
.btn-primary {
  background: var(--brass);
  color: #fff;
  padding: 0.95rem 2rem;
  font-size: 1rem;
}
.btn-primary:hover { background: var(--brass-deep); transform: translateY(-1px); }
.btn-large { padding: 1.1rem 2.4rem; font-size: 1.05rem; }
.btn-secondary {
  background: var(--ink);
  color: var(--ivory);
  padding: 0.85rem 1.7rem;
  font-size: 0.95rem;
}
.btn-secondary:hover { background: var(--ink-soft); }
.btn-small {
  background: var(--brass);
  color: #fff;
  padding: 0.5rem 1.1rem;
  font-size: 0.85rem;
}
.btn-small:hover { background: var(--brass-deep); }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(247, 243, 234, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 4.25rem;
}
.nav-name {
  font-family: var(--serif);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
}
.nav-links { display: flex; align-items: center; gap: 1.8rem; }
.nav-links a:not(.btn) {
  font-size: 0.92rem; font-weight: 500;
  color: var(--text); text-decoration: none;
  border-bottom: 2px solid transparent;
  padding-bottom: 2px;
  transition: border-color 0.15s ease;
}
.nav-links a:not(.btn):hover { border-color: var(--brass); }
.nav-toggle { display: none; }

/* ---------- Hero ---------- */
.hero { padding: 5.5rem 0 5rem; position: relative; overflow: hidden; }
.hero::after {
  /* quiet editorial rule: a single brass hairline down the page gutter */
  content: '';
  position: absolute; top: 0; bottom: 0; left: 50%;
  width: 1px; background: transparent;
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 4rem;
  align-items: center;
}
.hero h1 {
  font-size: clamp(2.6rem, 6vw, 4.1rem);
  line-height: 1.06;
  margin-bottom: 1.6rem;
}
.hero-sub {
  font-size: 1.25rem;
  line-height: 1.5;
  color: var(--text-muted);
  max-width: 30ch;
  margin-bottom: 2.2rem;
}
.hero-note { margin-top: 1rem; font-size: 0.85rem; letter-spacing: 0.06em; color: var(--text-muted); }
.hero-photo { position: relative; }
.hero-photo img {
  border-radius: var(--radius);
  aspect-ratio: 4 / 4.6;
  object-fit: cover;
  object-position: top;
  box-shadow: 18px 18px 0 0 var(--ivory-deep), 19px 19px 0 1px var(--line);
}

/* ---------- Credentials strip ---------- */
.cred { background: var(--ink); color: var(--ivory); padding: 1.9rem 0; }
.cred-inner {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.5rem;
}
.cred p { display: flex; flex-direction: column; gap: 0.15rem; font-size: 0.95rem; }
.cred strong { font-family: var(--serif); font-size: 1.05rem; font-weight: 600; }
.cred span { color: rgba(247, 243, 234, 0.65); font-size: 0.85rem; }

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  gap: 4.5rem;
  align-items: start;
}
.about-photo img {
  border-radius: var(--radius);
  aspect-ratio: 4 / 4.2;
  object-fit: cover;
  object-position: 55% 25%;
}
.about-copy p { margin-bottom: 1.2rem; color: var(--text-muted); }
.badges { list-style: none; display: flex; flex-wrap: wrap; gap: 0.6rem; padding-top: 0.6rem; }
.badges li {
  font-size: 0.82rem; font-weight: 600;
  color: var(--ink);
  background: var(--ivory-deep);
  border: 1px solid var(--line);
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
}

/* ---------- Approach ---------- */
.question {
  max-width: 820px; margin: 3rem auto 2.5rem;
  position: relative;
  padding-left: 2.2rem;
  border-left: 3px solid var(--brass);
}
.question-mark {
  position: absolute; left: -0.4rem; top: -3.2rem;
  font-family: var(--serif); font-size: 7rem; font-weight: 600;
  color: var(--brass); opacity: 0.12;
  user-select: none;
}
.question-text {
  font-family: var(--serif);
  font-size: clamp(1.5rem, 3.2vw, 2.1rem);
  line-height: 1.3;
  color: var(--ink);
}
.question-text em { font-style: italic; color: var(--brass-deep); }
.approach-lede { max-width: 760px; margin: 0 auto 3.5rem; }
.approach-lede p { margin-bottom: 1.2rem; color: var(--text-muted); }
.cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.8rem; }
.col p { color: var(--text-muted); font-size: 0.98rem; }
.col h3 { position: relative; padding-top: 0.9rem; }
.col h3::before {
  content: ''; position: absolute; top: 0; left: 0;
  width: 2.2rem; height: 3px; background: var(--brass);
}
.approach-logistics {
  text-align: center; max-width: 620px;
  margin: 3.5rem auto 0;
  color: var(--text-muted); font-size: 0.98rem;
}

/* ---------- Who ---------- */
.who-lede { text-align: center; color: rgba(247, 243, 234, 0.75); margin-bottom: 3rem; }
.who-list { list-style: none; max-width: 640px; margin: 0 auto; }
.who-list li {
  position: relative;
  padding: 1.1rem 0 1.1rem 2.2rem;
  border-bottom: 1px solid var(--line-dark);
  font-size: 1.05rem;
}
.who-list li:last-child { border-bottom: none; }
.who-list li::before {
  content: ''; position: absolute; left: 0.2rem; top: 1.75rem;
  width: 0.55rem; height: 0.55rem; border-radius: 50%;
  background: var(--brass);
}

/* ---------- Fees ---------- */
.fees-lede { text-align: center; color: var(--text-muted); max-width: 560px; margin: 0 auto 3.5rem; }
.fee-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.8rem; align-items: stretch; }
.fee-card {
  background: #FDFBF6;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2.2rem 2rem;
}
.fee-card-featured { border: 2px solid var(--ink); position: relative; }
.fee-price { font-family: var(--serif); font-size: 2.3rem; font-weight: 600; color: var(--ink); line-height: 1; margin: 0.8rem 0 0.3rem; }
.fee-meta { font-size: 0.82rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--brass-deep); font-weight: 600; margin-bottom: 1rem; }
.fee-card > p:last-child { color: var(--text-muted); font-size: 0.95rem; }
.fees-foundation {
  max-width: 720px; margin: 3rem auto 0;
  padding: 1.4rem 1.8rem;
  background: var(--ivory-deep);
  border-left: 3px solid var(--brass);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: 0.98rem; color: var(--text-muted);
}
.fees-foundation strong { color: var(--ink); }

/* ---------- Lead magnet ---------- */
.magnet-inner {
  display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
  gap: 4rem; align-items: center;
}
.magnet-copy h2 { margin-bottom: 1rem; }
.magnet-copy > p { color: var(--text-muted); max-width: 52ch; }
.magnet-cta { margin-top: 2rem; display: flex; align-items: center; gap: 1.2rem; flex-wrap: wrap; }
.magnet-note { font-size: 0.85rem; color: var(--text-muted); }
.magnet-visual { display: flex; justify-content: center; }
.magnet-doc {
  width: 200px; aspect-ratio: 1 / 1.414;
  background: var(--ink);
  border-radius: 4px;
  display: flex; align-items: flex-end;
  padding: 1.4rem;
  box-shadow: 14px 14px 0 0 rgba(154, 107, 33, 0.18);
  transform: rotate(-2.5deg);
}
.magnet-doc span {
  font-family: var(--serif); font-weight: 600;
  color: var(--ivory); font-size: 1.35rem; line-height: 1.25;
  border-top: 3px solid var(--brass); padding-top: 0.8rem;
}

/* ---------- Quotes (dormant until real testimonials) ---------- */
.quote-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.8rem; }
.quote-card {
  background: #FDFBF6; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 2rem;
}
.quote-card blockquote { font-family: var(--serif); font-size: 1.1rem; color: var(--ink); margin-bottom: 1rem; }
.quote-card figcaption { font-size: 0.88rem; color: var(--text-muted); }

/* ---------- FAQ ---------- */
.faq details {
  border-bottom: 1px solid var(--line);
  padding: 0.4rem 0;
}
.faq details:first-of-type { border-top: 1px solid var(--line); }
.faq summary {
  font-family: var(--serif);
  font-size: 1.15rem; font-weight: 600;
  color: var(--ink);
  padding: 1.1rem 2.4rem 1.1rem 0;
  cursor: pointer;
  list-style: none;
  position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: '+';
  position: absolute; right: 0.4rem; top: 50%;
  transform: translateY(-50%);
  font-family: var(--sans); font-size: 1.5rem; font-weight: 300;
  color: var(--brass);
  transition: transform 0.2s ease;
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { padding: 0 0 1.4rem; color: var(--text-muted); max-width: 65ch; }

/* ---------- Final CTA ---------- */
.cta { padding: 6.5rem 0; }
.cta-sub { color: rgba(247, 243, 234, 0.75); margin-bottom: 2.4rem; }
.cta-email { margin-top: 1.6rem; font-size: 0.92rem; color: rgba(247, 243, 234, 0.6); }
.cta-email a { color: var(--ivory); text-underline-offset: 4px; }

/* ---------- Footer ---------- */
.footer { background: var(--ivory); border-top: 1px solid var(--line); padding: 2rem 0; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.footer p { font-size: 0.8rem; color: var(--text-muted); }
.footer a { color: var(--text-muted); }
.footer a:hover { color: var(--ink); }

/* ---------- Hero entrance (CSS-only; never depends on JS) ---------- */
@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: none; }
}
.rise { animation: rise 0.7s ease both; }
.rise-late { animation-delay: 0.15s; }
@media (prefers-reduced-motion: reduce) {
  .rise, .rise-late { animation: none; }
}

/* ---------- Scroll reveals ---------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: none; }
.reveal-late { transition-delay: 0.15s; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .section { padding: 4.5rem 0; }
  .hero { padding: 3.5rem 0; }
  .hero-grid, .about-grid, .magnet-inner { grid-template-columns: 1fr; gap: 2.8rem; }
  .hero-photo { max-width: 440px; }
  .hero-sub { max-width: none; }
  .cred-inner { grid-template-columns: 1fr; gap: 1.3rem; }
  .cols, .fee-cards, .quote-grid { grid-template-columns: 1fr; gap: 2.2rem; }
  .about-photo { max-width: 340px; }
  .magnet-visual { justify-content: flex-start; padding-left: 1rem; }

  .nav-toggle {
    display: flex; flex-direction: column; gap: 6px;
    background: none; border: none; cursor: pointer; padding: 8px;
  }
  .nav-toggle span { width: 24px; height: 2px; background: var(--ink); transition: transform 0.2s ease; }
  .nav-toggle[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }
  .nav-links {
    display: none;
    position: absolute; top: 4.25rem; left: 0; right: 0;
    background: var(--ivory);
    border-bottom: 1px solid var(--line);
    flex-direction: column; align-items: flex-start;
    padding: 1.2rem 1.5rem 1.6rem; gap: 1.1rem;
  }
  .nav-links.open { display: flex; }
}
