:root {
  --violet: #8a2be2;
  --violet-bright: #b77aff;
  --ink: #14101e;
  --paper: #f4efe7;
  --paper-muted: #d8d0c8;
  --night: #07050f;
  --muted: #b3aed2;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  color: #fff;
  background: var(--night);
  font-family: "Segoe UI", Roboto, sans-serif;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background: radial-gradient(circle at 72% 48%, rgba(83, 27, 132, .20), transparent 34%),
    radial-gradient(circle at 12% 80%, rgba(138, 43, 226, .10), transparent 28%), #07050f;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: .15;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.35'/%3E%3C/svg%3E");
}

.album-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 8%;
  background: rgba(7, 5, 15, .78);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(138, 43, 226, .22);
}

.logo-text {
  color: #fff;
  text-decoration: none;
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 1px;
}

.purple-text {
  color: var(--violet);
  text-shadow: 0 0 10px rgba(138, 43, 226, .5);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 25px;
}

.nav-links a {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
  transition: color .25s ease, background .25s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--violet-bright);
}

.nav-links .live-button {
  padding: 8px 18px;
  border: 1px solid var(--violet);
  border-radius: 30px;
  box-shadow: 0 0 10px rgba(138, 43, 226, .2);
}

.nav-links .live-button:hover {
  color: #fff;
  background: var(--violet);
}

.album-stage {
  width: min(1180px, 92vw);
  margin: 0 auto;
  padding: clamp(54px, 8vw, 100px) 0 90px;
}

.intro {
  max-width: 800px;
  margin-left: 6%;
  animation: rise .8s ease both;
}

.eyebrow,
.page-kicker {
  color: var(--violet-bright);
  text-transform: uppercase;
  letter-spacing: .2em;
  font-size: .7rem;
  font-weight: 700;
}

.eyebrow span {
  margin-left: 8px;
}

.intro h1 {
  margin: 16px 0 8px;
  font-size: clamp(1.8rem, 5.2vw, 4.2rem);
  line-height: 1.05;
  letter-spacing: -.04em;
  font-weight: 800;
  white-space: nowrap;
}

.intro h1 em {
  color: var(--violet-bright);
  font-style: normal;
}

.intro-copy {
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.book-scene {
  position: relative;
  display: flex;
  justify-content: center;
  margin-top: clamp(46px, 7vw, 82px);
  perspective: 1800px;
}

.book {
  position: relative;
  width: min(760px, 88vw);
  height: min(510px, 62vw);
  min-height: 430px;
  transform: rotateX(7deg) rotateY(-10deg) rotateZ(-1.2deg);
  transform-style: preserve-3d;
  animation: book-in 1.15s cubic-bezier(.2, .8, .2, 1) .12s both;
}

.book-shadow {
  position: absolute;
  width: 93%;
  height: 22px;
  left: 5%;
  bottom: -40px;
  background: #000;
  filter: blur(22px);
  opacity: .8;
  transform: translateZ(-30px) rotate(-2deg);
}

.book-cover,
.book-page {
  position: absolute;
  inset: 0;
  border-radius: 3px 12px 12px 3px;
  overflow: hidden;
}

.cover-front {
  z-index: 3;
  width: 50%;
  right: auto;
  color: #fff;
  background: linear-gradient(125deg, #241134, #160a24 58%, #30174b);
  border: 1px solid rgba(183, 122, 255, .5);
  box-shadow: inset -10px 0 22px rgba(0, 0, 0, .25), 0 18px 32px rgba(0, 0, 0, .45);
  transform-origin: right center;
  transition: transform 1.2s cubic-bezier(.2, .72, .2, 1);
}

.cover-front::before {
  content: "";
  position: absolute;
  inset: 18px;
  border: 1px solid rgba(183, 122, 255, .5);
  border-radius: 2px;
}

.cover-inner {
  position: absolute;
  inset: 18px;
  padding: 38px 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  border: 1px solid rgba(183, 122, 255, .22);
}

.cover-kicker,
.cover-year {
  font-size: .58rem;
  letter-spacing: .22em;
  color: #c9a8ec;
}

.cover-rule {
  width: 42px;
  height: 1px;
  margin-top: 30%;
  background: var(--violet-bright);
  box-shadow: 0 0 12px var(--violet);
}

.cover-inner h2 {
  margin: 20px 0;
  font-size: clamp(2rem, 4.4vw, 3.8rem);
  line-height: .9;
  letter-spacing: -.06em;
  font-weight: 300;
}

.cover-inner h2 strong {
  font-weight: 800;
  color: var(--violet-bright);
}

.cover-mark {
  margin-top: auto;
  color: var(--violet-bright);
  font-size: 1.3rem;
  text-shadow: 0 0 14px var(--violet);
}

.cover-year {
  margin-top: 14px;
}

.book-page {
  z-index: 2;
  left: 50%;
  width: 50%;
  color: var(--ink);
  padding: 27px 32px 22px 38px;
  background: linear-gradient(110deg, #c8c0b4, #f7f1e8 7%, #f4efe7 95%, #d6cfc5);
  box-shadow: inset 12px 0 18px rgba(37, 24, 13, .10), 0 18px 32px rgba(0, 0, 0, .26);
}

.book-page::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: .2;
  pointer-events: none;
  background: repeating-linear-gradient(0deg, transparent 0 4px, rgba(80, 60, 40, .04) 5px);
}

.page-head,
.page-foot {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  color: #9279a7;
  font-size: .58rem;
  letter-spacing: .16em;
}

.page-content {
  position: relative;
  z-index: 1;
}

.page-kicker {
  margin: 34px 0 8px;
  color: #8350b0;
  font-size: .6rem;
}

.page-content h2 {
  margin: 0;
  font-family: Georgia, serif;
  font-size: clamp(2.2rem, 4vw, 3.7rem);
  font-weight: 400;
  letter-spacing: -.06em;
}

.page-note {
  margin: 8px 0 22px;
  color: #8f8582;
  font-size: .77rem;
}

.chapter-list {
  display: grid;
  gap: 8px;
  max-height: 235px;
  overflow: auto;
  padding-right: 4px;
}

.chapter {
  position: relative;
  display: grid;
  grid-template-columns: 29px 1fr auto;
  align-items: center;
  gap: 9px;
  min-height: 48px;
  padding: 7px 8px 7px 0;
  color: var(--ink);
  text-align: left;
  border: 0;
  border-bottom: 1px solid rgba(61, 38, 24, .16);
  background: transparent;
  cursor: pointer;
  font: inherit;
  transition: color .2s, padding .2s, background .2s;
}

.chapter:hover,
.chapter:focus-visible {
  padding-left: 8px;
  color: #6d25a4;
  background: rgba(138, 43, 226, .07);
  outline: none;
}

.chapter:focus-visible {
  box-shadow: 0 0 0 2px rgba(138, 43, 226, .55);
}

.chapter[aria-disabled="true"] {
  cursor: not-allowed;
  opacity: .48;
}

.chapter-number {
  color: #9c7cb4;
  font: 700 .7rem Georgia, serif;
}

.chapter-title {
  display: block;
  font: 700 .82rem Georgia, serif;
}

.chapter-meta {
  display: block;
  margin-top: 3px;
  color: #968b89;
  font-size: .58rem;
}

.chapter-arrow {
  color: var(--violet);
  font-size: 1.1rem;
}

.page-foot {
  position: absolute;
  right: 32px;
  bottom: 22px;
  left: 38px;
}

.book-spine {
  position: absolute;
  z-index: 4;
  left: 49.3%;
  top: 0;
  width: 12px;
  height: 100%;
  background: linear-gradient(90deg, rgba(0, 0, 0, .3), rgba(170, 123, 204, .4), rgba(0, 0, 0, .2));
  transform: translateZ(9px);
}

.paper-stack {
  position: absolute;
  z-index: 1;
  inset: 7px -8px -7px 48%;
  border-radius: 3px 12px 12px 3px;
  background: repeating-linear-gradient(0deg, #eee8df 0 3px, #b8afa5 4px 5px);
  transform: translateZ(-5px);
  box-shadow: 7px 15px 20px rgba(0, 0, 0, .35);
}

.riffle-layer {
  position: absolute;
  z-index: 5;
  inset: 0 0 0 50%;
  pointer-events: none;
}

.riffle-sheet {
  position: absolute;
  inset: 0;
  transform-origin: left center;
  border-radius: 0 12px 12px 0;
  background: linear-gradient(110deg, #d7cfc3, #f7f1e8 8%, #f4efe7 96%, #d0c7bd);
  box-shadow: 7px 8px 10px rgba(27, 15, 6, .3);
  animation: riffle .55s cubic-bezier(.2, .8, .3, 1) forwards;
}

.book.is-opening .cover-front {
  transform: rotateY(-155deg);
}

.book.is-opening .book-page {
  box-shadow: inset 12px 0 18px rgba(37, 24, 13, .18), 0 18px 32px rgba(0, 0, 0, .26);
}

.book-hint {
  margin: 48px 0 0;
  color: #8c87a4;
  text-align: center;
  font-size: .78rem;
  letter-spacing: .03em;
}

.hint-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  margin: 0 8px 1px 0;
  border-radius: 50%;
  background: var(--violet-bright);
  box-shadow: 0 0 10px var(--violet);
}

.transition-wash {
  position: fixed;
  inset: 0;
  z-index: 50;
  pointer-events: none;
  opacity: 0;
  background: #10081b;
  transition: opacity .35s ease;
}

.transition-wash.visible {
  opacity: 1;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes book-in {
  from {
    opacity: 0;
    transform: rotateX(13deg) rotateY(-25deg) translateY(26px);
  }

  to {
    opacity: 1;
    transform: rotateX(7deg) rotateY(-10deg) rotateZ(-1.2deg);
  }
}

@keyframes riffle {
  0% {
    transform: rotateY(0) translateX(0);
    opacity: .95;
  }

  100% {
    transform: rotateY(-165deg) translateX(-16px);
    opacity: 0;
  }
}

@media (max-width: 680px) {
  .album-header {
    padding: 16px 5%;
  }

  .logo-text {
    font-size: 1.25rem;
  }

  .nav-links {
    gap: 12px;
    font-size: .78rem;
  }

  .nav-links a:nth-child(2) {
    display: none;
  }

  .nav-links .live-button {
    padding: 7px 12px;
  }

  .album-stage {
    width: 92vw;
    padding-top: 52px;
  }

  .intro {
    margin-left: 0;
  }

  .intro h1 {
    font-size: clamp(1.4rem, 6.8vw, 2.5rem);
  }

  .book {
    width: min(420px, 88vw);
    height: min(560px, 124vw);
    min-height: 0;
    transform: rotateX(4deg) rotateY(-5deg) rotateZ(-.7deg);
  }

  .cover-front {
    width: 100%;
  }

  .book-page {
    left: 4%;
    top: 4%;
    width: 92%;
    height: 92%;
    opacity: 0;
  }

  .book-spine,
  .paper-stack {
    display: none;
  }

  .book.is-opening .cover-front {
    transform: rotateY(-160deg);
  }

  .page-kicker {
    margin-top: 24px;
  }

  .cover-rule {
    margin-top: 30%;
  }

  .chapter-list {
    max-height: 285px;
  }

  .book-hint {
    margin-top: 42px;
  }
}

@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
  }
}