
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }
        
        :root {
            --brand: #7c3aed;
            --brand-2: #4f46e5;
            --brand-soft: rgba(124, 58, 237, 0.12);
            --surface: rgba(255, 255, 255, 0.82);
            --surface-solid: #ffffff;
            --ink: #1f1635;
            --muted: #6b7280;
            --line: rgba(124, 58, 237, 0.12);
            --shadow: 0 18px 50px rgba(49, 30, 100, 0.10);
            --radius: 18px;
        }

        body {
            font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
            color: var(--ink);
            min-height: 100vh;
            background:
                radial-gradient(900px 500px at 8% 0%, rgba(167, 139, 250, 0.22), transparent 55%),
                radial-gradient(800px 480px at 92% 8%, rgba(99, 102, 241, 0.16), transparent 50%),
                radial-gradient(700px 420px at 70% 100%, rgba(236, 72, 153, 0.10), transparent 55%),
                linear-gradient(180deg, #f4f1ff 0%, #f7f8fc 40%, #eef2ff 100%);
            background-attachment: fixed;
            overflow-x: hidden;
        }

        body::before {
            content: '';
            position: fixed;
            inset: 0;
            pointer-events: none;
            z-index: 0;
            background-image:
                linear-gradient(rgba(124, 58, 237, 0.035) 1px, transparent 1px),
                linear-gradient(90deg, rgba(124, 58, 237, 0.035) 1px, transparent 1px);
            background-size: 56px 56px;
            mask-image: radial-gradient(circle at center, black 35%, transparent 85%);
            animation: appGridDrift 24s linear infinite;
            opacity: 0.7;
        }

        body::after {
            content: '';
            position: fixed;
            width: 420px;
            height: 420px;
            border-radius: 50%;
            right: 0;
            top: 120px;
            background: radial-gradient(circle, rgba(167, 139, 250, 0.28), transparent 70%);
            filter: blur(18px);
            pointer-events: none;
            z-index: 0;
            animation: appOrbFloat 14s ease-in-out infinite;
        }

        .top-nav,
        .app-shell {
            position: relative;
            z-index: 1;
        }

        @keyframes appGridDrift {
            from { background-position: 0 0; }
            to { background-position: -56px -28px; }
        }
        @keyframes appOrbFloat {
            0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
            50% { transform: translate3d(-30px, 40px, 0) scale(1.08); }
        }
        @keyframes fadeIn {
            from { opacity: 0; transform: translateY(18px); filter: blur(4px); }
            to { opacity: 1; transform: translateY(0); filter: blur(0); }
        }
        @keyframes softPulse {
            0%, 100% { box-shadow: 0 0 0 0 rgba(124, 58, 237, 0.18); }
            50% { box-shadow: 0 0 0 8px rgba(124, 58, 237, 0); }
        }
        @keyframes shimmerSweep {
            0% { transform: translateX(-130%); }
            100% { transform: translateX(130%); }
        }
        @keyframes navGlow {
            0%, 100% { opacity: 0.45; }
            50% { opacity: 0.85; }
        }
        @keyframes chatBubbleIn {
            from { opacity: 0; transform: translateY(14px) scale(0.98); }
            to { opacity: 1; transform: translateY(0) scale(1); }
        }
        @keyframes chatTypingDot {
            0%, 80%, 100% { transform: translateY(0); opacity: 0.35; }
            40% { transform: translateY(-4px); opacity: 1; }
        }
        @keyframes chatGlowPulse {
            0%, 100% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.18); }
            50% { box-shadow: 0 0 0 8px rgba(99, 102, 241, 0); }
        }
        .team-chat-shell {
            border: 1px solid #e5e7eb;
            border-radius: 18px;
            background:
                radial-gradient(circle at top right, rgba(129, 140, 248, 0.16), transparent 42%),
                linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
            box-shadow: 0 16px 40px rgba(15, 23, 42, 0.06);
            overflow: hidden;
        }
        .team-chat-stream {
            display: flex;
            flex-direction: column;
            gap: 12px;
            padding: 16px;
            min-height: 320px;
            max-height: 380px;
            overflow-y: auto;
            background:
                linear-gradient(180deg, rgba(248, 250, 252, 0.9), rgba(238, 242, 255, 0.55));
        }
        .team-chat-row {
            display: flex;
            width: 100%;
            animation: chatBubbleIn 0.32s cubic-bezier(0.22, 1, 0.36, 1) both;
        }
        .team-chat-row.user { justify-content: flex-end; }
        .team-chat-row.assistant { justify-content: flex-start; }
        .team-chat-bubble {
            max-width: min(86%, 560px);
            padding: 12px 14px;
            border-radius: 18px;
            line-height: 1.7;
            font-size: 14px;
            white-space: pre-wrap;
            word-break: break-word;
            box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
            position: relative;
        }
        .team-chat-bubble.user {
            background: linear-gradient(135deg, #4f46e5, #7c3aed);
            color: #fff;
            border-bottom-right-radius: 6px;
        }
        .team-chat-bubble.assistant {
            background: rgba(255, 255, 255, 0.92);
            color: #1f2937;
            border: 1px solid #e0e7ff;
            border-bottom-left-radius: 6px;
            backdrop-filter: blur(8px);
        }
        .team-chat-label {
            font-size: 11px;
            font-weight: 700;
            margin-bottom: 6px;
            letter-spacing: 0.02em;
        }
        .team-chat-bubble.user .team-chat-label { color: rgba(255,255,255,0.82); }
        .team-chat-bubble.assistant .team-chat-label { color: #4f46e5; }
        .team-chat-meta {
            margin-top: 8px;
            font-size: 12px;
            color: #6b7280;
        }
        .team-chat-typing {
            display: inline-flex;
            gap: 5px;
            align-items: center;
            padding: 4px 2px;
        }
        .team-chat-typing span {
            width: 7px;
            height: 7px;
            border-radius: 50%;
            background: #818cf8;
            animation: chatTypingDot 1.1s infinite ease-in-out;
        }
        .team-chat-typing span:nth-child(2) { animation-delay: 0.15s; }
        .team-chat-typing span:nth-child(3) { animation-delay: 0.3s; }
        .team-chat-chip {
            border: 1px solid #ddd6fe;
            background: rgba(255,255,255,0.8);
            color: #4f46e5;
            transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
        }
        .team-chat-chip:hover {
            transform: translateY(-2px);
            background: #eef2ff;
            box-shadow: 0 8px 18px rgba(79, 70, 229, 0.12);
        }
        .team-chat-send {
            transition: transform 0.18s ease, box-shadow 0.18s ease;
            animation: chatGlowPulse 2.8s ease-in-out infinite;
        }
        .team-chat-send:hover { transform: translateY(-1px) scale(1.02); }
        .openai-hero {
            position: relative;
            overflow: hidden;
            border-radius: 20px;
            padding: 22px 24px;
            color: #fff;
            background: linear-gradient(125deg, #4c1d95 0%, #6d28d9 45%, #4338ca 100%);
            background-size: 180% 180%;
            animation: navGradientShift 10s ease infinite;
            box-shadow: 0 18px 40px rgba(76, 29, 149, 0.28);
            margin-bottom: 18px;
        }
        .openai-hero::after {
            content: '';
            position: absolute;
            inset: 0;
            background: linear-gradient(110deg, transparent 20%, rgba(255,255,255,0.18) 48%, transparent 72%);
            transform: translateX(-120%);
            animation: shimmerSweep 4.8s ease-in-out infinite;
            pointer-events: none;
        }
        .openai-panel {
            border: 1px solid #e9d5ff;
            border-radius: 18px;
            background: linear-gradient(180deg, #ffffff, #faf5ff);
            box-shadow: 0 14px 36px rgba(88, 28, 135, 0.08);
            padding: 18px;
            margin-bottom: 16px;
            animation: fadeIn 0.45s cubic-bezier(0.22, 1, 0.36, 1) both;
            transition: transform 0.2s ease, box-shadow 0.2s ease;
        }
        .openai-panel:hover {
            transform: translateY(-2px);
            box-shadow: 0 18px 40px rgba(88, 28, 135, 0.12);
        }
        .openai-status-pill {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            padding: 4px 10px;
            border-radius: 999px;
            font-size: 12px;
            font-weight: 700;
            background: rgba(255,255,255,0.16);
            border: 1px solid rgba(255,255,255,0.22);
        }

        /* 顶部导航栏 */
        .top-nav {
            color: white;
            padding: 12px 24px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            background: #7c3aed;
            box-shadow: 0 8px 24px rgba(124, 58, 237, 0.22);
            backdrop-filter: blur(12px);
            position: sticky;
            top: 0;
            z-index: 1000;
            overflow-x: clip;   /* 裁掉 ::before 流光(translateX ±130%)的水平溢出，避免整页幽灵横滚 */
            overflow-y: visible; /* 保留通知/搜索/用户菜单等下拉面板向下溢出 */
        }
        .nav-back-btn {
            position: relative; z-index: 2; flex-shrink: 0;
            display: inline-flex; align-items: center; gap: 6px;
            margin-right: 12px; padding: 7px 14px;
            border: 1px solid rgba(255,255,255,0.35); border-radius: 999px;
            background: rgba(255,255,255,0.12); color: #fff;
            font-size: 13px; font-weight: 600; cursor: pointer;
            transition: background 0.18s, border-color 0.18s, opacity 0.18s;
        }
        .nav-back-btn:hover:not(:disabled) {
            background: rgba(255,255,255,0.22); border-color: rgba(255,255,255,0.55);
        }
        .nav-back-btn:disabled,
        .nav-back-btn.is-disabled {
            opacity: 0.42; cursor: not-allowed;
        }
        .nav-back-btn .back-arrow { font-size: 14px; line-height: 1; }
        .top-nav::before {
            content: '';
            position: absolute;
            inset: 0;
            background: linear-gradient(90deg, transparent, rgba(255,255,255,0.18), transparent);
            transform: translateX(-120%);
            animation: shimmerSweep 4.8s ease-in-out infinite;
            pointer-events: none;
            border-radius: inherit;
            overflow: hidden;
        }
        @keyframes navGradientShift {
            0%, 100% { background-position: 0% 50%; }
            50% { background-position: 100% 50%; }
        }
        
        .global-search {
            position: relative;
            z-index: 2;
            flex: 1;
            max-width: 460px;
            margin: 0 24px;
        }
        .global-search-icon {
            position: absolute;
            left: 12px;
            top: 50%;
            transform: translateY(-50%);
            font-size: 13px;
            opacity: 0.7;
            pointer-events: none;
        }
        #globalSearchInput {
            width: 100%;
            padding: 8px 12px 8px 34px;
            border-radius: 999px;
            border: 1px solid rgba(255,255,255,0.28);
            background: rgba(255,255,255,0.16);
            color: #fff;
            font-size: 13px;
            outline: none;
            transition: background 0.2s ease, border 0.2s ease, box-shadow 0.2s ease;
        }
        #globalSearchInput::placeholder { color: rgba(255,255,255,0.72); }
        #globalSearchInput:focus {
            background: rgba(255,255,255,0.96);
            color: #1f2937;
            border-color: #fff;
            box-shadow: 0 8px 24px rgba(15, 23, 42, 0.18);
        }
        #globalSearchInput:focus::placeholder { color: #9ca3af; }
        .global-search-panel {
            display: none;
            position: absolute;
            top: calc(100% + 8px);
            left: 0;
            right: 0;
            max-height: 420px;
            overflow-y: auto;
            background: #fff;
            border: 1px solid #e5e7eb;
            border-radius: 14px;
            box-shadow: 0 20px 48px rgba(15, 23, 42, 0.22);
            padding: 6px;
            z-index: 200;
            animation: fadeIn 0.18s ease;
        }
        .global-search-panel.show { display: block; }
        .gs-item {
            display: block;
            width: 100%;
            text-align: left;
            padding: 9px 12px;
            border: none;
            background: transparent;
            border-radius: 10px;
            cursor: pointer;
            transition: background 0.15s ease;
        }
        .gs-item:hover, .gs-item.active { background: #eef2ff; }
        .gs-item .gs-module {
            font-size: 11px;
            color: #6366f1;
            font-weight: 700;
        }
        .gs-item .gs-title {
            font-size: 13px;
            color: #111827;
            font-weight: 600;
            margin: 2px 0;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }
        .gs-item .gs-snippet {
            font-size: 12px;
            color: #6b7280;
            display: -webkit-box;
            -webkit-line-clamp: 1;
            -webkit-box-orient: vertical;
            overflow: hidden;
        }
        .gs-empty { padding: 16px; text-align: center; color: #9ca3af; font-size: 13px; }
        @media (max-width: 900px) {
            .global-search { max-width: none; margin: 8px 0; flex-basis: 100%; order: 3; }
            .top-nav { flex-wrap: wrap; }
        }

        .top-nav .logo {
            display: flex;
            align-items: center;
            gap: 12px;
            position: relative;
            z-index: 1;
        }
        
        .top-nav .logo img {
            height: 40px;
        }
        
        .top-nav .logo-text {
            font-size: 18px;
            font-weight: 700;
            letter-spacing: 0.02em;
            text-shadow: 0 2px 12px rgba(0,0,0,0.18);
        }
        
        .top-nav .nav-links {
            display: flex;
            align-items: center;
            gap: 8px;
            position: relative;
            z-index: 1;
            white-space: nowrap;
        }
        
        .top-nav .nav-links a {
            color: rgba(255,255,255,0.92);
            text-decoration: none;
            font-size: 14px;
            padding: 8px 14px;
            border-radius: 999px;
            transition: background 0.25s, transform 0.25s, color 0.25s;
        }
        
        .top-nav .nav-links a:hover {
            background: rgba(255,255,255,0.16);
            transform: translateY(-1px);
            text-decoration: none;
        }
        .global-notice-wrap { position: relative; display: inline-flex; align-items: center; margin-left: 6px; z-index: 1100; }
        .global-notice-bell {
            position: relative; width: 38px; height: 38px; border-radius: 10px; border: 1px solid rgba(255,255,255,0.18);
            background: rgba(255,255,255,0.08); color: #fff; cursor: pointer;
            display: inline-flex; align-items: center; justify-content: center; font-size: 16px;
        }
        .global-notice-bell:hover { background: rgba(255,255,255,0.16); transform: translateY(-1px); }
        .global-notice-badge {
            position: absolute; top: -4px; right: -4px; min-width: 18px; height: 18px; padding: 0 5px;
            border-radius: 999px; background: #ef4444; color: #fff; font-size: 11px; font-weight: 800;
            display: none; align-items: center; justify-content: center; line-height: 1;
            box-shadow: 0 0 0 2px rgba(76,29,149,0.9);
        }
        .global-notice-badge.show { display: inline-flex; }
        .global-notice-panel {
            display: none; position: fixed; width: 380px; max-width: calc(100vw - 24px);
            background: #fff; color: #111827; border-radius: 14px; border: 1px solid #e5e7eb;
            box-shadow: 0 18px 40px rgba(15,23,42,0.22); z-index: 3000; overflow: hidden;
        }
        .global-notice-panel.open { display: block; animation: chatBubbleIn 0.2s ease both; }
        .global-notice-panel-head {
            display: flex; justify-content: space-between; align-items: center; gap: 8px;
            padding: 12px 14px; border-bottom: 1px solid #f1f5f9; background: linear-gradient(135deg,#eef2ff,#fff);
        }
        .global-notice-panel-head strong { font-size: 14px; color: #312e81; }
        .global-notice-panel-list { max-height: 420px; overflow: auto; }
        .global-notice-item {
            padding: 12px 14px; border-bottom: 1px solid #f8fafc; cursor: pointer; transition: background 0.15s;
        }
        .global-notice-item:hover { background: #eef2ff; }
        .global-notice-item.unread .title { font-weight: 800; color: #111827; }
        .global-notice-item .title { font-size: 13px; color: #334155; margin-bottom: 4px; }
        .global-notice-item .meta { font-size: 11px; color: #94a3b8; display: flex; gap: 8px; flex-wrap: wrap; }
        .global-notice-item .loc {
            margin-top: 6px; font-size: 11px; font-weight: 700; color: #4f46e5;
            display: inline-flex; align-items: center; gap: 4px;
        }
        .global-notice-empty { padding: 28px 16px; text-align: center; color: #94a3b8; font-size: 13px; }
        .global-notice-empty .btn { margin-top: 10px; }
        .home-notice-banner {
            display: none; margin-bottom: 18px; border-radius: 4px; padding: 14px 18px;
            background: #fffaf8; border: 1px solid #f0d9d0; border-left: 3px solid #9a3412;
        }
        .home-notice-banner.show { display: block; }
        .home-notice-banner .row { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; flex-wrap: wrap; }
        .home-notice-banner .label { font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: #9a3412; margin-bottom: 4px; }
        .home-notice-banner .title { font-family: 'Noto Serif SC', serif; font-size: 16px; font-weight: 700; color: #1c1917; }
        .home-notice-banner .desc { font-size: 12px; color: #78716c; margin-top: 4px; line-height: 1.55; }

        /* 首页工作台 · 欢迎概览 + 统计 + 快捷 + 三栏 */
        .main-content:has(> #home.active) { padding: 10px 12px 92px; }
        #home.module {
            --home-ink: #1e1b4b;
            --home-muted: #6b7280;
            --home-line: #e9e4f8;
            --home-accent: #7c3aed;
            --home-accent-deep: #5b21b6;
            --home-soft: #f5f3ff;
            --home-serif: 'Noto Serif SC', 'Songti SC', serif;
            --home-sans: 'Outfit', 'PingFang SC', 'Microsoft YaHei', sans-serif;
            font-family: var(--home-sans);
            width: 100%; max-width: none; margin: 0; padding: 0; box-sizing: border-box;
            background: linear-gradient(180deg, #faf8ff 0%, #f8f7fc 50%, #f3f0ff 100%);
            border-radius: 8px;
        }
        .home-dashboard { display: flex; flex-direction: column; gap: 10px; width: 100%; box-sizing: border-box; }
        .home-hero {
            position: relative; border-radius: 10px; overflow: hidden;
            background: linear-gradient(135deg, rgba(255,255,255,0.55), rgba(255,255,255,0.15)),
                linear-gradient(118deg, #ede9fe 0%, #e0e7ff 48%, #ddd6fe 100%);
            color: #4c1d95; border: 1px solid #e9e4f8; box-shadow: 0 8px 22px rgba(167, 139, 250, 0.12);
        }
        .home-hero::after {
            content: ''; position: absolute; inset: 0; pointer-events: none; opacity: 0.9;
            background-image: linear-gradient(rgba(124,58,237,0.04) 1px, transparent 1px),
                linear-gradient(90deg, rgba(124,58,237,0.04) 1px, transparent 1px);
            background-size: 22px 22px;
        }
        .home-hero-inner {
            position: relative; z-index: 1; display: flex; align-items: stretch;
            justify-content: space-between; gap: 16px; padding: 16px 18px; flex-wrap: wrap;
        }
        .home-hero-main { display: flex; align-items: center; gap: 14px; flex: 1 1 380px; min-width: 0; }
        .home-hero-avatar {
            width: 60px; height: 60px; border-radius: 50%; flex-shrink: 0;
            background: linear-gradient(145deg, #a78bfa, #818cf8); color: #fff;
            font-size: 22px; font-weight: 700; display: flex; align-items: center; justify-content: center;
            overflow: hidden; border: 2px solid rgba(255,255,255,0.85);
            box-shadow: 0 6px 16px rgba(139, 92, 246, 0.2);
        }
        .home-hero-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
        .home-eyebrow { font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: #8b5cf6; font-weight: 650; margin-bottom: 4px; }
        .home-hero h2 { margin: 0; font-family: var(--home-serif); font-size: 26px; font-weight: 700; color: #4c1d95; line-height: 1.25; }
        .home-hero .sub { margin-top: 4px; font-size: 13px; line-height: 1.5; color: #6d28d9; }
        .home-hero-meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
        .home-chip {
            display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 999px;
            background: rgba(255,255,255,0.72); border: 1px solid #ddd6fe; font-size: 12px; color: #5b21b6; font-weight: 500;
        }
        .home-chip strong { color: #7c3aed; font-weight: 700; font-variant-numeric: tabular-nums; }
        .home-chip.warn { border-color: #fdba74; background: #fff7ed; color: #c2410c; }
        .home-chip.warn strong { color: #ea580c; }
        .home-hero-aside { flex: 0 1 280px; display: flex; flex-direction: column; gap: 8px; min-width: 220px; }
        .home-quick-launch { display: flex; flex-wrap: wrap; gap: 6px; }
        .home-quick-launch button {
            border: 1px solid #ddd6fe; background: #fff; color: #6d28d9; border-radius: 999px;
            padding: 6px 12px; font-size: 12px; font-weight: 650; cursor: pointer;
        }
        .home-quick-launch button:hover { background: #f5f3ff; border-color: #c4b5fd; }
        .home-ring-card {
            background: rgba(255,255,255,0.75); border: 1px solid #e9e4f8; border-radius: 8px;
            padding: 10px 12px; display: flex; align-items: center; gap: 12px;
        }
        .home-ring-card .label { font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase; color: #8b5cf6; font-weight: 650; margin-bottom: 6px; }
        .home-ring-svg { width: 72px; height: 72px; flex-shrink: 0; }
        .home-ring-legend { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
        .home-ring-legend button {
            display: flex; justify-content: space-between; gap: 8px; width: 100%;
            border: 0; background: transparent; padding: 2px 0; cursor: pointer; font-size: 12px; color: #5b21b6;
        }
        .home-ring-legend button:hover { color: #7c3aed; }
        .home-ring-legend .dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; margin-right: 6px; }

        .home-ledger-wrap {
            display: flex; flex-direction: column; gap: 8px; width: 100%;
        }
        .home-ledger-toolbar {
            display: flex; align-items: center; justify-content: space-between; gap: 12px;
            padding: 0 2px;
        }
        .home-ledger-title {
            font-size: 12px; font-weight: 750; letter-spacing: 0.04em; color: var(--home-muted);
        }
        .home-year-scope {
            display: inline-flex; border: 1px solid var(--home-line); border-radius: 8px;
            overflow: hidden; background: #fff;
        }
        .home-year-scope button {
            border: 0; background: transparent; padding: 5px 12px; font-size: 12px;
            font-weight: 650; color: #64748b; cursor: pointer;
        }
        .home-year-scope button + button { border-left: 1px solid var(--home-line); }
        .home-year-scope button.active {
            background: #f5f3ff; color: #5b21b6;
        }
        .home-year-scope button:hover { color: #5b21b6; }

        .home-ledger {
            display: flex !important; flex-direction: row !important; flex-wrap: nowrap; width: 100%;
            background: #fff; border: 1px solid var(--home-line); border-radius: 10px; overflow: hidden;
            box-shadow: 0 8px 20px rgba(76, 29, 149, 0.06);
        }
        .home-stat {
            position: relative; flex: 1 1 0; min-width: 0; padding: 12px 10px 10px;
            cursor: pointer; border-right: 1px solid var(--home-line); transition: background 0.15s;
        }
        .home-stat:last-child { border-right: 0; }
        .home-stat.is-hidden { display: none; }
        .home-stat::before { content: ''; position: absolute; left: 0; top: 0; right: 0; height: 3px; background: #c4b5fd; }
        .home-stat.accent-a::before { background: #7c3aed; }
        .home-stat.accent-b::before { background: #6366f1; }
        .home-stat.accent-c::before { background: #8b5cf6; }
        .home-stat.accent-d::before { background: #a855f7; }
        .home-stat.accent-e::before { background: #4f46e5; }
        .home-stat.accent-f::before { background: #db2777; }
        .home-stat:hover { background: #faf8ff; }
        .home-stat .k { font-size: 11px; color: var(--home-muted); font-weight: 700; letter-spacing: 0.06em; }
        .home-stat .v {
            margin-top: 8px; font-family: var(--home-serif); font-size: 26px; font-weight: 700;
            color: var(--home-ink); line-height: 1; font-variant-numeric: tabular-nums;
        }
        .home-stat .h { margin-top: 6px; font-size: 11px; color: #94a3b8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
        .home-stat .delta { color: #16a34a; font-weight: 650; }
        .home-stat .delta.neg { color: #dc2626; }
        .home-stat .delta.flat { color: #94a3b8; }

        .home-quick {
            display: flex !important; flex-direction: row !important; flex-wrap: nowrap; align-items: stretch;
            gap: 8px; width: 100%; padding: 10px; box-sizing: border-box; border-radius: 10px;
            background: rgba(255,255,255,0.9); border: 1px solid var(--home-line);
        }
        .home-quick-label {
            flex: 0 0 auto; display: flex; align-items: center; font-size: 11px; letter-spacing: 0.1em;
            text-transform: uppercase; color: var(--home-muted); font-weight: 750; padding: 0 4px;
        }
        .home-quick-item {
            position: relative; flex: 1 1 0; min-width: 0;
            display: flex; flex-direction: column; align-items: flex-start; justify-content: center;
            gap: 6px; padding: 10px 12px; border: 1px solid #e9e4f8; border-radius: 8px; background: #fff;
            cursor: pointer; transition: all 0.15s; color: #334155; font-weight: 650;
        }
        .home-quick-item:hover { border-color: #c4b5fd; color: var(--home-accent-deep); background: #f5f3ff; transform: translateY(-1px); }
        .home-quick-item .ico {
            display: inline-flex; align-items: center; justify-content: center;
            width: 26px; height: 26px; border-radius: 7px; font-size: 12px; font-weight: 800;
            background: linear-gradient(135deg, #7c3aed, #4f46e5); color: #ede9fe;
        }
        .home-quick-item .t { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
        .home-quick-badge {
            position: absolute; top: 6px; right: 8px; min-width: 16px; height: 16px; padding: 0 4px;
            border-radius: 999px; background: #e11d48; color: #fff; font-size: 10px; font-weight: 700;
            display: inline-flex; align-items: center; justify-content: center; line-height: 1;
        }

        .home-grid { display: flex !important; flex-direction: row !important; align-items: stretch; gap: 10px; width: 100%; min-height: 440px; }
        .home-col { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
        .home-panel {
            flex: 1 1 0; min-height: 200px; background: #fff; border: 1px solid var(--home-line);
            border-radius: 10px; overflow: hidden; box-shadow: 0 8px 18px rgba(76, 29, 149, 0.05);
            display: flex; flex-direction: column;
        }
        .home-panel-hd {
            display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap;
            padding: 10px 12px; border-bottom: 1px solid var(--home-line);
            background: linear-gradient(180deg, #faf8ff, #fff); flex-shrink: 0;
        }
        .home-panel-hd h3 {
            margin: 0; font-family: var(--home-serif); font-size: 15px; font-weight: 700; color: var(--home-ink);
            display: flex; align-items: center; gap: 8px;
        }
        .home-panel-hd h3::before { content: ''; width: 3px; height: 13px; border-radius: 2px; background: var(--home-accent); }
        .home-panel-hd .link { border: 0; background: transparent; color: var(--home-accent-deep); font-size: 12px; font-weight: 650; cursor: pointer; }
        .home-tabs { display: flex; flex-wrap: wrap; gap: 4px; padding: 8px 10px 0; }
        .home-tab {
            border: 1px solid #e9e4f8; background: #fff; color: #64748b; border-radius: 999px;
            padding: 3px 10px; font-size: 11px; font-weight: 650; cursor: pointer;
        }
        .home-tab.active { background: #f5f3ff; border-color: #c4b5fd; color: #6d28d9; }
        .home-member-search {
            width: 100%; box-sizing: border-box; margin: 8px 10px 0; padding: 7px 10px;
            border: 1px solid #e9e4f8; border-radius: 8px; font-size: 12px; outline: none;
        }
        .home-member-search:focus { border-color: #c4b5fd; box-shadow: 0 0 0 3px rgba(124,58,237,0.1); }
        .home-panel-bd { padding: 4px 8px 8px; flex: 1; overflow: auto; }
        .home-empty {
            min-height: 120px; display: flex; align-items: center; justify-content: center;
            text-align: center; color: #94a3b8; font-size: 13px; line-height: 1.6; padding: 20px;
        }
        .home-todo-item, .home-feed-item, .home-member-item {
            display: flex; gap: 10px; align-items: flex-start; padding: 11px 8px;
            border-radius: 6px; cursor: pointer; transition: background 0.15s; border-bottom: 1px solid #f1eef9;
        }
        .home-todo-item:last-child, .home-feed-item:last-child, .home-member-item:last-child { border-bottom: 0; }
        .home-todo-item:hover, .home-feed-item:hover, .home-member-item:hover { background: var(--home-soft); }
        .home-todo-item.is-urgent { background: #fff7f7; }
        .home-todo-item .pri { flex-shrink: 0; margin-top: 2px; font-size: 10px; font-weight: 750; padding: 3px 7px; border-radius: 4px; }
        .home-todo-item .pri.high { background: #fef2f2; color: #b91c1c; }
        .home-todo-item .pri.medium { background: #fff7ed; color: #c2410c; }
        .home-todo-item .pri.low { background: #f0fdf4; color: #15803d; }
        .home-todo-item .title, .home-feed-item .title { font-size: 13px; font-weight: 650; color: #1e293b; line-height: 1.4; }
        .home-todo-item .meta, .home-feed-item .meta { margin-top: 4px; font-size: 11px; color: #94a3b8; }
        .home-todo-item .meta.due-soon { color: #ea580c; font-weight: 650; }
        .home-todo-actions { display: none; gap: 6px; margin-top: 6px; }
        .home-todo-item:hover .home-todo-actions { display: flex; }
        .home-todo-actions button {
            border: 1px solid #e2e8f0; background: #fff; border-radius: 6px; padding: 3px 8px;
            font-size: 11px; font-weight: 650; cursor: pointer;
        }
        .home-todo-actions .ok { color: #16a34a; border-color: #bbf7d0; }
        .home-todo-actions .bad { color: #dc2626; border-color: #fecaca; }
        .home-feed-item { position: relative; padding-left: 20px; }
        .home-feed-item.is-read { opacity: 0.62; }
        .home-feed-item.is-read .home-feed-dot { background: #cbd5e1; box-shadow: none; }
        .home-feed-item.is-urgent .title { color: #b91c1c; }
        .home-feed-dot {
            position: absolute; left: 6px; top: 16px; width: 8px; height: 8px; border-radius: 50%;
            background: #3b82f6; box-shadow: 0 0 0 3px rgba(59,130,246,0.16);
        }
        .home-feed-tag {
            display: inline-block; margin-right: 6px; padding: 1px 6px; border-radius: 4px;
            font-size: 10px; font-weight: 700; background: #f5f3ff; color: #6d28d9;
        }
        .home-member-item { align-items: center; }
        .home-member-item .av {
            width: 36px; height: 36px; border-radius: 50%; flex-shrink: 0;
            background: linear-gradient(145deg, #5b21b6, #7c3aed); color: #ede9fe;
            display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700;
            overflow: hidden; border: 2px solid #fff; box-shadow: 0 0 0 1px #ddd6fe;
        }
        .home-member-item .av img { width: 100%; height: 100%; object-fit: cover; display: block; }
        .home-member-item .name { font-size: 13px; font-weight: 700; color: #1e293b; }
        .home-member-item .tag { font-size: 11px; color: #64748b; margin-top: 2px; }
        .home-member-item .badge { margin-left: auto; font-size: 11px; padding: 2px 8px; border-radius: 4px; white-space: nowrap; }
        .home-member-item .badge.on { background: #f5f3ff; color: #6d28d9; }
        .home-member-item .badge.off { background: #f1f5f9; color: #64748b; }
        .home-foot-note {
            display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap;
            padding: 8px 12px; border-radius: 8px; font-size: 12px; color: #64748b;
            background: rgba(255,255,255,0.8); border: 1px dashed #ddd6fe;
        }
        .home-foot-note strong { color: #5b21b6; font-weight: 700; }

        .nav-sync-chip {
            display: inline-flex; align-items: center; gap: 6px; margin-right: 6px; padding: 5px 10px;
            border-radius: 999px; border: 1px solid rgba(255,255,255,0.28); background: rgba(255,255,255,0.12);
            color: rgba(255,255,255,0.92); font-size: 11px; font-weight: 650; cursor: pointer; white-space: nowrap;
        }
        .nav-sync-chip:hover { background: rgba(255,255,255,0.2); }
        .nav-sync-chip .dot { width: 7px; height: 7px; border-radius: 50%; background: #fbbf24; }
        .nav-sync-chip.is-ok .dot { background: #4ade80; }
        .nav-sync-chip.is-bad .dot { background: #fb7185; }
        .nav-sync-chip.is-syncing .dot { background: #93c5fd; animation: homeSyncPulse 1s ease-in-out infinite; }
        @keyframes homeSyncPulse { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }

        /* 云端自动同步：隐藏手动同步入口，后台静默推送/拉取 */
        .cloud-sync-fab,
        .nav-sync-chip {
            display: none !important;
        }

        .cloud-sync-fab {
            position: fixed; right: 24px; bottom: 28px; z-index: 1210;
            display: inline-flex; align-items: center; gap: 8px; padding: 11px 16px;
            border: 1px solid #ddd6fe; border-radius: 999px; background: #fff; color: #5b21b6;
            font-size: 13px; font-weight: 700; cursor: pointer;
            box-shadow: 0 12px 28px rgba(91, 33, 182, 0.18);
            transition: transform 0.15s, box-shadow 0.15s;
        }
        .cloud-sync-fab:hover { transform: translateY(-1px); box-shadow: 0 14px 32px rgba(91, 33, 182, 0.24); }
        .cloud-sync-fab .fab-dot { width: 9px; height: 9px; border-radius: 50%; background: #fbbf24; }
        .cloud-sync-fab.is-ok .fab-dot { background: #22c55e; }
        .cloud-sync-fab.is-bad .fab-dot { background: #ef4444; }
        .cloud-sync-fab.is-syncing .fab-dot { background: #3b82f6; animation: homeSyncPulse 1s ease-in-out infinite; }
        .cloud-sync-fab .fab-sub { font-size: 11px; font-weight: 500; color: #64748b; }

        @media (max-width: 1100px) {
            .home-ledger { flex-wrap: wrap; }
            .home-stat { flex: 1 1 33.33%; border-bottom: 1px solid var(--home-line); }
            .home-stat:nth-child(3n) { border-right: 0; }
            .home-quick { flex-wrap: wrap; }
            .home-quick-label { flex: 1 1 100%; }
            .home-quick-item { flex: 1 1 30%; }
            .home-grid { flex-direction: column; min-height: 0; }
        }
        @media (max-width: 700px) {
            .home-stat { flex: 1 1 50%; }
            .home-stat:nth-child(2n) { border-right: 0; }
            .home-quick-item { flex: 1 1 45%; }
            .cloud-sync-fab { right: 12px; bottom: 16px; }
        }

        .home-quick-toolbar {
            display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
            padding: 0 2px;
        }
        .home-quick-toolbar button {
            border: 1px solid #e9e4f8; background: #fff; color: #6d28d9;
            border-radius: 999px; padding: 5px 12px; font-size: 12px; font-weight: 650; cursor: pointer;
        }
        .home-quick-toolbar button:hover { background: #f5f3ff; border-color: #c4b5fd; }
        .home-dashboard.is-compact .home-hero-inner { padding: 12px 14px; }
        .home-dashboard.is-compact .home-stat .v { font-size: 22px; }
        .home-dashboard.is-compact .home-grid { min-height: 360px; }
        .home-modal-mask {
            display: none; position: fixed; inset: 0; z-index: 13000;
            background: rgba(15, 23, 42, 0.45); align-items: center; justify-content: center; padding: 16px;
        }
        .home-modal {
            width: min(560px, 100%); max-height: min(80vh, 720px); overflow: auto;
            background: #fff; border-radius: 14px; border: 1px solid #e9e4f8;
            box-shadow: 0 24px 60px rgba(76, 29, 149, 0.22); padding: 16px 18px 18px;
        }
        .home-modal h3 { margin: 0 0 8px; font-size: 17px; color: #4c1d95; }
        .home-modal .desc { font-size: 12px; color: #64748b; margin-bottom: 12px; line-height: 1.5; }
        .home-modal-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; margin-top: 14px; }
        .home-modal-actions button {
            border: 1px solid #e2e8f0; background: #fff; border-radius: 8px;
            padding: 7px 14px; font-size: 13px; font-weight: 650; cursor: pointer;
        }
        .home-modal-actions .primary { background: #7c3aed; border-color: #7c3aed; color: #fff; }
        .home-customize-row {
            display: flex; align-items: center; gap: 10px; padding: 8px 10px;
            border: 1px solid #f1eef9; border-radius: 8px; margin-bottom: 6px; cursor: default;
        }
        .home-customize-row .ico {
            width: 24px; height: 24px; border-radius: 6px; display: inline-flex; align-items: center; justify-content: center;
            background: #f5f3ff; color: #6d28d9; font-size: 12px; font-weight: 800;
        }
        .home-customize-row .t { flex: 1; font-size: 13px; color: #334155; font-weight: 650; }
        .home-customize-row .ops button {
            border: 1px solid #e2e8f0; background: #fff; border-radius: 6px; width: 28px; height: 28px; cursor: pointer;
        }
        .home-sync-log-head {
            display: grid; gap: 4px; padding: 10px 12px; border-radius: 8px; background: #faf8ff;
            border: 1px solid #e9e4f8; margin-bottom: 10px; font-size: 12px; color: #64748b;
        }
        .home-sync-log-head .ok { color: #16a34a; }
        .home-sync-log-head .bad { color: #dc2626; }
        .home-sync-log-item {
            padding: 8px 10px; border-radius: 8px; border: 1px solid #f1eef9; margin-bottom: 6px;
        }
        .home-sync-log-item.ok { border-left: 3px solid #22c55e; }
        .home-sync-log-item.bad { border-left: 3px solid #ef4444; background: #fff7f7; }
        .home-sync-log-item .t { font-size: 12px; font-weight: 700; color: #334155; }
        .home-sync-log-item .m { font-size: 11px; color: #94a3b8; margin-top: 2px; }
        .home-foot-extra a { color: #6d28d9; font-weight: 650; text-decoration: none; }
        .home-foot-extra a:hover { text-decoration: underline; }
        .cloud-sync-fab .fab-menu {
            position: absolute; right: 0; bottom: calc(100% + 8px); min-width: 140px;
            background: #fff; border: 1px solid #e9e4f8; border-radius: 10px; padding: 6px;
            box-shadow: 0 12px 28px rgba(91,33,182,0.18); display: none;
        }
        .cloud-sync-fab:hover .fab-menu, .cloud-sync-fab:focus-within .fab-menu { display: block; }
        .cloud-sync-fab .fab-menu button {
            display: block; width: 100%; text-align: left; border: 0; background: transparent;
            padding: 8px 10px; border-radius: 6px; font-size: 12px; color: #5b21b6; cursor: pointer; font-weight: 650;
        }
        .cloud-sync-fab .fab-menu button:hover { background: #f5f3ff; }

        .notice-stat-card {
            background: #fff; padding: 20px; border-radius: 12px; box-shadow: 0 1px 3px rgba(0,0,0,0.05);
            cursor: pointer; transition: all 0.18s ease; border: 2px solid transparent;
        }
        .notice-stat-card:hover { transform: translateY(-2px); box-shadow: 0 8px 18px rgba(15,23,42,0.08); }
        .notice-stat-card.active { border-color: #818cf8; background: #eef2ff; }
        @media (max-width: 1100px) {
            .notice-stat-grid { grid-template-columns: repeat(2, 1fr) !important; }
        }
        @media (max-width: 640px) {
            .notice-stat-grid { grid-template-columns: 1fr !important; }
        }
        .notice-unread-dot {
            width: 8px; height: 8px; border-radius: 50%; background: #3b82f6; display: inline-block; margin-right: 6px;
            box-shadow: 0 0 0 3px rgba(59,130,246,0.18);
        }
        .notice-read-panel { margin-top: 18px; border: 1px solid #e5e7eb; border-radius: 12px; overflow: hidden; }
        .notice-read-panel-head {
            display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap;
            padding: 12px 14px; background: #f8fafc; border-bottom: 1px solid #eef2ff;
        }
        .notice-read-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 0; }
        @media (max-width: 640px) { .notice-read-cols { grid-template-columns: 1fr; } }
        .notice-read-col { padding: 12px 14px; min-height: 0; }
        .notice-read-col + .notice-read-col { border-left: 1px solid #eef2ff; }
        @media (max-width: 640px) { .notice-read-col + .notice-read-col { border-left: none; border-top: 1px solid #eef2ff; } }
        .notice-read-col h4 { margin: 0 0 10px; font-size: 13px; color: #334155; }
        .notice-read-col ul { list-style: none; margin: 0; padding: 0; max-height: 320px; overflow: auto; }
        .notice-read-col li {
            font-size: 12px; color: #475569; padding: 7px 8px; border-radius: 8px; margin-bottom: 4px;
            background: #fff; border: 1px solid #f1f5f9; display: flex; justify-content: space-between; gap: 8px;
        }
        .notice-read-col li.unread { background: #fff7ed; border-color: #fed7aa; color: #9a3412; }
        .notice-read-col li.read { background: #f0fdf4; border-color: #bbf7d0; color: #166534; }
        
        /* 主容器 */
        .app-shell {
            display: flex;
            width: 100%;
            min-height: calc(100vh - 64px);
        }
        
        /* 左侧菜单 */
        .sidebar {
            width: 260px;
            flex-shrink: 0;
            display: flex;
            flex-direction: column;
            background: linear-gradient(180deg, rgba(255,255,255,0.92) 0%, rgba(250,248,255,0.88) 100%);
            backdrop-filter: blur(16px) saturate(140%);
            -webkit-backdrop-filter: blur(16px) saturate(140%);
            border-right: 1px solid rgba(167, 139, 250, 0.18);
            box-shadow: 8px 0 24px rgba(139, 92, 246, 0.05);
            padding: 12px 10px 10px;
            overflow: hidden;
            max-height: calc(100vh - 64px);
            height: calc(100vh - 64px);
            position: sticky;
            top: 64px;
            align-self: flex-start;
            box-sizing: border-box;
        }

        /* ===== 移动端适配：侧栏抽屉 + 汉堡 + 遮罩（行为全部锁在 @media 内，桌面零影响）===== */
        .sidebar-toggle {
            display: none;
            flex-shrink: 0;
            width: 38px; height: 38px;
            margin-right: 6px;
            border: 1px solid rgba(255, 255, 255, 0.35);
            border-radius: 10px;
            background: rgba(255, 255, 255, 0.12);
            color: #fff; font-size: 18px; line-height: 1;
            cursor: pointer;
            align-items: center; justify-content: center;
            transition: background 0.18s;
        }
        .sidebar-toggle:hover { background: rgba(255, 255, 255, 0.24); }
        .sidebar-backdrop {
            display: none;
            position: fixed;
            inset: 0;
            background: rgba(2, 8, 23, 0.5);
            -webkit-backdrop-filter: blur(2px);
            backdrop-filter: blur(2px);
            z-index: 1150;
            opacity: 0;
            transition: opacity 0.28s ease;
        }
        @media (max-width: 768px) {
            .sidebar-toggle { display: inline-flex; }
            /* 隐藏桌面装饰层，避免极窄屏下装饰造成横向溢出，兼顾性能 */
            body::before, body::after { display: none; }
            .sidebar {
                position: fixed;
                left: 0; top: 0;
                height: 100vh; height: 100dvh;
                max-height: none;
                width: 264px; max-width: 84vw;
                transform: translateX(-100%);
                transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
                z-index: 1200;
                box-shadow: 12px 0 44px rgba(2, 8, 23, 0.4);
            }
            .app-shell.sidebar-open .sidebar { transform: translateX(0); }
            .app-shell.sidebar-open .sidebar-backdrop { display: block; opacity: 1; }
            .main-content { padding: 16px 14px; }
            .top-nav { flex-wrap: wrap; row-gap: 8px; padding: 10px 12px; }
            .top-nav .nav-links { flex-wrap: wrap; }
            .top-nav .nav-links > a[data-portal] { display: none; }
            .logo-text { display: none; }
            .global-search { flex: 1 1 160px; min-width: 0; }
        }

        .sidebar-nav {
            flex: 1 1 auto;
            min-height: 0;
            overflow-y: auto;
            padding-right: 2px;
        }
        
        .nav-item {
            padding: 12px 16px;
            margin: 4px 0;
            cursor: pointer;
            transition: all 0.28s cubic-bezier(0.22, 1, 0.36, 1);
            border-left: 3px solid transparent;
            border-radius: 12px;
            display: flex;
            align-items: center;
            gap: 10px;
            color: #374151;
            position: relative;
            overflow: hidden;
        }
        
        .nav-item:hover {
            background: linear-gradient(90deg, rgba(124,58,237,0.10), rgba(124,58,237,0.03));
            border-left-color: var(--brand);
            transform: translateX(4px);
            color: var(--brand);
        }
        
        .nav-item.active {
            background: linear-gradient(90deg, rgba(124,58,237,0.16), rgba(79,70,229,0.06));
            border-left-color: var(--brand);
            color: var(--brand);
            font-weight: 600;
            box-shadow: inset 0 0 0 1px rgba(124,58,237,0.08);
            animation: softPulse 2.8s ease-in-out infinite;
        }
        
        /* 导航分类样式 */
        .nav-category {
            display: flex;
            justify-content: space-between;
            align-items: center;
            font-weight: 700;
            gap: 10px;
        }

        .nav-category .nav-label,
        .submenu .nav-item .nav-label {
            flex: 1;
            min-width: 0;
        }

        /* 侧栏未读角标：折叠时父级「公告动态」也能看见 */
        .sidebar-unread-badge {
            display: none;
            min-width: 18px;
            height: 18px;
            padding: 0 6px;
            border-radius: 999px;
            background: #ef4444;
            color: #fff;
            font-size: 11px;
            font-weight: 800;
            line-height: 18px;
            text-align: center;
            flex-shrink: 0;
            box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.18);
        }
        .sidebar-unread-badge.show {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            animation: noticeBadgePulse 1.6s ease-in-out infinite;
        }
        @keyframes noticeBadgePulse {
            0%, 100% { transform: scale(1); box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.18); }
            50% { transform: scale(1.08); box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.28); }
        }
        
        /* 子菜单样式 */
        .submenu {
            display: none;
            padding-left: 10px;
            background: transparent;
            overflow: hidden;
        }
        
        .submenu.show {
            display: block;
            animation: fadeIn 0.28s ease;
        }
        
        /* 子菜单切换按钮 */
        .submenu-toggle {
            font-size: 12px;
            transition: transform 0.3s;
            opacity: 0.7;
        }
        
        .submenu-toggle.rotated {
            transform: rotate(180deg);
        }
        
        /* 子菜单项样式 */
        .submenu .nav-item {
            font-size: 13px;
            padding-left: 28px;
            transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
        }
        
        .submenu .nav-item:hover {
            background: linear-gradient(90deg, rgba(124,58,237,0.12), rgba(79,70,229,0.04));
            transform: translateX(6px);
            box-shadow: 0 8px 18px rgba(124, 58, 237, 0.08);
        }
        
        .submenu .nav-item.active {
            background: linear-gradient(90deg, rgba(124,58,237,0.18), rgba(79,70,229,0.08));
            border-left-color: var(--brand);
            box-shadow: inset 0 0 0 1px rgba(124,58,237,0.1), 0 10px 22px rgba(124, 58, 237, 0.1);
            animation: softPulse 2.8s ease-in-out infinite;
        }
        .submenu .nav-item span:first-child {
            display: inline-flex;
            transition: transform 0.22s ease;
        }
        .submenu .nav-item:hover span:first-child,
        .submenu .nav-item.active span:first-child {
            transform: scale(1.12) translateY(-1px);
        }
        .chat-hero {
            position: relative;
            overflow: hidden;
            border-radius: 18px;
            padding: 18px 20px;
            margin-bottom: 18px;
            color: #312e81;
            background:
                radial-gradient(circle at top right, rgba(129, 140, 248, 0.28), transparent 46%),
                linear-gradient(135deg, #eef2ff 0%, #f5f3ff 55%, #ffffff 100%);
            border: 1px solid #e0e7ff;
            box-shadow: 0 14px 34px rgba(79, 70, 229, 0.08);
        }
        .chat-hero::after {
            content: '';
            position: absolute;
            inset: 0;
            background: linear-gradient(110deg, transparent 20%, rgba(255,255,255,0.45) 48%, transparent 72%);
            transform: translateX(-120%);
            animation: shimmerSweep 5.2s ease-in-out infinite;
            pointer-events: none;
        }
        .chat-stat-card {
            background: linear-gradient(180deg, #ffffff, #f8fafc);
            border: 1px solid #e5e7eb;
            border-radius: 14px;
            padding: 14px 16px;
            transition: transform 0.2s ease, box-shadow 0.2s ease;
            animation: fadeIn 0.4s ease both;
        }
        .chat-stat-card:hover {
            transform: translateY(-3px);
            box-shadow: 0 14px 28px rgba(15, 23, 42, 0.08);
        }

        /* ===== 文献对比分析 ===== */
        .lit-hero {
            position: relative; overflow: hidden; border-radius: 16px; padding: 16px 18px; margin-bottom: 16px;
            background: radial-gradient(circle at top right, rgba(129,140,248,0.25), transparent 46%), linear-gradient(135deg, #eef2ff 0%, #f5f3ff 55%, #fff 100%);
            border: 1px solid #e0e7ff;
        }
        .lit-hero::after {
            content: ''; position: absolute; inset: 0;
            background: linear-gradient(110deg, transparent 20%, rgba(255,255,255,0.4) 48%, transparent 72%);
            transform: translateX(-120%); animation: shimmerSweep 5.2s ease-in-out infinite; pointer-events: none;
        }
        .lit-badge { display: inline-flex; align-items: center; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; color: #4f46e5; background: #eef2ff; border: 1px solid #c7d2fe; }
        .lit-layout { display: grid; grid-template-columns: minmax(300px, 0.95fr) minmax(0, 1.35fr); gap: 16px; align-items: stretch; min-height: 620px; }
        @media (max-width: 1100px) { .lit-layout { grid-template-columns: 1fr; } }
        .lit-left, .lit-right { border: 1px solid #e5e7eb; border-radius: 16px; background: linear-gradient(180deg, #fff, #fafafa); display: flex; flex-direction: column; min-height: 560px; overflow: hidden; }
        .lit-left-head { padding: 12px 14px; border-bottom: 1px solid #eef2ff; }
        .lit-left > .form-control, .lit-chips, .lit-filters { margin-left: 12px; margin-right: 12px; }
        .lit-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; max-height: 72px; overflow-y: auto; }
        .lit-chip { border: 1px solid #ddd6fe; background: #fff; color: #5b21b6; border-radius: 999px; padding: 3px 10px; font-size: 12px; cursor: pointer; transition: all 0.15s ease; }
        .lit-chip span { color: #9ca3af; margin-left: 2px; }
        .lit-chip:hover, .lit-chip.active { background: #4f46e5; color: #fff; border-color: #4f46e5; }
        .lit-chip.active span, .lit-chip:hover span { color: rgba(255,255,255,0.8); }
        .lit-chip.lit-chip-add { border-style: dashed; background: #faf8ff; }
        .lit-filters { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 10px; }
        .lit-list { flex: 1; overflow-y: auto; padding: 0 12px 12px; max-height: 420px; }
        .lit-card { border: 1px solid #e5e7eb; border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; background: #fff; cursor: pointer; transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease; animation: chatBubbleIn 0.28s ease both; }
        .lit-card:hover { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(79,70,229,0.1); border-color: #c7d2fe; }
        .lit-card.selected { border-color: #7c3aed; background: linear-gradient(180deg, #f5f3ff, #fff); box-shadow: inset 3px 0 0 #7c3aed; }
        .lit-card.disabled { opacity: 0.55; }
        .lit-card-main { display: flex; gap: 8px; align-items: flex-start; }
        .lit-card-title { font-size: 13px; font-weight: 700; color: #111827; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.4; }
        .lit-card-meta { font-size: 12px; color: #6b7280; margin-top: 4px; }
        .lit-card-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
        .lit-card-tags span { font-size: 11px; color: #6366f1; background: #eef2ff; padding: 1px 6px; border-radius: 999px; }
        .lit-metrics { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
        .lit-metrics span { font-size: 11px; font-weight: 600; color: #0f766e; background: #ecfdf5; border: 1px solid #a7f3d0; padding: 1px 6px; border-radius: 6px; }
        .lit-card-actions { display: flex; gap: 6px; margin-top: 8px; justify-content: flex-end; }
        .lit-selection-bar { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; padding: 10px 12px; border-top: 1px solid #eef2ff; background: rgba(238,242,255,0.55); font-size: 12px; color: #4b5563; }
        .lit-tabs { display: flex; gap: 6px; padding: 10px 12px; border-bottom: 1px solid #eef2ff; background: #fafafa; flex-wrap: wrap; }
        .lit-tab { border: 1px solid transparent; background: transparent; color: #6b7280; border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 600; cursor: pointer; transition: all 0.15s ease; }
        .lit-tab:hover { background: #eef2ff; color: #4f46e5; }
        .lit-tab.active { background: #4f46e5; color: #fff; box-shadow: 0 8px 18px rgba(79,70,229,0.25); }
        .lit-pane { flex: 1; overflow: auto; padding: 12px; min-height: 480px; }
        .lit-empty, .lit-empty-pane { text-align: center; color: #9ca3af; padding: 48px 16px; font-size: 13px; }
        .lit-empty-ico { font-size: 40px; margin-bottom: 8px; }
        .lit-dim-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 10px; font-size: 12px; color: #4b5563; }
        .lit-dim-check { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
        .lit-table-wrap { overflow: auto; max-height: 520px; border: 1px solid #e5e7eb; border-radius: 12px; }
        .lit-compare-table { border-collapse: collapse; min-width: 720px; width: 100%; font-size: 12px; }
        .lit-compare-table th, .lit-compare-table td { border-bottom: 1px solid #f1f5f9; padding: 10px 12px; vertical-align: top; background: #fff; }
        .lit-compare-table thead th { position: sticky; top: 0; z-index: 2; background: linear-gradient(180deg, #f5f3ff, #eef2ff); color: #4c1d95; }
        .lit-compare-table .sticky-col { position: sticky; left: 0; z-index: 1; background: #fafafa; min-width: 110px; font-weight: 600; }
        .lit-compare-table thead .sticky-col { z-index: 3; background: #ede9fe; }
        .lit-th-sub { font-weight: 500; color: #6b7280; font-size: 11px; margin-top: 4px; max-width: 140px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
        .lit-cell-best { background: #ecfdf5 !important; color: #047857; font-weight: 700; }
        .lit-cell-gap { background: #fffbeb !important; color: #b45309; }
        .lit-legend { display: flex; gap: 10px; margin-top: 10px; font-size: 12px; }
        .lit-legend span { padding: 2px 8px; border-radius: 6px; }
        .lit-chart-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
        @media (max-width: 900px) { .lit-chart-grid { grid-template-columns: 1fr; } }
        .lit-chart-card { border: 1px solid #e5e7eb; border-radius: 14px; padding: 12px; background: #fff; }
        .lit-chart-title { font-size: 13px; font-weight: 700; color: #312e81; margin-bottom: 6px; }
        .lit-ai-toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
        .lit-ai-hint { font-size: 12px; color: #6b7280; margin-bottom: 10px; }
        .lit-ai-result { white-space: pre-wrap; line-height: 1.8; font-size: 13px; color: #1f2937; background: linear-gradient(180deg, #faf5ff, #fff); border: 1px solid #e9d5ff; border-radius: 12px; padding: 14px; }
        .lit-ai-placeholder, .lit-ai-loading, .lit-ai-error { border-radius: 12px; padding: 16px; font-size: 13px; }
        .lit-ai-placeholder { background: #f8fafc; border: 1px dashed #cbd5e1; color: #64748b; }
        .lit-ai-loading { background: #eef2ff; color: #4338ca; display: flex; align-items: center; gap: 10px; }
        .lit-ai-error { background: #fef2f2; border: 1px solid #fecaca; color: #b91c1c; }
        .lit-ai-meta { font-size: 12px; color: #9ca3af; margin-top: 8px; }
        .lit-ai-follow { display: flex; gap: 8px; margin-top: 12px; }
        .lit-timeline { position: relative; padding-left: 18px; }
        .lit-tl-item { position: relative; padding: 0 0 18px 18px; border-left: 2px solid #c7d2fe; }
        .lit-tl-item:last-child { border-left-color: transparent; }
        .lit-tl-year { position: absolute; left: -18px; top: 0; width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg, #7c3aed, #4f46e5); color: #fff; font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center; box-shadow: 0 8px 18px rgba(79,70,229,0.28); }
        .lit-tl-card { margin-left: 28px; border: 1px solid #e5e7eb; border-radius: 12px; padding: 12px; background: #fff; animation: chatBubbleIn 0.3s ease both; }
        .lit-tl-title { font-weight: 700; font-size: 14px; color: #111827; }
        .lit-tl-meta { font-size: 12px; color: #6b7280; margin: 4px 0; }
        .lit-tl-innov { font-size: 13px; color: #374151; line-height: 1.6; }
        .lit-tl-link { margin: 6px 0 0 46px; font-size: 12px; color: #7c3aed; }
        .lit-modal-overlay { position: fixed; inset: 0; background: rgba(15,23,42,0.45); z-index: 3000; display: flex; align-items: center; justify-content: center; padding: 16px; }
        .lit-modal { background: #fff; border-radius: 16px; width: 100%; max-width: 720px; max-height: 90vh; overflow: auto; box-shadow: 0 24px 60px rgba(15,23,42,0.22); }
        .lit-modal-head, .lit-modal-foot { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid #eef2ff; }
        .lit-modal-foot { border-bottom: none; border-top: 1px solid #eef2ff; justify-content: flex-end; gap: 8px; }
        .lit-modal-body { padding: 16px 18px; }
        .lit-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
        .lit-form-grid .full { grid-column: 1 / -1; }
        .lit-form-grid label { display: block; font-size: 12px; color: #4b5563; margin-bottom: 4px; }

        /* ===== 文档智能解析 ===== */
        .doc-hero {
            position: relative; overflow: hidden; border-radius: 16px; padding: 16px 18px; margin-bottom: 16px;
            background: radial-gradient(circle at top right, rgba(99,102,241,0.22), transparent 46%), linear-gradient(135deg, #eef2ff 0%, #f8fafc 60%, #fff 100%);
            border: 1px solid #e0e7ff;
        }
        .doc-hero::after {
            content: ''; position: absolute; inset: 0;
            background: linear-gradient(110deg, transparent 20%, rgba(255,255,255,0.42) 48%, transparent 72%);
            transform: translateX(-120%); animation: shimmerSweep 5.2s ease-in-out infinite; pointer-events: none;
        }
        .doc-status-pill {
            display: inline-flex; align-items: center; padding: 4px 10px; border-radius: 999px;
            font-size: 12px; font-weight: 700; color: #64748b; background: #f1f5f9; border: 1px solid #e2e8f0;
        }
        .doc-status-pill.busy { color: #4338ca; background: #eef2ff; border-color: #c7d2fe; }
        .doc-status-pill.ok { color: #047857; background: #ecfdf5; border-color: #a7f3d0; }
        .doc-status-pill.err { color: #b91c1c; background: #fef2f2; border-color: #fecaca; }
        .doc-layout {
            display: grid;
            grid-template-columns: minmax(240px, 0.78fr) minmax(0, 1.28fr) minmax(280px, 0.92fr);
            gap: 14px; min-height: 560px; align-items: stretch;
        }
        @media (max-width: 1280px) {
            .doc-layout { grid-template-columns: minmax(220px, 0.9fr) minmax(0, 1.4fr); }
            .doc-chat { grid-column: 1 / -1; min-height: 360px; }
        }
        @media (max-width: 900px) { .doc-layout { grid-template-columns: 1fr; } }
        .doc-left, .doc-right, .doc-chat {
            border: 1px solid #e5e7eb; border-radius: 16px; background: linear-gradient(180deg, #fff, #fafafa);
            padding: 14px; display: flex; flex-direction: column; min-height: 520px;
        }
        .doc-upload-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
        .doc-upload-row.doc-upload-row-3 { grid-template-columns: 1fr 1fr 1fr; }
        @media (max-width: 720px) { .doc-upload-row.doc-upload-row-3 { grid-template-columns: 1fr; } }
        @media (max-width: 520px) { .doc-upload-row { grid-template-columns: 1fr; } }
        .doc-upload-zone.folder.whole { border-color: #67e8f9; background: linear-gradient(180deg, #f0fdfa, #ecfeff); }
        .doc-upload-zone.folder.whole .doc-upload-title { color: #0e7490; }
        .doc-upload-zone.folder.whole:hover, .doc-upload-zone.folder.whole.dragover {
            border-color: #0891b2; box-shadow: 0 14px 28px rgba(8,145,178,0.14);
            background: linear-gradient(180deg, #ecfeff, #cffafe);
        }
        .doc-upload-zone {
            border: 2px dashed #c7d2fe; border-radius: 14px; padding: 22px 10px; text-align: center; cursor: pointer;
            background: linear-gradient(180deg, #f8fafc, #eef2ff); transition: all 0.2s ease;
        }
        .doc-upload-zone.folder { border-color: #99f6e4; background: linear-gradient(180deg, #f8fafc, #ecfdf5); }
        .doc-upload-zone:hover, .doc-upload-zone.dragover {
            border-color: #7c3aed; transform: translateY(-2px); box-shadow: 0 14px 28px rgba(79,70,229,0.12);
            background: linear-gradient(180deg, #eef2ff, #e0e7ff);
        }
        .doc-upload-zone.folder:hover, .doc-upload-zone.folder.dragover {
            border-color: #0d9488; box-shadow: 0 14px 28px rgba(13,148,136,0.12);
            background: linear-gradient(180deg, #ecfdf5, #ccfbf1);
        }
        .doc-upload-ico { font-size: 28px; margin-bottom: 6px; }
        .doc-upload-title { font-size: 13px; font-weight: 700; color: #312e81; }
        .doc-upload-zone.folder .doc-upload-title { color: #115e59; }
        .doc-upload-desc { font-size: 11px; color: #6b7280; margin-top: 4px; line-height: 1.5; }
        .doc-tips { margin-top: 12px; font-size: 12px; color: #6b7280; line-height: 1.8; background: #f8fafc; border-radius: 12px; padding: 10px 12px; border: 1px solid #eef2ff; }
        .doc-scan-report {
            font-size: 12px; line-height: 1.7; color: #334155; background: #fffbeb; border: 1px solid #fde68a;
            border-radius: 12px; padding: 10px 12px;
        }
        .doc-scan-report strong { color: #92400e; }
        .doc-scan-report .muted { color: #78716c; }
        .doc-lib-title { font-size: 12px; font-weight: 700; color: #64748b; margin-bottom: 8px; display: flex; justify-content: space-between; gap: 8px; }
        .doc-lib-item {
            display: flex; gap: 8px; align-items: flex-start; padding: 10px; border-radius: 10px; border: 1px solid #e5e7eb;
            background: #fff; cursor: pointer; margin-bottom: 8px; transition: all 0.15s ease;
        }
        .doc-lib-item:hover { border-color: #c7d2fe; background: #f8fafc; }
        .doc-lib-item.active { border-color: #6366f1; background: #eef2ff; box-shadow: 0 0 0 1px rgba(99,102,241,0.25); }
        .doc-lib-item.err { border-color: #fecaca; background: #fef2f2; }
        .doc-lib-item .name { font-size: 12px; font-weight: 700; color: #111827; word-break: break-all; line-height: 1.4; }
        .doc-lib-item .sub { font-size: 11px; color: #6b7280; margin-top: 2px; }
        .doc-lib-badge {
            flex-shrink: 0; font-size: 10px; font-weight: 700; padding: 2px 6px; border-radius: 999px;
            background: #ecfdf5; color: #047857;
        }
        .doc-lib-badge.err { background: #fef2f2; color: #b91c1c; }
        .doc-lib-badge.busy { background: #eef2ff; color: #4338ca; }
        .doc-file-card {
            position: relative; display: flex; gap: 10px; align-items: center; padding: 12px; border-radius: 12px;
            border: 1px solid #e5e7eb; background: #fff; overflow: hidden; animation: chatBubbleIn 0.28s ease both;
        }
        .doc-file-card.ok { border-color: #a7f3d0; background: #f0fdf4; }
        .doc-file-card.err { border-color: #fecaca; background: #fef2f2; }
        .doc-file-icon { font-size: 28px; }
        .doc-file-name { font-size: 13px; font-weight: 700; color: #111827; word-break: break-all; }
        .doc-file-sub { font-size: 12px; color: #6b7280; margin-top: 2px; }
        .doc-progress { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: #e0e7ff; }
        .doc-progress i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #a78bfa, #4f46e5); transition: width 0.25s ease; }
        .doc-result-shell { flex: 1; min-height: 360px; border: 1px solid #eef2ff; border-radius: 14px; background: #fff; overflow: hidden; display: flex; flex-direction: column; }
        .doc-tabs { display: flex; gap: 6px; padding: 10px; border-bottom: 1px solid #eef2ff; background: #fafafa; flex-wrap: wrap; }
        .doc-tab { border: none; background: transparent; color: #6b7280; border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 600; cursor: pointer; }
        .doc-tab:hover { background: #eef2ff; color: #4f46e5; }
        .doc-tab.active { background: #4f46e5; color: #fff; }
        .doc-pane { flex: 1; overflow: auto; padding: 14px; }
        .doc-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
        .doc-actions .btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; box-shadow: none; }
        .doc-empty { text-align: center; color: #94a3b8; padding: 64px 20px; }
        .doc-empty-ico { font-size: 48px; margin-bottom: 10px; }
        .doc-empty-title { font-size: 16px; font-weight: 700; color: #475569; }
        .doc-empty-desc { font-size: 13px; margin-top: 8px; line-height: 1.6; }
        .doc-empty-steps { display: flex; justify-content: center; gap: 10px; margin-top: 16px; flex-wrap: wrap; }
        .doc-empty-steps span { background: #eef2ff; color: #4f46e5; border-radius: 999px; padding: 4px 10px; font-size: 12px; font-weight: 600; }
        .doc-loading { display: flex; align-items: center; justify-content: center; gap: 12px; min-height: 220px; color: #4338ca; font-size: 14px; }
        .doc-error { margin: 16px; padding: 14px; border-radius: 12px; background: #fef2f2; border: 1px solid #fecaca; color: #b91c1c; font-size: 13px; line-height: 1.7; }
        .doc-card-soft { border: 1px solid #e5e7eb; border-radius: 12px; padding: 14px; background: linear-gradient(180deg, #fff, #fafafa); animation: chatBubbleIn 0.28s ease both; }
        .doc-card-title { font-size: 14px; font-weight: 700; color: #312e81; margin-bottom: 8px; }
        .doc-meta-line { font-size: 12px; color: #6b7280; margin-bottom: 8px; }
        .doc-preview-text, .doc-prose { font-size: 13px; line-height: 1.8; color: #1f2937; white-space: pre-wrap; word-break: break-word; }
        .doc-preview-text { max-height: min(52vh, 420px); overflow: auto; background: #f8fafc; border-radius: 10px; padding: 12px; border: 1px solid #eef2ff; }
        .doc-stat-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
        .doc-stat-row span { font-size: 12px; color: #4f46e5; background: #eef2ff; border-radius: 999px; padding: 3px 10px; font-weight: 600; }
        .doc-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
        .doc-chips span { font-size: 12px; color: #5b21b6; background: #f5f3ff; border: 1px solid #ddd6fe; border-radius: 999px; padding: 2px 8px; }
        .doc-chips .muted { color: #9ca3af; background: #f3f4f6; border-color: #e5e7eb; }
        .doc-kv { margin-bottom: 12px; }
        .doc-ul { margin: 6px 0 0; padding-left: 18px; font-size: 13px; color: #374151; line-height: 1.7; }
        .doc-tree-item { margin-bottom: 10px; font-size: 13px; color: #1f2937; }
        .doc-tree-children { padding-left: 16px; margin-top: 4px; color: #4b5563; }
        .doc-hint { color: #94a3b8; font-size: 13px; padding: 24px; text-align: center; }
        .doc-chat-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; margin-bottom: 10px; }
        .doc-chat-title { font-size: 15px; font-weight: 800; color: #111827; }
        .doc-chat-sub { font-size: 12px; color: #6b7280; margin-top: 2px; line-height: 1.5; }
        .doc-chat-stream {
            flex: 1 1 auto; overflow: auto; min-height: 180px; max-height: 320px; padding: 10px;
            border: 1px solid #eef2ff; border-radius: 12px; background: #fff;
        }
        .doc-chat-row { display: flex; margin-bottom: 10px; }
        .doc-chat-row.user { justify-content: flex-end; }
        .doc-chat-row.assistant { justify-content: flex-start; }
        .doc-chat-bubble {
            max-width: 92%; padding: 10px 12px; border-radius: 14px; font-size: 13px; line-height: 1.65;
            white-space: pre-wrap; word-break: break-word; animation: chatBubbleIn 0.25s ease both;
        }
        .doc-chat-bubble.user { background: linear-gradient(135deg,#6366f1,#4f46e5); color: #fff; border-bottom-right-radius: 4px; }
        .doc-chat-bubble.assistant { background: #f8fafc; color: #1f2937; border: 1px solid #e5e7eb; border-bottom-left-radius: 4px; }
        .doc-chat-label { font-size: 11px; font-weight: 700; margin-bottom: 4px; opacity: 0.85; }
        .doc-chat-suggest { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
        .doc-chat-suggest button {
            border: 1px solid #e0e7ff; background: #eef2ff; color: #4338ca; border-radius: 999px;
            padding: 4px 10px; font-size: 11px; font-weight: 600; cursor: pointer;
        }
        .doc-chat-suggest button:hover { background: #e0e7ff; }
        .doc-chat-input-row { display: flex; gap: 8px; margin-top: 8px; }
        .doc-chat-input-row textarea {
            flex: 1; min-height: 64px; max-height: 120px; resize: vertical; border: 1px solid #e5e7eb;
            border-radius: 12px; padding: 10px 12px; font-size: 13px; font-family: inherit; line-height: 1.5;
        }
        .doc-chat-input-row textarea:focus { outline: none; border-color: #818cf8; box-shadow: 0 0 0 3px rgba(99,102,241,0.15); }
        .doc-chat-send {
            align-self: stretch; min-width: 72px; border: none; border-radius: 12px; color: #fff; font-weight: 700;
            background: linear-gradient(135deg,#7c3aed,#4f46e5); cursor: pointer; padding: 0 14px;
        }
        .doc-chat-send:disabled { opacity: 0.45; cursor: not-allowed; }
        .doc-ai-ports {
            margin-top: 12px; padding-top: 12px; border-top: 1px dashed #e2e8f0; flex-shrink: 0;
        }
        .doc-ai-ports-head {
            display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 8px;
        }
        .doc-ai-ports-title { font-size: 12px; font-weight: 800; color: #334155; letter-spacing: 0.02em; }
        .doc-ai-ports-sub { font-size: 11px; color: #94a3b8; }
        .doc-ai-ports-grid {
            display: grid; grid-template-columns: 1fr 1fr; gap: 8px;
        }
        .doc-ai-port {
            display: flex; align-items: center; gap: 8px; padding: 9px 10px; border-radius: 12px;
            text-decoration: none; border: 1px solid transparent; transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
            background: #fff; min-height: 52px;
        }
        .doc-ai-port:hover { transform: translateY(-2px); box-shadow: 0 10px 18px rgba(15, 23, 42, 0.08); }
        .doc-ai-port .mark {
            width: 30px; height: 30px; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center;
            font-size: 12px; font-weight: 800; color: #fff; flex-shrink: 0;
        }
        .doc-ai-port .meta { min-width: 0; }
        .doc-ai-port .name { font-size: 12px; font-weight: 800; color: #0f172a; line-height: 1.2; }
        .doc-ai-port .desc { font-size: 10px; color: #64748b; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
        .doc-ai-port.deepseek { border-color: #dbeafe; background: linear-gradient(135deg, #eff6ff, #fff); }
        .doc-ai-port.deepseek .mark { background: linear-gradient(135deg, #2563eb, #1d4ed8); }
        .doc-ai-port.doubao { border-color: #ffedd5; background: linear-gradient(135deg, #fff7ed, #fff); }
        .doc-ai-port.doubao .mark { background: linear-gradient(135deg, #f97316, #ea580c); }
        .doc-ai-port.kimi { border-color: #e2e8f0; background: linear-gradient(135deg, #f8fafc, #fff); }
        .doc-ai-port.kimi .mark { background: linear-gradient(135deg, #334155, #0f172a); }
        .doc-ai-port.gemini { border-color: #e9d5ff; background: linear-gradient(135deg, #faf5ff, #fff); }
        .doc-ai-port.gemini .mark { background: linear-gradient(135deg, #8b5cf6, #6366f1); }
        .doc-ai-port.qwen { border-color: #d1fae5; background: linear-gradient(135deg, #ecfdf5, #fff); }
        .doc-ai-port.qwen .mark { background: linear-gradient(135deg, #059669, #0d9488); }
        .doc-ai-port.gemini-app { border-color: #fce7f3; background: linear-gradient(135deg, #fdf2f8, #fff); }
        .doc-ai-port.gemini-app .mark { background: linear-gradient(135deg, #db2777, #7c3aed); }
        
        /* 主内容区 */
        .main-content {
            flex: 1;
            min-width: 0;
            padding: 28px 28px 96px;
            overflow-x: auto;
            overflow-y: auto;
            -webkit-overflow-scrolling: touch;
            overscroll-behavior-x: contain;
            position: relative;
        }

        .kx-link-button {
            appearance: none;
            border: 0;
            padding: 0;
            background: transparent;
            font: inherit;
            cursor: pointer;
        }

        /* 顶栏在中等宽度下改为“工作台模式”，避免门户链接和用户名被挤成竖排。 */
        @media (max-width: 1280px) {
            .top-nav { padding-inline: 16px; gap: 10px; }
            .top-nav-left { flex: 0 1 auto; }
            .top-nav .logo { gap: 8px; min-width: 0; }
            .top-nav .logo-text {
                max-width: 176px;
                font-size: 15px;
                line-height: 1.25;
                white-space: normal;
            }
            .global-search { max-width: 340px; margin-inline: 10px; }
            .top-nav .nav-links > a[data-portal] { display: none; }
            .top-nav .nav-links { margin-left: auto; flex: 0 0 auto; }
            .user-info-bar { white-space: nowrap; }
        }

        @media (max-width: 1024px) {
            .nav-back-btn { margin-right: 4px; padding-inline: 10px; }
            .nav-back-btn .back-text { display: none; }
            .top-nav .logo-text { max-width: 132px; font-size: 14px; }
            .global-search { max-width: none; min-width: 180px; margin-inline: 6px; }
            .user-info-bar > div:not(.avatar-circle) { display: none; }
            .user-info-bar { margin-left: 2px !important; }
        }

        @media (max-width: 768px) {
            .top-nav { column-gap: 8px; }
            .top-nav-left { order: 1; }
            .top-nav .nav-links { order: 2; }
            .global-search {
                order: 3;
                flex: 1 0 100%;
                margin: 2px 0 0;
            }
            .top-nav .logo-text { display: none; }
            .nav-sync-chip { padding-inline: 8px; }
            #navSyncChipText { display: none; }
            .main-content { padding-bottom: 92px; }
            .cloud-sync-fab { bottom: max(14px, env(safe-area-inset-bottom)); }
        }

        /* 宽表格可横向滑动：包裹表格的卡片容器（常带内联 overflow:hidden 做圆角）改为横向滚动，
           修复宽表 / 窄屏下右侧列被裁切且无法查看的问题。本项目已用 :has，兼容现代浏览器。 */
        .main-content div:has(> table),
        .main-content div:has(> .table) {
            overflow-x: auto !important;
            -webkit-overflow-scrolling: touch;
        }

        /* 模块显示 */
        .module {
            display: none;
        }
        
        .module.active {
            display: block;
            animation: fadeIn 0.45s cubic-bezier(0.22, 1, 0.36, 1);
        }

        .module.active > .card,
        .module.active > div > .card,
        .module.active [style*="background: #fff"],
        .module.active [style*="background:#fff"],
        .module.active [style*="background: white"],
        .module.active [style*="background:white"] {
            animation: fadeIn 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
        }
        .module.active > .card:nth-child(1),
        .module.active > div:nth-child(1) { animation-delay: 0.02s; }
        .module.active > .card:nth-child(2),
        .module.active > div:nth-child(2) { animation-delay: 0.06s; }
        .module.active > .card:nth-child(3),
        .module.active > div:nth-child(3) { animation-delay: 0.10s; }
        .module.active > .card:nth-child(4),
        .module.active > div:nth-child(4) { animation-delay: 0.14s; }
        
        /* 卡片样式 */
        .card {
            background: var(--surface);
            backdrop-filter: blur(14px) saturate(140%);
            -webkit-backdrop-filter: blur(14px) saturate(140%);
            border-radius: var(--radius);
            padding: 24px;
            margin-bottom: 20px;
            border: 1px solid rgba(255,255,255,0.7);
            box-shadow: var(--shadow);
            transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.3s, border-color 0.3s;
            position: relative;
            overflow: hidden;
        }
        .card::after {
            content: '';
            position: absolute;
            top: 0; left: 0; right: 0;
            height: 3px;
            background: linear-gradient(90deg, #a78bfa, #7c3aed, #4f46e5);
            opacity: 0.85;
            transform: scaleX(0.35);
            transform-origin: left;
            transition: transform 0.35s ease;
        }
        .card:hover {
            transform: translateY(-4px);
            box-shadow: 0 24px 60px rgba(49, 30, 100, 0.14);
            border-color: rgba(124, 58, 237, 0.18);
        }
        .card:hover::after {
            transform: scaleX(1);
        }
        
        .card h2 {
            color: var(--brand);
            margin-bottom: 18px;
            font-size: 22px;
            border-bottom: 1px solid var(--line);
            padding-bottom: 12px;
            letter-spacing: 0.01em;
        }

        /* 统一表格观感与行悬浮动效 */
        .data-table { border-collapse: collapse; }
        .data-table thead th {
            background: linear-gradient(180deg, #f5f3ff, #eef2ff);
            color: #4c1d95;
            font-weight: 700;
            font-size: 13px;
            padding: 12px 14px;
            text-align: left;
            border-bottom: 2px solid #e0e7ff;
            position: sticky;
            top: 0;
            z-index: 1;
        }
        .data-table tbody td {
            padding: 11px 14px;
            border-bottom: 1px solid #f1f5f9;
            font-size: 13px;
            color: #1f2937;
        }
        .data-table tbody tr {
            transition: background 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
        }
        .data-table tbody tr:hover {
            background: #f8f7ff;
            box-shadow: inset 3px 0 0 #7c3aed;
        }
        
        .data-table tbody tr:hover {
            background: #f8f7ff;
            box-shadow: inset 3px 0 0 #7c3aed;
        }

        /* 按钮样式 */
        .btn {
            background: linear-gradient(135deg, #8b5cf6, #7c3aed 50%, #4f46e5);
            color: white;
            border: none;
            padding: 11px 22px;
            border-radius: 12px;
            cursor: pointer;
            font-size: 14px;
            font-weight: 600;
            transition: transform 0.22s, box-shadow 0.22s, filter 0.22s;
            margin: 5px;
            box-shadow: 0 10px 24px rgba(124, 58, 237, 0.28);
            position: relative;
            overflow: hidden;
        }
        .btn::after {
            content: '';
            position: absolute;
            inset: 0;
            background: linear-gradient(90deg, transparent, rgba(255,255,255,0.28), transparent);
            transform: translateX(-120%);
            transition: none;
            pointer-events: none;
        }
        
        .btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 14px 30px rgba(124, 58, 237, 0.38);
            filter: brightness(1.05);
        }
        .btn:hover::after {
            animation: shimmerSweep 0.85s ease;
        }
        .btn:active { transform: translateY(0); }
        
        .btn-secondary {
            background: linear-gradient(135deg, #6b7280, #4b5563);
            box-shadow: 0 8px 18px rgba(75, 85, 99, 0.25);
        }
        
        .btn-success {
            background: linear-gradient(135deg, #34d399, #10b981);
            box-shadow: 0 8px 18px rgba(16, 185, 129, 0.28);
        }

        /* 通用表格/输入动效 */
        table {
            border-collapse: separate;
            border-spacing: 0;
        }
        table tbody tr {
            transition: background 0.2s, transform 0.2s;
        }
        table tbody tr:hover {
            background: rgba(124, 58, 237, 0.04);
        }
        input[type="text"],
        input[type="password"],
        input[type="search"],
        input[type="number"],
        input[type="date"],
        select,
        textarea {
            transition: border-color 0.22s, box-shadow 0.22s, transform 0.22s;
        }
        input[type="text"]:focus,
        input[type="password"]:focus,
        input[type="search"]:focus,
        input[type="number"]:focus,
        input[type="date"]:focus,
        select:focus,
        textarea:focus {
            outline: none;
            border-color: rgba(124, 58, 237, 0.55) !important;
            box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.14);
        }

        /* 首页等内联白卡片也有轻微动效 */
        .main-content [style*="box-shadow"] {
            transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.28s;
        }
        .file-card-item:hover,
        .file-list-row:hover {
            /* 已有内联 hover，这里补强过渡 */
        }

        @media (prefers-reduced-motion: reduce) {
            .login-particle,
            .login-bg-orb,
            .login-grid {
                animation-duration: 0.01ms !important;
            }
        }

        .task-status-btn {
            padding: 8px 16px;
            border: none;
            border-radius: 20px;
            font-size: 13px;
            cursor: pointer;
            background: #fff;
            color: #666;
            border: 1px solid #ddd;
            transition: all 0.2s;
        }

        .task-status-btn:hover {
            border-color: #667eea;
            color: #667eea;
        }

        .task-status-btn.active {
            background: #667eea;
            color: #fff;
            border-color: #667eea;
        }
        
        /* 表单样式 */
        .form-group {
            margin-bottom: 20px;
        }
        
        .form-group label {
            display: block;
            margin-bottom: 8px;
            font-weight: 600;
            color: #555;
        }
        
        .form-control {
            width: 100%;
            padding: 12px;
            border: 2px solid #e9ecef;
            border-radius: 8px;
            font-size: 14px;
            transition: border-color 0.3s;
        }
        
        .form-control:focus {
            outline: none;
            border-color: #8A2BE2;
        }
        
        /* 表格样式 */
        .table {
            width: 100%;
            border-collapse: collapse;
            margin-top: 20px;
        }
        
        .table th,
        .table td {
            padding: 12px;
            text-align: left;
            border-bottom: 1px solid #e9ecef;
        }
        
        .table th {
            background-color: #f8f9fa;
            font-weight: 600;
            color: #555;
        }
        
        .table tr:hover {
            background-color: #f8f9fa;
        }
        
        /* 标签页样式 */
        .tabs {
            display: flex;
            border-bottom: 2px solid #e9ecef;
            margin-bottom: 20px;
        }
        
        .tab {
            padding: 12px 20px;
            cursor: pointer;
            border-bottom: 2px solid transparent;
            transition: all 0.3s;
        }
        
        .tab:hover {
            color: #8A2BE2;
        }
        
        .tab.active {
            color: #8A2BE2;
            border-bottom-color: #8A2BE2;
        }
        
        .tab-content {
            display: none;
        }
        
        .tab-content.active {
            display: block;
        }
        
        /* 上传区域 */
        .upload-area {
            border: 2px dashed #8A2BE2;
            border-radius: 12px;
            padding: 40px;
            text-align: center;
            background: #f3e5f5;
            cursor: pointer;
            transition: all 0.3s;
        }
        
        .upload-area:hover {
            background: #e1bee7;
        }
        
        /* 标签样式 */
        .tag {
            display: inline-block;
            padding: 4px 12px;
            border-radius: 20px;
            font-size: 12px;
            margin: 2px;
        }
        
        .tag-primary {
            background: #e1bee7;
            color: #6a1b9a;
        }
        
        .tag-success {
            background: #e8f5e8;
            color: #388e3c;
        }
        
        .tag-warning {
            background: #fff3e0;
            color: #f57c00;
        }
        
        .tag-danger {
            background: #ffebee;
            color: #d32f2f;
        }
        
        .tag-info {
            background: #e3f2fd;
            color: #1565c0;
        }
        
        .btn-danger {
            background: linear-gradient(135deg, #f87171, #ef4444);
            box-shadow: 0 8px 18px rgba(239, 68, 68, 0.28);
        }
        
        /* 软著管理筛选标签样式 */
        .filter-tag {
            display: inline-block;
            padding: 6px 16px;
            border-radius: 20px;
            background: #e9ecef;
            color: #666;
            font-size: 13px;
            cursor: pointer;
            transition: all 0.2s;
            user-select: none;
        }
        
        .filter-tag:hover {
            background: #dee2e6;
        }
        
        .filter-tag.active {
            background: #8A2BE2;
            color: white;
        }
        
        /* 聊天容器 */
        .chat-container {
            height: 400px;
            border: 1px solid #e9ecef;
            border-radius: 8px;
            overflow-y: auto;
            padding: 15px;
            margin-bottom: 15px;
            background: #f8f9fa;
        }
        
        .chat-message {
            margin-bottom: 15px;
            padding: 10px 15px;
            border-radius: 18px;
            max-width: 80%;
        }
        
        .chat-message.user {
            background: #8A2BE2;
            color: white;
            margin-left: auto;
            text-align: right;
        }
        
        .chat-message.ai {
            background: white;
            border: 1px solid #e9ecef;
        }
        
        /* 图表占位符 */
        .chart-placeholder {
            height: 300px;
            background: linear-gradient(45deg, #f0f0f0 25%, transparent 25%), 
                        linear-gradient(-45deg, #f0f0f0 25%, transparent 25%), 
                        linear-gradient(45deg, transparent 75%, #f0f0f0 75%), 
                        linear-gradient(-45deg, transparent 75%, #f0f0f0 75%);
            background-size: 20px 20px;
            background-position: 0 0, 0 10px, 10px -10px, -10px 0px;
            border-radius: 8px;
            display: flex;
            align-items: center;
            justify-content: center;
            color: #666;
            font-size: 18px;
        }
        
        /* 统计卡片 */
        .stats-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
            gap: 20px;
            margin-bottom: 30px;
        }
        
        .stat-card {
            background: white;
            padding: 25px;
            border-radius: 12px;
            text-align: center;
            box-shadow: 0 2px 15px rgba(0,0,0,0.08);
            border-top: 4px solid #8A2BE2;
        }
        
        .stat-number {
            font-size: 36px;
            font-weight: bold;
            color: #8A2BE2;
            margin-bottom: 5px;
        }
        
        .stat-label {
            color: #666;
            font-size: 14px;
        }
        
        /* 复选框组 */
        .checkbox-group {
            display: flex;
            flex-wrap: wrap;
            gap: 15px;
            margin: 15px 0;
        }
        
        .checkbox-item {
            display: flex;
            align-items: center;
            gap: 8px;
        }
        
        .checkbox-item input[type="checkbox"] {
            width: 18px;
            height: 18px;
            accent-color: #8A2BE2;
        }
        
        /* 响应式设计（旧堆叠式移动规则已并入上方“侧栏抽屉”方案；此处仅保留非冲突项，
           避免覆盖抽屉的 position:fixed 与顶栏 nav-links 的精细处理） */
        @media (max-width: 768px) {
            .stats-grid {
                grid-template-columns: repeat(2, 1fr);
            }
        }
        
        /* ========== 登录页样式（动态高级感） ========== */
        .login-overlay {
            display: none;
            position: fixed;
            inset: 0;
            z-index: 10000;
            /* 手机端表单可能高于视口：必须允许纵向滚动，否则「进入系统」会被裁掉 */
            overflow-x: hidden;
            overflow-y: auto;
            -webkit-overflow-scrolling: touch;
            overscroll-behavior: contain;
            font-family: 'Outfit', 'Noto Serif SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
            background:
                radial-gradient(ellipse 90% 70% at 15% 20%, rgba(14, 165, 233, 0.22), transparent 55%),
                radial-gradient(ellipse 80% 60% at 85% 15%, rgba(99, 102, 241, 0.28), transparent 50%),
                radial-gradient(ellipse 70% 50% at 60% 90%, rgba(20, 184, 166, 0.18), transparent 55%),
                linear-gradient(155deg, #070b16 0%, #0f172a 38%, #111827 72%, #0b1220 100%);
            color: #e8eef7;
        }
        .login-overlay.active { display: block; }
        .login-atmosphere {
            position: absolute;
            inset: 0;
            pointer-events: none;
            z-index: 0;
        }
        .login-mesh {
            position: absolute;
            inset: -10%;
            background:
                radial-gradient(circle at 20% 30%, rgba(255,255,255,0.09) 0 1px, transparent 2px),
                radial-gradient(circle at 70% 55%, rgba(125, 211, 252, 0.12) 0 1px, transparent 2px),
                radial-gradient(circle at 45% 80%, rgba(255,255,255,0.06) 0 1px, transparent 2px);
            background-size: 140px 140px, 200px 200px, 100px 100px;
            animation: loginStarDrift 28s linear infinite;
            opacity: 0.85;
        }
        .login-horizon {
            position: absolute;
            left: -20%;
            right: -20%;
            bottom: -8%;
            height: 42%;
            background:
                linear-gradient(180deg, transparent 0%, rgba(8, 47, 73, 0.35) 40%, rgba(2, 8, 23, 0.85) 100%);
            filter: blur(1px);
        }
        .login-skyline {
            position: absolute;
            left: 0;
            right: 0;
            bottom: 0;
            height: 120px;
            background:
                linear-gradient(90deg, transparent 0 4%, #0b1220 4% 6%, transparent 6% 12%, #0b1220 12% 13.5%, transparent 13.5% 18%, #0b1220 18% 22%, transparent 22% 28%, #0b1220 28% 30%, transparent 30% 36%, #0b1220 36% 41%, transparent 41% 48%, #0b1220 48% 50%, transparent 50% 57%, #0b1220 57% 63%, transparent 63% 70%, #0b1220 70% 72%, transparent 72% 78%, #0b1220 78% 84%, transparent 84% 90%, #0b1220 90% 93%, transparent 93%),
                linear-gradient(180deg, transparent 30%, rgba(14, 165, 233, 0.08) 100%);
            opacity: 0.55;
            mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
        }
        .login-overlay::before,
        .login-overlay::after { display: none; }
        .login-bg-orb {
            position: absolute;
            border-radius: 50%;
            filter: blur(48px);
            pointer-events: none;
            z-index: 0;
            opacity: 0.7;
        }
        .login-bg-orb.orb-a {
            width: 460px; height: 460px;
            right: -80px; bottom: -60px;
            background: radial-gradient(circle, rgba(20, 184, 166, 0.35), transparent 70%);
            animation: loginOrbFloat 9s ease-in-out infinite reverse;
        }
        .login-bg-orb.orb-b {
            width: 320px; height: 320px;
            left: 8%; top: 12%;
            background: radial-gradient(circle, rgba(56, 189, 248, 0.28), transparent 70%);
            animation: loginOrbFloat 7s ease-in-out infinite;
        }
        .login-grid {
            position: absolute;
            inset: 0;
            background-image:
                linear-gradient(rgba(148, 163, 184, 0.06) 1px, transparent 1px),
                linear-gradient(90deg, rgba(148, 163, 184, 0.06) 1px, transparent 1px);
            background-size: 72px 72px;
            mask-image: radial-gradient(ellipse at 30% 40%, black 20%, transparent 72%);
            animation: loginGridPulse 5s ease-in-out infinite;
            z-index: 0;
        }
        @keyframes loginStarDrift {
            from { transform: translate3d(0,0,0); }
            to { transform: translate3d(-90px, -50px, 0); }
        }
        @keyframes loginOrbFloat {
            0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
            50% { transform: translate3d(36px, -40px, 0) scale(1.08); }
        }
        @keyframes loginParticleFloat {
            0% { transform: translate3d(0, 20px, 0) scale(0.5); opacity: 0; }
            20% { opacity: 0.9; }
            100% { transform: translate3d(var(--dx, 40px), -110vh, 0) scale(1); opacity: 0; }
        }
        @keyframes loginRingPulse {
            0%, 100% { transform: scale(1); opacity: 0.2; }
            50% { transform: scale(1.12); opacity: 0.45; }
        }
        @keyframes loginGridPulse {
            0%, 100% { opacity: 0.35; }
            50% { opacity: 0.55; }
        }
        @keyframes loginCardIn {
            from { opacity: 0; transform: translateY(24px) scale(0.98); }
            to { opacity: 1; transform: translateY(0) scale(1); }
        }
        @keyframes loginHeroIn {
            from { opacity: 0; transform: translateX(-28px); }
            to { opacity: 1; transform: translateX(0); }
        }
        @keyframes loginShimmer {
            0% { transform: translateX(-120%); }
            100% { transform: translateX(120%); }
        }
        .login-particles {
            position: absolute;
            inset: 0;
            overflow: hidden;
            z-index: 0;
        }
        .login-particle {
            position: absolute;
            bottom: -16px;
            width: 4px;
            height: 4px;
            border-radius: 50%;
            background: rgba(186, 230, 253, 0.9);
            box-shadow: 0 0 10px rgba(56, 189, 248, 0.45);
            animation: loginParticleFloat linear infinite;
        }
        .login-ring {
            position: absolute;
            border: 1px solid rgba(148, 163, 184, 0.18);
            border-radius: 50%;
            z-index: 0;
            animation: loginRingPulse 6s ease-in-out infinite;
        }
        .login-ring.r1 { width: 340px; height: 340px; left: 6%; top: 16%; }
        .login-ring.r2 { width: 520px; height: 520px; right: -4%; bottom: 4%; animation-delay: 1.4s; }

        .login-stage {
            position: relative;
            z-index: 1;
            min-height: 100%;
            min-height: 100dvh;
            display: grid;
            grid-template-columns: minmax(0, 1.15fr) minmax(320px, 440px);
            gap: clamp(28px, 5vw, 72px);
            align-items: center;
            padding: clamp(28px, 5vw, 64px) clamp(20px, 6vw, 80px);
            padding-bottom: max(clamp(28px, 5vw, 64px), env(safe-area-inset-bottom, 0px));
            max-width: 1180px;
            margin: 0 auto;
            box-sizing: border-box;
        }
        .login-hero {
            animation: loginHeroIn 0.85s cubic-bezier(0.22, 1, 0.36, 1) both;
            max-width: 560px;
        }
        .login-hero-kicker {
            font-size: 12px;
            letter-spacing: 0.22em;
            text-transform: uppercase;
            color: rgba(125, 211, 252, 0.85);
            margin-bottom: 18px;
            font-weight: 500;
        }
        .login-hero-title {
            font-family: 'Noto Serif SC', 'Songti SC', serif;
            font-size: clamp(40px, 5.6vw, 64px);
            font-weight: 700;
            line-height: 1.12;
            letter-spacing: 0.04em;
            color: #f8fafc;
            margin: 0 0 18px;
            text-shadow: 0 12px 40px rgba(2, 8, 23, 0.35);
        }
        .login-hero-desc {
            font-size: 16px;
            line-height: 1.7;
            color: rgba(203, 213, 225, 0.88);
            max-width: 34em;
            margin: 0 0 28px;
            font-weight: 400;
        }
        .login-hero-meta {
            list-style: none;
            margin: 0;
            padding: 0;
            display: flex;
            flex-direction: column;
            gap: 10px;
        }
        .login-hero-meta li {
            display: flex;
            align-items: center;
            gap: 14px;
            font-size: 13px;
            color: rgba(226, 232, 240, 0.78);
            letter-spacing: 0.04em;
        }
        .login-hero-meta span {
            font-family: 'Outfit', sans-serif;
            font-size: 11px;
            font-weight: 600;
            letter-spacing: 0.12em;
            color: #67e8f9;
            min-width: 28px;
        }

        .login-box {
            position: relative;
            z-index: 2;
            width: 100%;
            padding: 36px 34px 28px;
            border-radius: 22px;
            background: rgba(15, 23, 42, 0.62);
            border: 1px solid rgba(148, 163, 184, 0.22);
            box-shadow:
                0 28px 60px rgba(2, 6, 23, 0.45),
                inset 0 1px 0 rgba(255,255,255,0.08);
            backdrop-filter: blur(24px) saturate(140%);
            -webkit-backdrop-filter: blur(24px) saturate(140%);
            animation: loginCardIn 0.75s cubic-bezier(0.22, 1, 0.36, 1) 0.12s both;
            overflow: hidden;
            transition: transform 0.2s ease-out;
        }
        .login-box::before {
            content: '';
            position: absolute;
            inset: 0;
            background: linear-gradient(145deg, rgba(56, 189, 248, 0.12), transparent 42%, transparent 58%, rgba(45, 212, 191, 0.08));
            pointer-events: none;
        }
        .login-brand {
            display: flex;
            align-items: center;
            gap: 14px;
            margin-bottom: 26px;
            position: relative;
            z-index: 1;
        }
        .login-brand-mark {
            width: 52px;
            height: 52px;
            border-radius: 16px;
            display: grid;
            place-items: center;
            color: #e0f2fe;
            background: linear-gradient(145deg, rgba(14, 165, 233, 0.55), rgba(15, 23, 42, 0.9));
            border: 1px solid rgba(125, 211, 252, 0.35);
            box-shadow: 0 10px 28px rgba(14, 165, 233, 0.2);
            flex-shrink: 0;
        }
        .login-brand-name {
            font-family: 'Noto Serif SC', serif;
            font-size: 20px;
            font-weight: 700;
            color: #f8fafc;
            letter-spacing: 0.06em;
            line-height: 1.3;
        }
        .login-box .login-subtitle {
            color: rgba(148, 163, 184, 0.95);
            font-size: 12px;
            margin-top: 4px;
            letter-spacing: 0.12em;
            text-transform: uppercase;
        }
        .login-box .form-group {
            margin-bottom: 14px;
            position: relative;
            z-index: 1;
        }
        .login-box label {
            display: block;
            margin-bottom: 8px;
            font-weight: 500;
            color: rgba(226, 232, 240, 0.9);
            font-size: 12px;
            letter-spacing: 0.08em;
        }
        .login-input-wrap { position: relative; }
        .login-box input[type="text"],
        .login-box input[type="password"] {
            width: 100%;
            padding: 13px 44px 13px 14px;
            border: 1px solid rgba(148, 163, 184, 0.28);
            border-radius: 12px;
            font-size: 14px;
            font-family: inherit;
            outline: none;
            color: #0f172a;
            background: rgba(248, 250, 252, 0.96);
            transition: border-color 0.25s, box-shadow 0.25s, transform 0.2s;
        }
        .login-box input::placeholder { color: #94a3b8; }
        .login-box input:focus {
            border-color: rgba(56, 189, 248, 0.85);
            box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.22);
            transform: translateY(-1px);
        }
        .login-eye-btn {
            position: absolute;
            right: 8px;
            top: 50%;
            transform: translateY(-50%);
            background: transparent;
            border: none;
            cursor: pointer;
            color: #64748b;
            width: 34px;
            height: 34px;
            border-radius: 8px;
            display: grid;
            place-items: center;
            transition: background 0.2s, color 0.2s;
        }
        .login-eye-btn:hover {
            background: rgba(14, 165, 233, 0.1);
            color: #0284c7;
        }
        .login-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            gap: 12px;
            margin: 4px 0 10px;
            position: relative;
            z-index: 1;
            font-size: 12px;
            color: rgba(148, 163, 184, 0.9);
        }
        .login-remember {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            cursor: pointer;
            color: rgba(226, 232, 240, 0.85);
            font-weight: 500;
            letter-spacing: 0;
            margin: 0;
        }
        .login-remember input { accent-color: #0ea5e9; }
        .login-hint { opacity: 0.7; }
        .login-box .login-btn {
            position: relative;
            width: 100%;
            padding: 14px;
            background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 48%, #0f766e 100%);
            color: #f8fafc;
            border: none;
            border-radius: 12px;
            font-size: 15px;
            font-weight: 600;
            font-family: inherit;
            cursor: pointer;
            margin-top: 6px;
            overflow: hidden;
            letter-spacing: 0.14em;
            box-shadow: 0 14px 32px rgba(14, 165, 233, 0.28);
            transition: transform 0.25s, box-shadow 0.25s, filter 0.25s;
            z-index: 1;
        }
        .login-box .login-btn span { position: relative; z-index: 1; }
        .login-box .login-btn::after {
            content: '';
            position: absolute;
            top: 0; left: 0;
            width: 42%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255,255,255,0.28), transparent);
            transform: translateX(-120%);
            pointer-events: none;
        }
        .login-box .login-btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 18px 40px rgba(14, 165, 233, 0.36);
            filter: brightness(1.04);
        }
        .login-box .login-btn:hover::after { animation: loginShimmer 0.85s ease; }
        .login-box .login-btn:active { transform: translateY(0); }
        .login-box .login-btn:disabled {
            opacity: 0.55;
            cursor: not-allowed;
            transform: none;
            box-shadow: none;
        }
        .login-box select {
            width: 100%;
            padding: 12px 14px;
            border: 1px solid rgba(148, 163, 184, 0.35);
            border-radius: 10px;
            background: rgba(15, 23, 42, 0.55);
            color: #e2e8f0;
            font-size: 14px;
            outline: none;
        }
        .login-box .req { color: #fb7185; }
        .login-success {
            margin: 0 0 10px;
            padding: 10px 12px;
            border-radius: 8px;
            background: rgba(16, 185, 129, 0.16);
            border: 1px solid rgba(52, 211, 153, 0.35);
            color: #a7f3d0;
            font-size: 13px;
            line-height: 1.5;
            position: relative;
            z-index: 1;
        }
        .login-register-box {
            max-height: min(86vh, 760px);
            overflow-y: auto;
        }
        /* —— 登录页动感增强（克制、支持 prefers-reduced-motion 关闭）—— */
        .login-hero-title {
            background: linear-gradient(100deg, #f8fafc 0%, #f8fafc 38%, #a5f3fc 50%, #f8fafc 62%, #f8fafc 100%);
            background-size: 220% 100%;
            -webkit-background-clip: text;
            background-clip: text;
            -webkit-text-fill-color: transparent;
            color: transparent;
            text-shadow: none;
            filter: drop-shadow(0 12px 40px rgba(2, 8, 23, 0.35));
            animation: loginTitleSheen 7.5s ease-in-out infinite;
        }
        @keyframes loginTitleSheen {
            0%, 100% { background-position: 128% 0; }
            50% { background-position: -28% 0; }
        }
        .login-hero-meta li {
            animation: loginMetaIn 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
        }
        .login-hero-meta li:nth-child(1) { animation-delay: 0.48s; }
        .login-hero-meta li:nth-child(2) { animation-delay: 0.60s; }
        .login-hero-meta li:nth-child(3) { animation-delay: 0.72s; }
        @keyframes loginMetaIn {
            from { opacity: 0; transform: translateY(10px); }
            to { opacity: 1; transform: none; }
        }
        .login-brand-mark { animation: loginMarkGlow 4.2s ease-in-out infinite; }
        @keyframes loginMarkGlow {
            0%, 100% { box-shadow: 0 10px 28px rgba(14, 165, 233, 0.2); }
            50% { box-shadow: 0 12px 36px rgba(14, 165, 233, 0.45); }
        }
        .login-box .login-btn::after {
            animation: loginBtnIdleShine 6s ease-in-out 1.6s infinite;
        }
        @keyframes loginBtnIdleShine {
            0% { transform: translateX(-120%); }
            14% { transform: translateX(120%); }
            100% { transform: translateX(120%); }
        }
        @media (prefers-reduced-motion: reduce) {
            .login-hero-title {
                background: none;
                -webkit-text-fill-color: #f8fafc;
                color: #f8fafc;
                animation: none;
            }
            .login-hero-meta li,
            .login-brand-mark,
            .login-box .login-btn::after { animation: none; }
        }

        .login-error {
            color: #fecaca;
            font-size: 13px;
            text-align: center;
            margin-top: 8px;
            min-height: 18px;
            position: relative;
            z-index: 1;
        }
        .login-footer {
            display: flex;
            flex-wrap: wrap;
            gap: 8px 12px;
            align-items: center;
            justify-content: center;
            text-align: center;
            margin-top: 18px;
            position: relative;
            z-index: 1;
        }
        .login-demo-toggle {
            background: none;
            border: none;
            color: rgba(148, 163, 184, 0.95);
            font-size: 12px;
            letter-spacing: 0.08em;
            cursor: pointer;
            padding: 6px 10px;
            border-radius: 8px;
            transition: color 0.2s, background 0.2s;
            font-family: inherit;
        }
        .login-demo-toggle:hover {
            color: #e2e8f0;
            background: rgba(148, 163, 184, 0.12);
        }
        .login-demo {
            margin-top: 10px;
            padding: 12px;
            border-radius: 14px;
            background: rgba(2, 6, 23, 0.35);
            border: 1px solid rgba(148, 163, 184, 0.16);
            text-align: left;
        }
        .login-demo[hidden] { display: none !important; }
        .login-demo-note {
            font-size: 12px;
            color: rgba(148, 163, 184, 0.9);
            margin-bottom: 10px;
        }
        .login-demo-note code {
            font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
            color: #7dd3fc;
            background: rgba(14, 165, 233, 0.12);
            padding: 1px 6px;
            border-radius: 4px;
        }
        .login-demo-chips {
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
        }
        .login-demo-chips button {
            border: 1px solid rgba(125, 211, 252, 0.28);
            background: rgba(14, 165, 233, 0.1);
            color: #e0f2fe;
            border-radius: 999px;
            padding: 6px 12px;
            font-size: 12px;
            cursor: pointer;
            font-family: inherit;
            transition: background 0.2s, border-color 0.2s;
        }
        .login-demo-chips button:hover {
            background: rgba(14, 165, 233, 0.22);
            border-color: rgba(125, 211, 252, 0.5);
        }
        .login-attempt-warning {
            background: rgba(255, 237, 213, 0.94);
            border: 1px solid rgba(253, 186, 116, 0.7);
            border-radius: 12px;
            padding: 12px;
            margin-bottom: 12px;
            font-size: 13px;
            color: #9a3412;
            position: relative;
            z-index: 1;
        }
        @media (max-width: 900px) {
            .login-stage {
                grid-template-columns: 1fr;
                /* 登录框优先出现在首屏，避免被左侧文案顶出视口 */
                grid-template-areas:
                    "box"
                    "hero";
                padding-top: max(24px, env(safe-area-inset-top, 0px));
                padding-bottom: max(28px, env(safe-area-inset-bottom, 0px));
                align-content: start;
                gap: 20px;
            }
            .login-hero {
                grid-area: hero;
                text-align: center;
                max-width: none;
                animation-name: loginCardIn;
            }
            .login-box,
            .login-register-box {
                grid-area: box;
                max-width: 420px;
                margin: 0 auto;
                width: 100%;
            }
            .login-hero-title { font-size: clamp(28px, 8vw, 40px); }
            .login-hero-desc { margin-left: auto; margin-right: auto; }
            .login-hero-meta { align-items: center; }
            .login-hero-meta li { justify-content: center; }
            /* 窄屏弱化装饰粒子/光环，减轻「一直在加载」的观感与耗电 */
            .login-particles,
            .login-ring { display: none; }
        }
        @media (max-width: 480px) {
            .login-box { padding: 28px 20px 22px; border-radius: 18px; }
            .login-hero-kicker { margin-bottom: 10px; letter-spacing: 0.14em; }
            .login-hero-desc { font-size: 13px; margin-bottom: 14px; }
            .login-hero-meta { display: none; }
            .login-skyline { height: 72px; opacity: 0.4; }
            .login-hint { display: none; }
        }

        /* ========== 账号管理样式 ========== */
        .account-toolbar {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 16px;
            flex-wrap: wrap;
            gap: 10px;
        }
        .account-toolbar .toolbar-left {
            display: flex;
            gap: 8px;
            align-items: center;
        }
        .account-toolbar .toolbar-right {
            display: flex;
            gap: 8px;
            align-items: center;
        }
        .role-badge {
            display: inline-block;
            padding: 2px 10px;
            border-radius: 12px;
            font-size: 12px;
            font-weight: 600;
        }
        .role-badge.admin { background: #ffebee; color: #c62828; }
        .role-badge.leader { background: #e3f2fd; color: #1565c0; }
        .role-badge.student { background: #e8f5e9; color: #2e7d32; }
        .role-badge.visitor { background: #fff3e0; color: #e65100; }
        .status-dot {
            display: inline-block;
            width: 8px; height: 8px;
            border-radius: 50%;
            margin-right: 4px;
        }
        .status-dot.active { background: #4caf50; }
        .status-dot.disabled { background: #f44336; }
        .permission-matrix {
            width: 100%;
            border-collapse: collapse;
            margin-top: 12px;
        }
        .permission-matrix th,
        .permission-matrix td {
            border: 1px solid #e0e0e0;
            padding: 10px 12px;
            text-align: center;
            font-size: 13px;
        }
        .permission-matrix th {
            background: #f5f5f5;
            font-weight: 600;
        }
        .permission-matrix td:first-child {
            text-align: left;
            font-weight: 500;
        }
        .perm-check {
            width: 16px; height: 16px;
            cursor: pointer;
        }
        .perm-yes { color: #4caf50; font-weight: bold; }
        .perm-no { color: #e0e0e0; }
        .password-strength-bar {
            height: 4px;
            border-radius: 2px;
            background: #e0e0e0;
            margin-top: 6px;
            overflow: hidden;
        }
        .password-strength-bar .fill {
            height: 100%;
            border-radius: 2px;
            transition: width 0.3s, background 0.3s;
        }
        .password-strength-text {
            font-size: 12px;
            margin-top: 4px;
        }
        /* login-attempt-warning 样式已并入登录页高级样式 */
        .user-info-bar {
            display: flex;
            align-items: center;
            gap: 10px;
            font-size: 14px;
        }
        .user-info-bar .avatar-circle {
            width: 32px; height: 32px;
            border-radius: 50%;
            background: #667eea;
            color: white;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 14px;
            overflow: hidden;
            flex-shrink: 0;
        }
        .tab-nav {
            display: flex;
            border-bottom: 2px solid #e0e0e0;
            margin-bottom: 20px;
        }
        .tab-nav .tab-btn {
            padding: 10px 20px;
            cursor: pointer;
            border: none;
            background: none;
            font-size: 14px;
            font-weight: 500;
            color: #666;
            border-bottom: 2px solid transparent;
            margin-bottom: -2px;
            transition: all 0.2s;
        }
        .tab-nav .tab-btn.active {
            color: #667eea;
            border-bottom-color: #667eea;
        }
        .tab-nav .tab-btn:hover { color: #667eea; }

        /* ========== 文件库样式 ========== */
        .file-type-btn {
            padding: 6px 16px;
            border: 1px solid #e0e0e0;
            background: #fff;
            border-radius: 20px;
            font-size: 13px;
            cursor: pointer;
            transition: all 0.2s;
            color: #666;
        }
        .file-type-btn:hover {
            border-color: #7c3aed;
            color: #7c3aed;
        }
        .file-type-btn.active {
            background: #7c3aed;
            border-color: #7c3aed;
            color: #fff;
        }
        .type-count {
            display: inline-block;
            background: rgba(255,255,255,0.25);
            padding: 0 6px;
            border-radius: 10px;
            font-size: 11px;
            margin-left: 4px;
            min-width: 16px;
            text-align: center;
        }
        .file-type-btn:not(.active) .type-count {
            background: #f0f0f0;
            color: #999;
        }

        .file-card-item:hover .file-card-icon {
            transform: scale(1.1) rotate(-5deg);
        }

        .file-list-row:hover .file-list-icon {
            transform: scale(1.15);
        }

        /* ========== 系统配置样式 ========== */
        .config-tabs {
            display: flex;
            background: #f8fafc;
            border-bottom: 2px solid #e2e8f0;
            padding-left: 16px;
        }
        .config-tabs .tab-btn {
            padding: 12px 20px;
            cursor: pointer;
            border: none;
            background: none;
            font-size: 14px;
            font-weight: 500;
            color: #64748b;
            border-bottom: 2px solid transparent;
            margin-bottom: -2px;
            transition: all 0.2s;
            display: flex;
            align-items: center;
            gap: 6px;
        }
        .config-tabs .tab-btn.active {
            color: #7c3aed;
            border-bottom-color: #7c3aed;
            background: #fff;
        }
        .config-tabs .tab-btn:hover {
            color: #7c3aed;
            background: #f0f5ff;
        }
        .config-content {
            padding: 24px;
            min-height: 300px;
        }
        .config-form {
            max-width: 700px;
        }
        .config-form .form-group {
            margin-bottom: 20px;
        }
        .config-form label {
            display: block;
            font-weight: 500;
            color: #334155;
            margin-bottom: 8px;
            font-size: 14px;
        }
        .config-desc {
            display: block;
            font-size: 12px;
            color: #94a3b8;
            margin-top: 6px;
        }
        .toggle-switch {
            position: relative;
            display: inline-block;
            width: 56px;
            height: 28px;
            cursor: pointer;
        }
        .toggle-switch input {
            opacity: 0;
            width: 0;
            height: 0;
        }
        .toggle-switch .slider {
            position: absolute;
            cursor: pointer;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background-color: #cbd5e1;
            transition: 0.3s;
            border-radius: 28px;
        }
        .toggle-switch .slider:before {
            position: absolute;
            content: "";
            height: 22px;
            width: 22px;
            left: 3px;
            bottom: 3px;
            background-color: white;
            transition: 0.3s;
            border-radius: 50%;
            box-shadow: 0 2px 4px rgba(0,0,0,0.1);
        }
        .toggle-switch input:checked + .slider {
            background-color: #7c3aed;
        }
        .toggle-switch input:checked + .slider:before {
            transform: translateX(28px);
        }
        .config-action-bar {
            padding: 16px 24px;
            border-top: 1px solid #e2e8f0;
            display: flex;
            justify-content: center;
            gap: 12px;
            background: #fafafa;
        }

        /* ========== 账号管理样式 ========== */
        .footer {
            background: #7c3aed;
            color: white;
            padding: 18px 20px 16px;
            text-align: center;
            font-size: 12px;
            line-height: 1.8;
        }
        
        .footer p {
            margin: 4px 0;
            color: rgba(255,255,255,0.88);
        }
        
        /* Excel 处理模块新样式 */
        .upload-area:hover {
            background-color: rgba(138, 43, 226, 0.1);
            border-color: #8A2BE2;
        }
        
        .upload-area.drag-over {
            background-color: rgba(138, 43, 226, 0.2);
            border-color: #8A2BE2;
            transform: scale(1.02);
        }
        
        #naturalLanguageInput:focus {
            border-color: #8A2BE2;
            box-shadow: 0 0 0 3px rgba(138, 43, 226, 0.1);
        }
        
        .autocomplete-item {
            padding: 10px 15px;
            cursor: pointer;
            border-bottom: 1px solid #f0f0f0;
            transition: background-color 0.2s;
        }
        
        .autocomplete-item:hover {
            background-color: #f3e5f5;
        }
        
        .autocomplete-item:last-child {
            border-bottom: none;
        }
        
        .chart-container {
            width: 850px;
            height: 550px;
            background: white;
            border-radius: 12px;
            padding: 20px;
            box-shadow: 0 2px 12px rgba(0,0,0,0.15);
            position: relative;
        }
        
        .loading-spinner {
            display: inline-block;
            width: 20px;
            height: 20px;
            border: 3px solid rgba(138, 43, 226, 0.3);
            border-radius: 50%;
            border-top-color: #8A2BE2;
            animation: spin 1s linear infinite;
            margin-right: 10px;
        }
        
        @keyframes spin {
            to { transform: rotate(360deg); }
        }
        
        .status-message {
            padding: 15px;
            border-radius: 8px;
            margin: 10px 0;
            animation: slideIn 0.3s ease-out;
        }
        
        .status-message.success {
            background: #d4edda;
            border: 1px solid #c3e6cb;
            color: #155724;
        }
        
        .status-message.error {
            background: #f8d7da;
            border: 1px solid #f5c6cb;
            color: #721c24;
        }
        
        .status-message.info {
            background: #d1ecf1;
            border: 1px solid #bee5eb;
            color: #0c5460;
        }
        
        @keyframes slideIn {
            from { opacity: 0; transform: translateY(-10px); }
            to { opacity: 1; transform: translateY(0); }
        }

        /* ============================================
           团队成果模块 - 全局统一规范样式
           ============================================ */
        
        /* 全局变量定义 */
        :root {
            --ach-primary: #165DFF;      /* 主色-科技深蓝 */
            --ach-primary-light: #E8F3FF; /* 主色浅蓝背景 */
            --ach-success: #00B42A;       /* 增长绿色 */
            --ach-bg: #F5F7FA;            /* 页面背景 */
            --ach-white: #FFFFFF;         /* 卡片白色 */
            --ach-title: #1D2129;         /* 标题深色 */
            --ach-body: #4E5969;          /* 正文灰色 */
            --ach-helper: #86909C;        /* 辅助小字 */
            --ach-border: #E5E6EB;        /* 边框灰色 */
            --ach-card-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.04);
            --ach-card-radius: 8px;       /* 大卡片圆角 */
            --ach-tag-radius: 4px;        /* 标签圆角 */
            --ach-transition: all 0.3s ease;
        }

        /* 基础背景设置 */
        body.achievements-body {
            background: var(--ach-bg) !important;
        }

        /* 页面主标题 */
        .achievements-page-title {
            font-size: 24px;
            font-weight: 700;
            color: var(--ach-title);
            margin-bottom: 24px;
        }

        /* 模块标题 */
        .achievements-module-title {
            font-size: 18px;
            font-weight: 600;
            color: var(--ach-title);
            margin-bottom: 24px;
            padding-left: 12px;
            border-left: 4px solid var(--ach-primary);
        }

        /* ============================================
           顶部核心总览看板
           ============================================ */
        .achievements-stats-grid {
            display: grid;
            grid-template-columns: repeat(5, 1fr);
            gap: 20px;
            margin-bottom: 32px;
            align-items: stretch;
        }

        .achievements-stat-card {
            background: var(--ach-white);
            padding: 24px 20px;
            border-radius: var(--ach-card-radius);
            box-shadow: var(--ach-card-shadow);
            text-align: center;
            transition: var(--ach-transition);
            cursor: pointer;
            display: flex;
            flex-direction: column;
            justify-content: center;
        }

        .achievements-stat-card:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 16px rgba(22, 93, 255, 0.15);
        }

        .achievements-stat-label {
            font-size: 14px;
            font-weight: 400;
            color: var(--ach-body);
            margin-bottom: 12px;
        }

        .achievements-stat-number {
            font-size: 30px;
            font-weight: 700;
            color: var(--ach-primary);
            margin-bottom: 8px;
            line-height: 1.2;
        }

        .achievements-stat-unit {
            font-size: 14px;
            font-weight: 400;
            color: var(--ach-body);
            margin-left: 4px;
        }

        .achievements-stat-sub {
            font-size: 12px;
            font-weight: 400;
            color: var(--ach-helper);
            margin-top: 4px;
        }

        .achievements-stat-growth {
            color: var(--ach-success);
            font-weight: 600;
        }

        /* ============================================
           双栏业绩卡片
           ============================================ */
        .achievements-two-columns {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 24px;
            margin-bottom: 32px;
            align-items: stretch;
        }

        .achievements-section-card {
            background: var(--ach-white);
            border-radius: var(--ach-card-radius);
            padding: 24px;
            box-shadow: var(--ach-card-shadow);
            display: flex;
            flex-direction: column;
        }

        .achievements-comparison-grid {
            flex: 1;
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 16px;
        }

        .achievements-year-box {
            display: flex;
            flex-direction: column;
        }

        .achievements-data-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 10px;
        }

        .achievements-data-values {
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .achievements-section-title {
            display: flex;
            align-items: center;
            gap: 10px;
            margin-bottom: 20px;
        }

        .achievements-section-badge {
            background: var(--ach-primary-light);
            color: var(--ach-primary);
            padding: 6px 14px;
            border-radius: var(--ach-tag-radius);
            font-size: 13px;
            font-weight: 500;
        }

        .achievements-section-header {
            font-size: 18px;
            font-weight: 600;
            color: var(--ach-title);
            margin: 0;
        }

        .achievements-comparison-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 16px;
        }

        .achievements-year-box {
            background: var(--ach-bg);
            padding: 16px;
            border-radius: var(--ach-card-radius);
        }

        .achievements-year-title {
            font-size: 14px;
            font-weight: 600;
            color: var(--ach-title);
            margin-bottom: 16px;
        }

        .achievements-data-item {
            padding: 10px 0;
            border-bottom: 1px solid var(--ach-border);
            font-size: 14px;
            color: var(--ach-body);
        }

        .achievements-data-item:last-child {
            border-bottom: none;
        }

        .achievements-data-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 10px;
        }

        .achievements-data-row:last-child {
            margin-bottom: 0;
        }

        .achievements-data-label {
            font-size: 14px;
            color: var(--ach-body);
            flex-shrink: 0;
        }

        .achievements-data-values {
            display: flex;
            align-items: center;
            gap: 10px;
            justify-content: flex-end;
        }

        .achievements-data-old {
            font-size: 14px;
            color: var(--ach-helper);
            text-align: right;
            min-width: 40px;
        }

        .achievements-data-arrow {
            color: var(--ach-helper);
            text-align: center;
        }

        .achievements-data-new {
            font-weight: 600;
            color: var(--ach-primary);
            text-align: right;
            min-width: 50px;
        }

        .achievements-data-growth {
            color: #00B42A;
            font-weight: 600;
            font-size: 14px;
            text-align: right;
            min-width: 60px;
        }

        .achievements-new-badge {
            display: inline-block;
            background: #E8F3FF;
            color: var(--ach-primary);
            font-size: 11px;
            padding: 2px 6px;
            border-radius: 4px;
            margin-left: 6px;
            font-weight: 500;
        }

        .achievements-chart-wrapper {
            background: var(--ach-bg);
            padding: 16px;
            border-radius: var(--ach-card-radius);
            display: flex;
            flex-direction: column;
            justify-content: center;
            align-items: center;
        }

        .achievements-pie-chart {
            width: 140px;
            height: 140px;
            border-radius: 50%;
            position: relative;
            margin-bottom: 12px;
            background: conic-gradient(
                var(--ach-primary) 0deg 252deg,
                #3b82f6 252deg 360deg
            );
        }

        .achievements-pie-chart::before {
            content: '';
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            width: 80px;
            height: 80px;
            background: var(--ach-bg);
            border-radius: 50%;
        }

        .achievements-chart-legend {
            display: flex;
            flex-direction: column;
            gap: 8px;
            width: 100%;
        }

        .achievements-legend-item {
            display: flex;
            align-items: center;
            gap: 8px;
            font-size: 12px;
            color: var(--ach-body);
        }

        .achievements-legend-color {
            width: 12px;
            height: 12px;
            border-radius: 3px;
            flex-shrink: 0;
        }

        .achievements-legend-text {
            flex: 1;
        }

        .achievements-legend-percent {
            font-weight: 600;
            color: var(--ach-title);
        }

        /* ============================================
           重磅里程碑成果时间线
           ============================================ */
        .achievements-timeline {
            margin-bottom: 32px;
        }

        .achievements-timeline-item {
            display: flex;
            gap: 20px;
            margin-bottom: 32px;
            position: relative;
        }

        .achievements-timeline-line {
            width: 2px;
            background: var(--ach-border);
            border-radius: 1px;
            position: relative;
            flex-shrink: 0;
        }

        .achievements-timeline-dot {
            width: 8px;
            height: 8px;
            background: var(--ach-primary);
            border-radius: 50%;
            position: absolute;
            top: 4px;
            left: -3px;
            border: 2px solid var(--ach-white);
            box-shadow: 0 0 0 2px var(--ach-primary);
            transition: all 0.3s ease;
            z-index: 1;
        }

        .achievements-timeline-item:hover .achievements-timeline-dot {
            transform: scale(1.4);
            box-shadow: 0 0 0 4px var(--ach-primary-light);
        }

        .achievements-timeline-date {
            min-width: 80px;
            font-size: 12px;
            font-weight: 600;
            color: var(--ach-primary);
            padding-top: 6px;
            flex-shrink: 0;
            line-height: 1.2;
        }

        .achievements-timeline-content {
            flex: 1;
            background: var(--ach-white);
            padding: 20px 24px;
            border-radius: var(--ach-card-radius);
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
            transition: all 0.3s ease;
        }

        .achievements-timeline-item:hover .achievements-timeline-content {
            transform: translateY(-2px);
            box-shadow: 0 4px 16px rgba(22, 93, 255, 0.1);
        }

        .achievements-timeline-content h4 {
            color: var(--ach-title);
            font-size: 16px;
            font-weight: 600;
            margin: 0 0 8px;
            line-height: 1.5;
        }

        .achievements-timeline-content p {
            color: var(--ach-body);
            font-size: 14px;
            font-weight: 400;
            line-height: 1.5;
            margin: 0 0 8px;
        }

        .achievements-timeline-content .highlight {
            font-weight: 600;
            color: var(--ach-primary);
        }

        .achievements-timeline-tags {
            display: flex;
            gap: 8px;
            margin-top: 12px;
            flex-wrap: wrap;
        }

        .achievements-timeline-tag {
            background: #E8F3FF;
            color: var(--ach-primary);
            font-size: 12px;
            font-weight: 400;
            padding: 4px 10px;
            border-radius: 4px;
        }

        /* ============================================
           分类成果三栏卡片
           ============================================ */
        .achievements-three-columns {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 24px;
            margin-bottom: 32px;
            align-items: stretch;
        }

        .achievements-category-card {
            background: var(--ach-white);
            border-radius: var(--ach-card-radius);
            padding: 24px;
            box-shadow: var(--ach-card-shadow);
            display: flex;
            flex-direction: column;
        }

        .achievements-category-list {
            flex: 1;
        }

        .achievements-category-header {
            display: flex;
            align-items: center;
            gap: 12px;
            margin-bottom: 20px;
            padding-bottom: 16px;
            border-bottom: 1px solid var(--ach-border);
        }

        .achievements-category-icon {
            font-size: 28px;
            line-height: 1;
            flex-shrink: 0;
        }

        .achievements-category-name {
            font-size: 18px;
            font-weight: 600;
            color: var(--ach-title);
            flex: 1;
            line-height: 1.3;
        }

        .achievements-category-count {
            background: #165DFF;
            color: white;
            font-size: 14px;
            font-weight: 600;
            padding: 4px 12px;
            border-radius: 4px;
            flex-shrink: 0;
        }

        .achievements-category-list {
            display: flex;
            flex-direction: column;
            gap: 8px;
        }

        .achievements-category-item {
            background: #F5F7FA;
            padding: 12px;
            border-radius: 4px;
            border-left: 3px solid #165DFF;
        }

        .achievements-category-item h5 {
            font-size: 14px;
            font-weight: 600;
            color: var(--ach-title);
            margin: 0 0 6px;
            line-height: 1.4;
        }

        .achievements-category-item p {
            font-size: 12px;
            font-weight: 400;
            color: var(--ach-helper);
            margin: 0;
            line-height: 1.6;
        }

        .achievements-category-item .highlight-number {
            font-weight: 600;
            color: #165DFF;
        }

        /* ============================================
           统一页脚
           ============================================ */
        .achievements-footer {
            background: var(--ach-primary);
            padding: 20px 24px;
            border-radius: var(--ach-card-radius);
            text-align: center;
            color: var(--ach-white);
            font-size: 13px;
            font-weight: 400;
        }

        .achievements-footer a {
            color: var(--ach-white);
            text-decoration: none;
        }

        .achievements-footer a:hover {
            text-decoration: underline;
        }

        /* ============================================
           详情弹窗样式
           ============================================ */
        .modal {
            display: none;
            position: fixed;
            z-index: 1000;
            left: 0;
            top: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0,0,0,0.5);
            animation: fadeIn 0.3s ease;
        }

        .modal-content {
            background-color: white;
            margin: 10% auto;
            padding: 0;
            border-radius: 8px;
            width: 90%;
            max-width: 600px;
            box-shadow: 0 4px 20px rgba(0,0,0,0.15);
            animation: slideIn 0.3s ease;
        }

        .modal-header {
            background: #165DFF;
            color: white;
            padding: 20px 24px;
            border-bottom: 1px solid #e5e6eb;
            display: flex;
            justify-content: space-between;
            align-items: center;
            border-radius: 8px 8px 0 0;
        }

        .modal-header h3 {
            margin: 0;
            font-size: 18px;
            font-weight: 600;
        }

        .modal-close {
            color: white;
            font-size: 24px;
            font-weight: bold;
            cursor: pointer;
        }

        .modal-close:hover {
            color: #f0f0f0;
        }

        .modal-body {
            padding: 24px;
            line-height: 1.6;
        }

        .modal-body p {
            margin-bottom: 16px;
        }

        .modal-body ul {
            margin: 16px 0;
            padding-left: 24px;
        }

        .modal-body li {
            margin-bottom: 8px;
        }

        .modal-footer {
            padding: 16px 24px;
            border-top: 1px solid #e5e6eb;
            text-align: right;
        }

        .modal-close-btn {
            background: #165DFF;
            color: white;
            border: none;
            padding: 8px 20px;
            border-radius: 4px;
            font-size: 14px;
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .modal-close-btn:hover {
            background: #0f48c9;
        }

        @keyframes fadeIn {
            from { opacity: 0; }
            to { opacity: 1; }
        }

        @keyframes slideIn {
            from { transform: translateY(-50px); opacity: 0; }
            to { transform: translateY(0); opacity: 1; }
        }

        /* ============================================
           响应式适配
           ============================================ */
        @media (max-width: 1200px) {
            .achievements-stats-grid {
                grid-template-columns: repeat(3, 1fr);
            }
            
            .achievements-stat-card:nth-child(4),
            .achievements-stat-card:nth-child(5) {
                grid-column: span 1;
            }
            
            .achievements-three-columns {
                grid-template-columns: repeat(2, 1fr);
            }
            
            .achievements-three-columns .achievements-category-card:last-child {
                grid-column: span 2;
                justify-self: center;
                width: 50%;
            }
        }

        @media (max-width: 900px) {
            .achievements-two-columns {
                grid-template-columns: 1fr;
            }
            
            .achievements-three-columns {
                grid-template-columns: 1fr;
            }
            
            .achievements-three-columns .achievements-category-card:last-child {
                grid-column: span 1;
                width: 100%;
            }
        }

        @media (max-width: 768px) {
            .achievements-stats-grid {
                grid-template-columns: repeat(2, 1fr);
            }
            
            .achievements-stat-card:nth-child(5) {
                grid-column: span 2;
            }
            
            .achievements-two-columns,
            .achievements-three-columns {
                grid-template-columns: 1fr;
            }
            
            .achievements-three-columns .achievements-category-card:last-child {
                grid-column: span 1;
                width: 100%;
            }
            
            .achievements-comparison-grid {
                grid-template-columns: 1fr;
            }
            
            .achievements-timeline-item {
                flex-direction: column;
                gap: 12px;
                padding-left: 20px;
            }
            
            .achievements-timeline-line {
                position: absolute;
                left: 0;
                top: 0;
                height: 100%;
                width: 2px;
            }
            
            .achievements-timeline-date {
                padding-top: 0;
                text-align: left;
                font-size: 12px;
                font-weight: 600;
                color: var(--ach-primary);
            }
            
            .achievements-timeline-content {
                padding: 16px 20px;
            }
            
            .achievements-timeline-content h4 {
                font-size: 15px;
                margin-bottom: 6px;
            }
            
            .achievements-timeline-content p {
                font-size: 13px;
                line-height: 1.4;
                margin-bottom: 6px;
            }
            
            .achievements-timeline-line {
                width: 2px;
            }
        }
/* Keep every business surface out of the initial unauthenticated render. */
body.auth-locked > .top-nav,
body.auth-locked > .cloud-sync-fab,
body.auth-locked > .sidebar-backdrop,
body.auth-locked > .app-shell {
    display: none !important;
}
