/* ==================== 数字化培训平台 - 样式表 ==================== */
/* 版本: 3.0.0 */

/* ==================== CSS变量定义 ==================== */
:root {
    /* 主色调 */
    --primary: #0f172a;
    --primary-light: #1e293b;
    --secondary: #06b6d4;
    --secondary-light: #22d3ee;
    --accent: #f59e0b;
    --accent-light: #fbbf24;
    
    /* 状态色 */
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --info: #3b82f6;
    
    /* 标签颜色 */
    --tag-basic: #10b981;
    --tag-advanced: #f59e0b;
    --tag-maintenance: #3b82f6;
    --tag-safety: #ef4444;
    --tag-operation: #8b5cf6;
    --tag-theory: #06b6d4;
    --tag-troubleshooting: #ec4899;
    --tag-new: #22c55e;
    
    /* 背景色 */
    --bg: #f8fafc;
    --bg-gradient: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
    --card-bg: #ffffff;
    --card-hover: #f8fafc;
    
    /* 文字色 */
    --text: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --text-light: #cbd5e1;
    
    /* 边框与阴影 */
    --border: #e2e8f0;
    --border-light: #f1f5f9;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-glow: 0 0 20px rgba(6, 182, 212, 0.3);
    
    /* 尺寸 */
    --sidebar-width: 300px;
    --header-height: 70px;
    --footer-height: 60px;
    
    /* 圆角 */
    --radius-sm: 6px;
    --radius: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
}

/* ==================== 基础重置 ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Microsoft YaHei", "PingFang SC", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--bg-gradient);
    color: var(--text);
    min-height: 100vh;
    line-height: 1.6;
}

/* ==================== 动画关键帧 ==================== */
@keyframes slideDown {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.05); opacity: 0.8; }
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* ==================== 顶部标题栏 ==================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 50%, #0f172a 100%);
    background-size: 200% 200%;
    animation: gradientBG 8s ease infinite;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
    z-index: 1000;
    box-shadow: var(--shadow-lg);
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.logo {
    width: 45px;
    height: 45px;
    background: linear-gradient(135deg, var(--secondary), var(--secondary-light));
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 22px;
    box-shadow: 0 0 20px rgba(6, 182, 212, 0.4);
    animation: float 3s ease-in-out infinite;
}

.header-title {
    font-size: 24px;
    font-weight: 700;
    color: white;
    letter-spacing: 1px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.header-subtitle {
    font-size: 12px;
    color: var(--text-light);
    margin-left: 12px;
    padding-left: 12px;
    border-left: 1px solid rgba(255,255,255,0.2);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.search-box {
    position: relative;
    width: 280px;
}

.search-input {
    width: 100%;
    padding: 10px 16px 10px 40px;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 30px;
    background: rgba(255,255,255,0.1);
    color: white;
    font-size: 14px;
    transition: all 0.3s ease;
}

.search-input::placeholder {
    color: var(--text-light);
}

.search-input:focus {
    outline: none;
    background: rgba(255,255,255,0.15);
    border-color: var(--secondary);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.2);
}

.search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
}

.header-btn {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    color: white;
    padding: 10px 20px;
    border-radius: 30px;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.header-btn:hover {
    background: rgba(255,255,255,0.2);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
    color: white;
    font-size: 14px;
    font-weight: 500;
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.4);
}

.lang-select {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    color: white;
    padding: 8px 14px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
}

.lang-select option {
    color: var(--text);
    background: var(--card-bg);
}

/* ==================== 主布局 ==================== */
.main-container {
    display: flex;
    margin-top: var(--header-height);
    min-height: calc(100vh - var(--header-height) - var(--footer-height));
}

/* ==================== 左侧目录 ==================== */
.sidebar {
    width: var(--sidebar-width);
    background: var(--card-bg);
    border-right: 1px solid var(--border);
    overflow-y: auto;
    height: calc(100vh - var(--header-height) - var(--footer-height));
    position: fixed;
    left: 0;
    top: var(--header-height);
    box-shadow: var(--shadow);
    transition: opacity 0.3s ease;
}

.sidebar-overlay {
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(3px);
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.sidebar-overlay i {
    color: var(--text-muted);
    margin-bottom: 12px;
}

.sidebar-overlay p {
    color: var(--text-secondary);
    font-size: 13px;
    line-height: 1.5;
    font-weight: 500;
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid var(--border);
    font-weight: 600;
    font-size: 14px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
}

.sidebar-header i {
    color: var(--secondary);
}

.tree-menu {
    padding: 12px 0;
}

.tree-item {
    position: relative;
}

.tree-node {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
    margin: 2px 8px;
    border-radius: 0 var(--radius) var(--radius) 0;
}

.tree-node:hover {
    background: linear-gradient(90deg, #f1f5f9, #f8fafc);
    color: var(--secondary);
}

.tree-node.active {
    background: linear-gradient(90deg, rgba(6, 182, 212, 0.1), rgba(6, 182, 212, 0.05));
    border-left-color: var(--secondary);
    color: var(--secondary);
    font-weight: 600;
}

.tree-node.has-children {
    font-weight: 600;
    font-size: 15px;
}

.tree-icon {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    color: var(--secondary);
    font-size: 16px;
    background: rgba(6, 182, 212, 0.1);
    border-radius: var(--radius-sm);
}

.tree-text {
    flex: 1;
    font-size: 14px;
}

.tree-toggle {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease;
    color: var(--text-muted);
    border-radius: 50%;
}

.tree-toggle:hover {
    background: rgba(6, 182, 212, 0.1);
    color: var(--secondary);
}

.tree-toggle.expanded {
    transform: rotate(90deg);
}

.tree-children {
    display: none;
    padding-left: 20px;
    background: linear-gradient(180deg, #fafbfc, #f8fafc);
}

.tree-children.expanded {
    display: block;
    animation: slideDown 0.3s ease;
}

/* ==================== 内容区域 ==================== */
.content-wrapper {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - var(--header-height) - var(--footer-height));
}

.content {
    flex: 1;
    padding: 28px;
    background: transparent;
}

/* ==================== 分类栏 ==================== */
.category-bar {
    display: flex;
    align-items: center;
    padding: 16px 0;
    gap: 10px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.category-tab {
    padding: 10px 20px;
    border-radius: 30px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
    background: var(--card-bg);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}

.category-tab i {
    font-size: 14px;
}

.category-tab:hover {
    color: var(--secondary);
    border-color: var(--secondary);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.category-tab.active {
    background: linear-gradient(135deg, var(--secondary), var(--info));
    color: white;
    border-color: transparent;
    box-shadow: 0 4px 15px rgba(6, 182, 212, 0.4);
}

.category-tab.active[data-type="article"] {
    background: linear-gradient(135deg, #10b981, #34d399);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
}

.category-tab.active[data-type="interactive3d"] {
    background: linear-gradient(135deg, #8b5cf6, #a78bfa);
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.4);
}

.view-toggle {
    margin-left: auto;
    display: flex;
    gap: 6px;
    background: #f1f5f9;
    padding: 5px;
    border-radius: 30px;
}

.view-btn {
    padding: 8px 16px;
    border: none;
    background: transparent;
    cursor: pointer;
    border-radius: 20px;
    transition: all 0.3s ease;
    color: var(--text-secondary);
    font-size: 14px;
}

.view-btn:hover {
    color: var(--secondary);
}

.view-btn.active {
    background: white;
    color: var(--secondary);
    box-shadow: var(--shadow);
}


/* ==================== 标签样式 ==================== */
.tags-container {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 8px;
}

.tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.tag:hover {
    transform: scale(1.05);
}

.tag-basic { background: rgba(16, 185, 129, 0.1); color: var(--tag-basic); }
.tag-advanced { background: rgba(245, 158, 11, 0.1); color: var(--tag-advanced); }
.tag-maintenance { background: rgba(59, 130, 246, 0.1); color: var(--tag-maintenance); }
.tag-safety { background: rgba(239, 68, 68, 0.1); color: var(--tag-safety); }
.tag-operation { background: rgba(139, 92, 246, 0.1); color: var(--tag-operation); }
.tag-theory { background: rgba(6, 182, 212, 0.1); color: var(--tag-theory); }
.tag-troubleshooting { background: rgba(236, 72, 153, 0.1); color: var(--tag-troubleshooting); }
.tag-new { 
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.15), rgba(34, 197, 94, 0.05)); 
    color: var(--tag-new);
    animation: pulse 2s ease-in-out infinite;
}

/* ==================== 内容类型徽章 ==================== */
.type-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.type-badge.video {
    background: rgba(6, 182, 212, 0.1);
    color: var(--secondary);
}

.type-badge.article {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.type-badge.interactive3d {
    background: rgba(139, 92, 246, 0.1);
    color: #8b5cf6;
}

/* ==================== 内容头部 ==================== */
.content-header {
    margin-bottom: 28px;
    animation: slideDown 0.5s ease;
}

.content-title {
    font-size: 26px;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 8px;
    background: linear-gradient(135deg, var(--text), var(--text-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.content-desc {
    font-size: 15px;
    color: var(--text-secondary);
    max-width: 600px;
}

/* ==================== 列表视图 ==================== */
.list-view {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.list-item {
    display: flex;
    align-items: center;
    padding: 20px 24px;
    background: var(--card-bg);
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-light);
    position: relative;
    overflow: hidden;
}

.list-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, var(--secondary), var(--secondary-light));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.list-item:hover {
    transform: translateX(8px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(6, 182, 212, 0.3);
}

.list-item:hover::before {
    opacity: 1;
}

.list-item.type-video:hover {
    border-color: rgba(6, 182, 212, 0.3);
}

.list-item.type-video::before {
    background: linear-gradient(180deg, var(--secondary), var(--secondary-light));
}

.list-item.type-article:hover {
    border-color: rgba(16, 185, 129, 0.3);
}

.list-item.type-article::before {
    background: linear-gradient(180deg, var(--success), #34d399);
}

.list-item.type-interactive3d:hover {
    border-color: rgba(139, 92, 246, 0.3);
}

.list-item.type-interactive3d::before {
    background: linear-gradient(180deg, #8b5cf6, #a78bfa);
}

.list-item-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    margin-right: 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    position: relative;
}

.list-item-icon.video {
    background: linear-gradient(135deg, var(--secondary), var(--info));
}

.list-item-icon.article {
    background: linear-gradient(135deg, var(--success), #34d399);
}

.list-item-icon.interactive3d {
    background: linear-gradient(135deg, #8b5cf6, #a78bfa);
}

.list-item-icon::after {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: var(--radius);
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
    filter: blur(10px);
}

.list-item.type-video .list-item-icon::after {
    background: linear-gradient(135deg, var(--secondary), var(--secondary-light));
}

.list-item.type-article .list-item-icon::after {
    background: linear-gradient(135deg, var(--success), #34d399);
}

.list-item.type-interactive3d .list-item-icon::after {
    background: linear-gradient(135deg, #8b5cf6, #a78bfa);
}

.list-item:hover .list-item-icon::after {
    opacity: 0.5;
}

.list-item-content {
    flex: 1;
}

.list-item-title {
    font-size: 17px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.list-item-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 8px;
}

.list-item-meta {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.list-item-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--text-muted);
}

.list-item-meta i {
    font-size: 14px;
}

.progress-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.progress-badge.in-progress {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

.list-item-arrow {
    color: var(--text-muted);
    font-size: 18px;
    transition: all 0.3s ease;
}

.list-item:hover .list-item-arrow {
    color: var(--secondary);
    transform: translateX(4px);
}

/* ==================== 网格视图 ==================== */
.grid-view {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.grid-item {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    overflow: hidden;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-light);
    position: relative;
}

.grid-item:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.grid-item.type-video:hover {
    box-shadow: var(--shadow-lg), 0 0 30px rgba(6, 182, 212, 0.2);
    border-color: rgba(6, 182, 212, 0.2);
}

.grid-item.type-article:hover {
    box-shadow: var(--shadow-lg), 0 0 30px rgba(16, 185, 129, 0.2);
    border-color: rgba(16, 185, 129, 0.2);
}

.grid-item.type-interactive3d:hover {
    box-shadow: var(--shadow-lg), 0 0 30px rgba(139, 92, 246, 0.2);
    border-color: rgba(139, 92, 246, 0.2);
}

.grid-item-thumb {
    width: 100%;
    height: 160px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 48px;
    position: relative;
    overflow: hidden;
}

.grid-item.type-video .grid-item-thumb {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    background-size: 200% 200%;
    animation: gradientBG 5s ease infinite;
}

.grid-item.type-article .grid-item-thumb {
    background: linear-gradient(135deg, #10b981 0%, #059669 50%, #34d399 100%);
    background-size: 200% 200%;
    animation: gradientBG 5s ease infinite;
}

.grid-item.type-interactive3d .grid-item-thumb {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 50%, #a78bfa 100%);
    background-size: 200% 200%;
    animation: gradientBG 5s ease infinite;
}

.grid-item-thumb::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.3) 0%, transparent 30%, transparent 60%, rgba(0,0,0,0.5) 100%);
    z-index: 1;
}

.grid-item-thumb i {
    z-index: 2;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.5));
    transition: transform 0.3s ease;
    position: relative;
}

.grid-item:hover .grid-item-thumb i {
    transform: scale(1.1);
}

.grid-item-type-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(10px);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 6px;
    color: white;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

.grid-item-play {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(10px);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    z-index: 2;
    color: white;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

.grid-item-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: rgba(255,255,255,0.3);
    z-index: 2;
}

.grid-item-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--success), var(--secondary));
    border-radius: 0 2px 2px 0;
    transition: width 0.5s ease;
}

.grid-item-info {
    padding: 18px;
}

.grid-item-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.5;
    margin-bottom: 12px;
    min-height: 45px;
}

.grid-item-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    color: var(--text-muted);
}

.grid-item-meta-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.grid-item-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.grid-item-progress-text {
    font-size: 12px;
    color: var(--success);
    font-weight: 600;
}

/* ==================== 统计卡片 ==================== */
.stats-bar {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 28px;
}

.stat-card {
    background: var(--card-bg);
    padding: 20px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    gap: 16px;
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
}

.stat-icon.blue {
    background: rgba(59, 130, 246, 0.1);
    color: var(--info);
}

.stat-icon.green {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.stat-icon.orange {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

.stat-icon.cyan {
    background: rgba(6, 182, 212, 0.1);
    color: var(--secondary);
}

.stat-icon.purple {
    background: rgba(139, 92, 246, 0.1);
    color: #8b5cf6;
}

.stat-content h4 {
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 4px;
}

.stat-content p {
    font-size: 22px;
    font-weight: 700;
    color: var(--text);
}


/* ==================== 空状态 ==================== */
.empty-state {
    text-align: center;
    padding: 80px 20px;
    color: var(--text-secondary);
    animation: fadeIn 0.5s ease;
}

.empty-state i {
    font-size: 80px;
    margin-bottom: 24px;
    opacity: 0.3;
    background: linear-gradient(135deg, var(--text-muted), var(--border));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.empty-state h3 {
    font-size: 20px;
    margin-bottom: 12px;
    color: var(--text);
    font-weight: 600;
}

.empty-state p {
    font-size: 15px;
    color: var(--text-muted);
}

/* ==================== 搜索结果高亮 ==================== */
.highlight {
    background: linear-gradient(120deg, rgba(6, 182, 212, 0.2) 0%, rgba(6, 182, 212, 0.2) 100%);
    border-radius: 3px;
    padding: 0 2px;
    font-weight: 600;
}

/* ==================== 页脚 ==================== */
.footer {
    margin-left: var(--sidebar-width);
    padding: 20px 28px;
    background: var(--card-bg);
    border-top: 1px solid var(--border);
    text-align: center;
    color: var(--text-muted);
    font-size: 13px;
    position: relative;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.footer-links {
    display: flex;
    gap: 20px;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--secondary);
}

/* ==================== 弹窗样式 ==================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 20px;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 420px;
    padding: 32px;
    transform: scale(0.9) translateY(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    border: 1px solid var(--border);
}

.modal-overlay.active .modal {
    transform: scale(1) translateY(0);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 28px;
}

.modal-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--text);
}

.modal-close {
    width: 36px;
    height: 36px;
    border: none;
    background: var(--bg);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    color: var(--text-secondary);
}

.modal-close:hover {
    background: var(--border);
    color: var(--text);
    transform: rotate(90deg);
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text);
}

.form-input {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 15px;
    transition: all 0.3s ease;
    background: var(--bg);
}

.form-input:focus {
    outline: none;
    border-color: var(--secondary);
    box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.1);
    background: var(--card-bg);
}

.form-input::placeholder {
    color: var(--text-muted);
}

.form-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: var(--text-secondary);
    cursor: pointer;
}

.form-checkbox input {
    width: 18px;
    height: 18px;
    accent-color: var(--secondary);
    cursor: pointer;
}

.btn-primary {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, var(--secondary), var(--info));
    color: white;
    border: none;
    border-radius: var(--radius);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(6, 182, 212, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(6, 182, 212, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.login-error {
    color: var(--danger);
    font-size: 14px;
    margin-top: 12px;
    padding: 10px 14px;
    background: rgba(239, 68, 68, 0.08);
    border-radius: var(--radius-sm);
    display: none;
    align-items: center;
    gap: 8px;
}

.demo-account {
    margin-top: 20px;
    padding: 14px;
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.08), rgba(59, 130, 246, 0.08));
    border-radius: var(--radius);
    font-size: 13px;
    color: var(--text-secondary);
    text-align: center;
    border: 1px dashed rgba(6, 182, 212, 0.3);
}

.demo-account strong {
    color: var(--secondary);
}

/* ==================== 视频播放器弹窗 ==================== */
.video-modal .modal {
    max-width: 960px;
    padding: 0;
    background: #000;
    overflow: hidden;
    border-radius: var(--radius-lg);
}

.video-modal .modal-header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    padding: 20px;
    background: linear-gradient(to bottom, rgba(0,0,0,0.9) 0%, transparent 100%);
    z-index: 10;
    margin-bottom: 0;
}

.video-modal .modal-title {
    color: white;
    font-size: 18px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.video-modal .modal-close {
    background: rgba(255,255,255,0.15);
    color: white;
}

.video-modal .modal-close:hover {
    background: rgba(255,255,255,0.25);
}

.video-container {
    width: 100%;
    aspect-ratio: 16/9;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.video-player {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.video-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.95) 0%, transparent 100%);
    padding: 50px 24px 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.video-container:hover .video-controls {
    opacity: 1;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(255,255,255,0.2);
    border-radius: 3px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--secondary), var(--secondary-light));
    border-radius: 3px;
    width: 0%;
    transition: width 0.1s linear;
    position: relative;
}

.progress-fill::after {
    content: '';
    position: absolute;
    right: -8px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.progress-bar:hover .progress-fill::after {
    opacity: 1;
}

.control-buttons {
    display: flex;
    align-items: center;
    gap: 16px;
}

.control-btn {
    background: none;
    border: none;
    color: white;
    font-size: 18px;
    cursor: pointer;
    padding: 10px;
    border-radius: 50%;
    transition: all 0.2s ease;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.control-btn:hover {
    background: rgba(255,255,255,0.15);
    transform: scale(1.1);
}

.control-time {
    color: white;
    font-size: 14px;
    font-family: 'Courier New', monospace;
    margin-left: auto;
    margin-right: 8px;
}

.speed-select {
    background: rgba(255,255,255,0.15);
    border: none;
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
}

.speed-select option {
    background: #1e293b;
    color: white;
    padding: 8px;
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 10px;
}

.volume-slider {
    width: 80px;
    height: 4px;
    background: rgba(255,255,255,0.2);
    border-radius: 2px;
    cursor: pointer;
    appearance: none;
}

.volume-slider::-webkit-slider-thumb {
    appearance: none;
    width: 12px;
    height: 12px;
    background: white;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* ==================== 3D查看器弹窗 ==================== */
.viewer3d-modal .modal {
    max-width: 1200px;
    padding: 0;
    overflow: hidden;
    border-radius: var(--radius-lg);
}

.viewer3d-container {
    width: 100%;
    height: 600px;
    position: relative;
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
}

#viewer3d-canvas {
    width: 100%;
    height: 100%;
}

.viewer3d-controls {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    background: rgba(0,0,0,0.7);
    padding: 10px 20px;
    border-radius: 30px;
    backdrop-filter: blur(10px);
}

.viewer3d-btn {
    background: rgba(255,255,255,0.1);
    border: none;
    color: white;
    padding: 10px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.viewer3d-btn:hover {
    background: rgba(255,255,255,0.2);
}

.viewer3d-btn.active {
    background: var(--secondary);
}

.viewer3d-hotspot {
    position: absolute;
    width: 30px;
    height: 30px;
    background: var(--secondary);
    border-radius: 50%;
    cursor: pointer;
    animation: pulse 2s infinite;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 14px;
    font-weight: bold;
    box-shadow: 0 0 20px rgba(6, 182, 212, 0.5);
}

.viewer3d-tooltip {
    position: absolute;
    background: rgba(0,0,0,0.9);
    color: white;
    padding: 12px 16px;
    border-radius: var(--radius);
    font-size: 13px;
    max-width: 250px;
    z-index: 100;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.viewer3d-tooltip.visible {
    opacity: 1;
}

.viewer3d-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: white;
}

.viewer3d-loading i {
    font-size: 48px;
    animation: spin 1s linear infinite;
    margin-bottom: 16px;
}

/* ==================== 图文内容弹窗 ==================== */
.article-modal .modal {
    max-width: 900px;
    max-height: 85vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    padding: 0;
}

.article-modal .modal-header {
    padding: 24px 32px;
    border-bottom: 1px solid var(--border);
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
}

.article-content {
    overflow-y: auto;
    padding: 32px;
    line-height: 1.8;
    color: var(--text);
    background: var(--card-bg);
}

/* 文章标题样式 */
.article-content h1 {
    font-size: 28px;
    font-weight: 700;
    margin: 0 0 24px;
    color: var(--text);
    padding-bottom: 16px;
    border-bottom: 2px solid var(--secondary);
}

.article-content h2 {
    font-size: 22px;
    font-weight: 700;
    margin: 32px 0 16px;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 10px;
}

.article-content h2::before {
    content: '';
    width: 4px;
    height: 24px;
    background: linear-gradient(180deg, var(--secondary), var(--secondary-light));
    border-radius: 2px;
}

.article-content h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 24px 0 12px;
    color: var(--secondary);
}

.article-content p {
    margin-bottom: 16px;
    color: var(--text-secondary);
    font-size: 15px;
    text-align: justify;
}

/* 文章图片样式 */
.article-content img {
    max-width: 100%;
    border-radius: var(--radius-lg);
    margin: 24px 0;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border);
}

.article-content figure {
    margin: 24px 0;
    text-align: center;
}

.article-content figcaption {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 8px;
    font-style: italic;
}

/* 列表样式 */
.article-content ul, .article-content ol {
    margin: 16px 0;
    padding-left: 24px;
}

.article-content li {
    margin-bottom: 10px;
    color: var(--text-secondary);
}

.article-content ul li::marker {
    color: var(--secondary);
}

/* 强调文字 */
.article-content strong {
    color: var(--text);
    font-weight: 600;
}

.article-content em {
    color: var(--secondary);
    font-style: normal;
}

/* 信息框 */
.article-content .info-box {
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.08), rgba(59, 130, 246, 0.05));
    border-left: 4px solid var(--secondary);
    padding: 20px 24px;
    margin: 24px 0;
    border-radius: 0 var(--radius) var(--radius) 0;
}

.article-content .info-box h4 {
    color: var(--secondary);
    font-size: 16px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* 警告框 */
.article-content .warning-box {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.08), rgba(245, 158, 11, 0.05));
    border-left: 4px solid var(--warning);
    padding: 20px 24px;
    margin: 24px 0;
    border-radius: 0 var(--radius) var(--radius) 0;
}

.article-content .warning-box h4 {
    color: var(--warning);
    font-size: 16px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* 步骤列表 */
.article-content .step-list {
    counter-reset: step;
    list-style: none;
    padding-left: 0;
}

.article-content .step-list li {
    position: relative;
    padding-left: 50px;
    margin-bottom: 20px;
    min-height: 36px;
}

.article-content .step-list li::before {
    counter-increment: step;
    content: counter(step);
    position: absolute;
    left: 0;
    top: 0;
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--secondary), var(--info));
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
}

/* 表格样式 */
.article-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 24px 0;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.article-content th {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    padding: 14px 16px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
}

.article-content td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
    color: var(--text-secondary);
}

.article-content tr:nth-child(even) {
    background: #f8fafc;
}

.article-content tr:hover {
    background: #f1f5f9;
}

/* 分割线 */
.article-content hr {
    border: none;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border), transparent);
    margin: 32px 0;
}

/* 标签 */
.article-content .tag-inline {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    background: rgba(6, 182, 212, 0.1);
    color: var(--secondary);
}

/* 文章底部信息 */
.article-content .article-footer {
    margin-top: 40px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.article-content .article-meta {
    font-size: 13px;
    color: var(--text-muted);
}

.article-content .article-actions {
    display: flex;
    gap: 10px;
}

/* ==================== 设置弹窗 ==================== */
.settings-modal .modal {
    max-width: 500px;
}

.settings-section {
    margin-bottom: 28px;
}

.settings-title {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 8px;
}

.settings-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
    border-bottom: 1px solid var(--border-light);
}

.settings-item:last-child {
    border-bottom: none;
}

.settings-label {
    font-size: 14px;
    color: var(--text);
    font-weight: 500;
}

.settings-desc {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
}

.settings-input {
    padding: 10px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 14px;
    width: 260px;
    transition: all 0.3s ease;
}

.settings-input:focus {
    outline: none;
    border-color: var(--secondary);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}


/* ==================== 提示消息 ==================== */
.toast {
    position: fixed;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--text);
    color: white;
    padding: 14px 28px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 500;
    z-index: 3000;
    opacity: 0;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 10px;
}

.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.toast.success {
    background: var(--success);
}

.toast.error {
    background: var(--danger);
}

.toast.info {
    background: var(--info);
}

/* ==================== 加载动画 ==================== */
.skeleton {
    background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: var(--radius);
}

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255,255,255,0.9);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.loading-overlay.active {
    opacity: 1;
    visibility: visible;
}

.loading-spinner {
    text-align: center;
}

.loading-spinner i {
    font-size: 48px;
    color: var(--secondary);
    animation: spin 1s linear infinite;
}

.loading-spinner p {
    margin-top: 16px;
    color: var(--text-secondary);
    font-size: 14px;
}

/* ==================== 筛选标签栏 ==================== */
.filter-bar {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    align-items: center;
}

.filter-label {
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 500;
    margin-right: 8px;
}

.filter-tag {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: var(--card-bg);
    border: 1px solid var(--border);
    color: var(--text-secondary);
}

.filter-tag:hover {
    border-color: var(--secondary);
    color: var(--secondary);
}

.filter-tag.active {
    background: var(--secondary);
    color: white;
    border-color: var(--secondary);
}

/* ==================== 响应式设计 ==================== */
@media (max-width: 1200px) {
    .sidebar {
        width: 260px;
    }
    .content-wrapper,
    .footer {
        margin-left: 260px;
    }
}

@media (max-width: 992px) {
    .search-box {
        width: 200px;
    }
    .grid-view {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    }
    .stats-bar {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .header {
        padding: 0 16px;
    }
    .header-title {
        font-size: 18px;
    }
    .header-subtitle {
        display: none;
    }
    .search-box {
        display: none;
    }
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        z-index: 999;
    }
    .sidebar.open {
        transform: translateX(0);
    }
    .content-wrapper,
    .footer {
        margin-left: 0;
    }
    .grid-view {
        grid-template-columns: 1fr;
    }
    .stats-bar {
        grid-template-columns: 1fr;
    }
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    .category-bar {
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
    }
    .category-tab {
        white-space: nowrap;
    }
    .list-item {
        flex-direction: column;
        text-align: center;
    }
    .list-item-icon {
        margin-right: 0;
        margin-bottom: 12px;
    }
    .list-item-arrow {
        display: none;
    }
    .modal {
        margin: 16px;
    }
}

/* ==================== 滚动条样式 ==================== */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg);
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* ==================== 打印样式 ==================== */
@media print {
    .header,
    .sidebar,
    .footer,
    .category-bar,
    .stats-bar {
        display: none;
    }
    .content-wrapper {
        margin-left: 0;
    }
    .content {
        padding: 0;
    }
}

/* ==================== 用户管理模块样式 ==================== */
/* 版本: 1.0.0 */

/* ==================== 用户下拉菜单 ==================== */
.user-menu {
    position: relative;
}

.user-info-dropdown {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.user-info-dropdown:hover {
    background: rgba(255, 255, 255, 0.2);
}

.user-info-dropdown .user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--secondary), var(--info));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 14px;
    overflow: hidden;
}

.user-info-dropdown .user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-info-dropdown .user-name {
    color: white;
    font-weight: 500;
    font-size: 14px;
}

.user-dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 180px;
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    padding: 8px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
}

.user-dropdown-menu.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-dropdown-menu::before {
    content: '';
    position: absolute;
    top: -6px;
    right: 20px;
    width: 12px;
    height: 12px;
    background: white;
    transform: rotate(45deg);
    border-radius: 2px;
}

.dropdown-header {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-light);
}

.dropdown-username {
    display: block;
    font-weight: 600;
    color: var(--text);
    font-size: 14px;
}

.dropdown-role {
    display: block;
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
}

.dropdown-divider {
    height: 1px;
    background: var(--border-light);
    margin: 8px 0;
}

.user-dropdown-menu a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    color: var(--text);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s ease;
}

.user-dropdown-menu a:hover {
    background: var(--bg);
    color: var(--secondary);
}

.user-dropdown-menu a i {
    width: 18px;
    color: var(--text-muted);
}

.user-dropdown-menu a:hover i {
    color: var(--secondary);
}

/* ==================== 用户管理弹窗 ==================== */
.modal-large {
    max-width: 900px !important;
    width: 90% !important;
}

.user-management-modal .modal-body {
    padding: 24px;
    max-height: 70vh;
    overflow-y: auto;
}

/* 数据库统计 */
.db-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 24px;
    padding: 20px;
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
    border-radius: var(--radius);
    border: 1px solid var(--border);
}

.stat-item {
    text-align: center;
    padding: 12px;
}

.stat-value {
    display: block;
    font-size: 28px;
    font-weight: 700;
    color: var(--secondary);
    line-height: 1;
}

.stat-label {
    display: block;
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 6px;
}

/* 工具栏 */
.user-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    gap: 16px;
    flex-wrap: wrap;
}

.toolbar-left {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.toolbar-right {
    flex: 1;
    min-width: 200px;
    max-width: 300px;
}

.search-box-small {
    position: relative;
    width: 100%;
}

.search-box-small i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 14px;
}

.search-box-small input {
    width: 100%;
    padding: 10px 12px 10px 36px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 14px;
    transition: all 0.3s ease;
}

.search-box-small input:focus {
    outline: none;
    border-color: var(--secondary);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}

/* 按钮样式 */
.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: var(--bg);
    border-color: var(--secondary);
    color: var(--secondary);
}

.btn-danger {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    background: white;
    border: 1px solid var(--danger);
    border-radius: var(--radius-sm);
    color: var(--danger);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-danger:hover {
    background: var(--danger);
    color: white;
}

/* 数据表格 */
.table-container {
    overflow-x: auto;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    margin-bottom: 24px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.data-table th,
.data-table td {
    padding: 14px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-light);
}

.data-table th {
    background: #f8fafc;
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.data-table tbody tr:hover {
    background: #f8fafc;
}

.data-table tbody tr:last-child td {
    border-bottom: none;
}

.empty-table {
    text-align: center;
    padding: 60px 20px !important;
    color: var(--text-muted);
}

.empty-table i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

/* 用户信息单元格 */
.user-info-cell {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar-small {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--secondary), var(--info));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 16px;
    overflow: hidden;
    flex-shrink: 0;
}

.user-avatar-small img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-info-text {
    min-width: 0;
}

.user-name {
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.user-username {
    font-size: 12px;
    color: var(--text-muted);
}

/* 状态标签 */
.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.status-badge.active {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.status-badge.inactive {
    background: rgba(148, 163, 184, 0.1);
    color: var(--text-muted);
}

.role-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.role-badge.admin {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
}

.role-badge.user {
    background: rgba(6, 182, 212, 0.1);
    color: var(--secondary);
}

/* 操作按钮 */
.action-btns {
    display: flex;
    gap: 6px;
}

.action-btn {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-size: 13px;
}

.action-btn.edit {
    background: rgba(59, 130, 246, 0.1);
    color: var(--info);
}

.action-btn.edit:hover {
    background: var(--info);
    color: white;
}

.action-btn.reset {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

.action-btn.reset:hover {
    background: var(--warning);
    color: white;
}

.action-btn.delete {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
}

.action-btn.delete:hover {
    background: var(--danger);
    color: white;
}

.current-user-label {
    font-size: 12px;
    color: var(--text-muted);
    padding: 4px 8px;
    background: var(--border-light);
    border-radius: var(--radius-sm);
}

/* 危险操作区 */
.danger-zone {
    margin-top: 24px;
    padding: 20px;
    background: rgba(239, 68, 68, 0.05);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: var(--radius);
}

.danger-zone h4 {
    color: var(--danger);
    font-size: 14px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* 表单样式补充 */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.form-select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 14px;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.form-select:focus {
    outline: none;
    border-color: var(--secondary);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}

.form-hint {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 6px;
}

.required {
    color: var(--danger);
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--border-light);
}

/* 文本颜色 */
.text-muted {
    color: var(--text-muted);
}

/* 响应式调整 */
@media (max-width: 768px) {
    .modal-large {
        width: 95% !important;
        max-height: 90vh;
    }
    
    .db-stats {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .user-toolbar {
        flex-direction: column;
        align-items: stretch;
    }
    
    .toolbar-right {
        max-width: none;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .data-table {
        font-size: 12px;
    }
    
    .data-table th,
    .data-table td {
        padding: 10px 12px;
    }
    
    .action-btns {
        flex-direction: column;
        gap: 4px;
    }
    
    .action-btn {
        width: 28px;
        height: 28px;
    }
}

/* ==================== 登录错误提示 ==================== */
.login-error {
    display: none;
    align-items: center;
    gap: 8px;
    padding: 12px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: var(--radius-sm);
    color: var(--danger);
    font-size: 14px;
    margin-bottom: 16px;
}

.demo-account {
    margin-top: 16px;
    padding: 12px;
    background: rgba(6, 182, 212, 0.05);
    border-radius: var(--radius-sm);
    font-size: 13px;
    color: var(--text-secondary);
}

/* ==================== 打印样式 ==================== */
@media print {
    .user-management-modal,
    .modal-overlay {
        display: none !important;
    }
}
