/* ============================================================
   道德經 — Tao Te Ching | TON Token
   Aged-paper, ink-brush ancient-China design system
   ============================================================ */

:root {
  --paper: #e8dcc4;
  --paper-2: #efe4cd;
  --paper-dark: #c9b896;
  --paper-shade: #b8a47e;
  --ink: #1a1410;
  --ink-soft: #2d251c;
  --ink-mute: #3d3326;
  --ink-faint: #5a4a36;
  --seal: #a83b3b;
  --seal-dark: #7a2a2a;
  --mist: #8a9088;

  --shadow-ink: 0 1px 0 rgba(26, 20, 16, 0.06),
    0 12px 40px -12px rgba(26, 20, 16, 0.18);
  --shadow-deep: 0 30px 60px -28px rgba(26, 20, 16, 0.45),
    0 8px 20px -10px rgba(26, 20, 16, 0.25);

  --ease-out-soft: cubic-bezier(0.22, 0.61, 0.36, 1);
  --ease-in-soft: cubic-bezier(0.55, 0.06, 0.68, 0.19);
}

/* ------------------------------------------------------------
   Base
   ------------------------------------------------------------ */
* {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html {
  scroll-behavior: smooth;
}

html,
body {
  background: var(--paper);
  color: var(--ink-soft);
}

body {
  position: relative;
  background:
    radial-gradient(
      ellipse at 20% 10%,
      rgba(232, 220, 196, 1) 0%,
      rgba(220, 205, 175, 1) 60%,
      rgba(196, 178, 142, 1) 100%
    );
  min-height: 100vh;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 17px;
  line-height: 1.65;
}

::selection {
  background: rgba(168, 59, 59, 0.85);
  color: #f4ead3;
}

/* ------------------------------------------------------------
   Paper texture overlay (sits above background, below content)
   ------------------------------------------------------------ */
.paper-texture {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    /* aged stains */
    radial-gradient(
      ellipse 60% 40% at 12% 22%,
      rgba(120, 95, 50, 0.18) 0%,
      transparent 100%
    ),
    radial-gradient(
      ellipse 40% 30% at 82% 78%,
      rgba(140, 80, 40, 0.16) 0%,
      transparent 100%
    ),
    radial-gradient(
      circle at 65% 12%,
      rgba(80, 60, 30, 0.1) 0%,
      transparent 60%
    ),
    /* fiber noise via stacked tiny radials */
      url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='320' height='320' viewBox='0 0 320 320'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.06 0 0 0 0 0.04 0 0 0 0 0.02 0 0 0 0.35 0'/></filter><rect width='100%' height='100%' filter='url(%23n)' opacity='0.55'/></svg>");
  mix-blend-mode: multiply;
  opacity: 0.85;
}

.paper-vignette {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(
      ellipse at center,
      transparent 40%,
      rgba(60, 40, 20, 0.18) 100%
    );
}

/* All real content sits above the paper layers */
.site-header,
section,
.site-footer {
  position: relative;
  z-index: 2;
}

/* ------------------------------------------------------------
   SCROLL PROGRESS BAR
   ------------------------------------------------------------ */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  z-index: 100;
  pointer-events: none;
  background: rgba(26, 20, 16, 0.06);
}
.scroll-progress__fill {
  display: block;
  height: 100%;
  width: 0%;
  background: linear-gradient(
    90deg,
    var(--ink) 0%,
    var(--ink-soft) 70%,
    var(--seal) 100%
  );
  transform-origin: left center;
  will-change: width;
  box-shadow: 0 0 8px rgba(168, 59, 59, 0.25);
}

/* ------------------------------------------------------------
   HEADER / NAV
   ------------------------------------------------------------ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 90;
  border-bottom: 1px solid transparent;
  background: transparent;
  transition:
    background 0.4s var(--ease-out-soft),
    border-color 0.4s var(--ease-out-soft),
    backdrop-filter 0.4s var(--ease-out-soft),
    box-shadow 0.4s var(--ease-out-soft);
}

.site-header.is-stuck {
  background: rgba(232, 220, 196, 0.78);
  border-bottom: 1px solid rgba(26, 20, 16, 0.18);
  backdrop-filter: blur(8px) saturate(1.05);
  -webkit-backdrop-filter: blur(8px) saturate(1.05);
  box-shadow: 0 4px 16px -8px rgba(26, 20, 16, 0.18);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Compact ink-button used in tight header bar */
.header-actions .ink-button {
  padding: 0.45em 0.85em;
  letter-spacing: 0.02em;
  white-space: nowrap;
  font-size: 0.72rem;
}

/* Social icon buttons (Telegram / X) — same ink aesthetic as .ink-button */
.social-button {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1.2px solid var(--ink);
  background: transparent;
  color: var(--ink);
  text-decoration: none;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: color 0.4s var(--ease-out-soft);
  flex: 0 0 auto;
}
.social-button::before {
  content: "";
  position: absolute;
  inset: -2px;
  background: var(--ink);
  transform: translateY(102%);
  transition: transform 0.45s var(--ease-out-soft);
  z-index: 0;
}
.social-button > * {
  position: relative;
  z-index: 1;
}
.social-button:hover {
  color: var(--paper-2);
}
.social-button:hover::before {
  transform: translateY(0);
}
.social-button:focus-visible {
  outline: 2px solid var(--seal);
  outline-offset: 3px;
}

/* ------------------------------------------------------------
   LANGUAGE TOGGLE
   ------------------------------------------------------------ */
.lang-toggle {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1.2px solid var(--ink);
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  padding: 0;
  position: relative;
  overflow: hidden;
  transition: color 0.4s var(--ease-out-soft);
  flex: 0 0 auto;
}
.lang-toggle::before {
  content: "";
  position: absolute;
  inset: -2px;
  background: var(--ink);
  transform: translateY(102%);
  transition: transform 0.45s var(--ease-out-soft);
  z-index: 0;
}
.lang-toggle > * {
  position: relative;
  z-index: 1;
}
.lang-toggle:hover {
  color: var(--paper-2);
}
.lang-toggle:hover::before {
  transform: translateY(0);
}
.lang-toggle:focus-visible {
  outline: 2px solid var(--seal);
  outline-offset: 3px;
}
.lang-toggle__label {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 700;
  font-size: 1.15rem;
  line-height: 1;
  letter-spacing: 0;
}
body.lang-zh .lang-toggle:not(.lang-toggle--mobile) .lang-toggle__label {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-style: italic;
  font-size: 0.92rem;
  letter-spacing: 0.06em;
}

/* Mobile version is wider — shows EN · 繁體中文 with active highlight */
.lang-toggle--mobile {
  width: auto;
  min-width: 200px;
  padding: 0.55em 1.1em;
  gap: 0.6rem;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: 1rem;
  letter-spacing: 0.06em;
}
.lang-toggle__option {
  font-family: inherit;
  color: var(--ink-mute);
  transition: color 0.3s var(--ease-out-soft);
}
.lang-toggle__option.is-active {
  color: var(--ink);
  font-weight: 600;
}
.lang-toggle--mobile:hover .lang-toggle__option {
  color: var(--paper-2);
}
.lang-toggle--mobile:hover .lang-toggle__option.is-active {
  color: #f4ead3;
}
.lang-toggle__sep {
  color: var(--ink-mute);
  opacity: 0.5;
}
.lang-toggle--mobile:hover .lang-toggle__sep {
  color: var(--paper-2);
}

/* Mobile nav lang container */
.mobile-nav__lang {
  margin-top: 1.2rem;
  display: flex;
  justify-content: center;
  width: min(280px, 80vw);
  opacity: 0;
  transform: translateY(12px);
  transition:
    opacity 0.5s var(--ease-out-soft) 0.68s,
    transform 0.5s var(--ease-out-soft) 0.68s;
}
body.menu-open .mobile-nav__lang {
  opacity: 1;
  transform: translateY(0);
}

/* Mobile nav toggle (hamburger) */
.nav-toggle {
  width: 44px;
  height: 44px;
  border: 1px solid rgba(26, 20, 16, 0.4);
  background: transparent;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  padding: 0;
  transition: border-color 0.3s var(--ease-out-soft);
}
.nav-toggle:hover {
  border-color: var(--ink);
}
.nav-toggle__bar {
  display: block;
  width: 22px;
  height: 1.6px;
  background: var(--ink);
  border-radius: 1px;
  transition: transform 0.4s var(--ease-out-soft),
    opacity 0.3s var(--ease-out-soft);
  transform-origin: center;
}
body.menu-open .nav-toggle__bar:nth-child(1) {
  transform: translateY(6.6px) rotate(45deg);
}
body.menu-open .nav-toggle__bar:nth-child(2) {
  opacity: 0;
}
body.menu-open .nav-toggle__bar:nth-child(3) {
  transform: translateY(-6.6px) rotate(-45deg);
}

/* Mobile fullscreen nav overlay */
.mobile-nav {
  position: fixed;
  inset: 0;
  z-index: 88;
  background: linear-gradient(
    180deg,
    rgba(232, 220, 196, 0.98) 0%,
    rgba(196, 178, 142, 0.98) 100%
  );
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  clip-path: circle(0% at calc(100% - 44px) 44px);
  transition: clip-path 0.7s cubic-bezier(0.77, 0, 0.175, 1);
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
}
body.menu-open .mobile-nav {
  clip-path: circle(150% at calc(100% - 44px) 44px);
  pointer-events: auto;
}
.mobile-nav__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.4rem;
  padding: 5rem 2rem 3rem;
  text-align: center;
}
.mobile-nav__char {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 900;
  font-size: clamp(5rem, 18vw, 9rem);
  color: var(--ink);
  line-height: 1;
  margin-bottom: 1rem;
  opacity: 0.85;
}
.mobile-nav__link {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(1.6rem, 6vw, 2.4rem);
  color: var(--ink);
  text-decoration: none;
  letter-spacing: 0.06em;
  position: relative;
  padding: 0.2em 0;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s var(--ease-out-soft) 0.1s,
    transform 0.5s var(--ease-out-soft) 0.1s,
    color 0.3s var(--ease-out-soft);
}
body.menu-open .mobile-nav__link {
  opacity: 1;
  transform: translateY(0);
}
body.menu-open .mobile-nav__link:nth-child(2) {
  transition-delay: 0.18s;
}
body.menu-open .mobile-nav__link:nth-child(3) {
  transition-delay: 0.26s;
}
body.menu-open .mobile-nav__link:nth-child(4) {
  transition-delay: 0.34s;
}
body.menu-open .mobile-nav__link:nth-child(5) {
  transition-delay: 0.42s;
}
body.menu-open .mobile-nav__link:nth-child(6) {
  transition-delay: 0.5s;
}
body.menu-open .mobile-nav__link:nth-child(7) {
  transition-delay: 0.58s;
}
body.menu-open .mobile-nav__link:nth-child(8) {
  transition-delay: 0.66s;
}
.mobile-nav__link:hover {
  color: var(--seal);
}
.mobile-nav__ctas {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  align-items: stretch;
  width: min(280px, 80vw);
  margin-top: 1rem;
}

.mobile-nav__cta {
  padding: 0.6em 1.6em;
  border: 1.4px solid var(--ink);
  background: var(--ink);
  color: var(--paper-2);
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: 1.1rem;
  letter-spacing: 0.06em;
  text-decoration: none;
  text-align: center;
  transition:
    background 0.3s var(--ease-out-soft),
    color 0.3s var(--ease-out-soft),
    border-color 0.3s var(--ease-out-soft);
}
.mobile-nav__cta:hover {
  background: var(--seal);
  border-color: var(--seal);
}

.mobile-nav__cta--ghost {
  background: transparent;
  color: var(--ink);
}
.mobile-nav__cta--ghost:hover {
  background: var(--ink);
  color: var(--paper-2);
  border-color: var(--ink);
}

.mobile-nav__ctas .mobile-nav__cta {
  opacity: 0;
  transform: translateY(14px);
}
body.menu-open .mobile-nav__ctas .mobile-nav__cta {
  opacity: 1;
  transform: translateY(0);
  transition:
    opacity 0.5s var(--ease-out-soft) 0.6s,
    transform 0.5s var(--ease-out-soft) 0.6s,
    background 0.3s var(--ease-out-soft),
    color 0.3s var(--ease-out-soft),
    border-color 0.3s var(--ease-out-soft);
}
body.menu-open .mobile-nav__ctas .mobile-nav__cta:nth-child(2) {
  transition-delay: 0.66s, 0.66s, 0s, 0s, 0s;
}
body.menu-open .mobile-nav__ctas .mobile-nav__cta:nth-child(3) {
  transition-delay: 0.72s, 0.72s, 0s, 0s, 0s;
}
body.menu-open .mobile-nav__ctas .mobile-nav__cta:nth-child(4) {
  transition-delay: 0.78s, 0.78s, 0s, 0s, 0s;
}

/* Mobile nav: socials row */
.mobile-nav__socials {
  display: flex;
  gap: 1rem;
  align-items: center;
  justify-content: center;
  margin-top: 1.6rem;
  padding-top: 1.4rem;
  border-top: 1px dashed rgba(26, 20, 16, 0.25);
  width: min(280px, 80vw);
  flex-wrap: wrap;
}
.mobile-nav__social {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.55em 1.1em;
  border: 1.2px solid var(--ink);
  color: var(--ink);
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: 1rem;
  letter-spacing: 0.06em;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  transition: color 0.35s var(--ease-out-soft);
  opacity: 0;
  transform: translateY(12px);
}
.mobile-nav__social::before {
  content: "";
  position: absolute;
  inset: -2px;
  background: var(--ink);
  transform: translateY(102%);
  transition: transform 0.4s var(--ease-out-soft);
  z-index: 0;
}
.mobile-nav__social > * {
  position: relative;
  z-index: 1;
}
.mobile-nav__social:hover {
  color: var(--paper-2);
}
.mobile-nav__social:hover::before {
  transform: translateY(0);
}
body.menu-open .mobile-nav__social {
  opacity: 1;
  transform: translateY(0);
  transition:
    opacity 0.5s var(--ease-out-soft) 0.74s,
    transform 0.5s var(--ease-out-soft) 0.74s,
    color 0.35s var(--ease-out-soft);
}
body.menu-open .mobile-nav__social:nth-child(2) {
  transition:
    opacity 0.5s var(--ease-out-soft) 0.82s,
    transform 0.5s var(--ease-out-soft) 0.82s,
    color 0.35s var(--ease-out-soft);
}

body.menu-open {
  overflow: hidden;
}

.nav-link {
  position: relative;
  transition: color 0.3s var(--ease-out-soft);
}
.nav-link:hover {
  color: var(--ink);
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 100%;
  height: 1px;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s var(--ease-out-soft);
}
.nav-link:hover::after {
  transform: scaleX(1);
}

/* ------------------------------------------------------------
   INK BUTTON
   ------------------------------------------------------------ */
.ink-button {
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
  padding: 0.7em 1.4em;
  border: 1.2px solid var(--ink);
  background: transparent;
  color: var(--ink);
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-decoration: none;
  cursor: pointer;
  position: relative;
  transition: all 0.4s var(--ease-out-soft);
  overflow: hidden;
}

.ink-button::before {
  content: "";
  position: absolute;
  inset: -2px;
  background: var(--ink);
  transform: translateY(102%);
  transition: transform 0.45s var(--ease-out-soft);
  z-index: 0;
}

.ink-button > * {
  position: relative;
  z-index: 1;
}

.ink-button:hover {
  color: var(--paper-2);
}
.ink-button:hover::before {
  transform: translateY(0);
}

.ink-button--primary {
  background: var(--ink);
  color: var(--paper-2);
}
.ink-button--primary::before {
  background: var(--seal);
  transform: translateY(102%);
}
.ink-button--primary:hover {
  color: #f4ead3;
}
.ink-button--primary:hover::before {
  transform: translateY(0);
}

/* ------------------------------------------------------------
   HERO
   ------------------------------------------------------------ */
.hero {
  position: relative;
  min-height: 100vh;
  padding: 4rem 1.5rem 6rem;
  overflow: hidden;
}

/* Background portrait of Durov in ink-painting style */
.hero-portrait {
  position: absolute;
  top: -4%;
  right: -8%;
  width: 70%;
  height: 110%;
  z-index: 0;
  background: url("assets/durov-tao.png") right center / cover no-repeat;
  filter: grayscale(0.55) sepia(0.32) contrast(0.92) brightness(1.04);
  mix-blend-mode: multiply;
  -webkit-mask-image: radial-gradient(
    ellipse 70% 80% at 70% 45%,
    rgba(0, 0, 0, 0.95) 25%,
    rgba(0, 0, 0, 0.55) 55%,
    transparent 82%
  );
  mask-image: radial-gradient(
    ellipse 70% 80% at 70% 45%,
    rgba(0, 0, 0, 0.95) 25%,
    rgba(0, 0, 0, 0.55) 55%,
    transparent 82%
  );
  opacity: 0.34;
  pointer-events: none;
  will-change: transform;
}

.hero-mountains {
  position: absolute;
  inset: auto 0 0 0;
  width: 100%;
  height: 70%;
  z-index: 1;
  pointer-events: none;
}
.mtn-far,
.mtn-mid,
.mtn-near,
.pines {
  filter: url(#inkBleed);
  will-change: transform;
}

.hero-birds {
  position: absolute;
  inset: 0 0 auto 0;
  width: 100%;
  height: 60%;
  z-index: 2;
  pointer-events: none;
}
.bird {
  opacity: 0.85;
}

.hero-enso {
  position: absolute;
  top: 48%;
  left: 62%;
  width: min(72vh, 760px);
  height: min(72vh, 760px);
  transform: translate(-50%, -50%);
  z-index: 1;
  pointer-events: none;
  opacity: 0.5;
}

.enso-stroke {
  /* Length is approx 1700 — pre-set in CSS; JS will refine via getTotalLength */
  stroke-dasharray: 1700;
  stroke-dashoffset: 1700;
  filter: url(#inkBleed);
}

.hero-content {
  position: relative;
  z-index: 5;
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(400px, 1.4fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
  min-height: calc(100vh - 10rem);
}

/* --- Calligraphy stack (left) --- */
.hero-calligraphy {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  padding-top: 2rem;
}

.calligraphy-stack {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(0.5rem, 1.5vw, 1.2rem);
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 900;
  font-size: clamp(5rem, 12vw, 11rem);
  line-height: 1;
  color: var(--ink);
  text-shadow:
    0 1px 0 rgba(26, 20, 16, 0.1),
    1px 2px 0 rgba(168, 59, 59, 0.04);
}

.han-char {
  display: block;
  opacity: 0;
  filter: blur(18px);
  transform: translateY(-12px) scale(0.95);
  letter-spacing: 0;
  position: relative;
}

.han-char.is-revealed {
  animation: inkAbsorb 1.2s var(--ease-out-soft) forwards;
}

@keyframes inkAbsorb {
  0% {
    opacity: 0;
    filter: blur(22px);
    transform: translateY(-18px) scale(0.92);
  }
  60% {
    opacity: 0.9;
    filter: blur(2px);
    transform: translateY(2px) scale(1.02);
  }
  100% {
    opacity: 1;
    filter: blur(0);
    transform: translateY(0) scale(1);
  }
}

.seal-stamp {
  opacity: 0;
  transform: scale(0.4) rotate(-12deg);
  filter: drop-shadow(0 6px 14px rgba(122, 42, 42, 0.35));
}
.seal-stamp.is-stamped {
  animation: stampDown 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes stampDown {
  0% {
    opacity: 0;
    transform: scale(2) rotate(-12deg);
    filter: drop-shadow(0 0 0 rgba(122, 42, 42, 0));
  }
  60% {
    opacity: 1;
    transform: scale(0.9) rotate(-3deg);
  }
  100% {
    opacity: 1;
    transform: scale(1) rotate(-3deg);
    filter: drop-shadow(0 6px 14px rgba(122, 42, 42, 0.35));
  }
}

.seal-mini {
  display: inline-flex;
}

/* --- Hero info (right) --- */
.hero-info {
  display: flex;
  flex-direction: column;
  gap: 1.4rem;
  max-width: 620px;
}

[data-fade] {
  opacity: 0;
  transform: translateY(14px);
}

/* Paper-halo for hero text overlapping the portrait */
.hero-info > .overline,
.hero-info > .hero-byline,
.hero-info > .hero-tagline,
.hero-info > .hero-title {
  text-shadow:
    0 0 14px rgba(244, 234, 211, 0.95),
    0 0 32px rgba(232, 220, 196, 0.85),
    0 0 4px rgba(244, 234, 211, 0.8);
}

.overline {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: 0.92rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-mute);
}
.overline .line {
  flex: 0 0 38px;
  height: 1px;
  background: var(--ink-mute);
  opacity: 0.5;
}

.hero-title {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  line-height: 1;
}
.title-han {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 700;
  font-size: clamp(2.6rem, 4.5vw, 4.2rem);
  color: var(--ink);
  letter-spacing: 0.08em;
}
.title-en {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-weight: 500;
  font-size: clamp(1.4rem, 2.4vw, 2.2rem);
  color: var(--ink-soft);
}

.hero-byline {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: clamp(0.9rem, 1.05vw, 1rem);
  color: var(--ink-mute);
  letter-spacing: 0.04em;
  margin-top: -0.2rem;
}
.hero-byline strong {
  font-style: normal;
  font-weight: 600;
  color: var(--ink);
  border-bottom: 1px dotted rgba(168, 59, 59, 0.4);
}
.hero-byline em {
  font-style: italic;
  color: var(--ink-soft);
}

.hero-tagline {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: clamp(1.05rem, 1.6vw, 1.3rem);
  color: var(--ink-mute);
  border-left: 2px solid var(--seal);
  padding-left: 1rem;
  max-width: 30ch;
}

/* --- CA card --- */
.ca-card {
  background: linear-gradient(
    180deg,
    rgba(247, 238, 217, 0.85) 0%,
    rgba(232, 220, 196, 0.7) 100%
  );
  border: 1px solid rgba(26, 20, 16, 0.18);
  padding: 1rem 1.2rem;
  position: relative;
  box-shadow: var(--shadow-ink);
  backdrop-filter: blur(2px);
}

.ca-card::before,
.ca-card::after {
  content: "";
  position: absolute;
  width: 14px;
  height: 14px;
  border: 1px solid rgba(26, 20, 16, 0.4);
}
.ca-card::before {
  top: -1px;
  left: -1px;
  border-right: none;
  border-bottom: none;
}
.ca-card::after {
  bottom: -1px;
  right: -1px;
  border-left: none;
  border-top: none;
}

.ca-card__label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin-bottom: 0.55rem;
}

.ca-card__address {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-family: "JetBrains Mono", monospace;
  font-size: clamp(0.7rem, 1vw, 0.86rem);
  color: var(--ink);
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
  text-align: left;
  position: relative;
  transition: color 0.3s var(--ease-out-soft);
}
.ca-card__address:hover {
  color: var(--seal);
}
.ca-card__addr-text {
  flex: 1;
  word-break: break-all;
  line-height: 1.4;
}
.ca-card__copy-icon {
  flex: 0 0 auto;
  color: var(--ink-mute);
  transition: transform 0.3s var(--ease-out-soft), color 0.3s var(--ease-out-soft);
}
.ca-card__address:hover .ca-card__copy-icon {
  color: var(--seal);
  transform: translateY(-2px);
}

.ca-card__copied {
  position: absolute;
  inset: auto auto -8px 50%;
  transform: translate(-50%, 0) scale(0.9);
  background: var(--seal);
  color: #f4ead3;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  padding: 0.25em 0.9em;
  pointer-events: none;
  opacity: 0;
  transition: all 0.4s var(--ease-out-soft);
  white-space: nowrap;
}
.ca-card.is-copied .ca-card__copied {
  opacity: 1;
  transform: translate(-50%, 6px) scale(1);
}

/* --- Live stats --- */
.live-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid rgba(26, 20, 16, 0.18);
  border-bottom: 1px solid rgba(26, 20, 16, 0.18);
  padding: 0.8rem 0;
  list-style: none;
}
.live-stats li {
  padding: 0.2rem 0.8rem;
  border-right: 1px dashed rgba(26, 20, 16, 0.18);
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}
.live-stats li:last-child {
  border-right: 0;
}
.live-stats__label {
  font-size: 0.66rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-faint);
  text-shadow: 0 0 10px rgba(244, 234, 211, 0.85);
}
.live-stats__value {
  font-family: "JetBrains Mono", monospace;
  font-size: clamp(0.92rem, 1.2vw, 1.05rem);
  color: var(--ink);
  font-weight: 500;
  letter-spacing: 0.02em;
  text-shadow: 0 0 10px rgba(244, 234, 211, 0.8);
  transition: color 0.3s var(--ease-out-soft), transform 0.3s var(--ease-out-soft);
}
.live-stats__value.is-pulse {
  animation: valuePulse 0.8s var(--ease-out-soft);
}
@keyframes valuePulse {
  0% {
    color: var(--ink);
  }
  40% {
    color: var(--seal);
    transform: translateY(-2px);
  }
  100% {
    color: var(--ink);
    transform: translateY(0);
  }
}

/* --- Hero CTAs --- */
.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

/* --- Scroll indicator --- */
.scroll-indicator {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 6;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--ink-mute);
  text-decoration: none;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  letter-spacing: 0.18em;
  font-size: 0.78rem;
  text-transform: uppercase;
  transition: color 0.3s var(--ease-out-soft);
}
.scroll-indicator:hover {
  color: var(--ink);
}
.scroll-indicator__arrow {
  animation: bobDown 2.4s ease-in-out infinite;
}
@keyframes bobDown {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(8px);
  }
}

/* ------------------------------------------------------------
   PHILOSOPHY SECTION
   ------------------------------------------------------------ */
.philosophy {
  position: relative;
  background: linear-gradient(
    180deg,
    rgba(232, 220, 196, 0) 0%,
    rgba(220, 205, 175, 0.6) 30%,
    rgba(220, 205, 175, 0.6) 70%,
    rgba(232, 220, 196, 0) 100%
  );
}

.philosophy::before {
  content: "";
  position: absolute;
  top: 8%;
  right: -4vw;
  width: 32vw;
  height: 32vw;
  background-image: radial-gradient(
    circle,
    rgba(26, 20, 16, 0.1) 0%,
    transparent 60%
  );
  pointer-events: none;
}

.philosophy-heading {
  text-align: center;
  margin-bottom: 4rem;
  position: relative;
}
.philosophy-heading__big {
  display: block;
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 900;
  font-size: clamp(5rem, 10vw, 9rem);
  color: var(--ink);
  line-height: 1;
  margin-bottom: -0.1em;
  opacity: 0.92;
}
.philosophy-heading__title {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-weight: 500;
  font-size: clamp(2rem, 3.5vw, 3.2rem);
  color: var(--ink);
  letter-spacing: 0.04em;
  margin: 0;
}
.philosophy-heading__sub {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  color: var(--ink-mute);
  font-size: 1.05rem;
  margin-top: 0.7rem;
  letter-spacing: 0.06em;
}

.philosophy-grid {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.philosophy-grid {
  perspective: 1400px;
}

/* Tablet */
.tablet {
  display: grid;
  grid-template-columns: 0.6fr 1.4fr;
  gap: clamp(1rem, 4vw, 3rem);
  align-items: stretch;
  background: linear-gradient(
    180deg,
    rgba(247, 238, 217, 0.92) 0%,
    rgba(225, 210, 178, 0.85) 100%
  );
  border: 1px solid rgba(26, 20, 16, 0.18);
  padding: clamp(1.6rem, 3vw, 3rem);
  position: relative;
  box-shadow: var(--shadow-ink);
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.9s var(--ease-out-soft),
    transform 0.9s var(--ease-out-soft),
    box-shadow 0.4s var(--ease-out-soft);
  transform-style: preserve-3d;
  will-change: transform;
}
.tablet.is-tilted {
  transition: transform 0.15s var(--ease-out-soft),
    box-shadow 0.3s var(--ease-out-soft);
  box-shadow:
    0 30px 60px -28px rgba(26, 20, 16, 0.35),
    0 12px 24px -8px rgba(168, 59, 59, 0.18);
}

.tablet.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.tablet::before,
.tablet::after {
  content: "";
  position: absolute;
  width: 22px;
  height: 22px;
  border: 1px solid rgba(26, 20, 16, 0.4);
  pointer-events: none;
}
.tablet::before {
  top: 8px;
  left: 8px;
  border-right: none;
  border-bottom: none;
}
.tablet::after {
  bottom: 8px;
  right: 8px;
  border-left: none;
  border-top: none;
}

.tablet__char {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 900;
  font-size: clamp(8rem, 18vw, 16rem);
  line-height: 1;
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.88;
  letter-spacing: 0;
  text-shadow: 0 1px 0 rgba(168, 59, 59, 0.06),
    1px 2px 0 rgba(26, 20, 16, 0.05);
  position: relative;
}

.tablet__inner {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  justify-content: center;
}

.tablet__num {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: 0.95rem;
  letter-spacing: 0.3em;
  color: var(--seal);
  text-transform: uppercase;
}

.tablet__title {
  font-family: "Cormorant Garamond", serif;
  font-weight: 600;
  font-size: clamp(1.6rem, 2.5vw, 2.2rem);
  color: var(--ink);
  letter-spacing: 0.04em;
  margin: 0;
  line-height: 1.1;
}

.tablet p {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(1rem, 1.2vw, 1.12rem);
  line-height: 1.75;
  color: var(--ink-soft);
}
.tablet p + p {
  margin-top: 0.8em;
}

.tablet__highlight {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 700;
  color: var(--ink);
  font-size: 1.25em;
  margin: 0 0.05em;
}

.tablet em {
  font-style: italic;
  color: var(--ink);
}

/* Divider character between tablets */
.philosophy-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(1.5rem, 3vw, 3rem) 0;
  position: relative;
}
.philosophy-divider::before,
.philosophy-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(26, 20, 16, 0.3) 50%,
    transparent
  );
  margin: 0 1.5rem;
}
.philosophy-divider span {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 700;
  font-size: clamp(2.5rem, 5vw, 4rem);
  color: var(--ink);
  opacity: 0;
  transform: scale(0.7);
  transition: opacity 0.9s var(--ease-out-soft),
    transform 0.9s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.philosophy-divider.is-visible span {
  opacity: 0.85;
  transform: scale(1);
}

/* ------------------------------------------------------------
   MARKET / CHART
   ------------------------------------------------------------ */
.market {
  position: relative;
}

.market-heading {
  text-align: center;
  margin-bottom: 3rem;
}
.market-heading__char {
  display: block;
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 900;
  font-size: clamp(4rem, 8vw, 7rem);
  color: var(--ink);
  line-height: 1;
}
.market-heading h2 {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-weight: 500;
  font-size: clamp(2rem, 3vw, 2.8rem);
  color: var(--ink);
  margin: 0.2rem 0 0.5rem;
}
.market-heading p {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  color: var(--ink-mute);
  font-size: 1.05rem;
}
.market-heading a {
  color: var(--seal);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Scroll frame around the chart iframe */
.scroll-frame {
  position: relative;
  margin: 0 auto;
  max-width: 1100px;
  background: linear-gradient(
    180deg,
    rgba(247, 238, 217, 0.92) 0%,
    rgba(225, 210, 178, 0.85) 100%
  );
  border-left: 1px solid rgba(26, 20, 16, 0.25);
  border-right: 1px solid rgba(26, 20, 16, 0.25);
  padding: 1rem;
  box-shadow: var(--shadow-deep);
}

.scroll-frame__top,
.scroll-frame__bottom {
  position: absolute;
  left: -14px;
  right: -14px;
  height: 26px;
  background: linear-gradient(
    180deg,
    var(--ink-mute) 0%,
    var(--ink-soft) 50%,
    var(--ink-mute) 100%
  );
  border-radius: 13px;
  box-shadow:
    inset 0 1px 0 rgba(255, 240, 210, 0.2),
    0 6px 14px -6px rgba(26, 20, 16, 0.4);
}
.scroll-frame__top::before,
.scroll-frame__bottom::before,
.scroll-frame__top::after,
.scroll-frame__bottom::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 28px;
  height: 28px;
  background: var(--ink);
  border-radius: 50%;
  transform: translateY(-50%);
  box-shadow: inset 0 0 0 3px var(--paper-2),
    inset 0 0 0 4px var(--ink);
}
.scroll-frame__top::before,
.scroll-frame__bottom::before {
  left: -8px;
}
.scroll-frame__top::after,
.scroll-frame__bottom::after {
  right: -8px;
}
.scroll-frame__top {
  top: -13px;
}
.scroll-frame__bottom {
  bottom: -13px;
}

.scroll-frame__inner {
  position: relative;
  background: var(--paper);
  border: 1px solid rgba(26, 20, 16, 0.3);
  overflow: hidden;
  aspect-ratio: 16 / 10;
  width: 100%;
}

.scroll-frame__inner iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  filter: sepia(0.18) contrast(0.96);
}

/* Market summary grid below chart */
.market-summary {
  margin: 2rem auto 0;
  max-width: 1100px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background: rgba(26, 20, 16, 0.18);
  border: 1px solid rgba(26, 20, 16, 0.18);
}
.market-summary > div {
  background: rgba(247, 238, 217, 0.85);
  padding: 1rem 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.market-summary span {
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-mute);
}
.market-summary strong {
  font-family: "JetBrains Mono", monospace;
  font-size: clamp(1rem, 1.4vw, 1.2rem);
  font-weight: 500;
  color: var(--ink);
}

/* ------------------------------------------------------------
   FOUNDER SECTION
   ------------------------------------------------------------ */
.founder {
  position: relative;
  background: linear-gradient(
    180deg,
    rgba(232, 220, 196, 0) 0%,
    rgba(196, 178, 142, 0.32) 100%
  );
  overflow: hidden;
}
.founder::before {
  content: "老";
  position: absolute;
  top: 5%;
  left: -3vw;
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 900;
  font-size: clamp(14rem, 28vw, 28rem);
  color: var(--ink);
  opacity: 0.05;
  line-height: 1;
  pointer-events: none;
  z-index: 0;
}

.founder-grid {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) 1.4fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
  position: relative;
  z-index: 1;
}

.founder-portrait {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
}

.founder-portrait__frame {
  position: relative;
  width: 100%;
  max-width: 460px;
  aspect-ratio: 4 / 5;
  background: var(--paper-2);
  padding: 18px;
  border: 1px solid rgba(26, 20, 16, 0.35);
  box-shadow: var(--shadow-deep);
}
.founder-portrait__frame::before {
  content: "";
  position: absolute;
  inset: 6px;
  border: 1px dashed rgba(26, 20, 16, 0.3);
  pointer-events: none;
}
.founder-portrait__frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: sepia(0.18) contrast(0.96) saturate(0.92);
}

.founder-portrait__brush {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(
    ellipse 60% 25% at 50% 105%,
    rgba(26, 20, 16, 0.35) 0%,
    transparent 70%
  );
}

.founder-portrait__seal {
  position: absolute;
  bottom: -16px;
  right: -10px;
  filter: drop-shadow(0 6px 14px rgba(122, 42, 42, 0.35));
  transform: rotate(-6deg);
}

.founder-portrait figcaption {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: 0.92rem;
  color: var(--ink-mute);
  letter-spacing: 0.04em;
  text-align: center;
  max-width: 36ch;
}
.founder-portrait figcaption em {
  color: var(--ink);
  font-style: italic;
}

.founder-text {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.founder-eyebrow {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-size: 0.85rem;
  color: var(--seal);
}
.founder-title {
  font-family: "Cormorant Garamond", serif;
  font-weight: 600;
  font-style: italic;
  font-size: clamp(2rem, 3.4vw, 3rem);
  line-height: 1.05;
  color: var(--ink);
  margin: 0 0 0.6rem;
  letter-spacing: 0.02em;
}
.founder-text p {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(1.02rem, 1.2vw, 1.14rem);
  line-height: 1.75;
  color: var(--ink-soft);
}
.founder-text p + p {
  margin-top: 0.4em;
}
.founder-han {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 700;
  font-size: 1.25em;
  color: var(--ink);
}

/* VK signature replica card (clickable link) */
.vk-signature {
  display: block;
  margin-top: 1.5rem;
  background: rgba(247, 238, 217, 0.85);
  border: 1px solid rgba(26, 20, 16, 0.18);
  border-left: 3px solid var(--seal);
  padding: 1rem 1.2rem;
  box-shadow: var(--shadow-ink);
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  position: relative;
  transition:
    transform 0.35s var(--ease-out-soft),
    border-color 0.35s var(--ease-out-soft),
    box-shadow 0.35s var(--ease-out-soft),
    background 0.35s var(--ease-out-soft);
}
.vk-signature:hover {
  transform: translateY(-2px);
  border-color: rgba(26, 20, 16, 0.32);
  border-left-color: var(--seal-dark);
  background: rgba(247, 238, 217, 0.95);
  box-shadow:
    0 18px 38px -16px rgba(26, 20, 16, 0.32),
    0 6px 14px -6px rgba(168, 59, 59, 0.18);
}
.vk-signature:hover .vk-signature__open {
  opacity: 1;
  transform: translate(0, -2px);
  color: var(--seal);
}
.vk-signature:focus-visible {
  outline: 2px solid var(--seal);
  outline-offset: 3px;
}
.vk-signature__open {
  margin-left: 0.4rem;
  display: inline-flex;
  align-items: center;
  color: var(--ink-mute);
  opacity: 0.55;
  transform: translate(-2px, 0);
  transition:
    opacity 0.35s var(--ease-out-soft),
    transform 0.35s var(--ease-out-soft),
    color 0.35s var(--ease-out-soft);
}
.vk-signature__head {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding-bottom: 0.7rem;
  border-bottom: 1px dashed rgba(26, 20, 16, 0.18);
  margin-bottom: 0.8rem;
}
.vk-signature__avatar {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--paper-2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "Cormorant Garamond", serif;
  font-weight: 600;
  font-size: 0.92rem;
  letter-spacing: 0.05em;
}
.vk-signature__name {
  font-family: "Cormorant Garamond", serif;
  font-weight: 600;
  color: var(--ink);
  font-size: 1rem;
  margin: 0;
}
.vk-signature__url {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.72rem;
  color: var(--ink-mute);
  margin: 0;
}
.vk-signature__verified {
  margin-left: auto;
  color: var(--seal);
  display: inline-flex;
}
.vk-signature__bio {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 700;
  font-size: clamp(2.2rem, 4vw, 3rem);
  color: var(--ink);
  margin: 0.4rem 0 0.6rem;
  letter-spacing: 0.12em;
  text-align: center;
}
.vk-signature__foot {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: 0.78rem;
  color: var(--ink-mute);
  letter-spacing: 0.06em;
  text-align: center;
  margin: 0;
}

/* ------------------------------------------------------------
   VERSES SECTION
   ------------------------------------------------------------ */
.verses {
  position: relative;
  overflow: hidden;
  background: linear-gradient(
    180deg,
    rgba(232, 220, 196, 0) 0%,
    rgba(220, 205, 175, 0.3) 50%,
    rgba(232, 220, 196, 0) 100%
  );
}
.verses__bg-char {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 900;
  font-size: clamp(20rem, 50vw, 50rem);
  color: var(--ink);
  opacity: 0.05;
  line-height: 1;
  pointer-events: none;
  user-select: none;
}
.verses__eyebrow {
  display: block;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-mute);
  font-size: 0.85rem;
  margin-bottom: 2rem;
  position: relative;
  z-index: 2;
}
.verses__stage {
  position: relative;
  z-index: 2;
  min-height: 200px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}
.verses__han {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 700;
  font-size: clamp(2.4rem, 5vw, 4rem);
  color: var(--ink);
  letter-spacing: 0.18em;
  margin: 0;
  line-height: 1.2;
  transition: opacity 0.7s var(--ease-out-soft),
    transform 0.7s var(--ease-out-soft),
    filter 0.7s var(--ease-out-soft);
}
.verses__en {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: clamp(1.05rem, 1.5vw, 1.3rem);
  color: var(--ink-mute);
  margin: 0;
  max-width: 44ch;
  transition: opacity 0.7s var(--ease-out-soft),
    transform 0.7s var(--ease-out-soft);
}
.verses__stage.is-out .verses__han {
  opacity: 0;
  transform: translateY(-8px);
  filter: blur(6px);
}
.verses__stage.is-out .verses__en {
  opacity: 0;
  transform: translateY(8px);
}

.verses__dots {
  display: flex;
  gap: 0.55rem;
  justify-content: center;
  margin-top: 2rem;
  position: relative;
  z-index: 2;
}
.verses__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(26, 20, 16, 0.2);
  cursor: pointer;
  border: 0;
  padding: 0;
  transition: background 0.3s var(--ease-out-soft),
    transform 0.3s var(--ease-out-soft);
}
.verses__dot.is-active {
  background: var(--seal);
  transform: scale(1.3);
}

.verses__next {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.2rem;
  background: transparent;
  border: 0;
  color: var(--ink-mute);
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 0.78rem;
  cursor: pointer;
  position: relative;
  z-index: 2;
  transition: color 0.3s var(--ease-out-soft),
    transform 0.3s var(--ease-out-soft);
}
.verses__next:hover {
  color: var(--ink);
  transform: translateX(3px);
}

/* ------------------------------------------------------------
   THE BOOK — Open the Scroll
   ------------------------------------------------------------ */
.book {
  position: relative;
  overflow: hidden;
  background: linear-gradient(
    180deg,
    rgba(232, 220, 196, 0) 0%,
    rgba(196, 178, 142, 0.28) 50%,
    rgba(232, 220, 196, 0) 100%
  );
}
.book__bg-char {
  position: absolute;
  top: 50%;
  right: -8vw;
  transform: translateY(-50%);
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 900;
  font-size: clamp(18rem, 42vw, 42rem);
  color: var(--ink);
  opacity: 0.05;
  line-height: 1;
  pointer-events: none;
  user-select: none;
  z-index: 0;
}

.book__heading {
  text-align: center;
  margin-bottom: 3rem;
  position: relative;
  z-index: 1;
}
.book__eyebrow {
  display: inline-block;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  font-size: 0.85rem;
  color: var(--seal);
  margin-bottom: 0.6rem;
}
.book__title {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-weight: 600;
  font-size: clamp(2.2rem, 3.6vw, 3.4rem);
  color: var(--ink);
  line-height: 1.05;
  margin: 0 0 0.6rem;
  letter-spacing: 0.02em;
}
.book__sub {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  color: var(--ink-mute);
  font-size: clamp(1rem, 1.3vw, 1.15rem);
  max-width: 52ch;
  margin: 0 auto;
}

/* Scroll container with rolled top/bottom */
.book-scroll {
  position: relative;
  z-index: 1;
  margin: 0 auto;
  max-width: 760px;
  padding: 1rem;
  background: linear-gradient(
    180deg,
    rgba(247, 238, 217, 0.92) 0%,
    rgba(225, 210, 178, 0.85) 100%
  );
  border-left: 1px solid rgba(26, 20, 16, 0.25);
  border-right: 1px solid rgba(26, 20, 16, 0.25);
  box-shadow: var(--shadow-deep);
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity 1s var(--ease-out-soft),
    transform 1s var(--ease-out-soft);
}
.book-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.book-scroll__top,
.book-scroll__bottom {
  position: absolute;
  left: -14px;
  right: -14px;
  height: 26px;
  background: linear-gradient(
    180deg,
    var(--ink-mute) 0%,
    var(--ink-soft) 50%,
    var(--ink-mute) 100%
  );
  border-radius: 13px;
  box-shadow:
    inset 0 1px 0 rgba(255, 240, 210, 0.2),
    0 6px 14px -6px rgba(26, 20, 16, 0.4);
}
.book-scroll__top::before,
.book-scroll__top::after,
.book-scroll__bottom::before,
.book-scroll__bottom::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 28px;
  height: 28px;
  background: var(--ink);
  border-radius: 50%;
  transform: translateY(-50%);
  box-shadow:
    inset 0 0 0 3px var(--paper-2),
    inset 0 0 0 4px var(--ink);
}
.book-scroll__top::before,
.book-scroll__bottom::before {
  left: -8px;
}
.book-scroll__top::after,
.book-scroll__bottom::after {
  right: -8px;
}
.book-scroll__top {
  top: -13px;
}
.book-scroll__bottom {
  bottom: -13px;
}

.book-scroll__paper {
  position: relative;
  background: var(--paper-2);
  border: 1px solid rgba(26, 20, 16, 0.22);
  padding: clamp(2rem, 5vw, 3.5rem) clamp(1.4rem, 4vw, 3rem);
  text-align: center;
  overflow: hidden;
}
.book-scroll__paper::before,
.book-scroll__paper::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  border: 1px solid rgba(26, 20, 16, 0.3);
  pointer-events: none;
}
.book-scroll__paper::before {
  top: 8px;
  left: 8px;
  border-right: none;
  border-bottom: none;
}
.book-scroll__paper::after {
  bottom: 8px;
  right: 8px;
  border-left: none;
  border-top: none;
}

.book-scroll__chapter {
  display: inline-block;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-size: 0.78rem;
  color: var(--seal);
  margin-bottom: 1.4rem;
}

.book-scroll__han {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 700;
  font-size: clamp(1.6rem, 3.2vw, 2.6rem);
  line-height: 1.7;
  letter-spacing: 0.18em;
  color: var(--ink);
  margin: 0 0 1.6rem;
  text-shadow:
    0 1px 0 rgba(168, 59, 59, 0.05),
    1px 2px 0 rgba(26, 20, 16, 0.04);
}

.book-scroll__divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
  margin: 1.2rem auto 1.4rem;
  max-width: 60%;
}
.book-scroll__divider span {
  flex: 1;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(26, 20, 16, 0.35) 50%,
    transparent
  );
}
.book-scroll__divider em {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 600;
  font-style: normal;
  font-size: 1.1rem;
  color: var(--ink-mute);
  line-height: 1;
}

.book-scroll__ru {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: clamp(1.05rem, 1.4vw, 1.2rem);
  line-height: 1.7;
  color: var(--ink-soft);
  max-width: 50ch;
  margin: 0 auto 0.8rem;
}

.book-scroll__cite {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  letter-spacing: 0.06em;
  font-size: 0.86rem;
  color: var(--ink-mute);
  margin: 0;
}

.book-scroll__seal {
  position: absolute;
  bottom: 16px;
  right: 16px;
  filter: drop-shadow(0 4px 10px rgba(122, 42, 42, 0.32));
  transform: rotate(-4deg);
  opacity: 0.92;
}

.book__cta-wrap {
  position: relative;
  z-index: 1;
  margin-top: 2.4rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.7rem;
}
.book__cta {
  font-size: 1rem;
  padding: 0.85em 1.8em;
  letter-spacing: 0.06em;
}
.book__cta-fineprint {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: 0.82rem;
  color: var(--ink-mute);
  letter-spacing: 0.04em;
  text-align: center;
  margin: 0;
  max-width: 44ch;
}

/* ------------------------------------------------------------
   CHART SKELETON (loader for iframe)
   ------------------------------------------------------------ */
.scroll-frame__skeleton {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: var(--paper-2);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  padding: 2rem;
  transition: opacity 0.6s var(--ease-out-soft);
  pointer-events: none;
}
.scroll-frame__skeleton.is-hidden {
  opacity: 0;
}
.skeleton-char {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 700;
  font-size: clamp(4rem, 8vw, 6rem);
  color: var(--ink);
  opacity: 0.18;
  line-height: 1;
}
.skeleton-lines {
  width: min(70%, 600px);
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}
.skeleton-lines span {
  display: block;
  height: 8px;
  background: linear-gradient(
    90deg,
    rgba(26, 20, 16, 0.06) 0%,
    rgba(26, 20, 16, 0.18) 50%,
    rgba(26, 20, 16, 0.06) 100%
  );
  background-size: 200% 100%;
  animation: shimmer 1.6s linear infinite;
  border-radius: 1px;
}
.skeleton-lines span:nth-child(2) {
  width: 80%;
  animation-delay: 0.15s;
}
.skeleton-lines span:nth-child(3) {
  width: 90%;
  animation-delay: 0.3s;
}
.skeleton-lines span:nth-child(4) {
  width: 65%;
  animation-delay: 0.45s;
}
.skeleton-lines span:nth-child(5) {
  width: 75%;
  animation-delay: 0.6s;
}
@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}
.skeleton-text {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  color: var(--ink-mute);
  font-size: 0.95rem;
  letter-spacing: 0.06em;
}

/* ------------------------------------------------------------
   BACK TO TOP
   ------------------------------------------------------------ */
.back-to-top {
  position: fixed;
  bottom: clamp(1.2rem, 3vw, 2rem);
  right: clamp(1.2rem, 3vw, 2rem);
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--paper-2);
  border: 1.5px solid var(--ink);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  z-index: 80;
  opacity: 0;
  transform: translateY(16px) scale(0.9);
  pointer-events: none;
  transition: opacity 0.4s var(--ease-out-soft),
    transform 0.4s var(--ease-out-soft),
    background 0.3s var(--ease-out-soft),
    color 0.3s var(--ease-out-soft);
  box-shadow: 0 12px 28px -8px rgba(26, 20, 16, 0.45);
}
.back-to-top.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}
.back-to-top:hover {
  background: var(--seal);
  color: #f4ead3;
}
.back-to-top__char {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 700;
  font-size: 1.4rem;
  line-height: 1;
}

/* ------------------------------------------------------------
   TOAST
   ------------------------------------------------------------ */
.toast {
  position: fixed;
  top: clamp(1rem, 3vw, 1.6rem);
  right: clamp(1rem, 3vw, 1.6rem);
  z-index: 110;
  background: rgba(26, 20, 16, 0.96);
  color: var(--paper-2);
  padding: 0.7rem 1rem 0.7rem 0.7rem;
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  letter-spacing: 0.04em;
  box-shadow: 0 18px 40px -16px rgba(26, 20, 16, 0.6);
  opacity: 0;
  transform: translateY(-12px) scale(0.96);
  pointer-events: none;
  transition: opacity 0.4s var(--ease-out-soft),
    transform 0.4s var(--ease-out-soft);
  max-width: 90vw;
}
.toast.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}
.toast__seal {
  display: inline-flex;
  flex: 0 0 auto;
  filter: drop-shadow(0 4px 8px rgba(168, 59, 59, 0.4));
}
.toast.is-visible .toast__seal {
  animation: stampIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@keyframes stampIn {
  0% {
    transform: scale(2.2) rotate(-12deg);
    opacity: 0;
  }
  60% {
    transform: scale(0.9) rotate(-3deg);
    opacity: 1;
  }
  100% {
    transform: scale(1) rotate(-3deg);
    opacity: 1;
  }
}
.toast__text {
  font-size: 1rem;
  line-height: 1.2;
}

/* ------------------------------------------------------------
   FOOTER
   ------------------------------------------------------------ */
.site-footer {
  background: linear-gradient(
    180deg,
    rgba(220, 205, 175, 0) 0%,
    rgba(196, 178, 142, 0.7) 100%
  );
  border-top: 1px solid rgba(26, 20, 16, 0.18);
}

.footer-quote {
  text-align: center;
  margin-bottom: 4rem;
}
.footer-quote__han {
  font-family: "Noto Serif TC", "Noto Serif SC", serif;
  font-weight: 700;
  font-size: clamp(1.4rem, 2.6vw, 2.2rem);
  color: var(--ink);
  letter-spacing: 0.12em;
  margin-bottom: 0.6rem;
}
.footer-quote__en {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  color: var(--ink-mute);
  font-size: clamp(1rem, 1.3vw, 1.15rem);
  max-width: 56ch;
  margin: 0 auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 2.5rem;
  align-items: center;
  padding: 2rem 0;
  border-top: 1px solid rgba(26, 20, 16, 0.18);
  border-bottom: 1px solid rgba(26, 20, 16, 0.18);
}

.footer-ca {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.footer-ca__label {
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-mute);
}
.footer-ca__btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: transparent;
  border: 1px dashed rgba(26, 20, 16, 0.4);
  padding: 0.6rem 0.9rem;
  cursor: pointer;
  position: relative;
  text-align: left;
  transition: border-color 0.3s var(--ease-out-soft),
    background 0.3s var(--ease-out-soft);
}
.footer-ca__btn:hover {
  border-color: var(--seal);
  background: rgba(168, 59, 59, 0.06);
}
.footer-ca__btn code {
  font-family: "JetBrains Mono", monospace;
  font-size: clamp(0.65rem, 0.9vw, 0.78rem);
  word-break: break-all;
  color: var(--ink);
}
.footer-ca__copied {
  position: absolute;
  inset: -28px 0 auto auto;
  background: var(--seal);
  color: #f4ead3;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: 0.75rem;
  padding: 0.2em 0.7em;
  opacity: 0;
  transform: translateY(6px);
  transition: all 0.35s var(--ease-out-soft);
  pointer-events: none;
}
.footer-ca__btn.is-copied .footer-ca__copied {
  opacity: 1;
  transform: translateY(0);
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.8rem 1.2rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.footer-links a {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--ink-soft);
  text-decoration: none;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  letter-spacing: 0.06em;
  transition: color 0.3s var(--ease-out-soft),
    transform 0.3s var(--ease-out-soft);
}
.footer-links a:hover {
  color: var(--seal);
  transform: translateX(3px);
}
.footer-links__ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(26, 20, 16, 0.3);
  color: var(--ink);
}

.footer-tribute {
  margin: 2rem auto 0;
  max-width: 60ch;
  text-align: center;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: 1rem;
  color: var(--ink-soft);
  letter-spacing: 0.04em;
  padding: 0.8em 1.2em;
  border-top: 1px solid rgba(26, 20, 16, 0.18);
  border-bottom: 1px solid rgba(26, 20, 16, 0.18);
}
.footer-tribute strong {
  font-style: normal;
  color: var(--ink);
  font-weight: 600;
  border-bottom: 1px dotted rgba(168, 59, 59, 0.5);
}

.footer-fineprint {
  margin-top: 1.5rem;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: 0.86rem;
  color: var(--ink-faint);
  text-align: center;
  letter-spacing: 0.04em;
  max-width: 60ch;
  margin-left: auto;
  margin-right: auto;
}

/* ------------------------------------------------------------
   RESPONSIVE
   ------------------------------------------------------------ */
@media (max-width: 1024px) {
  .hero-content {
    grid-template-columns: 1fr;
    gap: 2.5rem;
    min-height: auto;
    padding: 6rem 0 4rem;
  }
  .hero-calligraphy {
    padding-top: 0;
  }
  .calligraphy-stack {
    flex-direction: row;
    font-size: clamp(4rem, 14vw, 7rem);
  }
  .seal-stamp {
    align-self: center;
  }
  .hero-enso {
    width: 90vw;
    height: 90vw;
    opacity: 0.35;
  }
  .hero-portrait {
    top: -2%;
    right: -20%;
    width: 100%;
    height: 70%;
    opacity: 0.22;
  }
  .live-stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .live-stats li:nth-child(2) {
    border-right: 0;
  }
  .live-stats li:nth-child(1),
  .live-stats li:nth-child(2) {
    border-bottom: 1px dashed rgba(26, 20, 16, 0.18);
    padding-bottom: 0.6rem;
  }
  .live-stats li:nth-child(3),
  .live-stats li:nth-child(4) {
    padding-top: 0.6rem;
  }

  .tablet {
    grid-template-columns: 1fr;
    gap: 1.2rem;
  }
  .tablet__char {
    font-size: clamp(6rem, 22vw, 11rem);
  }

  .founder-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
    text-align: center;
  }
  .founder-portrait {
    align-items: center;
  }
  .founder-portrait__frame {
    max-width: 360px;
  }
  .founder-text {
    text-align: left;
  }
  .founder-eyebrow,
  .founder-title {
    text-align: center;
  }
  .vk-signature {
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
  }

  .market-summary {
    grid-template-columns: repeat(2, 1fr);
  }

  .book-scroll {
    max-width: 100%;
  }
  .book-scroll__paper {
    padding: clamp(1.6rem, 5vw, 2.4rem) clamp(1.2rem, 4vw, 2rem);
  }
  .book-scroll__han {
    font-size: clamp(1.4rem, 5vw, 2rem);
    letter-spacing: 0.14em;
    line-height: 1.65;
  }
  .book-scroll__seal {
    bottom: 12px;
    right: 12px;
    transform: rotate(-4deg) scale(0.85);
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    text-align: center;
  }
  .footer-ca {
    align-items: center;
  }
}

@media (max-width: 600px) {
  .site-header .mx-auto {
    padding: 1rem 1rem;
  }
  .hero {
    padding: 2rem 1.2rem 4rem;
  }
  .ca-card__addr-text {
    font-size: 0.66rem;
  }
  .hero-enso {
    width: 110vw;
    height: 110vw;
    opacity: 0.28;
  }
  .hero-portrait {
    opacity: 0.16;
  }
  .market-summary {
    grid-template-columns: 1fr 1fr;
  }
  .footer-links {
    grid-template-columns: 1fr;
  }
  .scroll-frame__inner {
    aspect-ratio: 4 / 5;
  }
  .founder-portrait__frame {
    max-width: 290px;
  }
  .toast {
    top: auto;
    bottom: 84px;
    left: 50%;
    right: auto;
    transform: translate(-50%, 12px) scale(0.96);
  }
  .toast.is-visible {
    transform: translate(-50%, 0) scale(1);
  }
  .back-to-top {
    width: 46px;
    height: 46px;
  }
  .book-scroll__han {
    font-size: clamp(1.3rem, 6vw, 1.8rem);
    letter-spacing: 0.1em;
  }
  .book-scroll__seal {
    width: 44px;
    height: 44px;
  }
  .book-scroll__seal svg {
    width: 44px;
    height: 44px;
  }
}

/* ------------------------------------------------------------
   LANGUAGE — Traditional Chinese mode adjustments
   ------------------------------------------------------------ */
/* Russian translation block + cite are only meaningful in EN mode */
body.lang-zh .book-scroll__ru,
body.lang-zh .book-scroll__cite,
body.lang-zh .book-scroll__divider {
  display: none;
}

/* Tighten Han text for Chinese readers (no transliteration helpers needed) */
body.lang-zh .tablet p,
body.lang-zh .founder-text p,
body.lang-zh .book__sub,
body.lang-zh .market-heading p,
body.lang-zh .footer-tribute,
body.lang-zh .footer-fineprint,
body.lang-zh .hero-byline {
  font-family: "Noto Serif TC", "Cormorant Garamond", serif;
  line-height: 1.85;
  letter-spacing: 0.02em;
}

body.lang-zh .tablet__title,
body.lang-zh .founder-title,
body.lang-zh .book__title,
body.lang-zh .market-heading h2,
body.lang-zh .philosophy-heading__title {
  font-family: "Noto Serif TC", "Cormorant Garamond", serif;
  font-style: normal;
  letter-spacing: 0.06em;
}

body.lang-zh .verses__eyebrow,
body.lang-zh .founder-eyebrow,
body.lang-zh .book__eyebrow,
body.lang-zh .philosophy-heading__sub {
  font-family: "Noto Serif TC", "Cormorant Garamond", serif;
  font-style: normal;
}

body.lang-zh .ink-button,
body.lang-zh .mobile-nav__cta,
body.lang-zh .mobile-nav__link,
body.lang-zh .nav-link {
  font-family: "Noto Serif TC", "Cormorant Garamond", serif;
  font-style: normal;
}

/* ------------------------------------------------------------
   REDUCED MOTION
   ------------------------------------------------------------ */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .han-char,
  [data-fade] {
    opacity: 1 !important;
    filter: none !important;
    transform: none !important;
  }
  .enso-stroke {
    stroke-dashoffset: 0 !important;
  }
  .seal-stamp {
    opacity: 1 !important;
    transform: rotate(-3deg) !important;
  }
  .tablet,
  .philosophy-divider span,
  .book-scroll {
    opacity: 1 !important;
    transform: none !important;
  }
  .verses__han,
  .verses__en {
    transition: opacity 0.001ms !important;
  }
  .skeleton-lines span {
    animation: none !important;
    background: rgba(26, 20, 16, 0.12) !important;
  }
}
