:root {
  --paper: #f3f0e9;
  --paper-deep: #ddd6c8;
  --ink: #171815;
  --muted: #6e6c65;
  --line: rgba(23, 24, 21, 0.22);
  --accent: #bf4b2b;
  --white: #fffdf8;
  --serif: "Gill Sans MT", "Gill Sans", "PingFang SC", "Microsoft YaHei",
    sans-serif;
  --sans: "Gill Sans MT", "Gill Sans", "PingFang SC", "Microsoft YaHei",
    sans-serif;
  --pad: clamp(1.25rem, 4.5vw, 5rem);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

html[lang="zh-CN"] {
  --serif: "Gill Sans MT", "Gill Sans", "WF-Yunmt", "GenWanMin2 TW",
    "Noto Serif SC", serif;
  --sans: "Gill Sans MT", "Gill Sans", "WF-Yunmt", "GenWanMin2 TW",
    "Noto Serif SC", serif;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 5rem;
}

body {
  margin: 0;
  overflow-x: hidden;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
}

body.lightbox-open,
body.album-open,
body.guide-open {
  overflow: hidden;
}

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

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

button {
  color: inherit;
  background: none;
  border: 0;
  font: inherit;
}

::selection {
  color: var(--white);
  background: var(--accent);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

[hidden] {
  display: none !important;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  padding: 0;
  border: 0;
  margin: -1px;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.8rem 1rem;
  color: var(--white);
  background: var(--ink);
  transform: translateY(-180%);
  transition: transform 180ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.site-mark {
  position: fixed;
  z-index: 24;
  bottom: max(0.8rem, env(safe-area-inset-bottom));
  left: max(0.9rem, env(safe-area-inset-left));
  display: block;
  width: clamp(2.7rem, 3.6vw, 3.55rem);
  background: transparent;
  border: 0;
  line-height: 0;
  opacity: 0.92;
  transition:
    opacity 220ms ease,
    transform 320ms var(--ease);
}

.site-mark:hover {
  opacity: 1;
  transform: translateY(-0.18rem);
}

.site-mark img {
  width: 100%;
  height: auto;
  background: transparent;
}

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  right: 0;
  left: auto;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  width: 5.5rem;
  height: 100svh;
  padding: 1.5rem 0.7rem;
  color: var(--ink);
  background: transparent;
  border: 0;
  transition:
    color 250ms ease,
    background-color 250ms ease;
}

.site-header.is-scrolled {
  min-height: 0;
  color: var(--ink);
  background: transparent;
  border: 0;
}

.brand-lockup {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: clamp(0.9rem, 2vw, 1.5rem);
}

.brand-side {
  display: flex;
  align-items: flex-start;
  gap: clamp(1rem, 2vw, 2rem);
}

.wordmark {
  display: block;
  font-family: var(--sans);
  font-size: 3rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.09em;
  white-space: nowrap;
  writing-mode: vertical-rl;
}

.brand-kicker {
  margin-top: 2em;
  color: inherit;
  font-size: 0.62rem;
  line-height: 1.3;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
  opacity: 0.86;
  writing-mode: vertical-rl;
}

.hero-quote {
  position: absolute;
  z-index: 2;
  top: 50%;
  left: clamp(7.5rem, 14vw, 13rem);
  width: clamp(13rem, 17vw, 18rem);
  margin: 0;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.55;
  letter-spacing: 0.02em;
  transform: translateY(-50%);
}

.hero-quote span {
  display: block;
}

.hero-quote cite {
  display: block;
  margin-top: 0.85rem;
  color: var(--muted);
  font-size: 14px;
  font-style: normal;
  letter-spacing: 0.04em;
}

.hero-quote-reflection {
  margin: 1.15rem 0 0;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.55;
}

html[lang="en"] .brand-lockup {
  flex-direction: column;
  align-items: flex-start;
  gap: 0.9rem;
  width: auto;
}

html[lang="en"] .wordmark,
html[lang="en"] .brand-kicker {
  white-space: pre-line;
  writing-mode: horizontal-tb;
}

html[lang="en"] .wordmark {
  line-height: 1.05;
}

html[lang="en"] .brand-kicker {
  margin-top: 0;
  line-height: 1.55;
}

.site-header nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(1.6rem, 4vh, 2.8rem);
  width: 100%;
}

.header-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(2rem, 5vh, 3.5rem);
  width: 100%;
  height: 100%;
}

.site-header nav a {
  position: relative;
  padding: 0.35rem 0;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-orientation: mixed;
  writing-mode: horizontal-tb;
}

.site-header nav a::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 1px;
  background: currentColor;
  content: "";
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 300ms var(--ease);
}

.site-header nav a:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

.site-header nav a::after {
  display: none;
}

.language-switch {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  min-width: 0;
  padding: 0.35rem 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  font-size: 0.55rem;
  line-height: 1;
  letter-spacing: 0.08em;
  cursor: pointer;
  opacity: 0.88;
  transition: opacity 220ms ease;
}

.language-switch:hover {
  color: inherit;
  background: transparent;
  opacity: 1;
}

.site-header.is-scrolled .language-switch {
  background: transparent;
}

.site-header.is-scrolled .language-switch:hover {
  color: inherit;
  background: transparent;
}

html[lang="zh-CN"] .section-head h2,
html[lang="zh-CN"] .about h2,
html[lang="zh-CN"] .contact h2 {
  letter-spacing: -0.035em;
}

html[lang="zh-CN"] .section-head h2,
html[lang="zh-CN"] .about h2,
html[lang="zh-CN"] .contact h2 {
  line-height: 0.95;
}

.hero {
  position: relative;
  display: block;
  height: 100svh;
  min-height: 100svh;
  overflow: hidden;
  color: var(--ink);
  background: var(--paper);
}

.hero-layout {
  display: grid;
  grid-template-columns: minmax(24rem, 50vw) minmax(19rem, 1fr);
  height: 100%;
  overflow: hidden;
}

.hero-visual {
  position: relative;
  display: block;
  width: 100%;
  height: 100svh;
  min-width: 0;
  min-height: 0;
  background: var(--paper);
}

.hero-stack {
  position: relative;
  z-index: 0;
  width: 100%;
  height: 100%;
  min-height: 0;
  margin: 0;
  touch-action: pan-y;
}

.hero-stack-item {
  position: absolute;
  top: 0;
  left: 0;
  display: block;
  width: calc(100% - 5.8rem);
  height: calc(100% - 2.5rem);
  margin: 0;
  overflow: visible;
  background: transparent;
  border: 0;
  cursor: pointer;
  opacity: 0.34;
  transform: translate(var(--stack-x, 0), var(--stack-y, 0));
  transition:
    transform 420ms var(--ease),
    opacity 300ms ease,
    filter 350ms ease;
}

.hero-stack-item.is-active {
  opacity: 1;
  backdrop-filter: none;
}

.hero-stack.has-landscape-active .hero-stack-item:not(.is-active) {
  opacity: 0;
  pointer-events: none;
}

.hero-stack-item.is-landscape-photo.is-active::before {
  position: absolute;
  z-index: 0;
  top: 50%;
  left: 50%;
  width: calc(100% + clamp(2rem, 4vw, 4.5rem));
  height: auto;
  aspect-ratio: var(--hero-aspect, 1.5);
  background-image: var(--hero-image);
  background-position: center;
  background-size: cover;
  content: "";
  filter: blur(22px) saturate(0.86) brightness(0.96);
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.hero-stack-item > img {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  image-orientation: from-image;
  background: transparent;
  border: 0;
  transform: none;
  filter: blur(7px) saturate(0.78) brightness(0.88);
  transition: filter 350ms ease;
}

.hero-stack-item.is-active > img {
  filter: none;
}

.hero-stack-station img {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 110%;
  max-width: none;
  height: auto;
  object-fit: contain;
  image-orientation: none;
  transform: translate(-50%, -50%) rotate(-90deg);
  transform-origin: center;
}

.hero-photo-credit {
  position: absolute;
  z-index: 2;
  bottom: var(--credit-bottom, 0);
  left: calc(100% + 0.75rem);
  display: block;
  max-width: 4.8rem;
  max-height: 100%;
  margin: 0;
  width: max-content;
  padding: 0;
  color: var(--ink);
  background: transparent;
  border: 0;
  font-size: 0.58rem;
  line-height: 1.6;
  letter-spacing: 0.08em;
  overflow-wrap: anywhere;
  text-orientation: upright;
  white-space: normal;
  writing-mode: vertical-rl;
  text-shadow: none;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 220ms ease,
    visibility 220ms ease;
}

.hero-swipe-hint {
  position: absolute;
  z-index: 4;
  bottom: 0.65rem;
  left: var(--hero-swipe-hint-left, 0);
  display: none;
  margin: 0;
  color: var(--muted);
  font-size: 0.58rem;
  line-height: 1.4;
  letter-spacing: 0.06em;
  pointer-events: none;
}

.hero-stack-item.is-active .hero-photo-credit {
  opacity: 1;
  visibility: visible;
}

html[lang="en"] .hero-photo-credit {
  width: 5.4rem;
  max-width: 5.4rem;
  text-orientation: mixed;
  writing-mode: horizontal-tb;
}

html[lang="en"] .hero-photo-credit.hero-photo-credit-below {
  width: 100%;
  max-width: 100%;
}

.hero-photo-credit.hero-photo-credit-below {
  right: auto;
  top: calc(100% - var(--credit-bottom, 0px) + 0.35rem);
  bottom: auto;
  left: 0;
  width: 100%;
  max-width: 100%;
  max-height: none;
  padding-top: 0.25rem;
  font-size: 0.6rem;
  line-height: 1.5;
  overflow: visible;
  overflow-wrap: normal;
  text-orientation: mixed;
  white-space: normal;
  writing-mode: horizontal-tb;
}

.hero-overlay {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: space-between;
  min-height: 0;
  height: 100%;
  padding: 8rem 6.2rem 2.2rem 1rem;
}

.hero-cta {
  position: absolute;
  right: 0.72rem;
  bottom: 2rem;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  width: auto;
}

.arrow-link {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  width: max-content;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.arrow-link svg,
.contact-content a svg {
  width: 1.1rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.4;
  transition: transform 300ms var(--ease);
}

.arrow-link:hover svg,
.contact-content a:hover svg {
  transform: translateX(0.35rem);
}

.work,
.about,
.contact {
  padding: clamp(6rem, 11vw, 10rem) calc(var(--pad) + 5.5rem) clamp(6rem, 11vw, 10rem)
    var(--pad);
}

.work {
  width: min(100%, 100rem);
  margin: 0 auto;
}

.work-heading {
  margin-bottom: clamp(2rem, 4vw, 3.5rem);
}

.work-heading .eyebrow {
  margin-bottom: 0;
}

.section-head {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(18rem, 0.6fr);
  gap: 1.5rem 4rem;
  margin-bottom: clamp(3.5rem, 7vw, 6rem);
}

.eyebrow {
  margin: 0 0 1.5rem;
  color: var(--muted);
  font-size: 0.61rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.section-head .eyebrow {
  grid-column: 1 / -1;
}

.section-head h2,
.about h2,
.contact h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(3.4rem, 7vw, 7.5rem);
  font-weight: 400;
  line-height: 0.9;
  letter-spacing: -0.055em;
}

.section-intro {
  align-self: end;
  max-width: 28rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.9;
}

.gallery {
  --book-gap: clamp(0.18rem, 0.55vw, 0.45rem);
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  gap: var(--book-gap);
  min-height: clamp(21rem, 35vw, 27rem);
  overflow-x: auto;
  overflow-y: hidden;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.gallery::-webkit-scrollbar {
  display: none;
}

.bookcase {
  width: min(100%, 64rem);
  margin: 0 auto;
}

.book {
  position: relative;
  display: flex;
  flex: 0 0 calc((100% - (var(--book-gap) * 4)) / 5);
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  width: auto;
  height: var(--book-height);
  padding: 0.8rem 0.4rem;
  color: var(--ink);
  background: transparent;
  border: 0;
  border-radius: 0;
  cursor: pointer;
  opacity: 0.68;
  scroll-snap-align: start;
  transition:
    color 220ms ease,
    opacity 220ms ease,
    transform 260ms var(--ease);
}

.book:not(:last-child)::after {
  position: absolute;
  top: 8%;
  right: calc(var(--book-gap) * -0.5);
  bottom: 8%;
  width: 1px;
  background: rgba(23, 24, 21, 0.24);
  content: "";
  pointer-events: none;
}

.book:nth-child(1) {
  --book-height: 19rem;
}

.book:nth-child(2) {
  --book-height: 23rem;
}

.book:nth-child(3) {
  --book-height: 20rem;
}

.book:nth-child(4) {
  --book-height: 25rem;
}

.book:nth-child(5) {
  --book-height: 21rem;
}

.book:nth-child(6) {
  --book-height: 24rem;
}

.book:nth-child(7) {
  --book-height: 21rem;
}

.book:nth-child(8) {
  --book-height: 18.5rem;
}

.book:nth-child(9) {
  --book-height: 22.5rem;
}

.book:nth-child(10) {
  --book-height: 20rem;
}

.book:hover {
  color: var(--accent);
  background: transparent;
  opacity: 1;
  transform: translateY(-0.45rem);
}

.book.is-selected {
  color: var(--accent);
  opacity: 1;
}

.book.is-selected .book-media img {
  filter: saturate(1) brightness(1);
}

.book.is-selected .book-number {
  color: var(--accent);
}

.book:focus-visible {
  color: var(--accent);
  opacity: 1;
}

.book-title {
  white-space: pre-line;
  font-size: 0.68rem;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  text-orientation: upright;
  writing-mode: vertical-rl;
}

.book-media {
  display: block;
  flex: 0 0 auto;
  width: 1.8rem;
  height: 7.5rem;
  overflow: hidden;
}

.book-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.72) brightness(0.72);
  transition: filter 240ms ease;
}

.book:hover .book-media img {
  filter: saturate(1) brightness(1);
}

.book-number {
  color: var(--muted);
  font-size: 0.52rem;
  letter-spacing: 0.08em;
}

.book:hover .book-number {
  color: var(--accent);
}

.shelf-lines {
  display: grid;
  justify-items: center;
  gap: 0.48rem;
  padding-top: 0.8rem;
}

.shelf-lines span {
  display: block;
  width: 100%;
  height: 1px;
  background: currentColor;
  opacity: 0.72;
}

.shelf-lines span:nth-child(2) {
  width: 84%;
  opacity: 0.58;
}

.shelf-lines span:nth-child(3) {
  width: 62%;
  opacity: 0.44;
}

.shelf-lines span:nth-child(4) {
  width: 38%;
  opacity: 0.3;
}

.book-detail {
  display: grid;
  gap: 0.7rem;
  max-width: 48rem;
  margin: 1.45rem auto 0;
  padding: 0 0.35rem;
}

.book-detail-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1.5rem;
}

.book-detail h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1.15rem, 2vw, 1.65rem);
  font-weight: 400;
}

.book-detail-head span {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 0.55rem;
  letter-spacing: 0.09em;
}

.book-detail p {
  max-width: 42rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.75rem;
  line-height: 1.8;
  white-space: pre-wrap;
}

.some-photos {
  width: min(100%, 100rem);
  margin: 0 auto;
  padding: clamp(4rem, 8vw, 7rem) calc(var(--pad) + 5.5rem)
    clamp(5rem, 9vw, 8rem) var(--pad);
  border-top: 1px solid var(--line);
}

.some-photos-upload {
  display: none;
  align-items: center;
  justify-content: center;
  width: max-content;
  margin-left: auto;
  margin-bottom: 1.5rem;
  padding: 0.72rem 1.15rem;
  color: var(--white);
  background: var(--ink);
  border: 1px solid var(--ink);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  cursor: pointer;
}

.some-photos-upload:hover {
  color: var(--white);
  background: var(--accent);
  border-color: var(--accent);
}

body.editor-mode .some-photos-upload {
  display: flex;
}

.some-photos-heading {
  display: grid;
  grid-template-columns: minmax(8rem, 0.3fr) minmax(0, 1fr);
  gap: 2rem;
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}

.some-photos-heading .eyebrow {
  margin: 0.4rem 0 0;
}

.some-photos-heading h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(3rem, 6.5vw, 7rem);
  font-weight: 400;
  line-height: 0.92;
}

.some-photos-heading > p:last-child {
  grid-column: 2;
  max-width: 26rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.8;
}

.some-photos-grid {
  display: flex;
  align-items: flex-start;
  gap: clamp(1.4rem, 3vw, 3.2rem);
  width: 100%;
  padding-bottom: 1rem;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-x: contain;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  touch-action: pan-x pan-y;
}

.some-photos-grid::-webkit-scrollbar {
  display: none;
}

.photo-group-card {
  display: grid;
  flex: 0 0 31rem;
  min-width: 0;
  padding: 0;
  color: var(--ink);
  background: transparent;
  border: 0;
  text-align: left;
  cursor: pointer;
  scroll-snap-align: center;
  transition:
    color 220ms ease,
    transform 320ms var(--ease);
}

.photo-group-card:nth-child(6n + 1) {
  flex-basis: 34rem;
}

.photo-group-card:nth-child(6n + 2) {
  flex-basis: 27rem;
}

.photo-group-card:nth-child(6n + 3) {
  flex-basis: 23rem;
}

.photo-group-card:nth-child(6n + 4) {
  flex-basis: 30rem;
}

.photo-group-card:nth-child(6n + 5) {
  flex-basis: 37rem;
}

.photo-group-card:nth-child(6n + 6) {
  flex-basis: 25rem;
}

.photo-group-card:hover,
.photo-group-card:focus-visible {
  color: var(--accent);
  transform: translateY(-0.35rem);
}

.photo-group-card[data-title-position="below"] {
  grid-template-areas:
    "visual"
    "title";
  grid-template-rows: auto auto;
  gap: 0.75rem;
}

.photo-group-card[data-title-position="top"] {
  grid-template-areas:
    "title"
    "visual";
  grid-template-rows: auto auto;
  gap: 0.75rem;
}

.photo-group-card[data-title-position="right"] {
  grid-template-areas: "visual title";
  grid-template-columns: minmax(0, 1fr) 4.8rem;
  align-items: end;
  gap: 0.8rem;
}

.photo-group-card[data-title-position="left"] {
  grid-template-areas: "title visual";
  grid-template-columns: 4.8rem minmax(0, 1fr);
  align-items: end;
  gap: 0.8rem;
}

.photo-group-visual {
  position: relative;
  grid-area: visual;
  display: block;
  width: 100%;
  min-height: 14rem;
  overflow: hidden;
  background: transparent;
  aspect-ratio: 4 / 3;
}

.photo-group-card:nth-child(3n + 2) .photo-group-visual {
  aspect-ratio: 1.12;
}

.photo-group-card:nth-child(3n) .photo-group-visual {
  aspect-ratio: 1 / 1;
}

.photo-group-image {
  position: absolute;
  display: block;
  overflow: hidden;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.photo-group-image::before {
  display: none;
}

.photo-group-image img {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.photo-group-title {
  grid-area: title;
  align-self: end;
  max-width: 100%;
  font-family: var(--serif);
  font-size: clamp(1.1rem, 1.8vw, 1.55rem);
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.some-photos-empty {
  margin: 0;
  padding: clamp(2rem, 6vw, 5rem) 0;
  color: var(--muted);
  font-size: 0.7rem;
  line-height: 1.8;
  text-align: center;
}

.some-photos-swipe-hint {
  display: none;
  margin: 0.85rem 0 0;
  color: var(--muted);
  font-size: 0.56rem;
  line-height: 1.4;
  letter-spacing: 0.06em;
}

.cosmos {
  width: min(100%, 100rem);
  margin: 0 auto;
  padding: clamp(4rem, 8vw, 7rem) calc(var(--pad) + 5.5rem)
    clamp(6rem, 11vw, 10rem) var(--pad);
  border-top: 1px solid var(--line);
}

.cosmos-heading {
  display: grid;
  grid-template-columns: minmax(8rem, 0.3fr) minmax(0, 1fr);
  gap: 2rem;
  margin-bottom: clamp(2.5rem, 5vw, 4.5rem);
}

.cosmos-heading .eyebrow {
  margin: 0.4rem 0 0;
}

.cosmos-heading-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(15rem, 0.45fr);
  align-items: end;
  gap: clamp(2rem, 5vw, 6rem);
}

.cosmos-heading h2 {
  max-width: 14ch;
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2.75rem, 5.3vw, 6.2rem);
  font-weight: 400;
  line-height: 0.92;
  letter-spacing: -0.055em;
}

.cosmos-heading-main > p {
  max-width: 25rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.85;
}

.cosmos-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1rem, 2vw, 1.8rem);
}

.cosmos-card {
  position: relative;
  min-width: 0;
  overflow: hidden;
  background: #e7e4dc;
}

.cosmos-card-sky,
.cosmos-card-stars {
  display: grid;
  grid-template-rows: minmax(18rem, 31vw) auto;
  color: var(--ink);
}

.cosmos-card-copy {
  display: grid;
  gap: 0.75rem;
  padding: 1.2rem 1.35rem 1.4rem;
}

.cosmos-card-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  padding: 0;
  font-family: var(--serif);
  font-size: clamp(1.55rem, 2.6vw, 2.65rem);
  line-height: 1;
  text-align: left;
  cursor: pointer;
}

.cosmos-card-title:hover,
.cosmos-card-title:focus-visible {
  color: var(--accent);
}

.cosmos-card-title.is-empty {
  cursor: default;
}

.cosmos-card-title > span:last-child:not(:first-child) {
  flex: 0 0 auto;
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.52rem;
  letter-spacing: 0.08em;
}

.cosmos-card-copy > p {
  max-width: 24rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.7;
}

.cosmos-sky-art {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 73% 26%, rgba(255, 252, 227, 0.94) 0 4%, transparent 17%),
    linear-gradient(180deg, #95a7ae 0%, #d3d2c8 58%, #eeeae0 100%);
}

.cosmos-sky-art::before,
.cosmos-sky-art::after,
.cosmos-sky-art span {
  position: absolute;
  display: block;
  background: rgba(243, 240, 233, 0.68);
  border-radius: 999px;
  content: "";
  filter: blur(1px);
}

.cosmos-sky-art::before {
  top: 24%;
  left: 11%;
  width: 42%;
  height: 18%;
  box-shadow:
    7rem 2rem 0 rgba(243, 240, 233, 0.48),
    15rem -0.8rem 0 rgba(243, 240, 233, 0.38);
}

.cosmos-sky-art::after {
  top: 54%;
  left: 42%;
  width: 34%;
  height: 14%;
  box-shadow:
    -10rem 1rem 0 rgba(243, 240, 233, 0.4),
    9rem 2.2rem 0 rgba(243, 240, 233, 0.34);
}

.cosmos-sky-art span {
  right: 8%;
  bottom: 0;
  width: 44%;
  height: 35%;
  border-radius: 50% 50% 0 0;
  background: rgba(40, 52, 53, 0.38);
  filter: blur(8px);
}

.cosmos-sky-art span:last-child {
  right: auto;
  bottom: -12%;
  left: -4%;
  width: 58%;
  height: 42%;
  background: rgba(55, 68, 67, 0.26);
}

.cosmos-stars-art {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 32%, #fff 0 0.08rem, transparent 0.16rem),
    radial-gradient(circle at 72% 18%, #fff 0 0.11rem, transparent 0.2rem),
    radial-gradient(circle at 39% 77%, #fff 0 0.07rem, transparent 0.14rem),
    radial-gradient(circle at 86% 62%, #fff 0 0.09rem, transparent 0.18rem),
    radial-gradient(circle at 59% 43%, #fff 0 0.06rem, transparent 0.12rem),
    radial-gradient(circle at 8% 83%, #fff 0 0.07rem, transparent 0.14rem),
    linear-gradient(145deg, #0a1118, #202b31 58%, #536168);
}

.cosmos-stars-art::before {
  position: absolute;
  top: 16%;
  left: 9%;
  width: 78%;
  height: 58%;
  background-image:
    radial-gradient(circle, rgba(255, 255, 255, 0.86) 0 1px, transparent 1.5px),
    radial-gradient(circle, rgba(255, 255, 255, 0.4) 0 1px, transparent 1.4px);
  background-position: 0 0, 1.4rem 2rem;
  background-size: 4.7rem 4.2rem, 6.3rem 5.4rem;
  content: "";
  mask-image: linear-gradient(to bottom, transparent, #000 20%, #000 75%, transparent);
}

.cosmos-stars-art span:first-child {
  position: absolute;
  right: 15%;
  bottom: 12%;
  width: 1px;
  height: 44%;
  background: linear-gradient(transparent, rgba(255, 255, 255, 0.8));
  transform: rotate(36deg);
}

.cosmos-stars-art span:last-child {
  position: absolute;
  right: 11%;
  bottom: 7%;
  width: 4.5rem;
  height: 4.5rem;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 50%;
}

.cosmos-edit-button {
  display: none;
  width: max-content;
  padding: 0.45rem 0;
  color: var(--accent);
  border-bottom: 1px solid currentColor;
  font-size: 0.58rem;
  letter-spacing: 0.06em;
  cursor: pointer;
}

body.editor-mode .cosmos-edit-button {
  display: block;
}

.cosmos-card-moon {
  grid-column: 1 / -1;
  padding: clamp(1.35rem, 3vw, 2.5rem);
  color: var(--white);
  background:
    radial-gradient(circle at 88% 6%, rgba(237, 233, 215, 0.12), transparent 20rem),
    #171b1c;
}

.moon-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.moon-kicker {
  margin: 0 0 0.55rem;
  color: rgba(255, 253, 248, 0.48);
  font-size: 0.52rem;
  letter-spacing: 0.16em;
}

.moon-title {
  width: auto;
  color: var(--white);
  font-size: clamp(2rem, 4.2vw, 4.5rem);
}

.moon-title:hover,
.moon-title:focus-visible {
  color: #e9dfbb;
}

.moon-title > span:last-child:not(:first-child) {
  color: rgba(255, 253, 248, 0.5);
}

.moon-orbit {
  position: relative;
  flex: 0 0 auto;
  width: clamp(4.5rem, 8vw, 7.5rem);
  height: clamp(4.5rem, 8vw, 7.5rem);
  border: 1px solid rgba(255, 253, 248, 0.22);
  border-radius: 50%;
}

.moon-orbit::before {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 44%;
  height: 44%;
  background: #e7dfbf;
  border-radius: 50%;
  box-shadow: 0 0 2.5rem rgba(231, 223, 191, 0.24);
  content: "";
  transform: translate(-50%, -50%);
}

.moon-orbit::after {
  position: absolute;
  inset: 13%;
  border: 1px dashed rgba(255, 253, 248, 0.2);
  border-radius: 50%;
  content: "";
  transform: rotate(20deg) scaleY(0.42);
}

.moon-intro {
  max-width: 32rem;
  margin: 1rem 0 2rem;
  color: rgba(255, 253, 248, 0.6);
  font-size: 0.76rem;
  line-height: 1.75;
}

.moon-filters {
  display: grid;
  grid-template-columns: minmax(8rem, 0.25fr) minmax(11rem, 0.35fr) minmax(14rem, 1fr) minmax(9rem, 0.3fr) auto;
  align-items: end;
  gap: 0.8rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1.2rem;
  border-bottom: 1px solid rgba(255, 253, 248, 0.18);
}

.moon-filters label {
  display: grid;
  gap: 0.42rem;
  color: rgba(255, 253, 248, 0.5);
  font-size: 0.52rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.moon-filters select,
.moon-filters input {
  width: 100%;
  height: 2.4rem;
  padding: 0 0.65rem;
  color: var(--white);
  background: rgba(255, 253, 248, 0.07);
  border: 1px solid rgba(255, 253, 248, 0.22);
  border-radius: 0;
  font: inherit;
  font-size: 0.7rem;
  outline: none;
}

.moon-filters select:focus,
.moon-filters input:focus {
  border-color: rgba(255, 253, 248, 0.7);
}

.moon-filters select:disabled,
.moon-filters input:disabled,
.moon-filters button:disabled {
  cursor: not-allowed;
  opacity: 0.42;
}

.moon-filters select option {
  color: var(--ink);
  background: var(--paper);
}

.moon-clear {
  height: 2.4rem;
  padding: 0 0.9rem;
  color: rgba(255, 253, 248, 0.82);
  border: 1px solid rgba(255, 253, 248, 0.22);
  font-size: 0.6rem;
  cursor: pointer;
}

.moon-clear:hover {
  color: var(--ink);
  background: var(--white);
}

.moon-results-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 1.8rem;
  margin-bottom: 1rem;
  color: rgba(255, 253, 248, 0.55);
  font-size: 0.56rem;
  letter-spacing: 0.1em;
}

.moon-results-head .cosmos-edit-button {
  margin-left: auto;
  color: #e7dfbf;
}

.moon-results {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.7rem;
}

.moon-card {
  display: grid;
  gap: 0.7rem;
  min-width: 0;
  padding: 0;
  color: var(--white);
  text-align: left;
  cursor: pointer;
}

.moon-card-image {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: rgba(255, 253, 248, 0.07);
}

.moon-card-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition:
    filter 280ms ease,
    transform 500ms var(--ease);
}

.moon-card:hover .moon-card-image img,
.moon-card:focus-visible .moon-card-image img {
  filter: brightness(1.08);
  transform: scale(1.025);
}

.moon-card-image.is-placeholder::before {
  display: block;
  padding: 45% 1rem;
  color: rgba(255, 253, 248, 0.34);
  content: "MOON";
  font-size: 0.55rem;
  letter-spacing: 0.2em;
  text-align: center;
}

.moon-card-meta {
  display: grid;
  gap: 0.2rem;
  color: rgba(255, 253, 248, 0.5);
  font-size: 0.55rem;
  line-height: 1.45;
}

.moon-card-meta strong {
  overflow: hidden;
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.moon-card-meta time {
  color: #e7dfbf;
  letter-spacing: 0.06em;
}

.moon-empty {
  margin: 0;
  padding: clamp(2rem, 6vw, 5rem) 0;
  color: rgba(255, 253, 248, 0.46);
  font-size: 0.7rem;
  line-height: 1.8;
  text-align: center;
}

.sky-module .cosmos-heading h2 {
  max-width: none;
}

.sky-module .cosmos-heading {
  display: block;
  margin-bottom: clamp(2.2rem, 4vw, 3.5rem);
}

.sky-module .cosmos-heading .eyebrow {
  margin: 0;
}

.sky-line-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.2rem, 3vw, 3.5rem);
}

.sky-line-card {
  display: grid;
  gap: 1.1rem;
  min-width: 0;
  padding: 0;
  color: var(--ink);
  background: transparent;
  border: 0;
  text-align: left;
  cursor: pointer;
}

.sky-line-art {
  display: block;
  width: 100%;
  aspect-ratio: 320 / 220;
  overflow: hidden;
  color: var(--ink);
  background: transparent;
  transition:
    color 260ms ease,
    transform 420ms var(--ease);
}

.sky-line-art svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.25;
}

.sky-line-art .line-soft {
  opacity: 0.42;
}

.sky-line-art .line-dashed {
  stroke-dasharray: 4 7;
  opacity: 0.62;
}

.sky-line-card:hover .sky-line-art,
.sky-line-card:focus-visible .sky-line-art {
  color: var(--accent);
  transform: translateY(-0.35rem);
}

.sky-line-label {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--line);
  font-family: var(--serif);
  font-size: clamp(1.35rem, 2.2vw, 2.15rem);
  line-height: 1;
}

.sky-line-label > span:last-child:not(:first-child) {
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.55rem;
  letter-spacing: 0.08em;
}

body.editor-mode .sky-line-card {
  outline: 1px dashed rgba(191, 75, 43, 0.58);
  outline-offset: 0.55rem;
}

.moon-calendar {
  margin-top: clamp(4rem, 8vw, 7rem);
  padding-top: clamp(1.8rem, 3.5vw, 3rem);
  color: var(--ink);
  background: transparent;
  border-top: 1px solid var(--line);
}

.sky-module .moon-calendar {
  margin-top: 0;
}

.moon-calendar-head {
  display: grid;
  grid-template-columns: minmax(15rem, 0.55fr) minmax(16rem, 1fr);
  align-items: end;
  gap: 2rem;
  margin-bottom: 2rem;
}

.moon-kicker {
  margin: 0 0 0.6rem;
  color: var(--muted);
  font-size: 0.52rem;
  letter-spacing: 0.16em;
}

.moon-calendar-head h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2rem, 4vw, 4.2rem);
  font-weight: 400;
  line-height: 0.95;
}

.moon-intro {
  justify-self: end;
  max-width: 30rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.75rem;
  line-height: 1.75;
}

.moon-filters {
  grid-template-columns: minmax(8rem, 0.25fr) minmax(11rem, 0.35fr) minmax(14rem, 1fr) minmax(9rem, 0.3fr) auto;
  padding-bottom: 1.1rem;
  border-bottom: 1px solid var(--line);
}

.moon-filters label {
  color: var(--muted);
}

.moon-filters select,
.moon-filters input {
  color: var(--ink);
  background: transparent;
  border-color: var(--line);
}

.moon-filters select:focus,
.moon-filters input:focus {
  border-color: var(--ink);
}

.moon-filters select option {
  color: var(--ink);
  background: var(--paper);
}

.moon-clear {
  color: var(--ink);
  background: transparent;
  border-color: var(--line);
}

.moon-clear:hover {
  color: var(--white);
  background: var(--ink);
}

.moon-results-head {
  color: var(--muted);
}

.moon-card {
  color: var(--ink);
}

.moon-card-image {
  background: transparent;
}

.moon-card-meta {
  color: var(--muted);
}

.moon-card-meta strong {
  color: var(--ink);
}

.moon-card-meta time {
  color: var(--accent);
}

.moon-empty {
  color: var(--muted);
}

.moon-add-photos {
  display: none;
  align-items: center;
  justify-content: center;
  width: max-content;
  margin: -1.6rem auto 3rem;
  padding: 0.72rem 1.15rem;
  color: var(--white);
  background: var(--ink);
  border: 1px solid var(--ink);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  cursor: pointer;
}

.moon-add-photos:hover {
  color: var(--white);
  background: var(--accent);
  border-color: var(--accent);
}

body.editor-mode .moon-add-photos:not([hidden]) {
  display: flex;
}

.album-viewer {
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  margin: 0;
  padding: clamp(1.25rem, 4vw, 3rem);
  color: var(--white);
  background: rgba(8, 14, 19, 0.98);
  border: 0;
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  touch-action: pan-y;
}

html[lang="zh-CN"] .album-viewer,
html[lang="en"] .album-viewer {
  font-family: var(--sans);
}

.album-viewer button,
.album-viewer input,
.album-viewer textarea,
.album-viewer select {
  font-family: inherit;
}

.album-header h2,
.album-caption h3 {
  font-family: var(--serif);
}

.album-viewer::backdrop {
  background: rgba(8, 14, 19, 0.92);
}

.album-shell {
  display: grid;
  gap: 0.8rem;
  width: min(100%, 64rem);
  margin: 0 auto;
}

.album-header {
  position: relative;
  display: flex;
  align-items: baseline;
  gap: 1.25rem;
  padding-right: 3rem;
}

.album-kicker {
  margin: 0;
  color: rgba(255, 253, 248, 0.5);
  font-size: 0.56rem;
  letter-spacing: 0.16em;
}

.album-header h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1.5rem, 3vw, 2.4rem);
  font-weight: 400;
}

.album-close {
  position: absolute;
  top: 0;
  right: 0;
  width: 2.4rem;
  height: 2.4rem;
  padding: 0;
  cursor: pointer;
}

.album-close span {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 1.35rem;
  height: 1px;
  background: currentColor;
  transform: translate(-50%, -50%) rotate(45deg);
}

.album-close span:last-child {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.album-stage {
  display: grid;
  grid-template-columns: 3rem minmax(0, 1fr) 3rem;
  align-items: center;
  gap: 1rem;
  perspective: 1600px;
}

.album-page {
  position: relative;
  isolation: isolate;
  display: grid;
  gap: 0.9rem;
  min-height: 0;
  padding: clamp(1rem, 2.5vw, 2rem);
  overflow: hidden;
  color: var(--ink);
  background: #f7f4ed;
  box-shadow: 0 1.8rem 5rem rgba(0, 0, 0, 0.36);
  transform-origin: left center;
  scrollbar-width: none;
}

.album-page::-webkit-scrollbar {
  display: none;
}

.album-page::-webkit-scrollbar-track,
.album-page::-webkit-scrollbar-corner {
  background: transparent;
}

.album-page::-webkit-scrollbar-thumb {
  background: rgba(23, 24, 21, 0.34);
  border-radius: 999px;
}

.album-page[data-background="black"]::-webkit-scrollbar-thumb,
.album-page[data-background="glass"]::-webkit-scrollbar-thumb {
  background: rgba(255, 253, 248, 0.34);
}

.album-page[data-background="white"] {
  color: var(--ink);
  background: #ffffff;
}

.album-page[data-background="black"] {
  color: var(--white);
  background: #080908;
}

.album-page[data-background="glass"] {
  color: var(--white);
  background: #1b252a;
}

.album-page-background {
  position: absolute;
  z-index: -2;
  inset: -12%;
  display: none;
  background-position: center;
  background-size: cover;
  filter: blur(28px) saturate(0.82) brightness(0.65);
  transform: scale(1.12);
  pointer-events: none;
}

.album-page[data-background="glass"] .album-page-background {
  display: block;
}

.album-page[data-background="glass"]::before {
  position: absolute;
  z-index: -1;
  inset: 0;
  background: rgba(18, 26, 31, 0.28);
  backdrop-filter: blur(18px) saturate(112%);
  content: "";
  pointer-events: none;
}

.album-page[data-background="black"] .album-details,
.album-page[data-background="black"] .album-caption p,
.album-page[data-background="black"] .album-page-metadata p > span,
.album-page[data-background="glass"] .album-details,
.album-page[data-background="glass"] .album-caption p,
.album-page[data-background="glass"] .album-page-metadata p > span {
  color: rgba(255, 253, 248, 0.72);
}

.album-page[data-background="black"] .album-details,
.album-page[data-background="glass"] .album-details {
  border-bottom-color: rgba(255, 253, 248, 0.2);
}

.album-page.turn-forward {
  animation: page-forward 900ms cubic-bezier(0.18, 0.8, 0.2, 1);
}

.album-page.turn-backward {
  animation: page-backward 900ms cubic-bezier(0.18, 0.8, 0.2, 1);
}

.album-photo {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: min(55vh, 36rem);
  margin-inline: auto;
  overflow: hidden;
  background: transparent;
  border: 0;
  transition:
    width 220ms var(--ease),
    height 220ms var(--ease);
}

.album-image-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.album-photo img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.album-image-resize {
  position: absolute;
  right: 0.15rem;
  bottom: 0.15rem;
  display: none;
  width: 3rem;
  height: 3rem;
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  color: var(--ink);
  cursor: nwse-resize;
  opacity: 0;
  touch-action: none;
}

.album-image-resize svg {
  display: block;
  width: 1.7rem;
  height: 1.7rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.5;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.22));
}

body.editor-mode .album-image-resize {
  display: grid;
  opacity: 1;
  place-items: center;
}

.album-page[data-background="black"] .album-image-resize,
.album-page[data-background="glass"] .album-image-resize {
  color: var(--white);
}

.album-photo.is-resizing {
  transition: none;
}

.album-caption {
  display: grid;
  gap: 0.55rem;
}

.album-caption .album-details {
  padding-bottom: 0.45rem;
  color: var(--ink);
  border-bottom: 1px solid var(--line);
  font-size: 0.92rem;
  line-height: 1.8;
}

.album-caption h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1.4rem, 3vw, 2.5rem);
  font-weight: 400;
  line-height: 1.05;
}

.album-caption p {
  max-width: 48rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.8;
  white-space: pre-wrap;
}

.album-caption time {
  color: var(--accent);
  font-size: 0.58rem;
  letter-spacing: 0.08em;
}

.album-page-metadata {
  display: grid;
  gap: 0.2rem;
}

.album-page-metadata p {
  display: flex;
  gap: 0.45rem;
  margin: 0;
  font-size: 0.68rem;
  line-height: 1.65;
}

.album-page-metadata p > span:first-child {
  flex: 0 0 auto;
  color: var(--muted);
  letter-spacing: 0.06em;
}

.album-page-metadata p > span:last-child {
  color: var(--ink);
  white-space: pre-wrap;
}

.album-side-nav {
  display: grid;
  width: 2.8rem;
  height: 2.8rem;
  padding: 0;
  color: var(--white);
  cursor: pointer;
  place-items: center;
  opacity: 0.7;
}

.album-side-nav:disabled {
  cursor: default;
  opacity: 0.18;
}

.album-side-nav svg {
  width: 1.2rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.4;
}

.album-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 0.15rem;
  color: rgba(255, 253, 248, 0.54);
  font-size: 0.58rem;
  letter-spacing: 0.12em;
}

.album-nav-copy,
.album-swipe-hint {
  display: none;
}

.album-admin-editor {
  display: grid;
  gap: 1rem;
  padding: 1.25rem;
  border: 1px solid rgba(255, 253, 248, 0.18);
  background: rgba(255, 253, 248, 0.05);
}

.album-admin-editor[hidden] {
  display: none;
}

.album-editor-head,
.album-editor-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.album-editor-head h3 {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
}

.album-editor-head > div {
  display: flex;
  gap: 0.5rem;
}

.album-admin-editor button {
  padding: 0.6rem 0.8rem;
  border: 1px solid rgba(255, 253, 248, 0.28);
  border-radius: 999px;
  font-size: 0.6rem;
  cursor: pointer;
}

.album-editor-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.8rem;
}

.album-editor-grid label {
  display: grid;
  gap: 0.35rem;
  color: rgba(255, 253, 248, 0.62);
  font-size: 0.58rem;
  letter-spacing: 0.05em;
}

.album-editor-grid input,
.album-editor-grid textarea,
.album-editor-grid select {
  width: 100%;
  padding: 0.65rem;
  color: var(--white);
  background: rgba(255, 253, 248, 0.08);
  border: 1px solid rgba(255, 253, 248, 0.2);
  border-radius: 0;
  font: inherit;
  resize: vertical;
}

.album-editor-grid select {
  appearance: none;
}

.album-editor-actions {
  justify-content: flex-end;
}

.album-editor-actions span {
  margin-right: auto;
  color: rgba(255, 253, 248, 0.6);
  font-size: 0.58rem;
}

.album-editor-actions span[data-state="success"] {
  color: #b8e2c4;
}

.album-editor-actions span[data-state="error"] {
  color: #f3b7a9;
}

.album-scale-hint {
  margin: 0;
  color: rgba(255, 253, 248, 0.52);
  font-size: 0.56rem;
  line-height: 1.65;
}

@keyframes page-forward {
  from {
    opacity: 0.4;
    transform: perspective(80rem) rotateY(-9deg) translateX(1.2rem);
  }
  to {
    opacity: 1;
    transform: perspective(80rem) rotateY(0) translateX(0);
  }
}

@keyframes page-backward {
  from {
    opacity: 0.4;
    transform: perspective(80rem) rotateY(9deg) translateX(-1.2rem);
  }
  to {
    opacity: 1;
    transform: perspective(80rem) rotateY(0) translateX(0);
  }
}

.photo {
  display: grid;
  width: 100%;
  padding: 0;
  text-align: left;
  cursor: zoom-in;
}

.photo-feature {
  grid-column: 1 / -1;
}

.photo-media {
  display: block;
  overflow: hidden;
  background: var(--paper-deep);
  aspect-ratio: 4 / 3;
}

.photo-feature .photo-media {
  aspect-ratio: 16 / 8.5;
}

.photo-tall .photo-media {
  aspect-ratio: 4 / 5;
}

.photo-media img {
  height: 100%;
  object-fit: cover;
  transition:
    transform 800ms var(--ease),
    filter 500ms ease;
}

.photo:hover .photo-media img {
  transform: scale(1.025);
}

.photo-caption {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 0.85rem;
  color: var(--muted);
  font-size: 0.59rem;
  letter-spacing: 0.06em;
}

.placeholder-note {
  margin: 3.5rem 0 0;
  padding-top: 1rem;
  color: var(--muted);
  border-top: 1px solid var(--line);
  font-size: 0.57rem;
}

.about {
  position: relative;
  display: grid;
  min-height: max(40rem, 100svh);
  padding: 0;
  color: var(--ink);
  background: var(--paper);
  overflow: hidden;
  place-items: center;
}

.about-background {
  position: absolute;
  z-index: 0;
  top: 50%;
  left: 50%;
  width: auto;
  height: auto;
  max-width: min(20cm, calc(100% - (var(--pad) * 2) - 5.5rem));
  max-height: min(10cm, 55svh);
  object-fit: contain;
  border: 0;
  image-orientation: none;
  transform: translate(-50%, -50%);
}

.about::after {
  display: none;
}

.about-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(2rem, 5vw, 5rem) calc(var(--pad) + 5.5rem)
    clamp(2rem, 5vw, 4.5rem) var(--pad);
  color: var(--ink);
}

.about-bottom {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
}

.about-caption {
  margin: 0;
  color: var(--ink);
  font-size: 0.6rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.about-caption span {
  display: block;
}

.about-caption span:last-child {
  margin-top: 0.45rem;
  color: var(--muted);
  font-size: 0.53rem;
  line-height: 1.55;
  letter-spacing: 0.05em;
  text-transform: none;
}

.about-statement {
  max-width: 38rem;
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1.2rem, 2.3vw, 2.5rem);
  line-height: 1.35;
  letter-spacing: -0.03em;
  text-align: left;
  color: var(--ink);
}

.about-statement > span {
  display: block;
}

.about-statement-indent {
  margin-left: 3em;
}

.about .eyebrow {
  color: var(--ink);
  opacity: 0.58;
}

.about-content {
  display: grid;
  grid-template-columns: minmax(15rem, 0.68fr) minmax(0, 1fr);
  align-items: end;
  gap: clamp(3rem, 7vw, 8rem);
}

.about-portrait {
  margin: 0;
}

.about-portrait img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: 32% center;
  filter: saturate(0.9) brightness(0.88);
}

.about-portrait figcaption {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 0.8rem;
  color: rgba(255, 253, 248, 0.52);
  border-top: 1px solid rgba(255, 253, 248, 0.22);
  font-size: 0.57rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.about-portrait figcaption span:first-child {
  color: rgba(255, 253, 248, 0.82);
}

.about-story {
  display: grid;
  gap: clamp(2rem, 4vw, 3.5rem);
  align-content: end;
}

.about h2 {
  font-size: clamp(3.2rem, 5.5vw, 6.2rem);
}

.about-copy {
  display: grid;
  gap: 1.2rem;
  max-width: 28rem;
  color: rgba(255, 253, 248, 0.66);
  font-size: 0.82rem;
  line-height: 1.9;
}

.about-copy p {
  margin: 0;
}

.contact {
  display: grid;
  grid-template-columns: minmax(8rem, 0.35fr) minmax(0, 1fr);
  gap: 3rem;
  background: var(--paper);
  border: 0;
}

.contact-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(23rem, 0.55fr);
  align-items: end;
  gap: clamp(3rem, 7vw, 8rem);
}

.contact h2 {
  font-size: clamp(3rem, 4.8vw, 6rem);
}

.contact h2 span {
  display: block;
  white-space: nowrap;
}

.contact h2 span + span {
  margin-top: 0.16em;
}

.contact-content > div:last-child > p {
  margin: 0 0 1.2rem;
  color: var(--muted);
  font-size: 0.78rem;
}

.contact-content a {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding-bottom: 0.25rem;
  border-bottom: 1px solid var(--ink);
  font-family: var(--serif);
  font-size: clamp(1rem, 1.55vw, 1.45rem);
  overflow-wrap: anywhere;
}

.site-footer {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 2rem;
  padding: 2.4rem calc(var(--pad) + 5.5rem) 2.4rem var(--pad);
  color: rgba(255, 253, 248, 0.65);
  background: var(--ink);
  font-size: 0.57rem;
  letter-spacing: 0.08em;
}

.site-footer a:first-child {
  color: var(--white);
  font-family: var(--serif);
  font-size: 1.1rem;
}

.site-footer > a:last-child {
  justify-self: end;
}

.site-footer > span {
  justify-self: end;
}

.site-footer a:hover {
  color: var(--white);
}

.footer-notice {
  grid-column: 1 / -1;
  justify-self: center;
  max-width: 64rem;
  margin: 0;
  padding-top: 1.25rem;
  color: rgba(255, 253, 248, 0.46);
  border-top: 1px solid rgba(255, 253, 248, 0.14);
  font-size: 0.61rem;
  line-height: 1.8;
  letter-spacing: 0.04em;
  text-align: center;
}

.lightbox {
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  margin: 0;
  padding: 4rem clamp(1rem, 5vw, 5rem) 2rem;
  color: var(--white);
  background: rgba(12, 13, 11, 0.97);
  border: 0;
}

.lightbox::backdrop {
  background: rgba(12, 13, 11, 0.92);
}

.lightbox-shell,
.lightbox {
  --nav-size: 3.2rem;
}

.lightbox > figure {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  width: 100%;
  height: 100%;
  margin: 0;
}

.lightbox figure img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
}

.lightbox figcaption {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  max-width: 80rem;
  margin: 0 auto;
  padding-top: 1rem;
  width: 100%;
  color: rgba(255, 253, 248, 0.6);
  font-size: 0.6rem;
  letter-spacing: 0.08em;
}

.lightbox figcaption > span:first-child {
  color: var(--white);
  font-family: var(--serif);
  font-size: 1.1rem;
}

.lightbox-close {
  position: absolute;
  z-index: 2;
  top: 1.25rem;
  right: 1.4rem;
  width: 2.8rem;
  height: 2.8rem;
  padding: 0;
  cursor: pointer;
}

.lightbox-close span {
  position: absolute;
  top: 50%;
  left: 50%;
  display: block;
  width: 1.5rem;
  height: 1px;
  background: var(--white);
  transform: translate(-50%, -50%) rotate(45deg);
}

.lightbox-close span:last-child {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.lightbox-nav {
  position: absolute;
  z-index: 2;
  top: 50%;
  display: grid;
  width: var(--nav-size);
  height: var(--nav-size);
  padding: 0;
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  cursor: pointer;
  transform: translateY(-50%);
  place-items: center;
  transition:
    color 200ms ease,
    background-color 200ms ease;
}

.lightbox-nav:hover {
  color: var(--ink);
  background: var(--white);
}

.lightbox-nav svg {
  width: 1.2rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.3;
}

.lightbox-prev {
  left: 1rem;
}

.lightbox-next {
  right: 1rem;
}

@keyframes hero-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@media (max-width: 820px) {
  .contact-content {
    grid-template-columns: 1fr;
  }

  .cosmos-heading {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .cosmos-heading-main {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .sky-line-grid {
    gap: 1.5rem;
  }

  .moon-calendar-head {
    grid-template-columns: 1fr;
    align-items: start;
    gap: 1rem;
  }

  .moon-intro {
    justify-self: start;
  }

  .moon-filters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .moon-results {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .hero-cta {
    justify-content: flex-end;
  }

  .hero {
    grid-template-columns: minmax(20rem, 52vw) minmax(15rem, 1fr);
  }

  .hero-layout {
    grid-template-columns: minmax(20rem, 52vw) minmax(15rem, 1fr);
  }

  .hero-media {
    height: auto;
    min-height: 0;
    padding: 0;
  }

  .hero-overlay {
    height: 100%;
    min-height: 0;
    padding: 7rem 5.8rem 1.5rem 1rem;
  }

  .section-intro {
    justify-self: start;
  }

  .contact {
    grid-template-columns: 1fr;
  }

  .contact-content {
    gap: 2.5rem;
  }
}

@media (max-width: 580px) {
  :root {
    font-size: 112.5%;
    --pad: 1.2rem;
  }

  html,
  body {
    touch-action: pan-x pan-y;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
  }

  .site-header {
    width: 4.2rem;
    height: 100svh;
    min-height: 0;
    align-items: flex-start;
    justify-content: center;
    padding: 1rem 0.35rem;
  }

  .site-mark {
    bottom: max(0.55rem, env(safe-area-inset-bottom));
    left: max(0.65rem, env(safe-area-inset-left));
    width: 2.25rem;
  }

  .hero-swipe-hint {
    display: block;
    bottom: 0.6rem;
    left: var(--hero-swipe-hint-left, 0);
    font-size: 0.56rem;
  }

  .wordmark {
    font-size: 2.7rem;
  }

  .site-header nav {
    gap: 1.5rem;
  }

  .header-actions {
    gap: 1.8rem;
  }

  .language-switch {
    min-width: 0;
    padding: 0.3rem 0;
    font-size: 0.52rem;
  }

  .site-header nav a {
    font-size: 0.58rem;
  }

  .hero-overlay {
    grid-column: auto;
    grid-row: 2;
    min-height: 100svh;
    height: 100svh;
    align-items: flex-start;
    justify-content: center;
    gap: clamp(2.3rem, 7vh, 4.5rem);
    padding: 4.6rem 5rem 4.2rem var(--pad);
  }

  .hero-quote {
    position: relative;
    top: auto;
    left: auto;
    width: min(16rem, 68vw);
    margin: 0;
    font-size: 14px;
    line-height: 1.4;
    transform: none;
  }

  html[lang="en"] .brand-lockup {
    gap: 0.7rem;
  }

  html[lang="en"] .wordmark {
    font-size: 2.15rem;
    line-height: 0.95;
  }

  html[lang="en"] .brand-side {
    gap: 0.75rem;
    width: 100%;
  }

  html[lang="en"] .brand-kicker {
    flex: 0 0 auto;
    width: 4.5rem;
    font-size: 0.4rem;
    line-height: 1.25;
  }

  html[lang="en"] .hero-quote {
    width: min(16rem, 68vw);
    font-size: 14px;
    line-height: 1.4;
  }

  .hero {
    height: auto;
    min-height: 0;
    overflow: visible;
  }

  .hero-layout {
    grid-template-columns: 1fr;
    grid-template-rows: 100svh 100svh;
    height: 200svh;
  }

  .hero-visual {
    grid-row: 1;
    height: 100svh;
    grid-template-rows: minmax(0, 1fr) auto;
    background: transparent;
  }

  .hero-media {
    grid-column: auto;
    height: auto;
    min-height: 0;
    padding: 0;
  }

  .hero-media img {
    width: 100%;
    max-height: none;
  }

  .hero-stack-item,
  .hero-stack-item.is-active {
    top: 0.85rem;
    left: 0.75rem;
    width: calc(100% - 5rem);
    height: calc(100% - 6.2rem);
    background: transparent;
    border: 0;
    box-shadow: none;
    backdrop-filter: none;
  }

  .hero-stack-item:not(.is-active) {
    opacity: 0;
  }

  .hero-stack-item img,
  .hero-stack-item.is-active img,
  .hero-stack-station img {
    background: transparent;
    border: 0;
    box-shadow: none;
  }

  .hero-photo-credit {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: auto;
    bottom: auto;
    left: 0;
    max-width: 100%;
    width: 100%;
    margin: 0;
    padding: 0;
    background: transparent;
    border: 0;
    font-size: 0.52rem;
    line-height: 1.4;
    text-align: left;
    text-orientation: mixed;
    white-space: normal;
    writing-mode: horizontal-tb;
  }

  html[lang="en"] .hero-photo-credit {
    width: 100%;
    max-width: 100%;
    font-size: 0.5rem;
  }

  .hero-photo-credit.hero-photo-credit-below {
    right: auto;
    top: calc(100% + 0.5rem);
    bottom: auto;
    left: 0;
    width: 100%;
    max-width: 100%;
    padding-top: 0.2rem;
    font-size: 0.54rem;
    line-height: 1.45;
    text-orientation: mixed;
    white-space: normal;
    writing-mode: horizontal-tb;
  }

  .hero-stack-credits {
    gap: 0.1rem;
    padding: 0.4rem var(--pad) 0.55rem;
  }

  .hero-cta {
    position: relative;
    right: auto;
    bottom: auto;
    align-self: flex-start;
    justify-content: flex-start;
  }

  .hero-swipe-hint {
    left: max(
      calc(var(--hero-swipe-hint-left, 0px) + 2.7rem),
      2.7rem
    );
    bottom: 0.72rem;
  }

  .work,
  .cosmos,
  .about,
  .contact {
    padding-top: 5.5rem;
    padding-bottom: 5.5rem;
  }

  .work,
  .cosmos,
  .contact {
    padding-right: calc(var(--pad) + 4.2rem);
  }

  .cosmos {
    padding-top: 4rem;
    padding-bottom: 5.5rem;
  }

  .cosmos-heading h2 {
    font-size: clamp(2.65rem, 13vw, 4.5rem);
  }

  .cosmos-grid {
    grid-template-columns: 1fr;
  }

  .sky-line-grid {
    grid-template-columns: 1fr;
    gap: 2.8rem;
  }

  .sky-line-art {
    aspect-ratio: 320 / 205;
  }

  .sky-line-label {
    font-size: clamp(1.55rem, 8vw, 2.2rem);
  }

  .moon-calendar {
    margin-top: 4rem;
    padding-top: 1.8rem;
  }

  .moon-calendar-head h3 {
    font-size: clamp(2.25rem, 12vw, 3.7rem);
  }

  .cosmos-card-sky,
  .cosmos-card-stars {
    grid-template-rows: minmax(14rem, 62vw) auto;
  }

  .cosmos-card-copy {
    padding: 1rem 1rem 1.2rem;
  }

  .cosmos-card-title {
    font-size: clamp(1.6rem, 8vw, 2.2rem);
  }

  .cosmos-card-moon {
    grid-column: auto;
    padding: 1.15rem 1rem 1.5rem;
  }

  .moon-heading {
    align-items: flex-start;
  }

  .moon-title {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.4rem;
    font-size: clamp(2.1rem, 11vw, 3.3rem);
  }

  .moon-orbit {
    width: 4rem;
    height: 4rem;
  }

  .moon-filters {
    grid-template-columns: 1fr;
  }

  .moon-clear {
    width: 100%;
  }

  .moon-results {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem 0.65rem;
  }

  .moon-card-meta {
    font-size: 0.5rem;
  }

  .about {
    padding: 0;
  }

  .contact {
    border: 0;
  }

  .about-overlay {
    padding: 1.25rem 4.9rem 1.25rem var(--pad);
  }

  .about-bottom {
    align-items: flex-end;
    gap: 1rem;
  }

  .about-caption {
    font-size: 0.52rem;
  }

  .about-statement {
    max-width: 62%;
    font-size: clamp(0.82rem, 4.2vw, 1.2rem);
  }

  .section-head h2,
  .about h2,
  .contact h2 {
    font-size: clamp(3rem, 15vw, 4.7rem);
  }

  .about h2 {
    font-size: clamp(2.65rem, 13vw, 4rem);
  }

  .gallery {
    --book-gap: 0.36rem;
    gap: var(--book-gap);
    min-height: 20rem;
  }

  .book {
    padding: 0.75rem 0.32rem;
  }

  .book:nth-child(1) {
    --book-height: 15.5rem;
  }

  .book:nth-child(2) {
    --book-height: 18rem;
  }

  .book:nth-child(3) {
    --book-height: 16rem;
  }

  .book:nth-child(4) {
    --book-height: 19rem;
  }

  .book:nth-child(5) {
    --book-height: 17rem;
  }

  .book:nth-child(6) {
    --book-height: 18.5rem;
  }

  .book:nth-child(7) {
    --book-height: 16.5rem;
  }

  .book:nth-child(8) {
    --book-height: 15rem;
  }

  .book:nth-child(9) {
    --book-height: 18rem;
  }

  .book:nth-child(10) {
    --book-height: 16rem;
  }

  .book-title {
    font-size: 0.6rem;
  }

  .album-viewer {
    padding: 0.5rem 0.55rem 0;
    height: 100svh;
    max-height: 100svh;
    overflow: hidden;
  }

  .album-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.35rem;
  }

  .album-shell {
    height: 100%;
    gap: 0.45rem;
    grid-template-rows: auto minmax(0, 1fr);
  }

  .album-stage {
    position: relative;
    display: block;
    height: 100%;
    min-height: 0;
  }

  .album-page {
    width: 100%;
    height: 100%;
    min-height: 0;
    padding: 0.55rem 0.55rem 4.5rem;
    grid-template-rows: minmax(10rem, 1fr) auto;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }

  .album-photo {
    height: auto;
    min-height: 10rem;
  }

  .album-image-wrap {
    min-height: 0;
  }

  .album-caption {
    min-height: 0;
  }

  .album-caption h3 {
    font-size: clamp(1.6rem, 8vw, 2.5rem);
  }

  .album-caption p {
    font-size: 0.8rem;
  }

  .album-side-nav {
    position: absolute;
    z-index: 12;
    top: auto;
    bottom: 0.58rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    width: auto;
    min-width: 4.7rem;
    height: 2.35rem;
    padding: 0 0.62rem;
    color: var(--white);
    background: rgba(8, 14, 19, 0.9);
    border: 1px solid rgba(255, 253, 248, 0.2);
    border-radius: 999px;
    box-shadow: 0 0.35rem 1.2rem rgba(0, 0, 0, 0.24);
    backdrop-filter: blur(12px);
    transform: none;
  }

  .album-side-prev {
    left: max(0.62rem, env(safe-area-inset-left));
  }

  .album-side-next {
    right: max(0.62rem, env(safe-area-inset-right));
  }

  .album-side-nav svg {
    width: 0.95rem;
  }

  .album-nav-copy {
    display: inline;
    font-size: 0.54rem;
    line-height: 1;
    letter-spacing: 0.03em;
  }

  .album-footer {
    position: fixed;
    z-index: 11;
    right: auto;
    bottom: max(0.42rem, env(safe-area-inset-bottom));
    left: 50%;
    display: grid;
    width: 7rem;
    gap: 0.18rem;
    padding-bottom: 0;
    text-align: center;
    transform: translateX(-50%);
    pointer-events: none;
  }

  .album-swipe-hint {
    display: block;
    margin: 0;
    color: rgba(255, 253, 248, 0.58);
    font-size: 0.47rem;
    line-height: 1.25;
    letter-spacing: 0.02em;
    white-space: nowrap;
  }

  .book-detail {
    margin-top: 1.1rem;
  }

  html[lang="zh-CN"] .brand-lockup {
    flex-direction: column;
    gap: 0.55rem;
    width: auto;
  }

  html[lang="zh-CN"] .wordmark,
  html[lang="zh-CN"] .brand-kicker {
    white-space: nowrap;
    writing-mode: horizontal-tb;
    text-orientation: mixed;
  }

  html[lang="zh-CN"] .wordmark {
    font-size: clamp(1.6rem, 7.4vw, 2.4rem);
    letter-spacing: 0.05em;
  }

  html[lang="zh-CN"] .brand-kicker {
    margin-top: 0;
    font-size: 0.5rem;
    letter-spacing: 0.1em;
  }

  .hero-media {
    height: auto;
    justify-content: center;
  }

  .hero-media img {
    width: 100%;
    height: 100%;
    transform: none;
  }

  .bookcase {
    position: relative;
    width: 100%;
    padding-left: 1.1rem;
  }

  .gallery {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    min-height: 0;
    max-height: none;
    padding-right: 0;
    overflow: visible;
    scroll-snap-type: none;
  }

  .book,
  .book:nth-child(n) {
    display: grid;
    flex: 0 0 auto;
    grid-template-columns: minmax(0, 1fr) 3.2rem auto;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    height: auto;
    min-height: 4.8rem;
    padding: 0.8rem 0.4rem;
    text-align: left;
    transform: none;
    scroll-snap-align: none;
  }

  .book:hover {
    background: rgba(23, 24, 21, 0.035);
    transform: none;
  }

  .book:not(:last-child)::after {
    top: auto;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
  }

  .book-title {
    width: 100%;
    font-size: 0.72rem;
    line-height: 1.45;
    text-align: left;
    white-space: pre-line;
    writing-mode: horizontal-tb;
    text-orientation: mixed;
  }

  .book-media {
    width: 3.2rem;
    height: 3.2rem;
  }

  .book-number {
    justify-self: end;
  }

  .shelf-lines {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    display: block;
    width: 1px;
    padding: 0;
  }

  .shelf-lines span:first-child {
    display: block;
    width: 1px;
    height: 100%;
    opacity: 0.45;
  }

  .shelf-lines span:nth-child(n + 2) {
    display: none;
  }

  .book-detail {
    margin-left: 1rem;
  }

  .about {
    display: grid;
    min-height: 0;
    padding: 5.5rem calc(var(--pad) + 4.2rem) 5.5rem var(--pad);
    gap: 1.35rem;
    overflow: visible;
  }

  .about-overlay,
  .about-bottom {
    display: contents;
  }

  .about-overlay .eyebrow {
    grid-row: 1;
    margin: 0;
  }

  .about-statement {
    grid-row: 2;
    max-width: none;
    width: 100%;
    margin: 0;
    font-size: clamp(1rem, 4.8vw, 1.4rem);
  }

  .about-background {
    position: relative;
    top: auto;
    left: auto;
    grid-row: 3;
    justify-self: center;
    width: auto;
    height: auto;
    max-width: min(20cm, 100%);
    max-height: min(10cm, 55svh);
    transform: none;
  }

  .about-caption {
    grid-row: 4;
    margin: 0;
  }

  .album-side-nav {
    width: auto;
    height: 2.35rem;
  }

  .album-editor-grid {
    grid-template-columns: 1fr;
  }

  .album-editor-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .album-editor-head > div {
    flex-wrap: wrap;
  }

  .photo-feature {
    grid-column: auto;
  }

  .photo-feature .photo-media,
  .photo-tall .photo-media,
  .photo-media {
    aspect-ratio: 4 / 5;
  }

  .photo-feature .photo-media {
    aspect-ratio: 4 / 3;
  }

  .site-footer {
    grid-template-columns: 1fr auto;
    row-gap: 1.2rem;
    padding-right: calc(var(--pad) + 4.2rem);
  }

  .lightbox {
    padding: 4rem 0.75rem 1.5rem;
  }

  .lightbox-nav {
    top: auto;
    bottom: 4.5rem;
    transform: none;
  }

  .lightbox-prev {
    left: 1.1rem;
  }

  .lightbox-next {
    right: 1.1rem;
  }

  .lightbox figcaption {
    padding-right: 3.7rem;
    padding-left: 3.7rem;
  }
}

@media (max-width: 380px) {
  .site-header {
    padding-right: 0.9rem;
    padding-left: 0.9rem;
  }

  .wordmark {
    font-size: 2.4rem;
  }

  .header-actions {
    gap: 1.4rem;
  }

  .site-header nav {
    gap: 1.2rem;
  }

  .site-header nav a {
    font-size: 0.51rem;
    letter-spacing: 0.08em;
  }

  .language-switch {
    min-width: 0;
    padding: 0.28rem 0;
    font-size: 0.49rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

@media (min-width: 1200px) {
  html[lang="en"] .hero-quote {
    left: max(14vw, 18rem);
  }
}

@media (min-width: 581px) and (max-width: 1199px) {
  html[lang="en"] .hero-overlay {
    justify-content: flex-start;
  }

  html[lang="en"] .hero-quote {
    position: relative;
    top: auto;
    left: auto;
    width: min(17rem, 100%);
    max-width: 100%;
    margin-top: clamp(1.25rem, 3vh, 2rem);
    transform: none;
  }
}

@media (max-width: 820px) {
  .some-photos-heading {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .some-photos-heading > p:last-child {
    grid-column: 1;
  }

  .some-photos-grid {
    gap: 1.5rem;
  }

  .photo-group-card,
  .photo-group-card:nth-child(n) {
    flex: 0 0 clamp(20rem, 52vw, 30rem);
  }
}

@media (max-width: 580px) {
  .some-photos {
    padding-right: calc(var(--pad) + 4.2rem);
  }

  .some-photos-grid {
    gap: 1rem;
    padding-bottom: 1rem;
    padding-inline: 0.75rem;
    scroll-padding-inline: 0.75rem;
    -webkit-overflow-scrolling: touch;
  }

  .photo-group-card,
  .photo-group-card:nth-child(n) {
    position: relative;
    isolation: isolate;
    flex: 0 0 calc(100% - 1.5rem);
    scroll-snap-align: start;
    scroll-snap-stop: always;
  }

  .photo-group-title {
    position: relative;
    z-index: 4;
    padding-left: 0.15rem;
    overflow: visible;
  }

  .some-photos-swipe-hint {
    display: block;
  }

  .photo-group-visual {
    min-height: 11rem;
  }

  .photo-group-card[data-title-position="right"] {
    grid-template-columns: minmax(0, 1fr) 4rem;
  }

  .photo-group-card[data-title-position="left"] {
    grid-template-columns: 4rem minmax(0, 1fr);
  }
}

@media (max-width: 1000px) and (max-height: 580px) and (orientation: landscape) {
  .album-viewer {
    height: 100svh;
    max-height: 100svh;
    padding: 0.35rem 0.45rem 0;
    overflow: hidden;
  }

  .album-shell {
    height: 100%;
    gap: 0.2rem;
    grid-template-rows: auto minmax(0, 1fr);
  }

  .album-header {
    align-items: baseline;
    padding-right: 2.8rem;
  }

  .album-header h2 {
    font-size: clamp(1.15rem, 3vw, 1.55rem);
  }

  .album-close {
    width: 2.25rem;
    height: 2.25rem;
  }

  .album-stage {
    position: relative;
    display: block;
    min-height: 0;
    height: 100%;
  }

  .album-page {
    width: 100%;
    height: 100%;
    min-height: 0;
    padding: 0.45rem 0.45rem 3.2rem;
    grid-template-rows: minmax(7rem, 1fr) auto;
    gap: 0.35rem;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }

  .album-photo {
    height: auto;
    min-height: 7rem;
  }

  .album-image-wrap {
    min-height: 0;
  }

  .album-caption {
    gap: 0.25rem;
    min-height: 0;
  }

  .album-caption h3 {
    font-size: clamp(1.1rem, 3vw, 1.55rem);
  }

  .album-caption .album-details,
  .album-caption p {
    font-size: 0.62rem;
    line-height: 1.5;
  }

  .album-side-nav {
    position: absolute;
    z-index: 5;
    top: auto;
    bottom: 0.28rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    width: auto;
    min-width: 4.4rem;
    height: 2.2rem;
    padding: 0 0.55rem;
    background: rgba(8, 14, 19, 0.9);
    border: 1px solid rgba(255, 253, 248, 0.2);
    border-radius: 999px;
    transform: none;
  }

  .album-side-prev {
    left: max(0.45rem, env(safe-area-inset-left));
  }

  .album-side-next {
    right: max(0.45rem, env(safe-area-inset-right));
  }

  .album-nav-copy {
    display: inline;
    font-size: 0.5rem;
    line-height: 1;
  }

  .album-footer {
    position: fixed;
    z-index: 4;
    top: auto;
    right: auto;
    bottom: max(0.2rem, env(safe-area-inset-bottom));
    left: 50%;
    display: grid;
    width: 6.6rem;
    gap: 0.1rem;
    padding-bottom: 0;
    text-align: center;
    transform: translateX(-50%);
    pointer-events: none;
  }

  .album-swipe-hint {
    display: block;
    margin: 0;
    color: rgba(255, 253, 248, 0.58);
    font-size: 0.43rem;
    white-space: nowrap;
  }

  .album-footer {
    font-size: 0.5rem;
  }
}

.guide-trigger {
  position: fixed;
  z-index: 29;
  right: max(0.9rem, env(safe-area-inset-right));
  bottom: max(0.9rem, env(safe-area-inset-bottom));
  display: grid;
  width: 2.55rem;
  height: 2.55rem;
  padding: 0;
  color: var(--white);
  background: rgba(23, 24, 21, 0.92);
  border: 1px solid rgba(255, 253, 248, 0.2);
  border-radius: 50%;
  box-shadow: 0 0.5rem 1.6rem rgba(0, 0, 0, 0.24);
  font-size: 0.92rem;
  line-height: 1;
  cursor: pointer;
  place-items: center;
  transition:
    background-color 200ms ease,
    transform 200ms var(--ease);
}

.guide-trigger:hover {
  background: var(--accent);
  transform: translateY(-0.15rem);
}

body.guide-unread :is(a, button, [role="button"]) {
  filter: grayscale(1);
  opacity: 0.36;
}

body.guide-unread :is(
    .guide-trigger,
    .site-guide,
    .site-guide *,
    .site-guide-close
  ) {
  filter: none;
  opacity: 1;
}

body.guide-unread .guide-trigger {
  color: var(--white);
  background: var(--accent);
  border-color: rgba(255, 253, 248, 0.62);
  box-shadow:
    0 0 0 0.32rem rgba(191, 75, 43, 0.18),
    0 0.65rem 1.8rem rgba(0, 0, 0, 0.3);
  animation: guide-attention 1.8s ease-in-out infinite;
}

@keyframes guide-attention {
  0%,
  100% {
    box-shadow:
      0 0 0 0.25rem rgba(191, 75, 43, 0.16),
      0 0.65rem 1.8rem rgba(0, 0, 0, 0.3);
    transform: translateY(0);
  }

  50% {
    box-shadow:
      0 0 0 0.48rem rgba(191, 75, 43, 0.08),
      0 0.75rem 2rem rgba(0, 0, 0, 0.34);
    transform: translateY(-0.12rem);
  }
}

body.editor-mode .guide-trigger {
  display: none;
}

.site-guide {
  width: min(calc(100% - 2rem), 34rem);
  max-width: 34rem;
  max-height: calc(100svh - 2rem);
  margin: auto;
  padding: 0;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  box-shadow: 0 2rem 6rem rgba(0, 0, 0, 0.34);
}

.site-guide::backdrop {
  background: rgba(23, 24, 21, 0.68);
  backdrop-filter: blur(5px);
}

.site-guide-shell {
  max-height: calc(100svh - 2rem);
  padding: clamp(1.35rem, 4vw, 2rem);
  overflow-y: auto;
}

.site-guide-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.5rem;
  padding-right: 0.25rem;
}

.site-guide-kicker {
  margin: 0 0 0.5rem;
  color: var(--accent);
  font-size: 0.52rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.site-guide-head h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 400;
  line-height: 0.95;
}

.site-guide-close {
  position: relative;
  flex: 0 0 auto;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  cursor: pointer;
}

.site-guide-close span {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 1.35rem;
  height: 1px;
  background: currentColor;
  transform: translate(-50%, -50%) rotate(45deg);
}

.site-guide-close span:last-child {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.site-guide-steps {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--line);
}

.site-guide-step {
  display: grid;
  grid-template-columns: 1.8rem minmax(0, 1fr);
  gap: 0.65rem;
  min-width: 0;
  padding: 1rem 0.85rem 1rem 0;
  border-bottom: 1px solid var(--line);
}

.site-guide-step:nth-child(odd) {
  border-right: 1px solid var(--line);
}

.site-guide-step:nth-child(even) {
  padding-left: 0.85rem;
}

.site-guide-number {
  color: var(--accent);
  font-size: 0.52rem;
  letter-spacing: 0.08em;
}

.site-guide-step h3 {
  margin: 0 0 0.35rem;
  font-family: var(--serif);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.15;
}

.site-guide-step p,
.site-guide-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.68rem;
  line-height: 1.65;
}

.site-guide-note {
  margin-top: 1rem;
}

.site-guide-done {
  width: 100%;
  margin-top: 1.35rem;
  padding: 0.85rem 1rem;
  color: var(--white);
  background: var(--ink);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  cursor: pointer;
}

.site-guide-done:hover {
  background: var(--accent);
}

@media (max-width: 580px) {
  .guide-trigger {
    right: max(0.72rem, env(safe-area-inset-right));
    bottom: max(0.72rem, env(safe-area-inset-bottom));
    width: 2.4rem;
    height: 2.4rem;
  }

  .site-guide {
    width: calc(100% - 1rem);
    max-height: calc(100svh - 0.75rem);
  }

  .site-guide-shell {
    max-height: calc(100svh - 0.75rem);
    padding: 1.15rem;
  }

  .site-guide-head h2 {
    font-size: 2rem;
  }

  .site-guide-steps {
    grid-template-columns: 1fr;
  }

  .site-guide-step,
  .site-guide-step:nth-child(even) {
    padding: 0.85rem 0;
    border-right: 0;
  }
}

