/* Shared shell for all non-homepage pages: same design DNA as the
   homepage (Royal Bronze canvas, gold accents, flat heavy type, mono
   technical labels, floating card images, scroll reveals) with a unique
   layout per page type: blog index, article, ministry page. */

:root {
  /* Royal Bronze canvas: a matte gold base with an ambient warm wash
     layered on the body below. --site-bg stays a solid color so panels
     and overlays that reference it fill cleanly. */
  --site-bg: #191308;
  --site-text: #f4f2ec;
  --site-text-muted: rgba(244, 242, 236, 0.66);
  --site-gold: #d4af37;
  --site-gold-bright: #f3d371;
  --site-gold-soft: rgba(212, 175, 55, 0.4);
  --site-rule: rgba(244, 242, 236, 0.14);
  --font-sans: system-ui, -apple-system, 'Segoe UI', 'Helvetica Neue', sans-serif;
  --font-mono: ui-monospace, 'SF Mono', 'Menlo', 'Consolas', monospace;
  --site-inline: 1.5rem;
}

body.site-shell {
  margin: 0;
  font-family: var(--font-sans);
  /* Solid base. The ambient gold wash rides the fixed .gold-drift layer
     instead of background-attachment:fixed, which iOS Safari handles
     poorly and which can drop frames on long pages. */
  background: var(--site-bg);
  color: var(--site-text);
  overflow-x: hidden;
}
body.site-shell ::selection {
  background: var(--site-gold);
  color: #120d02;
}

/* ---------- Ambient gold wash (static on subpages) ---------- */

.gold-drift {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(120% 85% at 50% 0%, rgba(196, 152, 60, 0.2), transparent 60%),
    radial-gradient(85% 65% at 84% 38%, rgba(158, 116, 42, 0.13), transparent 66%),
    radial-gradient(95% 70% at 8% 94%, rgba(116, 78, 30, 0.15), transparent 68%);
}

/* ---------- Fixed chrome: crown mark + menu ---------- */

.corner-mark {
  position: fixed;
  top: 1.25rem;
  left: 1.5rem;
  z-index: 60;
  display: block;
  width: 34px;
  height: 34px;
}
.corner-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 0 10px rgba(212, 175, 55, 0.35));
}

.menu-toggle {
  position: fixed;
  top: 1.5rem;
  right: 1.5rem;
  z-index: 60;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  color: var(--site-text);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  display: grid;
}
.menu-toggle-line {
  grid-area: 1 / 1;
  transition: opacity 0.25s ease, transform 0.25s ease;
}
.menu-toggle-close {
  opacity: 0;
  transform: translateY(-6px);
}
body.menu-open .menu-toggle-line:not(.menu-toggle-close) {
  opacity: 0;
  transform: translateY(6px);
}
body.menu-open .menu-toggle-close {
  opacity: 1;
  transform: translateY(0);
  color: var(--site-gold);
}

.site-menu {
  position: fixed;
  inset: 0;
  z-index: 55;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding-left: clamp(1.5rem, 10vw, 9rem);
  background: rgba(21, 16, 9, 0.97);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-12px);
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), visibility 0s linear 0.4s;
}
body.menu-open .site-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), visibility 0s linear 0s;
}
.site-menu-links {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.5em;
  counter-reset: menuitem;
}
.site-menu-links a {
  display: block;
  counter-increment: menuitem;
  color: var(--site-text);
  text-decoration: none;
  font-family: var(--font-sans);
  font-weight: 800;
  font-size: clamp(1.5rem, 4.6vw, 2.9rem);
  letter-spacing: -0.01em;
  text-transform: uppercase;
  line-height: 1.15;
  opacity: 0.5;
  transition: opacity 0.25s ease, color 0.25s ease, transform 0.25s ease;
  max-width: 84vw;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.site-menu-links a::before {
  content: counter(menuitem, decimal-leading-zero) '  ';
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: 0.5em;
  vertical-align: 0.5em;
  letter-spacing: 0.1em;
  color: var(--site-gold);
}
.site-menu-links a:hover {
  opacity: 1;
  color: var(--site-gold-bright);
  transform: translateX(0.35rem);
}
/* Sub-page entry: indented under its parent, smaller, arrow instead of a
   number (and excluded from the numbering). */
.site-menu-links a.menu-sub {
  counter-increment: none;
  margin: -0.2em 0 0.2em 2.2em;
  font-size: clamp(0.95rem, 2.6vw, 1.5rem);
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
}
.site-menu-links a.menu-sub::before {
  content: '\2192  ';
  font-size: 0.8em;
  vertical-align: 0.1em;
}

/* ---------- Reading progress bar (articles) ---------- */

.read-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 100%;
  z-index: 70;
  background: linear-gradient(90deg, var(--site-gold), var(--site-gold-bright));
  transform-origin: 0 50%;
  transform: scaleX(var(--progress, 0));
}

/* ---------- Full-width hero billboard ---------- */

.page-billboard {
  position: relative;
  z-index: 1;
  width: 100%;
  height: clamp(20rem, 58vh, 34rem);
  overflow: hidden;
}
.page-billboard img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 0;
  box-shadow: none;
}
.billboard-overlay {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 3.5rem var(--site-inline) 2.2rem;
  background: linear-gradient(0deg, rgba(18, 14, 8, 0.94), rgba(18, 14, 8, 0.38) 60%, transparent);
}
.billboard-overlay .kicker {
  margin-bottom: 0.8rem;
}
.billboard-overlay h1 {
  font-family: var(--font-sans);
  font-weight: 900;
  font-size: clamp(2.2rem, 6vw, 4.6rem);
  line-height: 0.96;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  margin: 0;
  color: var(--site-text);
  max-width: 68rem;
}
body.has-billboard .page-main {
  padding-top: clamp(2.5rem, 6vh, 4rem);
}
/* Plain billboard: the artwork carries its own title, so it shows at its
   natural aspect ratio, uncropped and with no text overlay. */
.page-billboard.billboard-plain {
  height: auto;
}
.page-billboard.billboard-plain img {
  height: auto;
  object-fit: unset;
}

/* ---------- Page scaffold ---------- */

.page-main {
  position: relative;
  z-index: 1;
  max-width: 100%;
  padding: clamp(6rem, 14vh, 9rem) var(--site-inline) 6rem;
}

.page-hero {
  max-width: 68rem;
  margin: 0 auto clamp(2.5rem, 7vh, 5rem);
}
.kicker {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--site-gold);
  margin: 0 0 1.1rem;
}
.page-hero h1 {
  font-family: var(--font-sans);
  font-weight: 900;
  font-size: clamp(2.4rem, 7vw, 5.5rem);
  line-height: 0.96;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  margin: 0;
  color: var(--site-text);
}

/* ---------- Shared content styling ---------- */

.page-main a {
  color: var(--site-gold);
  text-decoration: underline;
  text-decoration-color: var(--site-gold-soft);
  text-underline-offset: 3px;
}
.page-main a:hover {
  text-decoration-color: var(--site-gold);
}
.page-main p {
  font-size: 1.08rem;
  line-height: 1.85;
  color: var(--site-text-muted);
}
.page-main strong {
  color: var(--site-text);
}
.page-main h1:not(.page-hero h1),
.page-main h2,
.page-main h3,
.page-main h4 {
  font-family: var(--font-sans);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  line-height: 1.05;
  color: var(--site-text);
  margin: 2.6rem 0 1rem;
}
.page-main h1:not(.page-hero h1) { font-size: clamp(1.7rem, 3.6vw, 2.6rem); }
.page-main h2 { font-size: clamp(1.5rem, 3vw, 2.2rem); }
.page-main h3, .page-main h4 { font-size: clamp(1.15rem, 2.2vw, 1.5rem); }
.page-main h5, .page-main h6 {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--site-gold);
  margin: 2rem 0 0.8rem;
}
.page-main blockquote {
  margin: 2rem 0;
  padding: 1rem 0 1rem 1.4rem;
  border-left: 2px solid var(--site-gold);
  color: var(--site-text);
  font-family: Georgia, 'Times New Roman', serif;
  font-style: italic;
  font-size: 1.15rem;
}
.page-main blockquote p {
  color: inherit;
  margin: 0;
}

/* Floating card treatment for content images (same DNA as home). The glow
   and ring colors are themeable per sub-brand below. */
.page-main img {
  max-width: 100%;
  width: auto;
  height: auto;
  border-radius: 12px;
  box-shadow:
    0 30px 60px rgba(0, 0, 0, 0.6),
    0 0 34px var(--card-glow, transparent),
    0 0 0 1px var(--card-ring, rgba(212, 175, 55, 0.2));
}

/* ---------- Sub-brand themes (original pages' own palettes) ---------- */

/* Sisters of Christ: dusty rose + warm tan (original page's #8E5D5D /
   #D4A373 scheme, lifted to read on the dark canvas). */
.theme-sisters {
  --site-gold: #d4a373;
  --site-gold-bright: #eac9a0;
  --site-gold-soft: rgba(212, 163, 115, 0.4);
  --card-glow: rgba(142, 93, 93, 0.38);
  --card-ring: rgba(212, 163, 115, 0.42);
}

/* Shorties of Christ: the sky blue + green of the original logo art. */
.theme-shorties {
  --site-gold: #5faee8;
  --site-gold-bright: #8fd0ff;
  --site-gold-soft: rgba(95, 174, 232, 0.4);
  --card-glow: rgba(79, 163, 224, 0.32);
  --card-ring: rgba(124, 179, 66, 0.45);
}

/* ---------- Layout: blog index ---------- */

.layout-blog-index .post-index {
  max-width: 68rem;
  margin: 0 auto;
  border-top: 1px solid var(--site-rule);
}
.post-row {
  display: grid;
  grid-template-columns: 3.2rem minmax(15rem, 24rem) minmax(0, 1fr);
}
.post-row.no-thumb {
  grid-template-columns: 3.2rem minmax(0, 1fr);
}
.post-row {
  gap: 2rem;
  align-items: center;
  padding: 2.2rem 0.25rem;
  border-bottom: 1px solid var(--site-rule);
  text-decoration: none !important;
}
.post-row .post-num {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  color: var(--site-gold);
}
.post-row .post-thumb img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 15rem;
  object-fit: cover;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
.post-row:hover .post-thumb img {
  transform: scale(1.05);
}
.post-row .post-title {
  display: block;
  font-family: var(--font-sans);
  font-weight: 800;
  font-size: clamp(1.05rem, 2.4vw, 1.6rem);
  line-height: 1.15;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  color: var(--site-text);
  transition: color 0.25s ease;
}
.post-row:hover .post-title {
  color: var(--site-gold-bright);
}
.post-row .post-meta {
  display: block;
  margin-top: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--site-text-muted);
}
@media (max-width: 46rem) {
  .post-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
  }
  .post-row .post-num {
    display: none;
  }
}

/* ---------- Layout: article ---------- */

.layout-article .page-hero {
  max-width: 46rem;
}
.layout-article .article-body {
  max-width: 46rem;
  margin: 0 auto;
}
.layout-article .article-body img {
  display: block;
  margin: 2.2rem auto;
  max-height: 60vh;
}
.audio-chapters {
  margin-top: 3.5rem;
  border-top: 1px solid var(--site-rule);
  padding-top: 2rem;
}
.audio-chapters h2 {
  margin-top: 0;
}
.audio-row {
  display: grid;
  grid-template-columns: 7.5rem minmax(0, 1fr);
  gap: 1.2rem;
  align-items: center;
  margin-bottom: 1.1rem;
}
.audio-row .audio-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--site-gold);
}
.audio-row audio {
  width: 100%;
  accent-color: var(--site-gold);
}

/* ---------- Layout: ministry page ---------- */

.layout-ministry .ministry-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
  max-width: 74rem;
}
.layout-ministry .ministry-hero .hero-media img {
  display: block;
  width: auto;
  max-width: 100%;
  max-height: 52vh;
  margin: 0 auto;
}
@media (max-width: 46rem) {
  .layout-ministry .ministry-hero {
    grid-template-columns: 1fr;
  }
}
.layout-ministry .ministry-body {
  max-width: 48rem;
  margin: 0 auto;
}
.layout-ministry .ministry-body img {
  display: block;
  margin: 2.2rem auto;
  max-height: 68vh;
}

/* Side-by-side image runs from the source layout */
.ministry-body .img-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: flex-start;
  gap: 1.6rem;
  margin: 2.2rem 0;
}
.layout-ministry .ministry-body .img-row img {
  margin: 0;
  max-height: 58vh;
  max-width: min(84vw, 22rem);
}

/* Clickable poems: zoom affordance + full-size reading lightbox */
.img-row .poem-zoom {
  display: block;
  text-decoration: none !important;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
.img-row .poem-zoom:hover {
  transform: translateY(-6px) scale(1.02);
}
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 90;
  overflow-y: auto;
  display: flex;
  padding: 3.5rem 1rem;
  background: rgba(16, 12, 7, 0.94);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  cursor: zoom-out;
}
.lightbox img {
  display: block;
  margin: auto;
  width: min(92vw, 44rem);
  height: auto;
  border-radius: 12px;
  box-shadow: 0 40px 90px rgba(0, 0, 0, 0.8);
}
.lightbox-close {
  position: fixed;
  top: 1.4rem;
  right: 1.6rem;
  z-index: 91;
  background: none;
  border: none;
  padding: 0.4rem;
  color: var(--site-text);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  cursor: pointer;
}
body.lightbox-open {
  overflow: hidden;
}

/* Responsive video embeds (YouTube) */
.ministry-body .video-embed {
  position: relative;
  aspect-ratio: 16 / 9;
  margin: 2.2rem 0;
  border-radius: 12px;
  overflow: hidden;
  box-shadow:
    0 30px 60px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(212, 175, 55, 0.2);
}
.ministry-body .video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* ---------- Book Launch landing (stored .soc-muse design) ----------
   The page ships its own scoped styles; the shell only clears the
   generic content-image treatment so the design's borders and radii
   read as authored. */

.layout-launch .page-main {
  padding-left: 0;
  padding-right: 0;
  padding-top: clamp(5rem, 10vh, 7rem);
}
.page-main .soc-muse img {
  box-shadow: none;
  border-radius: 0;
}
.page-main .soc-muse a {
  text-decoration: none;
}
.page-main .soc-muse p {
  font-size: inherit;
  line-height: inherit;
  color: inherit;
}
/* The shell's generic heading/blockquote treatment out-ranks the page's
   scoped styles; restore the design's serif headings at higher
   specificity. */
.page-main .soc-muse h1.h1 {
  font-family: Cinzel, Georgia, serif;
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0.4px;
  line-height: 1;
  font-size: clamp(44px, 6vw, 76px);
  margin: 12px 0 10px;
  color: #fff;
}
.page-main .soc-muse h2.h2 {
  font-family: Cinzel, Georgia, serif;
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0.3px;
  line-height: 1.15;
  font-size: clamp(24px, 3vw, 40px);
  margin: 0 0 8px;
  color: #fff;
}
.page-main .soc-muse .poem-copy h3 {
  font-family: Cinzel, Georgia, serif;
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0.2px;
  line-height: 1.2;
  font-size: 22px;
  margin: 10px 0 8px;
  color: #fff;
}
.page-main .soc-muse .names h2 {
  font-family: Cinzel, Georgia, serif;
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0.3px;
  line-height: 1.15;
  font-size: clamp(26px, 3.2vw, 44px);
  margin: 0 0 10px;
  color: #fff;
}
.page-main .soc-muse h3.subhead {
  font-family: Cinzel, Georgia, serif;
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0.25px;
  line-height: 1.15;
  font-size: clamp(22px, 2.6vw, 34px);
  margin: 0 0 8px;
  color: #fff;
}
.page-main .soc-muse blockquote {
  border-left: none;
  padding: 0;
}

/* ---------- Rhythm and Poetry particle hero ----------
   Mirror of the homepage hero: mono gold kicker over the giant wordmark,
   with gold particles (three music notes, driven by site.js) behind. */

.rap-hero {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}
canvas.particle-scene {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
/* Scroll-scrubbed background timelapse: sits under the particles at low
   opacity; playback position is driven entirely by scroll (site.js). */
#rap-timelapse {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.18;
  pointer-events: none;
}
.rap-hero .hero-content {
  position: relative;
  padding: 0 var(--site-inline);
  will-change: transform;
}
.rap-hero h6 {
  font-family: var(--font-mono);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.45em;
  font-size: 0.75rem;
  color: var(--site-gold);
  margin: 0 0 1.5rem;
}
.rap-hero h1 {
  font-family: var(--font-sans);
  font-weight: 900;
  font-size: clamp(3.25rem, 12.5vw, 10rem);
  line-height: 0.92;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  margin: 0;
  color: var(--site-text);
}
.rap-hero h1.hero-title-long {
  font-size: clamp(2.5rem, 8.5vw, 7rem);
}

/* ---------- App store badges ----------
   Cinematic glass-and-gold buttons that replace the oversized text links
   the source used for app downloads. */

.app-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin: 1.8rem 0 0.5rem;
}
.page-main a.app-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.75rem 1.4rem 0.75rem 1.1rem;
  border-radius: 14px;
  text-decoration: none !important;
  color: var(--site-text);
  background: linear-gradient(150deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.03));
  border: 1px solid rgba(212, 175, 55, 0.35);
  box-shadow:
    0 16px 34px rgba(0, 0, 0, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  transform-style: preserve-3d;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.35s ease, border-color 0.35s ease;
  position: relative;
  overflow: hidden;
}
/* Sheen that sweeps across on hover. */
.page-main a.app-badge::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: -60%;
  width: 45%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.16), transparent);
  transform: skewX(-18deg);
  transition: left 0.55s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}
.page-main a.app-badge:hover::after {
  left: 120%;
}
.page-main a.app-badge:hover {
  transform: translateY(-3px) scale(1.02);
  border-color: rgba(212, 175, 55, 0.75);
  box-shadow:
    0 24px 48px rgba(0, 0, 0, 0.6),
    0 0 26px rgba(212, 175, 55, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.16);
}
.app-badge-icon {
  flex: 0 0 auto;
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
}
.app-badge-icon svg {
  width: 100%;
  height: 100%;
  display: block;
}
.app-badge-apple .app-badge-icon {
  color: var(--site-text);
}
.app-badge-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}
.app-badge-text small {
  font-family: var(--font-mono);
  font-size: 0.55rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--site-text-muted);
}
.app-badge-text b {
  font-size: 1.02rem;
  font-weight: 800;
  letter-spacing: -0.01em;
}
.app-badge-text em {
  font-style: normal;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--site-gold);
  margin-top: 0.15rem;
}

/* ---------- Resources: alternating 3D feature rows ---------- */

.layout-resources .ministry-body {
  max-width: 74rem;
}
.res-feature {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: clamp(1.8rem, 5vw, 4rem);
  align-items: center;
  margin: clamp(3rem, 9vh, 6rem) 0;
  perspective: 1200px;
}
.res-feature-right {
  direction: rtl;
}
.res-feature-right > * {
  direction: ltr;
}
@media (max-width: 56rem) {
  .res-feature,
  .res-feature-right {
    grid-template-columns: 1fr;
    direction: ltr;
    gap: 1.6rem;
  }
}
.res-media {
  position: relative;
}
.layout-resources .res-media img {
  display: block;
  width: 100%;
  height: auto;
  max-height: none;
  margin: 0;
  border-radius: 18px;
  transform: rotateY(var(--ry, 0deg)) rotateX(var(--rx, 0deg)) translateZ(0);
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.45s ease;
  box-shadow:
    0 34px 70px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(212, 175, 55, 0.22);
  will-change: transform;
}
.res-media:hover img {
  box-shadow:
    0 44px 90px rgba(0, 0, 0, 0.68),
    0 0 34px rgba(212, 175, 55, 0.26),
    0 0 0 1px rgba(212, 175, 55, 0.45);
}
.res-copy > h3 {
  margin-top: 0;
}
/* Feature bullet lists read as gold-ticked rows, not plain bullets. */
.res-copy ul {
  list-style: none;
  padding: 0;
  margin: 1.2rem 0 0;
  display: grid;
  gap: 0.6rem;
}
.res-copy ul li {
  position: relative;
  padding: 0.6rem 0.9rem 0.6rem 2.2rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(244, 242, 236, 0.09);
  color: var(--site-text-muted);
  font-size: 0.97rem;
  line-height: 1.6;
  transition: background 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}
.res-copy ul li:hover {
  background: rgba(212, 175, 55, 0.08);
  border-color: rgba(212, 175, 55, 0.35);
  transform: translateX(3px);
}
.res-copy ul li::before {
  content: '';
  position: absolute;
  left: 0.85rem;
  top: 1.05em;
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 999px;
  background: radial-gradient(circle, var(--site-gold-bright), var(--site-gold));
  box-shadow: 0 0 12px rgba(212, 175, 55, 0.55);
}

/* ---------- Noah's Ark matching game (Shorties kids page) ---------- */

.ark-game {
  position: relative;
  z-index: 1;
  margin: clamp(2rem, 6vh, 4rem) auto;
  max-width: 46rem;
  padding: clamp(1.4rem, 4vw, 2.4rem);
  border-radius: 26px;
  background: linear-gradient(160deg, rgba(95, 174, 232, 0.16), rgba(124, 179, 66, 0.12));
  border: 1px solid rgba(143, 208, 255, 0.35);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.5);
  text-align: center;
}
.ark-head h2 {
  font-family: var(--font-sans);
  font-weight: 900;
  text-transform: none;
  letter-spacing: -0.01em;
  font-size: clamp(1.6rem, 4.5vw, 2.5rem);
  margin: 0 0 0.5rem;
  color: #8fd0ff;
}
.ark-head p {
  margin: 0 auto 1.4rem;
  max-width: 34rem;
  color: var(--site-text);
  font-size: 1rem;
  line-height: 1.6;
}
.ark-head p strong {
  color: #b6e08a;
}
.ark-hud {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.8rem 1.4rem;
  margin-bottom: 1.4rem;
}
.ark-stat {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--site-text-muted);
}
.ark-stat b {
  color: #8fd0ff;
  font-size: 1.1rem;
}
.ark-reset,
.ark-again {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #0b1a24;
  background: linear-gradient(180deg, #8fd0ff, #5faee8);
  border: none;
  border-radius: 999px;
  padding: 0.7rem 1.5rem;
  cursor: pointer;
  transition: transform 0.2s ease, filter 0.2s ease;
}
.ark-reset:hover,
.ark-again:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
}
.ark-board {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(0.5rem, 2vw, 0.9rem);
}
@media (max-width: 30rem) {
  .ark-board {
    grid-template-columns: repeat(3, 1fr);
  }
}
.ark-card {
  position: relative;
  aspect-ratio: 3 / 4;
  padding: 0;
  border: none;
  background: none;
  cursor: pointer;
  perspective: 700px;
}
.ark-card-inner {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}
.ark-card.is-flipped .ark-card-inner,
.ark-card.is-matched .ark-card-inner {
  transform: rotateY(180deg);
}
.ark-face {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}
.ark-back {
  background:
    radial-gradient(circle at 50% 38%, rgba(255, 255, 255, 0.35), transparent 45%),
    linear-gradient(160deg, #5faee8, #3a7fb8);
  border: 2px solid rgba(255, 255, 255, 0.35);
  box-shadow: inset 0 0 0 4px rgba(255, 255, 255, 0.08);
}
.ark-back::after {
  content: '';
  width: 46%;
  height: 46%;
  background: url('/assets/brand/soc-icon-crown.png') center / contain no-repeat;
  opacity: 0.9;
  filter: brightness(0) invert(1);
}
.ark-front {
  transform: rotateY(180deg);
  font-size: clamp(2rem, 9vw, 3.2rem);
  background: linear-gradient(160deg, #ffffff, #eaf6ff);
  border: 2px solid rgba(143, 208, 255, 0.7);
  line-height: 1;
}
.ark-card.is-matched {
  animation: ark-pop 0.4s ease;
}
.ark-card.is-matched .ark-front {
  border-color: #7cb342;
  box-shadow: 0 0 0 3px rgba(124, 179, 66, 0.5), 0 0 22px rgba(124, 179, 66, 0.4);
}
@keyframes ark-pop {
  0% { transform: scale(1); }
  45% { transform: scale(1.09); }
  100% { transform: scale(1); }
}
.ark-win {
  margin-top: 1.6rem;
  position: relative;
  overflow: visible;
}
.ark-win-title {
  font-family: var(--font-sans);
  font-weight: 900;
  font-size: clamp(1.4rem, 4vw, 2rem);
  color: #b6e08a;
  margin: 0 0 0.4rem;
}
.ark-win-verse {
  color: var(--site-text);
  font-style: italic;
  margin: 0 0 1.2rem;
}
.ark-confetti {
  position: absolute;
  top: 0;
  width: 9px;
  height: 14px;
  border-radius: 2px;
  pointer-events: none;
  animation: ark-confetti-fall 1.5s cubic-bezier(0.2, 0.7, 0.3, 1) forwards;
}
@keyframes ark-confetti-fall {
  0% { transform: translate(0, 0) rotate(0); opacity: 1; }
  100% { transform: translate(var(--dx), var(--dy)) rotate(var(--rot)); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .ark-card-inner { transition: none; }
  .ark-card.is-matched { animation: none; }
}

/* Meet the SOC: the Hebrew scroll runs behind the We Serve / miracles
   sections at low opacity. The backdrop paints on ::before at z-index -1
   inside the wrapper's own stacking context, so content never dims. */
.scroll-backdrop {
  position: relative;
  z-index: 0;
  padding: clamp(1.5rem, 4vh, 3rem) clamp(1rem, 3vw, 2.5rem);
  border-radius: 18px;
  overflow: hidden;
}
.scroll-backdrop::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: url('/assets/Hebrew-Scroll-scaled.webp') center / cover no-repeat;
  opacity: 0.14;
  pointer-events: none;
}

/* Former hero image, re-homed below the particle hero at low opacity */
.hero-echo {
  position: relative;
  z-index: 1;
  margin: 0 calc(-1 * var(--site-inline)) clamp(2rem, 5vh, 3.5rem);
}
.hero-echo img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  opacity: 0.45;
  border-radius: 0;
  box-shadow: none;
}
html.js .rap-hero .hero-content > * {
  opacity: 0;
  transform: translateY(34px);
  animation: rap-hero-rise 0.9s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
html.js .rap-hero .hero-content > *:nth-child(1) { animation-delay: 0.15s; }
html.js .rap-hero .hero-content > *:nth-child(2) { animation-delay: 0.3s; }
@keyframes rap-hero-rise {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.rap-hero .hero-scroll-hint {
  position: absolute;
  bottom: 1.4rem;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--site-text-muted);
  animation: rap-hint-pulse 2.2s ease infinite;
}
@keyframes rap-hint-pulse {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 1; }
}
/* Hero already fills the first viewport; the content column starts tight
   beneath it. */
.layout-rap .page-main {
  padding-top: clamp(2.5rem, 6vh, 4rem);
}
@media (prefers-reduced-motion: reduce) {
  html.js .rap-hero .hero-content > * {
    animation: none;
    opacity: 1;
    transform: none;
  }
  .rap-hero .hero-scroll-hint {
    animation: none;
  }
}

/* ---------- Sisters of Christ bespoke layout ----------
   The original page's boxes and colors -- rose serif headings, white cards
   with tan top borders, scripture callouts, pill CTAs, cream closing
   panel -- rebuilt on the black canvas. */

.layout-sisters {
  --font-serif: Georgia, 'Palatino Linotype', 'Times New Roman', serif;
  --sis-rose: #8e5d5d;
  --sis-rose-lift: #c9908f;
  --sis-tan: #d4a373;
  --sis-cream: #f4ebe8;
  --sis-card-bg: #fdfbf7;
  --sis-ink: #2c2c2c;
  --sis-ink-soft: #464646;
}
.layout-sisters .page-main {
  max-width: 72rem;
  margin: 0 auto;
}
.sis-section {
  padding: clamp(2.6rem, 6vh, 4.5rem) 0;
  text-align: center;
}
.sis-section h2 {
  font-family: var(--font-serif);
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0.01em;
  font-size: clamp(1.9rem, 4.2vw, 3.1rem);
  line-height: 1.15;
  color: var(--sis-rose-lift);
  margin: 0 0 1.2rem;
}
.sis-section h2.sis-display {
  font-size: clamp(2.2rem, 5vw, 3.8rem);
}
.sis-section > p,
.sis-encounter-copy p {
  max-width: 46rem;
  margin-left: auto;
  margin-right: auto;
}
.sis-cta {
  margin-top: 2.2rem;
}
.page-main a.sis-btn {
  display: inline-block;
  padding: 0.95rem 2.6rem;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  text-decoration: none;
  transition: transform 0.25s ease, filter 0.25s ease;
}
.page-main a.sis-btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.06);
}
.page-main a.sis-btn-light {
  background: var(--sis-card-bg);
  color: var(--sis-ink);
}
.page-main a.sis-btn-rose {
  background: var(--sis-rose);
  color: var(--sis-card-bg);
}

/* Legacy of Valor: three white cards with tan top borders */
.sis-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.6rem;
  margin-top: 2.6rem;
  text-align: left;
}
@media (max-width: 56rem) {
  .sis-cards {
    grid-template-columns: 1fr;
    max-width: 28rem;
    margin-left: auto;
    margin-right: auto;
  }
}
.sis-card {
  background: var(--sis-card-bg);
  border-top: 4px solid var(--sis-tan);
  border-radius: 10px;
  padding: 2.1rem 1.7rem 1.8rem;
  box-shadow: 0 26px 52px rgba(0, 0, 0, 0.55);
}
.sis-card h3 {
  font-family: var(--font-serif);
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0;
  font-size: clamp(1.3rem, 2vw, 1.6rem);
  color: var(--sis-rose);
  margin: 0 0 0.9rem;
}
.sis-card p {
  color: var(--sis-ink-soft);
  font-size: 1rem;
  line-height: 1.7;
  margin: 0 0 1rem;
}
.sis-card strong {
  color: var(--sis-ink);
}
.sis-card p.sis-verse {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #90745d;
  margin: 1.5rem 0 0;
}
.sis-quote {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1.25rem, 2.6vw, 1.8rem);
  line-height: 1.5;
  color: var(--sis-rose-lift);
  max-width: 54rem;
  margin: 3rem auto 0;
}

/* The Jesus Encounter: prose beside scripture callouts */
.sis-encounter {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
  text-align: left;
}
@media (max-width: 56rem) {
  .sis-encounter {
    grid-template-columns: 1fr;
  }
}
.sis-encounter-copy h2 {
  text-align: left;
}
.sis-encounter-copy p {
  margin-left: 0;
}
.sis-callouts ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 1.7rem;
}
.sis-callouts li {
  border-left: 3px solid var(--sis-rose);
  padding-left: 1.25rem;
  color: var(--site-text-muted);
  font-size: 1.02rem;
  line-height: 1.7;
}
.sis-callouts li strong {
  display: block;
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: 1.3rem;
  color: var(--sis-rose-lift);
  margin-bottom: 0.3rem;
}
/* The source markdown breaks after each bold lead-in; the block-level
   strong already provides that break. */
.sis-callouts li br {
  display: none;
}

/* To the Woman Still Searching: elevated dark panel, tan heading */
.sis-searching {
  background: #161514;
  border: 1px solid rgba(212, 163, 115, 0.14);
  border-radius: 14px;
  padding: clamp(3rem, 7vh, 5rem) clamp(1.5rem, 5vw, 4rem);
  margin: clamp(2rem, 5vh, 3.5rem) 0;
}
.sis-searching h2 {
  color: var(--sis-tan);
}

/* Join the Mission: cream closing panel */
.sis-join {
  background: var(--sis-cream);
  border-radius: 14px;
  padding: clamp(3rem, 7vh, 5rem) clamp(1.5rem, 5vw, 4rem);
  margin: clamp(2rem, 5vh, 3.5rem) 0;
}
.sis-join h2 {
  color: var(--sis-rose);
}
.sis-join p {
  color: var(--sis-ink-soft);
}
.sis-join .sis-links {
  margin-top: 1.8rem;
  font-size: 0.95rem;
}
.layout-sisters .page-main .sis-join a:not(.sis-btn) {
  color: var(--sis-rose);
  text-decoration-color: rgba(142, 93, 93, 0.4);
}
.sis-join .sis-links span {
  color: var(--sis-ink-soft);
  padding: 0 0.4rem;
}

/* ---------- Floating 3D card stage (Meet Apostello) ----------
   Three overlapping cards hang tilted in perspective space; site.js
   drifts them with the cursor at different depths and adds a slow idle
   bob. Base pose lives in CSS custom properties so the composition
   stands on its own without JS or with reduced motion. */

.apo-stage {
  position: relative;
  height: clamp(26rem, 74vh, 42rem);
  margin: clamp(1rem, 4vh, 3rem) auto clamp(2rem, 6vh, 4rem);
  max-width: 76rem;
  perspective: 1400px;
}
.apo-card {
  position: absolute;
  top: 50%;
  left: 50%;
  border-radius: 14px;
  will-change: transform;
  transform: translate(-50%, -50%)
    translate3d(calc(var(--bx) + var(--px, 0px)), calc(var(--by) + var(--py, 0px)), var(--bz))
    rotateX(calc(var(--brx) + var(--tx, 0deg)))
    rotateY(calc(var(--bry) + var(--ty, 0deg)))
    rotateZ(var(--brz));
  box-shadow:
    0 40px 80px rgba(0, 0, 0, 0.65),
    0 0 34px var(--card-glow, rgba(212, 175, 55, 0.14)),
    0 0 0 1px var(--card-ring, rgba(212, 175, 55, 0.2));
}
.apo-card img {
  display: block;
  height: 100%;
  width: auto;
  border-radius: inherit;
  box-shadow: none;
}
/* Square portrait photo, back left */
.apo-card-1 {
  --bx: -24rem; --by: -3rem; --bz: -80px;
  --brx: 2deg; --bry: 14deg; --brz: -6deg;
  height: 21rem;
  z-index: 2;
}
/* Tall armor portrait, front center */
.apo-card-2 {
  --bx: 0rem; --by: 0rem; --bz: 40px;
  --brx: 0deg; --bry: -7deg; --brz: 2.5deg;
  height: 34rem;
  z-index: 3;
}
/* SOC logo, deep right */
.apo-card-3 {
  --bx: 22rem; --by: 4rem; --bz: -140px;
  --brx: -2deg; --bry: -16deg; --brz: 7deg;
  height: 16rem;
  z-index: 1;
}
@media (max-width: 64rem) {
  .apo-card-1 { --bx: -17rem; height: 15rem; }
  .apo-card-2 { height: 26rem; }
  .apo-card-3 { --bx: 15rem; height: 12rem; }
}
@media (max-width: 44rem) {
  .apo-stage {
    height: auto;
    perspective: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.6rem;
  }
  .apo-card {
    position: static;
    height: auto;
    max-width: 100%;
  }
  .apo-card-1, .apo-card-2, .apo-card-3 {
    transform: rotateZ(var(--brz));
  }
  .apo-card img {
    height: auto;
    max-width: min(78vw, 22rem);
  }
}

/* ---------- Site-wide contact closer (form + crown of thorns) ---------- */

.page-contact {
  position: relative;
  z-index: 1;
  padding: clamp(3rem, 8vh, 5.5rem) var(--site-inline) 0;
}
.page-contact .contact-inner {
  width: min(40rem, 100%);
  margin: 0 auto;
}
.page-contact h2 {
  font-family: var(--font-sans);
  font-weight: 900;
  font-size: clamp(2rem, 5.5vw, 4rem);
  line-height: 0.98;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  margin: 0 0 0.9rem;
  color: var(--site-text);
}
.page-contact .contact-sub {
  font-size: 1.05rem;
  color: var(--site-text-muted);
  margin: 0 0 2.5rem;
}
#contact-form label {
  display: block;
  margin-bottom: 1.6rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--site-gold);
}
#contact-form .form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}
@media (max-width: 34rem) {
  #contact-form .form-row {
    grid-template-columns: 1fr;
    gap: 0;
  }
}
#contact-form input,
#contact-form textarea {
  display: block;
  width: 100%;
  box-sizing: border-box;
  margin-top: 0.5rem;
  padding: 0.65rem 0.1rem;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--site-rule);
  color: var(--site-text);
  font-family: var(--font-sans);
  font-size: 1rem;
  border-radius: 0;
  transition: border-color 0.2s ease;
}
#contact-form input:focus,
#contact-form textarea:focus {
  outline: none;
  border-bottom-color: var(--site-gold);
}
#contact-form textarea {
  resize: vertical;
  min-height: 6rem;
}
#contact-form .hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}
#contact-form button {
  margin-top: 0.4rem;
  padding: 0.95rem 2.6rem;
  background: transparent;
  border: 1px solid var(--site-gold);
  color: var(--site-gold-bright);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease;
}
#contact-form button:hover:not(:disabled) {
  background: var(--site-gold);
  color: #120d02;
}
#contact-form button:disabled {
  opacity: 0.55;
  cursor: default;
}
.form-status {
  margin: 1.1rem 0 0;
  min-height: 1.4em;
  font-size: 0.95rem;
  color: var(--site-gold-bright);
}
.page-contact .contact-crown {
  display: block;
  width: 100vw;
  max-width: 100vw;
  height: auto;
  margin: clamp(3rem, 8vh, 5rem) calc(-1 * var(--site-inline)) 0;
  border-radius: 0;
  box-shadow: none;
}

/* ---------- Reveal on scroll ---------- */

html.js .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.85s cubic-bezier(0.16, 1, 0.3, 1), transform 0.85s cubic-bezier(0.16, 1, 0.3, 1);
}
html.js .reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html.js .reveal {
    transition: opacity 0.3s ease;
    transform: none !important;
  }
  .post-row .post-thumb img {
    transition: none;
  }
  .site-menu {
    transition: opacity 0.2s ease, visibility 0s linear 0.2s;
  }
}
