/* Journey Home */
.jh {
  position: relative;
  width: 100%;
}

/* Two Column Grid */
.jh-grid {
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
  align-items: stretch;
}

/* Tablet: keep the grid stacked (copy above, cards below) but widen the
   gap. The 2-col side layout (copy-left/cards-right) doesn't kick in here
   because at tablet widths the cards-right column would force the cards to
   stack inside it — which is the layout we explicitly don't want. */
@media (min-width: 768px) and (max-width: 1023px) {
  .jh-grid {
    gap: var(--space-2xl);
  }
}

/* Desktop: switch to 2-col layout (copy left, cards row right). */
@media (min-width: 1024px) {
  .jh-grid {
    flex-direction: row;
    gap: var(--space-2xl);
    align-items: center;
  }
}

/* Left Column: Copy */
.jh-copy {
  width: 100%;
}

@media (min-width: 1024px) {
  .jh-copy {
    flex: 1;
    min-width: 0;
  }
}

/* Copy Typography */
.jh-heading {
  margin: 0 0 10px 0 !important;
  padding: 0 !important;
  line-height: 1.2;
  hyphens: none;
}

.jh-subhead {
  margin: 0 0 var(--space-md) 0 !important;
  padding: 0 !important;
  line-height: 1.7;
  white-space: pre-line;
  hyphens: none;
}

.jh-body {
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1.7;
  white-space: pre-line;
  hyphens: none;
}

/* Heading/subhead/body are richtext blocks rendered into a .rte wrapper.
   Typography lives on the WRAPPER (editor-safe — the WYSIWYG editor cannot
   strip the wrapper's classes). The inner <h2>/<p> inherits font + color
   from the wrapper so typography survives even after the editor rewrites
   the inner tag to a bare <p> on alignment/format edits. */
.jh-heading > *,
.jh-subhead > *,
.jh-body > * {
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  color: inherit;
  margin: 0 !important;
}

/* Right Column: Cards */
.jh-cards {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

/* Tablet: cards go side-by-side (with copy now stacked above them rather
   than to the left). Cards never stack while there's still 2-col room to
   place them. */
@media (min-width: 768px) and (max-width: 1023px) {
  .jh-cards {
    flex-direction: row;
    gap: var(--space-lg);
    align-items: stretch;
  }
}

/* Desktop: cards side-by-side */
@media (min-width: 1024px) {
  .jh-cards {
    flex: 1;
    min-width: 0;
    flex-direction: row;
    gap: var(--space-lg);
  }
}

/* Card */
.jh-card {
  display: flex;
  flex-direction: column;
  padding: 0;
  flex: 1;
  overflow: hidden;
}

.jh-card-image-wrapper {
  width: 100%;
  height: 220px;
  overflow: hidden;
}

@media (min-width: 768px) and (max-width: 1023px) {
  .jh-card-image-wrapper {
    height: 200px;
  }
}

@media (min-width: 1024px) {
  .jh-card-image-wrapper {
    height: 240px;
  }
}

.jh-card-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
}

.jh-card-content {
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  flex: 1;
}

.jh-card-heading {
  margin: 0 0 8px 0 !important;
  padding: 0 !important;
  line-height: 1.3;
  letter-spacing: 0.05em;
  hyphens: none;
}

.jh-card-body {
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1.6;
  white-space: pre-line;
  hyphens: none;
  flex: 1;
}

.jh-card-button {
  margin-top: var(--space-md);
}

.jh-card-button .btn {
  cursor: pointer;
}

/* Touch target: ensure buttons meet 44px minimum on mobile/tablet */
@media (max-width: 1023px) {
  .jh-card-button .btn {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }
}
