.visually-hidden {
  border: 0;
  clip: rect(0 0 0 0);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}

.not-found-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: #071019;
  color: #fff;
}

.not-found-page .header {
  position: static;
}

.not-found {
  width: var(--wrap);
  margin: auto;
  padding: 90px 0 120px;
}

.not-found h1 {
  max-width: 720px;
  font-size: clamp(52px, 8vw, 100px);
  line-height: .95;
  letter-spacing: -.07em;
  margin: 22px 0 28px;
}

.not-found h1 em {
  font-style: normal;
  color: var(--cyan);
}

.not-found p {
  max-width: 540px;
  color: #a8bdc8;
  font-size: 16px;
}

.not-found .btn {
  margin-top: 14px;
}

.image-viewer {
  width: min(96vw, 1400px);
  max-width: calc(100vw - 24px);
  max-height: calc(100dvh - 24px);
  padding: 0;
  border: 1px solid #31596e;
  background: #07131c;
  color: #fff;
  box-shadow: 0 30px 90px rgba(0, 0, 0, .55);
}

.image-viewer::backdrop {
  background: rgba(2, 9, 14, .8);
}

.image-viewer-inner {
  position: relative;
  display: grid;
  grid-template-rows: 36px minmax(0, 1fr) auto;
  justify-items: center;
  gap: 10px;
  padding: 18px;
  height: min(900px, calc(100dvh - 28px));
  min-width: 0;
}

.image-viewer img {
  display: block;
  grid-row: 2;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.image-viewer-caption {
  grid-row: 3;
  max-width: 900px;
  margin: 0;
  color: #a9bdc7;
  font-size: 11px;
  text-align: center;
  overflow-wrap: anywhere;
}

.image-viewer-close {
  grid-row: 1;
  justify-self: end;
  z-index: 1;
  width: 36px;
  height: 36px;
  border: 1px solid #416574;
  border-radius: 50%;
  background: #07131c;
  color: #e6f1f4;
  font-size: 25px;
  line-height: 1;
  cursor: pointer;
}

.image-viewer-close:hover {
  background: #12303e;
}

.image-viewer-close:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 2px;
}

body.image-viewer-open {
  overflow: hidden;
}

@media (max-width: 720px) {
  .image-viewer {
    max-width: calc(100vw - 12px);
    max-height: calc(100dvh - 12px);
  }

  .image-viewer-inner {
    padding: 10px;
    height: calc(100dvh - 16px);
  }

  .image-viewer img {
    max-width: 100%;
    max-height: 100%;
  }

  .image-viewer-caption {
    font-size: 10px;
  }
}
