:root {
  --black: #050504;
  --ink: #0c0b0a;
  --text: #f2efe8;
  --text-soft: rgba(242, 239, 232, 0.72);
  --text-muted: rgba(242, 239, 232, 0.45);
  --accent-warm: #c9a06a;
  --serif: "LXGW WenKai", "Songti SC", "Noto Serif SC", "STSong", "SimSun", Georgia, serif;
  --serif-en: "Cormorant Garamond", "Iowan Old Style", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", sans-serif;
  --header-h: 64px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--sans);
  background: var(--black);
  color: var(--text);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

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

a:hover {
  color: var(--accent-warm);
}

/* —— Home —— */

.page-home {
  overflow-x: hidden;
}

.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  overflow: hidden;
  background: var(--black);
}

.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  pointer-events: none;
}

.hero-video--hold {
  z-index: 1;
}

.hero-video.is-hidden {
  opacity: 0;
  visibility: hidden;
}

.hero-veil {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    rgba(5, 5, 4, 0.55) 0%,
    rgba(5, 5, 4, 0.15) 45%,
    rgba(5, 5, 4, 0.35) 100%
  );
  pointer-events: none;
}

.site-header {
  position: absolute;
  z-index: 3;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: max(20px, env(safe-area-inset-top)) clamp(24px, 5vw, 48px) 20px;
}

.brand {
  font-family: var(--serif);
  font-size: clamp(1.05rem, 2.2vw, 1.35rem);
  font-weight: 500;
  letter-spacing: 0.12em;
  color: var(--text);
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: clamp(12px, 3vw, 28px);
  font-family: var(--serif);
  font-size: clamp(0.85rem, 1.8vw, 0.95rem);
  letter-spacing: 0.08em;
  color: var(--text-soft);
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
  font-size: 0.92em;
  color: var(--text-muted);
}

.lang-switch a {
  color: var(--text-muted);
  text-decoration: none;
}

.lang-switch a:hover,
.lang-switch a.is-active {
  color: var(--text-soft);
}

.lang-sep {
  opacity: 0.45;
  user-select: none;
}

.page-home .hero-veil {
  background: linear-gradient(
    100deg,
    rgba(5, 5, 4, 0.78) 0%,
    rgba(5, 5, 4, 0.5) 28%,
    rgba(5, 5, 4, 0.14) 52%,
    rgba(5, 5, 4, 0.32) 100%
  );
}

.page-home .hero-copy {
  left: clamp(18px, 5vw, 64px);
  max-width: min(420px, 78vw);
  padding: clamp(16px, 3vh, 32px) clamp(16px, 2.5vw, 24px);
}

.page-home .hero-copy::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: -14% -10% -14% -22%;
  background: radial-gradient(
    ellipse 88% 92% at 16% 48%,
    rgba(5, 5, 4, 0.82) 0%,
    rgba(5, 5, 4, 0.42) 42%,
    transparent 70%
  );
  pointer-events: none;
}

.page-home .hero-title {
  color: #f2efe8;
  text-shadow:
    0 1px 2px rgba(0, 0, 0, 0.9),
    0 6px 28px rgba(0, 0, 0, 0.8),
    0 0 56px rgba(0, 0, 0, 0.65);
}

.page-home:not(.page-en) .hero-title {
  font-family: var(--serif);
  font-size: clamp(1.65rem, 4.8vw, 3rem);
  font-weight: 500;
  letter-spacing: 0.12em;
  line-height: 1.42;
}

.page-home:not(.page-en) .hero-sub {
  margin-top: 1.35em;
  font-family: var(--serif);
  font-size: clamp(0.86rem, 1.95vw, 1.06rem);
  font-weight: 400;
  letter-spacing: 0.22em;
  color: rgba(242, 239, 232, 0.82);
  text-shadow:
    0 2px 14px rgba(0, 0, 0, 0.85),
    0 0 36px rgba(0, 0, 0, 0.5);
}

.page-home:not(.page-en) .verse-line {
  margin: 0 0 0.55em;
  letter-spacing: 0.24em;
  line-height: 1.52;
}

.page-home:not(.page-en) .site-nav {
  letter-spacing: 0.1em;
}

.page-en .hero-sub,
.page-en .verse-line,
.page-en .compliance,
.page-en .cta-appstore,
.page-en .site-nav a,
.page-en .site-footer,
.page-en.page-legal .legal,
.page-en.page-legal .lead,
.page-en.page-legal footer {
  font-family: var(--serif-en);
  letter-spacing: 0.02em;
}

.page-en .hero-title {
  font-family: var(--serif-en);
  font-size: clamp(1.55rem, 4.2vw, 2.85rem);
  font-weight: 500;
  letter-spacing: 0.08em;
  line-height: 1.34;
}

.page-en .hero-title-em {
  font-style: italic;
  font-weight: 500;
  letter-spacing: 0.09em;
}

.page-en .hero-title-em--close {
  font-weight: 600;
  letter-spacing: 0.07em;
}

.page-en .hero-sub {
  margin-top: 1.55em;
  font-size: clamp(0.82rem, 1.85vw, 1rem);
  font-weight: 400;
  font-style: italic;
  letter-spacing: 0.22em;
  text-transform: none;
  color: rgba(242, 239, 232, 0.8);
  text-shadow:
    0 2px 12px rgba(0, 0, 0, 0.85),
    0 0 32px rgba(0, 0, 0, 0.55);
}

.page-en .site-nav {
  font-family: var(--serif-en);
  letter-spacing: 0.13em;
  font-weight: 500;
}

.page-en .verse {
  padding-top: clamp(88px, 16vh, 136px);
  padding-bottom: clamp(56px, 9vh, 88px);
}

.page-en .verse-line {
  margin: 0 0 0.7em;
  letter-spacing: 0.14em;
  line-height: 1.48;
  font-weight: 400;
}

.page-en .brand,
.page-en .verse-aside {
  font-family: var(--serif);
}

.page-legal nav .lang-switch {
  margin-left: 16px;
}

.hero-copy {
  position: absolute;
  z-index: 2;
  left: clamp(24px, 7vw, 96px);
  top: 50%;
  transform: translateY(-42%);
  max-width: min(520px, 88vw);
  pointer-events: none;
}

.hero-title {
  margin: 0 0 0.65em;
  font-family: var(--serif);
  font-size: clamp(1.75rem, 5.5vw, 3.25rem);
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: 0.06em;
  color: var(--text);
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.45);
}

.hero-sub {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(0.95rem, 2.2vw, 1.15rem);
  font-weight: 400;
  letter-spacing: 0.14em;
  color: var(--text-soft);
}

.scroll-hint {
  position: absolute;
  z-index: 2;
  bottom: max(28px, env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  pointer-events: none;
}

.scroll-hint-line {
  display: block;
  width: 1px;
  height: 48px;
  background: linear-gradient(to bottom, transparent, var(--text-muted), transparent);
  opacity: 0.7;
  animation: hint-pulse 2.8s ease-in-out infinite;
}

@keyframes hint-pulse {
  0%,
  100% {
    opacity: 0.35;
    transform: scaleY(0.85);
  }
  50% {
    opacity: 0.85;
    transform: scaleY(1);
  }
}

.verse {
  position: relative;
  z-index: 1;
  padding: clamp(72px, 14vh, 120px) clamp(24px, 7vw, 96px) clamp(48px, 8vh, 80px);
  background: var(--black);
  text-align: left;
}

.verse-line {
  margin: 0 0 0.35em;
  font-family: var(--serif);
  font-size: clamp(1.25rem, 3.5vw, 1.85rem);
  font-weight: 400;
  letter-spacing: 0.2em;
  color: var(--text-soft);
}

.verse-aside {
  margin: 2.5em 0 0;
  font-family: var(--serif);
  font-size: 0.9rem;
  letter-spacing: 0.28em;
  color: var(--text-muted);
}

.download {
  padding: 0 clamp(24px, 7vw, 96px) clamp(64px, 10vh, 96px);
  background: var(--black);
  text-align: left;
}

.cta-appstore {
  display: inline-block;
  padding: 14px 28px;
  font-family: var(--serif);
  font-size: 0.95rem;
  letter-spacing: 0.12em;
  color: var(--text-soft);
  border: 1px solid rgba(242, 239, 232, 0.22);
  border-radius: 2px;
  cursor: default;
  opacity: 0.85;
}

.compliance {
  margin: 2em 0 0;
  max-width: 36em;
  font-size: 0.8rem;
  line-height: 1.8;
  color: var(--text-muted);
}

.site-footer {
  padding: 24px clamp(24px, 7vw, 96px) max(40px, env(safe-area-inset-bottom));
  border-top: 1px solid rgba(242, 239, 232, 0.08);
  font-size: 0.78rem;
  color: var(--text-muted);
}

.site-footer a {
  color: var(--text-muted);
}

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

/* —— Legal pages —— */

.page-legal {
  background: var(--ink);
  color: #e5e1d8;
}

.page-legal header {
  border-bottom: 1px solid rgba(242, 239, 232, 0.08);
  padding: 14px clamp(20px, 5vw, 48px);
  background: rgba(5, 5, 4, 0.92);
}

.page-legal header .inner {
  max-width: 720px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.page-legal nav a {
  margin-left: 16px;
  font-family: var(--serif);
  font-size: 0.9rem;
  letter-spacing: 0.06em;
  color: var(--text-soft);
  text-decoration: none;
}

.page-legal nav a:hover {
  color: var(--accent-warm);
}

.page-legal main {
  max-width: 720px;
  margin: 0 auto;
  padding: 32px 20px 48px;
}

.page-legal h1 {
  font-family: var(--serif);
  font-size: 1.75rem;
  margin: 0 0 8px;
  font-weight: 500;
}

.page-legal .lead {
  color: var(--text-muted);
  margin-bottom: 24px;
}

.page-legal a {
  color: var(--accent-warm);
}

.page-legal .legal h2 {
  font-family: var(--serif);
  font-size: 1.05rem;
  margin: 24px 0 8px;
  font-weight: 500;
}

.page-legal .legal p,
.page-legal .legal li {
  color: #d8d4cb;
}

.page-legal footer {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 20px 40px;
  color: var(--text-muted);
  font-size: 0.85rem;
}

@media (max-width: 520px) {
  .site-nav {
    gap: 10px;
    font-size: 0.82rem;
  }

  .hero-copy {
    transform: translateY(-36%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .scroll-hint-line {
    animation: none;
  }

  html {
    scroll-behavior: auto;
  }

}
