/* English: размеры композиции ограничены общей сеткой, фоны — на всё окно. */
.en {
  background: var(--c-navy);
  color: var(--c-white);
  overflow: clip;
  container-type: inline-size;
}

.header.header--navy .header__logo.header__logo--custom {
  --logo-w: clamp(150px, 29.7vw, 356.4px);
  --logo-min-top: clamp(16px, 3.6vw, 43.2px);
}

@media (width < 480px) {
  .header.header--navy .header__logo.header__logo--custom {
    --logo-w: calc(110 * var(--u));
    --logo-min-top: 0px;
  }
}

.hero {
  width: min(100%, var(--site-container));
  margin-inline: auto;
  padding-bottom: var(--space-5);
  position: relative;
  container-type: inline-size;
}

.hero__head {
  display: grid;
  position: relative;
  z-index: 1;
}

.hero__title {
  padding-top: var(--space-4);
  font-family: var(--font-accent);
  font-size: var(--fs-h1);
  line-height: var(--lh-display);
  text-transform: uppercase;
  color: var(--c-red);
}

.hero__n {
  width: min(72%, 420px);
  margin: var(--space-3) -6% 0 0;
  justify-self: end;
}

.hero__boy {
  /* Полный Layer 9: 814 px слева лежали за границей PSD. */
  width: min(164.146%, 927.784px);
  max-width: none;
  margin: -30% 0 0 calc(-22% - min(72.146%, 407.784px));
}

.hero__copy {
  margin-top: -24%;
  font-family: var(--font-accent);
  font-size: var(--fs-h3);
  line-height: var(--lh-display);
  text-transform: uppercase;
  position: relative;
  z-index: 1;
}

.hero__copy p { margin-bottom: 1em; }
.hero__copy p:last-child { margin-bottom: 0; }
.hero__accent { color: var(--c-red); }

/* Исходник 2098×749. Центр x=740…1460 включает блокнот и персонажа.
   Боковые SVG растягивают только пустые полосы x=739 и x=1460.
   Все слои используют один масштаб, поэтому надпись не съезжает. */
.note__box {
  --note-unit: min(calc(100cqw / 720), 1px);
  height: calc(749 * var(--note-unit));
  position: relative;
}

.note__edge {
  position: absolute;
  top: 0;
  width: max(0px, calc(50% - 360 * var(--note-unit)));
  height: 100%;
  pointer-events: none;
}

.note__edge--left { left: 0; }
.note__edge--right { right: 0; }

.note__center {
  width: calc(720 * var(--note-unit));
  height: 100%;
  overflow: hidden;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.note__image {
  width: calc(2098 * var(--note-unit));
  max-width: none;
  height: auto;
  position: absolute;
  top: 0;
  left: calc(-740 * var(--note-unit));
}

.note__title {
  width: calc(184 * var(--note-unit));
  position: absolute;
  top: calc(175 * var(--note-unit));
  left: calc(256 * var(--note-unit));
}

.note__apple {
  width: calc(185 * var(--note-unit));
  position: absolute;
  top: calc(170 * var(--note-unit));
  left: max(var(--site-gutter), calc(50% - 500 * var(--note-unit)));
  transition: transform 200ms ease;
}

@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .note__apple:hover { transform: rotate(-8deg); }
}

.sky {
  min-height: clamp(360px, 39.4cqw, 472.8px);
  padding: var(--space-5) var(--gutter);
  text-align: center;
  background: url(/images/english/sky.jpg) 50% / cover no-repeat;
  display: grid;
  place-items: center;
}

.sky p {
  max-width: min(24em, calc(var(--site-container) - 2 * var(--site-gutter)));
  font-family: var(--font-accent);
  font-size: var(--fs-h1);
  line-height: var(--lh-display);
  text-transform: uppercase;
  text-shadow: 0 1px 12px color-mix(in srgb, var(--c-navy) 35%, transparent);
}

.eng {
  /* На планшетах длинный текст занимает больше высоты облачного блока:
     шапка маскота не должна заходить на последнюю строку. */
  margin-top: clamp(-84px, calc(324px - 36cqw), -40px);
  padding: 0 var(--gutter) var(--space-4);
  position: relative;
  z-index: 1;
}

.eng img {
  width: min(70%, 630px);
  margin-inline: auto;
}

@media (width >= 960px) {
  .hero__head {
    grid-template-columns: minmax(0, 0.45fr) minmax(0, 0.55fr);
    column-gap: var(--space-4);
    align-items: start;
  }
  .hero__title {
    font-size: min(var(--fs-h1), 2.9cqw);
    padding-top: 11.3cqw;
  }
  .hero__n {
    width: 35.6cqw;
    margin: 1.5cqw 0 0;
    justify-self: start;
  }
  .hero__boy {
    /* 25% слоя остаётся за окном: наклонный край фото не создаёт зазор. */
    --boy-width: max(97.42cqw, calc((54.6cqw + (100vw - 100cqw) / 2) / 0.75));
    width: var(--boy-width);
    margin: 0;
    position: absolute;
    /* При увеличении на широком окне лицо остаётся выше текста. */
    top: calc(3cqw - (var(--boy-width) - 97.42cqw) * 0.35);
    right: 45.4cqw;
  }
  .hero__copy {
    font-size: min(var(--fs-h1), 3.07cqw);
    margin-top: 8.6cqw;
  }
  .eng {
    padding-bottom: 54px;
  }
  .eng img { width: min(52.64cqw, 630px); }
}
