/* ==========================================================================
   AI 羊毛福利导航 · v2 高级极简编辑风 (Linear / Raycast / Editorial Precision)
   保留 WebStack-Hugo 侧栏+主区骨架，零外部依赖，完整支持深浅色与 375px 移动端
   ========================================================================== */

:root {
    --af-font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC", "Hiragino Sans GB", "Segoe UI", "Microsoft YaHei", sans-serif;
    --af-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;

    /* Light Mode: Warm Alabaster + Crisp Paper + Deep Charcoal */
    --af-bg: #f6f6f3;
    --af-sidebar-bg: #efefeb;
    --af-surface: #ffffff;
    --af-surface-2: #fafaf8;
    --af-surface-hover: #fcfcfb;
    --af-topbar-bg: rgba(246, 246, 243, 0.82);

    --af-border: rgba(17, 19, 24, 0.08);
    --af-border-strong: rgba(17, 19, 24, 0.16);
    --af-hairline: rgba(17, 19, 24, 0.06);

    --af-ink: #111318;
    --af-ink-2: #4b5262;
    --af-ink-3: #838b99;

    --af-btn-bg: #111318;
    --af-btn-ink: #ffffff;
    --af-btn-hover: #272b35;

    --af-emerald: #059669;
    --af-emerald-bg: rgba(16, 185, 129, 0.10);
    --af-amber: #b45309;
    --af-amber-bg: rgba(245, 158, 11, 0.12);
    --af-red: #b91c1c;
    --af-red-bg: rgba(239, 68, 68, 0.10);
    --af-blue: #1d4ed8;
    --af-blue-bg: rgba(37, 99, 235, 0.10);

    --af-shadow-card: 0 1px 2px rgba(17, 19, 24, 0.04), 0 4px 12px rgba(17, 19, 24, 0.02);
    --af-shadow-hover: 0 6px 20px rgba(17, 19, 24, 0.07), 0 1px 3px rgba(17, 19, 24, 0.05);
    --af-glow-1: rgba(16, 185, 129, 0.08);
    --af-glow-2: rgba(59, 130, 246, 0.07);
}

.io-black-mode {
    /* Dark Mode: True Obsidian + Hairline Glass */
    --af-bg: #0b0c0f;
    --af-sidebar-bg: #0f1116;
    --af-surface: #14171e;
    --af-surface-2: #191d26;
    --af-surface-hover: #181c24;
    --af-topbar-bg: rgba(11, 12, 15, 0.82);

    --af-border: rgba(255, 255, 255, 0.08);
    --af-border-strong: rgba(255, 255, 255, 0.17);
    --af-hairline: rgba(255, 255, 255, 0.06);

    --af-ink: #f3f4f6;
    --af-ink-2: #a0a7b5;
    --af-ink-3: #687080;

    --af-btn-bg: #f3f4f6;
    --af-btn-ink: #0b0c0f;
    --af-btn-hover: #ffffff;

    --af-emerald: #34d399;
    --af-emerald-bg: rgba(16, 185, 129, 0.14);
    --af-amber: #fbbf24;
    --af-amber-bg: rgba(245, 158, 11, 0.15);
    --af-red: #f87171;
    --af-red-bg: rgba(239, 68, 68, 0.15);
    --af-blue: #60a5fa;
    --af-blue-bg: rgba(59, 130, 246, 0.16);

    --af-shadow-card: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 2px 8px rgba(0, 0, 0, 0.25);
    --af-shadow-hover: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 10px 28px rgba(0, 0, 0, 0.45);
    --af-glow-1: rgba(16, 185, 129, 0.11);
    --af-glow-2: rgba(99, 102, 241, 0.11);
}

/* 全局基础重置 */
html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--af-font) !important;
    background-color: var(--af-bg) !important;
    color: var(--af-ink) !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: clip;
    font-size: 14px;
    line-height: 1.5;
}

.af-canvas,
.io-grey-mode .page-container .main-content,
.io-black-mode .page-container .main-content {
    background: var(--af-bg) !important;
    background-image: none !important;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.af-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 32px;
}

/* 深浅色 Logo 显示切换 */
.io-black-mode .logo-light { display: none !important; }
.io-black-mode .logo-dark { display: inline-block !important; }
.io-grey-mode .logo-light { display: inline-block !important; }
.io-grey-mode .logo-dark { display: none !important; }

/* ==========================================================================
   左侧导航栏 (Linear Navigation Rail)
   ========================================================================== */
.af-sidebar.sidebar-nav,
.af-sidebar.sidebar-nav .sidebar-nav-inner {
    background: var(--af-sidebar-bg) !important;
    box-shadow: none !important;
}

.af-sidebar.sidebar-nav {
    border-right: 1px solid var(--af-border) !important;
}

@media (min-width: 768px) {
    .af-sidebar.sidebar-nav {
        width: 224px !important;
        min-width: 224px !important;
        transition: width 0.22s ease, min-width 0.22s ease;
    }
    .af-sidebar.sidebar-nav.mini-sidebar {
        width: 64px !important;
        min-width: 64px !important;
    }
    .main-content {
        margin-left: 224px !important;
        transition: margin-left 0.22s ease;
    }
    .mini-sidebar ~ .main-content {
        margin-left: 64px !important;
    }
    .af-topbar {
        left: 224px !important;
        transition: left 0.22s ease;
    }
    .mini-sidebar ~ .main-content .af-topbar {
        left: 64px !important;
    }
}

.af-sidebar-logo {
    height: 60px;
    padding: 0 18px !important;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--af-hairline) !important;
}

.mini-sidebar .af-sidebar-logo {
    padding: 0 14px !important;
    justify-content: center;
}

.af-nav-wrap {
    padding: 16px 10px;
}

.af-nav-section-label {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.06em;
    color: var(--af-ink-3);
    padding: 0 10px 8px;
}

.mini-sidebar .af-nav-section-label,
.mini-sidebar .af-nav-text,
.mini-sidebar .af-nav-count,
.mini-sidebar .af-sidebar-foot {
    display: none !important;
}

.af-nav-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.af-nav-item {
    margin-bottom: 2px;
}

.af-nav-link {
    display: flex !important;
    align-items: center;
    gap: 10px;
    height: 36px;
    padding: 0 10px !important;
    border-radius: 8px;
    color: var(--af-ink-2) !important;
    font-size: 13.5px;
    font-weight: 500;
    text-decoration: none !important;
    transition: background-color 0.16s ease, color 0.16s ease;
}

.af-nav-link:hover {
    background: rgba(128, 128, 128, 0.08);
    color: var(--af-ink) !important;
}

.af-nav-link.is-active {
    background: var(--af-surface);
    color: var(--af-ink) !important;
    font-weight: 600;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.io-black-mode .af-nav-link.is-active {
    background: rgba(255, 255, 255, 0.08);
    box-shadow: none;
}

.mini-sidebar .af-nav-link {
    justify-content: center;
    padding: 0 !important;
}

.af-nav-ico {
    width: 17px;
    height: 17px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    opacity: 0.8;
}

.af-nav-link.is-active .af-nav-ico {
    opacity: 1;
    color: var(--af-ink);
}

.af-nav-ico svg {
    width: 17px;
    height: 17px;
}

.af-nav-text {
    flex: 1;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.af-nav-count {
    font-family: var(--af-mono);
    font-size: 11.5px;
    color: var(--af-ink-3);
    font-variant-numeric: tabular-nums;
}

.af-sidebar-foot {
    padding: 12px;
    border-top: 1px solid var(--af-hairline);
}

.af-sidebar-foot-card {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 10px;
    border-radius: 8px;
    background: var(--af-surface);
    border: 1px solid var(--af-border);
    font-size: 11.5px;
    color: var(--af-ink-2);
    line-height: 1.35;
}

.af-foot-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--af-emerald);
    flex-shrink: 0;
}

/* ==========================================================================
   顶部极简导航栏
   ========================================================================== */
.af-topbar-wrap {
    background: transparent !important;
}

.af-topbar.page-header {
    height: 60px;
    background: var(--af-topbar-bg) !important;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--af-hairline);
    box-shadow: none !important;
    padding: 0 !important;
    color: var(--af-ink) !important;
    z-index: 90;
}

.af-topbar-spacer {
    height: 60px !important;
}

.af-topbar-inner {
    height: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.af-topbar-left,
.af-topbar-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.af-collapse-btn {
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    margin: 0;
    border: 1px solid transparent;
    border-radius: 8px;
    background: transparent;
    color: var(--af-ink-2);
    cursor: pointer;
    transition: background-color 0.16s ease, color 0.16s ease, border-color 0.16s ease;
}

.af-collapse-btn:hover {
    background: rgba(128, 128, 128, 0.10);
    color: var(--af-ink);
}

.af-collapse-btn:focus {
    outline: none;
}

.af-collapse-btn svg {
    width: 18px;
    height: 18px;
    display: block;
}

.af-topbar-crumb {
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--af-ink-3);
}

.af-crumb-sep {
    opacity: 0.45;
}

.af-mobile-menu-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 8px;
    border: 1px solid var(--af-border);
    background: var(--af-surface);
    color: var(--af-ink);
    padding: 0;
    cursor: pointer;
}
.af-mobile-menu-btn svg {
    width: 18px;
    height: 18px;
}

.af-mobile-brand {
    display: inline-flex;
    align-items: center;
}

/* 深浅色切换按钮（全站唯一入口） */
.af-theme-switch {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 32px;
    padding: 0 11px;
    border-radius: 999px;
    border: 1px solid var(--af-border);
    background: var(--af-surface);
    color: var(--af-ink-2);
    font-size: 12.5px;
    font-weight: 500;
    cursor: pointer;
    transition: border-color 0.16s ease, color 0.16s ease, background-color 0.16s ease;
}

.af-theme-switch:hover {
    border-color: var(--af-border-strong);
    color: var(--af-ink);
}

.af-theme-switch:focus {
    outline: none;
}
.af-theme-switch:focus-visible {
    outline: 2px solid var(--af-blue);
    outline-offset: 2px;
}

.af-theme-icon {
    width: 15px;
    height: 15px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.af-theme-icon svg {
    width: 15px;
    height: 15px;
}

.io-grey-mode .af-theme-sun { display: none; }
.io-grey-mode .af-theme-moon { display: inline-flex; }
.io-black-mode .af-theme-sun { display: inline-flex; }
.io-black-mode .af-theme-moon { display: none; }

/* ==========================================================================
   Editorial Hero & Command Search Bar
   ========================================================================== */
.af-hero {
    position: relative;
    padding: 36px 0 24px;
    overflow: hidden;
}

.af-hero-glow {
    position: absolute;
    inset: -80px 0 auto 0;
    height: 280px;
    pointer-events: none;
    background:
        radial-gradient(560px 200px at 18% 20%, var(--af-glow-1), transparent 70%),
        radial-gradient(520px 220px at 82% 10%, var(--af-glow-2), transparent 70%);
}

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

.af-hero-grid {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 24px;
}

.af-hero-copy {
    max-width: 620px;
}

.af-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--af-surface);
    border: 1px solid var(--af-border);
    font-family: var(--af-mono);
    font-size: 10.5px;
    font-weight: 600;
    letter-spacing: 0.08em;
    color: var(--af-ink-2);
    margin-bottom: 14px;
}

.af-live-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--af-emerald);
    box-shadow: 0 0 0 3px var(--af-emerald-bg);
}

.af-hero-title {
    font-size: 32px;
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.18;
    color: var(--af-ink);
    margin: 0 0 10px;
}

.af-hero-desc {
    font-size: 14.5px;
    line-height: 1.6;
    color: var(--af-ink-2);
    margin: 0;
}

/* 统计指标块 */
.af-hero-metrics {
    display: inline-flex;
    align-items: center;
    gap: 18px;
    padding: 12px 20px;
    border-radius: 12px;
    background: var(--af-surface);
    border: 1px solid var(--af-border);
    box-shadow: var(--af-shadow-card);
    flex-shrink: 0;
}

.af-metric-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1px;
}

.af-metric-num {
    font-size: 20px;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.1;
    color: var(--af-ink);
    font-variant-numeric: tabular-nums;
}
.af-metric-num.is-emerald { color: var(--af-emerald); }
.af-metric-num.is-amber { color: var(--af-amber); }

.af-metric-label {
    font-size: 11.5px;
    color: var(--af-ink-3);
}

.af-metric-div {
    width: 1px;
    height: 26px;
    background: var(--af-hairline);
}

/* Command Palette 风格检索框 */
.af-command-bar {
    max-width: 100%;
}

.af-search-shell {
    display: flex;
    align-items: center;
    gap: 10px;
    height: 46px;
    padding: 0 14px;
    border-radius: 12px;
    background: var(--af-surface);
    border: 1px solid var(--af-border);
    box-shadow: var(--af-shadow-card);
    transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.af-search-shell:focus-within {
    border-color: var(--af-border-strong);
    box-shadow: 0 0 0 3px rgba(17, 19, 24, 0.06), var(--af-shadow-card);
}

.io-black-mode .af-search-shell:focus-within {
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.08), var(--af-shadow-card);
}

.af-search-ico {
    width: 17px;
    height: 17px;
    color: var(--af-ink-3);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.af-search-ico svg {
    width: 17px;
    height: 17px;
}

.af-search-input {
    flex: 1;
    min-width: 0;
    border: none;
    outline: none;
    background: transparent;
    color: var(--af-ink);
    font-size: 14px;
    height: 100%;
}

.af-search-input::placeholder {
    color: var(--af-ink-3);
}

.af-search-clear {
    width: 24px;
    height: 24px;
    border: none;
    border-radius: 6px;
    background: rgba(128, 128, 128, 0.12);
    color: var(--af-ink-2);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    cursor: pointer;
}
.af-search-clear svg {
    width: 13px;
    height: 13px;
}
.af-search-clear:hover {
    color: var(--af-ink);
    background: rgba(128, 128, 128, 0.22);
}

.af-kbd {
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    border-radius: 6px;
    border: 1px solid var(--af-border);
    background: var(--af-surface-2);
    font-family: var(--af-mono);
    font-size: 11px;
    color: var(--af-ink-3);
    line-height: 1;
}

/* ==========================================================================
   筛选控制条 (Inline Control Rail)
   ========================================================================== */
.af-main {
    flex: 1;
    padding: 0 0 40px !important;
}

.af-control-rail {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 0 22px;
    border-bottom: 1px solid var(--af-hairline);
    margin-bottom: 28px;
}

.af-segmented {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px;
    border-radius: 10px;
    background: var(--af-sidebar-bg);
    border: 1px solid var(--af-hairline);
}

.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 30px;
    padding: 0 12px;
    border-radius: 7px;
    border: none;
    background: transparent;
    color: var(--af-ink-2);
    font-size: 12.5px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease;
}

.filter-chip:hover {
    color: var(--af-ink);
}

.filter-chip:focus {
    outline: none;
}

.filter-chip.active {
    background: var(--af-surface);
    color: var(--af-ink);
    font-weight: 600;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.io-black-mode .filter-chip.active {
    background: rgba(255, 255, 255, 0.10);
    box-shadow: none;
}

.chip-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
}
.chip-dot.dot-ok { background: var(--af-emerald); }
.chip-dot.dot-warn { background: var(--af-amber); }
.chip-dot.dot-info { background: var(--af-blue); }

.af-rail-right {
    display: flex;
    align-items: center;
    gap: 14px;
}

.af-switch {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    cursor: pointer;
    user-select: none;
    font-size: 12.5px;
    color: var(--af-ink-2);
}

.af-switch input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.af-switch-track {
    position: relative;
    width: 34px;
    height: 20px;
    border-radius: 999px;
    background: rgba(128, 128, 128, 0.28);
    transition: background-color 0.18s ease;
    flex-shrink: 0;
}

.af-switch-track::after {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
    transition: transform 0.18s ease, background-color 0.18s ease;
}

.io-black-mode .af-switch-track::after {
    background: #9ca3af;
}

.af-switch input:checked + .af-switch-track {
    background: var(--af-emerald);
}

.af-switch input:checked + .af-switch-track::after {
    transform: translateX(14px);
    background: #ffffff;
}

.af-switch-num {
    font-family: var(--af-mono);
    font-size: 11.5px;
    color: var(--af-ink-3);
}

.af-rail-sep {
    width: 1px;
    height: 14px;
    background: var(--af-border);
}

.af-counter {
    font-family: var(--af-mono);
    font-size: 12px;
    color: var(--af-ink-3);
    font-variant-numeric: tabular-nums;
}

/* ==========================================================================
   分类区与福利卡片网格
   ========================================================================== */
.af-section {
    margin-bottom: 36px;
}

.af-section-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
    scroll-margin-top: 80px;
}

.af-section-title-group {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.af-section-title {
    font-size: 15.5px;
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--af-ink);
    margin: 0;
}

.af-section-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 20px;
    padding: 0 6px;
    border-radius: 6px;
    background: var(--af-sidebar-bg);
    border: 1px solid var(--af-hairline);
    font-family: var(--af-mono);
    font-size: 11px;
    font-weight: 600;
    color: var(--af-ink-2);
}

.af-section-line {
    flex: 1;
    height: 1px;
    background: var(--af-hairline);
}

.af-card-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

@media (max-width: 1199.98px) {
    .af-card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767.98px) {
    .af-card-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
}

.welfare-card-col.is-expired-hidden,
.welfare-card-col.is-filtered-out {
    display: none !important;
}

/* 卡片本体 */
.af-card {
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 18px 20px;
    border-radius: 14px;
    background: var(--af-surface);
    border: 1px solid var(--af-border);
    box-shadow: var(--af-shadow-card);
    transition: transform 0.2s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.2s ease, box-shadow 0.2s ease;
    position: relative;
}

.af-card:hover {
    transform: translateY(-2px);
    border-color: var(--af-border-strong);
    box-shadow: var(--af-shadow-hover);
}

/* 中高风险顶部细线强调，克制且醒目 */
.af-card-warn {
    border-color: rgba(245, 158, 11, 0.32);
}
.af-card-danger {
    border-color: rgba(239, 68, 68, 0.38);
}

.af-card-head {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 14px;
}

/* 克制的单色 Squircle 首字母标识 */
.af-monogram {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: -0.02em;
    background: var(--af-surface-2);
    border: 1px solid var(--af-border);
    color: var(--af-ink);
    flex-shrink: 0;
}

.af-monogram.is-risk-medium {
    background: var(--af-amber-bg);
    border-color: rgba(245, 158, 11, 0.28);
    color: var(--af-amber);
}

.af-monogram.is-risk-high {
    background: var(--af-red-bg);
    border-color: rgba(239, 68, 68, 0.32);
    color: var(--af-red);
}

.af-head-main {
    flex: 1;
    min-width: 0;
}

.af-card-title {
    font-size: 15.5px;
    font-weight: 700;
    letter-spacing: -0.015em;
    color: var(--af-ink);
    line-height: 1.3;
    margin: 0 0 6px;
    word-break: break-word;
}

.af-pill-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
}

.af-status-pill,
.af-risk-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    height: 21px;
    padding: 0 8px;
    border-radius: 6px;
    font-size: 11.5px;
    font-weight: 600;
    line-height: 1;
}

.af-pill-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: currentColor;
}

.af-status-pill.is-available {
    background: var(--af-emerald-bg);
    color: var(--af-emerald);
}
.af-status-pill.is-verify {
    background: var(--af-amber-bg);
    color: var(--af-amber);
}
.af-status-pill.is-claimed {
    background: var(--af-blue-bg);
    color: var(--af-blue);
}
.af-status-pill.is-expired {
    background: rgba(128, 128, 128, 0.14);
    color: var(--af-ink-3);
}

.af-risk-pill.is-risk-none {
    background: transparent;
    border: 1px solid var(--af-hairline);
    color: var(--af-ink-3);
    font-weight: 500;
}
.af-risk-pill.is-risk-low {
    background: var(--af-blue-bg);
    color: var(--af-blue);
}
.af-risk-pill.is-risk-medium {
    background: var(--af-amber-bg);
    color: var(--af-amber);
}
.af-risk-pill.is-risk-high {
    background: var(--af-red-bg);
    color: var(--af-red);
}

/* 核心福利文案（直接呈现，不嵌套多余小框） */
.af-benefit {
    font-size: 13.75px;
    line-height: 1.6;
    color: var(--af-ink);
    margin: 0 0 14px;
    word-break: break-word;
}

/* 精致细线参数表 */
.af-specs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 14px;
    padding: 12px 0;
    margin: 0;
    border-top: 1px solid var(--af-hairline);
    border-bottom: 1px solid var(--af-hairline);
}

.af-spec-row {
    min-width: 0;
}

.af-spec-row dt {
    font-size: 11px;
    font-weight: 500;
    color: var(--af-ink-3);
    margin: 0 0 2px;
}

.af-spec-row dd {
    font-size: 12.5px;
    font-weight: 500;
    color: var(--af-ink-2);
    margin: 0;
    line-height: 1.4;
    word-break: break-word;
}

.af-spec-row dd.is-muted-val {
    color: var(--af-ink-3);
    font-weight: 400;
}

/* 中高风险醒目提示框 */
.af-callout {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-top: 12px;
    padding: 10px 12px;
    border-radius: 9px;
    font-size: 12px;
    line-height: 1.55;
}

.af-callout-ico {
    width: 16px;
    height: 16px;
    margin-top: 1px;
    flex-shrink: 0;
}
.af-callout-ico svg {
    width: 16px;
    height: 16px;
}

.af-callout.callout-danger {
    background: var(--af-red-bg);
    border: 1px solid rgba(239, 68, 68, 0.26);
    color: var(--af-red);
}

.af-callout.callout-warn {
    background: var(--af-amber-bg);
    border: 1px solid rgba(245, 158, 11, 0.28);
    color: var(--af-amber);
}

.af-callout-body {
    min-width: 0;
    word-break: break-word;
}

/* 常规备注 */
.af-footnote {
    font-size: 12px;
    line-height: 1.5;
    color: var(--af-ink-3);
    margin: 12px 0 0;
}

/* 卡片底部行动链接 */
.af-card-foot {
    margin-top: auto;
    padding-top: 14px;
    display: flex;
    justify-content: flex-end;
}

.af-visit-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    height: 36px;
    padding: 0 14px;
    border-radius: 9px;
    background: var(--af-surface-2);
    border: 1px solid var(--af-border);
    color: var(--af-ink) !important;
    font-size: 12.5px;
    font-weight: 600;
    text-decoration: none !important;
    transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.af-visit-btn:hover {
    background: var(--af-btn-bg);
    border-color: var(--af-btn-bg);
    color: var(--af-btn-ink) !important;
}

.af-visit-btn .af-arrow {
    width: 14px;
    height: 14px;
    transition: transform 0.18s ease;
}

.af-visit-btn:hover .af-arrow {
    transform: translate(2px, -2px);
}

/* 空状态 */
.af-empty {
    text-align: center;
    padding: 56px 24px;
    border-radius: 14px;
    background: var(--af-surface);
    border: 1px dashed var(--af-border-strong);
}

.af-empty-ico {
    width: 40px;
    height: 40px;
    margin: 0 auto 12px;
    color: var(--af-ink-3);
}
.af-empty-ico svg {
    width: 40px;
    height: 40px;
}

.af-empty-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--af-ink);
    margin: 0 0 6px;
}

.af-empty-sub {
    font-size: 13px;
    color: var(--af-ink-3);
    margin: 0 0 18px;
}

.af-reset-btn {
    height: 34px;
    padding: 0 16px;
    border-radius: 8px;
    border: none;
    background: var(--af-btn-bg);
    color: var(--af-btn-ink);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

/* ==========================================================================
   页脚与返回顶部
   ========================================================================== */
.af-footer {
    margin-top: auto;
    background: transparent !important;
    border-top: 1px solid var(--af-hairline);
    padding: 24px 0 32px !important;
}

.af-footer-inner {
    text-align: center;
}

.af-footer-l1 {
    font-size: 12.5px;
    color: var(--af-ink-2);
    margin: 0 0 4px;
}

.af-footer-l2 {
    font-size: 12px;
    color: var(--af-ink-3);
    margin: 0;
}

.af-back-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    border: 1px solid var(--af-border);
    background: var(--af-surface);
    color: var(--af-ink-2);
    box-shadow: var(--af-shadow-hover);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transform: translateY(8px);
    transition: opacity 0.2s ease, transform 0.2s ease, color 0.16s ease, border-color 0.16s ease;
    z-index: 80;
}

.af-back-top.is-visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.af-back-top:hover {
    color: var(--af-ink);
    border-color: var(--af-border-strong);
}

.af-back-top svg {
    width: 17px;
    height: 17px;
}

/* ==========================================================================
   移动端 375px 精细适配
   ========================================================================== */
@media (max-width: 767.98px) {
    .af-container,
    .af-topbar-inner {
        padding: 0 16px;
    }

    .af-topbar.page-header {
        left: 0 !important;
        height: 54px;
    }
    .af-topbar-spacer {
        height: 54px !important;
    }

    .af-hero {
        padding: 22px 0 16px;
    }

    .af-hero-grid {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
        margin-bottom: 18px;
    }

    .af-hero-title {
        font-size: 24px;
    }

    .af-hero-desc {
        font-size: 13.5px;
    }

    .af-hero-metrics {
        width: 100%;
        justify-content: space-between;
        padding: 10px 16px;
        gap: 10px;
    }

    .af-metric-num {
        font-size: 18px;
    }

    .af-search-shell {
        height: 42px;
        padding: 0 12px;
    }

    .af-search-input {
        font-size: 13.5px;
    }

    .af-control-rail {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        padding: 10px 0 16px;
        margin-bottom: 20px;
    }

    .af-segmented {
        width: 100%;
        justify-content: space-between;
    }

    .filter-chip {
        flex: 1;
        justify-content: center;
        padding: 0 8px;
        font-size: 12px;
    }

    .af-rail-right {
        justify-content: space-between;
    }

    .af-card {
        padding: 16px;
    }

    .af-back-top {
        right: 16px;
        bottom: 16px;
        width: 36px;
        height: 36px;
    }

    /* 移动端侧栏抽屉美化 */
    .af-sidebar.sidebar-nav.show {
        background: var(--af-sidebar-bg) !important;
    }
}
