/**
 * 最安企商项目管理器 - 样式文件
 * 使用Ant Design风格设计
 */

/* ====== 主题色配置 ====== */
:root {
    --primary-color: #0066ff;        /* 主要蓝色 - 更蓝更纯净 */
    --primary-hover: #1a75ff;       /* 悬停状态 - 稍亮 */
    --primary-light: #e6f2ff;       /* 浅色背景 */
    --primary-border: #80b3ff;      /* 边框色 */
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
    overflow-x: hidden;
    min-width: 320px;
}

#app {
    height: 100vh;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
}

/* ====== 顶部导航栏 ====== */
.top-header {
    background-color: #fff;
    border-bottom: 1px solid #e8e8e8;
    padding: 6px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    z-index: 100;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 24px;
    flex: 1;
    min-width: 0;
}

/* ====== Logo容器样式 ====== */
.logo-container {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
    height: 28px; /* 固定容器高度，确保对齐 */
}

.company-logo {
    max-height: 28px;
    max-width: 140px;
    height: auto;
    width: auto;
    object-fit: contain;
    display: block;
    transition: opacity 0.3s ease;
}

.company-logo:hover {
    opacity: 0.8;
}

/* 备用标题样式 - 当logo加载失败时显示 */
.fallback-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--primary-color);
    margin: 0;
    flex-shrink: 0;
    display: none; /* 默认隐藏，只在logo加载失败时显示 */
    align-items: center;
    gap: 10px;
    line-height: 1.2;
}

/* 保持原有的project-title样式以向后兼容 */
.project-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--primary-color);
    margin: 0;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    line-height: 1.2;
}

.lite-badge {
    border-radius: 16px;
    vertical-align: middle;
    filter: drop-shadow(0 2px 4px color-mix(in srgb, var(--primary-color) 20%, transparent));
    align-self: center;
    margin-top: -1px; /* 微调垂直位置 */
}

.current-goal {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    flex: 1;
}

.current-goal .label {
    color: #666;
    font-size: 14px;
}

.current-goal .goal-name {
    color: #333;
    font-weight: 500;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.header-right {
    display: flex;
    gap: 12px;
    flex-shrink: 0;
}

/* ====== 按钮样式 ====== */
.btn {
    padding: 6px 16px;
    border: 1px solid transparent;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    background: none;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
}

.btn-outline {
    border-color: #d9d9d9;
    color: #333;
}

.btn-outline:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn-sm {
    padding: 4px 8px;
    font-size: 12px;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* 删除确认弹窗按钮样式 */
.modal .btn-secondary {
    border: 1px solid #d9d9d9 !important;
    background: #ffffff !important;
    color: #262626 !important;
    transform: none !important;
}

.modal .btn-secondary:hover {
    border-color: #40a9ff !important;
    color: #1890ff !important;
    background: #ffffff !important;
    transform: none !important;
    box-shadow: 0 2px 4px rgba(24, 144, 255, 0.2) !important;
}

.modal .btn-secondary:focus {
    outline: none !important;
    border-color: #40a9ff !important;
    box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2) !important;
}

.modal .btn-danger {
    border: 1px solid #ff4d4f !important;
    background: #ff4d4f !important;
    color: #ffffff !important;
    transform: none !important;
}

.modal .btn-danger:hover {
    border-color: #ff7875 !important;
    background: #ff7875 !important;
    color: #ffffff !important;
    transform: none !important;
    box-shadow: 0 2px 4px rgba(255, 77, 79, 0.2) !important;
}

.modal .btn-danger:focus {
    outline: none !important;
    border-color: #ff7875 !important;
    box-shadow: 0 0 0 2px rgba(255, 77, 79, 0.2) !important;
}

/* ====== 主内容区域 ====== */
.main-content {
    flex: 1;
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr 1fr 1fr 1fr;
    gap: 16px;
    padding: 20px;
    padding-bottom: 80px; /* 为固定底部栏留出空间 */
    background-color: #f5f5f5;
    overflow: auto;
    height: 0; /* 配合 flex: 1 确保正确的滚动行为 */
}

/* ====== 目标列 ====== */
.goals-column {
    background-color: #fff;
    border-radius: 8px;
    border: 1px solid #e8e8e8;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.column-header {
    padding: 16px;
    border-bottom: 1px solid #e8e8e8;
    background-color: #fafafa;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.column-header h2,
.column-header h3 {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin: 0;
}

/* 项目目标特殊样式 */
.column-header h2 {
    color: var(--primary-color);
    font-weight: 700;
}

/* 分项序号样式 */
.column-header h3 {
    position: relative;
}

.column-header h3::first-letter {
    color: var(--primary-color);
    font-weight: 700;
    margin-right: 2px;
}

.goals-list {
    flex: 1;
    padding: 16px;
    overflow-y: auto;
    max-height: calc(100vh - 200px);
    display: flex;
    flex-direction: column;
}

/* ====== 目标项样式 ====== */
.goal-item {
    padding: 12px;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    margin-bottom: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: #fff;
    position: relative;
}

.goal-item:hover {
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px color-mix(in srgb, var(--primary-color) 10%, transparent);
}

.goal-item.selected {
    border-color: var(--primary-color);
    background-color: var(--primary-light);
}

.goal-item.selected .goal-title::before {
    background-color: var(--primary-color);
    width: 4px;
    box-shadow: 0 0 4px rgba(24, 144, 255, 0.5);
}

.goal-content {
    position: relative;
}

.goal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 8px;
}

.goal-title {
    font-weight: 600;
    color: #333;
    font-size: 14px;
    flex: 1;
    padding-right: 10px; /* 增加右侧间距，避免被进度图标遮挡 */
    line-height: 1.4;
    position: relative;
    padding-left: 12px;
}

.goal-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background-color: var(--primary-color);
    border-radius: 2px;
    transition: all 0.3s ease;
}

.goal-progress-circle {
    position: relative;
    flex-shrink: 0;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 2px;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(255, 255, 255, 0.9);
    border: 1px solid #d9d9d9;
}

.goal-progress-circle:hover {
    transform: scale(1.1);
    background-color: rgba(255, 255, 255, 1);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.goal-progress-circle canvas {
    width: 16px;
    height: 16px;
    display: block;
}

/* 已完成目标样式 */
.goal-item.completed {
    background-color: #f5f5f5;
    border-color: #e0e0e0;
    order: 999; /* 移到底部 */
}

.goal-item.completed .goal-title {
    color: #999 !important;
    text-decoration: line-through;
}

.goal-item.completed .goal-title::before {
    background-color: #ccc;
    box-shadow: none;
}

.goal-item.completed .goal-description {
    color: #bbb !important;
}

.goal-item.completed:hover {
    border-color: #d0d0d0;
    background-color: #f8f8f8;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.goal-item.completed.selected {
    border-color: #b0b0b0;
    background-color: #eeeeee;
}

.goal-description {
    color: #666;
    font-size: 12px;
    margin-bottom: 8px;
    line-height: 1.4;
}

.goal-actions {
    display: flex;
    gap: 8px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.goal-item:hover .goal-actions {
    opacity: 1;
}

.action-btn {
    padding: 2px 6px;
    font-size: 11px;
    border: 1px solid #d9d9d9;
    background: white;
    color: #666;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.action-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

/* ====== 任务列 ====== */
.tasks-columns {
    display: contents;
}

.task-column {
    background-color: #fff;
    border-radius: 8px;
    border: 1px solid #e8e8e8;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.tasks-list {
    flex: 1;
    padding: 16px;
    overflow-y: auto;
    max-height: calc(100vh - 200px);
    display: flex;
    flex-direction: column;
}

/* ====== 任务项样式 ====== */
.task-item {
    padding: 10px;
    border: 1px solid #f0f0f0;
    border-radius: 6px;
    margin-bottom: 10px;
    background-color: #fafafa;
    transition: all 0.3s ease;
    position: relative; /* 为绝对定位的红点提供定位基准 */
}

.task-item:hover {
    border-color: var(--primary-color);
    background-color: #fff;
    box-shadow: 0 2px 4px color-mix(in srgb, var(--primary-color) 10%, transparent);
}

/* 标记任务样式 - 置顶显示 */
.task-item.tagged {
    order: -1; /* 置顶显示 */
    border-left: 3px solid #1890ff; /* 左侧蓝色边框标识 */
    background-color: #f6f9ff; /* 轻微的蓝色背景 */
}

.task-item.tagged:hover {
    background-color: #e6f2ff; /* 悬停时稍深的蓝色背景 */
    border-left-color: #0050b3; /* 悬停时更深的边框色 */
}

/* 已完成任务样式 */
.task-item.completed {
    background-color: #f5f5f5;
    border-color: #e0e0e0;
    order: 999 !important; /* 移到底部，优先级高于tagged */
}

/* 已完成且tagged的任务样式 */
.task-item.completed.tagged {
    border-left: 3px solid #d9d9d9; /* 灰色边框，表示已完成 */
    background-color: #f5f5f5; /* 保持灰色背景 */
}

.task-item.completed .task-title {
    color: #999 !important;
    text-decoration: line-through;
}

.task-item.completed .task-description {
    color: #bbb !important;
}

.task-item.completed:hover {
    border-color: #d0d0d0;
    background-color: #f8f8f8;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.task-header {
    display: flex;
    align-items: flex-start; /* 改为顶端对齐，让完成度图标与文字顶端对齐 */
    gap: 8px;
    margin-bottom: 6px;
}

.completion-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    position: relative;
    margin-top: 2px; /* 微调位置，与文字基线对齐 */
    flex-shrink: 0; /* 防止图标被压缩 */
}

.completion-dot:hover {
    transform: scale(1.2);
    border-color: rgba(255, 255, 255, 0.5);
}

.completion-0 {
    background-color: #d9d9d9;
}

.completion-1 {
    background-color: #ff4d4f;
}

.completion-2 {
    background-color: #faad14;
}

.completion-3 {
    background-color: #52c41a;
}

/* 全局提示框样式 */
.global-tooltip {
    position: fixed;
    background-color: rgba(0, 0, 0, 0.9);
    color: white;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 12px;
    white-space: nowrap;
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    pointer-events: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    transform: translateX(-50%) translateY(-100%);
}

.global-tooltip.show {
    opacity: 1;
    visibility: visible;
}

.task-title {
    font-weight: 500;
    color: #333;
    flex: 1;
    font-size: 13px;
    padding-right: 11px; /* 为图钉留出空间，避免文字被遮挡 */
    word-break: break-word; /* 长文字自动换行 */
}

/* 共享红点样式 - 固定显示在右下角 */
.shared-dots {
    position: absolute;
    bottom: 8px;
    right: 8px;
    display: flex;
    align-items: center;
    gap: 1px;
    font-size: 8px; /* 从10px减小到8px */
    color: #ff4d4f;
    letter-spacing: 0.5px; /* 从1px减小到0.5px */
    opacity: 1;
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 1px 4px; /* 从2px 6px减小到1px 4px */
    border-radius: 4px; /* 从6px减小到4px */
    background-color: rgba(255, 77, 79, 0.08);
    border: 1px solid rgba(255, 77, 79, 0.2);
    font-weight: bold;
    z-index: 10;
}

.shared-dots:hover {
    opacity: 1;
    background-color: rgba(255, 77, 79, 0.15);
    border-color: rgba(255, 77, 79, 0.4);
    transform: scale(1.05);
}

/* 限制红点数量显示，避免过长 */
.shared-dots {
    max-width: 50px; /* 从60px减小到50px */
    overflow: hidden;
    white-space: nowrap;
}

/* Tag图钉样式 - 显示在右上角，左斜插入效果 */
.task-tag-icon {
    position: absolute;
    top: 4px;
    right: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 16.8px; /* 14px * 1.2 = 16.8px，放大20% */
    height: 16.8px; /* 14px * 1.2 = 16.8px，放大20% */
    background-color: #1890ff;
    border: 2px solid #ffffff;
    border-radius: 50%;
    color: #ffffff;
    font-size: 8.4px; /* 7px * 1.2 = 8.4px，放大20% */
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 10;
    transform: rotate(45deg); /* 轻微左斜旋转，模拟图钉插入角度 */
    box-shadow: 0 2px 6px rgba(24, 144, 255, 0.4), 0 0 0 1px rgba(24, 144, 255, 0.2); /* 立体阴影效果 */
}

.task-tag-icon i {
    pointer-events: none;
    transform: none; /* 图标跟随容器一起旋转 */
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    /* 如果图标仍然看起来不居中，可以微调这些值 */
    margin-left: -0.6px; /* 微调水平位置 */
    margin-top: 1.5px; /* 微调垂直位置 */
}

.task-description {
    color: #666;
    font-size: 11px;
    margin-bottom: 6px;
    line-height: 1.4;
    cursor: pointer;
    transition: all 0.3s ease;
    /* 默认状态：显示3行 */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-word;
}

/* 任务描述展开状态 */
.task-description.expanded {
    -webkit-line-clamp: unset;
    overflow: visible;
}

/* 任务描述悬停提示 */
.task-description:hover {
    background-color: rgba(24, 144, 255, 0.05);
    border-radius: 4px;
    padding: 2px 4px;
    margin: -2px -4px 4px -4px;
}

/* 通用可展开描述样式 */
.expandable-desc {
    cursor: pointer;
    transition: all 0.3s ease;
    /* 默认状态：显示3行 */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-word;
}

.expandable-desc.expanded {
    -webkit-line-clamp: unset;
    overflow: visible;
}

.expandable-desc:hover {
    background-color: rgba(24, 144, 255, 0.05);
    border-radius: 4px;
    padding: 2px 4px;
    margin: -2px -4px 4px -4px;
}

/* 移除了不再使用的共享标签样式 */

.task-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    opacity: 0;
    transition: opacity 0.3s ease;
    margin-top: 4px;
}

.task-item:hover .task-actions {
    opacity: 1;
}

/* ====== 底部状态栏 ====== */
.status-bar {
    background-color: #fff;
    border-top: 1px solid #e8e8e8;
    padding: 12px 24px;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 100;
    box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.1);
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
}

.stats {
    display: flex;
    gap: 24px;
    font-size: 13px;
    color: #666;
}

.stats span {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* 版权信息样式 - 居中显示 */
.copyright {
    font-size: 12px;
    color: #999;
    font-weight: 400;
    text-align: center;
    grid-column: 2;
}

.copyright span {
    white-space: nowrap;
}

/* 状态栏功能区域 - 右侧显示 */
.status-functions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    grid-column: 3;
    gap: 16px;
}

/* 使用说明文字样式 */
.help-text {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #666;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
    user-select: none;
}

.help-text:hover {
    color: #1890ff;
}

.help-text i {
    font-size: 10px;
    transition: transform 0.2s ease;
}

.help-text:hover i {
    transform: scale(1.1);
}

/* 筛选tags文字样式 */
.filter-tags-text {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #666;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
    user-select: none;
}

.filter-tags-text:hover {
    color: #1890ff;
}

.filter-tags-text.active {
    color: #1890ff;
    font-weight: 500;
}

.filter-tags-text i {
    font-size: 10px;
    transition: transform 0.2s ease;
}

.filter-tags-text:hover i {
    transform: rotate(-15deg);
}

.filter-tags-text.active i {
    transform: rotate(-15deg);
}

/* 预览全部文字样式 */
.preview-all-text {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #666;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
    user-select: none;
}

.preview-all-text:hover {
    color: #1890ff;
}

.preview-all-text i {
    font-size: 10px;
    transition: transform 0.2s ease;
}

.preview-all-text:hover i {
    transform: scale(1.1);
}

/* 完结清理文字样式 */
.cleanup-completed-text {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #666;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
    user-select: none;
}

.cleanup-completed-text:hover {
    color: #1890ff;
}

.cleanup-completed-text i {
    font-size: 10px;
    transition: transform 0.2s ease;
}

.cleanup-completed-text:hover i {
    transform: rotate(15deg);
}

/* 企业看板按钮样式 */
.enterprise-dashboard-text {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #666;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
    user-select: none;
}

.enterprise-dashboard-text:hover {
    color: #1890ff;
}

.enterprise-dashboard-text i {
    font-size: 10px;
    transition: transform 0.2s ease;
}

.enterprise-dashboard-text:hover i {
    transform: scale(1.1);
}

/* 筛选空状态提示 */
.empty-filter-hint {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    text-align: center;
    color: #999;
}

.empty-filter-hint i {
    margin-bottom: 8px;
}

.empty-filter-hint p {
    margin: 0;
    font-size: 12px;
    line-height: 1.4;
}


/* ====== 协作者筛选样式 ====== */
.collaborator-filter {
    padding: 16px 20px 12px;
    border-bottom: 1px solid #f0f0f0;
}

.filter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.filter-tag {
    display: inline-block;
    padding: 0 8px;
    font-size: 13px;
    color: #666;
    cursor: pointer;
    user-select: none;
    white-space: nowrap;
}

.filter-tag:hover {
    color: #1890ff;
}

.filter-tag.active {
    color: #1890ff;
    font-weight: 500;
}

/* ====== 文档风格弹窗样式 ====== */
.document-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 1001;
    animation: fadeIn 0.3s ease;
}

.document-modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.document-modal-content {
    width: 60%;
    max-width: 920px;
    min-width: 610px;
    height: 95vh;
    max-height: none;
    margin: 1% auto;
    display: flex;
    flex-direction: column;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border: 1px solid #d9d9d9;
    overflow: hidden;
    background: white;
}

/* 小屏幕响应式 */
@media (max-width: 1400px) {
    .document-modal-content {
        width: 65%;
        min-width: 460px;
    }
}

/* 文档头部 */
.document-header {
    padding: 12px 20px;
    background: white;
    border-bottom: 1px solid #e8e8e8;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.document-header h3 {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: #262626;
}

.document-header .close {
    font-size: 16px;
    color: #999;
    cursor: pointer;
    line-height: 1;
}

.document-header .close:hover {
    color: #666;
}

/* 文档主体 */
.document-body {
    flex: 1;
    overflow-y: auto;
    padding: 0;
    background: white;
}

/* 文档元信息 */
.document-meta {
    padding: 16px 20px 12px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #666;
    background: #fafafa;
}

.meta-info {
    display: flex;
    gap: 32px;
}

.meta-info span {
    white-space: nowrap;
}

.meta-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.copy-all-text {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #666;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
    user-select: none;
    padding: 4px 8px;
    border-radius: 4px;
}

.copy-all-text:hover {
    color: #1890ff;
    background: rgba(24, 144, 255, 0.1);
}

.copy-all-text i {
    font-size: 11px;
    transition: transform 0.2s ease;
}

.copy-all-text:hover i {
    transform: scale(1.1);
}

.copy-all-text.copying {
    color: #52c41a;
}

.copy-all-text.copying i {
    transform: scale(1.2);
}

/* 复制成功状态 */
.copy-all-text.success {
    color: #fff;
    background-color: #52c41a;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.copy-all-text.success:hover {
    color: #fff;
    background-color: #52c41a;
}

.copy-all-text.success i {
    transform: scale(1.1);
}

/* 文档内容区域 */
.document-content {
    padding: 20px;
    line-height: 1.6;
    color: #262626;
}

/* 文档内容区域内的标准HTML标签样式 */
.document-content h3 {
    font-size: 14px;
    font-weight: 600;
    color: #262626;
    margin: 24px 0 8px 0;
    padding-bottom: 6px;
    border-bottom: 1px solid #e8e8e8;
}

.document-content h3:first-child {
    margin-top: 0;
}

.document-content h4 {
    font-size: 13px;
    font-weight: 600;
    color: #262626;
    margin: 16px 0 8px 0;
}

.document-content p {
    font-size: 12px;
    color: #666;
    margin: 0 0 12px 0;
    line-height: 1.5;
}

.document-content ul {
    margin: 0 0 12px 16px;
    padding-left: 12px;
}

.document-content li {
    font-size: 12px;
    color: #666;
    margin: 0 0 4px 0;
    line-height: 1.5;
}

.document-content strong {
    color: #262626;
    font-weight: 600;
}

/* 目标标题 (H1级别) */
.doc-goal-title {
    font-size: 14px;
    font-weight: 600;
    color: #262626;
    margin: 24px 0 8px 0;
    padding-bottom: 6px;
    border-bottom: 1px solid #e8e8e8;
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    min-height: 20px; /* 确保有足够高度容纳反馈文字 */
}

.doc-goal-title-text {
    flex: 1;
    margin-right: 8px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.doc-goal-title:first-child {
    margin-top: 0;
}

.doc-goal-title-text::before {
    content: "# ";
    color: #999;
    margin-right: 4px;
}

.copy-goal-icon {
    font-size: 11px;
    color: #999;
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 2px 4px;
    border-radius: 3px;
    user-select: none;
    flex-shrink: 0;
    margin-left: 8px;
    display: inline-flex;
    align-items: center;
    min-width: 12px; /* 确保有最小宽度 */
}

.copy-goal-icon:hover {
    color: #1890ff;
    background: rgba(24, 144, 255, 0.1);
    transform: scale(1.1);
}

.copy-goal-icon.copying {
    color: #52c41a;
    transform: scale(1.2);
}

.copy-feedback-text {
    color: #52c41a;
    font-size: 11px;
    font-weight: 500;
    margin-left: 4px;
    opacity: 0.9;
    white-space: nowrap;
    max-width: 60px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: inline-block;
    vertical-align: top;
}

/* 目标描述 */
.doc-goal-desc {
    font-size: 12px;
    color: #666;
    margin: 0 0 6px 0;
    line-height: 1.5;
    white-space: pre-wrap;
    word-break: break-word;
}

/* 目标统计 */
.doc-goal-stats {
    font-size: 11px;
    color: #999;
    margin: 0 0 16px 0;
    font-weight: 500;
}

/* 协作者分组 (H2级别) */
.doc-collaborator-title {
    font-size: 13px;
    font-weight: 600;
    color: #262626;
    margin: 16px 0 8px 0;
}

.doc-collaborator-title::before {
    content: "## ";
    color: #999;
    margin-right: 4px;
}

/* 任务项 */
.doc-task-item {
    margin: 0 0 12px 16px;
    padding-left: 12px;
    border-left: 2px solid #f0f0f0;
}

/* 任务标题 (H3级别) */
.doc-task-title {
    font-size: 13px;
    font-weight: 600;
    color: #262626;
    margin: 0 0 4px 0;
}

/* 任务状态信息 */
.doc-task-meta {
    font-size: 11px;
    color: #999;
    margin: 0 0 6px 0;
}

.doc-task-meta .status-completed {
    color: #52c41a;
    font-weight: 500;
}

.doc-task-meta .status-progress {
    color: #1890ff;
    font-weight: 500;
}

.doc-task-meta .status-pending {
    color: #999;
    font-weight: 500;
}

.doc-task-meta .tag-marked {
    color: #999;
    font-weight: 500;
}

/* 任务描述 */
.doc-task-desc {
    font-size: 12px;
    color: #666;
    margin: 0;
    line-height: 1.5;
    white-space: pre-wrap;
    word-break: break-word;
}

/* 分隔线 */
.doc-separator {
    border: none;
    border-top: 1px solid #e8e8e8;
    margin: 24px 0;
}

/* 空状态 */
.doc-empty {
    text-align: center;
    padding: 40px;
    color: #999;
    font-size: 12px;
}

/* 预览表格容器 */
.preview-table-container {
    flex: 1;
    overflow: auto;
    padding: 0;
}

.preview-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
    background: white;
}

.preview-table thead {
    position: sticky;
    top: 0;
    background: #fafafa;
    z-index: 10;
}

.preview-table th {
    padding: 12px 16px;
    text-align: left;
    font-weight: 600;
    color: #262626;
    border-bottom: 2px solid #e8e8e8;
    background: #fafafa;
}

.preview-table th.col-goal {
    width: 40%;
    min-width: 320px;
}

.preview-table th.col-tasks {
    width: 30%;
    min-width: 200px;
}

.preview-table th.col-details {
    width: 30%;
    min-width: 200px;
}

.preview-table td {
    padding: 12px 16px;
    vertical-align: top;
    border-bottom: 1px solid #f0f0f0;
    line-height: 1.4;
}


/* 目标信息单元格样式 */
.preview-table td[rowspan] {
    border-right: 2px solid #e8e8e8;
    background: white;
    vertical-align: top;
}

/* 任务行样式 */
.preview-table tbody tr:first-child td:first-child {
    border-top: 2px solid #e8e8e8;
}

.preview-table tbody tr td:not([rowspan]) {
    border-left: 1px solid #f0f0f0;
}

/* 表格单元格内容样式 */
.table-goal-info {
    padding: 0;
}

.table-goal-title {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    font-weight: 600;
    color: #262626;
    margin-bottom: 6px;
    font-size: 13px;
}

.table-goal-title i {
    color: #1890ff;
    font-size: 11px;
    margin-top: 1px;
}

.table-goal-desc {
    color: #666;
    font-size: 11px;
    margin-bottom: 8px;
    line-height: 1.3;
}

.table-goal-stats {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 10px;
    color: #999;
}

.table-goal-stats span {
    display: flex;
    align-items: flex-start;
    gap: 4px;
}

.table-goal-stats i {
    font-size: 9px;
    color: #1890ff;
    margin-top: 1px;
}

.table-task-list {
    padding: 0;
}

.table-task-item {
    margin-bottom: 0;
    padding: 8px 0;
    line-height: 1.2;
}

.table-task-item:last-child {
    margin-bottom: 0;
}

/* 三行展示样式 */
.table-task-category-line {
    background: #e6f7ff;
    color: #1890ff;
    padding: 1px 4px;
    border-radius: 2px;
    font-size: 9px;
    font-weight: 500;
    display: inline-block;
    margin-bottom: 3px;
}

.table-task-title-line {
    font-weight: 500;
    color: #262626;
    font-size: 11px;
    margin-bottom: 3px;
    word-break: break-all;
    line-height: 1.3;
}

.table-task-meta-line {
    font-size: 9px;
    color: #999;
    line-height: 1.2;
}

.table-task-tag {
    color: #1890ff;
    font-size: 9px;
}

.table-task-shared {
    color: #999;
    font-size: 9px;
}

.table-task-details {
    padding: 0;
}

.table-task-desc {
    font-size: 11px;
    color: #666;
    line-height: 1.4;
    margin-bottom: 8px;
}

.table-task-desc:last-child {
    margin-bottom: 0;
}

/* 目标项样式 */
.preview-goal {
    margin-bottom: 20px;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    overflow: hidden;
}

.preview-goal-header {
    background: #fafafa;
    padding: 12px 16px;
    border-bottom: 1px solid #e8e8e8;
}

.preview-goal-title {
    font-size: 14px;
    font-weight: 600;
    color: #262626;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.preview-goal-title i {
    color: #1890ff;
    font-size: 12px;
}

.preview-goal-desc {
    font-size: 12px;
    color: #666;
    margin-bottom: 8px;
    line-height: 1.4;
}

.preview-goal-stats {
    display: flex;
    gap: 24px;
    font-size: 12px;
    color: #999;
}

.preview-goal-stats span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.preview-goal-stats i {
    font-size: 10px;
    color: #1890ff;
}

/* 任务列表样式 */
.preview-tasks {
    padding: 12px 16px;
}

.preview-task {
    margin-bottom: 10px;
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
}

.preview-task:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.preview-task-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
    font-size: 12px;
}

.preview-task-category {
    background: #e6f7ff;
    color: #1890ff;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 500;
}

.preview-task-title {
    font-weight: 500;
    color: #262626;
    flex: 1;
}

.preview-task-status {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
}

.preview-task-status-badge {
    padding: 2px 6px;
    border-radius: 3px;
    font-weight: 500;
}

.preview-task-status-badge.completed {
    background: #f6ffed;
    color: #52c41a;
}

.preview-task-status-badge.in-progress {
    background: #e6f7ff;
    color: #1890ff;
}

.preview-task-status-badge.pending {
    background: #f6f6f6;
    color: #999;
}

.preview-task-tag {
    color: #1890ff;
    font-size: 10px;
}

.preview-task-shared {
    color: #999;
    font-size: 10px;
}

.preview-task-desc {
    font-size: 11px;
    color: #666;
    line-height: 1.3;
    margin-left: 12px;
    margin-top: 2px;
}

/* 空状态 */
.preview-empty {
    text-align: center;
    padding: 40px;
    color: #999;
}

.preview-empty i {
    font-size: 32px;
    margin-bottom: 12px;
    color: #d9d9d9;
}

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

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: white;
    border-radius: 8px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow: hidden;
    animation: slideIn 0.3s ease;
}

.modal-header {
    padding: 16px 20px;
    border-bottom: 1px solid #e8e8e8;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.modal-close {
    background: none;
    border: none;
    font-size: 20px;
    color: #999;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.modal-body {
    padding: 20px;
    max-height: 60vh;
    overflow-y: auto;
}

.modal-footer {
    padding: 16px 20px;
    border-top: 1px solid #e8e8e8;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

/* ====== 登录弹窗特定样式 ====== */
#loginModal {
    display: none;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
    background-color: rgba(0, 0, 0, 0.7);
}

#loginModal.show {
    display: flex !important;
}

.login-modal-content {
    max-width: 400px;
    min-height: 320px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
}

.login-modal-content .modal-header {
    text-align: center;
    padding: 32px 20px 8px;
    border-bottom: none;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.login-logo {
    margin-bottom: 8px;
}

.logo-image {
    height: 48px;
    width: auto;
    object-fit: contain;
}

.login-slogan {
    font-size: 14px;
    color: #666;
    margin: 0 0 15px 0;
    font-weight: 400;
    font-style: italic;
}

.login-subtitle {
    color: #666;
    font-size: 14px;
    margin: 0;
    line-height: 1.4;
}

.login-modal-content .modal-body {
    padding: 0 24px 28px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.login-modal-content .modal-footer {
    padding: 16px 24px 24px;
    border-top: none;
    justify-content: center;
}

.login-modal-content .form-group input {
    height: 40px;
    border: 1px solid #d9d9d9;
    border-radius: 6px;
    padding: 0 12px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.login-modal-content .form-group input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px color-mix(in srgb, var(--primary-color) 20%, transparent);
}

.login-modal-content .btn {
    margin-top: 8px;
}

.error-message {
    background-color: #fff2f0;
    border: 1px solid #ffccc7;
    color: #cf1322;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 14px;
    margin-top: 8px;
}

.success-message {
    background-color: #f6ffed;
    border: 1px solid #b7eb8f;
    color: #389e0d;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 14px;
    margin-top: 8px;
}

/* ====== 邮箱验证码登录界面样式 ====== */
.login-step-content {
    animation: fadeInSlide 0.3s ease;
}

.code-input-hint {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
    font-size: 12px;
}

.timer-text {
    color: #666;
}

.resend-btn {
    background: none;
    border: none;
    color: var(--primary-color);
    cursor: pointer;
    font-size: 12px;
    text-decoration: underline;
}

.resend-btn:hover {
    color: var(--primary-hover);
}

.email-display {
    background-color: var(--primary-light);
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 13px;
    color: #333;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.email-display span {
    font-weight: 500;
    color: var(--primary-color);
}

.change-email-btn {
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    font-size: 12px;
    text-decoration: underline;
}

.change-email-btn:hover {
    color: var(--primary-color);
}

/* 验证码输入框特殊样式 */
#verificationCode {
    text-align: center;
    font-size: 18px;
    font-weight: 600;
    letter-spacing: 4px;
    font-family: 'Courier New', monospace;
}

/* 加载状态按钮 */
.btn.loading {
    position: relative;
    color: transparent !important;
}

.btn.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 16px;
    height: 16px;
    border: 2px solid #ffffff;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

/* 动画效果 */
@keyframes fadeInSlide {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ====== 用户信息样式 ====== */
.user-info {
    color: #666;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-info .username {
    font-weight: 600;
    color: var(--primary-color);
}

.user-info .logout-btn {
    color: #999;
    text-decoration: none;
    font-size: 12px;
    padding: 4px 8px;
    border: 1px solid #d9d9d9;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.user-info .logout-btn:hover {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

/* ====== 表单样式 ====== */
.login-modal-content .form-group {
    margin-bottom: 20px;
}

/* 用户名提示样式 */
.username-hint {
    font-size: 11px;
    color: #666;
    margin-top: 4px;
    line-height: 1.3;
}

.form-group {
    margin-bottom: 16px;
}

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

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #d9d9d9;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px color-mix(in srgb, var(--primary-color) 20%, transparent);
}

.form-group textarea {
    resize: vertical;
    min-height: 60px;
}

/* ====== 复选框样式 ====== */
.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 14px;
    margin-bottom: 0 !important;
}

.checkbox-label input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 16px;
    height: 16px;
    border: 2px solid #d9d9d9;
    border-radius: 3px;
    margin-right: 8px;
    position: relative;
    transition: all 0.3s ease;
}

.checkbox-label input[type="checkbox"]:checked + .checkmark {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.checkbox-label input[type="checkbox"]:checked + .checkmark::after {
    content: "✓";
    position: absolute;
    top: -2px;
    left: 2px;
    color: white;
    font-size: 12px;
    font-weight: bold;
}

/* 可选文本样式 */
.optional-text {
    font-weight: normal;
    color: #999;
    font-size: 12px;
}

/* 多选框组样式 - 方案一：简约卡片式 */
.checkbox-group {
    border: 1px solid #e8e8e8;
    border-radius: 8px;
    padding: 12px;
    max-height: 140px;
    overflow-y: auto;
    background-color: #fff;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05);
}

.checkbox-group .checkbox-label {
    margin: 0;
    padding: 8px 10px;
    font-size: 13px;
    font-weight: normal;
    border-radius: 6px;
    transition: all 0.2s ease;
    background-color: transparent;
}

.checkbox-group .checkbox-label:hover {
    background-color: #f0f7ff;
    transform: translateX(2px);
}

.checkbox-group .checkbox-label input[type="checkbox"]:checked + .checkmark {
    background-color: #52c41a;
    border-color: #52c41a;
    box-shadow: 0 2px 4px rgba(82, 196, 26, 0.3);
}

/* 选中状态的目标项背景 */
.checkbox-group .checkbox-label:has(input[type="checkbox"]:checked) {
    background-color: #f6ffed;
    border-left: 3px solid #52c41a;
    padding-left: 7px;
}

.checkbox-group .checkbox-label .checkmark {
    width: 14px;
    height: 14px;
    margin-right: 10px;
}

/* ====== 空状态 ====== */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #999;
}

.empty-state i {
    font-size: 48px;
    color: #ccc;
    margin-bottom: 16px;
}

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

/* ====== 动画效果 ====== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

/* 删除确认弹窗专用动画 */
@keyframes deleteModalSlideIn {
    from { 
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

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

/* 删除确认弹窗样式 */
.delete-confirm-modal {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.45);
    z-index: 1050;
    animation: deleteModalFadeIn 0.3s ease;
}

.delete-confirm-modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 400px;
    width: 90%;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
    border: none;
    animation: deleteModalSlideIn 0.3s ease;
}

.delete-confirm-modal-with-tasks {
    max-width: 480px;
}

/* ====== 响应式设计 ====== */
@media (max-width: 1400px) {
    .main-content {
        grid-template-columns: 1.3fr 0.9fr 0.9fr 0.9fr 0.9fr 0.9fr;
        gap: 12px;
        padding: 16px;
        padding-bottom: 80px;
        height: 0;
    }
}

@media (max-width: 1200px) {
    .main-content {
        grid-template-columns: 1.4fr 0.8fr 0.8fr 0.8fr 0.8fr 0.8fr;
        gap: 10px;
        padding: 12px;
        padding-bottom: 80px;
        height: 0;
    }
}

@media (max-width: 992px) {
    .header-left {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    
    .logo-container {
        height: 36px; /* 在小屏幕上稍微缩小 */
    }
    
    .company-logo {
        max-height: 36px;
        max-width: 180px;
    }
    
    .fallback-title {
        font-size: 18px;
    }
    
    .project-title {
        font-size: 18px;
    }
    
    .main-content {
        grid-template-columns: 1fr;
        grid-template-rows: auto repeat(5, 1fr);
        gap: 12px;
        padding: 16px;
        padding-bottom: 80px;
        height: 0;
    }
    
    .task-column {
        min-height: 300px;
    }
}

@media (max-width: 768px) {
    .top-header {
        padding: 12px 16px;
    }
    
    .header-right {
        gap: 8px;
    }
    
    .logo-container {
        height: 32px; /* 移动设备进一步缩小 */
    }
    
    .company-logo {
        max-height: 32px;
        max-width: 160px;
    }
    
    .fallback-title {
        font-size: 16px;
    }
    
    .btn {
        padding: 4px 8px;
        font-size: 12px;
    }
    
    .main-content {
        padding: 12px;
        padding-bottom: 80px;
        gap: 8px;
        height: 0;
    }
}

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

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* ====== 拖拽排序样式 ====== */
.dragging {
    opacity: 0.5;
    transform: rotate(2deg);
}

.drag-over {
    border-color: var(--primary-color) !important;
    background-color: #e6f7ff !important;
}

/* ====== 加载状态 ====== */
.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    color: #999;
}

.loading::after {
    content: '';
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 10px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ===== 拖拽排序样式 ===== */
.goal-item[draggable="true"], 
.task-item[draggable="true"] {
    cursor: grab;
    transition: all 0.2s ease;
}

.goal-item[draggable="true"]:hover, 
.task-item[draggable="true"]:hover {
    background-color: color-mix(in srgb, var(--primary-color) 5%, transparent);
    border-radius: 6px;
}

.goal-item[draggable="true"]:active, 
.task-item[draggable="true"]:active {
    cursor: grabbing;
}

.dragging {
    opacity: 0.5;
    transform: rotate(2deg);
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
    z-index: 1000;
}

.drag-over {
    border-top: 2px solid var(--primary-color);
    transform: translateY(2px);
}

/* 拖拽时的容器样式 - 更简洁的设计 */
.tasks-list.drag-active {
    background-color: color-mix(in srgb, var(--primary-color) 3%, transparent);
    border: 1px dashed color-mix(in srgb, var(--primary-color) 30%, transparent);
    border-radius: 8px;
    transition: all 0.2s ease;
    position: relative;
}

/* 拖拽悬停时的强调效果 - 只在真正悬停时显示 */
.tasks-list.drag-active.drag-hover {
    background-color: color-mix(in srgb, var(--primary-color) 8%, transparent);
    border: 2px dashed var(--primary-color);
    box-shadow: 0 2px 8px color-mix(in srgb, var(--primary-color) 15%, transparent);
}

/* 空分类列表的拖拽提示 - 只在悬停时显示 */
.tasks-list.drag-active.drag-hover:empty::after {
    content: '释放以移动任务到此分类';
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 60px;
    color: var(--primary-color);
    font-size: 13px;
    font-weight: 500;
    text-align: center;
    padding: 10px;
}

/* 跨分类拖拽时任务的视觉反馈 */
.task-item.dragging.cross-category {
    box-shadow: 0 8px 20px rgba(24, 144, 255, 0.25);
    border: 1px solid var(--primary-color);
    background-color: color-mix(in srgb, var(--primary-color) 5%, white);
}

/* 拖拽时的基本样式保持不变 */
.task-item.dragging {
    opacity: 0.8;
    transform: rotate(1deg);
    z-index: 1000;
}

/* ====== 拖拽预览线样式 ====== */
.drop-preview-line {
    height: 2px;
    background-color: var(--primary-color);
    margin: 4px 0;
    border-radius: 1px;
    opacity: 0.8;
    transition: all 0.2s ease;
    position: relative;
}

.drop-preview-line::before {
    content: '';
    position: absolute;
    left: -4px;
    top: -2px;
    width: 6px;
    height: 6px;
    background-color: var(--primary-color);
    border-radius: 50%;
}

.drop-preview-line::after {
    content: '';
    position: absolute;
    right: -4px;
    top: -2px;
    width: 6px;
    height: 6px;
    background-color: var(--primary-color);
    border-radius: 50%;
}

/* 跨分类拖拽预览线样式 */
.drop-preview-line.cross-category-preview {
    background-color: #ff6b35;
    animation: pulse 1s infinite;
}

.drop-preview-line.cross-category-preview::before,
.drop-preview-line.cross-category-preview::after {
    background-color: #ff6b35;
}

@keyframes pulse {
    0% { opacity: 0.8; }
    50% { opacity: 1; }
    100% { opacity: 0.8; }
}

/* ====== 更多工具功能样式 ====== */

/* 更多工具按钮样式 - 与其他状态栏按钮保持一致 */
.more-tools-text {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #666;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
    user-select: none;
}

.more-tools-text:hover {
    color: #1890ff;
}

.more-tools-text i {
    font-size: 10px;
    transition: transform 0.2s ease;
}

.more-tools-text:hover i {
    transform: scale(1.1);
}

/* 工具Tab导航样式 */
.tools-tabs {
    display: flex;
    border-bottom: 1px solid #e8e8e8;
    margin-bottom: 0;
    background: #fafafa;
}

.tools-tab {
    padding: 12px 20px;
    cursor: pointer;
    color: #666;
    font-size: 13px;
    font-weight: 500;
    position: relative;
    transition: all 0.3s ease;
    border-bottom: 2px solid transparent;
    background: transparent;
}

.tools-tab:hover {
    color: var(--primary-color);
    background: #f0f8ff;
}

.tools-tab.active {
    color: var(--primary-color);
    background: #fff;
    border-bottom-color: var(--primary-color);
}

/* Tab内容区域样式 */
.tools-tab-content {
    min-height: 300px;
}

.tools-tab-pane {
    display: none;
}

.tools-tab-pane.active {
    display: block;
}

/* 更多工具弹窗内容样式 */
.more-tools-content {
    padding: 0 16px;
}

/* 空工具提示样式 */
.empty-tools-hint {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    text-align: center;
    color: #999;
}

.empty-tools-hint i {
    font-size: 48px;
    color: #ddd;
    margin-bottom: 16px;
}

.empty-tools-hint p {
    font-size: 16px;
    color: #666;
    margin: 0 0 8px 0;
    font-weight: 500;
}

.empty-tools-hint span {
    font-size: 13px;
    color: #999;
}

/* 工具卡片样式 */
.tool-card {
    display: flex;
    align-items: center;
    padding: 16px;
    margin: 12px 0;
    border: 1px solid #e6f0f9;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fff;
}

.tool-card:hover {
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(24, 144, 255, 0.15);
    transform: translateY(-1px);
}

.tool-card:first-child {
    margin-top: 12px;
}

.tool-card:last-child {
    margin-bottom: 12px;
}

/* 工具Logo样式 */
.tool-logo {
    width: 56px;
    height: 56px;
    margin-right: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    border: 1px solid #e6f0f9;
    border-radius: 6px;
    color: var(--primary-color);
    font-size: 24px;
    flex-shrink: 0;
}

.tool-card:hover .tool-logo {
    background: var(--primary-light);
    border-color: var(--primary-border);
}

/* 工具信息样式 */
.tool-info {
    flex: 1;
    min-width: 0;
}

.tool-info h4 {
    margin: 0 0 6px 0;
    color: var(--primary-color);
    font-size: 16px;
    font-weight: 600;
    line-height: 1.3;
}

.tool-info p {
    margin: 0;
    color: #666;
    font-size: 13px;
    line-height: 1.4;
    word-wrap: break-word;
}

.tool-card:hover .tool-info h4 {
    color: var(--primary-hover);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .tools-tabs {
        background: #fafafa;
    }
    
    .tools-tab {
        padding: 10px 16px;
        font-size: 12px;
        flex: 1;
        text-align: center;
    }
    
    .tools-tab-content {
        min-height: 250px;
    }
    
    .more-tools-content {
        padding: 0 12px;
    }
    
    .tool-card {
        padding: 12px;
        margin: 10px 0;
    }
    
    .tool-card:first-child {
        margin-top: 10px;
    }

    .tool-card:last-child {
        margin-bottom: 10px;
    }
    
    .tool-logo {
        width: 48px;
        height: 48px;
        margin-right: 12px;
        font-size: 20px;
    }
    
    .tool-info h4 {
        font-size: 15px;
    }
    
    .tool-info p {
        font-size: 12px;
    }
    
    .empty-tools-hint {
        padding: 40px 20px;
    }
    
    .empty-tools-hint i {
        font-size: 36px;
    }
    
    .empty-tools-hint p {
        font-size: 14px;
    }
}
