@import url("https://fonts.googleapis.com/css2?family=EB+Garamond:ital,wght@0,400;1,400&family=Inter:wght@400;500&display=swap");
:root {
  --ink: #090909;
  --paper: #f0eee7;
  --dim: rgba(240, 238, 231, 0.46);
  --line: rgba(240, 238, 231, 0.18);
  --red: #a52a24;
  --serif: "EB Garamond", Georgia, serif;
  --sans: "Inter", Arial, sans;
}
* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--ink);
  color: var(--paper);
}
body {
  font-family: var(--serif);
  overflow-x: hidden;
}
button,
a {
  font: inherit;
}
.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  right: 0;
  left: 0;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  padding: 22px clamp(20px, 4vw, 62px);
  pointer-events: none;
}
.site-header > * {
  pointer-events: auto;
}
.mark {
  width: 32px;
  height: 32px;
}
.mark img {
  display: block;
  width: 100%;
  height: 100%;
}
.site-header nav {
  display: flex;
  gap: 26px;
}
.site-header button,
.field-footer button:not(.sound),
.selection button,
.selection a {
  border: 0;
  border-bottom: 1px solid transparent;
  padding: 0 0 4px;
  background: none;
  color: var(--dim);
  font: 500 0.58rem/1.3 var(--sans);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
}
.site-header button:hover,
.site-header button.active,
.field-footer button:hover,
.selection button:hover,
.selection a:hover {
  border-color: currentColor;
  color: var(--paper);
}
.site-header > p {
  justify-self: end;
  margin: 0;
  color: var(--dim);
  font: 500 0.54rem/1.3 var(--sans);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.view {
  min-height: 100svh;
}
.field-view {
  position: relative;
  height: 100svh;
  overflow: hidden;
}
.field-view canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  touch-action: none;
  cursor: grab;
}
.field-view canvas:active {
  cursor: grabbing;
}
.field-title {
  position: absolute;
  bottom: clamp(100px, 14vh, 155px);
  left: clamp(20px, 5vw, 76px);
  pointer-events: none;
}
.field-title p,
.volume-intro > p,
.selection > p {
  margin: 0 0 13px;
  color: var(--red);
  font: 500 0.57rem/1.35 var(--sans);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.field-title h1 {
  margin: 0;
  font: 400 clamp(3.4rem, 8vw, 8.5rem)/0.78 var(--serif);
  letter-spacing: -0.06em;
}
.field-footer {
  position: absolute;
  right: clamp(20px, 4vw, 62px);
  bottom: 30px;
  left: clamp(20px, 4vw, 62px);
  display: flex;
  justify-content: space-between;
  align-items: end;
}
.field-footer p {
  margin: 0;
  color: rgba(240, 238, 231, 0.28);
  font: 500 0.52rem/1.3 var(--sans);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.selection {
  position: absolute;
  z-index: 5;
  top: 50%;
  right: clamp(20px, 5vw, 76px);
  width: min(360px, calc(100vw - 40px));
  padding: 26px;
  border: 1px solid var(--line);
  background: rgba(9, 9, 9, 0.88);
  transform: translateY(-50%);
  backdrop-filter: blur(16px);
}
.selection .close {
  position: absolute;
  top: 16px;
  right: 16px;
  border: 0;
  font-size: 1rem;
}
.selection h2 {
  margin: 0 30px 15px 0;
  font: 400 2.3rem/0.92 var(--serif);
  letter-spacing: -0.04em;
}
.selection > p:not(:first-of-type) {
  color: var(--dim);
  line-height: 1.42;
}
.selection-links {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 28px;
}
.volume-view {
  padding: clamp(120px, 16vw, 190px) clamp(20px, 6vw, 90px) 90px;
  background: #111110;
}
.volume-intro {
  display: grid;
  grid-template-columns: 0.45fr 1fr;
  gap: 5vw;
  padding-bottom: clamp(70px, 10vw, 130px);
  border-bottom: 1px solid #44423c;
}
.back-cover {
  display: grid;
  grid-template-columns: 0.45fr 1fr;
  gap: 5vw;
  margin-top: clamp(90px, 13vw, 170px);
  padding: clamp(34px, 5vw, 62px) 0;
  border-top: 1px solid #44423c;
  border-bottom: 1px solid #44423c;
}
.back-cover > div > p:first-child {
  margin: 0 0 18px;
  color: var(--red);
  font: 500 0.56rem/1.3 var(--sans);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.back-cover h2 {
  max-width: 590px;
  margin: 0;
  font: 400 clamp(2.8rem, 5vw, 5.8rem)/0.88 var(--serif);
  letter-spacing: -0.05em;
}
.back-cover-body {
  max-width: 680px;
}
.back-cover-body > p {
  max-width: 61ch;
  margin: 0 0 1.35em;
  color: #969289;
  font-size: 1rem;
  line-height: 1.65;
}
.back-cover-body .summary {
  color: #d2cdc1;
  font: 400 clamp(1.25rem, 2vw, 1.65rem)/1.45 var(--serif);
}
.archive-details {
  margin: clamp(42px, 6vw, 72px) 0 0;
  border-top: 1px solid #34322e;
}
.archive-details div {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 18px;
  padding: 14px 0;
  border-bottom: 1px solid #34322e;
}
.archive-details dt,
.archive-details dd {
  margin: 0;
  font: 500 0.55rem/1.5 var(--sans);
  letter-spacing: 0.09em;
  text-transform: uppercase;
}
.archive-details dt { color: #77736a; }
.archive-details dd { color: #bab5aa; }
.archive-details a { color: inherit; text-decoration: none; }
.archive-details a:hover { color: #fff; }
.volume-intro h1 {
  max-width: 950px;
  margin: 0;
  font: 400 clamp(3.6rem, 8vw, 8.5rem)/0.83 var(--serif);
  letter-spacing: -0.06em;
}
.volume-intro .principle {
  grid-column: 2;
  max-width: 620px;
  margin: 25px 0 0;
  color: #969289;
  font-size: 1.15rem;
  line-height: 1.55;
}
.shelf {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  margin-top: 70px;
  background: #35332e;
}
.volume-card {
  display: flex;
  min-height: 52vh;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(24px, 4vw, 50px);
  background: #111110;
  color: var(--paper);
  text-decoration: none;
}
.volume-card:hover {
  background: var(--paper);
  color: var(--ink);
}
.volume-card span {
  color: var(--red);
  font: 500 0.57rem/1.35 var(--sans);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.volume-card h2 {
  margin: 40px 0;
  font: 400 clamp(2.4rem, 4vw, 4.8rem)/0.88 var(--serif);
  letter-spacing: -0.05em;
}
.volume-card small {
  color: #77736a;
  font: 500 0.53rem/1.4 var(--sans);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.register {
  display: grid;
  grid-template-columns: 0.45fr 1fr;
  gap: 5vw;
  margin-top: clamp(90px, 13vw, 170px);
  padding-top: 35px;
  border-top: 1px solid #44423c;
}
.register header p {
  margin: 0 0 16px;
  color: var(--red);
  font: 500 0.56rem/1.3 var(--sans);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.register h2 {
  margin: 0;
  font: 400 clamp(2.8rem, 5vw, 5.8rem)/0.88 var(--serif);
  letter-spacing: -0.05em;
}
.register-entry {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  gap: 18px;
  padding: 20px 0;
  border-bottom: 1px solid #34322e;
  color: var(--paper);
  text-decoration: none;
}
.register-entry > span {
  color: var(--red);
  font: 500 0.56rem/1.3 var(--sans);
  letter-spacing: 0.1em;
}
.register-entry b {
  font: 400 1.2rem/1.1 var(--serif);
}
.register-entry small {
  align-self: center;
  color: #77736a;
  font: 500 0.5rem/1.3 var(--sans);
  letter-spacing: 0.09em;
  text-align: right;
  text-transform: uppercase;
}
.register-entry:hover b {
  color: #fff;
}
@media (max-width: 720px) {
  .site-header {
    grid-template-columns: 1fr auto;
    padding: 18px 20px;
  }
  .field-title {
    bottom: 120px;
  }
  .field-title h1 {
    font-size: clamp(3.5rem, 16vw, 5.8rem);
  }
  .field-footer {
    bottom: 22px;
  }
  .field-footer p {
    display: none;
  }
  .selection {
    top: auto;
    right: 20px;
    bottom: 72px;
    left: 20px;
    width: auto;
    transform: none;
  }
  .volume-intro,
  .back-cover,
  .register {
    grid-template-columns: 1fr;
  }
  .back-cover-body { max-width: none; }
  .volume-intro .principle {
    grid-column: 1;
  }
  .shelf {
    grid-template-columns: 1fr;
  }
  .volume-card {
    min-height: 55vh;
  }
  .register-entry {
    grid-template-columns: 36px 1fr;
  }
  .register-entry small {
    grid-column: 2;
    text-align: left;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
.shelf {
  grid-template-columns: repeat(4, minmax(150px, 230px));
  gap: clamp(22px, 4vw, 54px);
  align-items: start;
  background: transparent;
}
.volume-card {
  aspect-ratio: 2/3;
  min-height: 0;
  padding: 22px;
  border: 1px solid #3b3934;
  transition:
    background 0.35s,
    color 0.35s,
    transform 0.35s,
    border-color 0.35s;
}
.volume-card:hover {
  border-color: #d3cec1;
  background: #e5dfd2;
  transform: translateY(-5px);
}
.volume-card h2 {
  font-size: clamp(1.65rem, 2.5vw, 2.5rem);
}
@media (max-width: 720px) {
  .shelf {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
  }
  .volume-card {
    width: 100%;
    min-height: 0;
  }
}
.book-layer {
  position: fixed;
  z-index: 40;
  inset: 0;
  background: #111110;
}
.book-layer iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}
.book-layer > button {
  position: fixed;
  z-index: 2;
  top: 20px;
  right: 24px;
  border: 0;
  border-bottom: 1px solid rgba(17, 17, 16, 0.35);
  padding: 0 0 4px;
  background: none;
  color: #111110;
  font: 500 0.55rem/1.3 var(--sans);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  mix-blend-mode: difference;
  filter: invert(1);
}
