/* ==================== 基础样式 ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 霓虹黑色电影 - 字体系统 */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
    /* 霓虹色系 */
    --neon-cyan: #00f5ff;
    --neon-magenta: #ff00ff;
    --neon-yellow: #f5ff00;
    --neon-green: #00ff88;
    
    /* 深色背景 */
    --deep-black: #050508;
    --charcoal: #0a0a0f;
    --dark-gray: #141418;
    
    /* 玻璃态 */
    --glass-black: rgba(10, 10, 15, 0.85);
    --glass-white: rgba(255, 255, 255, 0.03);
    --glass-white-hover: rgba(255, 255, 255, 0.06);
    
    /* 文字 */
    --text-primary: #f8fafc;
    --text-secondary: #64748b;
    --text-muted: #475569;
    
    /* 边框 */
    --border-color: rgba(255, 255, 255, 0.08);
    --border-neon: rgba(0, 245, 255, 0.2);
    
    /* 字体 */
    --font-display: 'Space Grotesk', sans-serif;
    --font-body: 'Space Grotesk', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
    
    /* 尺寸 */
    --sidebar-width: 260px;
    --toolbar-width: 320px;
    --header-height: 70px;
    
    /* 文字比例 */
    --text-xs: 11px;
    --text-sm: 13px;
    --text-base: 15px;
    --text-lg: 17px;
    --text-xl: 20px;
    --text-2xl: 24px;
    --text-3xl: 30px;
}

/* 浅色主题适配（保持霓虹风格） */
body.theme-light {
    --deep-black: #f8fafc;
    --charcoal: #f1f5f9;
    --dark-gray: #e2e8f0;
    --glass-black: rgba(255, 255, 255, 0.9);
    --glass-white: rgba(0, 0, 0, 0.02);
    --glass-white-hover: rgba(0, 0, 0, 0.05);
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --border-color: rgba(0, 0, 0, 0.08);
    --border-neon: rgba(0, 245, 255, 0.3);
}

body {
    font-family: var(--font-body);
    background: var(--deep-black);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.5;
}

/* ==================== 动态背景 - 霓虹网格 ==================== */
.bg-effects {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.bg-gradient {
    position: absolute;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(ellipse at top, rgba(0, 245, 255, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at bottom right, rgba(255, 0, 255, 0.05) 0%, transparent 50%),
        radial-gradient(ellipse at bottom left, rgba(245, 255, 0, 0.03) 0%, transparent 40%),
        var(--deep-black);
}

/* 几何网格背景 */
.bg-grid-pattern {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(0, 245, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 245, 255, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    animation: gridPulse 8s ease-in-out infinite;
}

@keyframes gridPulse {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 0.7; }
}

/* 霓虹光点 */
.bg-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.25;
    animation: neonFloat 15s ease-in-out infinite;
}

.bg-orb-1 {
    width: 300px;
    height: 300px;
    background: var(--neon-cyan);
    top: -50px;
    left: -50px;
    animation-delay: 0s;
}

.bg-orb-2 {
    width: 250px;
    height: 250px;
    background: var(--neon-magenta);
    bottom: -50px;
    right: -50px;
    animation-delay: -5s;
}

.bg-orb-3 {
    width: 200px;
    height: 200px;
    background: var(--neon-yellow);
    top: 50%;
    left: 50%;
    animation-delay: -10s;
}

@keyframes neonFloat {
    0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.25; }
    25% { transform: translate(30px, -30px) scale(1.15); opacity: 0.35; }
    50% { transform: translate(-20px, 20px) scale(0.9); opacity: 0.2; }
    75% { transform: translate(20px, 10px) scale(1.05); opacity: 0.3; }
}

/* ==================== 主布局 ==================== */
.app-container {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* ==================== 顶部导航栏 ==================== */
.header {
    height: var(--header-height);
    background: var(--glass-black);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-left, .header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-btn {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--glass-white);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.header-btn:hover {
    background: var(--glass-white-hover);
    color: var(--neon-cyan);
    border-color: var(--border-neon);
    box-shadow: 0 0 15px rgba(0, 245, 255, 0.2);
}

.header-btn svg {
    width: 20px;
    height: 20px;
}

/* 搜索栏 */
.search-container {
    flex: 1;
    max-width: 720px;
    margin: 0 32px;
}

.search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.search-input {
    width: 100%;
    height: 52px;
    background: var(--glass-white);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 0 60px 0 56px;
    color: var(--text-primary);
    font-size: 16px;
    font-family: var(--font-body);
    outline: none;
    transition: all 0.3s ease;
}

.search-input::placeholder {
    color: var(--text-muted);
}

.search-input:focus {
    border-color: var(--neon-cyan);
    box-shadow: 
        0 0 0 3px rgba(0, 245, 255, 0.1),
        0 0 20px rgba(0, 245, 255, 0.15);
}

.search-icon {
    position: absolute;
    left: 20px;
    color: var(--text-secondary);
    pointer-events: none;
}

.search-icon svg {
    width: 22px;
    height: 22px;
}

.search-mode-toggle {
    position: absolute;
    right: 12px;
    height: 36px;
    padding: 0 16px;
    background: var(--glass-white-hover);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    color: var(--text-secondary);
    font-size: 13px;
    font-family: var(--font-mono);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.search-mode-toggle:hover {
    background: rgba(0, 245, 255, 0.1);
    color: var(--neon-cyan);
    border-color: var(--border-neon);
}

.search-mode-toggle.active {
    background: rgba(0, 245, 255, 0.15);
    color: var(--neon-cyan);
    border-color: var(--neon-cyan);
}

/* ==================== 主内容区 ==================== */
.main-content {
    display: flex;
    flex: 1;
    overflow: hidden;
}

/* ==================== 左侧导航栏 ==================== */
.sidebar {
    width: var(--sidebar-width);
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.sidebar.collapsed {
    width: 0;
    border-right: none;
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 18px;
    font-weight: 600;
}

.sidebar-logo svg {
    width: 32px;
    height: 32px;
    color: var(--primary-color);
}

.sidebar-nav {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

.nav-section {
    margin-bottom: 24px;
}

.nav-section-title {
    font-size: 12px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
    padding: 0 12px;
}

.nav-section-count {
    margin-left: 6px;
    font-size: 11px;
    background: var(--glass-white-hover);
    padding: 2px 8px;
    border-radius: 8px;
    color: var(--text-secondary);
}

.selected-tags-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 0 12px;
}

.selected-tag-item {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 8px;
    color: var(--primary-color);
    font-size: 12px;
    font-family: var(--font-mono);
    cursor: pointer;
    transition: all 0.2s ease;
}

.selected-tag-item:hover {
    background: rgba(99, 102, 241, 0.25);
    border-color: var(--primary-color);
    transform: translateY(-1px);
}

.selected-tag-text {
    font-weight: 500;
}

.selected-tag-close {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
    opacity: 0.7;
    transition: opacity 0.2s ease;
}

.selected-tag-item:hover .selected-tag-close {
    opacity: 1;
}

.clear-all-tags-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 8px;
    color: #ef4444;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.clear-all-tags-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: #ef4444;
}

.clear-all-tags-btn svg {
    width: 14px;
    height: 14px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 4px;
}

.nav-item:hover {
    background: var(--bg-card-hover);
}

.nav-item.active {
    background: rgba(99, 102, 241, 0.2);
    border: 1px solid rgba(99, 102, 241, 0.3);
}

.nav-item-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: var(--bg-card);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.nav-item-icon svg {
    width: 20px;
    height: 20px;
    color: var(--text-secondary);
}

.nav-item.active .nav-item-icon {
    background: var(--primary-color);
}

.nav-item.active .nav-item-icon svg {
    color: white;
}

.nav-item-info {
    flex: 1;
    min-width: 0;
}

.nav-item-name {
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nav-item-tags {
    display: flex;
    gap: 4px;
    margin-top: 4px;
}

.nav-item-tag {
    font-size: 10px;
    padding: 2px 6px;
    background: var(--bg-card);
    border-radius: 4px;
    color: var(--text-secondary);
}

/* 多级导航样式 */
.nav-group {
    margin-bottom: 8px;
}

.nav-group-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    user-select: none;
}

.nav-group-header:hover {
    background: var(--bg-card-hover);
}

.nav-group-header-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-group-icon {
    width: 20px;
    height: 20px;
    color: var(--text-secondary);
    transition: transform 0.3s ease;
}

.nav-group-title {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
}

.nav-group-arrow {
    width: 16px;
    height: 16px;
    color: var(--text-secondary);
    transition: transform 0.3s ease;
}

.nav-group.collapsed .nav-group-arrow {
    transform: rotate(-90deg);
}

.nav-group.collapsed .nav-group-icon {
    transform: rotate(-90deg);
}

.nav-group-header.active {
    background: rgba(99, 102, 241, 0.15);
    border-left: 2px solid var(--primary-color);
}

.nav-group-header.active .nav-group-title {
    color: var(--primary-light);
}

.nav-group-items {
    overflow: hidden;
    max-height: 1000px;
    transition: max-height 0.4s ease;
}

.nav-group.collapsed .nav-group-items {
    max-height: 0;
}

.nav-sub-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px 10px 44px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 2px;
    font-size: 13px;
    color: var(--text-secondary);
}

.nav-sub-item:hover {
    background: var(--bg-card-hover);
    color: var(--text-primary);
}

.nav-sub-item.active {
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary-light);
    border-left: 2px solid var(--primary-color);
}

.nav-sub-item-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: var(--bg-card);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.nav-sub-item-icon svg {
    width: 16px;
    height: 16px;
}

.nav-sub-item-name {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nav-sub-item-count {
    font-size: 11px;
    padding: 2px 8px;
    background: var(--bg-card);
    border-radius: 10px;
    color: var(--text-secondary);
}

/* 导航目录项样式 */
.nav-dir-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px 10px 44px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 2px;
    font-size: 13px;
    color: var(--text-secondary);
}

.nav-dir-item:hover {
    background: var(--bg-card-hover);
    color: var(--text-primary);
}

.nav-dir-item.active {
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary-light);
    border-left: 2px solid var(--primary-color);
}

.nav-dir-item-name {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nav-dir-item-count {
    font-size: 11px;
    padding: 2px 8px;
    background: var(--bg-card);
    border-radius: 10px;
    color: var(--text-secondary);
}

.nav-dir-item.active .nav-dir-item-count {
    background: rgba(99, 102, 241, 0.3);
    color: var(--primary-light);
}

/* ==================== 中间内容区 - 瀑布流 ==================== */
.content-area {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
    scroll-behavior: smooth;
}

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

.content-title {
    font-size: 24px;
    font-weight: 600;
}

.content-actions {
    display: flex;
    gap: 12px;
}

.action-btn {
    padding: 10px 20px;
    background: var(--glass-white);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 14px;
    font-family: var(--font-display);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.action-btn:hover {
    background: var(--glass-white-hover);
    border-color: var(--neon-cyan);
    color: var(--neon-cyan);
    box-shadow: 0 0 15px rgba(0, 245, 255, 0.2);
}

.action-btn.primary {
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-magenta));
    border: none;
    color: #000;
    font-weight: 600;
}

.action-btn.primary:hover {
    background: linear-gradient(135deg, var(--neon-magenta), var(--neon-cyan));
    box-shadow: 
        0 0 20px rgba(0, 245, 255, 0.4),
        0 0 40px rgba(255, 0, 255, 0.3);
    transform: translateY(-2px);
}

/* ==================== 瀑布流网格 ==================== */
.masonry-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.card {
    background: linear-gradient(145deg, var(--charcoal), var(--dark-gray));
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 20px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    box-shadow: 
        0 4px 12px rgba(0, 0, 0, 0.3),
        0 0 0 1px rgba(0, 245, 255, 0.05);
}

/* 鼠标追踪光效 */
.card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(800px circle at var(--mouse-x, 50%) var(--mouse-y, 50%), 
        rgba(0, 245, 255, 0.08), transparent 40%);
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
}

.card:hover::before {
    opacity: 1;
}

/* 顶部霓虹边框 */
.card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--neon-cyan), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.card:hover::after {
    opacity: 1;
}

.card:hover {
    transform: translateY(-8px);
    border-color: var(--border-neon);
    box-shadow: 
        0 0 20px rgba(0, 245, 255, 0.15),
        0 0 40px rgba(0, 245, 255, 0.08),
        0 8px 24px rgba(0, 0, 0, 0.4);
}

.card-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 16px;
    position: relative;
    z-index: 1;
}

.card-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-magenta));
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(0, 245, 255, 0.3);
    transition: all 0.3s ease;
}

.card:hover .card-icon {
    transform: scale(1.1) rotate(3deg);
    box-shadow: 0 6px 20px rgba(0, 245, 255, 0.5);
}

.card-icon svg {
    width: 24px;
    height: 24px;
    color: white;
}

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

.card-title {
    font-family: var(--font-display);
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
    letter-spacing: -0.01em;
}

.card-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
    position: relative;
    z-index: 1;
}

.card-tag {
    font-size: 11px;
    padding: 4px 10px;
    background: rgba(0, 245, 255, 0.1);
    border: 1px solid rgba(0, 245, 255, 0.2);
    border-radius: 6px;
    color: var(--neon-cyan);
    font-family: var(--font-mono);
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}

.card-tag:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 245, 255, 0.2);
}

.card-tag.selected {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: #fff;
    box-shadow: 0 0 12px rgba(99, 102, 241, 0.4);
}

.card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
    position: relative;
    z-index: 1;
}

.card-session {
    font-size: 12px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-mono);
}

.card-actions {
    display: flex;
    gap: 8px;
}

.card-action-btn {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.card-action-btn:hover {
    background: rgba(0, 245, 255, 0.1);
    color: var(--neon-cyan);
    border-color: var(--border-neon);
    box-shadow: 0 0 10px rgba(0, 245, 255, 0.2);
}

.card-action-btn:hover svg {
    stroke: var(--neon-cyan);
}

.card-action-btn.active {
    color: #ef4444;
    border-color: rgba(239, 68, 68, 0.3);
}

.card-action-btn.active svg {
    fill: currentColor;
    stroke: #ef4444;
}

.card-action-btn.active:hover {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border-color: rgba(239, 68, 68, 0.5);
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.2);
}

/* ==================== 右侧工具栏 ==================== */
.toolbar {
    width: var(--toolbar-width);
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border-left: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.toolbar.collapsed {
    width: 0;
    border-left: none;
}

.toolbar-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.toolbar-title {
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-primary);
}

.toolbar-manage-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toolbar-manage-btn:hover {
    background: var(--bg-card-hover);
    color: var(--primary-color);
}
    color: var(--text-secondary);
}

.toolbar-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

/* 工具组件 - 霓虹风格 */
.tool-widget {
    background: linear-gradient(145deg, var(--charcoal), var(--dark-gray));
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 12px;
    margin-bottom: 12px;
    cursor: move;
    position: relative;
    overflow: hidden;
    box-shadow: 
        0 4px 12px rgba(0, 0, 0, 0.3),
        0 0 0 1px rgba(0, 245, 255, 0.05);
    transition: all 0.3s ease;
}

.tool-widget::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--neon-cyan), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.tool-widget:hover {
    border-color: var(--border-neon);
    box-shadow: 
        0 0 15px rgba(0, 245, 255, 0.15),
        0 4px 12px rgba(0, 0, 0, 0.4);
}

.tool-widget:hover::before {
    opacity: 1;
}

.tool-widget-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    position: relative;
    z-index: 1;
}

.tool-widget-title {
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-display);
    letter-spacing: 0.02em;
}

.tool-widget-title svg {
    width: 14px;
    height: 14px;
    color: var(--neon-cyan);
}

.tool-widget-close {
    width: 20px;
    height: 20px;
    border-radius: 4px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.tool-widget-close:hover {
    background: rgba(255, 0, 255, 0.2);
    color: var(--neon-magenta);
    box-shadow: 0 0 10px rgba(255, 0, 255, 0.3);
}

/* 便签组件 */
.note-widget textarea {
    width: 100%;
    min-height: 80px;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 13px;
    resize: none;
    outline: none;
    font-family: inherit;
    line-height: 1.5;
}

.note-widget textarea::placeholder {
    color: var(--text-secondary);
}

/* 日期组件 - 霓虹风格 */
.date-widget {
    text-align: center;
}

.date-current {
    font-size: 36px;
    font-weight: 700;
    font-family: var(--font-display);
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-magenta));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 20px rgba(0, 245, 255, 0.3);
}

.date-weekday {
    font-size: 14px;
    color: var(--text-secondary);
    margin-top: 8px;
    font-family: var(--font-mono);
    letter-spacing: 0.05em;
}

.date-full {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 4px;
    font-family: var(--font-mono);
}

/* 待办组件 */
.todo-widget .todo-input {
    width: 100%;
    padding: 10px;
    background: var(--bg-card-hover);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 13px;
    outline: none;
    margin-bottom: 10px;
}

.todo-widget .todo-input:focus {
    border-color: var(--primary-color);
}

.todo-list {
    list-style: none;
}

.todo-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
}

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

.todo-checkbox {
    width: 18px;
    height: 18px;
    border-radius: 5px;
    border: 2px solid var(--border-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.todo-checkbox.checked {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.todo-checkbox.checked svg {
    stroke: white;
}

.todo-text {
    flex: 1;
    font-size: 13px;
    transition: all 0.3s ease;
}

.todo-text.completed {
    text-decoration: line-through;
    color: var(--text-secondary);
}

.todo-delete {
    width: 20px;
    height: 20px;
    border-radius: 5px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s ease;
}

.todo-item:hover .todo-delete {
    opacity: 1;
}

.todo-delete:hover {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

/* 快捷键提示 */
.shortcuts-hint {
    margin-top: auto;
    padding: 16px;
    background: var(--bg-card);
    border-radius: 12px;
}

.shortcuts-hint-title {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.shortcut-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 13px;
}

.shortcut-keys {
    display: flex;
    gap: 4px;
}

.shortcut-key {
    padding: 4px 8px;
    background: var(--bg-card-hover);
    border-radius: 6px;
    font-size: 11px;
    font-family: monospace;
    border: 1px solid var(--border-color);
}

/* ==================== 工具管理 ==================== */
.widget-manager-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 10px;
    max-height: 350px;
    overflow-y: auto;
}

.widget-manager-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    transition: all 0.3s ease;
}

.widget-manager-item:hover {
    border-color: var(--primary-color);
    background: var(--bg-card-hover);
}

.widget-manager-item.added {
    opacity: 0.6;
}

.widget-manager-item-info {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.widget-manager-item-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card-hover);
    border-radius: 8px;
    color: var(--primary-color);
}

.widget-manager-item-icon svg {
    width: 18px;
    height: 18px;
}

.widget-manager-item-details {
    flex: 1;
}

.widget-manager-item-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 3px;
}

.widget-manager-item-desc {
    font-size: 11px;
    color: var(--text-secondary);
}

.widget-manager-item-btn {
    padding: 6px 12px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.widget-manager-item-btn:hover:not(:disabled) {
    opacity: 0.9;
    transform: translateY(-1px);
}

.widget-manager-item-btn:disabled {
    background: var(--bg-card-hover);
    color: var(--text-secondary);
    cursor: not-allowed;
}

/* ==================== 底部页脚 ==================== */
.footer {
    padding: 20px 24px;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border-top: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.footer-info {
    font-size: 13px;
    color: var(--text-secondary);
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-link {
    font-size: 13px;
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
    cursor: pointer;
}

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

/* ==================== 拖拽提示 ==================== */
.drag-preview {
    position: fixed;
    pointer-events: none;
    z-index: 1000;
    opacity: 0.8;
    transform: rotate(3deg);
}

/* ==================== 模态框 - 霓虹风格 ==================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 200;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: linear-gradient(145deg, var(--charcoal), var(--dark-gray));
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 32px;
    max-width: 500px;
    width: 90%;
    transform: scale(0.9);
    transition: all 0.3s ease;
    box-shadow: 
        0 0 40px rgba(0, 245, 255, 0.15),
        0 0 0 1px rgba(0, 245, 255, 0.1);
}

.modal-overlay.active .modal {
    transform: scale(1);
}

.modal-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 24px;
    font-family: var(--font-display);
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-magenta));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

.modal-form label {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 8px;
    display: block;
    font-family: var(--font-display);
}

.modal-form input,
.modal-form textarea,
.modal-form select {
    width: 100%;
    padding: 14px;
    background: var(--glass-white);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 14px;
    font-family: var(--font-body);
    outline: none;
    transition: all 0.3s ease;
}

.modal-form input:focus,
.modal-form textarea:focus,
.modal-form select:focus {
    border-color: var(--neon-cyan);
    box-shadow: 
        0 0 0 3px rgba(0, 245, 255, 0.1),
        0 0 15px rgba(0, 245, 255, 0.15);
}

.modal-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.modal-btn {
    flex: 1;
    padding: 14px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: var(--font-display);
    position: relative;
    overflow: hidden;
}

.modal-btn.secondary {
    background: var(--glass-white);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}

.modal-btn.secondary:hover {
    background: var(--glass-white-hover);
    border-color: var(--neon-cyan);
    color: var(--neon-cyan);
}

.modal-btn.primary {
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-magenta));
    border: none;
    color: #000;
    font-weight: 600;
}

.modal-btn.primary:hover {
    background: linear-gradient(135deg, var(--neon-magenta), var(--neon-cyan));
    box-shadow: 
        0 0 20px rgba(0, 245, 255, 0.4),
        0 0 40px rgba(255, 0, 255, 0.3);
    transform: translateY(-2px);
}

/* ==================== 响应式设计 ==================== */
@media (max-width: 1200px) {
    .toolbar {
        width: 280px;
    }
}

@media (max-width: 992px) {
    .sidebar {
        position: fixed;
        left: 0;
        top: var(--header-height);
        height: calc(100vh - var(--header-height));
        z-index: 50;
    }

    .sidebar.collapsed {
        transform: translateX(-100%);
    }

    .toolbar {
        position: fixed;
        right: 0;
        top: var(--header-height);
        height: calc(100vh - var(--header-height));
        z-index: 50;
    }

    .toolbar.collapsed {
        transform: translateX(100%);
    }
}

@media (max-width: 768px) {
    .header {
        padding: 0 16px;
    }

    .search-container {
        margin: 0 16px;
    }

    .search-input {
        height: 48px;
        font-size: 14px;
    }

    .content-area {
        padding: 16px;
    }

    .masonry-grid {
        grid-template-columns: 1fr;
    }

    .footer {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }
}

/* ==================== 动画效果 - 霓虹风格 ==================== */
@keyframes slideUpFade {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes neonPulse {
    0%, 100% {
        box-shadow: 
            0 0 5px rgba(0, 245, 255, 0.3),
            0 0 10px rgba(0, 245, 255, 0.2);
    }
    50% {
        box-shadow: 
            0 0 10px rgba(0, 245, 255, 0.5),
            0 0 20px rgba(0, 245, 255, 0.3);
    }
}

@keyframes rippleEffect {
    0% {
        transform: scale(0);
        opacity: 1;
    }
    100% {
        transform: scale(4);
        opacity: 0;
    }
}

/* 卡片入场动画 */
.card {
    animation: slideUpFade 0.6s ease forwards;
    opacity: 0;
}

.card:nth-child(1) { animation-delay: 0.05s; }
.card:nth-child(2) { animation-delay: 0.1s; }
.card:nth-child(3) { animation-delay: 0.15s; }
.card:nth-child(4) { animation-delay: 0.2s; }
.card:nth-child(5) { animation-delay: 0.25s; }
.card:nth-child(6) { animation-delay: 0.3s; }
.card:nth-child(7) { animation-delay: 0.35s; }
.card:nth-child(8) { animation-delay: 0.4s; }
.card:nth-child(9) { animation-delay: 0.45s; }
.card:nth-child(10) { animation-delay: 0.5s; }
.card:nth-child(11) { animation-delay: 0.55s; }
.card:nth-child(12) { animation-delay: 0.6s; }

/* 搜索框聚焦动画 */
.search-input:focus {
    animation: neonPulse 2s ease-in-out infinite;
}

/* 按钮涟漪效果 */
.action-btn {
    position: relative;
    overflow: hidden;
}

.action-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(0, 245, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.4s ease, height 0.4s ease;
}

.action-btn:active::before {
    width: 200px;
    height: 200px;
}

/* 加载动画 */
.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border-color);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.empty-state svg {
    width: 80px;
    height: 80px;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-state h3 {
    font-size: 18px;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.empty-state p {
    font-size: 14px;
}

/* 通知提示 - 霓虹风格 */
.toast-container {
    position: fixed;
    bottom: 100px;
    right: 24px;
    z-index: 300;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.toast {
    padding: 16px 24px;
    background: linear-gradient(145deg, var(--charcoal), var(--dark-gray));
    border: 1px solid var(--border-color);
    border-radius: 12px;
    backdrop-filter: blur(20px);
    display: flex;
    align-items: center;
    gap: 12px;
    animation: neonSlideIn 0.4s cubic-bezier(0.2, 0, 0.1, 1);
    max-width: 350px;
    box-shadow: 
        0 4px 12px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(0, 245, 255, 0.05);
}

.toast.success {
    border-color: var(--neon-green);
    box-shadow: 
        0 4px 12px rgba(0, 0, 0, 0.4),
        0 0 15px rgba(0, 255, 136, 0.2);
}

.toast.error {
    border-color: var(--neon-magenta);
    box-shadow: 
        0 4px 12px rgba(0, 0, 0, 0.4),
        0 0 15px rgba(255, 0, 255, 0.2);
}

.toast.info {
    border-color: var(--neon-cyan);
    box-shadow: 
        0 4px 12px rgba(0, 0, 0, 0.4),
        0 0 15px rgba(0, 245, 255, 0.2);
}

@keyframes neonSlideIn {
    from {
        opacity: 0;
        transform: translateX(80px) translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(0) translateY(0);
    }
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-secondary);
}
