/* South African itinerary refinements. The Kenya reference pages are untouched.
   The shared Classic Cape component supplies typography and responsive layout. */

#itinerary.ame-sa-editorial .classic-chapter__header h3 {
  line-height: .98;
}

#itinerary.ame-sa-editorial .classic-chapter__header small {
  margin-top: clamp(28px, 2.3vw, 40px);
}

/* Remove the former sidebar layout's offsets while retaining each chapter's
   palette and the shared component's centered width and vertical rhythm. */
#itinerary.ame-sa-editorial :is(
  .kruger-chapter--lowveld,
  .victoria-chapter--lowveld,
  .victoria-chapter--zambezi
) {
  margin-inline: auto;
  padding-inline: 0;
}

/* Full-width chapter pauses use the same frame as the Kenya benchmark.
   Existing image object positions remain specific to each photograph. */
#itinerary.ame-sa-editorial :is(.classic-transition, .honeymoon-chapter-divider) {
  width: 100%;
  min-height: clamp(580px, 78vh, 920px);
  margin: 0;
}

#itinerary.ame-sa-editorial .classic-transition__copy {
  max-width: min(calc(100% - 96px), var(--classic-max, 1680px));
  white-space: normal;
}

/* These existing dividers retain their labelled h3 for accessibility. */
#itinerary.ame-sa-editorial .honeymoon-chapter-divider .classic-transition__copy {
  left: max(48px, calc((100vw - var(--classic-max, 1680px)) / 2));
  right: 48px;
  bottom: clamp(64px, 10vh, 120px);
}

#itinerary.ame-sa-editorial .classic-transition__copy > h3 {
  margin: 10px 0 0;
  font: 400 clamp(4rem, 8.7vw, 10.5rem)/.79 "Cormorant Garamond", serif;
  letter-spacing: -.055em;
}

#itinerary.ame-sa-editorial .honeymoon-chapter-divider .classic-transition__copy > span {
  margin-bottom: 0;
  color: rgba(255, 255, 255, .72);
  font: 500 clamp(11px, .9vw, 14px)/1.3 "Inter", sans-serif;
}

@media (max-width: 640px) {
  #itinerary.ame-sa-editorial .classic-chapter__header small {
    margin-top: 24px;
  }

  #itinerary.ame-sa-editorial :is(.classic-transition, .honeymoon-chapter-divider) {
    min-height: 72svh;
  }

  #itinerary.ame-sa-editorial .classic-transition__copy {
    left: 20px;
    right: 20px;
    max-width: none;
    white-space: normal;
  }

  #itinerary.ame-sa-editorial :is(.victoria-transition, .kruger-transition) .classic-transition__copy {
    bottom: 124px;
  }

  #itinerary.ame-sa-editorial .honeymoon-chapter-divider .classic-transition__copy {
    left: 20px;
    right: 20px;
    bottom: 124px;
  }

  #itinerary.ame-sa-editorial .classic-transition__copy > :is(strong, h3) {
    font-size: clamp(3.3rem, 18vw, 5.8rem);
    line-height: .9;
    text-wrap: balance;
  }
}
