/* PRAYERHOUSE COFFEE — Light Through Glass (LOCKED 8/02)
   The interface stays white. The type stays ink. Color arrives only as light:
   photography and soft prismatic caustics drifting across the page.
   One hairline of gold is the only pigment the chrome is allowed.
   Bodoni Moda (display) + Instrument Sans (working text). NO browns, ever. */

:root {
  --white: #FEFEFC;
  --ink: #16181D;
  --slate: #5F6672;
  --hairline: rgba(22, 24, 29, 0.14);
  --gold: #D4AF37;
  --err: #B3324B;
  --display: "Bodoni Moda", Didot, "Bodoni MT", serif;
  --body: "Instrument Sans", -apple-system, sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001s !important; transition-duration: 0.001s !important; }
  .ribbon { display: none; }
}

body {
  background: var(--white);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; }

::selection { background: var(--ink); color: var(--white); }

.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 300;
  background: var(--ink); color: var(--white); padding: 0.6rem 1rem;
  font-weight: 600; text-decoration: none;
}
.skip-link:focus { left: 0; }

:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 2px; }

/* ---------- The light: prismatic caustics on white ---------- */

.light { position: fixed; inset: 0; pointer-events: none; z-index: 0; }
.ribbon {
  position: absolute; width: 130vw; height: 200px;
  filter: blur(60px); opacity: 0.16; will-change: translate;
  background: linear-gradient(90deg, transparent, #3B63C4 18%, #7FD0B0 34%, #F2B21A 52%, #E86A7A 70%, #7146A8 86%, transparent);
  animation: sweep 34s ease-in-out infinite alternate;
}
.r1 { top: 60vh; left: -25vw; transform: rotate(-13deg); }
.r2 { top: 175vh; left: -15vw; transform: rotate(8deg); animation-delay: -15s; opacity: 0.12; }
.r3 { top: 320vh; left: -20vw; transform: rotate(-7deg); animation-delay: -26s; opacity: 0.12; }
@keyframes sweep { from { translate: 0 0; } to { translate: 12vw 50px; } }

body > *:not(.light) { position: relative; z-index: 1; }

/* ---------- Type helpers ---------- */

.eyebrow {
  font-family: var(--body);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--slate);
  margin-bottom: 1.1rem;
}

h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.08; letter-spacing: 0.005em; }

h2 { font-size: clamp(2.1rem, 4.4vw, 3.4rem); }
h2 br { display: none; }

.k {
  font-size: 0.7rem; font-weight: 600; letter-spacing: 0.3em;
  text-transform: uppercase; color: var(--slate); margin-bottom: 0.9rem;
}

.gold-rule { width: 64px; height: 1px; background: var(--gold); margin: 1.7rem auto; }

.section-head { margin-bottom: clamp(2.6rem, 5vw, 4rem); }
.section-head.center { text-align: center; }
.section-head.center h2 { margin-left: auto; margin-right: auto; }
.section-sub { color: var(--slate); max-width: 44rem; margin: 1.1rem auto 0; }
.section-head:not(.center) .section-sub { margin-left: 0; }

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

.btn {
  display: inline-block;
  font-family: var(--body);
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 1rem 1.9rem;
  border-radius: 100px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), background 0.35s var(--ease), color 0.35s var(--ease), border-color 0.35s var(--ease);
}
.btn-ink { background: var(--ink); color: var(--white); }
.btn-ink:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 34px -12px rgba(22, 24, 29, 0.45);
}
.btn-line { background: transparent; color: var(--ink); border-color: rgba(22, 24, 29, 0.4); }
.btn-line:hover { border-color: var(--ink); transform: translateY(-2px); }
.btn-wide { width: 100%; text-align: center; }

/* ---------- Nav ---------- */

.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  display: flex; align-items: center; gap: 2rem;
  padding: 1rem 2rem;
  transition: background 0.4s var(--ease), box-shadow 0.4s var(--ease), padding 0.4s var(--ease);
}
.nav.scrolled {
  background: rgba(254, 254, 252, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 var(--hairline);
  padding: 0.65rem 2rem;
}
.nav-brand { display: flex; align-items: center; gap: 0.7rem; text-decoration: none; }
.nav-word {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1rem;
  letter-spacing: 0.18em;
  color: var(--ink);
}
.nav-word em {
  font-style: normal;
  color: var(--slate);
  font-size: 0.56rem;
  letter-spacing: 0.5em;
  display: block;
  margin-top: -0.05rem;
  font-family: var(--body);
  font-weight: 600;
}
.nav-links { display: flex; gap: 1.8rem; margin-left: auto; }
.nav-links a {
  font-size: 0.82rem; font-weight: 500; letter-spacing: 0.05em;
  text-decoration: none; color: var(--slate);
  transition: color 0.25s;
}
.nav-links a:hover { color: var(--ink); }
.nav-cta { padding: 0.62rem 1.3rem; font-size: 0.7rem; }

@media (max-width: 880px) {
  .nav-links { display: none; }
  .nav { padding: 0.8rem 1rem; gap: 0.8rem; }
  .nav.scrolled { padding: 0.6rem 1rem; }
  .nav-cta { margin-left: auto; white-space: nowrap; padding: 0.55rem 0.9rem; font-size: 0.62rem; }
  .nav-word { font-size: 0.85rem; letter-spacing: 0.12em; }
  .nav-brand { flex-shrink: 0; }
}

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

.hero { position: relative; }
.hero-media { position: relative; height: min(74vh, 640px); overflow: hidden; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-fade {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(254, 254, 252, 0.0) 55%, var(--white) 98%);
}
#prayer-air { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.air-word {
  position: absolute;
  bottom: -8%;
  font-family: var(--display);
  font-style: italic;
  color: var(--white);
  text-shadow: 0 1px 18px rgba(22, 24, 29, 0.25);
  opacity: 0;
  will-change: transform, opacity;
  animation: rise linear forwards;
}
@keyframes rise {
  0%   { transform: translateY(0) translateX(0); opacity: 0; }
  12%  { opacity: var(--peak, 0.5); }
  70%  { opacity: var(--peak, 0.5); }
  100% { transform: translateY(-70vh) translateX(var(--drift, 2vw)); opacity: 0; }
}

.hero-copy {
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
  padding: clamp(2.2rem, 5vw, 4rem) 2rem 4.5rem;
}
.hero-copy h1 {
  font-size: clamp(3rem, 7.6vw, 5.8rem);
  line-height: 1.04;
}
.hero-copy h1 em { font-style: italic; }
.hero-copy h1 br { display: inline; }
.hero-sub {
  color: var(--slate);
  max-width: 40rem;
  margin: 0 auto 2.2rem;
  font-size: clamp(1rem, 1.4vw, 1.1rem);
}
.hero-ctas { display: flex; gap: 0.9rem; justify-content: center; flex-wrap: wrap; }

/* ---------- Reveal choreography ---------- */

.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}
.reveal.in { opacity: 1; transform: none; }
.d1 { transition-delay: 0.12s; }
.d2 { transition-delay: 0.24s; }

/* ---------- Verse band ---------- */

.verse-band {
  text-align: center;
  padding: clamp(4rem, 9vw, 7rem) 2rem;
  border-top: 1px solid var(--hairline);
}
.verse-big {
  font-family: var(--display);
  font-style: italic;
  font-size: clamp(1.7rem, 4vw, 3rem);
  line-height: 1.3;
  max-width: 22ch;
  margin: 0 auto 1.2rem;
}
.verse-big .w { color: #6E7480; transition: color 0.5s var(--ease); }
.verse-big .w.lit { color: var(--ink); }
.verse-ref {
  font-size: 0.7rem; font-weight: 600; letter-spacing: 0.34em;
  text-transform: uppercase; color: var(--slate); margin-bottom: 2rem;
}
.verse-kicker { color: var(--slate); max-width: 36rem; margin: 0 auto; font-size: 1rem; }

/* ---------- Vision ---------- */

.vision { padding: clamp(3rem, 7vw, 6rem) 2rem; max-width: 1160px; margin: 0 auto; }
.vision-row {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
  margin-bottom: clamp(4rem, 7vw, 6.5rem);
}
.vision-row.flip .vision-photo { order: 2; }
.vision-photo { overflow: hidden; aspect-ratio: 4 / 4.4; }
.vision-photo img {
  width: 100%; height: 100%; object-fit: cover;
  transform: scale(1.05);
  transition: transform 1.6s var(--ease);
}
.vision-row:hover .vision-photo img { transform: scale(1.0); }
.vision-copy h3 { font-size: clamp(1.7rem, 2.8vw, 2.4rem); margin-bottom: 1rem; }
.vision-copy p { color: var(--slate); max-width: 32rem; margin-bottom: 1rem; }
.vision-line {
  font-family: var(--display);
  font-style: italic;
  color: var(--ink) !important;
  font-size: 1.15rem;
  border-left: 1px solid var(--gold);
  padding-left: 1.2rem;
}

@media (max-width: 820px) {
  .vision-row, .vision-row.flip { grid-template-columns: 1fr; }
  .vision-row.flip .vision-photo { order: 0; }
  .vision-photo { aspect-ratio: 4 / 3; }
}

/* ---------- Living Sanctuary ---------- */

.sanctuary { padding: clamp(3rem, 7vw, 6rem) 2rem; max-width: 1160px; margin: 0 auto; border-top: 1px solid var(--hairline); }
.creed { display: grid; grid-template-columns: 1fr 1fr 1fr; border: 1px solid var(--hairline); margin-bottom: clamp(2rem, 4vw, 3rem); }
.creed div { padding: 1.6rem 1.8rem; border-right: 1px solid var(--hairline); }
.creed div:last-child { border-right: none; }
.creed b { display: block; font-family: var(--display); font-weight: 500; font-size: 1.2rem; margin-bottom: 0.4rem; }
.creed span { font-size: 0.92rem; color: var(--slate); }

.houses { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 1.2rem; margin-bottom: clamp(2.2rem, 4vw, 3rem); }
.house { margin: 0; }
.house img { width: 100%; aspect-ratio: 16 / 10.5; object-fit: cover; }
.house figcaption { padding: 0.9rem 0.2rem 0; }
.house b { display: block; font-family: var(--display); font-weight: 500; font-size: 1.05rem; }
.house span { font-size: 0.88rem; color: var(--slate); }

.plan-ctas { display: flex; gap: 0.9rem; flex-wrap: wrap; }
.plan-ctas.center { justify-content: center; }

@media (max-width: 880px) {
  .creed { grid-template-columns: 1fr; }
  .creed div { border-right: none; border-bottom: 1px solid var(--hairline); }
  .creed div:last-child { border-bottom: none; }
  .houses { grid-template-columns: 1fr; }
}

/* ---------- Rhythm ---------- */

.rhythm { border-top: 1px solid var(--hairline); padding: clamp(3rem, 7vw, 6rem) 2rem; }
.rhythm-inner { max-width: 1160px; margin: 0 auto; }
.rhythm-board { border-top: 1px solid var(--hairline); }
.rhythm-slot {
  display: grid;
  grid-template-columns: 8rem 16rem 1fr;
  gap: 1.5rem;
  align-items: baseline;
  padding: 1.3rem 0.4rem;
  border-bottom: 1px solid var(--hairline);
  transition: background 0.3s var(--ease);
}
.rhythm-slot:hover { background: rgba(22, 24, 29, 0.025); }
.r-time { font-family: var(--display); font-weight: 500; font-size: 1.25rem; letter-spacing: 0.03em; }
.r-name { font-weight: 600; letter-spacing: 0.04em; }
.r-note { color: var(--slate); font-size: 0.95rem; }
.rhythm-slot.featured .r-name::after {
  content: "";
  display: inline-block;
  width: 34px; height: 1px;
  background: var(--gold);
  margin-left: 0.8rem;
  vertical-align: middle;
}
.rhythm-slot.closed .r-time, .rhythm-slot.closed .r-name { color: var(--slate); }

@media (max-width: 720px) {
  .rhythm-slot { grid-template-columns: 1fr; gap: 0.2rem; }
}

/* ---------- Prayer Window ---------- */

.window { border-top: 1px solid var(--hairline); padding: clamp(3rem, 7vw, 6rem) 2rem; }
.window-inner { max-width: 760px; margin: 0 auto; }
.window-stage { text-align: center; margin-bottom: 2.4rem; }
#window-canvas {
  width: min(420px, 82vw);
  height: auto;
  display: inline-block;
}
.pane-count {
  font-family: var(--display);
  font-style: italic;
  color: var(--slate);
  font-size: 1.05rem;
  margin-top: 0.9rem;
}

.window-form { text-align: left; }
.field { display: block; margin-bottom: 1.1rem; }
.field span {
  display: block;
  font-size: 0.68rem; font-weight: 600;
  letter-spacing: 0.26em; text-transform: uppercase;
  color: var(--slate);
  margin-bottom: 0.5rem;
}
.field input, .field textarea {
  width: 100%;
  background: var(--white);
  border: 1px solid rgba(22, 24, 29, 0.25);
  border-radius: 4px;
  color: var(--ink);
  font-family: var(--body);
  font-size: 1rem;
  padding: 0.9rem 1rem;
  transition: border-color 0.3s, box-shadow 0.3s;
}
.field input::placeholder, .field textarea::placeholder { color: rgba(95, 102, 114, 0.55); }
.field input:focus, .field textarea:focus {
  outline: none;
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(22, 24, 29, 0.08);
}
.field textarea { resize: vertical; min-height: 90px; }
.field-row { display: flex; gap: 1rem; align-items: flex-end; }
.field-row .slim { flex: 1; margin-bottom: 0; }
.field-row .btn { flex-shrink: 0; }
.field-row.three { display: grid; grid-template-columns: 1fr 1.2fr 0.9fr; align-items: start; }
@media (max-width: 720px) {
  .field-row { flex-direction: column; align-items: stretch; }
  .field-row.three { grid-template-columns: 1fr; }
}

.form-status { margin-top: 1rem; font-size: 0.95rem; color: var(--ink); min-height: 1.4em; }
.form-status.err { color: var(--err); }

/* ---------- Founding ---------- */

.founding { border-top: 1px solid var(--hairline); padding: clamp(3.5rem, 8vw, 7rem) 2rem; }
.founding-inner { max-width: 720px; margin: 0 auto; text-align: center; }
.founding h2 { margin-bottom: 1.3rem; }
.founding h2 br { display: inline; }
.founding-sub { color: var(--slate); max-width: 36rem; margin: 0 auto 2.6rem; }
.founding-form { text-align: left; }

.chips { border: none; margin: 0.4rem 0 1.6rem; }
.chips legend {
  font-size: 0.68rem; font-weight: 600; letter-spacing: 0.26em;
  text-transform: uppercase; color: var(--slate); margin-bottom: 0.7rem;
}
.chips label { display: inline-block; margin: 0 0.5rem 0.5rem 0; cursor: pointer; }
.chips input { position: absolute; opacity: 0; }
.chips span {
  display: inline-block;
  padding: 0.55rem 1.15rem;
  border: 1px solid rgba(22, 24, 29, 0.3);
  border-radius: 100px;
  font-size: 0.85rem;
  color: var(--slate);
  transition: all 0.25s var(--ease);
}
.chips input:checked + span { background: var(--ink); color: var(--white); border-color: var(--ink); font-weight: 600; }
.chips input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 2px; }

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

.footer {
  border-top: 1px solid var(--hairline);
  padding: 4rem 2rem 3.2rem;
  text-align: center;
}
.footer img { margin: 0 auto 1.1rem; }
.footer-word { font-family: var(--display); font-weight: 500; letter-spacing: 0.32em; font-size: 0.9rem; margin-bottom: 0.8rem; }
.footer-verse { font-family: var(--display); font-style: italic; color: var(--slate); font-size: 0.98rem; margin-bottom: 1.8rem; }
.footer-links { display: flex; gap: 1.6rem; justify-content: center; flex-wrap: wrap; margin-bottom: 1.8rem; }
.footer-links a { font-size: 0.84rem; color: var(--slate); text-decoration: none; transition: color 0.25s; }
.footer-links a:hover { color: var(--ink); }
.footer-fine { font-size: 0.76rem; color: var(--slate); letter-spacing: 0.08em; }
