/* Your BF Pattern — yourbfpattern.com
   Calm, editorial, warm. No frameworks, no JS. Mobile-first. */

:root {
  --bg: #fbf8f2;
  --bg-alt: #f4ede1;
  --ink: #2e2a24;
  --muted: #6f6557;
  --accent: #9c4a2f;
  --accent-dark: #7c3a23;
  --rule: #e6dccb;
  --footer-bg: #2c2720;
  --footer-ink: #efe7d9;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.125rem;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.wrap { max-width: 46rem; margin: 0 auto; padding: 0 1.375rem; }

h1, h2 { font-family: var(--serif); font-weight: 600; line-height: 1.25; margin: 0 0 1.25rem; }
p { margin: 0 0 1.25em; }
p:last-child { margin-bottom: 0; }
img { max-width: 100%; height: auto; display: block; }

a { color: var(--accent); }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 2px; }

/* ---------- Header ---------- */

.site-header { border-bottom: 1px solid var(--rule); }
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  padding-top: 0.65rem;
  padding-bottom: 0.65rem;
}
.brand {
  font-family: var(--serif);
  font-size: 1.3125rem;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}
.site-nav { display: flex; align-items: center; flex-wrap: wrap; gap: 0.4rem 1.15rem; }
.site-nav a { color: var(--ink); text-decoration: none; font-size: 0.875rem; }
.site-nav a:hover { color: var(--accent); }

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  background: var(--accent);
  color: #fff8ef;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 1.0625rem;
  text-decoration: none;
  border-radius: 999px;
  padding: 0.95rem 1.9rem;
  box-shadow: 0 1px 2px rgba(46, 42, 36, 0.18);
  transition: background-color 0.15s ease;
}
.btn:hover { background: var(--accent-dark); color: #fff8ef; }
.site-nav .btn { color: #fff8ef; font-size: 0.875rem; padding: 0.45rem 1.05rem; }
.btn-note { font-size: 0.875rem; color: var(--muted); margin-top: 0.85rem; }

/* ---------- Hero ---------- */

.hero { padding: 4rem 0 4.25rem; }
.eyebrow {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1.25rem;
}
.hero h1 { font-size: clamp(2rem, 6vw, 2.875rem); margin-bottom: 1.5rem; }
.hero .lead p { font-size: 1.1875rem; }
.hero .cta-block { margin-top: 2.25rem; }

/* ---------- Sections ---------- */

.section { padding: 4rem 0; }
.section-alt { background: var(--bg-alt); }
.section h2 { font-size: clamp(1.625rem, 4.5vw, 2.125rem); margin-bottom: 1.75rem; }

.pull {
  font-family: var(--serif);
  font-size: 1.375rem;
  line-height: 1.5;
  border-left: 3px solid var(--accent);
  padding-left: 1.25rem;
  margin: 2rem 0;
}

.photo-figure { margin: 2.5rem auto 0; max-width: 22rem; }
.photo-figure img { border-radius: 10px; }
.photo-figure figcaption {
  font-size: 0.875rem;
  font-style: italic;
  color: var(--muted);
  text-align: center;
  margin-top: 0.75rem;
}

.cta-block { margin-top: 2.25rem; }

/* ---------- Who I am ---------- */

.who-grid { display: grid; gap: 2rem; align-items: start; }
.who-photo { margin: 0; max-width: 13rem; }
.who-photo img { border-radius: 50%; aspect-ratio: 1 / 1; object-fit: cover; }
@media (min-width: 720px) {
  .who-grid { grid-template-columns: 13rem 1fr; gap: 2.5rem; }
  .who-photo { max-width: none; }
}

/* ---------- Final CTA ---------- */

.final-cta { text-align: center; padding: 4.5rem 0; }
.final-cta .cta-block { margin-top: 2rem; }

/* ---------- Footer ---------- */

.site-footer {
  background: var(--footer-bg);
  color: var(--footer-ink);
  font-size: 0.9375rem;
  line-height: 1.7;
  padding: 3.5rem 0 2.5rem;
}
.site-footer a { color: var(--footer-ink); }
.footer-cols { display: grid; gap: 2rem; margin-bottom: 2.5rem; }
@media (min-width: 720px) { .footer-cols { grid-template-columns: 1fr 1fr; } }
.footer-brand { font-family: var(--serif); font-size: 1.125rem; font-weight: 700; margin-bottom: 0.5rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: 0.4rem 1.15rem; margin-bottom: 1rem; }
.footer-links a { white-space: nowrap; }
.footer-small { font-size: 0.8125rem; opacity: 0.82; }
.footer-disclaimer { margin-top: 1.5rem; }
.footer-copyright { margin-top: 1.5rem; margin-bottom: 0; }

/* ---------- Logo ---------- */

.brand-logo { display: flex; align-items: center; text-decoration: none; }
.brand-logo img { height: 36px; width: auto; }

/* ---------- Learn index ---------- */

.learn-hero { padding: 2.5rem 0 0.5rem; }
.learn-hero h1 { font-size: clamp(1.75rem, 5vw, 2.25rem); margin-bottom: 0.65rem; }
.learn-hero .intro { color: var(--muted); max-width: 38rem; font-size: 1rem; }
.article-list { padding: 1.5rem 0 4.5rem; border-top: 1px solid var(--rule); margin-top: 1.5rem; }
.news-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  padding: 1.4rem 0;
  border-bottom: 1px solid var(--rule);
  text-decoration: none;
  color: inherit;
}
.news-meta {
  display: block;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.35rem;
}
.news-title {
  display: block;
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.25rem;
  line-height: 1.3;
  color: var(--ink);
  margin-bottom: 0.35rem;
  transition: color 0.15s ease;
}
.news-item:hover .news-title { color: var(--accent); }
.news-teaser { display: block; font-size: 0.9rem; color: var(--muted); line-height: 1.55; }
.news-thumb {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--bg-alt);
  display: flex;
  align-items: center;
  justify-content: center;
}
.news-thumb svg { width: 30px; height: 30px; }
@media (max-width: 480px) {
  .news-item { gap: 1rem; padding: 1.2rem 0; }
  .news-thumb { width: 42px; height: 42px; }
  .news-thumb svg { width: 22px; height: 22px; }
  .news-title { font-size: 1.125rem; }
}

/* ---------- Article pages ---------- */

.article-main { padding: 2.25rem 0 0; }
.article-main .wrap { max-width: 42rem; }
.article-header .eyebrow a { color: var(--accent); text-decoration: none; }
.article-header .eyebrow a:hover { text-decoration: underline; }
.article-header h1 {
  font-size: clamp(1.9rem, 6.5vw, 2.75rem);
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 1rem;
}
.dek {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.1875rem;
  line-height: 1.55;
  color: var(--muted);
  margin-bottom: 1.5rem;
}
.byline {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.8rem 0;
  margin-bottom: 2.25rem;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
.byline img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
.byline-text { font-size: 0.875rem; color: var(--muted); margin: 0; }
.article-body {
  font-family: var(--serif);
  font-size: 1.0938rem;
  line-height: 1.8;
}
.article-body > p:first-of-type::first-letter {
  float: left;
  font-family: var(--serif);
  font-size: 3.3em;
  line-height: 0.82;
  font-weight: 700;
  color: var(--accent);
  padding: 0.06em 0.13em 0 0;
}
.article-body h2 {
  font-family: var(--serif);
  font-weight: 700;
  font-size: clamp(1.35rem, 4vw, 1.5rem);
  margin: 2.6rem 0 1rem;
}
.article-body ul { padding-left: 1.375rem; }
.article-body li { margin-bottom: 0.5rem; }
.article-photo { margin: 2.25rem auto; max-width: 30rem; }
.article-photo img { border-radius: 10px; width: 100%; height: auto; }
.article-photo figcaption {
  font-size: 0.85rem;
  font-style: italic;
  color: var(--muted);
  text-align: center;
  margin-top: 0.6rem;
}

.art-figure {
  margin: 2.25rem 0;
  background: #fffdf9;
  border: 1px solid var(--rule);
  border-radius: 12px;
  padding: 1.25rem 1.25rem 1rem;
}
.art-figure svg { width: 100%; height: auto; display: block; }
.art-figure figcaption {
  font-size: 0.875rem;
  font-style: italic;
  color: var(--muted);
  text-align: center;
  margin-top: 0.6rem;
}

.bio-box, .cta-box {
  border: 1px solid var(--rule);
  border-radius: 12px;
  padding: 1.75rem;
  margin: 3rem 0;
  background: var(--bg-alt);
}
.box-title { font-size: 1.25rem; margin-bottom: 1.25rem; }
.bio-inner { display: flex; gap: 1.25rem; align-items: flex-start; }
.bio-photo { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.bio-inner p { font-size: 1rem; }

.cta-box { background: #f6e8db; border-color: #e9d3bf; text-align: center; }
.cta-title { font-family: var(--serif); font-size: 1.375rem; font-weight: 600; margin-bottom: 1rem; }
.cta-box > p { max-width: 34rem; margin-left: auto; margin-right: auto; }
.cta-action { margin: 1.5rem 0 0; }
.cta-box .btn-note { margin-top: 0.85rem; }

.refs { font-size: 0.8125rem; color: var(--muted); margin-top: 3rem; }
.refs h2 { font-size: 1.0625rem; color: var(--ink); margin-bottom: 0.85rem; }
.refs ol { padding-left: 1.25rem; margin: 0; }
.refs li { margin-bottom: 0.7rem; line-height: 1.55; }
.refs a { word-break: break-word; }

.disclaimers {
  font-size: 0.75rem;
  line-height: 1.6;
  color: var(--muted);
  border-top: 1px solid var(--rule);
  margin: 3rem 0 0;
  padding: 1.5rem 0 3rem;
}
.disclaimers p { margin-bottom: 1em; }
.site-footer .ad-disclaimer { font-size: 0.8125rem; opacity: 0.82; margin-top: 1.25rem; }

/* ---------- Legal pages ---------- */

.legal-main { padding: 3rem 0 4.5rem; }
.backlink { font-size: 0.9375rem; margin-bottom: 2.25rem; }
.legal-main h1 { font-size: clamp(1.9rem, 5vw, 2.5rem); margin-bottom: 0.75rem; }
.effective { color: var(--muted); margin-bottom: 2rem; }
.legal-main h2 { font-size: 1.375rem; margin: 2.5rem 0 1rem; }
.legal-main ul { margin: 0 0 1.25em; padding-left: 1.375rem; }
.legal-main li { margin-bottom: 0.5rem; }

/* ---------- Small screens ---------- */

@media (max-width: 560px) {
  .brand-logo img { height: 32px; }
  .site-nav a[href$="#story"], .site-nav a[href$="#what"] { display: none; }
  .art-figure { padding: 0.9rem 0.9rem 0.75rem; }
  .bio-box, .cta-box { padding: 1.25rem; }
  .bio-inner { display: block; }
  .bio-photo { width: 64px; height: 64px; margin-bottom: 1rem; }
}
