/* ============================================================
   REDLAND 离线存档纪念馆 · 全站视觉样式（阶段 1）
   工业废墟 × 像素 RPG × 暗红二次元
   ------------------------------------------------------------
   设计规范摘要（与官方视觉保持一致，禁止擅自更改）：
   - 主色 暗红 #A82020 / 铁锈灰 #333333 / 深炭黑 #121212
   - 辅助 冷钢灰 #4A4A4A / 点缀 像素亮黄 #FFD145
   - 文本 正文浅灰 #E8E8E8 / 标题白色 #FFFFFF
   - 字体 自托管官方字体（RL Body / RL Subtitle / RL Pixel）；兜底思源黑体 / Press Start 2P
   - 卡片 半透明铁锈灰 + 细暗红边框（做旧）+ 小圆角(4px)
   - 动效 克制：淡入淡出 / 图片缓淡入 / 按钮亮度变化
   ============================================================ */

/* ============================================================
   0. 自托管官方字体（REDLAND 网页开发字体建议）
   来源：压缩包 RL网页开发字体建议.zip，全部同源部署于 /fonts/。
   - RL Body     ← 三级标题（正文）.ttf      → 正文
   - RL Subtitle ← 二级标题（副标题）.ttf    → 副标题 / 次级标题
   - RL Pixel    ← 像素风10px（大标题一）.otf → 大标题像素字
   - RL Pixel 12 ← 像素风12px（大标题二）.otf → 大标题像素字（备选尺寸）
   ============================================================ */
@font-face {
    font-family: "RL Body";
    src: url("/fonts/font-body.ttf") format("truetype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "RL Body";
    src: url("/fonts/font-body.ttf") format("truetype");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "RL Subtitle";
    src: url("/fonts/font-subtitle.ttf") format("truetype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "RL Subtitle";
    src: url("/fonts/font-subtitle.ttf") format("truetype");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* ---------- 0.5 像素字体防重叠加固 ----------
   像素字体字形为固定网格设计，字宽与设计网格绑定；一旦中文落到等宽兜底字体，
   两者字宽/基线不一致，叠加 letter-spacing 就会出现文字挤压重叠。

   这里用 unicode-range 把「像素字体」严格限定在它真正擅长的范围
   （ASCII 可见字符 + 常用符号 + 几何图形），中文与全角标点一律交给后面的
   正文字体渲染。这样即使元素声明了像素字体，中文也不会再与像素字形混排，
   视觉上英文/数字保持像素风格、中文保持清晰可读，且不再重叠。

   覆盖范围 = U+0020~U+007E（ASCII）、U+00A0/00B7（空格/间隔号）、U+2000~U+206F（常用标点）、
   U+2190~U+21FF（箭头）、U+25A0~U+25FF（几何图形，含▲■●）。
   该区间内两个像素字体均实测零缺字（ASCII 95/95 全覆盖），不会出现豆腐块。 */
@font-face {
    font-family: "RL Pixel 12";
    src: url("/fonts/font-pixel-12.otf") format("opentype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0020-007E, U+00A0, U+00B7, U+2000-206F, U+2190-21FF, U+25A0-25FF;
}
@font-face {
    font-family: "RL Pixel";
    src: url("/fonts/font-pixel-10.otf") format("opentype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0020-007E, U+00A0, U+00B7, U+2000-206F, U+2190-21FF, U+25A0-25FF;
}

/* ---------- 1. 设计令牌 ---------- */
:root {
    /* 色彩系统（REDLAND 官方配色） */
    --rl-red: #A82020;
    --rl-red-hover: #C23232;
    --rl-red-dark: #6E1010;
    --rl-iron: #333333;
    --rl-charcoal: #121212;
    --rl-steel: #4A4A4A;
    --rl-yellow: #FFD145;
    --rl-text: #E8E8E8;
    --rl-white: #FFFFFF;

    /* 半透明铁锈灰卡片底（做旧金属质感） */
    --rl-card-bg: rgba(51, 51, 51, 0.82);
    --rl-card-border: rgba(168, 32, 32, 0.55);
    --rl-card-border-hover: rgba(200, 50, 50, 0.95);

    /* 小圆角（禁止大圆角） */
    --rl-radius: 4px;
    --rl-radius-sm: 2px;

    /* 字体：REDLAND 官方字体建议（自托管，见上方 @font-face）。
       正文=RL Body；副标题=RL Subtitle；大标题/REDLAND 像素字=RL Pixel / RL Pixel 12。
       思源黑体、Press Start 2P 等保留为兜底（自托管字体缺失或字形不全时回退）。

       ⚠️ 像素字体的兜底顺序很重要（曾导致中文重叠）：
       像素字体（font-pixel-10.otf）实测【仅含 22/61 个常用中文字形】，缺字（如欢迎/离线/存档）
       会逐字回退。若兜底是 monospace 等宽字体，中文按 0.6em 固定宽排布，
       而像素字体的拉丁字母也是等宽 —— 两者基线与字宽不同，叠加各处的 letter-spacing
       就会出现「文字挤压重叠」。因此中文兜底【必须】放在 monospace 之前，
       即缺字中文走正常比例的正文字体，而非等宽字体。
       另外 RL Pixel 12（13590 字形）覆盖极全，作为首选可覆盖绝大多数中文。 */
    --rl-font: "RL Body", "Source Han Sans SC", "Noto Sans SC", "思源黑体", "Microsoft YaHei", "PingFang SC", sans-serif;
    --rl-font-subtitle: "RL Subtitle", "Source Han Sans SC", "Noto Sans SC", "思源黑体", "Microsoft YaHei", "PingFang SC", sans-serif;
    --rl-font-pixel: "RL Pixel 12", "RL Pixel", "Source Han Sans SC", "Noto Sans SC", "思源黑体", "Microsoft YaHei", "PingFang SC", "Press Start 2P", monospace;

    /* 首页首屏背景图已改为「官方实景图轮播」（见 .rl-hero-slides 一节）。
       图片目录 public/images/hero/，hero-01.jpg 起按两位数字命名、升序轮播；
       新增或替换图片只需覆盖同名文件，前端无需任何改动。 */

    /* 布局 */
    --rl-header-h: 64px;
    --rl-container: 1180px;
}

/* ---------- 2. 基础 ---------- */
*,
*::before,
*::after {
    box-sizing: border-box;
}

/* 像素字体元素的通用排版保障。
   像素字体（RL Pixel / RL Pixel 12）通过上面的 unicode-range 只承担
   ASCII / 符号 / 几何图形；一旦元素内容出现中文，中文会回退到正文字体。
   此时若沿用像素字体时期设定的过小 line-height，中文行盒会偏矮、
   相邻行文字上下相碰（表现为"文字重叠"）。

   因此统一为使用像素字体的元素兜底一个宽松行高，并把 word-break 交还浏览器，
   避免中英文混排时出现挤压。逐个选择器仍可覆盖 line-height。 */
[class*="pixel"],
[class*="kicker"],
[class*="stat-num"],
[class*="city-rank"],
[class*="option-index"],
[class*="marker-num"] {
    line-height: 1.6;
}

html {
    scroll-behavior: smooth;
}

body.rl-body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-color: var(--rl-charcoal);
    color: var(--rl-text);
    font-family: var(--rl-font);
    font-size: 15px;
    line-height: 1.8;
    -webkit-font-smoothing: antialiased;
}

/* 全局做旧噪点（极低透明度，营造废墟胶片感，不干扰阅读） */
body.rl-body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 2000;
    pointer-events: none;
    opacity: 0.05;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.rl-main {
    flex: 1;
    display: flex;
    flex-direction: column;
}

h1, h2, h3, h4 {
    color: var(--rl-white);
    font-weight: 700;
    line-height: 1.4;
}

a {
    color: var(--rl-text);
}

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

::selection {
    background: var(--rl-red);
    color: var(--rl-white);
}

/* 暗色滚动条 */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: #0d0d0d;
}

::-webkit-scrollbar-thumb {
    background: #3a3a3a;
    border: 2px solid #0d0d0d;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--rl-red-dark);
}

/* ---------- 3. 通用布局 ---------- */
.rl-container {
    max-width: var(--rl-container);
    margin: 0 auto;
    width: 100%;
}

/* ---------- 4. 头部导航 ---------- */
.rl-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(18, 18, 18, 0.92);
    backdrop-filter: blur(8px);
    border-bottom: 2px solid var(--rl-red);
}

.rl-header-inner {
    max-width: var(--rl-container);
    margin: 0 auto;
    height: var(--rl-header-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 0 24px;
    /* 头部内容永不换行：避免导航项被挤到第二行、撑破 64px 头部 */
    flex-wrap: nowrap;
}

.rl-logo {
    display: flex;
    flex-direction: column;
    align-items: flex-start; /* 徽标与副标题左对齐 */
    justify-content: center;
    text-align: left;
    text-decoration: none;
    line-height: 1.1;
    flex-shrink: 0;
    min-width: 0;
}

/* REDLAND 英文 LOGO：官方原版像素字体（备用文字版） */
.rl-logo-pixel {
    font-family: var(--rl-font-pixel);
    font-size: 17px;
    color: var(--rl-yellow);
    text-shadow: 2px 2px 0 var(--rl-red-dark);
    letter-spacing: 1px;
}

.rl-logo-sub {
    font-family: var(--rl-font-subtitle);
    font-size: 11px;
    color: rgba(232, 232, 232, 0.65);
    letter-spacing: 2px;
    margin-top: 4px;
}

/* 旧 LOGO 图片（logo-on-dark.png）内部文字左侧含约 42px 透明留白，
   渲染到导航栏（高 26px→宽约 156px）时文字左缘比图片左缘右移约 12px。
   副标题加等量左缩进，使「离线存档纪念馆」与 LOGO 内文字左缘对齐。
   仅作用于左对齐的导航（.rl-logo）与后台侧栏（.rl-admin-logo），
   登录页为 text-align:center 居中布局，不受此影响。 */
.rl-logo .rl-logo-sub {
    padding-left: 12px;
}

/* 后台侧栏同款 LOGO（高 24px，偏移约 11px） */
.rl-admin-logo span {
    padding-left: 11px;
}

/* 官方方形主视觉徽标（REDLAND 2026 主视觉整图，圆角处理）
   注意：<img> 的 width/height 属性与这里保持一致，
   即使样式表命中旧缓存或加载失败也不会因原图尺寸撑破导航栏。 */
.rl-logo-badge {
    display: block;
    width: 38px;
    height: 38px;
    border-radius: 8px;
    object-fit: cover;
    border: 1px solid rgba(168, 32, 32, 0.55);
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35);
}

/* 后台登录页居中徽标（稍大） */
.rl-login-logo-badge {
    display: inline-block;
    width: 64px;
    height: 64px;
    border-radius: 12px;
    object-fit: cover;
    border: 1px solid rgba(168, 32, 32, 0.55);
    margin: 0 auto;
}

/* 后台侧栏徽标（紧凑） */
.rl-admin-logo-badge {
    display: block;
    width: 34px;
    height: 34px;
    border-radius: 7px;
    object-fit: cover;
    border: 1px solid rgba(168, 32, 32, 0.5);
}

/* ---- 旧版横向文字 LOGO（保留向后兼容，当前页面已不再引用） ---- */
.rl-logo-img {
    display: block;
    height: 26px;
    width: auto;
    max-width: 200px;
}

/* 后台登录页居中 LOGO（稍大） */
.rl-login-logo-img {
    display: inline-block;
    height: 46px;
    width: auto;
    max-width: 280px;
    margin: 0 auto;
}

/* 后台侧栏 LOGO（紧凑） */
.rl-admin-logo-img {
    display: block;
    height: 24px;
    width: auto;
    max-width: 190px;
}

.rl-nav {
    display: flex;
    align-items: center;
    gap: 2px;
    /* 桌面端保持单行（≤960px 时切换为抽屉菜单，见响应式区段） */
    flex-wrap: nowrap;
    justify-content: flex-end;
    min-width: 0;
}

.rl-nav-link {
    position: relative;
    color: var(--rl-text);
    text-decoration: none;
    padding: 8px 10px;
    font-size: 14px;
    letter-spacing: 1px;
    transition: color 0.15s ease;
    white-space: nowrap;
}

/* hover / 选中：暗红像素下划线 */
.rl-nav-link::after {
    content: "";
    position: absolute;
    left: 10px;
    right: 10px;
    bottom: 2px;
    height: 3px;
    background: var(--rl-red);
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 0.18s ease;
}

.rl-nav-link:hover {
    color: var(--rl-white);
}

.rl-nav-link:hover::after,
.rl-nav-link.is-active::after {
    transform: scaleX(1);
}

.rl-nav-link.is-active {
    color: var(--rl-white);
    font-weight: 700;
}

/* 管理入口：低调处理 */
.rl-nav-admin {
    font-size: 12px;
    color: rgba(232, 232, 232, 0.5);
    margin-left: 10px;
}

.rl-nav-admin:hover {
    color: var(--rl-yellow);
}

/* 移动端汉堡按钮 */
.rl-nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 42px;
    height: 42px;
    padding: 0 9px;
    background: transparent;
    border: 1px solid rgba(168, 32, 32, 0.5);
    border-radius: var(--rl-radius-sm);
    cursor: pointer;
}

.rl-nav-toggle span {
    display: block;
    height: 2px;
    background: var(--rl-text);
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.rl-nav-toggle.is-open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.rl-nav-toggle.is-open span:nth-child(2) {
    opacity: 0;
}

.rl-nav-toggle.is-open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* ---------- 5. 首页 Hero（全屏实景轮播背景 + Slogan） ---------- */
.rl-hero {
    position: relative;
    min-height: calc(100vh - var(--rl-header-h));
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    padding: 60px 24px;
}

/* 兜底层：像素网格 + 暗红辉光。位于实景图之下，
   图片尚未加载完成或加载失败时仍是一块有质感的底图，不会出现纯黑首屏。 */
.rl-hero-bg {
    position: absolute;
    inset: 0;
    background-color: #0b0b0b;
    background-image:
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.025) 0 1px, transparent 1px 4px),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.025) 0 1px, transparent 1px 4px),
        radial-gradient(60% 50% at 50% 35%, rgba(168, 32, 20, 0.22), transparent 70%),
        linear-gradient(180deg, #1a1414 0%, #121212 100%);
}

/* ---------- 5.1 实景轮播层（官方素材来源：REDLAND 2026 官方实景图） ----------
   图片目录：public/images/hero/，命名 hero-01.jpg 起两位数字，按文件名升序轮播。
   实现：纯 CSS 淡入淡出（animation 错峰 delay），零脚本依赖；
        每张图的周期与延迟由 Blade 按实际张数写入内联 style，增删图片无需改 CSS。
   z 轴顺序：bg（兜底） < slides（实景图） < mask（暗化） < content / dots
   动效红线：仅做透明度淡入淡出，无位移、无缩放、无闪烁。 */
.rl-hero-slides {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.rl-hero-slide {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    opacity: 0;
    animation-name: rl-hero-cycle;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
    animation-duration: 32s; /* 兜底值，实际由内联 style 按张数覆盖 */
    backface-visibility: hidden;
}

/* 首张：不等淡入，首屏立即有画面。
   循环回到自身时会被上层仍在淡出的图片遮挡，因此不会出现硬切跳闪。 */
.rl-hero-slide:first-child {
    animation-name: rl-hero-cycle-first;
}

/* 只有一张图时不做轮播，静态常亮 */
.rl-hero-slide:only-child {
    animation: none;
    opacity: 1;
}

/* 淡入淡出曲线：两段式，保证任意时刻都不漏出兜底底色
   若采用「线性交叉」（旧图淡出的同时新图淡入），两层各半透明时兜底色会透出约
   20%，肉眼可见为一次亮度塌陷（场呼吸）。故改为两段式：
     0% → 3.5%   新图 1.1s 内淡入到完全不透明（此时旧图仍全亮，被新图逐层覆盖）
     3.5% → 25%  新图全亮停留（8s，即每张的展示时长）
     25% → 28.5% 旧图维持全亮，但已被新图完全遮挡，视觉停留在此结束
     28.5% → 32% 旧图淡出到全透明，为下一轮腾位（过程被遮挡，不可见）
   于是任何时刻都至少有一层 opacity = 1，露底比例 Π(1-opacity) 恒为 0。
   百分比基准：动画周期 = 张数 × 8s，每张占 100 / 张数 %。
   当前按 4 张（周期 32s）设定：3.5% ≈ 1.1s、25% = 8s、28.5% ≈ 9.1s、32% ≈ 10.2s。
   若增删图片：周期与延迟会自动跟随张数，只需同步把 3.5% / 25% / 28.5% 三个
   百分比按「1.1s / 总周期」「1 / 张数」「1 / 张数 + 1.1s / 总周期」重算即可。 */
@keyframes rl-hero-cycle {
    0% {
        opacity: 0;
    }

    3.5% {
        opacity: 1;
    }

    25% {
        opacity: 1;
    }

    28.5% {
        opacity: 1;
    }

    32% {
        opacity: 0;
    }

    100% {
        opacity: 0;
    }
}

/* 首张：0% 即为不透明，首屏加载完成立刻有画面，不必等待淡入。
   循环回到自身时，上一层图片仍处于全亮遮挡状态，因此不会出现硬切跳闪。 */
@keyframes rl-hero-cycle-first {
    0% {
        opacity: 1;
    }

    25% {
        opacity: 1;
    }

    28.5% {
        opacity: 1;
    }

    32% {
        opacity: 0;
    }

    100% {
        opacity: 0;
    }
}

/* 暗化蒙版：中心为文字留出对比度，四周与底部压暗衔接下方区块，
   底层再叠一层暗红，把官方实景图的鲜艳色彩统一到站点调性。 */
.rl-hero-mask {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(58% 46% at 50% 50%, rgba(18, 18, 18, 0.62), rgba(18, 18, 18, 0) 74%),
        linear-gradient(180deg,
            rgba(18, 18, 18, 0.72) 0%,
            rgba(18, 18, 18, 0.36) 38%,
            rgba(18, 18, 18, 0.54) 64%,
            rgba(18, 18, 18, 0.95) 100%),
        linear-gradient(180deg, rgba(168, 32, 20, 0.18), rgba(168, 32, 20, 0.08));
}

/* 轮播指示：像素小方块，与图片同步亮起（纯 CSS，无需脚本） */
.rl-hero-dots {
    position: absolute;
    left: 50%;
    bottom: 50px;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 3;
}

.rl-hero-dot {
    width: 16px;
    height: 4px;
    background-color: rgba(232, 232, 232, 0.25);
    animation-name: rl-hero-dot;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
    animation-duration: 32s; /* 兜底值，实际与对应图片同步 */
}

/* 高亮区间与「本张图作为主角」的时段一致：0% ~ 25%（即 8s），之后熄灭。
   像素小方块采用阶跃切换而非渐变，避免出现「两个点同时半亮」的含糊状态。 */
@keyframes rl-hero-dot {
    0% {
        background-color: var(--rl-yellow);
    }

    25% {
        background-color: var(--rl-yellow);
    }

    25.1% {
        background-color: rgba(232, 232, 232, 0.25);
    }

    100% {
        background-color: rgba(232, 232, 232, 0.25);
    }
}

.rl-hero-content {
    position: relative;
    z-index: 2;
    max-width: 860px;
}

.rl-hero-kicker {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0;
    font-size: 12px;
    color: var(--rl-yellow);
    letter-spacing: 2px;
    margin: 0 0 26px;
    /* 背景为实景照片，加柔化阴影保证小字可读 */
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.9);
}

/* 仅拉丁部分用像素字体；中文与间隔符用正文字体，避免像素字体缺字导致挤在一起 */
.rl-hero-kicker-en {
    font-family: var(--rl-font-pixel);
}

.rl-hero-kicker-sep,
.rl-hero-kicker-cn {
    font-family: var(--rl-font);
}

.rl-hero-kicker-cn {
    letter-spacing: 1px;
}

/* 官方原版 Slogan */
.rl-hero-slogan {
    font-size: clamp(34px, 6vw, 64px);
    font-weight: 700;
    color: var(--rl-white);
    margin: 0;
    line-height: 1.35;
    letter-spacing: 4px;
    text-shadow:
        4px 4px 0 rgba(168, 32, 32, 0.65),
        0 4px 30px rgba(0, 0, 0, 0.85);
}

.rl-hero-intro {
    font-size: 15px;
    color: rgba(232, 232, 232, 0.88);
    margin: 0 auto;
    max-width: 640px;
    text-shadow: 0 2px 14px rgba(0, 0, 0, 0.9);
}

.rl-hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-top: 38px;
    flex-wrap: wrap;
}

.rl-hero-hint {
    position: absolute;
    bottom: 18px;
    left: 0;
    right: 0;
    padding: 0 18px; /* 窄屏下与屏幕边缘留白，长文案可正常折行 */
    text-align: center;
    font-size: 11px;
    color: rgba(232, 232, 232, 0.38);
    letter-spacing: 2px;
    margin: 0;
    z-index: 2;
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.9);
}

/* ---------- 6. 内容分区 ---------- */
.rl-section {
    padding: 72px 24px;
}

.rl-section-title {
    text-align: center;
    font-size: 26px;
    color: var(--rl-white);
    letter-spacing: 6px;
    margin: 0;
    font-weight: 700;
}

.rl-grid {
    display: grid;
    gap: 20px;
    margin-top: 40px;
}

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

/* ---------- 7. 内容卡片（半透明铁锈灰 + 细暗红边框 + 做旧） ---------- */
.rl-card {
    position: relative;
    background-color: var(--rl-card-bg);
    border: 1px solid var(--rl-card-border);
    border-radius: var(--rl-radius);
    padding: 28px 24px;
    box-shadow:
        inset 0 0 30px rgba(0, 0, 0, 0.35),
        0 6px 18px rgba(0, 0, 0, 0.25);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

/* 做旧金属：四角铆钉 */
.rl-card::before {
    content: "";
    position: absolute;
    inset: 5px;
    pointer-events: none;
    border-radius: var(--rl-radius-sm);
    background-image:
        radial-gradient(circle at 4px 4px, rgba(255, 209, 69, 0.35) 1px, transparent 1.6px),
        radial-gradient(circle at calc(100% - 4px) 4px, rgba(255, 209, 69, 0.35) 1px, transparent 1.6px),
        radial-gradient(circle at 4px calc(100% - 4px), rgba(255, 209, 69, 0.35) 1px, transparent 1.6px),
        radial-gradient(circle at calc(100% - 4px) calc(100% - 4px), rgba(255, 209, 69, 0.35) 1px, transparent 1.6px);
}

.rl-card:hover {
    border-color: var(--rl-card-border-hover);
    box-shadow:
        inset 0 0 30px rgba(0, 0, 0, 0.35),
        0 0 16px rgba(168, 32, 32, 0.35);
}

.rl-card-icon {
    width: 24px;
    height: 24px;
    margin-bottom: 14px;
    image-rendering: pixelated;
}

.rl-card-title {
    font-size: 18px;
    margin: 0 0 10px;
    letter-spacing: 2px;
}

.rl-card-text {
    margin: 0;
    font-size: 13.5px;
    color: rgba(232, 232, 232, 0.75);
    line-height: 1.9;
}

.rl-card-link {
    display: inline-block;
    margin-top: 16px;
    color: var(--rl-yellow);
    font-size: 13px;
    text-decoration: none;
    letter-spacing: 1px;
    transition: color 0.15s ease;
}

.rl-card-link:hover {
    color: var(--rl-white);
}

/* ---------- 8. 按钮（暗红底 + hover 提亮 + 像素描边 + 白字） ---------- */
.rl-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 30px;
    background: var(--rl-red);
    color: var(--rl-white);
    border: 1px solid var(--rl-red-dark);
    border-radius: var(--rl-radius);
    font-family: var(--rl-font);
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 3px;
    text-decoration: none;
    cursor: pointer;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
    transition: filter 0.15s ease, box-shadow 0.15s ease, transform 0.1s ease;
}

/* hover 轻微提亮 + 像素亮黄描边 */
.rl-btn:hover {
    filter: brightness(1.18);
    box-shadow: inset 0 0 0 2px var(--rl-yellow);
}

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

.rl-btn:focus-visible {
    outline: 2px solid var(--rl-yellow);
    outline-offset: 2px;
}

.rl-btn--ghost {
    background: transparent;
    border-color: var(--rl-red);
    color: var(--rl-text);
}

.rl-btn--ghost:hover {
    background: var(--rl-red);
    color: var(--rl-white);
    filter: none;
}

.rl-btn--sm {
    padding: 6px 14px;
    font-size: 13px;
    letter-spacing: 1px;
}

.rl-btn--block {
    width: 100%;
}

.rl-btn[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ---------- 9. 分割线（细暗红 + 像素碎片） ---------- */
.rl-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 26px auto;
    max-width: 300px;
}

.rl-divider-line {
    flex: 1;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--rl-red));
}

.rl-divider-line:last-child {
    background: linear-gradient(90deg, var(--rl-red), transparent);
}

/* 三枚像素碎片：黄-红-黄 */
.rl-divider-pixels {
    position: relative;
    width: 6px;
    height: 6px;
    background: var(--rl-yellow);
    box-shadow:
        10px 0 0 var(--rl-red),
        20px 0 0 var(--rl-yellow),
        30px 0 0 var(--rl-red);
}

/* ---------- 10. 表单元素（登录 / 后台 / 后续阶段前台表单复用） ---------- */
.rl-label {
    display: block;
    font-size: 13px;
    color: rgba(232, 232, 232, 0.8);
    margin: 18px 0 6px;
    letter-spacing: 1px;
}

.rl-input {
    width: 100%;
    padding: 10px 14px;
    background: rgba(18, 18, 18, 0.85);
    border: 1px solid var(--rl-steel);
    border-radius: var(--rl-radius);
    color: var(--rl-text);
    font-family: var(--rl-font);
    font-size: 14px;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.rl-input::placeholder {
    color: rgba(232, 232, 232, 0.3);
}

.rl-input:focus {
    outline: none;
    border-color: var(--rl-red);
    box-shadow: 0 0 0 2px rgba(168, 32, 32, 0.25);
}

.rl-checkbox {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: rgba(232, 232, 232, 0.8);
    cursor: pointer;
}

.rl-checkbox input {
    accent-color: var(--rl-red);
    width: 15px;
    height: 15px;
}

/* ---------- 11. 提示条 ---------- */
.rl-alert {
    border-radius: var(--rl-radius);
    padding: 12px 16px;
    font-size: 13px;
    margin: 0 0 16px;
    border: 1px solid;
    line-height: 1.7;
}

.rl-alert p {
    margin: 0;
}

.rl-alert--error {
    background: rgba(168, 32, 32, 0.15);
    border-color: var(--rl-red);
    color: #ff9a9a;
}

.rl-alert--success {
    background: rgba(255, 209, 69, 0.1);
    border-color: rgba(255, 209, 69, 0.5);
    color: var(--rl-yellow);
}

/* ---------- 12. 页脚（固定版权免责声明） ---------- */
.rl-footer {
    margin-top: auto;
    border-top: 1px solid rgba(168, 32, 32, 0.35);
    padding: 36px 24px 44px;
    text-align: center;
    background: rgba(10, 10, 10, 0.6);
}

.rl-footer p {
    margin: 6px 0;
    font-size: 13px;
    color: rgba(232, 232, 232, 0.65);
}

.rl-footer-disclaimer {
    font-size: 12px !important;
    color: rgba(232, 232, 232, 0.4) !important;
    max-width: 720px;
    margin: 10px auto 0 !important;
    line-height: 1.8;
}

/* ---------- 13. 动画（保持克制：淡入 / 图片缓淡入 / 按钮亮度） ---------- */
@keyframes rlFadeUp {
    from {
        opacity: 0;
        transform: translateY(12px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

/* 页面切换 / 元素入场淡入 */
.rl-fade-in {
    animation: rlFadeUp 0.7s ease both;
}

/* 滚动渐显 */
.rl-reveal {
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.rl-reveal.is-visible {
    opacity: 1;
    transform: none;
}

/* 图片缓慢淡入加载 */
img.rl-img {
    opacity: 0;
    transition: opacity 0.9s ease;
}

img.rl-img.is-loaded {
    opacity: 1;
}

/* 尊重系统"减少动态效果"偏好 */
@media (prefers-reduced-motion: reduce) {

    .rl-fade-in,
    .rl-reveal,
    img.rl-img {
        animation: none;
        opacity: 1;
        transform: none;
        transition: none;
    }

    html {
        scroll-behavior: auto;
    }
}

/* ---------- 14. 登录页 ---------- */
.rl-login-body {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background:
        radial-gradient(60% 45% at 50% 20%, rgba(168, 32, 20, 0.18), transparent 70%),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.02) 0 1px, transparent 1px 4px),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.02) 0 1px, transparent 1px 4px),
        var(--rl-charcoal);
}

.rl-login-wrap {
    width: 100%;
    max-width: 420px;
}

.rl-login-card {
    padding: 36px 32px;
}

.rl-login-logo {
    display: block;
    text-align: center;
    text-decoration: none;
    margin-bottom: 26px;
}

.rl-login-logo .rl-logo-sub {
    display: block;
    margin-top: 8px;
}

.rl-login-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 18px 0 24px;
}

.rl-login-tip {
    text-align: center;
    font-size: 12px;
    color: rgba(232, 232, 232, 0.35);
    margin: 22px 0 0;
    line-height: 1.7;
}

/* ---------- 15. 后台布局 ---------- */
.rl-admin-body {
    display: block;
}

.rl-admin {
    display: flex;
    min-height: 100vh;
}

.rl-admin-sidebar {
    width: 230px;
    flex-shrink: 0;
    background: #0c0c0c;
    border-right: 2px solid var(--rl-red);
    display: flex;
    flex-direction: column;
    position: sticky;
    top: 0;
    height: 100vh;
}

.rl-admin-logo {
    display: block;
    padding: 20px;
    font-family: var(--rl-font-pixel);
    font-size: 14px;
    color: var(--rl-yellow);
    text-decoration: none;
    border-bottom: 1px solid rgba(168, 32, 32, 0.4);
    text-shadow: 2px 2px 0 var(--rl-red-dark);
}

.rl-admin-logo span {
    display: block;
    font-family: var(--rl-font);
    font-size: 11px;
    color: rgba(232, 232, 232, 0.5);
    letter-spacing: 4px;
    margin-top: 8px;
    text-shadow: none;
}

.rl-admin-nav {
    flex: 1;
    padding: 12px 0;
    overflow-y: auto;
}

.rl-admin-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 11px 20px;
    color: rgba(232, 232, 232, 0.75);
    text-decoration: none;
    font-size: 14px;
    border-left: 3px solid transparent;
    transition: background 0.15s ease, color 0.15s ease;
}

.rl-admin-link:hover {
    background: rgba(168, 32, 32, 0.12);
    color: var(--rl-white);
}

.rl-admin-link.is-active {
    background: rgba(168, 32, 32, 0.18);
    color: var(--rl-white);
    border-left-color: var(--rl-red);
    font-weight: 700;
}

.rl-admin-link.is-disabled {
    color: rgba(232, 232, 232, 0.3);
    cursor: not-allowed;
}

.rl-admin-link em {
    font-style: normal;
    font-size: 10px;
    color: rgba(255, 209, 69, 0.45);
    border: 1px solid rgba(255, 209, 69, 0.25);
    padding: 1px 6px;
    border-radius: var(--rl-radius-sm);
}

.rl-admin-sidebar-footer {
    padding: 14px 20px;
    border-top: 1px solid rgba(168, 32, 32, 0.4);
    font-size: 12px;
}

.rl-admin-sidebar-footer a {
    color: rgba(232, 232, 232, 0.6);
    text-decoration: none;
}

.rl-admin-sidebar-footer a:hover {
    color: var(--rl-yellow);
}

.rl-admin-main {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.rl-admin-topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 0 24px;
    height: 56px;
    background: rgba(18, 18, 18, 0.95);
    border-bottom: 1px solid rgba(168, 32, 32, 0.4);
}

.rl-admin-crumb {
    font-size: 14px;
    color: rgba(232, 232, 232, 0.7);
    letter-spacing: 1px;
}

.rl-admin-user {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    color: rgba(232, 232, 232, 0.8);
}

.rl-admin-content {
    padding: 28px 24px 60px;
    max-width: 1080px;
    width: 100%;
}

.rl-admin-title {
    font-size: 22px;
    color: var(--rl-white);
    margin: 0 0 4px;
    letter-spacing: 1px;
}

.rl-admin-sub {
    font-family: var(--rl-font-subtitle);
    color: rgba(232, 232, 232, 0.55);
    font-size: 13px;
    margin: 0 0 28px;
}

/* 后台统计卡片 */
.rl-admin-stats .rl-stat {
    text-align: center;
    padding: 22px 16px;
}

.rl-stat-num {
    display: block;
    font-family: var(--rl-font-pixel);
    font-size: 24px;
    color: var(--rl-yellow);
    text-shadow: 2px 2px 0 var(--rl-red-dark);
}

.rl-stat-label {
    display: block;
    margin-top: 10px;
    font-size: 13px;
    color: rgba(232, 232, 232, 0.7);
    letter-spacing: 2px;
}

.rl-stat-note {
    display: block;
    margin-top: 8px;
    font-size: 11px;
    color: rgba(232, 232, 232, 0.4);
    line-height: 1.6;
}

.rl-admin-panel {
    margin-top: 24px;
}

.rl-admin-panel h2 {
    font-size: 16px;
    color: var(--rl-white);
    margin: 0 0 14px;
    letter-spacing: 2px;
}

.rl-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.rl-table th,
.rl-table td {
    padding: 9px 12px;
    text-align: left;
    border-bottom: 1px solid rgba(74, 74, 74, 0.5);
}

.rl-table th {
    color: rgba(232, 232, 232, 0.55);
    font-weight: 400;
    width: 160px;
}

.rl-table td {
    color: var(--rl-text);
}

.rl-code {
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(74, 74, 74, 0.6);
    border-radius: var(--rl-radius);
    padding: 12px 14px;
    font-size: 13px;
    color: var(--rl-yellow);
    overflow-x: auto;
    font-family: Consolas, Monaco, "Courier New", monospace;
    margin: 0;
}

/* 后台移动端菜单按钮 */
.rl-admin-toggle {
    display: none;
    background: transparent;
    border: 1px solid rgba(168, 32, 32, 0.5);
    color: var(--rl-text);
    border-radius: var(--rl-radius-sm);
    padding: 6px 10px;
    font-size: 13px;
    cursor: pointer;
    font-family: var(--rl-font);
}

/* ---------- 16. 占位页（区域重建中） ---------- */
.rl-coming {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 24px;
}

.rl-coming-card {
    max-width: 520px;
    text-align: center;
    padding: 48px 36px;
}

.rl-coming-card h1 {
    font-size: 26px;
    color: var(--rl-white);
    letter-spacing: 4px;
    margin: 20px 0 12px;
}

.rl-coming-card p {
    color: rgba(232, 232, 232, 0.65);
    margin: 0 0 28px;
    line-height: 2;
}

/* 像素警示块（黄黑斜纹） */
.rl-coming-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 10px;
    background: repeating-linear-gradient(45deg,
            var(--rl-yellow) 0 8px,
            #1a1a1a 8px 16px);
    border: 2px solid var(--rl-red);
    image-rendering: pixelated;
}

/* ---------- 17. 响应式 ---------- */
@media (max-width: 960px) {

    /* 前台导航折叠为抽屉 */
    .rl-nav {
        position: fixed;
        top: var(--rl-header-h);
        left: 0;
        right: 0;
        background: rgba(14, 14, 14, 0.98);
        border-bottom: 2px solid var(--rl-red);
        flex-direction: column;
        align-items: stretch;
        padding: 8px 16px 16px;
        display: none;
    }

    .rl-nav.is-open {
        display: flex;
    }

    .rl-nav-toggle {
        display: inline-flex;
    }

    .rl-nav-link {
        padding: 12px 8px;
        border-bottom: 1px solid rgba(74, 74, 74, 0.3);
    }

    .rl-nav-link::after {
        display: none;
    }

    .rl-nav-admin {
        margin-left: 0;
    }

    .rl-grid--3 {
        grid-template-columns: 1fr;
    }

    /* 后台侧栏改为滑出式 */
    .rl-admin-sidebar {
        position: fixed;
        left: 0;
        top: 0;
        bottom: 0;
        z-index: 100;
        transform: translateX(-100%);
        transition: transform 0.2s ease;
    }

    .rl-admin.is-open .rl-admin-sidebar {
        transform: none;
    }

    .rl-admin-toggle {
        display: inline-block;
    }
}

@media (max-width: 640px) {
    .rl-hero-slogan {
        letter-spacing: 2px;
    }

    /* 小屏：缩小轮播指示并上移，避开底部来源标注 */
    .rl-hero-dots {
        bottom: 42px;
        gap: 6px;
    }

    .rl-hero-dot {
        width: 12px;
    }

    .rl-section {
        padding: 52px 18px;
    }

    .rl-admin-content {
        padding: 20px 16px 48px;
    }

    .rl-logo-sub {
        letter-spacing: 2px;
    }

    /* 移动端导航 LOGO 高 22px，偏移约 10px */
    .rl-logo .rl-logo-sub {
        padding-left: 10px;
    }

    .rl-logo-badge {
        width: 32px;
        height: 32px;
        border-radius: 7px;
    }

    .rl-login-logo-badge {
        width: 56px;
        height: 56px;
    }

    .rl-logo-img {
        height: 22px;
        max-width: 160px;
    }

    .rl-login-logo-img {
        height: 40px;
    }

    .rl-header-inner {
        padding: 0 16px;
    }

    .rl-login-card {
        padding: 28px 22px;
    }
}

/* ---------- 无障碍：用户系统开启「减弱动态效果」时 ----------
   首屏轮播停止，只保留第一张实景图，避免持续闪烁造成不适。 */
@media (prefers-reduced-motion: reduce) {
    .rl-hero-slide {
        animation: none;
        opacity: 0;
    }

    .rl-hero-slide:first-child {
        opacity: 1;
    }

    .rl-hero-dot {
        animation: none;
    }

    .rl-hero-dot:first-child {
        background-color: var(--rl-yellow);
    }
}

/* ---------- 子页面内容区最小高度（避免空状态下方大片空白） ---------- */
.rl-page {
    min-height: 60vh;
}

/* ---------- 地图加载指示器 ---------- */
.rl-map-spinner {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 500;
    pointer-events: none;
}

.rl-map-spinner span {
    display: block;
    width: 32px;
    height: 32px;
    border: 3px solid rgba(168, 32, 32, 0.25);
    border-top-color: var(--rl-red);
    border-radius: 50%;
    animation: rl-spin 0.8s linear infinite;
}

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

/* ============================================================
   全站背景音乐控制按钮（像素风 · 右下角悬浮）
   ============================================================ */
.rl-audio-toggle {
    position: fixed;
    right: 18px;
    bottom: 18px;
    z-index: 900;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    background: rgba(18, 18, 18, 0.85);
    border: 2px solid var(--rl-red);
    border-radius: 4px;
    color: var(--rl-text);
    font-family: 'Noto Sans SC', sans-serif;
    font-size: 13px;
    letter-spacing: 1px;
    cursor: pointer;
    box-shadow: 0 0 0 1px rgba(255, 209, 69, 0.4), 0 4px 12px rgba(0, 0, 0, 0.5);
    transition: filter 0.2s ease, transform 0.1s ease;
    -webkit-tap-highlight-color: transparent;
}

.rl-audio-toggle:hover {
    filter: brightness(1.25);
}

.rl-audio-toggle:active {
    transform: translateY(1px);
}

.rl-audio-bars {
    display: inline-flex;
    align-items: flex-end;
    gap: 2px;
    width: 16px;
    height: 14px;
}

.rl-audio-bars i {
    display: block;
    width: 3px;
    height: 4px;
    background: var(--rl-yellow);
}

.rl-audio-toggle.is-playing .rl-audio-bars i {
    animation: rl-eq 0.9s ease-in-out infinite;
}

.rl-audio-toggle.is-playing .rl-audio-bars i:nth-child(2) {
    animation-delay: 0.2s;
}

.rl-audio-toggle.is-playing .rl-audio-bars i:nth-child(3) {
    animation-delay: 0.4s;
}

.rl-audio-toggle:not(.is-playing) .rl-audio-bars i {
    opacity: 0.4;
}

/* 静音待出声状态：条形变冷钢灰，提示“即将有声音” */
.rl-audio-toggle.is-muted .rl-audio-bars i {
    background: #4A4A4A;
}

/* 音频载入中（35MB 文件首次拉流）：黄色像素描边提示仍在等待，避免用户以为失效 */
.rl-audio-toggle.is-loading {
    border-color: var(--rl-yellow);
}

.rl-audio-toggle.is-loading .rl-audio-bars i {
    background: var(--rl-yellow);
    animation: rl-eq 0.9s ease-in-out infinite;
}

.rl-audio-toggle.is-loading .rl-audio-label::after {
    content: " ···";
    letter-spacing: 1px;
}

/* 音频加载失败：暗红警示，明确降级 */
.rl-audio-toggle.is-failed {
    border-color: var(--rl-red);
}

.rl-audio-toggle.is-failed .rl-audio-bars i {
    background: var(--rl-red);
    opacity: 0.5;
}

@keyframes rl-eq {
    0%, 100% {
        height: 4px;
    }
    50% {
        height: 14px;
    }
}

.rl-audio-label {
    white-space: nowrap;
}

@media (max-width: 600px) {
    .rl-audio-toggle {
        right: 12px;
        bottom: 12px;
        padding: 8px 10px;
        font-size: 12px;
    }

    .rl-audio-label {
        display: none;
    }
}
