/* IConnect Ministry Inc. — Fast, Responsive Motion & Visual Effects */

:root {
  --fx-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --fx-cyan: #00a6e6;
  --fx-cyan-bright: #67d2ff;
}

html {
  scroll-padding-top: 96px;
}

html,
body {
  background: #080909;
  padding: 0 !important;
  margin: 0;
}

/* 1. Full-Bleed Dark Shell, Atmosphere & Scroll Progress */
.site {
  isolation: isolate;
  width: 100% !important;
  max-width: none !important;
  margin: 0;
  border-radius: 0 !important;
  box-shadow: none !important;
  min-height: 100vh;
  min-height: 100svh;
}

.subpage-site {
  min-height: 100vh;
  min-height: 100svh;
}

.header,
.hero-bottom,
.section,
.contact,
.ministers-page,
.updating-page,
.subpage-footer {
  padding-inline: max(5%, calc((100% - 1320px) / 2));
}

.site::before,
.site::after {
  content: '';
  position: absolute;
  pointer-events: none;
  z-index: 0;
  border-radius: 50%;
}

.site::before {
  width: 680px;
  height: 680px;
  top: 720px;
  left: -240px;
  background: radial-gradient(circle, rgba(0, 166, 230, 0.11) 0%, transparent 65%);
}

.site::after {
  width: 720px;
  height: 720px;
  top: 2300px;
  right: -260px;
  background: radial-gradient(circle, rgba(34, 183, 237, 0.1) 0%, transparent 65%);
}

.site > main,
.site > footer {
  position: relative;
  z-index: 1;
}

.ministries,
.pastors,
.compass,
.book,
.gallery,
.contact {
  content-visibility: auto;
  contain-intrinsic-size: auto 560px;
}

.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 2.5px;
  z-index: 90;
  pointer-events: none;
  background: linear-gradient(90deg, #009bd5 0%, #67d2ff 55%, #c9f1ff 100%);
  box-shadow: 0 0 10px rgba(0, 166, 230, 0.65);
  transform-origin: left center;
  transform: scaleX(var(--scroll-progress, 0));
  opacity: 0;
  transition: opacity 0.2s ease;
}

.scroll-progress.is-active {
  opacity: 1;
}

/* 2. Floating Frosted-Glass Sticky Header & Nav */
.header {
  transition:
    background-color 0.25s var(--fx-ease),
    border-color 0.25s var(--fx-ease),
    box-shadow 0.25s var(--fx-ease),
    height 0.25s var(--fx-ease),
    padding 0.25s var(--fx-ease),
    border-radius 0.25s var(--fx-ease);
}

.header .brand img {
  transition: width 0.25s var(--fx-ease), height 0.25s var(--fx-ease);
}

.header.is-scrolled {
  position: fixed;
  top: 0;
  left: 0 !important;
  width: 100% !important;
  height: 72px;
  padding: 10px max(5%, calc((100% - 1320px) / 2));
  border-radius: 0;
  background: rgba(8, 13, 19, 0.88);
  backdrop-filter: blur(12px) saturate(135%);
  -webkit-backdrop-filter: blur(12px) saturate(135%);
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  z-index: 60;
  animation: headerDockIn 0.22s var(--fx-ease) both;
}

@keyframes headerDockIn {
  from {
    opacity: 0.65;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.header.is-scrolled .brand img {
  width: 104px;
  height: 54px;
}

@media (min-width: 981px) {
  .header nav > a,
  .header .sermons-menu > a {
    position: relative;
    padding-block: 4px;
    transition: color 0.2s ease;
  }

  .header nav > a::after,
  .header .sermons-menu > a::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: -1px;
    height: 1.5px;
    background: linear-gradient(90deg, #00a6e6, #85dbff);
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 0.22s var(--fx-ease);
  }

  .header nav > a:hover::after,
  .header .sermons-menu > a:hover::after,
  .header nav > a.is-active::after,
  .header .sermons-menu > a.is-active::after {
    transform: scaleX(1);
  }

  .header nav > a.is-active,
  .header .sermons-menu > a.is-active {
    color: #85dbff;
  }
}

.submenu-toggle > span {
  transition: transform 0.22s var(--fx-ease), border-color 0.2s ease;
}

.submenu-toggle[aria-expanded='true'] > span {
  transform: rotate(225deg);
  border-color: var(--fx-cyan-bright);
}

.sermons-submenu:not([hidden]) {
  animation: submenuDrop 0.18s var(--fx-ease) both;
}

@keyframes submenuDrop {
  from {
    opacity: 0;
    transform: translateY(-5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.sermons-submenu a {
  transition: color 0.18s ease, transform 0.18s ease;
}

.header nav.open {
  animation: mobileNavIn 0.2s var(--fx-ease) both;
}

@keyframes mobileNavIn {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.language-control select,
.select-wrap select {
  -webkit-appearance: none;
  appearance: none;
}

/* 3. Snappy Hero Layout, Entrance & Particles */
.hero {
  overflow: hidden;
  height: auto;
  min-height: clamp(640px, 92svh, 860px);
}

.hero-heading {
  padding-top: clamp(106px, 11vw, 130px);
}

.hero h1.full-logo-heading {
  width: clamp(230px, 24vw, 310px);
  filter: drop-shadow(0 6px 18px rgba(0, 166, 230, 0.26));
  animation: heroLogoReveal 0.42s var(--fx-ease) 0.08s both;
}

.hero-bottom {
  padding-bottom: clamp(36px, 4.5vw, 56px);
}

.hero-particles {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  pointer-events: none;
}

.hero-bg {
  translate: 0 var(--hero-parallax, 0px);
  transform: scale(1.04);
  will-change: translate;
}

.hero-heading > .eyebrow {
  animation: heroFadeUp 0.38s var(--fx-ease) 0.04s both;
}

@keyframes heroLogoReveal {
  from {
    opacity: 0;
    translate: 0 14px;
    transform: scale(0.97);
  }
  to {
    opacity: 1;
    translate: 0 0;
    transform: scale(1);
  }
}

.hero-heading h2 {
  animation: heroFadeUp 0.38s var(--fx-ease) 0.16s both;
}

@keyframes heroFadeUp {
  from {
    opacity: 0;
    translate: 0 14px;
  }
  to {
    opacity: 1;
    translate: 0 0;
  }
}

.photo-card {
  animation: heroFadeUp 0.38s var(--fx-ease) calc(0.2s + var(--card-i, 0) * 0.04s) both;
  transition: transform 0.22s var(--fx-ease), box-shadow 0.25s ease, opacity 0.25s ease;
}

.photo-card::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(
    circle 120px at var(--mx, 50%) var(--my, 50%),
    rgba(255, 255, 255, 0.24),
    rgba(103, 210, 255, 0.1) 45%,
    transparent 75%
  );
  transition: opacity 0.2s ease;
}

.photo-card img {
  transition: transform 0.35s var(--fx-ease), filter 0.25s ease;
}

.photo-card span {
  transition: transform 0.22s var(--fx-ease);
}

.hero-cta {
  animation: heroFadeUp 0.38s var(--fx-ease) 0.36s both;
}

.hero-social {
  animation: heroFadeUp 0.38s var(--fx-ease) 0.38s both;
}

/* 4. Buttons, Links & Desktop-Only Hover Polish */
.button {
  position: relative;
  overflow: hidden;
  transition:
    background-color 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease,
    transform 0.18s var(--fx-ease),
    box-shadow 0.2s ease;
}

.button:active {
  transform: scale(0.98);
}

.nav-contact,
.back-top,
.inline-link,
.hero-social a {
  transition:
    background-color 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.18s var(--fx-ease);
}

.inline-link {
  position: relative;
  border-bottom-color: rgba(153, 162, 159, 0.38);
}

.inline-link::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1.5px;
  background: linear-gradient(90deg, #00a6e6, #85dbff);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.24s var(--fx-ease);
}

@media (hover: hover) and (pointer: fine) {
  .sermons-submenu a:hover {
    transform: translateX(4px);
  }

  .photo-card {
    transform-style: preserve-3d;
  }

  .photo-card:hover {
    transform: perspective(750px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(-8px) scale(1.02);
    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.55), 0 0 22px rgba(0, 166, 230, 0.34);
  }

  .photo-card:hover::before {
    opacity: 1;
  }

  .photo-card:hover img {
    transform: scale(1.06);
    filter: brightness(0.96);
  }

  .photo-card:hover span {
    transform: translateY(-2px);
  }

  .photo-cards:hover .photo-card:not(:hover) {
    opacity: 0.74;
  }

  .button::before {
    content: '';
    position: absolute;
    top: -20%;
    left: -75%;
    width: 55%;
    height: 140%;
    background: linear-gradient(110deg, transparent 0%, rgba(255, 255, 255, 0.5) 50%, transparent 100%);
    transform: skewX(-20deg);
    transition: left 0.42s var(--fx-ease);
    pointer-events: none;
  }

  .button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 166, 230, 0.24);
  }

  .button:hover::before {
    left: 135%;
  }

  .nav-contact:hover,
  .back-top:hover {
    border-color: #67d2ff;
    background: rgba(0, 166, 230, 0.14);
    color: #fff;
    box-shadow: 0 0 16px rgba(0, 166, 230, 0.28);
    transform: translateY(-1px);
  }

  .inline-link:hover {
    transform: translateX(3px);
  }

  .inline-link:hover::after {
    transform: scaleX(1);
  }

  .hero-social a:hover {
    transform: scale(1.12);
    border-color: #67d2ff;
    color: #67d2ff;
    background: rgba(0, 166, 230, 0.18);
    box-shadow: 0 0 14px rgba(0, 166, 230, 0.45);
  }

  .journey-stop:hover img {
    transform: rotate(0deg) scale(1.03);
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.5);
  }

  .ministry-grid article:hover {
    transform: translateY(-5px);
    border-color: rgba(77, 200, 255, 0.65);
    box-shadow: 0 16px 34px rgba(0, 0, 0, 0.45), 0 0 20px rgba(0, 166, 230, 0.15);
  }

  .ministry-grid article:hover::before {
    opacity: 1;
  }

  .ministry-grid article:hover > span {
    transform: rotate(16deg) scale(1.12);
  }

  .pastors-photo:hover > img {
    transform: scale(1.03);
  }

  .pastors-photo:hover figcaption {
    transform: translateY(-2px);
    color: #fff;
  }

  .iteams-role:hover img {
    transform: scale(1.03);
  }

  .compass-inner:hover {
    border-color: #3f87a6;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4), 0 0 24px rgba(0, 166, 230, 0.12);
  }

  .book-cover:hover {
    transform: perspective(950px) rotateX(var(--rx, 2deg)) rotateY(var(--ry, -4deg)) translateY(-5px);
    box-shadow: -14px 20px 44px rgba(0, 166, 230, 0.2);
  }

  .book-cover:hover::after {
    opacity: 1;
  }

  .book-copy li:hover {
    transform: translateX(4px);
    color: #eef5f7;
  }

  .carousel-buttons button:hover:not(:disabled) {
    border-color: #67d2ff;
    box-shadow: 0 0 12px rgba(0, 166, 230, 0.24);
    transform: translateY(-1px);
  }

  .minister-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.44), 0 0 20px rgba(74, 183, 228, 0.16);
  }

  .minister-card:hover::before {
    opacity: 1;
  }

  .minister-card:hover .minister-monogram {
    transform: scale(1.06);
    border-color: #6ecef5;
    box-shadow: 0 0 16px rgba(110, 206, 245, 0.34);
  }
}

/* 5. Snappy Scroll-Triggered Reveals (GPU-only) */
html.js-fx [data-fx] {
  opacity: 0;
  transition:
    opacity 0.38s var(--fx-ease) var(--fx-delay, 0s),
    translate 0.4s var(--fx-ease) var(--fx-delay, 0s);
}

html.js-fx [data-fx='up'] {
  translate: 0 16px;
}

html.js-fx [data-fx='left'] {
  translate: -18px 0;
}

html.js-fx [data-fx='right'] {
  translate: 18px 0;
}

html.js-fx [data-fx='scale'] {
  translate: 0 14px;
}

html.js-fx [data-fx].is-visible {
  opacity: 1;
  translate: 0 0;
}

html.js-fx .section-title::before,
html.js-fx .section-title::after {
  transform: scaleX(0);
  transition: transform 0.45s var(--fx-ease) 0.06s;
}

html.js-fx .section-title::before {
  transform-origin: right center;
}

html.js-fx .section-title::after {
  transform-origin: left center;
}

html.js-fx .section-title.is-visible::before,
html.js-fx .section-title.is-visible::after {
  transform: scaleX(1);
}

/* 6. About & Journey Timeline */
.brand-highlight {
  display: inline-block;
  vertical-align: bottom;
}

.journey:before {
  background: rgba(179, 182, 179, 0.3);
}

.journey-progress {
  position: absolute;
  left: 49%;
  top: 10px;
  bottom: 20px;
  width: 2px;
  background: linear-gradient(180deg, #00a6e6 0%, #67d2ff 80%, #c6f0ff 100%);
  box-shadow: 0 0 10px rgba(0, 166, 230, 0.72);
  transform-origin: top center;
  transform: scaleY(var(--journey-progress, 0));
  pointer-events: none;
  z-index: 1;
}

.journey-stop:before {
  z-index: 2;
  transition: background-color 0.25s ease, box-shadow 0.28s var(--fx-ease), transform 0.25s var(--fx-ease);
}

.journey-stop.is-lit:before {
  background: #29b5ed;
  transform: scale(1.16);
  box-shadow: 0 0 0 4px rgba(0, 166, 230, 0.24), 0 0 12px rgba(0, 166, 230, 0.8);
}

.journey-stop img {
  transition: transform 0.35s var(--fx-ease), box-shadow 0.3s ease;
}

/* 7. Mission Cards */
.ministry-grid article {
  overflow: hidden;
  border-color: rgba(255, 255, 255, 0.16);
  transition: transform 0.24s var(--fx-ease), border-color 0.24s ease, box-shadow 0.24s ease;
}

.ministry-grid article::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(
    circle 200px at var(--mx, 50%) var(--my, 35%),
    rgba(0, 166, 230, 0.16),
    transparent 70%
  );
  transition: opacity 0.22s ease;
}

.ministry-grid article > * {
  position: relative;
  z-index: 1;
}

.ministry-grid article > span {
  transition: transform 0.3s var(--fx-ease);
}

/* 8. Pastors Portrait */
.pastors-photo {
  border-radius: 6px;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.42);
}

.pastors-photo > img {
  transition: transform 0.45s var(--fx-ease);
}

.pastors-photo figcaption {
  transition: transform 0.28s var(--fx-ease), color 0.25s ease;
}

.iteams-role img {
  transition: transform 0.25s var(--fx-ease);
}

/* 9. OUR COMPASS */
.compass-inner {
  position: relative;
  overflow: hidden;
  transition: border-color 0.28s ease, box-shadow 0.3s ease;
}

.compass-inner::before {
  content: '';
  position: absolute;
  width: 320px;
  height: 320px;
  left: -60px;
  top: 50%;
  transform: translateY(-50%);
  background: radial-gradient(circle, rgba(32, 180, 237, 0.14), transparent 68%);
  pointer-events: none;
}

.compass-emblem {
  overflow: visible;
  filter: drop-shadow(0 0 12px rgba(32, 180, 237, 0.24));
}

.compass-needle {
  transform-box: view-box;
  transform-origin: 50px 50px;
  transform: rotate(var(--compass-angle, 0deg));
  transition: transform 0.32s var(--fx-ease);
}

.compass-scripture em {
  text-shadow: 0 0 16px rgba(50, 185, 238, 0.26);
}

/* 10. Book 3D Tilt */
.book-cover {
  position: relative;
  border-radius: 4px;
  transition: transform 0.24s var(--fx-ease), box-shadow 0.28s ease;
}

.book-cover::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  border-radius: 4px;
  background: radial-gradient(
    circle 180px at var(--mx, 50%) var(--my, 35%),
    rgba(255, 255, 255, 0.22),
    transparent 65%
  );
  transition: opacity 0.22s ease;
}

.book-copy li {
  transition: transform 0.2s var(--fx-ease), color 0.2s ease;
}

/* 11. Gallery Carousel */
.carousel-stage {
  border-radius: 6px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
}

.carousel-stage > img.is-entering {
  animation: slideEnter 0.38s var(--fx-ease) both;
}

@keyframes slideEnter {
  from {
    opacity: 0.4;
    transform: scale(1.025);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.carousel-stage > p.is-entering {
  animation: captionEnter 0.34s var(--fx-ease) 0.04s both;
}

@keyframes captionEnter {
  from {
    opacity: 0;
    translate: 0 8px;
  }
  to {
    opacity: 1;
    translate: 0 0;
  }
}

.carousel-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  background: rgba(255, 255, 255, 0.12);
  z-index: 3;
  pointer-events: none;
}

.carousel-progress-bar {
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, #009bd5, #67d2ff);
  transform-origin: left center;
  animation: carouselCountdown 6s linear infinite;
}

.carousel.is-paused .carousel-progress-bar {
  animation-play-state: paused;
}

@keyframes carouselCountdown {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

.carousel-dots button {
  transition: width 0.25s var(--fx-ease), background-color 0.2s ease, box-shadow 0.2s ease;
}

.carousel-dots button[aria-current='true'] {
  width: 24px;
  border-radius: 99px;
  box-shadow: 0 0 10px rgba(0, 166, 230, 0.6);
}

.carousel-buttons button {
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.18s var(--fx-ease);
}

.carousel-buttons button:active:not(:disabled) {
  transform: scale(0.97);
}

/* 12. Contact Section & White-on-Blue Statement Highlight */
.contact {
  overflow: hidden;
}

.contact-bg {
  translate: 0 var(--contact-parallax, 0px);
  transform: scale(1.04);
}

.contact-glass {
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.contact-glass:focus-within {
  border-color: rgba(103, 210, 255, 0.45);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.32), 0 0 22px rgba(0, 166, 230, 0.16);
}

.select-wrap select,
.contact-glass textarea {
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.select-wrap select:focus,
.contact-glass textarea:focus {
  border-bottom-color: #67d2ff;
  box-shadow: 0 2px 0 -1px rgba(103, 210, 255, 0.6);
}

#copy-message.is-copied {
  background: #c8f3ff;
  border-color: #67d2ff;
  color: #042130;
  animation: copyPulse 0.5s var(--fx-ease);
}

@keyframes copyPulse {
  0% {
    box-shadow: 0 0 0 0 rgba(103, 210, 255, 0.68);
  }
  100% {
    box-shadow: 0 0 0 14px rgba(103, 210, 255, 0);
  }
}

.contact-statement {
  display: block;
}

.contact-statement p {
  display: inline;
  color: #ffffff;
  background: linear-gradient(95deg, rgba(0, 155, 213, 0.94), rgba(0, 134, 198, 0.88));
  padding: 0.06em 0.26em 0.1em;
  border-radius: 4px;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
  line-height: 1.5;
  text-shadow: 0 2px 8px rgba(0, 18, 32, 0.35);
  box-shadow: 0 8px 24px rgba(0, 155, 213, 0.28);
}

.contact-statement > span {
  display: block;
  width: fit-content;
  color: #ffffff;
  background: rgba(0, 155, 213, 0.34);
  border: 1px solid rgba(77, 200, 255, 0.72);
  border-left: 3px solid #00a6e6;
  padding: 6px 14px;
  border-radius: 4px;
  margin-top: 22px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.45);
}

/* 13. Subpages */
.minister-card {
  position: relative;
  overflow: hidden;
  transition: transform 0.24s var(--fx-ease), background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.24s ease;
}

.minister-card::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(
    circle 220px at var(--mx, 50%) var(--my, 35%),
    rgba(74, 183, 228, 0.16),
    transparent 70%
  );
  transition: opacity 0.22s ease;
}

.minister-card > * {
  position: relative;
  z-index: 1;
}

.minister-monogram,
.profile-monogram {
  transition: transform 0.25s var(--fx-ease), border-color 0.2s ease, box-shadow 0.22s ease;
}

.updating-status {
  color: #4dc8ff;
  text-shadow: 0 0 22px rgba(0, 166, 230, 0.35);
}

/* 14. Responsive Breakpoints (Tablet & Mobile) */
@media (max-width: 980px) {
  .header.is-scrolled nav.open {
    top: 76px;
    max-height: calc(100dvh - 96px);
    overflow-y: auto;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.55);
  }

  .hero-bottom {
    flex-wrap: wrap;
    gap: 18px;
  }

  .photo-cards {
    width: 100%;
    max-width: 100%;
  }

  .hero-cta {
    display: inline-flex;
    width: 100%;
    min-width: 0;
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .about-copy {
    gap: 24px;
    padding-bottom: 0;
  }

  .about-copy p {
    max-width: none;
  }
}

@media (max-width: 860px) {
  .pastors-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .pastors-photo {
    height: clamp(360px, 58vw, 500px);
    min-height: 0;
  }

  .contact {
    min-height: auto;
    padding-top: 52px;
  }

  .contact-content {
    grid-template-columns: 1fr;
    gap: 32px;
    padding-bottom: 44px;
  }

  .contact-glass {
    max-width: 100%;
  }

  .contact-statement {
    margin-top: 6px;
  }

  .contact-statement p {
    font-size: clamp(1.5rem, 4.2vw, 2.2rem);
  }
}

@media (max-width: 820px) {
  .book-grid {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 5px 0 0;
  }
}

@media (max-width: 620px) {
  html {
    scroll-padding-top: 84px;
  }

  .header.is-scrolled {
    top: 0;
    height: 64px;
    padding: 8px 5%;
    border-radius: 0;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
  }

  .header.is-scrolled .brand img {
    width: 92px;
    height: 50px;
  }

  .header.is-scrolled nav.open {
    top: 64px;
    max-height: calc(100dvh - 74px);
    border-radius: 0 0 12px 12px;
  }

  .language-control select {
    max-width: 124px;
    white-space: nowrap;
  }

  .hero {
    height: auto;
    min-height: min(740px, 94svh);
  }

  .hero-heading {
    padding-top: 106px;
  }

  .hero h1.full-logo-heading {
    width: min(215px, 62vw);
    margin-top: 16px;
  }

  .photo-cards {
    gap: 10px;
    -webkit-overflow-scrolling: touch;
  }

  .photo-card {
    width: 122px;
    min-width: 122px;
    height: 152px;
  }

  .journey:before,
  .journey-progress {
    left: 10px;
  }

  .journey-stop,
  .journey-stop:nth-child(2) {
    grid-template-columns: 1fr;
    gap: 12px;
    min-height: auto;
    padding-left: 30px;
    direction: ltr;
  }

  .journey-stop:before {
    left: 4px;
    top: 6px;
  }

  .journey-stop img,
  .journey-stop:nth-child(2) > img {
    height: 185px;
    transform: none;
    border-radius: 6px;
  }

  .contact-statement {
    display: block !important;
    margin-top: 10px;
  }

  .contact-statement p {
    font-size: clamp(1.35rem, 6.2vw, 1.85rem);
    line-height: 1.55;
  }

  .contact-statement > span {
    margin-top: 16px;
    font-size: 0.625rem;
    letter-spacing: 0.15em;
  }
}

@media (max-width: 420px) {
  .ministry-grid {
    grid-template-columns: 1fr;
  }
}

/* 15. Reduced Motion Accessibility */
@media (prefers-reduced-motion: reduce) {
  .scroll-progress,
  .hero-particles,
  .carousel-progress {
    display: none !important;
  }

  html.js-fx [data-fx] {
    opacity: 1 !important;
    translate: none !important;
  }

  html.js-fx .section-title::before,
  html.js-fx .section-title::after {
    transform: none !important;
  }

  .hero-bg,
  .contact-bg,
  .compass-needle {
    translate: none !important;
    transform: none !important;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
