./* ========================================================================== 
   CZW website – restrained modernisation
   --------------------------------------------------------------------------
   Design goals:
   - preserve the calm, photo-led character of the former site
   - remain visually neutral rather than "corporate"
   - use generous spacing and readable typography
   - avoid excessive cards, shadows, colour blocks and decoration
   ========================================================================== */

@font-face { font-family: Montserrat; src: url("fonts/Montserrat-ExtraLight.woff2") format("woff2"); font-weight: 200; font-display: swap; }
@font-face { font-family: Montserrat; src: url("fonts/Montserrat-Light.woff2") format("woff2"); font-weight: 300; font-display: swap; }
@font-face { font-family: Montserrat; src: url("fonts/Montserrat-Regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Dancing Script"; src: url("fonts/DancingScript-Regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }

:root {
  --page-width: 1040px;
  --white: #ffffff;
  --paper: #fbfbf8;
  --panel: #f3f5f5;
  --panel-soft: #f8f8f5;
  --text: #252b2e;
  --muted: #68757c;
  --accent: #667985;
  --line: #dde1e2;
  --line-dark: #cbd1d4;
  --footer: #5f7079;
  --contact-red: #c80f1a;
  --header-height: 96px;
  --header-offset: var(--header-height);
  --section-space: 84px;
}

* { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-offset) + 18px);
  scrollbar-gutter: stable;
}
body {
  margin: 0;
  background: var(--white);
  color: var(--text);
  font-family: Montserrat, Arial, sans-serif;
  font-size: 16px;
  font-weight: 300;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img { display: block; max-width: 100%; }
a { color: inherit; }
button, input, textarea { font: inherit; }
button, a, input, textarea { outline-offset: 3px; }
:focus-visible { outline: 2px solid var(--accent); }
.page-width { width: min(calc(100% - 44px), var(--page-width)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link {
  position: fixed;
  top: 10px;
  left: 12px;
  z-index: 1000;
  padding: 9px 13px;
  background: #fff;
  color: var(--text);
  border: 1px solid var(--line-dark);
  transform: translateY(-160%);
  transition: transform .15s ease;
}
.skip-link:focus { transform: translateY(0); }


/* Header ------------------------------------------------------------------ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  border-bottom: 1px solid var(--line);
}
.header-main { min-height: var(--header-height); }
.scroll-progress {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  z-index: 4;
  height: 2px;
  background: var(--accent);
  opacity: .58;
  transform: scaleX(0);
  transform-origin: 0 50%;
  pointer-events: none;
}
@supports (animation-timeline: scroll()) {
  .scroll-progress {
    animation: czw-scroll-progress linear both;
    animation-timeline: scroll(root block);
  }
  @keyframes czw-scroll-progress {
    from { transform: scaleX(0); }
    to { transform: scaleX(1); }
  }
}
@view-transition { navigation: auto; }
.site-header { view-transition-name: czw-header; }
.site-footer { view-transition-name: czw-footer; }

.header-inner {
  min-height: var(--header-height);
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  grid-template-rows: 38px 58px;
  grid-template-areas:
    "logo contact"
    "logo navigation";
  column-gap: 24px;
  padding-inline: 0;
}
.site-logo {
  grid-area: logo;
  width: 80px;
  height: 80px;
  align-self: center;
  justify-self: start;
}
.site-logo img { width: 80px; height: 80px; }
.contact-strip { grid-area: contact; align-self: stretch; }
.contact-strip-inner {
  height: 100%;
  display: flex;
  align-items: end;
  justify-content: flex-start;
  gap: 24px;
  padding-bottom: 2px;
  color: var(--muted);
}
.contact-strip span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14.5px;
  font-weight: 300;
}
.contact-strip a {
  color: var(--contact-red);
  text-decoration: none;
}
.contact-strip a:hover { color: #9f0c15; }
.contact-strip img {
  width: 20px;
  height: 20px;
  object-fit: contain;
  filter: none;
  opacity: 1;
}
.contact-strip span:nth-child(2) img {
  width: 22px;
  height: 22px;
}
.main-navigation {
  grid-area: navigation;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: clamp(15px, 2.2vw, 25px);
  white-space: nowrap;
}
.main-navigation a {
  position: relative;
  color: #53656f;
  text-decoration: none;
  font-size: 15px;
  font-weight: 300;
  line-height: 1.2;
  padding: 9px 0 11px;
}
.main-navigation a::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 5px;
  left: 0;
  height: 1px;
  background: #8b979d;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .18s ease;
}
.main-navigation a:hover { color: var(--text); }
.main-navigation a:hover::after { transform: scaleX(1); }
.menu-toggle {
  display: none;
  grid-area: menu;
  border: 1px solid var(--line-dark);
  background: transparent;
  color: var(--muted);
  padding: 7px 10px;
  border-radius: 0;
  cursor: pointer;
}

/* Hero -------------------------------------------------------------------- */
.hero {
  position: relative;
  height: clamp(220px, 68.75vw, 660px);
  min-height: 0;
  color: var(--white);
  display: flex;
  align-items: flex-start;
  background-color: #d9ddde;
  background-position: 50% 50%;
  background-size: cover;
  background-repeat: no-repeat;
  /* The original first photograph is a normal cover background, not a
     fixed parallax layer. Keeping it attached to the section prevents the
     exaggerated crop/zoom that fixed backgrounds can cause on phones. */
  background-attachment: scroll;
  background-image: image-set(url("images/church-building-front_480x330.jpg") 1x, url("images/church-building-front-alt_960x660.jpg") 2x);
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(20,28,31,.24) 0%, rgba(20,28,31,.08) 43%, rgba(20,28,31,0) 76%);
  pointer-events: none;
}
.hero-text {
  position: relative;
  z-index: 1;
  padding-top: clamp(95px, 29.8vw, 286px);
}
.hero h1 {
  max-width: 760px;
  margin: 0;
  font-family: "Dancing Script", cursive;
  font-size: clamp(37px, 11.67vw, 112px);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -.015em;
  text-shadow: 0 1px 12px rgba(0,0,0,.12);
}
.hero p {
  margin: clamp(-16px, -1.7vw, -5px) 0 0 clamp(2px, .5vw, 5px);
  font-size: clamp(16px, 5vw, 48px);
  font-weight: 300;
  line-height: 1.3;
  text-shadow: 0 1px 10px rgba(0,0,0,.14);
}
@media (min-width:480px) { .hero { background-image: image-set(url("images/church-building-front_768x528.jpg") 1x, url("images/church-building-front_1536x1056.jpg") 2x); } }
@media (min-width:768px) { .hero { background-image: image-set(url("images/church-building-front_960x660.jpg") 1x, url("images/church-building-front_1920x1320.jpg") 2x); } }
@media (min-width:960px) { .hero { background-image: image-set(url("images/church-building-front_1200x660.jpg") 1x, url("images/church-building-front_2400x1320.jpg") 2x); } }
@media (min-width:1200px) { .hero { background-image: image-set(url("images/church-building-front_1600x660.jpg") 1x, url("images/church-building-front_3200x1320.jpg") 2x); } }
@media (min-width:1600px) { .hero { background-image: image-set(url("images/church-building-front_2000x660.jpg") 1x, url("images/church-building-front_4000x1320.jpg") 2x); } }

/* Shared typography ------------------------------------------------------- */
main h2 {
  text-wrap: balance;
  margin: 0 0 28px;
  color: var(--accent);
  font-size: clamp(19px, calc(10px + 2.4vw), 33px);
  font-weight: 300;
  line-height: 1.3;
  letter-spacing: -.02em;
}
main h3 {
  text-wrap: balance;
  margin: 32px 0 7px;
  color: #394248;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.55;
  letter-spacing: .035em;
}
main p { margin-top: 0; font-size: clamp(13px, calc(10px + .625vw), 16px); font-weight: 300; line-height: 1.82; text-wrap: pretty; hyphens: auto; }
main strong { font-weight: 400; }

/* Welcome ----------------------------------------------------------------- */
.welcome-section { background: var(--white); padding-block: var(--section-space); }
.welcome-layout { display: flex; justify-content: flex-start; }
.welcome-card {
  width: min(60%, 610px);
  padding: 52px 58px 54px;
  background: var(--panel);
  border-top: 1px solid #e1e5e6;
  border-bottom: 1px solid #e1e5e6;
}
.welcome-card p { margin: 0 0 17px; }
.welcome-card p:last-child { margin-bottom: 0; }

/* Reusable photo breaks --------------------------------------------------- */
.parallax {
  position: relative;
  width: 100%;
  min-height: 0;
  --photo-position: 50% 50%;
  --photo-size: cover;
  --photo-color: #d9dddd;
  background-color: var(--photo-color);
  background-repeat: no-repeat;
  background-position: var(--photo-position);
  background-size: var(--photo-size);
  background-attachment: fixed;
  background-image: var(--photo-image, none);
  isolation: isolate;
}
/* The old Sparkle site scaled these photographic bands with the viewport.
   Keeping the same proportions is especially important on phones: they
   remain backgrounds rather than turning into tall, picture-like panels. */
.parallax-community-conversation {
  height: min(55.73vw, 535px);
  --photo-image: image-set(url("images/community-conversation_320x240.jpg") 1x, url("images/community-conversation_640x480.jpg") 2x);
}
.parallax-church-interior {
  height: min(55.73vw, 535px);
  --photo-image: image-set(url("images/church-interior_320x240.jpg") 1x, url("images/church-interior_640x480.jpg") 2x);
}
.parallax-worship {
  height: min(59.1vw, 567px);
  --photo-image: image-set(url("images/worship-service_320x240.jpg") 1x, url("images/worship-service_640x480.jpg") 2x);
}
.parallax-community-room {
  height: min(55.63vw, 534px);
  --photo-image: image-set(url("images/community-room_320x240.jpg") 1x, url("images/community-room_640x480.jpg") 2x);
}
.parallax-highway {
  height: min(55.73vw, 535px);
  --photo-image: image-set(url("images/highway-at-night_320x240.jpg") 1x, url("images/highway-at-night_640x480.jpg") 2x);
}
.parallax-church-street {
  height: min(64.9vw, 623px);
  --photo-position: 50% 100%;
  --photo-size: contain;
  --photo-image: image-set(url("images/church-street-view_320x240.jpg") 1x, url("images/church-street-view_640x480.jpg") 2x);
}

@media (min-width:480px) {
  .parallax-community-conversation { --photo-image: image-set(url("images/community-conversation_480x360.jpg") 1x, url("images/community-conversation-alt_960x720.jpg") 2x); }
  .parallax-church-interior { --photo-image: image-set(url("images/church-interior_480x360.jpg") 1x, url("images/church-interior-alt_960x720.jpg") 2x); }
  .parallax-worship { --photo-image: image-set(url("images/worship-service_480x360.jpg") 1x, url("images/worship-service-alt_960x720.jpg") 2x); }
  .parallax-community-room { --photo-image: image-set(url("images/community-room_480x360.jpg") 1x, url("images/community-room-alt_960x720.jpg") 2x); }
  .parallax-highway { --photo-image: image-set(url("images/highway-at-night_480x360.jpg") 1x, url("images/highway-at-night-alt_960x720.jpg") 2x); }
  .parallax-church-street { --photo-image: image-set(url("images/church-street-view_480x360.jpg") 1x, url("images/church-street-view-alt_960x720.jpg") 2x); }
}
@media (min-width:768px) {
  .parallax-community-conversation { --photo-image: image-set(url("images/community-conversation_768x576.jpg") 1x, url("images/community-conversation_1536x1152.jpg") 2x); }
  .parallax-church-interior { --photo-image: image-set(url("images/church-interior_768x576.jpg") 1x, url("images/church-interior_1536x1152.jpg") 2x); }
  .parallax-worship { --photo-image: image-set(url("images/worship-service_768x576.jpg") 1x, url("images/worship-service_1536x1152.jpg") 2x); }
  .parallax-community-room { --photo-image: image-set(url("images/community-room_768x576.jpg") 1x, url("images/community-room_1536x1152.jpg") 2x); }
  .parallax-highway { --photo-image: image-set(url("images/highway-at-night_768x576.jpg") 1x, url("images/highway-at-night_1536x1152.jpg") 2x); }
  .parallax-church-street { --photo-image: image-set(url("images/church-street-view_768x576.jpg") 1x, url("images/church-street-view_1536x1152.jpg") 2x); }
}
@media (min-width:960px) {
  .parallax-community-conversation { --photo-image: image-set(url("images/community-conversation_960x720.jpg") 1x, url("images/community-conversation_2000x1500.jpg") 2x); }
  .parallax-church-interior { --photo-image: image-set(url("images/church-interior_1200x900.jpg") 1x, url("images/church-interior_2400x1800.jpg") 2x); }
  .parallax-worship { --photo-image: image-set(url("images/worship-service_1200x900.jpg") 1x, url("images/worship-service_2400x1800.jpg") 2x); }
  .parallax-community-room { --photo-image: image-set(url("images/community-room_1200x900.jpg") 1x, url("images/community-room_2400x1800.jpg") 2x); }
  .parallax-highway { --photo-image: image-set(url("images/highway-at-night_1200x900.jpg") 1x, url("images/highway-at-night_2400x1800.jpg") 2x); }
  .parallax-church-street { --photo-image: image-set(url("images/church-street-view_1200x900.jpg") 1x, url("images/church-street-view_2400x1800.jpg") 2x); }
}
@media (min-width:1200px) {
  .parallax-church-interior { --photo-image: image-set(url("images/church-interior_1600x1200.jpg") 1x, url("images/church-interior_3200x2400.jpg") 2x); }
  .parallax-worship { --photo-image: image-set(url("images/worship-service_1600x1200.jpg") 1x, url("images/worship-service_3200x2400.jpg") 2x); }
  .parallax-community-room { --photo-image: image-set(url("images/community-room_1600x1200.jpg") 1x, url("images/community-room_3200x2400.jpg") 2x); }
  .parallax-highway { --photo-image: image-set(url("images/highway-at-night_1600x1200.jpg") 1x, url("images/highway-at-night_3200x2400.jpg") 2x); }
  .parallax-church-street { --photo-image: image-set(url("images/church-street-view_1600x1200.jpg") 1x, url("images/church-street-view_3200x2400.jpg") 2x); }
}
@media (min-width:1600px) {
  .parallax-church-interior { --photo-image: image-set(url("images/church-interior_2000x1500.jpg") 1x, url("images/church-interior_4000x3000.jpg") 2x); }
  .parallax-worship { --photo-image: image-set(url("images/worship-service_2000x1500.jpg") 1x, url("images/worship-service_4000x3000.jpg") 2x); }
  .parallax-community-room { --photo-image: image-set(url("images/community-room_2000x1500.jpg") 1x, url("images/community-room_4000x3000.jpg") 2x); }
  .parallax-highway { --photo-image: image-set(url("images/highway-at-night_2000x1500.jpg") 1x, url("images/highway-at-night_4000x3000.jpg") 2x); }
  .parallax-church-street { --photo-image: image-set(url("images/church-street-view_2000x1500.jpg") 1x, url("images/church-street-view_4000x3000.jpg") 2x); }
}

@media (scripting: enabled) {
  .parallax { background-image: none; }
}

/* About ------------------------------------------------------------------- */
.about-section { background: var(--white); padding-block: calc(var(--section-space) + 4px); }
.about-layout {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  gap: 74px;
  align-items: start;
}
.pastor-card { width: 261px; margin: 4px 0 0; text-align: left; }
.pastor-card picture, .pastor-card img { width: 261px; height: 253px; }
.pastor-card img { object-fit: cover; border-radius: 50%; box-shadow: 0 12px 28px rgba(24,35,40,.16), 0 2px 5px rgba(24,35,40,.12); }
.pastor-card p {
  margin: 14px 0 0;
  padding-top: 11px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
  font-weight: 300;
  line-height: 1.5;
}
.about-copy { max-width: 670px; }
.about-copy p { margin: 0 0 18px; }
.about-copy strong { font-weight: 400; }

/* Events ------------------------------------------------------------------ */
.events-section { background: var(--white); padding-block: var(--section-space); }
.events-layout { display: flex; justify-content: flex-start; }
.events-card {
  width: min(62%, 650px);
  padding: 50px 60px 52px;
  background: var(--panel);
  border-top: 1px solid #e7e7e1;
  border-bottom: 1px solid #e7e7e1;
}
.events-card h3 {
  margin-top: 27px;
  margin-bottom: 8px;
  padding-top: 23px;
  border-top: 1px solid #dfe4e5;
}
.events-card h2 + h3 { margin-top: 2px; padding-top: 0; border-top: 0; }
.events-card p { margin: 0 0 12px; }

/* Photo overlays ---------------------------------------------------------- */
.kids-photo-break, .fellowship-photo-break { position: relative; overflow: hidden; }
.photo-overlay {
  min-height: inherit;
  display: flex;
  align-items: center;
  padding-inline: 20px;
}
.photo-overlay-left picture { display: block; width: 344px; }
.photo-overlay-left img {
  width: 344px;
  height: 273px;
  object-fit: cover;
  outline: 6px solid rgba(255,255,255,.96);
  outline-offset: 0;
  box-shadow: 0 16px 34px rgba(25,35,40,.13), 0 2px 8px rgba(25,35,40,.08);
}
.dual-photo-overlay {
  min-height: inherit;
  position: relative;
}
.dual-photo-overlay picture {
  position: absolute;
  width: 342px;
}
.dual-photo-overlay picture:first-child { top: 48px; right: 42px; }
.dual-photo-overlay picture + picture { bottom: 44px; left: 44px; }
.dual-photo-overlay img {
  width: 342px;
  object-fit: cover;
  outline: 6px solid rgba(255,255,255,.96);
  box-shadow: 0 16px 34px rgba(25,35,40,.13), 0 2px 8px rgba(25,35,40,.08);
}

/* Gottesdienst ------------------------------------------------------------ */
.service-section { background: var(--white); padding-block: var(--section-space); }
.service-layout {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 78px;
  align-items: center;
}
.simple-slider {
  position: relative;
  width: 344px;
  height: 279px;
  overflow: hidden;
}
.simple-slider .slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.1s ease; }
.simple-slider .slide.is-active { opacity: 1; }
.simple-slider img { width: 344px; height: 279px; object-fit: cover; }
.service-copy { max-width: 560px; }
.service-copy p { margin: 0 0 17px; }

/* Contact ----------------------------------------------------------------- */
.contact-section { background: var(--paper); padding-block: calc(var(--section-space) + 6px); }
.contact-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 72px;
  align-items: start;
}
.contact-details { padding-right: 36px; border-right: 1px solid var(--line); }
.contact-details > p { margin: 0 0 10px; }
.contact-line { display: flex; align-items: center; gap: 12px; }
.contact-line img { filter: grayscale(1) saturate(0); opacity: .7; }
.contact-line a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; border-bottom: 1px solid transparent; }
.contact-line a:hover { border-bottom-color: #a9b0b3; }
.contact-form-wrap { margin-top: 0; }
.contact-form-wrap h3 {
  color: var(--accent);
  font-size: 27px;
  font-weight: 300;
  line-height: 1.4;
  letter-spacing: -.01em;
  margin: 3px 0 28px;
}
.contact-form {
  width: min(100%, 700px);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 21px 24px;
}
.form-row { display: flex; flex-direction: column; gap: 7px; }
.form-row:nth-child(3) { grid-column: 1 / -1; }
.form-row label { color: #4e5b61; font-size: 13px; font-weight: 300; }
input, textarea {
  width: 100%;
  border: 1px solid #cfd5d7;
  background: rgba(255,255,255,.82);
  color: var(--text);
  padding: 10px 11px;
  border-radius: 0;
  transition: border-color .15s ease, background-color .15s ease;
}
input { min-height: 44px; }
textarea { resize: vertical; min-height: 158px; }
input:focus, textarea:focus { border-color: #8f9ca2; background: #fff; }
.honeypot { position: absolute !important; left: -10000px !important; width: 1px !important; height: 1px !important; overflow: hidden !important; }
.consent-row {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #55636a;
  font-size: 11px;
}
.consent-row input { width: auto; min-height: auto; }
.privacy-short, .privacy-note { color: #6b777c; font-size: 12px; font-weight: 300; line-height: 1.7; }
.privacy-short { grid-column: 1 / -1; margin: -8px 0 0; max-width: 700px; }
.contact-form button {
  width: 150px;
  min-height: 44px;
  border: 1px solid #73838b;
  background: transparent;
  color: #53656f;
  cursor: pointer;
  transition: background-color .15s ease, color .15s ease;
}
.contact-form button:hover { background: #657780; color: #fff; }
.contact-form button:disabled { cursor: wait; opacity: .62; }
.field-error {
  min-height: 1.35em;
  margin: 0;
  color: #a60e17;
  font-size: 11px;
  line-height: 1.35;
}
.field-error:empty { min-height: 0; }
.contact-form > .field-error { grid-column: 1 / -1; }
.form-status {
  grid-column: 1 / -1;
  min-height: 1.5em;
  margin: -4px 0 0;
  color: #56656c;
  font-size: 12px;
  line-height: 1.5;
}
.form-status:empty { min-height: 0; }
[aria-invalid="true"] { border-color: #b73a42; }

.privacy-note { max-width: 700px; margin: 26px 0 0; }

/* Anfahrt ----------------------------------------------------------------- */
/* Keep directions and the map as a real content section. The road image is
   a separate photographic window immediately before it in the HTML, rather
   than being mixed into the text/map background. */
.directions-section {
  background: var(--white);
  padding-block: calc(var(--section-space) + 4px);
}
.directions-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 1fr);
  gap: 64px;
  align-items: start;
}
.directions-card {
  max-width: 570px;
  padding: 0;
  background: transparent;
}
.directions-card p { margin: 0 0 18px; }
.map-box {
  position: relative;
  width: 100%;
  height: 430px;
  overflow: hidden;
  background: #e9ecec;
  border: 1px solid var(--line);
}
.map-placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 15px;
  padding: 30px;
  text-align: center;
  color: var(--accent);
  background: #f5f7f6;
}
.map-placeholder svg { width: 72px; height: 72px; opacity: .72; }
.map-placeholder p {
  max-width: 330px;
  margin: 0.45rem 0;
  color: #617077;
  font-size: 0.85rem;
  line-height: 1.45;
}

.map-placeholder strong {
  font-size: 0.95rem;
}
.map-placeholder button {
  border: 1px solid #7a8990;
  background: #fff;
  color: #566870;
  min-height: 44px;
  padding: 9px 15px;
  cursor: pointer;
  transition: border-color .15s ease, color .15s ease;
}
.map-placeholder button:hover { border-color: #566870; color: #34434a; }
.map-box iframe { width: 100%; height: 100%; border: 0; }
.map-placeholder[hidden], .map-box iframe[hidden] { display: none; }
.map-box.map-is-loaded iframe { display: block; }

/* Road photograph is its own photo window immediately before Anfahrt. */
.footer-photo { --photo-color: var(--white); background-color: var(--white); }

/* Footer ------------------------------------------------------------------ */
.site-footer {
  background: var(--footer);
  color: rgba(255,255,255,.92);
  border-top: 1px solid rgba(255,255,255,.18);
}
.footer-inner {
  min-height: 142px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 42px;
  padding-block: 28px;
}
.footer-copy { flex: 1; text-align: left; }
.footer-copy p { margin: 0; font-size: 13px; font-weight: 300; line-height: 1.65; }
.footer-copy nav { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 9px; }
.footer-copy a { font-size: 11px; font-weight: 300; text-decoration: none; }
.footer-copy a:hover { text-decoration: underline; text-underline-offset: 3px; }
.footer-copy .copyright { margin-top: 8px; font-size: 9px; opacity: .78; }
.footer-logo { flex: 0 0 74px; opacity: .92; }
.footer-logo img { width: 74px; height: 74px; }

/* Legal / thank-you pages ------------------------------------------------- */
.subpage-main { min-height: 700px; padding: 78px 22px 110px; background: var(--white); }
.legal-page { width: min(100%, 760px); margin: 0 auto; }
.legal-page > h1, .thankyou-box h1 {
  color: var(--accent);
  font-family: Montserrat, Arial, sans-serif;
  font-size: 34px;
  font-weight: 300;
  line-height: 1.35;
  letter-spacing: -.02em;
  margin: 0 0 38px;
}
.legal-page h2 { color: #343b3f; font-size: 15px; font-weight: 400; line-height: 1.6; margin: 30px 0 8px; }
.legal-page h3 { font-size: 12px; font-weight: 400; line-height: 1.7; margin: 22px 0 5px; }
.legal-page p, .legal-page li { font-size: 12px; font-weight: 300; line-height: 1.8; }
.legal-page a { text-decoration: underline; text-underline-offset: 2px; }
.thankyou-box { max-width: 640px; margin: 50px auto 300px; padding: 42px 46px; background: var(--panel); border-top: 1px solid #e6e7e2; }
.thankyou-box h1 { margin: 0; }

/* Tablet ------------------------------------------------------------------ */
@media (max-width: 959px) {
  :root { --page-width: 820px; --section-space: 70px; }
  .page-width { width: min(calc(100% - 38px), var(--page-width)); }
  .header-inner { grid-template-columns: 74px minmax(0,1fr); column-gap: 18px; }
  .site-logo, .site-logo img { width: 64px; height: 64px; }
  .main-navigation { gap: 13px; }
  .main-navigation a { font-size: 12.5px; }
  .contact-strip span { font-size: 13.5px; }
  .welcome-card, .events-card { width: 68%; }
  .about-layout { grid-template-columns: 220px minmax(0,1fr); gap: 48px; }
  .pastor-card { width: 209px; }
  .pastor-card picture, .pastor-card img { width: 209px; height: 203px; }
  .service-layout { grid-template-columns: 300px minmax(0,1fr); gap: 50px; }
  .simple-slider, .simple-slider img { width: 275px; height: 223px; }
  .contact-layout { grid-template-columns: 220px minmax(0,1fr); gap: 48px; }
  .directions-layout { gap: 42px; grid-template-columns: minmax(0, 1fr) minmax(320px, .95fr); }
}

/* Mobile ------------------------------------------------------------------ */
@media (max-width: 767px) {
  :root { --header-height: 78px; --section-space: 56px; }
  html { scroll-padding-top: 94px; }
  .page-width { width: min(calc(100% - 34px), 680px); }
  .header-inner {
    position: relative;
    min-height: 78px;
    grid-template-columns: 52px 1fr auto;
    grid-template-rows: 78px;
    grid-template-areas: "logo contact menu";
    column-gap: 12px;
  }
  .site-logo, .site-logo img { width: 48px; height: 48px; }
  .contact-strip-inner {
    align-items: center;
    justify-content: flex-end;
    padding: 0;
    gap: 11px;
  }
  .contact-strip span { font-size: 15px; font-weight: 400; }
  .contact-strip a { display: inline-flex; align-items: center; min-height: 44px; }
  .contact-strip img { width: 18px; height: 18px; }
  .contact-strip span:nth-child(2) img { width: 20px; height: 20px; }
  .hero::before { background: linear-gradient(90deg, rgba(20,28,31,.25), rgba(20,28,31,.04) 75%); }
  .welcome-card, .events-card { width: 100%; padding: 38px 32px 40px; }
  /* Match the compact photographic bands of the original mobile layout. */
  .parallax-community-conversation { height: 55.7vw; }
  .parallax-church-interior { height: min(101.5vw, 487px); }
  .parallax-worship { height: 60.9vw; }
  .parallax-community-room { height: 58.1vw; }
  .parallax-church-street { height: 82.8vw; }
  .about-layout { display: block; }
  .pastor-card { width: 171px; margin-bottom: 42px; }
  .pastor-card picture, .pastor-card img { width: 171px; height: auto; }
  .about-copy { max-width: 100%; }
  .photo-overlay { align-items: flex-end; padding-bottom: 34px; }
  .photo-overlay-left picture, .photo-overlay-left img { width: 275px; height: auto; }
  .photo-overlay-left img, .dual-photo-overlay img { outline-width: 6px; }
  .service-layout { display: flex; flex-direction: column; gap: 40px; align-items: flex-start; }
  .simple-slider, .simple-slider img { width: 275px; height: 223px; }
  .service-copy { max-width: 100%; }
  .dual-photo-overlay picture { width: 274px; }
  .dual-photo-overlay picture:first-child { top: 32px; right: 22px; }
  .dual-photo-overlay picture + picture { bottom: 34px; left: 22px; }
  .dual-photo-overlay img { width: 274px; height: auto; }
  .contact-layout { display: block; }
  .contact-details { max-width: 450px; margin-bottom: 48px; padding: 0 0 32px; border-right: 0; border-bottom: 1px solid var(--line); }
  .contact-form { grid-template-columns: 1fr; }
  .form-row:nth-child(3), .consent-row, .privacy-short { grid-column: auto; }
  .directions-layout { display: block; }
  .directions-card { max-width: 100%; margin-bottom: 42px; }
  .map-box { height: 410px; }
  .parallax-church-street { min-height: 380px; }
  .footer-inner { min-height: 124px; gap: 22px; }
  .footer-copy p { font-size: 10.5px; }
  .footer-copy a { font-size: 9.5px; }
  .footer-logo { flex-basis: 52px; }
  .footer-logo img { width: 52px; height: 52px; }
  .subpage-main { padding-top: 54px; }
}

@media (max-width: 479px) {
  main h2 {
  text-wrap: balance; font-size: 19px; line-height: 1.55; }
  main h3 {
  text-wrap: balance; font-size: 13px; }
  main p { font-size: 13px; line-height: 1.76; }
  .pastor-card p { font-size: 10px; }
}

@media (max-width: 520px) {
  .page-width { width: min(calc(100% - 28px), 480px); }
  .contact-strip span:first-child { display: none; }
  .welcome-card, .events-card { padding-inline: 24px; }
  .pastor-card { width: 150px; }
  .pastor-card picture, .pastor-card img { width: 150px; }
  .photo-overlay-left picture, .photo-overlay-left img, .simple-slider, .simple-slider img { width: 228px; }
  .simple-slider { height: 186px; }
  .dual-photo-overlay picture { width: 228px; }
  .dual-photo-overlay img { width: 228px; }
  .map-box { height: 330px; }
  .footer-inner { align-items: flex-start; }
}


@media (max-width: 767px), (hover: none) {
  .parallax { background-attachment: scroll; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero, .parallax, .directions-section { background-attachment: scroll; }
  .simple-slider .slide { transition: none; }
  .main-navigation a::after { transition: none; }
}

/* ========================================================================== 
   Fixed photo-background windows
   --------------------------------------------------------------------------
   JavaScript creates one fixed plane per photo band. Only near/visible planes
   are active. CSS backgrounds remain a no-JavaScript fallback.
   ========================================================================== */
.photo-stage {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  contain: strict;
}
.photo-stage-scene {
  position: fixed;
  inset: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateZ(0);
}
.photo-stage-scene.is-visible {
  visibility: visible;
  will-change: clip-path;
}
.photo-stage-base {
  position: absolute;
  inset: 0;
  background-repeat: no-repeat;
  background-color: #d9dddd;
  transform: translateZ(0);
}
.has-photo-stage .site-header { z-index: 300; }
.has-photo-stage main,
.has-photo-stage .site-footer { position: relative; z-index: 1; }
.has-photo-stage .stage-window {
  position: relative;
  overflow: hidden;
  background-image: none !important;
  background-color: transparent !important;
  background-attachment: scroll !important;
}
.has-photo-stage .stage-window > * { position: relative; z-index: 2; }

/* A very quiet depth seam: the white page feels slightly in front of the
   photographs without adding a new colour or decorative motif. */
.parallax::before,
.parallax::after {
  content: "";
  position: absolute;
  z-index: 1;
  right: 0;
  left: 0;
  height: 12px;
  pointer-events: none;
}
.parallax::before {
  top: 0;
  background: linear-gradient(to bottom, rgba(20,28,31,.14), rgba(20,28,31,0));
}
.parallax::after {
  bottom: 0;
  background: linear-gradient(to top, rgba(20,28,31,.12), rgba(20,28,31,0));
}

/* Quiet reveal of the circular pastor portrait. */
.pastor-card img {
  transform: scale(.965);
  filter: saturate(.96);
  transition: transform .8s cubic-bezier(.2,.7,.2,1), filter .8s ease;
}
.pastor-card.is-revealed img {
  transform: scale(1);
  filter: saturate(1);
}

/* Understated scroll-position indication. */
.main-navigation a.is-current { color: var(--text); }
.main-navigation a.is-current::after { transform: scaleX(1); }

@media (prefers-reduced-motion: reduce) {
  .pastor-card img {
    transform: none;
    transition: none;
    filter: none;
  }
}

/* Mobile navigation --------------------------------------------------------
   The button remains fixed and reachable at every scroll position. The menu
   is focus-contained, uses the measured header height and respects safe areas. */
@media (max-width: 767px) {
  body.menu-open { overflow: hidden; }
  .header-inner { padding-right: 54px; }
  .contact-strip-inner { padding-right: 2px; }

  .menu-toggle {
    display: grid;
    position: fixed;
    top: calc(env(safe-area-inset-top, 0px) + 16px);
    right: max(14px, env(safe-area-inset-right, 0px));
    z-index: 520;
    width: 46px;
    height: 46px;
    padding: 0;
    place-items: center;
    border: 1px solid var(--line-dark);
    background: rgba(255,255,255,.98);
    color: #56666e;
    font-size: 25px;
    line-height: 1;
    box-shadow: 0 4px 16px rgba(29,39,44,.10);
  }
  .menu-toggle > span[aria-hidden="true"] { display: block; transform: translateY(-1px); }

  .main-navigation {
    position: fixed;
    top: var(--header-offset);
    right: 0;
    left: 0;
    z-index: 500;
    display: flex;
    max-height: calc(100dvh - var(--header-offset));
    overflow-y: auto;
    padding: 14px max(24px, calc((100vw - 680px) / 2 + 17px)) calc(19px + env(safe-area-inset-bottom, 0px));
    background: rgba(255,255,255,.99);
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 10px 28px rgba(29,39,44,.10);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-8px);
    transition: opacity .16s ease, transform .16s ease, visibility 0s linear .16s;
  }
  .main-navigation.is-open {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
    transition-delay: 0s;
  }
  .main-navigation a { display: flex; align-items: center; min-height: 44px; font-size: 14px; padding: 8px 0; }
  .main-navigation a::after { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .main-navigation { transition: none; }
  .scroll-progress { animation: none; }
}

