/* ==========================================================================
   亮见AI管理 核心设计系统 (style.css)
   ========================================================================== */

/* 1. 变量定义与主题配置 */
:root {
    /* 品牌色彩系统 */
    --color-bg-dark: #070b19;      /* 钛黑深底 (用于控制台和深色区) */
    --color-bg-light: #f4f6f9;     /* 浅灰底 (用于浅色区) */
    --color-card-dark: #0d1222;    /* 深色卡片背景 */
    --color-card-light: #ffffff;   /* 浅色卡片背景 */
    --color-border-dark: #1f2b48;  /* 深色边框 */
    --color-border-light: #e2e8f0; /* 浅色边框 */
    
    --color-primary: #00b4d8;      /* 科技青 */
    --color-primary-hover: #0077b6;
    --color-secondary: #0096c7;    /* 工业蓝 */
    --color-accent: #10b981;       /* 激活绿 */
    --color-accent-hover: #059669;
    --color-warning: #f59e0b;      /* 警告橙 */
    --color-danger: #ef4444;       /* 警报红 */
    
    --color-text-primary-dark: #f8fafc;   /* 深底主文字 */
    --color-text-secondary-dark: #94a3b8; /* 深底次文字 */
    --color-text-primary-light: #0f172a;  /* 浅底主文字 */
    --color-text-secondary-light: #475569;/* 浅底次文字 */

    /* 辅助属性 */
    --font-family: 'Outfit', 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --border-radius-sm: 6px;
    --border-radius-md: 12px;
    --border-radius-lg: 20px;
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 8px 30px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.12);
    --shadow-cyan-glow: 0 0 20px rgba(0, 180, 216, 0.25);
    --shadow-green-glow: 0 0 20px rgba(16, 185, 129, 0.2);
}

/* 2. 基础重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    background-color: var(--color-bg-light);
    color: var(--color-text-primary-light);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-smooth);
}

button, input, select, textarea {
    font-family: inherit;
    outline: none;
}

/* 3. 公共布局与工具类 */
.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }

/* 按钮组件 */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: var(--border-radius-sm);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition-smooth);
    border: none;
    gap: 8px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    color: #fff;
    box-shadow: var(--shadow-cyan-glow);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 25px rgba(0, 180, 216, 0.4);
}

.btn-accent {
    background: var(--color-accent);
    color: var(--color-bg-dark);
}
.btn-accent:hover {
    background: var(--color-accent-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-green-glow);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--color-border-dark);
    color: var(--color-text-secondary-dark);
}
.btn-outline:hover {
    border-color: var(--color-primary);
    color: var(--color-text-primary-dark);
    background-color: rgba(255, 255, 255, 0.05);
}

/* 毛玻璃材质 */
.glass-effect {
    background: rgba(18, 25, 44, 0.75);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

/* 4. 全局 Header 导航栏 */
.header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(7, 11, 25, 0.9);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--color-border-dark);
    color: var(--color-text-primary-dark);
    height: 80px;
    transition: var(--transition-smooth);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-text h2 {
    font-size: 15px;
    font-weight: 700;
}
.logo-text p {
    font-size: 11px;
    color: var(--color-text-secondary-dark);
}

.nav-menu {
    display: flex;
    gap: 24px;
    list-style: none;
}

.nav-link {
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text-secondary-dark);
    position: relative;
    padding: 8px 0;
}
.nav-link:hover, .nav-link.active {
    color: var(--color-primary);
}
.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-primary);
    transition: var(--transition-smooth);
}
.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

.header-cta {
    display: flex;
    align-items: center;
    gap: 16px;
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
}
.hamburger span {
    width: 24px;
    height: 2px;
    background-color: #fff;
    transition: var(--transition-smooth);
}

/* 5. 首页内容样式 (Home View) */

/* Hero 首屏 */
.hero-section {
    background-color: var(--color-bg-dark);
    color: #fff;
    padding: 100px 0;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(0, 180, 216, 0.15) 0%, transparent 70%);
    pointer-events: none;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 48px;
    align-items: center;
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
}

.badge-new {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--color-border-dark);
    padding: 6px 16px;
    border-radius: 100px;
    font-size: 12px;
    color: var(--color-text-secondary-dark);
}

.badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--color-accent);
    box-shadow: 0 0 10px var(--color-accent);
    animation: pulse 1.5s infinite;
}

.hero-title {
    font-size: 48px;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.5px;
}

.gradient-text {
    background: linear-gradient(135deg, var(--color-primary) 30%, var(--color-accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-desc {
    font-size: 17px;
    color: var(--color-text-secondary-dark);
    max-width: 540px;
}

.hero-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 8px;
}

.hero-tag {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 12px;
    color: var(--color-text-secondary-dark);
}

.hero-btns {
    display: flex;
    gap: 16px;
    margin-top: 12px;
}

/* 数字化看盘 Mockup */
.hero-mockup {
    position: relative;
    perspective: 1000px;
}

.mockup-window {
    background: var(--color-card-dark);
    border: 1px solid var(--color-border-dark);
    border-radius: var(--border-radius-md);
    padding: 20px;
    box-shadow: var(--shadow-lg), 0 0 40px rgba(0, 0, 0, 0.6);
    transform: rotateY(-5deg) rotateX(5deg);
    transition: transform 0.5s ease;
}
.mockup-window:hover {
    transform: rotateY(0deg) rotateX(0deg);
}

.window-header {
    display: flex;
    align-items: center;
    gap: 6px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 12px;
    margin-bottom: 16px;
}

.win-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}
.win-dot.red { background-color: var(--color-danger); }
.win-dot.yellow { background-color: var(--color-warning); }
.win-dot.green { background-color: var(--color-accent); }

.win-title {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.3);
    margin-left: 8px;
    font-family: monospace;
}

.mockup-dashboard {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.alert-bar {
    background: rgba(245, 158, 11, 0.08);
    border: 1px solid rgba(245, 158, 11, 0.2);
    border-radius: var(--border-radius-sm);
    padding: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.alert-info h4 {
    font-size: 11px;
    color: var(--color-warning);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.alert-info p {
    font-size: 13px;
    font-weight: 500;
    color: #fff;
}

.alert-status {
    font-size: 11px;
    background: rgba(245, 158, 11, 0.15);
    color: var(--color-warning);
    padding: 3px 8px;
    border-radius: 3px;
    animation: flash 1s infinite alternate;
}

.ai-terminal {
    background: #030712;
    border-radius: var(--border-radius-sm);
    padding: 16px;
    border: 1px solid var(--color-border-dark);
    font-family: monospace;
    font-size: 12px;
    color: #a7f3d0;
}

.terminal-header {
    color: var(--color-accent);
    margin-bottom: 8px;
}

.terminal-line {
    margin-bottom: 6px;
    color: #e2e8f0;
}

.terminal-btn {
    margin-top: 12px;
    background: rgba(0, 180, 216, 0.15);
    border: 1px solid rgba(0, 180, 216, 0.3);
    color: var(--color-primary);
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    transition: var(--transition-smooth);
}
.terminal-btn:hover {
    background: var(--color-primary);
    color: var(--color-bg-dark);
}

/* 痛点模块 */
.section {
    padding: 100px 0;
}
.section-dark {
    background-color: var(--color-bg-dark);
    color: #fff;
}

.section-header {
    text-align: center;
    max-width: 720px;
    margin: 0 auto 64px auto;
}

.section-label {
    font-size: 12px;
    font-weight: 700;
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 8px;
    display: block;
}

.section-title {
    font-size: 32px;
    font-weight: 800;
    color: inherit;
    line-height: 1.25;
}

.pain-card {
    background: var(--color-card-light);
    border: 1px solid var(--color-border-light);
    border-radius: var(--border-radius-md);
    padding: 40px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-smooth);
}
.pain-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
    border-color: rgba(0, 180, 216, 0.3);
}

.pain-icon {
    font-size: 28px;
    margin-bottom: 24px;
    display: inline-block;
    padding: 12px;
    background-color: #f1f5f9;
    border-radius: var(--border-radius-sm);
}

.pain-card h3 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 12px;
}

.pain-card p {
    font-size: 14px;
    color: var(--color-text-secondary-light);
    margin-bottom: 20px;
}

.pain-solution {
    background-color: #f0fdf4;
    border: 1px solid #dcfce7;
    border-radius: 6px;
    padding: 12px 16px;
    font-size: 12px;
    font-weight: 600;
    color: #166534;
}

/* 方法论模块 (三层方法论) */
.methodology-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    position: relative;
}

.method-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--color-border-dark);
    border-radius: var(--border-radius-md);
    padding: 32px;
    position: relative;
    transition: var(--transition-smooth);
}
.method-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--color-primary);
}

.method-num {
    font-size: 40px;
    font-weight: 800;
    color: rgba(0, 180, 216, 0.15);
    position: absolute;
    top: 20px;
    right: 24px;
}

.method-card h3 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--color-primary);
}

.method-card p {
    font-size: 14px;
    color: var(--color-text-secondary-dark);
}

/* 核心场景与工具预览卡片 */
.card-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.item-card {
    background: var(--color-card-light);
    border: 1px solid var(--color-border-light);
    border-radius: var(--border-radius-md);
    padding: 24px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: var(--transition-smooth);
    min-height: 280px;
}
.item-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
    border-color: rgba(0, 180, 216, 0.3);
}

.item-card-dark {
    background: var(--color-card-dark);
    border: 1px solid var(--color-border-dark);
    color: #fff;
    min-height: 320px;
}
.item-card-dark:hover {
    border-color: var(--color-primary);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.item-top {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.item-badge {
    align-self: flex-start;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
}
.badge-active { background: #dcfce7; color: #166534; }
.badge-beta { background: #fee2e2; color: #991b1b; }
.badge-plan { background: #f1f5f9; color: #475569; }

.badge-active-dark { background: rgba(16, 185, 129, 0.15); color: var(--color-accent); border: 1px solid rgba(16, 185, 129, 0.3); }
.badge-beta-dark { background: rgba(239, 68, 68, 0.15); color: var(--color-danger); border: 1px solid rgba(239, 68, 68, 0.3); }
.badge-plan-dark { background: rgba(148, 163, 184, 0.15); color: var(--color-text-secondary-dark); border: 1px solid rgba(148, 163, 184, 0.3); }

.item-title {
    font-size: 16px;
    font-weight: 700;
}

.item-desc {
    font-size: 13px;
    color: var(--color-text-secondary-light);
}
.item-card-dark .item-desc {
    color: var(--color-text-secondary-dark);
}

.item-features {
    list-style: none;
    margin: 12px 0 20px 0;
    font-size: 12px;
    color: var(--color-text-secondary-light);
}
.item-card-dark .item-features {
    color: var(--color-text-secondary-dark);
}
.item-features li {
    margin-bottom: 6px;
    padding-left: 12px;
    position: relative;
}
.item-features li::before {
    content: '▪';
    color: var(--color-primary);
    position: absolute;
    left: 0;
}

.item-btn {
    text-align: center;
    background: var(--color-bg-light);
    color: var(--color-text-primary-light);
    font-size: 12px;
    font-weight: 600;
    padding: 10px;
    border-radius: 6px;
    display: block;
}
.item-card-dark .item-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--color-border-dark);
    color: #fff;
}
.item-card-dark .item-btn:hover {
    background: var(--color-primary);
    color: var(--color-bg-dark);
    border-color: var(--color-primary);
}

/* 咨询转化与双轴 CTA */
.cta-box {
    background: var(--color-bg-dark);
    border: 1px solid var(--color-border-dark);
    border-radius: var(--border-radius-lg);
    padding: 64px;
    position: relative;
    overflow: hidden;
    color: #fff;
    box-shadow: var(--shadow-lg);
}

.cta-box::after {
    content: '';
    position: absolute;
    bottom: -100px;
    right: -100px;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.1) 0%, transparent 70%);
    pointer-events: none;
}

.cta-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 64px;
    align-items: center;
    position: relative;
    z-index: 5;
}

.cta-left {
    border-right: 1px solid rgba(255, 255, 255, 0.05);
    padding-right: 64px;
}

.cta-tag {
    background: rgba(16, 185, 129, 0.15);
    color: var(--color-accent);
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 4px;
    display: inline-block;
    margin-bottom: 12px;
}

.cta-title {
    font-size: 26px;
    font-weight: 800;
    margin-bottom: 16px;
}

.cta-desc {
    font-size: 14px;
    color: var(--color-text-secondary-dark);
    margin-bottom: 28px;
}

.qr-wrapper {
    display: flex;
    gap: 20px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--color-border-dark);
    padding: 20px;
    border-radius: var(--border-radius-md);
    max-width: 380px;
}

.qr-code {
    width: 80px;
    height: 80px;
    background: #fff;
    border-radius: 6px;
    padding: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.qr-code svg {
    width: 100%;
    height: 100%;
}

.qr-info h4 {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
}
.qr-info p {
    font-size: 11px;
    color: var(--color-text-secondary-dark);
    margin-top: 4px;
}

.cta-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.cta-form-title {
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 8px;
}

.form-row-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.form-input {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--color-border-dark);
    border-radius: 6px;
    padding: 12px;
    color: #fff;
    font-size: 13px;
    transition: var(--transition-smooth);
}
.form-input:focus {
    border-color: var(--color-primary);
    background: rgba(255, 255, 255, 0.08);
}

select.form-input {
    color: #94a3b8;
    appearance: none;
    -webkit-appearance: none;
}
select.form-input option {
    background-color: var(--color-bg-dark);
    color: #fff;
}

/* ==========================================================================
   6. 企业AI应用中心工作台样式
   ========================================================================== */
.tools-page {
    padding: 40px 0 80px 0;
    background-color: var(--color-bg-dark);
    color: #fff;
    min-height: calc(100vh - 80px);
}

.page-header {
    margin-bottom: 40px;
    text-align: center;
}

.page-title {
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 12px;
}

.page-desc {
    font-size: 15px;
    color: var(--color-text-secondary-dark);
    max-width: 640px;
    margin: 0 auto;
}

/* 控制台布局 */
.platform-console {
    background-color: #0b111e;
    border: 1px solid var(--color-border-dark);
    border-radius: var(--border-radius-lg);
    display: grid;
    grid-template-columns: 240px 1fr 340px;
    min-height: 800px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    margin-bottom: 64px;
}

/* 左侧分类 Sidebar */
.console-sidebar {
    background-color: #060913;
    border-right: 1px solid var(--color-border-dark);
    display: flex;
    flex-direction: column;
    padding: 24px 0;
}

.sidebar-title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.3);
    letter-spacing: 1px;
    padding: 0 24px;
    margin-bottom: 20px;
}

.center-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.center-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 24px;
    font-size: 13px;
    font-weight: 600;
    color: var(--color-text-secondary-dark);
    cursor: pointer;
    transition: var(--transition-smooth);
    border-left: 3px solid transparent;
}
.center-item:hover {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.02);
}
.center-item.active {
    color: var(--color-primary);
    background-color: rgba(0, 180, 216, 0.05);
    border-left-color: var(--color-primary);
}

.center-item-icon {
    font-size: 16px;
}

/* 中间主区 */
.console-main {
    padding: 32px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    background-color: #0b111e;
}

/* 子维度 Sub-Tabs */
.app-nav-tabs {
    display: flex;
    gap: 8px;
    border-bottom: 1px solid var(--color-border-dark);
    padding-bottom: 12px;
    overflow-x: auto;
    margin-top: 12px;
}

.app-tab {
    background: transparent;
    border: none;
    color: var(--color-text-secondary-dark);
    font-size: 13px;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    white-space: nowrap;
    transition: var(--transition-smooth);
}
.app-tab:hover {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.03);
}
.app-tab.active {
    color: var(--color-primary);
    background-color: rgba(0, 180, 216, 0.08);
}

/* 动态内容区 */
.workbench-content-area {
    margin-top: 24px;
}

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

/* 智能体卡片 */
.app-card {
    background-color: #111827;
    border: 1px solid var(--color-border-dark);
    border-radius: var(--border-radius-md);
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 220px;
    transition: var(--transition-smooth);
}
.app-card:hover {
    transform: translateY(-4px);
    border-color: rgba(0, 180, 216, 0.4);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.app-card-top {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.app-card-avatar {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.app-card-tag {
    font-size: 9px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
}

.fav-star-btn {
    background: none;
    border: none;
    color: #64748b;
    font-size: 16px;
    cursor: pointer;
    transition: var(--transition-smooth);
}
.fav-star-btn:hover {
    color: var(--color-warning);
}
.fav-star-btn.starred {
    color: var(--color-warning);
    text-shadow: 0 0 8px rgba(245, 158, 11, 0.4);
}

.app-card-title {
    font-size: 15px;
    font-weight: 700;
    color: #fff;
}

.app-card-desc {
    font-size: 12px;
    color: var(--color-text-secondary-dark);
    line-height: 1.5;
}

.app-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.03);
    padding-top: 12px;
}

.app-card-dept {
    font-size: 10px;
    color: #64748b;
}

/* 知识库拖拽模拟上传区 */
.kb-upload-panel {
    background: rgba(255, 255, 255, 0.01);
    border: 2px dashed var(--color-border-dark);
    border-radius: var(--border-radius-md);
    padding: 32px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition-smooth);
    margin-bottom: 24px;
}
.kb-upload-panel:hover {
    border-color: var(--color-primary);
    background: rgba(0, 180, 216, 0.02);
}
.kb-upload-icon {
    font-size: 32px;
    display: block;
    margin-bottom: 12px;
}
.kb-upload-panel h5 {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
}
.kb-upload-panel p {
    font-size: 11px;
    color: var(--color-text-secondary-dark);
    margin-top: 6px;
}

.kb-file-list-header {
    font-size: 13px;
    font-weight: 700;
    color: #94a3b8;
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
}

.kb-file-table {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.kb-file-row {
    background: #111827;
    border: 1px solid var(--color-border-dark);
    border-radius: 6px;
    padding: 12px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition-smooth);
}
.kb-file-row:hover {
    border-color: rgba(0, 180, 216, 0.2);
    transform: translateX(4px);
}
.kb-file-info {
    display: flex;
    align-items: center;
    gap: 12px;
}
.kb-file-info h6 {
    font-size: 13px;
    font-weight: 600;
    color: #fff;
}
.kb-file-info span {
    font-size: 10px;
    color: #64748b;
}

/* 数据库表格 */
.db-table-container {
    background: #111827;
    border: 1px solid var(--color-border-dark);
    border-radius: var(--border-radius-md);
    overflow: hidden;
}
.db-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 13px;
}
.db-table th {
    background: #090c17;
    padding: 14px 20px;
    color: #94a3b8;
    font-weight: 700;
    border-bottom: 1px solid var(--color-border-dark);
}
.db-table td {
    padding: 14px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    color: var(--color-text-secondary-dark);
}
.db-table tr:hover td {
    background: rgba(255, 255, 255, 0.01);
    color: #fff;
}
.db-status-badge {
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
}
.db-status-ok { background: rgba(16, 185, 129, 0.15); color: var(--color-accent); }
.db-status-sync { background: rgba(245, 158, 11, 0.15); color: var(--color-warning); }

/* ==========================================================================
   6B. WF-D2 问题描述工作台
   ========================================================================== */
.d2-workflow-page {
    background: #080d18;
    color: var(--color-text-primary-dark);
    min-height: calc(100vh - 80px);
    padding-bottom: 48px;
}

.d2-workflow-topbar {
    background: #0d1222;
    border-bottom: 1px solid var(--color-border-dark);
    padding: 16px 0;
}

.d2-topbar-inner,
.d2-topbar-left,
.d2-topbar-state {
    display: flex;
    align-items: center;
}

.d2-topbar-inner {
    justify-content: space-between;
    gap: 20px;
}

.d2-topbar-left {
    gap: 14px;
}

.d2-topbar-left .btn {
    padding: 7px 12px;
    font-size: 12px;
    border-color: rgba(255,255,255,0.15);
}

.d2-topbar-left h1 {
    font-size: 18px;
    line-height: 1.2;
    margin-bottom: 3px;
}

.d2-topbar-left p,
.d2-topbar-state {
    color: var(--color-text-secondary-dark);
    font-size: 12px;
}

.d2-topbar-state {
    gap: 8px;
    color: var(--color-accent);
    font-weight: 700;
}

.d2-workbench-grid {
    display: grid;
    max-width: 1500px;
    grid-template-columns: minmax(280px, var(--d2-left-width, 340px)) 12px minmax(0, 1fr);
    gap: 12px;
    padding-top: 24px;
    align-items: start;
}

.d2-input-rail {
    background: #0d1222;
    border: 1px solid var(--color-border-dark);
    border-radius: 8px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    position: sticky;
    top: 104px;
    max-height: calc(100vh - 128px);
    overflow-y: auto;
}

.d2-input-rail > * {
    flex-shrink: 0;
}

.d2-input-rail::-webkit-scrollbar,
.d2-main-workspace::-webkit-scrollbar,
.d2-table-wrap::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

.d2-input-rail::-webkit-scrollbar-thumb,
.d2-main-workspace::-webkit-scrollbar-thumb,
.d2-table-wrap::-webkit-scrollbar-thumb {
    background: #334155;
    border-radius: 3px;
}

.d2-panel-title,
.d2-action-buttons {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.d2-panel-title span {
    font-size: 14px;
    font-weight: 800;
}

.d2-panel-title .btn {
    padding: 6px 10px;
    font-size: 11px;
    border-color: rgba(255,255,255,0.15);
}

.d2-side-field {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.d2-side-field span {
    font-size: 12px;
    color: #cbd5e1;
    font-weight: 700;
}

.d2-side-field textarea,
.d2-payload-output,
#d2-rebrainstorm-payload {
    width: 100%;
    background: #070b19;
    border: 1px solid var(--color-border-dark);
    border-radius: 6px;
    color: #e2e8f0;
    font-size: 12px;
    line-height: 1.55;
    padding: 10px 12px;
    resize: vertical;
}

.d2-side-field textarea:focus,
#d2-rebrainstorm-payload:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 2px rgba(0, 180, 216, 0.12);
}

.d2-file-drop {
    border: 1px dashed #334155;
    border-radius: 8px;
    padding: 16px;
    text-align: center;
    cursor: pointer;
    background: rgba(255,255,255,0.02);
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
}

.d2-file-drop:hover {
    border-color: var(--color-primary);
    background: rgba(0,180,216,0.05);
}

.d2-file-drop.is-dragover {
    border-color: var(--color-accent);
    background: rgba(16,185,129,0.08);
}

.d2-file-drop input {
    display: none;
}

.d2-file-icon {
    font-size: 24px;
    color: var(--color-primary);
    line-height: 1;
}

.d2-file-drop strong {
    font-size: 13px;
    color: #fff;
}

.d2-file-drop small,
.d2-file-list {
    color: var(--color-text-secondary-dark);
    font-size: 11px;
}

.d2-file-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-top: -8px;
}

.d2-file-list li {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    border: 1px solid rgba(255,255,255,0.05);
    background: rgba(255,255,255,0.02);
    border-radius: 5px;
    padding: 6px 8px;
}

.d2-status {
    border: 1px solid rgba(0,180,216,0.25);
    background: rgba(0,180,216,0.08);
    color: #bae6fd;
    border-radius: 6px;
    padding: 9px 10px;
    font-size: 12px;
    line-height: 1.45;
}

.d2-status[data-tone="ok"] {
    border-color: rgba(16,185,129,0.3);
    background: rgba(16,185,129,0.08);
    color: #bbf7d0;
}

.d2-status[data-tone="warn"] {
    border-color: rgba(245,158,11,0.35);
    background: rgba(245,158,11,0.1);
    color: #fde68a;
}

.d2-resizer {
    width: 12px;
    min-height: calc(100vh - 128px);
    position: sticky;
    top: 104px;
    cursor: col-resize;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.58);
    border: 1px solid rgba(148, 163, 184, 0.16);
}

.d2-resizer span {
    width: 3px;
    height: 52px;
    border-radius: 999px;
    background: linear-gradient(180deg, #334155, #00b4d8, #334155);
    opacity: 0.8;
}

.d2-resizer:hover,
.d2-resizer:focus-visible,
body.is-d2-resizing .d2-resizer {
    background: rgba(0, 180, 216, 0.12);
    border-color: rgba(0, 180, 216, 0.45);
    outline: none;
}

body.is-d2-resizing {
    cursor: col-resize;
    user-select: none;
}

.d2-main-workspace {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
    overflow-x: auto;
}

.d2-paper {
    background: #ffffff;
    color: var(--color-text-primary-light);
    border-radius: 8px;
    padding: 26px;
    box-shadow: 0 18px 44px rgba(0,0,0,0.28);
    min-height: 760px;
    min-width: 980px;
}

.d2-paper-header,
.d2-chamber-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 18px;
}

.d2-paper-header {
    padding-bottom: 18px;
    border-bottom: 2px solid #0f172a;
    margin-bottom: 20px;
}

.d2-paper-kicker {
    display: block;
    color: #0f766e;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    margin-bottom: 5px;
}

.d2-paper-header h2 {
    font-size: 30px;
    line-height: 1.2;
    color: #0b3d91;
}

.d2-brand-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #0f172a;
    text-align: right;
}

.d2-brand-logo svg {
    width: 46px;
    height: 46px;
    flex-shrink: 0;
}

.d2-brand-logo strong {
    display: block;
    color: #0b3d91;
    font-size: 18px;
    line-height: 1.15;
    white-space: nowrap;
}

.d2-brand-logo span {
    display: block;
    color: #64748b;
    font-size: 10px;
    font-family: "Courier New", monospace;
    white-space: nowrap;
}

.d2-sheet-subtitle {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #111827;
    font-size: 18px;
    font-weight: 800;
    margin: 12px 0 12px 0;
}

.d2-sheet-subtitle span {
    color: #0b3d91;
    font-size: 24px;
    line-height: 1;
}

.d2-sheet-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.d2-sheet-panel {
    min-width: 0;
}

.d2-sheet-panel h3 {
    background: #0b3d91;
    color: #ffffff;
    border-radius: 7px 7px 0 0;
    text-align: center;
    font-size: 17px;
    font-weight: 800;
    padding: 8px 10px;
    line-height: 1.25;
}

.d2-sheet-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    border: 1px solid #2f62b3;
    background: #fff;
}

.d2-sheet-table th,
.d2-sheet-table td {
    border: 1px solid #8eaadc;
}

.d2-sheet-table thead th {
    background: #f8fafc;
    color: #0b3d91;
    font-size: 13px;
    font-weight: 800;
    text-align: center;
    padding: 7px;
}

.d2-sheet-table thead th:first-child {
    width: 76px;
}

.d2-dimension-cell {
    color: #0b3d91;
    font-size: 14px;
    font-weight: 900;
    text-align: center;
    vertical-align: middle;
    background: #ffffff;
}

.d2-sheet-cell {
    position: relative;
    vertical-align: top;
    background: #ffffff;
    padding: 0;
}

.d2-sheet-cell textarea {
    width: 100%;
    min-height: 86px;
    border: 0;
    resize: vertical;
    color: #111827;
    background: transparent;
    padding: 9px 10px 18px;
    font-size: 13px;
    line-height: 1.45;
}

.d2-sheet-cell textarea:focus {
    box-shadow: inset 0 0 0 2px rgba(11, 61, 145, 0.22);
}

.d2-sheet-cell small {
    position: absolute;
    right: 8px;
    bottom: 4px;
    color: #ea580c;
    font-size: 10px;
    font-weight: 800;
    pointer-events: none;
}

.d2-sheet-cell.is-ai-suggested {
    background: #fff8db;
}

.d2-sheet-cell.is-ai-suggested textarea {
    background: #fffde7;
}

.d2-next-action-card {
    margin-top: 12px;
    border: 1px solid #2f62b3;
    border-radius: 7px;
    padding: 11px 14px;
    color: #111827;
}

.d2-next-action-card strong {
    display: inline-block;
    background: #0b3d91;
    color: #ffffff;
    border-radius: 999px;
    padding: 4px 12px;
    font-size: 13px;
    margin-bottom: 6px;
}

.d2-next-action-card p {
    min-height: 68px;
    font-size: 13px;
    line-height: 1.55;
    padding-left: 12px;
    white-space: pre-wrap;
}

.d2-conclusion-row {
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid #2f62b3;
    border-radius: 6px;
    margin-top: 14px;
    padding: 9px 14px;
    font-size: 18px;
    line-height: 1.35;
}

.d2-conclusion-row span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #0b3d91;
    color: #ffffff;
    flex-shrink: 0;
}

.d2-conclusion-row strong {
    color: #0b3d91;
    font-weight: 900;
    white-space: nowrap;
}

.d2-conclusion-row p {
    flex: 1;
    min-height: 26px;
}

.d2-chamber {
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 18px;
    margin-bottom: 20px;
}

.d2-chamber.occurrence {
    border-top: 4px solid #0284c7;
}

.d2-chamber.detection {
    border-top: 4px solid #16a34a;
}

.d2-chamber-head {
    margin-bottom: 16px;
}

.d2-chamber-head span {
    color: #64748b;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.8px;
    text-transform: uppercase;
}

.d2-chamber-head h3 {
    font-size: 17px;
    margin-top: 3px;
}

.d2-chamber-head small {
    color: #64748b;
    font-size: 11px;
    white-space: nowrap;
}

.d2-5w-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 16px;
}

.d2-field {
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #f8fafc;
    padding: 9px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.d2-field span {
    font-size: 11px;
    font-weight: 800;
    color: #334155;
}

.d2-field textarea {
    width: 100%;
    min-height: 58px;
    resize: vertical;
    border: 1px solid #dbe3ee;
    border-radius: 5px;
    background: #fff;
    color: #0f172a;
    font-size: 12px;
    line-height: 1.5;
    padding: 8px;
}

.d2-field textarea:focus,
.d2-matrix-table textarea:focus,
.d2-matrix-table input:focus {
    border-color: #0284c7;
    box-shadow: 0 0 0 2px rgba(2,132,199,0.12);
}

.d2-field small {
    color: #64748b;
    font-size: 10px;
    line-height: 1.3;
}

.d2-field.is-ai-suggested {
    border-color: #f59e0b;
    background: #fff8db;
}

.d2-field.is-ai-suggested textarea {
    background: #fffde7;
    border-color: #f59e0b;
}

.d2-field.is-ai-suggested small {
    color: #92400e;
    font-weight: 700;
}

.d2-table-wrap {
    overflow-x: auto;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
}

.d2-matrix-table {
    width: 100%;
    min-width: 760px;
    border-collapse: collapse;
    font-size: 12px;
}

.d2-matrix-table th {
    background: #eff6ff;
    color: #1e3a8a;
    font-weight: 800;
    text-align: left;
    padding: 9px;
    border-bottom: 1px solid #cbd5e1;
}

.d2-matrix-table td {
    border-bottom: 1px solid #e2e8f0;
    border-right: 1px solid #e2e8f0;
    padding: 7px;
    vertical-align: top;
}

.d2-matrix-table td:last-child {
    border-right: 0;
}

.d2-matrix-table input,
.d2-matrix-table textarea {
    width: 100%;
    border: 1px solid #e2e8f0;
    border-radius: 5px;
    color: #0f172a;
    background: #fff;
    padding: 7px;
    font-size: 12px;
    line-height: 1.45;
    resize: vertical;
}

.d2-next-action {
    margin-top: 14px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-left: 4px solid #f59e0b;
    border-radius: 6px;
    padding: 12px;
}

.d2-next-action strong {
    display: block;
    color: #92400e;
    font-size: 12px;
    margin-bottom: 6px;
}

.d2-next-action p {
    color: #334155;
    font-size: 12px;
    line-height: 1.6;
    min-height: 38px;
}

.d2-floating-actions {
    position: sticky;
    bottom: 16px;
    z-index: 20;
    background: rgba(13, 18, 34, 0.96);
    border: 1px solid var(--color-border-dark);
    border-radius: 8px;
    padding: 12px;
    box-shadow: 0 16px 36px rgba(0,0,0,0.32);
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
}

.d2-floating-actions textarea {
    min-height: 62px;
    max-height: 120px;
    resize: vertical;
}

.d2-action-buttons {
    align-items: stretch;
}

.d2-action-buttons .btn {
    white-space: nowrap;
    padding: 10px 14px;
}

.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(7, 11, 25, 0.72);
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.modal-overlay.active {
    display: flex;
}

.modal-container {
    background: #ffffff;
    color: var(--color-text-primary-light);
    border-radius: 8px;
    width: min(560px, 100%);
    box-shadow: 0 24px 80px rgba(0,0,0,0.32);
    position: relative;
    padding: 28px;
}

.modal-close-btn {
    position: absolute;
    top: 10px;
    right: 12px;
    border: 0;
    background: transparent;
    font-size: 26px;
    cursor: pointer;
    color: #64748b;
}

.modal-header h3 {
    font-size: 20px;
    margin-bottom: 6px;
}

.modal-header p {
    color: var(--color-text-secondary-light);
    font-size: 13px;
}

/* 最近使用 */
.recent-use-section {
    margin-top: 40px;
    border-top: 1px solid var(--color-border-dark);
    padding-top: 24px;
}
.recent-use-title {
    font-size: 13px;
    font-weight: 700;
    color: #94a3b8;
    margin-bottom: 16px;
}
.recent-list-row {
    display: flex;
    gap: 12px;
    overflow-x: auto;
}
.recent-item {
    background-color: #111827;
    border: 1px solid var(--color-border-dark);
    border-radius: var(--border-radius-sm);
    padding: 10px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 170px;
    cursor: pointer;
    transition: var(--transition-smooth);
}
.recent-item:hover {
    background-color: #1e293b;
    border-color: var(--color-primary);
}
.recent-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}
.recent-item h6 {
    font-size: 12px;
    font-weight: 700;
    color: #fff;
}
.recent-item span {
    font-size: 9px;
    color: #64748b;
    display: block;
    margin-top: 1px;
}

/* 右侧 AI 助手与指标区 */
.console-chat {
    background-color: #060913;
    border-left: 1px solid var(--color-border-dark);
    display: flex;
    flex-direction: column;
    height: 100%;
}
.chat-header {
    padding: 24px;
    border-bottom: 1px solid var(--color-border-dark);
}
.agent-profile {
    display: flex;
    align-items: center;
    gap: 12px;
}
.agent-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    border: 2px solid var(--color-primary);
    box-shadow: var(--shadow-cyan-glow);
}
.agent-status h4 {
    font-size: 14px;
    font-weight: 700;
}

/* 快捷操作列表 */
.shortcut-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.shortcut-item {
    font-size: 12px;
    color: var(--color-text-secondary-dark);
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.01);
    border: 1px solid var(--color-border-dark);
    transition: var(--transition-smooth);
}
.shortcut-item:hover {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.03);
    border-color: var(--color-primary);
    transform: translateX(4px);
}
.sc-icon {
    color: var(--color-primary);
    font-weight: bold;
}

/* 底部知识库快速访问 */
.kb-quick-section {
    margin-top: 40px;
}
.kb-quick-card {
    background-color: #0b111e;
    border: 1px solid var(--color-border-dark);
    border-radius: var(--border-radius-md);
    padding: 16px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition-smooth);
}
.kb-quick-card:hover {
    transform: translateY(-4px);
    border-color: var(--color-primary);
    background-color: #111827;
    box-shadow: var(--shadow-cyan-glow);
}
.kb-qc-avatar {
    font-size: 24px;
    margin-bottom: 10px;
    display: inline-block;
}
.kb-quick-card h6 {
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
}
.kb-quick-card span {
    font-size: 10px;
    color: var(--color-text-secondary-dark);
}

/* ==========================================================================
   7. 沉浸式双栏 8D 报告助手工作台特有样式
   ========================================================================== */

/* 8D 垂直树节点连线与点亮 */
.progress-tree {
    position: relative;
}
.progress-tree::before {
    content: '';
    position: absolute;
    left: 23px;
    top: 12px;
    bottom: 12px;
    width: 2px;
    background-color: var(--color-border-dark);
    z-index: 1;
}

.tree-node {
    position: relative;
    z-index: 5;
}

.node-circle {
    background-color: #0b111e;
    z-index: 10;
}

/* 节点激活状态 */
.tree-node.active-node {
    opacity: 1 !important;
}
.tree-node.active-node .node-circle {
    border-color: var(--color-primary) !important;
    color: var(--color-primary) !important;
    box-shadow: var(--shadow-cyan-glow);
}

.tree-node.completed-node {
    opacity: 1 !important;
}
.tree-node.completed-node .node-circle {
    border-color: var(--color-accent) !important;
    background-color: var(--color-accent) !important;
    color: var(--color-bg-dark) !important;
    box-shadow: var(--shadow-green-glow);
}

/* Word 纸张高仿真样式 */
.word-paper-mock {
    background: #ffffff;
    color: #0f172a;
    border: 1px solid #e2e8f0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    padding: 36px;
    border-radius: 4px;
    max-height: 480px;
    overflow-y: auto;
    font-family: 'SimSun', 'STSong', 'Georgia', serif;
    line-height: 1.6;
}

/* 滚动条美化 */
.word-paper-mock::-webkit-scrollbar {
    width: 6px;
}
.word-paper-mock::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

.wp-title {
    font-size: 18px;
    font-weight: 800;
    text-align: center;
    color: #1e3a8a;
    margin-bottom: 20px;
    border-bottom: 2px solid #1e3a8a;
    padding-bottom: 10px;
}

.wp-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
    font-size: 12px;
}
.wp-table td {
    border: 1px solid #cbd5e1;
    padding: 8px 12px;
}
.wp-td-lbl {
    background: #f8fafc;
    font-weight: 700;
    color: #475569;
    width: 20%;
}

.wp-sec-title {
    font-size: 13px;
    font-weight: 700;
    color: #1e3a8a;
    margin: 16px 0 8px 0;
    border-left: 3px solid #1e3a8a;
    padding-left: 8px;
}

.wp-text {
    font-size: 12px;
    color: #334155;
    text-indent: 24px;
    margin-bottom: 12px;
    text-align: justify;
}

/* ==========================================================================
   8. 强行重载 Dify 官方嵌入 Chatbot 悬浮窗口样式
   ========================================================================== */

/* 1. 强行隐藏右下角的悬浮气泡 */
#dify-chatbot-bubble-button {
    display: none !important;
}

/* 2. 当 Dify 窗口仍在 body 下时，强制将其隐藏，防止遮挡首页 */
body > #dify-chatbot-bubble-window {
    display: none !important;
}

/* 3. 当 Dify 窗口被移入我们的目标容器内时，重载为铺满容器的形式 */
#dify-chat-container #dify-chatbot-bubble-window {
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 600px !important;
    box-shadow: none !important;
    border: none !important;
    border-radius: 12px !important;
    z-index: 10 !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    transform: none !important;
}

/* 9. 页脚 Footer */
.footer {
    background-color: var(--color-bg-dark);
    border-top: 1px solid var(--color-border-dark);
    padding: 64px 0 32px 0;
    color: var(--color-text-secondary-dark);
    font-size: 14px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 48px;
    margin-bottom: 48px;
}

.footer-logo {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.footer-logo h3 {
    font-size: 18px;
    font-weight: 800;
    color: #fff;
}

.footer-logo p {
    font-size: 13px;
    max-width: 280px;
    line-height: 1.6;
}

.footer-col h4 {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links a:hover {
    color: var(--color-primary);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
}

.footer-copyright p {
    margin-bottom: 4px;
}

.footer-meta-links {
    display: flex;
    gap: 20px;
}
.footer-meta-links a:hover {
    color: var(--color-primary);
}

/* 10. 动画关键帧 */
@keyframes pulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.5); }
    70% { transform: scale(1); box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

@keyframes flash {
    0% { opacity: 0.4; }
    100% { opacity: 1; }
}

/* 11. 响应式布局媒体查询 */
@media (max-width: 1024px) {
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .hero-grid { grid-template-columns: 1fr; gap: 40px; }
    .hero-mockup { max-width: 560px; margin: 0 auto; }
    .cta-grid { grid-template-columns: 1fr; gap: 40px; }
    .cta-left { border-right: none; padding-right: 0; }
    .platform-console { grid-template-columns: 200px 1fr; height: auto; min-height: 600px; }
    .console-chat { grid-column: span 2; border-left: none; border-top: 1px solid var(--color-border-dark); height: auto; }
    .workbench-grid-3 { grid-template-columns: repeat(2, 1fr); }
    .kb-quick-section .container > div { grid-template-columns: repeat(3, 1fr); }
    .workbench-split { grid-template-columns: 1fr !important; height: auto !important; }
    .d2-workbench-grid { grid-template-columns: 1fr; }
    .d2-resizer { display: none; }
    .d2-input-rail { position: static; max-height: none; }
    .d2-floating-actions { grid-template-columns: 1fr; }
    .d2-paper { min-width: 0; }
}

@media (max-width: 768px) {
    .grid-2, .grid-3 { grid-template-columns: 1fr; }
    .header-cta .btn { display: none; }
    .hamburger { display: flex; }
    .nav-menu {
        display: none;
        position: absolute;
        top: 80px;
        left: 0;
        right: 0;
        background-color: var(--color-bg-dark);
        border-bottom: 1px solid var(--color-border-dark);
        flex-direction: column;
        padding: 24px;
        gap: 16px;
    }
    .nav-menu.mobile-active { display: flex; }
    .hero-title { font-size: 36px; }
    .methodology-grid { grid-template-columns: 1fr; }
    
    .platform-console { grid-template-columns: 1fr; }
    .console-sidebar { border-right: none; border-bottom: 1px solid var(--color-border-dark); padding: 16px 0; }
    .center-list { flex-direction: row; flex-wrap: wrap; padding: 0 16px; }
    .center-item { border-left: none; border-bottom: 3px solid transparent; padding: 10px 16px; }
    .center-item.active { border-bottom-color: var(--color-primary); }
    .console-chat { grid-column: span 1; }
    
    .workbench-grid-3 { grid-template-columns: 1fr; }
    .kb-quick-section .container > div { grid-template-columns: repeat(2, 1fr); }
    .d2-topbar-inner, .d2-topbar-left, .d2-paper-header, .d2-chamber-head, .d2-action-buttons {
        align-items: stretch;
        flex-direction: column;
    }
    .d2-topbar-state { align-self: flex-start; }
    .d2-paper { padding: 18px; }
    .d2-paper-header h2 { font-size: 21px; }
    .d2-brand-logo { text-align: left; }
    .d2-sheet-grid { grid-template-columns: 1fr; }
    .d2-sheet-panel h3 { font-size: 15px; }
    .d2-sheet-table { table-layout: auto; }
    .d2-sheet-cell textarea { min-height: 72px; }
    .d2-5w-grid { grid-template-columns: 1fr; }
    .d2-chamber-head small { white-space: normal; }
    
    .footer-grid { grid-template-columns: 1fr; gap: 32px; }
    .footer-bottom { flex-direction: column; gap: 16px; text-align: center; }
}

/* ==========================================================================
   12. Dify 智能模拟对话流 & 实时更新动效
   ========================================================================== */
.dify-mock-chat {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 600px;
    background: #060913;
    font-family: var(--font-primary);
}

.dify-mock-header {
    background: #0d1222;
    border-bottom: 1px solid var(--color-border-dark);
    padding: 14px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dify-mock-body {
    flex-grow: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
    height: 420px;
    max-height: 420px;
}

.dify-message {
    display: flex;
    gap: 12px;
    max-width: 85%;
    animation: fadeIn 0.3s ease-out;
}

.dify-message.ai {
    align-self: flex-start;
}

.dify-message.user {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.dify-msg-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}

.dify-message.ai .dify-msg-avatar {
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
}

.dify-message.user .dify-msg-avatar {
    background: #475569;
}

.dify-msg-content {
    background: #111827;
    border: 1px solid var(--color-border-dark);
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 12px;
    line-height: 1.5;
    color: #e2e8f0;
}

.dify-message.user .dify-msg-content {
    background: rgba(0, 180, 216, 0.15);
    border-color: rgba(0, 180, 216, 0.3);
    color: #fff;
}

.dify-quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 12px 20px;
    background: rgba(0,0,0,0.15);
    border-top: 1px solid var(--color-border-dark);
}

.dify-pill-btn {
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--color-border-dark);
    color: #94a3b8;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dify-pill-btn:hover {
    background: rgba(0, 180, 216, 0.08);
    border-color: var(--color-primary);
    color: #fff;
    transform: translateY(-1px);
}

.dify-mock-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--color-border-dark);
    background: #090c17;
    display: flex;
    gap: 12px;
    align-items: center;
}

.dify-mock-input {
    flex-grow: 1;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--color-border-dark);
    border-radius: 6px;
    padding: 10px 14px;
    color: #fff;
    font-size: 12px;
    transition: var(--transition-smooth);
}

.dify-mock-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 8px rgba(0, 180, 216, 0.2);
}

/* 节点高亮特效 */
.active-node {
    opacity: 1 !important;
    animation: nodePulse 1.2s infinite alternate;
}

.active-node .node-circle {
    border-color: var(--color-primary) !important;
    box-shadow: var(--shadow-cyan-glow) !important;
    color: var(--color-primary) !important;
}

.completed-node {
    opacity: 1 !important;
    border-color: rgba(16, 185, 129, 0.3) !important;
}

.completed-node .node-circle {
    border-color: #10b981 !important;
    background-color: #10b981 !important;
    color: #fff !important;
}

.node-circle {
    transition: var(--transition-smooth);
}

/* 模拟纸张文本更新时的闪烁与高亮动效 */
.pulse-highlight {
    animation: pulseGlow 1.8s ease-out;
}

@keyframes nodePulse {
    0% { transform: scale(0.98); }
    100% { transform: scale(1.02); }
}

@keyframes pulseGlow {
    0% { background-color: rgba(0, 180, 216, 0.5); color: #fff; }
    50% { background-color: rgba(0, 180, 216, 0.2); }
    100% { background-color: transparent; }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   9. 新增：8D AI Copilot 工作台专属三栏式及表单交互样式
   ========================================================================== */

/* 顶部控制栏 */
.wb-header {
    background: #0d1222;
    border-bottom: 1px solid var(--color-border-dark);
    padding: 12px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 64px;
}
.wb-header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}
.wb-header-title {
    font-size: 15px;
    font-weight: 700;
    color: #ffffff;
}
.wb-report-id-input {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--color-border-dark);
    color: #ffffff;
    font-family: monospace;
    font-size: 13px;
    padding: 4px 8px;
    border-radius: 4px;
    width: 180px;
    transition: var(--transition-smooth);
}
.wb-report-id-input:focus {
    border-color: var(--color-primary);
    background: rgba(255, 255, 255, 0.08);
    outline: none;
}
.wb-header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}
.wb-save-status {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: #94a3b8;
}
.wb-save-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: #10b981;
    display: inline-block;
}
.wb-save-dot.saving {
    background-color: #f59e0b;
    animation: flash 0.8s infinite alternate;
}

/* 三栏布局容器 */
.workbench-three-col {
    display: grid;
    grid-template-columns: 360px 180px 1fr;
    gap: 20px;
    height: calc(100vh - 128px);
    min-height: 650px;
    padding: 20px 24px;
    background: var(--color-bg-dark);
}

/* 左侧自研聊天舱 */
.wb-chat-panel {
    background: #060913;
    border: 1px solid var(--color-border-dark);
    border-radius: var(--border-radius-lg);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    height: 100%;
}
.wb-chat-header {
    background: #0d1222;
    border-bottom: 1px solid var(--color-border-dark);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.wb-chat-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    border: 1.5px solid var(--color-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
}
.wb-chat-title {
    font-size: 13px;
    font-weight: 600;
    color: #ffffff;
}
.wb-chat-subtitle {
    font-size: 10px;
    color: var(--color-accent);
}
.wb-chat-messages {
    flex-grow: 1;
    padding: 16px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
}
/* 消息气泡 */
.wb-msg {
    max-width: 85%;
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 12.5px;
    line-height: 1.5;
    word-break: break-all;
    animation: fadeIn 0.3s ease-out;
}
.wb-msg.user {
    background: var(--color-primary);
    color: #ffffff;
    align-self: flex-end;
    border-bottom-right-radius: 2px;
    box-shadow: var(--shadow-cyan-glow);
}
.wb-msg.ai {
    background: #111827;
    color: #cbd5e1;
    align-self: flex-start;
    border-bottom-left-radius: 2px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}
/* 系统/推导日志气泡 */
.wb-msg.log {
    background: rgba(16, 185, 129, 0.05);
    border: 1px dashed rgba(16, 185, 129, 0.2);
    color: #a7f3d0;
    align-self: stretch;
    font-family: monospace;
    font-size: 11px;
    border-radius: 6px;
    padding: 8px 12px;
}
.wb-msg.log span {
    color: var(--color-accent);
}
/* 聊天输入区 */
.wb-chat-input-area {
    padding: 16px;
    background: #0d1222;
    border-top: 1px solid var(--color-border-dark);
}
.wb-chat-input-container {
    position: relative;
    margin-bottom: 10px;
}
.wb-chat-textarea {
    width: 100%;
    height: 70px;
    background: #070a13;
    border: 1px solid var(--color-border-dark);
    border-radius: 6px;
    color: #ffffff;
    font-size: 12px;
    padding: 10px 12px;
    resize: none;
    font-family: inherit;
    transition: var(--transition-smooth);
}
.wb-chat-textarea:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 10px rgba(0, 180, 216, 0.15);
    outline: none;
}
.wb-chat-actions {
    display: flex;
    gap: 8px;
}
.wb-chat-filebar {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}
.wb-file-input {
    display: none;
}
.wb-file-trigger {
    flex: 0 0 auto;
    border: 1px dashed rgba(56, 189, 248, 0.7);
    color: #67e8f9;
    border-radius: 4px;
    padding: 6px 10px;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
}
.wb-file-trigger:hover {
    background: rgba(56, 189, 248, 0.1);
}
.wb-file-list {
    min-width: 0;
    flex: 1;
    color: #94a3b8;
    font-size: 11px;
    line-height: 1.4;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wb-chat-actions button {
    flex: 1;
    font-size: 11px;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
}
.wb-btn-send {
    background: var(--color-primary);
    border: none;
    color: #ffffff;
    transition: var(--transition-smooth);
}
.wb-btn-send:hover {
    filter: brightness(1.1);
    box-shadow: var(--shadow-cyan-glow);
}
.wb-btn-reanalyze {
    background: transparent;
    border: 1px solid var(--color-accent);
    color: var(--color-accent);
    transition: var(--transition-smooth);
}
.wb-btn-reanalyze:hover {
    background: rgba(0, 180, 216, 0.1);
}

/* 中间步骤卡关条 */
.wb-steps-panel {
    background: #0b111e;
    border: 1px solid var(--color-border-dark);
    border-radius: var(--border-radius-lg);
    padding: 16px 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow-y: auto;
    height: 100%;
}
.wb-steps-header {
    font-size: 11px;
    font-weight: 800;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
    padding-left: 6px;
}
.wb-step-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.01);
    border: 1px solid transparent;
    transition: var(--transition-smooth);
}
.wb-step-item.active {
    background: rgba(0, 180, 216, 0.03);
    border-color: rgba(0, 180, 216, 0.15);
}
.wb-step-badge {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    transition: var(--transition-smooth);
}
/* 状态：缺失 */
.wb-step-item.status-empty .wb-step-badge {
    border: 1.5px dashed #475569;
    color: #475569;
    background: transparent;
}
/* 状态：生成中 */
.wb-step-item.status-generating .wb-step-badge {
    border: 1.5px solid var(--color-primary);
    color: var(--color-primary);
    background: rgba(0, 180, 216, 0.1);
    animation: pulse 1s infinite alternate;
}
/* 状态：待确认 */
.wb-step-item.status-ai_suggested .wb-step-badge,
.wb-step-item.status-need_confirm .wb-step-badge {
    border: 1.5px solid #f59e0b;
    color: #f59e0b;
    background: rgba(245, 158, 11, 0.1);
}
/* 状态：已确认 */
.wb-step-item.status-human_confirmed .wb-step-badge {
    border: 1.5px solid #10b981;
    color: #ffffff;
    background: #10b981;
    box-shadow: var(--shadow-green-glow);
}

.wb-step-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}
.wb-step-title {
    font-size: 11.5px;
    font-weight: 700;
    color: #ffffff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wb-step-tag {
    font-size: 9px;
    font-weight: 600;
    padding: 1px 4px;
    border-radius: 3px;
    align-self: flex-start;
    text-transform: uppercase;
}
.status-empty .wb-step-tag {
    background: rgba(71, 85, 105, 0.15);
    color: #64748b;
}
.status-generating .wb-step-tag {
    background: rgba(0, 180, 216, 0.15);
    color: var(--color-primary);
}
.status-ai_suggested .wb-step-tag,
.status-need_confirm .wb-step-tag {
    background: rgba(245, 158, 11, 0.15);
    color: #f59e0b;
}
.status-missing .wb-step-tag {
    background: rgba(239, 68, 68, 0.15);
    color: #fca5a5;
}
.status-human_confirmed .wb-step-tag {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
}

/* 右侧 A4 报告纸张 */
.wb-report-panel {
    background: #0b111e;
    border: 1px solid var(--color-border-dark);
    border-radius: var(--border-radius-lg);
    padding: 20px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    height: 100%;
}
.wb-a4-container {
    background: #ffffff;
    color: #0f172a;
    border: 1px solid #e2e8f0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    padding: 40px;
    border-radius: 4px;
    font-family: 'SimSun', 'STSong', 'NSimSun', 'Georgia', serif;
    line-height: 1.5;
    position: relative;
}
.wb-a4-title {
    font-size: 20px;
    font-weight: 900;
    text-align: center;
    color: #1e3a8a;
    margin-bottom: 24px;
    border-bottom: 3px double #1e3a8a;
    padding-bottom: 12px;
    letter-spacing: 1px;
}
.wb-a4-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
    font-size: 11px;
    table-layout: fixed;
}
.wb-a4-table th, .wb-a4-table td {
    border: 1px solid #94a3b8;
    padding: 6px 10px;
    vertical-align: middle;
}
.wb-a4-label {
    background: #f1f5f9;
    font-weight: 700;
    color: #1e3a8a;
    text-align: center;
}
.wb-a4-section-title {
    background: #1e3a8a;
    color: #ffffff !important;
    font-size: 12px;
    font-weight: 700;
    padding: 8px 12px !important;
    text-align: left;
}

/* 可编辑表格输入框 */
.wb-a4-input {
    width: 100%;
    min-height: 24px;
    border: none;
    outline: none;
    background: transparent;
    font-family: inherit;
    font-size: 11.5px;
    color: #1e293b;
    resize: vertical;
    padding: 2px 0;
    transition: background-color 0.4s ease, box-shadow 0.2s;
}
.wb-a4-input:focus {
    background: rgba(30, 58, 138, 0.03);
}

/* 单元格字段状态 */
td.state-ai_suggested {
    background-color: #fef08a !important; /* 浅黄色 */
    position: relative;
}
td.state-need_confirm {
    background-color: #ffedd5 !important; /* 浅橙色 */
    position: relative;
}
td.state-missing {
    background-color: #fee2e2 !important;
    position: relative;
}
td.state-human_confirmed {
    background-color: #ffffff !important;
    transition: background-color 0.4s ease;
}
td.state-locked {
    background-color: #f8fafc !important;
    color: #64748b;
}

/* 待确认小标签 */
.wb-field-badge {
    position: absolute;
    right: 4px;
    top: 4px;
    background: rgba(245, 158, 11, 0.9);
    color: #ffffff;
    font-size: 7.5px;
    padding: 1px 3px;
    border-radius: 2px;
    font-family: var(--font-sans);
    font-weight: 600;
    pointer-events: none;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}
td.state-need_confirm .wb-field-badge {
    background: rgba(239, 68, 68, 0.9);
}
td.state-missing .wb-field-badge {
    background: rgba(220, 38, 38, 0.95);
}

/* A4表格嵌套样式 (对于Is/Is Not矩阵) */
.wb-nested-table {
    width: 100%;
    border-collapse: collapse;
    margin: 4px 0;
}
.wb-nested-table th, .wb-nested-table td {
    border: 1px solid #cbd5e1;
    padding: 4px 6px;
}
.wb-nested-table th {
    background: #f8fafc;
    font-weight: 700;
}

/* D4 5Why推导容器 */
.wb-why-flow {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 4px 0;
}
.wb-why-step {
    display: flex;
    align-items: flex-start;
    gap: 6px;
}
.wb-why-label {
    font-weight: 700;
    color: #1e3a8a;
    font-size: 11px;
    flex-shrink: 0;
    width: 48px;
}
.wb-why-val {
    flex-grow: 1;
}

/* 重新分析打字高亮特效 */
.pulse-fill {
    animation: fillGlow 1.2s ease-out;
}
@keyframes fillGlow {
    0% { background-color: rgba(254, 240, 138, 0.8); }
    100% { background-color: transparent; }
}

/* ==========================================================================
   用户登录与管理界面 CSS 样式
   ========================================================================== */
.login-modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1100;
    background: rgba(7, 11, 25, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease-out;
}

.login-modal-overlay.active {
    display: flex;
}

.login-modal-container {
    background: linear-gradient(145deg, #1e293b 0%, #0f172a 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    width: min(880px, 100%);
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    color: #f1f5f9;
    animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

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

@keyframes slideUp {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.login-modal-header {
    padding: 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.login-modal-header-text h3 {
    font-size: 20px;
    font-weight: 700;
    margin: 0 0 4px 0;
    background: linear-gradient(to right, #38bdf8, #818cf8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.login-modal-header-text p {
    font-size: 13px;
    color: #94a3b8;
    margin: 0;
}

.login-modal-close {
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 28px;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
}

.login-modal-close:hover {
    color: #f1f5f9;
}

.login-modal-body {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    overflow: hidden;
    height: 600px;
}

@media (max-width: 768px) {
    .login-modal-body {
        grid-template-columns: 1fr;
        height: auto;
        overflow-y: auto;
        max-height: 70vh;
    }
    .login-modal-body > div {
        border-right: none !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    }
}

/* 左侧：演示账号一键登录 */
.login-quick-section {
    padding: 24px;
    overflow-y: auto;
    border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.login-quick-section h4 {
    font-size: 14px;
    color: #38bdf8;
    margin-top: 0;
    margin-bottom: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
}

.login-quick-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.login-quick-dept-group {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 8px;
    padding: 12px;
}

.login-quick-dept-title {
    font-size: 12px;
    font-weight: bold;
    color: #94a3b8;
    margin-bottom: 8px;
    padding-bottom: 4px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    display: flex;
    justify-content: space-between;
}

.login-quick-cards-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

@media (max-width: 480px) {
    .login-quick-cards-row {
        grid-template-columns: 1fr;
    }
}

.login-quick-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 8px;
    padding: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.login-quick-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(255,255,255,0.05) 0%, rgba(255,255,255,0) 100%);
    opacity: 0;
    transition: opacity 0.2s;
}

.login-quick-card:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: #38bdf8;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(56, 189, 248, 0.15);
}

.login-quick-card:hover::before {
    opacity: 1;
}

.login-quick-card-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: bold;
    flex-shrink: 0;
}

.login-quick-card-info {
    flex-grow: 1;
    min-width: 0;
}

.login-quick-card-name {
    font-size: 13px;
    font-weight: 600;
    color: #f8fafc;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: flex;
    align-items: center;
    gap: 4px;
}

.login-quick-card-email {
    font-size: 10px;
    color: #64748b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.login-quick-card-role {
    font-size: 9px;
    padding: 1px 4px;
    border-radius: 3px;
    font-weight: 700;
    line-height: 1;
    display: inline-block;
}

.role-tag-owner {
    background: rgba(234, 179, 8, 0.15);
    color: #facc15;
    border: 1px solid rgba(234, 179, 8, 0.3);
}

.role-tag-manager {
    background: rgba(99, 102, 241, 0.15);
    color: #818cf8;
    border: 1px solid rgba(99, 102, 241, 0.3);
}

.role-tag-staff {
    background: rgba(16, 185, 129, 0.15);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

/* 右侧：表单登录 */
.login-form-section {
    padding: 24px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: rgba(0, 0, 0, 0.15);
}

.login-form-section h4 {
    font-size: 14px;
    color: #818cf8;
    margin-top: 0;
    margin-bottom: 20px;
    font-weight: 600;
}

.login-field {
    margin-bottom: 16px;
}

.login-field label {
    display: block;
    font-size: 12px;
    color: #94a3b8;
    margin-bottom: 6px;
    font-weight: 500;
}

.login-field input {
    width: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 10px 12px;
    color: #ffffff;
    font-size: 13px;
    transition: all 0.2s;
}

.login-field input:focus {
    outline: none;
    border-color: #818cf8;
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 0 0 2px rgba(129, 140, 248, 0.2);
}

.btn-login-submit {
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    border: none;
    color: #ffffff;
    padding: 12px;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
    font-size: 14px;
    margin-top: 8px;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
    transition: all 0.2s;
}

.btn-login-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(79, 70, 229, 0.4);
    background: linear-gradient(135deg, #818cf8 0%, #4f46e5 100%);
}

.login-error-msg {
    color: #ef4444;
    font-size: 12px;
    margin-top: 8px;
    min-height: 18px;
}

/* 顶部 Header 用户登录后状态样式 */
.user-status-card {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 20px;
    padding: 3px 6px 3px 12px;
    font-size: 12px;
    color: #cbd5e1;
    position: relative;
    cursor: pointer;
    transition: all 0.2s;
}

.user-status-card:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.15);
}

.user-status-name {
    font-weight: bold;
    color: #ffffff;
}

.user-status-role-badge {
    font-size: 9px;
    padding: 1px 4px;
    border-radius: 3px;
    font-weight: 700;
    line-height: 1;
}

.user-status-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    color: #ffffff;
}

.btn-logout {
    border: none;
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-logout:hover {
    background: rgba(239, 68, 68, 0.3);
    color: #ffffff;
}

/* 权限不可用蒙层 & 锁定样式 */
.app-locked {
    position: relative;
    opacity: 0.6;
}

.app-locked::after {
    content: '🔒 需本部门权限';
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #e2e8f0;
    font-size: 13px;
    font-weight: bold;
    border-radius: inherit;
    backdrop-filter: blur(2px);
    z-index: 10;
}

.center-item-disabled {
    opacity: 0.4;
    cursor: not-allowed !important;
}

.center-item-disabled:hover {
    background: transparent !important;
    transform: none !important;
}

.center-item-disabled-tag {
    font-size: 8px;
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
    padding: 0px 4px;
    border-radius: 3px;
    margin-left: auto;
    font-weight: bold;
}

/* ==========================================================================
   管理员控制台 (#admin-view) 专属 CSS
   ========================================================================== */
.admin-page {
    padding: 40px 0;
    background: radial-gradient(circle at top, #1e293b 0%, #0f172a 100%);
    min-height: calc(100vh - 70px);
}

.admin-header {
    margin-bottom: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-header h1 {
    font-size: 28px;
    font-weight: 800;
    margin: 0;
    background: linear-gradient(135deg, #38bdf8 0%, #818cf8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.admin-header p {
    color: #94a3b8;
    margin: 6px 0 0 0;
    font-size: 14px;
}

/* 顶部统计区 */
.admin-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.admin-stat-card {
    background: rgba(30, 41, 59, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255,255,255,0.05);
    border-radius: 12px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s;
}

.admin-stat-card:hover {
    transform: translateY(-2px);
    border-color: rgba(56, 189, 248, 0.2);
    box-shadow: 0 15px 35px rgba(56, 189, 248, 0.1);
}

.admin-stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #ffffff;
}

.admin-stat-info h5 {
    font-size: 12px;
    color: #94a3b8;
    margin: 0 0 4px 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.admin-stat-info h3 {
    font-size: 24px;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
}

/* 主面板双栏布局 */
.admin-panel-grid {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 30px;
    margin-bottom: 40px;
    align-items: start;
}

@media (max-width: 992px) {
    .admin-panel-grid {
        grid-template-columns: 1fr;
    }
}

.admin-card {
    background: rgba(30, 41, 59, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.admin-card-header {
    padding: 20px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-card-header h4 {
    font-size: 16px;
    font-weight: 700;
    color: #f1f5f9;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.admin-card-body {
    padding: 24px;
}

/* 表单组件 */
.admin-form-group {
    margin-bottom: 18px;
}

.admin-form-group label {
    display: block;
    font-size: 12px;
    color: #cbd5e1;
    margin-bottom: 6px;
    font-weight: 500;
}

.admin-form-group input,
.admin-form-group select {
    width: 100%;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 10px 12px;
    color: #ffffff;
    font-size: 13px;
    transition: all 0.2s;
}

.admin-form-group input:focus,
.admin-form-group select:focus {
    outline: none;
    border-color: #818cf8;
    box-shadow: 0 0 0 2px rgba(129, 140, 248, 0.25);
}

.admin-form-actions {
    display: flex;
    gap: 10px;
    margin-top: 24px;
}

/* 管理数据表 */
.admin-table-container {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 13px;
}

.admin-table th {
    padding: 14px 16px;
    font-weight: 600;
    color: #94a3b8;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-table td {
    padding: 12px 16px;
    color: #cbd5e1;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    vertical-align: middle;
}

.admin-table tbody tr {
    transition: background-color 0.2s;
}

.admin-table tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.02);
}

.admin-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: #ffffff;
    font-size: 13px;
}

.dept-badge {
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.dept-quality { background: rgba(16, 185, 129, 0.12); color: #34d399; border: 1px solid rgba(16, 185, 129, 0.2); }
.dept-research { background: rgba(99, 102, 241, 0.12); color: #818cf8; border: 1px solid rgba(99, 102, 241, 0.2); }
.dept-project { background: rgba(245, 158, 11, 0.12); color: #fbbf24; border: 1px solid rgba(245, 158, 11, 0.2); }
.dept-production { background: rgba(14, 165, 233, 0.12); color: #38bdf8; border: 1px solid rgba(14, 165, 233, 0.2); }
.dept-management { background: rgba(168, 85, 247, 0.12); color: #c084fc; border: 1px solid rgba(168, 85, 247, 0.2); }
.dept-public { background: rgba(100, 116, 139, 0.12); color: #94a3b8; border: 1px solid rgba(100, 116, 139, 0.2); }

.admin-btn-action {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #cbd5e1;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.admin-btn-action:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
    color: #ffffff;
}

.admin-btn-switch {
    background: rgba(56, 189, 248, 0.1);
    border-color: rgba(56, 189, 248, 0.2);
    color: #38bdf8;
}

.admin-btn-switch:hover {
    background: #38bdf8;
    color: #0f172a;
    border-color: #38bdf8;
    box-shadow: 0 4px 12px rgba(56, 189, 248, 0.2);
}

.admin-btn-delete {
    color: #f87171;
    background: rgba(239, 68, 68, 0.05);
    border-color: rgba(239, 68, 68, 0.15);
}

.admin-btn-delete:hover {
    background: #ef4444;
    color: #ffffff;
    border-color: #ef4444;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.2);
}

.admin-btn-delete:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    background: transparent;
    border-color: rgba(255, 255, 255, 0.05);
    color: #64748b;
}

/* 扮演身份时的顶部提示条 */
.impersonation-banner {
    background: linear-gradient(to right, #ea580c, #b45309);
    color: #ffffff;
    padding: 8px 24px;
    font-size: 13px;
    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 70px;
    z-index: 100;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    animation: slideDownBanner 0.3s ease-out;
}

@keyframes slideDownBanner {
    from { transform: translateY(-100%); }
    to { transform: translateY(0); }
}

.btn-restore-owner {
    background: #ffffff;
    color: #b45309;
    border: none;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-restore-owner:hover {
    background: #fef3c7;
    transform: scale(1.03);
}

/* 权限矩阵表格 */
.matrix-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
    margin-top: 10px;
}

.matrix-table th {
    background: rgba(15, 23, 42, 0.5);
    color: #94a3b8;
    font-weight: 700;
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.matrix-table td {
    padding: 10px 14px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    color: #cbd5e1;
}

.matrix-table tr:nth-child(even) {
    background: rgba(255, 255, 255, 0.01);
}

.matrix-icon-ok {
    color: #10b981;
    font-weight: bold;
    font-size: 14px;
}

.matrix-icon-no {
    color: #ef4444;
    font-size: 14px;
}
