/*
 * 山河入卷，灯火有信
 *
 * This is the final visual authority for the public letter. The earlier style
 * files keep the tested layout and interaction mechanics; this sheet gives
 * them one contemporary Chinese visual language: ink, silk, water and light.
 */

:root {
  --scroll-night: #0f1416;
  --scroll-night-soft: #171c1d;
  --scroll-dai: #243639;
  --scroll-ink: #312b27;
  --scroll-paper: #eee4d3;
  --scroll-paper-deep: #d8c6ac;
  --scroll-moon: #ece5da;
  --scroll-cinnabar: #9d4b3f;
  --scroll-cinnabar-rgb: 157 75 63;
  --scroll-rouge: #895b60;
  --scroll-tea: #b08a60;
  --scroll-mist: #8e9f9c;
  --scroll-silk: #c9bba7;
  --scroll-ease: cubic-bezier(0.16, 1, 0.3, 1);
  --scroll-border: rgb(236 229 218 / 0.12);
}

.scroll-painting {
  --sky-a: 142 159 156;
  --sky-b: 236 229 218;
  --sky-c: 157 75 63;
  background: var(--scroll-night);
  color: var(--scroll-moon);
}

.scroll-painting[data-tone="blue"] {
  --sky-a: 118 145 146;
  --sky-b: 220 215 202;
  --sky-c: 137 91 96;
}

.scroll-painting[data-tone="warm"] {
  --sky-a: 176 138 108;
  --sky-b: 231 218 196;
  --sky-c: 157 75 63;
}

.scroll-painting[data-tone="ink"] {
  --sky-a: 116 105 94;
  --sky-b: 222 205 180;
  --sky-c: 143 78 70;
}

.scroll-painting[data-tone="day"] {
  --sky-a: 126 145 141;
  --sky-b: 176 138 96;
  --sky-c: 157 75 63;
}

.scroll-painting ::selection {
  color: #fff8ed;
  background: rgb(var(--scroll-cinnabar-rgb) / 0.7);
}

.scroll-painting .grain {
  opacity: 0.14;
  mix-blend-mode: soft-light;
}

.scroll-painting .cinema-frame {
  inset: 13px;
  border-color: rgb(236 229 218 / 0.055);
}

.scroll-painting .cinema-frame i {
  width: 13vw;
  background: linear-gradient(90deg, transparent, rgb(176 138 96 / 0.46), transparent);
}

/* --------------------------------------------------------------------------
   卷首 · one quiet invitation, drawn like a night landscape
   -------------------------------------------------------------------------- */

.scroll-painting .threshold {
  background:
    linear-gradient(105deg, rgb(8 12 13 / 0.92), rgb(17 23 24 / 0.78) 52%, rgb(31 27 26 / 0.76)),
    radial-gradient(ellipse at 78% 22%, rgb(236 229 218 / 0.09), transparent 22%),
    #0b1012;
}

.scroll-painting .threshold::before {
  top: auto;
  right: -7vw;
  bottom: -1px;
  left: -7vw;
  width: 114vw;
  height: 43vh;
  border: 0;
  border-radius: 0;
  content: "";
  opacity: 0.72;
  background:
    linear-gradient(148deg, transparent 0 9%, rgb(62 78 78 / 0.3) 9.2% 16%, transparent 16.2% 27%, rgb(44 59 60 / 0.46) 27.2% 43%, transparent 43.2% 54%, rgb(37 50 51 / 0.68) 54.2% 72%, transparent 72.2%),
    linear-gradient(169deg, transparent 0 19%, rgb(24 34 35 / 0.96) 19.2% 63%, transparent 63.2%);
  box-shadow: none;
  filter: blur(0.2px);
  clip-path: polygon(0 52%, 8% 45%, 15% 51%, 23% 34%, 31% 48%, 42% 21%, 53% 46%, 62% 36%, 71% 49%, 81% 27%, 91% 44%, 100% 36%, 100% 100%, 0 100%);
  transform: translate3d(calc(var(--ambient-x, 0px) * -0.12), 0, 0);
}

.scroll-painting .threshold::after {
  top: auto;
  right: -8vw;
  bottom: 12.5vh;
  left: -8vw;
  width: 116vw;
  height: 16vh;
  border: 0;
  border-radius: 50%;
  content: "";
  opacity: 0.42;
  background:
    repeating-linear-gradient(176deg, transparent 0 18px, rgb(205 196 181 / 0.075) 19px 20px, transparent 21px 33px);
  box-shadow: none;
  transform: rotate(-1.8deg);
}

.scroll-painting .threshold__orbit {
  inset: 5vh -3vw auto auto;
  width: min(74vw, 980px);
  height: 78vh;
  aspect-ratio: auto;
  border: 0;
  border-radius: 0;
  opacity: 0.74;
  background: radial-gradient(circle at 72% 22%, rgb(236 229 218 / 0.12), transparent 18%);
  box-shadow: none;
  transform: none;
}

.scroll-painting .threshold__orbit::before {
  top: 8%;
  right: 16%;
  bottom: auto;
  left: auto;
  width: clamp(112px, 14vw, 210px);
  height: auto;
  aspect-ratio: 1;
  border: 1px solid rgb(236 229 218 / 0.09);
  border-radius: 50%;
  content: "";
  opacity: calc(0.5 + var(--hold-scale, 0) * 0.36);
  background:
    radial-gradient(circle at 38% 34%, rgb(242 235 220 / 0.27) 0 8%, rgb(216 207 190 / 0.13) 35%, rgb(142 159 156 / 0.045) 61%, transparent 72%);
  box-shadow: 0 0 90px rgb(222 211 190 / 0.055);
  transform: scale(calc(0.94 + var(--hold-scale, 0) * 0.06));
}

.scroll-painting .threshold__orbit::after {
  top: auto;
  right: 7%;
  bottom: 24%;
  left: auto;
  width: 88%;
  height: 1px;
  border: 0;
  border-radius: 0;
  content: "";
  opacity: 0.3;
  background: linear-gradient(90deg, transparent, rgb(236 229 218 / 0.32) 30% 72%, transparent);
  box-shadow: 0 11px 0 rgb(236 229 218 / 0.03), 0 25px 0 rgb(236 229 218 / 0.02);
  transform: rotate(-3deg);
}

.scroll-painting .threshold__orbit i {
  width: 2px;
  height: 8px;
  border-radius: 0;
  background: rgb(176 138 96 / 0.72);
  box-shadow: 0 0 16px rgb(176 138 96 / 0.28);
  animation: scroll-window-breathe 5.8s ease-in-out infinite;
}

.scroll-painting .threshold__orbit i:nth-child(1) { top: 43%; left: 48%; }
.scroll-painting .threshold__orbit i:nth-child(2) { top: 37%; right: 24%; background: rgb(236 229 218 / 0.58); animation-delay: -1.9s; }
.scroll-painting .threshold__orbit i:nth-child(3) { right: 9%; bottom: 30%; background: rgb(157 75 63 / 0.64); animation-delay: -3.4s; }

@keyframes scroll-window-breathe {
  0%, 100% { opacity: 0.24; transform: translateY(0); }
  48% { opacity: 0.9; transform: translateY(-2px); }
}

.scroll-painting .threshold__halo {
  top: 50%;
  left: 29%;
  width: min(62vw, 720px);
  opacity: calc(0.12 + var(--hold-scale, 0) * 0.3);
  background: radial-gradient(ellipse, rgb(176 138 96 / 0.13), rgb(142 159 156 / 0.035) 42%, transparent 70%);
  filter: blur(6px);
  transform: translate(-50%, -50%) scale(calc(0.78 + var(--hold-scale, 0) * 0.28));
}

.scroll-painting .threshold__content {
  width: min(900px, calc(100vw - 96px));
  align-items: flex-start;
  padding-right: min(24vw, 260px);
  text-align: left;
}

.scroll-painting .threshold__eyebrow {
  margin-bottom: clamp(26px, 4vh, 46px);
  color: rgb(176 138 96 / 0.8);
}

.scroll-painting .threshold__title {
  max-width: 17em;
  color: rgb(244 238 227 / 0.94);
  font-size: clamp(1.5rem, 2.45vw, 2.25rem);
  letter-spacing: 0.045em;
  line-height: 1.92;
  text-shadow: 0 18px 58px rgb(0 0 0 / 0.28);
  text-wrap: balance;
}

.scroll-painting .threshold__route {
  width: min(450px, 86vw);
  margin-top: clamp(28px, 4vh, 46px);
  color: rgb(236 229 218 / 0.48);
}

.scroll-painting .threshold__city i {
  width: 5px;
  height: 5px;
  border: 0;
  border-radius: 1px;
  background: rgb(157 75 63 / 0.72);
  box-shadow: none;
  transform: rotate(45deg);
}

.scroll-painting .threshold__route-line,
.scroll-painting .threshold__route-line i {
  background: linear-gradient(90deg, transparent, rgb(142 159 156 / 0.55) 18%, rgb(176 138 96 / 0.72) 76%, transparent);
  box-shadow: none;
}

.scroll-painting .hold-button {
  min-width: min(330px, 84vw);
  min-height: 80px;
  margin-top: 18px;
  padding: 0 24px 0 90px;
  border: 0;
  border-top: 1px solid rgb(236 229 218 / 0.16);
  border-bottom: 1px solid rgb(236 229 218 / 0.1);
  border-radius: 1px;
  color: rgb(236 229 218 / 0.78);
  background: linear-gradient(90deg, rgb(236 229 218 / 0.025), transparent 82%);
  box-shadow: none;
  backdrop-filter: none;
}

.scroll-painting .hold-button::before {
  width: 51px;
  height: 51px;
  border-color: rgb(176 138 96 / 0.24);
  border-radius: 50%;
  background: radial-gradient(circle, rgb(176 138 96 / 0.12), transparent 68%);
}

.scroll-painting .hold-button::after {
  right: 0;
  bottom: -1px;
  left: 74px;
  background: linear-gradient(90deg, rgb(157 75 63 / 0.52), transparent 74%);
}

.scroll-painting .hold-button:hover,
.scroll-painting .hold-button:focus-visible,
.scroll-painting .hold-button.is-holding {
  border-color: rgb(236 229 218 / 0.22);
  background: linear-gradient(90deg, rgb(176 138 96 / 0.07), transparent 86%);
  transform: translateX(4px);
}

.scroll-painting .hold-button__track { stroke: rgb(236 229 218 / 0.15); }
.scroll-painting .hold-button__progress { stroke: var(--scroll-cinnabar); }
.scroll-painting .hold-button__dot {
  width: 7px;
  height: 7px;
  background: var(--scroll-cinnabar);
  box-shadow: 0 0 calc(6px + var(--hold-scale, 0) * 13px) rgb(157 75 63 / 0.24);
}

.scroll-painting .threshold__hint,
.scroll-painting .threshold__direct {
  color: rgb(236 229 218 / 0.48);
}

.scroll-painting .threshold__direct {
  padding-left: 0;
  border-bottom: 1px solid transparent;
}

.scroll-painting .threshold__direct:hover,
.scroll-painting .threshold__direct:focus-visible {
  border-bottom-color: rgb(157 75 63 / 0.48);
  color: rgb(236 229 218 / 0.86);
}

/* --------------------------------------------------------------------------
   卷标 · fewer controls, quieter hierarchy
   -------------------------------------------------------------------------- */

.scroll-painting .site-chrome {
  grid-template-columns: minmax(150px, 1fr) minmax(170px, 0.55fr) minmax(150px, 1fr);
  padding: max(20px, env(safe-area-inset-top)) max(28px, 3.5vw) 22px;
  background: linear-gradient(180deg, rgb(9 13 14 / 0.72), rgb(9 13 14 / 0.16) 72%, transparent);
  backdrop-filter: none;
}

.scroll-painting .archive-mark {
  align-items: center;
  gap: 12px;
  min-width: 44px;
}

.scroll-painting .archive-mark::before {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid rgb(157 75 63 / 0.55);
  content: "间";
  color: rgb(192 111 92 / 0.9);
  font-family: var(--serif);
  font-size: 0.7rem;
  line-height: 1;
  transform: rotate(-2deg);
}

.scroll-painting .archive-mark__title {
  color: rgb(236 229 218 / 0.84);
  letter-spacing: 0.14em;
}

.scroll-painting .archive-mark__label {
  max-width: 24em;
  color: rgb(236 229 218 / 0.42);
  letter-spacing: 0.1em;
}

.scroll-painting .journey {
  position: relative;
  display: grid;
  width: clamp(170px, 18vw, 270px);
  gap: 8px;
}

.scroll-painting .journey__percent {
  display: none;
}

.scroll-painting .journey__track {
  height: 1px;
  overflow: visible;
  opacity: 0.62;
  background: linear-gradient(90deg, transparent, rgb(236 229 218 / 0.22) 16% 84%, transparent);
}

.scroll-painting .journey__fill {
  background: linear-gradient(90deg, rgb(142 159 156 / 0.65), rgb(176 138 96 / 0.82));
  box-shadow: none;
}

.scroll-painting .journey__fill::after {
  right: 0;
  width: 5px;
  height: 5px;
  border: 0;
  border-radius: 1px;
  background: var(--scroll-cinnabar);
  box-shadow: none;
  transform: translate(50%, -50%) rotate(45deg);
}

.scroll-painting .journey__caption {
  margin: 0;
  color: rgb(236 229 218 / 0.5);
  font-family: var(--serif);
  font-size: 0.64rem;
  letter-spacing: 0.18em;
  text-align: center;
}

.scroll-painting .site-chrome__tools {
  display: flex;
  min-width: 150px;
  align-items: center;
  justify-self: end;
  justify-content: flex-end;
  gap: 8px;
}

.scroll-painting .sound-toggle {
  width: auto;
  min-width: 92px;
  min-height: 44px;
  color: rgb(236 229 218 / 0.62);
}

.scroll-painting[data-tone="day"] .site-chrome {
  background: linear-gradient(180deg, rgb(238 228 211 / 0.82), rgb(238 228 211 / 0.2) 76%, transparent);
}

.scroll-painting[data-tone="day"] .archive-mark__title,
.scroll-painting[data-tone="day"] .journey__caption,
.scroll-painting[data-tone="day"] .sound-toggle {
  color: rgb(49 43 39 / 0.68);
}

.scroll-painting .chapter-nav {
  top: 50%;
  right: max(15px, 1.25vw);
  left: auto;
  display: grid;
  width: 68px;
  gap: 6px;
  padding: 12px 0;
  border-top: 1px solid rgb(236 229 218 / 0.08);
  border-bottom: 1px solid rgb(236 229 218 / 0.08);
  transform: translateY(-50%);
}

.scroll-painting .chapter-nav a {
  display: grid;
  min-height: 38px;
  grid-template-columns: 17px 1fr;
  align-items: center;
  gap: 7px;
  padding: 0;
  color: rgb(236 229 218 / 0.42);
}

.scroll-painting .chapter-nav a::after {
  display: none;
}

.scroll-painting .chapter-nav a span {
  width: 16px;
  height: 16px;
  color: rgb(176 138 96 / 0.5);
  font-family: var(--serif);
  font-size: 0.56rem;
  line-height: 16px;
  text-align: center;
}

.scroll-painting .chapter-nav a em {
  position: static;
  color: currentColor;
  font-family: var(--serif);
  font-size: 0.6rem;
  font-style: normal;
  letter-spacing: 0.08em;
  opacity: 0;
  transform: translateX(5px);
  transition: opacity 280ms ease, transform 360ms var(--scroll-ease);
}

.scroll-painting .chapter-nav:hover a em,
.scroll-painting .chapter-nav:focus-within a em,
.scroll-painting .chapter-nav a.is-active em {
  opacity: 0.72;
  transform: none;
}

.scroll-painting .chapter-nav a.is-active span {
  color: rgb(223 197 170 / 0.94);
  background: rgb(157 75 63 / 0.58);
  box-shadow: none;
}

.scroll-painting[data-tone="day"] .chapter-nav a {
  color: rgb(49 43 39 / 0.48);
}

/* --------------------------------------------------------------------------
   一卷山水 · the former star map becomes water, geese, moon and distant lamps
   -------------------------------------------------------------------------- */

.scroll-painting .memory-sky__field {
  mix-blend-mode: normal;
  animation-duration: 34s;
}

.scroll-painting .memory-sky__halo {
  top: 3%;
  right: -7%;
  width: min(56vw, 820px);
  opacity: 0.55;
  background: radial-gradient(circle at 43% 44%, rgb(var(--sky-b) / 0.13) 0 6%, rgb(var(--sky-a) / 0.05) 32%, transparent 69%);
  box-shadow: none;
}

.scroll-painting .memory-sky__halo::before,
.scroll-painting .memory-sky__halo::after,
.scroll-painting .memory-sky__star::after,
.scroll-painting .pointer-light::before {
  display: none;
}

.scroll-painting .memory-sky__ribbon {
  left: -8%;
  width: 116%;
  border: 0;
  border-top: 1px solid rgb(var(--sky-a) / 0.13);
  border-radius: 46% 54% 50% 50%;
  opacity: 0.42;
  box-shadow: 0 -16px 52px rgb(var(--sky-a) / 0.025);
}

.scroll-painting .memory-sky__ribbon--one {
  top: 23%;
  height: 37%;
  transform: rotate(-4.5deg);
}

.scroll-painting .memory-sky__ribbon--two {
  top: 52%;
  left: -13%;
  width: 126%;
  height: 24%;
  border-top-color: rgb(var(--sky-b) / 0.09);
  transform: rotate(2.5deg);
}

.scroll-painting .memory-sky__constellation {
  inset: 16% 2% 23%;
  width: 96%;
  height: 61%;
  opacity: 0.3;
}

.scroll-painting .memory-sky__constellation path {
  stroke: rgb(var(--sky-a) / 0.32);
  stroke-width: 0.65;
  stroke-dasharray: 24 15 2 11;
}

.scroll-painting .memory-sky__node {
  fill: rgb(var(--scroll-cinnabar-rgb) / 0.46);
  opacity: 0.28;
}

.scroll-painting[data-chapter="01"] .memory-sky__node--01,
.scroll-painting[data-chapter="02"] .memory-sky__node--02,
.scroll-painting[data-chapter="03"] .memory-sky__node--03,
.scroll-painting[data-chapter="04"] .memory-sky__node--04,
.scroll-painting[data-chapter="05"] .memory-sky__node--05 {
  fill: rgb(var(--scroll-cinnabar-rgb) / 0.86);
  opacity: 0.9;
  transform: scale(1.2);
}

.scroll-painting .memory-sky__star {
  width: 2px;
  height: 7px;
  border-radius: 0;
  opacity: 0.38;
  background: rgb(var(--sky-b) / 0.56);
  box-shadow: 0 0 12px rgb(var(--sky-b) / 0.12);
}

.scroll-painting .memory-sky__moon {
  border-color: rgb(var(--sky-b) / 0.08);
  background:
    radial-gradient(circle at 36% 31%, rgb(var(--sky-b) / 0.2) 0 5%, transparent 6%),
    radial-gradient(circle at 51% 49%, rgb(var(--sky-b) / 0.13), rgb(var(--sky-a) / 0.035) 56%, transparent 70%);
  box-shadow: 0 0 86px rgb(var(--sky-b) / 0.055);
}

.scroll-painting .memory-sky__chapter-echo {
  top: 18%;
  left: 5.5%;
  color: rgb(var(--sky-b) / 0.52);
  letter-spacing: 0.22em;
}

.scroll-painting .memory-projection__layer {
  border-radius: 2px;
  filter: grayscale(0.3) saturate(0.6) contrast(0.94) blur(8px);
  mask-image: linear-gradient(90deg, transparent 0, rgb(0 0 0 / 0.52) 18%, #000 42% 78%, transparent 100%);
  mix-blend-mode: soft-light;
}

/* Each chapter passes like a different turn of the same scroll. */
.scroll-painting .memory-sky::before {
  width: 118vw;
  background: linear-gradient(100deg, transparent 18%, rgb(var(--sky-a) / 0.04) 35%, rgb(var(--sky-b) / 0.18) 49%, rgb(var(--sky-c) / 0.09) 57%, transparent 76%);
}

.scroll-painting[data-transition-to="02"].is-chapter-transitioning .memory-sky::before {
  animation-name: scroll-pass-ink;
}

.scroll-painting[data-transition-to="03"].is-chapter-transitioning .memory-sky::before {
  animation-name: scroll-pass-window;
}

.scroll-painting[data-transition-to="04"].is-chapter-transitioning .memory-sky::before {
  animation-name: scroll-pass-paper;
}

.scroll-painting[data-transition-to="05"].is-chapter-transitioning .memory-sky::before {
  animation-name: scroll-pass-dawn;
}

@keyframes scroll-pass-ink {
  0% { opacity: 0; transform: translate3d(88vw, 0, 0) skewX(8deg); }
  34% { opacity: 0.72; }
  100% { opacity: 0; transform: translate3d(-92vw, 5vh, 0) skewX(2deg); }
}

@keyframes scroll-pass-window {
  0% { opacity: 0; transform: translate3d(-80vw, -9vh, 0) skewX(-9deg); }
  40% { opacity: 0.6; }
  100% { opacity: 0; transform: translate3d(86vw, 7vh, 0) skewX(-2deg); }
}

@keyframes scroll-pass-paper {
  0% { opacity: 0; transform: translate3d(0, -74vh, 0) scaleY(0.32); }
  38% { opacity: 0.62; }
  100% { opacity: 0; transform: translate3d(0, 74vh, 0) scaleY(1); }
}

@keyframes scroll-pass-dawn {
  0% { opacity: 0; transform: translate3d(-64vw, 18vh, 0) rotate(-3deg); }
  42% { opacity: 0.7; }
  100% { opacity: 0; transform: translate3d(70vw, -16vh, 0) rotate(2deg); }
}

/* --------------------------------------------------------------------------
   五折 · editorial composition and chapter seals
   -------------------------------------------------------------------------- */

.scroll-painting .chapter {
  isolation: isolate;
}

.scroll-painting .chapter-scroll-seal {
  position: absolute;
  z-index: 14;
  top: clamp(108px, 15vh, 170px);
  right: max(36px, 6vw);
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: rgb(236 229 218 / 0.48);
  font-family: var(--serif);
  pointer-events: auto;
}

.scroll-painting .chapter-scroll-seal b {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border: 1px solid rgb(157 75 63 / 0.62);
  color: rgb(196 107 88 / 0.86);
  font-size: 0.7rem;
  font-weight: 400;
  line-height: 1;
  transform: rotate(-2deg);
  transition: color 320ms ease, background 420ms ease, transform 520ms var(--scroll-ease);
}

.scroll-painting .chapter-scroll-seal i {
  writing-mode: vertical-rl;
  font-size: 0.62rem;
  font-style: normal;
  letter-spacing: 0.22em;
  line-height: 1;
}

.scroll-painting .chapter-scroll-seal:hover b,
.scroll-painting .chapter-scroll-seal:focus-visible b,
.scroll-painting .chapter-scroll-seal.is-seal-stamped b {
  color: rgb(246 229 210 / 0.95);
  background: rgb(157 75 63 / 0.64);
  transform: rotate(1deg) scale(0.96);
}

.scroll-painting .chapter-seal-imprint {
  position: absolute;
  z-index: 2;
  top: -3px;
  left: -3px;
  width: 36px;
  height: 36px;
  border: 1px solid rgb(var(--scroll-cinnabar-rgb) / 0.56);
  color: rgb(var(--scroll-cinnabar-rgb) / 0.72);
  font-family: var(--serif);
  font-size: 0.65rem;
  line-height: 34px;
  text-align: center;
  pointer-events: none;
  animation: chapter-imprint 920ms var(--scroll-ease) both;
}

@keyframes chapter-imprint {
  0% { opacity: 0; transform: translate(-50%, -50%) rotate(-8deg) scale(1.7); }
  28% { opacity: 0.86; transform: translate(-50%, -50%) rotate(2deg) scale(0.94); }
  100% { opacity: 0; transform: translate(-50%, -72%) rotate(0) scale(1); }
}

.scroll-painting .first-frame {
  background:
    radial-gradient(ellipse at 78% 31%, rgb(142 159 156 / 0.1), transparent 31%),
    linear-gradient(180deg, #0d1315, #131a1b 74%, #171a1b);
}

.scroll-painting .display-title,
.scroll-painting .section-heading h2,
.scroll-painting .ordinary-days__heading h2,
.scroll-painting .daybreak__copy h2 {
  font-weight: 400;
  text-wrap: balance;
}

.scroll-painting .first-frame__copy::before {
  width: 56px;
  background: linear-gradient(90deg, rgb(157 75 63 / 0.72), transparent);
}

.scroll-painting .film-frame,
.scroll-painting .memory__visual,
.scroll-painting .puzzle-story__visual,
.scroll-painting .photo-after__figure {
  border-color: rgb(216 198 172 / 0.16);
  border-radius: 2px;
  background: linear-gradient(145deg, rgb(238 228 211 / 0.065), rgb(142 159 156 / 0.018));
  box-shadow: 0 34px 94px rgb(0 0 0 / 0.3), 0 0 0 1px rgb(255 255 255 / 0.018);
}

.scroll-painting .film-frame::before,
.scroll-painting .memory__visual::before,
.scroll-painting .photo-after__figure::before {
  border-color: rgb(238 228 211 / 0.05);
}

.scroll-painting .contact-sheet {
  background:
    linear-gradient(180deg, #141a1b 0%, #172020 28%, #1d2020 64%, #1c1b1a 100%);
}

.scroll-painting .contact-sheet::before {
  position: absolute;
  z-index: 0;
  inset: 0;
  content: "";
  pointer-events: none;
  opacity: 0.38;
  background:
    repeating-linear-gradient(0deg, transparent 0 79px, rgb(216 198 172 / 0.026) 80px 81px),
    linear-gradient(90deg, transparent 8%, rgb(216 198 172 / 0.025) 8.1% 8.25%, transparent 8.35% 91.6%, rgb(216 198 172 / 0.02) 91.7% 91.85%, transparent 92%);
}

.scroll-painting .contact-sheet__thread {
  background: linear-gradient(180deg, transparent, rgb(157 75 63 / 0.52) 12% 78%, transparent);
  box-shadow: none;
}

.scroll-painting .memory__index,
.scroll-painting .memory__date,
.scroll-painting .photo-after__caption,
.scroll-painting .puzzle-story__visual figcaption {
  color: rgb(176 138 96 / 0.72);
}

.scroll-painting .puzzle-story__control,
.scroll-painting .chat-slip {
  border-radius: 2px;
}

.scroll-painting .puzzle-story__control {
  border-color: rgb(216 198 172 / 0.16);
  color: rgb(236 229 218 / 0.58);
  background: transparent;
}

.scroll-painting .puzzle-story__control.is-active {
  border-color: rgb(157 75 63 / 0.58);
  color: rgb(236 229 218 / 0.9);
  background: rgb(157 75 63 / 0.12);
  box-shadow: none;
}

/* Chat and the tide now belong to the third fold. */
.scroll-painting .ordinary-days {
  min-height: 250svh;
  background:
    radial-gradient(ellipse at 78% 22%, rgb(176 138 96 / 0.13), transparent 30%),
    linear-gradient(180deg, #1b1d1d 0%, #241f1c 43%, #1b1918 72%, #121719 100%);
}

.scroll-painting .ordinary-days__wash {
  opacity: 0.72;
  background:
    repeating-linear-gradient(90deg, transparent 0 63px, rgb(216 198 172 / 0.022) 64px 65px),
    repeating-linear-gradient(0deg, transparent 0 92px, rgb(216 198 172 / 0.018) 93px 94px),
    radial-gradient(ellipse at 74% 28%, rgb(176 138 96 / 0.14), transparent 34%);
}

.scroll-painting .ordinary-days__layout {
  display: block;
}

.scroll-painting .ordinary-days__heading {
  position: relative;
  top: auto;
  width: min(42%, 470px);
}

.scroll-painting .ordinary-days__text {
  width: min(62%, 760px);
  max-width: 760px;
  margin: clamp(150px, 24vh, 290px) 4% 0 auto;
  padding-top: 0;
}

.scroll-painting .ordinary-lines li {
  max-width: 21em;
  color: rgb(236 229 218 / 0.26);
  letter-spacing: -0.018em;
  line-height: 1.68;
}

.scroll-painting .ordinary-lines li.is-visible {
  color: rgb(238 228 211 / 0.9);
}

.scroll-painting .ordinary-lines li.is-past {
  color: rgb(216 198 172 / 0.38);
}

.scroll-painting .ordinary-ink__period {
  border-radius: 1px;
  background: rgb(var(--scroll-cinnabar-rgb) / 0.88);
  box-shadow: none;
  transform: rotate(45deg) scale(0.72);
}

.scroll-painting .ordinary-days__layout > .chat-fragments,
.scroll-painting .ordinary-days__layout > .truth-beat {
  grid-column: 1 / -1;
}

.scroll-painting .chat-fragments {
  width: 100%;
  margin-top: clamp(110px, 18vh, 220px);
  border-color: rgb(216 198 172 / 0.12);
}

.scroll-painting .chat-fragments::before {
  opacity: 0.42;
  background: radial-gradient(ellipse, rgb(176 138 96 / 0.09), transparent 68%);
}

.scroll-painting .chat-slip,
.scroll-painting .chat-fragment__inner {
  border-color: rgb(216 198 172 / 0.13);
  background:
    linear-gradient(90deg, rgb(238 228 211 / 0.035), transparent 68%),
    rgb(17 20 20 / 0.22);
  box-shadow: none;
}

.scroll-painting .chat-fragment__inner::before {
  background: rgb(var(--scroll-cinnabar-rgb) / 0.62);
  box-shadow: none;
}

.scroll-painting .truth-beat {
  width: min(1040px, 100%);
  margin-top: clamp(160px, 25vh, 300px);
  border: 1px solid rgb(216 198 172 / 0.09);
  border-right-color: transparent;
  border-left-color: transparent;
  border-radius: 0;
  background: linear-gradient(180deg, rgb(10 16 18 / 0.16), rgb(12 16 17 / 0.5));
}

.scroll-painting .truth-beat p {
  color: rgb(238 228 211 / 0.94);
  text-shadow: 0 20px 62px rgb(0 0 0 / 0.28);
}

.scroll-painting .truth-beat span {
  color: rgb(216 198 172 / 0.62);
}

.scroll-painting .truth-tide__moon {
  opacity: 0.48;
  filter: none;
  box-shadow: 0 0 72px rgb(236 229 218 / 0.06);
}

.scroll-painting .letter {
  background:
    radial-gradient(ellipse at 76% 22%, rgb(176 138 96 / 0.08), transparent 28%),
    linear-gradient(180deg, #121719 0%, #101516 36%, #0d1214 100%);
}

.scroll-painting .letter-body {
  width: min(940px, 92%);
  padding: clamp(74px, 9vw, 118px) clamp(58px, 8vw, 116px);
  color: var(--scroll-ink);
  background:
    linear-gradient(104deg, transparent 0 48%, rgb(176 138 96 / 0.045) 50%, transparent 52%),
    repeating-linear-gradient(0deg, rgb(83 67 53 / 0.018) 0 1px, transparent 1px 6px),
    linear-gradient(135deg, #eee4d3, #e8dbc6 66%, #dfcfb8);
  box-shadow: 0 40px 110px rgb(0 0 0 / 0.3), inset 0 0 80px rgb(100 77 55 / 0.035);
}

.scroll-painting .letter-body::after {
  position: absolute;
  inset: 14px;
  border: 1px solid rgb(72 58 47 / 0.065);
  content: "";
  pointer-events: none;
}

.scroll-painting .letter-body__salutation,
.scroll-painting .letter-row__text {
  color: rgb(57 48 41 / 0.88);
}

.scroll-painting .letter-note,
.scroll-painting .letter-body__footer,
.scroll-painting .letter-fold__note {
  color: rgb(72 58 47 / 0.55);
}

.scroll-painting .letter-row.is-touched-row .letter-row__text {
  color: rgb(45 37 32 / 0.98);
  text-shadow: none;
}

.scroll-painting .letter-row.is-touched-row .letter-note {
  color: rgb(126 65 57 / 0.78);
}

.scroll-painting .letter-fold__button {
  border-color: rgb(72 58 47 / 0.16);
  border-radius: 2px;
  color: rgb(57 48 41 / 0.72);
  background: transparent;
  box-shadow: none;
}

.scroll-painting .letter-fold__paper b {
  color: rgb(246 229 210 / 0.92);
  background: rgb(157 75 63 / 0.76);
}

.scroll-painting .daybreak {
  color: var(--scroll-ink);
  background:
    radial-gradient(ellipse at 73% 21%, rgb(176 138 96 / 0.18), transparent 28%),
    linear-gradient(180deg, #d8d4ca 0%, #e6dece 32%, #eee4d3 72%, #e7dbc8 100%);
}

.scroll-painting .daybreak::before {
  height: 45vh;
  background: linear-gradient(180deg, #101617 0%, #273638 25%, #899493 68%, rgb(216 212 202 / 0) 100%);
}

.scroll-painting .daybreak::after {
  background: radial-gradient(ellipse at 15% 70%, rgb(176 138 96 / 0.42), rgb(157 75 63 / 0.08) 18%, transparent 42%);
}

.scroll-painting .daybreak__sun {
  opacity: 0.35;
  background: radial-gradient(circle, rgb(238 224 195 / 0.78), rgb(176 138 96 / 0.12) 33%, transparent 69%);
  filter: none;
}

.scroll-painting .daybreak__lines,
.scroll-painting .daybreak__open-line {
  color: rgb(49 43 39 / 0.68);
}

.scroll-painting .daybreak__open-line {
  max-width: 21em;
}

.scroll-painting .closing-button {
  min-height: 122px;
  border-color: rgb(49 43 39 / 0.2);
}

.scroll-painting .city-pair {
  border-top: 1px solid rgb(49 43 39 / 0.14);
  border-bottom: 1px solid rgb(49 43 39 / 0.1);
  border-radius: 0;
  background: linear-gradient(180deg, rgb(238 228 211 / 0.16), transparent);
  box-shadow: none;
}

.scroll-painting .city-pair svg {
  filter: saturate(0.7) contrast(1.08);
}

.scroll-painting .city-pair__route,
.scroll-painting .city-pair__route-progress,
.scroll-painting .city-pair__river,
.scroll-painting .city-pair__water,
.scroll-painting .city-pair__ridge {
  stroke-linecap: round;
}

.scroll-painting .city-pair__handle-core {
  fill: var(--scroll-tea);
  filter: none;
}

.scroll-painting .city-weather__button {
  border-radius: 2px;
  box-shadow: none;
}

.scroll-painting .archive-door {
  display: block;
  max-width: 760px;
  margin: clamp(230px, 30vh, 380px) auto 0;
  padding: clamp(46px, 7vw, 74px) 0;
  border: 0;
  border-top: 1px solid rgb(49 43 39 / 0.16);
  border-bottom: 1px solid rgb(49 43 39 / 0.12);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.scroll-painting .archive-door__copy {
  max-width: 31em;
}

.scroll-painting .archive-door__action {
  margin-top: 42px;
}

.scroll-painting .archive-door__button {
  border-radius: 2px;
  color: rgb(49 43 39 / 0.72);
  background: transparent;
  box-shadow: none;
}

/* --------------------------------------------------------------------------
   UI becomes ink marks and paper slips, never glass pills
   -------------------------------------------------------------------------- */

.scroll-painting .memory-map-toggle {
  position: relative;
  inset: auto;
  display: grid;
  width: 44px;
  min-width: 44px;
  min-height: 44px;
  grid-template-columns: 1fr;
  padding: 4px;
  border: 0;
  border-radius: 1px;
  color: rgb(236 229 218 / 0.66);
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
  opacity: 0.78;
  transform: none;
}

.scroll-painting .memory-map-toggle > i {
  width: 30px;
  height: 30px;
  margin: auto;
  border: 1px solid rgb(176 138 96 / 0.4);
  border-radius: 1px;
  background: linear-gradient(145deg, rgb(176 138 96 / 0.08), transparent);
  transform: rotate(-1deg);
}

.scroll-painting .memory-map-toggle > i::before,
.scroll-painting .memory-map-toggle > i::after,
.scroll-painting .memory-map-toggle > i span {
  width: 3px;
  height: 3px;
  border-radius: 0;
  background: rgb(157 75 63 / 0.72);
  box-shadow: none;
  transform: rotate(45deg);
}

.scroll-painting .memory-map-toggle > span {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  display: none;
  width: max-content;
  padding: 7px 9px;
  border: 1px solid rgb(236 229 218 / 0.1);
  color: rgb(236 229 218 / 0.64);
  background: rgb(15 20 22 / 0.88);
}

.scroll-painting .memory-map-toggle:hover > span,
.scroll-painting .memory-map-toggle:focus-visible > span,
.scroll-painting.is-memory-map-open .memory-map-toggle > span {
  display: grid;
}

.scroll-painting[data-tone="day"] .memory-map-toggle {
  color: rgb(49 43 39 / 0.64);
  background: transparent;
  box-shadow: none;
}

.scroll-painting .memory-map-panel {
  right: max(24px, 3.2vw);
  bottom: auto;
  top: max(82px, calc(env(safe-area-inset-top) + 68px));
  width: min(390px, calc(100vw - 40px));
  padding: 28px 30px 26px;
  border: 1px solid rgb(68 55 46 / 0.14);
  border-radius: 3px;
  color: rgb(49 43 39 / 0.88);
  background:
    repeating-linear-gradient(0deg, rgb(75 59 46 / 0.018) 0 1px, transparent 1px 6px),
    linear-gradient(135deg, #eee4d3, #e4d6c1);
  box-shadow: 0 28px 90px rgb(0 0 0 / 0.25), inset 0 0 54px rgb(95 72 52 / 0.028);
  backdrop-filter: none;
  transform: translate3d(22px, 0, 0);
  transform-origin: right top;
  clip-path: inset(0 0 0 100%);
  transition: opacity 340ms ease, transform 520ms var(--scroll-ease), clip-path 520ms var(--scroll-ease);
}

.scroll-painting.is-memory-map-open .memory-map-panel {
  transform: none;
  clip-path: inset(0);
}

.scroll-painting .memory-map-panel > header {
  border-bottom-color: rgb(49 43 39 / 0.12);
}

.scroll-painting .memory-map-panel .eyebrow {
  color: rgb(157 75 63 / 0.72);
}

.scroll-painting .memory-map-panel__close {
  border-radius: 1px;
  border-color: rgb(49 43 39 / 0.16);
}

.scroll-painting .memory-map-panel__nav::before {
  background: linear-gradient(rgb(157 75 63 / 0.42), rgb(49 43 39 / 0.08));
}

.scroll-painting .memory-map-panel__nav a > i {
  border: 1px solid rgb(157 75 63 / 0.5);
  border-radius: 0;
  background: var(--scroll-paper);
  transform: rotate(45deg);
}

.scroll-painting .memory-map-panel__nav a.is-visited > i {
  background: rgb(157 75 63 / 0.42);
}

.scroll-painting .memory-map-panel__nav a.is-active > i {
  background: var(--scroll-cinnabar);
  box-shadow: none;
  transform: rotate(45deg) scale(1.08);
}

.scroll-painting .memory-map-panel__hint,
.scroll-painting .memory-map-panel__privacy {
  color: rgb(49 43 39 / 0.48);
}

.scroll-painting .memory-map-panel__echo {
  border-color: rgb(49 43 39 / 0.16);
  border-radius: 2px;
  color: rgb(91 59 48 / 0.84);
  background: rgb(157 75 63 / 0.035);
}

.scroll-painting .chapter-seal-slot {
  position: sticky;
  z-index: 71;
  top: 46vh;
  width: 48px;
  height: 0;
  margin-right: max(22px, 4vw);
  margin-left: auto;
  pointer-events: none;
}

.scroll-painting .chapter-seal-slot .light-seed {
  position: absolute;
  inset: 0 0 auto auto;
  width: 46px;
  min-width: 46px;
  min-height: 46px;
  padding: 4px;
  border: 1px solid rgb(var(--scroll-cinnabar-rgb) / 0.46);
  border-radius: 2px;
  color: rgb(205 158 126 / 0.9);
  background: rgb(16 20 20 / 0.64);
  box-shadow: none;
  backdrop-filter: none;
  pointer-events: auto;
  opacity: 0;
  transform: translate3d(-8px, 0, 0);
}

.scroll-painting .chapter-seal-slot.is-current .light-seed {
  opacity: 0.78;
  transform: none;
}

.scroll-painting .light-seed > i {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 1px;
  background: none;
  box-shadow: none;
}

.scroll-painting .light-seed > i::before,
.scroll-painting .light-seed > i::after {
  background: linear-gradient(90deg, transparent, rgb(var(--scroll-cinnabar-rgb) / 0.82), transparent);
}

.scroll-painting .light-seed > i span {
  inset: 8px;
  border-color: rgb(var(--scroll-cinnabar-rgb) / 0.48);
  border-radius: 1px;
  transform: rotate(45deg);
}

.scroll-painting .light-seed > span {
  right: calc(100% + 9px);
  left: auto;
  border-color: rgb(236 229 218 / 0.12);
  border-radius: 2px;
  background: rgb(15 20 21 / 0.88);
  box-shadow: none;
  transform: translate3d(7px, -50%, 0);
}

.scroll-painting .light-seed:hover > span,
.scroll-painting .light-seed:focus-visible > span,
.scroll-painting .light-seed.is-inviting > span {
  transform: translate3d(0, -50%, 0);
}

.scroll-painting .light-note {
  border-radius: 2px;
  background: rgb(15 20 21 / 0.9);
  box-shadow: 0 24px 70px rgb(0 0 0 / 0.22);
}

.scroll-painting .moon-gate,
.scroll-painting .moon-secret__return {
  border-radius: 2px;
  box-shadow: none;
  backdrop-filter: none;
}

.scroll-painting .chapter-bridge {
  width: min(420px, calc(100% - 40px));
  min-height: 76px;
  padding: 12px 8px 12px 4px;
  border: 0;
  border-top: 1px solid rgb(var(--sky-b) / 0.16);
  border-bottom: 1px solid rgb(var(--sky-b) / 0.08);
  border-radius: 0;
  color: rgb(var(--sky-b) / 0.68);
  background: transparent;
}

.scroll-painting .chapter-bridge::before {
  align-self: center;
  grid-column: 1;
  grid-row: 1 / span 2;
  width: 5px;
  height: 5px;
  margin-right: 13px;
  content: "";
  background: rgb(var(--scroll-cinnabar-rgb) / 0.72);
  transform: rotate(45deg);
}

.scroll-painting .chapter-bridge small,
.scroll-painting .chapter-bridge strong {
  padding-left: 16px;
}

.scroll-painting .chapter-bridge i {
  background: linear-gradient(90deg, transparent, currentColor 72%, transparent);
}

.scroll-painting .chapter-bridge:hover,
.scroll-painting .chapter-bridge:focus-visible {
  border-color: rgb(var(--sky-b) / 0.28);
  background: linear-gradient(90deg, rgb(var(--sky-b) / 0.03), transparent);
  transform: translate3d(6px, 0, 0);
}

.scroll-painting .pointer-light {
  width: 190px;
  height: 94px;
  border: 0;
  border-radius: 50%;
  opacity: 0.3;
  background: radial-gradient(ellipse, rgb(var(--sky-b) / 0.1), rgb(var(--sky-a) / 0.045) 38%, transparent 72%);
  box-shadow: none;
}

.scroll-painting .pointer-light::after {
  width: 3px;
  height: 3px;
  border-radius: 1px;
  background: rgb(var(--scroll-cinnabar-rgb) / 0.64);
  box-shadow: none;
  transform: translate(-50%, -50%) rotate(45deg);
}

.scroll-painting .interaction-bloom {
  mix-blend-mode: soft-light;
}

.scroll-painting .interaction-bloom::before,
.scroll-painting .interaction-bloom::after {
  width: clamp(220px, 34vw, 520px);
  aspect-ratio: 2.4;
  border-color: rgb(var(--bloom-rgb) / 0.28);
  border-radius: 48% 52% 46% 54%;
  box-shadow: inset 0 0 54px rgb(var(--bloom-rgb) / 0.05);
}

.scroll-painting .interaction-bloom::after {
  width: clamp(330px, 52vw, 760px);
  border-style: solid;
  opacity: 0.3;
}

.scroll-painting .interaction-bloom i {
  width: 3px;
  height: 3px;
  border-radius: 1px;
  background: rgb(var(--scroll-cinnabar-rgb) / 0.74);
}

.scroll-painting .interaction-bloom.is-visible i {
  animation-name: scroll-cinnabar-fall;
}

@keyframes scroll-cinnabar-fall {
  0% { opacity: 0; transform: rotate(var(--bloom-angle)) translateY(5px) scale(0.2); }
  32% { opacity: 0.72; }
  100% { opacity: 0; transform: rotate(var(--bloom-angle)) translateY(clamp(42px, 7vw, 88px)) scale(0.72); }
}

.scroll-painting .ink-page-turn {
  position: fixed;
  z-index: 88;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  opacity: 0;
}

.scroll-painting .ink-page-turn::before,
.scroll-painting .ink-page-turn::after {
  position: absolute;
  inset: -14%;
  content: "";
  opacity: 0;
}

.scroll-painting .ink-page-turn::before {
  background: linear-gradient(102deg, transparent 21%, rgb(30 39 39 / 0.68) 45%, rgb(216 198 172 / 0.18) 54%, transparent 76%);
  transform: translateX(-100%) skewX(-7deg);
}

.scroll-painting .ink-page-turn::after {
  background: radial-gradient(ellipse at 52% 58%, rgb(var(--scroll-cinnabar-rgb) / 0.11), transparent 38%);
  transform: scale(0.7);
}

.scroll-painting .ink-page-turn.is-turning {
  opacity: 1;
}

.scroll-painting .ink-page-turn.is-turning::before {
  animation: ink-page-sweep 900ms var(--scroll-ease) both;
}

.scroll-painting .ink-page-turn.is-settling::after {
  animation: ink-page-settle 780ms ease-out both;
}

@keyframes ink-page-sweep {
  0% { opacity: 0; transform: translateX(-100%) skewX(-7deg); }
  38% { opacity: 0.76; }
  100% { opacity: 0; transform: translateX(100%) skewX(-2deg); }
}

@keyframes ink-page-settle {
  0% { opacity: 0; transform: scale(0.72); }
  42% { opacity: 0.5; }
  100% { opacity: 0; transform: scale(1.22); }
}

/* --------------------------------------------------------------------------
   Responsive recut · same work, newly composed for the hand
   -------------------------------------------------------------------------- */

@media (max-width: 900px) {
  .scroll-painting .threshold__content {
    width: min(720px, calc(100vw - 56px));
    padding-right: 11vw;
  }

  .scroll-painting .archive-mark__label {
    display: none;
  }

  .scroll-painting .site-chrome {
    grid-template-columns: 1fr minmax(140px, 0.8fr) 1fr;
  }

  .scroll-painting .chapter-nav {
    display: none;
  }

  .scroll-painting .ordinary-days__layout {
    display: block;
  }

  .scroll-painting .ordinary-days__heading {
    width: min(72%, 480px);
  }

  .scroll-painting .ordinary-days__text {
    width: min(78%, 680px);
    margin-top: 18vh;
    padding-top: 0;
  }
}

@media (max-width: 700px) {
  .scroll-painting .cinema-frame {
    inset: 7px;
  }

  .scroll-painting .threshold {
    justify-items: start;
    padding: max(58px, env(safe-area-inset-top)) 24px max(34px, env(safe-area-inset-bottom));
  }

  .scroll-painting .threshold::before {
    right: -28vw;
    left: -28vw;
    width: 156vw;
    height: 38vh;
    opacity: 0.74;
  }

  .scroll-painting .threshold::after {
    bottom: 10vh;
  }

  .scroll-painting .threshold__orbit {
    top: 2vh;
    right: -54vw;
    width: 128vw;
    height: 78vh;
    opacity: 0.68;
  }

  .scroll-painting .threshold__orbit::before {
    top: 7%;
    right: 31%;
    width: 34vw;
  }

  .scroll-painting .threshold__halo {
    top: 42%;
    left: 38%;
    width: 94vw;
  }

  .scroll-painting .threshold__content {
    width: 100%;
    align-items: flex-start;
    padding: 0;
    text-align: left;
  }

  .scroll-painting .threshold__eyebrow {
    margin-bottom: 24px;
  }

  .scroll-painting .threshold__title {
    max-width: 13em;
    font-size: clamp(1.42rem, 6.8vw, 2.1rem);
    line-height: 1.82;
  }

  .scroll-painting .threshold__route {
    width: 100%;
    gap: 11px;
    margin-top: 28px;
  }

  .scroll-painting .hold-button {
    width: min(320px, 100%);
    min-width: 0;
    margin-top: 16px;
  }

  .scroll-painting .site-chrome {
    grid-template-columns: auto 1fr auto;
    padding: max(12px, env(safe-area-inset-top)) 17px 14px;
  }

  .scroll-painting .archive-mark::before {
    width: 26px;
    height: 26px;
  }

  .scroll-painting .archive-mark__title,
  .scroll-painting .sound-toggle__label {
    display: none;
  }

  .scroll-painting .journey {
    width: min(46vw, 190px);
  }

  .scroll-painting .journey__caption {
    font-size: 0.57rem;
    letter-spacing: 0.12em;
  }

  .scroll-painting .site-chrome__tools {
    min-width: 78px;
    gap: 3px;
  }

  .scroll-painting .sound-toggle {
    min-width: 44px;
    min-height: 44px;
    justify-content: center;
  }

  .scroll-painting .memory-map-toggle {
    width: 44px;
    min-width: 44px;
  }

  .scroll-painting .chapter-nav {
    display: none;
  }

  .scroll-painting .chapter-scroll-seal {
    top: 90px;
    right: 22px;
    gap: 7px;
  }

  .scroll-painting .chapter-scroll-seal b {
    width: 27px;
    height: 27px;
  }

  .scroll-painting .chapter-scroll-seal i {
    font-size: 0.55rem;
  }

  .scroll-painting .memory-sky__aurora--two,
  .scroll-painting .memory-sky__ribbon--two {
    display: none;
  }

  .scroll-painting .memory-sky__constellation {
    inset: 20% -10% 26%;
    width: 120%;
    opacity: 0.18;
  }

  .scroll-painting .memory-projection__layer {
    opacity: 0.09;
    filter: grayscale(0.45) saturate(0.48) blur(6px);
  }

  .scroll-painting .chapter-seal-slot {
    top: 42vh;
    width: 44px;
    margin-right: 12px;
    margin-left: auto;
  }

  .scroll-painting .chapter-seal-slot .light-seed {
    width: 44px;
    min-width: 44px;
    min-height: 44px;
  }

  .scroll-painting .light-seed > i {
    width: 31px;
    height: 31px;
  }

  .scroll-painting .light-seed.is-inviting > span {
    opacity: 0;
    pointer-events: none;
    transform: translate3d(7px, -50%, 0);
  }

  .scroll-painting .light-seed:hover > span,
  .scroll-painting .light-seed:focus-visible > span {
    opacity: 1;
    transform: translate3d(0, -50%, 0);
  }

  .scroll-painting .first-frame__lead {
    max-width: 31em;
    font-size: 1.02rem;
    line-height: 1.95;
  }

  .scroll-painting .memory-map-panel {
    top: max(64px, calc(env(safe-area-inset-top) + 54px));
    right: 10px;
    left: 10px;
    width: auto;
    max-height: calc(100svh - 76px);
    padding: 22px 21px;
    overflow-y: auto;
  }

  .scroll-painting .first-frame,
  .scroll-painting .contact-sheet,
  .scroll-painting .ordinary-days,
  .scroll-painting .letter,
  .scroll-painting .daybreak {
    overflow: clip;
  }

  .scroll-painting .display-title,
  .scroll-painting .section-heading h2,
  .scroll-painting .ordinary-days__heading h2,
  .scroll-painting .daybreak__copy h2 {
    font-size: clamp(2.75rem, 12.5vw, 4.1rem);
    line-height: 1.08;
  }

  .scroll-painting .ordinary-lines li {
    max-width: none;
    font-size: clamp(1.55rem, 7.3vw, 2.35rem);
    line-height: 1.68;
  }

  .scroll-painting .chat-fragments {
    margin-top: 150px;
    padding-block: 78px;
  }

  .scroll-painting .ordinary-days__heading,
  .scroll-painting .ordinary-days__text {
    width: 100%;
  }

  .scroll-painting .ordinary-days__text {
    margin-top: 140px;
  }

  .scroll-painting .truth-beat {
    width: 100%;
    min-height: 82svh;
    margin-top: 140px;
    padding-inline: 7%;
  }

  .scroll-painting .letter-body {
    width: calc(100% - 18px);
    padding: 62px 25px 58px;
  }

  .scroll-painting .letter-body::after {
    inset: 9px;
  }

  .scroll-painting .letter-row {
    grid-template-columns: 1fr;
  }

  .scroll-painting .letter-row__text {
    font-size: 1.08rem;
    line-height: 2.08;
  }

  .scroll-painting .archive-door {
    width: calc(100% - 20px);
    margin-top: 190px;
    padding-block: 42px;
  }

  .scroll-painting .interaction-bloom i:nth-child(n + 4) {
    display: none;
  }
}

@media (max-width: 380px) {
  .scroll-painting .threshold {
    padding-right: 19px;
    padding-left: 19px;
  }

  .scroll-painting .threshold__title {
    font-size: 1.3rem;
  }

  .scroll-painting .memory-map-toggle > span {
    display: none !important;
  }

  .scroll-painting .journey__caption {
    letter-spacing: 0.07em;
  }

  .scroll-painting .chapter-scroll-seal i {
    display: none;
  }
}

@media (max-width: 380px) and (max-height: 600px) {
  .scroll-painting .threshold {
    padding-top: 14px;
    padding-bottom: 10px;
  }

  .scroll-painting .threshold__eyebrow {
    margin-bottom: 8px;
    font-size: 0.55rem;
  }

  .scroll-painting .threshold__title {
    max-width: 15em;
    font-size: 1.05rem;
    line-height: 1.56;
  }

  .scroll-painting .threshold__route {
    margin-top: 10px;
  }

  .scroll-painting .hold-button {
    min-height: 64px;
    margin-top: 7px;
  }

  .scroll-painting .hold-button__ring {
    top: 4px;
    left: 4px;
    width: 56px;
    height: 56px;
  }

  .scroll-painting .hold-button::before {
    left: 32px;
    width: 42px;
    height: 42px;
  }

  .scroll-painting .hold-button__dot {
    top: 29px;
    left: 29px;
  }

  .scroll-painting .threshold__hint {
    margin-top: 3px;
  }

  .scroll-painting .threshold__direct {
    margin-top: 0;
  }
}

@media (max-height: 560px) and (orientation: landscape) {
  .scroll-painting .site-chrome {
    min-height: 54px;
    padding: max(4px, env(safe-area-inset-top)) 14px 5px;
  }

  .scroll-painting .journey {
    gap: 4px;
  }

  .scroll-painting .journey__caption {
    font-size: 0.54rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .scroll-painting .threshold__orbit i,
  .scroll-painting .chapter-seal-imprint,
  .scroll-painting .ink-page-turn::before,
  .scroll-painting .ink-page-turn::after,
  .scroll-painting .interaction-bloom.is-visible i {
    animation: none !important;
  }

  .scroll-painting .threshold::before,
  .scroll-painting .threshold__orbit::before,
  .scroll-painting .memory-sky__field,
  .scroll-painting .chapter-scroll-seal b {
    transform: none !important;
  }

  .scroll-painting .chapter-seal-imprint,
  .scroll-painting .ink-page-turn {
    display: none;
  }
}

.scroll-painting.is-data-saver .ink-page-turn,
.scroll-painting.is-data-saver .chapter-seal-imprint,
.scroll-painting.is-data-saver .memory-sky__aurora--two,
.scroll-painting.is-data-saver .memory-sky__ribbon--two {
  display: none;
}

@media (forced-colors: active) {
  .scroll-painting .threshold::before,
  .scroll-painting .threshold::after,
  .scroll-painting .chapter-scroll-seal,
  .scroll-painting .ink-page-turn,
  .scroll-painting .chapter-seal-imprint {
    display: none;
  }

  .scroll-painting .memory-map-toggle,
  .scroll-painting .chapter-seal-slot .light-seed,
  .scroll-painting .memory-map-panel,
  .scroll-painting .hold-button,
  .scroll-painting .chapter-bridge {
    border: 1px solid ButtonText;
    color: ButtonText;
    background: ButtonFace;
    box-shadow: none;
    forced-color-adjust: auto;
  }
}
