:root {
  --ink-dark: #0F0F0F;
  --ink-main: #333333;
  --ink-light: #888888;
  --ink-bg: #E0E0E0;
  --seal-red: #B63B34;
  --paper: #f8f4ea;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  color: var(--ink-main);
  font-family: 'Songti SC','SimSun','STSong','serif';
  background: radial-gradient(circle at 20% 20%, #fbf8f0, #f2ecde 55%, #e8dfcf);
  min-height: 100vh;
  overflow-x: hidden;
}

.paper-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  mix-blend-mode: multiply;
  opacity: .15;
  background-image:
    radial-gradient(circle at 30% 40%, rgba(0,0,0,.04), transparent 30%),
    radial-gradient(circle at 70% 70%, rgba(0,0,0,.03), transparent 20%);
}

.page {
  width: min(1100px, 88vw);
  margin: 0 auto;
  padding: 5rem 2rem 4rem;
}

.v-nav {
  position: fixed;
  right: 1.2rem;
  top: 1rem;
  writing-mode: vertical-rl;
  z-index: 20;
  display: flex;
  gap: .5rem;
}

.v-link {
  color: var(--ink-main);
  text-decoration: none;
  padding: .3rem .2rem;
  border-right: 2px solid transparent;
}
.v-link:hover {
  color: var(--seal-red);
  border-right-color: var(--seal-red);
}
.level-nav {
  color: var(--seal-red);
  border-right-color: rgba(182,59,52,.35);
}

.vertical-title {
  writing-mode: vertical-rl;
  font-family: 'STKaiti','KaiTi','FZKai-Z03','serif';
  letter-spacing: .2rem;
  color: var(--ink-dark);
}
.v-heading {
  writing-mode: horizontal-tb;
  font-family: 'STKaiti','KaiTi','FZKai-Z03','serif';
  letter-spacing: 0;
  color: var(--ink-dark);
  margin: 0 0 1rem;
}

.home-hero {
  position: relative;
  height: 82vh;
  display: grid;
  place-items: center;
}

#inkCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  filter: contrast(110%);
}

.home-title-wrap { position: relative; z-index: 2; text-align: center; }
.vertical-title { font-size: clamp(3rem, 8vw, 7rem); margin: 0 auto; }
.current-tip { margin-top: 1rem; color: var(--ink-light); }

.seal-ai {
  width: 62px;
  height: 62px;
  margin: 1rem auto;
  background: var(--seal-red);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: bold;
  transform: rotate(-8deg);
  filter: drop-shadow(0 4px 8px rgba(0,0,0,.2));
}

.tag-filter, .styles { display: flex; flex-wrap: wrap; gap: .5rem; margin: 1rem 0 1.5rem; }
.tag {
  border: 1px solid var(--ink-light);
  color: var(--ink-main);
  background: transparent;
  padding: .3rem .7rem;
  text-decoration: none;
  cursor: pointer;
}
.tag.active { border-color: var(--seal-red); color: var(--seal-red); }
.danger-tag {
  border-color: rgba(182,59,52,.65);
  color: var(--seal-red);
}

.term-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 1.2rem;
}

.term-card {
  background: color-mix(in srgb, var(--micro, #eee) 65%, #fff);
  padding: .6rem;
  min-height: 280px;
  transition: transform .3s ease;
  clip-path: polygon(0 2%, 98% 0, 100% 98%, 2% 100%);
}
.term-card:hover { transform: translateY(-4px); }
.term-card a { color: inherit; text-decoration: none; }
.poster {
  height: 145px;
  background-size: cover;
  background-position: center;
  filter: grayscale(15%);
  mix-blend-mode: multiply;
}

.rough-edge {
  -webkit-mask-image: radial-gradient(circle at 12px 12px, transparent 0 9px, #000 10px), linear-gradient(#000,#000);
  -webkit-mask-composite: source-over;
}

.scroll-wrap {
  overflow-x: auto;
  overflow-y: hidden;
  white-space: nowrap;
  border-top: 1px solid rgba(0,0,0,.1);
  border-bottom: 1px solid rgba(0,0,0,.1);
  background: linear-gradient(120deg, rgba(255,255,255,.2), color-mix(in srgb, var(--micro,#eee) 60%, transparent));
}
.scroll-track { display: flex; min-height: 70vh; }
.scroll-panel {
  min-width: 70vw;
  padding: 2rem;
  white-space: normal;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: .8rem;
}

.term-detail-page {
  display: grid;
  gap: 1rem;
  max-width: 860px;
  margin: 0 auto;
}
.term-hero {
  display: grid;
  grid-template-columns: 1fr;
  gap: .8rem;
  padding: 1rem;
  background: linear-gradient(120deg, rgba(255,255,255,.4), color-mix(in srgb, var(--micro,#eee) 55%, #fff));
  border: 1px solid rgba(0,0,0,.12);
}
.term-hero-poster {
  position: relative;
  display: grid;
  place-items: center;
}
.term-hero-info {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: .5rem;
  text-align: center;
}
.term-season {
  color: var(--ink-light);
  margin: 0;
}
.term-title {
  margin: .1rem 0;
  font-size: clamp(1.8rem, 3.8vw, 3rem);
  font-family: 'STKaiti','KaiTi','FZKai-Z03','serif';
}
.term-date {
  margin: 0;
}
.term-grid-detail {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}
.term-stack {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}
.term-list-grid {
  display: grid;
  gap: .8rem;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.term-card {
  border-radius: 14px;
  border: 1px solid rgba(86, 69, 51, .15);
  box-shadow: 0 8px 20px rgba(0,0,0,.08);
  background: linear-gradient(180deg, rgba(255,255,255,.62), rgba(255,255,255,.3));
}
.region-card {
  padding: .8rem .9rem;
  background: rgba(255,255,255,.4);
  border-left: 2px solid color-mix(in srgb, var(--seal-red), #fff 45%);
  border-radius: 10px;
}
.story-links a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px dashed rgba(0,0,0,.25);
}
.story-links a:hover {
  color: var(--seal-red);
  border-bottom-color: var(--seal-red);
}
.story-note {
  margin-top: .45rem;
  padding: .55rem .7rem;
  border-left: 2px solid rgba(182,59,52,.45);
  background: rgba(255,255,255,.26);
  color: var(--ink-light);
  font-size: .94rem;
  line-height: 1.7;
}
.story-detail {
  position: relative;
  overflow: hidden;
  padding: 1.2rem;
}
.story-detail::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(90deg, rgba(248,244,234,.96), rgba(248,244,234,.82) 52%, rgba(248,244,234,.48)),
    var(--story-bg) center / cover no-repeat;
  opacity: .72;
}
.story-detail::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(248,244,234,.25), rgba(248,244,234,.92) 78%);
}
.story-title-horizontal {
  writing-mode: horizontal-tb;
  margin: 0 0 .6rem;
  font-family: 'STKaiti','KaiTi','FZKai-Z03','serif';
  font-size: clamp(2rem, 5vw, 3.4rem);
  letter-spacing: 0;
  color: var(--ink-dark);
}
.story-module {
  margin-top: 1rem;
}
.story-main-card {
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 1.1rem 1.4rem;
  margin-top: .8rem;
  background: rgba(255,255,255,.42);
}
.story-main-card h3 {
  margin: 0 0 .6rem;
  font-size: 1.4rem;
}
.story-main-card p {
  margin: .45rem 0;
}
.story-main-text {
  max-width: 72ch;
  color: #3d362d;
  line-height: 1.9;
  font-size: 1.08rem;
  white-space: pre-line;
}
.read-card-btn {
  display: block;
  width: fit-content;
  margin: auto 0 0 auto;
  padding: .45rem .8rem;
  font-size: .95rem;
}
.story-module-title {
  margin: 0 0 .75rem;
  font-family: 'STKaiti','KaiTi','FZKai-Z03','serif';
  font-size: 1.45rem;
  letter-spacing: 0;
  color: var(--ink-dark);
}
.poem-grid {
  display: grid;
  gap: .8rem;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.poem-card {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  background: rgba(255,255,255,.38);
}
.poem-title-btn {
  display: grid;
  gap: .18rem;
  width: 100%;
  padding: 0 0 .35rem;
  color: var(--seal-red);
  text-align: left;
  border: 0;
  border-bottom: 1px dashed rgba(150,63,54,.28);
  background: transparent;
  cursor: pointer;
  font-family: inherit;
}
.poem-title-btn:hover,
.poem-title-btn:focus-visible {
  color: #7f2b26;
}
.poem-title {
  font-size: 1.04rem;
  font-weight: 700;
}
.poem-author {
  color: var(--ink-light);
  font-size: .9rem;
}
.poem-title-btn::after {
  content: "点击展开全文";
  justify-self: end;
  color: var(--ink-light);
  font-size: .78rem;
}
.poem-title-btn[aria-expanded="true"]::after {
  content: "点击收起";
}
.poem-full {
  line-height: 1.9;
}
.poem-card .story-note p {
  margin: 0;
}
.story-text {
  white-space: pre-line;
  line-height: 1.95;
  font-size: 1.03rem;
}
.classic-quote-text {
  font-family: 'STKaiti','KaiTi','FangSong','SimSun',serif;
  color: #2d241b;
}
.classic-quote-list {
  display: grid;
  gap: .8rem;
}
.classic-quote-item {
  display: flex;
  flex-direction: column;
  margin: 0;
}
.classic-quote-source {
  margin: 0 0 .45rem;
  color: var(--seal-red);
  font-weight: 700;
}
.classic-quote-item .story-text {
  margin: 0;
}
.story-illustration {
  margin: 1rem 0;
}
.story-illustration img {
  display: block;
  width: min(100%, 720px);
  height: auto;
  max-height: none;
  object-fit: contain;
  background: rgba(255,255,255,.45);
  border-radius: 12px;
  border: 1px solid rgba(0,0,0,.12);
  box-shadow: 0 10px 28px rgba(0,0,0,.16);
}
.story-illustration figcaption {
  margin-top: .4rem;
  color: var(--ink-light);
  font-size: .92rem;
}
.source-box {
  margin-top: .8rem;
  font-size: .95rem;
  border-left-color: color-mix(in srgb, var(--seal-red), #fff 20%);
}
.source-box p { margin: .35rem 0 0; }
.admin-table {
  width: 100%;
  border-collapse: collapse;
}
.admin-table th,
.admin-table td {
  border-bottom: 1px solid rgba(0,0,0,.12);
  padding: .55rem .45rem;
  text-align: left;
}

.detail-poster {
  max-width: min(100%, 360px);
  width: 100%;
  border: 1px solid rgba(0,0,0,.12);
  box-shadow: 0 8px 20px rgba(0,0,0,.16);
  border-radius: 12px;
}
.pattern-overlay {
  width: 180px;
  opacity: .15;
  mix-blend-mode: multiply;
}
.pattern-overlay-hero {
  position: absolute;
  right: 50%;
  transform: translateX(150px);
  bottom: .4rem;
  width: min(30%, 96px);
  opacity: .28;
}

.ink-block {
  padding: 1rem 1.2rem;
  border-left: 2px solid color-mix(in srgb, var(--ink-light), #fff 25%);
  background: rgba(255,255,255,.28);
}
.light { color: var(--ink-light); }

.seal-btn {
  background: var(--seal-red);
  color: #fff;
  border: none;
  padding: .6rem 1rem;
  cursor: pointer;
  font-family: 'STKaiti','KaiTi','serif';
  transition: transform .15s ease, filter .2s ease;
}
.seal-btn:hover { filter: saturate(1.2) brightness(.92); transform: scale(1.03); }
.seal-btn:disabled {
  cursor: wait;
  opacity: .72;
  transform: none;
}

#stampDrop { width: 96px; height: 96px; margin-top: 1rem; }
.stamp-fall {
  animation: stampFall .45s ease-out;
  filter: blur(.3px) saturate(1.15);
}
@keyframes stampFall {
  0% { transform: translateY(-40px) scale(1.25); opacity: .1; }
  70% { transform: translateY(5px) scale(.96); }
  100% { transform: translateY(0) scale(1); opacity: 1; }
}

.calendar-cards, .dashboard-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit,minmax(220px,1fr)); }
.tiny-chart rect { fill: var(--seal-red); opacity: .8; }
.story-filter {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr auto;
  gap: .6rem;
  margin-bottom: 1rem;
}
.story-filter input,
.story-filter select {
  border: 1px solid #b8ab97;
  background: transparent;
  padding: .5rem .6rem;
}

.ai-box { max-width: 760px; }
.ink-input-wrap {
  margin: 1rem 0;
  border-bottom: 2px solid #6c5d4e;
  filter: url(#inkDistort);
}
.ink-input-wrap input {
  width: 100%; border: none; outline: none; background: transparent; padding: .6rem .1rem; font-size: 1.05rem;
}
.ink-answer {
  min-height: 120px;
  white-space: pre-wrap;
  margin-top: 1rem;
  line-height: 1.8;
}
.ink-char {
  opacity: 0;
  filter: blur(2px);
  animation: inkChar .45s forwards;
}
@keyframes inkChar { to { opacity: 1; filter: blur(0); } }

.stamp-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(90px,1fr));
  gap: .8rem;
}
.stamp-item {
  border: 1px dashed rgba(0,0,0,.2);
  padding: .5rem;
  text-align: center;
}
.stamp-item .stamp-mark { color: #aaa; font-size: 1.2rem; }
.stamp-item.owned .stamp-mark { color: var(--seal-red); font-weight: 700; }
.level-card {
  margin-bottom: 1rem;
  background: rgba(255,255,255,.38);
}
.stamp-thumb-crop {
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  margin: .45rem auto;
  overflow: hidden;
  background: rgba(255,255,255,.55);
  border: 1px solid rgba(182,59,52,.25);
}
.stamp-thumb-crop .stamp-thumb {
  width: 126%;
  height: 126%;
  object-fit: cover;
  display: block;
  max-width: none;
  margin: 0;
  border: 0;
  background: transparent;
}
.stamp-remake-btn {
  display: inline-block;
  margin: .05rem auto .35rem;
}
.stamp-hide-form {
  margin: .25rem 0 .35rem;
}
.stamp-hidden-state {
  color: var(--ink-light);
}
.owned-stamp-preview {
  width: 96px;
  height: 96px;
  object-fit: contain;
  display: block;
  margin: .45rem auto;
  background: rgba(255,255,255,.55);
  border: 1px solid rgba(182,59,52,.25);
}
.owned-stamp-preview { width: 96px; height: 96px; margin: .8rem 0 0; }

.auth-form { max-width: 360px; display: flex; flex-direction: column; gap: .8rem; }
.auth-form input, .auth-form select, .auth-form textarea { border: 1px solid #b8ab97; background: transparent; padding: .55rem .6rem; font-family: inherit; }

.scene-card {
  background:
    linear-gradient(135deg, rgba(255,255,255,.68), rgba(255,255,255,.24)),
    radial-gradient(circle at 12% 20%, color-mix(in srgb, var(--micro,#ddd) 70%, #fff), transparent 40%);
}
.scene-lichun, .scene-chunfen, .scene-qingming, .scene-guyu {
  --scene-wash: rgba(112, 156, 93, .13);
}
.scene-yushui, .scene-bailu, .scene-xiaoxue, .scene-daxue {
  --scene-wash: rgba(83, 132, 168, .15);
}
.scene-jingzhe, .scene-xiazhi, .scene-dashu {
  --scene-wash: rgba(160, 92, 70, .13);
}
.scene-liqiu, .scene-qiufen, .scene-shuangjiang {
  --scene-wash: rgba(180, 126, 62, .14);
}
.scene-lidong, .scene-dongzhi, .scene-xiaohan, .scene-dahan {
  --scene-wash: rgba(90, 104, 134, .15);
}
.term-detail-page,
.story-detail,
.stamp-custom-page {
  background:
    linear-gradient(180deg, var(--scene-wash, transparent), transparent 420px);
  border-radius: 12px;
}

.comment-zone { margin-top: .5rem; }
.comment-form {
  display: grid;
  gap: .75rem;
  margin: .8rem 0 1.2rem;
}
.comment-form textarea,
.stamp-custom-form textarea,
.quiz-option {
  border: 1px solid #b8ab97;
  background: rgba(255,255,255,.3);
  padding: .65rem .75rem;
  font-family: inherit;
}
.comment-form input[type="file"],
.stamp-custom-form input[type="file"] {
  border: 1px dashed rgba(0,0,0,.22);
  padding: .55rem;
  background: rgba(255,255,255,.25);
}
.check-row,
.quiz-option {
  display: flex;
  align-items: center;
  gap: .45rem;
}
.comment-list {
  display: grid;
  gap: .75rem;
}
.comment-item {
  padding: .85rem 1rem;
  border: 1px solid rgba(0,0,0,.1);
  background: rgba(255,255,255,.34);
}
.comment-head,
.comment-actions,
.canvas-tools {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .5rem;
}
.comment-actions form { margin: 0; }
.comment-image {
  max-width: min(100%, 360px);
  max-height: 260px;
  object-fit: cover;
  border: 1px solid rgba(0,0,0,.12);
}
.admin-comment-list {
  display: grid;
  gap: .8rem;
}
.admin-comment-card {
  display: grid;
  gap: .55rem;
}
.admin-comment-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  align-items: center;
}
.admin-comment-actions input {
  min-width: min(100%, 260px);
  border: 1px solid #b8ab97;
  background: rgba(255,255,255,.32);
  padding: .45rem .6rem;
}
.admin-log-heading {
  margin-top: 1.2rem;
}

.quiz-form,
.stamp-custom-form {
  display: grid;
  gap: 1rem;
}
.quiz-card {
  display: grid;
  gap: .55rem;
}
.quiz-card h3 { margin-bottom: .2rem; }
.quiz-ok { border-left-color: #568a5b; }
.quiz-bad { border-left-color: #B63B34; }

.stamp-canvas {
  width: min(100%, 360px);
  aspect-ratio: 1;
  border: 1px solid rgba(182,59,52,.32);
  background: #fffaf0;
  touch-action: none;
  display: block;
}
.canvas-tools { margin-top: .7rem; }

.certificate-image-wrap {
  max-width: 980px;
  margin: 0 auto 1rem;
  background: linear-gradient(135deg, rgba(218, 239, 225, .72), rgba(246, 238, 216, .62));
  padding: .9rem;
  border: 1px solid rgba(82, 127, 112, .2);
  box-shadow: 0 16px 34px rgba(51, 84, 72, .15);
}
.certificate-svg {
  width: 100%;
  height: auto;
  display: block;
}
.admin-certificate-panel {
  margin-top: 1.4rem;
}
.certificate-admin-preview {
  margin-left: 0;
  margin-right: 0;
}
.admin-stamp-test-panel {
  margin-top: 1rem;
}
.admin-panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}
.admin-panel-heading h3 {
  margin: 0 0 .35rem;
}
.admin-term-shortcuts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  gap: .45rem;
  margin-top: .8rem;
}
.admin-term-shortcut {
  display: grid;
  gap: .12rem;
  text-align: center;
}
.admin-term-shortcut small {
  color: var(--ink-light);
  font-size: .72rem;
}

.flash-wrap { position: fixed; left: 1rem; top: 1rem; z-index: 30; }
.flash { background: #fff8; padding: .4rem .6rem; margin: .2rem 0; border-left: 2px solid var(--seal-red); }

.fade-ink {
  animation: fadeInk .8s ease-out;
}
@keyframes fadeInk {
  from { opacity: 0; transform: translateY(10px); filter: blur(2px); }
  to { opacity: 1; transform: translateY(0); filter: blur(0); }
}

@media print {
  .v-nav, .seal-btn { display: none !important; }
  body { background: #fff; }
}

@media (max-width: 780px) {
  .page { width: 94vw; padding: 4rem 1rem 2rem; }
  .v-nav { writing-mode: horizontal-tb; right: auto; left: .5rem; top: .5rem; }
  .scroll-panel { min-width: 88vw; }
  .story-filter { grid-template-columns: 1fr; }
  .term-detail-page { max-width: 100%; }
  .detail-poster { max-width: 300px; }
  .pattern-overlay-hero {
    transform: translateX(122px);
    width: 84px;
  }
}

/* Exhibition cards keep the six-piece view compact while preserving readable controls. */
.term-card { min-height: 0; }
.stamp-share { margin-top: .45rem; text-align: left; }
.stamp-share summary { display: inline-block; list-style: none; }
.stamp-share summary::-webkit-details-marker { display: none; }
.stamp-share-form {
  display: grid;
  gap: .45rem;
  margin-top: .55rem;
  text-align: left;
}
.stamp-share-form textarea {
  width: 100%;
  resize: vertical;
  border: 1px solid #b8ab97;
  background: rgba(255,255,255,.32);
  padding: .45rem .55rem;
  font-family: inherit;
}
.stamp-shared-state {
  margin: .35rem 0 0;
  color: #568a5b;
  font-size: .86rem;
}
.exhibition-page { max-width: 1050px; margin: 0 auto; }
.exhibition-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}
.exhibition-heading p { margin: .25rem 0 0; }
.exhibition-page-count { color: var(--ink-light); white-space: nowrap; }
.exhibition-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  align-items: start;
}
.exhibition-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid rgba(86, 69, 51, .16);
  border-radius: 10px;
  background: rgba(255,255,255,.42);
  box-shadow: 0 8px 18px rgba(66, 55, 43, .08);
  overflow: hidden;
}
.exhibition-image-wrap {
  display: grid;
  place-items: center;
  aspect-ratio: 1 / .82;
  padding: .9rem;
  background:
    radial-gradient(circle at 50% 40%, rgba(255,255,255,.78), transparent 58%),
    linear-gradient(135deg, rgba(208,231,216,.52), rgba(246,238,216,.64));
  border-bottom: 1px solid rgba(86, 69, 51, .1);
}
.exhibition-stamp-crop {
  display: grid;
  place-items: center;
  width: min(86%, 310px);
  aspect-ratio: 1;
  overflow: hidden;
  background: rgba(255,255,255,.45);
  filter: drop-shadow(0 8px 8px rgba(66, 42, 24, .14));
}
.exhibition-stamp-image {
  width: 126%;
  height: 126%;
  max-width: none;
  object-fit: cover;
  display: block;
}
.exhibition-card-body {
  display: flex;
  flex-direction: column;
  gap: .35rem;
  padding: .62rem .78rem .68rem;
}
.exhibition-meta {
  display: flex;
  justify-content: space-between;
  gap: .7rem;
  color: var(--ink-light);
  font-size: .88rem;
}
.exhibition-meta time { white-space: nowrap; }
.exhibition-note {
  margin: 0;
  min-height: 0;
  line-height: 1.5;
  white-space: pre-line;
}
.exhibition-guess-area {
  display: flex;
  flex-direction: column;
  gap: .25rem;
  margin-top: .15rem;
  padding-top: 0;
}
.exhibition-guess-form {
  display: flex;
  align-items: center;
  gap: .4rem;
}
.exhibition-guess-form select {
  flex: 1;
  min-width: 0;
  border: 1px solid #b8ab97;
  background: rgba(255,255,255,.38);
  padding: .42rem .45rem;
  font-family: inherit;
}
.exhibition-guess-form .tag { white-space: nowrap; }
.exhibition-rate {
  margin: 0;
  color: var(--ink-light);
  font-size: .88rem;
}
.exhibition-rate strong { color: var(--seal-red); }
.exhibition-rate span { font-size: .8rem; }
.guess-result {
  margin: 0;
  padding: .4rem .5rem;
  border-left: 2px solid;
  font-size: .92rem;
}
.guess-correct {
  color: #3f754c;
  border-left-color: #568a5b;
  background: rgba(86,138,91,.08);
}
.guess-wrong {
  color: var(--seal-red);
  border-left-color: var(--seal-red);
  background: rgba(182,59,52,.06);
}
.exhibition-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .65rem;
  margin-top: 1.2rem;
}
.exhibition-page-number {
  min-width: 2rem;
  text-align: center;
  color: var(--ink-light);
}
.tag.disabled { opacity: .45; cursor: not-allowed; }
.exhibition-empty { padding: 1.4rem; text-align: center; }
.exhibition-empty h3 { margin-top: 0; }
.account-delete-page { max-width: 720px; margin: 0 auto; }
.account-warning { line-height: 1.8; }
.account-warning h3 { margin-top: 0; }
.account-warning li + li { margin-top: .55rem; }
.account-delete-form { margin-top: 1rem; }
.account-delete-form label[for="account-password"] { color: var(--ink-main); }
.account-choice {
  display: grid;
  gap: .55rem;
  border: 1px solid rgba(86, 69, 51, .18);
  padding: .8rem;
  margin: 0;
}
.account-choice legend { padding: 0 .35rem; }
.danger-account-btn { background: #8f302d; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 780px) {
  .exhibition-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .exhibition-heading { align-items: start; flex-direction: column; }
}
@media (max-width: 520px) {
  .exhibition-grid { grid-template-columns: 1fr; }
  .exhibition-image-wrap { aspect-ratio: 1 / .78; }
}

.stamp-editor-card { padding: 1rem; }
.stamp-editor-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: .8rem;
}
.stamp-editor-heading h3 { margin: 0; }
.stamp-editor-heading p { margin: .3rem 0 0; }
.stamp-import-label {
  position: relative;
  overflow: hidden;
  flex: 0 0 auto;
}
.stamp-import-label input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
  opacity: 0;
}
.stamp-editor-layout {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(220px, .7fr);
  gap: 1rem;
  align-items: start;
}
.stamp-stage-wrap { min-width: 0; }
.stamp-canvas {
  width: min(100%, 480px);
  aspect-ratio: 1;
  border: 1px solid rgba(182,59,52,.32);
  background: #fffaf0;
  touch-action: none;
  display: block;
  cursor: crosshair;
}
.stamp-canvas.select-mode { cursor: grab; }
.stamp-canvas.select-mode:active { cursor: grabbing; }
.stamp-editor-status {
  min-height: 1.4em;
  margin: .45rem 0 0;
  color: var(--ink-light);
  font-size: .9rem;
}
.stamp-editor-controls {
  display: grid;
  gap: .8rem;
  min-width: 0;
}
.editor-control-group {
  display: grid;
  gap: .4rem;
}
.editor-label {
  color: var(--ink-main);
  font-size: .94rem;
}
.editor-control-group input[type="range"] { width: 100%; }
.editor-control-group output {
  color: var(--seal-red);
  margin-left: .25rem;
}
.editor-control-group button:disabled { opacity: .4; cursor: not-allowed; }
.sticker-palette {
  display: grid;
  grid-template-columns: repeat(4, minmax(52px, 1fr));
  gap: .45rem;
}
.sticker-option {
  display: grid;
  justify-items: center;
  gap: .15rem;
  min-width: 0;
  padding: .25rem;
  color: var(--ink-main);
  border: 1px solid rgba(86,69,51,.2);
  background: rgba(255,255,255,.35);
  cursor: pointer;
  font-family: inherit;
}
.sticker-option:hover,
.sticker-option:focus-visible {
  border-color: var(--seal-red);
  color: var(--seal-red);
}
.sticker-option canvas {
  width: 48px;
  height: 48px;
  object-fit: contain;
}
.sticker-option span {
  overflow: hidden;
  max-width: 100%;
  font-size: .78rem;
  white-space: nowrap;
  text-overflow: ellipsis;
}

@media (max-width: 780px) {
  .stamp-editor-heading { flex-direction: column; }
  .stamp-editor-layout { grid-template-columns: 1fr; }
  .stamp-editor-controls { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stamp-editor-controls > .editor-control-group:nth-child(4),
  .stamp-editor-controls > .canvas-tools { grid-column: 1 / -1; }
}

@media (max-width: 520px) {
  .stamp-editor-controls { grid-template-columns: 1fr; }
}
/* Unified horizontal navigation and seasonal visual hierarchy. */
body .v-nav {position:relative;inset:auto;writing-mode:horizontal-tb;display:flex;flex-direction:row;flex-wrap:wrap;align-items:center;justify-content:center;gap:.5rem;padding:1rem;background:#f8f4eaeF;border-bottom:1px solid #d8c9b0;height:auto;}
body .v-nav .v-link {writing-mode:horizontal-tb;white-space:nowrap;padding:.55rem .9rem;border:1px solid #cbbca4;border-radius:8px 2px;color:#544536;background:#f4ecdf;font-size:.95rem;text-decoration:none;}
body .v-nav .nav-section-0 {border-color:#a5b29a;background:#edf1e7;color:#435b42;}
body .v-nav .nav-section-1 {border-color:#a5b5be;background:#eaf0f2;color:#375663;}
body .v-nav .nav-section-2 {border-color:#c4a58e;background:#f4eadb;color:#795330;}
body .v-nav .v-link[aria-current=page],body .v-nav .v-link:hover {background:#9e3e34;color:#fff9ed;border-color:#9e3e34;}
body .page {margin:0 auto;padding:2rem 1.25rem 4rem;width:min(1200px,96vw);}
.tag {display:inline-flex;align-items:center;justify-content:center;line-height:1.5;padding:.45rem .85rem;border-radius:6px 2px;text-decoration:none;cursor:pointer;font-size:.95rem;background:#f6f0e5;color:#435b42;border:1px solid #a4b09a;}
.seal-btn {display:inline-flex;align-items:center;justify-content:center;text-decoration:none;padding:.7rem 1rem;line-height:1.5;border-radius:8px 2px;background:#a63f35;color:#fff9ed;border:1px solid #a63f35;font:inherit;cursor:pointer;}
.ink-block h3,.story-module-title {border-left:3px solid #8e9d7c;padding-left:.7rem;color:#51452f;}
.stamps-page .stamp-grid {display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:1.25rem;align-items:start;}
.stamps-page .stamp-item {display:flex;flex-direction:column;align-items:stretch;gap:.75rem;padding:1.2rem;background:#fffaf0;border:1px solid #d5c4a7;border-radius:12px 3px;text-align:center;min-width:0;}
.stamp-term-title {margin:0;font-size:1.35rem;color:#544536;}
.stamps-page .stamp-thumb-crop {display:flex;align-items:center;justify-content:center;width:100%;height:170px;margin:0;background:#f4ede0;border-radius:8px;}
.stamps-page .stamp-thumb {max-width:100%;max-height:170px;width:auto;height:auto;object-fit:contain;}
.stamps-page .stamp-item .tag {width:100%;white-space:normal;font-size:.95rem;}
.stamps-page .stamp-item p {margin:.25rem 0;line-height:1.5;font-size:.9rem;}
.stamps-page .stamp-item details {text-align:left;font-size:.9rem;}
.stamps-page .stamp-item summary {padding:.55rem;border-bottom:1px solid #d5c4a7;cursor:pointer;color:#435b42;}
.stamp-share-form textarea {width:100%;box-sizing:border-box;}
.stamp-item .check-row {display:flex;gap:.5rem;align-items:flex-start;line-height:1.5;margin:.7rem 0;}
.auth-form label {display:grid;gap:.5rem;margin:1rem 0;font-weight:bold;}
@media(max-width:600px){body .v-nav{justify-content:flex-start;padding:.7rem;gap:.4rem;}body .v-nav .v-link{font-size:.85rem;padding:.45rem .6rem;}.stamps-page .stamp-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:.65rem;}.stamps-page .stamp-item{padding:.75rem;}.stamps-page .stamp-thumb-crop{height:125px;}.stamps-page .stamp-thumb{max-height:125px;}}
@media(max-width:360px){.stamps-page .stamp-grid{grid-template-columns:1fr;}}
.season-icon{width:18px;height:18px;display:inline-block;vertical-align:middle;margin-right:.4rem;flex-shrink:0;}.task-icon{width:32px;height:32px;}body .v-nav .v-link{display:inline-flex;align-items:center;}
/* Consistent page hierarchy and a two-tier seasonal masthead. */
.site-masthead{background:#526b50;color:#fff8e9;padding:1rem max(1.2rem,calc((100vw - 1200px)/2));display:flex;align-items:center;justify-content:space-between;gap:1rem;}
.site-brand{font-size:1.5rem;letter-spacing:.15em;color:inherit;text-decoration:none;font-weight:bold;}.site-brand span{display:block;font-size:.8rem;font-weight:normal;letter-spacing:.08em;margin-top:.3rem;}.site-masthead p{font-size:.9rem;}
body .v-nav{background:#344e3c;padding:.6rem 1rem;border:0;gap:.35rem;}body .v-nav a.v-link{background:transparent;color:#f7edda;border-color:transparent;border-radius:3px;font-size:.95rem;}body .v-nav a.v-link:hover,body .v-nav a.v-link[aria-current=page]{background:#ae793a;color:#fff;}
.status-label,.journey-badge,.task-difficulty{display:inline-block;padding:.4rem .7rem;background:#eae7de;color:#655d50;border:1px solid #d7d0c0;border-radius:4px;font-size:.85rem;cursor:default;}.v-nav .status-label{background:#e3e9de;color:#43533e;}
body .page h1,body .page h2.v-heading,body .page .exhibition-heading h2{font-size:1.75rem;line-height:1.4;letter-spacing:.05em;margin:0 0 .8rem;}body .page h2{font-size:1.3rem;line-height:1.5;}body .page h3{font-size:1.1rem;line-height:1.5;}body .page p,body .page label{font-size:1rem;line-height:1.7;}
body .page a.tag,body .page button.tag,body .page summary.tag{background:#e6eee2;border-color:#97aa89;color:#3b563b;}body .page .seal-btn{background:#a54839;color:#fff9eb;border-color:#a54839;}body .page .danger-tag{background:#f3e4df;color:#993c32;border-color:#ca9a8e;}body .page .light{color:#77756c;}
.explore-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1.25rem;margin:1.5rem 0;}.explore-card{padding:1.5rem;background:#fffcf3;border:1px solid #d9cfbb;border-top:3px solid #78936f;border-radius:6px;}.explore-card .season-icon{width:32px;height:32px;color:#587251;}.explore-card p{min-height:4.5rem;}
.stamps-page .stamp-grid{grid-template-columns:repeat(6,minmax(0,1fr));gap:.8rem;}.stamps-page .stamp-item{padding:.8rem;gap:.55rem;}.stamps-page .stamp-thumb-crop{position:relative;display:block;width:100%;height:auto;aspect-ratio:1;overflow:hidden;background:#fffaf0;border-radius:4px;}.stamps-page .stamp-thumb{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:117.1%;height:117.1%;max-width:none;max-height:none;object-fit:fill;}.stamps-page .stamp-item .tag{font-size:.8rem;padding:.4rem;}.stamps-page .stamp-term-title{font-size:1.05rem;}
body .exhibition-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:.8rem;}body .exhibition-image-wrap{aspect-ratio:auto;height:170px;padding:.65rem;}body .exhibition-stamp-crop{width:150px;height:150px;aspect-ratio:1;filter:none;}body .exhibition-stamp-image{width:117.1%;height:117.1%;object-fit:fill;}body .exhibition-card-body{padding:.65rem;gap:.25rem;}body .exhibition-card-body p{font-size:.88rem;margin:.25rem 0;line-height:1.5;}body .exhibition-guess-area{min-height:0;padding:.35rem 0;margin:0;}body .exhibition-meta{font-size:.8rem;}.exhibition-note{max-height:3.2rem;overflow:auto;}
@media(max-width:1000px){.stamps-page .stamp-grid{grid-template-columns:repeat(3,minmax(0,1fr));}}@media(max-width:650px){.site-masthead{padding:1rem;}.site-masthead p{display:none;}.explore-grid{grid-template-columns:1fr;}.stamps-page .stamp-grid{grid-template-columns:repeat(2,minmax(0,1fr));}body .exhibition-grid{grid-template-columns:repeat(2,minmax(0,1fr));}body .exhibition-image-wrap{height:140px;}body .exhibition-stamp-crop{width:120px;height:120px;}body .page h1,body .page h2.v-heading{font-size:1.5rem;}}
body .page h1{font-size:1.75rem!important;line-height:1.4!important;}body .page h2{font-size:1.3rem!important;line-height:1.5!important;}body .page h2.v-heading,body .page .exhibition-heading h2{font-size:1.75rem!important;}body .page h3{font-size:1.1rem!important;line-height:1.5!important;}body .page .stamp-term-title{font-size:1.05rem!important;}body .page .status-label{font-size:.85rem;}
@media(max-width:650px){body .page h1,body .page h2.v-heading,body .page .exhibition-heading h2{font-size:1.5rem!important;}}
body .page span.tag,body .page p.tag{background:#eae7de;border-color:#d7d0c0;color:#655d50;cursor:default;}
/* Consistent page hierarchy and equal image frames, including atlas detail views. */
body .page .page-title, body .page > section > h2:first-child,
body .page .story-title-horizontal, body .page .term-title {
  font-family: var(--font-title, 'STKaiti', 'KaiTi', 'Noto Serif SC', serif);
  font-size: 1.75rem !important; line-height: 1.4 !important; writing-mode: horizontal-tb;
}
body .page h1, body .page h2, body .page h3 { font-family: 'STKaiti', 'KaiTi', 'Noto Serif SC', serif; }
.terms-page .term-grid { align-items: stretch; }
.terms-page .term-card > a { display: flex; flex-direction: column; height: 100%; }
.terms-page .poster { width: 100%; height: auto; aspect-ratio: 4 / 5; flex-shrink: 0; background-size: cover; background-position: center; }
.term-hero-poster .detail-poster { width: min(100%, 360px); height: auto; aspect-ratio: 4 / 5; object-fit: cover; }
.pattern-overlay { height: auto; aspect-ratio: 1; object-fit: contain; }
.pattern-overlay-hero { width: 90px; height: 90px; }
body .home-page { --scene-green: #617c61; }
.home-intro { position: relative; padding: 2.5rem 2rem; margin-bottom: 1.5rem; border: 1px solid #d8cfbc; border-radius: 24px 4px; background: linear-gradient(110deg,#fcf8ef,#e9eee3); }
.home-intro::after { content: '春生 夏长 秋收 冬藏'; position: absolute; right: 2rem; top: 2rem; writing-mode: vertical-rl; letter-spacing: .35em; color: #617c612b; font: 1.5rem 'STKaiti','KaiTi',serif; pointer-events: none; }
.home-kicker { color: #617c61; letter-spacing: .16em; font-size: .85rem; }
.home-intro h1 { margin: .6rem 0; }
.home-intro > p { max-width: 42rem; }
.home-actions,.home-today,.scene-controls { display: flex; flex-wrap: wrap; align-items: center; gap: .65rem; }
.season-scroll { position: relative; display: grid; grid-template-columns: minmax(0, 1.8fr) minmax(220px, 1fr); gap: 1.5rem; align-items: start; }
.season-stage { position: sticky; top: 1rem; height: min(760px, 88vh); min-height: 520px; border: 1px solid #d8cfbc; border-radius: 24px 4px; overflow: hidden; background: #f3f4e9; transition: background 800ms; }
.season-stage[data-season='夏'] { background: #edf3e9; }
.season-stage[data-season='秋'] { background: #f5efdf; }
.season-stage[data-season='冬'] { background: #eef1f2; }
.season-stage #inkCanvas { position: absolute; inset: 0; pointer-events: none; filter: none; }
.season-song { position: absolute; right: 1.8rem; top: 1.8rem; writing-mode: vertical-rl; font: 1.65rem/2.3 'STXingkai','STKaiti','KaiTi',serif; letter-spacing: .22em; color: #59654b21; pointer-events: none; }
.season-caption { position: relative; z-index: 1; padding: 2rem; max-width: 95%; }
body .page .season-caption h2 { font-size: 1.75rem !important; margin: .5rem 0; }
.season-caption > p { margin: .65rem 0; }
.season-picker { position: absolute; z-index: 2; bottom: 1rem; left: 1rem; right: 1rem; display: grid; grid-template-columns: repeat(6,minmax(0,1fr)); gap: .35rem; }
.season-dot { padding: .35rem .15rem; border: 1px solid #99ac8c; border-radius: 12px 2px; font: inherit; font-size: .8rem; color: #466547; background: #faf8eee8; cursor: pointer; }
.season-dot[aria-current='true'] { color: #fff9ee; background: #a54b38; border-color: #a54b38; }
.season-dot:hover { background: #dae5d2; color: #3e5b3f; }
.season-dot:focus-visible,.scene-controls a:focus-visible { outline: 3px solid #b28b43; outline-offset: 2px; }
.scene-controls button:disabled { opacity: .45; cursor: default; }
.season-panel { min-height: 48vh; display: flex; align-items: center; scroll-margin-top: 1rem; }
.season-panel:first-child { padding-top: 1rem; }
.season-note { width: 100%; padding: 1.4rem; border: 1px solid #d8cfbc; border-radius: 20px 4px; background: #fffcf3d9; box-sizing: border-box; }
.season-note h3 { margin: .75rem 0; }
.season-note .status-label { border-radius: 2px; background: #ece6d7; color: #766246; border: none; font-size: .8rem; }
.home-end { text-align: center; margin: 2rem 0; padding: 2rem; border-top: 1px solid #d8cfbc; }
.home-end .tag { margin-left: .65rem; }
@media(max-width: 800px) {
  .home-intro { padding: 1.5rem; }.home-intro::after { display: none; }
  .season-scroll { grid-template-columns: minmax(0,1fr); gap: 0; }
  .season-stage { z-index: 3; top: .3rem; height: 65vh; min-height: 410px; }
  .season-caption { padding: 1rem; }.season-caption .light { font-size: .8rem; }
  .season-song { right: .5rem; top: 1rem; font-size: 1.1rem; opacity: .7; }
  .scene-controls .tag,.scene-controls .seal-btn { padding: .4rem .5rem; font-size: .8rem; }
  .season-panel { min-height: 55vh; align-items: end; padding: 1rem 0; }
}
@media(prefers-reduced-motion: reduce) { .season-stage { transition: none; } }
@media(max-width:650px) {
 body .page h1, body .page h2.v-heading, body .page .page-title,
 body .page .story-title-horizontal, body .page .term-title,
 body .page .exhibition-heading h2, body .page .season-caption h2 { font-size: 1.5rem !important; }
}
