/* ================================
   GLOBAL SECTIONS & WRAPPERS
================================= */
.section-padding {
  padding: 70px 0;
  opacity: 0;
  transform: translateY(40px);
  transition: all 0.8s ease;
}
.section-padding.visible {
  opacity: 1;
  transform: translateY(0);
}

.wrap {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

.section-title, .section h2 {
  font-size: 2.2rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 50px;
  color: #111;
  opacity: 0;
  transform: translateY(30px);
  transition: 0.6s ease;
}
.section-title.visible, .section h2.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ================================
   BUTTONS
================================= */
.btn {
  display: inline-block;
  padding: 10px 22px;
  margin-top:30px;
  border-radius: 6px;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  transition: 0.25s ease-in-out;
  cursor: pointer;
  align-self: center;
}

.btn-outline {
  border: 2px solid #1352f1;
  color: #1352f1;
  transition: 0.3s ease;
}

/* ✅ Glow hover */
.btn-outline:hover {
  background: #1352f1;
  color: #fff;
  box-shadow: 0 0 15px rgba(19,82,241,0.6);
}

/* ================================
   HERO SLIDER
================================= */
.hero-slider {
  position: relative;
  height: 520px;
  overflow: hidden;
}

.hero-slider .slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1s ease-in-out;
}
.hero-slider .slide.active { opacity: 1; }

.hero-text {
  position: absolute;
  left: 5%;
  bottom: 8%;
  color: #fff;
  max-width: 55%;
}

.hero-text h1 {
  font-size: 48px;
  line-height: 1.02;
  font-weight: 700;
  text-shadow: 0 6px 22px rgba(0,0,0,.45);
}
.hero-text p {
  font-size: 18px;
  margin-bottom: 16px;
  text-shadow: 0 4px 14px rgba(0,0,0,.35);
}

/* ================================
   QUICK INFO CARDS
================================= */
.quick-info {
  display: flex;
  gap: 28px;
  justify-content: space-between;
  padding: 36px 0;
  align-items: center;
  opacity: 0;
  transform: translateY(40px);
  transition: 0.8s ease;
}
.quick-info.visible {
  opacity: 1;
  transform: translateY(0);
}

.qi-item {
  flex: 1;
  text-align: center;
  background: #fff;
  border-radius: 10px;
  padding: 18px;
  box-shadow: 0 2px 10px rgba(0,0,0,.06);
  transition: transform .3s ease, box-shadow .3s ease;
}

/* ✅ Zoom hover */
.qi-item:hover {
  transform: scale(1.05);
  box-shadow: 0 8px 25px rgba(0,0,0,.1);
}

.qi-item i {
  font-size: 44px;
  margin-bottom: 8px;
  color: #0b5e4f;
}

.qi-item h4 {
  margin: 6px 0 4px;
  color: #0b5e4f;
  font-weight: 700;
}

.qi-item p {
  color: #555;
  font-size: 14px;
}

/* ================================
   SPLIT SECTIONS (About, Leadership)
================================= */
.section-split {
  display: flex;
  gap: 30px;
  align-items: center;
  padding: 60px 0;
  flex-wrap: wrap;
  opacity: 0;
  transform: translateY(50px);
  transition: all .8s ease;
}
.section-split.visible {
  opacity: 1;
  transform: translateY(0);
}

.section-split.reverse { flex-direction: row-reverse; }

.section-split .image-side {
  flex: 1;
  min-height: 300px;
  background-size: cover;
  background-position: center;
  border-radius: 12px;
  animation: crossfade 8s infinite alternate ease-in-out;
}

/* ✅ Crossfade background */
@keyframes crossfade {
  0% { filter: brightness(.9) contrast(1); }
  100% { filter: brightness(1.1) contrast(1.1) }
}

.section-split .text-side {
  flex: 1;
  padding: 12px;
  text-align:center;
}

.section-split h2 {
  font-size: 28px;
  color: #344c7e;
  margin-bottom: 12px;
}

.section-split p {
  color: #333;
  line-height: 1.7;
}

/* ================================
   QUOTE SECTION
================================= */
.quote-section {
  background: #f7f9f9;
  padding: 40px 0;
  text-align: center;
}

.quote-section blockquote {
  font-size: 22px;
  color: #0b5e4f;
  max-width: 900px;
  margin: 0 auto;
  font-style: italic;
}

/* ================================
   LATEST SERMONS (DB)
================================= */
.latest-sermons {
  background: #f8fafc;
}

.sermon-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 35px;
}

.sermon-card {
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
  transition: transform 0.25s ease;
  opacity: 0;
  transform: translateY(40px);
}
.sermon-card.visible {
  opacity: 1;
  transform: translateY(0);
}

.sermon-card:hover { transform: translateY(-6px) scale(1.03); }

.sermon-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.sermon-details {
  padding: 20px;
}

.sermon-details h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.sermon-details .meta {
  font-size: 0.9rem;
  color: #777;
  margin-bottom: 15px;
}

/* ================================
   UPCOMING EVENTS (DB)
================================= */
.upcoming-events {
  background: #fff;
}

.event-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 35px;
}

.event-card {
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
  transition: transform 0.25s ease;
  opacity: 0;
  transform: translateY(40px);
}
.event-card.visible {
  opacity: 1;
  transform: translateY(0);
}

.event-card:hover { transform: translateY(-6px) scale(1.03); }

.event-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.event-info {
  padding: 20px;
}

.event-info h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.event-info p {
  color: #777;
  font-size: 0.9rem;
  margin-bottom: 15px;
}

/* ================================
   JOIN MINISTRY
================================= */
.join-ministry {
  position: relative;
  color: #fff;
  padding: 80px 0;
  overflow: hidden;
}

.join-ministry .jm-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: brightness(.45);
}

.join-ministry h2 { color:#fff; }

.join-ministry .content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 40px 20px;
}

.jm-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
  margin-top: 40px;
}

.jm-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: 140px;
  padding: 18px 10px;
  background: #ffffff;
  border: 2px solid #354e78;
  border-radius: 10px;
  color: #354e78;
  font-weight: 600;
  transition: all .3s ease;
}

.jm-btn i {
  font-size: 32px;
  margin-bottom: 8px;
  opacity: .9;
}

.jm-btn:hover {
  background: #354e78;
  color: #fff;
  transform: translateY(-4px) scale(1.05);
  box-shadow: 0 8px 20px rgba(53,78,120,.4);
}

.jm-btn:hover i { color: #fff; }

/* ✅ Mobile responsiveness */
@media (max-width: 600px) {
  .jm-btn {
    width: 48%;
    padding: 14px 6px;
  }
  .jm-buttons { gap: 12px; }
}

/* ================================
   NEXT STEPS
================================= */
.next-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(220px,1fr));
  gap: 18px;
  padding: 40px 0;
}

.next-steps .step {
  position: relative;
  color: #fff;
  border-radius: 10px;
  overflow: hidden;
  min-height: 180px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 16px;
}

.next-steps .step .step-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: brightness(.35);
  z-index: 0;
}

.step p {
  color:#fff;
  text-align:center;
  position: relative;
  padding: 2px;
  margin-top: 10px;
}

.step h3 {
  color: #fff;
  top:25px;
  text-align:center;
  position: relative;
  padding: 10px;
  margin-bottom: 15px;
}

/* ================================
   RESPONSIVE
================================= */
@media (max-width: 768px) {
  .hero-text h1 { font-size: 28px; }
  .section-title { font-size: 1.8rem; }
  .section-split { flex-direction: column; }
}


/* =========================================
   MOBILE RESPONSIVE FIXES
   ========================================= */
@media (max-width: 768px) {

  /* General */
  .wrap {
    width: 94%;
  }

  section.section-padding {
    padding: 45px 0;
  }

  .section-title, .section h2 {
    font-size: 1.65rem;
    margin-bottom: 30px;
  }

  /* Hero Text */
  .hero-text {
    max-width: 90%;
    bottom: 15%;
  }

  .hero-text h1 {
    font-size: 26px !important;
    line-height: 1.2;
  }

  .hero-text p {
    font-size: 15px;
  }

  /* Quick Info Icons */
  .quick-info {
    flex-direction: column;
    gap: 16px;
  }

  .qi-item {
    width: 100%;
  }

  /* Split Sections (About, Leadership, Inspiring Teaching) */
  .section-split,
  .section-split.reverse {
    flex-direction: column !important;
    text-align: center;
  }

  .section-split .image-side {
    width: 100%;
    height: 240px;
    border-radius: 10px;
    background-size: cover !important;
    background-position: center !important;
    order: 1;
  }

  .section-split.reverse .image-side {
    order: 1; /* Fix leadership wrong order */
  }

  .section-split .text-side {
    width: 100%;
    order: 2;
    padding: 15px 5px;
  }

  .section-split h2 {
    font-size: 22px;
  }

  .section-split p {
    font-size: 15px;
    line-height: 1.55;
  }

  /* Sermons Grid */
  .sermon-grid {
    grid-template-columns: 1fr;
  }

  .sermon-card img {
    height: 180px;
  }

  /* Events Grid */
  .event-grid {
    grid-template-columns: 1fr;
  }

  .event-card img {
    height: 180px;
  }

  /* Join Ministry Buttons */
  .jm-btn {
    width: 48% !important;
    padding: 14px;
    font-size: 13px;
  }

  .jm-btn i {
    font-size: 28px;
  }

  /* Next Steps */
  .next-steps {
    grid-template-columns: 1fr;
  }

  .step {
    min-height: 160px;
  }
}

/* Extra Small Screens */
@media (max-width: 480px) {
  .hero-text h1 {
    font-size: 22px;
  }

  .qi-item i {
    font-size: 36px;
  }

  .jm-btn {
    width: 100% !important;
  }
}