/* ================================================================
   modules.css — 各模块专用样式
   声景花园 · 唱段研习室 · 旋律迷宫 · 情绪锚点 · 双演对照 · 浮岛成长
   ------------------------------------------------
   MusicMath AI 去 AI 化视觉重构
   设计原则：实色卡片 + 细边框 + 克制动效
   统一使用 base.css 中的 CSS 变量，无 !important
   ================================================================ */

/* ================================================================
   通用模块结构
   ================================================================ */

.view-section {
    position: relative;
    animation: view-fade-in 400ms ease-out;
    padding-top: 5rem;
    padding-bottom: 3rem;
}

.view-section > .max-w-7xl {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.view-section > .max-w-7xl > div:first-child {
    margin-bottom: 0.5rem;
}

@keyframes view-fade-in {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.module-header {
    max-width: 1200px;
    margin: 0 auto 2rem;
    padding: 0 1.5rem;
}

.module-title {
    font-family: var(--font-serif);
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    letter-spacing: -0.01em;
}

.module-subtitle {
    font-size: var(--fs-sm);
    color: var(--text-tertiary);
    line-height: 1.6;
    max-width: 600px;
}

.module-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ================================================================
   通用卡片：glass-card 覆盖（实色，无毛玻璃）
   ================================================================ */

.glass-card {
    background: var(--bg-card);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.feature-card,
.glass-card {
    box-shadow: var(--shadow-sm);
}

.feature-card {
    padding: 20px 16px;
    border-radius: var(--radius-lg);
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.feature-card:hover {
    border-color: var(--border-strong);
    background: var(--bg-hover);
}

.feature-icon {
    width: 44px;
    height: 44px;
    margin: 0 auto;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-tertiary);
    color: var(--accent-primary);
    border: 1px solid var(--border-default);
}

/* ================================================================
   通用：按钮系统覆盖（实色，无渐变无发光）
   ================================================================ */

.ctrl-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    font-size: var(--fs-sm);
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    cursor: pointer;
    border: none;
    white-space: nowrap;
}

.ctrl-btn:active {
    transform: scale(0.97);
    transition: transform 80ms ease-out;
}

.ctrl-btn-primary {
    background: var(--accent-primary);
    color: var(--text-inverse);
    border: 1px solid var(--accent-primary);
    border-radius: var(--radius-md);
}

.ctrl-btn-primary:hover {
    background: var(--accent-primary-hover);
    border-color: var(--accent-primary-hover);
}

.ctrl-btn-secondary {
    background: transparent;
    color: var(--accent-primary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
}

.ctrl-btn-secondary:hover {
    background: var(--accent-primary-soft);
    border-color: var(--accent-primary);
}

.ctrl-btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
}

.ctrl-btn-ghost:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.ctrl-btn-ghost.active {
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
    border-color: var(--accent-primary);
}

.ctrl-btn-danger {
    background: transparent;
    color: var(--accent-red);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
}

.ctrl-btn-danger:hover {
    background: var(--accent-red-soft);
    border-color: var(--accent-red);
}

/* 按钮禁用态 */
#view-study .ctrl-btn:disabled,
#view-duallab .ctrl-btn:disabled {
    opacity: 0.4;
    filter: grayscale(0.6);
    cursor: not-allowed;
    pointer-events: none;
    box-shadow: none;
    transform: none;
}

/* ================================================================
   通用：表单元素（覆盖旧渐变样式）
   ================================================================ */

.ctrl-select {
    padding: 6px 12px;
    font-size: var(--fs-sm);
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    outline: none;
    cursor: pointer;
    transition: border-color var(--transition-fast);
}

.ctrl-select:focus {
    border-color: var(--accent-primary);
}

.ctrl-input {
    padding: 6px 12px;
    font-size: var(--fs-sm);
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    outline: none;
    transition: border-color var(--transition-fast);
}

.ctrl-input:focus {
    border-color: var(--accent-primary);
}

.ctrl-input::placeholder {
    color: var(--text-muted);
}

.ctrl-input.jianpu-valid {
    border-color: var(--accent-green);
    box-shadow: 0 0 0 1px var(--accent-green-soft);
}

.ctrl-input.jianpu-invalid {
    border-color: var(--accent-red);
    box-shadow: 0 0 0 1px var(--accent-red-soft);
}

/* 滑块 */
.ctrl-range {
    width: 100%;
    height: 4px;
    background: var(--bg-tertiary);
    border-radius: 2px;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}

.ctrl-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--accent-primary);
    cursor: pointer;
}

.ctrl-range::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--accent-primary);
    cursor: pointer;
    border: none;
}

/* ================================================================
   通用：状态点
   ================================================================ */

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
}

.status-dot-off {
    background: var(--text-muted);
}

.status-dot-on {
    background: var(--accent-green);
    animation: pulse-dot 1.5s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* ================================================================
   通用：模块标签
   ================================================================ */

.module-tag {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    font-family: var(--font-sans);
    font-size: 12.5px;
    font-weight: 400;
    letter-spacing: 0.02em;
    text-transform: none;
    color: var(--accent-primary);
    padding: 3px 10px;
    border-radius: var(--radius-sm);
    background: var(--accent-primary-soft);
    border: 1px solid transparent;
}

/* 支持 --tag-color 自定义属性 */
.module-tag[style*="--tag-color"] {
    background: color-mix(in srgb, var(--tag-color) 15%, transparent);
    color: var(--tag-color);
    border-color: color-mix(in srgb, var(--tag-color) 30%, transparent);
}

.module-tag::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 2px;
    background: var(--accent-primary);
    border-radius: 1px;
}

/* ================================================================
   通用：Canvas 空闲提示
   ================================================================ */

.canvas-idle-hint {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--text-muted);
    font-size: var(--fs-sm);
    pointer-events: none;
}

/* ================================================================
   通用：自定义滚动条
   ================================================================ */

.custom-scroll::-webkit-scrollbar {
    width: 4px;
}

.custom-scroll::-webkit-scrollbar-track {
    background: transparent;
}

.custom-scroll::-webkit-scrollbar-thumb {
    background: var(--border-strong);
    border-radius: 2px;
}

/* ================================================================
   通用：空状态提示
   ================================================================ */

.empty-card-hint {
    color: var(--text-muted);
}

.readout-placeholder {
    color: var(--text-muted);
    font-style: italic;
    font-size: 0.8em;
    font-family: var(--font-sans);
}

/* ================================================================
   通用：页脚
   ================================================================ */

.footer-main-text {
    font-family: var(--font-serif);
    font-size: var(--fs-sm);
    font-weight: 500;
    color: var(--text-secondary);
    letter-spacing: 0.03em;
}

.footer-sub-text {
    font-family: var(--font-serif);
    font-size: var(--fs-xs);
    font-weight: 400;
    color: var(--text-tertiary);
    letter-spacing: 0.02em;
}

/* 页脚英文小字：斜体衬线作为学术收尾标注，与主标题 serif 呼应 */
.footer-en-text {
    font-family: var(--font-serif);
    font-size: 0.6875rem;      /* 11px */
    font-style: italic;
    font-weight: 400;
    color: var(--text-tertiary);
    letter-spacing: 0.04em;
    opacity: 0.88;
}

/* ================================================================
   通用：Toast 通知
   ================================================================ */

#toast-container {
    display: flex;
    flex-direction: column-reverse;
    gap: 8px;
}

.toast {
    padding: 12px 36px 12px 20px;
    border-radius: var(--radius-lg);
    font-size: var(--fs-sm);
    font-weight: 500;
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    color: var(--text-primary);
    box-shadow: var(--shadow-lg);
    animation: toastIn 0.3s ease forwards;
    max-width: 320px;
    position: relative;
    display: flex;
    align-items: center;
}

.toast-text {
    flex: 1;
}

.toast-close {
    position: absolute;
    top: 6px;
    right: 8px;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: var(--text-muted);
    cursor: pointer;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
    line-height: 1;
}

.toast-close:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
}

.toast.success { border-left: 3px solid var(--accent-green); }
.toast.error { border-left: 3px solid var(--accent-red); }
.toast.info { border-left: 3px solid var(--accent-primary); }
.toast.warning { border-left: 3px solid var(--accent-amber); }

@keyframes toastIn {
    from { opacity: 0; transform: translateX(40px) scale(0.95); }
    to { opacity: 1; transform: translateX(0) scale(1); }
}

.toast.out { animation: toastOut 0.3s ease forwards; }

@keyframes toastOut {
    to { opacity: 0; transform: translateX(40px) scale(0.95); }
}

/* ================================================================
   通用：模态弹窗
   ================================================================ */

.report-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    animation: view-fade-in 0.3s ease;
}

.report-modal {
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-xl);
    padding: 28px;
    max-width: 480px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: var(--shadow-xl);
    position: relative;
}

.report-modal-title {
    font-size: 1.25rem;
    font-weight: 700;
    font-family: var(--font-serif);
    color: var(--text-primary);
    margin-bottom: 1rem;
    text-align: center;
}

.report-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-md);
    background: var(--bg-hover);
    border: 1px solid var(--border-default);
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.report-modal-close:hover {
    background: var(--bg-active);
    color: var(--text-primary);
}

/* ================================================================
   通用：发现卡片
   ================================================================ */

.discovery-card {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 200;
    padding: 24px 32px;
    border-radius: var(--radius-xl);
    background: var(--bg-card);
    border: 1px solid var(--accent-primary);
    box-shadow: var(--shadow-xl);
    text-align: center;
    animation: discoveryIn 0.4s ease forwards;
    max-width: 360px;
}

.discovery-card.out {
    animation: discoveryOut 0.5s ease forwards;
}

@keyframes discoveryIn {
    from { opacity: 0; transform: translate(-50%, -50%) scale(0.8); }
    to { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}

@keyframes discoveryOut {
    to { opacity: 0; transform: translate(-50%, -50%) scale(1.1); }
}

.discovery-card-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--accent-primary);
    margin-bottom: 8px;
    font-family: var(--font-serif);
}

.discovery-card-seq {
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    font-family: var(--font-mono);
    margin-bottom: 12px;
}

.discovery-card-footer {
    font-size: var(--fs-xs);
    color: var(--accent-amber);
    font-weight: 600;
}

/* ================================================================
   模块背景统一
   ================================================================ */

/* 模块背景统一：改为透明，透出全局绿洲背景层（#oasis-bg），
   底色由 html body 的 --bg-primary 统一提供 */
#view-garden,
#view-study,
#view-maze,
#view-anchor,
#view-duallab,
#view-island {
    background: transparent;
}

/* 模块顶部微光装饰 */
#view-garden::before,
#view-maze::before,
#view-anchor::before,
#view-study::before,
#view-duallab::before,
#view-island::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 200px;
    background: radial-gradient(ellipse at 50% 0%, var(--accent-primary-soft), transparent 70%);
    pointer-events: none;
    z-index: 0;
}

/* SVG/Canvas 容器裁剪溢出 */
#view-maze .glass-card .relative,
.burnside-canvas-wrapper,
.exp-abstract-art-wrapper {
    overflow: hidden;
}

#orbit-svg {
    overflow: hidden;
    display: block;
}

/* 钢琴键消除焦点轮廓 */
#piano-keyboard,
.piano-keyboard,
.exp-piano-88,
.exp-piano-inner,
.exp-white-key-88,
.exp-black-key-88,
.white-key,
.black-key {
    outline: none;
    -webkit-tap-highlight-color: transparent;
}

/* ================================================================
   首页 Hero 背景（从内联 style 迁移）
   ================================================================ */

.hero-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
    z-index: 0;
}

.hero-glow {
    position: absolute;
    top: -10%;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 60%;
    background: radial-gradient(ellipse 80% 50% at 50% 50%, rgba(45, 212, 191, 0.12), transparent 70%);
    pointer-events: none;
}

[data-theme="light"] .hero-glow {
    background: radial-gradient(ellipse 80% 50% at 50% 50%, rgba(13, 148, 136, 0.06), transparent 70%);
}

.hero-grid-lines {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(to right, var(--border-subtle) 1px, transparent 1px),
        linear-gradient(to bottom, var(--border-subtle) 1px, transparent 1px);
    background-size: 80px 80px;
    opacity: 0.3;
    mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black 30%, transparent 70%);
    -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black 30%, transparent 70%);
}

.hero-circle-decoration {
    position: absolute;
    border: 1px solid var(--border-subtle);
    border-radius: 50%;
    opacity: 0.4;
}

.hero-circle-1 {
    width: 300px;
    height: 300px;
    top: 10%;
    right: -100px;
}

.hero-circle-2 {
    width: 200px;
    height: 200px;
    bottom: 15%;
    left: -60px;
}

.hero-line-decoration {
    position: absolute;
    height: 1px;
    background: var(--border-subtle);
    opacity: 0.3;
}

.hero-line-1 {
    width: 120px;
    top: 30%;
    left: 10%;
    transform: rotate(-30deg);
}

.hero-line-2 {
    width: 80px;
    bottom: 25%;
    right: 15%;
    transform: rotate(45deg);
}

#view-home > .container {
    position: relative;
    z-index: 1;
}

/* Hero 布局 */
.hero-layout {
    display: flex;
    gap: 3rem;
    width: 100%;
    align-items: center;
}

.hero-left {
    flex: 0 0 55%;
    max-width: 55%;
}

.hero-right {
    flex: 0 0 45%;
    max-width: 45%;
}

.hero-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.hero-cta-row {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

/* Hero 模块卡片 */
.hero-module-card {
    padding: 1rem 1rem 1rem 1.25rem;
    cursor: pointer;
    position: relative;
}

.hero-module-num {
    font-family: var(--font-mono);
    font-size: 1.75rem;
    font-weight: 600;
    line-height: 1;
    margin-bottom: 0.5rem;
    opacity: 0.8;
}

.hero-module-title {
    font-family: var(--font-serif);
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.hero-module-desc {
    font-size: 0.75rem;
    color: var(--text-tertiary);
    line-height: 1.4;
}

.hero-module-icon {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 1.5rem;
    height: 1.5rem;
    color: var(--accent-purple);
    opacity: 0.6;
}

/* Hero 文字 */
.hero-tag-row {
    margin-bottom: 1.25rem;
}

.hero-title-text {
    font-family: var(--font-serif);
    font-size: var(--fs-h1);
    font-weight: 600;
    line-height: var(--lh-tight);
    color: var(--text-primary);
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
}

.hero-subtitle-text {
    font-family: var(--font-sans);
    font-size: 0.875rem;
    color: var(--text-tertiary);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
}

.hero-body-text {
    font-size: var(--fs-body);
    line-height: var(--lh-relaxed);
    color: var(--text-secondary);
    max-width: 480px;
    margin-bottom: 2rem;
}

.hero-accent-text {
    color: var(--accent-primary);
    font-weight: 500;
}

/* ==================== Loading Screen 增强样式 ==================== */

/* 主标题 — 渐变文字 */
.loading-title {
    margin: 0;
    font-family: var(--font-serif);
    font-size: 2.75rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-amber) 50%, var(--accent-primary) 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    animation: loading-title-shimmer 4s ease-in-out infinite;
}

@keyframes loading-title-shimmer {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* 副标题 — 数学 × 音乐 × 计算机 */
.loading-subtitle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin: 0.5rem 0 0 0;
    font-size: 0.875rem;
    color: var(--text-secondary);
    letter-spacing: 0.15em;
    font-family: var(--font-serif);
    opacity: 0;
    animation: loading-fade-up 0.8s ease-out 0.4s forwards;
}

.loading-subtitle-divider {
    width: 24px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent-primary), transparent);
    opacity: 0.6;
}

/* 英文副标 */
.loading-en-sub {
    margin: 0.35rem 0 0 0;
    font-size: 0.7rem;
    color: var(--text-tertiary);
    letter-spacing: 0.2em;
    font-family: var(--font-sans);
    text-transform: uppercase;
    opacity: 0;
    animation: loading-fade-up 0.8s ease-out 0.6s forwards;
}

/* 状态文本 */
.loading-status {
    margin: 1rem 0 0 0;
    font-size: 0.75rem;
    color: var(--text-muted);
    letter-spacing: 0.15em;
    font-family: var(--font-mono);
    opacity: 0;
    animation: loading-fade-up 0.8s ease-out 0.8s forwards;
}

.loading-status::before {
    content: '';
    display: inline-block;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--accent-primary);
    margin-right: 0.5rem;
    vertical-align: middle;
    animation: loading-status-dot 1.4s ease-in-out infinite;
}

@keyframes loading-status-dot {
    0%, 100% { opacity: 0.3; transform: scale(0.8); }
    50% { opacity: 1; transform: scale(1.2); }
}

/* 跳过按钮 — 优雅样式 */
.loading-skip-btn {
    margin-top: 1.75rem;
    padding: 0.55rem 1.4rem;
    font-size: 0.75rem;
    color: var(--text-tertiary);
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-subtle);
    border-radius: 999px;
    cursor: pointer;
    letter-spacing: 0.1em;
    transition: all var(--transition-fast);
    animation: skip-btn-fade-in 0.6s ease-out;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.loading-skip-text {
    font-family: var(--font-sans);
}

.loading-skip-icon {
    width: 12px;
    height: 12px;
    opacity: 0.7;
    transition: transform var(--transition-fast), opacity var(--transition-fast);
}

.loading-skip-btn:hover {
    color: var(--accent-primary);
    border-color: var(--accent-primary);
    background: var(--accent-primary-soft);
    transform: translateY(-1px);
}

.loading-skip-btn:hover .loading-skip-icon {
    opacity: 1;
    transform: translateX(2px);
}

.loading-skip-btn:active {
    transform: scale(0.97);
    filter: brightness(0.92);
}

@keyframes skip-btn-fade-in {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 渐入上移动画（通用） */
@keyframes loading-fade-up {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 响应式 Hero */
@media (max-width: 900px) {
    #view-home .hero-left,
    #view-home .hero-right {
        flex: 0 0 100%;
        max-width: 100%;
    }
    #view-home > .container > .hero-layout {
        flex-direction: column;
        gap: 2.5rem;
    }
}

@media (max-width: 640px) {
    #view-home .hero-right .hero-grid {
        grid-template-columns: 1fr;
    }
}

/* ================================================================
   首页：首页蓝绿渐变背景（从 experience.css 迁移）
   ================================================================ */

#view-home {
    background: transparent;
}

[data-theme="light"] #view-home {
    background: transparent;
}

/* 首页顶部细碎光点：改为极淡，融入全局网格底色 */
#view-home::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(1px 1px at 15% 22%, rgba(45,212,191,0.18), transparent),
        radial-gradient(1px 1px at 45% 68%, rgba(45,212,191,0.12), transparent),
        radial-gradient(1px 1px at 75% 35%, rgba(255,255,255,0.15), transparent),
        radial-gradient(1.5px 1.5px at 88% 80%, rgba(6,182,212,0.12), transparent),
        radial-gradient(1px 1px at 30% 90%, rgba(255,255,255,0.1), transparent),
        radial-gradient(1px 1px at 60% 10%, rgba(45,212,191,0.12), transparent);
    background-size: 100% 100%;
    pointer-events: none;
    z-index: 0;
    opacity: 0.35;
}

[data-theme="light"] #view-home::before {
    opacity: 0.15;
}

/* ================================================================
   导航栏：nav-item 覆盖（与新设计系统统一）
   ================================================================ */

.nav-item {
    padding: 0.5rem 0.875rem;
    font-size: var(--fs-sm);
    font-weight: 500;
    color: var(--text-secondary);
    background: transparent;
    border: none;
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    position: relative;
    cursor: pointer;
}

.nav-item:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
}

.nav-item.active {
    color: var(--accent-primary);
    background: var(--accent-primary-soft);
}

.nav-item.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 2px;
    background: var(--accent-primary);
    border-radius: 1px;
}

.nav-logo-mark {
    display: none;
}

/* 移动端菜单 */
.mobile-nav-item {
    display: block;
    width: 100%;
    text-align: left;
    padding: 0.625rem 0.75rem;
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
    background: transparent;
    border: none;
}

.mobile-nav-item:hover,
.mobile-nav-item.active {
    color: var(--accent-primary);
    background: var(--accent-primary-soft);
}

/* 导航分隔线 */
.nav-divider {
    width: 1px;
    height: 20px;
    background: var(--border-default);
    margin: 0 var(--space-1);
}

/* 导航设置菜单标签 */
.nav-settings-label {
    padding: 0.25rem 0.75rem;
    font-size: 0.7rem;
    color: var(--text-muted);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    font-family: var(--font-mono);
}

/* SVG 图标尺寸辅助类 */
.icon-sm { width: 14px; height: 14px; }
.icon-md { width: 16px; height: 16px; }
.icon-lg { width: 18px; height: 18px; }
.icon-xl { width: 20px; height: 20px; }

/* SVG 图标颜色辅助类 */
.icon-tertiary { color: var(--text-tertiary); }

/* ================================================================
   模块1：声景花园
   ================================================================ */

#view-garden {
    background: linear-gradient(180deg,
        rgba(209, 250, 229, 0.55) 0%,
        rgba(204, 251, 241, 0.35) 14%,
        rgba(254, 249, 195, 0.30) 28%,
        rgba(254, 249, 195, 0.14) 55%,
        rgba(254, 249, 195, 0.05) 78%,
        var(--bg-primary) 92%,
        var(--bg-primary) 100%);
}
/* 底部柔和收尾：薄荷绿-淡黄渐变在 55% 后不再骤停，而是经
   78%（0.05 透明度）→ 92% 缓慢淡出到 var(--bg-primary)，
   渐变终点与 body/页脚底色完全一致，模块底部 → 页脚零切痕。 */

/* 顶部微光装饰拉高，避免与下方实色生硬交界 */
#view-garden::before {
    height: 480px;
}

/* 读数面板 */
.feature-readout {
    padding: 12px;
    border-radius: var(--radius-lg);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
}

.readout-label {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    margin-bottom: 4px;
}

.readout-value {
    font-size: 1.125rem;
    font-weight: 700;
    font-family: var(--font-mono);
    color: var(--text-primary);
}

.readout-bar {
    height: 3px;
    background: var(--bg-tertiary);
    border-radius: 2px;
    margin-top: 6px;
    overflow: hidden;
}

.readout-bar-fill {
    height: 100%;
    width: 0%;
    background: var(--bar-color, var(--accent-primary));
    border-radius: 2px;
    transition: width 0.15s ease;
}

/* 对照迷你条 */
.compare-bars-container {
    padding: 12px;
    border-radius: var(--radius-lg);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
}

.compare-bar-row {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.compare-bar-label {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    text-align: center;
    margin-bottom: 4px;
}

.compare-bar-user,
.compare-bar-template {
    height: 6px;
    border-radius: 3px;
    overflow: hidden;
    background: var(--bg-tertiary);
}

.compare-bar-user-fill {
    height: 100%;
    background: var(--accent-amber);
    border-radius: 3px;
    transition: width 0.3s;
}

.compare-bar-template-fill {
    height: 100%;
    background: var(--accent-primary);
    border-radius: 3px;
    transition: width 0.3s;
}

.compare-bar-diff {
    font-size: var(--fs-xs);
    font-family: var(--font-mono);
    text-align: center;
    min-width: 50px;
    color: var(--text-secondary);
}

/* 即将上线遮罩 */
.coming-soon-overlay {
    position: absolute;
    inset: 0;
    background: rgba(11, 15, 25, 0.85);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    z-index: 10;
}

[data-theme="light"] .coming-soon-overlay {
    background: rgba(250, 248, 245, 0.85);
}

.coming-soon-badge {
    padding: 6px 16px;
    border: 1px solid rgba(45, 212, 191, 0.3);
    border-radius: 20px;
    background: rgba(45, 212, 191, 0.08);
    font-size: 12px;
    color: var(--accent-primary);
    font-weight: 600;
}

.coming-soon-text {
    font-size: 11px;
    color: var(--text-muted);
    text-align: center;
    max-width: 280px;
}

/* 情绪计算面板 */
.calc-panel {
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.calc-panel-header {
    padding: 12px 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: var(--fs-sm);
    font-weight: 600;
    color: var(--text-secondary);
    transition: all var(--transition-fast);
}

.calc-panel-header:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
}

.calc-panel-body {
    padding: 0 16px 16px;
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    font-family: var(--font-mono);
    line-height: 1.8;
}

.calc-panel-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.calc-panel-bar {
    flex: 1;
    height: 4px;
    background: var(--bg-tertiary);
    border-radius: 2px;
    overflow: hidden;
}

.calc-panel-bar-fill {
    height: 100%;
    border-radius: 2px;
    transition: width 0.3s;
}

.calc-panel-hint {
    padding: 16px;
    text-align: center;
    color: var(--text-muted);
    font-size: var(--fs-xs);
}

/* 情绪声音按钮 */
.emotion-sound-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    font-size: var(--fs-xs);
    border-radius: var(--radius-sm);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.emotion-sound-btn:hover {
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
    border-color: var(--accent-primary);
}

.emotion-sound-btn.playing {
    background: var(--accent-amber-soft);
    color: var(--accent-amber);
    border-color: var(--accent-amber);
}

/* ================================================================
   模块2：唱段研习室
   ================================================================ */

#view-study {
    background: var(--bg-primary);
}

/* 上传区 */
.sr-upload-zone {
    border: 2px dashed var(--border-default);
    border-radius: var(--radius-xl);
    padding: 40px 24px;
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-base);
    background: var(--bg-tertiary);
}

.sr-upload-zone:hover,
.sr-upload-zone.dragover {
    border-color: var(--accent-primary);
    background: var(--accent-primary-soft);
}

.sr-upload-zone .sr-upload-icon {
    font-size: 48px;
    margin-bottom: 12px;
    opacity: 0.7;
    transition: transform var(--transition-base);
}

.sr-upload-zone:hover .sr-upload-icon {
    transform: scale(1.1);
}

.sr-upload-zone .sr-upload-text {
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.sr-upload-zone .sr-upload-hint {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    line-height: 1.6;
}

/* 文件信息 */
.sr-file-info {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    margin-top: 12px;
    background: var(--accent-primary-soft);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    font-size: var(--fs-xs);
    color: var(--text-secondary);
}

.sr-file-info .sr-file-icon {
    font-size: 18px;
    flex-shrink: 0;
}

.sr-file-info .sr-file-name {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sr-file-info .sr-file-size {
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: 11px;
    flex-shrink: 0;
}

/* 播放器控制栏 */
.sr-player-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    flex-wrap: wrap;
}

.sr-play-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--accent-primary);
    border: none;
    color: var(--text-inverse);
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
    flex-shrink: 0;
}

.sr-play-btn:hover {
    transform: scale(1.08);
}

.sr-play-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none;
}

/* 变速控制 */
.sr-speed-control {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 160px;
}

.sr-speed-label {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    white-space: nowrap;
}

.sr-speed-slider {
    flex: 1;
    height: 4px;
    -webkit-appearance: none;
    appearance: none;
    background: var(--bg-tertiary);
    border-radius: 2px;
    outline: none;
}

.sr-speed-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--accent-primary);
    cursor: pointer;
}

.sr-speed-slider::-moz-range-thumb {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--accent-primary);
    cursor: pointer;
    border: none;
}

.sr-speed-value {
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    color: var(--accent-primary);
    min-width: 44px;
    text-align: right;
}

.sr-time-display {
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    color: var(--text-muted);
    min-width: 100px;
    text-align: center;
}

/* 变速预设 */
.sr-speed-presets {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    flex-basis: 100%;
    margin-top: 4px;
}

.sr-speed-presets-label {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    margin-right: 2px;
}

.sr-preset-chip {
    padding: 4px 10px;
    border-radius: var(--radius-full);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    color: var(--text-muted);
    font-size: var(--fs-xs);
    font-family: var(--font-mono);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.sr-preset-chip:hover {
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
    border-color: var(--accent-primary);
}

.sr-preset-chip.active {
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
    border-color: var(--accent-primary);
}

/* 波形可视化 */
.sr-waveform-container {
    position: relative;
    height: 140px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    overflow: hidden;
    cursor: pointer;
}

.sr-waveform-canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.sr-waveform-canvas.sr-fade-in {
    animation: sr-canvas-fade-in 0.45s ease-out;
}

@keyframes sr-canvas-fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.sr-waveform-playhead {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 2px;
    border-radius: 1px;
    background: var(--accent-primary);
    pointer-events: none;
    transition: left 0.05s linear;
    transform: translateX(-50%);
    z-index: 5;
}

.sr-waveform-selection {
    position: absolute;
    top: 0;
    bottom: 0;
    background: var(--accent-primary-soft);
    border-left: 2px solid var(--accent-primary);
    border-right: 2px solid var(--accent-primary);
    pointer-events: none;
    z-index: 4;
}

.sr-zoom-controls {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    margin-top: 8px;
}

.sr-zoom-btn {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    color: var(--text-secondary);
    font-size: var(--fs-sm);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.sr-zoom-btn:hover {
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
    border-color: var(--accent-primary);
}

.sr-zoom-btn.sr-clear-btn {
    width: auto;
    padding: 0 10px;
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    border-color: var(--accent-red-soft);
}

.sr-zoom-btn.sr-clear-btn:hover {
    background: var(--accent-red-soft);
    color: var(--accent-red);
    border-color: var(--accent-red);
}

.sr-waveform-guide {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    margin-left: 6px;
    line-height: 1.4;
}

/* 分句系统 */
.sr-segment-list {
    max-height: 200px;
    overflow-y: auto;
}

.sr-segment-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    margin-bottom: 4px;
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    cursor: pointer;
}

.sr-segment-item:hover {
    background: var(--accent-primary-soft);
    border-color: var(--accent-primary);
}

.sr-segment-item.active {
    background: var(--accent-primary-soft);
    border-color: var(--accent-primary);
    border-left: 3px solid var(--accent-primary);
}

.sr-segment-item.looping {
    border-color: var(--accent-amber);
    background: var(--accent-amber-soft);
}

.sr-segment-number {
    width: 24px;
    height: 24px;
    border-radius: var(--radius-sm);
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
    font-size: var(--fs-xs);
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.sr-segment-time {
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    color: var(--text-muted);
    flex: 1;
}

.sr-segment-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.sr-segment-label {
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sr-segment-item.active .sr-segment-label {
    color: var(--text-primary);
}

.sr-segment-actions {
    display: flex;
    gap: 4px;
    flex-shrink: 0;
}

.sr-segment-btn {
    width: 24px;
    height: 24px;
    border-radius: var(--radius-sm);
    background: transparent;
    border: 1px solid var(--border-default);
    color: var(--text-muted);
    font-size: var(--fs-xs);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.sr-segment-btn:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.sr-segment-btn.loop-btn:hover {
    background: var(--accent-amber-soft);
    color: var(--accent-amber);
    border-color: var(--accent-amber);
}

.sr-segment-btn.delete-btn:hover {
    background: var(--accent-red-soft);
    color: var(--accent-red);
    border-color: var(--accent-red);
}

.sr-segment-btn.play-btn {
    color: var(--accent-primary);
    border-color: var(--accent-primary);
}

.sr-segment-btn.play-btn:hover {
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
}

.sr-segment-btn.play-btn.playing {
    background: var(--accent-amber-soft);
    color: var(--accent-amber);
    border-color: var(--accent-amber);
    animation: sr-play-pulse 1.2s ease-in-out infinite;
}

@keyframes sr-play-pulse {
    0%, 100% { box-shadow: 0 0 0 0 var(--accent-amber-soft); }
    50% { box-shadow: 0 0 0 5px transparent; }
}

.sr-segment-empty {
    text-align: center;
    padding: 24px 12px;
    color: var(--text-muted);
    font-size: var(--fs-xs);
    line-height: 1.8;
}

/* AB 循环标记 */
.sr-ab-marker {
    position: absolute;
    top: -2px;
    width: 3px;
    height: calc(100% + 4px);
    border-radius: 2px;
    pointer-events: none;
    z-index: 6;
}

.sr-ab-marker.marker-a {
    background: var(--accent-amber);
}

.sr-ab-marker.marker-b {
    background: var(--accent-primary);
}

/* 跟唱练习 */
.sr-practice-status {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    font-size: var(--fs-sm);
}

.sr-practice-status .sr-status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--text-muted);
    transition: background var(--transition-base);
}

.sr-practice-status.recording .sr-status-dot {
    background: var(--accent-red);
    animation: sr-pulse-rec 1.2s ease-in-out infinite;
}

.sr-practice-status.playing-original .sr-status-dot {
    background: var(--accent-amber);
}

@keyframes sr-pulse-rec {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.3); }
}

.sr-countdown {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.5);
    z-index: 9999;
    font-size: 120px;
    font-weight: 900;
    font-family: var(--font-serif);
    color: var(--accent-primary);
    opacity: 0;
    transition: opacity var(--transition-base), transform var(--transition-base);
    pointer-events: none;
}

.sr-countdown.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

/* 音高对比画布 */
.sr-pitch-compare {
    position: relative;
    height: 200px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-top: 12px;
}

.sr-pitch-canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.sr-pitch-legend {
    display: flex;
    gap: 16px;
    padding: 8px 12px;
    font-size: var(--fs-xs);
    color: var(--text-muted);
}

.sr-pitch-legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.sr-pitch-legend-dot {
    width: 12px;
    height: 3px;
    border-radius: 2px;
}

/* 音频解码覆盖层 */
.sr-decode-overlay {
    position: absolute;
    inset: 0;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    background: rgba(8, 12, 22, 0.78);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border-radius: var(--radius-lg);
    z-index: 10;
}

[data-theme="light"] .sr-decode-overlay {
    background: rgba(250, 248, 245, 0.78);
}

.sr-decode-overlay.show {
    display: flex;
}

.sr-decode-ring {
    transform: rotate(-90deg);
}

.sr-decode-ring-track {
    stroke: var(--border-default);
}

.sr-decode-ring-progress {
    stroke: var(--accent-primary);
    transition: stroke-dashoffset 0.18s ease-out;
}

.sr-decode-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.sr-decode-percent {
    font-family: var(--font-mono);
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--accent-primary);
}

.sr-decode-label {
    font-size: var(--fs-xs);
    color: var(--text-muted);
}

/* AI 占位 */
.sr-ai-placeholder {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    background: var(--accent-purple-soft);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    font-size: var(--fs-xs);
    color: var(--text-muted);
    margin-top: 8px;
}

.sr-ai-placeholder .sr-ai-badge {
    padding: 2px 8px;
    border-radius: var(--radius-sm);
    background: var(--accent-purple-soft);
    color: var(--accent-purple);
    font-size: 10px;
    font-weight: 700;
    flex-shrink: 0;
}

/* 空状态 */
.sr-empty-state {
    text-align: center;
    padding: 60px 24px;
    color: var(--text-muted);
}

.sr-empty-state .sr-empty-icon {
    font-size: 56px;
    margin-bottom: 16px;
    opacity: 0.4;
}

.sr-empty-state .sr-empty-title {
    font-size: var(--fs-body);
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.sr-empty-state .sr-empty-desc {
    font-size: var(--fs-xs);
    line-height: 1.8;
    max-width: 400px;
    margin: 0 auto;
}

/* ================================================================
   模块3：旋律迷宫
   ================================================================ */

#view-maze {
    background: var(--bg-primary);
}

/* 钢琴键盘 */
.piano-keyboard {
    display: flex;
    position: relative;
    height: 100px;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 4px;
}

.piano-keyboard::-webkit-scrollbar {
    height: 4px;
}

.piano-keyboard::-webkit-scrollbar-thumb {
    background: var(--border-strong);
    border-radius: 2px;
}

.white-key {
    flex: 0 0 36px;
    height: 100%;
    background: var(--bg-card);
    border: 1px solid var(--border-strong);
    border-radius: 0 0 var(--radius-sm) var(--radius-sm);
    cursor: pointer;
    position: relative;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 4px;
    font-size: 9px;
    color: var(--text-tertiary);
    font-weight: 500;
    transition: all 0.1s;
    user-select: none;
}

.white-key:hover {
    background: var(--accent-amber-soft);
}

.white-key:active,
.white-key.active {
    background: var(--accent-amber);
    color: var(--text-inverse);
    transform: translateY(2px);
}

.black-key {
    position: absolute;
    width: 24px;
    height: 60%;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-strong);
    border-radius: 0 0 var(--radius-sm) var(--radius-sm);
    cursor: pointer;
    z-index: 2;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 3px;
    font-size: 8px;
    color: var(--text-muted);
    transition: all 0.1s;
    user-select: none;
}

.black-key:hover {
    background: var(--accent-primary-soft);
}

.black-key:active,
.black-key.active {
    background: var(--accent-primary);
    color: var(--text-inverse);
    transform: translateY(2px);
}

/* 音高序列显示 */
.sequence-display {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    min-height: 40px;
    padding: 8px;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    border: 1px dashed var(--border-subtle);
}

.seq-note {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 6px;
    background: var(--accent-primary-soft);
    border: 1px solid var(--accent-primary);
    border-radius: var(--radius-sm);
    font-size: var(--fs-xs);
    font-weight: 600;
    color: var(--accent-primary);
    font-family: var(--font-mono);
    position: relative;
    cursor: pointer;
}

.seq-note:hover {
    background: var(--accent-primary);
    color: var(--text-inverse);
}

.seq-note .remove-x {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 14px;
    height: 14px;
    background: var(--accent-red);
    border-radius: 50%;
    font-size: 9px;
    color: white;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.seq-note:hover .remove-x {
    display: flex;
}

.seq-note-transformed {
    background: var(--accent-amber-soft);
    border-color: var(--accent-amber);
    color: var(--accent-amber);
}

.seq-note-original {
    background: var(--accent-primary-soft);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

/* 示例按钮 */
.sample-btn {
    padding: 4px 10px;
    font-size: var(--fs-xs);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.sample-btn:hover {
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
    border-color: var(--accent-primary);
}

/* Burnside 公式 */
.burnside-formula {
    text-align: center;
}

.formula-box {
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.formula-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    font-size: var(--fs-sm);
}

.formula-divider {
    height: 1px;
    background: var(--border-subtle);
    margin: 4px 0;
}

/* 轨道可视化节点 */
.orbit-node {
    cursor: pointer;
    transition: all var(--transition-base);
}

.orbit-node circle {
    transition: all var(--transition-base);
}

.orbit-node:hover circle {
    filter: brightness(1.3);
}

.orbit-node text {
    pointer-events: none;
}

/* 四象限标签 */
.quadrant-label {
    padding: 6px 10px;
    border-radius: var(--radius-md);
    background: color-mix(in srgb, var(--q-color) 8%, transparent);
    border: 1px solid color-mix(in srgb, var(--q-color) 20%, transparent);
    color: var(--q-color);
    font-weight: 500;
    text-align: center;
}

/* 步骤徽章 */
.maze-step-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent-primary-soft);
    border: 1px solid var(--accent-primary);
    color: var(--accent-primary);
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    font-weight: 700;
    letter-spacing: 0.02em;
    flex-shrink: 0;
}

/* 公式展示盒 */
.maze-theory-formula-box {
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    padding: 24px 20px;
    text-align: center;
}

.maze-theory-main-formula {
    font-family: var(--font-mono);
    font-size: clamp(16px, 3vw, 22px);
    color: var(--text-primary);
    letter-spacing: 0.03em;
    line-height: 1.6;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    justify-content: center;
}

/* 分数渲染 */
.maze-frac {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    vertical-align: middle;
    line-height: 1.1;
}

.maze-frac-num {
    border-bottom: 1.5px solid var(--border-strong);
    padding: 0 8px 2px;
    font-size: 0.85em;
}

.maze-frac-den {
    padding: 2px 8px 0;
    font-size: 0.85em;
}

/* 公式分项注解 */
.maze-anno-item {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    padding: 12px 14px;
    transition: border-color var(--transition-base);
}

.maze-anno-item:hover {
    border-color: var(--accent-primary);
}

.maze-anno-symbol {
    font-family: var(--font-mono);
    font-size: var(--fs-body);
    font-weight: 700;
    color: var(--accent-primary);
    margin-bottom: 6px;
}

.maze-anno-desc {
    font-size: 0.72rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* 项目关联条目 */
.maze-conn-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    padding: 12px 14px;
}

.maze-conn-icon {
    font-size: 20px;
    flex-shrink: 0;
    line-height: 1.4;
}

/* 操作引导步骤 */
.maze-guide-step {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    padding: 16px 14px;
    transition: border-color var(--transition-base);
}

.maze-guide-step:hover {
    border-color: var(--accent-primary);
}

.maze-guide-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--accent-primary-soft);
    border: 1px solid var(--accent-primary);
    color: var(--accent-primary);
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    font-weight: 700;
}

/* 阶段进度指示器 */
.maze-phase-progress {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: 16px;
    padding: 10px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
}

.maze-phase-step {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 12px;
    opacity: 0.4;
    transition: opacity var(--transition-base);
}

.maze-phase-step .mps-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    font-weight: 700;
    transition: all var(--transition-base);
}

.maze-phase-step .mps-label {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    white-space: nowrap;
    transition: color var(--transition-base);
}

.maze-phase-step.active {
    opacity: 1;
}

.maze-phase-step.active .mps-num {
    background: var(--accent-primary-soft);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.maze-phase-step.active .mps-label {
    color: var(--accent-primary);
    font-weight: 600;
}

.maze-phase-step.completed {
    opacity: 0.8;
}

.maze-phase-step.completed .mps-num {
    background: var(--accent-amber-soft);
    border-color: var(--accent-amber);
    color: var(--accent-amber);
    font-size: 0;
}

.maze-phase-step.completed .mps-num::after {
    content: '✓';
    font-size: var(--fs-xs);
}

.maze-phase-step.completed .mps-label {
    color: var(--text-secondary);
}

.maze-phase-divider {
    width: 32px;
    height: 1px;
    background: var(--border-default);
    flex-shrink: 0;
}

/* 叙事区域 */
.maze-narrative {
    transition: max-height var(--transition-slow), opacity var(--transition-base);
    overflow: hidden;
}

.maze-narrative-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    padding: 8px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    margin-bottom: 8px;
    transition: background var(--transition-fast);
}

.maze-narrative-toggle:hover {
    background: var(--bg-hover);
}

.maze-narrative-toggle .mnt-label {
    font-size: var(--fs-sm);
    font-weight: 600;
    color: var(--text-secondary);
}

.maze-narrative-toggle .mnt-arrow {
    color: var(--text-muted);
    transition: transform var(--transition-base);
}

.maze-narrative-toggle.collapsed .mnt-arrow {
    transform: rotate(-90deg);
}

/* 列占位提示 */
.maze-col-placeholder {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
    font-size: var(--fs-sm);
    line-height: 1.8;
}

.maze-col-placeholder .mcp-icon {
    font-size: 32px;
    opacity: 0.3;
    margin-bottom: 10px;
}

.maze-col-placeholder .mcp-hint {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    margin-top: 4px;
}

/* Burnside 交互式可视化 */
.burnside-interactive {
    padding: 20px;
}

.burnside-canvas-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 1;
    max-width: 360px;
    margin: 0 auto;
}

.burnside-canvas-wrapper canvas {
    width: 100%;
    height: 100%;
    display: block;
    cursor: pointer;
}

.burnside-color-picker {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 12px 0;
    flex-wrap: wrap;
}

.burnside-color-swatch {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-md);
    cursor: pointer;
    border: 2px solid transparent;
    transition: all var(--transition-fast);
    position: relative;
}

.burnside-color-swatch:hover {
    transform: scale(1.15);
}

.burnside-color-swatch.selected {
    border-color: var(--border-strong);
}

.burnside-color-swatch.selected::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: var(--fs-xs);
    font-weight: 900;
}

.burnside-transform-btns {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin: 12px 0;
    flex-wrap: wrap;
}

.burnside-btn {
    padding: 8px 16px;
    border-radius: var(--radius-md);
    background: var(--accent-primary-soft);
    border: 1px solid var(--accent-primary);
    color: var(--accent-primary);
    font-size: var(--fs-xs);
    cursor: pointer;
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 4px;
}

.burnside-btn:hover {
    background: var(--accent-primary);
    color: var(--text-inverse);
}

.burnside-sides-select {
    display: flex;
    gap: 6px;
    justify-content: center;
    margin-bottom: 8px;
}

.burnside-side-btn {
    padding: 4px 12px;
    border-radius: var(--radius-sm);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    color: var(--text-muted);
    font-size: var(--fs-xs);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.burnside-side-btn.active {
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
    border-color: var(--accent-primary);
}

.burnside-formula-interactive {
    text-align: center;
    padding: 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    margin: 12px 0;
    font-family: var(--font-mono);
}

.burnside-formula-line {
    font-size: var(--fs-sm);
    color: var(--text-muted);
    margin: 4px 0;
    transition: all var(--transition-base);
}

.burnside-formula-line .bf-token {
    display: inline-block;
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    margin: 0 2px;
    transition: all var(--transition-base);
    cursor: pointer;
}

.burnside-formula-line .bf-token:hover {
    background: var(--accent-primary-soft);
}

.burnside-formula-line .bf-token.highlight {
    background: var(--accent-amber-soft);
    color: var(--accent-amber);
}

.burnside-formula-result {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--accent-amber);
    margin-top: 8px;
}

.burnside-bubble {
    position: absolute;
    max-width: 220px;
    padding: 10px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    line-height: 1.6;
    z-index: 100;
    opacity: 0;
    pointer-events: none;
    transform: translateY(8px);
    transition: all var(--transition-fast);
    box-shadow: var(--shadow-lg);
}

.burnside-bubble.show {
    opacity: 1;
    transform: translateY(0);
}

.burnside-bubble strong {
    color: var(--accent-primary);
}

.burnside-explanation {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    line-height: 1.8;
    text-align: center;
    margin-top: 12px;
    padding: 10px;
    background: var(--accent-primary-soft);
    border-radius: var(--radius-sm);
    border-left: 3px solid var(--accent-primary);
}

/* ================================================================
   模块4：情绪锚点
   ================================================================ */

#view-anchor {
    background: var(--bg-primary);
}

/* 情绪显示 */
.emotion-display {
    min-height: 120px;
}

.emotion-icon-large {
    font-size: 48px;
    text-align: center;
    margin-bottom: 8px;
}

.emotion-name {
    font-size: 1.5rem;
    font-weight: 900;
    font-family: var(--font-serif);
    text-align: center;
    color: var(--text-primary);
}

.emotion-desc {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    text-align: center;
    margin-top: 4px;
}

/* 特征条 */
.feature-bar {
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: 3px;
    overflow: hidden;
}

.feature-bar-fill {
    height: 100%;
    width: 0%;
    background: var(--fb-color, var(--accent-primary));
    border-radius: 3px;
    transition: width 0.3s ease;
}

/* 统计数据 */
.stat-box {
    padding: 10px 6px;
    border-radius: var(--radius-md);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
}

.stat-value {
    font-size: 1.375rem;
    font-weight: 800;
    font-family: var(--font-mono);
    color: var(--accent-purple);
}

.stat-label {
    font-size: 10px;
    color: var(--text-muted);
    margin-top: 2px;
}

/* 情绪分布 */
.emotion-dist-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.dist-label {
    width: 36px;
    font-size: var(--fs-xs);
    font-weight: 600;
}

.dist-bar {
    flex: 1;
    height: 8px;
    background: var(--bg-tertiary);
    border-radius: 4px;
    overflow: hidden;
}

.dist-bar-fill {
    height: 100%;
    background: var(--d-color, var(--accent-primary));
    border-radius: 4px;
    transition: width var(--transition-slow);
}

.dist-count {
    width: 24px;
    text-align: right;
    font-size: var(--fs-xs);
    font-family: var(--font-mono);
    color: var(--text-secondary);
}

/* 学习旅程 */
.journey-stages {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 4px;
}

.journey-stage {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.stage-dot {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--bg-tertiary);
    border: 2px solid var(--border-default);
    transition: all var(--transition-base);
}

.journey-stage.completed .stage-dot {
    background: var(--accent-purple);
    border-color: var(--accent-purple);
}

.journey-stage.active .stage-dot {
    background: var(--accent-amber);
    border-color: var(--accent-amber);
    animation: pulse-dot 1.5s ease-in-out infinite;
}

.journey-line {
    flex: 1;
    height: 2px;
    background: var(--bg-tertiary);
    margin: 0 4px;
    margin-bottom: 18px;
}

.journey-line.completed {
    background: var(--accent-purple);
}

/* 情绪卡片 */
.emotion-card {
    padding: 16px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-default);
    background: var(--bg-card);
    position: relative;
    overflow: hidden;
    transition: all var(--transition-base);
}

.emotion-card:hover {
    border-color: var(--border-strong);
}

.emotion-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.emotion-card-type {
    font-size: 1.125rem;
    font-weight: 800;
    font-family: var(--font-serif);
}

.emotion-card-time {
    font-size: 10px;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

.emotion-card-body {
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    line-height: 1.6;
}

.emotion-card-mini-viz {
    height: 40px;
    margin-top: 8px;
    border-radius: var(--radius-sm);
    background: var(--bg-secondary);
    overflow: hidden;
}

/* 情绪链路可视化 */
.emotion-chain-viz {
    position: relative;
    height: 60px;
    margin: 12px 0;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.emotion-chain-canvas {
    width: 100%;
    height: 100%;
    display: block;
}

.emotion-coord-bubble {
    position: absolute;
    max-width: 200px;
    padding: 10px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    line-height: 1.6;
    z-index: 50;
    opacity: 0;
    pointer-events: none;
    transform: translateY(4px);
    transition: all var(--transition-fast);
    box-shadow: var(--shadow-lg);
}

.emotion-coord-bubble.show {
    opacity: 1;
    transform: translateY(0);
}

.emotion-coord-bubble .ec-label {
    font-size: var(--fs-sm);
    font-weight: 700;
    margin-bottom: 4px;
}

.emotion-science-panel {
    padding: 12px 16px;
    background: var(--accent-primary-soft);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    margin-top: 12px;
}

.emotion-science-panel h4 {
    font-size: var(--fs-xs);
    color: var(--accent-primary);
    margin-bottom: 6px;
    font-weight: 700;
}

.emotion-science-panel p {
    font-size: 11px;
    color: var(--text-muted);
    line-height: 1.7;
}

.emotion-axis-label {
    position: absolute;
    font-size: 10px;
    color: var(--text-muted);
    pointer-events: none;
}

/* 情绪锚点计算链路 */
.exp-calc-chain {
    position: relative;
    padding: 16px;
    margin-top: 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.exp-calc-chain-step {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    opacity: 0.5;
    transition: opacity var(--transition-slow);
}

.exp-calc-chain-step.active {
    opacity: 1;
}

.exp-calc-chain-step .cs-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--fs-xs);
    font-weight: 700;
    background: var(--accent-primary-soft);
    border: 1px solid var(--accent-primary);
    color: var(--accent-primary);
    flex-shrink: 0;
    transition: all var(--transition-base);
}

.exp-calc-chain-step.active .cs-icon {
    background: var(--accent-primary);
    color: var(--text-inverse);
}

.exp-calc-chain-step .cs-label {
    font-size: var(--fs-xs);
    color: var(--text-secondary);
}

.exp-calc-chain-step .cs-value {
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    color: var(--accent-amber);
    margin-left: auto;
}

.exp-calc-chain-arrow {
    width: 2px;
    height: 16px;
    margin-left: 13px;
    background: var(--border-default);
}

/* ================================================================
   模块5：双演对照实验室
   ================================================================ */

#view-duallab {
    background: var(--bg-primary);
}

/* 场景说明 */
.dl-scene-desc {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: var(--radius-md);
    background: var(--accent-pink-soft);
    border: 1px solid var(--border-default);
    color: var(--accent-pink);
    font-family: var(--font-sans);
    font-size: var(--fs-sm);
    line-height: 1.6;
}

/* 预设对比样本条 */
.dl-preset-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: var(--radius-md);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
}

.dl-preset-label {
    font-family: var(--font-sans);
    font-size: var(--fs-xs);
    font-weight: 700;
    color: var(--accent-pink);
    letter-spacing: 0.05em;
}

.dl-preset-btn {
    color: var(--accent-pink);
    border-color: var(--accent-pink);
    background: var(--accent-pink-soft);
}

.dl-preset-btn:hover {
    background: var(--accent-pink);
    color: var(--text-inverse);
    border-color: var(--accent-pink);
}

.dl-preset-note {
    font-family: var(--font-sans);
    font-size: 11px;
    color: var(--text-muted);
}

/* 分析提示 */
.dl-analyze-hint {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 12px;
    padding: 8px 12px;
    border-radius: var(--radius-md);
    background: var(--accent-amber-soft);
    border: 1px solid var(--accent-amber);
    color: var(--accent-amber);
    font-family: var(--font-sans);
    font-size: var(--fs-xs);
    line-height: 1.5;
    transition: opacity var(--transition-base);
}

.dl-analyze-hint.hidden {
    display: none;
}

/* 上传区 */
.dl-upload-zone {
    border: 2px dashed var(--border-default);
    border-radius: var(--radius-xl);
    padding: 40px 24px;
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-base);
    background: var(--bg-tertiary);
    position: relative;
    overflow: hidden;
}

.dl-upload-zone:hover,
.dl-upload-zone.dragover {
    border-color: var(--border-strong);
    background: var(--bg-hover);
}

.dl-upload-zone[data-side="a"]:hover,
.dl-upload-zone[data-side="a"].dragover {
    border-color: var(--accent-amber);
}

.dl-upload-zone[data-side="b"]:hover,
.dl-upload-zone[data-side="b"].dragover {
    border-color: var(--accent-primary);
}

.dl-upload-icon {
    font-size: 40px;
    margin-bottom: 12px;
    opacity: 0.7;
    transition: transform var(--transition-base);
    line-height: 1;
}

.dl-upload-zone:hover .dl-upload-icon {
    transform: scale(1.15);
}

.dl-upload-text {
    font-family: var(--font-sans);
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    margin-bottom: 6px;
    font-weight: 500;
}

.dl-upload-hint {
    font-family: var(--font-sans);
    font-size: 11px;
    color: var(--text-muted);
    line-height: 1.6;
}

/* 迷你播放器 */
.dl-mini-player {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    margin-top: 12px;
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
}

.dl-play-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: var(--text-inverse);
    flex-shrink: 0;
    transition: transform var(--transition-fast);
    line-height: 1;
}

#dl-play-a {
    background: var(--accent-amber);
}

#dl-play-b {
    background: var(--accent-primary);
}

.dl-play-btn:hover {
    transform: translateY(-3px);
}

.dl-play-btn:active {
    transform: translateY(-1px) scale(0.96);
}

.dl-player-info {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.dl-time {
    font-family: var(--font-mono);
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

/* 频谱画布 */
.dl-spectrum-canvas {
    display: block;
    width: 100%;
    height: 180px;
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
}

/* 图例 */
.dl-legend-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

/* 注释文本框 */
.dl-annotation-input {
    width: 100%;
    min-height: 100px;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    color: var(--text-primary);
    font-family: var(--font-sans);
    font-size: var(--fs-sm);
    line-height: 1.7;
    resize: vertical;
    outline: none;
    transition: border-color var(--transition-fast);
    box-sizing: border-box;
}

.dl-annotation-input:focus {
    border-color: var(--accent-pink);
}

.dl-annotation-input::placeholder {
    color: var(--text-muted);
}

/* 情感指标展示 */
.dl-emotion-summary {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.dl-emotion-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 4px;
}

.dl-emotion-label {
    font-family: var(--font-sans);
    font-size: var(--fs-xs);
    color: var(--text-muted);
}

.dl-emotion-value {
    font-family: var(--font-mono);
    font-size: 1rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    color: var(--text-primary);
}

.dl-emotion-bar {
    width: 100%;
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: 3px;
    overflow: hidden;
}

.dl-emotion-bar-fill {
    height: 100%;
    border-radius: 3px;
    transition: width var(--transition-slow);
}

.dl-emotion-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: var(--radius-md);
    font-family: var(--font-sans);
    font-size: var(--fs-sm);
    font-weight: 700;
}

.dl-feature-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    border-bottom: 1px solid var(--border-subtle);
    font-size: var(--fs-xs);
}

.dl-feature-row:last-child {
    border-bottom: none;
}

.dl-feature-label {
    font-family: var(--font-sans);
    color: var(--text-secondary);
}

.dl-feature-value {
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--text-primary);
    font-variant-numeric: tabular-nums;
}

/* ================================================================
   模块6：浮岛成长
   ================================================================ */

#view-island {
    background: var(--bg-primary);
}

/* 统计数据 */
.island-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: var(--space-5);
    margin-bottom: var(--space-6);
}

.island-stat {
    text-align: center;
}

.island-stat-value {
    font-family: var(--font-mono);
    font-size: 2rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.2;
    font-variant-numeric: tabular-nums;
}

.island-stat-label {
    font-size: var(--fs-xs);
    color: var(--text-tertiary);
    margin-top: var(--space-1);
}

/* 今日小目标卡片 */
.daily-goal-card {
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    padding: var(--space-4) var(--space-5);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
}

.daily-goal-info h4 {
    font-family: var(--font-sans);
    font-size: var(--fs-body);
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.daily-goal-info p {
    font-size: var(--fs-sm);
    color: var(--text-tertiary);
    margin: 0;
}

.daily-goal-progress {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    min-width: 200px;
}

.daily-goal-progress .progress {
    flex: 1;
}

/* 里程碑时间轴 */
.milestone-timeline {
    position: relative;
    padding-left: var(--space-5);
}

.milestone-timeline::before {
    content: '';
    position: absolute;
    left: 7px;
    top: 8px;
    bottom: 8px;
    width: 2px;
    background: var(--border-subtle);
}

.milestone-item {
    position: relative;
    padding-bottom: var(--space-5);
}

.milestone-item:last-child {
    padding-bottom: 0;
}

.milestone-dot {
    position: absolute;
    left: -21px;
    top: 4px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 2px solid var(--border-default);
    transition: all var(--transition-fast);
}

.milestone-item.completed .milestone-dot {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
}

.milestone-title {
    font-size: var(--fs-sm);
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.milestone-desc {
    font-size: var(--fs-xs);
    color: var(--text-tertiary);
}

.milestone-reward {
    display: inline-block;
    margin-top: var(--space-2);
    padding: 0.125rem 0.5rem;
    font-size: 11px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    color: var(--text-tertiary);
}

.milestone-item.completed .milestone-reward {
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
}

/* 浮岛 Canvas 容器 */
.island-canvas-wrap {
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

/* 成就徽章 */
.achievement-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: var(--space-3);
}

.achievement-badge {
    text-align: center;
    padding: var(--space-3);
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    opacity: 0.4;
    filter: grayscale(1);
    transition: all var(--transition-fast);
}

.achievement-badge.unlocked {
    opacity: 1;
    filter: none;
    border-color: var(--accent-primary);
    background: var(--accent-primary-soft);
}

.achievement-icon {
    width: 36px;
    height: 36px;
    margin: 0 auto var(--space-2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.achievement-name {
    font-size: var(--fs-xs);
    font-weight: 500;
    color: var(--text-secondary);
}

.achievement-badge.unlocked .achievement-name {
    color: var(--text-primary);
}

/* 留言板 */
.island-message-board {
    margin-top: 16px;
}

.message-board-notice {
    padding: 8px 12px;
    background: var(--accent-amber-soft);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-sm);
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 12px;
    display: flex;
    align-items: flex-start;
    gap: 6px;
}

.message-board-notice .mb-notice-icon {
    flex-shrink: 0;
    font-size: 14px;
    margin-top: 1px;
}

.message-input-area {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 12px;
}

.message-nick-input {
    width: 100%;
    padding: 8px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: var(--fs-xs);
    outline: none;
    transition: border-color var(--transition-fast);
}

.message-nick-input:focus {
    border-color: var(--accent-purple);
}

.message-nick-input::placeholder {
    color: var(--text-muted);
}

.message-text-area {
    width: 100%;
    min-height: 60px;
    max-height: 120px;
    padding: 10px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: var(--fs-sm);
    font-family: inherit;
    resize: vertical;
    outline: none;
    transition: border-color var(--transition-fast);
}

.message-text-area:focus {
    border-color: var(--accent-purple);
}

.message-text-area::placeholder {
    color: var(--text-muted);
}

.message-char-count {
    text-align: right;
    font-size: 10px;
    color: var(--text-muted);
}

.message-char-count.over-limit {
    color: var(--accent-red);
}

.message-submit-btn {
    align-self: flex-end;
    padding: 8px 20px;
    border-radius: var(--radius-md);
    background: var(--accent-purple);
    border: none;
    color: var(--text-inverse);
    font-size: var(--fs-xs);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 4px;
}

.message-submit-btn:hover {
    background: var(--accent-purple);
    filter: brightness(1.1);
}

.message-submit-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.message-list {
    max-height: 400px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.message-card {
    padding: 12px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
    animation: msg-slide-in 0.4s ease;
}

@keyframes msg-slide-in {
    from { opacity: 0; transform: translateY(-12px) scale(0.97); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.message-card:hover {
    background: var(--bg-hover);
    border-color: var(--accent-purple);
}

.message-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 6px;
}

.message-card-nick {
    font-size: var(--fs-xs);
    font-weight: 700;
    color: var(--accent-purple);
    display: flex;
    align-items: center;
    gap: 4px;
}

.message-card-time {
    font-size: 10px;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

.message-card-body {
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    line-height: 1.7;
    word-break: break-word;
}

.message-card-delete {
    width: 20px;
    height: 20px;
    border-radius: var(--radius-sm);
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: var(--fs-xs);
    opacity: 0;
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
}

.message-card:hover .message-card-delete {
    opacity: 0.6;
}

.message-card-delete:hover {
    opacity: 1;
    color: var(--accent-red);
    background: var(--accent-red-soft);
}

.message-empty {
    text-align: center;
    padding: 32px 16px;
    color: var(--text-muted);
    font-size: var(--fs-xs);
    line-height: 1.8;
}

.message-empty .me-icon {
    font-size: 36px;
    margin-bottom: 8px;
    opacity: 0.3;
}

/* ================================================================
   体验增强模块（从 experience.css + enhancements.css 迁移）
   ================================================================ */

/* 视差滚动层 */
.exp-parallax-layer {
    position: absolute;
    inset: 0;
    pointer-events: none;
    will-change: transform;
    transition: transform 0.1s linear;
}

/* 绿洲背景重构：移除生硬的实心山脉/浮岛多边形色块，
   星星弱化为若隐若现的细碎点缀（由全局 oasis 网格与光斑承担氛围） */
.exp-parallax-mountains,
.exp-parallax-islands {
    display: none !important;
}

.exp-parallax-stars { z-index: 1; opacity: 0.22; }

/* 氛围音按钮 */
.exp-ambient-btn {
    position: fixed;
    bottom: 24px;
    right: 80px;
    z-index: 55;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: var(--radius-full);
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    color: var(--accent-primary);
    font-size: var(--fs-sm);
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-base);
    user-select: none;
}

.exp-ambient-btn:hover {
    background: var(--bg-hover);
    border-color: var(--accent-primary);
}

.exp-ambient-btn.playing,
.exp-ambient-btn.active {
    background: var(--accent-primary-soft);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.exp-ambient-btn .exp-ambient-icon {
    font-size: 16px;
    transition: transform var(--transition-base);
}

.exp-ambient-btn.playing .exp-ambient-icon,
.exp-ambient-btn.active .exp-ambient-icon {
    animation: amb-icon-spin 3s linear infinite;
}

@keyframes amb-icon-spin {
    to { transform: rotate(360deg); }
}

/* 氛围音面板 */
.amb-panel {
    position: fixed;
    bottom: 80px;
    right: 24px;
    width: 320px;
    max-width: calc(100vw - 48px);
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    padding: 16px;
    z-index: 9998;
    transform: translateY(20px) scale(0.95);
    opacity: 0;
    pointer-events: none;
    transition: all var(--transition-base);
    box-shadow: var(--shadow-xl);
}

.amb-panel.open {
    transform: translateY(0) scale(1);
    opacity: 1;
    pointer-events: auto;
}

.amb-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.amb-panel-title {
    font-size: var(--fs-sm);
    font-weight: 700;
    color: var(--text-secondary);
}

.amb-panel-close {
    width: 24px;
    height: 24px;
    border-radius: var(--radius-sm);
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.amb-panel-close:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.amb-track-info {
    text-align: center;
    margin-bottom: 12px;
    padding: 12px;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
}

.amb-track-name {
    font-size: var(--fs-sm);
    color: var(--accent-amber);
    font-weight: 600;
    margin-bottom: 2px;
}

.amb-track-composer {
    font-size: 11px;
    color: var(--text-muted);
}

.amb-track-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 12px;
}

.amb-ctrl-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
    font-size: var(--fs-sm);
}

.amb-ctrl-btn:hover {
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
    border-color: var(--accent-primary);
}

.amb-ctrl-btn.amb-play-btn {
    width: 44px;
    height: 44px;
    background: var(--accent-amber);
    color: var(--text-inverse);
    border: none;
    font-size: 16px;
}

.amb-ctrl-btn.amb-play-btn:hover {
    transform: scale(1.08);
}

.amb-volume-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.amb-volume-icon {
    font-size: var(--fs-sm);
    color: var(--text-muted);
    flex-shrink: 0;
}

.amb-volume-slider {
    flex: 1;
    height: 4px;
    -webkit-appearance: none;
    appearance: none;
    background: var(--bg-tertiary);
    border-radius: 2px;
    outline: none;
}

.amb-volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent-primary);
    cursor: pointer;
}

.amb-volume-slider::-moz-range-thumb {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent-primary);
    cursor: pointer;
    border: none;
}

.amb-playlist {
    max-height: 140px;
    overflow-y: auto;
    margin-top: 8px;
}

.amb-playlist-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: var(--fs-xs);
    color: var(--text-muted);
}

.amb-playlist-item:hover {
    background: var(--bg-hover);
    color: var(--text-secondary);
}

.amb-playlist-item.active {
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
}

.amb-playlist-item .amb-pl-icon {
    font-size: 10px;
    opacity: 0.6;
}

/* 傅里叶知识卡片 */
.exp-knowledge-card {
    position: absolute;
    z-index: 100;
    width: min(340px, 90vw);
    background: var(--bg-card);
    border: 1px solid var(--accent-primary);
    border-radius: var(--radius-lg);
    padding: 20px 22px;
    color: var(--text-primary);
    box-shadow: var(--shadow-xl);
    opacity: 0;
    transform: scale(0.7) translateY(10px);
    transition: opacity var(--transition-slow), transform var(--transition-slow);
    pointer-events: none;
}

.exp-knowledge-card.show {
    opacity: 1;
    transform: scale(1) translateY(0);
    pointer-events: auto;
}

.exp-knowledge-card .kc-title {
    font-family: var(--font-serif);
    font-size: 1rem;
    font-weight: 700;
    color: var(--accent-amber);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.exp-knowledge-card .kc-body {
    font-size: var(--fs-sm);
    line-height: 1.8;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.exp-knowledge-card .kc-diagram {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 12px 0;
    padding: 10px;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
}

.exp-knowledge-card .kc-diagram svg {
    max-width: 100%;
    height: auto;
}

.exp-knowledge-card .kc-quote {
    font-size: var(--fs-xs);
    color: var(--accent-primary);
    font-style: italic;
    text-align: center;
    padding: 8px 0;
    border-top: 1px solid var(--border-subtle);
    margin-top: 8px;
}

.exp-knowledge-card .kc-close {
    display: block;
    width: 100%;
    margin-top: 12px;
    padding: 8px;
    border-radius: var(--radius-md);
    background: var(--accent-primary-soft);
    border: 1px solid var(--accent-primary);
    color: var(--accent-primary);
    font-size: var(--fs-xs);
    font-weight: 600;
    cursor: pointer;
    transition: background var(--transition-fast);
}

.exp-knowledge-card .kc-close:hover {
    background: var(--accent-primary);
    color: var(--text-inverse);
}

/* 声景花园正向提示 */
.exp-garden-whisper {
    position: absolute;
    top: 16px;
    left: 50%;
    transform: translateX(-50%) translateY(-10px);
    z-index: 10;
    padding: 10px 20px;
    border-radius: var(--radius-full);
    background: var(--accent-primary-soft);
    border: 1px solid var(--accent-primary);
    color: var(--accent-primary);
    font-size: var(--fs-sm);
    font-weight: 500;
    white-space: nowrap;
    opacity: 0;
    transition: opacity var(--transition-slow), transform var(--transition-slow);
    pointer-events: none;
    max-width: 90%;
    overflow: hidden;
    text-overflow: ellipsis;
}

.exp-garden-whisper.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* 生长阶段指示器 */
.exp-growth-stage-bar {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 8px 12px;
    margin-top: 8px;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
}

.exp-growth-stage-dot {
    flex: 1;
    height: 4px;
    border-radius: 2px;
    background: var(--bg-tertiary);
    transition: background var(--transition-slow);
}

.exp-growth-stage-dot.active {
    background: var(--accent-primary);
}

.exp-growth-stage-label {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    margin-left: 8px;
    white-space: nowrap;
}

/* 数学公式卡片 */
.exp-formula-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    padding: 20px 24px;
    margin: 12px 0;
}

.exp-formula-card .ef-title {
    font-family: var(--font-serif);
    font-size: var(--fs-sm);
    font-weight: 700;
    color: var(--accent-amber);
    margin-bottom: 12px;
    letter-spacing: 0.03em;
}

.exp-formula-line {
    font-family: var(--font-mono);
    font-size: 0.9375rem;
    line-height: 2.2;
    color: var(--text-primary);
    letter-spacing: 0.02em;
}

.exp-formula-param {
    display: inline-block;
    padding: 2px 8px;
    margin: 0 1px;
    border-radius: var(--radius-sm);
    background: var(--accent-primary-soft);
    border: 1px solid var(--accent-primary);
    color: var(--accent-primary);
    cursor: pointer;
    transition: all var(--transition-fast);
    position: relative;
}

.exp-formula-param:hover {
    background: var(--accent-primary);
    color: var(--text-inverse);
}

.exp-formula-hint {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    margin-top: 10px;
    text-align: center;
    font-style: italic;
}

/* 公式参数注解气泡 */
.exp-annotation-bubble {
    position: absolute;
    z-index: 200;
    width: min(280px, 85vw);
    padding: 14px 18px;
    background: var(--bg-card);
    border: 1px solid var(--accent-primary);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: var(--fs-xs);
    line-height: 1.7;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    transform: translateY(8px) scale(0.95);
    transition: opacity var(--transition-base), transform var(--transition-base);
    pointer-events: none;
}

.exp-annotation-bubble.show {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.exp-annotation-bubble .ab-symbol {
    font-family: var(--font-mono);
    font-weight: 700;
    color: var(--accent-primary);
    font-size: var(--fs-sm);
    margin-bottom: 4px;
}

.exp-annotation-bubble .ab-close {
    position: absolute;
    top: 6px;
    right: 8px;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--bg-hover);
    cursor: pointer;
    font-size: var(--fs-xs);
    color: var(--text-muted);
    transition: background var(--transition-fast);
}

.exp-annotation-bubble .ab-close:hover {
    background: var(--bg-active);
    color: var(--text-primary);
}

/* 情绪锚点注解按钮 */
.exp-help-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--accent-primary-soft);
    border: 1px solid var(--accent-primary);
    color: var(--accent-primary);
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    transition: all var(--transition-fast);
    margin-left: 6px;
    vertical-align: middle;
}

.exp-help-btn:hover {
    background: var(--accent-primary);
    color: var(--text-inverse);
    transform: scale(1.15);
}

/* 88键全音域钢琴 */
.exp-piano-88 {
    position: relative;
    height: 120px;
    overflow-x: auto;
    overflow-y: hidden;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: 0;
    cursor: grab;
    scrollbar-width: thin;
    scrollbar-color: var(--border-strong) transparent;
}

.exp-piano-88.dragging {
    cursor: grabbing;
}

.exp-piano-88::-webkit-scrollbar {
    height: 6px;
}

.exp-piano-88::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}

.exp-piano-88::-webkit-scrollbar-thumb {
    background: var(--border-strong);
    border-radius: 3px;
}

.exp-piano-inner {
    display: flex;
    position: relative;
    height: 100%;
    user-select: none;
}

.exp-white-key-88 {
    flex: 0 0 28px;
    height: 100%;
    background: var(--bg-card);
    border: 1px solid var(--border-strong);
    border-radius: 0 0 var(--radius-sm) var(--radius-sm);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 6px;
    font-size: 8px;
    color: var(--text-tertiary);
    cursor: pointer;
    transition: background 0.08s, transform 0.08s;
    position: relative;
    z-index: 1;
}

.exp-white-key-88:hover {
    background: var(--accent-amber-soft);
}

.exp-white-key-88:active,
.exp-white-key-88.active {
    background: var(--accent-primary);
    color: var(--text-inverse);
    transform: translateY(2px);
}

.exp-white-key-88.octave-c {
    border-left: 2px solid var(--accent-amber);
}

.exp-black-key-88 {
    position: absolute;
    width: 18px;
    height: 68%;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-strong);
    border-radius: 0 0 var(--radius-sm) var(--radius-sm);
    z-index: 2;
    cursor: pointer;
    transition: background 0.08s, transform 0.08s;
}

.exp-black-key-88:hover {
    background: var(--accent-primary-soft);
}

.exp-black-key-88:active,
.exp-black-key-88.active {
    background: var(--accent-primary);
    transform: translateY(2px);
}

.exp-piano-range-labels {
    display: flex;
    justify-content: space-between;
    padding: 4px 8px;
    font-size: 10px;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

/* 旋律彩蛋卡片 */
.exp-melody-easter-egg {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.7);
    z-index: 9999;
    width: min(380px, 92vw);
    padding: 28px 24px;
    background: var(--bg-card);
    border: 1px solid var(--accent-amber);
    border-radius: var(--radius-xl);
    text-align: center;
    color: var(--text-primary);
    box-shadow: var(--shadow-xl);
    opacity: 0;
    transition: opacity var(--transition-slow), transform var(--transition-slow);
    pointer-events: none;
}

.exp-melody-easter-egg.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    pointer-events: auto;
}

.exp-melody-easter-egg .ee-sparkle {
    font-size: 36px;
    margin-bottom: 8px;
    animation: ee-sparkle-spin 2s ease-in-out infinite;
}

@keyframes ee-sparkle-spin {
    0%, 100% { transform: rotate(0deg) scale(1); }
    50%      { transform: rotate(10deg) scale(1.1); }
}

.exp-melody-easter-egg .ee-title {
    font-family: var(--font-serif);
    font-size: 1.125rem;
    font-weight: 800;
    color: var(--accent-amber);
    margin-bottom: 6px;
}

.exp-melody-easter-egg .ee-scene {
    font-size: var(--fs-sm);
    color: var(--accent-primary);
    margin-bottom: 12px;
}

.exp-melody-easter-egg .ee-desc {
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 16px;
}

.exp-melody-easter-egg .ee-close {
    padding: 8px 24px;
    border-radius: var(--radius-md);
    background: var(--accent-amber-soft);
    border: 1px solid var(--accent-amber);
    color: var(--accent-amber);
    font-size: var(--fs-xs);
    font-weight: 600;
    cursor: pointer;
    transition: background var(--transition-fast);
}

.exp-melody-easter-egg .ee-close:hover {
    background: var(--accent-amber);
    color: var(--text-inverse);
}

/* 抽象线条动画 */
.exp-abstract-art-canvas {
    width: 100%;
    height: 120px;
    margin-bottom: 12px;
    border-radius: var(--radius-md);
    background: var(--bg-secondary);
}

/* 每日签到礼盒 */
.exp-daily-gift {
    position: absolute;
    top: 15%;
    right: 7%;
    transform: scale(0);
    z-index: 5;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0;
    color: #7C6A55;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(62, 158, 119, 0.22);
    box-shadow: 0 2px 8px rgba(62, 158, 119, 0.10);
    cursor: pointer;
    transition: transform .3s ease, background .2s ease, border-color .2s ease;
}

.exp-daily-gift.show {
    transform: scale(1);
}

.exp-daily-gift:hover {
    transform: scale(1.08);
    background: #fff;
    border-color: rgba(62, 158, 119, 0.42);
}

/* 签到奖励弹窗 */
.exp-gift-reward {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.7);
    z-index: 9999;
    padding: 24px 32px;
    background: var(--bg-card);
    border: 1px solid var(--accent-amber);
    border-radius: var(--radius-xl);
    text-align: center;
    color: var(--text-primary);
    opacity: 0;
    transition: opacity var(--transition-base), transform var(--transition-base);
    pointer-events: none;
}

.exp-gift-reward.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    pointer-events: auto;
}

.exp-gift-reward .gr-emoji {
    font-size: 40px;
    margin-bottom: 8px;
}

.exp-gift-reward .gr-text {
    font-size: var(--fs-sm);
    color: var(--accent-amber);
    margin-bottom: 12px;
}

.exp-gift-reward .gr-value {
    font-family: var(--font-mono);
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--accent-primary);
    margin-bottom: 12px;
}

/* 里程碑时间轴（浮岛） */
.exp-milestone-timeline {
    position: relative;
    padding: 16px 0 16px 28px;
    max-height: 380px;
    overflow-y: auto;
}

.exp-milestone-timeline::before {
    content: '';
    position: absolute;
    left: 10px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border-default);
}

.exp-milestone-node {
    position: relative;
    margin-bottom: 16px;
    cursor: pointer;
    transition: transform var(--transition-fast);
}

.exp-milestone-node:hover {
    transform: translateX(4px);
}

.exp-milestone-dot {
    position: absolute;
    left: -22px;
    top: 4px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 2px solid var(--text-muted);
    transition: all var(--transition-base);
}

.exp-milestone-node.unlocked .exp-milestone-dot {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
}

.exp-milestone-content {
    padding: 10px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.exp-milestone-node.unlocked .exp-milestone-content {
    background: var(--accent-primary-soft);
    border-color: var(--accent-primary);
}

.exp-milestone-node:hover .exp-milestone-content {
    border-color: var(--accent-primary);
}

.exp-milestone-title {
    font-size: var(--fs-sm);
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.exp-milestone-node:not(.unlocked) .exp-milestone-title {
    color: var(--text-muted);
}

.exp-milestone-date {
    font-size: 10px;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

.exp-milestone-desc {
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    margin-top: 4px;
    line-height: 1.5;
}

.exp-milestone-reward {
    font-size: 10px;
    font-weight: 600;
    color: var(--accent-amber);
    margin-top: 4px;
}

.exp-milestone-node.unlocked .exp-milestone-reward {
    color: var(--text-muted);
}

/* 浮岛交互元素光点 */
.exp-island-sparkle {
    position: absolute;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--accent-amber);
    pointer-events: none;
    opacity: 0;
    z-index: 6;
}

/* 浮岛数据叙事化 */
.exp-narrative-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin-top: 12px;
}

.exp-narrative-stat {
    padding: 10px 12px;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    text-align: center;
}

.exp-narrative-stat .ns-value {
    font-family: var(--font-serif);
    font-size: 1.125rem;
    font-weight: 800;
    color: var(--accent-primary);
}

.exp-narrative-stat .ns-label {
    font-size: 10px;
    color: var(--text-muted);
    margin-top: 2px;
}

/* 懒加载占位 */
.exp-lazy-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
    color: var(--text-muted);
    font-size: var(--fs-sm);
}

.exp-lazy-placeholder .lp-spinner {
    width: 24px;
    height: 24px;
    border: 2px solid var(--border-default);
    border-top-color: var(--accent-primary);
    border-radius: 50%;
    animation: exp-lazy-spin 0.8s linear infinite;
    margin-right: 8px;
}

@keyframes exp-lazy-spin {
    to { transform: rotate(360deg); }
}

/* 歌词模块 */
.lyrics-panel {
    margin-top: 16px;
}

.lyrics-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.lyrics-panel-title {
    font-size: var(--fs-sm);
    font-weight: 700;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 6px;
}

.lyrics-tabs {
    display: flex;
    gap: 4px;
}

.lyrics-tab {
    padding: 4px 12px;
    border-radius: var(--radius-sm);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    color: var(--text-muted);
    font-size: var(--fs-xs);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.lyrics-tab:hover {
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
}

.lyrics-tab.active {
    background: var(--accent-primary-soft);
    color: var(--accent-primary);
    border-color: var(--accent-primary);
}

.lyrics-upload-area {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
}

.lyrics-upload-btn {
    flex: 1;
    padding: 10px;
    border: 1px dashed var(--accent-primary);
    border-radius: var(--radius-md);
    background: var(--accent-primary-soft);
    color: var(--text-secondary);
    font-size: var(--fs-xs);
    cursor: pointer;
    text-align: center;
    transition: all var(--transition-fast);
}

.lyrics-upload-btn:hover {
    background: var(--accent-primary);
    color: var(--text-inverse);
    border-color: var(--accent-primary);
}

.lyrics-text-input {
    width: 100%;
    min-height: 80px;
    padding: 10px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-size: var(--fs-xs);
    font-family: inherit;
    resize: vertical;
    outline: none;
    transition: border-color var(--transition-fast);
}

.lyrics-text-input:focus {
    border-color: var(--accent-primary);
}

.lyrics-text-input::placeholder {
    color: var(--text-muted);
    font-size: 11px;
}

.lyrics-display {
    max-height: 200px;
    overflow-y: auto;
    padding: 8px 4px;
    text-align: center;
}

.lyrics-line {
    padding: 6px 12px;
    font-size: var(--fs-sm);
    color: var(--text-muted);
    line-height: 1.8;
    transition: all var(--transition-base);
    border-radius: var(--radius-sm);
}

.lyrics-line.active {
    color: var(--accent-amber);
    font-size: 0.9375rem;
    font-weight: 600;
    transform: scale(1.02);
}

.lyrics-line.passed {
    color: var(--text-muted);
    opacity: 0.5;
}

.lyrics-hint {
    font-size: 10px;
    color: var(--text-muted);
    text-align: center;
    margin-top: 6px;
    line-height: 1.6;
}

/* ================================================================
   页脚
   ================================================================ */

.site-footer {
    margin-top: var(--space-12);
    padding: var(--space-6) 1.5rem;
    border-top: 1px solid var(--border-subtle);
    text-align: center;
    background: var(--bg-secondary);
}

.footer-title {
    font-family: var(--font-serif);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-secondary);
    letter-spacing: 0.02em;
    margin-bottom: var(--space-2);
}

.footer-subtitle {
    font-size: var(--fs-xs);
    color: var(--text-tertiary);
    letter-spacing: 0.03em;
}

/* ================================================================
   弹窗模态辅助类（从内联样式迁移）
   ================================================================ */

.modal-backdrop {
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

[data-theme="light"] .modal-backdrop {
    background: rgba(0, 0, 0, 0.4);
}

.modal-dialog {
    max-width: 420px;
    border-radius: var(--radius-xl);
}

.modal-icon-amber {
    background: var(--accent-amber-soft);
    border: 1px solid var(--accent-amber);
}

.modal-icon-teal {
    background: var(--accent-primary-soft);
    border: 1px solid var(--accent-primary);
}

.modal-min-width {
    min-width: 200px;
}

/* 画布高度辅助类 */
.canvas-h-400 { height: 400px; }
.canvas-h-280 { height: 280px; }
.canvas-h-380 { height: 380px; }
.canvas-h-240 { height: 240px; }

/* Russell 情绪环容器 */
.russell-canvas-wrap {
    width: 100%;
    max-width: 380px;
    aspect-ratio: 1;
    margin: 0 auto;
}

/* 上传区域边框 */
.dl-drop-zone-border {
    border: 2px dashed var(--accent-primary);
    border-color: rgba(45, 212, 191, 0.25);
}

/* SVG 垂直对齐辅助 */
.svg-valign {
    vertical-align: -2px;
}

/* ================================================================
   响应式：移动端适配
   ================================================================ */

@media (max-width: 768px) {
    .module-header {
        margin-bottom: 1.5rem;
    }

    .module-title {
        font-size: 1.5rem;
    }

    .island-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-4);
    }

    .island-stat-value {
        font-size: 1.5rem;
    }

    .daily-goal-card {
        flex-direction: column;
        align-items: flex-start;
    }

    .daily-goal-progress {
        width: 100%;
        min-width: auto;
    }

    /* 唱段研习室 */
    .sr-player-bar {
        gap: 8px;
        padding: 10px;
    }

    .sr-play-btn {
        width: 48px;
        height: 48px;
    }

    .sr-speed-control {
        min-width: 120px;
    }

    .sr-waveform-container {
        height: 100px;
    }

    .sr-pitch-compare {
        height: 160px;
    }

    .sr-countdown {
        font-size: 80px;
    }

    .sr-upload-zone {
        padding: 28px 16px;
    }

    .sr-segment-item {
        padding: 10px 8px;
        font-size: var(--fs-xs);
    }

    .sr-segment-btn {
        width: 32px;
        height: 32px;
        font-size: var(--fs-sm);
    }

    .sr-zoom-controls {
        flex-wrap: wrap;
    }

    .sr-waveform-guide {
        width: 100%;
        margin-left: 0;
    }

    /* 双演对照 */
    .dl-upload-zone {
        padding: 28px 16px;
    }

    .dl-upload-icon {
        font-size: 32px;
    }

    .dl-mini-player {
        padding: 10px 12px;
        gap: 10px;
    }

    .dl-play-btn {
        width: 44px;
        height: 44px;
    }

    .dl-spectrum-canvas {
        height: 140px;
    }

    .dl-annotation-input {
        min-height: 80px;
        font-size: var(--fs-xs);
    }

    .dl-emotion-value {
        font-size: 0.875rem;
    }

    /* 氛围音面板 */
    .amb-panel {
        bottom: 72px;
        right: 12px;
        width: calc(100vw - 24px);
    }

    /* Burnside */
    .burnside-canvas-wrapper {
        max-width: 280px;
    }

    .burnside-color-swatch {
        width: 32px;
        height: 32px;
    }

    .burnside-btn {
        padding: 10px 14px;
        font-size: var(--fs-sm);
    }

    /* 留言板 */
    .message-submit-btn {
        align-self: stretch;
        text-align: center;
        justify-content: center;
        padding: 10px;
    }

    /* 歌词面板 */
    .lyrics-line {
        font-size: var(--fs-sm);
        padding: 8px 10px;
    }

    .lyrics-line.active {
        font-size: 1rem;
    }

    /* 88键钢琴 */
    .exp-white-key-88 {
        flex: 0 0 24px;
    }

    .exp-black-key-88 {
        width: 16px;
    }

    /* 里程碑时间轴 */
    .exp-milestone-timeline {
        max-height: 280px;
    }

    /* 视差层移动端关闭 */
    .exp-parallax-layer {
        display: none;
    }

    /* 氛围音按钮位置 */
    .exp-ambient-btn {
        bottom: 16px;
        right: 16px;
        padding: 8px 14px;
        font-size: var(--fs-xs);
    }
}

@media (max-width: 480px) {
    .sr-player-bar {
        flex-direction: column;
        align-items: stretch;
    }

    .sr-speed-control {
        min-width: 100%;
    }

    .dl-mini-player {
        padding: 8px 10px;
    }

    .dl-play-btn {
        width: 40px;
        height: 40px;
        font-size: var(--fs-xs);
    }

    .dl-time {
        font-size: 11px;
    }

    .exp-narrative-stats {
        grid-template-columns: 1fr;
    }
}

/* 减少动画偏好 */
@media (prefers-reduced-motion: reduce) {
    #view-home,
    #view-home::before,
    .exp-ambient-btn.playing .exp-ambient-icon,
    .exp-daily-gift {
        animation: none;
    }

    .exp-parallax-layer {
        display: none;
    }
}

/* ================================================================
   内联样式提取 — 从 index.html 迁移的静态内联样式
   ================================================================ */

/* ==================== 加载屏幕（增强版） ==================== */
.loading-screen {
    background:
        radial-gradient(ellipse at 20% 20%, rgba(45, 212, 191, 0.12) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(210, 153, 34, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(13, 148, 136, 0.05) 0%, transparent 70%),
        var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* 中央内容容器 */
.loading-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 2rem;
    max-width: 480px;
    width: 100%;
}

/* ===== Logo ===== */
.loading-logo {
    width: 120px;
    height: 120px;
    margin-bottom: 1.25rem;
    opacity: 0;
    animation: loading-logo-in 1s cubic-bezier(0.22, 1, 0.36, 1) 0.1s forwards;
}

.loading-logo-svg {
    width: 100%;
    height: 100%;
    animation: loading-logo-spin 20s linear infinite;
}

.loading-logo-note,
.loading-logo-math {
    animation: loading-logo-pulse 3s ease-in-out infinite;
}

.loading-logo-math {
    animation-delay: 1.5s;
}

.loading-logo-wave {
    animation: loading-wave-pulse 2.5s ease-in-out infinite;
}

@keyframes loading-logo-in {
    from {
        opacity: 0;
        transform: scale(0.8) rotate(-10deg);
    }
    to {
        opacity: 1;
        transform: scale(1) rotate(0);
    }
}

@keyframes loading-logo-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes loading-logo-pulse {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

@keyframes loading-wave-pulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.6; }
}

/* ===== 装饰波形 ===== */
.loading-waveform {
    width: 280px;
    height: 40px;
    margin: 0.5rem 0 1rem 0;
    opacity: 0;
    animation: loading-fade-up 0.8s ease-out 0.3s forwards;
}

.loading-waveform svg {
    width: 100%;
    height: 100%;
    overflow: visible;
}

.loading-waveform-path {
    animation: loading-waveform-morph 2.5s ease-in-out infinite;
}

@keyframes loading-waveform-morph {
    0%, 100% {
        d: path("M0 20 Q15 8 30 20 T60 20 T90 20 T120 20 T150 20 T180 20 T210 20 T240 20 T270 20 T300 20");
    }
    25% {
        d: path("M0 20 Q15 4 30 20 T60 20 T90 20 T120 20 T150 20 T180 20 T210 20 T240 20 T270 20 T300 20");
    }
    50% {
        d: path("M0 20 Q15 30 30 20 T60 20 T90 20 T120 20 T150 20 T180 20 T210 20 T240 20 T270 20 T300 20");
    }
    75% {
        d: path("M0 20 Q15 12 30 20 T60 20 T90 20 T120 20 T150 20 T180 20 T210 20 T240 20 T270 20 T300 20");
    }
}

/* ===== 进度条 ===== */
.loading-progress-wrap {
    width: 240px;
    margin-top: 1.5rem;
    opacity: 0;
    animation: loading-fade-up 0.8s ease-out 0.7s forwards;
}

.loading-progress-track {
    position: relative;
    width: 100%;
    height: 3px;
    background: var(--border-subtle);
    border-radius: 3px;
    overflow: hidden;
}

.loading-progress-bar {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 0;
    background: linear-gradient(90deg, var(--accent-primary), var(--accent-amber), var(--accent-primary));
    background-size: 200% 100%;
    border-radius: 3px;
    animation:
        loading-progress-fill 5s ease-out forwards,
        loading-progress-shimmer 2s linear infinite;
    box-shadow: 0 0 8px rgba(45, 212, 191, 0.4);
}

@keyframes loading-progress-fill {
    0%   { width: 0%; }
    15%  { width: 20%; }
    30%  { width: 35%; }
    50%  { width: 55%; }
    70%  { width: 72%; }
    85%  { width: 85%; }
    100% { width: 92%; }
}

@keyframes loading-progress-shimmer {
    0%   { background-position: 0% 50%; }
    100% { background-position: 200% 50%; }
}

/* ===== 背景粒子 ===== */
.loading-particles {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    overflow: hidden;
}

.loading-particle {
    position: absolute;
    border-radius: 50%;
    opacity: 0;
    animation: loading-particle-float 8s ease-in-out infinite;
}

.loading-particle::after {
    content: '';
    position: absolute;
    inset: -200%;
    border-radius: 50%;
    background: inherit;
    filter: blur(1px);
    opacity: 0.3;
}

/* 琥珀色粒子 */
.loading-particle--1 {
    width: 3px; height: 3px;
    background: rgba(210, 153, 34, 0.8);
    left: 10%; top: 20%;
    animation-delay: 0s;
}
.loading-particle--2 {
    width: 2px; height: 2px;
    background: rgba(210, 153, 34, 0.6);
    left: 25%; top: 70%;
    animation-delay: 1.2s;
}
.loading-particle--3 {
    width: 4px; height: 4px;
    background: rgba(210, 153, 34, 0.5);
    left: 85%; top: 15%;
    animation-delay: 2.5s;
}
.loading-particle--4 {
    width: 2px; height: 2px;
    background: rgba(210, 153, 34, 0.7);
    left: 70%; top: 80%;
    animation-delay: 0.8s;
}
.loading-particle--5 {
    width: 3px; height: 3px;
    background: rgba(210, 153, 34, 0.5);
    left: 50%; top: 10%;
    animation-delay: 3.2s;
}
.loading-particle--6 {
    width: 2px; height: 2px;
    background: rgba(210, 153, 34, 0.6);
    left: 35%; top: 45%;
    animation-delay: 1.8s;
}

/* 青色粒子 */
.loading-particle--7 {
    width: 3px; height: 3px;
    background: rgba(45, 212, 191, 0.8);
    left: 15%; top: 60%;
    animation-delay: 0.5s;
}
.loading-particle--8 {
    width: 2px; height: 2px;
    background: rgba(45, 212, 191, 0.6);
    left: 80%; top: 40%;
    animation-delay: 1.7s;
}
.loading-particle--9 {
    width: 4px; height: 4px;
    background: rgba(45, 212, 191, 0.5);
    left: 5%; top: 85%;
    animation-delay: 2.9s;
}
.loading-particle--10 {
    width: 2px; height: 2px;
    background: rgba(45, 212, 191, 0.7);
    left: 92%; top: 65%;
    animation-delay: 0.3s;
}
.loading-particle--11 {
    width: 3px; height: 3px;
    background: rgba(45, 212, 191, 0.5);
    left: 60%; top: 25%;
    animation-delay: 2.1s;
}
.loading-particle--12 {
    width: 2px; height: 2px;
    background: rgba(45, 212, 191, 0.6);
    left: 45%; top: 90%;
    animation-delay: 3.6s;
}

@keyframes loading-particle-float {
    0% {
        opacity: 0;
        transform: translateY(20px) scale(0.5);
    }
    20% {
        opacity: 1;
    }
    80% {
        opacity: 1;
    }
    100% {
        opacity: 0;
        transform: translateY(-30px) scale(1);
    }
}

/* ===== 响应式 ===== */
@media (max-width: 640px) {
    .loading-title {
        font-size: 2rem;
    }
    .loading-logo {
        width: 96px;
        height: 96px;
    }
    .loading-waveform {
        width: 220px;
    }
    .loading-progress-wrap {
        width: 200px;
    }
    .loading-subtitle {
        font-size: 0.8rem;
    }
}

/* ===== 旧的 wave 样式保留（模块加载仍在用） ===== */
.loading-wave {
    height: 40px;
    gap: 4px;
}

.loading-wave-bar {
    width: 5px;
}

/* ==================== 导航图标尺寸 ==================== */
.nav-icon-sm {
    width: 14px;
    height: 14px;
}

.nav-icon-sm-ml {
    width: 14px;
    height: 14px;
    margin-left: 2px;
}

.nav-icon-md {
    width: 18px;
    height: 18px;
}

.nav-icon-lg {
    width: 20px;
    height: 20px;
}

.nav-icon-settings {
    width: 16px;
    height: 16px;
    color: var(--text-tertiary);
}

.nav-icon-16 {
    width: 16px;
    height: 16px;
}

/* ==================== 移动端菜单 ==================== */
.mobile-menu {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-default);
}

.mobile-menu-divider {
    height: 1px;
    background: var(--border-subtle);
    margin: 0.375rem 0;
}

/* ==================== 首页视图内边距 ==================== */
#view-home {
    padding-top: 80px;
    padding-bottom: 40px;
}

/* ==================== 首页 Hero 容器 ==================== */
.hero-container {
    min-height: calc(100vh - 120px);
    display: flex;
    align-items: center;
}

/* ==================== 模块标题颜色 ==================== */
.module-heading-rose { color: #FB7185; }
.module-heading-teal { color: #2DD4BF; }
.module-heading-cyan { color: #06B6D4; }
.module-heading-pink { color: #F472B6; }
.module-heading-purple { color: #A78BFA; }

/* ==================== 子标题颜色 ==================== */
.dl-heading-amber { color: #F59E0B; }
.dl-heading-teal { color: #2DD4BF; }
.island-heading-purple { color: #A78BFA; }

/* ==================== 图例点颜色 ==================== */
.legend-dot-amber { background: #F59E0B; }
.legend-dot-teal { background: #2DD4BF; }
.legend-dot-amber-translucent { background: rgba(245, 158, 11, 0.5); }
.legend-dot-teal-translucent { background: rgba(45, 212, 191, 0.5); }

/* ==================== 分布标签颜色 ==================== */
.dist-label-red { color: #EF4444; }
.dist-label-green { color: #10B981; }
.dist-label-blue { color: #3B82F6; }
.dist-label-amber { color: #F59E0B; }

/* ==================== 象限容器 ==================== */
.quadrant-container {
    width: 100%;
    max-width: 380px;
    aspect-ratio: 1;
}

/* ==================== 模态框遮罩 ==================== */
.modal-overlay {
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

/* ==================== 拖放区域 ==================== */
.drop-zone-teal {
    border-color: rgba(45, 212, 191, 0.25);
}

/* ==================== 用户对比上传区 ==================== */
.user-compare-upload-area {
    position: relative;
    overflow: hidden;
}

/* ==================== 行内图标基线对齐 ==================== */
.inline-icon-baseline {
    vertical-align: -2px;
}

/* ================================================================
   Module 06: Miao Piano (Iframe)
   ================================================================ */

/* Iframe wrapper with glass card frame */
.piano-iframe-wrap {
    width: 100%;
    height: calc(100vh - 140px);
    min-height: 500px;
    max-height: 82vh;
    overflow: hidden;
    padding: 0;
    border-radius: var(--radius-lg);
}

.piano-iframe {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: calc(var(--radius-lg) - 2px);
    display: block;
    background: var(--bg-primary);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .piano-iframe-wrap {
        height: calc(100vh - 140px);
        min-height: 400px;
    }
}

@media (max-width: 480px) {
    .piano-iframe-wrap {
        height: calc(100vh - 160px);
        min-height: 350px;
    }
}

/* ================================================================
   学术说明 (Academic Section) 专用样式
   ================================================================ */

/* 学术区整体排版 */
#view-academic .glass-card {
    margin-bottom: var(--space-5);
}

#view-academic h3 {
    font-family: var(--font-serif);
    font-weight: 700;
    font-size: 1.35rem;
    letter-spacing: -0.01em;
    color: var(--accent-amber);
    margin-bottom: var(--space-4);
    padding-bottom: var(--space-3);
    border-bottom: 1px solid var(--border-subtle);
}

#view-academic h4 {
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: -0.005em;
    color: var(--text-primary);
    margin-top: var(--space-5);
    margin-bottom: var(--space-3);
}

#view-academic h4:first-child {
    margin-top: 0;
}

#view-academic p {
    font-size: var(--fs-sm);
    line-height: var(--lh-relaxed);
    color: var(--text-secondary);
    margin-bottom: var(--space-3);
}

#view-academic strong {
    color: var(--text-primary);
    font-weight: 600;
}

/* 学术区英文文本优化 */
#view-academic .en-term {
    font-family: var(--font-sans);
    font-weight: 500;
    letter-spacing: 0.01em;
    font-variant-numeric: tabular-nums;
}

#view-academic .en-display {
    font-family: var(--font-display);
    font-weight: 500;
    letter-spacing: 0.005em;
}

#view-academic code {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    padding: 0.1em 0.4em;
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    color: var(--accent-amber);
    border: 1px solid var(--border-subtle);
}

/* 研究背景段落 */
.academic-background {
    padding: var(--space-4);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    border-left: 3px solid var(--accent-amber);
    margin-bottom: var(--space-5);
}

.academic-background p {
    font-size: var(--fs-sm);
    line-height: var(--lh-relaxed);
    color: var(--text-secondary);
    margin-bottom: 0;
}

/* 流程图步骤增强 */
.flow-step {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    padding: var(--space-3) var(--space-4);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
    transition: all var(--transition-fast);
}

.flow-step:hover {
    border-color: var(--accent-amber);
    background: var(--bg-hover);
}

.flow-step__index {
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--accent-amber);
    font-size: 0.85rem;
    flex-shrink: 0;
    width: 1.5rem;
    text-align: center;
}

.flow-step__content {
    flex: 1;
    min-width: 0;
}

.flow-step__title {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
    margin-bottom: 0.25rem;
    font-family: var(--font-sans);
    letter-spacing: -0.005em;
}

.flow-step__desc {
    font-size: var(--fs-xs);
    color: var(--text-tertiary);
    line-height: 1.6;
}

.flow-step__io {
    margin-top: 0.35rem;
    font-size: var(--fs-xs);
    color: var(--text-muted);
    font-family: var(--font-mono);
    line-height: 1.5;
}

.flow-step__io span {
    display: inline-block;
    margin-right: var(--space-3);
}

.flow-step__io .io-label {
    color: var(--accent-amber);
    font-weight: 500;
}

/* 创新点卡片 */
.innovation-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-3);
    margin-top: var(--space-4);
}

.innovation-card {
    padding: var(--space-4);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
    transition: all var(--transition-fast);
}

.innovation-card:hover {
    border-color: var(--accent-amber);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.innovation-card__icon {
    font-size: 1.5rem;
    margin-bottom: var(--space-2);
}

.innovation-card__title {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
    margin-bottom: var(--space-2);
    font-family: var(--font-sans);
    letter-spacing: -0.005em;
}

.innovation-card__desc {
    font-size: var(--fs-xs);
    color: var(--text-tertiary);
    line-height: 1.6;
}

@media (max-width: 640px) {
    .innovation-grid {
        grid-template-columns: 1fr;
    }
}

/* 技术路线图 */
.tech-roadmap {
    position: relative;
    padding-left: var(--space-5);
    margin-top: var(--space-4);
}

.tech-roadmap::before {
    content: '';
    position: absolute;
    left: 0.5rem;
    top: 0.5rem;
    bottom: 0.5rem;
    width: 2px;
    background: var(--border-default);
}

.roadmap-phase {
    position: relative;
    padding-bottom: var(--space-4);
}

.roadmap-phase:last-child {
    padding-bottom: 0;
}

.roadmap-phase::before {
    content: '';
    position: absolute;
    left: -1.55rem;
    top: 0.35rem;
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 50%;
    background: var(--accent-amber);
    border: 2px solid var(--bg-card);
    box-shadow: 0 0 0 2px var(--accent-amber);
}

.roadmap-phase__title {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
    margin-bottom: 0.25rem;
    font-family: var(--font-sans);
}

.roadmap-phase__meta {
    font-size: var(--fs-xs);
    color: var(--accent-amber);
    font-family: var(--font-mono);
    margin-bottom: 0.35rem;
}

.roadmap-phase__desc {
    font-size: var(--fs-xs);
    color: var(--text-tertiary);
    line-height: 1.6;
}

/* 验证状态徽章 */
.validation-status {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.75rem;
    background: var(--accent-amber-soft);
    color: var(--accent-amber);
    border-radius: var(--radius-full);
    font-size: var(--fs-xs);
    font-weight: 500;
    font-family: var(--font-sans);
    letter-spacing: 0.01em;
    margin-bottom: var(--space-3);
}

.validation-status__dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent-amber);
    animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

/* 局限列表增强 */
.limitation-list {
    list-style: none;
    padding: 0;
    margin: 0;
    space-y: var(--space-3);
}

.limitation-item {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    padding: var(--space-3);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-2);
    border: 1px solid var(--border-subtle);
}

.limitation-item:last-child {
    margin-bottom: 0;
}

.limitation-item__icon {
    flex-shrink: 0;
    width: 1.25rem;
    height: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    color: var(--accent-red);
    background: var(--accent-red-soft);
    border-radius: var(--radius-sm);
    margin-top: 0.1rem;
}

.limitation-item__content {
    flex: 1;
    min-width: 0;
}

.limitation-item__title {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.8125rem;
    margin-bottom: 0.2rem;
    font-family: var(--font-sans);
}

.limitation-item__desc {
    font-size: var(--fs-xs);
    color: var(--text-tertiary);
    line-height: 1.6;
}

/* 未来工作方向 */
.future-work-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.future-work-item {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    padding: var(--space-3);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-2);
    border: 1px solid var(--border-subtle);
}

.future-work-item:last-child {
    margin-bottom: 0;
}

.future-work-item__icon {
    flex-shrink: 0;
    width: 1.25rem;
    height: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    color: var(--accent-green);
    background: var(--accent-green-soft);
    border-radius: var(--radius-sm);
    margin-top: 0.1rem;
}

.future-work-item__content {
    flex: 1;
    min-width: 0;
}

.future-work-item__title {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.8125rem;
    margin-bottom: 0.2rem;
    font-family: var(--font-sans);
}

.future-work-item__desc {
    font-size: var(--fs-xs);
    color: var(--text-tertiary);
    line-height: 1.6;
}

/* 参考文献列表优化 */
.reference-list {
    list-style: none;
    padding: 0;
    margin: 0;
    counter-reset: reference;
}

.reference-item {
    counter-increment: reference;
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    padding: var(--space-3) var(--space-4);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-2);
    border: 1px solid var(--border-subtle);
    transition: all var(--transition-fast);
}

.reference-item:hover {
    border-color: var(--border-strong);
    background: var(--bg-hover);
}

.reference-item:last-child {
    margin-bottom: 0;
}

.reference-item__num {
    flex-shrink: 0;
    width: 1.5rem;
    height: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    font-weight: 600;
    color: var(--accent-amber);
    background: var(--accent-amber-soft);
    border-radius: var(--radius-sm);
}

.reference-item__content {
    flex: 1;
    min-width: 0;
    font-size: var(--fs-xs);
    line-height: 1.7;
    color: var(--text-secondary);
    font-family: var(--font-sans);
    letter-spacing: 0.005em;
}

.reference-item__content em {
    color: var(--text-primary);
    font-style: italic;
}

.reference-item__doi {
    display: inline-block;
    margin-top: 0.25rem;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--text-muted);
}

/* 参考文献分类显示 */
#view-academic .ref-category {
    margin-bottom: var(--space-5);
}

#view-academic .ref-category:last-child {
    margin-bottom: 0;
}

#view-academic .ref-category__title {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-primary);
    margin-bottom: var(--space-3);
    padding-bottom: var(--space-2);
    border-bottom: 1px solid var(--border-subtle);
    display: flex;
    align-items: baseline;
    gap: var(--space-2);
}

#view-academic .ref-category__en {
    font-size: 0.7rem;
    font-weight: 400;
    color: var(--text-muted);
    font-family: var(--font-sans);
    letter-spacing: 0.02em;
}

#view-academic ol.ref-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

#view-academic .ref-item {
    position: relative;
    padding: var(--space-2) var(--space-3) var(--space-2) 2.25rem;
    margin-bottom: var(--space-2);
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    transition: all var(--transition-fast);
    line-height: 1.65;
}

#view-academic .ref-item:hover {
    border-color: var(--border-subtle);
    background: var(--bg-hover);
}

#view-academic .ref-item:last-child {
    margin-bottom: 0;
}

#view-academic .ref-num {
    position: absolute;
    left: var(--space-3);
    top: var(--space-2);
    font-family: var(--font-mono);
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--accent-amber);
    background: var(--accent-amber-soft);
    padding: 0.1rem 0.35rem;
    border-radius: var(--radius-xs);
    line-height: 1.4;
}

#view-academic .ref-item em {
    color: var(--text-primary);
    font-style: italic;
}

#view-academic .ref-note {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    margin-top: var(--space-4);
    padding-top: var(--space-3);
    border-top: 1px solid var(--border-subtle);
    font-style: italic;
}

/* 可复现性声明 - 信息块 */
.repro-section {
    margin-bottom: var(--space-5);
}

.repro-section:last-child {
    margin-bottom: 0;
}

.repro-section__title {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
    margin-bottom: var(--space-3);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-sans);
    letter-spacing: -0.005em;
}

.repro-section__title-icon {
    width: 1.5rem;
    height: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent-amber-soft);
    color: var(--accent-amber);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
}

.repro-info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-3);
}

.repro-info-card {
    padding: var(--space-3) var(--space-4);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
}

.repro-info-card__label {
    font-size: var(--fs-xs);
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 500;
    margin-bottom: 0.35rem;
    font-family: var(--font-sans);
}

.repro-info-card__value {
    font-size: 0.8125rem;
    color: var(--text-primary);
    font-weight: 500;
    font-family: var(--font-sans);
    line-height: 1.5;
}

.repro-info-card__detail {
    font-size: var(--fs-xs);
    color: var(--text-tertiary);
    margin-top: 0.25rem;
    line-height: 1.5;
}

@media (max-width: 640px) {
    .repro-info-grid {
        grid-template-columns: 1fr;
    }
}

/* 代码结构概览 */
.code-structure {
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
    padding: var(--space-4);
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    line-height: 1.9;
    color: var(--text-secondary);
    overflow-x: auto;
    white-space: nowrap;
}

.code-structure .cs-line {
    display: block;
}

.code-structure .cs-indent-1 { padding-left: 1.25rem; }
.code-structure .cs-indent-2 { padding-left: 2.5rem; }
.code-structure .cs-indent-3 { padding-left: 3.75rem; }
.code-structure .cs-folder { color: var(--accent-amber); font-weight: 600; }
.code-structure .cs-file { color: var(--text-secondary); }
.code-structure .cs-comment { color: var(--text-muted); font-style: italic; margin-left: 0.25rem; }

/* 数据可用性声明 */
.data-availability {
    padding: var(--space-4);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
    font-size: var(--fs-xs);
    line-height: 1.7;
    color: var(--text-secondary);
}

.data-availability strong {
    color: var(--text-primary);
    font-weight: 600;
}

/* 学术区模块标签优化 */
#view-academic .module-tag {
    font-family: var(--font-sans);
    font-weight: 600;
    letter-spacing: 0.03em;
    font-size: 0.7rem;
    text-transform: uppercase;
}

/* 学术区小标题英文副标题 */
.academic-subtitle-en {
    font-family: var(--font-display);
    font-style: italic;
    font-weight: 400;
    color: var(--text-tertiary);
    font-size: 0.85rem;
    letter-spacing: 0.01em;
    margin-top: -0.25rem;
    margin-bottom: var(--space-3);
}

/* Burnside 公式强调 */
.formula-highlight {
    display: block;
    padding: var(--space-3) var(--space-4);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    border-left: 3px solid var(--accent-amber);
    margin: var(--space-3) 0;
    font-family: var(--font-math);
    font-size: 0.9rem;
    color: var(--text-primary);
    text-align: center;
    letter-spacing: 0.02em;
}

/* 响应式调整 */
@media (max-width: 640px) {
    #view-academic .glass-card {
        padding: var(--space-4);
    }

    #view-academic h3 {
        font-size: 1.15rem;
    }
}

/* ================================================================
   绿洲背景系统（#oasis-bg）
   ----------------------------------------------------------------
   · 全局 fixed 层，z-index:-1，位于所有内容之下（若隐若现）
   · 极淡笛卡尔坐标网格（linear-gradient 双方向，浅绿）
   · 2 个柔和渐变光斑（薄荷绿 / 浅薄荷绿），blur 80px，水彩晕开感
   · 光斑呼吸动画（12-16s 错峰）+ 鼠标视差（反向微移，基础 5px）
   · 所有参数由 CSS 变量 --bg-grid-* / --bg-blob-* 管理
   ================================================================ */

#oasis-bg {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
    --px: 0;
    --py: 0;
}

/* ---- 笛卡尔网格 ---- */
.oasis-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(to right, rgba(var(--bg-grid-color), 0.9) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(var(--bg-grid-color), 0.9) 1px, transparent 1px);
    background-size: var(--bg-grid-size) var(--bg-grid-size);
    opacity: var(--bg-grid-opacity);
    /* 视差：反向微移（基础 5px，由 --bg-parallax-strength 管理） */
    transform: translate(
        calc(var(--px) * var(--bg-parallax-strength) * -1),
        calc(var(--py) * var(--bg-parallax-strength) * -1)
    );
    transition: transform 0.4s ease-out;
    will-change: transform;
}

/* ---- 渐变光斑（外层负责视差位移） ---- */
.oasis-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(var(--bg-blob-blur));
    opacity: var(--bg-blob-opacity);
    transition: transform 0.5s ease-out;
    will-change: transform;
}

/* 三个光斑的布局位置：左上 / 右下 / 中右 */
.oasis-blob-1 {
    top: -16vh;
    left: -12vw;
    width: 46vw;
    height: 46vw;
    transform: translate(
        calc(var(--px) * var(--bg-parallax-strength) * -1.4),
        calc(var(--py) * var(--bg-parallax-strength) * -1.4)
    );
}

.oasis-blob-3 {
    top: 52%;
    right: 8vw;
    width: 34vw;
    height: 34vw;
    transform: translate(
        calc(var(--px) * var(--bg-parallax-strength) * -1.6),
        calc(var(--py) * var(--bg-parallax-strength) * -1.6)
    );
}

/* ---- 光斑内核（负责呼吸动画，与视差分层避免 transform 冲突） ---- */
.oasis-blob-core {
    position: absolute;
    inset: 0;
    border-radius: 50%;
}

.oasis-blob-1 .oasis-blob-core { background: var(--bg-blob-color-1); animation: oasis-breathe 14s ease-in-out infinite; }
.oasis-blob-3 .oasis-blob-core { background: var(--bg-blob-color-3); animation: oasis-breathe 12s ease-in-out infinite; animation-delay: -9s; }

/* 呼吸：极缓慢的缩放 + 位置微调（10-15s 量级，不可太快） */
@keyframes oasis-breathe {
    0%, 100% { transform: scale(1) translate(0, 0); }
    33%      { transform: scale(1.08) translate(14px, -10px); }
    66%      { transform: scale(0.96) translate(-10px, 8px); }
}

/* 移动端：光斑更含蓄、模糊半径减小，避免大 blur 性能开销 */
@media (max-width: 768px) {
    .oasis-blob {
        opacity: calc(var(--bg-blob-opacity) * 0.7);
        filter: blur(60px);
    }
}

/* ================================================================
   页脚版权信息：毛玻璃容器
   ----------------------------------------------------------------
   使底部版权文案清晰稳定，与背景形成优雅的层次对比
   ================================================================ */

.footer-glass {
    display: inline-block;
    max-width: min(92vw, 880px);
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 16px;
    padding: 16px 32px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.04);
}

[data-theme="dark"] .footer-glass {
    background: rgba(28, 28, 34, 0.45);
    border-color: rgba(255, 255, 255, 0.12);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.18);
}

/* ================================================================
   声景花园（#view-garden）视觉统一 —— 消除 AI 拼接感
   ----------------------------------------------------------------
   目标：融入全站绿洲主题，浅色/深色双主题适配。
   覆盖点：Header 层级、画布容器、数据卡片（毛玻璃+彩色进度条）、
   空状态（呼吸麦克风+更亮文案）、状态指示器、按钮主次、文字可读性
   ================================================================ */

/* ---- 1. Header 层级与说明文字可读性 ---- */
#view-garden .module-tag {
    font-size: 12px;
    letter-spacing: 0.06em;
}
#view-garden .mb-8 h2 {
    letter-spacing: 0.02em;
}
#view-garden .mb-8 > p {
    color: #4A4A4A;
    font-size: 15px;
    line-height: 1.8;
    max-width: 46rem;
}
[data-theme="dark"] #view-garden .mb-8 > p {
    color: #9898a5;
}

/* ---- 2. 画布容器：圆角 + 柔和环境光晕 ---- */
#view-garden .canvas-h-400 {
    border-radius: 16px;
    overflow: hidden;
    box-shadow: inset 0 0 60px rgba(13, 148, 136, 0.08),
                inset 0 0 24px rgba(124, 58, 237, 0.05);
}
#view-garden .glass-card {
    border-radius: 16px;
}

/* ---- 3. 数据卡片：半透明毛玻璃 + 深色文字 + 彩色进度条 + 大数字 ---- */
#view-garden .feature-readout {
    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(13, 148, 136, 0.16);
    border-radius: 16px;
    padding: 16px;
    box-shadow: 0 4px 18px rgba(13, 148, 136, 0.07);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
#view-garden .feature-readout:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(13, 148, 136, 0.12);
}
#view-garden .readout-label {
    color: #4A4A4A;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.04em;
    margin-bottom: 2px;
}
#view-garden .readout-value {
    font-size: 1.55rem;
    font-weight: 700;
    color: #1a1a1a;
    font-family: var(--font-sans), "Inter", -apple-system, sans-serif;
    letter-spacing: 0.01em;
}
#view-garden .readout-bar {
    height: 6px;
    border-radius: 4px;
    background: rgba(13, 148, 136, 0.08);
    margin-top: 10px;
}
#view-garden .readout-bar-fill {
    border-radius: 4px;
    background: linear-gradient(90deg, var(--bar-color), color-mix(in srgb, var(--bar-color) 55%, #ffffff));
    box-shadow: 0 0 8px color-mix(in srgb, var(--bar-color) 45%, transparent);
}
[data-theme="dark"] #view-garden .feature-readout {
    background: rgba(38, 38, 46, 0.55);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.2);
}
[data-theme="dark"] #view-garden .readout-label {
    color: #9898a5;
}
[data-theme="dark"] #view-garden .readout-value {
    color: #e6e6ee;
}
[data-theme="dark"] #view-garden .readout-bar {
    background: rgba(255, 255, 255, 0.07);
}

/* ---- 4. 空状态：呼吸麦克风 + 更亮更大的引导文案 ---- */
.idle-mic-icon {
    color: #0d9488;
    animation: idle-mic-breathe 3s ease-in-out infinite;
    filter: drop-shadow(0 0 14px rgba(45, 212, 191, 0.55));
}
@keyframes idle-mic-breathe {
    0%, 100% { transform: scale(1); opacity: 0.72; }
    50%      { transform: scale(1.08); opacity: 1; }
}
#view-garden .canvas-idle-hint .idle-main-text {
    font-size: 18px;
    font-weight: 600;
    color: #0d9488;
    letter-spacing: 0.02em;
}
#view-garden .canvas-idle-hint .idle-sub-text {
    font-size: 13px;
    color: #4A4A4A;
    margin-top: 6px;
}
[data-theme="dark"] #view-garden .canvas-idle-hint .idle-sub-text {
    color: #9898a5;
}

/* ---- 5. 麦克风状态指示器：更清晰、开启后绿色光晕 ---- */
#view-garden #mic-status {
    color: #4A4A4A;
    font-weight: 500;
}
#view-garden .status-dot {
    width: 10px;
    height: 10px;
}
#view-garden .status-dot-on {
    box-shadow: 0 0 10px rgba(22, 163, 74, 0.75);
}
[data-theme="dark"] #view-garden #mic-status {
    color: #c8c8d0;
}

/* ---- 6. 按钮主次：主按钮饱满绿色加大，次按钮描边弱化 ---- */
#view-garden #mic-toggle-btn {
    background: linear-gradient(135deg, #0d9488, #0f766e);
    border-color: #0d9488;
    font-size: 15px;
    font-weight: 600;
    padding: 10px 22px;
    border-radius: 12px;
    box-shadow: 0 6px 18px rgba(13, 148, 136, 0.28);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
#view-garden #mic-toggle-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(13, 148, 136, 0.38);
}
#view-garden .ctrl-btn-ghost {
    border-radius: 12px;
    opacity: 0.9;
}
#view-garden .ctrl-btn-ghost:hover {
    opacity: 1;
}

/* ---- 7. 唱段研习室上传区提示文字对比度（与声景花园一致的口径） ---- */
#view-study .sr-upload-text {
    color: #4A4A4A;
    font-size: 15px;
    font-weight: 500;
}
#view-study .sr-upload-hint {
    color: #6b6b6b;
    font-size: 13px;
    line-height: 1.8;
}
[data-theme="dark"] #view-study .sr-upload-text { color: #c8c8d0; }
[data-theme="dark"] #view-study .sr-upload-hint { color: #9898a5; }

/* ================================================================
   旋律迷宫（#view-maze）—— 聚焦交互，折叠理论
   ----------------------------------------------------------------
   1. Burnside 叙事折叠面板（默认收起）
   2. 虚拟钢琴 / 轨道交互区放大 1.5x（核心操作区）
   3. 轨道可视化旁实时数据解读
   ================================================================ */

/* ---- 1. 折叠面板：轻量胶囊头，聚焦交互 ---- */
#view-maze .maze-math-accordion {
    margin-bottom: 20px;
    border: 1px solid var(--border-default);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    overflow: hidden;
    transition: box-shadow 0.3s ease;
}
[data-theme="dark"] #view-maze .maze-math-accordion {
    background: rgba(38, 38, 46, 0.45);
}
#view-maze .maze-accordion-head {
    padding: 14px 18px;
    cursor: pointer;
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 14px;
    font-weight: 600;
    color: #0d9488;
    user-select: none;
}
#view-maze .maze-accordion-head::-webkit-details-marker { display: none; }
#view-maze .maze-accordion-head .maze-chevron { transition: transform 0.3s ease; }
#view-maze .maze-math-accordion[open] .maze-accordion-head .maze-chevron { transform: rotate(180deg); }
#view-maze .maze-math-accordion[open] .maze-accordion-head { border-bottom: 1px solid var(--border-subtle); }

/* ---- 2. 放大交互区：虚拟钢琴 1.5x ---- */
#view-maze #piano-keyboard.piano-keyboard { height: 150px !important; overflow: hidden !important; }
#view-maze .piano-keyboard .white-key { flex: 0 0 54px !important; font-size: 12px; }
#view-maze .piano-keyboard .black-key { width: 36px !important; font-size: 11px; }
/* 轨道可视化区放大（高画布 · 浮岛拓扑图） */
#view-maze .canvas-h-280 { height: 480px; }

/* ================================================================
   旋律迷宫 · 工作区统一背景域（上下半区过渡融合）
   —— 柔和渐变底色包裹三栏 + 右栏底部理论面板，
      「故事模式」从分割线变为内部引导，消除断层感
   ================================================================ */
#view-maze .maze-workspace {
    position: relative;
    border-radius: 24px;
    padding: 18px;
    background: linear-gradient(165deg,
        rgba(232, 245, 233, 0.60) 0%,
        rgba(253, 252, 231, 0.52) 42%,
        rgba(248, 250, 252, 0.72) 78%,
        rgba(245, 245, 245, 0.80) 100%);
    border: 1px solid rgba(45, 212, 191, 0.16);
    box-shadow: 0 14px 44px rgba(15, 23, 42, 0.06);
    margin-top: 6px;
}
[data-theme="dark"] #view-maze .maze-workspace {
    background: linear-gradient(165deg,
        rgba(15, 23, 42, 0.40) 0%,
        rgba(17, 34, 44, 0.46) 45%,
        rgba(15, 23, 42, 0.52) 100%);
    border-color: rgba(148, 163, 184, 0.14);
    box-shadow: 0 14px 44px rgba(0, 0, 0, 0.25);
}
/* 工作区内卡片：半透明玻璃，与渐变域自然融合 */
#view-maze .maze-workspace .glass-card {
    background: rgba(255, 255, 255, 0.62);
    border: 1px solid rgba(255, 255, 255, 0.65);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05);
}
[data-theme="dark"] #view-maze .maze-workspace .glass-card {
    background: rgba(30, 41, 59, 0.55);
    border-color: rgba(148, 163, 184, 0.10);
}
/* 两栏布局：左 钢琴输入 / 右 轨道可视化（4:3）；Burnside 计算整排换行到下方 */
#view-maze .maze-grid {
    display: grid;
    grid-template-columns: 4fr 3fr;
    gap: 16px;
    align-items: start;
}
#view-maze .maze-grid > * { min-width: 0; }
/* 第二排：Burnside 计算 / 旋律结构报告 / 故事情境 三张短卡并排，交互式 Burnside 与数学建模整行铺满 */
#view-maze .maze-secondary {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    align-items: start;
}
#view-maze .maze-secondary > #burnside-interactive-card,
#view-maze .maze-secondary > #maze-math-system { grid-column: 1 / -1; }
/* 交互式 Burnside 单独成行，收窄居中，避免宽屏下色块/不动点清单被拉散 */
#view-maze .maze-secondary > #burnside-interactive-card { max-width: 720px; justify-self: center; width: 100%; }
@media (max-width: 1023px) {
    #view-maze .maze-grid { grid-template-columns: 1fr; }
    #view-maze .maze-secondary { grid-template-columns: 1fr; }
    #view-maze .maze-secondary > #burnside-interactive-card,
    #view-maze .maze-secondary > #maze-math-system { grid-column: auto; }
}
/* 右栏底部数学建模面板：与右栏计算区贴合 */
#view-maze #maze-math-system {
    border-radius: 16px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.62);
}
[data-theme="dark"] #view-maze #maze-math-system {
    background: rgba(30, 41, 59, 0.55);
}

/* 数学建模体系内的 LaTeX 公式卡：原样式按深色底设计，浅色主题下会变成突兀的灰块，这里做浅底适配 */
html[data-theme="light"] #view-maze .maze-formula-card {
    background: rgba(245, 241, 234, 0.75);
    border: 1px solid rgba(203, 190, 168, 0.38);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6);
}
html[data-theme="light"] #view-maze .maze-formula-card .mfc-title { color: var(--accent-amber, #b45309); }
html[data-theme="light"] #view-maze .maze-formula-card .mfc-section-label { color: #0f766e; }
html[data-theme="light"] #view-maze .maze-formula-card .mfc-formula {
    color: #334155;
    border-left-color: rgba(13, 148, 136, 0.3);
}
html[data-theme="light"] #view-maze .maze-formula-card .mfc-annotation { color: #6b7280; }
html[data-theme="light"] #view-maze .maze-formula-card .mfc-divider { background: rgba(15, 23, 42, 0.08); }
html[data-theme="light"] #view-maze .maze-formula-card .mfc-result-label { color: #6b7280; }
html[data-theme="light"] #view-maze .maze-formula-card .mfc-result-formula { color: var(--accent-amber, #b45309); }

/* ---- 3. 数据解读气泡 ---- */
#view-maze .orbit-insight {
    margin-top: 10px;
    padding: 10px 14px;
    border-radius: 12px;
    background: rgba(13, 148, 136, 0.06);
    border: 1px solid rgba(13, 148, 136, 0.16);
    font-size: 12px;
    line-height: 1.7;
    color: #4A4A4A;
    position: relative;
}
#view-maze .orbit-insight-live {
    background: rgba(13, 148, 136, 0.09);
    border-color: rgba(13, 148, 136, 0.3);
}
#view-maze .orbit-insight .orbit-insight-pulse {
    display: inline-block;
    width: 8px;
    height: 8px;
    margin-right: 8px;
    border-radius: 50%;
    background: #0d9488;
    vertical-align: middle;
    box-shadow: 0 0 0 0 rgba(13, 148, 136, 0.5);
    animation: orbit-insight-ping 1.8s ease-out infinite;
}
@keyframes orbit-insight-ping {
    0% { box-shadow: 0 0 0 0 rgba(13, 148, 136, 0.5); }
    70% { box-shadow: 0 0 0 8px rgba(13, 148, 136, 0); }
    100% { box-shadow: 0 0 0 0 rgba(13, 148, 136, 0); }
}
[data-theme="dark"] #view-maze .orbit-insight {
    color: #c8c8d0;
    background: rgba(13, 148, 136, 0.12);
    border-color: rgba(13, 148, 136, 0.3);
}

/* ================================================================
   唱段研习室（#view-study）—— 紧凑上传 + 预设唱段卡片
   ----------------------------------------------------------------
   上传区不再铺满全屏，改为左置紧凑卡片；右侧预设以彩色卡片呈现
   （封面、难度标签、时长、播放按钮），让用户立刻有东西可点。
   ================================================================ */

/* 上传区紧凑化 */
#view-study .sr-upload-zone {
    padding: 30px 20px;
    border-radius: 16px;
    min-height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.4);
    border-color: rgba(13, 148, 136, 0.35);
}
[data-theme="dark"] #view-study .sr-upload-zone {
    background: rgba(38, 38, 46, 0.45);
}
#view-study .sr-upload-text {
    font-size: 15px;
    font-weight: 600;
    color: #4A4A4A;
}
#view-study .sr-upload-hint {
    color: #6b6b6b;
    font-size: 13px;
    line-height: 1.7;
}
[data-theme="dark"] #view-study .sr-upload-text { color: #c8c8d0; }
[data-theme="dark"] #view-study .sr-upload-hint { color: #9898a5; }

/* 预设唱段区头部 */
#view-study .sr-preset-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    font-weight: 600;
    color: #4A4A4A;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-subtle);
}
#view-study .sr-preset-head-hint {
    font-size: 11px;
    font-weight: 400;
    color: var(--text-muted);
}
[data-theme="dark"] #view-study .sr-preset-head { color: #c8c8d0; }

/* 预设卡片网格 */
#view-study .sr-preset-card-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}
/* 窄屏自动降为 2 列 */
@media (max-width: 1024px) {
    #view-study .sr-preset-card-grid { grid-template-columns: repeat(2, 1fr); }
}
/* 手机窄屏降为 1 列 */
@media (max-width: 640px) {
    #view-study .sr-preset-card-grid { grid-template-columns: 1fr; }
}

/* 预设卡片 */
#view-study .sr-preset-card {
    position: relative;
    text-align: left;
    padding: 14px;
    border-radius: 16px;
    border: 1px solid var(--border-default);
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    display: flex;
    flex-direction: column;
    gap: 8px;
    overflow: hidden;
}
#view-study .sr-preset-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(13, 148, 136, 0.12);
}
[data-theme="dark"] #view-study .sr-preset-card {
    background: rgba(38, 38, 46, 0.5);
    border-color: rgba(255, 255, 255, 0.08);
}
/* 各曲目色调 */
#view-study .sr-tone-canon { border-top: 3px solid #0d9488; }
#view-study .sr-tone-phantom { border-top: 3px solid #f472b6; }
#view-study .sr-tone-twinkle { border-top: 3px solid #f59e0b; }

#view-study .sr-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
}
#view-study .sr-card-cover {
    font-size: 28px;
    line-height: 1;
    filter: drop-shadow(0 3px 6px rgba(0,0,0,0.12));
}
#view-study .sr-card-badge {
    font-size: 10px;
    padding: 2px 8px;
    border-radius: 10px;
    color: #0d9488;
    background: rgba(13, 148, 136, 0.1);
    border: 1px solid rgba(13, 148, 136, 0.2);
}
#view-study .sr-card-name {
    font-size: 14px;
    font-weight: 700;
    color: #1a1a1a;
}
#view-study .sr-card-desc {
    font-size: 11px;
    color: #6b6b6b;
    line-height: 1.6;
}
[data-theme="dark"] #view-study .sr-card-name { color: #e6e6ee; }
[data-theme="dark"] #view-study .sr-card-desc { color: #9898a5; }
#view-study .sr-card-meta {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}
#view-study .sr-card-tag {
    font-size: 10px;
    padding: 2px 8px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid var(--border-subtle);
    color: #6b6b6b;
}
[data-theme="dark"] #view-study .sr-card-tag {
    background: rgba(255, 255, 255, 0.04);
    color: #9898a5;
}
#view-study .sr-card-play {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: auto;
    padding-top: 8px;
    font-size: 12px;
    font-weight: 600;
    color: #0d9488;
    border-top: 1px dashed rgba(13, 148, 136, 0.25);
}
#view-study .sr-card-play span {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(13, 148, 136, 0.12);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
}

/* ================================================================
   情绪锚点（#view-anchor）—— 引导态 + 渐变维度光带 + 折叠公式
   ================================================================ */

/* 引导态提示条 */
#view-anchor .anchor-guide {
    margin-bottom: 10px;
    padding: 8px 12px;
    border-radius: 12px;
    font-size: 12px;
    line-height: 1.6;
    color: #4A4A4A;
    background: rgba(6, 182, 212, 0.07);
    border: 1px solid rgba(6, 182, 212, 0.18);
    display: flex;
    align-items: center;
    gap: 8px;
    animation: anchor-guide-breathe 3.2s ease-in-out infinite;
}
@keyframes anchor-guide-breathe {
    0%, 100% { box-shadow: 0 0 0 0 rgba(6, 182, 212, 0.12); }
    50% { box-shadow: 0 0 12px 2px rgba(6, 182, 212, 0.18); }
}
[data-theme="dark"] #view-anchor .anchor-guide {
    color: #c8c8d0;
    background: rgba(6, 182, 212, 0.12);
    border-color: rgba(6, 182, 212, 0.3);
}

/* 维度条：渐变光带（冷蓝 → 暖橙），契合情绪环 */
#view-anchor .feature-bar {
    height: 8px;
    border-radius: 6px;
    background: rgba(13, 148, 136, 0.08);
    overflow: hidden;
}
#view-anchor .feature-bar-fill {
    border-radius: 6px;
    background: linear-gradient(90deg,
        #06B6D4 0%, #2DD4BF 40%, #F59E0B 72%, #F97316 100%);
    box-shadow: 0 0 10px rgba(6, 182, 212, 0.35);
}

/* 数学内核折叠面板：默认收起 + 统一圆角 */
#view-anchor details.glass-card {
    border-radius: 16px;
    overflow: hidden;
}

/* ================================================================
   双演对照实验室（#view-duallab）—— 去警告化 + VS 标识 + 就绪变绿
   ----------------------------------------------------------------
   1. 移除红色警告感：状态提示改柔和中性条
   2. 上传框之间加 VS 对比徽标
   3. 分析按钮在就绪（两段音频齐备）时高亮绿色
   ================================================================ */

/* ---- 1. 场景说明：改薄荷中性，去掉粉红警告感 ---- */
#view-duallab .dl-scene-desc {
    background: rgba(13, 148, 136, 0.07);
    border-color: rgba(13, 148, 136, 0.16);
    color: #0d9488;
}
/* 禁用提示：柔和浅灰蓝，不再是琥珀警告 */
#view-duallab .dl-analyze-hint {
    background: rgba(148, 163, 184, 0.1);
    border-color: rgba(148, 163, 184, 0.25);
    color: #64748B;
    border-radius: 12px;
}
[data-theme="dark"] #view-duallab .dl-analyze-hint {
    color: #9898a5;
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.08);
}

/* ---- 2. VS 对比徽标 ---- */
#view-duallab .dl-vs-badge {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 6;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.78);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border: 1px solid rgba(244, 114, 182, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 14px;
    letter-spacing: 0.5px;
    color: #f472b6;
    box-shadow: 0 4px 14px rgba(244, 114, 182, 0.28);
    pointer-events: none;
}
[data-theme="dark"] #view-duallab .dl-vs-badge {
    background: rgba(38, 38, 46, 0.8);
    border-color: rgba(244, 114, 182, 0.45);
}
@media (max-width: 767px) {
    #view-duallab .dl-vs-badge { display: none; }
}

/* ---- 3. 分析按钮就绪时高亮绿 ---- */
#view-duallab #dl-analyze-btn:not(:disabled) {
    background: linear-gradient(135deg, #16a34a, #15803d);
    border-color: #16a34a;
    box-shadow: 0 6px 18px rgba(22, 163, 74, 0.3);
    color: #fff;
}
#view-duallab #dl-analyze-btn:not(:disabled):hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 22px rgba(22, 163, 74, 0.4);
}

/* ================================================================
   音游工坊（#view-rhythm）—— 2x2 卡片强化 + 成就进度 + 问答小游戏
   ================================================================ */

/* ---- 游戏卡片：色块背景 + 图标放大 + 开始按钮突出 ---- */
#rhythm-home .glass-card.card-hover {
    background: linear-gradient(135deg, rgba(255,255,255,0.6), rgba(255,255,255,0.3));
    border-radius: 16px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
[data-theme="dark"] #rhythm-home .glass-card.card-hover {
    background: linear-gradient(135deg, rgba(38,38,46,0.55), rgba(38,38,46,0.35));
}
#rhythm-home .glass-card.card-hover:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 28px rgba(13, 148, 136, 0.14);
}
/* 游戏图标容器：放大 + 色块渐变 */
#rhythm-home .card-hover .w-14.h-14 {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.35);
}
#rhythm-home .card-hover .w-14.h-14 span {
    font-size: 26px;
}
/* 开始按钮：更大、更醒目 */
#rhythm-home .ctrl-btn-primary {
    font-size: 13px;
    padding: 8px 18px;
    border-radius: 12px;
}
#rhythm-home .glass-card.card-hover:hover .ctrl-btn-primary {
    transform: scale(1.05);
    box-shadow: 0 6px 16px rgba(13, 148, 136, 0.28);
}
#rhythm-home .ctrl-btn-primary {
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

/* ---- 成就进度条 ---- */
#view-rhythm .rhythm-ach-progress {
    height: 6px;
    border-radius: 6px;
    background: var(--bg-tertiary);
    overflow: hidden;
}
#view-rhythm .rhythm-ach-progress-fill {
    height: 100%;
    border-radius: 6px;
    background: linear-gradient(90deg, #2DD4BF, #0d9488);
    transition: width 0.45s ease;
}
/* 未解锁成就：描边轮廓，保留色彩 */
#view-rhythm [id^="ach-"] {
    border: 1px solid transparent;
    transition: opacity 0.3s ease, background 0.3s ease, transform 0.2s ease;
}
#view-rhythm [id^="ach-"]:hover {
    transform: translateY(-2px);
}

/* ---- 音乐数学问答：选项样式 ---- */
#view-rhythm .quiz-option {
    text-align: left;
    padding: 12px 14px;
    border-radius: 12px;
    border: 1px solid var(--border-default);
    background: rgba(255, 255, 255, 0.55);
    color: var(--text-primary);
    font-size: 14px;
    cursor: pointer;
    transition: border-color 0.2s ease, background 0.2s ease, transform 0.15s ease;
}
[data-theme="dark"] #view-rhythm .quiz-option {
    background: rgba(38, 38, 46, 0.5);
    border-color: rgba(255, 255, 255, 0.1);
}
#view-rhythm .quiz-option:not(.quiz-option-locked):hover {
    border-color: var(--accent-primary);
    background: var(--accent-primary-soft);
    transform: translateY(-1px);
}
#view-rhythm .quiz-option-locked {
    cursor: default;
    opacity: 0.85;
}
#view-rhythm .quiz-option-correct {
    border-color: #16a34a;
    background: rgba(22, 163, 74, 0.1);
}
#view-rhythm .quiz-option-wrong {
    border-color: #ef4444;
    background: rgba(239, 68, 68, 0.08);
}

/* ================================================================
   浮岛成长（#view-island）—— 统一薄荷绿配色 + 浮岛 C 位 + 侧边栏化
   ================================================================ */

/* ---- 1. 配色统一：粉紫 → 薄荷绿（呼应首页与声景花园） ---- */
#view-island .module-heading-purple {
    color: #0d9488;
    text-shadow: 0 0 24px rgba(13, 148, 136, 0.3);
}
#view-island .island-heading-purple {
    color: #0d9488;
}
#view-island .module-tag[style*="A78BFA"] {
    --tag-color: #0d9488;
    color: #0d9488;
    border-color: rgba(13, 148, 136, 0.35);
    background: rgba(13, 148, 136, 0.08);
}

/* ---- 2. 浮岛 C 位：画布玻璃容器 + 薄荷氛围 ---- */
#view-island .glass-card {
    border-radius: 16px;
}
#view-island .relative.canvas-h-380 {
    border-radius: 14px;
    /* 2026-11-13：改为与 SVG 场景同调的米白 → 淡薄荷，消除深色画框感 */
    background: linear-gradient(180deg, #FBFAF5 0%, #F4F1E6 55%, #E9F2EB 100%);
    overflow: hidden;
}
/* 浮岛卡片：毛玻璃化，突出"浮动"感 */
#view-island .lg\:col-span-3.glass-card {
    background: linear-gradient(160deg,
        rgba(255, 255, 255, 0.55),
        rgba(13, 148, 136, 0.06));
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 16px 40px rgba(13, 148, 136, 0.1);
}
[data-theme="dark"] #view-island .lg\:col-span-3.glass-card {
    background: linear-gradient(160deg, rgba(38, 38, 46, 0.55), rgba(13, 148, 136, 0.08));
    border-color: rgba(255, 255, 255, 0.08);
}

/* ---- 3. 右侧边栏紧凑化：今日小目标单列 ---- */
#view-island #daily-goals-section .glass-card {
    background: rgba(255, 255, 255, 0.45);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}
[data-theme="dark"] #view-island #daily-goals-section .glass-card {
    background: rgba(38, 38, 46, 0.45);
}
#view-island #daily-goals-list .goal-item,
#view-island #daily-goals-list > div {
    border-radius: 12px;
    border: 1px solid var(--border-subtle);
    background: rgba(255, 255, 255, 0.5);
    padding: 10px 12px;
}
[data-theme="dark"] #view-island #daily-goals-list .goal-item,
[data-theme="dark"] #view-island #daily-goals-list > div {
    background: rgba(38, 38, 46, 0.5);
}

/* ================================================================
   浮岛成长（#view-island）—— 全维度 UI/UX 升级
   ----------------------------------------------------------------
   美观度：对比度提升 · 色彩层次 · 浮岛羽化+音符粒子
   呈现度：数据卡 icon 化 · 近期练习区 · 成就筛选 · 心情打卡
   交互度：CTA 强化 · 新用户引导气泡 · 目标勾选热区
   ================================================================ */

/* ---- 数据卡：放大数字 + 音乐图标 + 品牌色 ---- */
#view-island .stat-box {
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(13, 148, 136, 0.14);
    border-radius: 14px;
    padding: 14px 10px 12px;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
#view-island .stat-box:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(13, 148, 136, 0.12);
}
[data-theme="dark"] #view-island .stat-box {
    background: rgba(38, 38, 46, 0.55);
    border-color: rgba(255, 255, 255, 0.08);
}
#view-island .stat-icon {
    font-size: 18px;
    line-height: 1;
    margin-bottom: 6px;
    filter: drop-shadow(0 2px 6px rgba(13, 148, 136, 0.18));
}
#view-island .stat-value {
    font-size: 26px;
    font-weight: 800;
    color: #0d9488;
    font-family: var(--font-display);
    line-height: 1.1;
    letter-spacing: -0.5px;
}
#view-island .stat-label {
    font-size: 12px;
    color: #556070;
    font-weight: 600;
    margin-top: 4px;
    letter-spacing: 0.5px;
}
[data-theme="dark"] #view-island .stat-value { color: #2DD4BF; }
[data-theme="dark"] #view-island .stat-label { color: #4b5563; }

/* ---- 浮岛画布：羽化过渡 + 音符粒子 ---- */
#view-island .island-canvas-wrap {
    -webkit-mask-image: radial-gradient(120% 100% at 50% 50%, #000 78%, transparent 100%);
    mask-image: radial-gradient(120% 100% at 50% 50%, #000 78%, transparent 100%);
}
#view-island .island-note-particles {
    position: absolute; inset: 0;
    pointer-events: none;
    overflow: hidden;
    border-radius: 14px;
}
.island-note-particles::before,
.island-note-particles::after {
    content: '♪';
    position: absolute;
    font-size: 16px;
    color: rgba(13, 148, 136, 0.35);
    animation: island-note-float 7s ease-in-out infinite;
}
.island-note-particles::before { left: 12%; bottom: 18%; animation-delay: 0s; }
.island-note-particles::after  { content: '♫'; left: 78%; bottom: 30%; font-size: 20px; color: rgba(167, 139, 250, 0.30); animation-delay: 3.2s; }
@keyframes island-note-float {
    0%   { transform: translateY(0) rotate(0deg); opacity: 0; }
    18%  { opacity: 1; }
    100% { transform: translateY(-160px) rotate(24deg); opacity: 0; }
}
#view-island .island-level-badge-wrap { }

/* ---- 浮岛等级徽标（2026-11-13：改为可点击按钮） ---- */
#view-island #island-level-badge {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #2F6B55;
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(62, 158, 119, 0.30);
    padding: 4px 10px;
    border-radius: 999px;
    font-weight: 600;
    letter-spacing: 0.02em;
    cursor: pointer;
    overflow: hidden;
    transition: background .16s ease, border-color .16s ease, color .16s ease;
}
#view-island #island-level-badge:hover {
    background: #fff;
    border-color: rgba(62, 158, 119, 0.55);
    color: #1F5743;
}
#view-island #island-level-badge:focus-visible {
    outline: 2px solid rgba(62, 158, 119, 0.45);
    outline-offset: 2px;
}
#view-island #island-level-badge::before {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    height: 2px;
    width: var(--lvl-p, 0%);
    background: linear-gradient(90deg, #6FC29B, #2F8F6A);
    opacity: 0.9;
}
[data-theme="dark"] #view-island #island-level-badge {
    color: #A7D9C2;
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(111, 194, 155, 0.32);
}
[data-theme="dark"] #view-island #island-level-badge:hover {
    background: rgba(255, 255, 255, 0.10);
    color: #C6E8D8;
}

/* ---- 情绪分布：彩色圆点 + 深色标签 + 彩色轨道 ---- */
#view-island .dist-label {
    font-size: 12px;
    color: #334155;
    font-weight: 700;
    width: 52px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}
[data-theme="dark"] #view-island .dist-label { color: #334155; }
#view-island .dist-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.04);
}
#view-island .dist-bar {
    flex: 1;
    height: 10px;
    background: rgba(148, 163, 184, 0.16);
    border-radius: 5px;
    overflow: hidden;
}
#view-island .dist-bar-fill {
    border-radius: 5px;
    background: var(--d-color);
    opacity: 0.9;
    transition: width 0.6s ease;
}
#view-island .dist-count {
    font-size: 12px;
    font-weight: 700;
    color: #475569;
    font-family: var(--font-mono);
    width: 22px;
    text-align: right;
    flex-shrink: 0;
}
[data-theme="dark"] #view-island .dist-count { color: #4b5563; }

/* ---- 三段式学习旅程：当前状态高亮 ---- */
#view-island .journey-stages {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px 0 2px;
}
#view-island .journey-stage {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    color: #556070;
}
#view-island .journey-stage .stage-dot {
    width: 14px; height: 14px;
    border-radius: 50%;
    background: transparent;
    border: 1.5px solid #C8D4CB;
    transition: background 0.3s ease, border-color 0.3s ease;
}
#view-island .journey-stage.active {
    color: #2F6B55;
    font-weight: 700;
}
#view-island .journey-stage.active .stage-dot {
    background: #3E9E77;
    border-color: #3E9E77;
    box-shadow: 0 0 0 3px rgba(62, 158, 119, 0.10);
}
#view-island .journey-stage.done {
    color: #4E8C71;
}
#view-island .journey-stage.done .stage-dot {
    background: #A9D8C2;
    border-color: #A9D8C2;
}
#view-island .journey-line {
    width: 36px;
    height: 1px;
    background: #DCE3DC;
    border-radius: 1px;
    margin: 0 8px;
}
#view-island .journey-line.done {
    background: #A9D8C2;
}
[data-theme="dark"] #view-island .journey-line { background: #334155; }
[data-theme="dark"] #view-island .journey-stage .stage-dot { background: #334155; border-color: #475569; }

/* ---- CTA 按钮强化 ---- */
#view-island .island-cta-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: linear-gradient(135deg, #3E9E77, #2F8F6A);
    color: #F6FBF8;
    font-weight: 700;
    letter-spacing: 1px;
    padding: 12px 16px;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(47, 143, 106, 0.16);
    transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}
#view-island .island-cta-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(47, 143, 106, 0.20);
}
#view-island .island-cta-btn:active {
    transform: translateY(0) scale(0.98);
}
#view-island .island-cta-icon {
    font-size: 12px;
    line-height: 1;
    filter: drop-shadow(0 1px 2px rgba(255,255,255,0.5));
}

/* ---- 新用户引导气泡 ---- */
#view-island .island-onboarding-tip {
    display: none;
    margin-top: 10px;
    padding: 8px 12px;
    border-radius: 10px;
    background: #FBFDF9;
    border: 1px dashed rgba(62, 158, 119, 0.35);
    color: #47674F;
    font-size: 12px;
    line-height: 1.6;
    animation: island-tip-pulse 2.2s ease-in-out infinite;
}
#view-island .island-onboarding-tip.show { display: block; }
#view-island .io-arrow { font-weight: 700; color: #3E9E77; }
@keyframes island-tip-pulse {
    0%, 100% { opacity: 0.85; }
    50% { opacity: 1; box-shadow: 0 0 0 4px rgba(13, 148, 136, 0.06); }
}

/* ---- 近期练习（填充左侧留白） ---- */
#view-island .island-recent-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 14px;
    font-size: 12px;
    color: #4b5563;
    background: rgba(148, 163, 184, 0.08);
    border: 1px dashed rgba(148, 163, 184, 0.25);
    border-radius: 12px;
}
.island-recent-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(13, 148, 136, 0.12);
    transition: transform 0.2s ease;
}
.island-recent-item:hover { transform: translateY(-1px); }
[data-theme="dark"] .island-recent-item {
    background: rgba(38, 38, 46, 0.55);
    border-color: rgba(255, 255, 255, 0.08);
}
.island-recent-icon { font-size: 20px; flex-shrink: 0; }
.island-recent-info { flex: 1; min-width: 0; }
.island-recent-name {
    font-size: 12.5px;
    font-weight: 700;
    color: #334155;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.island-recent-time { font-size: 11px; color: #4b5563; margin-top: 1px; }
.island-recent-emoji { font-size: 16px; flex-shrink: 0; }
[data-theme="dark"] .island-recent-name { color: #1e293b; }

/* ---- 成就筛选 Tab ---- */
#view-island .ach-filter-btn {
    padding: 5px 14px;
    font-size: 12px;
    font-weight: 700;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.25);
    background: rgba(255, 255, 255, 0.6);
    color: #556070;
    cursor: pointer;
    transition: all 0.2s ease;
}
#view-island .ach-filter-btn:hover {
    border-color: rgba(13, 148, 136, 0.4);
    color: #0d9488;
}
#view-island .ach-filter-btn.active {
    background: linear-gradient(135deg, #0d9488, #10b981);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 4px 12px rgba(13, 148, 136, 0.25);
}
[data-theme="dark"] #view-island .ach-filter-btn {
    background: rgba(38, 38, 46, 0.55);
    color: #4b5563;
}

/* ---- 今日心情打卡 ---- */
#view-island .mood-checkin-card {
    border: 1px solid rgba(13, 148, 136, 0.14);
}
#view-island .mood-btn {
    width: 40px; height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(148, 163, 184, 0.3);
    background: rgba(255, 255, 255, 0.75);
    font-size: 18px;
    cursor: pointer;
    transition: all 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
#view-island .mood-btn:hover {
    transform: translateY(-3px) scale(1.1);
    border-color: rgba(13, 148, 136, 0.45);
    box-shadow: 0 6px 14px rgba(13, 148, 136, 0.15);
}
#view-island .mood-btn.selected {
    border-color: #0d9488;
    background: rgba(13, 148, 136, 0.12);
    box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.18);
    transform: scale(1.08);
}
[data-theme="dark"] #view-island .mood-btn {
    background: rgba(38, 38, 46, 0.55);
}

/* ================================================================
   浮岛成长 —— JS 注入样式的浅色适配覆盖层
   （island-achievements.js / floating-island.js / experience-island.js
    原注入样式为深色主题风，此处以 #view-island 高特异性前缀覆盖）
   ================================================================ */

/* ---- 成就 Tab ---- */
#view-island .island-tab-btn { color: #556070; border-radius: 8px; }
#view-island .island-tab-btn:hover { color: #334155; }
#view-island .island-tab-btn.active {
    color: #0d9488;
    border-bottom-color: #0d9488;
}

/* ---- 成就卡片 ---- */
#view-island .achievement-card {
    padding: 14px 12px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid rgba(148, 163, 184, 0.22);
    box-shadow: 0 2px 10px rgba(13, 148, 136, 0.05);
}
#view-island .achievement-card:hover {
    border-color: rgba(13, 148, 136, 0.4);
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 8px 20px rgba(13, 148, 136, 0.14);
    transform: translateY(-3px);
}
#view-island .achievement-card.locked {
    opacity: 0.58;
    filter: grayscale(0.55);
    background: rgba(241, 245, 249, 0.55);
}
#view-island .achievement-card.locked:hover {
    opacity: 0.8;
    filter: grayscale(0.25);
}
#view-island .achievement-card.unlocked {
    border-color: rgba(16, 185, 129, 0.45);
    background: linear-gradient(160deg, rgba(255, 255, 255, 0.92), rgba(16, 185, 129, 0.10));
    box-shadow: 0 4px 16px rgba(16, 185, 129, 0.12);
}
#view-island .achievement-card.unlocked::before {
    background: linear-gradient(90deg, #0d9488, #2DD4BF);
    height: 3px;
}
#view-island .ach-card-icon { margin-bottom: 10px; }
#view-island .ach-card-name {
    color: #334155;
    font-size: 13.5px;
}
#view-island .achievement-card.unlocked .ach-card-name { color: #047857; }
#view-island .ach-card-desc { color: #556070; }
#view-island .ach-card-date { color: #4b5563; }
#view-island .ach-card-progress-bar { background: rgba(148, 163, 184, 0.22); }
#view-island .ach-card-progress-fill { background: linear-gradient(90deg, #0d9488, #2DD4BF); }
#view-island .ach-card-progress-text { color: #556070; }
[data-theme="dark"] #view-island .achievement-card {
    background: rgba(38, 38, 46, 0.55);
    border-color: rgba(255, 255, 255, 0.1);
}
[data-theme="dark"] #view-island .ach-card-name { color: #1e293b; }
[data-theme="dark"] #view-island .ach-card-desc { color: #4b5563; }

/* ---- 模块统计条 / 7天趋势 / 最近记录 ---- */
#view-island .module-stat-name { color: #475569; }
[data-theme="dark"] #view-island .module-stat-name { color: #334155; }
#view-island .module-stat-bar-wrap { background: rgba(148, 163, 184, 0.18); }
#view-island .module-stat-value { color: #556070; }
#view-island .weekly-trend-container {
    background: rgba(255, 255, 255, 0.6);
    border-color: rgba(148, 163, 184, 0.2);
}
#view-island .trend-bar { opacity: 0.85; }
#view-island .trend-bar.zero { background: #cbd5e1; opacity: 0.5; }
#view-island .trend-bar-label { color: #556070; }
#view-island .trend-bar-value { color: #4b5563; }
#view-island .recent-practice-item {
    background: rgba(255, 255, 255, 0.7);
    border-color: rgba(148, 163, 184, 0.2);
    border-radius: 12px;
    padding: 10px 12px;
}
[data-theme="dark"] #view-island .recent-practice-item {
    background: rgba(38, 38, 46, 0.55);
    border-color: rgba(255, 255, 255, 0.08);
}
#view-island .rp-module { color: #334155; }
#view-island .rp-detail { color: #556070; }
#view-island .rp-time { color: #4b5563; }
#view-island .rp-empty { color: #4b5563; }
[data-theme="dark"] #view-island .rp-module { color: #1e293b; }

/* ---- 今日小目标（floating-island.js 注入样式浅色覆盖） ---- */
#view-island .island-resource-badge {
    background: rgba(13, 148, 136, 0.08);
    border-color: rgba(13, 148, 136, 0.22);
    color: #0f766e;
}
[data-theme="dark"] #view-island .island-resource-badge {
    background: rgba(45, 212, 191, 0.1);
    border-color: rgba(45, 212, 191, 0.25);
    color: #5eead4;
}
#view-island .daily-goal-item {
    background: rgba(255, 255, 255, 0.78);
    border-color: rgba(148, 163, 184, 0.22);
    border-radius: 13px;
    cursor: pointer;
}
#view-island .daily-goal-item:hover {
    border-color: rgba(13, 148, 136, 0.4);
    box-shadow: 0 4px 12px rgba(13, 148, 136, 0.1);
}
#view-island .daily-goal-item.completed {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.35);
}
[data-theme="dark"] #view-island .daily-goal-item {
    background: rgba(38, 38, 46, 0.55);
    border-color: rgba(255, 255, 255, 0.1);
}
#view-island .daily-goal-item .dg-title { color: #334155; font-weight: 700; }
#view-island .daily-goal-item.completed .dg-title { color: #047857; }
[data-theme="dark"] #view-island .daily-goal-item .dg-title { color: #1e293b; }
[data-theme="dark"] #view-island .daily-goal-item.completed .dg-title { color: #6ee7b7; }
#view-island .daily-goal-item .dg-desc { color: #556070; }
#view-island .daily-goal-item .dg-reward { color: #b45309; }
#view-island .daily-goal-item .dg-check {
    width: 26px; height: 26px;
    font-size: 15px;
    background: rgba(148, 163, 184, 0.18);
    color: #4b5563;
    border-radius: 50%;
}
#view-island .daily-goal-item.completed .dg-check {
    background: #10b981;
    color: #fff;
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.15);
}
[data-theme="dark"] #view-island .daily-goal-item .dg-check { background: rgba(148, 163, 184, 0.25); }

/* ---- 成长里程碑：时间轴 + 节点（experience-island.js 注入样式浅色覆盖） ---- */
#view-island .exp-milestone-timeline {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 12px;
    padding: 8px 2px;
}
@media (max-width: 1024px) {
    #view-island .exp-milestone-timeline { grid-template-columns: 1fr; }
}
#view-island .exp-milestone-node {
    position: relative;
    padding: 14px 14px 12px;
    border-radius: 14px;
    background: rgba(241, 245, 249, 0.6);
    border: 1px dashed rgba(148, 163, 184, 0.35);
    opacity: 0.75;
    transition: all 0.3s ease;
}
#view-island .exp-milestone-node.unlocked {
    background: linear-gradient(160deg, rgba(255, 255, 255, 0.9), rgba(13, 148, 136, 0.08));
    border: 1px solid rgba(13, 148, 136, 0.35);
    opacity: 1;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(13, 148, 136, 0.1);
}
#view-island .exp-milestone-node.unlocked:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 22px rgba(13, 148, 136, 0.18);
}
#view-island .exp-milestone-node .exp-milestone-dot {
    width: 12px; height: 12px;
    border-radius: 50%;
    background: #cbd5e1;
    border: 2px solid #94a3b8;
    margin-bottom: 8px;
}
#view-island .exp-milestone-node.unlocked .exp-milestone-dot {
    background: #0d9488;
    border-color: #0d9488;
    box-shadow: 0 0 0 4px rgba(13, 148, 136, 0.15), 0 0 10px rgba(13, 148, 136, 0.3);
}
#view-island .exp-milestone-title {
    font-size: 12.5px;
    font-weight: 800;
    color: #475569;
    line-height: 1.4;
    margin-bottom: 2px;
}
#view-island .exp-milestone-node.unlocked .exp-milestone-title { color: #0f766e; }
#view-island .exp-milestone-date {
    font-size: 10.5px;
    color: #4b5563;
    font-family: var(--font-mono);
    margin-bottom: 4px;
}
#view-island .exp-milestone-desc {
    font-size: 11px;
    color: #556070;
    line-height: 1.5;
}
#view-island .exp-milestone-reward {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 6px;
    font-size: 10.5px;
    font-weight: 700;
    color: #b45309;
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.25);
    padding: 2px 8px;
    border-radius: 999px;
}
#view-island .exp-timeline-card-title {
    color: #0d9488;
    font-size: 15px;
}
[data-theme="dark"] #view-island .exp-milestone-node {
    background: rgba(38, 38, 46, 0.5);
    border-color: rgba(255, 255, 255, 0.12);
}
[data-theme="dark"] #view-island .exp-milestone-node.unlocked {
    background: rgba(13, 148, 136, 0.12);
    border-color: rgba(45, 212, 191, 0.35);
}
[data-theme="dark"] #view-island .exp-milestone-title { color: #334155; }
[data-theme="dark"] #view-island .exp-milestone-desc { color: #4b5563; }

/* ================================================================
   旋律迷宫（#view-maze）—— 钢琴键按下的视觉反馈动画
   ----------------------------------------------------------------
   用户要求：点击虚拟钢琴琴键时应有 .active 按压反馈。
   按下：琥珀色高亮 + 轻微下压位移（物理按压感）。
   松开/移出：平滑还原。
   ================================================================ */
#view-maze .white-key:hover {
    background: var(--accent-amber-soft);
}
#view-maze .white-key:active,
#view-maze .white-key.active {
    background: var(--accent-amber);
    color: var(--text-inverse);
    transform: translateY(2px);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}
#view-maze .black-key:hover {
    background: var(--accent-amber-soft);
}
#view-maze .black-key:active,
#view-maze .black-key.active {
    background: var(--accent-amber);
    transform: translateY(2px);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

/* ================================================================
   唱段研习室（#view-study）—— 内置唱段卡片选中态 + 原生 audio 条
   ----------------------------------------------------------------
   点击「载入练习」后：当前卡片边框高亮变绿（选中态）。
   内置唱段播放器：载入预设 mp3 用的原生 <audio> 条（本地 file:// 不受 CORS 限制）。
   ================================================================ */
#view-study .sr-preset-card.selected {
    border-color: #0d9488;
    box-shadow: 0 0 0 2px rgba(13, 148, 136, 0.35), 0 10px 24px rgba(13, 148, 136, 0.15);
    transform: translateY(-2px);
}
[data-theme="dark"] #view-study .sr-preset-card.selected {
    border-color: #2DD4BF;
    box-shadow: 0 0 0 2px rgba(45, 212, 191, 0.35);
}
#view-study .sr-preset-audio-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.5);
    border: 1px solid rgba(13, 148, 136, 0.25);
}
[data-theme="dark"] #view-study .sr-preset-audio-wrap {
    background: rgba(38, 38, 46, 0.5);
    border-color: rgba(255, 255, 255, 0.08);
}
#view-study .sr-preset-audio-wrap.hidden { display: none; }
#view-study .sr-preset-audio-label {
    font-size: 12px;
    font-weight: 700;
    color: #0d9488;
    white-space: nowrap;
    flex-shrink: 0;
}
#view-study #sr-preset-audio {
    flex: 1;
    min-width: 0;
    height: 38px;
}

/* ================================================================
   喵琴馆 Miao Piano（模块六 · 全新创作）
   —— 猫咪 + 88 键真实钢琴 + 弹出音符（audio/piano88 采样）
   ================================================================ */

/* ---- 猫咪 ---- */
.miao-cat {
    display: inline-flex; align-items: center; gap: 12px;
    cursor: pointer; user-select: none;
    padding: 6px 20px 6px 8px;
    border-radius: 999px;
    background: rgba(13,148,136,0.06);
    border: 1px solid rgba(13,148,136,0.16);
    transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
    margin-bottom: 14px;
}
.miao-cat:hover { transform: translateY(-3px); box-shadow: 0 8px 22px rgba(13,148,136,0.18); background: rgba(13,148,136,0.10); }
.miao-cat.happy { animation: miao-bounce 0.5s ease; }
.miao-cat-face { display: inline-flex; }
.miao-cat-face svg { width: 58px; height: 52px; display: block; }
.miao-cat-label { font-size: 14px; color: #2f5f5a; font-weight: 600; }
[data-theme="dark"] .miao-cat-label { color: #a7f3d0; }
@keyframes miao-bounce {
    0%   { transform: translateY(0); }
    30%  { transform: translateY(-8px) rotate(-3deg); }
    60%  { transform: translateY(2px); }
    100% { transform: translateY(0); }
}

/* ---- 钢琴容器（横向可滚动，88 键完整展示） ---- */
.miao-piano-scroll {
    position: relative; margin-top: 6px;
    overflow-x: auto; border-radius: 12px;
    background: linear-gradient(180deg, rgba(13,148,136,0.05), rgba(13,148,136,0.02));
    border: 1px solid rgba(13,148,136,0.14);
    padding: 14px 10px 10px;
}
.miao-piano {
    position: relative; height: 210px;
    border-radius: 8px; background: #ffffff;
    box-shadow: inset 0 0 0 1px rgba(0,0,0,0.04);
}
[data-theme="dark"] .miao-piano { background: #0f172a; }

/* ---- 琴键 ---- */
.miao-key {
    position: absolute; top: 0; bottom: 0;
    cursor: pointer; user-select: none;
    box-sizing: border-box;
}
.miao-white {
    background: linear-gradient(180deg, #ffffff 0%, #f3f6f5 82%, #e6ecea 100%);
    border: 1px solid #c9d6d3; border-top: none;
    border-radius: 0 0 6px 6px;
    transition: background 0.12s ease, box-shadow 0.12s ease;
}
.miao-white.active {
    background: linear-gradient(180deg, #d9f7ef, #a9ebdc);
    box-shadow: inset 0 3px 6px rgba(13,148,136,0.25);
}
[data-theme="dark"] .miao-white { background: linear-gradient(180deg, #f8fafc, #e2e8f0); }
[data-theme="dark"] .miao-white.active { background: linear-gradient(180deg, #ccfbf1, #5eead4); }

.miao-black {
    background: linear-gradient(180deg, #12213a 0%, #1e2c47 12%, #0d1526 88%, #000000 100%);
    border: 1px solid #000; border-top: none;
    border-radius: 0 0 5px 5px; z-index: 3;
    transition: background 0.12s ease, transform 0.12s ease;
}
.miao-black.active {
    background: linear-gradient(180deg, #2b4570, #1b2f52);
    transform: translateY(2px);
}
[data-theme="dark"] .miao-black { background: linear-gradient(180deg, #334155, #0f172a); }
[data-theme="dark"] .miao-black.active { background: linear-gradient(180deg, #4c6a9c, #2b4570); }

/* ---- 弹出音符层 ---- */
.miao-notes {
    position: absolute; left: 0; right: 0; top: 0; height: 0;
    pointer-events: none; z-index: 10;
}
.miao-note-bubble {
    position: absolute; transform: translate(-50%, 0); top: -30px;
    font-size: 18px; font-weight: 700; color: #0d9488;
    text-shadow: 0 2px 8px rgba(255,255,255,0.7);
    opacity: 0; white-space: nowrap;
}
.miao-note-bubble.float { animation: miao-note-float 1.1s ease-out forwards; }
@keyframes miao-note-float {
    0%   { opacity: 0; transform: translate(-50%, 6px); }
    15%  { opacity: 1; }
    100% { opacity: 0; transform: translate(-50%, -58px); }
}
[data-theme="dark"] .miao-note-bubble { color: #5eead4; text-shadow: 0 2px 10px rgba(0,0,0,0.5); }

/* ---- 信息条 + 键盘提示 ---- */
.miao-info {
    display: flex; gap: 18px; flex-wrap: wrap;
    margin-top: 12px; font-size: 14px; color: #3f5f5a;
}
[data-theme="dark"] .miao-info { color: #a5b8b3; }
.miao-info b { color: #0d9488; font-family: var(--font-mono, monospace); font-weight: 700; }
.miao-hint { margin-top: 6px; font-size: 12.5px; color: #6b7f7a; }
[data-theme="dark"] .miao-hint { color: #8aa39c; }
.miao-hint .kbd {
    display: inline-block; padding: 0 6px; margin: 0 2px;
    border-radius: 5px; border: 1px solid rgba(13,148,136,0.3);
    background: rgba(13,148,136,0.06); font-family: var(--font-mono, monospace);
    color: #0d9488; font-size: 11.5px; line-height: 1.6;
}

/* ================================================================
   喵琴馆 · 五线谱学习区 / 音区 / 音组（图二教学版）
   ================================================================ */
.miao-inner { min-width: 860px; width: 100%; position: relative; }

/* ---- 五线谱 ---- */
.miao-staff {
    position: relative; height: 205px;
    background: linear-gradient(180deg, rgba(13,148,136,0.05), rgba(255,255,255,0.65));
    border-radius: 10px 10px 0 0;
}
[data-theme="dark"] .miao-staff { background: linear-gradient(180deg, rgba(13,148,136,0.10), rgba(15,23,42,0.4)); }
.miao-staff svg { width: 100%; height: 100%; display: block; }
.staff-line { stroke: rgba(13,148,136,0.42); stroke-width: 0.7; }
.staff-clef { fill: #1f4f4a; font-size: 34px; font-family: "Bravura","Noto Music","Segoe UI Symbol","Apple Symbols",serif; }
[data-theme="dark"] .staff-clef { fill: #a7f3d0; }
.staff-note-head { fill: #0d9488; stroke: #ffffff; stroke-width: 0.6; }
.staff-ledger { stroke: #0d9488; stroke-width: 0.7; }
[data-theme="dark"] .staff-note-head { stroke: #0f172a; }
.staff-eight { fill: #c2410c; font-size: 10px; font-weight: 700; font-family: var(--font-mono, monospace); }

/* ---- 音区标注 ---- */
.miao-ranges {
    display: flex; height: 26px; margin-top: 5px;
    border-radius: 8px; overflow: hidden;
    border: 1px solid rgba(13,148,136,0.12);
}
.miao-range {
    display: flex; align-items: center; justify-content: center;
    font-size: 12px; font-weight: 600; letter-spacing: 2px;
}
.miao-range.low  { background: rgba(100,116,139,0.14); color: #475569; }
.miao-range.mid  { background: rgba(13,148,136,0.14);  color: #0d9488; }
.miao-range.high { background: rgba(249,115,22,0.14);  color: #c2410c; }
[data-theme="dark"] .miao-range.low  { background: rgba(148,163,184,0.16); color: #334155; }
[data-theme="dark"] .miao-range.mid  { background: rgba(13,148,136,0.20);  color: #5eead4; }
[data-theme="dark"] .miao-range.high { background: rgba(249,115,22,0.20);  color: #fdba74; }

/* ---- 音组标注 ---- */
.miao-groups { position: relative; height: 20px; margin-top: 3px; }
.miao-group {
    position: absolute; top: 0; bottom: 0;
    text-align: center; font-size: 10.5px; color: #6b7f7a;
    border-left: 1px dashed rgba(13,148,136,0.25);
    padding-top: 2px; white-space: nowrap;
}
[data-theme="dark"] .miao-group { color: #8aa39c; }

/* ---- 键上音名 + 中央C ---- */
.miao-key-label {
    position: absolute; bottom: 6px; left: 0; right: 0;
    text-align: center; font-size: 10px; font-weight: 600;
    color: #2c4f4a; pointer-events: none; user-select: none;
}
/* 琴键上直接标注电脑键盘键名（当前可弹八度），提升键盘演奏上手度 */
.miao-key-kbd {
    position: absolute; top: 5px; left: 50%; transform: translateX(-50%);
    font-family: var(--font-mono, monospace);
    font-size: 9.5px; font-weight: 700; letter-spacing: 0.5px;
    color: #0d9488; background: rgba(13,148,136,0.12);
    border: 1px solid rgba(13,148,136,0.38); border-radius: 4px;
    padding: 0 4px; line-height: 1.5;
    pointer-events: none; user-select: none; z-index: 4;
    opacity: 0.92;
}
.miao-key-kbd.central { color: #ef4444; border-color: rgba(239,68,68,0.45); background: rgba(239,68,68,0.08); }
.miao-black .miao-key-kbd {
    color: #f8fafc; background: rgba(255,255,255,0.16);
    border-color: rgba(255,255,255,0.55);
}
[data-theme="dark"] .miao-key-kbd { color: #5eead4; background: rgba(94,234,212,0.14); border-color: rgba(94,234,212,0.45); }
[data-theme="dark"] .miao-black .miao-key-kbd { color: #1e293b; background: rgba(255,255,255,0.14); border-color: rgba(255,255,255,0.5); }
[data-theme="dark"] .miao-key-kbd.central { color: #f87171; border-color: rgba(248,113,113,0.5); background: rgba(248,113,113,0.12); }
.miao-white.miao-central::before {
    content: ''; position: absolute; top: 0; left: 50%;
    width: 2px; height: 15px; background: #ef4444;
    transform: translateX(-50%);
}
.miao-key-label.central { color: #ef4444; }
[data-theme="dark"] .miao-key-label { color: #355c56; }
[data-theme="dark"] .miao-key-label.central { color: #f87171; }

/* ================================================================
   喵琴馆 · 新版布局（v2）：浮动方块 + 全屏弹奏 + 五线谱实时记录
   ================================================================ */

/* ---- 顶栏：猫咪 + 全屏弹奏按钮 ---- */
.miao-topbar {
    display: flex; align-items: center; justify-content: space-between;
    gap: 12px; margin-bottom: 12px;
}
.miao-fs-btn {
    display: inline-flex; align-items: center; gap: 7px;
    padding: 9px 18px; border-radius: 999px;
    font-size: 14px; font-weight: 600; color: #ffffff;
    background: linear-gradient(135deg, #0d9488, #14b8a6);
    border: none; cursor: pointer;
    box-shadow: 0 6px 18px rgba(13,148,136,0.28);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    flex-shrink: 0;
}
.miao-fs-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(13,148,136,0.34); }
.miao-fs-btn svg { width: 17px; height: 17px; }
[data-theme="dark"] .miao-fs-btn { background: linear-gradient(135deg, #0f766e, #14b8a6); }

/* ---- [v15] 多曲目 MIDI 播放器控件 ---- */
.miao-player {
    display: flex; align-items: center; gap: 10px;
    margin-left: auto; flex-wrap: wrap; justify-content: flex-end;
}
.miao-now-playing {
    font-size: 13px; font-weight: 600; color: #0d9488;
    max-width: 300px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
    background: rgba(13,148,136,0.08); border: 1px solid rgba(13,148,136,0.18);
    border-radius: 999px; padding: 5px 12px;
}
.miao-now-playing:empty { display: none; }
.miao-track-select {
    max-width: 230px; font-size: 13px; font-weight: 500;
    color: #334155; background: rgba(255,255,255,0.85);
    border: 1px solid rgba(13,148,136,0.28); border-radius: 12px;
    padding: 8px 10px; cursor: pointer; outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.miao-track-select:hover { border-color: rgba(13,148,136,0.5); }
.miao-track-select:focus { box-shadow: 0 0 0 3px rgba(13,148,136,0.15); }
[data-theme="dark"] .miao-track-select { color: #1e293b; background: rgba(30,41,59,0.85); }
.miao-next-btn {
    display: inline-flex; align-items: center; gap: 5px;
    padding: 8px 16px; border-radius: 12px; font-size: 13px; font-weight: 600;
    color: #0d9488; background: rgba(255,255,255,0.75);
    border: 1px solid rgba(13,148,136,0.35); cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    flex-shrink: 0;
}
.miao-next-btn:hover { transform: translateY(-1px); background: rgba(13,148,136,0.12); box-shadow: 0 6px 14px rgba(13,148,136,0.18); }
[data-theme="dark"] .miao-next-btn { color: #5eead4; background: rgba(30,41,59,0.75); border-color: rgba(94,234,212,0.3); }
@media (max-width: 980px) {
    .miao-player { margin-left: 0; width: 100%; justify-content: flex-start; }
    .miao-now-playing { max-width: 100%; }
}

/* ---- 浮动方块区（xiwnn 风格：按压产生彩色方块，按住越久越长） ---- */
.miao-roll {
    position: relative; height: 110px; border-radius: 10px 10px 0 0;
    background:
        linear-gradient(180deg, rgba(13,148,136,0.03), rgba(13,148,136,0.08)),
        repeating-linear-gradient(0deg, rgba(13,148,136,0.05) 0 1px, transparent 1px 12px);
    border: 1px solid rgba(13,148,136,0.14); border-bottom: none;
    overflow: hidden;
}
[data-theme="dark"] .miao-roll { background: linear-gradient(180deg, rgba(15,23,42,0.3), rgba(13,148,136,0.10)); }
.roll-block {
    position: absolute; bottom: 0; min-height: 6px;
    border-radius: 4px 4px 0 0;
    opacity: 0.85;
    box-shadow: 0 0 10px rgba(13,148,136,0.25);
    transition: opacity 0.6s ease;
}

/* ---- 黑键：白键的 3/5 高度（覆盖旧 top/bottom 全高） ---- */
.miao-black { top: 0; bottom: auto; height: 60%; }

/* ---- 板块放宽 ---- */
.miao-inner { min-width: 1120px; }

/* ---- 五线谱实时记录区（加高、可滚动历史） ---- */
.miao-staff-wrap { margin-top: 14px; border-radius: 12px; overflow: hidden; border: 1px solid rgba(13,148,136,0.14); }
.miao-staff-head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 8px 16px; background: rgba(13,148,136,0.06);
    border-bottom: 1px solid rgba(13,148,136,0.12);
}
.miao-staff-title { font-size: 13px; font-weight: 700; color: #0d9488; letter-spacing: 1px; }
.miao-staff-clear {
    font-size: 12px; color: #6b7f7a; background: transparent;
    border: 1px solid rgba(13,148,136,0.3); border-radius: 999px;
    padding: 3px 12px; cursor: pointer; transition: all 0.2s;
}
.miao-staff-clear:hover { color: #0d9488; border-color: #0d9488; background: rgba(13,148,136,0.08); }
.miao-staff-scroll { overflow-x: auto; background: linear-gradient(180deg, rgba(255,255,255,0.85), rgba(245,250,248,0.9)); }
[data-theme="dark"] .miao-staff-scroll { background: linear-gradient(180deg, rgba(15,23,42,0.55), rgba(15,23,42,0.7)); }
.miao-staff-inner {
    position: relative; height: 380px; min-width: 100%;
}
/* 高音谱表五线：66 / 82 / 98 / 114 / 130（线5→线1） */
.miao-staff-inner::before,
.miao-staff-inner::after { content: ''; position: absolute; left: 0; right: 0; height: 1px; background: rgba(13,148,136,0.40); }
.miao-staff-inner::before { top: 66px; box-shadow: 0 16px 0 rgba(13,148,136,0.40), 0 32px 0 rgba(13,148,136,0.40), 0 48px 0 rgba(13,148,136,0.40), 0 64px 0 rgba(13,148,136,0.40); }
.miao-staff-inner::after { top: 250px; box-shadow: 0 16px 0 rgba(13,148,136,0.40), 0 32px 0 rgba(13,148,136,0.40), 0 48px 0 rgba(13,148,136,0.40), 0 64px 0 rgba(13,148,136,0.40); }
.miao-clef {
    position: absolute; left: 10px; font-size: 72px; line-height: 1;
    font-family: "Bravura","Noto Music","Segoe UI Symbol","Apple Symbols",serif;
    color: #1f4f4a; z-index: 3;
}
[data-theme="dark"] .miao-clef { color: #a7f3d0; }
.miao-clef-high { top: 66px; }
.miao-clef-low { top: 250px; }
.miao-staff-notes { position: absolute; left: 0; top: 0; right: 0; bottom: 0; pointer-events: none; }
/* 音符 */
.sn { position: absolute; }
.sn-head {
    position: absolute; width: 11px; height: 8px; border-radius: 50%;
    background: #0d9488; transform: translate(-50%, -50%);
    box-shadow: inset -2px -1px 0 rgba(0,0,0,0.18);
}
[data-theme="dark"] .sn-head { background: #5eead4; }
.sn-stem { position: absolute; width: 1.5px; background: #0d9488; }
.sn-stem.up   { bottom: 4px;  height: 30px; left: 2px; }
.sn-stem.down { top: 4px;    height: 30px; left: -6px; }
[data-theme="dark"] .sn-stem { background: #5eead4; }
.sn-ledger {
    position: absolute; left: -7px; right: -7px; height: 1.6px;
    background: #0d9488; transform: translateY(-50%);
}
[data-theme="dark"] .sn-ledger { background: #5eead4; }
.sn-eight {
    position: absolute; font-size: 12px; font-weight: 700; color: #c2410c;
    font-family: var(--font-mono, monospace); white-space: nowrap;
}
/* 高音/低音谱表提示角标 */
.miao-staff-tag-high, .miao-staff-tag-low {
    position: absolute; left: 58px; font-size: 10px; color: rgba(13,148,136,0.55); letter-spacing: 2px;
}
.miao-staff-tag-high { top: 58px; }
.miao-staff-tag-low { top: 242px; }

/* ---- 全屏弹奏模式 ---- */
/* 用 ID 特异性 + !important 压过 Tailwind CDN 动态注入的 .relative / .p-4 等工具类，
   确保全屏时 panel 真正 position: fixed 铺满视口（此前被 .relative 覆盖导致"全屏只占模块区域"） */
#miao-panel.miao-panel-fs {
    position: fixed !important;
    top: 0 !important; left: 0 !important; right: 0 !important; bottom: 0 !important;
    inset: 0 !important;
    z-index: 1200;
    width: 100vw !important; height: 100vh !important;
    margin: 0 !important; padding: 0 !important;
    border-radius: 0 !important;
    overflow-x: hidden !important; overflow-y: auto !important;      /* 只允许纵向滚动，避免五线谱记录撑出横向滚动 */
    background: linear-gradient(160deg, #f0fdf9 0%, #f5f3ff 60%, #fff7ed 100%);
}
[data-theme="dark"] #miao-panel.miao-panel-fs { background: linear-gradient(160deg, #0b1e1a 0%, #131a2e 60%, #2a1a12 100%); }
/* 全屏时锁定模块视图的入场动画（view-fade-in 的 transform 会劫持 fixed 的定位基准），
   并移除其 transform，确保 panel 相对真实视口定位 */
body:has(#miao-panel.miao-panel-fs) #view-piano {
    animation: none !important;
    transform: none !important;
}
/* 全屏时其他区块保留左右留白，钢琴键盘独占全宽 */
.miao-panel-fs .miao-topbar,
.miao-panel-fs .miao-staff-wrap,
.miao-panel-fs .miao-info,
.miao-panel-fs .miao-hint,
.miao-panel-fs .miao-fs-tip { margin-left: 16px; margin-right: 16px; }
.miao-panel-fs .miao-piano-scroll { padding: 0; border-radius: 0; border-left: none; border-right: none; }
.miao-panel-fs .miao-roll { height: 170px; }
.miao-panel-fs .miao-piano { height: 380px; }
/* 全屏 = 钢琴键盘铺满整个窗口宽（88 键按 % 均分），不再内部横向滚动 */
.miao-panel-fs .miao-piano-scroll { overflow-x: visible; }
.miao-panel-fs .miao-inner { min-width: 0; width: 100%; }
.miao-panel-fs .miao-staff-inner { height: 520px; }
.miao-panel-fs .miao-key-label { font-size: 14px; }
.miao-panel-fs .miao-key.active { transform: translateY(3px); }
.miao-panel-fs .miao-hint { font-size: 15px; }

/* 全屏提示：按 Esc 退出（仅全屏时显示，悬浮右上角） */
.miao-fs-tip {
    display: none; position: absolute; top: 14px; right: 14px; z-index: 1300;
    font-size: 12.5px; color: #0d9488; letter-spacing: 0.5px;
    background: rgba(255, 255, 255, 0.7); backdrop-filter: blur(10px);
    border: 1px solid rgba(13, 148, 136, 0.35); border-radius: 999px;
    padding: 6px 14px; box-shadow: 0 4px 14px rgba(13, 148, 136, 0.12);
}
[data-theme="dark"] .miao-fs-tip { background: rgba(15, 23, 42, 0.7); color: #5eead4; }
.miao-panel-fs .miao-fs-tip { display: block; }
.miao-fs-tip .kbd {
    display: inline-block; font-size: 11px; font-weight: 700;
    background: rgba(13, 148, 136, 0.12); border: 1px solid rgba(13, 148, 136, 0.4);
    border-radius: 5px; padding: 1px 6px; margin: 0 1px;
}

/* 键盘演奏范围高亮（当前八度对应的琴键） */
.miao-key.miao-kbd-on { box-shadow: inset 0 0 0 2px rgba(13, 148, 136, 0.55); }
.miao-black.miao-kbd-on { box-shadow: inset 0 0 0 2px rgba(94, 234, 212, 0.5); }

/* 键盘音区胶囊（信息条右侧） */
.miao-kbd-range {
    margin-left: auto; font-size: 12px; font-weight: 600;
    color: #0d9488; background: rgba(13, 148, 136, 0.10);
    border: 1px solid rgba(13, 148, 136, 0.25); border-radius: 999px;
    padding: 3px 12px; white-space: nowrap;
}

/* ---- 键盘对应琴键 按钮（顶栏） ---- */
.miao-kbd-btn {
    display: inline-flex; align-items: center; gap: 6px;
    font-size: 13px; font-weight: 600; color: #0d9488;
    background: rgba(255, 255, 255, 0.65); border: 1px solid rgba(13, 148, 136, 0.35);
    border-radius: 999px; padding: 8px 16px; cursor: pointer;
    transition: all 0.2s ease;
}
.miao-kbd-btn svg { width: 15px; height: 15px; }
.miao-kbd-btn:hover { background: rgba(13, 148, 136, 0.10); border-color: #0d9488; }
[data-theme="dark"] .miao-kbd-btn { background: rgba(15, 23, 42, 0.6); color: #5eead4; border-color: rgba(94, 234, 212, 0.4); }

/* ---- 键盘对应琴键 弹窗 ---- */
.miao-kbd-modal {
    display: none; position: fixed; inset: 0; z-index: 1500;
    background: rgba(15, 23, 42, 0.45); backdrop-filter: blur(4px);
    align-items: center; justify-content: center; padding: 24px;
}
.miao-kbd-modal.open { display: flex; }
.miao-kbd-card {
    width: min(720px, 94vw); max-height: 86vh; overflow: auto;
    background: rgba(255, 255, 255, 0.92); backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.6); border-radius: 18px;
    box-shadow: 0 24px 60px rgba(13, 148, 136, 0.18);
}
[data-theme="dark"] .miao-kbd-card { background: rgba(15, 23, 42, 0.92); border-color: rgba(94, 234, 212, 0.25); }
.miao-kbd-head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 20px; font-size: 15px; font-weight: 700; color: #0d9488;
    border-bottom: 1px solid rgba(13, 148, 136, 0.15);
}
.miao-kbd-close {
    width: 26px; height: 26px; border-radius: 50%; cursor: pointer;
    background: rgba(13, 148, 136, 0.08); color: #0d9488;
    border: 1px solid rgba(13, 148, 136, 0.25); font-size: 13px; line-height: 1;
}
.miao-kbd-close:hover { background: rgba(13, 148, 136, 0.16); }
.miao-kbd-body { padding: 16px 20px 20px; }
.miao-kbd-lead { font-size: 13px; color: #4a4a4a; line-height: 1.8; margin-bottom: 14px; }
[data-theme="dark"] .miao-kbd-lead { color: #334155; }

/* 键盘映射图 */
.miao-kbd-map { display: flex; flex-direction: column; gap: 8px; }
.miao-kbd-row { display: flex; align-items: center; gap: 8px; }
.miao-kbd-row-label {
    width: 78px; flex: none; font-size: 11px; color: #6b7f7a; letter-spacing: 0.5px;
}
.miao-kbd-row-keys { display: flex; gap: 5px; flex: 1; }
.miao-kbd-cell {
    flex: 1; min-width: 0; text-align: center;
    background: linear-gradient(180deg, #ffffff, #eef2f0);
    border: 1px solid #cfdcd9; border-radius: 8px;
    padding: 8px 2px 6px; display: flex; flex-direction: column; align-items: center; gap: 3px;
    transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.miao-kbd-cell:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(13, 148, 136, 0.18); }
.miao-kbd-cell.blk {
    background: linear-gradient(180deg, #1e2c47, #0d1526);
    border-color: #000;
}
.miao-kbd-cell.blk .miao-kbd-key { color: #1e293b; }
.miao-kbd-cell.blk .miao-kbd-nm { color: #4b5563; }
.miao-kbd-cell.central {
    border-color: #ef4444; box-shadow: inset 0 0 0 1px rgba(239, 68, 68, 0.6);
}
.miao-kbd-cell.central .miao-kbd-nm { color: #dc2626; font-weight: 800; }
.miao-kbd-key { font-size: 13px; font-weight: 700; color: #0f172a; line-height: 1; }
.miao-kbd-nm { font-size: 11px; color: #475569; line-height: 1; white-space: nowrap; }
[data-theme="dark"] .miao-kbd-key { color: #f1f5f9; }
[data-theme="dark"] .miao-kbd-nm { color: #4b5563; }

/* Shift 修饰徽标（数字行黑键） */
.miao-kbd-shift {
    font-size: 9px; font-weight: 700; color: #fff;
    background: linear-gradient(135deg, #f97316, #ef4444);
    border-radius: 4px; padding: 1px 5px; line-height: 1.3; letter-spacing: 0.5px;
}

/* 音区着色：键帽顶部颜色条（低=蓝 中=绿 高=橙） */
.miao-kbd-cell { position: relative; }
.miao-kbd-cell::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
    border-radius: 8px 8px 0 0;
}
.miao-kbd-cell.zone-low::before { background: #3b82f6; }
.miao-kbd-cell.zone-mid::before { background: #10b981; }
.miao-kbd-cell.zone-high::before { background: #f97316; }

/* 说明区音区色标签 */
.miao-kbd-lead .tag-low, .miao-kbd-lead .tag-mid, .miao-kbd-lead .tag-high {
    font-size: 11px; font-weight: 700; color: #fff;
    border-radius: 5px; padding: 1px 6px; margin: 0 1px;
}
.miao-kbd-lead .tag-low { background: #3b82f6; }
.miao-kbd-lead .tag-mid { background: #10b981; }
.miao-kbd-lead .tag-high { background: #f97316; }
.miao-kbd-note { font-size: 12.5px; color: #4a4a4a; margin: 12px 0 4px; line-height: 1.8; }
[data-theme="dark"] .miao-kbd-note { color: #334155; }
.miao-kbd-help { list-style: none; margin-top: 8px; }
.miao-kbd-help li {
    font-size: 12.5px; color: #4a4a4a; line-height: 1.9;
    padding: 6px 0 6px 18px; position: relative;
}
.miao-kbd-help li::before {
    content: ''; position: absolute; left: 4px; top: 13px;
    width: 5px; height: 5px; border-radius: 50%; background: #0d9488;
}
.miao-kbd-help b { color: #0f766e; }
[data-theme="dark"] .miao-kbd-help li, [data-theme="dark"] .miao-kbd-help b { color: #334155; }
[data-theme="dark"] .miao-kbd-help b { color: #5eead4; }
.miao-kbd-help .kbd, .miao-kbd-note .kbd {
    display: inline-block; font-size: 11px; font-weight: 700;
    background: rgba(13, 148, 136, 0.12); border: 1px solid rgba(13, 148, 136, 0.4);
    border-radius: 5px; padding: 1px 6px; margin: 0 1px; color: #0d9488;
}

/* 浮动方块生长动画（CSS 驱动，按住线性生长） */
@keyframes roll-grow {
    from { height: 0; }
    to { height: var(--roll-max, 110px); }
}

/* ====== v12 猫咪演奏《Canon in D》动画 ====== */
.miao-cat { cursor: pointer; transition: transform 0.25s ease; }
.miao-cat:hover { transform: scale(1.06); }
.miao-cat.playing { animation: miao-cat-sway 0.9s ease-in-out infinite alternate; }
.miao-cat.playing .miao-cat-face { animation: miao-cat-bob 0.45s ease-in-out infinite alternate; }
.miao-cat.playing .miao-cat-label {
    color: #d97706; font-weight: 700;
    text-shadow: 0 0 12px rgba(217, 119, 6, 0.35);
}
@keyframes miao-cat-sway {
    from { transform: rotate(-3deg) scale(1.03); }
    to { transform: rotate(3deg) scale(1.06); }
}
@keyframes miao-cat-bob {
    from { transform: translateY(0); }
    to { transform: translateY(-4px); }
}

/* ================================================================
   [v16] 图标 SVG 尺寸兜底
   项目未引入 Tailwind，HTML 中残留的 w-4/w-5/w-6 等尺寸类从未生效，
   导致无尺寸 SVG 在 flex 行父容器中被拉伸（典型：模块五信息条图标
   被撑成 558px，把主体内容挤出首屏）。此兜底为这些类补上标准尺寸。
   仅命中 class 含 w-N 的 svg；miao 等已显式定尺寸的 svg 不受影响。
   ================================================================ */
svg[class*="w-3"]  { width: 12px; height: 12px; }
svg[class*="w-4"]  { width: 16px; height: 16px; }
svg[class*="w-5"]  { width: 20px; height: 20px; }
svg[class*="w-6"]  { width: 24px; height: 24px; }
svg[class*="w-7"]  { width: 28px; height: 28px; }
svg[class*="w-8"]  { width: 32px; height: 32px; }
svg[class*="w-9"]  { width: 36px; height: 36px; }
svg[class*="w-10"] { width: 40px; height: 40px; }
svg[class*="w-12"] { width: 48px; height: 48px; }
svg[class*="w-14"] { width: 56px; height: 56px; }
svg[class*="w-16"] { width: 64px; height: 64px; }
svg[class*="w-20"] { width: 80px; height: 80px; }

/* ================================================================
   [v18] 键盘对应弹窗：单行钢琴键盘布局（白键宽黑键窄，一排展示完）
   ================================================================ */
.miao-kbd-piano {
    display: flex; align-items: stretch; gap: 2px;
    padding: 14px 10px 10px;
    background: rgba(0,0,0,0.04);
    border-radius: 12px;
    overflow-x: auto;
}
.pk-key {
    flex: 1 0 auto; min-width: 26px;
    height: 96px; border-radius: 0 0 6px 6px;
    background: #fff; border: 1px solid #cbd5e1;
    display: flex; flex-direction: column; align-items: center; justify-content: flex-end;
    padding-bottom: 6px; position: relative;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
}
.pk-key.blk {
    flex: 0.6 0 auto; min-width: 18px;
    height: 58px; background: #1e293b; color: #f1f5f9;
    border-color: #0f172a; z-index: 2;
    justify-content: flex-end; padding-bottom: 4px;
    box-shadow: 0 3px 6px rgba(0,0,0,0.25);
}
.pk-letter {
    font-family: var(--font-mono, monospace);
    font-size: 12px; font-weight: 800; line-height: 1;
    color: #0d9488; margin-bottom: 3px;
}
.pk-key.blk .pk-letter { color: #5eead4; }
.pk-nm { font-size: 9px; color: #556070; line-height: 1.1; text-align: center; }
.pk-key.blk .pk-nm { color: #4b5563; }
.pk-key.central { outline: 2px solid #ef4444; outline-offset: -2px; }
.pk-key.central .pk-letter { color: #ef4444; }
.pk-key.zone-low { border-top: 3px solid #3b82f6; }
.pk-key.zone-mid { border-top: 3px solid #10b981; }
.pk-key.zone-high { border-top: 3px solid #f59e0b; }
[data-theme="dark"] .pk-key { background: #1e293b; border-color: #334155; }
[data-theme="dark"] .pk-key.blk { background: #0f172a; }

/* ---- v18: 导航一行展示全部模块（去掉"更多"下拉后压缩间距） ---- */
.navbar-nav { gap: 0.18rem; }
.navbar-nav .navbar-link { padding: 0.4rem 0.42rem; font-size: 0.8rem; }

/* ---- v18b: 导航整体左移（紧跟 logo），间距字号恢复舒适 ---- */
.nav-desktop .navbar-nav { margin-right: auto; gap: 0.35rem; }
.nav-desktop .navbar-nav .navbar-link { padding: 0.42rem 0.6rem; font-size: 0.85rem; }

/* ================================================================
   v18: 模块一 声景花园 —— 中文字体重排 + LaTeX 风格数学公式
   ================================================================ */
#view-garden {
    font-family: var(--font-sans);
    color: #2d2d2d;
}
#view-garden .mb-8 h2 {
    font-family: "Songti SC", "Source Han Serif SC", Georgia, serif;
    font-weight: 700;
    letter-spacing: 0.04em;
}
#view-garden .mb-8 > p {
    font-size: 15px;
    line-height: 1.85;
    letter-spacing: 0.015em;
}
#view-garden .module-tag {
    font-family: var(--font-mono, ui-monospace, Menlo, monospace);
    letter-spacing: 0.12em;
}

/* LaTeX 风格公式小字（挂在数值下方） */
#view-garden .readout-formula {
    font-family: "Latin Modern Roman", "STIX Two Text", Georgia, "Times New Roman", serif;
    font-style: italic;
    font-size: 11.5px;
    color: #6b7280;
    margin-top: 5px;
    letter-spacing: 0.01em;
    line-height: 1.5;
}
#view-garden .readout-formula .op,
#view-garden .readout-formula .func {
    font-style: normal;
}

/* 读数卡片公式区升级：一行中文小字描述 + LaTeX 公式（KaTeX 渲染） */
#view-garden .readout-formula-cn {
    font-family: var(--font-sans);
    font-size: 11px;
    font-weight: 500;
    color: #8b8b98;
    margin-top: 8px;
    letter-spacing: 0.06em;
    line-height: 1.5;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
[data-theme="dark"] #view-garden .readout-formula-cn {
    color: #7d7d8a;
}
#view-garden .readout-formula {
    font-style: normal;
    font-size: 14px;
    color: #0d9488;
    margin-top: 6px;
    line-height: 1.7;
}
#view-garden .readout-formula .katex {
    font-size: 1.02em;
    vertical-align: baseline;
}
[data-theme="dark"] #view-garden .readout-formula {
    color: #2DD4BF;
}

/* 读数卡片放大：更宽内边距 + 更大数值（模块一声景花园） */
#view-garden .feature-readout {
    padding: 20px 18px;
    border-radius: 16px;
}
#view-garden .readout-label {
    font-size: 13px;
    letter-spacing: 0.14em;
}
#view-garden .readout-value {
    font-size: 1.9rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    margin: 8px 0 2px;
}
#view-garden .readout-bar {
    height: 8px;
    margin-top: 12px;
}

/* ================================================================
   频谱能量历史记录（GardenHistory）
   ================================================================ */
.garden-history-bar .ctrl-btn {
    font-size: 12.5px;
    padding: 6px 14px;
    letter-spacing: 0.04em;
}
.garden-history-count {
    font-family: var(--font-mono);
    font-size: 11px;
    color: #0d9488;
    margin-left: 2px;
}
[data-theme="dark"] .garden-history-count {
    color: #2DD4BF;
}
.garden-history-card {
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(13, 148, 136, 0.18);
    border-radius: 16px;
    padding: 14px 16px;
    box-shadow: 0 6px 24px rgba(13, 148, 136, 0.08);
}
[data-theme="dark"] .garden-history-card {
    background: rgba(38, 38, 46, 0.72);
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.25);
}
.gh-head {
    display: grid;
    grid-template-columns: 84px repeat(5, 1fr);
    gap: 8px;
    padding: 0 0 6px;
    border-bottom: 1px dashed rgba(13, 148, 136, 0.2);
    margin-bottom: 4px;
}
.gh-head-time {
    text-align: left;
}
.gh-head-label {
    font-family: var(--font-serif);
    font-size: 11px;
    letter-spacing: 0.1em;
    color: #4A4A4A;
    text-align: center;
}
[data-theme="dark"] .gh-head-label {
    color: #b3b3c0;
}
.gh-body {
    max-height: 280px;
    overflow-y: auto;
}
.gh-row {
    display: grid;
    grid-template-columns: 84px repeat(5, 1fr);
    gap: 8px;
    align-items: center;
    padding: 7px 0;
    border-bottom: 1px solid rgba(13, 148, 136, 0.08);
    animation: ghRowIn .22s ease both;
    animation-delay: calc(var(--row-idx, 0) * 30ms);
}
@keyframes ghRowIn {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: none; }
}
.gh-time {
    font-family: var(--font-mono);
    font-size: 11px;
    color: #64748B;
}
.gh-cell {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    min-width: 0;
}
.gh-val {
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 600;
    color: #1a1a1a;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}
[data-theme="dark"] .gh-val {
    color: #e6e6ee;
}
.gh-centroid .gh-val {
    font-size: 11px;
}
.gh-minibar {
    display: block;
    height: 3px;
    border-radius: 2px;
    opacity: 0.75;
}
.gh-foot {
    margin-top: 10px;
    font-size: 11px;
    color: #8b8b98;
    text-align: right;
    font-family: var(--font-sans);
    letter-spacing: 0.03em;
}
.garden-history-empty {
    background: rgba(255, 255, 255, 0.6);
    border: 1px dashed rgba(13, 148, 136, 0.25);
    border-radius: 14px;
    padding: 22px;
    text-align: center;
    color: #64748B;
    line-height: 1.9;
}
[data-theme="dark"] .garden-history-empty {
    background: rgba(38, 38, 46, 0.55);
    border-color: rgba(255, 255, 255, 0.14);
    color: #9898a5;
}

/* 数据面板数值：数字用衬线斜体更有学术感 */
#view-garden .readout-value {
    font-family: "Latin Modern Roman", Georgia, "Times New Roman", serif;
    font-style: italic;
    font-weight: 600;
}

/* 音乐翻译器 / 香农熵 / 余弦相似度面板 */
#music-translator,
#entropy-panel,
#cosine-panel {
    font-family: var(--font-sans);
    line-height: 1.75;
}
#music-translator b,
#entropy-panel b,
#cosine-panel b {
    font-family: "Latin Modern Roman", Georgia, serif;
    font-style: italic;
    font-weight: 600;
}
#entropy-panel .formula-big,
#cosine-panel .formula-big {
    font-family: "Latin Modern Roman", "STIX Two Text", Georgia, serif;
    font-style: italic;
    font-size: 13px;
    color: #9ca3af;
    letter-spacing: 0.02em;
}

/* 真实唱段卡片 */
#real-track-grid .real-track-card {
    font-family: var(--font-sans);
    line-height: 1.6;
}
#real-track-grid .real-track-card .en {
    font-family: Georgia, "Times New Roman", serif;
    font-style: italic;
}

/* ================================================================
   声景花园（#view-garden）全面排版升级
   ----------------------------------------------------------------
   目标：中文排版系统化 + 数学公式 LaTeX 化呈现。
   字体四级体系：
     一级 · 中文标题 —— Noto Serif SC（衬线，字距 0.1em）
     二级 · 中文正文 —— Noto Sans SC / PingFang SC（无衬线，行高 1.8）
     三级 · 数字单位 —— JetBrains Mono（等宽，tabular-nums 对齐）
     四级 · 数学公式 —— STIX Two Math / Times（LaTeX 风格衬线斜体）
   ================================================================ */

/* ---- 0. 模块一全局字体基调 ---- */
#view-garden,
#view-garden * {
    font-family: var(--font-sans);
}
#view-garden .font-serif-sc,
#view-garden h1,
#view-garden h2,
#view-garden h3,
#view-garden h4 {
    font-family: var(--font-serif);
    font-weight: 600;
    letter-spacing: 0.06em;
}
/* 英文/拉丁字形回退到 Playfair/Inter，保持双语层级 */
#view-garden .font-serif-sc em,
#view-garden .font-serif-sc .en,
#view-garden h2 .en,
#view-garden h3 .en {
    font-family: var(--font-serif);
    letter-spacing: 0.14em;
}

/* ---- 1. Header：标题居左、字距舒展、副题与描述层级分明 ---- */
#view-garden .mb-8 {
    padding-bottom: 6px;
}
#view-garden .mb-8 h2 {
    font-family: var(--font-serif);
    font-weight: 700;
    letter-spacing: 0.12em;
    line-height: 1.3;
    font-size: clamp(1.9rem, 3.6vw, 2.6rem);
}
#view-garden .mb-8 > p {
    font-family: var(--font-sans);
    font-size: 15px;
    line-height: 2;
    letter-spacing: 0.02em;
    color: #4A4A4A;
    max-width: 52rem;
    text-align: justify;
    text-justify: inter-ideograph;
}
#view-garden .mb-8 > p strong {
    font-family: var(--font-serif);
    font-weight: 700;
    color: #0d9488;
    letter-spacing: 0.04em;
}
[data-theme="dark"] #view-garden .mb-8 > p {
    color: #a6a6b4;
}
[data-theme="dark"] #view-garden .mb-8 > p strong {
    color: #2DD4BF;
}
/* 模块编号标签 */
#view-garden .module-tag {
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.14em;
    padding: 4px 12px;
    border-radius: 999px;
}
#view-garden .text-xs.font-mono {
    font-family: var(--font-mono);
    letter-spacing: 0.08em;
}

/* ---- 2. 控制栏：中文按钮文本舒适化 ---- */
#view-garden .ctrl-btn {
    font-family: var(--font-sans);
    letter-spacing: 0.03em;
    line-height: 1.6;
}
#view-garden .ctrl-select {
    font-family: var(--font-sans);
    letter-spacing: 0.02em;
}
#view-garden .ctrl-btn + .flex label,
#view-garden label.text-xs {
    font-family: var(--font-sans);
    letter-spacing: 0.05em;
    line-height: 1.7;
}
#view-garden #mic-status {
    font-family: var(--font-sans);
    letter-spacing: 0.04em;
}

/* ---- 3. 画布标题：中文小标题衬线化，英文注记等宽化 ---- */
#view-garden .glass-card h3,
#view-garden .glass-card .h3,
#view-garden .px-4.py-3 h3 {
    font-family: var(--font-serif);
    font-weight: 600;
    letter-spacing: 0.08em;
    line-height: 1.5;
    font-size: 14.5px;
}
#view-garden .glass-card h3 + span,
#view-garden .px-4.py-3 .text-xs,
#view-garden .glass-card > div > .text-xs {
    font-family: var(--font-sans);
    letter-spacing: 0.05em;
    line-height: 1.6;
}

/* ---- 4. 数据面板：标签中文衬线、数值等宽学术化 ---- */
#view-garden .feature-readout {
    border-radius: 14px;
}
#view-garden .readout-label {
    font-family: var(--font-serif);
    font-weight: 600;
    font-size: 12.5px;
    letter-spacing: 0.14em;
    color: #3d3d3d;
}
[data-theme="dark"] #view-garden .readout-label {
    color: #b3b3c0;
}
#view-garden .readout-value {
    font-family: "JetBrains Mono", "STIX Two Text", var(--font-mono), monospace;
    font-style: normal;
    font-weight: 600;
    font-size: 1.5rem;
    letter-spacing: 0.01em;
    font-variant-numeric: tabular-nums lining-nums;
    color: #111111;
}
[data-theme="dark"] #view-garden .readout-value {
    color: #f0f0f5;
}
#view-garden .readout-formula {
    font-family: "STIX Two Text", "Latin Modern Roman", "Times New Roman", Georgia, serif;
    font-style: italic;
    font-size: 11.5px;
    letter-spacing: 0.015em;
    color: #6b7280;
}
#view-garden .readout-formula .op,
#view-garden .readout-formula .func {
    font-style: normal;
}

/* ---- 5. 数学公式 LaTeX 化呈现 ---- */
/* 块级公式：居中 + 学术卡片 + LaTeX 衬线 + 上下留白 */
#view-garden .katex-display,
#view-garden .g-math-block .katex-display {
    margin: 14px 0;
    padding: 14px 20px;
    background: rgba(13, 148, 136, 0.05);
    border: 1px solid rgba(13, 148, 136, 0.14);
    border-radius: 12px;
    overflow-x: auto;
    overflow-y: hidden;
    text-align: center;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4);
}
[data-theme="dark"] #view-garden .katex-display,
[data-theme="dark"] #view-garden .g-math-block .katex-display {
    background: rgba(13, 148, 136, 0.08);
    border-color: rgba(45, 212, 191, 0.2);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}
/* 行内公式：与中文基线对齐、微调垂直位置 */
#view-garden .katex {
    font-family: "STIX Two Math", "KaTeX_Main", "Times New Roman", serif;
    font-size: 1.04em;
    vertical-align: -0.08em;
}
#view-garden p .katex {
    padding: 0 1px;
}
/* 公式编号：LaTeX (1)(2)… 风格，右对齐 */
#view-garden .g-formula {
    position: relative;
    margin: 12px 0;
}
#view-garden .g-formula .g-formula-num {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    font-family: "STIX Two Text", "Times New Roman", serif;
    font-size: 12px;
    color: #8b8b98;
    letter-spacing: 0.05em;
    padding-right: 2px;
}
[data-theme="dark"] #view-garden .g-formula .g-formula-num {
    color: #7d7d8a;
}
/* 数学符号说明（变量表）：LaTeX 风格 key=value */
#view-garden .g-symbols {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 6px 18px;
    margin: 10px 0 4px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.45);
    border: 1px dashed rgba(13, 148, 136, 0.22);
    border-radius: 10px;
}
[data-theme="dark"] #view-garden .g-symbols {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(45, 212, 191, 0.16);
}
#view-garden .g-symbols .sym-item {
    font-family: var(--font-sans);
    font-size: 12.5px;
    line-height: 1.8;
    color: #4A4A4A;
    letter-spacing: 0.02em;
}
[data-theme="dark"] #view-garden .g-symbols .sym-item {
    color: #b3b3c0;
}
#view-garden .g-symbols .sym-item .sym {
    font-family: "STIX Two Math", "Times New Roman", serif;
    font-style: italic;
    font-size: 13.5px;
    color: #0d9488;
    margin-right: 4px;
}
[data-theme="dark"] #view-garden .g-symbols .sym-item .sym {
    color: #2DD4BF;
}

/* ---- 6. 数学内核折叠区正文 ---- */
#view-garden details.glass-card summary {
    font-family: var(--font-serif);
    font-weight: 600;
    letter-spacing: 0.08em;
    line-height: 1.7;
    font-size: 14px;
}
#view-garden details.glass-card .px-4.pb-4 {
    font-family: var(--font-sans);
    line-height: 2;
    letter-spacing: 0.02em;
    font-size: 13px;
    text-align: justify;
    text-justify: inter-ideograph;
}
#view-garden details.glass-card .px-4.pb-4 strong {
    font-family: var(--font-serif);
    font-weight: 700;
    letter-spacing: 0.04em;
}
#view-garden details.glass-card code {
    font-family: var(--font-mono);
    font-size: 12px;
    background: rgba(13, 148, 136, 0.1);
    padding: 1px 6px;
    border-radius: 5px;
    letter-spacing: 0.01em;
}
[data-theme="dark"] #view-garden details.glass-card code {
    background: rgba(45, 212, 191, 0.12);
}

/* ---- 7. 空状态 / 提示文字 ---- */
#view-garden .canvas-idle-hint .idle-main-text {
    font-family: var(--font-serif);
    font-weight: 600;
    letter-spacing: 0.1em;
    line-height: 1.7;
}
#view-garden .canvas-idle-hint .idle-sub-text,
#view-garden .coming-soon-text,
#view-garden .text-slate-500,
#view-garden .text-slate-400 {
    font-family: var(--font-sans);
    letter-spacing: 0.03em;
    line-height: 1.8;
}
/* 预设卡片标题 */
#view-garden #soundscape-preset-grid h4,
#view-garden #soundscape-preset-grid .preset-name {
    font-family: var(--font-serif);
    font-weight: 600;
    letter-spacing: 0.06em;
}

/* ================================================================
   声景花园读数区 · 最终覆盖版（卡片放大 · 数值放大 · LaTeX 公式）
   —— 置于全部旧规则之后，确保优先级生效 ——
   ================================================================ */
#view-garden .feature-readout {
    padding: 22px 20px;
    border-radius: 18px;
}
#view-garden .readout-label {
    font-family: var(--font-serif);
    font-weight: 600;
    font-size: 13.5px;
    letter-spacing: 0.16em;
    color: #3d3d3d;
}
[data-theme="dark"] #view-garden .readout-label {
    color: #b3b3c0;
}
#view-garden .readout-value {
    font-family: "JetBrains Mono", "STIX Two Text", var(--font-mono), monospace;
    font-style: normal;
    font-weight: 700;
    font-size: 2rem;
    letter-spacing: 0.01em;
    margin: 10px 0 4px;
    font-variant-numeric: tabular-nums lining-nums;
    color: #111111;
}
[data-theme="dark"] #view-garden .readout-value {
    color: #f0f0f5;
}
#view-garden .readout-bar {
    height: 9px;
    border-radius: 5px;
    background: rgba(13, 148, 136, 0.08);
    margin-top: 14px;
}
[data-theme="dark"] #view-garden .readout-bar {
    background: rgba(255, 255, 255, 0.07);
}
#view-garden .readout-formula-cn {
    font-family: var(--font-sans);
    font-size: 11px;
    font-weight: 500;
    color: #8b8b98;
    margin-top: 9px;
    letter-spacing: 0.06em;
    line-height: 1.5;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
[data-theme="dark"] #view-garden .readout-formula-cn {
    color: #7d7d8a;
}
#view-garden .readout-formula {
    font-family: "STIX Two Math", "Latin Modern Roman", "Times New Roman", Georgia, serif;
    font-style: normal;
    font-size: 15px;
    color: #0d9488;
    margin-top: 6px;
    line-height: 1.7;
    letter-spacing: 0.01em;
}
#view-garden .readout-formula .op,
#view-garden .readout-formula .func,
#view-garden .readout-formula .katex {
    font-style: normal;
}
#view-garden .readout-formula .katex {
    font-size: 1.05em;
    vertical-align: -0.06em;
}
[data-theme="dark"] #view-garden .readout-formula {
    color: #2DD4BF;
}

/* ================================================================
   模块一 JS 注入面板 · 字体/配色双主题适配
   —— 浅色主题下文字加深为可读深色，深色主题保持原有浅色质感 ——
   ================================================================ */
.g-inject-panel {
    background: rgba(255, 255, 255, 0.62) !important;
    border: 1px solid rgba(13, 148, 136, 0.18) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 4px 18px rgba(13, 148, 136, 0.06);
}
[data-theme="dark"] .g-inject-panel {
    background: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: none;
}
/* 面板标题：深青色衬线（浅色） / 琥珀浅色（深色） */
.g-inject-panel .g-title {
    color: #0f766e !important;
    font-family: var(--font-serif);
    letter-spacing: 0.05em;
}
[data-theme="dark"] .g-inject-panel .g-title {
    color: #fcd34d !important;
    font-family: inherit;
    letter-spacing: 0.03em;
}
/* 正文：深石板灰（浅色） / 浅灰（深色） */
.g-inject-panel .g-body {
    color: #334155 !important;
}
[data-theme="dark"] .g-inject-panel .g-body {
    color: #1e293b !important;
}
/* 次要文字：中灰（浅色） / 中浅灰（深色） */
.g-inject-panel .g-sub,
.g-inject-panel .g-muted {
    color: #64748B !important;
}
[data-theme="dark"] .g-inject-panel .g-sub,
[data-theme="dark"] .g-inject-panel .g-muted {
    color: #4b5563 !important;
}
/* 强调值（余弦相似度数值等） */
.g-inject-panel .g-accent {
    color: #d97706 !important;
}
[data-theme="dark"] .g-inject-panel .g-accent {
    color: #fbbf24 !important;
}
/* 提示小字 */
.g-inject-panel .g-hint {
    color: #334155 !important;
}
[data-theme="dark"] .g-inject-panel .g-hint {
    color: #64748B !important;
}

/* 真实唱段卡片：浅色玻璃底（浅色） / 深色半透明（深色） */
.real-track-card {
    background: rgba(255, 255, 255, 0.62) !important;
    border: 1px solid rgba(13, 148, 136, 0.16) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 3px 14px rgba(13, 148, 136, 0.05);
}
[data-theme="dark"] .real-track-card {
    background: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: none;
}
.real-track-card .g-muted {
    color: #64748B !important;
}
[data-theme="dark"] .real-track-card .g-muted {
    color: #4b5563 !important;
}
.real-track-card .g-body {
    color: #334155 !important;
}
[data-theme="dark"] .real-track-card .g-body {
    color: #334155 !important;
}
.real-track-card .g-hint {
    color: #0d9488 !important;
}
[data-theme="dark"] .real-track-card .g-hint {
    color: #475569 !important;
}
.real-track-wrap .g-title {
    color: #0f766e !important;
    font-family: var(--font-serif);
    letter-spacing: 0.04em;
}
[data-theme="dark"] .real-track-wrap .g-title {
    color: #fcd34d !important;
    font-family: inherit;
    letter-spacing: 0.02em;
}
.real-track-wrap .g-sub {
    color: #64748B !important;
}
[data-theme="dark"] .real-track-wrap .g-sub {
    color: #4b5563 !important;
}

/* 范本声景预设卡片：浅色玻璃底 + 文字加深（浅色） */
#view-garden .soundscape-preset-card {
    background: rgba(255, 255, 255, 0.62) !important;
    border-color: rgba(13, 148, 136, 0.16) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 3px 14px rgba(13, 148, 136, 0.05);
}
[data-theme="dark"] #view-garden .soundscape-preset-card {
    background: rgba(255, 255, 255, 0.03) !important;
    border-color: rgba(255, 255, 255, 0.06) !important;
    box-shadow: none;
}
#view-garden .soundscape-preset-card .g-desc {
    color: #334155 !important;
}
[data-theme="dark"] #view-garden .soundscape-preset-card .g-desc {
    color: #4b5563 !important;
}
#view-garden .soundscape-preset-card .preset-play-hint {
    color: #0d9488 !important;
}
[data-theme="dark"] #view-garden .soundscape-preset-card .preset-play-hint {
    color: #64748B !important;
}

/* ================================================================
   数学内核 · FFT 频谱特征提取 —— 重构版（三卡片 + 微动画 + Tooltip）
   ================================================================ */
.math-core-panel {
    margin-top: 1rem;
    border-radius: 18px;
    border: 1px solid rgba(13, 148, 136, 0.16);
    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 6px 24px rgba(13, 148, 136, 0.07);
    overflow: hidden;
}
[data-theme="dark"] .math-core-panel {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.09);
    box-shadow: none;
}
.math-core-summary {
    list-style: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px 20px;
    user-select: none;
    -webkit-user-select: none;
}
.math-core-summary::-webkit-details-marker { display: none; }
.math-core-summary-title {
    font-family: var(--font-serif);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: #0f766e;
}
[data-theme="dark"] .math-core-summary-title { color: #fcd34d; }
.math-core-summary-tag {
    font-size: 10px;
    padding: 3px 10px;
    border-radius: 999px;
    background: rgba(13, 148, 136, 0.12);
    color: #0f766e;
    letter-spacing: 0.06em;
    white-space: nowrap;
}
[data-theme="dark"] .math-core-summary-tag {
    background: rgba(252, 211, 77, 0.14);
    color: #fcd34d;
}
.math-core-chevron {
    width: 16px; height: 16px;
    margin-left: auto;
    transition: transform 0.3s;
    color: #556070;
}
.math-core-panel[open] .math-core-chevron { transform: rotate(180deg); }
.math-core-body { padding: 4px 20px 20px; }

/* 引导提示语 */
.math-core-hint {
    font-size: 12px;
    color: #475569;
    background: linear-gradient(135deg, rgba(13, 148, 136, 0.08), rgba(167, 139, 250, 0.07));
    border: 1px dashed rgba(13, 148, 136, 0.3);
    border-radius: 12px;
    padding: 9px 14px;
    margin-bottom: 14px;
    letter-spacing: 0.02em;
}
[data-theme="dark"] .math-core-hint { color: #334155; background: rgba(255,255,255,0.04); border-color: rgba(252,211,77,0.35); }

/* 三卡片 Grid */
.math-core-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 14px;
    margin-bottom: 16px;
}
.math-core-card {
    background: #F7F9F8;
    border: 1px solid rgba(13, 148, 136, 0.12);
    border-radius: 16px;
    padding: 16px 16px 12px;
    box-shadow: 0 4px 18px rgba(15, 118, 110, 0.05);
    display: flex;
    flex-direction: column;
    transition: transform 0.25s, box-shadow 0.25s;
}
[data-theme="dark"] .math-core-card {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.09);
    box-shadow: none;
}
.math-core-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 26px rgba(15, 118, 110, 0.10);
}
.mc-card-head {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 10px;
}
.mc-badge {
    font-size: 11px; font-weight: 700;
    padding: 3px 10px; border-radius: 999px;
    letter-spacing: 0.04em;
}
.mc-badge-mint  { background: rgba(16,185,129,0.14); color: #059669; }
.mc-badge-orange{ background: rgba(245,158,11,0.15); color: #d97706; }
.mc-badge-rose  { background: rgba(244,114,182,0.14); color: #db2777; }
[data-theme="dark"] .mc-badge-mint   { background: rgba(52,211,153,0.18); color: #6ee7b7; }
[data-theme="dark"] .mc-badge-orange { background: rgba(251,191,36,0.18); color: #fcd34d; }
[data-theme="dark"] .mc-badge-rose   { background: rgba(244,114,182,0.18); color: #f9a8d4; }
.mc-en {
    font-size: 10px; letter-spacing: 0.12em;
    text-transform: uppercase; color: #4b5563;
}
[data-theme="dark"] .mc-en { color: #556070; }

/* 公式：等宽字体 + 彩色变量 */
.mc-formula {
    font-family: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;
    font-size: 17px;
    color: #1e293b;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(100, 116, 139, 0.12);
    border-radius: 12px;
    padding: 12px 14px;
    text-align: center;
    line-height: 1.9;
    margin-bottom: 10px;
    overflow-x: auto;
}
[data-theme="dark"] .mc-formula {
    background: rgba(0, 0, 0, 0.25);
    border-color: rgba(255, 255, 255, 0.08);
    color: #1e293b;
}
.mc-delta { color: #0f766e; font-weight: 700; }
[data-theme="dark"] .mc-delta { color: #2dd4bf; }
.mc-approx { color: #4b5563; font-size: 13px; margin-left: 4px; }
[data-theme="dark"] .mc-approx { color: #556070; }
.mc-formula-frac { display: flex; align-items: center; justify-content: center; gap: 8px; }
.mc-frac {
    display: inline-flex; flex-direction: column; align-items: center;
    vertical-align: middle;
}
.mc-num { border-bottom: 1.5px solid rgba(100,116,139,0.4); padding: 0 10px 3px; }
.mc-den { padding-top: 3px; }

/* 彩色变量 + Tooltip */
.math-var {
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    font-style: italic;
    cursor: help;
    position: relative;
    font-weight: 700;
    border-bottom: 1.5px dashed currentColor;
    padding-bottom: 1px;
    transition: filter 0.2s;
}
.math-var:hover { filter: brightness(1.12); }
.math-var[data-tip]::after {
    content: attr(data-tip);
    position: absolute;
    bottom: calc(100% + 9px);
    left: 50%;
    transform: translateX(-50%) scale(0.92);
    transform-origin: bottom center;
    background: #0f172a;
    color: #f1f5f9;
    font-family: -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
    font-style: normal;
    font-weight: 500;
    font-size: 11px;
    line-height: 1.5;
    padding: 6px 10px;
    border-radius: 8px;
    white-space: nowrap;
    letter-spacing: 0.02em;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s, transform 0.2s;
    z-index: 50;
    box-shadow: 0 6px 20px rgba(15, 23, 42, 0.35);
}
.math-var[data-tip]:hover::after {
    opacity: 1;
    transform: translateX(-50%) scale(1);
}
.math-var[data-tip]:hover::before {
    content: "";
    position: absolute;
    bottom: calc(100% + 3px);
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #0f172a;
    z-index: 50;
    opacity: 0;
    transition: opacity 0.2s;
}
.math-var[data-tip]:hover::before { opacity: 1; }
/* 变量主题色 */
.math-var-mint   { color: #10b981; }  /* N：薄荷绿 */
.math-var-violet { color: #8b5cf6; }  /* f_s：淡紫 */
.math-var-orange { color: #f59e0b; }  /* m_k：暖橙 */
.math-var-pink   { color: #ec4899; }  /* L_k：粉 */
.math-var-sky    { color: #0ea5e9; }  /* f_k：天蓝 */
.math-var-rose   { color: #f43f5e; }  /* C：玫红 */
.math-var-teal   { color: #14b8a6; }  /* y[n]：青 */
.math-var-cyan   { color: #06b6d4; }  /* x'：亮青 */
[data-theme="dark"] .math-var-mint   { color: #34d399; }
[data-theme="dark"] .math-var-violet { color: #a78bfa; }
[data-theme="dark"] .math-var-orange { color: #fbbf24; }
[data-theme="dark"] .math-var-pink   { color: #f472b6; }
[data-theme="dark"] .math-var-sky    { color: #38bdf8; }
[data-theme="dark"] .math-var-rose   { color: #fb7185; }
[data-theme="dark"] .math-var-teal   { color: #2dd4bf; }
[data-theme="dark"] .math-var-cyan   { color: #22d3ee; }

/* 微动画画布 */
.mc-viz {
    width: 100%;
    height: 64px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid rgba(100, 116, 139, 0.1);
    margin-bottom: 10px;
    display: block;
}
[data-theme="dark"] .mc-viz {
    background: rgba(0, 0, 0, 0.22);
    border-color: rgba(255, 255, 255, 0.06);
}
.mc-explain {
    font-size: 12px;
    color: #475569;
    line-height: 1.7;
    margin: 0 0 9px;
    flex: 1;
}
[data-theme="dark"] .mc-explain { color: #4b5563; }
.mc-conf {
    font-size: 10.5px;
    color: #556070;
    background: rgba(100, 116, 139, 0.08);
    border-radius: 8px;
    padding: 5px 9px;
    text-align: center;
    letter-spacing: 0.03em;
}
[data-theme="dark"] .mc-conf { color: #556070; background: rgba(255,255,255,0.05); }

/* 进阶公式（EMA + 归一化） */
.math-core-advanced {
    margin-bottom: 14px;
}
.mc-adv-head {
    font-size: 11px; font-weight: 700;
    letter-spacing: 0.14em; text-transform: uppercase;
    color: #4b5563;
    margin-bottom: 8px;
}
[data-theme="dark"] .mc-adv-head { color: #556070; }
.mc-adv-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 10px;
}
.mc-adv-item {
    background: rgba(255, 255, 255, 0.45);
    border: 1px solid rgba(100, 116, 139, 0.1);
    border-radius: 12px;
    padding: 10px 13px;
}
[data-theme="dark"] .mc-adv-item {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.07);
}
.mc-adv-label {
    font-size: 11px; font-weight: 700;
    color: #0f766e;
    display: block; margin-bottom: 6px;
    letter-spacing: 0.03em;
}
[data-theme="dark"] .mc-adv-label { color: #fcd34d; }
.mc-adv-formula {
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    font-size: 14px;
    color: #1e293b;
    text-align: center;
    line-height: 1.9;
}
[data-theme="dark"] .mc-adv-formula { color: #1e293b; }
.mc-adv-note {
    font-size: 11px; color: #556070;
    margin: 6px 0 0; line-height: 1.6;
}
[data-theme="dark"] .mc-adv-note { color: #4b5563; }
.mc-adv-foot {
    font-size: 10.5px; color: #4b5563;
    margin: 8px 2px 0; line-height: 1.6;
}
[data-theme="dark"] .mc-adv-foot { color: #556070; }

/* 三频段图例 */
.math-core-legend {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(100, 116, 139, 0.1);
}
[data-theme="dark"] .math-core-legend {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.07);
}
.mc-legend-title {
    font-size: 11.5px; font-weight: 700;
    color: #334155;
    margin-right: 4px;
}
.mc-legend-title em {
    font-style: normal; font-weight: 400;
    color: #4b5563; font-size: 10.5px;
}
[data-theme="dark"] .mc-legend-title { color: #1e293b; }
[data-theme="dark"] .mc-legend-title em { color: #556070; }
.mc-legend-item {
    font-size: 11px; font-weight: 600;
    padding: 4px 11px; border-radius: 999px;
    letter-spacing: 0.02em;
}
.mc-legend-low  { background: rgba(16, 185, 129, 0.13); color: #047857; }
.mc-legend-mid  { background: rgba(139, 92, 246, 0.13); color: #6d28d9; }
.mc-legend-high { background: rgba(244, 63, 94, 0.13); color: #be123c; }
[data-theme="dark"] .mc-legend-low  { background: rgba(52, 211, 153, 0.16); color: #6ee7b7; }
[data-theme="dark"] .mc-legend-mid  { background: rgba(167, 139, 250, 0.16); color: #c4b5fd; }
[data-theme="dark"] .mc-legend-high { background: rgba(251, 113, 133, 0.16); color: #fda4af; }

/* ================================================================
   数学内核 · LaTeX 公式排版放大（KaTeX 渲染 + 变量 Tooltip）
   ================================================================ */
.mc-katex {
    font-size: 1.45rem;          /* 主公式放大 */
    line-height: 2.0;
    text-align: center;
    overflow-x: auto;
    padding: 4px 0;
}
.mc-katex .katex-display { margin: 0; }
.mc-katex .katex { font-size: 1em; }
.mc-katex .math-var {
    cursor: help;
    border-bottom: 1.5px dashed currentColor;
    padding-bottom: 1px;
    transition: filter 0.2s;
}
.mc-katex .math-var:hover { filter: brightness(1.15); }
/* Tooltip（复用 .math-var[data-tip] 样式，增强为深底浮层） */
.mc-katex .math-var[data-tip]::after {
    content: attr(data-tip);
    position: absolute;
    bottom: calc(100% + 9px);
    left: 50%;
    transform: translateX(-50%) scale(0.92);
    transform-origin: bottom center;
    background: #0f172a;
    color: #f1f5f9;
    font-family: -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
    font-style: normal;
    font-weight: 500;
    font-size: 11.5px;
    line-height: 1.5;
    padding: 7px 11px;
    border-radius: 9px;
    white-space: nowrap;
    letter-spacing: 0.02em;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s, transform 0.2s;
    z-index: 60;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.4);
}
.mc-katex .math-var[data-tip]:hover::after {
    opacity: 1;
    transform: translateX(-50%) scale(1);
}
.mc-katex .math-var[data-tip]:hover::before {
    content: "";
    position: absolute;
    bottom: calc(100% + 3px);
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #0f172a;
    z-index: 60;
    opacity: 0;
    transition: opacity 0.2s;
}
.mc-katex .math-var[data-tip]:hover::before { opacity: 1; }
/* 进阶公式内联小公式 */
.mc-katex-inline { font-size: 1.15rem; line-height: 2.1; }
/* 卡片整体放大（无大小限制 → 更舒展） */
.math-core-card { padding: 20px 20px 16px; }
.mc-formula { padding: 14px 16px; margin-bottom: 12px; }
.mc-explain { font-size: 13px; line-height: 1.9; margin-bottom: 11px; }
.mc-adv-formula { padding: 4px 0; }

/* ================================================================
   KaTeX 公式全局美化（本地化渲染 · 罗马体 LaTeX 排版）
   ================================================================ */
.katex { font-size: 1.1em; }
.katex-display { margin: 0.9em auto; overflow-x: auto; overflow-y: hidden; padding: 2px 0; }
.katex-display > .katex { font-size: 1.16em; }
/* 声景花园核心公式卡：公式显著放大 */
.math-core-card .mc-katex .katex { font-size: 1.38em; }
.math-core-card .mc-katex-inline .katex { font-size: 1.25em; }
/* 旋律迷宫标准公式框与 Burnside 高亮公式：居中 */
.maze-theory-main-formula { text-align: center; }
.maze-theory-main-formula .katex-display { margin: 0.4em auto; }
.formula-highlight { text-align: center; }
.formula-highlight .katex-display { margin: 0.45em auto; }
/* 符号注解网格：内联符号略放大 */
.maze-anno-symbol .katex { font-size: 1.25em; }
/* 情绪锚点 / AI 创作工坊：块级公式居中留白 */
details .katex-display { margin: 0.8em auto; }
/* 生态交响乐数学内核卡 */
.eco-math-body .katex { font-size: 1.08em; }
/* 香农熵 / 频谱面板内联小公式 */
.sm-latex-inline .katex,
.sm-latex .katex { font-size: 1.12em; }
/* 唱段研习室 / 音准评分数学标注 */
#vw-math-note .katex,
.glass-card .katex { font-size: 1.08em; }
/* 深色 / 浅色主题自适应：KaTeX 继承文本色 */
.katex { color: inherit; }

/* ================================================================
   模块十 · 浮岛成长 — 音域成长档（Island Range Archive）
   1) 三个档案页的 tab 栏
   2) 音域档案：统计格 / 折线图 / 图例 / 里程碑 / 空状态
   3) 顶部四个统计图标改为细线 SVG（去掉 emoji 与光晕）
   ================================================================ */

/* ---------- 1. 档案 tab 栏 ---------- */
#view-island .island-tab-bar {
    border-bottom-color: rgba(31, 41, 55, 0.10);
    gap: 2px;
}
#view-island .island-tab-ico {
    color: currentColor;
    opacity: 0.85;
}

/* ---------- 2. 音域成长档 ---------- */
.ira-wrap {
    padding-top: 4px;
}

.ira-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 14px;
}
.ira-head-text { min-width: 0; flex: 1 1 320px; }
.ira-title {
    font-size: 14px;
    font-weight: 700;
    color: #1e293b;
    letter-spacing: 0.01em;
}
.ira-desc {
    font-size: 12.5px;
    line-height: 1.9;
    color: #4b5563;
    margin-top: 5px;
    max-width: 64ch;
}
.ira-head-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.ira-btn {
    font-size: 12px;
    padding: 6px 13px;
}
.ira-clear {
    background: none;
    border: none;
    padding: 0;
    font-size: 11.5px;
    color: #556070;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-color: rgba(85, 96, 112, 0.35);
    transition: color 0.2s ease;
}
.ira-clear:hover { color: #B45309; text-decoration-color: rgba(180, 83, 9, 0.45); }

/* 统计四格 */
.ira-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 14px;
}
.ira-stat {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
    padding: 11px 13px 10px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(13, 148, 136, 0.14);
}
.ira-stat-label {
    font-size: 11px;
    color: #556070;
    letter-spacing: 0.02em;
}
.ira-stat-value {
    font-size: 17px;
    font-weight: 700;
    line-height: 1.3;
    color: #1e293b;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}
.ira-stat-value i {
    font-style: normal;
    font-weight: 400;
    margin: 0 3px;
    color: #9ca3af;
}
.ira-stat-value em {
    font-style: normal;
    font-size: 11px;
    font-weight: 500;
    color: #556070;
    margin-left: 3px;
}
.ira-stat-note {
    font-size: 10.5px;
    color: #6b7280;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.ira-growth.is-up { color: #B45309; }
.ira-growth.is-down,
.ira-growth.is-flat { color: #556070; }
.ira-stable { color: #0F766E; }

/* 图表 */
.ira-chart-wrap {
    border: 1px solid rgba(13, 148, 136, 0.10);
    border-radius: 14px;
    background: rgba(250, 250, 247, 0.85);
    padding: 4px 2px 2px;
    overflow: hidden;
}
.ira-svg {
    display: block;
    width: 100%;
    height: auto;
}
.ira-grid {
    stroke: rgba(31, 41, 55, 0.055);
    stroke-width: 1;
}
.ira-grid.is-oct {
    stroke: rgba(31, 41, 55, 0.16);
}
.ira-axis-y {
    fill: #556070;
    font-size: 12px;
    text-anchor: end;
    font-variant-numeric: tabular-nums;
}
.ira-axis-x {
    fill: #6b7280;
    font-size: 11.5px;
    text-anchor: middle;
    font-variant-numeric: tabular-nums;
}
.ira-band {
    fill: rgba(180, 83, 9, 0.09);
    stroke: none;
}
.ira-stable {
    fill: rgba(15, 118, 110, 0.07);
    stroke: rgba(15, 118, 110, 0.38);
    stroke-width: 1;
    stroke-dasharray: 5 4;
}
.ira-line {
    fill: none;
    stroke-width: 2;
    stroke-linejoin: round;
}
.ira-line.is-max { stroke: #B45309; }
.ira-line.is-min { stroke: #0F766E; }
.ira-dot { stroke: rgba(255, 255, 255, 0.9); stroke-width: 1.4; }
.ira-dot.is-max { fill: #B45309; }
.ira-dot.is-min { fill: #0F766E; }

/* 图例 */
.ira-legend {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 10px;
    font-size: 11.5px;
    color: #556070;
}
.ira-lg { display: inline-flex; align-items: center; gap: 6px; }
.ira-lg-line {
    display: inline-block;
    width: 16px;
    height: 2px;
    border-radius: 1px;
}
.ira-lg-line.is-max { background: #B45309; }
.ira-lg-line.is-min { background: #0F766E; }
.ira-lg-band {
    display: inline-block;
    width: 16px;
    height: 9px;
    border-radius: 2px;
    background: rgba(180, 83, 9, 0.14);
}
.ira-lg-dash {
    display: inline-block;
    width: 16px;
    height: 9px;
    border-radius: 2px;
    border: 1px dashed rgba(15, 118, 110, 0.5);
}
.ira-lg-note {
    margin-left: auto;
    font-size: 11px;
    color: #6b7280;
    font-variant-numeric: tabular-nums;
}

/* 里程碑 */
.ira-miles {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed rgba(31, 41, 55, 0.10);
}
.ira-mile {
    padding: 5px 11px;
    border-radius: 999px;
    font-size: 11.5px;
    color: #6b7280;
    background: rgba(31, 41, 55, 0.04);
    border: 1px solid rgba(31, 41, 55, 0.08);
}
.ira-mile.is-on {
    color: #0F766E;
    background: rgba(13, 148, 136, 0.08);
    border-color: rgba(13, 148, 136, 0.26);
    font-weight: 600;
}

/* 空状态 */
.ira-empty {
    text-align: center;
    padding: 34px 20px 30px;
}
.ira-empty-icon {
    display: flex;
    justify-content: center;
    color: #0F766E;
    opacity: 0.75;
    margin-bottom: 10px;
}
.ira-empty-icon svg { display: inline-block; }
.ira-empty-title {
    font-size: 14px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 6px;
}
.ira-empty-text {
    font-size: 12.5px;
    line-height: 1.9;
    color: #4b5563;
    max-width: 46ch;
    margin: 0 auto 14px;
}
.ira-cta {
    font-size: 12.5px;
    padding: 8px 18px;
}

/* ---------- 3. 顶部统计图标（细线 SVG 替代 emoji）---------- */
#view-island .stat-icon {
    font-size: 0;
    line-height: 0;
    margin-bottom: 8px;
    filter: none;
    color: #0F766E;
}
#view-island .stat-icon svg {
    display: inline-block;
    width: 17px;
    height: 17px;
}
#view-island .stat-box:hover .stat-icon { color: #B45309; }

/* ---------- 深色主题 ---------- */
/* 档案区所在卡片：浅色主题是白玻璃，深色主题必须跟着变暗，
   否则浅色文字压在浅灰卡上不可读（成就 / 统计 / 音域三页同受此卡） */
[data-theme="dark"] #island-growth-tabs-section .glass-card {
    background: linear-gradient(160deg, rgba(38, 38, 46, 0.62), rgba(13, 148, 136, 0.07));
    border-color: rgba(255, 255, 255, 0.08);
}
[data-theme="dark"] .ira-title { color: #e2e8f0; }
[data-theme="dark"] .ira-desc { color: #9898a5; }
[data-theme="dark"] .ira-stat {
    background: rgba(38, 38, 46, 0.55);
    border-color: rgba(255, 255, 255, 0.08);
}
[data-theme="dark"] .ira-stat-label,
[data-theme="dark"] .ira-stat-value em { color: #9898a5; }
[data-theme="dark"] .ira-stat-value { color: #e2e8f0; }
[data-theme="dark"] .ira-stat-note { color: #8b8b98; }
[data-theme="dark"] .ira-growth.is-up { color: #C9921E; }
[data-theme="dark"] .ira-growth.is-down,
[data-theme="dark"] .ira-growth.is-flat { color: #9898a5; }
[data-theme="dark"] .ira-stable { color: #18B5A4; }
[data-theme="dark"] .ira-chart-wrap {
    background: rgba(28, 28, 34, 0.55);
    border-color: rgba(255, 255, 255, 0.08);
}
[data-theme="dark"] .ira-grid { stroke: rgba(255, 255, 255, 0.05); }
[data-theme="dark"] .ira-grid.is-oct { stroke: rgba(255, 255, 255, 0.14); }
[data-theme="dark"] .ira-axis-y { fill: #9898a5; }
[data-theme="dark"] .ira-axis-x { fill: #8b8b98; }
[data-theme="dark"] .ira-band { fill: rgba(201, 146, 30, 0.12); }
[data-theme="dark"] .ira-stable {
    fill: rgba(24, 181, 164, 0.08);
    stroke: rgba(24, 181, 164, 0.42);
}
[data-theme="dark"] .ira-line.is-max { stroke: #C9921E; }
[data-theme="dark"] .ira-line.is-min { stroke: #18B5A4; }
[data-theme="dark"] .ira-dot.is-max { fill: #C9921E; }
[data-theme="dark"] .ira-dot.is-min { fill: #18B5A4; }
[data-theme="dark"] .ira-dot { stroke: rgba(28, 28, 34, 0.9); }
[data-theme="dark"] .ira-legend { color: #9898a5; }
[data-theme="dark"] .ira-lg-line.is-max { background: #C9921E; }
[data-theme="dark"] .ira-lg-line.is-min { background: #18B5A4; }
[data-theme="dark"] .ira-lg-band { background: rgba(201, 146, 30, 0.16); }
[data-theme="dark"] .ira-lg-dash { border-color: rgba(24, 181, 164, 0.5); }
[data-theme="dark"] .ira-lg-note { color: #8b8b98; }
[data-theme="dark"] .ira-miles { border-top-color: rgba(255, 255, 255, 0.10); }
[data-theme="dark"] .ira-mile {
    color: #8b8b98;
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.10);
}
[data-theme="dark"] .ira-mile.is-on {
    color: #18B5A4;
    background: rgba(24, 181, 164, 0.10);
    border-color: rgba(24, 181, 164, 0.30);
}
[data-theme="dark"] .ira-empty-title { color: #e2e8f0; }
[data-theme="dark"] .ira-empty-text { color: #9898a5; }
[data-theme="dark"] #view-island .stat-icon { color: #18B5A4; }

/* 窄屏：统计格两列 */
@media (max-width: 640px) {
    .ira-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .ira-head-actions { width: 100%; justify-content: flex-start; }
}

/* ==================================================================
   浮岛成长 · 2026-11-13 优化
   1) 全景画面浅色化（与米白页面同调）
   2) Lv 徽章可点击 + 等级体系弹层
   3) 今日小目标 + 自适应教练 并排一行
   ================================================================== */

/* ---- 全景容器：与 SVG 背景同色，消除左右白边的“画框感” ---- */
#view-island .island-canvas-wrap {
    background: linear-gradient(180deg, #FBFAF5 0%, #F4F1E6 55%, #E9F2EB 100%);
    border-color: rgba(62, 158, 119, 0.16);
}
#view-island .island-h3-ico {
    color: #3E9E77;
    flex: 0 0 auto;
}

/* ---- Lv 徽章按钮 ---- */
.island-level-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    border: 1px solid rgba(62, 158, 119, 0.30);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.86);
    color: #2F6B55;
    font-size: 12px;
    line-height: 1.6;
    letter-spacing: 0.02em;
    cursor: pointer;
    overflow: hidden;
    transition: background .16s ease, border-color .16s ease, color .16s ease;
}
.island-level-btn:hover {
    background: #fff;
    border-color: rgba(62, 158, 119, 0.55);
    color: #1F5743;
}
.island-level-btn:active { transform: translateY(0.5px); }
.island-level-btn:focus-visible {
    outline: 2px solid rgba(62, 158, 119, 0.45);
    outline-offset: 2px;
}
.island-level-btn .ilb-text { white-space: nowrap; }
.island-level-btn svg { opacity: 0.55; flex: 0 0 auto; }
.island-level-btn::before {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    height: 2px;
    width: var(--lvl-p, 0%);
    background: linear-gradient(90deg, #6FC29B, #2F8F6A);
    opacity: 0.9;
}

/* ---- 等级弹层 ---- */
.island-level-modal {
    position: fixed;
    inset: 0;
    z-index: 70;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
.island-level-modal[hidden] { display: none; }
.island-level-modal.show { animation: ilm-fade .18s ease forwards; }
.ilm-mask {
    position: absolute;
    inset: 0;
    background: rgba(30, 32, 36, 0.40);
}
.ilm-card {
    position: relative;
    width: min(520px, 100%);
    max-height: min(82vh, 720px);
    overflow-y: auto;
    padding: 20px 20px 16px;
    border-radius: 16px;
    background: #FFFFFF;
    border: 1px solid rgba(62, 158, 119, 0.18);
    box-shadow: 0 18px 48px rgba(40, 44, 48, 0.20);
    animation: ilm-rise .22s ease forwards;
}
@keyframes ilm-fade { from { opacity: 0 } to { opacity: 1 } }
@keyframes ilm-rise {
    from { opacity: 0; transform: translateY(10px) scale(.985) }
    to   { opacity: 1; transform: translateY(0) scale(1) }
}
.ilm-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}
.ilm-head h3 {
    margin: 0 0 4px;
    font-size: 16px;
    font-weight: 700;
    color: #1a1a1a;
    letter-spacing: 0.02em;
}
.ilm-head p {
    margin: 0;
    font-size: 12px;
    line-height: 1.7;
    color: #556070;
    max-width: 34em;
}
.ilm-close {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 8px;
    background: transparent;
    color: #6b7280;
    cursor: pointer;
    transition: background .15s ease, color .15s ease;
}
.ilm-close:hover { background: rgba(0, 0, 0, 0.045); color: #374151; }

.ilm-current {
    padding: 12px 14px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(111, 194, 155, 0.12), rgba(156, 140, 214, 0.10));
    border: 1px solid rgba(62, 158, 119, 0.14);
}
.ilm-cur-head {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 8px;
}
.ilm-cur-lv {
    font-size: 15px;
    font-weight: 700;
    color: #2F6B55;
    font-variant-numeric: tabular-nums;
}
.ilm-cur-name { font-size: 13px; color: #374151; }
.ilm-bar {
    height: 6px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.06);
    overflow: hidden;
}
.ilm-bar i {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #6FC29B, #2F8F6A);
    transition: width .3s ease;
}
.ilm-cur-meta {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-top: 7px;
    font-size: 11.5px;
    color: #556070;
    font-variant-numeric: tabular-nums;
}
.ilm-cur-meta span:last-child { text-align: right; }

.ilm-rule {
    margin: 12px 2px;
    font-size: 11.5px;
    line-height: 1.75;
    color: #4b5563;
}
.ilm-list {
    list-style: none;
    margin: 0;
    padding: 0;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
}
.ilm-row {
    display: grid;
    grid-template-columns: 52px 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 8px 2px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.045);
    font-size: 12.5px;
    color: #374151;
}
.ilm-row .ilm-lv {
    color: #6b7280;
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.02em;
}
.ilm-row .ilm-name { letter-spacing: 0.02em; }
.ilm-row .ilm-need {
    color: #556070;
    font-variant-numeric: tabular-nums;
    text-align: right;
}
.ilm-row.done { color: #6b7280; }
.ilm-row.done .ilm-name { text-decoration: line-through; text-decoration-color: rgba(0,0,0,.18); }
.ilm-row.done .ilm-need { color: #3E9E77; }
.ilm-row.now {
    background: rgba(111, 194, 155, 0.10);
    border-radius: 8px;
    padding-left: 8px;
    padding-right: 8px;
    margin: 2px 0;
    border-bottom-color: transparent;
}
.ilm-row.now .ilm-lv,
.ilm-row.now .ilm-name { color: #2F6B55; font-weight: 700; }
.ilm-row.now .ilm-need { color: #2F6B55; font-weight: 700; }
.ilm-foot {
    margin: 12px 2px 2px;
    font-size: 11.5px;
    line-height: 1.7;
    color: #6b7280;
}

/* ---- 右栏：两端对齐 + 旅程卡撑满 ---- */
/* 情绪类型分布 / 三段式旅程：宽屏两列并排，窄屏单列 */
#view-island .island-side-col {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1.25rem;
    align-items: stretch;
}
@media (min-width: 768px) {
    #view-island .island-side-col { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
#view-island .island-side-col > * { margin-top: 0 !important; }
#view-island .island-journey-card {
    height: 100%;
    display: flex;
    flex-direction: column;
}
/* 情绪类型分布：4 行在卡内纵向均匀铺开，避免下方大片留白 */
#view-island .island-side-col > .glass-card:not(.island-journey-card) {
    display: flex;
    flex-direction: column;
}
#view-island #emotion-distribution {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
    gap: 0;
}
#view-island #emotion-distribution .emotion-dist-row { margin-top: 0 !important; }
#view-island .island-journey-card .island-cta-btn { margin-top: auto; }

/* ---- 今日小目标 / 自适应教练 并排 ---- */
#view-island #island-pair-row { align-items: stretch; }
#view-island #island-pair-row > * { display: flex; }
#view-island #island-pair-row > * > .glass-card { width: 100%; }
#view-island .island-coach-slot { display: flex; }
#view-island .island-coach-card {
    width: 100%;
    display: flex;
    flex-direction: column;
}
#view-island .island-coach-card #coach-plan-body { flex: 1 1 auto; }

/* ---- 近期练习条目 ---- */
.island-recent-dur {
    margin-left: auto;
    flex: 0 0 auto;
    font-size: 11.5px;
    color: #556070;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}
.island-recent-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100%;
}

/* ---- 深色主题 ---- */
[data-theme="dark"] #view-island .island-canvas-wrap {
    background: linear-gradient(180deg, #24262c 0%, #262930 55%, #232c28 100%);
    border-color: rgba(111, 194, 155, 0.18);
}
[data-theme="dark"] .island-level-btn {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(111, 194, 155, 0.32);
    color: #A7D9C2;
}
[data-theme="dark"] .island-level-btn:hover {
    background: rgba(255, 255, 255, 0.10);
    color: #C6E8D8;
}
[data-theme="dark"] .ilm-card {
    background: #23252b;
    border-color: rgba(111, 194, 155, 0.22);
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.5);
}
[data-theme="dark"] .ilm-head h3 { color: #e2e8f0; }
[data-theme="dark"] .ilm-head p,
[data-theme="dark"] .ilm-rule,
[data-theme="dark"] .ilm-foot,
[data-theme="dark"] .ilm-cur-meta { color: #98a2b3; }
[data-theme="dark"] .ilm-close { color: #98a2b3; border-color: rgba(255,255,255,.10); }
[data-theme="dark"] .ilm-close:hover { background: rgba(255,255,255,.08); color: #e2e8f0; }
[data-theme="dark"] .ilm-current {
    background: linear-gradient(135deg, rgba(111,194,155,.14), rgba(156,140,214,.12));
    border-color: rgba(111,194,155,.22);
}
[data-theme="dark"] .ilm-cur-lv { color: #A7D9C2; }
[data-theme="dark"] .ilm-cur-name { color: #d1d5db; }
[data-theme="dark"] .ilm-bar { background: rgba(255,255,255,.10); }
[data-theme="dark"] .ilm-list { border-top-color: rgba(255,255,255,.10); }
[data-theme="dark"] .ilm-row {
    color: #d1d5db;
    border-bottom-color: rgba(255,255,255,.06);
}
[data-theme="dark"] .ilm-row .ilm-lv,
[data-theme="dark"] .ilm-row .ilm-need { color: #98a2b3; }
[data-theme="dark"] .ilm-row.done .ilm-need { color: #A7D9C2; }
[data-theme="dark"] .ilm-row.now {
    background: rgba(111,194,155,.14);
    border-bottom-color: transparent;
}
[data-theme="dark"] .ilm-row.now .ilm-lv,
[data-theme="dark"] .ilm-row.now .ilm-name,
[data-theme="dark"] .ilm-row.now .ilm-need { color: #C6E8D8; }
[data-theme="dark"] .island-recent-dur { color: #98a2b3; }

/* ---- 窄屏：并排改竖排 ---- */
@media (max-width: 1023px) {
    #view-island .island-side-col { gap: 1rem; }
}
@media (max-width: 640px) {
    .ilm-card { padding: 16px 14px 12px; border-radius: 14px; }
    .ilm-head h3 { font-size: 15px; }
    .ilm-row { grid-template-columns: 46px 1fr auto; font-size: 12px; }
}
