/* ============================================================
   博物志档案 · 夜温室 v2
   深夜温室:近黑深绿底,纸色线稿,朱砂常亮
   ============================================================ */

@property --lamp {
  syntax: "<color>";
  inherits: true;
  initial-value: rgba(199, 80, 31, .14);
}

:root {
  --night:      #12150F;
  --night-2:    #0B0D09;
  --panel:      #1B2016;
  --paper:      #EFEDE7;
  --paper-2:    #E7E4DB;
  --ink:        #1A1A1A;
  --cinnabar:   #C7501F;
  --lamp:       rgba(199, 80, 31, .14);

  --line:       .75px solid rgba(239, 237, 231, .34);
  --line-soft:  .75px solid rgba(239, 237, 231, .16);
  --line-ink:   .75px solid rgba(26, 26, 26, .55);
  --line-ink-soft: .75px solid rgba(26, 26, 26, .25);
  --serif: "Noto Serif SC", "Songti SC", serif;
  --sans: "Noto Sans SC", "PingFang SC", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --latin: "Cormorant Garamond", "Noto Serif SC", serif;
  --ease: cubic-bezier(.23, 1, .32, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--night);
  color: var(--paper);
  font-family: var(--sans);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  transition: --lamp 30s linear;
  overflow-x: hidden;
}

::selection { background: var(--cinnabar); color: var(--paper); }

a { color: inherit; }

.mono, .meta { font-family: var(--mono); }
.meta {
  font-size: 11px;
  letter-spacing: .14em;
  color: rgba(239, 237, 231, .55);
}

/* ---------- 纸纹颗粒(整页笼罩) ---------- */
.grain {
  position: fixed; inset: -50%;
  pointer-events: none;
  z-index: 80;
  opacity: .055;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='240' height='240' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
}

/* ============================================================
   第一幕 · 剖面索引
   ============================================================ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
/* 温室灯:朱砂光晕,随晨昏缓变 */
.hero::before {
  content: "";
  position: absolute; inset: -25%;
  background: radial-gradient(circle at 30% 47%, var(--lamp) 0%, transparent 52%);
  pointer-events: none;
  transition: --lamp 30s linear;
}

.hero__strip {
  position: absolute; top: 0; left: 0; right: 0;
  display: flex; justify-content: space-between;
  padding: 22px 36px;
  border-bottom: var(--line-soft);
  z-index: 5;
}

.hero__side {
  position: relative;
  z-index: 4;
  margin-left: auto;
  margin-right: clamp(24px, 6vw, 96px);
  display: flex;
  align-items: center;
  gap: clamp(24px, 3vw, 48px);
}
.hero__catalog { display: grid; gap: 14px; padding-bottom: 8vh; }
.hero__catalog .hot { color: rgba(239, 237, 231, .85); }
.hero__clock { color: rgba(199, 80, 31, .95); }

.hero__latin {
  writing-mode: vertical-rl;
  font-family: var(--latin);
  font-style: italic;
  font-size: clamp(26px, 2.6vw, 40px);
  letter-spacing: .08em;
  color: rgba(239, 237, 231, .5);
  padding-bottom: 8vh;
}

.scroll-hint {
  position: absolute;
  left: 50%; bottom: 26px;
  transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  z-index: 5;
}
.scroll-hint__line {
  width: 1px; height: 56px;
  background: rgba(239, 237, 231, .22);
  position: relative; overflow: hidden;
}
.scroll-hint__line::after {
  content: "";
  position: absolute; left: 0; top: 0;
  width: 100%; height: 100%;
  background: var(--cinnabar);
  animation: scrollHint 2.5s ease-in-out infinite;
}
@keyframes scrollHint {
  0%   { transform: translateY(-100%); }
  70%  { transform: translateY(100%); }
  100% { transform: translateY(100%); }
}

/* ---------- 剖面果 ---------- */
.citrus {
  position: relative; z-index: 2;
  height: 88vh; width: auto;
  margin-left: clamp(-140px, -7vw, -48px);
  display: block;
}
.citrus text { user-select: none; }

/* 自绘入场:线条从无到全 */
.draw {
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
}
body.is-ready .draw {
  animation: drawIn .9s cubic-bezier(.4, 0, .2, 1) var(--d, 0s) forwards;
}
@keyframes drawIn { to { stroke-dashoffset: 0; } }

.seg-text { opacity: 0; transition: opacity .6s ease 1.5s; }
body.is-ready .seg-text { opacity: 1; }

.citrus__rind, .citrus__rind-2 { fill: none; stroke: var(--paper); stroke-linecap: round; }
.citrus__rind   { stroke-width: 3;   opacity: .85; }
.citrus__rind-2 { stroke-width: 1.1; opacity: .5; }
.citrus__ring   { fill: none; stroke: rgba(239, 237, 231, .8); stroke-width: 12; opacity: .22; }

.segment__flesh {
  fill: rgba(199, 80, 31, 0);
  stroke: rgba(239, 237, 231, .85);
  stroke-width: 1.4;
  transition: fill .45s ease, filter .45s ease;
}
.segment--lit .segment__flesh { fill: rgba(199, 80, 31, .12); }
.segment:hover .segment__flesh, .segment.force .segment__flesh {
  fill: rgba(199, 80, 31, .34);
  filter: drop-shadow(0 0 16px rgba(199, 80, 31, .55));
}
.segment__vesicle {
  fill: none; stroke: rgba(239, 237, 231, .4);
  stroke-width: 1; stroke-linecap: round;
  transition: stroke .4s ease, filter .45s ease;
}
.segment:hover .segment__vesicle {
  stroke: rgba(239, 237, 231, .9);
  filter: drop-shadow(0 0 6px rgba(199, 80, 31, .8));
}
.pith { stroke: rgba(239, 237, 231, .3); stroke-width: .75; }
.segment--vacat { cursor: default; }
.segment--vacat .segment__flesh { stroke: rgba(239, 237, 231, .28); }
.segment--vacat .segment__vesicle { stroke: rgba(239, 237, 231, .14); }
.segment--vacat .pith { stroke: rgba(239, 237, 231, .12); }

.segment__label {
  font-family: var(--serif); font-weight: 700;
  font-size: 27px; letter-spacing: .2em;
  fill: var(--paper);
  text-anchor: middle;
  pointer-events: none;
  transition: fill .3s ease;
}
.segment__sublabel {
  font-family: var(--mono);
  font-size: 9px; letter-spacing: .3em;
  fill: rgba(239, 237, 231, .5);
}
.segment__label--vacat { fill: rgba(239, 237, 231, .28); }
.segment:hover .segment__label { fill: var(--cinnabar); }
.segment:hover .segment__sublabel { fill: rgba(239, 237, 231, .9); }

.citrus__hub { fill: var(--night); stroke: var(--paper); stroke-width: 1.5; opacity: .9; }
.citrus__hubdot { fill: var(--cinnabar); }
.seed { fill: var(--panel); stroke: rgba(239, 237, 231, .7); stroke-width: .75; }

/* 类型标本章(首幕角标) */
.typeseal {
  position: absolute;
  left: clamp(20px, 4vw, 64px); bottom: 34px;
  width: 64px; height: 64px;
  border: 1.5px solid var(--cinnabar);
  color: var(--cinnabar);
  display: grid; place-items: center;
  font-family: var(--serif); font-size: 13px; letter-spacing: .2em;
  writing-mode: vertical-rl;
  opacity: .9;
  cursor: pointer;
  z-index: 6;
  transition: background .3s ease;
  background: transparent;
}
.typeseal:hover { background: rgba(199, 80, 31, .14); }
.typeseal small {
  position: absolute; bottom: -20px; left: 50%; transform: translateX(-50%);
  writing-mode: horizontal-tb;
  font-family: var(--mono); font-size: 9px; letter-spacing: .3em;
  color: rgba(199, 80, 31, .8);
  white-space: nowrap;
}

/* ============================================================
   幕间通用
   ============================================================ */
.act {
  position: relative;
  min-height: 100vh;
  padding: 16vh clamp(24px, 7vw, 110px);
  display: flex; flex-direction: column; justify-content: center;
}
.act__index {
  position: absolute; top: 34px; left: clamp(24px, 7vw, 110px);
  display: flex; gap: 14px; align-items: baseline;
}
.act__index::after {
  content: ""; width: 72px; height: 1px;
  background: rgba(239, 237, 231, .3);
  align-self: center;
}

/* 逐行揭幕 */
.line-mask { display: block; overflow: hidden; }
.line-mask > span {
  display: block;
  transform: translate3d(0, 110%, 0);
  transition: transform .9s var(--ease) var(--ld, 0s);
}
.is-inview .line-mask > span { transform: translate3d(0, 0, 0); }
.fade-up {
  opacity: 0; transform: translateY(18px);
  transition: opacity .8s ease var(--ld, 0s), transform .8s var(--ease) var(--ld, 0s);
}
.is-inview .fade-up { opacity: 1; transform: none; }

/* ============================================================
   第二幕 · 物种志
   ============================================================ */
.act--species { background: var(--night-2); }

.species__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: clamp(40px, 6vw, 110px);
  align-items: center;
}
.species__kicker { margin-bottom: 3.5vh; }
.species__kicker .hot { color: var(--cinnabar); }

.display {
  font-family: var(--serif);
  font-weight: 900;
  font-size: clamp(72px, 10.5vw, 152px);
  line-height: 1.08;
  letter-spacing: .04em;
  color: var(--paper);
  margin-bottom: 4vh;
}
.display .lit { color: var(--cinnabar); }

.species__lines {
  font-family: var(--serif);
  font-size: clamp(17px, 1.55vw, 22px);
  line-height: 2.05;
  font-weight: 400;
  color: rgba(239, 237, 231, .88);
  max-width: 34em;
}
.species__facts {
  margin-top: 5vh;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  border-top: var(--line-soft);
  max-width: 560px;
}
.species__facts div {
  padding: 14px 18px 14px 0;
  border-bottom: var(--line-soft);
  display: flex; flex-direction: column; gap: 6px;
}
.species__facts dt { font-family: var(--mono); font-size: 10px; letter-spacing: .22em; color: rgba(239, 237, 231, .45); }
.species__facts dd { font-size: 14px; color: rgba(239, 237, 231, .92); }

/* 背景大字:朱砂描边「档」 */
.species__watermark {
  position: absolute;
  right: -2vw; top: 4vh;
  font-family: var(--serif); font-weight: 900;
  font-size: clamp(220px, 30vw, 420px);
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px rgba(199, 80, 31, .3);
  pointer-events: none;
  user-select: none;
}

/* 枝条:滚动中自绘 */
.branch { width: 100%; height: auto; display: block; overflow: visible; }
.branch path, .branch circle {
  fill: none; stroke: rgba(239, 237, 231, .75);
  stroke-width: 1.4; stroke-linecap: round;
  stroke-dasharray: 1; stroke-dashoffset: 1;
  transition: stroke-dashoffset 1.1s cubic-bezier(.4, 0, .2, 1) var(--d, 0s);
}
.branch circle { stroke: rgba(199, 80, 31, .9); stroke-width: 1.6; }
.branch .branch__fruit { fill: rgba(199, 80, 31, .28); stroke: rgba(199, 80, 31, .9); stroke-width: 1.6; }
.is-inview .branch path, .is-inview .branch circle { stroke-dashoffset: 0; }


/* 枝条细分图元 */
.branch .branch__vein { stroke-width: .75; opacity: .5; }
.branch .branch__wing { stroke-width: 1; opacity: .6; }
.branch .branch__petal { stroke-width: 1; opacity: .8; }
.branch .branch__calyx { stroke: rgba(199, 80, 31, .85); stroke-width: 1.2; }
.branch .branch__stipple {
  fill: rgba(199, 80, 31, .8);
  stroke: none; stroke-dasharray: none; stroke-dashoffset: 0;
  opacity: 0; transition: opacity .5s ease var(--d, 0s);
}
.is-inview .branch .branch__stipple { opacity: 1; }

/* ============================================================
   第三幕 · 通讯
   ============================================================ */
.act--contact { align-items: center; }

/* 灯下纸卡 */
.contact__lamp {
  position: absolute; inset: auto 0 0 0; height: 70%;
  background: radial-gradient(ellipse at 50% 62%, var(--lamp) 0%, transparent 60%);
  pointer-events: none;
  transition: --lamp 30s linear;
}
.label-card {
  position: relative;
  width: min(640px, 100%);
  background: var(--paper);
  color: var(--ink);
  padding: clamp(30px, 4.5vw, 52px);
  z-index: 2;
}
/* 纸叠:底下一层微偏 */
.label-card::after {
  content: "";
  position: absolute; inset: 0;
  background: var(--paper-2);
  transform: translate(10px, 10px);
  z-index: -1;
}
.label-card__head {
  display: flex; justify-content: space-between; align-items: baseline;
  border-bottom: var(--line-ink);
  padding-bottom: 14px; margin-bottom: 22px;
}
.label-card__head h2 {
  font-family: var(--serif); font-weight: 700;
  font-size: clamp(22px, 2.4vw, 28px); letter-spacing: .3em;
}
.label-card .meta { color: rgba(26, 26, 26, .55); }

.field-row {
  display: flex; align-items: baseline; gap: 16px;
  padding: 13px 0;
  border-bottom: var(--line-ink-soft);
  font-size: 15px;
}
.field-row dt {
  flex: 0 0 84px;
  font-family: var(--mono); font-size: 10px; letter-spacing: .22em;
  color: rgba(26, 26, 26, .5);
}
.field-row dd { flex: 1; }
.field-row dd a { text-decoration: none; border-bottom: .75px solid rgba(26, 26, 26, .4); }

/* 盖章复制 */
.copyable {
  position: relative;
  font: inherit; color: inherit;
  background: none; border: none; cursor: pointer;
  padding: 0 2px 1px;
  border-bottom: .75px dashed rgba(26, 26, 26, .55);
  transition: color .25s ease, border-color .25s ease;
}
.copyable:hover { color: var(--cinnabar); border-bottom-color: var(--cinnabar); }
.stamp-mini {
  position: absolute;
  top: -22px; right: -58px;
  font-family: var(--serif); font-size: 12px;
  color: var(--cinnabar);
  border: 1.2px solid var(--cinnabar);
  padding: 2px 6px;
  transform: rotate(-8deg);
  opacity: 0;
  pointer-events: none;
  white-space: nowrap;
}
.stamp-mini.show { animation: stamp .38s cubic-bezier(.2, 1.3, .4, 1) forwards; }
@keyframes stamp {
  0%   { opacity: 0; transform: scale(1.7) rotate(-8deg); }
  60%  { opacity: 1; transform: scale(.96) rotate(-8deg); }
  100% { opacity: 1; transform: scale(1) rotate(-8deg); }
}

/* 闲章 */
.seal-nick {
  position: absolute; right: 26px; bottom: 24px;
  width: 54px; height: 54px;
  border: 1.5px solid var(--cinnabar);
  color: var(--cinnabar);
  display: grid; place-items: center;
  font-family: var(--serif); font-size: 15px; letter-spacing: .1em;
  writing-mode: vertical-rl;
  transform: rotate(-6deg);
  opacity: .85;
}

/* ---------- 访客标本签 ---------- */
.visitor {
  margin-top: 26px;
  border-top: var(--line-ink);
  padding-top: 20px;
}
.visitor__form { display: flex; gap: 10px; margin: 14px 0 18px; }
.visitor__form input {
  flex: 1;
  font-family: var(--mono); font-size: 13px; letter-spacing: .06em;
  padding: 10px 12px;
  background: transparent;
  border: var(--line-ink);
  color: var(--ink);
  outline: none;
}
.visitor__form input:focus { border-color: var(--cinnabar); }
.visitor__form button, .visitor__dl {
  font-family: var(--mono); font-size: 11px; letter-spacing: .22em;
  padding: 10px 18px;
  background: var(--ink); color: var(--paper);
  border: none; cursor: pointer;
  transition: background .25s ease;
}
.visitor__form button:hover, .visitor__dl:hover { background: var(--cinnabar); }
.visitor__preview {
  display: none;
  border: var(--line-ink-soft);
  padding: 12px;
  margin-bottom: 14px;
}
.visitor__preview.on { display: block; }
.visitor__preview svg { width: 100%; height: auto; display: block; }
.visitor__dl {
  display: none;
  text-decoration: none;
  text-align: center;
}
.visitor__dl.on { display: inline-block; }

/* ============================================================
   页脚 · 到此一游印痕
   ============================================================ */
.colophon {
  position: relative;
  padding: 60px clamp(24px, 7vw, 110px) 46px;
  border-top: var(--line-soft);
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 16px;
}

/* 备案号:独占一行居中(第十三条要求"主页底部中央位置"),
   并保持字号与对比度显著可见(12px / 对比度 9.2:1),不随 .meta 弱化 */
.beian {
  flex: 0 0 100%;
  justify-content: center;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .08em;
  color: rgba(239, 237, 231, .75);
  display: flex; align-items: center; flex-wrap: wrap; gap: 6px 14px;
}
.beian a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid rgba(239, 237, 231, .28);
  transition: color .2s, border-color .2s;
}
.beian a:hover { color: var(--paper); border-bottom-color: var(--cinnabar); }

/* 备案号静态兜底:置于 <noscript> 内,仅在不执行 JS 时渲染,正常浏览不出现、不闪烁 */
.beian-fallback {
  display: flex; justify-content: center;
  padding: 0 clamp(24px, 7vw, 110px) 46px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .08em;
  color: rgba(239, 237, 231, .75);
}
.beian-fallback a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid rgba(239, 237, 231, .28);
}
.imprint {
  position: fixed;
  width: 54px; height: 54px;
  pointer-events: none;
  z-index: 70;
  opacity: 0;
}
.imprint.on { animation: stamp .38s cubic-bezier(.2, 1.3, .4, 1) forwards; opacity: .5; }

/* ============================================================
   移动端
   ============================================================ */
@media (max-width: 900px) {
  /* 移动端首幕:剖面果与注释上下排开,互不重叠 */
  .hero {
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 4vh;
    padding: 84px 0 110px;
    box-sizing: border-box;
  }
  .citrus {
    position: relative;
    left: auto; top: auto;
    transform: none;
    height: auto;
    width: min(88vw, 420px);
    margin-left: 0;
    opacity: .95;
    z-index: 1;
    flex: none;
  }
  .hero__latin { display: none; }
  .hero__side {
    margin: 0;
    padding: 0 24px;
    align-self: stretch;
    z-index: 4;
  }
  .hero__catalog { gap: 10px; max-width: none; padding-bottom: 0; }
  .hero__strip { padding: 18px 20px; }
  .typeseal { bottom: 96px; width: 52px; height: 52px; font-size: 11px; }
  .species__grid { grid-template-columns: 1fr; }
  .species__watermark { font-size: 46vw; opacity: .8; }
  .act { padding-top: 12vh; padding-bottom: 12vh; }
  .label-card::after { transform: translate(7px, 7px); }
  .stamp-mini { right: -8px; }
}

@media (prefers-reduced-motion: reduce) {
  .draw, .branch path, .branch circle { stroke-dashoffset: 0 !important; animation: none !important; transition: none !important; }
  .branch .branch__stipple { opacity: 1; }
  .seg-text { opacity: 1; transition: none; }
  .line-mask > span, .fade-up { transform: none !important; opacity: 1 !important; transition: none !important; }
  .scroll-hint__line::after { animation: none; }
  html { scroll-behavior: auto; }
}

/* ============================================================
   v3 新增组件
   ============================================================ */

/* 页眉右列 + 虫鸣开关 */
.strip__right { display: flex; align-items: center; gap: 18px; }
.cricket-toggle {
  font-family: var(--mono); font-size: 10px; letter-spacing: .22em;
  color: rgba(239, 237, 231, .55);
  background: none;
  border: .75px solid rgba(239, 237, 231, .3);
  padding: 5px 12px;
  cursor: pointer;
  transition: color .25s ease, border-color .25s ease;
}
.cricket-toggle:hover { color: var(--paper); border-color: rgba(239, 237, 231, .7); }
.cricket-toggle.on { color: var(--cinnabar); border-color: var(--cinnabar); }

/* 第二幕右列:枝条 + 近况标本 */
.species__right { display: flex; flex-direction: column; gap: 28px; }
.now-card {
  border: var(--line-soft);
  border-top: var(--line);
  padding: 18px 20px 14px;
  max-width: 340px;
}
.now-card__head {
  display: flex; justify-content: space-between;
  margin-bottom: 12px;
}
.now-card dl { display: grid; gap: 10px; }
.now-card dl > div { display: flex; gap: 14px; align-items: baseline; }
.now-card dt {
  flex: 0 0 34px;
  font-family: var(--mono); font-size: 10px; letter-spacing: .22em;
  color: rgba(239, 237, 231, .45);
}
.now-card dd { font-size: 14px; color: rgba(239, 237, 231, .9); }

/* 纸卡角落的手记 */
.note-line {
  margin-top: 20px;
  font-family: var(--serif);
  font-size: 13.5px;
  color: rgba(26, 26, 26, .6);
  border-top: var(--line-ink-soft);
  padding-top: 12px;
  transition: opacity .45s ease;
}
.note-line.is-out { opacity: 0; }

/* ---------- 标本签墙 ---------- */
.tagwall {
  width: min(760px, 100%);
  margin-top: 7vh;
  position: relative; z-index: 2;
}
.tagwall__head {
  display: flex; justify-content: space-between; align-items: baseline;
  border-top: var(--line);
  padding-top: 16px; margin-bottom: 18px;
  flex-wrap: wrap; gap: 8px;
}
.tagwall__form { display: flex; gap: 10px; margin-bottom: 26px; flex-wrap: wrap; }
.tagwall__form input {
  font-family: var(--mono); font-size: 13px;
  padding: 10px 12px;
  background: rgba(27, 32, 22, .8);
  border: .75px solid rgba(239, 237, 231, .3);
  color: var(--paper);
  outline: none;
}
.tagwall__form input:first-child { flex: 0 0 130px; }
.tagwall__form input:nth-child(2) { flex: 1; min-width: 200px; }
.tagwall__form input:focus { border-color: var(--cinnabar); }
.tagwall__form button {
  font-family: var(--mono); font-size: 11px; letter-spacing: .22em;
  padding: 10px 20px;
  background: var(--paper); color: var(--ink);
  border: none; cursor: pointer;
  transition: background .25s ease, color .25s ease;
}
.tagwall__form button:hover:not(:disabled) { background: var(--cinnabar); color: var(--paper); }
.tagwall__form button:disabled { opacity: .4; cursor: default; }
.tagwall__err { color: var(--cinnabar); margin: -14px 0 18px; }
/* 提交成功提示:与 .whisper__ok 同一处理,朱砂色是这座站里"被点亮"的语义 */
.tagwall__ok { color: var(--cinnabar); margin: -14px 0 18px; }

.tagwall__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
}
.tagcard {
  background: var(--paper);
  color: var(--ink);
  padding: 16px 16px 12px;
  transform: rotate(var(--r, 0deg));
  animation: tagIn .7s var(--ease) var(--td, 0s) backwards;
  display: flex; flex-direction: column; gap: 12px;
  min-height: 108px;
}
@keyframes tagIn {
  from { opacity: 0; transform: translateY(14px) rotate(var(--r, 0deg)); }
  to   { opacity: 1; transform: translateY(0) rotate(var(--r, 0deg)); }
}
.tagcard__msg {
  font-family: var(--serif); font-size: 14.5px; line-height: 1.7;
  flex: 1;
  overflow-wrap: break-word;
}
.tagcard footer {
  display: flex; justify-content: space-between; align-items: baseline;
  border-top: var(--line-ink-soft);
  padding-top: 8px;
}
.tagcard__name { font-family: var(--serif); font-weight: 700; font-size: 13px; }
.tagcard .meta { color: rgba(26, 26, 26, .5); font-size: 10px; }

/* ---------- 萤火光标 ---------- */
.firefly {
  position: fixed; left: 0; top: 0;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--cinnabar);
  pointer-events: none;
  z-index: 60;
}
.firefly--0 { opacity: .5; filter: blur(.5px) drop-shadow(0 0 6px rgba(199, 80, 31, .9)); }
.firefly--1 { opacity: .32; filter: blur(1px) drop-shadow(0 0 8px rgba(199, 80, 31, .7)); width: 5px; height: 5px; }
.firefly--2 { opacity: .2;  filter: blur(1.5px) drop-shadow(0 0 10px rgba(199, 80, 31, .6)); width: 4px; height: 4px; }

@media (max-width: 900px) {
  .strip__right { gap: 10px; }
  .tagwall__form input:first-child { flex: 1; }
  .tagwall__grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
  .firefly { display: none; }
  .tagcard { animation: none; }
  .note-line { transition: none; }
}

.contact__stack { display: flex; flex-direction: column; align-items: center; width: 100%; }

/* ============================================================
   v4 · 拼签墙 / 悄悄话 / 收件箱 / 预览语过渡
   ============================================================ */

/* 首幕预览语:换行时淡出淡入 */
#previewLine {
  display: inline-block;
  transition: opacity .17s ease, transform .17s ease;
}
#previewLine.is-swap { opacity: 0; transform: translateY(4px); }

/* ---------- 拼签器 ---------- */
.tagwall__tabs { display: flex; gap: 10px; margin-bottom: 20px; }
.tagwall__tabs button {
  font-family: var(--mono); font-size: 11px; letter-spacing: .22em;
  padding: 7px 16px;
  background: none;
  border: .75px solid rgba(239, 237, 231, .3);
  color: rgba(239, 237, 231, .55);
  cursor: pointer;
  transition: color .25s ease, border-color .25s ease;
}
.tagwall__tabs button.on { color: var(--cinnabar); border-color: var(--cinnabar); }

.composer__row { display: flex; gap: 14px; margin-bottom: 14px; align-items: flex-start; }
.composer__label { flex: 0 0 42px; padding-top: 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  font-family: var(--serif); font-size: 13.5px;
  padding: 6px 13px;
  background: none;
  border: .75px solid rgba(239, 237, 231, .25);
  color: rgba(239, 237, 231, .75);
  cursor: pointer;
  transition: color .2s ease, border-color .2s ease, background .2s ease;
}
.chip:hover { border-color: rgba(239, 237, 231, .6); color: var(--paper); }
.chip.on { color: var(--cinnabar); border-color: var(--cinnabar); background: rgba(199, 80, 31, .1); }
.chip--sticker { padding: 6px 9px; display: inline-flex; }
.chip--sticker svg { width: 19px; height: 19px; }

.composer__preview {
  min-height: 54px;
  margin: 18px 0 14px;
  padding: 12px 16px;
  border-left: 2px solid var(--cinnabar);
  background: rgba(27, 32, 22, .6);
  display: flex; align-items: center; gap: 12px;
  opacity: 0; transform: translateY(6px);
  transition: opacity .3s ease, transform .3s var(--ease);
}
.composer__preview.on { opacity: 1; transform: none; }
.composer__sticker { width: 24px; height: 24px; color: var(--cinnabar); flex: none; }
.composer__sentence { font-family: var(--serif); font-size: 17px; color: var(--paper); letter-spacing: .06em; }

.composer__submit { display: flex; gap: 10px; flex-wrap: wrap; }
.composer__submit input {
  font-family: var(--mono); font-size: 13px;
  padding: 10px 12px; width: 170px;
  background: rgba(27, 32, 22, .8);
  border: .75px solid rgba(239, 237, 231, .3);
  color: var(--paper); outline: none;
}
.composer__submit input:focus { border-color: var(--cinnabar); }
.composer__submit button {
  font-family: var(--mono); font-size: 11px; letter-spacing: .22em;
  padding: 10px 20px;
  background: var(--paper); color: var(--ink);
  border: none; cursor: pointer;
  transition: background .25s ease, color .25s ease;
}
.composer__submit button:hover:not(:disabled) { background: var(--cinnabar); color: var(--paper); }
.composer__submit button:disabled { opacity: .4; cursor: default; }

/* ---------- 悄悄话 ---------- */
.whisper__hint { margin-bottom: 12px; }
.whisper textarea {
  width: 100%;
  font-family: var(--sans); font-size: 14px; line-height: 1.8;
  padding: 12px 14px;
  background: rgba(27, 32, 22, .8);
  border: .75px solid rgba(239, 237, 231, .3);
  color: var(--paper); outline: none; resize: vertical;
}
.whisper textarea:focus { border-color: var(--cinnabar); }
.whisper__bar { display: flex; gap: 10px; margin-top: 10px; }
.whisper__bar input {
  font-family: var(--mono); font-size: 13px;
  padding: 10px 12px; width: 170px;
  background: rgba(27, 32, 22, .8);
  border: .75px solid rgba(239, 237, 231, .3);
  color: var(--paper); outline: none;
}
.whisper__bar button {
  font-family: var(--mono); font-size: 11px; letter-spacing: .22em;
  padding: 10px 20px;
  background: var(--paper); color: var(--ink);
  border: none; cursor: pointer;
  transition: background .25s ease, color .25s ease;
}
.whisper__bar button:hover:not(:disabled) { background: var(--cinnabar); color: var(--paper); }
.whisper__bar button:disabled { opacity: .4; cursor: default; }
.whisper__ok { color: var(--cinnabar); margin-top: 10px; }

/* 签角贴纸 */
.tagcard { position: relative; }
.tagcard__sticker {
  position: absolute; top: 10px; right: 10px;
  width: 20px; height: 20px;
  color: var(--cinnabar); opacity: .85;
}

/* ---------- 收件箱 ---------- */
.inbox {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  padding: 40px 20px;
  background: var(--night);
}
.inbox__card {
  width: min(620px, 100%);
  background: var(--paper); color: var(--ink);
  padding: clamp(28px, 4vw, 48px);
}
.inbox__card .meta { color: rgba(26, 26, 26, .55); }
.inbox__bar { display: flex; gap: 10px; }
.inbox__bar input {
  flex: 1;
  font-family: var(--mono); font-size: 13px;
  padding: 10px 12px;
  background: transparent;
  border: var(--line-ink); color: var(--ink); outline: none;
}
.inbox__bar input:focus { border-color: var(--cinnabar); }
.inbox__bar button {
  font-family: var(--mono); font-size: 11px; letter-spacing: .22em;
  padding: 10px 20px;
  background: var(--ink); color: var(--paper);
  border: none; cursor: pointer;
}
.inbox__bar button:hover:not(:disabled) { background: var(--cinnabar); }
.inbox__list { display: grid; gap: 14px; }
.inbox__note {
  border-bottom: var(--line-ink-soft);
  padding-bottom: 12px;
}
.inbox__note p { font-size: 14.5px; line-height: 1.8; margin-bottom: 8px; overflow-wrap: break-word; }
.inbox__note footer { display: flex; justify-content: space-between; font-size: 13px; }
.inbox__back { display: inline-block; margin-top: 18px; text-decoration: none; }

@media (max-width: 900px) {
  .composer__row { flex-direction: column; gap: 8px; }
  .composer__label { padding-top: 0; }
}

/* 悄悄话双输入行 */
.whisper__bar input { width: auto; flex: 1; min-width: 140px; }

/* ============================================================
   v10 · 纸质贴纸(粘在首页右上,可揭下,随处粘贴)
   ============================================================ */
/* 贴纸的家:首页右上,微微斜贴 */
.sticker-home {
  position: absolute;
  top: 92px; right: clamp(20px, 5vw, 72px);
  width: 92px; height: 92px;
  z-index: 7;
}
.sticker-home .orange-sticker__tilt { transform: rotate(-6deg); }

.orange-sticker {
  width: 92px; height: 92px;
  cursor: grab;
  touch-action: none;
  user-select: none;
  position: relative;
  z-index: 95;
  filter: drop-shadow(1px 2px 2px rgba(11, 13, 9, .4));
  transition: transform .3s var(--ease), filter .25s ease;
}
.orange-sticker__tilt { width: 100%; height: 100%; will-change: transform; }
.orange-sticker__tilt img {
  width: 100%; height: 100%; display: block;
  pointer-events: none;
  -webkit-user-drag: none;
}
.orange-sticker:hover { transform: scale(1.04); }
/* 揭起在空中:投影拉长,卷角收起 */
.orange-sticker.is-air {
  cursor: grabbing;
  transform: scale(1.1);
  filter: drop-shadow(0 16px 24px rgba(11, 13, 9, .55));
  transition: transform .18s ease-out, filter .18s ease-out;
}
/* 粘贴到页面任意处:相对文档定位,随内容滚动 */
.orange-sticker.is-loose { position: absolute; }
/* 初次到访的一次性轻晃 */
.sticker-home:not(.is-seen) .orange-sticker:not(:hover) {
  animation: sticker-hello 1.1s var(--ease) 1.8s 1 both;
}
@keyframes sticker-hello {
  0%, 100% { transform: none; }
  32% { transform: rotate(-5deg) translateY(-3px); }
  64% { transform: rotate(3deg); }
}

@media (max-width: 900px) {
  .sticker-home { top: 76px; right: 16px; width: 72px; height: 72px; }
  .orange-sticker { width: 72px; height: 72px; }
}

@media (prefers-reduced-motion: reduce) {
  .sticker-home .orange-sticker { animation: none !important; }
}

/* 放下贴纸时溅起的橘汁 */
.juice-drop {
  position: absolute;
  display: block;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #E2703A, #C7501F 65%, rgba(199, 80, 31, 0));
  pointer-events: none;
  z-index: 94;
}
.juice-ring {
  position: absolute;
  display: block;
  border-radius: 50%;
  border: 1.5px solid rgba(199, 80, 31, .55);
  pointer-events: none;
  z-index: 94;
}
