/* 通阜环保移动办公平台 - 模块样式 */

/* 详情信息 */
.detail-info {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-row label {
    font-size: 14px;
    color: var(--text-secondary);
    min-width: 80px;
}

.detail-row span {
    font-size: 14px;
    color: var(--text-color);
    text-align: right;
    flex: 1;
}

.amount {
    font-weight: 600;
    color: var(--warning-color);
}

/* 任务操作 */
.task-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
}

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

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

.btn-success:hover {
    background: #389e0d;
}

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

.btn-danger:hover {
    background: #cf1322;
}

/* 审批操作 */
.approval-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
}

/* 状态样式 */
.status-active {
    color: var(--success-color);
    font-weight: 500;
}

.status-potential {
    color: var(--info-color);
    font-weight: 500;
}

.priority-高 {
    color: var(--danger-color);
    font-weight: 500;
}

.priority-中 {
    color: var(--warning-color);
    font-weight: 500;
}

.priority-低 {
    color: var(--success-color);
    font-weight: 500;
}

/* 通知列表 */
.notification-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.notification-item {
    padding: 12px;
    background: var(--bg-color);
    border-radius: var(--radius);
    border-left: 3px solid var(--primary-color);
}

.notification-item.unread {
    background: #e6f7ff;
    border-left-color: var(--warning-color);
}

.notification-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
}

.notification-content {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.notification-time {
    font-size: 12px;
    color: var(--text-light);
}

/* 报表样式 */
.report-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.report-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 12px;
    background: var(--bg-color);
    border-radius: var(--radius);
}

.report-stat .label {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.report-stat .value {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-color);
}

.report-stat .value.success {
    color: var(--success-color);
}

.report-stat .value.warning {
    color: var(--warning-color);
}

.report-stat .value.danger {
    color: var(--danger-color);
}

/* 图表样式 */
.report-chart {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.chart-bar {
    display: flex;
    align-items: center;
    gap: 12px;
}

.bar-label {
    min-width: 60px;
    font-size: 13px;
    color: var(--text-secondary);
}

.bar-track {
    flex: 1;
    height: 20px;
    background: var(--bg-color);
    border-radius: 10px;
    overflow: hidden;
}

.bar-fill {
    height: 100%;
    background: var(--primary-color);
    border-radius: 10px;
    transition: width 0.3s;
}

.bar-fill.success {
    background: var(--success-color);
}

.bar-fill.danger {
    background: var(--danger-color);
}

.bar-value {
    min-width: 30px;
    font-size: 13px;
    font-weight: 600;
    text-align: right;
}

/* 报表详情 */
.report-detail {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

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

.summary-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 12px;
    background: var(--bg-color);
    border-radius: var(--radius);
}

.summary-item .label {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.summary-item .value {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-color);
}

.summary-item .value.success {
    color: var(--success-color);
}

.summary-item .value.warning {
    color: var(--warning-color);
}

.summary-item .value.danger {
    color: var(--danger-color);
}

.report-detail h4 {
    font-size: 15px;
    font-weight: 600;
    margin-top: 8px;
}

/* 报表表格 */
.report-table {
    overflow-x: auto;
}

.report-table table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.report-table th,
.report-table td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.report-table th {
    background: var(--bg-color);
    font-weight: 600;
    color: var(--text-secondary);
}

.report-table tr:hover {
    background: var(--bg-color);
}

/* 漏斗图 */
.funnel-chart {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.funnel-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: var(--primary-color);
    color: white;
    border-radius: var(--radius);
    transition: all 0.3s;
}

.funnel-item:nth-child(2) {
    background: #40a9ff;
}

.funnel-item:nth-child(3) {
    background: #69c0ff;
}

.funnel-item:nth-child(4) {
    background: #91d5ff;
}

.funnel-label {
    font-size: 14px;
    font-weight: 500;
}

.funnel-value {
    font-size: 13px;
}

/* 分类统计 */
.category-stats {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.category-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: var(--bg-color);
    border-radius: var(--radius);
}

.category-name {
    font-size: 14px;
    color: var(--text-color);
}

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

.category-value {
    font-size: 14px;
    font-weight: 600;
    color: var(--warning-color);
}

/* 徽章样式增强 */
.badge-completed {
    background: #f6ffed;
    color: #52c41a;
}

.badge-rejected {
    background: #fff1f0;
    color: #ff4d4f;
}

.badge-processing {
    background: #e6f7ff;
    color: #1890ff;
}

/* 搜索高亮 */
.highlight {
    background: #fff7e6;
    padding: 2px 4px;
    border-radius: 2px;
}

/* 空状态 */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    color: var(--text-light);
}

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

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

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

.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);
    }
}

/* 确认对话框 */
.confirm-dialog {
    text-align: center;
}

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

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

/* 滑动操作 */
.swipe-actions {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    display: flex;
    transform: translateX(100%);
    transition: transform 0.3s;
}

.swipe-action {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    color: white;
    font-size: 18px;
}

.swipe-action.edit {
    background: var(--primary-color);
}

.swipe-action.delete {
    background: var(--danger-color);
}

/* 标签页 */
.tabs {
    display: flex;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 16px;
}

.tab {
    flex: 1;
    padding: 12px;
    text-align: center;
    font-size: 14px;
    color: var(--text-secondary);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.3s;
}

.tab.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

/* 卡片列表 */
.card-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.card {
    background: white;
    border-radius: var(--radius);
    padding: 16px;
    box-shadow: var(--shadow);
}

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

.card-title {
    font-size: 15px;
    font-weight: 600;
}

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

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

/* 进度条 */
.progress-bar {
    height: 8px;
    background: var(--bg-color);
    border-radius: 4px;
    overflow: hidden;
    margin-top: 8px;
}

.progress-fill {
    height: 100%;
    background: var(--primary-color);
    border-radius: 4px;
    transition: width 0.3s;
}

.progress-fill.success {
    background: var(--success-color);
}

.progress-fill.warning {
    background: var(--warning-color);
}

.progress-fill.danger {
    background: var(--danger-color);
}

/* 头像 */
.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.avatar-sm {
    width: 32px;
    height: 32px;
    font-size: 14px;
}

/* 工具提示 */
.tooltip {
    position: relative;
}

.tooltip::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 4px 8px;
    background: rgba(0,0,0,0.8);
    color: white;
    font-size: 12px;
    border-radius: 4px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.tooltip:hover::after {
    opacity: 1;
    visibility: visible;
}

/* 分割线 */
.divider {
    height: 1px;
    background: var(--border-color);
    margin: 16px 0;
}

/* 徽章计数 */
.count-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    background: var(--danger-color);
    color: white;
    font-size: 12px;
    border-radius: 10px;
}

/* 骨架屏 */
.skeleton {
    background: linear-gradient(90deg, var(--bg-color) 25%, #e8e8e8 50%, var(--bg-color) 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: var(--radius);
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

.skeleton-text {
    height: 16px;
    margin-bottom: 8px;
}

.skeleton-title {
    height: 24px;
    width: 60%;
    margin-bottom: 12px;
}

.skeleton-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}
