@import url("_shared.css");

.page-404 .page-main {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.page-404 .page-section--404 {
  flex: 1;
  padding-block: var(--subpage-content-padding-block);
}

.page-404 .page-section--404 .page-section__inner {
  min-height: calc(100dvh - var(--header-height) - calc(120px * var(--subpage-coord-scale)));
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.page-404 .err-number {
  position: absolute;
  font-size: clamp(calc(200px * var(--subpage-coord-scale)), 28vw, calc(380px * var(--subpage-coord-scale)));
  font-weight: var(--font-weight-bold);
  line-height: 1;
  letter-spacing: -0.04em;
  color: transparent;
  -webkit-text-stroke: 1px rgb(30 111 217 / 0.12);
  user-select: none;
  pointer-events: none;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -52%);
  white-space: nowrap;
}

.page-404 .err-content {
  position: relative;
  z-index: 1;
  max-width: calc(640px * var(--subpage-coord-scale));
  width: 100%;
  text-align: center;
}

.page-404 .err-label {
  font-size: calc(var(--h1-light-size) * var(--subpage-coord-scale));
  font-weight: var(--font-weight-medium);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-accent-light);
  margin-bottom: calc(24px * var(--subpage-coord-scale));
  display: flex;
  align-items: center;
  justify-content: center;
  gap: calc(12px * var(--subpage-coord-scale));
}

.page-404 .err-label::before,
.page-404 .err-label::after {
  content: "";
  display: block;
  width: calc(32px * var(--subpage-coord-scale));
  height: 1px;
  background: var(--color-accent);
  opacity: 0.6;
}

.page-404 .err-title {
  font-size: clamp(calc(40px * var(--subpage-coord-scale)), 6vw, calc(72px * var(--subpage-coord-scale)));
  font-weight: var(--font-weight-bold);
  line-height: 1.06;
  margin-bottom: calc(20px * var(--subpage-coord-scale));
}

.page-404 .err-title em {
  font-style: normal;
  color: var(--color-accent-light);
}

.page-404 .err-sub {
  font-size: var(--subpage-text-min-size);
  line-height: calc(32px * var(--subpage-coord-scale));
  opacity: 0.85;
  margin-bottom: calc(44px * var(--subpage-coord-scale));
  max-width: calc(480px * var(--subpage-coord-scale));
  margin-inline: auto;
}

.page-404 .err-ctas {
  display: flex;
  gap: calc(14px * var(--subpage-coord-scale));
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: calc(56px * var(--subpage-coord-scale));
}

.page-404 .err-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: calc(14px * var(--subpage-coord-scale)) calc(28px * var(--subpage-coord-scale));
  border-radius: calc(6px * var(--subpage-coord-scale));
  font-size: calc(var(--h1-light-size) * var(--subpage-coord-scale));
  letter-spacing: 0.07em;
  text-transform: uppercase;
  border: 1px solid transparent;
}

.page-404 .err-btn--primary {
  background: var(--color-accent);
  color: #fff;
}

.page-404 .err-btn--outline {
  border-color: rgb(255 255 255 / 0.15);
}

.page-404 .err-divider {
  width: calc(40px * var(--subpage-coord-scale));
  height: 2px;
  background: var(--color-accent);
  margin: 0 auto calc(28px * var(--subpage-coord-scale));
  border-radius: 2px;
}

.page-404 .err-links {
  border: var(--subpage-card-outline);
  border-radius: var(--subpage-card-radius);
  padding: calc(28px * var(--subpage-coord-scale)) calc(32px * var(--subpage-coord-scale));
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  background: var(--subpage-card-body-bg);
}

.page-404 .err-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: calc(10px * var(--subpage-coord-scale));
  padding: calc(18px * var(--subpage-coord-scale)) calc(16px * var(--subpage-coord-scale));
  border-right: 1px solid rgb(255 255 255 / 0.08);
  transition: background 0.25s ease;
  border-radius: calc(6px * var(--subpage-coord-scale));
}

.page-404 .err-link:last-child {
  border-right: none;
}

.page-404 .err-link:hover {
  background: rgb(255 255 255 / 0.04);
}

.page-404 .err-link:hover .err-link-label {
  color: var(--color-accent-light);
}

.page-404 .err-link-icon {
  width: calc(40px * var(--subpage-coord-scale));
  height: calc(40px * var(--subpage-coord-scale));
  background: rgb(30 111 217 / 0.1);
  border: 1px solid rgb(30 111 217 / 0.2);
  border-radius: calc(8px * var(--subpage-coord-scale));
  display: flex;
  align-items: center;
  justify-content: center;
}

.page-404 .err-link-icon svg {
  width: calc(18px * var(--subpage-coord-scale));
  height: calc(18px * var(--subpage-coord-scale));
  stroke: var(--color-accent-light);
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.page-404 .err-link-label {
  font-size: calc(var(--h1-light-size) * var(--subpage-coord-scale));
  font-weight: var(--font-weight-medium);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.55;
  transition: color 0.25s ease;
}

@media (max-width: 767px) {
  .page-404 .err-links {
    grid-template-columns: 1fr;
    gap: calc(4px * var(--subpage-coord-scale));
    padding: calc(16px * var(--subpage-coord-scale));
  }

  .page-404 .err-link {
    flex-direction: row;
    border-right: none;
    border-bottom: 1px solid rgb(255 255 255 / 0.08);
    padding: calc(14px * var(--subpage-coord-scale)) calc(16px * var(--subpage-coord-scale));
    justify-content: flex-start;
    gap: calc(14px * var(--subpage-coord-scale));
  }

  .page-404 .err-link:last-child {
    border-bottom: none;
  }

  .page-404 .err-label::before,
  .page-404 .err-label::after {
    display: none;
  }
}

@import url("../components/subpage-text.css");
