@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Spectral:wght@400;600;700&display=swap");

* {
  box-sizing: border-box;
}
body {
  margin: 0;
  color: #141414;
  background: #f6f1ea;
}
.page {
  min-height: 100vh;
  padding: 28px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
}
.paper {
  position: relative;
  width: 100%;
  max-width: 1180px;
  background: #f4eee6;
  border-radius: 12px;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.14);
  padding: 40px 44px 56px;
}

.header {
  display: flex;
  align-items: flex-start;
  gap: 32px;
}
.brand {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.brand__title {
  font-family: "Spectral", Georgia, serif;
  font-weight: 700;
  font-size: clamp(46px, 8.4vw, 104px);
  line-height: 1;
}
.brand__tag {
  font-family: Inter, system-ui, sans-serif;
  font-size: 12px;
  letter-spacing: 2.8px;
  color: #54514b;
}
.nav {
  margin-left: auto;
  display: inline-flex;
  gap: clamp(14px, 3vw, 32px);
  transform: translateY(8px);
}
.nav__link {
  font-family: Inter, system-ui, sans-serif;
  font-size: 14px;
  text-decoration: none;
  color: #141414;
  opacity: 0.9;
}
.nav__link:hover,
.nav__link:focus {
  opacity: 1;
  outline: none;
}

.paper {
  --left: 0.58;
  --right: 0.42;
  --img: 0.8;
  --overhang-px: 100px;
  --offset-px: -25px;
  --head: 0.2825;
  --torso: 0.6;
  --head-top: 0.135;
  --torso-top: 0.36;
}

.layout {
  display: grid;
  row-gap: 56px;
  margin-top: 20px;
}
.top {
  display: grid;
  grid-template-columns: calc(100% * var(--left)) calc(100% * var(--right));
  column-gap: 40px;
  align-items: start;
}

.col--text {
  position: relative;
  z-index: 2;
}
.col--portrait {
  position: relative;
  z-index: 0;
}

.h {
  font-family: "Spectral", Georgia, serif;
  font-weight: 700;
  font-size: clamp(36px, 5.4vw, 66px);
  line-height: 1.08;
  margin: 0 0 12px;
}
.p {
  font-family: Inter, system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.8;
  margin: 0;
}
.p--italic {
  font-style: italic;
}

.about {
  margin: 0 0 40px 0;
}
.about__wrap,
.works__wrap {
  position: relative;
  max-width: none;
  z-index: 2;
}

.about__wrap p.p {
  width: 95%;
}
.works {
  margin-top: 150px;
}

.works__wrap p.p {
  width: 75%;
}

.portrait {
  width: calc(100% * var(--img));
  pointer-events: none;
}

.portrait__img {
  display: block;
  width: 100%;
  height: auto;
}
.portrait--desktop {
  margin-left: auto;
  margin-right: calc(var(--overhang-px) * -1);
  transform: translateY(var(--offset-px));
  position: absolute;
  right: 50px;
  top: -20px;
  width: 180%;
  pointer-events: none;
  z-index: 0;
}
.portrait--mobile {
  display: none;
  margin: 24px 0 24px 0;
}

.legacy {
  margin-top: 150px;
  grid-column: 1/-1;
}

.footer {
  margin-top: 44px;
}
.foot {
  font-family: Inter, system-ui, sans-serif;
  font-size: 14px;
  color: #54514b;
  margin: 0;
}

@media (max-width: 1139px) and (min-width: 901px) {
  .paper {
    --head: 0;
    --torso: 0;
  }
}

@media (max-width: 900px) {
  .layout {
    display: block;
  }
  .top {
    display: block;
  }
  .portrait--desktop {
    display: none;
  }
  .portrait--mobile {
    display: block;
  }

  .portrait.portrait--mobile {
    position: relative;
    width: 100%;
    pointer-events: none;
    right: 10px;
  }
  .about,
  .works {
    margin: 0 0 24px 0;
  }
  .about__wrap,
  .works__wrap {
    width: 100%;
    margin-top: 0;
  }

  .about__wrap p.p,
  .works__wrap p.p {
    width: 100%;
  }

  .legacy {
    margin-top: 0;
  }
}

@media (max-width: 630px) {
  .page {
    padding: 0;
  }
}
@media (max-width: 480px) {
  .header {
    flex-direction: column;
    gap: 12px;
  }
  .nav {
    margin-left: 0;
    order: 1;
  }
  .brand {
    order: 2;
  }
}
