* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --index: calc(1vw + 1vh);
  --text: #e7e7e0;
  --transition: transform 0.75s cubic-bezier(0.075, 0.5, 0, 1);
}

body {
  background-color: #010101;
  line-height: 1.55;
}

.content {
  /*
	https://developer.mozilla.org/zh-CN/docs/Web/CSS/will-change
	CSS 属性 will-change 为 web 开发者提供了一种告知浏览器该元素会有哪些变化的方法，
	这样浏览器可以在元素属性真正发生变化之前提前做好对应的优化准备工作。
	这种优化可以将一部分复杂的计算工作提前准备好，使页面的反应更为快速灵敏。
	*/
  will-change: transform;

  & .main-header {
    position: relative;

    & .layers {
      height: 100vh;
      display: flex;
      align-items: center;
      justify-content: center;
      text-align: center;
      overflow: hidden;
      position: relative;

      & .layer_header_container {
        position: relative;
        z-index: 1;
        width: calc(var(--index) * 40);
        display: flex;
        justify-content: center;
        align-items: center;
        flex-direction: column;

        & .layer__header {
          position: absolute;
          left: 50%;
          top: 0;
          margin-top: -6rem;
          z-index: 1;
          transform: translate3d(-50%, calc(var(--scrollTop) / 2), 0);
          transition: var(--transition);
          will-change: transform;
          text-transform: uppercase;
          font-weight: 900;
          color: var(--text);
          text-shadow: 0 0 15px #9d822b;

          & .layers__caption {
            font-size: calc(var(--index) * 1.5);
            letter-spacing: calc(var(--index) / 3.5);
            margin-top: calc(var(--index) * -0.75);
          }

          & .layers__title {
            font-size: calc(var(--index) * 3.65);
            letter-spacing: calc(var(--index) / 2.25);
          }
        }
      }

      & .layer {
        height: 100%;
        width: 100%;
        position: absolute;
        background-size: cover;
        background-position: center;
        will-change: transform;
        z-index: 2;
        transition: var(--transition);
      }

      & .layer.layers__base {
        transform: translate3d(0, calc(var(--scrollTop) / 1.6), 0);
        z-index: 0;
      }
      & .layer.layers__middle {
        transform: translate3d(0, calc(var(--scrollTop) / 2.5), 0);
      }
      & .layer.layers__front {
        transform: translate3d(0, calc(var(--scrollTop) / 5.7), 0);
      }
    }
  }

  & .main-header::after {
    content: "";
    position: absolute;
    z-index: 100;
    width: 100%;
    height: calc(var(--index) * 10);
    background-image: url(./images/ground.png);
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    bottom: calc(var(--index) * -4.5);
  }

  & .main-article {
    --main-article-transform: translate3d(0, calc(var(--scrollTop) / -7.5), 0);
    min-height: 100vh;
    background-size: cover;
    background-position: center;
    color: var(--text);
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    text-align: center;
    top: -1px;
    z-index: 10;

    & .main-article__content {
      & .main-article__header {
        text-transform: uppercase;
        font-size: calc(var(--index) * 1.8);
        letter-spacing: calc(var(--index) / 7.5);
        transform: var(--main-article-transform);
        transition: var(--transition);
        will-change: transform;
      }

      & .main-article__paragraph {
        max-width: calc(var(--index) * 30);
        font-size: calc(var(--index) * 0.9);
        margin-top: calc(var(--index) / 1.25);
        transform: var(--main-article-transform);
        transition: var(--transition);
        will-change: transform;
        text-align: left;
      }
    }

    & .copyright {
      position: absolute;
      bottom: calc(var(--index) * 2.5);
      opacity: 0.45;
      font-size: calc(var(--index) * 0.75);
      letter-spacing: calc(var(--index) / 37.5);
    }
  }
}
