/* ============================================================
   AIoT · 四川省物联网产教融合发展研究院 — 统一设计系统
   参考 CNCF 风格：浅色主调、深近黑标题、蓝紫渐变点缀、
   大标题分区、数据信任区、Mac 风格组件缩略图、终端元素
   所有页面通过 var(--xxx) 引用，便于全局换肤与保持一致
   ============================================================ */

:root {
    /* ---------- 品牌主色（蓝 → 紫） ---------- */
    --c-primary: #326de6;          /* CNCF 式科技蓝 */
    --c-primary-2: #7c5cf0;        /* 紫罗兰 */
    --c-primary-dark: #1f4fb8;
    --c-primary-2-dark: #5d3fc0;
    --c-primary-50: #eef3ff;
    --c-primary-100: #dbe6ff;
    --c-accent: #9b6cf5;           /* 紫，作为渐变末端点缀 */
    --c-accent-soft: #f5a3d4;

    /* ---------- 渐变 ---------- */
    --gradient-brand: linear-gradient(135deg, #326de6 0%, #5b6ef5 48%, #9b6cf5 100%);
    --gradient-brand-soft: linear-gradient(135deg, #5b6ef5 0%, #7c5cf0 100%);
    --gradient-brand-rev: linear-gradient(135deg, #9b6cf5 0%, #5b6ef5 50%, #326de6 100%);

    /* ---------- 文字（浅色主题：深近黑标题） ---------- */
    --c-text: #16161d;
    --c-text-2: #2e2e3a;
    --c-text-muted: #5b6472;
    --c-text-light: #8b95a5;

    /* ---------- 背景 / 边框（浅色） ---------- */
    --c-bg: #ffffff;
    --c-bg-soft: #f7f8fb;
    --c-bg-mist: #eef1f8;
    --c-bg-deep: #0b1020;          /* 深色区块（hero/footer 反色） */
    --c-border: #e8eaf2;
    --c-border-strong: #d6dbe8;

    /* ---------- 圆角 ---------- */
    --radius-sm: 8px;
    --radius: 12px;
    --radius-lg: 18px;
    --radius-xl: 26px;
    --radius-pill: 999px;

    /* ---------- 阴影（更克制、柔和） ---------- */
    --shadow-sm: 0 1px 3px rgba(16, 22, 29, 0.06), 0 1px 2px rgba(16, 22, 29, 0.04);
    --shadow-md: 0 10px 30px rgba(16, 22, 29, 0.08);
    --shadow-lg: 0 22px 60px rgba(50, 109, 230, 0.18);
    --shadow-soft: 0 4px 18px rgba(16, 22, 29, 0.05);

    /* ---------- 字体 ---------- */
    --font-sans: "Inter", "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    --font-mono: "SFMono-Regular", "JetBrains Mono", "Fira Code", Menlo, Consolas, monospace;

    /* ---------- 容器 ---------- */
    --container: 1200px;
    --container-wide: 1320px;
}

/* ============================================================
   基础
   ============================================================ */
* { box-sizing: border-box; }

/* ========= 全端 Flexbox 粘性页脚：内容不够一屏时 footer 始终贴底 ========= */
html, body {
    min-height: 100vh;
    min-height: 100dvh;
    margin: 0;
    padding: 0;
}

body {
    display: flex;
    flex-direction: column;
    font-family: var(--font-sans);
    color: var(--c-text-2);
    background: var(--c-bg);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    line-height: 1.6;
}

.main-content {
    flex: 1 0 auto;
}

.footer {
    flex-shrink: 0;
}

h1, h2, h3, h4, h5 {
    color: var(--c-text);
    line-height: 1.2;
    letter-spacing: -0.01em;
    font-weight: 800;
}

a { color: var(--c-primary); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--c-primary-dark); }

img { max-width: 100%; display: block; }

/* 渐变文字 */
.text-gradient {
    background: var(--gradient-brand);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

/* ============================================================
   布局工具
   ============================================================ */
.container-box {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
}
.container-wide {
    max-width: var(--container-wide);
    margin: 0 auto;
    padding: 0 24px;
}
.container-header {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
}

.section {
    padding: 96px 0;
    position: relative;
}
.section--tight { padding: 64px 0; }
.section--soft { background: var(--c-bg-soft); }
.section--mist { background: var(--c-bg-mist); }

/* 区块标题（CNCF 风：eyebrow + 大标题 + 描述） */
.section-head { text-align: center; margin-bottom: 56px; max-width: 760px; margin-left: auto; margin-right: auto; }
.section-head .eyebrow {
    display: inline-block;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: var(--c-primary);
    background: var(--c-primary-50);
    padding: 6px 16px;
    border-radius: var(--radius-pill);
    margin-bottom: 18px;
}
.section-head h2 {
    font-size: clamp(28px, 4vw, 42px);
    font-weight: 800;
    color: var(--c-text);
    margin: 0 0 16px;
    letter-spacing: -0.02em;
}
.section-head p {
    font-size: 17px;
    color: var(--c-text-muted);
    line-height: 1.7;
    margin: 0;
}
.section-head--left { text-align: left; margin-left: 0; margin-right: 0; }
.section-head--left .eyebrow { margin-left: 0; }

/* ============================================================
   按钮
   ============================================================ */
.btn-brand {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 30px;
    border: none;
    border-radius: var(--radius-pill);
    background: var(--gradient-brand);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: .2px;
    cursor: pointer;
    box-shadow: 0 8px 22px rgba(50, 109, 230, 0.28);
    transition: transform .3s cubic-bezier(.4,0,.2,1), box-shadow .3s ease, filter .3s ease;
}
.btn-brand:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); filter: brightness(1.05); color:#fff; }
.btn-brand:active { transform: translateY(0); }

.btn-outline-brand {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    border: 1.5px solid var(--c-border-strong);
    border-radius: var(--radius-pill);
    background: #fff;
    color: var(--c-text-2);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all .3s ease;
}
.btn-outline-brand:hover { border-color: var(--c-primary); color: var(--c-primary); background: var(--c-primary-50); }

/* 深色区块内的按钮反色 */
.on-dark .btn-outline-brand {
    border-color: rgba(255,255,255,.3);
    color: #fff;
    background: transparent;
}
.on-dark .btn-outline-brand:hover { border-color: #fff; background: rgba(255,255,255,.1); color:#fff; }

/* ============================================================
   统一卡片
   ============================================================ */
.card-brand {
    background: #fff;
    border: 1px solid var(--c-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
    transition: transform .35s ease, box-shadow .35s ease, border-color .35s ease;
}
.card-brand:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: var(--c-primary-100); }

/* 统一徽标/标签 */
.tag-brand {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 600;
    color: var(--c-primary);
    background: var(--c-primary-50);
    border-radius: var(--radius-pill);
}

/* ============================================================
   CNCF 风：数据信任区（metrics band）
   ============================================================ */
.metrics-head {
    margin-bottom: 44px;
    text-align: left;
}
.metrics-head__row {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
}
.metrics-head__desc-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 16px;
}
.metrics-eyebrow {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--c-primary, #4f46e5);
    display: block;
    margin-bottom: 0;
}
.metrics-title {
    font-size: clamp(26px, 3.4vw, 38px);
    font-weight: 800;
    margin: 0;
    color: var(--c-text, #111827);
    letter-spacing: -0.01em;
    white-space: normal;
}
.metrics-more {
    font-size: 15px;
    font-weight: 600;
    color: var(--c-primary, #4f46e5);
    text-decoration: underline;
    text-underline-offset: 4px;
    text-decoration-thickness: 1.5px;
    cursor: pointer;
    transition: color .2s ease, opacity .2s ease;
    white-space: nowrap;
    flex-shrink: 0;
}
.metrics-more:hover {
    color: #4338ca;
    opacity: .85;
}
.metrics-desc {
    font-size: 15px;
    color: var(--c-text-muted, #6b7280);
    margin: 0;
    line-height: 1.7;
    max-width: 520px;
}

/* 面板：淡渐变背景 + 圆角 + 装饰线，让区域更充实 */
.metrics-panel {
    position: relative;
    padding: 14px;
    border-radius: 24px;
    background:
        radial-gradient(120% 140% at 0% 0%, rgba(99, 102, 241, 0.10), transparent 55%),
        radial-gradient(120% 140% at 100% 100%, rgba(16, 185, 129, 0.10), transparent 55%),
        #ffffff;
    border: 1px solid rgba(229, 231, 235, 0.9);
    box-shadow: 0 18px 50px rgba(17, 24, 39, 0.07);
    overflow: hidden;
}
/* 顶部装饰线（已移除） */
.metrics-panel::before {
    display: none;
}

.metrics-band {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    padding: 26px 12px;
}
.metric-item {
    position: relative;
    text-align: right;
    padding: 28px 18px 24px;
    border-radius: 16px;
    background: #ffffff;
    border: 1px solid #eef0f4;
    box-shadow: 0 6px 18px rgba(17, 24, 39, 0.05);
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
    overflow: visible;
}
.metric-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 32px rgba(79, 70, 229, 0.14);
    border-color: var(--accent, #6366f1);
}
/* 顶部强调色条（已移除） */
.metric-item::before {
    display: none;
}
.metric-item .metric-value {
    display: block;
    text-align: center;
    font-size: clamp(44px, 5.2vw, 62px);
    font-weight: 800;
    line-height: 1;
    color: var(--c-text, #111827);
    letter-spacing: -0.03em;
    margin-top: 6px;
}
.metric-item .metric-value .text-gradient { font-weight: 800; display: inline-block; }
.metric-item .metric-label {
    display: block;
    text-align: center;
    margin-top: 14px;
    font-size: 15px;
    font-weight: 500;
    color: #64748b;
    letter-spacing: .3px;
}

/* ============================================================
   CNCF 风：Mac 风格组件缩略图外壳
   ============================================================ */
.mac-frame {
    background: #fff;
    border-radius: var(--radius-lg);
    border: 1px solid var(--c-border);
    box-shadow: var(--shadow-md);
    overflow: hidden;
}
.mac-frame__bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: var(--c-bg-soft);
    border-bottom: 1px solid var(--c-border);
}
.mac-frame__dot { width: 12px; height: 12px; border-radius: 50%; }
.mac-frame__dot--r { background: #ff5f57; }
.mac-frame__dot--y { background: #febc2e; }
.mac-frame__dot--g { background: #28c840; }
.mac-frame__title {
    margin-left: 10px;
    font-size: 13px;
    color: var(--c-text-muted);
    font-family: var(--font-mono);
}
.mac-frame__body { padding: 0; background: #0b1020; }
.mac-frame__body img,
.mac-img { width: 100%; height: auto; display: block; object-fit: contain; }

/* ============================================================
   CNCF 风：终端（terminal）元素
   ============================================================ */
.terminal {
    background: #0b1020;
    border-radius: var(--radius);
    border: 1px solid rgba(255,255,255,.08);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    font-family: var(--font-mono);
}
.terminal__bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 11px 14px;
    background: #11182e;
    border-bottom: 1px solid rgba(255,255,255,.06);
}
.terminal__dot { width: 11px; height: 11px; border-radius: 50%; }
.terminal__dot--r { background: #ff5f57; }
.terminal__dot--y { background: #febc2e; }
.terminal__dot--g { background: #28c840; }
.terminal__title { margin-left: 8px; font-size: 12px; color: #8b95a5; }
.terminal__body {
    padding: 18px 20px;
    color: #c9d3e8;
    font-size: 13.5px;
    line-height: 1.8;
    white-space: pre-wrap;
    word-break: break-word;
}
.terminal__body .t-prompt { color: #7cf0a0; }
.terminal__body .t-cmd { color: #fff; }
.terminal__body .t-comment { color: #5b6472; }
.terminal__body .t-accent { color: #8ab4ff; }

/* ============================================================
   CNCF 风：项目/分类网格卡片
   ============================================================ */
.grid-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 24px;
}
.project-card {
    position: relative;
    background: #fff;
    border: 1px solid var(--c-border);
    border-radius: var(--radius-lg);
    padding: 28px;
    box-shadow: var(--shadow-soft);
    transition: transform .35s ease, box-shadow .35s ease, border-color .35s ease;
    overflow: hidden;
}
.project-card::before {
    content: "";
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 4px;
    background: var(--gradient-brand);
    opacity: 0;
    transition: opacity .35s ease;
}
.project-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: var(--c-primary-100); }
.project-card:hover::before { opacity: 1; }
.project-card__icon {
    width: 52px; height: 52px;
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    background: var(--c-primary-50);
    color: var(--c-primary);
    font-size: 24px;
    margin-bottom: 18px;
}
.project-card__title { font-size: 18px; font-weight: 700; color: var(--c-text); margin: 0 0 8px; }
.project-card__desc { font-size: 14px; color: var(--c-text-muted); line-height: 1.65; margin: 0; }

/* ============================================================
   CNCF 风：深色区块（hero / CTA / footer）
   ============================================================ */
.on-dark { color: rgba(255,255,255,.82); }
.on-dark h1, .on-dark h2, .on-dark h3, .on-dark h4 { color: #fff; }
.on-dark p { color: rgba(255,255,255,.72); }

.cta-band {
    background: var(--c-bg-deep);
    border-radius: var(--radius-xl);
    padding: 64px 48px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.cta-band::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(600px 300px at 12% 0%, rgba(50,109,230,.35), transparent 60%),
        radial-gradient(600px 300px at 90% 100%, rgba(155,108,245,.30), transparent 60%);
    pointer-events: none;
}
.cta-band > * { position: relative; z-index: 1; }
.cta-band h2 { font-size: clamp(28px, 3.5vw, 38px); margin: 0 0 14px; }
.cta-band p { font-size: 17px; max-width: 620px; margin: 0 auto 28px; }

/* ============================================================
   分隔装饰：波浪/曲线（可选）
   ============================================================ */
.divider-soft {
    height: 1px;
    background: linear-gradient(to right, transparent, var(--c-border-strong), transparent);
    border: none;
    margin: 0;
}

/* ============================================================
   响应式
   ============================================================ */
@media (max-width: 992px) {
    .metrics-band { grid-template-columns: repeat(2, 1fr); gap: 32px 16px; }
    .section { padding: 72px 0; }
}
@media (max-width: 576px) {
    .metrics-band { grid-template-columns: repeat(2, 1fr); }
    .section { padding: 56px 0; }
    .section-head { margin-bottom: 40px; }
    .cta-band { padding: 48px 24px; }
}

/* ============================================================
   基于 reference 资源的风格增强层
   复用 reference 的 Nucleo 图标体系、形状 SVG(curved-images/shapes)
   与 Soft-UI 设计语言（圆角 + 柔和阴影 + 玻璃拟态），
   在保留现有科技渐变主题的基础上提升视觉层次。
   ============================================================ */

/* ---------- Nucleo 图标基础规范 ---------- */
.ni {
    font-size: 1.1em;
    vertical-align: -0.125em;
    line-height: 1;
}
.icon-lg { font-size: 1.6rem; }
.icon-xl { font-size: 2rem; }

/* 图标胶囊：用于卡片 / 列表的图标承载 */
.icon-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: var(--radius-lg);
    background: var(--c-primary-50);
    color: var(--c-primary);
    font-size: 1.4rem;
    box-shadow: var(--shadow-soft);
    transition: transform .25s ease, box-shadow .25s ease, background .25s ease;
}
.icon-badge.accent { background: linear-gradient(135deg, rgba(124,92,240,.14), rgba(155,108,245,.18)); color: var(--c-primary-2); }
a:hover > .icon-badge,
.card:hover .icon-badge,
.feature-card:hover .icon-badge { transform: translateY(-3px); box-shadow: var(--shadow-md); }

/* 深色区块内的图标胶囊（hero / footer） */
.bg-gradient-dark .icon-badge,
.hero::after .icon-badge {
    background: rgba(255,255,255,.12);
    color: #fff;
    box-shadow: none;
}

/* ---------- 形状 / 波浪装饰（来自 reference img/ref/shapes） ---------- */
/* section 之间的波浪过渡分隔：用 reference 的 wave SVG 做柔和衔接 */
.shape-divider {
    position: relative;
    width: 100%;
    line-height: 0;
    pointer-events: none;
    margin-top: -1px;
}
.shape-divider svg { display: block; width: 100%; height: auto; }
.shape-divider.top-flip svg { transform: rotate(180deg); }

/* 绝对定位的浮动装饰形状（点阵 / 线条 / 三角），用于 hero 与 section 背景 */
.bg-shape {
    position: absolute;
    pointer-events: none;
    background-repeat: no-repeat;
    background-size: contain;
    opacity: .8;
    z-index: 0;
}
.bg-shape--pattern {
    top: 24px; right: -10px;
    width: 220px; height: 220px;
    background-image: url('/static/img/ref/shapes/pattern-lines.svg');
    opacity: .35;
}
.bg-shape--dot {
    bottom: 20px; left: -8px;
    width: 160px; height: 160px;
    background-image: url('/static/img/ref/shapes/shape-1.svg');
    opacity: .4;
}

/* 深色区块（footer）内的发光形状，呼应 Soft-UI 的曲线蒙版 */
.bg-gradient-dark .bg-shape--pattern,
.hero .bg-shape--pattern { opacity: .25; }

/* ---------- 曲线蒙版图片（来自 reference img/ref/curved-images） ---------- */
/* 使用 Soft-UI 的 white-curved 曲线蒙版装饰图，作为深色/浅色区块的柔和边缘衔接 */
.curved-mask {
    -webkit-mask-image: url('/static/img/ref/curved-images/white-curved.jpg');
    mask-image: url('/static/img/ref/curved-images/white-curved.jpg');
    -webkit-mask-size: cover;
    mask-size: cover;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
}

/* ---------- Soft-UI 风格卡片升级 ---------- */
/* 在原有卡片基础上叠加更柔和的圆角与悬浮态，与 reference 设计语言对齐 */
.card-soft {
    border-radius: var(--radius-lg);
    border: 1px solid var(--c-border);
    background: var(--c-bg);
    box-shadow: var(--shadow-soft);
    transition: transform .3s cubic-bezier(.2,.7,.3,1), box-shadow .3s ease, border-color .3s ease;
}
.card-soft:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-md);
    border-color: var(--c-primary-100);
}
.card-soft .card-body { padding: 28px; }

/* 玻璃拟态卡片（用于 hero 内的统计 / 浮动信息块） */
.glass-card {
    background: rgba(255,255,255,.72);
    -webkit-backdrop-filter: saturate(180%) blur(14px);
    backdrop-filter: saturate(180%) blur(14px);
    border: 1px solid rgba(255,255,255,.6);
    border-radius: var(--radius-lg);
    box-shadow: 0 18px 50px rgba(11,16,32,.18);
}
.bg-gradient-dark .glass-card {
    background: rgba(255,255,255,.10);
    border-color: rgba(255,255,255,.18);
    box-shadow: 0 18px 50px rgba(0,0,0,.30);
    color: #fff;
}

/* ---------- 装饰插画（来自 reference img/ref/illustrations） ---------- */
.illustration-rocket { width: 160px; max-width: 60%; height: auto; }

/* ---------- 列表项图标化（用 Nucleo 图标替代纯文字） ---------- */
.feature-list { list-style: none; padding: 0; margin: 0; }
.feature-list li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 0;
    color: var(--c-text-2);
}
.feature-list li .ni {
    color: var(--c-primary);
    font-size: 1.1rem;
    margin-top: 4px;
    flex: 0 0 auto;
}

/* ---------- 响应式：移动端隐藏大幅装饰形状 ---------- */
@media (max-width: 768px) {
    .bg-shape--pattern, .bg-shape--dot { display: none; }
    .hero .bg-curved { width: 70%; opacity: .35; }
}

/* ============================================================
   新闻活动页（news_activity）：FlagOS 风格全宽 Hero + 左图右文列表
   ============================================================ */

/* 顶部轮播图区域（宽度与 header 一致，高度约为屏幕一半） */
.na-banner {
    width: 100%;
    padding: 24px 0;            /* 与 header 上下留白保持一致 */
}
.na-banner__viewport {
    position: relative;
    max-width: 1400px;          /* 与 header 内容容器同宽 */
    margin: 0 auto;
    padding: 0 24px;
    height: 50vh;               /* 约为屏幕的一半 */
    min-height: 340px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 24px rgba(15, 23, 42, .08);
}
.na-banner__track {
    position: absolute; inset: 0;
    border-radius: 16px;
    overflow: hidden;
}
.na-banner__slide {
    position: absolute; inset: 0;
    background-size: cover; background-position: center;
    border-radius: 16px;
    opacity: 0; transform: scale(1.06);
    transition: opacity .8s cubic-bezier(0.4, 0, 0.2, 1), transform 4.5s cubic-bezier(0.25, 0, 0, 1);
    text-decoration: none;
}
.na-banner__slide.active {
    opacity: 1; transform: scale(1.0); z-index: 1;
}
.na-banner__overlay {
    position: absolute; inset: 0; z-index: 2; pointer-events: none;
    border-radius: 16px;
    background:
        linear-gradient(90deg, rgba(10, 18, 48, .62) 0%, rgba(10, 18, 48, .32) 45%, rgba(10, 18, 48, .12) 100%),
        linear-gradient(0deg, rgba(10, 18, 48, .55) 0%, transparent 40%);
}
.na-banner__caption {
    position: absolute; left: 0; right: 0; bottom: 0; z-index: 3;
    padding: 48px 56px;
    color: #fff; cursor: pointer;
    max-width: 70%;
}
.na-banner__badge {
    position: absolute; top: 24px; left: 32px; z-index: 4;
    display: inline-block;
    padding: 5px 16px; border-radius: 999px;
    font-size: 12px; font-weight: 700; letter-spacing: .04em;
    color: #fff;
    background: rgba(255, 255, 255, .16);
    border: 1px solid rgba(255, 255, 255, .35);
}
.na-banner__title {
    font-size: clamp(24px, 3.4vw, 40px);
    font-weight: 800; line-height: 1.25; margin: 0 0 14px;
    color: #fff;
    text-shadow: 0 4px 24px rgba(0, 0, 0, .35);
    transition: transform .5s cubic-bezier(.22,.61,.36,1), opacity .4s ease;
    transform: translateY(0); opacity: 1;
}
.na-banner__title.switching { transform: translateY(8px); opacity: 0; }
.na-banner__desc {
    font-size: 15px; line-height: 1.8; color: rgba(255, 255, 255, .82);
    margin: 0; max-width: 640px;
    transition: transform .45s cubic-bezier(.22,.61,.36,1), opacity .35s ease;
    transform: translateY(0); opacity: 1;
}
.na-banner__desc.switching { transform: translateY(6px); opacity: 0; }
.na-banner__arrow {
    position: absolute; top: 50%; transform: translateY(-50%); z-index: 4;
    width: 44px; height: 44px; border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, .35);
    background: rgba(255, 255, 255, .12);
    color: #fff; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    font-size: 16px; backdrop-filter: blur(4px);
    opacity: 0;
    transition: opacity .25s ease, background .25s ease, border-color .25s ease;
}
.na-banner__viewport:hover .na-banner__arrow { opacity: 1; }
.na-banner__arrow:hover { background: rgba(255, 255, 255, .28); border-color: rgba(255, 255, 255, .7); }
.na-banner__arrow--prev { left: 20px; }
.na-banner__arrow--next { right: 20px; }

.na-banner__dots {
    position: absolute; right: 56px; bottom: 48px; z-index: 4;
    display: flex; align-items: center; gap: 10px;
}
.na-banner__dot {
    position: relative;
    width: 8px; height: 8px; border-radius: 50%;
    background: rgba(255, 255, 255, .3); cursor: pointer;
    overflow: hidden;
    flex-shrink: 0;
    transition: width .3s ease, height .3s ease, border-radius .3s ease, background .3s ease;
}
.na-banner__dot.active {
    width: 40px; height: 5px; border-radius: 999px;
    background: rgba(255, 255, 255, .35);  /* 最终倒计时结束后的半透明底色 */
}
.na-banner__dot.completed {
    background: rgba(255, 255, 255, .5);
}
.na-banner__dot-progress {
    display: block;
    position: absolute; top: 0; right: 0; height: 100%;
    background: #fff;                       /* 白色遮罩，从满宽收缩到 0 */
    border-radius: 999px;
    width: 0;                               /* 非激活时隐藏 */
    transition: none;
}
.na-banner__dot.active .na-banner__dot-progress {
    /* 由 JS 内联样式驱动动画，CSS 仅提供兜底 */
}
.na-banner__dot.completed .na-banner__dot-progress {
    width: 100%;
    transition: none;
    opacity: 0;
}

@media (max-width: 768px) {
    .na-banner { padding: 12px 16px; }
    .na-banner__viewport { aspect-ratio: 16 / 9; height: auto; min-height: 200px; padding: 0; border-radius: 12px; overflow: hidden; }
    .na-banner__caption { display: none; }
    .na-banner__badge { top: 16px; left: 16px; }
    .na-banner__dots { right: 24px; bottom: 28px; gap: 6px; }
    .na-banner__dot { width: 6px; height: 6px; }
    .na-banner__dot.active { width: 28px; height: 3px; }
    .na-banner__arrow { width: 38px; height: 38px; opacity: 0; }
    .na-banner__arrow--prev { left: 12px; }
    .na-banner__arrow--next { right: 12px; }
}

/* ========= 二级菜单栏 + 内容列表 ========= */
.na-content {
    max-width: 1400px; margin: 0 auto;
    padding: 0 24px 80px;
    background: linear-gradient(180deg, #f8fafc 0%, #eff6ff 30%, #f5f3ff 60%, #f8fafc 100%);
}
.na-toolbar {
    display: flex; align-items: center; justify-content: space-between;
    flex-wrap: wrap; gap: 16px;
    padding: 28px 0 18px;
    border-bottom: 1px solid #e2e8f0;
}
.na-tabs { display: flex; gap: 32px; }
.na-tab {
    position: relative; padding: 10px 4px;
    border: none; background: none;
    font-size: 15px; font-weight: 600; color: #64748b;
    cursor: pointer;
    transition: color .25s ease, transform .2s ease;
}
.na-tab:hover { color: #144bb5; transform: translateY(-1px); }
.na-tab.active { color: #144bb5; }
.na-tab.active::after {
    content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 3px;
    background: #144bb5; border-radius: 3px 3px 0 0;
    transform-origin: left;
    animation: tab-underline-in .35s cubic-bezier(.22,.61,.36,1);
}
@keyframes tab-underline-in {
    from { transform: scaleX(0); }
    to   { transform: scaleX(1); }
}
.na-toolbar-right { display: flex; align-items: center; gap: 12px; }

.na-category {
    padding: 9px 32px 9px 14px;
    border: 1px solid #e2e8f0; border-radius: 8px;
    font-size: 13px; color: #334155; background: #fff;
    cursor: pointer; outline: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 10px center;
    transition: border-color .25s ease, box-shadow .25s ease;
}
.na-category:focus { border-color: #144bb5; box-shadow: 0 0 0 3px rgba(20,75,181,.1); }

.na-search {
    display: flex; align-items: center; gap: 8px;
    padding: 9px 16px; border: 1px solid #e2e8f0; border-radius: 8px;
    background: #fff; color: #94a3b8;
    min-width: 220px; transition: border-color .2s ease, box-shadow .2s ease;
}
.na-search:focus-within { border-color: #144bb5; box-shadow: 0 0 0 3px rgba(20,75,181,.1); transition: border-color .25s ease, box-shadow .25s ease; }
.na-search input {
    border: none; outline: none; background: none;
    font-size: 14px; color: #1e293b; width: 100%;
}
.na-info-bar {
    font-size: 13px; color: #64748b;
    padding: 14px 0 10px;
}

/* 卡片列表 */
.na-list { display: flex; flex-direction: column; }
.na-cards { display: flex; flex-direction: column; gap: 16px; }

.na-card {
    display: grid; grid-template-columns: 300px 1fr;
    background: linear-gradient(135deg, rgba(50,109,230,.008) 0%, rgba(50,109,230,.016) 50%, rgba(50,109,230,.04) 100%), #fff;
    border: 1px solid #e2e8f0; border-radius: 12px;
    padding: 12px;
    overflow: hidden; box-shadow: 0 1px 4px rgba(15,23,42,.04);
    transition: transform .3s cubic-bezier(.22,.61,.36,1), box-shadow .3s ease, border-color .3s ease;
    cursor: pointer;
    animation: na-card-in .5s cubic-bezier(.22,.61,.36,1) backwards;
}
.na-card:nth-child(1)  { animation-delay: .00s; }
.na-card:nth-child(2)  { animation-delay: .05s; }
.na-card:nth-child(3)  { animation-delay: .10s; }
.na-card:nth-child(4)  { animation-delay: .15s; }
.na-card:nth-child(5)  { animation-delay: .20s; }
.na-card:nth-child(6)  { animation-delay: .25s; }
.na-card:nth-child(7)  { animation-delay: .30s; }
.na-card:nth-child(8)  { animation-delay: .35s; }
.na-card:nth-child(9)  { animation-delay: .40s; }
.na-card:nth-child(10) { animation-delay: .45s; }
.na-card.fresh {
    animation: na-card-in .5s cubic-bezier(.22,.61,.36,1) backwards;
}

@keyframes na-card-in {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: translateY(0); }
}

.na-card:hover { transform: translateY(-4px); box-shadow: 0 14px 30px rgba(15,23,42,.1); border-color: #bfdbfe; }
.na-card__cover {
    position: relative; display: block; overflow: hidden;
    width: 100%;           /* 锁定填满 300px 列，确保所有缩略图尺寸一致 */
    background: #f1f5f9;
    border-radius: 10px;
    min-height: 140px;
}
.na-card__cover,
.na-card__cover img {
    aspect-ratio: 16 / 9;
}
.na-card__cover img {
    width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0;
    border-radius: inherit;
    transition: transform .5s ease;
}
.na-card:hover .na-card__cover img { transform: scale(1.06); }

.na-card__body {
    padding: 0 24px 12px 12px; display: flex; flex-direction: column; justify-content: center;
}
.na-card__meta {
    display: flex; flex-wrap: wrap; gap: 10px; align-items: center;
    margin-bottom: 8px; font-size: 13px; color: #64748b;
}
.na-card__cat {
    display: inline-block; padding: 2px 10px; border-radius: 999px;
    font-size: 12px; font-weight: 600; color: #144bb5;
    background: #e8f0ff;
}
.na-status {
    padding: 3px 10px; border-radius: 999px; font-weight: 700; font-size: 12px;
}
.na-status--upcoming { background: #e8f0ff; color: #144bb5; }
.na-status--ongoing { background: #e7f8ee; color: #16a34a; }
.na-status--completed { background: #f1f3f7; color: #64748b; }

.na-member-badge {
    display: inline-block; padding: 3px 10px; border-radius: 999px;
    font-weight: 700; font-size: 12px; line-height: 1.4;
    background: linear-gradient(135deg, #fef3c7, #fde68a); color: #92400e;
    margin-left: 6px; vertical-align: middle;
}

.na-card__title {
    font-size: 19px; font-weight: 700; line-height: 1.4; margin: 0 0 8px; color: #0f172a;
}
.na-card__title a { color: inherit; text-decoration: none; }
.na-card__title a:hover { color: #144bb5; }
.na-card__summary {
    font-size: 13.5px; line-height: 1.7; color: #475569; margin: 0 0 12px;
    overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.na-card__footer {
    display: flex; align-items: center; justify-content: space-between;
    padding-top: 10px; border-top: 1px solid #f1f5f9;
}
.na-card__info { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.na-card__info-item {
    font-size: 12.5px; color: #94a3b8;
    display: flex; align-items: center; gap: 4px;
    white-space: nowrap;
}
.na-card__info-sep { width: 1px; height: 12px; background: #e2e8f0; }
.na-card__more {
    font-size: 13px; font-weight: 700; color: #144bb5;
    text-decoration: none;
    transition: all .25s ease;
}
.na-card__more:hover { text-decoration: underline; transform: translateX(3px); }
.na-card__event-detail {
    display: flex; flex-direction: column; gap: 6px;
    margin-bottom: 6px;
}
.na-card__event-row {
    display: flex; align-items: center; gap: 8px;
    font-size: 13px; line-height: 1.5;
}
.na-card__event-title {
    color: #667eea; font-weight: 600;
    flex-shrink: 0;
    background: rgba(102, 126, 234, .08); padding: 2px 8px;
    border-radius: 4px;
}
.na-card__event-value {
    color: #475569;
}

/* 加载 / 空 / 更多 */
.na-loading { text-align: center; padding: 60px 0; color: #64748b; }
.na-retry-btn {
    display: inline-block; margin-top: 16px;
    padding: 10px 28px; border: 1px solid #144bb5;
    border-radius: 8px; background: #fff; color: #144bb5;
    font-size: 14px; font-weight: 600; cursor: pointer;
    transition: all .25s ease;
}
.na-retry-btn:hover { background: #144bb5; color: #fff; }
.na-loading__spinner {
    width: 32px; height: 32px; margin: 0 auto 12px;
    border: 3px solid #e2e8f0; border-top-color: #144bb5;
    border-radius: 50%; animation: na-spin .7s cubic-bezier(.45,.05,.55,.95) infinite;
}
@keyframes na-spin { to { transform: rotate(360deg); } }
.na-empty { text-align: center; padding: 60px 0; color: #64748b; }
.na-empty p { margin: 0 0 14px; }
.na-empty__btn {
    border: 1px solid #e2e8f0; background: #fff; color: #334155;
    padding: 9px 22px; border-radius: 8px; cursor: pointer;
    font-size: 13px; font-weight: 600;
}
.na-empty__btn:hover { border-color: #144bb5; color: #144bb5; }
.na-more { text-align: center; margin-top: 28px; }
.na-more__btn {
    border: 1px solid #144bb5; background: #fff; color: #144bb5;
    padding: 11px 36px; border-radius: 8px; cursor: pointer;
    font-size: 14px; font-weight: 700;
    transition: all .3s cubic-bezier(.22,.61,.36,1);
}
.na-more__btn:hover { background: #144bb5; color: #fff; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(20,75,181,.25); }
.na-more__btn:disabled {
    cursor: default; opacity: .55; background: #f1f5f9; border-color: #e2e8f0; color: #94a3b8;
}

@media (max-width: 720px) {
    .na-toolbar { flex-direction: column; align-items: stretch; padding: 14px 0 9px; }
    .na-toolbar-right { flex-direction: column; align-items: stretch; }
    .na-search { min-width: auto; }
    .na-search input { font-size: 16px; }  /* 防止iOS聚焦时自动放大界面 */
    .na-card { grid-template-columns: 1fr; gap: 12px; }
    .na-card__cover { min-height: 200px; border-radius: 10px; }
    .na-card__body { padding: 16px; }
}

/* 权限弹框 */
.permission-modal {
    position: fixed; inset: 0; z-index: 2000; display: none;
    align-items: center; justify-content: center;
}
.permission-modal.show { display: flex; }
.permission-modal__backdrop {
    position: absolute; inset: 0; background: rgba(15,23,42,.55); backdrop-filter: blur(3px);
}
.permission-modal__dialog {
    position: relative; z-index: 1; width: min(420px, 92vw);
    background: #fff; border-radius: var(--radius-lg); padding: 36px 32px;
    text-align: center; box-shadow: var(--shadow-lg);
}
.permission-modal__icon {
    width: 60px; height: 60px; margin: 0 auto 16px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: var(--c-primary-50); color: var(--c-primary);
}
.permission-modal__dialog h3 { margin: 0 0 10px; font-size: 19px; color: var(--c-text); }
.permission-modal__dialog p { margin: 0 0 22px; font-size: 14px; line-height: 1.65; color: var(--c-text-muted); }
.permission-modal__actions { display: flex; gap: 12px; justify-content: center; }
.permission-modal__actions .btn-primary {
    background: var(--c-primary); color: #fff; text-decoration: none;
    padding: 10px 22px; border-radius: 999px; font-size: 14px; font-weight: 600;
}
.permission-modal__actions .btn-secondary {
    border: 1px solid var(--c-border); background: #fff; color: var(--c-text);
    padding: 10px 22px; border-radius: 999px; cursor: pointer; font-size: 14px; font-weight: 600;
}

/* ========= 移动端全局布局修正（确保 footer 锚定、图片约束等生效） ========= */
@media (max-width: 768px) {
    /* 防止 iOS 弹性滚动时 footer 底部滑出白色 */
    html { background: var(--c-bg-deep, #0b1220); }

    /* 平台图片约束已移至 index.html 的 @media (max-width: 768px) */
}
