* {
  box-sizing: border-box;
}

:root {
  --firebird: #BE5103;
  --firebird-dark: #8f3d02;
  --text: #333;
  --muted: #555;
  --line: #eee;
  --soft-bg: #fafafa;
  --footer: #BE5103;
  --green: #2f8f46;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 150px;
}

body {
  margin: 0;
  font-family: 'Inter', Arial, sans-serif;
  color: var(--text);
  background: #fff;
  line-height: 1.7;
}

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

a {
  color: inherit;
}

main {
  background: #fff;
}

.page-section {
  width: 100%;
  padding: 90px 20px;
  background: #fff;
}

.subtle-section {
  background: var(--soft-bg);
}

.container {
  max-width: 1100px;
  margin: 0 auto;
}

.container.narrow {
  max-width: 850px;
}

h1,
h2,
h3 {
  margin-top: 0;
  line-height: 1.2;
  color: #222;
}

h1 {
  font-size: clamp(2.3rem, 5vw, 4rem);
}

h2 {
  font-size: clamp(1.7rem, 3vw, 2.3rem);
  margin-bottom: 20px;
  color: var(--firebird);
}

h3 {
  font-size: 1.2rem;
  margin-bottom: 8px;
}

p {
  margin-top: 0;
}

.section-intro,
.page-subtitle {
  max-width: 720px;
  color: var(--muted);
  margin-bottom: 34px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #fff;
  border-bottom: 1px solid #ddd;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.header-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: 64px;
  text-decoration: none;
}

.brand img {
  max-height: 114px;
  width: auto;
}

.brand strong {
  font-size: 1.35rem;
  color: #222;
}

.brand span {
  display: block;
  color: #666;
  font-size: 0.95rem;
}

.header-info {
  text-align: right;
  color: var(--muted);
  font-size: 0.95rem;
}

.header-info a {
  color: var(--firebird);
  text-decoration: none;
}

.nav-row {
  max-width: 1100px;
  margin: 0 auto;
  padding: 10px 20px;
  display: flex;
  justify-content: flex-end;
  gap: 6px;
  flex-wrap: wrap;
  border-top: 1px solid var(--line);
}

.nav-row a {
  color: var(--muted);
  text-decoration: none;
  padding: 7px 11px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  font: inherit;
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.text-button {
  color: var(--muted);
  text-decoration: none;
  padding: 10px 16px;
  border: 1px solid #d6d6d6;
  border-radius: 6px;
  background: #fff;
  display: inline-block;
  font: inherit;
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.nav-row a:hover {
  color: var(--firebird);
  border-color: rgba(190, 81, 3, 0.25);
  background: rgba(190, 81, 3, 0.06);
}

.text-button:hover {
  color: var(--firebird);
  border-color: rgba(190, 81, 3, 0.35);
  background: rgba(190, 81, 3, 0.06);
}

.giving-link {
  color: var(--green) !important;
  border-color: rgba(47, 143, 70, 0.3) !important;
}

.giving-link:hover {
  color: var(--green) !important;
  border-color: #b9dfc4 !important;
  background: #f3fbf5 !important;
}

.carousel-section {
  padding: 0;
  position: relative;
  overflow: hidden;
  background: #111;
}

.carousel {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

.carousel::-webkit-scrollbar {
  display: none;
}

.slide {
  min-width: 100%;
  height: 540px;
  max-height: 70vh;
  position: relative;
  scroll-snap-align: start;
  flex-shrink: 0;
  display: block;
}

.slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%) translate(1px);
  z-index: 5;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.86);
  color: #333;
  font-size: 2.4rem;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
  display:flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
  padding: 0;
}

.carousel-btn:hover {
  background: var(--firebird);
  color: #fff;
}

.prev {
  left: 20px;
}

.next {
  right: 20px;
}

.carousel-dots {
  position: absolute;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 5;
  display: flex;
  gap: 8px;
}

.dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.6);
  cursor: pointer;
}

.dot.active {
  background: #fff;
}

.info-grid,
.card-grid {
  display: grid;
  gap: 28px;
  margin-top: 34px;
}

.info-grid,
.three-col,
.staff-grid {
  grid-template-columns: repeat(3, 1fr);
}

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 26px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.045);
}

.image-card img {
  border-radius: 10px;
  margin-bottom: 18px;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.media-grid {
  text-align: center;
  padding: 20px 0 30px;
}

.media-item {
  display: inline-block;
  max-width: 760px;
}

.media-item img {
  width: 100%;
  border-radius: 14px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.06);
}

.staff-card {
  text-align: center;
}

.staff-photo {
  width: 300px;
  height: 300px;
  max-width: 100%;
  margin: 0 auto 18px;
  border-radius: 10px;
  object-fit: cover;
}

.staff-title,
.ministry-meta {
  font-weight: 700;
  color: var(--firebird);
  margin-bottom: 10px;
}

.group-heading {
  margin-top: 48px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  color: #333;
}

.fade-in {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0,0,0,0.65);
  padding: 20px;
}

.modal.is-open {
  display: block;
}

.modal-content {
  background: #fff;
  max-width: 650px;
  margin: 80px auto;
  padding: 34px;
  border-radius: 14px;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 16px;
  border: none;
  background: transparent;
  font-size: 1.6rem;
  cursor: pointer;
  color: var(--muted);
}

.ministries-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 26px;
  margin-top: 30px;
}

.ministry-card {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  background: #fff;
  border: 1px solid #e9e9e9;
  border-radius: 14px;
  padding: 24px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.045);
}

.ministry-content h3 {
  margin-bottom: 6px;
}

footer {
  background: var(--footer);
  color: #eee;
  padding: 64px 20px;
}

footer h2 {
  color: #fff;
}

footer a {
  color: #fff;
}

.footer-grid {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 34px;
  align-items: center;
}

footer img {
  border-radius: 12px;
  width: 100%;
}

#topBtn {
  display: none;
  position: fixed;
  bottom: 22px;
  right: 22px;
  z-index: 1500;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: none;
  background: #eee;
  color: #333;
  font-size: 1.2rem;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.18);
}

#topBtn:hover {
  background: var(--firebird);
  color: #fff;
}

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

  .header-info {
    text-align: left;
  }

  .nav-row {
    justify-content: flex-start;
  }
}

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

  .page-section {
    padding: 70px 18px;
  }

  .header-inner {
    align-items: flex-start;
  }

  .brand {
    align-items: flex-start;
  }

  .brand img {
    max-height: 66px;
  }

  .slide {
    height: 420px;
    max-height: none;
  }

  .carousel-btn {
    width: 40px;
    height: 40px;
    font-size: 1.45rem;
  }

  .info-grid,
  .three-col,
  .staff-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .staff-photo {
    width: 260px;
    height: 260px;
  }

  .modal-content {
    margin: 50px auto;
  }
}

@media (max-width: 460px) {
  .slide {
    height: 380px;
  }

  .nav-row a {
    font-size: 0.92rem;
  }

  .staff-photo {
    width: 220px;
    height: 220px;
  }
}
