/* ==========================================================================
   Himalayan Trails — trek detail page
   ========================================================================== */

.ht-trek-hero {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: flex-end;
  min-height: clamp(20rem, 16rem + 18vh, 30rem);
  padding-block: clamp(3rem, 2rem + 6vw, 5rem);
  color: var(--ht-text-inverse);
  background: var(--ht-pine-950);
  overflow: hidden;
}

.ht-trek-hero__media {
  position: absolute;
  inset: 0;
  z-index: -1;
}

.ht-trek-hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ht-trek-hero__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgb(11 22 17 / 0.6) 0%, rgb(11 22 17 / 0.2) 38%, rgb(11 22 17 / 0.82) 100%);
}

.ht-trek-hero__inner {
  position: relative;
  width: 100%;
}

.ht-trek-hero__title {
  margin-top: var(--ht-space-2);
  max-width: 20ch;
  font-family: var(--ht-font-display);
  font-size: var(--ht-display-2);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.ht-trek-hero__subtitle {
  margin-top: var(--ht-space-3);
  max-width: 52ch;
  font-size: var(--ht-text-lg);
  color: rgb(242 239 232 / 0.85);
}

.ht-breadcrumbs--inverse ol {
  color: rgb(242 239 232 / 0.7);
  /* Clears the eyebrow that follows it; without this the two collide. */
  margin-bottom: var(--ht-space-5);
}

.ht-breadcrumbs--inverse li + li::before {
  color: rgb(242 239 232 / 0.4);
}

.ht-breadcrumbs--inverse [aria-current="page"] {
  color: var(--ht-text-inverse);
}

.ht-breadcrumbs--inverse a:hover {
  color: var(--ht-clay-400);
}

/* ---- Fact bar ------------------------------------------------------------
   The decision-making numbers, above the prose, so a scanning reader never has
   to hunt for duration, grade or altitude. */

.ht-factbar {
  padding-block: var(--ht-space-6);
  background: var(--ht-surface-alt);
  border-bottom: 1px solid var(--ht-border-soft);
}

.ht-factbar__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(45%, 9rem), 1fr));
  gap: var(--ht-space-5) var(--ht-space-6);
}

.ht-factbar dt {
  font-size: var(--ht-text-xs);
  font-weight: 600;
  letter-spacing: var(--ht-tracking-caps);
  text-transform: uppercase;
  color: var(--ht-text-muted);
}

.ht-factbar dd {
  margin: 0.25rem 0 0;
  font-family: var(--ht-font-display);
  font-size: var(--ht-text-xl);
  font-weight: 500;
}

/* ---- Layout -------------------------------------------------------------- */

.ht-trek-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--ht-space-10);
  padding-block: var(--ht-section-y-tight);
}

@media (min-width: 62rem) {
  .ht-trek-layout {
    grid-template-columns: minmax(0, 1fr) 22rem;
    gap: var(--ht-space-12);
    align-items: start;
  }
}

.ht-trek-block + .ht-trek-block {
  margin-top: var(--ht-space-12);
  padding-top: var(--ht-space-12);
  border-top: 1px solid var(--ht-border-soft);
}

.ht-prose {
  margin-top: var(--ht-space-4);
  max-width: 68ch;
  color: var(--ht-text-soft);
  font-size: var(--ht-text-lg);
  line-height: var(--ht-leading-relaxed);
}

.ht-two-col {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--ht-space-8);
  margin-top: var(--ht-space-6);
}

@media (min-width: 44rem) {
  .ht-two-col {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.ht-list-heading {
  margin-bottom: var(--ht-space-4);
  font-size: var(--ht-text-xs);
  font-weight: 600;
  letter-spacing: var(--ht-tracking-caps);
  text-transform: uppercase;
  color: var(--ht-text-muted);
}

.ht-tick-list {
  display: grid;
  gap: var(--ht-space-3);
  margin-top: var(--ht-space-6);
}

.ht-two-col .ht-tick-list {
  margin-top: 0;
}

.ht-tick-list li {
  display: flex;
  align-items: flex-start;
  gap: var(--ht-space-3);
  color: var(--ht-text-soft);
  line-height: var(--ht-leading-normal);
}

.ht-tick-list svg {
  flex: none;
  width: 1.125rem;
  height: 1.125rem;
  margin-top: 0.2rem;
  color: var(--ht-success);
}

.ht-tick-list--cross svg {
  color: var(--ht-danger);
}

@media (min-width: 44rem) {
  .ht-tick-list--two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--ht-space-3) var(--ht-space-8);
  }
}

/* ---- Itinerary ----------------------------------------------------------- */

.ht-itinerary {
  margin-top: var(--ht-space-6);
}

.ht-itinerary__day {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--ht-space-2);
  padding-block: var(--ht-space-6);
  border-top: 1px solid var(--ht-border-soft);
}

.ht-itinerary__day:last-child {
  border-bottom: 1px solid var(--ht-border-soft);
}

@media (min-width: 40rem) {
  .ht-itinerary__day {
    grid-template-columns: 5.5rem minmax(0, 1fr);
    gap: var(--ht-space-6);
  }
}

.ht-itinerary__marker {
  padding-top: 0.25rem;
  font-size: var(--ht-text-xs);
  font-weight: 600;
  letter-spacing: var(--ht-tracking-caps);
  text-transform: uppercase;
  color: var(--ht-accent);
}

.ht-itinerary__title {
  font-family: var(--ht-font-display);
  font-size: var(--ht-text-xl);
  font-weight: 500;
  line-height: 1.25;
}

.ht-itinerary__route {
  margin-top: 0.25rem;
  font-size: var(--ht-text-base);
  font-weight: 500;
  color: var(--ht-pine-600);
}

.ht-itinerary__text {
  margin-top: var(--ht-space-3);
  max-width: 62ch;
  color: var(--ht-text-soft);
  line-height: var(--ht-leading-relaxed);
}

.ht-itinerary__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ht-space-2) var(--ht-space-4);
  margin-top: var(--ht-space-3);
  font-size: var(--ht-text-sm);
  color: var(--ht-text-muted);
}

.ht-itinerary__meta li {
  display: flex;
  align-items: center;
}

.ht-itinerary__meta li + li::before {
  content: "";
  width: 3px;
  height: 3px;
  margin-right: var(--ht-space-4);
  border-radius: 50%;
  background: var(--ht-stone-400);
}

/* ---- Booking panel ------------------------------------------------------- */

@media (min-width: 62rem) {
  .ht-trek-aside {
    position: sticky;
    top: calc(var(--ht-header-main-h) + var(--ht-space-6));
  }
}

.ht-book-card {
  display: grid;
  gap: var(--ht-space-5);
  padding: var(--ht-space-6);
  background: var(--ht-surface-card);
  border: 1px solid var(--ht-border);
  border-radius: var(--ht-radius-lg);
  box-shadow: var(--ht-shadow-md);
}

.ht-book-card__price {
  display: grid;
  gap: 0.25rem;
  padding-bottom: var(--ht-space-5);
  border-bottom: 1px solid var(--ht-border-soft);
}

.ht-book-card__heading {
  font-size: var(--ht-text-xs);
  font-weight: 600;
  letter-spacing: var(--ht-tracking-caps);
  text-transform: uppercase;
  color: var(--ht-text-muted);
}

.ht-book-card__empty {
  color: var(--ht-text-soft);
  font-size: var(--ht-text-base);
  line-height: var(--ht-leading-relaxed);
}

.ht-book-card__note {
  font-size: var(--ht-text-xs);
  line-height: var(--ht-leading-normal);
  color: var(--ht-text-muted);
}

.ht-batch-list {
  display: grid;
  gap: var(--ht-space-2);
  max-height: 12rem;
  overflow-y: auto;
}

.ht-batch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--ht-space-3);
  padding: var(--ht-space-3);
  border-radius: var(--ht-radius-sm);
  background: var(--ht-surface-alt);
  font-size: var(--ht-text-sm);
}

.ht-batch[data-sold-out="true"] {
  opacity: 0.62;
}

.ht-batch__date {
  font-weight: 600;
}

.ht-book-form {
  display: grid;
  gap: var(--ht-space-4);
}

/* ---- Mobile sticky CTA --------------------------------------------------- */

.ht-sticky-cta {
  position: fixed;
  inset-inline: 0;
  bottom: 0;
  z-index: var(--ht-z-sticky-cta);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--ht-space-4);
  padding: var(--ht-space-3) var(--ht-gutter);
  padding-bottom: calc(var(--ht-space-3) + env(safe-area-inset-bottom, 0px));
  background: var(--ht-surface-card);
  border-top: 1px solid var(--ht-border);
  box-shadow: 0 -6px 24px -12px rgb(20 32 26 / 0.25);
}

.ht-sticky-cta__price {
  display: grid;
  line-height: 1.2;
}

.ht-sticky-cta__price strong {
  font-family: var(--ht-font-display);
  font-size: var(--ht-text-xl);
  font-weight: 600;
}

.ht-sticky-cta__price span {
  font-size: var(--ht-text-xs);
  color: var(--ht-text-muted);
}

/* The desktop layout keeps the booking panel permanently in view, so the bar is
   only needed where that panel has collapsed below the content. */
@media (min-width: 62rem) {
  .ht-sticky-cta {
    display: none;
  }
}

/* Lift the floating buttons and the footer clear of the bar. */
@media (max-width: 61.9375rem) {
  body:has(.ht-sticky-cta) .ht-float {
    bottom: 5.5rem;
  }

  body:has(.ht-sticky-cta) .ht-footer__bottom {
    padding-bottom: 7rem;
  }
}

/* ==========================================================================
   Article detail
   ========================================================================== */

.ht-article {
  padding-block: var(--ht-section-y-tight);
}

.ht-article__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ht-space-2) var(--ht-space-4);
  margin-top: var(--ht-space-4);
  font-size: var(--ht-text-sm);
  color: var(--ht-text-muted);
}

.ht-article__cover {
  margin-block: var(--ht-space-8);
  border-radius: var(--ht-radius-lg);
  overflow: hidden;
}

.ht-article__body {
  max-width: var(--ht-shell-narrow);
  margin-inline: auto;
}

.ht-article__body p {
  margin-top: var(--ht-space-5);
  color: var(--ht-text-soft);
  font-size: var(--ht-text-lg);
  line-height: var(--ht-leading-relaxed);
}

.ht-article__body p:first-child {
  margin-top: 0;
}

/* Itinerary PDF download sits under the heading, before the day list. */
.ht-itinerary__download { margin: 0 0 var(--ht-space-5); }

/* "Ask about this trek" — the booking card's form styling, inline in the content column. */
.ht-book-card--inline { position: static; max-width: none; margin-top: var(--ht-space-5); }
#trek-enquire .ht-section-intro { margin-bottom: 0; }
