/* Localized homepage copy can grow, but the EN / PL / ES hero keeps one
   predictable reading order, image role and tap rhythm. */
:root {
  --tr-hero-copy-max: 45rem;
  --tr-hero-copy-pad: clamp(2.75rem, 5.5vw, 4.75rem);
  --tr-hero-title-size: clamp(3.05rem, 4.7vw, 4.9rem);
  --tr-hero-body-size: clamp(1rem, .95rem + .25vw, 1.12rem);
  --tr-hero-visual-min: clamp(25rem, 42vw, 38rem);
}

body main > .hero:first-child,
body main > .hero:first-child .wrap,
body main > .hero:first-child .hero-grid,
body main > .hero:first-child .hero-copy,
body main > .hero:first-child .hero-visual {
  min-width: 0;
}

body main > .hero:first-child .hero-grid {
  display: grid !important;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  align-items: center;
  min-height: clamp(37rem, 56vw, 43rem);
  height: auto !important;
}

body main > .hero:first-child .hero-copy {
  grid-column: 1 / span 7;
  grid-row: 1;
  z-index: 2;
  max-width: var(--tr-hero-copy-max);
  padding: var(--tr-hero-copy-pad) clamp(1.25rem, 3vw, 3rem) var(--tr-hero-copy-pad) 0;
}

body main > .hero:first-child .hero h1,
body main > .hero:first-child h1 {
  width: min(100%, var(--tr-hero-copy-max));
  max-width: var(--tr-hero-copy-max);
  margin: 1.2rem 0 0 !important;
  font-size: var(--tr-hero-title-size) !important;
  line-height: .99 !important;
  letter-spacing: -.04em !important;
  text-wrap: balance !important;
  overflow-wrap: anywhere;
}

body main > .hero:first-child .hero-title-line {
  display: block;
  white-space: normal !important;
}

body main > .hero:first-child .hero-title-line--accent {
  margin-top: .07em;
  color: var(--trawa-pink, var(--pink, #df7e9e));
  font-style: italic;
}

body main > .hero:first-child .sub {
  max-width: 34rem !important;
  margin-bottom: 0;
  font-size: var(--tr-hero-body-size) !important;
  line-height: 1.62 !important;
  overflow-wrap: anywhere;
}

body main > .hero:first-child .hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: clamp(1.45rem, 2.8vw, 2.15rem);
}

body main > .hero:first-child .hero-cta .btn {
  min-width: 0;
  min-height: 52px;
  overflow-wrap: anywhere;
}

body main > .hero:first-child .hero-visual {
  grid-column: 8 / -1;
  grid-row: 1;
  align-self: stretch;
  min-height: var(--tr-hero-visual-min);
  margin: 0 !important;
}

body main > .hero:first-child .hero-visual img {
  max-width: 100%;
  object-position: 68% center;
}

@media (max-width: 1080px) {
  body main > .hero:first-child .hero-grid {
    grid-template-columns: minmax(0, 1fr);
    min-height: 0;
  }

  body main > .hero:first-child .hero-copy {
    grid-column: 1;
    grid-row: 1;
    max-width: min(100%, 52rem);
    padding: clamp(2.7rem, 7vw, 4.1rem) 0 1.6rem;
  }

  body main > .hero:first-child .hero-visual {
    grid-column: 1;
    grid-row: 2;
    min-height: clamp(22rem, 58vw, 31rem);
    margin: 0 0 1.35rem !important;
  }
}

@media (max-width: 700px) {
  :root {
    --tr-hero-copy-pad: clamp(2.1rem, 9vw, 3.1rem);
    --tr-hero-title-size: clamp(2.7rem, 11.2vw, 4.1rem);
    --tr-hero-body-size: 1rem;
  }

  body main > .hero:first-child .hero-copy {
    padding-right: 0;
  }

  body main > .hero:first-child .hero-visual {
    min-height: clamp(19rem, 78vw, 25rem);
  }

  body main > .hero:first-child .hero-cta {
    gap: 10px;
  }

  body main > .hero:first-child .hero-cta .btn {
    flex: 1 1 13.5rem;
    justify-content: center;
  }
}

@media (max-width: 430px) {
  body main > .hero:first-child .hero-cta .btn {
    flex-basis: 100%;
  }

  body main > .hero:first-child .hero-visual {
    min-height: clamp(18rem, 86vw, 22rem);
  }
}
