/* =============================================================
   True Community Baptist Church — design system
   Black & white editorial. Warm paper, deep ink, bronze accent.
   ============================================================= */

:root {
  --bone:       #f5f1e8;
  --bone-2:     #ece6d8;
  --paper:      #fbf9f3;
  --ink:        #15130e;
  --ink-soft:   #2a2620;
  --muted:      #6b6356;
  --line:       rgba(21, 19, 14, 0.12);
  --line-soft:  rgba(21, 19, 14, 0.07);
  --accent:     #9a6b33;
  --accent-dk:  #7d551f;
  --accent-soft:rgba(154, 107, 51, 0.10);

  /* on dark sections */
  --on-dark:        #f5f1e8;
  --on-dark-muted:  rgba(245, 241, 232, 0.62);
  --line-dark:      rgba(245, 241, 232, 0.15);

  --maxw: 1180px;
  --gutter: clamp(1.25rem, 5vw, 4rem);

  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Hanken Grotesk", -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--bone);
  color: var(--ink);
  line-height: 1.6;
  font-size: 1.0625rem;
  letter-spacing: -0.005em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; cursor: pointer; }

/* ---------- type ---------- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.04;
  letter-spacing: -0.02em;
  font-optical-sizing: auto;
}
.display {
  font-size: clamp(2.6rem, 7vw, 5.4rem);
  font-weight: 350;
}
h2.section-title { font-size: clamp(1.9rem, 4.2vw, 3.2rem); }
h3 { font-size: clamp(1.25rem, 2.4vw, 1.65rem); }
.eyebrow {
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
}
.lede { font-size: clamp(1.1rem, 2vw, 1.4rem); line-height: 1.5; color: var(--ink-soft); }
.muted { color: var(--muted); }

/* ---------- layout ---------- */
.wrap { max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
section { padding-block: clamp(4rem, 9vw, 8rem); }
.section-ink { background: var(--ink); color: var(--on-dark); }
.section-ink .eyebrow { color: #d2a261; }
.section-ink .muted, .section-ink .lede { color: var(--on-dark-muted); }
.divider { height: 1px; background: var(--line); border: 0; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.6em;
  padding: 0.95em 1.6em;
  font-size: 0.92rem; font-weight: 600; letter-spacing: 0.01em;
  border-radius: 999px;
  text-decoration: none;
  border: 1px solid var(--ink);
  transition: transform .25s ease, background .25s ease, color .25s ease, border-color .25s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-solid { background: var(--ink); color: var(--bone); }
.btn-solid:hover { background: var(--accent-dk); border-color: var(--accent-dk); }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: var(--bone); }
.section-ink .btn-solid { background: var(--bone); color: var(--ink); border-color: var(--bone); }
.section-ink .btn-solid:hover { background: var(--accent); border-color: var(--accent); color: var(--bone); }
.section-ink .btn-ghost { color: var(--on-dark); border-color: var(--line-dark); }
.section-ink .btn-ghost:hover { background: var(--bone); color: var(--ink); border-color: var(--bone); }
.btn .arrow { transition: transform .25s ease; }
.btn:hover .arrow { transform: translateX(3px); }

/* ---------- orbit mark (inline svg uses currentColor) ---------- */
.mark { width: 1.9rem; height: 1.9rem; flex: none; }
.mark .core { fill: currentColor; }
.mark .ring { fill: none; stroke: currentColor; stroke-width: 2.4; }

/* =============================================================
   HEADER
   ============================================================= */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bone) 86%, transparent);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s ease, background .3s ease;
}
.site-header.scrolled { border-bottom-color: var(--line); }
.nav {
  display: flex; align-items: center; justify-content: space-between;
  height: 72px;
}
.brand { display: flex; align-items: center; gap: 0.7rem; text-decoration: none; color: var(--ink); }
.brand-name {
  font-family: var(--font-display); font-size: 1.15rem; letter-spacing: 0.04em;
  text-transform: uppercase; font-weight: 400; line-height: 1;
}
.brand-name small { display: block; font-size: 0.6rem; letter-spacing: 0.32em; color: var(--muted); margin-top: 3px; }
.nav-links { display: flex; align-items: center; gap: clamp(1rem, 2.4vw, 2.2rem); list-style: none; }
.nav-links a {
  text-decoration: none; font-size: 0.92rem; font-weight: 500; color: var(--ink-soft);
  padding-block: 0.4rem; position: relative; transition: color .2s ease;
}
.nav-links a::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 1px; width: 0;
  background: var(--accent); transition: width .25s ease;
}
.nav-links a:hover { color: var(--ink); }
.nav-links a:hover::after, .nav-links a[aria-current="page"]::after { width: 100%; }
.nav-links a[aria-current="page"] { color: var(--ink); }
.nav-cta { margin-left: 0.4rem; }
.nav-cta .btn { padding: 0.6em 1.2em; }

.nav-toggle {
  display: none; background: none; border: 0; padding: 0.5rem; margin: -0.5rem;
}
.nav-toggle span { display: block; width: 26px; height: 2px; background: var(--ink); transition: .3s; }
.nav-toggle span + span { margin-top: 6px; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

@media (max-width: 880px) {
  .nav-toggle { display: block; z-index: 60; }
  .nav-links {
    position: fixed; inset: 0 0 0 auto; width: min(80vw, 340px);
    flex-direction: column; align-items: flex-start; justify-content: center;
    gap: 1.5rem; padding: var(--gutter);
    background: var(--ink); color: var(--on-dark);
    transform: translateX(100%); transition: transform .4s cubic-bezier(.4,0,.2,1);
  }
  .nav-links.open { transform: translateX(0); }
  .nav-links a { color: var(--on-dark); font-size: 1.3rem; font-family: var(--font-display); }
  .nav-links a::after { background: #d2a261; }
  .nav-cta { margin: 0.5rem 0 0; }
  .nav-cta .btn { background: var(--bone); color: var(--ink); border-color: var(--bone); }
}

/* =============================================================
   HERO
   ============================================================= */
.hero {
  background: var(--ink); color: var(--on-dark);
  position: relative; overflow: hidden;
  padding-block: clamp(5rem, 13vw, 10rem);
}
.hero::before {
  /* faint orbit motif echoing the logo */
  content: ""; position: absolute; right: -12%; top: 50%; transform: translateY(-50%);
  width: min(60vw, 640px); aspect-ratio: 1;
  background:
    radial-gradient(circle at center, transparent 0 24%, rgba(210,162,97,.08) 24% 24.4%, transparent 25%),
    conic-gradient(from 0deg, transparent, rgba(245,241,232,.04), transparent 50%);
  border-radius: 50%;
  pointer-events: none;
}
.hero .wrap { position: relative; }
.hero .eyebrow { color: #d2a261; }
.hero .display { margin: 1rem 0 1.2rem; max-width: 14ch; }
.hero .lede { max-width: 46ch; color: var(--on-dark-muted); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 2.4rem; }
.hero-meta {
  margin-top: 3rem; padding-top: 1.6rem; border-top: 1px solid var(--line-dark);
  display: flex; flex-wrap: wrap; gap: 2.4rem;
}
.hero-meta .item small { display: block; font-size: 0.72rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--on-dark-muted); margin-bottom: 0.3rem; }
.hero-meta .item strong { font-family: var(--font-display); font-weight: 400; font-size: 1.25rem; }
.hero-logo {
  width: 64px; height: 64px; border-radius: 14px; object-fit: cover;
  margin-bottom: 1.6rem; box-shadow: 0 10px 40px rgba(0,0,0,.35);
}

/* =============================================================
   GENERIC CONTENT BLOCKS
   ============================================================= */
.split { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: clamp(2rem, 6vw, 5rem); align-items: start; }
@media (max-width: 820px) { .split { grid-template-columns: 1fr; gap: 2.2rem; } }

.stack > * + * { margin-top: 1.2rem; }
.section-head { max-width: 60ch; margin-bottom: clamp(2.4rem, 5vw, 3.6rem); }
.section-head .eyebrow { display: block; margin-bottom: 0.9rem; }
.section-head p { margin-top: 1rem; color: var(--muted); font-size: 1.1rem; }

/* cards grid */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1.5rem; }
.card {
  background: var(--paper); border: 1px solid var(--line); border-radius: 18px;
  padding: clamp(1.6rem, 3vw, 2.2rem);
  transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 18px 50px -24px rgba(21,19,14,.4); border-color: var(--ink); }
.card .num { font-family: var(--font-display); color: var(--accent); font-size: 1.1rem; }
.card h3 { margin: 0.6rem 0 0.5rem; }
.card p { color: var(--muted); font-size: 0.97rem; }
.card .card-link { display: inline-flex; gap: .4em; align-items: center; margin-top: 1.1rem; text-decoration: none; font-weight: 600; font-size: 0.9rem; color: var(--ink); border-bottom: 1px solid var(--accent); padding-bottom: 2px; }
.card .card-link:hover { color: var(--accent-dk); }

/* feature list */
.feature-list { list-style: none; padding: 0; display: grid; gap: 0; }
.feature-list li { display: flex; gap: 1rem; padding: 1.4rem 0; border-top: 1px solid var(--line); }
.feature-list li:last-child { border-bottom: 1px solid var(--line); }
.feature-list .k { font-family: var(--font-display); font-size: 1.05rem; min-width: 9rem; }
.feature-list .v { color: var(--muted); }

/* accordion (beliefs) */
.accordion { border-top: 1px solid var(--line); }
.accordion details { border-bottom: 1px solid var(--line); }
.accordion summary {
  list-style: none; cursor: pointer; padding: 1.3rem 0;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  font-family: var(--font-display); font-size: clamp(1.1rem, 2vw, 1.4rem);
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary .plus { flex: none; width: 22px; height: 22px; position: relative; transition: transform .3s ease; }
.accordion summary .plus::before, .accordion summary .plus::after { content: ""; position: absolute; background: var(--accent); inset: 0; margin: auto; }
.accordion summary .plus::before { width: 100%; height: 2px; }
.accordion summary .plus::after { width: 2px; height: 100%; transition: transform .3s ease; }
.accordion details[open] summary .plus::after { transform: rotate(90deg); opacity: 0; }
.accordion .body { padding: 0 0 1.5rem; color: var(--muted); max-width: 70ch; }

/* embeds */
.embed-frame {
  width: 100%; border: 1px solid var(--line); border-radius: 18px; overflow: hidden;
  background: var(--paper);
}
.embed-frame iframe { display: block; width: 100%; border: 0; }
.ratio-video { aspect-ratio: 16 / 9; }
.ratio-map { height: 420px; }
.ratio-cal { height: 620px; }
.ratio-form { height: 760px; }

/* empty-state notice */
.notice {
  border: 1px dashed var(--line); border-radius: 18px; padding: clamp(1.6rem, 4vw, 2.6rem);
  background: var(--bone-2); color: var(--ink-soft);
}
.notice h3 { margin-bottom: 0.5rem; }
.notice code { background: rgba(21,19,14,.07); padding: 0.15em 0.45em; border-radius: 6px; font-size: 0.9em; }

/* page header (interior pages) */
.page-head { background: var(--ink); color: var(--on-dark); padding-block: clamp(3.5rem, 8vw, 6rem); }
.page-head .eyebrow { color: #d2a261; }
.page-head h1 { font-size: clamp(2.4rem, 6vw, 4.4rem); margin-top: 0.8rem; }
.page-head p { color: var(--on-dark-muted); max-width: 52ch; margin-top: 1.1rem; font-size: 1.15rem; }

/* prose */
.prose { max-width: 68ch; }
.prose > * + * { margin-top: 1.3rem; }
.prose h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); margin-top: 2.6rem; }
.prose p, .prose li { color: var(--ink-soft); }
.prose a { color: var(--accent-dk); text-underline-offset: 3px; }
.pullquote {
  font-family: var(--font-display); font-size: clamp(1.3rem, 2.6vw, 1.9rem); line-height: 1.3;
  border-left: 2px solid var(--accent); padding-left: 1.4rem; color: var(--ink); font-style: italic;
}

/* band CTA */
.band { text-align: center; }
.band h2 { font-size: clamp(2rem, 5vw, 3.6rem); max-width: 18ch; margin-inline: auto; }
.band .hero-actions { justify-content: center; }

/* =============================================================
   FOOTER
   ============================================================= */
.site-footer { background: var(--ink); color: var(--on-dark); padding-block: clamp(3.5rem, 7vw, 5rem) 2rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2.5rem; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; gap: 2rem; } }
.footer-brand { display: flex; align-items: center; gap: 0.7rem; margin-bottom: 1.1rem; }
.footer-brand .brand-name { color: var(--on-dark); }
.footer-brand .brand-name small { color: var(--on-dark-muted); }
.site-footer p, .site-footer a { color: var(--on-dark-muted); text-decoration: none; font-size: 0.95rem; }
.site-footer a:hover { color: var(--on-dark); }
.footer-col h4 { font-family: var(--font-body); font-size: 0.72rem; letter-spacing: 0.2em; text-transform: uppercase; color: #d2a261; margin-bottom: 1rem; font-weight: 600; }
.footer-col ul { list-style: none; padding: 0; display: grid; gap: 0.6rem; }
.footer-bottom {
  margin-top: 3rem; padding-top: 1.6rem; border-top: 1px solid var(--line-dark);
  display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; font-size: 0.85rem;
}

/* =============================================================
   REVEAL ANIMATION
   ============================================================= */
@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
  .reveal.in { opacity: 1; transform: none; }
}
