:root {
  --site-header-height: 5.25rem;
}

html {
  scroll-padding-top: calc(var(--site-header-height) + 1rem);
}

body {
  overflow-x: clip;
}

[id] {
  scroll-margin-top: calc(var(--site-header-height) + 1rem);
}

h1,
h2,
h3,
blockquote {
  text-wrap: balance;
}

p {
  text-wrap: pretty;
}

button,
.motion-button,
.testimonial-control,
.gallery-expand {
  min-height: 2.75rem;
  min-width: 2.75rem;
  touch-action: manipulation;
}

.reactive-photo-stage img,
.clinic-gallery-item img,
.lightbox-image {
  backface-visibility: hidden;
}

.testimonials-rail {
  scroll-padding-inline: 1.25rem;
}

@media (width <= 639px) {
  :root {
    --site-header-height: 5.25rem;
  }

  #inicio > section > div:first-child {
    padding-top: 3.5rem;
    padding-bottom: 3.25rem;
  }

  #inicio h1 {
    max-width: 11.5ch;
    font-size: clamp(3.75rem, 18vw, 4.5rem);
    line-height: 0.84;
    letter-spacing: -0.052em;
  }

  #inicio h1 + div {
    margin-top: 2rem;
    padding-left: 1.25rem;
  }

  #inicio h1 + div p {
    line-height: 1.75;
  }

  #inicio > section > div:last-child {
    min-height: clamp(33rem, 145vw, 38rem);
  }

  .kinetic-trace-b {
    display: none;
  }

  .reactive-photo-stage {
    will-change: auto;
  }

  .testimonials-rail {
    scroll-padding-inline: 1.25rem;
  }
}

@media (width >= 640px) and (width <= 1023px) {
  #inicio > section > div:first-child {
    padding-top: 5rem;
    padding-bottom: 4.5rem;
  }

  #inicio > section > div:last-child {
    min-height: 46rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .testimonials-rail {
    scroll-behavior: auto;
  }
}
