/* Messiah | ATHRTY Layout System v3
   Component gutters, editorial type, responsive grids and safe interactive targets.
   Loaded after the main design system. */

/* Shared, intentional spacing primitives */
:root {
  --page-gutter: clamp(16px, 3.2vw, 48px);
  --section-space: clamp(62px, 7vw, 110px);
  --content-gap: clamp(22px, 3.6vw, 58px);
  --card-gap: clamp(12px, 1.5vw, 20px);
}
html, body { max-width: 100%; }
body { overflow-x: clip; }
.container { width: min(1260px, calc(100% - 2 * var(--page-gutter))); }
#main { min-width: 0; }
.section { padding-block: var(--section-space); }
.section.tight { padding-block: clamp(42px, 5vw, 75px); }
.section-header { gap: var(--content-gap); }
.section-header > *, .hero-grid > *, .photo-split > *,
.page-hero .container > *, .cta-band > *, .newsletter-inner > *,
.location-panel > *, .edu-detail > *, .footer .cols > *,
.two-col > *, .three-col > *, .card-grid > *, .ministry-grid > *,
.info-grid > * { min-width: 0; }
h1, h2, h3 { text-wrap: balance; }
p { overflow-wrap: break-word; text-wrap: pretty; }
h2 { font-size: clamp(2.25rem, 4.2vw, 4.25rem); }
.section-header h2 { max-width: 760px; }
.btn { min-height: 45px; line-height: 1.2; text-align: center; }
.btn, .nav-link, .footer a, .text-link { -webkit-tap-highlight-color: transparent; }
.card-grid, .info-grid, .ministry-grid, .three-col { gap: var(--card-gap); }
.two-col { gap: var(--card-gap); }
.feature-card, .info-card, .ministry-card, .panel { overflow-wrap: anywhere; }

/* Home hero: heading can never overrun its column. */
.hero { padding-block: clamp(12px, 2.5vw, 34px) clamp(16px, 2.5vw, 34px); }
.hero-grid {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.02fr);
  gap: clamp(12px, 1.25vw, 18px);
  min-height: 570px;
}
.hero-copy {
  container-type: inline-size;
  padding: clamp(30px, 3.3vw, 56px);
}
.hero-copy h1 {
  font-size: clamp(2.8rem, 5.05vw, 4.9rem);
  line-height: 1.06;
  letter-spacing: -.055em;
  max-width: 100%;
  margin: clamp(14px, 2vw, 25px) 0 clamp(17px, 2vw, 27px);
}
@supports (font-size: 1cqi) {
  .hero-copy h1 { font-size: clamp(2.7rem, 13.3cqi, 4.7rem); }
}
.hero-copy p { max-width: 43ch; font-size: clamp(.96rem, 1.1vw, 1.06rem); }
.hero-buttons { gap: 10px; margin-top: clamp(14px, 2vw, 24px); }
.hero-note { margin-top: clamp(25px, 3.3vw, 42px); }
.hero-art { min-height: 500px; }

/* Reusable content: maintain paragraph/CTA rhythm. */
.photo-split { gap: clamp(14px, 1.4vw, 20px); }
.copy-panel { padding: clamp(32px, 4.5vw, 64px); }
.copy-panel h2 { max-width: 12ch; }
.info-card .content { padding: clamp(22px, 2.3vw, 29px); }
.info-card .content h3 { line-height: 1.22; }
.feature-card { padding: clamp(26px, 2.9vw, 36px); }
.feature-card h3 { line-height: 1.18; }
.education { padding: clamp(27px, 4.5vw, 64px); }
.ministry-card { padding: clamp(23px, 2.5vw, 30px); }
.worship-ribbon {
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr) minmax(0, 1fr) auto;
  gap: clamp(12px, 2vw, 25px);
  padding: clamp(20px, 2.2vw, 29px);
}
.worship-ribbon .btn { justify-self: end; }

/* Newsletter: primary fix for the flush-left type and floating button. */
.newsletter {
  padding: 0;
  isolation: isolate;
  border-radius: clamp(21px, 2.2vw, 32px);
  overflow: hidden;
  min-width: 0;
}
.newsletter::after {
  position: absolute;
  z-index: -1;
  right: -3%;
  bottom: -30%;
  line-height: 1;
  font-size: clamp(13rem, 23vw, 25rem);
  opacity: .075;
  pointer-events: none;
}
.newsletter-inner {
  width: 100%;
  padding: clamp(35px, 5.2vw, 76px);
  min-height: clamp(340px, 32vw, 425px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(28px, 5vw, 80px);
  position: relative;
  z-index: 1;
}
.newsletter-content { max-width: 870px; }
.newsletter h2 {
  max-width: 18ch;
  margin: 15px 0 20px;
  font-size: clamp(2.65rem, 4.4vw, 4.9rem);
  line-height: 1.1;
  letter-spacing: -.052em;
  text-wrap: balance;
}
.newsletter p { max-width: 54ch; margin-bottom: 0; font-size: clamp(.93rem, 1.07vw, 1.05rem); line-height: 1.7; }
.newsletter-action { align-self: center; justify-self: end; flex-shrink: 0; }
.newsletter-action .btn { min-width: 176px; box-shadow: 0 12px 30px rgba(21,24,26,.07); }
.newsletter .eyebrow { margin-left: 0; }

/* Other conversion blocks */
.cta-band { padding: clamp(38px, 5vw, 76px); }
.cta-band h2 { max-width: 13ch; }
.cta-band > .btn { flex-shrink: 0; }
.page-hero { padding-block: clamp(52px, 6vw, 80px) clamp(38px, 5vw, 60px); }
.page-hero .container { gap: clamp(20px, 4vw, 60px); }
.page-hero h1 {
  font-size: clamp(3rem, 5.55vw, 5.7rem);
  line-height: 1.07;
  max-width: 100%;
}
.page-hero p { max-width: 57ch; }
.page-hero .aside { min-width: 0; }
.location-panel { gap: var(--content-gap); }
.form .btn { justify-self: start; }
.footer .cols { gap: clamp(25px, 3vw, 46px); }

/* Small laptop: protect the narrow header and four-column ribbon. */
@media (max-width: 1130px) {
  .nav-row { gap: 12px; }
  .nav-links { gap: 2px; }
  .nav-link { padding-inline: 8px; }
  .hero-grid { min-height: 520px; }
  .hero-copy { padding: clamp(28px, 3vw, 40px); }
  .hero-art { min-height: 470px; }
  .worship-ribbon { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .worship-ribbon .ribbon-label { grid-column: 1 / -1; }
  .worship-ribbon > .btn { grid-column: 1 / -1; justify-self: stretch; }
  .newsletter-inner { grid-template-columns: minmax(0, 1fr) auto; gap: 25px; }
  .newsletter h2 { font-size: clamp(2.5rem, 4.2vw, 4rem); }
}
@media (max-width: 900px) {
  .nav-links, .nav-actions { display: none; }
  .site-header { --mobile-menu-offset: 82px; }
  .mobile-panel { display: block; position: fixed; top: var(--mobile-menu-offset); left: 0; right: 0; bottom: 0; z-index: 49; overflow: auto; padding: 26px var(--page-gutter); background: var(--cream); box-shadow: 0 20px 50px rgba(11,13,12,.08); }
  .mobile-panel[hidden] { display: none; }
  .mobile-panel nav { display: flex; flex-direction: column; gap: 6px; }
  .mobile-panel nav a { font: 500 2rem Fraunces,Fraunces,serif; border-bottom: 1px solid var(--outline); padding: 11px 4px; }
  .mobile-panel > .btn { width: 100%; margin-top: 24px; }
  .mobile-trigger { display: inline-block; margin-left: auto; }
  .hero-grid { grid-template-columns: 1fr; min-height: 0; }
  .hero-copy { min-height: 490px; padding: clamp(32px, 6vw, 55px); }
  .hero-copy h1 { font-size: clamp(3.2rem, 8vw, 5.2rem); }
  @supports (font-size: 1cqi) {
    .hero-copy h1 { font-size: clamp(3.1rem, 11.6cqi, 5.4rem); }
  }
  .hero-art { min-height: 410px; }
  .newsletter-inner { grid-template-columns: minmax(0, 1fr); align-items: start; min-height: 0; }
  .newsletter-action { justify-self: start; }
  .newsletter h2 { max-width: 20ch; font-size: clamp(2.65rem, 6.3vw, 4.1rem); }
  .newsletter p { max-width: 60ch; }
  .section-header { align-items: start; }
  .page-hero .container { grid-template-columns: 1fr; }
  .page-hero .aside { min-height: 140px; }
}
@media (max-width: 800px) {
  .site-header { --mobile-menu-offset: 72px; }
  .section-header { display: block; }
  .section-header p { margin-top: 16px; }
  .card-grid, .info-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .photo-split, .faq-wrap { grid-template-columns: 1fr; }
  .cta-band { flex-direction: column; align-items: flex-start; }
  .faq-wrap { gap: 25px; }
}
@media (max-width: 600px) {
  :root { --page-gutter: 16px; }
  .hero-copy {
    min-height: 0;
    padding: clamp(26px, 7.1vw, 38px);
    border-radius: 22px;
  }
  .hero-copy h1 { font-size: clamp(2.5rem, 10vw, 4.5rem); line-height: 1.075; }
  @supports (font-size: 1cqi) {
    .hero-copy h1 { font-size: clamp(2.45rem, 12.7cqi, 4.35rem); }
  }
  .hero-copy p { font-size: .95rem; }
  .hero-buttons { flex-direction: column; align-items: stretch; }
  .hero-buttons .btn { width: 100%; }
  .hero-art { min-height: 315px; }
  .worship-ribbon { grid-template-columns: 1fr; }
  .worship-ribbon .ribbon-label, .worship-ribbon > .btn { grid-column: auto; }
  .card-grid, .info-grid, .three-col, .ministry-grid, .two-col, .form-grid { grid-template-columns: 1fr; }
  .card-grid .feature-card:last-child { grid-column: auto; }
  .newsletter-inner { padding: clamp(29px, 7.5vw, 42px); gap: 26px; }
  .newsletter h2 {
    font-size: clamp(2.22rem, 9.2vw, 3.4rem);
    line-height: 1.12;
    margin-block: 15px 18px;
  }
  .newsletter h2 br { display: none; }
  .newsletter-action, .newsletter-action .btn { justify-self: stretch; width: 100%; }
  .newsletter::after { right: -14%; bottom: -18%; }
  .cta-band { padding: 36px 28px; }
  .cta-band > .btn { width: 100%; }
  .copy-panel { padding: 32px 26px; }
  .photo-panel { min-height: 300px; }
  .page-hero h1 { font-size: clamp(2.75rem, 10vw, 4rem); }
  .page-hero .aside { padding: 25px; }
  .footer .cols { grid-template-columns: 1fr; gap: 30px; }
}
@media (max-width: 360px) {
  .hero-copy { padding-inline: 24px; }
  .hero-copy h1 { letter-spacing: -.065em; font-size: 2.42rem; }
  .newsletter-inner { padding-inline: 24px; }
  .newsletter h2 { font-size: 2.15rem; }
  .brand-name { font-size: 1.05rem; }
  .brand-sub { font-size: .5rem; }
}

/* ATHRTY brand-adaptive contrast: preserve terracotta as an accent, deepen textual variants. */
.hero-copy .eyebrow,.section-header .eyebrow,.info-card .eyebrow,.faq-wrap .eyebrow{color:#115e59}
.photo-split p,.section-header p,.info-card p{color:#26292c}
.hero-art{background:#15181a}
.newsletter{background:#0f766e}
.newsletter .eyebrow,.newsletter p{color:#ccfbf1}

/* Restore inverse foreground in deep evergreen story panel. */
.photo-split .copy-panel p{color:#f4f2ec!important}
.info-card.peach p,.feature-card.peach p{color:#232629!important}