/* Christ Reformed Baptist Church — New Castle, IN */
:root {
  --blue: #3f86c6;
  --blue-dark: #1f5a8f;
  --navy: #17324f;
  --ink: #23272d;
  --muted: #5a6270;
  --cream: #f7f3ec;
  --sand: #ece4d6;
  --gold: #a8742c;
  --line: #e2ddd3;
  --white: #fff;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --wrap: 1120px;
  --radius: 10px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; font-family: var(--sans); font-size: 1.0625rem; line-height: 1.7; color: var(--ink); background: var(--white); overflow-x: hidden; }
img, video, iframe { max-width: 100%; display: block; }
img { height: auto; }
a { color: var(--blue-dark); text-underline-offset: 2px; }
a:hover { color: var(--navy); }
h1, h2, h3, h4 { font-family: var(--serif); color: var(--navy); line-height: 1.2; font-weight: 600; margin: 0 0 .6em; }
h1 { font-size: clamp(2rem, 5.5vw, 3.25rem); }
h2 { font-size: clamp(1.6rem, 3.6vw, 2.25rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 1.1em; }
ul, ol { padding-left: 1.3em; margin: 0 0 1.2em; }
li { margin-bottom: .35em; }
blockquote { margin: 1.5em 0; padding: 1em 1.4em; border-left: 4px solid var(--blue); background: var(--cream); font-family: var(--serif); font-size: 1.12rem; border-radius: 0 var(--radius) var(--radius) 0; }
blockquote cite { display: block; margin-top: .5em; font-family: var(--sans); font-size: .9rem; font-style: normal; color: var(--muted); }
.wrap { width: min(100% - 2.5rem, var(--wrap)); margin-inline: auto; }
.narrow { width: min(100% - 2.5rem, 760px); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 0; background: var(--navy); color: #fff; padding: .6em 1em; z-index: 100; }
.skip:focus { left: 1rem; top: 1rem; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

/* Header */
.site-header { background: var(--white); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 76px; }
.brand { display: flex; align-items: center; gap: .75rem; text-decoration: none; color: var(--navy); }
.brand img { width: 54px; height: auto; flex: none; }
.brand-name { font-family: var(--serif); font-size: 1.12rem; font-weight: 600; line-height: 1.15; display: block; }
.brand-name .small { display: block; font-size: .78em; letter-spacing: .06em; text-transform: uppercase; color: var(--blue-dark); }
.brand-tag { display: block; font-size: .8rem; color: var(--muted); margin-top: 2px; }
.menu-toggle { display: inline-flex; align-items: center; gap: .5rem; background: none; border: 1px solid var(--line); border-radius: 8px; padding: .55rem .8rem; font: inherit; font-size: .95rem; color: var(--navy); cursor: pointer; min-height: 44px; }
.menu-toggle svg { width: 20px; height: 20px; }
.nav { display: none; }
.nav.open { display: block; position: absolute; left: 0; right: 0; top: 100%; background: var(--white); border-bottom: 1px solid var(--line); box-shadow: 0 12px 24px rgba(23, 50, 79, .08); max-height: calc(100vh - 76px); overflow-y: auto; }
.nav ul { list-style: none; margin: 0; padding: 0; }
.nav > ul { padding: .5rem 1.25rem 1rem; }
.nav li { margin: 0; }
.nav a { display: block; padding: .6rem .25rem; text-decoration: none; color: var(--navy); font-weight: 500; border-bottom: 1px solid var(--line); }
.nav a[aria-current="page"] { color: var(--blue-dark); font-weight: 700; }
.nav .sub a { padding-left: 1.25rem; font-weight: 400; font-size: .97rem; }
.nav .group-label { display: block; padding: .6rem .25rem; font-weight: 500; color: var(--navy); border-bottom: 1px solid var(--line); }
@media (min-width: 1000px) {
  .menu-toggle { display: none; }
  .nav, .nav.open { display: block; position: static; box-shadow: none; border: 0; max-height: none; overflow: visible; }
  .nav > ul { display: flex; gap: .15rem; padding: 0; }
  .nav > ul > li { position: relative; }
  .nav a, .nav .group-label { border: 0; padding: .5rem .7rem; font-size: .95rem; border-radius: 6px; cursor: pointer; }
  .nav > ul > li > a:hover, .nav .group-label:hover { background: var(--cream); }
  .nav .group-label::after { content: ""; display: inline-block; width: .4em; height: .4em; margin-left: .45em; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-.2em) rotate(45deg); }
  .nav .sub { display: none; position: absolute; top: 100%; left: 0; min-width: 220px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 14px 30px rgba(23, 50, 79, .12); padding: .4rem; }
  .nav li:hover > .sub, .nav li:focus-within > .sub { display: block; }
  .nav .sub a { padding: .5rem .75rem; font-size: .95rem; }
  .nav .sub a:hover { background: var(--cream); }
}

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .45rem; padding: .8rem 1.4rem; border-radius: 999px; background: var(--blue-dark); color: var(--white); text-decoration: none; font-weight: 600; border: 2px solid var(--blue-dark); min-height: 48px; line-height: 1.2; font-size: 1rem; cursor: pointer; font-family: var(--sans); }
.btn:hover { background: var(--navy); border-color: var(--navy); color: var(--white); }
.btn.light { background: var(--white); color: var(--navy); border-color: var(--white); }
.btn.light:hover { background: var(--cream); border-color: var(--cream); color: var(--navy); }
.btn.ghost { background: transparent; color: var(--white); border-color: rgba(255, 255, 255, .85); }
.btn.ghost:hover { background: rgba(255, 255, 255, .15); }
.btn.outline { background: transparent; color: var(--blue-dark); }
.btn.outline:hover { background: var(--blue-dark); color: var(--white); }
.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; }

/* Hero */
.hero { position: relative; color: var(--white); background: var(--navy); overflow: hidden; }
.hero img.bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(15, 30, 48, .55) 0%, rgba(15, 30, 48, .35) 45%, rgba(15, 30, 48, .75) 100%); }
.hero .wrap { position: relative; z-index: 1; padding: clamp(4.5rem, 14vw, 9rem) 0 clamp(3.5rem, 10vw, 7rem); text-align: center; }
.hero h1 { color: var(--white); margin-bottom: .3em; text-shadow: 0 2px 18px rgba(0, 0, 0, .35); }
.hero h1 .christ { display: block; font-size: .62em; letter-spacing: .32em; text-transform: uppercase; font-weight: 500; margin-bottom: .25em; }
.hero p.lead { font-size: clamp(1.05rem, 2.4vw, 1.3rem); max-width: 40rem; margin: 0 auto 1.8rem; text-shadow: 0 1px 10px rgba(0, 0, 0, .4); }
.hero .btn-row { justify-content: center; }
.hero .rule { width: min(70%, 560px); height: 1px; background: rgba(255, 255, 255, .7); margin: 0 auto 2rem; border: 0; }

.page-hero { position: relative; background: var(--navy); color: var(--white); overflow: hidden; }
.page-hero img.bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.page-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(15, 30, 48, .82), rgba(15, 30, 48, .45)); }
.page-hero .wrap { position: relative; z-index: 1; padding: clamp(3rem, 9vw, 5.5rem) 0; }
.page-hero h1 { color: var(--white); margin: 0; }
.page-hero p { margin: .6rem 0 0; max-width: 40rem; font-size: 1.1rem; }
.page-hero.plain { background: var(--cream); color: var(--ink); }
.page-hero.plain::after { display: none; }
.page-hero.plain h1 { color: var(--navy); }
.eyebrow { display: block; font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; font-weight: 700; color: var(--gold); margin-bottom: .6rem; }
.page-hero .eyebrow, .hero .eyebrow { color: #f1d9ad; }
.page-hero.plain .eyebrow { color: var(--gold); }

/* Sections */
.section { padding: clamp(3rem, 8vw, 5.5rem) 0; }
.section.tint { background: var(--cream); }
.section.navy { background: var(--navy); color: #e8eef5; }
.section.navy h2, .section.navy h3 { color: var(--white); }
.section.navy a:not(.btn) { color: #cfe3f6; }
.section-head { max-width: 46rem; margin-bottom: 2.2rem; }
.section-head.center { margin-inline: auto; text-align: center; }
.split { display: grid; gap: 2.5rem; align-items: center; }
@media (min-width: 860px) { .split { grid-template-columns: 1.05fr .95fr; gap: 4rem; } .split.flip > :first-child { order: 2; } }
.photo { border-radius: var(--radius); overflow: hidden; box-shadow: 0 18px 40px rgba(23, 50, 79, .15); }
.photo img { width: 100%; }
.cards { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); }
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; display: flex; flex-direction: column; }
.card h3 { margin-bottom: .4em; }
.card p:last-child { margin-bottom: 0; }
.card .more { margin-top: auto; padding-top: .6rem; font-weight: 600; }
.card.link { text-decoration: none; color: inherit; transition: box-shadow .2s, transform .2s; }
.card.link:hover { box-shadow: 0 12px 28px rgba(23, 50, 79, .12); transform: translateY(-2px); color: inherit; }
@media (prefers-reduced-motion: reduce) { .card.link, .card.link:hover { transition: none; transform: none; } }
.card .icon { width: 44px; height: 44px; border-radius: 50%; background: var(--cream); color: var(--blue-dark); display: grid; place-items: center; margin-bottom: .9rem; }
.card .icon svg { width: 22px; height: 22px; }
.values { list-style: none; padding: 0; display: grid; gap: .7rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.values li { background: var(--white); border-left: 4px solid var(--blue); padding: .8rem 1rem; border-radius: 0 8px 8px 0; margin: 0; font-weight: 500; }
.tint .values li { background: var(--white); }
.gallery { display: grid; gap: .75rem; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 760px) { .gallery { grid-template-columns: repeat(4, 1fr); } }
.gallery figure { margin: 0; border-radius: 8px; overflow: hidden; aspect-ratio: 4 / 3; background: var(--sand); }
.gallery img { width: 100%; height: 100%; object-fit: cover; }
.prose h2 { margin-top: 1.6em; }
.prose h2:first-child, .prose h3:first-child { margin-top: 0; }
.prose h3 { margin-top: 1.4em; }
.prose img { border-radius: 8px; margin: 1.5em 0; }
.order { list-style: none; padding: 0; counter-reset: o; }
.order li { position: relative; padding: .55rem 0 .55rem 2.6rem; border-bottom: 1px dashed var(--line); margin: 0; }
.order li::before { counter-increment: o; content: counter(o); position: absolute; left: 0; top: .55rem; width: 1.8rem; height: 1.8rem; border-radius: 50%; background: var(--cream); color: var(--blue-dark); font-weight: 700; font-size: .85rem; display: grid; place-items: center; }
.order li.note { padding-left: 2.6rem; color: var(--muted); font-style: italic; }
.order li.note::before { content: ""; background: none; counter-increment: none; }
.beliefs { counter-reset: b; list-style: none; padding: 0; }
.beliefs li { position: relative; padding: .7rem 0 .7rem 3rem; border-bottom: 1px solid var(--line); margin: 0; }
.beliefs li::before { counter-increment: b; content: counter(b); position: absolute; left: 0; top: .75rem; font-family: var(--serif); font-size: 1.35rem; font-weight: 600; color: var(--blue); width: 2.2rem; text-align: right; }
.resource { display: grid; grid-template-columns: 90px 1fr; gap: 1.1rem; align-items: center; }
.resource img { width: 90px; border-radius: 4px; box-shadow: 0 6px 16px rgba(0, 0, 0, .15); }
.embed { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: #000; }
.embed iframe, .embed video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.embed.tall { aspect-ratio: auto; height: 640px; background: var(--white); border: 1px solid var(--line); }
.embed.map { aspect-ratio: 4 / 3; background: var(--sand); }
@media (min-width: 760px) { .embed.map { aspect-ratio: 16 / 10; } }
.video-card video { width: 100%; border-radius: var(--radius); background: #000; }
.video-card figcaption { margin-top: .6rem; font-weight: 600; color: var(--navy); }
.event { border-left: 3px solid var(--blue); padding: .2rem 0 .2rem 1.2rem; margin-bottom: 2rem; }
.event .date { font-size: .82rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--gold); }
.event h3 { margin: .2rem 0 .5rem; }
.event p { margin-bottom: .4em; }
details.archive { border: 1px solid var(--line); border-radius: var(--radius); padding: 0 1.25rem; background: var(--white); margin-bottom: 1rem; }
details.archive summary { cursor: pointer; padding: 1rem 0; font-weight: 600; color: var(--navy); font-family: var(--serif); font-size: 1.15rem; min-height: 44px; }
details.archive[open] summary { border-bottom: 1px solid var(--line); margin-bottom: 1.2rem; }
.class-list { list-style: none; padding: 0; columns: 2 260px; column-gap: 2rem; }
.class-list li { break-inside: avoid; padding: .35rem 0; border-bottom: 1px solid var(--line); margin: 0; }
.class-list a { font-weight: 600; }
.badge { display: inline-block; font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; background: var(--blue-dark); color: var(--white); border-radius: 4px; padding: .1rem .45rem; margin-left: .35rem; vertical-align: middle; }
.posts { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); }
.post-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; text-decoration: none; color: inherit; display: flex; flex-direction: column; }
.post-card:hover { box-shadow: 0 12px 28px rgba(23, 50, 79, .12); color: inherit; }
.post-card .thumb { aspect-ratio: 16 / 9; background: var(--cream); display: grid; place-items: center; overflow: hidden; }
.post-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.post-card .thumb img.mark { width: 64px; height: auto; object-fit: contain; opacity: .55; }
.post-card .body { padding: 1.1rem 1.25rem 1.3rem; }
.post-card time { font-size: .85rem; color: var(--muted); }
.post-card h3 { font-size: 1.15rem; margin: .25rem 0 .4rem; }
.post-card p { font-size: .95rem; color: var(--muted); margin: 0; }
.post-meta { color: #e2e9f1; }
.post-body { white-space: normal; }
.post-body .line { margin: 0 0 .5em; }
.post-images { display: grid; gap: .75rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); margin: 1.5rem 0; }
.post-images img { border-radius: 8px; width: 100%; margin: 0; }
.post-nav { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 1.5rem; margin-top: 2.5rem; }

/* Forms */
.form { display: grid; gap: 1.1rem; }
.form .row { display: grid; gap: 1.1rem; }
@media (min-width: 640px) { .form .row { grid-template-columns: 1fr 1fr; } }
.form label, .form legend { display: block; font-weight: 600; color: var(--navy); margin-bottom: .35rem; font-size: .98rem; }
.form .req { color: #b42318; }
.form input[type=text], .form input[type=email], .form input[type=tel], .form textarea { width: 100%; font: inherit; font-size: 1rem; padding: .75rem .9rem; border: 1px solid #c9c3b8; border-radius: 8px; background: var(--white); color: var(--ink); min-height: 48px; }
.form textarea { min-height: 140px; resize: vertical; }
.form input:focus, .form textarea:focus { outline: 3px solid rgba(63, 134, 198, .35); border-color: var(--blue); }
.form fieldset { border: 0; padding: 0; margin: 0; }
.form .choice { display: flex; align-items: center; gap: .6rem; padding: .3rem 0; font-weight: 400; color: var(--ink); min-height: 32px; margin: 0; }
.form .choice input { width: 20px; height: 20px; accent-color: var(--blue-dark); }
.form .q { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.1rem; }
.form-box { background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: clamp(1.25rem, 4vw, 2.25rem); box-shadow: 0 18px 40px rgba(23, 50, 79, .08); }
.hp-note { font-size: .9rem; color: var(--muted); }

/* Footer */
.site-footer { background: #10253b; color: #d3dde8; padding: 3.5rem 0 1.5rem; font-size: .97rem; }
.site-footer a { color: #fff; }
.site-footer h2 { font-family: var(--serif); color: #fff; font-size: 1.15rem; margin-bottom: .8rem; }
.footer-grid { display: grid; gap: 2rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); }
.footer-brand { display: flex; gap: .8rem; align-items: center; margin-bottom: 1rem; }
.footer-brand img { width: 52px; filter: brightness(0) invert(1); opacity: .9; }
.footer-brand span { font-family: var(--serif); color: #fff; font-size: 1.1rem; line-height: 1.25; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: .5rem; }
.site-footer p { margin-bottom: .7rem; }
.site-footer .fine { border-top: 1px solid rgba(255, 255, 255, .14); margin-top: 2.5rem; padding-top: 1.25rem; font-size: .88rem; color: #a9b8c8; display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; justify-content: space-between; padding-bottom: 1rem; }
.site-footer .fine a { color: #d3dde8; }
.footer-links a { text-decoration: none; display: inline-block; padding: .15rem 0; }
.footer-links a:hover { text-decoration: underline; }

.center { text-align: center; }
.mt { margin-top: 2rem; }
.muted { color: var(--muted); }
/* Small screens */
.prose, .post-body, .event, .card { overflow-wrap: anywhere; }
.brand { min-width: 0; }
@media (max-width: 480px) {
  .brand img { width: 42px; }
  .brand-name { font-size: 1rem; }
  .brand-tag { display: none; }
  .menu-toggle { padding: .5rem .65rem; }
}
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); border: 0; }
