/* Template: image-text — image on the left, glass text box overlapping it on
   the right (see js/templates/image-text.js). For the mirrored layout use
   the image-text-right template. Desktop keeps the side-by-side overlap;
   mobile stacks with the box overlapping the image bottom. */

.image-text {
  flex: 1;
  display: flex;
  align-items: center;
  width: 100%;
  padding: clamp(96px, 16vh, 160px) 0;
}

.image-text__inner {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.image-text__image {
  flex: 0 0 auto;
  width: 60%;
  height: clamp(300px, 60vh, 620px);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.image-text__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Glass text box: translucent surface tint + backdrop blur, so the part
   covering the image stays visible while the text stays readable. */
.image-text__content {
  position: relative;
  z-index: 1;
  flex: 0 0 auto;
  width: 52%;
  margin-left: -14%;
  padding: clamp(28px, 4vw, 48px);
  background: var(--color-surface);
  background: color-mix(in srgb, var(--color-surface) 55%, transparent);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
  backdrop-filter: blur(18px) saturate(150%);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
}

.image-text__title {
  font-size: clamp(24px, 4vw, 40px);
  letter-spacing: 0.04em;
}

.image-text__paragraph {
  margin-top: clamp(16px, 2.5vh, 24px);
  font-size: clamp(14px, 1.9vw, 16.5px);
  line-height: 1.75;
  text-align: justify;
  text-justify: inter-word;
  hyphens: auto;
  color: var(--color-text-secondary);
}

.image-text__paragraph:first-of-type {
  margin-top: clamp(20px, 3vh, 32px);
}

@media (max-width: 767px) {
  .image-text__inner {
    flex-direction: column;
    align-items: stretch;
  }

  .image-text__image {
    width: 100%;
    height: clamp(240px, 34vh, 380px);
  }

  .image-text__content {
    width: 88%;
    margin: calc(-1 * clamp(44px, 7vh, 64px)) auto 0;
  }
}
