/* ============================
   LBC PASTORS PAGE - Mobile First
   Matches beliefs page design language
   
   VERSION: 1.3.3 - FIXED
   - Flexible image height (no cropping)
   - Accent frame properly follows image size
   ============================ */

/* =====================
   GLOBAL RESETS
   ===================== */
*, *::before, *::after {
  box-sizing: border-box;
}

html, body {
  max-width: 100vw;
  overflow-x: hidden;
}

/* =====================
   CONTAINER
   ===================== */
.container {
  width: 100%;
  max-width: 1120px;
  margin-inline: auto;
  padding-inline: 1rem;
}

/* =====================
   BUTTONS
   ===================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.75rem 1.5rem;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 2px solid transparent;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--lbc-gold), #facc6b);
  color: var(--lbc-navy);
  border-color: transparent;
  box-shadow: 0 4px 15px rgba(208, 167, 95, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(208, 167, 95, 0.4);
  filter: brightness(1.05);
}

.btn-outline {
  background: transparent;
  border-color: var(--lbc-navy);
  color: var(--lbc-navy);
}

.btn-outline:hover {
  background: var(--lbc-navy);
  color: #fff;
}

/* =====================
   1. HERO SECTION
   HERO SPACING MOVED TO lbc-overrides.css
   ===================== */
.pastors-hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  color: #fff;
  background: linear-gradient(135deg, #0b1021 0%, #1e293b 50%, #0b1021 100%);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: rgba(11, 16, 33, 0.6);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 800px;
  width: 100%;
}

.hero-kicker {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--lbc-gold);
  margin-bottom: 1rem;
  padding: 0.4rem 1rem;
  border: 1px solid rgba(208, 167, 95, 0.4);
  border-radius: 999px;
}

.hero-title {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 700;
  margin: 0 0 1rem;
  line-height: 1.15;
  color: #fff;
}

.hero-lead {
  font-size: 1rem;
  line-height: 1.7;
  color: #e5e7eb;
  margin: 0 0 1.5rem;
  padding: 0 0.5rem;
}

.hero-verse {
  background: rgba(255, 255, 255, 0.05);
  border-left: 3px solid var(--lbc-gold);
  padding: 1rem;
  margin: 0 auto;
  max-width: 600px;
  text-align: left;
  border-radius: 0 0.5rem 0.5rem 0;
}

.hero-verse p {
  font-size: 1rem;
  font-style: italic;
  color: #facc6b;
  margin: 0 0 0.5rem;
  line-height: 1.6;
}

.verse-ref {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.7);
  font-style: normal;
  font-weight: 600;
}

/* =====================
   2. PASTOR SECTIONS
   ===================== */
.pastor-section {
  padding: 3rem 0;
  background: #fff;
}

.pastor-section--alt {
  background: var(--lbc-cream);
}

.pastor-card {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

/* =====================
   IMAGE FRAME - FIXED VERSION
   
   Key changes:
   - .image-frame uses display: inline-block to wrap tightly around image
   - .pastor-photo uses height: auto for natural aspect ratio
   - .image-accent positioned relative to the actual image size
   ===================== */
.pastor-image {
  width: 100%;
  text-align: center; /* Centers the inline-block frame */
}

.image-frame {
  position: relative;
  display: inline-block; /* KEY FIX: Shrinks to fit the image */
  max-width: 400px;
}

.pastor-photo {
  display: block;
  width: 100%;
  height: auto;           /* FIXED: Natural aspect ratio */
  max-height: 550px;      /* Safety limit */
  object-fit: contain;    /* FIXED: No cropping */
  border-radius: var(--radius-lg);
  position: relative;
  z-index: 2;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

.image-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  width: 100%;
  min-height: 300px;
  background: linear-gradient(135deg, #e5e7eb 0%, #f3f4f6 100%);
  border-radius: var(--radius-lg);
  position: relative;
  z-index: 2;
  color: #9ca3af;
  font-family: var(--font-heading);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  border: 2px dashed #d1d5db;
}

/* Gold accent frame - now properly follows image size */
.image-accent {
  position: absolute;
  top: 12px;
  left: 12px;
  right: -12px;
  bottom: -12px;
  border: 2px solid var(--lbc-gold);
  border-radius: var(--radius-lg);
  z-index: 1;
  pointer-events: none; /* Prevents interfering with clicks */
}

/* PASTOR CONTENT */
.pastor-content {
  text-align: center;
}

.pastor-role {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--lbc-gold);
  margin-bottom: 0.5rem;
}

.pastor-name {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--lbc-navy);
  margin: 0 0 0.25rem;
  line-height: 1.2;
}

.pastor-family {
  font-size: 1rem;
  color: var(--lbc-text-soft);
  font-style: italic;
  margin: 0 0 1.5rem;
}

.pastor-bio {
  text-align: left;
  margin-bottom: 1.5rem;
}

.pastor-bio p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--lbc-text-soft);
  margin: 0 0 1rem;
}

.pastor-bio p:last-child {
  margin-bottom: 0;
}

/* PASTOR META */
.pastor-meta {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.25rem 0;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  margin-bottom: 1.5rem;
}

.meta-item {
  display: flex;
  flex-direction: column;
  text-align: center;
}

.meta-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--lbc-gold);
  margin-bottom: 0.25rem;
}

.meta-value {
  font-size: 0.95rem;
  color: var(--lbc-navy);
  font-weight: 600;
}

.meta-link {
  color: var(--lbc-navy);
  text-decoration: underline;
  text-decoration-color: rgba(11, 16, 33, 0.2);
  text-underline-offset: 3px;
  transition: all 0.2s;
}

.meta-link:hover {
  color: var(--lbc-gold);
  text-decoration-color: var(--lbc-gold);
}

/* PASTOR ACTIONS */
.pastor-actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.pastor-actions .btn {
  width: 100%;
  max-width: 280px;
  margin: 0 auto;
}

/* =====================
   3. CTA SECTION
   ===================== */
.cta-section {
  padding: 3rem 0 4rem;
  background: var(--lbc-cream);
  border-top: 1px solid rgba(148, 163, 184, 0.15);
}

.cta-content {
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
  padding: 2rem 1.5rem;
  background: #fff;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(148, 163, 184, 0.2);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.cta-title {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 1rem;
  color: var(--lbc-navy);
}

.cta-text {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--lbc-text-soft);
  margin: 0 0 1.5rem;
}

.cta-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.cta-buttons .btn {
  width: 100%;
  max-width: 280px;
  margin: 0 auto;
}

/* =====================
   TABLET+ (641px and up)
   ===================== */
@media (min-width: 641px) {
  .container {
    padding-inline: 1.5rem;
  }

  /* HERO PADDING MOVED TO lbc-overrides.css */

  .hero-title {
    font-size: clamp(2.25rem, 5vw, 3rem);
  }

  .hero-lead {
    font-size: 1.1rem;
  }

  .hero-verse {
    padding: 1.5rem;
  }

  .hero-verse p {
    font-size: 1.1rem;
  }

  /* Pastor Sections */
  .pastor-section {
    padding: 4rem 0;
  }

  .pastor-card {
    gap: 2.5rem;
  }

  .pastor-name {
    font-size: 2rem;
  }

  .pastor-meta {
    flex-direction: row;
    justify-content: center;
    gap: 3rem;
  }

  .meta-item {
    text-align: left;
  }

  .pastor-actions {
    flex-direction: row;
    justify-content: center;
  }

  .pastor-actions .btn {
    width: auto;
    max-width: none;
    margin: 0;
  }

  /* CTA */
  .cta-section {
    padding: 4rem 0 5rem;
  }

  .cta-content {
    padding: 3rem;
  }

  .cta-title {
    font-size: 1.75rem;
  }

  .cta-buttons {
    flex-direction: row;
    justify-content: center;
    gap: 1rem;
  }

  .cta-buttons .btn {
    width: auto;
    max-width: none;
    margin: 0;
  }
}

/* =====================
   DESKTOP (900px and up)
   ===================== */
@media (min-width: 900px) {
  /* Pastor Cards - Side by side layout */
  .pastor-card {
    display: grid;
    grid-template-columns: 1fr 1.3fr;
    gap: 4rem;
    align-items: start;
  }

  .pastor-card--reverse {
    grid-template-columns: 1.3fr 1fr;
  }

  .pastor-card--reverse .pastor-image {
    order: 2;
  }

  .pastor-card--reverse .pastor-content {
    order: 1;
  }

  .image-frame {
    position: sticky;
    top: 120px;
    max-width: none;
  }


  .pastor-content {
    text-align: left;
    padding-top: 0.5rem;
  }

  .pastor-meta {
    justify-content: flex-start;
  }

  .pastor-actions {
    justify-content: flex-start;
  }
}

/* =====================
   LARGE DESKTOP (1100px+)
   ===================== */
@media (min-width: 1100px) {
  .pastor-section {
    padding: 5rem 0;
  }

  .pastor-card {
    gap: 5rem;
  }


  .pastor-name {
    font-size: 2.5rem;
  }

  .pastor-bio p {
    font-size: 1.05rem;
  }
}
