:root {
  color-scheme: dark;

  --background: #090d17;
  --panel: rgba(15, 22, 37, 0.88);
  --panel-deep: rgba(9, 14, 25, 0.97);

  --white: #edf1f8;
  --muted: #9ba9bd;
  --blue: #8bbaff;
  --bright-blue: #c3dcff;
  --gold: #c8b17d;

  --border: rgba(166, 194, 232, 0.16);
  --border-bright: rgba(166, 194, 232, 0.34);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;

  background: var(--background);
  color: var(--white);

  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.75;
}

a {
  color: inherit;
}

/* CSS-CREATED BACKGROUND */

.arcane-background {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;

  background:
    radial-gradient(
      ellipse at 50% 8%,
      rgba(48, 78, 128, 0.23),
      transparent 48%
    ),
    radial-gradient(
      ellipse at 0% 65%,
      rgba(34, 72, 120, 0.13),
      transparent 42%
    ),
    radial-gradient(
      ellipse at 100% 82%,
      rgba(75, 61, 111, 0.12),
      transparent 42%
    ),
    linear-gradient(
      180deg,
      #0c1423,
      #090d17 55%,
      #070a11
    );
}

.arcane-background::before {
  content: "";
  position: absolute;
  inset: 0;

  opacity: 0.24;

  background-image:
    linear-gradient(
      rgba(153, 185, 230, 0.045) 1px,
      transparent 1px
    ),
    linear-gradient(
      90deg,
      rgba(153, 185, 230, 0.045) 1px,
      transparent 1px
    );

  background-size: 74px 74px;

  mask-image: linear-gradient(
    to bottom,
    black,
    transparent 80%
  );
}

.arcane-background::after {
  content: "";
  position: absolute;
  inset: 0;

  background:
    linear-gradient(
      90deg,
      rgba(5, 8, 15, 0.36),
      transparent 30%,
      transparent 70%,
      rgba(5, 8, 15, 0.36)
    );
}

.arcane-orb {
  position: absolute;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  filter: blur(75px);
  opacity: 0.15;
}

.orb-one {
  top: 18%;
  left: -190px;
  background: #3569bd;
}

.orb-two {
  top: 58%;
  right: -210px;
  background: #65509c;
}

.rune-circle {
  position: absolute;
  width: 450px;
  height: 450px;

  border: 1px solid rgba(157, 190, 239, 0.07);
  border-radius: 50%;
}

.rune-circle::before,
.rune-circle::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(157, 190, 239, 0.06);
  border-radius: 50%;
}

.rune-circle::before {
  inset: 32px;
}

.rune-circle::after {
  inset: 75px;
}

.rune-one {
  top: 80px;
  right: -300px;
}

.rune-two {
  top: 950px;
  left: -320px;
}

/* HEADER */

.page-header {
  position: sticky;
  top: 0;
  z-index: 10;

  min-height: 76px;
  padding: 12px 5%;

  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 18px;

  background: rgba(8, 12, 21, 0.91);
  border-bottom: 1px solid var(--border);

  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.back-link {
  justify-self: start;

  color: #c3cede;
  font-family: Arial, sans-serif;
  font-size: 0.75rem;
  text-decoration: none;

  transition: color 0.2s ease;
}

.back-link:hover {
  color: var(--bright-blue);
}

.back-link span {
  margin-right: 5px;
}

.header-brand {
  display: flex;
  flex-direction: column;
  align-items: center;

  font-family: Arial, sans-serif;
  font-size: 0.67rem;
  letter-spacing: 0.16em;
  text-align: center;
}

.header-brand small {
  margin-top: 4px;

  color: var(--muted);
  font-size: 0.53rem;
  letter-spacing: 0.13em;
}

.header-index {
  justify-self: end;

  color: var(--muted);
  font-family: Arial, sans-serif;
  font-size: 0.58rem;
  letter-spacing: 0.13em;
}

/* MAIN LAYOUT */

.page-content {
  width: min(1100px, calc(100% - 44px));
  margin: 0 auto;
}

.eyebrow {
  margin: 0;

  color: var(--gold);
  font-family: Arial, sans-serif;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

/* HERO */

.hero {
  position: relative;
  min-height: 480px;
  padding: 85px 15px 75px;

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;

  text-align: center;
  isolation: isolate;
}

.hero-symbol {
  position: absolute;
  z-index: -1;

  color: rgba(151, 190, 248, 0.055);
  font-size: clamp(16rem, 35vw, 26rem);
  line-height: 1;

  pointer-events: none;
}

.hero > .eyebrow {
  margin-bottom: 18px;
  color: var(--blue);
}

.hero h1 {
  margin: 0;

  color: #f1f5fc;
  font-size: clamp(2.7rem, 7vw, 5.4rem);
  font-weight: 400;
  letter-spacing: 0.015em;
  line-height: 1.15;

  text-shadow: 0 8px 35px rgba(0, 0, 0, 0.45);
}

.hero h1 span {
  color: var(--blue);
  font-style: italic;
}

.hero-divider {
  width: min(310px, 78%);
  margin: 25px 0 17px;

  display: flex;
  align-items: center;
  gap: 14px;
}

.hero-divider > span {
  flex: 1;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(151, 190, 248, 0.55)
  );
}

.hero-divider > span:last-child {
  transform: rotate(180deg);
}

.hero-divider i {
  color: var(--bright-blue);
  font-size: 0.9rem;
  font-style: normal;
}

.hero-description {
  max-width: 570px;
  margin: 0;

  color: #b9c5d8;
  font-size: 0.96rem;
  line-height: 2;
}

.archive-status {
  margin-top: 26px;
  padding: 8px 13px;

  display: flex;
  align-items: center;
  gap: 9px;

  border: 1px solid var(--border);
  background: rgba(11, 19, 32, 0.6);

  color: #bdcbe0;
  font-family: Arial, sans-serif;
  font-size: 0.56rem;
  letter-spacing: 0.13em;
}

.status-light {
  width: 6px;
  height: 6px;
  border-radius: 50%;

  background: #9bbef4;
  box-shadow: 0 0 12px rgba(139, 186, 255, 0.8);
}

/* ARCHIVE SECTION */

.archive-section {
  padding: 40px 0 75px;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 20px;
}

.section-heading .eyebrow {
  margin-bottom: 8px;
}

.section-heading h2 {
  margin: 0;

  color: var(--white);
  font-size: clamp(1.65rem, 4vw, 2.4rem);
  font-weight: 400;
  line-height: 1.3;
}

.record-count {
  flex-shrink: 0;
  padding: 7px 10px;

  border: 1px solid var(--border);

  color: #a9bad3;
  font-family: Arial, sans-serif;
  font-size: 0.54rem;
  letter-spacing: 0.12em;
}

.section-description {
  max-width: 620px;
  margin: 13px 0 30px;

  color: var(--muted);
  font-size: 0.87rem;
}

/* TWO-COLUMN ARTIFACT GRID */

.artifact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  align-items: start;
}

.artifact-card-link {
  display: block;
  min-width: 0;

  color: inherit;
  text-decoration: none;
}

.artifact-card {
  min-width: 0;
  aspect-ratio: 2 / 1;

  display: flex;
  flex-direction: column;

  overflow: hidden;

  border: 1px solid var(--border);
  background: var(--panel);

  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.17);

  transition:
    transform 0.25s ease,
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}

.artifact-card-link:hover .artifact-card {
  transform: translateY(-4px);

  border-color: var(--border-bright);

  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.23),
    0 0 25px rgba(83, 132, 208, 0.05);
}

.artifact-card-link:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 5px;
}

.artifact-visual {
  position: relative;
  flex: 1;
  min-height: 0;

  display: flex;
  align-items: center;
  justify-content: center;

  overflow: hidden;
  isolation: isolate;
}

.visual-index {
  position: absolute;
  top: 12px;
  left: 14px;
  z-index: 3;

  color: #9baecb;
  font-family: Arial, sans-serif;
  font-size: 0.5rem;
  letter-spacing: 0.14em;
}

/* VISUAL CORNERS */

.visual-corner {
  position: absolute;
  z-index: 3;

  width: 15px;
  height: 15px;

  border-color: rgba(164, 194, 237, 0.55);
  border-style: solid;
}

.corner-tl {
  top: 10px;
  left: 10px;
  border-width: 1px 0 0 1px;
}

.corner-tr {
  top: 10px;
  right: 10px;
  border-width: 1px 1px 0 0;
}

.corner-bl {
  bottom: 10px;
  left: 10px;
  border-width: 0 0 1px 1px;
}

.corner-br {
  right: 10px;
  bottom: 10px;
  border-width: 0 1px 1px 0;
}

/* SKYSHIP */

.skyship-visual {
  background:
    radial-gradient(
      ellipse at center,
      rgba(49, 94, 158, 0.23),
      transparent 55%
    ),
    linear-gradient(
      145deg,
      #121f35,
      #0a101d 70%,
      #101827
    );
}

.skyship-visual::before {
  content: "";
  position: absolute;
  inset: 0;

  background:
    linear-gradient(
      35deg,
      transparent 48%,
      rgba(147, 186, 244, 0.055) 49%,
      transparent 50%
    ),
    linear-gradient(
      145deg,
      transparent 48%,
      rgba(147, 186, 244, 0.045) 49%,
      transparent 50%
    );

  background-size: 45px 45px;
}

.skyship-sigil {
  position: relative;
  width: 92px;
  height: 92px;

  display: grid;
  place-items: center;

  border: 1px solid rgba(154, 191, 243, 0.38);
  border-radius: 50%;

  color: rgba(196, 220, 255, 0.62);
  font-size: 2.8rem;

  box-shadow:
    0 0 45px rgba(72, 123, 204, 0.09),
    inset 0 0 35px rgba(72, 123, 204, 0.07);
}

.skyship-sigil i {
  position: absolute;
  inset: -12px;

  border: 1px dashed rgba(154, 191, 243, 0.2);
  border-radius: 50%;
}

.design-seal {
  position: absolute;
  z-index: 2;
  bottom: 17px;

  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;

  text-align: center;
}

.seal-symbol {
  color: #c4d9f9;
  font-size: 1rem;
}

.design-seal > span:nth-child(2) {
  color: #c8d9f0;
  font-family: Arial, sans-serif;
  font-size: 0.55rem;
  letter-spacing: 0.14em;
}

.design-seal small {
  color: #8497b2;
  font-family: Arial, sans-serif;
  font-size: 0.46rem;
  letter-spacing: 0.1em;
}

/* ARTIFACT INFORMATION */

.artifact-information {
  flex: 0 0 42%;
  min-height: 0;
  padding: 15px 17px;

  display: flex;
  flex-direction: column;
  justify-content: center;

  background: rgba(9, 14, 24, 0.97);
  border-top: 1px solid var(--border);
  overflow: hidden;
}

.artifact-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px 10px;
}

.artifact-category,
.available-status,
.sealed-status {
  font-family: Arial, sans-serif;
  font-size: 0.47rem;
  letter-spacing: 0.1em;
}

.artifact-category {
  color: var(--blue);
}

.available-status {
  color: #b8cde8;
}

.sealed-status {
  color: #a6a7b4;
}

.artifact-information h3 {
  margin: 5px 0 2px;

  color: #edf2fa;
  font-size: clamp(1rem, 2vw, 1.45rem);
  font-weight: 400;
  line-height: 1.3;
}

.artifact-information > p {
  margin: 2px 0 8px;

  color: #aab7ca;
  font-size: clamp(0.65rem, 1vw, 0.78rem);
  line-height: 1.55;
}

.artifact-footer {
  margin-top: auto;
  padding-top: 7px;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;

  border-top: 1px solid rgba(166, 194, 232, 0.1);

  color: #8298b8;
  font-family: Arial, sans-serif;
  font-size: 0.47rem;
  letter-spacing: 0.08em;
}

.open-record {
  color: #c6dafa;
}

.open-record b {
  margin-left: 4px;
  font-size: 0.75rem;
}

/* SEALED CARDS */

.sealed-card {
  background: rgba(9, 12, 20, 0.95);
}

.sealed-visual {
  background:
    radial-gradient(
      ellipse at 50% 45%,
      rgba(102, 117, 143, 0.13),
      transparent 60%
    ),
    linear-gradient(
      145deg,
      #141824,
      #080b12 75%
    );
}

.sealed-visual::before {
  content: "";
  position: absolute;
  inset: 0;

  background-image:
    linear-gradient(
      rgba(181, 191, 210, 0.025) 1px,
      transparent 1px
    ),
    linear-gradient(
      90deg,
      rgba(181, 191, 210, 0.025) 1px,
      transparent 1px
    );

  background-size: 30px 30px;
}

.watcher-visual::after {
  content: "";
  position: absolute;
  width: 140px;
  height: 140px;

  border: 1px solid rgba(171, 182, 204, 0.08);
  border-radius: 50%;

  box-shadow:
    0 0 0 18px rgba(171, 182, 204, 0.018),
    0 0 0 38px rgba(171, 182, 204, 0.014);
}

.sealed-symbol {
  position: relative;
  z-index: 1;

  width: 75px;
  height: 75px;

  display: grid;
  place-items: center;

  border: 1px solid rgba(168, 185, 215, 0.18);
  border-radius: 50%;

  color: rgba(184, 197, 221, 0.34);
  font-size: 2.2rem;
}

.sealed-symbol i {
  position: absolute;
  inset: -9px;

  border: 1px dashed rgba(168, 185, 215, 0.12);
  border-radius: 50%;
}

.sealed-symbol b {
  position: absolute;
  inset: 14px;

  border: 1px solid rgba(168, 185, 215, 0.12);
  border-radius: 50%;
}

.sealed-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;

  background: rgba(5, 8, 14, 0.29);
  text-align: center;
}

.lock-symbol {
  color: #b6bfd0;
  font-size: 1.1rem;
}

.sealed-overlay strong {
  color: #d0d6e1;
  font-family: Arial, sans-serif;
  font-size: 0.57rem;
  font-weight: 400;
  letter-spacing: 0.17em;
}

.sealed-overlay small {
  color: #858fa1;
  font-family: Arial, sans-serif;
  font-size: 0.46rem;
  letter-spacing: 0.12em;
}

.diary-silhouette {
  position: relative;
  width: 66px;
  height: 90px;

  transform: rotate(-7deg);
  opacity: 0.3;
}

.diary-pages {
  position: absolute;
  inset: 5px -5px -4px 5px;

  border: 1px solid #c0c6d2;
  background: #555d6b;
}

.diary-cover {
  position: absolute;
  inset: 0;

  display: grid;
  place-items: center;

  border: 1px solid #7d8ba3;
  background: linear-gradient(135deg, #303b50, #111723);

  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.diary-cover span {
  color: #aab8d0;
  font-size: 1.8rem;
}

/* SEALED RECORD MESSAGES */

.hidden-description {
  color: #858d9c !important;
}

.coming-message {
  margin-top: auto;
  padding-top: 7px;

  display: flex;
  align-items: center;
  gap: 7px;

  border-top: 1px solid rgba(166, 194, 232, 0.1);

  color: #9ba8bc;
  font-family: Arial, sans-serif;
  font-size: 0.47rem;
  letter-spacing: 0.1em;
}

.coming-message span {
  color: #9eacc3;
  font-size: 0.85rem;
}

/* ENDING */

.archive-ending {
  padding: 70px 15px 95px;

  display: flex;
  flex-direction: column;
  align-items: center;

  text-align: center;
}

.ending-symbol {
  margin-bottom: 13px;
  color: var(--blue);
  font-size: 1.4rem;
}

.archive-ending h2 {
  max-width: 650px;
  margin: 13px 0;

  color: var(--white);
  font-size: clamp(1.6rem, 4vw, 2.5rem);
  font-weight: 400;
  line-height: 1.4;
}

.archive-ending > p:not(.eyebrow) {
  max-width: 500px;
  margin: 0 0 26px;

  color: var(--muted);
  font-size: 0.85rem;
}

.return-link {
  display: inline-block;
  padding: 11px 17px;

  border: 1px solid var(--border-bright);
  background: rgba(12, 19, 32, 0.7);

  color: #c6dafa;
  font-family: Arial, sans-serif;
  font-size: 0.68rem;
  text-decoration: none;

  transition: background 0.2s ease;
}

.return-link:hover {
  background: rgba(110, 153, 218, 0.12);
}

.return-link span {
  margin-right: 8px;
}

/* FOOTER */

.page-footer {
  padding: 17px 5%;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;

  border-top: 1px solid var(--border);
  background: rgba(6, 9, 15, 0.82);

  color: #818da1;
  font-family: Arial, sans-serif;
  font-size: 0.51rem;
  letter-spacing: 0.1em;
}

/* TABLET */

@media (max-width: 800px) {
  .page-content {
    width: calc(100% - 32px);
  }

  .artifact-grid {
    gap: 15px;
  }

  .artifact-information {
    flex-basis: 46%;
    padding: 11px 12px;
  }

  .artifact-footer {
    font-size: 0.42rem;
  }

  .artifact-category,
  .available-status,
  .sealed-status {
    font-size: 0.41rem;
  }
}

/* MOBILE */

@media (max-width: 560px) {
  .page-header {
    min-height: 68px;
    padding: 10px 13px;
    gap: 8px;
  }

  .back-link {
    font-size: 0.62rem;
  }

  .header-brand {
    font-size: 0.54rem;
    letter-spacing: 0.08em;
  }

  .header-brand small {
    font-size: 0.43rem;
  }

  .header-index {
    font-size: 0.46rem;
    letter-spacing: 0.05em;
  }

  .page-content {
    width: calc(100% - 28px);
  }

  .hero {
    min-height: 430px;
    padding: 65px 8px;
  }

  .hero-description {
    font-size: 0.85rem;
  }

  .archive-section {
    padding-top: 25px;
  }

  .section-heading {
    align-items: start;
  }

  .section-heading h2 {
    font-size: 1.65rem;
  }

  .record-count {
    padding: 6px;
    font-size: 0.45rem;
  }

  .artifact-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  /*
    Keep every card at the same 2:1 ratio,
    even when there is an odd number of cards.
  */

  .artifact-card {
    aspect-ratio: 2 / 1;
  }

  .artifact-information {
    flex-basis: 42%;
    padding: 12px 15px;
  }

  .artifact-information h3 {
    font-size: 1.2rem;
  }

  .artifact-information > p {
    font-size: 0.72rem;
  }

  .artifact-category,
  .available-status,
  .sealed-status {
    font-size: 0.45rem;
  }

  .artifact-footer,
  .coming-message {
    font-size: 0.45rem;
  }

  .archive-ending {
    padding: 55px 5px 70px;
  }

  .page-footer {
    padding: 15px 12px;
    flex-wrap: wrap;
    font-size: 0.43rem;
    letter-spacing: 0.05em;
  }
}

/* ACCESSIBILITY */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}
/* SEALED ARTIFACT MESSAGE */

body.message-open {
  overflow: hidden;
}

.sealed-card {
  cursor: pointer;
}

.sealed-card:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 4px;
}

.sealed-message-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;

  display: flex;
  align-items: center;
  justify-content: center;

  padding: 20px;

  background: rgba(3, 5, 10, 0.84);
  backdrop-filter: blur(9px);
  -webkit-backdrop-filter: blur(9px);

  opacity: 0;
  visibility: hidden;
  pointer-events: none;

  transition:
    opacity 0.25s ease,
    visibility 0.25s ease;
}

.sealed-message-overlay.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.sealed-message-box {
  width: min(420px, 100%);
  padding: 35px 27px;

  text-align: center;

  background:
    radial-gradient(
      circle at 50% 0%,
      rgba(106, 126, 163, 0.14),
      transparent 55%
    ),
    #0b101b;

  border: 1px solid rgba(157, 178, 212, 0.3);

  box-shadow:
    0 25px 80px rgba(0, 0, 0, 0.6),
    0 0 35px rgba(92, 119, 168, 0.08);
}

.message-symbol {
  width: 54px;
  height: 54px;
  margin: 0 auto 18px;

  display: grid;
  place-items: center;

  border: 1px solid rgba(166, 194, 232, 0.3);
  border-radius: 50%;

  color: #c1cde0;
  font-size: 1.7rem;
}

.message-eyebrow {
  margin: 0 0 9px;

  color: var(--gold);
  font-family: Arial, sans-serif;
  font-size: 0.58rem;
  letter-spacing: 0.18em;
}

.sealed-message-box h2 {
  margin: 0;

  color: var(--white);
  font-size: 1.9rem;
  font-weight: 400;
  line-height: 1.35;
}

.message-description {
  margin: 17px 0 22px;

  color: #aebbd0;
  font-size: 0.88rem;
  line-height: 1.9;
}

.message-status {
  display: inline-block;
  padding: 6px 11px;

  border: 1px solid rgba(166, 194, 232, 0.2);

  color: #aabbd4;
  font-family: Arial, sans-serif;
  font-size: 0.54rem;
  letter-spacing: 0.14em;
}

.message-close {
  display: block;
  margin: 25px auto 0;
  padding: 11px 20px;

  border: 1px solid rgba(166, 194, 232, 0.35);
  background: rgba(101, 132, 184, 0.08);

  color: #d4e2f7;
  font-family: Arial, sans-serif;
  font-size: 0.68rem;

  cursor: pointer;
  transition: background 0.2s ease;
}

.message-close:hover {
  background: rgba(101, 132, 184, 0.2);
}

.message-close:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 4px;
}

@media (prefers-reduced-motion: reduce) {
  .sealed-message-overlay {
    transition: none;
  }
}