.content-page {
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 12%, rgba(63, 102, 74, 0.18), transparent 28%),
    radial-gradient(circle at 88% 34%, rgba(155, 98, 48, 0.13), transparent 30%),
    #d8bd92;
}

.content-hero {
  position: relative;
  min-height: 540px;
  overflow: hidden;
  color: var(--white);
  background: var(--night);
  isolation: isolate;
}

.content-hero::before {
  position: absolute;
  z-index: -3;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(13, 11, 9, 0.96) 0%, rgba(13, 11, 9, 0.76) 50%, rgba(13, 11, 9, 0.28) 100%),
    linear-gradient(0deg, rgba(13, 11, 9, 0.97), transparent 52%),
    var(--hero-image) center / cover;
  image-rendering: pixelated;
  content: "";
}

.content-hero::after {
  position: absolute;
  z-index: -2;
  inset: 0;
  opacity: 0.17;
  background: repeating-linear-gradient(0deg, transparent 0 3px, rgba(255, 255, 255, 0.08) 4px);
  pointer-events: none;
  content: "";
}

.content-hero__inner {
  display: grid;
  align-items: end;
  width: var(--container);
  min-height: 540px;
  margin-inline: auto;
  padding-block: clamp(78px, 10vw, 130px) 82px;
}

.content-hero__copy {
  max-width: 850px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 24px;
  color: rgba(255, 247, 232, 0.58);
  font-size: var(--type-base);
}

.breadcrumb a:hover,
.breadcrumb a:focus-visible {
  color: var(--gold-light);
}

.content-hero h1 {
  max-width: 900px;
  margin: 0;
  font-size: var(--type-hero-title);
  letter-spacing: -0.035em;
  line-height: 0.92;
  text-wrap: balance;
  text-shadow: 0 7px 0 rgba(38, 23, 14, 0.58), 0 18px 40px rgba(0, 0, 0, 0.5);
}

.content-hero__lead {
  max-width: 760px;
  margin: 28px 0 0;
  color: rgba(255, 247, 232, 0.82);
  font-size: var(--type-hero-lead);
  line-height: 1.38;
}

.content-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 32px;
}

.article-shell {
  width: var(--container);
  margin-inline: auto;
  padding-block: clamp(68px, 8vw, 108px);
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 270px;
  gap: clamp(48px, 7vw, 92px);
  align-items: start;
}

.article-prose {
  min-width: 0;
}

.article-prose > *:first-child {
  margin-top: 0;
}

.article-prose h2 {
  margin: 62px 0 20px;
  color: var(--ink);
  font-size: var(--type-section-title);
  letter-spacing: -0.025em;
  line-height: 0.98;
  text-wrap: balance;
}

.article-prose h3 {
  margin: 34px 0 12px;
  color: #3f2c21;
  font-size: clamp(27px, 3vw, 34px);
  line-height: 1.08;
}

.article-prose p,
.article-prose li {
  color: var(--ink-soft);
  font-size: var(--type-copy);
  line-height: 1.52;
}

.article-prose p {
  max-width: 66ch;
  margin: 0 0 18px;
}

.article-prose strong {
  color: var(--ink);
}

.article-prose ul,
.article-prose ol {
  display: grid;
  gap: 11px;
  max-width: 74ch;
  padding-left: 28px;
}

.article-prose a:not(.button) {
  color: #294d35;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: rgba(41, 77, 53, 0.36);
  text-underline-offset: 4px;
}

.article-prose a:not(.button):hover,
.article-prose a:not(.button):focus-visible {
  color: #172f20;
  text-decoration-color: currentColor;
}

.article-aside {
  position: sticky;
  top: calc(var(--header-height) + 24px);
  padding: 24px 22px;
  background: rgba(242, 223, 186, 0.68);
  border: 2px solid rgba(95, 65, 41, 0.52);
  border-radius: 7px;
  box-shadow: inset 0 0 0 4px rgba(255, 247, 232, 0.2), 0 16px 36px rgba(64, 42, 27, 0.12);
}

.article-aside p {
  margin: 0 0 14px;
  color: #6c503a;
  font-size: var(--type-kicker);
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.article-aside nav {
  display: grid;
  gap: 4px;
}

.article-aside a {
  padding: 9px 0;
  color: var(--ink-soft);
  border-bottom: 1px solid rgba(95, 65, 41, 0.18);
  font-size: var(--type-action);
  line-height: 1.25;
}

.article-aside a:hover,
.article-aside a:focus-visible {
  color: #294d35;
}

.article-figure {
  margin: 42px 0;
  padding: 7px;
  background: #39261b;
  border: 2px solid #76523a;
  border-radius: 8px;
  box-shadow: 0 24px 50px rgba(55, 34, 21, 0.24);
}

.article-figure img {
  width: 100%;
  aspect-ratio: 20 / 9;
  object-fit: cover;
  image-rendering: pixelated;
}

.article-figure figcaption {
  padding: 10px 10px 4px;
  color: rgba(255, 247, 232, 0.68);
  font-size: var(--type-caption);
}

.mechanic-grid,
.feature-index,
.related-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-block: 34px 46px;
}

.mechanic-card,
.feature-index__card,
.related-card,
.callout {
  padding: 27px;
  background:
    linear-gradient(145deg, rgba(255, 247, 232, 0.48), rgba(228, 199, 155, 0.4)),
    rgba(242, 223, 186, 0.64);
  border: 2px solid rgba(95, 65, 41, 0.44);
  border-radius: 7px;
  box-shadow: inset 0 0 0 4px rgba(255, 247, 232, 0.16);
}

.mechanic-card__number,
.feature-index__icon {
  display: grid;
  width: 46px;
  height: 46px;
  margin-bottom: 22px;
  color: var(--paper-light);
  background: #294d35;
  border: 2px solid #183121;
  border-radius: 5px;
  place-items: center;
  box-shadow: inset 0 0 0 2px rgba(255, 247, 232, 0.12), 0 4px 0 #14291b;
  font-size: 22px;
  font-weight: 700;
}

.mechanic-card h3,
.feature-index__card h3,
.related-card h3 {
  margin: 0 0 10px;
  font-size: var(--type-card-title);
  line-height: 1.08;
}

.mechanic-card p,
.feature-index__card p,
.related-card p {
  margin: 0;
  font-size: var(--type-card);
  line-height: 1.42;
}

.callout {
  margin-block: 42px;
  padding: clamp(28px, 4vw, 44px);
  background:
    linear-gradient(135deg, rgba(27, 53, 35, 0.97), rgba(21, 37, 27, 0.97)),
    var(--night);
  color: var(--white);
  border-color: rgba(214, 154, 69, 0.62);
  box-shadow: inset 0 0 0 5px rgba(255, 247, 232, 0.04), 0 22px 48px rgba(36, 26, 18, 0.22);
}

.callout h2,
.callout h3 {
  margin-top: 0;
  color: var(--white);
}

.callout p,
.callout li {
  color: rgba(255, 247, 232, 0.74);
}

.callout .button {
  margin-top: 14px;
  text-decoration: none;
}

.example-task {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  margin-block: 14px;
  padding: 17px 19px;
  background: rgba(247, 231, 198, 0.62);
  border: 1px solid rgba(95, 65, 41, 0.38);
  border-radius: 5px;
}

.example-task__box {
  display: grid;
  width: 34px;
  height: 34px;
  color: var(--paper-light);
  background: #294d35;
  border: 2px solid #17301f;
  border-radius: 4px;
  place-items: center;
  font-weight: 700;
}

.example-task strong,
.example-task small {
  display: block;
}

.example-task small {
  color: #765b46;
  font-size: var(--type-action);
}

.example-task__difficulty {
  padding: 5px 9px;
  color: #53371f;
  background: rgba(214, 154, 69, 0.28);
  border: 1px solid rgba(120, 76, 35, 0.34);
  border-radius: 4px;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.related {
  padding-block: clamp(70px, 8vw, 104px);
  color: var(--white);
  background:
    radial-gradient(circle at 82% 20%, rgba(63, 102, 74, 0.23), transparent 32%),
    #17130f;
  border-top: 3px solid rgba(214, 154, 69, 0.45);
}

.related__inner {
  width: var(--container);
  margin-inline: auto;
}

.related h2 {
  max-width: 700px;
  margin: 0;
  font-size: var(--type-section-title);
  line-height: 1;
}

.related-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 0;
}

.related-card {
  display: flex;
  flex-direction: column;
  color: var(--white);
  background: rgba(255, 247, 232, 0.055);
  border-color: rgba(231, 195, 134, 0.3);
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.related-card:hover,
.related-card:focus-visible {
  background: rgba(255, 247, 232, 0.09);
  border-color: var(--gold);
  transform: translateY(-4px);
}

.related-card p {
  color: rgba(255, 247, 232, 0.62);
}

.related-card__link {
  margin-top: auto;
  padding-top: 22px;
  color: var(--gold-light);
  font-weight: 700;
}

.content-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}

.content-footer-links a:hover,
.content-footer-links a:focus-visible {
  color: var(--gold-light);
}

@media (max-width: 900px) {
  .content-hero,
  .content-hero__inner {
    min-height: 540px;
  }

  .article-layout {
    grid-template-columns: 1fr;
  }

  .article-aside {
    position: static;
    order: -1;
  }

  .related-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .content-hero,
  .content-hero__inner {
    min-height: 520px;
  }

  .content-hero__inner {
    padding-block: 62px 58px;
  }

  .content-hero h1 {
    font-size: var(--type-hero-title);
  }

  .article-shell {
    padding-block: 58px 70px;
  }

  .article-prose h2 {
    margin-top: 58px;
  }

  .article-prose p,
  .article-prose li {
    font-size: var(--type-copy);
  }

  .mechanic-grid,
  .feature-index {
    grid-template-columns: 1fr;
  }

  .mechanic-card,
  .feature-index__card,
  .related-card {
    padding: 22px;
  }

  .example-task {
    grid-template-columns: 36px minmax(0, 1fr);
  }

  .example-task__difficulty {
    grid-column: 2;
    justify-self: start;
  }
}

@media (prefers-reduced-motion: reduce) {
  .related-card {
    transition: none;
  }
}
