/* 语言切换样式 */
.lang-switch {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    background: none;
    border: none;
    padding: 0.5rem;
    cursor: pointer;
    font-family: 'Cormorant Garamond', serif;
    font-size: 1rem;
    letter-spacing: 0.1em;
    color: var(--color-text-secondary);
}
.lang-cn, .lang-en { transition: all 0.3s ease; opacity: 0.5; cursor: pointer; }
.lang-cn:hover, .lang-en:hover { opacity: 1; color: var(--color-gold); transform: translateY(-1px); }
.lang-cn.active, .lang-en.active { color: var(--color-gold); opacity: 1; font-weight: 500; }
.lang-divider { color: rgba(240,235,227,0.3); font-weight: 300; }

/* ===== 核心：中英文显示切换（放在最前面确保最高优先级）===== */
body:not(.lang-en) [data-lang="en"] {
    display: none !important;
    visibility: hidden !important;
    position: absolute !important;
    left: -9999px !important;
    width: 0 !important;
    height: 0 !important;
    overflow: hidden !important;
}
body.lang-en [data-lang="zh"] {
    display: none !important;
    visibility: hidden !important;
    position: absolute !important;
    left: -9999px !important;
    width: 0 !important;
    height: 0 !important;
    overflow: hidden !important;
}

/* 英文模式下的英文内容恢复显示 */
body.lang-en [data-lang="en"] {
    display: inline !important;
    visibility: visible !important;
    position: static !important;
    left: auto !important;
    width: auto !important;
    height: auto !important;
    overflow: visible !important;
}
body:not(.lang-en) [data-lang="zh"] {
    display: inline !important;
    visibility: visible !important;
    position: static !important;
    left: auto !important;
    width: auto !important;
    height: auto !important;
    overflow: visible !important;
}

/* 导航链接内的 span 为 GSAP 动画做准备 */
.nav-links a [data-lang="zh"],
.nav-links a [data-lang="en"] {
    display: inline-block;
    vertical-align: top;
}

/* 英文字体 */
[data-lang="en"], [data-lang="en"] * {
    font-family: 'Playfair Display', 'Cormorant Garamond', Georgia, serif !important;
    font-weight: 400;
    letter-spacing: 0.02em;
}
[data-lang="en"] h1,
[data-lang="en"] h2,
[data-lang="en"] h3 {
    font-weight: 300;
    letter-spacing: 0.03em;
}
[data-lang="en"] .hero-title {
    font-weight: 300 !important;
    font-size: clamp(3rem, 7vw, 6rem) !important;
}
[data-lang="en"] .section-title {
    font-weight: 300 !important;
}
[data-lang="en"] p {
    font-weight: 400;
    line-height: 1.8;
}

/* 英文模式专属样式 */
body.lang-en { font-family: 'Playfair Display', 'Cormorant Garamond', Georgia, serif; }
body.lang-en .hero-subtitle { font-size: 1.05rem; font-weight: 400; letter-spacing: 0.25em; }
body.lang-en .btn-primary,
body.lang-en .btn-secondary {
    font-family: 'Cormorant Garamond', serif !important;
    font-weight: 500;
    letter-spacing: 0.1em;
}
body.lang-en .section-label { font-size: 0.95rem; letter-spacing: 0.35em; font-weight: 400; }
body.lang-en .collection-info h3 { font-weight: 400; }
body.lang-en .poem-content h3 { font-weight: 400; }
body.lang-en .story-quote { font-style: normal; font-weight: 400; }
body.lang-en nav a { font-weight: 400; }

/* 英文小字字号增大 */
body.lang-en .collection-tag { font-size: 0.95rem !important; }
body.lang-en .collection-info p { font-size: 1.2rem !important; }
body.lang-en .gallery-name { font-size: 1.1rem !important; }
body.lang-en .poem-content p { font-size: 1.25rem !important; }
body.lang-en .section-desc { font-size: 1.35rem !important; }
body.lang-en .footer-tagline { font-size: 1.2rem !important; }
body.lang-en .btn-primary,
body.lang-en .btn-secondary { font-size: 1.1rem !important; }
body.lang-en nav a { font-size: 1.15rem !important; }
body.lang-en .hero-desc { font-size: 1.4rem !important; }
body.lang-en .story-body p { font-size: 1.15rem !important; }
body.lang-en .story-quote { font-size: 1.2rem !important; }

/* 强制英文大标题使用 Garamond */
body.lang-en .hero-title,
body.lang-en .hero-title *,
body.lang-en .hero-title .char,
body.lang-en .hero-title .title-line {
    font-family: 'Playfair Display', 'Cormorant Garamond', Georgia, serif !important;
}

/* 修复标题动画导致的中英文混合 */
body.lang-en .hero-title .char { display: inline !important; }
body.lang-en .hero-title [data-lang="zh"] .char { display: none !important; }
body:not(.lang-en) .hero-title [data-lang="en"] .char { display: none !important; }
