/* ==========================================================================
   时序001 · 温暖情感风 UI 样式表（v33）
   主色 #F49E4C | 背景 #FFF8F0 | 强调 #5D3A1A
   v33（单视频 + 去黑条）：
    1. 删除 .hero::after 视频底部黑色过渡渐变（80px/60px/48px 全部移除），
       视频下方不再有黑色过渡条；
    2. 碎片轮播文字字号 17px → 20px，引号颜色改为与文字一致 #6B4226；
    3. 首屏视频改为单视频 hero_sky.mp4（index.php 侧，不再随机）。
   v32（方案A定稿）：故事区顶部 ::before 短浅暗部渐变（26px，
     rgba(8,4,2,0.25) → transparent）；.section-divider 调整为
     2px / rgba(244,158,76,0.5)。
   v31（分割线方案）：.hero 与 .story-zone 之间新增 .section-divider；
     删除 .story-zone::before 双向渐变遮罩。
   v30：长廊方案调整（背景图 v2、废弃独立屋檐图片）。
   v29：独立屋檐图片 gallery_eaves.jpg（已废弃）。
   v28：渐变终点不透明、纯文字整卡入口、SVG 屋檐（已废弃）。
   v27：借鉴 v15/v17 参考设计（暖色遮罩 + 标题暖光分层）。
   v26：技术排查修正（遮罩恢复、过渡带移除）。
   ========================================================================== */

:root {
    --color-primary: #F49E4C;
    --color-primary-deep: #E8822E;
    --color-primary-tint: #FFF0DC;
    --color-bg: #FFF8F0;
    --color-accent: #5D3A1A;
    --color-caramel: #8B5E34;
    --color-card: #FFFFFF;
    --color-text: #3D3D3D;
    --color-text-secondary: #8C8C8C;
    --color-text-faint: #B8AFA4;
    --color-border: #E0E0E0;
    --color-border-soft: #EFE3D3;
    --color-line: #E8D8C2;
    --color-danger: #E35D5D;

    --radius-card: 12px;
    --radius-btn: 8px;
    --shadow-card: 0 2px 12px rgba(0, 0, 0, 0.06);
    --shadow-float: 0 4px 16px rgba(93, 58, 26, 0.12);

    --font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    --font-serif: "Noto Serif SC", "Songti SC", "STSong", "SimSun", serif;
    --font-kai: "Kaiti SC", "STKaiti", "KaiTi", "楷体", serif;

    --grad-placeholder: linear-gradient(135deg, #FFE3C4 0%, #F6C890 55%, #F49E4C 100%);
}

/* ==========================================================================
   全局微信端适配规范（全站标准）
   ========================================================================== */

* {
    -webkit-tap-highlight-color: transparent;
}

html {
    -webkit-text-size-adjust: 100%;
}

input,
textarea,
button,
select {
    -webkit-appearance: none;
    appearance: none;
    font-size: 16px;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a,
button {
    cursor: pointer;
}

a {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

button {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* 基础重置 */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow-x: hidden;
    font-family: var(--font-family);
    font-size: 15px;
    line-height: 1.6;
    color: var(--color-text);
    background: var(--color-bg);
}

a {
    color: var(--color-primary);
    text-decoration: none;
}

ul,
ol {
    list-style: none;
}

.container {
    width: 100%;
    max-width: 750px;
    margin: 0 auto;
    padding-right: 16px;
    padding-left: 16px;
}

/* ==========================================================================
   顶部导航栏（轻纱；预留顶部安全区）
   ========================================================================== */

.topbar {
    position: sticky;
    top: 0;
    z-index: 100;
    padding-top: env(safe-area-inset-top);
    background: transparent;
    box-shadow: none;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

body.is-scrolled .topbar {
    background: rgba(255, 248, 240, 0.92);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    box-shadow: 0 1px 8px rgba(93, 58, 26, 0.06);
}

.topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 56px;
}

.topbar-brand {
    color: var(--color-accent);
    font-size: 19px;
    font-weight: 700;
    letter-spacing: 1px;
}

.topbar-brand::before {
    content: "";
    width: 10px;
    height: 10px;
    margin-right: 8px;
    border-radius: 50%;
    background: var(--color-primary);
    box-shadow: 0 0 0 4px rgba(244, 158, 76, 0.18);
}

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 4px;
}

.topbar-link {
    padding: 0 10px;
    color: var(--color-caramel);
    font-size: 14px;
    border-radius: var(--radius-btn);
}

.topbar-link:active {
    background: rgba(244, 158, 76, 0.12);
}

.topbar-link--strong {
    color: var(--color-primary);
    font-weight: 600;
}

.topbar-btn--login {
    padding: 0 22px;
    border-radius: 22px;
    background: rgba(244, 158, 76, 0.95);
    color: #FFFFFF;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(244, 158, 76, 0.3);
}

/* ==========================================================================
   主导航（首页默认隐藏、下滑浮现）
   ========================================================================== */

.main-nav {
    position: sticky;
    top: calc(56px + env(safe-area-inset-top));
    z-index: 90;
    background: rgba(255, 255, 255, 0.88);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    box-shadow: 0 1px 4px rgba(93, 58, 26, 0.05);
}

.main-nav-inner {
    display: flex;
}

.main-nav-link {
    flex: 1;
    padding: 0 4px;
    color: rgba(61, 61, 61, 0.72);
    font-size: 13px;
    border-bottom: 2px solid transparent;
    transition: color 0.2s ease, border-color 0.2s ease;
}

.main-nav-link.active {
    color: var(--color-primary);
    font-weight: 600;
    border-bottom-color: var(--color-primary);
}

body.is-home .main-nav {
    display: none;
}

body.is-home.is-scrolled .main-nav {
    display: block;
    animation: navFade 0.35s ease both;
}

@keyframes navFade {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
}

.page-body {
    flex: 1 0 auto;
    width: 100%;
    padding: 20px 0 40px;
}

.page-title {
    margin-bottom: 6px;
    color: var(--color-accent);
    font-size: 22px;
    font-weight: 700;
}

.page-subtitle {
    margin-bottom: 20px;
    color: var(--color-text-secondary);
    font-size: 14px;
}

/* ==========================================================================
   首页 · 首屏「记忆展厅」（多视频随机背景）
   ========================================================================== */

.hero {
    position: relative;
    margin-top: -20px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    text-align: center;
    background:
        radial-gradient(ellipse 90% 70% at 50% 36%, #FFFDF6 0%, #FFF3DC 45%, #F6E7D3 78%, #F1DFC9 100%);
    /* 高度：逐级降级，兼容旧版微信（不支持 svh/env 时仍可渲染） */
    min-height: calc(100vh - 56px);
    min-height: calc(100vh - 56px - env(safe-area-inset-top));
    min-height: calc(100svh - 56px - env(safe-area-inset-top));
}

.hero-media {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.hero-video {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1.2s ease;
}

.hero-video.is-ready {
    opacity: 1;
}

/* 暖色半透明遮罩（借鉴 v15 参考设计）：奶油渐变，保证文字与碎片清晰可读 */
.hero-media-veil {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: linear-gradient(
        180deg,
        rgba(255, 248, 240, 0.72) 0%,
        rgba(255, 240, 220, 0.55) 50%,
        rgba(246, 231, 211, 0.78) 100%
    );
}

.hero-fragments {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1;
    display: block;
    visibility: visible;
    opacity: 1;
    overflow: hidden;
    pointer-events: none;
}

.frag {
    position: absolute;
    display: inline-block;
    padding: 8px 12px;
    max-width: var(--frag-w, 180px);
    background: rgba(255, 253, 249, 0.65);
    border: 1px solid rgba(244, 158, 76, 0.5);
    border-radius: 10px;
    font-family: var(--font-kai);
    font-size: var(--frag-size, 16px);
    font-weight: 600;
    line-height: 1.5;
    color: #3D1A0A;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.3);
    box-shadow: 0 2px 10px rgba(93, 58, 26, 0.08);
    visibility: visible;
    /* 基础态可见：即使动画未运行（弱网/降级/微信 X5），碎片也一定显示 */
    opacity: var(--frag-o, 0.6);
    will-change: transform, opacity;
    animation: fragFloat linear infinite;
}

@keyframes fragFloat {
    0%   { transform: translateX(-50%) translateY(0) scale(1) rotate(-2deg);       opacity: var(--frag-o, 0.6); }
    50%  { transform: translateX(-50%) translateY(-24px) scale(1.05) rotate(2deg); opacity: calc(var(--frag-o, 0.6) + 0.08); }
    100% { transform: translateX(-50%) translateY(0) scale(1) rotate(-2deg);       opacity: var(--frag-o, 0.6); }
}

/* ==========================================================================
   手机端 · 标题间碎片轮播文字（<768px 显示；桌面端隐藏）
   位于主标题"你还记得吗？"与副标题之间：纯淡入淡出（opacity），每5秒一句
   ========================================================================== */

.hero-frag-line {
    display: none; /* 桌面端隐藏 */
    margin-top: 24px; /* 主标题下方 24px */
    margin-bottom: 16px; /* 副标题上方 16px（配合 .hero-invite margin-top:0） */
    font-family: var(--font-kai);
    font-size: 20px;
    line-height: 1.7;
    color: #6B4226; /* 纯文字展示，无背景条 */
    text-shadow: 0 1px 3px rgba(255, 255, 255, 0.5);
    opacity: 0;
    transition: opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: opacity;
}

/* “ ”中文双引号：与碎片文字同色 #6B4226 */
.hero-frag-line::before {
    content: "“";
    margin-right: 4px;
    color: #6B4226;
}

.hero-frag-line::after {
    content: "”";
    margin-left: 4px;
    color: #6B4226;
}

.hero-frag-line.is-show {
    opacity: 1;
}

.hero-inner {
    position: relative;
    z-index: 2;
    width: 100%;
    padding: 48px 24px;
    visibility: visible;
    opacity: 1;
}

.hero-title {
    position: relative;
    font-family: var(--font-serif);
    font-size: 36px;
    font-weight: 900;
    line-height: 1.35;
    letter-spacing: 2px;
    color: #3D1A0A; /* 恢复原始清晰样式：无 text-shadow、无 filter */
    animation: heroIn 0.9s ease-out both;
}

.hero-title::after {
    content: "";
    display: block;
    width: 60px;
    height: 1px;
    margin: 14px auto 0;
    background: linear-gradient(90deg, transparent, #F49E4C 50%, transparent);
}

.hero-invite {
    margin-top: 16px;
    font-family: var(--font-kai);
    font-size: 17px;
    color: var(--color-caramel);
    animation: heroIn 0.9s ease-out 0.15s both;
}

.btn.btn-hero {
    position: relative;
    box-shadow:
        0 6px 18px rgba(244, 158, 76, 0.45),
        0 0 26px rgba(244, 158, 76, 0.30);
    animation: heroIn 0.9s ease-out 0.3s both;
}

.btn-hero::after {
    content: "";
    position: absolute;
    inset: -6px;
    border-radius: 14px;
    box-shadow: 0 6px 24px rgba(244, 158, 76, 0.45);
    opacity: 0.5;
    animation: btnBreath 3s ease-in-out infinite;
    pointer-events: none;
}

@keyframes heroIn {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes btnBreath {
    0%, 100% { opacity: 0.35; }
    50%      { opacity: 0.7; }
}

/* ==========================================================================
   分割线 · 极简暖色（.hero 与 .story-zone 之间）
   ========================================================================== */

.section-divider {
    height: 2px;
    background: rgba(244, 158, 76, 0.5);
    margin: 0;
    padding: 0;
}

/* ==========================================================================
   首页 · 故事区（story-zone：长廊+收尾+入口 共用背景）
   ========================================================================== */

.story-zone {
    position: relative;
    overflow: hidden;
    background: linear-gradient(180deg, #FFFDF9 0%, #FFF0DC 55%, #FDE6C8 100%);
}

/* 顶部短浅暗部渐变（方案A）：模拟柔和边缘阴影，
   缓解视频底部（rgba(8,4,2,0.55)深色）到故事区顶部的明度跳变；
   高26px，从上到下 rgba(8,4,2,0.25) → 完全透明；
   z-index 高于背景图(z0)、低于内容层(z2) */
.story-zone::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
    background: rgba(255, 253, 249, 0.68);
    pointer-events: none;
}

/* 底部渐变遮罩：故事区背景图自然淡出到比赛区底色 */
.story-zone::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 70px;
    z-index: 1;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, #FFF8F0 100%);
    pointer-events: none;
}

/* 统一背景图（background-attachment: scroll，微信兼容）
   背景图 story_zone_bg_v2.jpg 顶部已含走廊屋檐视觉元素；
   图片顶部区域与视频底部渐变终点 rgba(8,4,2,0.55) 衔接 */
.story-zone-bg {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 0;
    background-color: #FFF0DC;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: scroll;
}

.story-zone .gallery {
    position: relative;
    z-index: 2;
}

/* ---------- 故事长廊（墙上装裱的挂画） ---------- */

.gallery {
    padding: 56px 0 40px;
}

.gallery-decor {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 0;
    opacity: 0.2;
    pointer-events: none;
}

.gallery-decor img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-decor::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: linear-gradient(
        180deg,
        rgba(255, 248, 240, 0.6) 0%,
        rgba(255, 248, 240, 0) 18%,
        rgba(255, 248, 240, 0) 82%,
        rgba(255, 248, 240, 0.6) 100%
    );
}

.gallery .container,
.gallery-scroll,
.gallery-controls {
    position: relative;
    z-index: 1;
}

.gallery-title {
    margin-bottom: 28px;
    font-family: var(--font-kai);
    font-size: 28px;
    font-weight: 700;
    text-align: center;
    color: #3D1A0A;
}

.gallery-title::before,
.gallery-title::after {
    content: "";
    display: inline-block;
    width: 18px;
    height: 1.5px;
    margin: 0 10px;
    vertical-align: middle;
    background: var(--color-line);
}

.gallery-scroll {
    display: flex;
    gap: 16px;
    padding: 8px 16px 20px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-left: 16px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.gallery-scroll::-webkit-scrollbar {
    display: none;
}

.story-card {
    position: relative;
    flex: 0 0 264px;
    display: flex;
    flex-direction: column;
    min-height: 180px;
    padding: 18px 16px;
    border: 3px solid rgba(244, 158, 76, 0.45);
    border-radius: var(--radius-card);
    background: #FFFDF8;
    box-shadow: 0 6px 24px rgba(93, 58, 26, 0.12);
    scroll-snap-align: center;
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.story-bg {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 0;
    background-size: cover;
    background-position: center;
    opacity: 0.2;
    pointer-events: none;
}

.story-body {
    position: relative;
    z-index: 1;
    display: flex;
    flex: 1;
    flex-direction: column;
}

.tone-1 { background: #FFFDF8; }
.tone-2 { background: #FFFCF4; }
.tone-3 { background: #FFF9EF; }
.tone-4 { background: #FFF7EC; }

.story-target {
    display: inline-block;
    max-width: 100%;
    margin-bottom: 10px;
    padding: 2px 8px;
    border-radius: 4px;
    background: var(--color-primary);
    color: #FFFFFF;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.6;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.story-summary {
    flex: 1;
    font-size: 14px;
    line-height: 1.7;
    color: var(--color-caramel);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.story-meta {
    display: flex;
    align-items: center;
    margin-top: 12px;
}

.story-date {
    font-size: 12px;
    color: var(--color-text-faint);
}

@media (hover: hover) {
    .story-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 10px 32px rgba(93, 58, 26, 0.18);
    }
}

.gallery-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    padding: 4px 0 16px;
}

.gallery-arrow {
    width: 44px;
    height: 44px;
    border: 1px solid var(--color-border-soft);
    border-radius: 50%;
    background: var(--color-card);
    color: var(--color-caramel);
    font-size: 22px;
    line-height: 1;
    box-shadow: 0 2px 8px rgba(93, 58, 26, 0.06);
    transition: transform 0.15s ease;
}

.gallery-arrow:active {
    transform: scale(0.94);
}

.gallery-dots {
    display: flex;
    align-items: center;
    gap: 6px;
}

.gallery-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--color-line);
    transition: width 0.25s ease, background-color 0.25s ease;
}

.gallery-dot.active {
    width: 18px;
    border-radius: 3px;
    background: var(--color-primary);
}





/* ==========================================================================
   板块过渡带：故事区 → 比赛区
   ========================================================================== */

.section-transition {
    height: 26px;
    background: linear-gradient(180deg, #FFF8F0 0%, #FFE9CF 50%, #FFF8F0 100%);
}

/* ==========================================================================
   首页 · 比赛区（活力引擎：燃动氛围）
   ========================================================================== */

.competition {
    position: relative;
    padding: 48px 0 16px;
    overflow: hidden;
    background: radial-gradient(
        ellipse at 50% 30%,
        rgba(255, 253, 249, 1) 0%,
        rgba(255, 248, 240, 0.6) 60%,
        rgba(255, 248, 240, 1) 100%
    );
}

/* 顶部装饰性渐变条：暗示区域开始 */
.competition::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 40px;
    z-index: 0;
    background: linear-gradient(180deg, rgba(244, 158, 76, 0.18) 0%, rgba(244, 158, 76, 0) 100%);
    pointer-events: none;
}

/* 底部渐变：页脚深棕色出现前的柔和预兆 */
.competition::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40px;
    z-index: 0;
    background: linear-gradient(180deg, rgba(93, 58, 26, 0) 0%, rgba(93, 58, 26, 0.08) 100%);
    pointer-events: none;
}

/* 动态光点粒子层（纯 transform/opacity，不干扰阅读） */
.comp-glow {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.comp-glow-orb {
    position: absolute;
    display: block;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(244, 158, 76, 0.28) 0%, rgba(244, 158, 76, 0) 70%);
    animation: glowFloat ease-in-out infinite alternate;
}

.comp-glow-orb--1 { width: 260px; height: 260px; top: -60px; right: -60px; animation-duration: 9s; }
.comp-glow-orb--2 { width: 200px; height: 200px; bottom: 20%; left: -70px; animation-duration: 12s; animation-delay: -3s; }
.comp-glow-orb--3 { width: 140px; height: 140px; top: 30%; right: 12%; opacity: 0.6; animation-duration: 10s; animation-delay: -6s; }
.comp-glow-orb--4 { width: 120px; height: 120px; top: 18%; left: 10%; animation: compDrift 14s ease-in-out infinite alternate; }
.comp-glow-orb--5 { width: 90px; height: 90px; bottom: 8%; right: 22%; animation: compDrift 11s ease-in-out infinite alternate; animation-delay: -4s; }

/* 细微暖色尘埃粒子层：box-shadow 光点随 transform/opacity 漂移（GPU 加速，性能优先） */
.comp-dust {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.comp-dust-p {
    position: absolute;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #F49E4C;
    opacity: 0;
    animation: dustDrift linear infinite;
}

.comp-dust-p--1 {
    top: 16%;
    left: 8%;
    box-shadow:
        46px 96px 0 rgba(244, 158, 76, 0.8),
        128px 168px 0 rgba(232, 130, 46, 0.6),
        226px 44px 0 rgba(244, 158, 76, 0.7),
        330px 128px 0 rgba(255, 138, 92, 0.55),
        436px 208px 0 rgba(244, 158, 76, 0.65),
        568px 64px 0 rgba(232, 130, 46, 0.6),
        672px 152px 0 rgba(244, 158, 76, 0.7);
    animation-duration: 14s;
}

.comp-dust-p--2 {
    top: 52%;
    left: 30%;
    box-shadow:
        64px 44px 0 rgba(244, 158, 76, 0.6),
        156px 132px 0 rgba(255, 138, 92, 0.5),
        264px 224px 0 rgba(244, 158, 76, 0.7),
        384px 92px 0 rgba(232, 130, 46, 0.55),
        508px 196px 0 rgba(244, 158, 76, 0.6),
        628px 34px 0 rgba(255, 138, 92, 0.5);
    animation-duration: 18s;
    animation-delay: -7s;
}

@keyframes dustDrift {
    0%   { transform: translate(0, 0);       opacity: 0; }
    12%  { opacity: 0.5; }
    50%  { transform: translate(16px, -28px); opacity: 0.32; }
    88%  { opacity: 0.5; }
    100% { transform: translate(30px, -54px); opacity: 0; }
}

@keyframes glowFloat {
    from { transform: translateY(0) scale(1);        opacity: 0.45; }
    to   { transform: translateY(-24px) scale(1.12); opacity: 0.85; }
}

@keyframes compDrift {
    from { transform: translate(0, 0) scale(1);      opacity: 0.4; }
    to   { transform: translate(30px, -22px) scale(1.15); opacity: 0.8; }
}

.competition .container {
    position: relative;
    z-index: 1;
}

/* 标题：火热赛事 —— 32px 深棕 700 + 暖橙粗装饰短线 */
.comp-heading {
    position: relative;
    text-align: center;
    font-size: 32px;
    font-weight: 700;
    letter-spacing: 3px;
    color: var(--color-accent);
}

.comp-heading::after {
    content: "";
    display: block;
    width: 64px;
    height: 6px;
    margin: 14px auto 0;
    border-radius: 3px;
    background: linear-gradient(90deg, #FF8A5C, #F49E4C);
    box-shadow: 0 2px 10px rgba(244, 158, 76, 0.55);
}

.comp-subtitle {
    margin-top: 12px;
    text-align: center;
    font-family: var(--font-kai);
    font-size: 15px;
    color: var(--color-caramel);
}

/* 网格：移动端两列，桌面端三列 */
.comp-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-top: 30px;
    align-items: stretch;
}

/* 卡片：覆盖全局 a 的 inline-flex/center（否则封面会被 align-items:center 塌缩成 0 宽），
   纵向布局、强制对齐、高度统一 */
.comp-card {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    min-height: 330px;
    overflow: hidden;
    border: 1px solid rgba(244, 158, 76, 0.3);
    border-radius: 12px;
    background: #FFFDF9;
    color: inherit;
    text-align: left;
    box-shadow: 0 4px 16px rgba(93, 58, 26, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.comp-card:active {
    transform: scale(0.97);
}

.comp-card--featured {
    grid-column: 1 / -1;
}

/* 封面位：固定高度 180px，强制渲染；
   渐变占位层常驻（暖色渐变+图标），图片覆盖其上，加载失败自动回落占位层，绝不空白 */
.comp-cover {
    position: relative;
    flex: none;
    height: 180px;
    overflow: hidden;
    background-color: #F6E7D3;
    background-image: var(--grad-placeholder);
    background-size: cover;
    background-position: center;
}

.comp-cover-ph {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.8);
}

.comp-cover-ph svg {
    display: block;
}

.comp-cover-img {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

/* 图片加载失败兑底：先淡出，随后由 JS/onerror 移除，露出渐变占位层 */
.comp-cover-img.is-broken {
    opacity: 0;
}

.comp-badges {
    position: absolute;
    top: 8px;
    left: 8px;
    z-index: 2;
    display: flex;
    gap: 6px;
}

.comp-badge {
    min-height: 22px;
    padding: 0 8px;
    border-radius: 4px;
    background: var(--color-primary);
    color: #FFFFFF;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.comp-badge--live {
    background: var(--color-primary);
    color: #FFFFFF;
}

.comp-badge--hot {
    background: var(--color-primary);
    color: #FFFFFF;
    animation: hotBreath 1.6s ease-in-out infinite;
}

@keyframes hotBreath {
    0%, 100% { box-shadow: 0 0 4px rgba(244, 158, 76, 0.35); }
    50%      { box-shadow: 0 0 14px rgba(244, 158, 76, 0.8); }
}

.comp-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-height: 150px;
    padding: 14px;
}

.comp-title {
    margin-bottom: 8px;
    font-size: 17px;
    font-weight: 600;
    line-height: 1.35;
    color: #3D1A0A;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.comp-card--featured .comp-title {
    font-size: 18px;
}

/* 参与热度：火焰图标 + 暖橙大数字突出，传递"很多人参与" */
.comp-heat {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 3px;
    margin-bottom: 8px;
    font-size: 13px;
    color: var(--color-text-secondary);
}

.comp-heat-flame {
    flex: none;
    font-size: 14px;
    line-height: 1;
}

.comp-heat-num {
    font-size: 18px;
    font-weight: 800;
    line-height: 1;
    color: var(--color-primary);
}

.comp-heat-label,
.comp-heat-suffix {
    line-height: 1.6;
}

/* 动态进度条：模拟进行中的热度（纯 CSS） */
.comp-progress {
    position: relative;
    height: 3px;
    margin-bottom: 10px;
    border-radius: 2px;
    background: rgba(244, 158, 76, 0.14);
    overflow: hidden;
}

.comp-progress::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 72%;
    border-radius: 2px;
    background: linear-gradient(90deg, #FF8A5C, #F49E4C);
    animation: compProgress 2.6s ease-in-out infinite;
}

@keyframes compProgress {
    0%, 100% { transform: translateX(-25%); opacity: 0.7; }
    50%      { transform: translateX(38%);  opacity: 1; }
}

.comp-desc {
    margin-bottom: 10px;
    font-size: 14px;
    line-height: 1.5;
    color: var(--color-text-secondary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.comp-works {
    flex: 1;
    margin: 0 0 4px;
    padding: 0;
}

.comp-work {
    position: relative;
    padding-left: 12px;
    font-size: 12px;
    line-height: 1.6;
    color: var(--color-caramel);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.comp-work::before {
    content: "";
    position: absolute;
    left: 0;
    top: 8px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--color-primary);
}

.comp-work + .comp-work {
    margin-top: 3px;
}

.comp-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 44px;
    /* 按钮钉底：内容不足时自动吸底，保证同行卡片按钮严格对齐 */
    margin-top: auto;
    border-radius: 10px;
    background: linear-gradient(135deg, #FF8A5C, #F49E4C);
    color: #FFFFFF;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(244, 158, 76, 0.35);
}

.comp-more-wrap {
    margin-top: 24px;
}

.comp-more {
    display: flex;
    width: 100%;
    min-height: 48px;
    border: 1px solid rgba(244, 158, 76, 0.4);
    border-radius: 14px;
    background: linear-gradient(135deg, #FF8A5C, #F49E4C);
    color: #FFFFFF;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 1px;
    box-shadow: 0 6px 20px rgba(244, 158, 76, 0.35);
    transition: transform 0.15s ease;
}

.comp-more:active {
    transform: scale(0.98);
}

@media (hover: hover) {
    .comp-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 8px 24px rgba(93, 58, 26, 0.15);
    }

    .comp-card:hover .comp-cover-img {
        transform: scale(1.08);
    }
}

/* ==========================================================================
   首页 · 背景音乐按钮（默认静音，点击开启；底部安全区）
   ========================================================================== */

.music-btn {
    position: fixed;
    right: 16px;
    bottom: calc(24px + env(safe-area-inset-bottom));
    z-index: 200;
    gap: 6px;
    height: 44px;
    padding: 0 16px;
    border: 1px solid var(--color-border-soft);
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow-float);
    font-size: 13px;
    transition: transform 0.15s ease;
}

.music-btn:active {
    transform: scale(0.95);
}

.music-icon {
    position: relative;
    display: inline-flex;
    color: var(--color-primary);
}

.music-icon svg {
    display: block;
}

.music-label {
    line-height: 1;
}

.music-btn--off {
    color: var(--color-text-faint);
    border-color: var(--color-line);
}

.music-btn--off .music-icon {
    color: var(--color-text-faint);
    opacity: 0.7;
}

.music-btn--off .music-icon::after {
    content: "";
    position: absolute;
    left: -2px;
    right: -2px;
    top: 50%;
    height: 2px;
    border-radius: 1px;
    background: var(--color-text-faint);
    transform: rotate(-40deg);
}

.music-btn--playing {
    color: var(--color-caramel);
}

.music-btn--playing .music-icon {
    color: var(--color-primary);
}

.music-btn--playing::before {
    content: "";
    position: absolute;
    inset: -4px;
    border: 1px solid rgba(244, 158, 76, 0.5);
    border-radius: 26px;
    animation: musicPulse 2.4s ease-out infinite;
    pointer-events: none;
}

@keyframes musicPulse {
    0%   { transform: scale(0.92); opacity: 0.8; }
    70%  { transform: scale(1.12); opacity: 0; }
    100% { transform: scale(1.12); opacity: 0; }
}

/* ==========================================================================
   通用 · 按钮
   ========================================================================== */

.btn {
    min-height: 44px;
    padding: 0 28px;
    border: 0;
    border-radius: var(--radius-btn);
    font-size: 16px;
    line-height: 1.2;
    text-decoration: none;
    transition: background-color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

.btn:active {
    transform: translateY(1px);
}

.btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.btn-primary {
    height: 48px;
    background: var(--color-primary);
    color: #FFFFFF;
    font-weight: 600;
    box-shadow: 0 4px 14px rgba(244, 158, 76, 0.35);
}

.btn-primary:active {
    background: var(--color-primary-deep);
}

.btn-secondary {
    height: 48px;
    background: var(--color-card);
    color: var(--color-primary);
    border: 1px solid var(--color-primary);
}

.btn-block {
    display: flex;
    width: 100%;
}

/* ==========================================================================
   通用 · 卡片
   ========================================================================== */

.card {
    padding: 20px;
    background: var(--color-card);
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
}

.card + .card {
    margin-top: 16px;
}

.card-title {
    margin-bottom: 14px;
    color: var(--color-accent);
    font-size: 16px;
    font-weight: 600;
}

/* ==========================================================================
   通用 · 表单
   ========================================================================== */

.form-group {
    margin-bottom: 18px;
}

.form-label {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text);
}

.form-label .required {
    margin-left: 2px;
    color: var(--color-danger);
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    height: 44px;
    padding: 0 14px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-btn);
    background: var(--color-card);
    color: var(--color-text);
    font-size: 15px;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-textarea {
    height: auto;
    min-height: 120px;
    padding: 12px 14px;
    line-height: 1.6;
    resize: vertical;
}

.form-select {
    padding-right: 40px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%238C8C8C' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: #B9B9B9;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(244, 158, 76, 0.15);
}

.form-hint {
    margin-top: 6px;
    font-size: 12px;
    color: var(--color-text-secondary);
}

.form-error {
    margin-top: 6px;
    font-size: 12px;
    color: var(--color-danger);
}

.upload-area {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 150px;
    padding: 24px 16px;
    border: 2px dashed #EBC79E;
    border-radius: var(--radius-card);
    background: #FFFDF8;
    cursor: pointer;
    text-align: center;
    transition: border-color 0.2s ease, background-color 0.2s ease;
}

.upload-area:active {
    border-color: var(--color-primary);
    background: var(--color-bg);
}

.upload-area .upload-icon {
    margin-bottom: 8px;
    font-size: 32px;
}

.upload-area .upload-text {
    color: var(--color-text-secondary);
    font-size: 14px;
}

/* ==========================================================================
   通用 · 底部
   ========================================================================== */

.footer {
    margin-top: auto;
    padding: 30px 16px calc(32px + env(safe-area-inset-bottom));
    background: var(--color-accent);
    color: #FFFFFF;
    text-align: center;
}

.footer-links {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 4px 36px;
    margin-bottom: 16px;
}

.footer-links a {
    padding: 0 4px;
    color: rgba(255, 255, 255, 0.92);
    font-size: 14px;
}

.footer-copy {
    font-size: 13px;
    letter-spacing: 0.5px;
    color: rgba(255, 255, 255, 0.72);
}

/* ==========================================================================
   通用 · 工具类
   ========================================================================== */

.text-center    { text-align: center; }
.text-secondary { color: var(--color-text-secondary); }
.text-primary   { color: var(--color-primary); }
.text-accent    { color: var(--color-accent); }

.mt-8  { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }

.mb-8  { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }

.empty {
    padding: 48px 20px;
    text-align: center;
    color: var(--color-text-secondary);
}

.empty .empty-icon {
    margin-bottom: 10px;
    font-size: 40px;
}

.badge {
    min-height: 24px;
    padding: 0 10px;
    border-radius: 12px;
    background: #FFF0DE;
    color: var(--color-accent);
    font-size: 12px;
}

/* ==========================================================================
   响应式与无障碍
   ========================================================================== */

@media (max-width: 480px) {
    .topbar-link {
        padding: 0 6px;
    }

    .btn {
        padding: 0 20px;
    }

    .hero-title {
        font-size: 30px;
    }

    .story-card {
        flex-basis: 240px;
    }

    .music-btn {
        padding: 0 14px;
    }
}

/* 移动端（<768px） */
@media (max-width: 767px) {
    /* 过渡渐变：高度统一为 40px（与视频底部淡出色一致），不遮挡长廊标题 */
    .story-zone::after {
        height: 36px;
    }

    .competition::after {
        height: 28px;
    }

    .section-transition {
        height: 16px;
    }

    /* 首屏可见性加固（最高优先级）：主文字卡片在任何 WebView 下必须显示 */
    .hero-inner {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    .hero-title,
    .hero-invite,
    .btn.btn-hero {
        visibility: visible !important;
        opacity: 1 !important;
    }

    /* 手机端碎片重构：桌面漂浮碎片停用 → 标题间碎片轮播文字 */
    .hero-fragments {
        display: none;
    }

    .hero-frag-line {
        display: inline-block;
    }

    .hero-frag-line + .hero-invite {
        margin-top: 0;
    }

    .hero-title {
        font-size: 30px;
    }

    

    /* 比赛卡片：两列，间距12px；封面高度保持180px，文字区最小150px，同行等高 */
    .comp-grid {
        gap: 12px;
    }

    .comp-card {
        min-height: 300px;
    }

    .comp-title {
        font-size: 15px;
    }

    .comp-heat-num {
        font-size: 16px;
    }
}

@media (min-width: 768px) {
    .frag {
        font-size: calc(var(--frag-size, 16px) + 2px);
    }

    .story-card {
        flex-basis: 280px;
    }

    .comp-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (prefers-reduced-motion: reduce) {
    .frag,
    .comp-glow-orb,
    .comp-dust-p,
    .comp-badge--hot,
    .comp-heading,
    .comp-progress::before {
        animation: none;
    }

    .frag {
        opacity: var(--frag-o, 0.6);
    }

    /* 标题间碎片轮播：减弱动效时取消淡入淡出，直接切换文字 */
    .hero-frag-line {
        transition: none;
    }

    .hero-title,
    .hero-invite,
    .btn.btn-hero {
        animation: none;
    }

    .btn-hero::after,
    .music-btn--playing::before,
    .hero-audio-dot.is-playing::before,
    .hero-audio-dot.is-playing .audio-dot-icon {
        animation: none;
    }
}

/* ===== 首屏音频（方案B：hero右下角折叠小圆钮 + 精简播放条） ===== */
.hero-audio {
    position: absolute;
    right: 16px;
    bottom: 16px;
    z-index: 5;
    display: flex;
    align-items: center;
    gap: 10px;
}
.hero-audio-dot {
    position: relative;
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
    max-width: 44px;
    max-height: 44px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: #FFFDF9;
    color: #F49E4C;
    -webkit-appearance: none;
    appearance: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 0 0 1px rgba(244,158,76,0.40), 0 2px 8px rgba(93,58,26,0.12);
    transition: box-shadow 0.2s, transform 0.2s;
}
.hero-audio-dot:hover {
    box-shadow: 0 0 0 1px rgba(244,158,76,0.65), 0 2px 10px rgba(93,58,26,0.18);
    transform: scale(1.05);
}
.hero-audio-dot:active { transform: scale(0.95); }
.audio-dot-icon { display: block; }

/* 播放中：呼吸动效（扩散圆环 + 图标呼吸） */
.hero-audio-dot.is-playing::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 50%;
    background: rgba(244,158,76,0.45);
    z-index: -1;
    animation: audioDotPulse 1.6s ease-out infinite;
}
.hero-audio-dot.is-playing .audio-dot-icon {
    animation: audioIconBreath 1.6s ease-in-out infinite;
}
@keyframes audioDotPulse {
    0% { transform: scale(1); opacity: 0.55; }
    100% { transform: scale(1.7); opacity: 0; }
}
@keyframes audioIconBreath {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.45; }
}

/* 精简播放条（展开态，位于小圆钮左侧） */
.hero-audio-player {
    display: none;
    align-items: center;
    gap: 8px;
    width: 180px;
    max-width: 46vw;
    padding: 8px 12px;
    border-radius: 22px;
    background: #FFFDF9;
    border: 1px solid rgba(244,158,76,0.35);
    box-shadow: 0 2px 10px rgba(93,58,26,0.12);
    animation: audioPlayerIn 0.25s ease;
}
@keyframes audioPlayerIn {
    from { opacity: 0; transform: translateX(6px); }
    to { opacity: 1; transform: translateX(0); }
}
.audio-ctrl-btn {
    width: 30px;
    height: 30px;
    min-width: 30px;
    max-width: 30px;
    min-height: 0;
    max-height: 30px;
    padding: 0;
    flex-shrink: 0;
    border-radius: 50%;
    border: none;
    background: #F49E4C;
    color: #fff;
    font-size: 12px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}
.audio-progress {
    flex: 1;
    min-width: 0;
    height: 3px;
    background: rgba(244,158,76,0.2);
    border-radius: 2px;
    cursor: pointer;
}
.audio-progress-bar {
    width: 0%;
    height: 100%;
    background: #F49E4C;
    border-radius: 2px;
    transition: width 0.3s linear;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .hero-audio { right: 12px; bottom: 12px; }
    .hero-audio-player { width: 150px; max-width: 42vw; padding: 6px 10px; gap: 6px; }
}

/* ===== 故事长廊副标题（“这一次”下方） ===== */
.gallery-subtitle {
    font-size: 14px;
    color: #8C8C8C;
    text-align: center;
    margin-top: 10px;
}

/* ===== 视频区双按钮（hero-actions） ===== */
.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    align-items: center;
    margin-top: 8px;
}
.hero-actions .btn {
    min-height: 48px;
    padding: 12px 24px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
@media (max-width: 768px) {
    /* 副标题→按钮间距：8px 增至 24px */
    .hero-actions {
        margin-top: 24px;
        flex-direction: row;
        gap: 12px;
    }
    .hero-actions .btn {
        width: auto;
        min-height: 44px;
        min-width: 108px;
        padding: 0 20px;
        font-size: 14px;
        gap: 6px;
    }
    .hero-actions .btn svg {
        width: 16px;
        height: 16px;
    }
    /* 两按钮视觉重量平衡：实心光晕收敛；找回描边加深+浮起 */
    .hero-actions .btn.btn-hero {
        box-shadow: 0 2px 8px rgba(244, 158, 76, 0.20);
    }
    .hero-actions .btn-ghost {
        border-color: #E8822E;
        box-shadow: 0 2px 10px rgba(93, 58, 26, 0.14);
    }
}

/* ===== 故事长廊标题移动端字号（与比赛区同级） ===== */
@media (max-width: 767px) {
    .gallery-title {
        font-size: 24px;
    }
    .gallery {
        padding: 48px 0 28px;
    }
    .gallery-controls {
        padding: 2px 0 14px;
    }
}

/* ===== 首页双按钮：找回=线框暖橙（透明底+橙边框+橙字） ===== */
.hero-actions .btn-ghost {
    background: #FFFDF9;
    border: 2px solid #F49E4C;
    color: #5D3A1A;
    font-weight: 600;
    box-shadow: 0 1px 4px rgba(93, 58, 26, 0.08);
}
.hero-actions .btn-ghost svg {
    stroke-width: 2.5;
}
.hero-actions .btn-ghost:hover {
    background: #FFF6EA;
    border-color: #E8822E;
    color: #5D3A1A;
}
.hero-actions .btn-ghost::after {
    display: none;
}

/* ===== 页头（Logo + 水平导航 + 手机端汉堡菜单） ===== */
.site-header {
    position: relative;
    z-index: 100;
    background: #FFFDF9;
    border-bottom: 1px solid rgba(244, 158, 76, 0.25);
}
.site-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 56px;
}
.site-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    text-decoration: none;
}
.site-logo {
    display: block;
    width: 48px;
    height: 48px;
    object-fit: contain;
}
.site-brand-text {
    font-size: 20px;
    font-weight: 700;
    letter-spacing: 2px;
    color: #3D1A0A;
    font-family: var(--font-kai, Georgia, serif);
}
.site-nav {
    display: flex;
    align-items: center;
    gap: 8px;
}
.site-nav-link {
    position: relative;
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 0 14px;
    font-size: 15px;
    color: #5D3A1A;
    text-decoration: none;
    transition: color 0.2s;
}
.site-nav-link:hover {
    color: #F49E4C;
}
.site-nav-link.active {
    color: #5D3A1A;
}
.site-nav-link.active::after {
    content: "";
    position: absolute;
    left: 14px;
    right: 14px;
    bottom: 6px;
    height: 2px;
    border-radius: 1px;
    background: #F49E4C;
}
.nav-toggle {
    display: none;
    width: 44px;
    height: 44px;
    padding: 0;
    border: none;
    background: transparent;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    cursor: pointer;
}
.nav-toggle-bar {
    display: block;
    width: 22px;
    height: 2px;
    background: #5D3A1A;
    border-radius: 1px;
    transition: transform 0.25s ease, opacity 0.25s ease;
}
.nav-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 150;
    background: rgba(0, 0, 0, 0.3);
}
.nav-panel {
    display: none;
    position: fixed;
    top: 64px;
    right: 12px;
    z-index: 160;
    width: 75vw;
    max-width: 320px;
    max-height: calc(100vh - 80px);
    background: #FFFDF9;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(93, 58, 26, 0.18);
    padding: 12px 12px 16px;
    flex-direction: column;
    gap: 8px;
    overflow-y: auto;
}
.nav-panel-link {
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 0 14px;
    font-size: 16px;
    color: #5D3A1A;
    text-decoration: none;
    border-radius: 8px;
    transition: background 0.2s, color 0.2s;
}
.nav-panel-link:hover {
    background: rgba(244, 158, 76, 0.12);
}
.nav-panel-link.active {
    color: #F49E4C;
    font-weight: 600;
}
.site-header.is-open .nav-overlay {
    display: block;
    animation: navOverlayIn 0.25s ease;
}
.site-header.is-open .nav-panel {
    display: flex;
    animation: navPanelIn 0.25s ease;
}
@keyframes navPanelIn {
    from {
        transform: translateX(40px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}
@keyframes navOverlayIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}
.site-header.is-open .nav-toggle-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.site-header.is-open .nav-toggle-bar:nth-child(2) {
    opacity: 0;
}
.site-header.is-open .nav-toggle-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}
@media (max-width: 768px) {
    .site-nav {
        display: none;
    }
    .nav-toggle {
        display: flex;
    }
}

/* ===== 故事区：时间线直排（无图，标题+概要；约一屏高） ===== */
.story-zone {
    min-height: 100vh;
}
.gallery-timeline {
    position: relative;
    max-width: 620px;
    margin: 0 auto;
    padding: 8px 20px 12px 24px;
}
.gallery-timeline::before {
    content: '';
    position: absolute;
    top: 6px;
    bottom: 6px;
    left: 7px;
    width: 2px;
    border-radius: 1px;
    background: rgba(244, 158, 76, 0.35);
}
/* 默认条目 = 紧凑行（标题一行 + 概要一行，目录感） */
.timeline-item {
    position: relative;
    padding: 12px 0 12px 24px;
}
.timeline-item:last-child {
    padding-bottom: 8px;
}
.timeline-dot {
    position: absolute;
    left: 1px;
    top: 18px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #F49E4C;
    border: 2px solid #FFFDF9;
    box-shadow: 0 0 0 2px rgba(244, 158, 76, 0.25);
}
.timeline-title {
    font-size: 16px;
    font-weight: 600;
    color: #3D1A0A;
    margin: 0 0 2px;
    line-height: 1.4;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.timeline-summary {
    font-size: 13px;
    line-height: 1.6;
    color: #8C8C8C;
    margin: 0;
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
/* 头条 = 独立大块：大标题 + 概要3行 + 底部实线分隔 */
.timeline-item--lead {
    padding: 16px 0 26px 24px;
    border-bottom: 1px solid rgba(244, 158, 76, 0.35);
    margin-bottom: 4px;
}
/* 紧凑列表条目之间用细虚线分隔 */
.timeline-item:not(.timeline-item--lead) + .timeline-item:not(.timeline-item--lead) {
    border-top: 1px dashed rgba(244, 158, 76, 0.22);
}
.timeline-item--lead .timeline-dot {
    width: 16px;
    height: 16px;
    top: 22px;
}
.timeline-item--lead .timeline-title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 8px;
    white-space: normal;
}
.timeline-item--lead .timeline-summary {
    font-size: 15px;
    line-height: 1.7;
    white-space: normal;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    border-left: 2px solid rgba(244, 158, 76, 0.5);
    padding-left: 10px;
}
.gallery-more {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    margin-top: 12px;
    color: #F49E4C;
    font-size: 14px;
    text-decoration: none;
}
.gallery-more::after {
    content: '\2192';
    margin-left: 4px;
}
.gallery-more:hover {
    color: #E8822E;
}
@media (min-width: 768px) {
    .story-zone {
        min-height: auto;
    }
    .timeline-item {
        padding: 14px 0 14px 24px;
    }
    .timeline-item--lead {
        padding: 20px 0 30px 24px;
    }
    .timeline-item:not(.timeline-item--lead) .timeline-title {
        font-size: 17px;
    }
    .timeline-item:not(.timeline-item--lead) .timeline-summary {
        font-size: 14px;
    }
}

/* ===== 背景双图：手机竖版 / PC横版 ===== */
.story-zone-bg--pc {
    display: none;
}
@media (min-width: 768px) {
    .story-zone-bg--mobile {
        display: none;
    }
    .story-zone-bg--pc {
        display: block;
    }
}
