/* ============================================================================
   hero-orbits.css — homepage hero backdrop (Earth + parallel LEO orbits)
   ----------------------------------------------------------------------------
   口径：reports/PROPOSAL-demos-sacas-v3.md §1.4（渲染部分，kanban T8a）。
   层级（自下而上，与 §1.4 第 4 条一致）：
     parallax-starfield（base.html，z-index:-1）
       → .hero-orbits-stage 画布（本文件，z-index:1）
         → hero 文字层（index.html 既有 `relative z-10`）
   约束：
     · 只用站内既有 token（--bg-hero / --accent-blue / --accent-cyan），不新增色板；
     · 画布层 pointer-events:none —— 点击热区与 CTA 按钮都不被遮挡（点击跳转是 T8b）；
     · 遮罩（::after）保证文字对比度：浅色白雾 / 深色深蓝雾（§1.4）。
   ========================================================================== */

/* ── 画布舞台：铺满 hero，位于星场之上、文字之下 ───────────────────────────
   层级坐标（首页实际图层，实测自现有实现）：
     body 背景 → canvas-particles.js（fixed, z-index:2）→ 本舞台（z-index:3）
       → hero 文字层（z-10）。首页的星点由 canvas-particles.js 提供
       （index.html 清空了 base.html 的 parallax-starfield 槽位），parallax-starfield.js
       仍在其它页面使用——两者都不改动，本层只是插到它们与文字之间。 */
.hero-orbits-stage {
    position: absolute;
    inset: 0;
    z-index: 3;
    overflow: hidden;
    pointer-events: none; /* decorative only — never steal clicks from the hero */
}

.hero-orbits-stage > canvas {
    display: block;
    width: 100%;
    height: 100%;
}

/* ── 文字对比度遮罩（§1.4：浅色白雾 / 深色深蓝雾）────────────────────────
   球体已移到左上角，遮罩改为「中段成雾、两端通透」：hero 文字是居中排版
   （max-w-4xl），中段弱雾只压在文字列上，左上的球体与右侧轨道不被压死。 */
.hero-orbits-stage::after {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(
        90deg,
        rgba(248, 250, 252, 0) 0%,
        rgba(248, 250, 252, 0.06) 20%,
        rgba(248, 250, 252, 0.46) 34%,
        rgba(248, 250, 252, 0.50) 66%,
        rgba(248, 250, 252, 0.10) 82%,
        rgba(248, 250, 252, 0) 100%
    );
}

html.dark .hero-orbits-stage::after {
    background: linear-gradient(
        90deg,
        rgba(15, 23, 42, 0) 0%,
        rgba(15, 23, 42, 0.10) 20%,
        rgba(15, 23, 42, 0.62) 34%,
        rgba(15, 23, 42, 0.66) 66%,
        rgba(15, 23, 42, 0.18) 82%,
        rgba(15, 23, 42, 0) 100%
    );
}

/* ── 移动端 <640px（§1.4）：地球缩小移到文字下方，轨道 16 条、透明度降 30% ──
   舞台改为贴在 hero 底部；相邻的文字容器（.hero-orbits-stage + div）加下内边距，
   把文字整体抬到地球之上 —— 只靠兄弟选择器，不新增/不改动文字层标记。 */
@media (max-width: 639px) {
    .hero-orbits-stage {
        inset: auto 0 0 0;
        height: 44vh;
        min-height: 260px;
    }

    .hero-orbits-stage + div {
        padding-bottom: 40vh;
    }

    /* 移动端遮罩只压文字区，地球区域保持清晰。 */
    .hero-orbits-stage::after {
        background: linear-gradient(
            to bottom,
            rgba(248, 250, 252, 0.55) 0%,
            rgba(248, 250, 252, 0) 46%
        );
    }

    html.dark .hero-orbits-stage::after {
        background: linear-gradient(
            to bottom,
            rgba(15, 23, 42, 0.55) 0%,
            rgba(15, 23, 42, 0) 46%
        );
    }
}

/* 打印：背景装饰无意义，直接不绘制（canvas 内容不会打印，遮罩也不必占位）。 */
@media print {
    .hero-orbits-stage {
        display: none;
    }
}
