.error-page {
  display: flex;
  align-items: center;
  background: #fff;
  padding: 6.4rem 0 8rem;
}

.error-page__container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4.8rem;
  max-width: 124rem;
}

.error-page__copy {
  flex: 0 1 52rem;
  max-width: 52rem;
}

.error-page__title {
  margin: 0;
  font-size: 5.6rem;
  letter-spacing: -0.03em;
}

.error-page__text {
  margin: 1.6rem 0 0;
  max-width: 42rem;
  color: #5c5c5c;
  font-size: 1.8rem;
  line-height: 1.45;
}

.error-page__home {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 5.6rem;
  margin-top: 3.2rem;
  padding: 1.4rem 2.8rem;
  border-radius: 1.2rem;
  background: #111111;
  color: #fdb602;
  font-size: 1.6rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.error-page__home:hover {
  background: #2a2a2a;
  color: #ffd61d;
}

.error-page__home:focus-visible {
  outline: 0.2rem solid #fdb602;
  outline-offset: 0.3rem;
}

.error-page__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem 2.4rem;
  margin-top: 2rem;
}

.error-page__links a {
  color: #1a1a1a;
  font-size: 1.5rem;
  font-weight: 500;
  line-height: 1.4;
  text-decoration: none;
}

.error-page__links a:hover {
  color: #8a5a00;
  text-decoration: underline;
  text-underline-offset: 0.3rem;
}

.error-page__links a:focus-visible {
  outline: 0.2rem solid #fdb602;
  outline-offset: 0.3rem;
  border-radius: 0.4rem;
}

.error-page__art {
  position: relative;
  flex: 1 1 52rem;
  width: min(100%, 56rem);
  max-width: 56rem;
  aspect-ratio: 6 / 5;
  margin-left: auto;
}

.error-page__scene {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.error-page__digits {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  color: #111111;
  font-family: Sora, "Sora Fallback", system-ui, sans-serif;
  font-size: 13.6rem;
  font-weight: 700;
  line-height: 0.8;
  letter-spacing: -0.06em;
  user-select: none;
}

.error-page__digit {
  display: block;
}

.error-page__zero {
  position: relative;
  display: block;
  width: 0.74em;
  height: 0.74em;
  margin: 0 0.04em 0.04em;
  flex: none;
}

.error-page__ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: linear-gradient(145deg, #ffe08a 0%, #f5b000 46%, #e08c00 100%);
  -webkit-mask: radial-gradient(circle, transparent 57%, #000 58.5%);
  mask: radial-gradient(circle, transparent 57%, #000 58.5%);
}

.error-page__spark {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 34%;
  height: 34%;
  transform: translate(-50%, -50%);
}

@media (max-width: 1100px) {
  .error-page__digits {
    font-size: 11rem;
  }
}

@media (max-width: 960px) {
  .error-page {
    align-items: flex-start;
    padding: 0.4rem 0 3.2rem;
  }

  .error-page__container {
    flex-direction: column-reverse;
    align-items: stretch;
    gap: 0;
  }

  .error-page__copy {
    max-width: none;
  }

  .error-page__art {
    flex: none;
    width: 100%;
    max-width: 32rem;
    aspect-ratio: 6 / 3.3;
    margin: 0 auto;
  }

  .error-page__digits {
    font-size: 8.4rem;
  }

  .error-page__title {
    font-size: 3.6rem;
  }
}

@media (max-width: 600px) {
  .error-page__text {
    font-size: 1.6rem;
  }

  .error-page__home {
    width: 100%;
    max-width: 32rem;
  }

  .error-page__digits {
    font-size: 8.8rem;
  }
}
