@font-face {
  font-family: "Oranienbaum";
  src: url("assets/fonts/Oranienbaum-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("assets/fonts/Inter-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("assets/fonts/Inter-SemiBold.ttf") format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #fffdf1;
  --red: #d9322b;
  --text: #4f5652;
  --muted: #8b918b;
  --page: min(100vw - 72px, 1500px);
  --scale: 1;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  cursor: url("курсор.png") 16 16, auto;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.15;
}

body.modal-open {
  overflow: hidden;
}

img {
  display: block;
  width: 100%;
}

button,
a {
  color: inherit;
  cursor: url("курсор.png") 16 16, pointer;
}

.topbar {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: start;
  gap: 32px;
  width: var(--page);
  max-width: none;
  margin: 0 auto;
  padding: 18px 48px 0;
  color: var(--red);
  font-size: 14px;
}

.logo,
.nav a,
.footer a {
  text-decoration: none;
}

.logo {
  font-family: "Oranienbaum", Georgia, serif;
  font-size: 22px;
}

.nav {
  display: grid;
  grid-template-columns: repeat(4, auto);
  gap: 126px;
}

.nav a:hover,
.footer a:hover {
  text-decoration: underline;
}

main {
  width: var(--page);
  max-width: none;
  margin: 0 auto;
  padding: 0 18px;
}

.hero {
  padding: 104px 0 104px;
  color: var(--red);
  text-align: center;
}

.hero-title {
  display: inline-block;
  text-align: right;
}

.hero h1,
.about-section h2,
.practice-section h2,
.works-section h2,
.footer h2 {
  margin: 0;
  font-family: "Oranienbaum", Georgia, serif;
  font-weight: 400;
  letter-spacing: -0.04em;
  line-height: 0.86;
}

.hero h1 {
  font-size: 96px;
}

.hero p {
  width: auto;
  margin: 4px 0 0;
  font-size: 13px;
  line-height: 1;
}

.intro-strip {
  display: grid;
  grid-template-columns: 112px 122px 164px 186px 190px 156px;
  justify-content: center;
  align-items: end;
  gap: 28px;
  padding-bottom: 150px;
}

.intro-strip img {
  position: relative;
  height: 112px;
  object-fit: cover;
  transform-origin: center;
  transition: transform 220ms ease, filter 220ms ease;
  will-change: transform;
}

.intro-strip img:hover {
  filter: saturate(1.08);
  transform: scale(1.18);
  z-index: 1;
}

.intro-strip img:nth-child(1) {
  object-position: 50% 0;
}

.intro-strip img:nth-child(2) {
  height: 142px;
  object-position: 50% 50%;
}

.intro-strip img:nth-child(3) {
  height: 116px;
  object-position: 50% 48%;
}

.intro-strip img:nth-child(4) {
  height: 185px;
  object-position: 50% 0;
}

.intro-strip img:nth-child(5) {
  height: 135px;
}

.intro-strip img:nth-child(6) {
  height: 116px;
  object-position: 50% 50%;
}

.about-section {
  display: grid;
  grid-template-columns: 344px minmax(0, 1fr);
  grid-template-areas:
    "title title"
    "photo copy"
    "statement statement";
  column-gap: 22px;
  row-gap: 26px;
  padding: 0 28px 150px;
}

.about-section h2 {
  grid-area: title;
  color: var(--red);
  font-size: 63px;
}

.about-section p {
  margin: 0;
  font-size: 18px;
}

.about-photo {
  grid-area: photo;
  margin-top: 0;
}

.about-photo img {
  width: 100%;
  height: auto;
  object-fit: contain;
  object-position: center;
}

.about-copy {
  grid-area: copy;
  max-width: 620px;
  display: grid;
  align-content: start;
  gap: 20px;
}

.statement {
  grid-area: statement;
  display: grid;
  grid-template-columns: 344px minmax(0, 1fr);
  column-gap: 22px;
  max-width: none;
  margin-top: -62px !important;
  color: var(--red);
  font-size: 38px !important;
  font-weight: 600;
  line-height: 0.94 !important;
  letter-spacing: -0.05em;
}

.statement-lead {
  grid-column: 2;
  align-self: end;
  margin-bottom: 10px;
}

.statement-rest {
  grid-column: 1 / -1;
}

.practice-section {
  display: grid;
  grid-template-columns: 1fr 368px;
  grid-template-areas:
    "copy title"
    "copy image";
  gap: 72px;
  align-items: start;
  padding: 0 28px 136px;
}

.practice-copy {
  grid-area: copy;
  display: grid;
  grid-template-columns: 1fr;
  justify-items: end;
  text-align: right;
  align-self: start;
  padding-top: 126px;
}

.practice-section h2 {
  grid-area: title;
  align-self: end;
  margin-bottom: 0;
  color: var(--red);
  font-size: 63px;
}

.practice-copy p {
  max-width: 640px;
  margin: 0 0 18px;
  font-size: 17px;
}

.practice-image {
  grid-area: image;
  align-self: start;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: url("курсор.png") 16 16, zoom-in;
}

.practice-image img {
  height: 472px;
  object-fit: cover;
  object-position: center;
}

.works-section {
  padding: 0 28px 112px;
}

.section-head {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: baseline;
  gap: 32px;
  margin-bottom: 92px;
}

.works-section h2 {
  color: var(--red);
  font-size: 63px;
}

.section-head p {
  margin: 0;
  color: var(--red);
  font-size: 14px;
}

.paintings-grid,
.graphics-grid {
  display: grid;
  grid-template-columns: repeat(2, 300px);
  justify-content: center;
  column-gap: 150px;
}

.paintings-grid-bottom {
  margin-top: 126px;
}

.work-card {
  color: #7a807b;
}

.work-image {
  width: 100%;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: url("курсор.png") 16 16, zoom-in;
}

.work-image img {
  height: 416px;
  object-fit: contain;
  transform-origin: center;
  transition: filter 220ms ease, transform 220ms ease;
  will-change: transform;
}

.work-image:hover img {
  filter: saturate(1.08);
  transform: scale(1.18);
}

.work-card h3,
.work-card p,
.work-card strong {
  display: block;
  margin: 10px 0 0;
  font-size: 15px;
  font-weight: 400;
}

.work-card p {
  margin-top: 3px;
}

.work-card strong {
  margin-top: 26px;
}

.mini-series {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
  margin-top: 128px;
}

.mini-card .work-image img {
  height: 226px;
  object-fit: contain;
  object-position: center;
}

.series-meta {
  margin: 16px 0 0;
  color: #7a807b;
  font-size: 15px;
}

.series-price {
  margin: 26px 0 0;
  color: #7a807b;
  font-size: 15px;
}

.graphics-section {
  padding-bottom: 150px;
}

.graphics-heading {
  display: grid;
  grid-template-columns: 1fr 380px;
  align-items: start;
  gap: 40px;
  margin-bottom: 76px;
}

.graphics-heading h2 {
  margin: 0;
}

.graphics-heading p {
  max-width: 360px;
  margin: 15px 0 0;
  color: var(--red);
  font-size: 14px;
  line-height: 1.15;
}

.graphics-grid .work-image img {
  height: 426px;
  object-fit: contain;
}

.footer {
  background: #d22f29;
  color: var(--bg);
  cursor: url("курсор-молочный.png") 16 16, auto;
  padding: 92px max(46px, calc((100vw - min(100vw, 1500px)) / 2 + 46px)) 108px;
}

.footer a {
  cursor: url("курсор-молочный.png") 16 16, pointer;
}

.footer h2 {
  font-size: 58px;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 80px;
  margin-top: 72px;
  font-size: 16px;
  font-weight: 600;
}

.gallery {
  width: min(1280px, calc(100vw - 56px));
  height: min(760px, calc(100dvh - 56px));
  max-height: calc(100dvh - 56px);
  padding: 0;
  border: 0;
  background: var(--bg);
  color: var(--text);
  overflow: hidden;
}

.gallery::backdrop {
  background: rgba(31, 25, 20, 0.52);
}

.gallery[open] {
  display: block;
}

.gallery-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 350px;
  gap: 34px;
  width: 100%;
  height: 100%;
  padding: 34px;
  overflow: hidden;
}

.gallery-stage {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 0;
  overflow: hidden;
  background: #f7f1e4;
}

.gallery-stage img {
  width: auto;
  height: auto;
  max-width: calc(100% - 96px);
  max-height: 100%;
  min-height: 0;
  object-fit: contain;
}

.gallery-info {
  display: flex;
  min-height: 0;
  flex-direction: column;
  align-self: stretch;
  color: var(--text);
}

.gallery-kicker {
  margin: 0 0 20px;
  color: var(--red);
  font-size: 13px;
}

.gallery-info h2 {
  margin: 0 0 28px;
  color: var(--red);
  font-family: "Oranienbaum", Georgia, serif;
  font-size: 58px;
  font-weight: 400;
  line-height: 0.9;
}

.gallery-info dl {
  display: grid;
  gap: 18px;
  margin: 0 0 28px;
}

.gallery-info div {
  display: grid;
  gap: 5px;
}

.gallery-info dt {
  color: var(--muted);
  font-size: 13px;
}

.gallery-info dd {
  margin: 0;
  font-size: 20px;
}

#galleryMeta {
  margin: 0 0 auto;
  color: var(--muted);
  font-size: 14px;
}

.gallery-action {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  margin-top: 12px;
  border: 1px solid var(--red);
  border-radius: 999px;
  color: var(--red);
  font-weight: 600;
  text-decoration: none;
}

.gallery-buy {
  background: var(--red);
  color: var(--bg);
}

.gallery-close {
  position: absolute;
  top: 12px;
  right: 18px;
  z-index: 2;
  border: 0;
  color: var(--red);
  background: transparent;
  font-size: 42px;
  line-height: 1;
  cursor: url("курсор.png") 16 16, pointer;
}

.gallery-arrow {
  position: absolute;
  top: 50%;
  z-index: 1;
  width: 48px;
  height: 48px;
  border: 1px solid var(--red);
  border-radius: 999px;
  color: var(--red);
  background: var(--bg);
  font-size: 34px;
  line-height: 1;
  transform: translateY(-50%);
  cursor: url("курсор.png") 16 16, pointer;
}

.gallery-prev {
  left: 18px;
}

.gallery-next {
  right: 18px;
}

#galleryCounter {
  position: absolute;
  left: 18px;
  bottom: 16px;
  color: var(--muted);
  font-size: 14px;
}

@media (min-width: 1280px) {
  :root {
    --scale: 1.18;
  }

  .topbar,
  main {
    padding-left: 0;
    padding-right: 0;
  }

  .hero {
    padding-top: calc(104px * var(--scale));
    padding-bottom: calc(104px * var(--scale));
  }

  .hero h1 {
    font-size: calc(96px * var(--scale));
  }

  .intro-strip {
    grid-template-columns:
      calc(112px * var(--scale))
      calc(122px * var(--scale))
      calc(164px * var(--scale))
      calc(186px * var(--scale))
      calc(190px * var(--scale))
      calc(156px * var(--scale));
    gap: calc(28px * var(--scale));
  }

  .intro-strip img {
    height: calc(112px * var(--scale));
  }

  .intro-strip img:nth-child(2) {
    height: calc(142px * var(--scale));
  }

  .intro-strip img:nth-child(3),
  .intro-strip img:nth-child(6) {
    height: calc(116px * var(--scale));
  }

  .intro-strip img:nth-child(4) {
    height: calc(185px * var(--scale));
  }

  .intro-strip img:nth-child(5) {
    height: calc(135px * var(--scale));
  }

  .about-section,
  .practice-section,
  .works-section {
    padding-left: calc(28px * var(--scale));
    padding-right: calc(28px * var(--scale));
  }

  .about-section {
    grid-template-columns: calc(344px * var(--scale)) minmax(0, 1fr);
    column-gap: calc(22px * var(--scale));
  }

  .statement {
    grid-template-columns: calc(344px * var(--scale)) minmax(0, 1fr);
    column-gap: calc(22px * var(--scale));
  }

  .about-photo img {
    height: auto;
  }

  .paintings-grid,
  .graphics-grid {
    grid-template-columns: repeat(2, calc(300px * var(--scale)));
    column-gap: calc(150px * var(--scale));
  }

  .work-image img {
    height: calc(416px * var(--scale));
  }

  .mini-card .work-image img {
    height: calc(226px * var(--scale));
  }
}

@media (min-width: 1600px) {
  :root {
    --scale: 1.34;
  }
}

@media (max-width: 860px) {
  .topbar {
    grid-template-columns: 1fr;
    padding: 18px 18px 0;
  }

  .nav {
    display: flex;
    gap: 22px;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .hero {
    padding: 70px 0 72px;
  }

  .hero h1 {
    font-size: 64px;
  }

  .hero p {
    width: auto;
  }

  .intro-strip {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    padding-bottom: 84px;
  }

  .intro-strip img,
  .intro-strip img:nth-child(n) {
    height: 128px;
  }

  .about-section,
  .practice-section,
  .section-head,
  .graphics-heading,
  .paintings-grid,
  .graphics-grid {
    grid-template-columns: 1fr;
  }

  .about-section {
    grid-template-areas:
      "title"
      "photo"
      "copy"
      "statement";
    padding: 0 0 92px;
  }

  .about-section h2,
  .practice-section h2,
  .works-section h2 {
    font-size: 50px;
  }

  .about-photo img {
    height: auto;
  }

  .statement {
    display: block;
    margin-top: 24px !important;
    font-size: 29px !important;
  }

  .statement-lead,
  .statement-rest {
    display: inline;
  }

  .practice-section {
    grid-template-areas:
      "title"
      "copy"
      "image";
    gap: 26px;
    padding: 0 0 92px;
  }

  .practice-copy {
    justify-items: start;
    text-align: left;
  }

  .practice-section h2 {
    margin-bottom: 26px;
  }

  .works-section {
    padding: 0 0 88px;
  }

  .section-head {
    margin-bottom: 44px;
  }

  .graphics-heading {
    gap: 14px;
    margin-bottom: 44px;
  }

  .graphics-heading p {
    margin-top: 0;
  }

  .paintings-grid,
  .graphics-grid {
    gap: 56px;
  }

  .work-image img,
  .graphics-grid .work-image img {
    height: auto;
    max-height: 520px;
    object-fit: contain;
  }

  .mini-series {
    grid-template-columns: repeat(2, 1fr);
    margin-top: 72px;
  }

  .mini-card .work-image img {
    height: auto;
  }

  .footer {
    padding: 62px 18px 70px;
  }

  .footer h2 {
    font-size: 46px;
  }

  .footer-links {
    grid-template-columns: 1fr;
    gap: 22px;
    margin-top: 42px;
  }

  .gallery figure {
    padding: 54px 38px 34px;
  }

  .gallery {
    width: calc(100vw - 24px);
    height: calc(100dvh - 24px);
  }

  .gallery-layout {
    grid-template-columns: 1fr;
    gap: 18px;
    padding: 24px;
  }

  .gallery-stage img {
    max-width: calc(100% - 72px);
  }

  .gallery-info {
    min-height: 210px;
  }

  .gallery-info h2 {
    font-size: 38px;
  }
}
