@font-face {
  font-family: "Rei Notebook Hand";
  src: url("assets/fonts/rei-notebook-hand.woff2") format("woff2");
  font-display: swap;
  font-style: normal;
  font-weight: 400;
}

@font-face {
  font-family: "Rei Gothic Title";
  src: url("assets/fonts/rei-gothic-title.woff2") format("woff2");
  font-display: swap;
  font-style: normal;
  font-weight: 400;
}

:root {
  --ink: #493a43;
  --rei-paper-border: #efdee5;
  --rei-lace-border: #eedde4;
  --rei-muted-mauve: #8c6678;
  --rei-blush-highlight: #fff0f6;
  --rei-vellum-highlight: #fff8fa;
  --paper: #fffaf7;
  --book-w: 980px;
  --book-h: 640px;
  --page-w: 490px;
  --page-h: 640px;
  --pixel: "MS Gothic", "MS PGothic", Fixedsys, "Courier New", monospace;
  --serif: "Noto Serif TC", "Source Han Serif TC", "Yu Mincho", "MS Mincho", Georgia, serif;
  --gothic: "Old English Text MT", "Lucida Blackletter", "Times New Roman", serif;
  --notebook-hand: "Rei Notebook Hand", "Yu Kyokasho", "Kaiti TC", "KaiTi", "STKaiti", "Yu Mincho", "Noto Serif CJK JP", serif;
  --gothic-title: "Rei Gothic Title", "Yu Mincho Demibold", "Noto Serif CJK JP", "Noto Serif CJK SC", "Songti SC", var(--serif);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: #f5ecef;
}

body {
  min-height: 100vh;
  margin: 0px;
  overflow-x: hidden;
  color: var(--ink);
  font: 12px/1.58 var(--pixel);
  cursor: url("/assets/cursors/rei-bow-cursor.svg") 12 10, auto;
  background-repeat: repeat;
  background-size: auto;
  background-position: 0 0;
  background-attachment: fixed;
  background-color: rgb(246, 237, 240);
  background-image: url("assets/materials/pink/pattern_tile_04_02.svg");
}

.book,
.page.rei-responsive-active {
  font-family: var(--notebook-hand);
}

.book h1,
.book h2,
.page.rei-responsive-active h1,
.page.rei-responsive-active h2,
.cover-copy strong {
  font-family: var(--gothic-title);
  font-weight: 700;
}

body::after {
  content: "";
  position: fixed;
  inset: 8px;
  z-index: 0;
  pointer-events: none;
  border-right: 3px double rgba(47, 36, 43, .48);
  border-left: 3px double rgba(47, 36, 43, .48);
  box-shadow: inset 14px 0 rgba(255, 255, 255, .35), inset -14px 0 rgba(255, 255, 255, .35);
}

button,
a {
  cursor: url("/assets/cursors/rei-bow-cursor.svg") 12 10, pointer;
}

button,
input,
textarea {
  font: inherit;
}

button {
  color: var(--ink);
}

img {
  max-width: 100%;
}

a {
  color: #755568;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

[hidden] {
  display: none !important;
}

.ceiling {
  position: fixed;
  top: 0px;
  right: 0px;
  left: 0px;
  z-index: 40;
  height: 99px;
  overflow: hidden;
  pointer-events: none;
  background: url("assets/materials/pink/pattern_extra_006.svg") repeat-x;
}

.ceiling-lace-band,
.ceiling-chain-band {
  position: absolute;
  right: 0;
  left: 0;
  display: block;
  background-position: left top;
  background-repeat: repeat-x;
}

.ceiling-lace-band {
  top: 0px;
  height: 70px;
  background-image: url("assets/materials/black/pattern_extra_015.svg");
  background-size: auto 64px;
  border-radius: 100px;
  background-repeat: repeat;
}

.ceiling-chain-band {
  top: 51px;
  height: 48px;
  opacity: .86;
  background-image: url("assets/journal/01_banners/garland_cross_moon_chain.png");
  background-size: auto 42px;
}

.site-shell {
  position: relative;
  z-index: 2;
  width: min(1280px, 100%);
  margin: 0 auto;
  padding: 112px 18px 34px;
}

.reader-frame {
  position: relative;
  width: min(1130px, -44px + 100vw);
  min-height: 0px;
  margin: 0px auto;
  padding: 26px 54px 17px;
  overflow: visible;
  transition: width 0.38s, padding 0.38s;
  background: transparent;
  box-shadow: none;
  border-color: transparent;
  outline-color: transparent;
}

.reader-frame.book-closed {
  width: min(760px, calc(100vw - 44px));
  padding-right: 44px;
  padding-left: 44px;
}

.desktop-reader {
  display: block;
}

.responsive-reader-controls,
.responsive-tab-strip {
  display: none;
}

.book-scene {
  position: relative;
  display: grid;
  place-items: center;
  height: 674px;
  overflow: visible;
  perspective: 2600px;
}

.book {
  --leaf-left: 25%;
  position: absolute;
  top: 17px;
  left: 50%;
  width: var(--book-w);
  height: var(--book-h);
  transform: translateX(-50%);
  transform-style: preserve-3d;
}

.book.is-open {
  --leaf-left: 50%;
}

.book.is-back {
  --leaf-left: 75%;
}

.book-spine {
  position: absolute;
  top: 4px;
  bottom: 4px;
  left: calc(50% - 13px);
  z-index: 120;
  width: 26px;
  opacity: 0;
  pointer-events: none;
  background: linear-gradient(90deg, rgba(75, 51, 64, .12), rgba(255, 255, 255, .94) 42%, rgba(73, 49, 61, .22) 57%, rgba(255, 255, 255, .08));
  box-shadow: inset 2px 0 4px rgba(68, 44, 57, .12), inset -2px 0 4px rgba(68, 44, 57, .14);
  transition: opacity .3s;
}

.book.is-open .book-spine {
  opacity: 1;
}

.paper {
  position: absolute;
  top: 0;
  left: var(--leaf-left);
  width: var(--page-w);
  height: var(--page-h);
  transform-origin: left center;
  transform-style: preserve-3d;
  transition: transform .78s cubic-bezier(.6, .03, .34, 1), left .52s ease, z-index .01s .38s;
  will-change: transform, left;
}

.paper.flipped {
  transform: rotateY(-180deg);
}

.page {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border: 1px solid #947985;
  background: var(--paper);
  box-shadow: 0 8px 17px rgba(70, 47, 59, .17), inset 0 0 18px rgba(200, 157, 176, .08);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.page.front {
  border-radius: 2px 12px 12px 2px;
}

.page.back {
  transform: rotateY(180deg);
  border-radius: 12px 2px 2px 12px;
}

.page::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(90deg, rgba(64, 43, 54, .1), transparent 7%, transparent 92%, rgba(64, 43, 54, .045));
}

.page.back::after {
  background: linear-gradient(90deg, rgba(64, 43, 54, .045), transparent 8%, transparent 93%, rgba(64, 43, 54, .1));
}

.paper .page.front {
  pointer-events: auto;
}

.paper .page.back {
  pointer-events: none;
}

.paper.flipped .page.front {
  pointer-events: none;
}

.paper.flipped .page.back {
  pointer-events: auto;
}

.page-inner {
  --paper-wash: linear-gradient(rgba(255, 251, 248, .72), rgba(255, 251, 248, .72));
  --paper-motif: url("assets/materials/pink/pattern_tile_01_01.svg");
  --motif-size: 112px 112px;
  --paper-blocks: repeating-linear-gradient(90deg, rgba(231, 165, 192, .28) 0 48px, rgba(255, 255, 255, .1) 48px 88px, rgba(49, 37, 44, .12) 88px 98px, rgba(240, 207, 220, .27) 98px 148px);
  position: relative;
  width: 100%;
  height: 100%;
  padding: 34px 32px 28px;
  overflow: hidden;
  background-color: #fff9f7;
  background-image: var(--paper-wash), var(--paper-motif), var(--paper-blocks);
  background-repeat: repeat, repeat, repeat;
  background-size: auto, var(--motif-size), 100% 100%;
  background-position: 0 0;
}

.commission-inner {
  --paper-wash: linear-gradient(rgba(255, 251, 249, .76), rgba(255, 251, 249, .76));
  --paper-motif: url("assets/materials/pink/pattern_tile_02_01.svg");
  --motif-size: 120px 112px;
  --paper-blocks: repeating-linear-gradient(0deg, rgba(238, 189, 208, .25) 0 40px, rgba(255, 255, 255, .12) 40px 78px, rgba(57, 43, 50, .1) 78px 87px, rgba(244, 218, 228, .25) 87px 132px);
  padding-top: 38px;
}

.index-page .grid-paper {
  --paper-wash: linear-gradient(rgba(255, 250, 248, .69), rgba(255, 250, 248, .69));
  --paper-motif: url("assets/materials/pink/pattern_tile_01_01.svg");
  --motif-size: 108px 108px;
  --paper-blocks: repeating-linear-gradient(90deg, rgba(235, 174, 199, .34) 0 52px, rgba(255, 255, 255, .09) 52px 89px, rgba(48, 36, 43, .14) 89px 99px, rgba(244, 213, 225, .3) 99px 151px);
}

.rei-page .notebook-paper {
  --paper-wash: linear-gradient(rgba(255, 251, 249, .7), rgba(255, 251, 249, .7));
  --paper-motif: url("assets/materials/pink/pattern_tile_03_01.svg");
  --motif-size: 102px 102px;
  --paper-blocks: repeating-linear-gradient(0deg, rgba(242, 190, 211, .31) 0 43px, rgba(255, 255, 255, .1) 43px 76px, rgba(53, 40, 47, .11) 76px 84px, rgba(232, 211, 219, .3) 84px 128px);
}

.master-page .diary-paper {
  --paper-wash: linear-gradient(rgba(255, 252, 247, .73), rgba(255, 252, 247, .73));
  --paper-motif: url("assets/materials/pink/pattern_tile_02_01.svg");
  --motif-size: 118px 110px;
  --paper-blocks: repeating-linear-gradient(90deg, rgba(49, 37, 44, .16) 0 37px, rgba(240, 181, 205, .31) 37px 82px, rgba(255, 255, 255, .08) 82px 119px, rgba(218, 198, 208, .31) 119px 158px);
}

.writings-page .pale-paper {
  --paper-wash: linear-gradient(rgba(255, 252, 248, .74), rgba(255, 252, 248, .74));
  --paper-motif: url("assets/materials/pink/pattern_tile_04_01.svg");
  --motif-size: 116px 82px;
  --paper-blocks: repeating-linear-gradient(0deg, rgba(234, 171, 198, .32) 0 37px, rgba(255, 255, 255, .08) 37px 73px, rgba(51, 38, 45, .12) 73px 82px, rgba(244, 216, 227, .28) 82px 124px);
}

.diary-index-page .grid-paper {
  --paper-wash: linear-gradient(rgba(255, 251, 248, .68), rgba(255, 251, 248, .68));
  --paper-motif: url("assets/materials/pink/pattern_tile_01_02.svg");
  --motif-size: 106px 106px;
  --paper-blocks: repeating-linear-gradient(90deg, rgba(244, 203, 219, .35) 0 52px, rgba(255, 255, 255, .08) 52px 88px, rgba(49, 37, 44, .12) 88px 98px, rgba(230, 173, 197, .29) 98px 148px);
}

.diary-day-page .diary-paper {
  --paper-wash: linear-gradient(rgba(255, 253, 249, .76), rgba(255, 253, 249, .76));
  --paper-motif: url("assets/materials/pink/pattern_tile_03_02.svg");
  --motif-size: 104px 104px;
  --paper-blocks: repeating-linear-gradient(0deg, rgba(234, 173, 198, .27) 0 40px, rgba(255, 255, 255, .1) 40px 75px, rgba(55, 42, 49, .11) 75px 83px, rgba(244, 218, 228, .28) 83px 129px);
}

.master-collection-page .cabinet-paper {
  --paper-wash: linear-gradient(rgba(255, 251, 248, .73), rgba(255, 251, 248, .73));
  --paper-motif: url("assets/journal/04_background_tiles/tile_gray_grid_butterfly.png");
  --motif-size: 126px 126px;
  --paper-blocks: repeating-linear-gradient(90deg, rgba(49, 37, 44, .16) 0 42px, rgba(241, 190, 211, .31) 42px 84px, rgba(255, 255, 255, .09) 84px 120px, rgba(218, 200, 210, .3) 120px 158px);
}

.rei-collection-page .notebook-paper {
  --paper-wash: linear-gradient(rgba(255, 249, 251, .63), rgba(255, 249, 251, .63));
  --paper-motif: url("assets/materials/pink/pattern_tile_01_03.svg");
  --motif-size: 112px 112px;
  --paper-blocks: repeating-linear-gradient(90deg, rgba(228, 153, 185, .4) 0 45px, rgba(255, 255, 255, .08) 45px 79px, rgba(48, 36, 43, .15) 79px 90px, rgba(242, 204, 220, .34) 90px 138px);
}

.lost-magic-page .pale-paper {
  --paper-wash: linear-gradient(rgba(255, 252, 249, .73), rgba(255, 252, 249, .73));
  --paper-motif: url("assets/materials/pink/pattern_tile_02_03.svg");
  --motif-size: 116px 108px;
  --paper-blocks: repeating-linear-gradient(0deg, rgba(237, 178, 203, .31) 0 41px, rgba(255, 255, 255, .09) 41px 77px, rgba(52, 39, 46, .12) 77px 86px, rgba(242, 214, 225, .29) 86px 132px);
}

.ai-page .notebook-paper {
  --paper-wash: linear-gradient(rgba(255, 251, 250, .74), rgba(255, 251, 250, .74));
  --paper-motif: url("assets/materials/pink/pattern_tile_04_03.svg");
  --motif-size: 118px 84px;
  --paper-blocks: repeating-linear-gradient(90deg, rgba(48, 36, 43, .13) 0 35px, rgba(238, 183, 206, .29) 35px 78px, rgba(255, 255, 255, .09) 78px 112px, rgba(223, 204, 213, .28) 112px 152px);
}

.bbs-page .pale-paper {
  --paper-wash: linear-gradient(rgba(255, 252, 249, .72), rgba(255, 252, 249, .72));
  --paper-motif: url("assets/materials/pink/pattern_tile_03_04.svg");
  --motif-size: 108px 108px;
  --paper-blocks: repeating-linear-gradient(90deg, rgba(235, 175, 200, .31) 0 43px, rgba(255, 255, 255, .09) 43px 82px, rgba(52, 39, 46, .13) 82px 92px, rgba(243, 216, 227, .29) 92px 140px);
  display: flex;
  flex-direction: column;
}

.friends-page .garden-paper {
  position: relative;
  overflow: hidden;
  --paper-wash: linear-gradient(rgba(255, 253, 249, .73), rgba(255, 253, 249, .73));
  --paper-motif: url("assets/materials/pink/pattern_tile_01_04.svg");
  --motif-size: 112px 112px;
  --paper-blocks: repeating-linear-gradient(0deg, rgba(234, 174, 199, .29) 0 43px, rgba(255, 255, 255, .1) 43px 83px, rgba(52, 39, 46, .12) 83px 92px, rgba(243, 217, 227, .28) 92px 140px);
}

.badges-page .badge-paper {
  --paper-wash: linear-gradient(rgba(255, 250, 250, .64), rgba(255, 250, 250, .64));
  --paper-motif: url("assets/journal/09_bottom_tiles/bottom_01_checkers.png");
  --motif-size: 76px 76px;
  --paper-blocks: repeating-linear-gradient(90deg, rgba(232, 167, 194, .35) 0 39px, rgba(255, 255, 255, .08) 39px 74px, rgba(48, 36, 43, .15) 74px 83px, rgba(243, 210, 224, .31) 83px 128px);
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.goodbye-page .notebook-paper {
  --paper-wash: linear-gradient(rgba(255, 252, 250, .73), rgba(255, 252, 250, .73));
  --paper-motif: url("assets/materials/pink/pattern_tile_04_04.svg");
  --motif-size: 122px 87px;
  --paper-blocks: repeating-linear-gradient(90deg, rgba(48, 36, 43, .12) 0 34px, rgba(239, 186, 208, .29) 34px 78px, rgba(255, 255, 255, .09) 78px 112px, rgba(226, 207, 216, .29) 112px 153px);
}

.page-kicker {
  margin: 0 0 5px;
  color: #927985;
  font-size: 7px;
  letter-spacing: .15em;
  text-transform: uppercase;
}

.page h2 {
  margin: 0 0 11px;
  color: #58434f;
  font: 700 20px/1.2 var(--serif);
  letter-spacing: .11em;
  text-shadow: 1px 1px rgba(255, 255, 255, .8);
}

.page h2::after,
.page.rei-responsive-active h2::after {
  content: "✞";
  display: inline-block;
  width: auto;
  height: auto;
  margin-left: .38em;
  color: #b87391;
  font-size: .60em;
  line-height: 1;
  vertical-align: .08em;
  transform: none;
  pointer-events: none;
  position: static;
  inset: auto;
  float: none;
}

.page-divider {
  display: block;
  width: 86%;
  max-height: 34px;
  margin: 9px auto 0;
  object-fit: contain;
  opacity: .75;
}

.tiny-handnote,
.scribble {
  color: #715d69;
  font: italic 9px/1.62 var(--serif);
}

.scribble {
  text-align: center;
}

.small-deco {
  position: absolute;
  width: 44px;
  opacity: .76;
}

.bottom-right {
  right: 18px;
  bottom: 16px;
}

.page-material-sticker {
  position: absolute;
  z-index: 1;
  max-width: 66px;
  max-height: 70px;
  object-fit: contain;
  pointer-events: none;
  opacity: .46;
}

.sticker-rei {
  top: 48px;
  right: 16px;
  width: 38px;
}

.sticker-master {
  top: 50px;
  right: 18px;
  width: 34px;
}

.sticker-diary {
  top: 42px;
  right: 16px;
  width: 82px;
  opacity: .36;
}

.sticker-collection {
  top: 40px;
  right: 12px;
  width: 62px;
}

.sticker-bbs {
  top: 42px;
  right: 16px;
  width: 48px;
}

.web-button,
.text-link,
.journal-index button,
.diary-tools button,
.bbs-form button,
.book-controls button,
.responsive-controls button {
  border: 1px solid #725564;
  color: #58414f;
  background: #fff4f7;
  box-shadow: inset 1px 1px #fff, 2px 2px #c8a5b5;
  font: 8px var(--pixel);
}

.web-button,
.journal-index button,
.diary-tools button,
.bbs-form button {
  padding: 6px 9px;
}

.web-button:hover,
.journal-index button:hover,
.diary-tools button:hover,
.book-controls button:hover:not(:disabled),
.responsive-controls button:hover:not(:disabled) {
  color: #2f232a;
  background: #f2cbdc;
}

.web-button.primary {
  border-color: #4b3742;
  background: #ebbed1;
  font-weight: 700;
}

.text-link {
  padding: 0;
  border: 0;
  color: #81536b;
  background: transparent;
  box-shadow: none;
  text-decoration: underline;
}

.web-button img {
  height: 20px;
  margin-right: 4px;
  vertical-align: middle;
}

body.memory-open .ceiling,
body.memory-open .ceiling-lace-band,
body.memory-open .ceiling-chain-band,
body.archive-module-open .ceiling,
body.archive-module-open .ceiling-lace-band,
body.archive-module-open .ceiling-chain-band {
  visibility: hidden;
  pointer-events: none;
}

.cover-page {
  border: 2px solid #4a3741;
  outline: 4px double #f8d9e6;
  background: #e8c8d6;
}

.cover-inner {
  --rei-cover-bg-pattern-image: url("assets/materials/black/pattern_tile_04_01.svg");
  --rei-cover-bg-tile-w: 104px;
  --rei-cover-bg-tile-h: 71px;
  --rei-cover-bg-repeat: repeat;
  --rei-cover-bg-offset-x: -379px;
  --rei-cover-bg-offset-y: -246px;
  --rei-cover-bg-opacity: 0.4;
  display: grid;
  place-items: center;
  isolation: isolate;
  padding: 26px;
  background-image: none;
  backdrop-filter: blur(1px);
  translate: 0px -2px;
  background-color: rgb(253, 231, 239);
}

.cover-inner::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: var(--rei-cover-bg-opacity);
  background-image: var(--rei-cover-bg-pattern-image);
  background-repeat: var(--rei-cover-bg-repeat);
  background-size: var(--rei-cover-bg-tile-w) var(--rei-cover-bg-tile-h);
  background-position: var(--rei-cover-bg-offset-x) var(--rei-cover-bg-offset-y);
}

.cover-inner::before {
  content: "";
  position: absolute;
  inset: 19px;
  border: 4px double #3e2d36;
  outline: 2px solid rgba(245, 207, 222, .86);
  box-shadow: inset 0 0 0 7px rgba(255, 247, 249, .28), inset 0 0 28px rgba(47, 34, 41, .12);
  pointer-events: none;
}







.cover-reliquary {
  position: absolute;
  top: 80px;
  left: 50%;
  z-index: 4;
  display: grid;
  place-items: center;
  width: 82px;
  height: 116px;
  transform: translateX(-50%);
  border: 3px double rgb(62, 45, 54);
  border-radius: 50% 50% 44% 44% / 42% 42% 58% 58%;
  outline: rgba(255, 240, 246, 0.7) solid 3px;
  background: rgba(246, 218, 229, 0.84);
  box-shadow: rgba(62, 45, 54, 0.1) 0px 0px 0px 6px, rgba(54, 38, 47, 0.11) 0px 0px 16px inset;
  translate: 0px 40px;
}

.cover-reliquary::before,
.cover-reliquary::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 52px;
  border-top: 1px solid #5a414e;
}

.cover-reliquary::before {
  right: 77px;
}

.cover-reliquary::after {
  left: 77px;
}

.cover-reliquary img {
  width: 55px;
  height: 88px;
  object-fit: contain;
}



.cover-copy {
  position: relative;
  z-index: 3;
  width: 338px;
  margin-top: 72px;
  padding: 22px 15px 17px;
  border: 3px double rgb(74, 53, 64);
  text-align: center;
  background: rgba(255, 246, 248, 0.82);
  box-shadow: rgba(58, 42, 50, 0.07) 0px 0px 0px 6px, rgba(234, 187, 206, 0.32) 0px 0px 0px 4px inset;
  translate: 0px 38px;
}

.cover-copy::before,
.cover-copy::after {
  content: "✦";
  position: absolute;
  top: 50%;
  color: #634653;
  font-size: 12px;
  transform: translateY(-50%);
}

.cover-copy::before {
  left: 10px;
}

.cover-copy::after {
  right: 10px;
}

.cover-copy strong {
  display: block;
  color: #34272e;
  font: 700 29px/.98 var(--gothic);
  text-shadow: 1px 1px #fff;
}

.cover-copy small {
  display: block;
  margin-top: 11px;
  color: #654e5b;
  font: 600 10px var(--serif);
  letter-spacing: .1em;
}

.cover-copy em {
  display: block;
  margin-top: 8px;
  color: #87566d;
  font: italic 6.5px var(--serif);
  letter-spacing: .13em;
}

.cover-star {
  display: block;
  margin-bottom: 8px;
  color: #694653;
  font: 7px var(--serif);
  letter-spacing: .15em;
}

.visitor-counter {
  position: absolute;
  bottom: 84px;
  left: 50%;
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 5px 9px;
  transform: translateX(-50%);
  border: 1px solid #8f6a7d;
  background: var(--rei-vellum-highlight);
  font-size: 7px;
  white-space: nowrap;
}

.visitor-counter b {
  font-size: 10px;
  letter-spacing: .1em;
}

.cover-inner > .web-button {
  position: absolute;
  bottom: 46px;
  left: 50%;
  z-index: 4;
  transform: translateX(-50%);
}

.cover-note {
  position: absolute;
  bottom: 17px;
  margin: 0px;
  color: rgb(132, 107, 120);
  font-size: 7px;
  translate: -4px 14px;
}

.commission-seal {
  position: absolute;
  top: 40px;
  right: 28px;
  width: 62px;
  opacity: .7;
}

.record-table {
  width: 79%;
  margin: 15px 0;
  padding: 6px 10px;
  border: 1px solid rgba(122, 90, 106, .23);
  background: rgba(255, 253, 251, .83);
}

.record-table div {
  display: grid;
  grid-template-columns: 105px 1fr;
  padding: 5px 0;
  border-bottom: 1px dotted #cfb4c1;
}

.record-table div:last-child {
  border-bottom: 0;
}

.record-table dt {
  color: #907785;
  font-size: 7px;
}

.record-table dd {
  margin: 0;
  font: 9px var(--serif);
}

.record-table img {
  height: 18px;
  vertical-align: middle;
}

.rei-note {
  margin: 14px 0 8px;
  padding: 9px 10px;
  border-left: 3px double #c47e9d;
  background: rgba(255, 239, 246, .88);
  color: #684c5d;
  font: italic 10px/1.6 var(--serif);
}

.tape-strip {
  position: absolute;
  top: 10px;
  right: 12px;
  width: 118px;
  opacity: .72;
}

.journal-index {
  display: grid;
  gap: 5px;
  margin: 14px 0 10px;
}

.journal-index button {
  display: grid;
  grid-template-columns: 31px 1fr;
  min-height: 28px;
  padding: 5px 8px;
  border-style: dotted;
  text-align: left;
  background: rgba(255, 252, 251, .87);
}

.journal-index b {
  display: grid;
  place-items: center;
  color: #ffeaf3;
  background: #4b3942;
  font-size: 7px;
}

.journal-index span {
  padding-left: 8px;
  font-size: 8px;
}

.portrait-collage {
  display: grid;
  grid-template-columns: 1fr 152px;
  gap: 12px;
  align-items: center;
}

.portrait-copy {
  padding: 11px;
  border: 1px solid rgba(117, 84, 101, .25);
  border-left: 3px double #c1809e;
  background: rgba(255, 253, 251, .84);
  font: 9px/1.62 var(--serif);
}

.portrait-copy .hello {
  color: #995f7a;
  font-style: italic;
}

.mini-profile {
  margin: 8px 0 0;
}

.mini-profile div {
  display: flex;
  padding: 2px 0;
  border-bottom: 1px dotted #d6bdc8;
}

.mini-profile dt {
  width: 57px;
  color: #8e7482;
  font: 7px var(--pixel);
}

.mini-profile dd {
  margin: 0;
  font-size: 8px;
}

.rei-frame {
  position: relative;
  display: grid;
  place-items: center;
  height: 226px;
}

.rei-frame > img:first-child {
  position: absolute;
  width: 150px;
  height: 220px;
  object-fit: fill;
  opacity: .77;
}

.rei-avatar {
  position: relative;
  z-index: 2;
  width: 104px;
  max-height: 182px;
  object-fit: contain;
}

.rei-quote {
  width: 92%;
  margin: 12px auto 0;
  padding: 8px;
  border: 1px dashed #b98fa4;
  color: #684b5c;
  background: rgba(255, 239, 246, .9);
  font: italic 10px/1.6 var(--serif);
  text-align: center;
}

.rei-about-inner {
  padding: 27px 27px 20px;
}

.rei-about-inner h2 {
  margin-bottom: 7px;
}

.rei-about-inner .portrait-collage {
  grid-template-columns: 1fr 82px;
  gap: 9px;
  min-height: 94px;
  padding: 6px 8px;
  border: 3px double rgba(104, 73, 89, .38);
  background: rgba(255, 250, 248, .88);
  box-shadow: inset 0 0 0 1px rgba(231, 190, 207, .55);
}

.rei-about-inner .portrait-copy {
  align-self: stretch;
  padding: 5px 4px;
  border: 0;
  background: transparent;
  font-size: 8.5px;
}

.rei-about-inner .portrait-copy .hello {
  margin: 0 0 7px;
  padding-bottom: 5px;
  border-bottom: 1px dotted #c9a4b6;
}

.rei-about-inner .mini-profile {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
  margin-top: 0;
}

.rei-about-inner .mini-profile div {
  display: block;
  padding: 4px 5px;
  border: 1px solid rgba(177, 128, 151, .25);
  background: rgba(255, 241, 247, .72);
}

.rei-about-inner .mini-profile dt {
  width: auto;
  margin-bottom: 3px;
  font-size: 6px;
}

.rei-about-inner .mini-profile dd {
  font-size: 7px;
  overflow-wrap: anywhere;
}

.rei-about-inner .rei-frame {
  height: 82px;
}

.rei-about-inner .rei-frame > img:first-child {
  width: 72px;
  height: 80px;
}

.rei-about-inner .rei-avatar {
  width: 53px;
  max-height: 66px;
}

.rei-biography {
  column-count: 2;
  column-gap: 17px;
  column-rule: 1px dotted rgba(163, 113, 137, .42);
  margin-top: 8px;
  padding: 9px 11px 7px;
  border: 1px solid rgba(115, 82, 98, .26);
  border-left: 3px double #b77996;
  background: rgba(255, 253, 251, .9);
  color: #4d3b45;
  font: 9.5px/1.56 var(--serif);
  letter-spacing: .015em;
  text-align: justify;
}

.rei-biography p {
  break-inside: avoid;
  margin: 0 0 5px;
}

.rei-question {
  break-inside: avoid;
  margin: 5px 0 6px;
  padding: 5px 7px;
  border-block: 1px dotted #c69caf;
  background: rgba(250, 226, 237, .72);
}

.rei-question blockquote {
  margin: 1px 0 4px;
  color: #513744;
  font-style: italic;
  font-weight: 700;
}

.rei-about-inner .rei-quote {
  width: 100%;
  margin-top: 7px;
  padding: 6px 8px;
  font-size: 9.2px;
  line-height: 1.45;
}

.rei-volume-entry-links button,.rei-volume-mini-nav button {
  appearance: none;
  border: 0;
  padding: 0;
  margin: 0;
  background: transparent;
  box-shadow: none;
  color: #9d667f;
  cursor: pointer;
  font-family: "Yu Kyokasho","Kaiti TC",KaiTi,serif;
  font-size: 14px;
  line-height: 1.6;
  text-decoration: underline;
  text-decoration-style: dotted;
  text-underline-offset: 3px;
}

.rei-volume-entry-links button:hover,.rei-volume-entry-links button:focus-visible,
.rei-volume-mini-nav button:hover,.rei-volume-mini-nav button:focus-visible {
  color: #754b60;
  background: transparent;
  outline: 0;
  text-decoration-style: solid;
}

.rei-volume-reader[hidden] {
  display: none!important;
}

.rei-volume-reader {
  position: fixed;
  inset: 0;
  z-index: 25000;
  overflow: auto;
  color: #000;
  background-color: #fff8fb;
  background-image: url("/assets/library/soft-pink/04_patterns/pattern_tile_04_02.svg");
  background-repeat: repeat;
  background-size: 208px 159px;
}

.rei-volume-reader:before {
  content: "";
  position: fixed;
  inset: 8px;
  pointer-events: none;
  border-left: 3px double rgba(47,36,43,.25);
  border-right: 3px double rgba(47,36,43,.25);
}

.rei-volume-shell {
  position: relative;
  z-index: 1;
  width: min(1080px,94vw);
  min-height: 100dvh;
  margin: 0 auto;
  padding: 27px 22px 45px;
}

.rei-volume-mini-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 17px;
  margin: 0 0 14px;
  padding: 0 0 8px;
  border-bottom: 1px dotted #b89aa8;
}

.rei-volume-mini-nav .rei-volume-close {
  margin-left: auto;
}

.rei-volume-surface {
  position: relative;
  min-height: 650px;
  padding: 27px 31px 25px;
  background: radial-gradient(circle at 13% 17%,rgba(128,83,104,.055) 0 1px,transparent 1.5px),
    radial-gradient(circle at 73% 38%,rgba(128,83,104,.045) 0 1px,transparent 1.4px),
    radial-gradient(circle at 41% 82%,rgba(255,255,255,.48) 0 1px,transparent 1.5px),
    repeating-linear-gradient(0deg,rgba(88,60,73,.018) 0 1px,transparent 1px 4px),
    linear-gradient(90deg,rgba(255,252,250,.16),rgba(255,247,250,.33) 13%,rgba(255,250,250,.28) 50%,rgba(255,247,250,.33) 87%,rgba(255,252,250,.16));
  background-size: 17px 17px,23px 23px,31px 31px,auto,auto;
}

.rei-volume-page-name,.rei-volume-small-title {
  color: #9b7f8e;
  font-family: "Yu Kyokasho","Kaiti TC",KaiTi,serif;
  font-weight: normal;
}

.rei-volume-page-name {
  margin: 2px 0 15px;
  padding: 0 0 7px;
  border-bottom: 1px dotted #c9b4bc;
  font-size: 16.5px;
  letter-spacing: .04em;
  text-align: right;
}

.rei-volume-small-title {
  margin: 0 0 7px;
  padding-bottom: 3px;
  border-bottom: 1px dotted #bfaab3;
  font-size: 17px;
  letter-spacing: .025em;
}

.rei-volume-body,.rei-volume-fact-table td {
  font-family: "Yu Kyokasho","Kaiti TC",KaiTi,serif;
  color: #000;
  font-size: 15.5px;
  line-height: 1.84;
}

.rei-volume-profile {
  display: grid;
  grid-template-columns: minmax(300px,40%) minmax(0,60%);
  min-height: 570px;
}

.rei-volume-profile-left {
  padding: 4px 22px 0 4px;
  border-right: 1px solid #c8b6bd;
}

.rei-volume-profile-right {
  padding: 5px 4px 0 24px;
}

.rei-volume-portrait {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 420px;
  overflow: hidden;
  border: 1px dashed #c7a5b5;
  background: rgba(255,255,255,.31);
  box-shadow: inset 0 0 0 5px rgba(239,208,221,.17);
}

.rei-volume-portrait img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.rei-volume-left-section {
  margin-top: 14px;
}

.rei-volume-left-section.is-credits .rei-volume-small-title:before {
  content: "";
  display: inline-block;
  width: 25px;
  height: 31px;
  margin-right: 6px;
  vertical-align: middle;
  background: url("/assets/library/soft-pink/01_icons/icon_061.svg") center/contain no-repeat;
  opacity: .82;
}

.rei-volume-fact-table {
  width: 100%;
  margin: 0 0 17px;
  border-collapse: collapse;
}

.rei-volume-fact-table td {
  padding: 6px 4px;
  border-bottom: 1px dotted #ddcdd3;
  vertical-align: top;
}

.rei-volume-fact-table td:first-child {
  width: 31%;
  white-space: nowrap;
  color: #9d7d8c;
  font-size: 16.5px;
}

.rei-volume-text-section {
  margin: 0 0 8px;
}

.rei-volume-text-section:not(:last-child):after {
  content: "";
  display: block;
  height: 22px;
  margin: 6px 0 5px;
  background: url("/assets/library/soft-pink/01_icons/icon_099.svg") center/150px auto no-repeat;
  opacity: .50;
}

.rei-volume-two-col {
  display: grid;
  grid-template-columns: 34% 66%;
  min-height: 570px;
}

.rei-volume-index {
  padding-right: 18px;
  border-right: 1px solid #c8b6bd;
}

.rei-volume-document {
  padding-left: 20px;
}

.rei-volume-index-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.rei-volume-index-list button {
  appearance: none;
  display: block;
  width: 100%;
  margin: 0;
  padding: 6px 2px;
  border: 0;
  border-bottom: 1px dotted rgba(190,160,174,.48);
  background: transparent;
  box-shadow: none;
  color: #000;
  cursor: pointer;
  text-align: left;
  font-family: "Yu Kyokasho","Kaiti TC",KaiTi,serif;
  font-size: 15.5px;
}

.rei-volume-index-list button:hover,.rei-volume-index-list button.is-active {
  color: #9d667f;
  background: transparent;
}

.rei-volume-document-content img,.rei-volume-document-content video {
  max-width: 100%;
  height: auto;
}

.rei-volume-loading,.rei-volume-empty {
  color: #765f6c;
  font-family: "Yu Kyokasho","Kaiti TC",KaiTi,serif;
  font-size: 15px;
}

body.rei-volume-open {
  overflow: hidden!important;
}

@media (max-width: 720px) {
  .rei-volume-shell {
    width: 100%;
    padding: 25px 15px 30px;
  }
  .rei-volume-surface {
    min-height: 0;
    padding: 24px 19px 22px;
  }
  .rei-volume-profile,.rei-volume-two-col {
    grid-template-columns: 1fr;
  }
  .rei-volume-profile-left,.rei-volume-index {
    padding-right: 0;
    padding-bottom: 14px;
    border-right: 0;
    border-bottom: 1px solid #c8b6bd;
  }
  .rei-volume-profile-right,.rei-volume-document {
    padding-left: 0;
    padding-top: 14px;
  }
  .rei-volume-portrait {
    height: 52vh;
    min-height: 330px;
    max-height: 470px;
  }
  .rei-volume-mini-nav .rei-volume-close {
    margin-left: 0;
  }
}

.mini-profile dd .rei-volume-profile-link {
  appearance: none;
  border: 0;
  padding: 0;
  margin: 0;
  background: transparent;
  box-shadow: none;
  color: inherit;
  cursor: pointer;
  font: inherit;
  line-height: inherit;
  text-align: left;
  text-decoration: underline;
  text-decoration-style: dotted;
  text-underline-offset: 3px;
}

.mini-profile dd .rei-volume-profile-link:hover,
.mini-profile dd .rei-volume-profile-link:focus-visible {
  color: #9d667f;
  outline: 0;
  text-decoration-style: solid;
}

.master-observation-inner {
  padding: 29px 29px 23px;
}

.master-observation-inner h2 {
  margin-bottom: 8px;
}

.master-observation-file {
  position: relative;
  padding: 10px;
  border: 3px double rgba(67, 47, 57, .6);
  outline: 1px solid rgba(219, 166, 190, .5);
  background: linear-gradient(rgba(255, 252, 248, .92), rgba(255, 252, 248, .92)),
    url("assets/materials/black/pattern_tile_01_01.svg");
  background-size: auto, 78px 78px;
  box-shadow: inset 0 0 18px rgba(113, 75, 94, .08), 3px 3px rgba(114, 78, 96, .08);
  color: #4d3944;
}

.master-observation-file::after {
  content: "✠ REI INDEX // PRIVATE ✠";
  position: absolute;
  right: 12px;
  bottom: 7px;
  color: rgba(151, 91, 120, .38);
  font: 6px var(--pixel);
  letter-spacing: .08em;
}

.observation-file-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 28px;
  padding: 6px 9px;
  border: 1px solid #33272d;
  color: #fff7fa;
  background: linear-gradient(rgba(50, 37, 44, .88), rgba(50, 37, 44, .88)),
    url("assets/materials/black/pattern_tile_04_01.svg");
  background-size: auto, 42px 30px;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .1);
}

.observation-file-title strong {
  font: 8px var(--pixel);
  letter-spacing: .08em;
}

.observation-file-title span {
  color: #eebbd0;
  font: 6px var(--pixel);
  letter-spacing: .06em;
}

.master-facts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin-top: 7px;
}

.master-facts section {
  display: grid;
  grid-template-columns: 58px 1fr;
  align-items: center;
  min-height: 31px;
  border: 1px solid rgba(126, 88, 107, .25);
  background: rgba(255, 240, 246, .82);
}

.master-facts span {
  align-self: stretch;
  display: grid;
  place-items: center;
  border-right: 1px dotted #ba8da2;
  color: #8a6175;
  font: 700 8px var(--serif);
  letter-spacing: .08em;
}

.master-facts b {
  padding-left: 8px;
  font: 9px var(--pixel);
}

.master-interests {
  margin-top: 7px;
  padding: 7px 8px 8px;
  border: 1px solid rgba(113, 80, 96, .24);
  background: rgba(255, 253, 251, .88);
}

.master-interests h3,
.rei-observation h3 {
  margin: 0 0 6px;
  color: #7f566b;
  font: 700 8px var(--pixel);
  letter-spacing: .1em;
  display: flex;
  align-items: center;
  gap: 5px;
}

.master-interests h3::before,
.rei-observation h3::before {
  content: "";
  display: block;
  flex: 0 0 9px;
  width: 9px;
  height: 9px;
  margin: 0;
  background: #b47291;
  clip-path: polygon(40% 0, 60% 0, 60% 32%, 78% 23%, 100% 42%, 72% 50%, 100% 58%, 78% 77%, 60% 68%, 60% 100%, 40% 100%, 40% 68%, 22% 77%, 0 58%, 28% 50%, 0 42%, 22% 23%, 40% 32%);
  pointer-events: none;
}

.master-interests ul {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px 5px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.master-interests li {
  position: relative;
  min-height: 19px;
  padding: 4px 6px 3px 20px;
  border: 1px solid rgba(180, 130, 153, .22);
  background: rgba(247, 224, 234, .66);
  font: 8.3px/1.25 var(--serif);
}

.master-interests li::before {
  content: "◆";
  position: absolute;
  left: 7px;
  top: 50%;
  transform: translateY(-50%);
  color: #ad6f8d;
  font-family: serif;
  font-size: 5px;
  line-height: 1;
  pointer-events: none;
}

.rei-observation {
  margin-top: 7px;
  padding: 8px 10px 7px;
  border: 1px solid rgba(93, 65, 79, .28);
  border-left: 3px double #9f627f;
  background: rgba(255, 248, 249, .9);
}

.rei-observation p {
  margin: 0 0 3px;
  color: #4d3c45;
  font: 9px/1.42 var(--serif);
}

.rei-observation p:last-child {
  margin-bottom: 0;
  color: #814e67;
  font-weight: 700;
}

.observation-meta {
  display: grid;
  grid-template-columns: 1.15fr .72fr 1fr;
  gap: 5px;
  margin: 7px 0 0;
  padding: 0 0 14px;
}

.observation-meta div {
  padding: 5px 6px;
  border-top: 2px solid #51404a;
  background: rgba(241, 216, 227, .64);
}

.observation-meta dt {
  color: #8a6476;
  font: 5.5px var(--pixel);
  letter-spacing: .05em;
}

.observation-meta dd {
  margin: 3px 0 0;
  color: #43343c;
  font: 6.8px var(--pixel);
  white-space: nowrap;
}

.library-intro {
  width: 92%;
  margin: -3px 0 9px;
  padding: 6px 9px;
  border-left: 3px double #55414c;
  color: #735b68;
  background: rgba(255, 249, 247, .76);
  font: 7.6px/1.55 var(--serif);
}

.library-shelf {
  display: grid;
  gap: 6px;
}

.library-slip {
  position: relative;
  display: grid;
  grid-template-columns: 53px minmax(0, 1fr) 60px;
  grid-template-rows: auto auto;
  gap: 1px 8px;
  width: 100%;
  min-height: 57px;
  padding: 7px 10px 7px 13px;
  overflow: hidden;
  border: 1px solid #9a7989;
  border-left: 5px solid #392b33;
  border-radius: 0;
  color: #4a3842;
  text-align: left;
  background-color: rgba(255, 250, 248, .92);
  background-image: linear-gradient(90deg, transparent 0 53px, rgba(145, 105, 123, .18) 53px 54px, transparent 54px),
    url("assets/materials/pink/pattern_tile_01_01.svg");
  background-size: auto, 86px 86px;
  box-shadow: 2px 2px 0 rgba(48, 36, 43, .13);
}

.library-slip::after {
  content: "✠";
  position: absolute;
  top: 50%;
  left: 5px;
  color: rgba(255, 238, 245, .86);
  font: 9px var(--serif);
  transform: translateY(-50%);
}

.library-slip:hover,
.library-slip:focus-visible {
  border-color: #4c3742;
  background-color: var(--rei-blush-highlight);
  transform: translateX(2px);
}

.library-slip.featured {
  border-top: 2px double #3d2e36;
  border-bottom: 2px double #3d2e36;
  background-color: rgba(247, 226, 235, .94);
}

.library-slip-no,
.library-slip time,
.library-slip small {
  color: #917181;
  font: 6.2px/1.25 var(--pixel);
  letter-spacing: .04em;
}

.library-slip-no {
  grid-row: 1 / 3;
  align-self: center;
  color: #5b4550;
  font-weight: 700;
}

.library-slip time {
  grid-column: 3;
  grid-row: 1;
  text-align: right;
}

.library-slip strong {
  grid-column: 2 / 4;
  grid-row: 1;
  min-width: 0;
  overflow: hidden;
  font: 600 9.5px/1.35 var(--serif);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.library-slip small {
  grid-column: 2 / 4;
  grid-row: 2;
  align-self: end;
}

.page-end {
  margin-top: 6px;
  color: #8f7381;
  font-size: 7px;
  text-align: center;
}

body.library-open {
  overflow: hidden;
}

body.library-open .ceiling {
  z-index: 1;
}

.library-reader {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: grid;
  place-items: center;
  padding: 3vh 3vw;
}

.library-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: linear-gradient(rgba(28, 20, 25, .82), rgba(28, 20, 25, .88)),
    url("assets/materials/black/pattern_tile_04_01.svg") repeat;
  background-size: auto, 170px 121px;
  backdrop-filter: blur(5px);
}

.library-vault {
  position: relative;
  display: grid;
  grid-template-rows: 78px minmax(0, 1fr);
  width: min(1180px, 94vw);
  height: min(860px, 94vh);
  overflow: hidden;
  border: 5px double #1f171c;
  outline: 1px solid #d5a8ba;
  color: #46363f;
  background: #f9eef2;
  box-shadow: 0 24px 80px rgba(15, 8, 12, .55), inset 0 0 0 7px rgba(255, 255, 255, .38);
}

.library-vault::before,
.library-vault::after {
  content: "";
  position: absolute;
  z-index: 4;
  right: 0;
  left: 0;
  height: 19px;
  pointer-events: none;
  background: url("assets/library/black/02_borders_frames/border_004.svg") repeat-x center / auto 19px;
}

.library-vault::before {
  top: 73px;
}

.library-vault::after {
  bottom: 0;
  transform: rotate(180deg);
}

.library-vault-header {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: 54px 1fr 44px;
  align-items: center;
  gap: 12px;
  padding: 9px 18px;
  border-bottom: 2px solid #2e2229;
  color: #fff7f9;
  background-color: #33262e;
  background-image: linear-gradient(rgba(48, 35, 43, .9), rgba(48, 35, 43, .9)),
    url("assets/materials/black/pattern_tile_01_01.svg");
  background-size: auto, 120px 119px;
}

.library-vault-header p {
  margin: 0;
  color: #d9a9be;
  font: 8px var(--pixel);
  letter-spacing: .16em;
}

.library-vault-header h2 {
  margin: 1px 0 0;
  color: var(--rei-vellum-highlight);
  font: 25px/1.05 var(--serif);
  letter-spacing: .18em;
}

.library-sigil {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 3px double #dca8bd;
  border-radius: 50%;
  color: #f1c5d7;
  font: 26px var(--serif);
  box-shadow: inset 0 0 0 4px rgba(255, 255, 255, .06);
}

.library-close {
  width: 38px;
  height: 38px;
  border: 2px double #d9a7bc;
  border-radius: 0;
  color: var(--rei-vellum-highlight);
  background: #251a20;
  font: 26px/1 var(--serif);
}

.library-vault-layout {
  display: grid;
  grid-template-columns: 286px minmax(0, 1fr);
  min-height: 0;
  padding-bottom: 14px;
}

.library-record-nav {
  min-width: 0;
  padding: 28px 14px 24px;
  overflow-y: auto;
  border-right: 4px double #5d4451;
  background-color: #ead9df;
  background-image: linear-gradient(rgba(250, 238, 242, .7), rgba(250, 238, 242, .7)),
    url("assets/materials/black/pattern_tile_02_01.svg");
  background-size: auto, 126px 117px;
}

.library-nav-label {
  margin: 0 0 10px;
  padding: 5px 7px;
  border-top: 2px solid #3c2c34;
  border-bottom: 1px dotted #745663;
  color: #5b414e;
  font: 700 9px var(--pixel);
  letter-spacing: .08em;
}

.library-record-button {
  position: relative;
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 2px 8px;
  width: 100%;
  margin: 0 0 8px;
  padding: 9px 8px 9px 11px;
  border: 1px solid #a48493;
  border-left: 4px solid #3d2d35;
  border-radius: 0;
  text-align: left;
  background: rgba(255, 250, 248, .91);
}

.library-record-button::before {
  content: "✞";
  grid-row: 1 / 3;
  align-self: center;
  color: #8a6375;
  font: 19px var(--serif);
  text-align: center;
}

.library-record-button strong {
  min-width: 0;
  font: 600 11px/1.45 var(--serif);
}

.library-record-button small {
  color: #927282;
  font: 7px var(--pixel);
}

.library-record-button.active {
  color: var(--rei-vellum-highlight);
  border-color: #21171d;
  background: #3a2b33;
  box-shadow: 3px 3px 0 #d7a4b9;
}

.library-record-button.active::before,
.library-record-button.active small {
  color: #efbfd3;
}

.library-document {
  min-width: 0;
  padding: 42px clamp(26px, 5vw, 72px) 54px;
  overflow-y: auto;
  scroll-behavior: smooth;
  background-color: #fffbf8;
  background-image: linear-gradient(rgba(255, 251, 248, .91), rgba(255, 251, 248, .91)),
    url("assets/materials/pink/pattern_tile_04_01.svg");
  background-size: auto, 132px 94px;
}

.library-document-header {
  position: relative;
  margin-bottom: 24px;
  padding: 0 0 18px;
  border-bottom: 4px double #5b404d;
  text-align: center;
}

.library-document-header::after {
  content: "✠";
  position: absolute;
  right: 0;
  bottom: -14px;
  left: 0;
  width: 30px;
  margin: auto;
  color: #8c6074;
  background: #fffaf8;
  font: 17px var(--serif);
}

.library-document-header > p {
  margin: 0 0 7px;
  color: #9d7185;
  font: 8px var(--pixel);
  letter-spacing: .15em;
}

.library-document-header h3 {
  max-width: 760px;
  margin: auto;
  color: #3f2e37;
  font: 700 clamp(22px, 3.1vw, 36px)/1.38 var(--serif);
  overflow-wrap: anywhere;
  font-family: var(--serif);
}

.library-document-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 5px;
  margin-top: 12px;
  color: #765865;
  font: 8px var(--pixel);
}

.library-document-meta span {
  padding: 3px 8px;
  border: 1px solid #c49daf;
  background: #fff4f7;
}

.library-featured {
  max-width: 720px;
  margin: 0 auto 28px;
  padding: 8px;
  border: 4px double #5a414d;
  background: #f1dbe4;
  box-shadow: 7px 7px 0 rgba(57, 42, 50, .12);
}

.library-featured img {
  display: block;
  width: 100%;
  max-height: 520px;
  object-fit: contain;
}

.library-content {
  max-width: 780px;
  margin: auto;
  color: #43363c;
  font: 15px/1.9 var(--serif);
  overflow-wrap: anywhere;
}

.library-content h2,
.library-content h3,
.library-content h4,
.library-content h5,
.library-content h6 {
  clear: both;
  margin: 1.8em 0 .72em;
  color: #46323c;
  font-family: var(--serif);
  line-height: 1.45;
}

.library-content h2 {
  padding: 6px 11px;
  border-left: 5px solid #3b2b33;
  border-bottom: 1px dotted #a67e91;
  background: rgba(238, 208, 220, .52);
  font-size: 24px;
}

.library-content h3 {
  font-size: 20px;
}

.library-content p {
  margin: 0 0 1.15em;
}

.library-content ul,
.library-content ol {
  padding-left: 1.7em;
}

.library-content blockquote {
  margin: 1.5em 0;
  padding: 12px 18px;
  border: 3px double #a47d8f;
  background: rgba(249, 229, 237, .72);
}

.library-content pre {
  max-width: 100%;
  padding: 15px 17px;
  overflow: auto;
  border: 2px solid #523e48;
  color: #fceff5;
  background: #2f252b;
  font: 12px/1.62 var(--pixel);
  white-space: pre-wrap;
}

.library-content :not(pre) > code {
  padding: 1px 4px;
  color: #5d3e4d;
  background: #f2dbe5;
  font: .88em var(--pixel);
}

.library-content figure {
  max-width: 100%;
  margin: 24px auto;
  text-align: center;
}

.library-content img,
.library-content video {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 18px auto;
  border: 5px double #715462;
  background: #f2dbe4;
  box-shadow: 6px 6px 0 rgba(52, 38, 46, .11);
}

.library-content figcaption {
  margin-top: -10px;
  color: #826876;
  font: 11px/1.55 var(--serif);
}

.library-content table {
  width: 100%;
  border-collapse: collapse;
}

.library-content th,
.library-content td {
  padding: 6px 8px;
  border: 1px solid #b58d9f;
}

.library-content a {
  text-decoration: underline;
  text-decoration-style: dotted;
  text-underline-offset: 3px;
}

.library-loading,
.library-error {
  padding: 18px;
  color: var(--rei-muted-mauve);
  font: 11px var(--pixel);
  text-align: center;
}

.library-error {
  border: 2px double #9d6b81;
  background: #fbe8ef;
}

.library-document-footer {
  display: grid;
  grid-template-columns: 120px 1fr 120px;
  align-items: center;
  gap: 12px;
  max-width: 780px;
  margin: 52px auto 0;
  padding-top: 20px;
  border-top: 4px double #5a404d;
  color: #8c6b79;
  font: 7px var(--pixel);
  text-align: center;
}

.library-document-footer button {
  min-height: 34px;
  border: 2px double #49353f;
  color: #fff6f9;
  background: #3c2c34;
  font: 8px var(--pixel);
}

.library-document-footer button:disabled {
  opacity: .35;
}

.diary-tools {
  display: flex;
  gap: 6px;
  margin: 4px 0 8px;
}

.memory-index-subtitle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: -6px 0 5px;
  color: #745464;
  font: 8px var(--serif);
  letter-spacing: .08em;
}

.memory-index-subtitle span {
  color: #9b7184;
  font: 5.5px var(--pixel);
}

.memory-search-note {
  min-height: 10px;
  margin: -5px 0 4px;
  color: #8c5871;
  font: 6px var(--pixel);
}

.year-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 9px;
}

.year-tabs button {
  padding: 3px 6px;
  border: 1px solid #c7a5b5;
  border-radius: 0;
  color: #6f5361;
  background: rgba(255, 248, 250, .9);
  font: 7px var(--pixel);
  cursor: pointer;
}

.year-tabs button:hover,
.year-tabs button.is-active {
  color: #382a32;
  background: #e7b7ca;
  box-shadow: inset 0 -2px #845c6e;
}

.mini-calendar {
  border: 2px double #9f7589;
  background: rgba(255, 253, 251, .88);
}

.cal-head {
  display: grid;
  grid-template-columns: 25px 1fr 25px;
  align-items: center;
  padding: 5px;
  border-bottom: 1px dotted #c6a4b4;
  font-size: 8px;
  letter-spacing: .1em;
  text-align: center;
}

.cal-head button {
  width: 23px;
  height: 19px;
  padding: 0;
  border: 1px solid #b98fa2;
  border-radius: 0;
  color: #604451;
  background: #f8e9ef;
  font: 14px/1 var(--serif);
  cursor: pointer;
}

.cal-head button:disabled {
  opacity: .25;
}

.week,
.days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
}

.week i {
  padding: 3px 0;
  color: #947b87;
  font: 6px var(--pixel);
  text-align: center;
}

.days > * {
  min-height: 38px;
  padding: 4px;
  border-top: 1px dotted #dfcbd4;
  border-right: 1px dotted #dfcbd4;
  border-bottom: 0;
  border-left: 0;
  border-radius: 0;
  color: #5b4651;
  background: rgba(255, 253, 251, .36);
  font: 8px var(--pixel);
  text-align: left;
}

.days button {
  cursor: pointer;
}

.days button:hover {
  background: #f6dce7;
}

.days small {
  display: block;
  color: #b95f88;
  font-size: 6px;
}

.days button.is-selected {
  background: #efcad9;
  box-shadow: inset 0 0 0 2px #a46f87;
}

.diary-source-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 8px;
}

.diary-source-legend span {
  color: #8e7180;
  font-size: 6px;
}

.diary-source-legend b {
  margin-left: auto;
  color: #725260;
  font: 5.5px var(--pixel);
}

.rei-diary-gif,
.rei-sort-gif,
.rei-glitch-gif,
.rei-sleep-gif {
  position: absolute;
  object-fit: contain;
}

.rei-diary-gif {
  right: 14px;
  bottom: 12px;
  width: 92px;
  max-height: 96px;
}

.diary-entry {
  position: relative;
  margin: 0 0 10px;
  padding: 7px 9px 9px 24px;
  border: 1px solid rgba(111, 79, 95, .16);
  border-bottom: 1px dotted #ceb3c0;
  background: rgba(255, 253, 251, .83);
}

.diary-entry-list {
  max-height: 375px;
  overflow: auto;
  scrollbar-width: thin;
  scrollbar-color: #bd8da4 rgba(255, 247, 250, .72);
}

.memory-day-navigation {
  display: grid;
  grid-template-columns: 1fr 1.2fr 1fr;
  gap: 4px;
  margin: -5px 0 8px;
}

.memory-day-navigation button {
  min-height: 25px;
  padding: 3px 4px;
  border: 1px solid #ac8497;
  border-radius: 0;
  color: #5d4450;
  background: rgba(255, 245, 248, .88);
  font: 6px var(--pixel);
  cursor: pointer;
}

.memory-day-navigation button:nth-child(2) {
  color: #fff7fa;
  background: #493641;
}

.memory-day-navigation button:disabled {
  opacity: .28;
}

.diary-entry-list .diary-entry:last-child {
  margin-bottom: 4px;
}

.diary-entry[data-memory-record] {
  padding-right: 25px;
  cursor: pointer;
}

.diary-entry[data-memory-record]:hover,
.diary-entry[data-memory-record]:focus {
  outline: 1px solid #a86f89;
  background: rgba(255, 244, 248, .96);
}

.diary-entry[data-memory-record]::after {
  content: "開啟\A卷宗";
  position: absolute;
  top: 7px;
  right: 5px;
  color: #9c6880;
  font: 5px/1.3 var(--pixel);
  text-align: center;
  white-space: pre;
}

.diary-entry.is-reply {
  border-left: 3px solid #cb91aa;
}

.diary-entry.is-retweet {
  border-left: 3px solid #4d3943;
}

.diary-entry-media {
  display: flex;
  gap: 4px;
  margin-top: 5px;
  color: #9d6480;
  font-size: 6px;
}

.diary-entry-thumbs {
  display: flex;
  gap: 4px;
  margin-top: 5px;
}

.diary-entry-thumbs img {
  width: 39px;
  height: 29px;
  object-fit: cover;
  border: 1px solid #8f687a;
  background: #ead4de;
}

.memory-empty {
  padding: 22px 12px;
  border: 1px dashed #bd98aa;
  color: #806b76;
  background: rgba(255, 250, 252, .72);
  font: 9px/1.7 var(--serif);
  text-align: center;
}

.diary-entry::before {
  content: "✧";
  position: absolute;
  top: 6px;
  left: 7px;
  color: #bf6f94;
}

.diary-entry time {
  color: #8e7280;
  font-size: 7px;
}

.diary-entry p {
  margin: 3px 0;
  font: 9px/1.55 var(--serif);
}

.memory-mark {
  position: absolute;
  top: 0;
  right: 0;
  border: 0;
  color: #bf6e93;
  background: transparent;
  font-size: 15px;
}

.related-memory {
  display: flex;
  align-items: center;
  gap: 5px;
  color: #946c81;
  font-size: 7px;
}

.related-memory img {
  width: 22px;
  height: 22px;
}

body.memory-open {
  overflow: hidden;
}

.memory-reader {
  position: fixed;
  z-index: 260;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 28px;
}

.memory-reader[hidden] {
  display: none;
}

.memory-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: rgba(27, 18, 23, .72);
  backdrop-filter: blur(4px);
}

.memory-vellum {
  position: relative;
  width: min(670px, calc(100vw - 34px));
  max-height: min(760px, calc(100vh - 44px));
  padding: 28px 38px 54px;
  overflow-y: auto;
  border: 6px double #44313b;
  outline: 1px solid #d6aabd;
  outline-offset: -11px;
  color: #3f3037;
  background-color: #fbf1e8;
  background-image: linear-gradient(rgba(253, 246, 239, .91), rgba(253, 246, 239, .91)),
    url("assets/materials/pink/pattern_tile_03_01.svg");
  background-size: auto, 142px 110px;
  box-shadow: 0 22px 70px rgba(17, 10, 14, .48), inset 0 0 48px rgba(112, 73, 91, .08);
  display: flex;
  flex-direction: column;
  min-height: min(520px, calc(100vh - 44px));
  padding-bottom: 10px;
  scroll-padding-bottom: 0;
}

.memory-vellum::before,
.memory-vellum::after {
  content: "";
  position: absolute;
  right: 28px;
  left: 28px;
  height: 15px;
  pointer-events: none;
  background: url("assets/materials/black/border_004.svg") repeat-x center / auto 15px;
  z-index: 0;
  opacity: .72;
}

.memory-vellum > * {
  position: relative;
  z-index: 1;
}

.vellum-corner {
  position: absolute;
  z-index: 2;
  color: #785266;
  font: 18px var(--serif);
}

.vellum-corner.tl {
  top: 13px;
  left: 15px;
}

.vellum-corner.tr {
  top: 13px;
  right: 15px;
}

.vellum-corner.bl {
  bottom: 13px;
  left: 15px;
}

.vellum-corner.br {
  right: 15px;
  bottom: 13px;
}

.memory-vellum-header {
  display: grid;
  grid-template-columns: 48px 1fr 34px;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  padding: 8px 0 15px;
  border-bottom: 4px double #745363;
}

.memory-vellum-header img {
  width: 43px;
  height: 43px;
  object-fit: contain;
}

.memory-vellum-header p {
  margin: 0 0 4px;
  color: #966b80;
  font: 7px var(--pixel);
  letter-spacing: .12em;
}

.memory-vellum-header h2 {
  margin: 0;
  font: 24px/1.2 var(--serif);
  letter-spacing: .1em;
}

.memory-vellum-header button {
  width: 32px;
  height: 32px;
  padding: 0;
  border: 2px double #624653;
  border-radius: 0;
  color: var(--rei-vellum-highlight);
  background: #36272f;
  font: 22px/1 var(--serif);
  cursor: pointer;
}

.memory-vellum-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 15px;
}

.memory-vellum-meta span {
  padding: 4px 7px;
  border: 1px solid #c09aaa;
  background: rgba(250, 224, 234, .64);
  color: #745260;
  font: 7px var(--pixel);
}

.memory-vellum-body {
  min-height: 100px;
  padding: 18px 20px;
  border: 1px solid rgba(107, 73, 89, .27);
  border-left: 4px double #7b5366;
  background: rgba(255, 253, 248, .8);
  font: 15px/1.9 var(--serif);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.memory-vellum footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 17px;
  padding-top: 10px;
  border-top: 1px dotted #a98596;
  color: var(--rei-muted-mauve);
  font: 6px var(--pixel);
}

.memory-vellum footer b {
  color: #674654;
}

.collection-note {
  padding: 8px;
  border: 1px solid rgba(111, 79, 95, .17);
  border-left: 3px double #9b7185;
  background: rgba(255, 251, 250, .88);
}

.collection-note span {
  color: #8c7080;
  font-size: 7px;
}

.collection-note p {
  margin: 3px 0;
  font: 9px/1.55 var(--serif);
}

.module-title-line {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 4px double #735363;
}

.module-title-line h2 {
  margin: 0;
}

.module-title-line p {
  margin: 4px 0 0;
  color: #8c6b7b;
  font: 6px var(--pixel);
  letter-spacing: .13em;
}

.module-title-line > b {
  flex: 0 0 auto;
  padding: 4px 6px;
  border: 1px solid #ab8395;
  background: rgba(255,249,251,.82);
  color: #725260;
  font: 6px var(--pixel);
}

.cabinet-door-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.cabinet-door-grid button {
  position: relative;
  display: grid;
  align-content: center;
  min-height: 112px;
  padding: 14px 12px 12px 34px;
  overflow: hidden;
  border: 4px double #493741;
  outline: 1px solid #d5a9ba;
  outline-offset: -7px;
  color: #fbedf3;
  background-color: #352830;
  background-image: linear-gradient(rgba(46,34,41,.88),rgba(46,34,41,.93)),url("assets/materials/black/pattern_tile_01_01.svg");
  background-size: auto,74px 74px;
  text-align: left;
  cursor: pointer;
  box-shadow: 3px 3px 0 rgba(204,151,174,.62);
}

.cabinet-door-grid button:nth-child(even) {
  background-image: linear-gradient(rgba(54,40,48,.89),rgba(54,40,48,.94)),url("assets/materials/black/pattern_tile_04_01.svg");
}

.cabinet-door-grid button::after {
  content: "✠";
  position: absolute;
  right: 9px;
  bottom: 5px;
  color: rgba(240,188,209,.24);
  font: 30px var(--serif);
}

.cabinet-door-grid i {
  position: absolute;
  top: 8px;
  bottom: 8px;
  left: 8px;
  display: grid;
  place-items: center;
  width: 18px;
  border-right: 1px dotted #b78299;
  color: #dca9bd;
  font: 8px var(--pixel);
}

.cabinet-door-grid strong {
  position: relative;
  z-index: 1;
  font: 12px/1.35 var(--serif);
  letter-spacing: .05em;
}

.cabinet-door-grid span,.cabinet-door-grid small {
  position: relative;
  z-index: 1;
  display: block;
}

.cabinet-door-grid span {
  margin-top: 5px;
  color: #d5aabd;
  font: 5px var(--pixel);
  letter-spacing: .08em;
}

.cabinet-door-grid small {
  margin-top: 10px;
  color: #f1dbe4;
  font: 6px var(--pixel);
}

.cabinet-door-grid button.has-relics small {
  color: #efb6ce;
}

.master-collection-page .collection-note {
  margin-top: 12px;
  padding: 10px 11px;
}

.reliquary-intro {
  margin: 0 0 10px;
  padding: 8px 9px;
  border-left: 3px double #96677c;
  background: rgba(255,250,249,.83);
  font: 9px/1.6 var(--serif);
}

.reliquary-door-grid {
  display: grid;
  grid-template-columns: repeat(2,1fr);
  gap: 7px;
}

.reliquary-door-grid button {
  display: grid;
  grid-template-columns: 48px 1fr;
  align-items: center;
  min-height: 75px;
  padding: 7px;
  border: 2px double #947083;
  background: rgba(255,248,250,.9);
  color: #47333e;
  text-align: left;
  cursor: pointer;
  box-shadow: inset 0 0 0 3px rgba(233,194,210,.25);
}

.reliquary-door-grid button:nth-child(3n+1) {
  background: rgba(53,40,48,.92);
  color: #fff1f6;
}

.reliquary-door-grid img {
  width: 44px;
  height: 48px;
  object-fit: contain;
}

.reliquary-door-grid span {
  padding-left: 7px;
  border-left: 1px dotted #b58a9d;
  font: 9px/1.4 var(--serif);
}

.reliquary-door-grid b {
  display: block;
  margin-top: 5px;
  color: #9b7184;
  font: 6px var(--pixel);
}

.reliquary-door-grid button:nth-child(3n+1) b {
  color: #e2abc2;
}

.rei-collection-page .tiny-handnote {
  margin-top: 10px;
}

@keyframes radarSweep {
  to {
    transform: rotate(360deg);
  }
}

.archive-overlay {
  position: fixed;
  z-index: 920;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 22px;
}

.archive-overlay[hidden] {
  display: none;
}

.archive-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(30,19,25,.76);
  backdrop-filter: blur(4px);
}

.archive-vault {
  position: relative;
  width: min(1120px,calc(100vw - 30px));
  height: min(760px,calc(100vh - 34px));
  overflow: hidden;
  border: 6px double #4f3844;
  outline: 3px solid #d1a1b4;
  outline-offset: -12px;
  color: #33262d;
  background: #f8efe9 url("assets/materials/pink/pattern_tile_01_01.svg") repeat;
  background-size: 124px;
  box-shadow: 0 22px 80px rgba(22,13,18,.55);
}

.archive-vault::after {
  content: "";
  position: absolute;
  pointer-events: none;
  inset: 13px;
  border: 1px dotted rgba(93,61,77,.35);
}

.archive-vault-header {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 46px 1fr 38px;
  align-items: center;
  gap: 12px;
  min-height: 86px;
  padding: 18px 22px 12px;
  border-bottom: 4px double #684b59;
  background: rgba(250,241,236,.93);
}

.archive-sigil {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 3px double #765563;
  font: 24px var(--serif);
}

.archive-vault-header p {
  margin: 0 0 4px;
  color: var(--rei-muted-mauve);
  font: 7px var(--pixel);
  letter-spacing: .1em;
}

.archive-vault-header h2 {
  margin: 0;
  font: 24px var(--serif);
  letter-spacing: .1em;
}

.archive-vault-header > button {
  width: 34px;
  height: 34px;
  border: 3px double #73515f;
  color: var(--rei-vellum-highlight);
  background: #33242c;
  font: 21px/1 var(--serif);
  cursor: pointer;
}

.archive-vault-layout {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 230px 1fr;
  height: calc(100% - 86px);
}

.archive-category-nav {
  padding: 17px 13px;
  overflow: auto;
  border-right: 4px double #8f6c7b;
  background: rgba(48,36,43,.94) url("assets/materials/black/pattern_tile_04_01.svg") repeat;
  background-size: 78px 56px;
}

.archive-category-nav button {
  display: grid;
  width: 100%;
  margin-bottom: 8px;
  padding: 11px;
  border: 1px solid #9e7386;
  color: #f2dfe7;
  background: rgba(255,255,255,.04);
  text-align: left;
  cursor: pointer;
}

.archive-category-nav button.is-active {
  border-color: #e0a7c0;
  background: rgba(221,151,181,.2);
  box-shadow: inset 3px 0 #e2abc2;
}

.archive-category-nav strong {
  font: 12px var(--serif);
}

.archive-category-nav span {
  margin-top: 4px;
  color: #cf9db2;
  font: 6px var(--pixel);
}

.archive-gallery-pane {
  padding: 22px 24px 28px;
  overflow: auto;
  background: linear-gradient(rgba(255,250,247,.82),rgba(255,250,247,.82)),url("assets/materials/pink/pattern_tile_02_02.svg") repeat;
  background-size: auto,120px;
}

.archive-gallery-pane > header {
  margin-bottom: 16px;
  padding-bottom: 13px;
  border-bottom: 3px double #8c6878;
}

.archive-gallery-pane > header > p:first-child {
  margin: 0;
  color: #956b7e;
  font: 7px var(--pixel);
}

.archive-gallery-pane h3 {
  margin: 5px 0;
  font: 24px var(--serif);
}

#collectionCabinetDescription {
  margin: 0;
  color: #705864;
  font: 12px/1.65 var(--serif);
}

.relic-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill,minmax(170px,1fr));
  gap: 13px;
}

.relic-card {
  padding: 8px;
  border: 3px double #896879;
  background: rgba(255,252,249,.92);
  cursor: pointer;
  box-shadow: 3px 4px 0 rgba(157,111,131,.18);
}

.relic-card img {
  display: block;
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  background: #e5d2da;
}

.relic-card strong {
  display: block;
  margin: 8px 0 3px;
  font: 13px var(--serif);
}

.relic-card span {
  color: #846674;
  font: 7px var(--pixel);
}

.relic-empty {
  grid-column: 1/-1;
  padding: 70px 25px;
  border: 1px dotted #a78292;
  background: rgba(255,251,248,.75);
  color: #7c6170;
  font: 14px/1.8 var(--serif);
  text-align: center;
}

.relic-detail {
  position: absolute;
  z-index: 4;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0,1.15fr) minmax(300px,.85fr);
  gap: 24px;
  padding: 35px;
  overflow: auto;
  background: #f8efea url("assets/materials/pink/pattern_tile_03_02.svg") repeat;
  background-size: 120px;
}

.relic-detail[hidden] {
  display: none;
}

.relic-detail > button {
  position: absolute;
  z-index: 2;
  top: 12px;
  left: 16px;
  padding: 6px 10px;
  border: 1px solid #795867;
  background: #33252c;
  color: #fff4f8;
  cursor: pointer;
  font: 8px var(--pixel);
}

.relic-detail-photos {
  display: grid;
  align-content: start;
  gap: 9px;
  padding-top: 23px;
}

.relic-detail-photos img {
  width: 100%;
  max-height: 580px;
  object-fit: contain;
  border: 5px double #71505f;
  background: #e3cfd8;
}

.relic-detail > div:last-child {
  align-self: center;
  padding: 27px;
  border: 4px double #795867;
  background: rgba(255,251,247,.9);
}

.relic-detail > div > p:first-child {
  color: #93697b;
  font: 7px var(--pixel);
}

.relic-detail h3 {
  margin: 8px 0 12px;
  font: 25px var(--serif);
}

.relic-detail #collectionDetailDescription {
  white-space: pre-wrap;
  font: 13px/1.85 var(--serif);
}

.relic-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 12px;
}

.relic-meta span {
  padding: 4px 6px;
  border: 1px solid #b790a1;
  background: #f2dce5;
  font: 7px var(--pixel);
}

.relic-detail small {
  display: block;
  margin-top: 20px;
  color: #8b6a79;
  font: 6px var(--pixel);
}

.reliquary-vault-body {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-rows: auto 1fr;
  height: calc(100% - 86px);
  padding: 15px 20px 23px;
}

.reliquary-category-tabs {
  display: flex;
  gap: 6px;
  padding-bottom: 12px;
  overflow-x: auto;
}

.reliquary-category-tabs button {
  flex: 0 0 auto;
  padding: 7px 11px;
  border: 2px double #755463;
  background: #f5dfe8;
  cursor: pointer;
  font: 9px var(--serif);
}

.reliquary-category-tabs button.is-active {
  color: #fff3f7;
  background: #362830;
}

.asset-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill,minmax(145px,1fr));
  gap: 9px;
  align-content: start;
  overflow: auto;
  padding-right: 5px;
}

.asset-card {
  padding: 8px;
  border: 1px dotted #a47d8f;
  background: rgba(255,252,249,.88);
}

.asset-card img {
  display: block;
  width: 100%;
  height: 112px;
  object-fit: contain;
  background: linear-gradient(45deg,var(--rei-lace-border) 25%,transparent 25%,transparent 75%,var(--rei-lace-border) 75%),linear-gradient(45deg,var(--rei-lace-border) 25%,#fff9f6 25%,#fff9f6 75%,var(--rei-lace-border) 75%);
  background-position: 0 0,7px 7px;
  background-size: 14px 14px;
}

.asset-card strong {
  display: block;
  margin-top: 7px;
  overflow: hidden;
  font: 10px var(--serif);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.asset-card small {
  display: flex;
  justify-content: space-between;
  margin-top: 4px;
  color: #846774;
  font: 6px var(--pixel);
}

.asset-card .is-used {
  color: #4f725d;
}

body.archive-module-open {
  overflow: hidden;
}

.lost-intro {
  width: 92%;
  margin: 0 auto 9px;
  padding: 6px 9px;
  border-top: 1px solid rgba(94, 65, 79, .44);
  border-bottom: 1px solid rgba(94, 65, 79, .44);
  color: #6d5360;
  background: rgba(255, 253, 251, .78);
  font: 8px/1.55 var(--serif);
  text-align: center;
}

@keyframes sealedFlame {
  from {
    transform: rotate(5deg) scale(.94);
  }
  to {
    transform: rotate(-5deg) scale(1.08);
  }
}

.ai-reliquary {
  padding: 10px;
  border: 3px double #daa7be;
  outline: 2px solid #43333c;
  color: #f9e8ef;
  background: #342b33;
  position: relative;
}

.ai-header {
  display: grid;
  grid-template-columns: 30px 1fr auto;
  align-items: center;
  padding-bottom: 5px;
  border-bottom: 1px dotted #c389a4;
  font-size: 7px;
}

.ai-header img {
  width: 26px;
}

.ai-header b {
  color: #dba8bd;
  font-size: 6px;
}

.ai-log {
  height: 215px;
  margin: 8px 0;
  padding: 9px;
  overflow: auto;
  border: 1px solid #6e5663;
  color: #f8e7ee;
  background: #231e23;
  font: 8px/1.6 var(--pixel);
}

.ai-log p {
  margin: 0 0 8px;
}

.ai-log b {
  color: #efaeca;
}

.ai-reliquary form {
  display: grid;
  grid-template-columns: 1fr 48px;
}

.ai-reliquary input {
  padding: 5px;
  border: 1px solid #8c687b;
  background: var(--rei-vellum-highlight);
}

.ai-reliquary button {
  border: 1px outset #c9a5b6;
  background: #edcddd;
}

.rei-glitch-gif {
  right: 17px;
  bottom: 15px;
  width: 82px;
  opacity: .75;
}

.library-content .rei-table-scroll {
  display: block;
  max-width: 100%;
  margin: 1.25em 0;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-inline: contain;
  -webkit-overflow-scrolling: touch;
}

.library-content .rei-table-scroll table {
  width: 100%;
  margin: 0;
  border-collapse: collapse;
  table-layout: auto;
}

.library-content .rei-table-scroll.rei-table-wide table {
  min-width: 760px;
}

.library-content .rei-table-scroll th,
.library-content .rei-table-scroll td {
  box-sizing: border-box;
  vertical-align: top;
  overflow-wrap: break-word;
  word-break: normal;
}

.library-content math {
  font-family: serif;
}

.library-content math[display="block"] {
  display: block;
  max-width: 100%;
  margin: 1.2em auto;
  padding: .15em 0;
  overflow-x: auto;
  overflow-y: hidden;
  text-align: center;
  font-size: 1.08em;
  -webkit-overflow-scrolling: touch;
}

@media (max-width: 600px) {
  .library-content .rei-table-scroll {
    margin: 1em 0;
  }
  .library-content .rei-table-scroll.rei-table-wide table {
    min-width: 680px;
  }
  .library-content math[display="block"] {
    font-size: 1em;
  }
}

.bbs-board header {
  font-size: 6.5px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  color: #8e7280;
  font: 6.5px/1.35 var(--pixel, monospace);
}

.bbs-form label {
  font-size: 7px;
  display: grid;
  grid-template-columns: 58px minmax(0,1fr);
  align-items: start;
  gap: 6px;
  margin-bottom: 5px;
  color: #745c68;
  font: 7px/1.4 var(--pixel, monospace);
}

.friend-pages {
  min-height: 14px;
}

.friend-pages[hidden] {
  display: none;
}

.friend-pages button {
  padding: 0 2px;
  border: 0;
  background: transparent;
  color: #765667;
  font: inherit;
  cursor: pointer;
}

.friend-pages button:hover:not(:disabled) {
  color: #aa6f8a;
  text-decoration: underline;
}

.friend-pages button.is-current,
.friend-pages button.is-current:disabled {
  color: #4f3944;
  font-weight: 700;
  text-decoration: none;
  opacity: 1;
  cursor: default;
}

.friend-garden b {
  font: 10px var(--serif);
}

.friend-garden small {
  color: #907481;
  font-size: 7px;
}

.site-badge {
  display: grid;
  grid-row: 1 / 3;
  place-items: center;
  width: 100px;
  height: 31px;
  border: 2px outset #8e697b;
  background: var(--rei-blush-highlight);
  font: 7px var(--pixel);
}

.site-badge.pink {
  background: #e9bcd0;
}

.site-badge.dark {
  color: #fae5ed;
  background: #40323a;
}

.friend-cage {
  position: absolute;
  right: 19px;
  bottom: 15px;
  width: 74px;
  opacity: .6;
}

.copy-status {
  margin-left: 6px;
  color: #805c6f;
  font-size: 7px;
}

.goodbye-inner {
  padding-top: 46px;
  text-align: center;
}

.goodbye-cross {
  width: 70px;
  height: 100px;
  object-fit: contain;
}

.goodbye-copy {
  width: 78%;
  margin: 15px auto;
  padding: 12px;
  border-top: 2px double #a98295;
  border-bottom: 2px double #a98295;
  background: rgba(255, 253, 251, .82);
  font: 10px/1.7 var(--serif);
}

.goodbye-copy p {
  margin: 0;
}

.goodbye-copy blockquote {
  margin: 8px 0 0;
  color: #825b71;
  font-style: italic;
}

.rei-sleep-gif {
  right: 18px;
  bottom: 12px;
  width: 95px;
  max-height: 100px;
}

.back-cover-page {
  border: 2px solid #4a3741;
  outline: 4px double #f5d5e2;
  background: #e6c3d2;
}

.back-cover-inner {
  display: grid;
  place-items: center;
  text-align: center;
  background-color: #e9c8d6;
  background-image: linear-gradient(rgba(255, 246, 249, .28), rgba(255, 246, 249, .12)),
    url("assets/materials/pink/pattern_tile_01_05.svg"),
    repeating-linear-gradient(90deg, rgba(47, 35, 42, .1) 0 38px, rgba(242, 192, 213, .3) 38px 88px, rgba(255, 255, 255, .08) 88px 128px);
  background-repeat: repeat;
  background-size: auto, 156px 156px, 100% 100%;
}

.back-cover-inner::before {
  content: "";
  position: absolute;
  inset: 22px;
  border: 3px double #513b47;
  pointer-events: none;
}

.back-cover-stamp {
  padding: 8px 14px;
  transform: rotate(-2deg);
  border: 2px double var(--rei-muted-mauve);
  color: #4c3742;
  background: #fff2f7;
  font: 700 16px var(--gothic);
}

.back-cover-credit {
  display: grid;
  gap: 5px;
  width: min(330px, 82%);
  margin: 30px auto 0;
  padding: 10px 14px;
  color: #f8e9ef;
  border: 1px solid rgba(248, 233, 239, .72);
  outline: 1px solid rgba(248, 233, 239, .28);
  outline-offset: 3px;
  background: rgba(23, 16, 20, .46);
  text-align: center;
  letter-spacing: .04em;
}

.back-cover-credit strong {
  color: #f1bfd3;
  font-weight: 700;
}

.back-rose {
  position: absolute;
  bottom: 35px;
  left: 30px;
  width: 90px;
  opacity: .7;
}

.back-rei {
  position: absolute;
  right: 25px;
  bottom: 30px;
  width: 110px;
  max-height: 115px;
  object-fit: contain;
}

.back-cover-inner p {
  position: absolute;
  bottom: 70px;
  font: 8px var(--serif);
}

.back-cover-inner small {
  position: absolute;
  bottom: 48px;
  color: #806b76;
  font-size: 6px;
}

.book-controls {
  display: grid;
  grid-template-columns: 155px 1fr 155px;
  align-items: center;
  gap: 10px;
  width: min(var(--book-w), 100%);
  margin: 0 auto;
  padding: 7px 14px;
  border-top: 1px dotted #aa8295;
  background: rgba(255, 250, 250, .84);
}

.book-controls button {
  padding: 7px 10px;
  border: 2px outset #9e7488;
  background: #fff1f6;
  font-size: 8px;
}

.book-controls button:disabled,
.responsive-controls button:disabled {
  opacity: .34;
}

.book-controls div {
  text-align: center;
}

.book-controls span {
  display: block;
  font: 8px var(--pixel);
  letter-spacing: .1em;
}

.book-controls small {
  color: #907783;
  font-size: 6px;
}

.chapter-tabs {
  position: absolute;
  top: 48px;
  right: -94px;
  z-index: 300;
  display: grid;
  gap: 3px;
  overflow: visible;
}

.chapter-tabs button {
  position: relative;
  width: 120px;
  height: 30px;
  padding: 0 19px 0 26px;
  overflow: visible;
  border: 2px double #21191d;
  border-left: 5px solid #21191d;
  border-radius: 0;
  clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 50%, calc(100% - 14px) 100%, 0 100%);
  color: #fff4f8;
  background-color: #34282f;
  background-image: linear-gradient(rgba(47, 35, 42, .78), rgba(47, 35, 42, .78)),
    url("assets/materials/black/pattern_tile_04_01.svg");
  background-size: auto, 40px 29px;
  box-shadow: 4px 3px #dda8be, inset 0 0 0 2px rgba(255, 255, 255, .13);
  font-size: 7px;
  text-align: left;
  filter: drop-shadow(1px 1px rgba(255, 255, 255, .65));
  transition: transform .16s steps(2, end), filter .16s;
}

.chapter-tabs button::before {
  content: "✞";
  position: absolute;
  top: 50%;
  left: 8px;
  color: #efbad0;
  font-size: 11px;
  text-shadow: 1px 1px #1d1519;
  transform: translateY(-53%);
}

.chapter-tabs button::after {
  content: "";
  position: absolute;
  top: 3px;
  bottom: 3px;
  left: 19px;
  border-left: 1px dotted rgba(255, 244, 248, .45);
}

.chapter-tabs button:nth-child(even) {
  border-color: #3c2d35;
  color: #34272e;
  background-color: #efc6d7;
  background-image: linear-gradient(rgba(246, 216, 228, .83), rgba(246, 216, 228, .83)),
    url("assets/materials/black/pattern_tile_01_01.svg");
  box-shadow: 4px 3px #34282f, inset 0 0 0 2px rgba(255, 255, 255, .55);
}

.chapter-tabs button:nth-child(even)::before {
  color: #4e3743;
  text-shadow: none;
}

.chapter-tabs button:nth-child(3n + 1) {
  transform: rotate(.35deg);
}

.chapter-tabs button:nth-child(3n + 2) {
  transform: rotate(-.45deg);
}

.chapter-tabs button:hover,
.chapter-tabs button.active {
  z-index: 4;
  transform: translateX(13px);
  filter: brightness(1.1) drop-shadow(2px 2px #382a31);
}

.chapter-tabs span {
  position: relative;
  z-index: 2;
  font-weight: 700;
  font-family: var(--serif);
  letter-spacing: .04em;
  white-space: nowrap;
}

.reader-frame.book-closed .chapter-tabs,
.reader-frame.book-closed .book-controls {
  display: none;
}

body.notebook-closed .site-shell {
  padding-top: 118px;
}

.site-footer {
  width: min(820px, 92vw);
  margin: 15px auto 0;
  color: #806a76;
  text-align: center;
}

.site-footer img {
  width: 100%;
  height: 27px;
  object-fit: fill;
  opacity: .55;
}

.site-footer p {
  margin: 2px 0;
  font-size: 6.5px;
  letter-spacing: .12em;
}

@keyframes twinkle {
  50% {
    opacity: .25;
    transform: scale(.88);
  }
}

@keyframes responsiveTurnNext {
  0% {
    transform: perspective(1000px) rotateY(0);
    opacity: 1;
  }
  45% {
    transform: perspective(1000px) rotateY(-12deg) translateX(-10px);
    opacity: .55;
  }
  100% {
    transform: perspective(1000px) rotateY(0);
    opacity: 1;
  }
}

@keyframes responsiveTurnPrev {
  0% {
    transform: perspective(1000px) rotateY(0);
    opacity: 1;
  }
  45% {
    transform: perspective(1000px) rotateY(12deg) translateX(10px);
    opacity: .55;
  }
  100% {
    transform: perspective(1000px) rotateY(0);
    opacity: 1;
  }
}

.page.rei-responsive-active.turn-forward {
  animation: responsiveTurnNext .48s ease;
}

.page.rei-responsive-active.turn-back {
  animation: responsiveTurnPrev .48s ease;
}

@media (max-width: 1120px) and (min-width: 821px) {
  :root {
    --book-w: 900px;
    --book-h: 590px;
    --page-w: 450px;
    --page-h: 590px;
  }
  .reader-frame {
    width: min(1035px, calc(100vw - 28px));
    padding-right: 47px;
    padding-left: 47px;
  }
  .reader-frame.book-closed {
    width: min(720px, calc(100vw - 28px));
  }
  .book-scene {
    height: 624px;
  }
  .page-inner {
    padding: 31px 28px 25px;
  }
  .chapter-tabs {
    right: -87px;
  }
  .chapter-tabs button {
    width: 111px;
    height: 28px;
  }
}

@media (max-width: 820px) {
  .memory-reader {
    padding: 12px;
  }
  .memory-vellum {
    width: calc(100vw - 18px);
    max-height: calc(100vh - 20px);
    padding: 24px 20px 50px;
    border-width: 4px;
    outline-offset: -8px;
    min-height: min(520px, calc(100vh - 20px));
    padding-bottom: 8px;
  }
  .memory-vellum-header {
    grid-template-columns: 39px 1fr 31px;
    gap: 8px;
    padding-top: 4px;
  }
  .memory-vellum-header img {
    width: 35px;
    height: 35px;
  }
  .memory-vellum-header h2 {
    font-size: 19px;
  }
  .memory-vellum-header button {
    width: 29px;
    height: 29px;
  }
  .memory-vellum-body {
    padding: 14px;
    font-size: 13px;
    line-height: 1.8;
  }
  .memory-vellum-media {
    grid-template-columns: 1fr;
  }
  .memory-vellum footer {
    display: grid;
  }
  body {
    background-size: auto;
  }
  body::after {
    inset: 4px;
    border-width: 2px;
  }
  .ceiling {
    height: 60px;
  }
  .ceiling-lace-band {
    height: 43px;
    background-size: auto 40px;
  }
  .ceiling-chain-band {
    top: 31px;
    height: 29px;
    background-size: auto 27px;
  }
  .site-shell,
body.notebook-closed .site-shell {
    width: 100%;
    padding: 67px 5px 22px;
  }
  .reader-frame,
.reader-frame.book-closed {
    width: calc(100vw - 12px);
    padding: 12px 5px 12px;
    border-width: 1px;
    outline-width: 2px;
  }
  .desktop-tabs {
    display: none;
  }
  .page.rei-responsive-active > .page-inner {
    padding: 24px 20px 26px;
    background-attachment: initial;
  }
  .page.rei-responsive-active h2 {
    margin-bottom: 11px;
    font-size: 19px;
  }
  .page.rei-responsive-active .cover-inner {
    min-height: 690px !important;
    padding: 21px 15px;
  }
  .page.rei-responsive-active .cover-copy {
    width: min(286px, 78vw);
    margin-top: 74px;
    padding: 14px 8px 12px;
  }
  .page.rei-responsive-active .cover-copy strong {
    font-size: 23px;
  }
  .page.rei-responsive-active .cover-reliquary {
    top: 72px;
    width: 72px;
    height: 104px;
  }
  .page.rei-responsive-active .cover-reliquary::before {
    right: 67px;
    width: 38px;
  }
  .page.rei-responsive-active .cover-reliquary::after {
    left: 67px;
    width: 38px;
  }
  .page.rei-responsive-active .cover-reliquary img {
    width: 48px;
    height: 78px;
  }
  .page.rei-responsive-active .visitor-counter {
    bottom: 78px;
  }
  .page.rei-responsive-active .cover-inner > .web-button {
    bottom: 44px;
  }
  .page.rei-responsive-active .cover-note {
    bottom: 17px;
  }
  .page.rei-responsive-active .commission-inner,
.page.rei-responsive-active .goodbye-inner {
    min-height: 650px !important;
  }
  .portrait-collage {
    grid-template-columns: 1fr 122px;
  }
  .rei-frame {
    height: 192px;
  }
  .rei-frame > img:first-child {
    width: 124px;
    height: 188px;
  }
  .rei-avatar {
    width: 86px;
  }
  .page-material-sticker {
    opacity: .3;
  }
  .ai-log {
    height: 185px;
  }
}

@media (max-width: 430px) {
  .page.rei-responsive-active > .page-inner {
    padding: 21px 16px 24px;
  }
  .page.rei-responsive-active .cover-inner {
    min-height: 650px !important;
  }
  .page.rei-responsive-active .commission-inner,
.page.rei-responsive-active .goodbye-inner {
    min-height: 620px !important;
  }
  .page.rei-responsive-active .cover-copy {
    width: min(264px, 76vw);
  }
  .page.rei-responsive-active .cover-copy strong {
    font-size: 21px;
  }
  .portrait-collage {
    grid-template-columns: 1fr 94px;
    gap: 7px;
  }
  .portrait-copy {
    padding: 8px;
    font-size: 8px;
  }
  .rei-frame {
    height: 154px;
  }
  .rei-frame > img:first-child {
    width: 96px;
    height: 151px;
  }
  .rei-avatar {
    width: 70px;
  }
  .journal-index {
    gap: 4px;
  }
  .journal-index button {
    min-height: 26px;
    padding: 4px;
  }
  .goodbye-inner {
    padding-top: 34px;
  }
}

@media (max-width: 820px) {
  .archive-overlay {
    padding: 7px;
  }
  .archive-vault {
    width: calc(100vw - 12px);
    height: calc(100vh - 14px);
    border-width: 4px;
    outline-offset: -8px;
  }
  .archive-vault-header {
    grid-template-columns: 38px 1fr 32px;
    min-height: 70px;
    padding: 12px 14px 9px;
  }
  .archive-sigil {
    width: 34px;
    height: 34px;
    font-size: 19px;
  }
  .archive-vault-header h2 {
    font-size: 18px;
  }
  .archive-vault-header > button {
    width: 30px;
    height: 30px;
  }
  .archive-vault-layout {
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr;
    height: calc(100% - 70px);
  }
  .archive-category-nav {
    display: flex;
    gap: 5px;
    padding: 9px 10px;
    overflow-x: auto;
    border-right: 0;
    border-bottom: 3px double #8f6c7b;
  }
  .archive-category-nav button {
    width: auto;
    min-width: 138px;
    margin: 0;
    padding: 8px;
  }
  .archive-gallery-pane {
    padding: 14px 13px 20px;
  }
  .archive-gallery-pane h3 {
    font-size: 19px;
  }
  .relic-gallery {
    grid-template-columns: repeat(2,minmax(0,1fr));
    gap: 8px;
  }
  .relic-detail {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 42px 16px 20px;
  }
  .relic-detail-photos img {
    max-height: 45vh;
  }
  .relic-detail > div:last-child {
    padding: 17px;
  }
  .reliquary-vault-body {
    height: calc(100% - 70px);
    padding: 10px 11px 16px;
  }
  .asset-gallery {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }
  .asset-card img {
    height: 90px;
  }
  .page.rei-responsive-active .master-facts section {
    display: block;
    min-height: 43px;
    text-align: center;
  }
  .page.rei-responsive-active .master-facts span {
    display: grid;
    height: 18px;
    border-right: 0;
    border-bottom: 1px dotted #ba8da2;
  }
  .page.rei-responsive-active .master-facts b {
    display: block;
    padding: 5px 2px 0;
    font-size: 7.6px;
    white-space: nowrap;
  }
  .page.rei-responsive-active .rei-about-inner {
    padding: 21px 18px 22px;
  }
  .page.rei-responsive-active .rei-about-inner .portrait-collage {
    grid-template-columns: 1fr 74px;
    min-height: 86px;
    padding: 5px 7px;
  }
  .page.rei-responsive-active .rei-about-inner .portrait-copy {
    padding: 4px 2px;
    font-size: 8px;
  }
  .page.rei-responsive-active .rei-about-inner .mini-profile {
    gap: 3px;
  }
  .page.rei-responsive-active .rei-about-inner .mini-profile div {
    padding: 3px;
  }
  .page.rei-responsive-active .rei-about-inner .mini-profile dt {
    font-size: 5.5px;
  }
  .page.rei-responsive-active .rei-about-inner .mini-profile dd {
    font-size: 6.3px;
  }
  .page.rei-responsive-active .rei-about-inner .rei-frame {
    height: 74px;
  }
  .page.rei-responsive-active .rei-about-inner .rei-frame > img:first-child {
    width: 65px;
    height: 72px;
  }
  .page.rei-responsive-active .rei-about-inner .rei-avatar {
    width: 47px;
    max-height: 59px;
  }
  .page.rei-responsive-active .rei-biography {
    column-count: 1;
    margin-top: 7px;
    padding: 8px 10px 6px;
    font-size: 9.2px;
    line-height: 1.5;
  }
  .page.rei-responsive-active .rei-biography p {
    margin-bottom: 3px;
  }
  .page.rei-responsive-active .rei-question {
    margin: 4px 0 5px;
    padding: 4px 6px;
  }
  .page.rei-responsive-active .rei-about-inner .rei-quote {
    margin-top: 6px;
    font-size: 8px;
  }
  .page.rei-responsive-active .library-intro {
    width: 100%;
    font-size: 7px;
  }
  .page.rei-responsive-active .library-shelf {
    gap: 5px;
  }
  .page.rei-responsive-active .library-slip {
    grid-template-columns: 47px minmax(0, 1fr) 55px;
    min-height: 54px;
    padding: 6px 7px 6px 11px;
  }
  .page.rei-responsive-active .library-slip strong {
    font-size: 8.7px;
  }
  .library-reader {
    padding: 0;
  }
  .library-vault {
    grid-template-rows: 64px minmax(0, 1fr);
    width: 100vw;
    height: 100dvh;
    max-height: none;
    border-width: 0;
    outline: 0;
  }
  .library-vault::before {
    top: 59px;
  }
  .library-vault-header {
    grid-template-columns: 39px 1fr 36px;
    gap: 8px;
    padding: 7px 10px;
  }
  .library-sigil {
    width: 35px;
    height: 35px;
    font-size: 20px;
  }
  .library-vault-header p {
    font-size: 6px;
  }
  .library-vault-header h2 {
    font-size: 19px;
  }
  .library-close {
    width: 32px;
    height: 32px;
    font-size: 22px;
  }
  .library-vault-layout {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    grid-template-columns: 1fr;
  }
  .library-record-nav {
    padding: 21px 10px 8px;
    overflow-x: auto;
    overflow-y: hidden;
    border-right: 0;
    border-bottom: 3px double #5d4451;
  }
  .library-nav-label {
    display: none;
  }
  #libraryRecordList {
    display: flex;
    gap: 7px;
    width: max-content;
  }
  .library-record-button {
    grid-template-columns: 24px 1fr;
    width: 188px;
    min-height: 54px;
    margin: 0;
    padding: 6px;
  }
  .library-record-button::before {
    font-size: 15px;
  }
  .library-record-button strong {
    font-size: 8.5px;
  }
  .library-record-button small {
    font-size: 6px;
  }
  .library-document {
    padding: 32px 18px 44px;
  }
  .library-document-header {
    margin-bottom: 19px;
  }
  .library-document-header h3 {
    font-size: clamp(20px, 6vw, 27px);
  }
  .library-content {
    font-size: 14px;
    line-height: 1.82;
  }
  .library-content h2 {
    font-size: 20px;
  }
  .library-content h3 {
    font-size: 18px;
  }
  .library-content pre {
    font-size: 10.5px;
  }
  .library-document-footer {
    grid-template-columns: 1fr 1fr;
    margin-top: 38px;
  }
  .library-document-footer span {
    grid-column: 1 / 3;
    grid-row: 1;
  }
  .page.rei-responsive-active .module-title-line {
    margin-bottom: 10px;
  }
  .page.rei-responsive-active .module-title-line h2 {
    margin-bottom: 0;
  }
  .page.rei-responsive-active .cabinet-door-grid button {
    min-height: 118px;
  }
  .page.rei-responsive-active .reliquary-door-grid button {
    min-height: 80px;
  }
}

@media (max-width: 430px) {
  .page.rei-responsive-active .cabinet-door-grid {
    gap: 7px;
  }
  .page.rei-responsive-active .cabinet-door-grid button {
    min-height: 108px;
    padding: 11px 8px 10px 31px;
  }
  .page.rei-responsive-active .cabinet-door-grid strong {
    font-size: 10px;
  }
  .page.rei-responsive-active .reliquary-door-grid button {
    grid-template-columns: 40px 1fr;
    min-height: 72px;
  }
  .page.rei-responsive-active .reliquary-door-grid img {
    width: 36px;
    height: 42px;
  }
}

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

.page-inner[data-page-theme] {
  background-color: #fff9f7;
  background-image: var(--paper-wash), var(--paper-motif), var(--paper-blocks);
  background-repeat: repeat, repeat, repeat;
  background-size: auto, var(--motif-size), 100% 100%;
  background-position: 0 0;
}

.page-inner[data-page-theme="rose-grid"] {
  --paper-wash: linear-gradient(rgba(255, 250, 250, .74), rgba(255, 250, 250, .74));
  --paper-motif: url("assets/materials/pink/pattern_tile_01_01.svg");
  --motif-size: 104px 104px;
  --paper-blocks: repeating-linear-gradient(90deg, rgba(230,161,191,.34) 0 52px, rgba(255,255,255,.12) 52px 91px, rgba(54,40,47,.12) 91px 100px, rgba(247,216,228,.28) 100px 151px);
}

.page-inner[data-page-theme="black-cross"] {
  --paper-wash: linear-gradient(rgba(255, 251, 249, .82), rgba(255, 251, 249, .82));
  --paper-motif: url("assets/materials/black/pattern_tile_04_01.svg");
  --motif-size: 132px 132px;
  --paper-blocks: repeating-linear-gradient(0deg, rgba(49,37,44,.15) 0 34px, rgba(242,207,220,.27) 34px 82px, rgba(255,255,255,.12) 82px 116px, rgba(65,49,58,.1) 116px 127px);
}

.page-inner[data-page-theme="ribbon-stripe"] {
  --paper-wash: linear-gradient(rgba(255, 251, 249, .76), rgba(255, 251, 249, .76));
  --paper-motif: url("assets/materials/black/pattern_tile_02_01.svg");
  --motif-size: 126px 126px;
  --paper-blocks: repeating-linear-gradient(90deg, rgba(43,32,38,.18) 0 30px, rgba(232,169,195,.34) 30px 72px, rgba(255,255,255,.1) 72px 105px, rgba(48,36,43,.14) 105px 114px, rgba(244,211,224,.3) 114px 157px);
}

.page-inner[data-page-theme="pale-checker"] {
  --paper-wash: linear-gradient(rgba(255, 252, 250, .8), rgba(255, 252, 250, .8));
  --paper-motif: url("assets/journal/09_bottom_tiles/bottom_01_checkers.png");
  --motif-size: 76px 76px;
  --paper-blocks: repeating-linear-gradient(0deg, rgba(235,179,202,.26) 0 46px, rgba(255,255,255,.1) 46px 83px, rgba(53,40,47,.11) 83px 92px, rgba(242,215,225,.27) 92px 138px);
}

.material-license {
  position: relative;
  z-index: 5;
  display: grid;
  gap: 8px;
  width: 100%;
  margin-top: 12px;
}

.material-license-divider,
.material-license-content {
  position: relative;
  z-index: 11;
  width: 100%;
  max-width: 100%;
  margin: 0;
  color: #604b56;
}

.material-license-divider {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  justify-self: center;
  gap: 7px;
  min-height: 15px;
  color: #7c5365;
  text-align: center;
}

.material-license-divider::before,
.material-license-divider::after {
  content: "";
  height: 1px;
  background: linear-gradient(90deg, transparent, currentColor);
}

.material-license-divider::after {
  background: linear-gradient(90deg, currentColor, transparent);
}

.material-license-divider span {
  font-size: 12px;
}

.material-license-content {
  justify-self: start;
  padding: 8px 10px;
  border: 1px solid rgba(134,105,116,.32);
  background: rgba(255,251,245,.82);
  box-shadow: 2px 2px rgba(75,52,63,.1);
  text-align: left;
}

.material-license-content p {
  margin: 0;
  white-space: pre-line;
  font-size: 9px;
  line-height: 1.65;
}

.rei-decoration-layer {
  position: absolute;
  z-index: 6;
  inset: 0;
  pointer-events: none;
  overflow: visible;
}


.book .page,
.book .page :where(*),
.page.rei-responsive-active,
.page.rei-responsive-active :where(*) {
  font-family: var(--notebook-hand) !important;
  -webkit-text-stroke: 0.12px currentColor;
}

.book .page h1,
.book .page h2,
.page.rei-responsive-active h1,
.page.rei-responsive-active h2,
.cover-copy strong {
  font-family: var(--gothic-title) !important;
}

.book .page h1,
.book .page h2,
.page.rei-responsive-active h1,
.page.rei-responsive-active h2,
.cover-copy strong,
.library-document-header h3 {
  -webkit-text-stroke: 0;
}

.rei-decoration-item {
  position: absolute;
  display: block;
  transform-origin: center;
  pointer-events: none;
}

.rei-decoration-item > img {
  position: static;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  max-width: none;
  max-height: none;
  filter: drop-shadow(1px 2px 1px rgba(45,31,38,.18));
  transform-origin: center;
  user-select: none;
  -webkit-user-drag: none;
}

.archive-index-pager {
  display: grid;
  grid-template-columns: 34px 1fr 34px;
  align-items: center;
  gap: 7px;
  width: min(210px, 76%);
  margin: 8px auto 0;
  padding: 3px 5px;
  border-top: 1px dotted rgba(104,72,88,.45);
  border-bottom: 1px dotted rgba(104,72,88,.45);
  text-align: center;
}

.archive-index-pager button {
  min-height: 24px;
  border: 1px outset #c9a5b6;
  background: #f4dce7;
  color: #493641;
  cursor: pointer;
  font: 12px var(--serif);
}

.archive-index-pager button:disabled {
  opacity: .35;
  cursor: default;
}

.archive-index-pager span {
  color: #765568;
  font: 6px var(--pixel);
  letter-spacing: .12em;
}

.archive-index-empty {
  grid-column: 1 / -1;
  margin: 8px 0;
  padding: 24px 14px;
  border: 1px dashed #b88da1;
  background: rgba(255,249,251,.7);
  color: #705565;
  text-align: center;
  font: 9px/1.6 var(--serif);
}

.cabinet-door-grid button,
.reliquary-door-grid button {
  min-width: 0;
}

.cabinet-door-grid strong,
.reliquary-door-grid span {
  overflow-wrap: anywhere;
}

@media (max-width: 760px) {
  .archive-index-pager {
    width: min(190px, 82%);
    margin-top: 7px;
  }
}

.cabinet-door-grid .cabinet-index-cover {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .16;
  filter: grayscale(.65) contrast(.9);
  pointer-events: none;
}

.cabinet-door-grid button.has-cover::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(90deg,rgba(35,25,31,.88),rgba(45,31,39,.68));
  pointer-events: none;
}

.cabinet-door-grid button.has-cover i,
.cabinet-door-grid button.has-cover strong,
.cabinet-door-grid button.has-cover span,
.cabinet-door-grid button.has-cover small {
  position: relative;
  z-index: 1;
}

.memory-diary-index-v2,
.memory-diary-day-v2 {
  isolation: isolate;
}

.memory-diary-heading,
.memory-day-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.memory-diary-heading > b {
  flex: 0 0 auto;
  margin-top: 5px;
  padding: 4px 6px 3px;
  border: 1px solid #9b7487;
  box-shadow: 2px 2px 0 rgba(89, 57, 72, .16);
  color: #5f4250;
  background: rgba(255, 242, 247, .86);
  font: 5.5px var(--pixel);
  letter-spacing: .04em;
}

.memory-diary-index-v2 .memory-index-subtitle {
  display: block;
  margin-top: -7px;
}

.memory-diary-index-v2 .memory-index-subtitle span {
  display: block;
  margin-top: 2px;
}

.memory-source-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  margin: 2px 0 7px;
}

.memory-source-summary span {
  min-width: 0;
  padding: 5px 6px 4px;
  border: 1px solid rgba(118, 80, 98, .28);
  background: rgba(255, 248, 250, .76);
}

.memory-source-summary i,
.memory-source-summary b {
  display: block;
  font-style: normal;
}

.memory-source-summary i {
  overflow: hidden;
  color: #8b6b7a;
  font: 5px var(--pixel);
  letter-spacing: .05em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.memory-source-summary b {
  margin-top: 2px;
  color: #4f3843;
  font: 8px var(--pixel);
}

.memory-diary-index-v2 .year-tabs {
  flex-wrap: nowrap;
  overflow-x: auto;
  padding-bottom: 3px;
  scrollbar-width: thin;
}

.memory-diary-index-v2 .year-tabs button {
  min-width: 43px;
  padding: 3px 4px 2px;
}

.memory-diary-index-v2 .year-tabs button span,
.memory-diary-index-v2 .year-tabs button small {
  display: block;
}

.memory-diary-index-v2 .year-tabs button small {
  margin-top: 1px;
  color: #9f7187;
  font-size: 4.5px;
}

.memory-diary-index-v2 .year-tabs button.is-active small {
  color: #624352;
}

.memory-diary-index-v2 .mini-calendar {
  position: relative;
  box-shadow: 3px 3px 0 rgba(83, 56, 68, .08);
}

.memory-diary-index-v2 .days > * {
  position: relative;
  min-height: 33px;
}

.memory-diary-index-v2 .days button.has-memory {
  background-image: linear-gradient(145deg, rgba(255,255,255,.58), rgba(239,207,220,.42));
}

.memory-diary-index-v2 .days small {
  position: absolute;
  right: 3px;
  bottom: 3px;
  min-width: 13px;
  padding: 1px 2px;
  border: 1px solid rgba(166, 101, 131, .35);
  color: #8d506d;
  background: rgba(255, 241, 247, .9);
  font-size: 5px;
  line-height: 1.1;
  text-align: center;
}

.memory-month-ledger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 6px;
  padding: 5px 7px;
  border-top: 1px dotted #caa8b8;
  border-bottom: 1px dotted #caa8b8;
  background: rgba(255, 247, 250, .54);
}

.memory-month-ledger span,
.memory-month-ledger b {
  font: 5.5px var(--pixel);
}

.memory-month-ledger span {
  color: #9a7385;
}

.memory-month-ledger b {
  color: #5c4250;
  text-align: right;
}

.memory-diary-index-v2 .diary-source-legend em {
  margin-left: auto;
  color: #99818c;
  font: 5px var(--pixel);
  font-style: normal;
}

.memory-day-heading {
  align-items: center;
  margin-bottom: 5px;
}

.memory-day-heading h2 {
  margin-bottom: 1px;
}

.memory-day-heading p {
  margin: 0;
  color: #8c6d7b;
  font: 5.5px var(--pixel);
  letter-spacing: .04em;
}

.memory-day-heading > span {
  max-width: 98px;
  padding: 4px 6px;
  border: 1px solid #7a5667;
  transform: rotate(1.5deg);
  color: #5d3f4d;
  background: rgba(248, 223, 233, .62);
  font: 5px var(--pixel);
  text-align: center;
}

.memory-card-v2 {
  padding: 7px 8px 8px 9px;
  border-left-width: 3px;
  box-shadow: 2px 2px 0 rgba(84, 57, 69, .06);
}

.memory-card-v2::before {
  display: none;
}

.memory-card-v2[data-memory-record] {
  padding-right: 24px;
}

.memory-card-head {
  display: flex;
  align-items: center;
  gap: 5px;
  padding-bottom: 4px;
  border-bottom: 1px dotted rgba(132, 91, 111, .26);
}

.memory-card-head .memory-source-stamp {
  padding: 2px 4px;
  border: 1px solid currentColor;
  color: #704b5d;
  background: rgba(255, 235, 244, .72);
  font: 5px var(--pixel);
  letter-spacing: .03em;
}

.memory-card-head time {
  color: #654b58;
  font: 6px var(--pixel);
}

.memory-card-head i {
  color: #9b7285;
  font: 5px var(--pixel);
  font-style: normal;
}

.memory-card-head small {
  margin-left: auto;
  color: #a38995;
  font: 4.5px var(--pixel);
}

.memory-card-text {
  margin: 6px 0 3px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.memory-card-v2.source-x-archive {
  border-left-color: #7b5969;
}

.memory-card-v2.source-x-sync {
  border-left-color: #b07992;
}

.memory-card-v2.source-direct {
  border-left-color: #c899ad;
}

.memory-card-v2.source-rei {
  border-left-color: #d18caf;
}

.memory-card-v2.is-reply {
  border-left-style: double;
}

.memory-card-v2.is-retweet {
  opacity: .91;
}

.memory-relations {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 8px 0;
}

.memory-relations.compact {
  margin: 4px 0 2px;
}

.memory-relations span {
  padding: 2px 4px;
  border: 1px dotted #b68ca0;
  color: #805f6f;
  background: rgba(255, 245, 249, .74);
  font: 4.8px var(--pixel);
}

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

.memory-media-preview.count-1 {
  grid-template-columns: minmax(0, 1fr);
}

.memory-media-preview.count-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.memory-media-preview.count-3 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.memory-media-preview img,
.memory-video-tile {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #957083;
  background: #ead6df;
}

.memory-media-preview img {
  display: block;
  height: auto;
  max-height: 190px;
  object-fit: contain;
}

.memory-media-preview.count-2 img,
.memory-media-preview.count-3 img,
.memory-media-preview.count-4 img {
  max-height: 145px;
}

.memory-video-tile {
  display: grid;
  min-height: 64px;
  max-height: 145px;
  place-items: center;
  color: #684a58;
  background-image: repeating-linear-gradient(135deg, rgba(255,255,255,.55) 0 5px, rgba(224,194,207,.55) 5px 10px);
  font: 5px var(--pixel);
}

.memory-card-v2 .diary-entry-media {
  justify-content: flex-end;
  margin-top: 3px;
  font: 4.8px var(--pixel);
}

.memory-record-relations[hidden],
.memory-record-provenance[hidden] {
  display: none;
}

.memory-record-relations {
  margin: 11px 0 2px;
  padding-top: 7px;
  border-top: 1px dotted #c4a1b1;
}

.memory-record-provenance {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
  margin: 13px 0 4px;
  padding: 9px;
  border: 1px solid rgba(104, 73, 87, .24);
  background: rgba(255, 247, 242, .72);
}

.memory-record-provenance div {
  min-width: 0;
}

.memory-record-provenance b,
.memory-record-provenance span {
  display: block;
}

.memory-record-provenance b {
  color: #9a7083;
  font: 5px var(--pixel);
}

.memory-record-provenance span {
  margin-top: 2px;
  overflow-wrap: anywhere;
  color: #513c46;
  font: 7px/1.35 var(--serif);
}

.memory-vellum-media {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.memory-vellum-media[hidden] {
  display: none;
}

.memory-vellum-media img,
.memory-vellum-media video {
  display: block;
  width: 100%;
  max-height: 420px;
  object-fit: contain;
  border: 1px solid #8a6677;
  background: rgba(238, 218, 225, .58);
}

@media (max-width: 720px) {
  .memory-source-summary {
    grid-template-columns: repeat(3, minmax(0,1fr));
  }
  .memory-diary-heading > b {
    font-size: 4.8px;
  }
  .memory-diary-index-v2 .days > * {
    min-height: 36px;
  }
  .memory-day-heading > span {
    max-width: 86px;
  }
  .memory-record-provenance {
    grid-template-columns: 1fr;
  }
  .memory-vellum-media {
    grid-template-columns: 1fr;
  }
  .memory-media-preview,
.memory-media-preview.count-2,
.memory-media-preview.count-3,
.memory-media-preview.count-4 {
    grid-template-columns: 1fr;
  }
  .memory-media-preview img {
    max-height: 260px;
  }
}

.memory-vellum-media audio,
.memory-vellum-media a {
  width: 100%;
  box-sizing: border-box;
}

.memory-vellum-media a {
  display: grid;
  min-height: 44px;
  place-items: center;
  border: 1px solid #8a6677;
  color: #5d4250;
  background: rgba(250, 231, 239, .7);
  font: 6px var(--pixel);
  text-decoration: none;
}

.memory-vellum::before {
  position: absolute;
  top: 6px;
  right: 28px;
  left: 28px;
}

.memory-vellum::after {
  position: static;
  right: auto;
  bottom: auto;
  left: auto;
  display: block;
  align-self: stretch;
  flex: 0 0 31px;
  width: auto;
  height: 31px;
  margin-top: auto;
  background-position: center top;
  background-size: auto 15px;
  transform: scaleY(-1);
  z-index: auto;
}

@media (max-width: 820px) {
  .memory-vellum::before {
    right: 18px;
    left: 18px;
  }
}

html,
body {
  cursor: url("/assets/cursors/rei-bow-cursor.svg") 12 10, auto !important;
}

a,
button,
[role="button"],
summary,
label[for],
select,
input[type="button"],
input[type="submit"],
input[type="reset"],
input[type="checkbox"],
input[type="radio"],
input[type="file"] {
  cursor: url("/assets/cursors/rei-bow-cursor.svg") 12 10, pointer !important;
}

input:not([type]),
input[type="text"],
input[type="search"],
input[type="email"],
input[type="url"],
input[type="tel"],
input[type="password"],
input[type="number"],
input[type="date"],
input[type="datetime-local"],
input[type="time"],
textarea {
  cursor: text !important;
}

button:disabled,
[aria-disabled="true"] {
  cursor: not-allowed !important;
}

.badge-sanctum-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-top: 1px dotted #a97f92;
  border-bottom: 1px dotted #a97f92;
  color: #6f5260;
  background: rgba(255,249,249,.62);
  font: 6px var(--pixel);
  margin: 5px 0 4px;
  padding: 3px 5px;
  opacity: .72;
}

.badge-sanctum-summary b {
  color: #3f3038;
  font-size: 7px;
}

.badge-sanctum-tabs {
  display: flex;
  padding: 0 0 7px;
  overflow-x: auto;
  scrollbar-width: thin;
  gap: 2px;
  min-height: 18px;
  padding-bottom: 4px;
  opacity: .66;
}

.badge-sanctum-tabs button {
  flex: 0 0 auto;
  border: 1px solid #a47b8e;
  color: #5f4451;
  font: 5.5px var(--pixel);
  cursor: pointer;
  min-height: 17px;
  padding: 2px 4px;
  border-color: rgba(164,123,142,.58);
  background: rgba(247,227,235,.48);
  font-size: 5px;
}

.badge-sanctum-tabs button.is-active {
  color: #fff2f7;
  box-shadow: inset 0 0 0 1px #d69bb4;
  background: #4a3740;
}

.badge-sanctum-item {
  justify-items: center;
  align-content: start;
  color: #4e3a44;
  cursor: default;
  transform-origin: 50% 50%;
  overflow: visible;
}

a.badge-sanctum-item {
  cursor: pointer;
}

.badge-wall-slot {
  place-items: center;
  display: block;
  width: 88px;
  height: 31px;
  overflow: hidden;
  background: transparent;
  box-shadow: 0 1px 1px rgba(67,43,54,.14);
}

.badge-wall-slot img {
  display: block;
  object-fit: contain;
  width: auto;
  height: auto;
  max-width: 88px;
  max-height: 31px;
  margin: auto;
}

.badge-sanctum-empty {
  grid-column: 1 / -1;
  align-self: center;
  margin: auto;
  color: #806676;
  font: 8px/1.7 var(--serif);
  text-align: center;
}

.badge-sanctum-footnote {
  margin: auto 0 0;
  color: #9b7b89;
  font: 5px/1.35 var(--pixel);
  text-align: center;
  letter-spacing: .04em;
}

@media (max-width: 760px) {
}

@media (max-width: 420px) {
  .badge-sanctum-wall,
.page.rei-responsive-active .badge-sanctum-wall {
    grid-template-columns: repeat(3,88px);
    justify-content: center;
    column-gap: 1px;
    row-gap: 2px;
  }
}

@media (max-width: 320px) {
  .badge-sanctum-wall,
.page.rei-responsive-active .badge-sanctum-wall {
    grid-template-columns: repeat(2,88px);
  }
}

.badge-sanctum-wall {
  min-height: 190px;
  border: 3px double #9b7386;
  background: linear-gradient(rgba(255,252,250,.91),rgba(255,252,250,.91)),
    repeating-linear-gradient(0deg,transparent 0 30px,rgba(191,143,165,.14) 30px 31px),
    repeating-linear-gradient(90deg,transparent 0 96px,rgba(191,143,165,.1) 96px 97px);
  box-shadow: inset 0 0 0 4px rgba(231,197,211,.28);
  grid-template-columns: repeat(auto-fit,88px);
  column-gap: 1px;
  row-gap: 1px;
}

.badge-sanctum-item:hover,
.badge-sanctum-item:focus-visible {
  z-index: 12;
  outline: none;
  background: transparent;
}

.badge-sanctum-item::after {
  content: attr(data-badge-info);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 4px);
  z-index: 20;
  width: max-content;
  max-width: 180px;
  padding: 4px 6px;
  border: 1px solid #9f7789;
  color: #4d3943;
  background: rgba(255,245,249,.96);
  box-shadow: 2px 2px 0 rgba(84,57,69,.14);
  font: 5.5px/1.45 var(--pixel);
  letter-spacing: .02em;
  white-space: normal;
  text-align: center;
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%,3px);
  transition: opacity .10s ease,transform .10s ease;
}

.badge-sanctum-item:hover::after,
.badge-sanctum-item:focus-visible::after {
  opacity: 1;
  transform: translate(-50%,0);
}

.badge-sanctum-tabs:hover,
.badge-sanctum-tabs:focus-within {
  opacity: 1;
}

@media (max-width: 760px) {
  .page.rei-responsive-active .badge-sanctum-wall {
    gap: 7px 3px;
    grid-template-columns: repeat(auto-fit,88px);
    justify-content: center;
    column-gap: 1px;
    row-gap: 1px;
    padding: 4px 2px;
  }
}

.badge-sanctum-wall,
.page.rei-responsive-active .badge-sanctum-wall {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  align-content: flex-start;
  justify-content: center;
  gap: 1px;
  padding: 4px 3px;
  max-height: clamp(190px, calc(100dvh - 220px), 480px);
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior-y: contain;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-y;
}

.badge-webring-widget {
  flex: 0 1 auto;
  max-width: 100%;
  min-width: 0;
  align-self: flex-start;
  box-sizing: border-box;
  padding: 3px 5px;
  color: #4e3a44;
  font: 9px/1.3 var(--serif);
  text-align: center;
  white-space: normal;
  overflow-wrap: anywhere;
  overflow-x: auto;
}

.badge-webring-widget iframe {
  display: block;
  max-width: none;
  margin: 0 auto;
  border: 0;
}

.badge-webring-widget img {
  max-width: 100%;
  height: auto;
  vertical-align: middle;
}

.badge-webring-widget a {
  cursor: pointer;
}

.badge-sanctum-item,
.badge-sanctum-item:nth-child(n) {
  position: relative;
  display: block;
  flex: 0 0 var(--badge-w,88px);
  width: var(--badge-w,88px);
  height: var(--badge-h,31px);
  min-width: 0;
  min-height: 0;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  line-height: 0;
  background: transparent;
  transform: none;
  translate: none;
  rotate: none;
  vertical-align: top;
}

.badge-sanctum-item .badge-wall-slot,
.badge-sanctum-item:nth-child(n) .badge-wall-slot {
  display: block;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  overflow: hidden;
  background: transparent;
  transform: none;
  translate: none;
  rotate: none;
  box-shadow: none;
  line-height: 0;
}

.badge-sanctum-item .badge-wall-slot img,
.badge-sanctum-item:nth-child(n) .badge-wall-slot img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  object-fit: contain;
  object-position: center;
  transform: none;
  translate: none;
  rotate: none;
  vertical-align: top;
}

.badge-sanctum-item.is-standard {
  --badge-w: 88px;
  --badge-h: 31px;
}

.badge-sanctum-item.is-blinkie {
  --badge-w: 150px;
  --badge-h: 20px;
}

.badge-sanctum-item.is-banner {
  --badge-w: 200px;
  --badge-h: 40px;
}

@media (hover:none) {
  .badge-sanctum-item::after {
    display: none !important;
  }
}

.bbs-statusline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 2px 0 6px;
  min-height: 14px;
  color: #8d7480;
  font: 6.5px/1.2 var(--pixel, monospace);
  letter-spacing: .04em;
}

.bbs-statusline b {
  color: #bb6f93;
  font-weight: 500;
  text-align: right;
}

.bbs-board {
  max-height: 330px;
  overflow: auto;
  border-top: 2px double #9c7589;
  border-bottom: 2px double #9c7589;
  background: repeating-linear-gradient(0deg, rgba(185,135,157,.035) 0 1px, transparent 1px 19px),
    rgba(255,253,251,.88);
  scrollbar-width: thin;
  scrollbar-color: #c997ad #fff7fa;
}

.bbs-board article {
  position: relative;
  padding: 7px 8px 8px;
  border-bottom: 1px dotted #ceb2bf;
}

.bbs-board article:last-child {
  border-bottom: 0;
}

.bbs-board article:hover {
  background: rgba(255,235,244,.42);
}

.bbs-board header span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.bbs-board p {
  margin: 4px 0 0;
  color: #4f3d46;
  font: 9px/1.55 var(--serif);
  overflow-wrap: anywhere;
  white-space: normal;
}

.bbs-quote-line {
  color: #a65f83;
  font-family: var(--mono, monospace);
}

.bbs-reply-ref {
  display: inline-block;
  margin-top: 3px;
  color: #a36e87;
  font: 6.5px var(--pixel, monospace);
}

.bbs-reply-button {
  flex: 0 0 auto;
  padding: 0 3px;
  border: 0;
  background: transparent;
  color: #c06f94;
  font: 8px var(--pixel, monospace);
  cursor: pointer;
}

.bbs-reply-button:hover,
.bbs-reply-button:focus-visible {
  color: #75475e;
  text-decoration: underline;
}

.bbs-empty,
.bbs-loading {
  padding: 28px 12px;
  color: #927a85;
  text-align: center;
  font: 8px/1.6 var(--serif);
}

.bbs-new-post {
  align-self: flex-start;
  margin-top: 7px;
}

.bbs-form {
  position: relative;
  margin-top: 7px;
  padding: 8px;
  border: 1px dashed #ae8498;
  box-shadow: inset 0 0 0 2px rgba(255,255,255,.68);
  background: var(--rei-blush-highlight);
}

.bbs-form input,
.bbs-form textarea {
  min-width: 0;
  padding: 4px 5px;
  border: 1px solid #ad8598;
  border-radius: 0;
  outline: 0;
  color: #4c3b44;
  background: #fff;
  font: 9px/1.45 var(--serif);
}

.bbs-form input:focus,
.bbs-form textarea:focus {
  border-color: #c96f9a;
  box-shadow: 0 0 0 1px rgba(201,111,154,.16);
}

.bbs-form textarea {
  height: 72px;
  resize: vertical;
}

.bbs-reply-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: -2px -1px 7px;
  padding: 4px 6px;
  border-left: 3px solid #d58dab;
  color: #895f72;
  background: rgba(255,255,255,.65);
  font: 6.5px var(--pixel, monospace);
}

.bbs-reply-banner button {
  border: 0;
  background: transparent;
  color: #9c607c;
  cursor: pointer;
}

.bbs-form-foot,
.bbs-form-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.bbs-form-foot {
  min-height: 13px;
  margin: -1px 0 5px 64px;
  color: #9a7c8a;
  font: 6.5px var(--pixel, monospace);
}

.bbs-form-foot [data-bbs-counter].is-near {
  color: #b24d7b;
}

.bbs-form-foot [data-bbs-form-status] {
  color: #a55378;
  text-align: right;
}

.bbs-form-actions {
  justify-content: flex-end;
}

.bbs-form-actions button {
  min-width: 58px;
  padding: 4px 8px;
  border: 1px solid #ad8598;
  background: #fffafd;
  color: #684f5b;
  font: 7px var(--pixel, monospace);
  cursor: pointer;
}

.bbs-form-actions button:first-child {
  background: #f7d9e6;
}

.bbs-form-actions button:disabled {
  opacity: .5;
  cursor: wait;
}

.bbs-trap {
  position: absolute !important;
  left: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
}

.bbs-pages {
  font-size: 7px;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 2px;
  margin-top: 7px;
  min-height: 17px;
  font: 7px var(--pixel, monospace);
}

.bbs-pages button {
  min-width: 24px;
  padding: 2px 4px;
  border: 0;
  background: transparent;
  color: #8b6778;
  font: inherit;
  cursor: pointer;
}

.bbs-pages button::before {
  content: '[ ';
}

.bbs-pages button::after {
  content: ' ]';
}

.bbs-pages button:hover:not(:disabled),
.bbs-pages button.is-current {
  color: #b55382;
  text-decoration: underline;
}

.bbs-pages button.is-current {
  font-weight: 700;
}

.bbs-pages button:disabled {
  opacity: .35;
  cursor: default;
}

@media (max-width: 820px) {
  .page.rei-responsive-active .bbs-board {
    max-height: none;
    overflow: visible;
  }
  .page.rei-responsive-active .bbs-form {
    padding: 10px;
  }
  .page.rei-responsive-active .bbs-form label {
    grid-template-columns: 54px minmax(0,1fr);
  }
  .page.rei-responsive-active .bbs-form-foot {
    margin-left: 60px;
  }
}

.friend-garden-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 8px 0 5px;
  font: 7px var(--pixel);
  color: #8e7280;
}

.friend-garden-head .web-button {
  padding: 3px 7px;
  font-size: 6.5px;
}

.friend-garden-area {
  position: relative;
  min-height: 0;
}

.friend-garden {
  display: grid;
  gap: 4px;
  margin-top: 5px;
}

.friend-link-entry {
  display: grid;
  grid-template-columns: 96px minmax(0,1fr);
  grid-template-rows: auto;
  align-items: center;
  gap: 7px;
  padding: 5px 6px;
  min-height: 43px;
  text-decoration: none;
  color: #59434f;
  border: 1px solid rgba(111,79,95,.13);
  border-bottom: 1px dotted #bfa0af;
  background: rgba(255,253,251,.78);
}

.friend-link-entry:hover {
  background: #fff4f8;
  border-color: #c99fb2;
}

.friend-link-media {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 92px;
  min-height: 33px;
}

.friend-badge-image {
  display: block;
  width: auto;
  max-width: 88px;
  height: auto;
  max-height: 31px;
  image-rendering: auto;
}

.friend-avatar-image {
  display: block;
  width: 42px;
  height: 42px;
  object-fit: cover;
  border: 1px solid #b892a3;
  background: #fff;
}

.friend-text-mark {
  display: grid;
  place-items: center;
  width: 88px;
  height: 31px;
  padding: 0 4px;
  overflow: hidden;
  border: 2px outset #8e697b;
  background: var(--rei-blush-highlight);
  font: 6px/1 var(--pixel);
  text-align: center;
}

.friend-link-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.friend-link-copy b {
  font: 9px var(--serif);
  overflow-wrap: anywhere;
}

.friend-link-copy small {
  font-size: 6.5px;
  line-height: 1.35;
  color: #8c7180;
}

.friend-link-copy i {
  font: 5.5px var(--pixel);
  font-style: normal;
  color: #aa8798;
}

.friend-empty {
  margin: 7px 0;
  padding: 8px;
  border: 1px dashed #c4a0b1;
  background: rgba(255,244,248,.62);
  font: 7px/1.5 var(--serif);
  color: #8e7280;
}

.notebook-info {
  position: relative;
  margin-top: 9px;
  padding: 7px 9px 8px;
  border: 1px dashed #b98fa3;
  background: rgba(255,249,246,.84);
}

.friend-section-label {
  margin: 0 0 6px;
  font: 6px var(--pixel);
  letter-spacing: .08em;
  color: #9b7184;
}

.notebook-info dl {
  margin: 0;
  display: grid;
  gap: 2px;
  font: 7px/1.4 var(--serif);
}

.notebook-info dl div {
  display: grid;
  grid-template-columns: 54px 1fr;
  border-bottom: 1px dotted rgba(185,143,163,.35);
}

.notebook-info dt {
  color: #987888;
}

.notebook-info dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.notebook-info a {
  color: #6d5360;
}

.notebook-badge {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 6px;
  font: 6px var(--pixel);
}

.notebook-badge img {
  display: block;
  width: auto;
  max-width: 88px;
  height: auto;
  max-height: 31px;
}

.tiny-copy {
  margin-top: 6px;
  padding: 3px 6px;
  border: 1px outset #a77e92;
  background: var(--rei-blush-highlight);
  font: 6px var(--pixel);
  color: #604955;
}

.friend-apply-form {
  position: absolute;
  inset: 0;
  z-index: 3;
  min-height: 0;
  margin: 0;
  padding: 8px;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior-y: contain;
  border: 1px solid #b98fa3;
  background: #fff1f6;
}

.friend-apply-form label {
  display: grid;
  grid-template-columns: 76px 1fr;
  gap: 5px;
  align-items: start;
  margin: 0 0 5px;
  font: 6.5px var(--serif);
}

.friend-apply-form input,.friend-apply-form textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 4px;
  border: 1px solid #ad8598;
  background: #fff;
  font: 7px var(--serif);
}

.friend-rule {
  margin: 0 0 7px;
  padding: 5px;
  border-left: 2px solid #c491a9;
  background: rgba(255,255,255,.55);
  font: 6.5px/1.45 var(--serif);
  color: #795f6c;
}

.friend-form-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.friend-form-actions button {
  padding: 3px 8px;
  border: 1px outset #9f778b;
  background: #f9dce8;
  font: 6px var(--pixel);
}

.friend-form-actions span {
  font: 6px/1.35 var(--serif);
  color: #8a596f;
}

.friend-trap {
  position: absolute!important;
  left: -10000px!important;
  width: 1px!important;
  height: 1px!important;
  overflow: hidden!important;
}

.friends-page .friend-cage {
  opacity: .25;
  pointer-events: none;
  z-index: 0;
}

.friends-page .friend-garden,.friends-page .notebook-info,.friends-page .friend-garden-head {
  position: relative;
  z-index: 1;
}

@media (max-width: 820px) {
  .friend-link-entry {
    grid-template-columns: 94px minmax(0,1fr);
  }
  .friend-apply-form label {
    grid-template-columns: 1fr;
  }
  .friends-page .friend-cage {
    display: none;
  }
  .notebook-info dl div {
    grid-template-columns: 50px 1fr;
  }
}

.lost-magic-directory {
  position: relative;
  overflow: hidden;
  background: linear-gradient(rgba(255,255,255,.36),rgba(255,255,255,.36)),
    repeating-linear-gradient(0deg,transparent 0 24px,rgba(116,72,91,.055) 24px 25px),
    #f8efe9;
}

.lost-magic-directory::before {
  content: none;
  display: none;
}

.lost-magic-directory>h2 {
  margin-bottom: 5px;
}

.lost-magic-directory .lost-intro {
  width: min(92%,470px);
  margin: 0 auto 9px;
  text-align: center;
  color: #6d5360;
  font-size: 12px;
  line-height: 1.65;
}

.lost-magic-ledger {
  position: relative;
  width: min(94%,510px);
  margin: 0 auto;
  padding: 3px 0 2px;
  border-top: 1px dotted rgba(91,62,76,.45);
  border-bottom: 1px dotted rgba(91,62,76,.38);
}

.lost-magic-ledger::before,
.lost-magic-ledger::after {
  position: absolute;
  z-index: 3;
  color: #bb829b;
  font: 10px/1 var(--serif,serif);
  pointer-events: none;
  opacity: .72;
}

.lost-magic-ledger::before {
  content: "♡";
  top: -6px;
  left: 18px;
}

.lost-magic-ledger::after {
  content: "✦";
  right: 20px;
  bottom: -6px;
}

.lost-magic-door {
  position: relative;
  display: grid;
  grid-template-columns: 46px minmax(0,1fr) 48px;
  align-items: center;
  gap: 8px;
  width: calc(100% - 9px);
  min-height: 56px;
  margin: 5px 0;
  padding: 6px 7px 6px 5px;
  overflow: visible;
  border: 1px solid rgba(103,74,88,.34);
  border-left: 3px double #9c7286;
  color: #2c2227;
  text-decoration: none;
  background: linear-gradient(90deg,rgba(255,255,255,.75),rgba(255,248,250,.46) 62%,rgba(236,206,219,.25)),
    repeating-linear-gradient(135deg,rgba(196,139,164,.065) 0 5px,transparent 5px 11px);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.6),2px 2px 0 rgba(126,89,106,.11);
  transform-origin: center center;
}

.lost-magic-door::before {
  content: "";
  position: absolute;
  top: -4px;
  left: 12px;
  z-index: 3;
  width: 23px;
  height: 6px;
  border-right: 1px solid rgba(157,113,134,.16);
  border-left: 1px solid rgba(157,113,134,.16);
  background: rgba(239,190,210,.52);
  transform: rotate(-2deg);
  pointer-events: none;
}

.lost-magic-door::after {
  position: absolute;
  z-index: 1;
  right: 57px;
  top: 7px;
  color: #b98199;
  font: 12px/1 var(--serif,serif);
  pointer-events: none;
  opacity: .18;
}

.lost-magic-door--badge {
  margin-left: 1px;
  transform: rotate(-.22deg);
  border-style: double;
  border-left-width: 3px;
}

.lost-magic-door--badge::after {
  content: "♡";
}

.lost-magic-door--badge::before {
  left: 16px;
  width: 20px;
  background: rgba(229,176,199,.54);
  transform: rotate(-3deg);
}

.lost-magic-door--image {
  margin-left: 7px;
  transform: rotate(.18deg);
  border-top-style: dotted;
  border-bottom-style: dotted;
  border-left-color: #705662;
}

.lost-magic-door--image::after {
  content: "✦";
  opacity: .22;
}

.lost-magic-door--image::before {
  left: auto;
  right: 18px;
  width: 18px;
  background: rgba(220,202,211,.58);
  transform: rotate(3deg);
}

.lost-magic-door--page {
  margin-left: 3px;
  transform: rotate(-.12deg);
  border-top: 3px double rgba(111,78,94,.42);
  border-left-color: #a4768c;
}

.lost-magic-door--page::after {
  content: "✞";
  opacity: .16;
}

.lost-magic-door--page::before {
  left: 22px;
  width: 25px;
  background: rgba(244,208,222,.58);
  transform: rotate(-1deg);
}

.lost-magic-door--collage {
  margin-left: 8px;
  transform: rotate(.2deg);
  border-right-style: dotted;
  border-bottom-style: dashed;
  border-left-color: #7d5d6c;
}

.lost-magic-door--collage::after {
  content: "⋆";
  font-size: 15px;
  opacity: .22;
}

.lost-magic-door--collage::before {
  left: auto;
  right: 70px;
  width: 21px;
  background: rgba(230,187,205,.48);
  transform: rotate(2deg);
}

.lost-magic-door--fortune {
  margin-left: 2px;
  transform: rotate(-.18deg);
  border: 3px double rgba(171,113,139,.42);
  border-left-color: #b47893;
  background: linear-gradient(90deg,rgba(255,250,252,.83),rgba(248,232,240,.55) 68%,rgba(233,201,216,.25));
}

.lost-magic-door--fortune::after {
  content: "☆";
  font-size: 14px;
  opacity: .24;
}

.lost-magic-door--fortune::before {
  left: 14px;
  width: 19px;
  background: rgba(234,179,203,.56);
  transform: rotate(-4deg);
}

.lost-magic-door:hover,.lost-magic-door:focus-visible {
  z-index: 4;
  border-color: #a6758d;
  color: #2c2227;
  text-decoration: none;
  background: #fff3f7;
  box-shadow: inset 0 0 0 1px #fff,2px 2px 0 #d9b4c5;
  outline: 1px dotted rgba(90,60,74,.46);
  outline-offset: 1px;
}

.lost-magic-sigil {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 35px;
  height: 35px;
  justify-self: center;
  border: 3px double rgba(79,56,68,.68);
  color: #815168;
  background: #fff8f9;
  box-shadow: inset 0 0 0 2px rgba(242,211,223,.52);
  font: 700 16px/1 var(--serif,serif);
  text-shadow: 1px 1px #f4d5e1;
}

.lost-magic-door--image .lost-magic-sigil {
  border-style: dotted;
  background: #fffaf7;
  transform: rotate(-2deg);
}

.lost-magic-door--page .lost-magic-sigil {
  border-style: double;
  background: #f9edf2;
  transform: rotate(1deg);
}

.lost-magic-door--collage .lost-magic-sigil {
  border-radius: 1px;
  background: #fff6fa;
  transform: rotate(-3deg);
}

.lost-magic-door--fortune .lost-magic-sigil {
  border-color: #a96f89;
  background: #fcebf3;
  transform: rotate(2deg);
}

.lost-magic-sigil--badge {
  width: 42px;
  height: 21px;
  border: 2px outset #8f6a7c;
  background: #f4d2df;
  font: 700 6px/1 var(--pixel,monospace);
  letter-spacing: -.03em;
  text-shadow: none;
}

.lost-magic-copy {
  position: relative;
  z-index: 2;
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 1px;
}

.lost-magic-copy small {
  overflow: hidden;
  color: #987989;
  font: 700 6.3px/1.2 var(--pixel,monospace);
  letter-spacing: .07em;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.lost-magic-copy b {
  color: #3b2b34;
  font: 700 14px/1.12 var(--serif,serif);
  letter-spacing: .05em;
}

.lost-magic-copy span {
  color: #775f6b;
  font-size: 8.3px;
  line-height: 1.28;
  white-space: normal;
}

.lost-magic-door>em {
  position: relative;
  z-index: 2;
  justify-self: end;
  min-width: 42px;
  padding: 4px 4px 3px;
  border: 1px outset #a47b8e;
  color: #674657;
  background: #f7dce7;
  box-shadow: inset 1px 1px #fff;
  font: 700 6.3px/1 var(--pixel,monospace);
  font-style: normal;
  letter-spacing: .05em;
  text-align: center;
}

.lost-magic-door:nth-child(2n)>em {
  background: #f8edf1;
}

.lost-magic-door--fortune>em {
  background: #efd0dd;
}

.lost-magic-door:active>em {
  border-style: inset;
  background: #edc7d7;
}

.lost-magic-footnote {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin: 7px 0 0;
  color: #947785;
  font: 700 6.3px/1.2 var(--pixel,monospace);
  letter-spacing: .09em;
  text-align: center;
}

.lost-magic-footnote::before,.lost-magic-footnote::after {
  color: #bd829c;
  font: 10px/1 var(--serif,serif);
}

.lost-magic-footnote::before {
  content: "✞";
}

.lost-magic-footnote::after {
  content: "♡";
}

.lost-magic-footnote img {
  width: 13px;
  height: 13px;
  object-fit: contain;
  image-rendering: auto;
}

@media (max-width: 820px) {
  .lost-magic-directory {
    padding-bottom: 28px;
  }
  .lost-magic-directory .lost-intro {
    margin-bottom: 8px;
    font-size: 10.5px;
  }
  .lost-magic-ledger {
    width: 96%;
    padding-top: 2px;
  }
  .lost-magic-ledger::before,.lost-magic-ledger::after {
    display: none;
  }
  .lost-magic-door {
    grid-template-columns: 42px minmax(0,1fr) 44px;
    width: calc(100% - 4px);
    min-height: 54px;
    gap: 6px;
    margin: 4px 0 4px 2px;
    padding: 5px 5px 5px 4px;
    transform: none;
  }
  .lost-magic-door::before {
    top: -3px;
    height: 5px;
  }
  .lost-magic-door::after {
    right: 51px;
    top: 6px;
    font-size: 10px;
  }
  .lost-magic-sigil {
    width: 32px;
    height: 32px;
    font-size: 14px;
    transform: none;
  }
  .lost-magic-sigil--badge {
    width: 40px;
    height: 20px;
    font-size: 5.8px;
  }
  .lost-magic-copy b {
    font-size: 13px;
  }
  .lost-magic-copy span {
    font-size: 8px;
  }
  .lost-magic-copy small {
    font-size: 6px;
  }
  .lost-magic-door>em {
    min-width: 39px;
    padding: 4px 3px 3px;
    font-size: 6px;
  }
  .lost-magic-footnote {
    gap: 4px;
    margin-top: 6px;
    font-size: 5.8px;
  }
  .lost-magic-footnote img {
    width: 12px;
    height: 12px;
  }
}

.library-shelf-empty {
  margin: 8px 0;
  padding: 18px 12px;
  border: 1px dashed #a88696;
  color: #806573;
  background: rgba(255, 250, 248, .72);
  font: 8px/1.6 var(--pixel);
  text-align: center;
}

.library-archive-tools {
  display: grid;
  gap: 8px;
  margin: 0 0 9px;
  padding: 8px;
  border: 1px solid rgba(92, 65, 79, .34);
  background: rgba(255, 249, 247, .66);
}

.library-archive-tools label {
  display: grid;
  gap: 4px;
  color: #765968;
  font: 6.4px/1.2 var(--pixel);
  letter-spacing: .05em;
}

.library-date-filters {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.library-archive-tools select {
  width: 100%;
  min-width: 0;
  height: 29px;
  padding: 3px 22px 3px 7px;
  border: 1px solid #9c7b8a;
  border-radius: 0;
  color: #4b3741;
  background: #fffaf8;
  font: 8px var(--pixel);
}

.library-archive-tools select:disabled {
  opacity: .48;
}

.library-filter-reset {
  min-height: 27px;
  border: 1px solid #6a4f5c;
  border-radius: 0;
  color: #604652;
  background: #f2dfe7;
  font: 6.5px var(--pixel);
  letter-spacing: .04em;
}

.library-filter-reset:hover,
.library-filter-reset:focus-visible {
  color: var(--rei-vellum-highlight);
  background: #5a404d;
}

.library-filter-status {
  margin: 0 0 8px;
  padding: 5px 7px;
  border-bottom: 1px dotted #987383;
  color: #826272;
  font: 6.2px var(--pixel);
  letter-spacing: .04em;
}

.library-empty-results {
  margin: 10px 0;
  padding: 16px 8px;
  border: 1px dashed #aa8998;
  color: #7d6370;
  background: rgba(255, 250, 248, .7);
  font: 8px/1.55 var(--serif);
  text-align: center;
}

.library-list-pagination {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
  padding-top: 9px;
  border-top: 3px double #836270;
}

.library-list-pagination button {
  min-height: 27px;
  padding: 4px 6px;
  border: 1px solid #856775;
  border-radius: 0;
  color: #58414c;
  background: #fff8f8;
  font: 6.5px var(--pixel);
}

.library-list-pagination button:disabled {
  opacity: .32;
}

.library-list-pagination span {
  min-width: 46px;
  color: #765665;
  font: 7px var(--pixel);
  text-align: center;
}

@media (max-width: 820px) {
  .library-archive-tools {
    gap: 7px;
    padding: 7px;
  }
  .library-date-filters {
    grid-template-columns: 1fr;
  }
  .library-archive-tools select {
    height: 31px;
    font-size: 7px;
  }
  .library-filter-status {
    font-size: 5.8px;
  }
}

.ai-reliquary .ai-header {
  grid-template-columns: 30px minmax(0, 1fr) auto auto;
  gap: 5px;
}

.ai-reliquary .ai-header > span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ai-reliquary .ai-owner-link {
  min-width: 0;
  padding: 2px 4px;
  border: 0;
  border-left: 1px dotted #9e7186;
  color: #eab3ca;
  background: transparent;
  box-shadow: none;
  font: 6px var(--pixel);
  letter-spacing: .02em;
  white-space: nowrap;
  cursor: pointer;
}

.ai-reliquary .ai-owner-link:hover,
.ai-reliquary .ai-owner-link:focus-visible {
  color: #fff4f8;
  background: #493642;
  outline: 1px dotted #d9a6bc;
}

.ai-reliquary .ai-owner-panel {
  position: absolute;
  z-index: 8;
  inset: 43px 10px 10px;
  display: grid;
  align-content: center;
  padding: 18px;
  border: 1px solid #8f687b;
  outline: 1px solid #211a1f;
  color: #f9e8ef;
  background: rgba(35, 30, 35, .98);
  box-shadow: inset 0 0 0 2px rgba(218, 167, 190, .08);
  font: 7px/1.55 var(--pixel);
}

.ai-reliquary .ai-owner-panel[hidden] {
  display: none !important;
}

.ai-reliquary .ai-owner-panel-title {
  margin-bottom: 12px;
  padding-bottom: 5px;
  border-bottom: 1px dotted #8f687b;
  color: #efb5cd;
  letter-spacing: .08em;
}

.ai-reliquary .ai-owner-form {
  display: grid;
  grid-template-columns: 1fr;
  gap: 9px;
}

.ai-reliquary .ai-owner-form label {
  display: grid;
  grid-template-columns: 58px 1fr;
  align-items: center;
  gap: 7px;
  color: #d6a9bd;
}

.ai-reliquary .ai-owner-form input {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  padding: 6px;
  color: #332630;
  background: var(--rei-vellum-highlight);
}

.ai-reliquary .ai-owner-actions {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
}

.ai-reliquary .ai-owner-actions button {
  min-width: 54px;
  padding: 4px 6px;
  color: #513b47;
  background: #edcddd;
  font: 6px var(--pixel);
}

.ai-reliquary .ai-owner-status {
  min-height: 12px;
  margin: 0;
  color: #cda2b5;
  font: 6px/1.4 var(--pixel);
  text-align: right;
}

.ai-reliquary .ai-owner-status[data-kind="ok"] {
  color: #dcb2c4;
}

.ai-reliquary .ai-owner-status[data-kind="error"] {
  color: #e2a0b2;
}

.ai-reliquary .ai-log .ai-mind-pending {
  opacity: .62;
}

.ai-reliquary .ai-log .ai-mind-pending b {
  animation: reiMindPulse 1s steps(2, end) infinite;
}

.ai-reliquary .ai-log .ai-mind-system {
  color: #bfa6b1;
}

.ai-reliquary .ai-log .ai-mind-system b {
  color: #c58ba5;
}

.ai-reliquary #aiForm button:disabled,
.ai-reliquary [data-source-id="aiForm"] button:disabled,
.ai-reliquary #aiForm input:disabled,
.ai-reliquary [data-source-id="aiForm"] input:disabled {
  opacity: .58;
  cursor: wait;
}

@keyframes reiMindPulse {
  0%, 45% {
    opacity: .48;
  }
  46%, 100% {
    opacity: 1;
  }
}

@media (max-width: 820px) {
  .ai-reliquary .ai-header {
    grid-template-columns: 28px minmax(0, 1fr) auto;
  }
  .ai-reliquary .ai-header b {
    grid-column: 2 / 3;
    grid-row: 2;
  }
  .ai-reliquary .ai-owner-link {
    grid-column: 3;
    grid-row: 1 / span 2;
    align-self: stretch;
  }
  .ai-reliquary .ai-owner-panel {
    inset: 54px 10px 10px;
    padding: 14px;
  }
}



.ai-reliquary .ai-log p:not(.ai-mind-system) {
  color: #efaeca;
}

@media (max-width: 820px) {
  .desktop-reader {
    display: block !important;
  }
  .book-controls {
    display: none !important;
  }
  .book-scene {
    display: block;
    perspective: none !important;
    -webkit-perspective: none !important;
    min-height: var(--rei-mobile-sheet-height);
    padding-bottom: 8px;
  }
  .book-spine {
    display: none !important;
  }
  .book,
  .book.is-open,
  .book.is-back {
    --leaf-left: 0%;
    position: relative;
    top: auto;
    left: auto;
    margin: 0 auto;
    transform: none !important;
    -webkit-transform: none !important;
    transform-style: flat !important;
    -webkit-transform-style: flat !important;
    width: var(--rei-mobile-book-width);
    height: var(--rei-mobile-sheet-height);
  }
  .paper {
    display: none !important;
    position: static;
    width: 100%;
    transform: none !important;
    -webkit-transform: none !important;
    transform-style: flat !important;
    -webkit-transform-style: flat !important;
    transition: none !important;
    height: var(--rei-mobile-sheet-height);
  }
  .paper.rei-responsive-paper-active {
    display: block !important;
  }
  .paper.rei-responsive-paper-active > .page {
    display: none !important;
  }
  .paper.rei-responsive-paper-active > .page.rei-responsive-active {
    display: block !important;
    position: relative;
    inset: auto;
    width: 100%;
    transform: none !important;
    -webkit-transform: none !important;
    backface-visibility: visible !important;
    -webkit-backface-visibility: visible !important;
    pointer-events: auto !important;
    height: 100%;
    overflow: hidden;
    transform-origin: left center;
  }
  .reader-frame {
    --rei-mobile-book-width: min(calc(100vw - 28px), 480px);
    --rei-mobile-sheet-height: clamp(650px, 82dvh, 690px);
  }
  .page.rei-responsive-active > .page-inner {
    box-sizing: border-box;
    height: 100% !important;
    min-height: 0 !important;
  }
  body:not(.responsive-notebook-cover)
  .paper.rei-responsive-paper-active > .page.rei-responsive-active {
    width: 100%;
    margin-left: 0;
    border: 1px solid #806672;
    border-radius: 2px;
    background-color: #fffaf7;
    box-shadow: 2px 2px 0 rgba(247, 235, 240, .9),
      4px 4px 0 rgba(225, 207, 215, .82),
      8px 12px 20px rgba(38, 25, 31, .22),
      inset 7px 0 10px -12px rgba(71, 48, 59, .5),
      inset 0 0 18px rgba(194, 149, 170, .06);
  }
  body:not(.responsive-notebook-cover)
  .page.rei-responsive-active > .page-inner {
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior-y: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: rgba(160, 113, 133, .62) transparent;
  }
  body:not(.responsive-notebook-cover)
  .page.rei-responsive-active > .page-inner::-webkit-scrollbar {
    width: 3px;
  }
  body:not(.responsive-notebook-cover)
  .page.rei-responsive-active > .page-inner::-webkit-scrollbar-thumb {
    background: rgba(160, 113, 133, .58);
    border-radius: 3px;
  }
  body:not(.responsive-notebook-cover)
  .page.rei-responsive-active > .page-inner::-webkit-scrollbar-track {
    background: transparent;
  }
  body.responsive-notebook-cover
  .paper.rei-responsive-paper-active > .page.rei-responsive-active {
    width: 100%;
    margin-left: 0;
    border-radius: 2px;
    box-shadow: 0 12px 24px rgba(32, 21, 27, .25);
  }
  body.responsive-notebook-cover
  .page.rei-responsive-active > .page-inner {
    overflow: hidden;
  }
}

.rei-stage-curtains {
  position: fixed;
  inset: 0;
  width: 100vw;
  width: 100dvw;
  height: 100vh;
  height: 100dvh;
  z-index: 40;
  overflow: visible;
  pointer-events: none;
  user-select: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 460ms cubic-bezier(.22,.61,.36,1),
    visibility 0s linear 460ms;
  will-change: opacity;
}

body.notebook-closed .rei-stage-curtains {
  opacity: 1;
  visibility: visible;
  transition: opacity 720ms cubic-bezier(.22,.61,.36,1),
    visibility 0s;
}

.rei-stage-curtain {
  position: absolute;
  top: 0;
  bottom: 0;
  height: 100%;
  min-height: 100%;
  width: auto;
  max-width: none;
  object-fit: fill;
  pointer-events: none;
  transform: none;
  -webkit-user-drag: none;
  user-select: none;
}

.rei-stage-curtain--left {
  left: 0;
}

.rei-stage-curtain--right {
  right: 0;
}

@media (max-width: 820px) {
  .rei-stage-curtains {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .rei-stage-curtains,
  body.notebook-closed .rei-stage-curtains {
    transition-duration: 1ms;
  }
}

@media (max-width: 600px) {
  .library-vault-layout {
    grid-template-rows: minmax(0, 224px) minmax(0, 1fr);
  }
  .library-record-nav {
    display: grid;
    grid-template-rows: auto auto minmax(0, 1fr) auto;
    gap: 4px;
    padding: 8px 10px 6px;
    overflow: hidden;
  }
  .library-archive-tools {
    gap: 4px;
    margin: 0;
    padding: 5px 6px;
  }
  .library-archive-tools label {
    gap: 2px;
    font-size: 5.4px;
  }
  .library-date-filters {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 4px;
  }
  .library-archive-tools select {
    height: 25px;
    padding: 2px 18px 2px 6px;
    font-size: 6.1px;
  }
  .library-filter-reset {
    min-height: 23px;
    padding: 2px 5px;
    font-size: 5.6px;
  }
  .library-filter-status {
    margin: 0;
    padding: 2px 4px 3px;
    font-size: 5.2px;
    line-height: 1.2;
  }
  #libraryRecordList {
    display: flex;
    gap: 6px;
    width: 100%;
    min-width: 0;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 0 0 2px;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  #libraryRecordList::-webkit-scrollbar {
    display: none;
  }
  .library-record-button {
    flex: 0 0 min(72vw, 235px);
    width: auto;
    min-height: 44px;
    margin: 0;
    padding: 5px 6px;
    grid-template-columns: 20px minmax(0, 1fr);
    gap: 1px 5px;
    scroll-snap-align: start;
  }
  .library-record-button::before {
    font-size: 13px;
  }
  .library-record-button strong {
    font-size: 7.6px;
    line-height: 1.25;
  }
  .library-record-button small {
    font-size: 5.3px;
  }
  .library-list-pagination {
    margin-top: 0;
    padding-top: 4px;
    gap: 4px;
    border-top-width: 1px;
  }
  .library-list-pagination button {
    min-height: 22px;
    padding: 2px 4px;
    font-size: 5.5px;
  }
  .library-list-pagination span {
    min-width: 38px;
    font-size: 5.8px;
  }
  .library-document {
    padding: 18px 15px 38px;
    overflow-y: auto;
    overscroll-behavior: contain;
  }
  .library-document-header {
    margin-bottom: 12px;
    padding-bottom: 13px;
  }
  .library-document-header > p {
    margin-bottom: 5px;
    font-size: 6.5px;
  }
  .library-document-header h3 {
    font-size: clamp(19px, 5.6vw, 25px);
    line-height: 1.25;
  }
  .library-document-meta {
    gap: 4px;
  }
}

.desktop-reader .book-scene {
  -webkit-perspective: 2600px;
  perspective: 2600px;
}

.desktop-reader .book {
  -webkit-transform: translateX(-50%);
  transform: translateX(-50%);
  -webkit-transform-style: preserve-3d;
  transform-style: preserve-3d;
}

.desktop-reader .paper {
  -webkit-transform-origin: left center;
  transform-origin: left center;
  -webkit-transform-style: preserve-3d;
  transform-style: preserve-3d;
  -webkit-transition: -webkit-transform .78s cubic-bezier(.6, .03, .34, 1), left .52s ease, z-index .01s .38s;
  transition: transform .78s cubic-bezier(.6, .03, .34, 1), left .52s ease, z-index .01s .38s;
  will-change: transform, left;
}

.desktop-reader .paper.flipped {
  -webkit-transform: rotateY(-180deg);
  transform: rotateY(-180deg);
}

.desktop-reader .paper > .page {
  -webkit-backface-visibility: hidden !important;
  backface-visibility: hidden !important;
  -webkit-transform-style: flat;
  transform-style: flat;
}

.desktop-reader .paper > .page.front {
  -webkit-transform: rotateY(0deg) translateZ(.02px);
  transform: rotateY(0deg) translateZ(.02px);
}

.desktop-reader .paper > .page.back {
  -webkit-transform: rotateY(180deg) translateZ(.02px);
  transform: rotateY(180deg) translateZ(.02px);
}

.desktop-reader .paper:not(.flipped) > .page.front,
.desktop-reader .paper.flipped > .page.back {
  visibility: visible;
}
