:root {
  --white: #ffffff;
  --veil: rgba(255, 255, 255, 0.84);
  --veil-strong: rgba(255, 255, 255, 0.94);
  --frost: #eef5f6;
  --marble: #dce5e7;
  --silver: #aeb9be;
  --steel: #59646b;
  --ink: #101215;
  --muted: #5c666c;
  --ice: #c9f7ff;
  --shadow: 0 34px 110px rgba(29, 38, 45, 0.18);
  --line: rgba(16, 18, 21, 0.13);
  color-scheme: light;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  overflow-x: hidden;
  color: var(--ink);
  background: #fff;
  font-family: "Cormorant Garamond", Georgia, "Times New Roman", serif;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -4;
  pointer-events: none;
  background:
    linear-gradient(rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.9)),
    url("../img/hero-knights-zero-ultra-generated.png") center / cover no-repeat;
  filter: saturate(0.72) brightness(1.08);
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  cursor: pointer;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

img {
  display: block;
  max-width: 100%;
}

::selection {
  color: var(--ink);
  background: var(--ice);
}

.site-header {
  position: fixed;
  top: 18px;
  left: 50%;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  width: calc(100% - 36px);
  min-height: 68px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.88);
  border-bottom-color: rgba(16, 18, 21, 0.1);
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(24px) saturate(1.04);
  box-shadow: 0 20px 80px rgba(26, 35, 42, 0.13);
  transform: translateX(-50%);
}

.brand,
.site-nav {
  display: flex;
  align-items: center;
}

.brand {
  gap: 12px;
  min-width: 0;
  font-family: Cinzel, Georgia, serif;
  font-size: clamp(0.82rem, 1.2vw, 1rem);
  font-weight: 900;
}

.brand-seal {
  display: block;
  width: 34px;
  height: 46px;
  flex: 0 0 auto;
  filter: drop-shadow(0 8px 14px rgba(16, 18, 21, 0.12));
}

.brand-seal img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.menu-toggle,
.nav-scrim {
  display: none;
}

.menu-toggle {
  position: relative;
  z-index: 61;
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid rgba(16, 18, 21, 0.14);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 14px 34px rgba(26, 35, 42, 0.12);
  transition: border-color 180ms ease, background 180ms ease, transform 180ms ease;
}

.menu-toggle span {
  grid-area: 1 / 1;
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: rgba(16, 18, 21, 0.82);
  transition: transform 240ms ease, opacity 180ms ease;
}

.menu-toggle span:nth-child(1) {
  transform: translateY(-6px);
}

.menu-toggle span:nth-child(3) {
  transform: translateY(6px);
}

.menu-toggle:hover {
  border-color: rgba(16, 18, 21, 0.22);
  background: #fff;
  transform: translateY(-1px);
}

.menu-toggle:focus-visible,
.site-nav a:focus-visible,
.dark-toggle:focus-visible,
.button:focus-visible {
  outline: 2px solid rgba(71, 184, 205, 0.72);
  outline-offset: 3px;
}

.site-nav {
  gap: 8px;
  font-family: Cinzel, Georgia, serif;
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
}

.site-nav a,
.dark-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 13px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: transparent;
  color: rgba(16, 18, 21, 0.74);
  transition: background 180ms ease, transform 180ms ease, border-color 180ms ease;
}

.site-nav a:hover {
  background: rgba(255, 255, 255, 0.8);
  border-color: rgba(16, 18, 21, 0.1);
  transform: translateY(-1px);
}

.dark-toggle {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.34);
  background: linear-gradient(135deg, #0e1114, #2f363b);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

main {
  position: relative;
  z-index: 2;
}

.cathedral-viewport,
.cathedral-section {
  position: relative;
  isolation: isolate;
  min-height: 100svh;
  overflow: hidden;
}

.hero {
  background: #fff;
}

.hero-poster,
.section-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-poster {
  filter: brightness(1.02) saturate(0.96) contrast(1.02);
  transform: scale(1.018) translate3d(0, calc(var(--parallax, 0) * -30px), 0);
}

.cathedral-veil,
.cathedral-section::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.1) 44%, rgba(255, 255, 255, 0.92) 100%),
    radial-gradient(circle at 50% 35%, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.55) 70%);
}

.cathedral-veil::after,
.cathedral-section::after {
  content: "";
  position: absolute;
  left: -5%;
  right: -5%;
  bottom: -14%;
  z-index: 2;
  height: 42%;
  pointer-events: none;
  background: radial-gradient(ellipse at center, rgba(255, 255, 255, 0.98), rgba(255, 255, 255, 0) 70%);
}

.hero-inscription {
  position: absolute;
  left: clamp(24px, 6vw, 88px);
  bottom: clamp(30px, 6vw, 74px);
  z-index: 3;
  max-width: 520px;
  text-shadow: 0 2px 20px rgba(255, 255, 255, 0.98);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 16px;
  color: rgba(16, 18, 21, 0.62);
  font-family: Cinzel, Georgia, serif;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 44px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(16, 18, 21, 0.52), transparent);
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  font-family: Cinzel, Georgia, serif;
  letter-spacing: 0;
}

h1 {
  max-width: 500px;
  margin-bottom: 16px;
  font-size: clamp(2.8rem, 5.4vw, 6rem);
  line-height: 0.88;
  font-weight: 900;
}

h2 {
  max-width: 980px;
  margin-bottom: 0;
  font-size: clamp(2.35rem, 5.6vw, 6.4rem);
  line-height: 0.92;
  font-weight: 900;
}

h3 {
  margin-bottom: 12px;
  font-size: clamp(1.15rem, 1.7vw, 1.55rem);
  line-height: 1.08;
  font-weight: 800;
}

.hero-inscription p:not(.eyebrow),
.section-title p:not(.eyebrow) {
  color: rgba(16, 18, 21, 0.72);
  font-size: clamp(1.05rem, 1.45vw, 1.28rem);
  line-height: 1.45;
  font-weight: 600;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0 20px;
  overflow: hidden;
  border: 1px solid rgba(16, 18, 21, 0.14);
  border-radius: 999px;
  font-family: Cinzel, Georgia, serif;
  font-size: 0.8rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.button::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 0 34%, rgba(255, 255, 255, 0.75) 48%, transparent 64%);
  transform: translateX(-120%);
  transition: transform 520ms ease;
}

.button:hover {
  border-color: rgba(16, 18, 21, 0.24);
  box-shadow: 0 18px 46px rgba(255, 255, 255, 0.72);
  transform: translateY(-2px);
}

.button:hover::before {
  transform: translateX(120%);
}

.button.primary {
  color: #fff;
  background: linear-gradient(135deg, #111417, #354047 60%, #e8f5f7);
}

.button.ghost {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(16px);
}

.decree-band {
  position: relative;
  z-index: 4;
  overflow: hidden;
  border-block: 1px solid rgba(16, 18, 21, 0.09);
  background: rgba(255, 255, 255, 0.9);
}

.decree-band::before,
.decree-band::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 2;
  width: 12%;
  pointer-events: none;
}

.decree-band::before {
  left: 0;
  background: linear-gradient(90deg, #fff, transparent);
}

.decree-band::after {
  right: 0;
  background: linear-gradient(270deg, #fff, transparent);
}

.decree-track {
  display: flex;
  width: max-content;
  animation: decree 38s linear infinite;
}

.decree-track span {
  padding: 20px 28px;
  color: rgba(16, 18, 21, 0.66);
  font-family: Cinzel, Georgia, serif;
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
  white-space: nowrap;
}

.section-bg {
  background:
    linear-gradient(var(--veil), var(--veil-strong)),
    url("../img/hero-knights-zero-ultra-generated.png") center / cover no-repeat;
  filter: saturate(0.64) brightness(1.08);
  transform: scale(1.05);
}

.chronicle-section .section-bg {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.94), rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.9)),
    url("../img/hero-knights-zero-ultra-generated.png") center / cover no-repeat;
}

.realm-section .section-bg {
  background:
    linear-gradient(rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.9)),
    url("../img/hero-knights-zero-ultra-generated.png") center / cover no-repeat;
}

.light-section .section-bg {
  background:
    linear-gradient(rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.84)),
    url("../img/hero-knights-zero-ultra-generated.png") center / cover no-repeat;
}

.section-inner {
  position: relative;
  z-index: 3;
  width: 100%;
  min-height: 100svh;
  padding: clamp(108px, 13vh, 160px) clamp(22px, 6vw, 92px);
}

.section-title {
  width: min(100%, 1180px);
  margin-bottom: clamp(42px, 7vw, 86px);
}

.section-title.wide {
  width: min(100%, 1320px);
}

.section-title p:not(.eyebrow) {
  max-width: 760px;
  margin-top: 26px;
}

.section-title.centered {
  width: 100%;
  text-align: center;
}

.section-title.centered .eyebrow {
  justify-content: center;
}

.chronicle {
  display: grid;
  border-top: 1px solid var(--line);
}

.chronicle article {
  display: grid;
  grid-template-columns: minmax(130px, 0.18fr) minmax(220px, 0.34fr) minmax(360px, 1fr);
  gap: clamp(20px, 4vw, 56px);
  align-items: start;
  padding: clamp(30px, 5vw, 64px) 0;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.54), rgba(255, 255, 255, 0.08));
  backdrop-filter: blur(10px);
}

.chronicle article > span {
  color: rgba(16, 18, 21, 0.62);
  font-family: Cinzel, Georgia, serif;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.chronicle p,
.realm-copy p,
.site-footer p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.35vw, 1.28rem);
  line-height: 1.55;
  font-weight: 600;
}

.realm-inner {
  display: grid;
  grid-template-columns: minmax(300px, 1fr) minmax(240px, 0.42fr);
  gap: clamp(38px, 7vw, 110px);
  align-items: center;
}

.realm-copy {
  max-width: 980px;
}

.realm-copy blockquote {
  max-width: 820px;
  margin: clamp(34px, 5vw, 58px) 0 0;
  padding: 28px 0 0;
  border-top: 1px solid var(--line);
  color: rgba(16, 18, 21, 0.72);
  font-size: clamp(1.45rem, 2.6vw, 2.35rem);
  font-style: italic;
  line-height: 1.22;
}

.realm-can {
  justify-self: center;
  width: min(330px, 72vw);
  filter:
    drop-shadow(0 36px 44px rgba(16, 18, 21, 0.2))
    drop-shadow(0 0 60px rgba(255, 255, 255, 0.9));
  animation: canAscend 5s ease-in-out infinite;
}

.light-inner {
  display: grid;
  align-content: center;
  justify-items: center;
  text-align: center;
}

.light-inner > img {
  width: 78px;
  height: 118px;
  margin-bottom: 30px;
  object-fit: contain;
  opacity: 0.72;
}

.light-inner h2 {
  max-width: 980px;
}

.light-inner p:not(.eyebrow) {
  max-width: 740px;
  margin: 28px auto 0;
  color: var(--muted);
  font-size: clamp(1.12rem, 1.6vw, 1.45rem);
  line-height: 1.55;
  font-weight: 600;
}

.site-footer {
  position: relative;
  z-index: 3;
  display: grid;
  justify-items: center;
  gap: 16px;
  padding: 54px clamp(22px, 6vw, 92px) 70px;
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
  text-align: center;
}

.site-footer img {
  width: 36px;
  height: 54px;
  object-fit: contain;
  opacity: 0.72;
}

[data-reveal] {
  opacity: 0;
  transform: translate3d(0, 34px, 0);
  transition:
    opacity 820ms cubic-bezier(0.22, 1, 0.36, 1),
    transform 820ms cubic-bezier(0.22, 1, 0.36, 1);
  transition-delay: calc(var(--reveal-index, 0) * 80ms);
}

[data-reveal].is-visible,
.hero-inscription [data-reveal] {
  opacity: 1;
  transform: none;
}

.flashbang {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: grid;
  place-items: center;
  pointer-events: none;
  background: #fff;
  opacity: 0;
  visibility: hidden;
}

.death-message {
  display: grid;
  justify-items: center;
  gap: 18px;
  width: min(920px, calc(100% - 36px));
  color: rgba(16, 18, 21, 0.86);
  text-align: center;
  text-shadow: 0 0 22px rgba(255, 255, 255, 1);
}

.death-message::before,
.death-message::after {
  content: "";
  width: min(640px, 80vw);
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(16, 18, 21, 0.28), transparent);
}

.death-message strong {
  font-family: Cinzel, Georgia, serif;
  font-size: clamp(2rem, 6vw, 5.2rem);
  font-weight: 500;
  letter-spacing: 0;
  text-transform: uppercase;
}

.death-message span {
  color: rgba(16, 18, 21, 0.62);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(1.25rem, 2.2vw, 2rem);
  font-style: italic;
  font-weight: 600;
}

body.flashbang-active .flashbang {
  visibility: visible;
  animation: flashbang 5.5s ease-out forwards;
}

body.flashbang-active .death-message {
  animation: deathMessage 5.5s ease-out forwards;
}

@keyframes canAscend {
  0%,
  100% {
    translate: 0 0;
  }
  50% {
    translate: 0 -16px;
  }
}

@keyframes decree {
  to {
    transform: translateX(-50%);
  }
}

@keyframes flashbang {
  0% {
    opacity: 0;
  }
  7%,
  68% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}

@keyframes deathMessage {
  0%,
  16% {
    opacity: 0;
    transform: translateY(14px) scale(1.03);
    filter: blur(8px);
  }
  28%,
  78% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
  100% {
    opacity: 0;
    transform: translateY(-8px) scale(0.99);
    filter: blur(5px);
  }
}

@media (max-width: 980px) {
  body.nav-open {
    overflow: hidden;
  }

  .menu-toggle {
    display: grid;
    margin-left: auto;
  }

  body.nav-open .menu-toggle span:nth-child(1) {
    transform: rotate(45deg);
  }

  body.nav-open .menu-toggle span:nth-child(2) {
    opacity: 0;
  }

  body.nav-open .menu-toggle span:nth-child(3) {
    transform: rotate(-45deg);
  }

  .nav-scrim {
    position: fixed;
    inset: 0;
    z-index: 45;
    display: block;
    pointer-events: none;
    background: rgba(255, 255, 255, 0.42);
    opacity: 0;
    backdrop-filter: blur(1px);
    transition: opacity 220ms ease;
  }

  body.nav-open .nav-scrim {
    pointer-events: auto;
    opacity: 1;
  }

  .site-nav {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    z-index: 62;
    display: grid;
    width: min(360px, calc(100vw - 20px));
    max-height: calc(100svh - 98px);
    gap: 10px;
    padding: 14px;
    overflow: auto;
    border: 1px solid rgba(16, 18, 21, 0.12);
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(245, 250, 251, 0.92)),
      radial-gradient(circle at 50% 0%, rgba(201, 247, 255, 0.24), transparent 56%);
    box-shadow: 0 34px 88px rgba(26, 35, 42, 0.2);
    opacity: 0;
    pointer-events: none;
    transform: translate3d(0, -8px, 0) scale(0.98);
    transform-origin: top right;
    transition:
      opacity 220ms ease,
      transform 260ms cubic-bezier(0.22, 1, 0.36, 1),
      visibility 220ms ease;
    visibility: hidden;
  }

  body.nav-open .site-nav {
    opacity: 1;
    pointer-events: auto;
    transform: none;
    visibility: visible;
  }

  .site-nav a,
  .site-nav .dark-toggle {
    width: 100%;
    min-height: 52px;
    justify-content: flex-start;
    padding-inline: 16px;
    border-color: rgba(16, 18, 21, 0.1);
    background: rgba(255, 255, 255, 0.68);
  }

  .site-nav .dark-toggle {
    justify-content: center;
    background: linear-gradient(135deg, #0e1114, #2f363b);
  }

  .site-header {
    width: calc(100% - 20px);
  }

  .hero-inscription {
    left: 22px;
    right: 22px;
    bottom: 26px;
    max-width: none;
  }

  .realm-inner {
    grid-template-columns: 1fr;
  }

  .chronicle article {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}

@media (max-width: 560px) {
  .site-header {
    top: 10px;
    min-height: 58px;
  }

  .brand {
    font-size: 0.78rem;
  }

  .brand-seal {
    width: 28px;
    height: 40px;
  }

  .brand-seal img {
    width: 100%;
    height: 100%;
  }

  .hero-poster {
    object-position: center;
  }

  .cathedral-veil {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.06) 46%, rgba(255, 255, 255, 0.94) 100%),
      linear-gradient(90deg, rgba(255, 255, 255, 0.38), rgba(255, 255, 255, 0.02) 62%);
  }

  h1 {
    max-width: 350px;
    font-size: clamp(2rem, 11vw, 3rem);
    line-height: 0.98;
  }

  h2 {
    font-size: clamp(2rem, 10vw, 3.1rem);
    line-height: 1;
  }

  .hero-inscription p:not(.eyebrow) {
    max-width: 300px;
    font-size: 1rem;
  }

  .hero-actions {
    display: grid;
    width: 100%;
  }

  .button {
    width: 100%;
  }

  .section-inner {
    padding: 96px 22px;
  }

  .chronicle article {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .realm-can {
    width: min(250px, 76vw);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 1ms !important;
  }
}
