/* ===== 基础 ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background: #f0f4f8;
    color: #334155;
    font-size: 13px;
    line-height: 1.5;
    min-height: 100vh;
}

/* ===== 顶部 Header ===== */
.dashboard-header {
    background: #ffffff;
    background: linear-gradient(135deg, #ffffff 0%, #e8f0fb 100%);
    padding: 14px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 2px 10px rgba(30, 64, 120, 0.08);
    position: relative;
    z-index: 100;
}
.dashboard-header::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, #3b82f6, #60a5fa, #3b82f6, transparent);
}
.dashboard-title {
    font-size: 21px;
    font-weight: 700;
    color: #1e40af;
    letter-spacing: 3px;
}
.dashboard-header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}
.header-date {
    color: #64748b;
    font-size: 13px;
}
.header-actions {
    display: flex;
    gap: 6px;
    background: #eef2f8;
    border-radius: 8px;
    padding: 3px;
}
.header-btn {
    padding: 6px 16px;
    border-radius: 6px;
    border: none;
    background: transparent;
    color: #64748b;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}
.header-btn:hover { color: #2563eb; }
.header-btn.active {
    background: #ffffff;
    color: #2563eb;
    font-weight: 600;
    box-shadow: 0 1px 4px rgba(30, 64, 120, 0.12);
}
.header-record-btn {
    padding: 7px 16px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
    white-space: nowrap;
}
.header-record-btn:hover { transform: translateY(-1px); }

/* ===== 主容器 ===== */
.dashboard-container {
    padding: 20px 32px 32px;
    max-width: 1600px;
    margin: 0 auto;
}

/* ===== KPI 卡片行 ===== */
.kpi-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 20px;
}
.kpi-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 20px 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(30, 64, 120, 0.05);
    transition: transform 0.2s, box-shadow 0.2s;
}
.kpi-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(30, 64, 120, 0.1);
}
.kpi-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, #3b82f6, #60a5fa);
}
.kpi-progress-ring {
    position: relative;
    width: 56px; height: 56px;
    flex-shrink: 0;
}
.kpi-progress-ring svg { transform: rotate(-90deg); }
.kpi-ring-bg {
    fill: none;
    stroke: #e2e8f0;
    stroke-width: 5;
}
.kpi-ring-fill {
    fill: none;
    stroke: url(#ringGradient);
    stroke-width: 5;
    stroke-linecap: round;
    transition: stroke-dashoffset 1s ease;
}
.kpi-ring-text {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    font-size: 11px;
    font-weight: 700;
    color: #2563eb;
}
.kpi-info { flex: 1; }
.kpi-label {
    font-size: 12px;
    color: #64748b;
    margin-bottom: 6px;
}
.kpi-value {
    font-size: 24px;
    font-weight: 700;
    color: #0f172a;
    letter-spacing: 0.5px;
}
.kpi-delta {
    font-size: 11px;
    margin-top: 4px;
    display: flex;
    align-items: center;
    gap: 4px;
}
.kpi-delta.up { color: #16a34a; }
.kpi-delta.down { color: #dc2626; }

/* ===== 内容网格 ===== */
.content-grid {
    display: grid;
    grid-template-columns: 280px 1fr 280px;
    gap: 16px;
    margin-bottom: 16px;
}
.content-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}
.content-grid-3 {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

/* ===== 面板卡片 ===== */
.panel-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 16px;
    position: relative;
    box-shadow: 0 1px 3px rgba(30, 64, 120, 0.05);
}
.panel-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 40px; height: 3px;
    background: linear-gradient(90deg, #3b82f6, #60a5fa);
    border-radius: 2px 0 0 0;
}
.panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}
.panel-title {
    font-size: 14px;
    font-weight: 600;
    color: #1e3a8a;
    display: flex;
    align-items: center;
    gap: 8px;
}
.panel-title::before {
    content: '';
    width: 3px; height: 14px;
    background: linear-gradient(180deg, #3b82f6, #2563eb);
    border-radius: 2px;
}
.panel-badge {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 10px;
    background: #eff6ff;
    color: #3b82f6;
}
.panel-body {
    min-height: 180px;
}

/* ===== 图表容器 ===== */
.chart-container {
    position: relative;
    height: 220px;
    width: 100%;
}
.chart-container-lg {
    position: relative;
    height: 280px;
    width: 100%;
}

/* ===== 横向条形图 ===== */
.bar-h-list { display: flex; flex-direction: column; gap: 10px; }
.bar-h-item { display: flex; align-items: center; gap: 8px; }
.bar-h-label {
    width: 70px;
    font-size: 12px;
    color: #475569;
    text-align: right;
    flex-shrink: 0;
}
.bar-h-track {
    flex: 1;
    height: 18px;
    background: #eef2f8;
    border-radius: 3px;
    overflow: hidden;
    position: relative;
}
.bar-h-fill {
    height: 100%;
    border-radius: 3px;
    background: linear-gradient(90deg, #2563eb, #60a5fa);
    transition: width 0.8s ease;
    position: relative;
}
.bar-h-value {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 11px;
    color: #fff;
    font-weight: 600;
}

/* ===== 漏斗图 ===== */
.funnel-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 10px 0;
}
.funnel-segment {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 32px;
    border-radius: 4px;
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    position: relative;
    transition: all 0.3s;
}
.funnel-segment:hover { filter: brightness(1.1); }
.funnel-label {
    position: absolute;
    right: -80px;
    font-size: 11px;
    color: #475569;
    width: 70px;
    text-align: left;
}

/* ===== 数据表格 ===== */
.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}
.data-table th {
    background: #f1f5f9;
    color: #475569;
    font-weight: 600;
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}
.data-table td {
    padding: 9px 12px;
    border-bottom: 1px solid #f1f5f9;
    color: #334155;
}
.data-table tr:hover td {
    background: #f8fafc;
}
.data-table .tag {
    display: inline-block;
    padding: 1px 8px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 500;
}
.tag-primary { background: #dbeafe; color: #1d4ed8; }
.tag-success { background: #dcfce7; color: #15803d; }
.tag-warning { background: #fef9c3; color: #a16207; }
.tag-danger { background: #fee2e2; color: #b91c1c; }

/* ===== 通知列表 ===== */
.notice-list { display: flex; flex-direction: column; gap: 8px; }
.notice-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 12px;
    background: #f8fafc;
    border-radius: 6px;
    border-left: 3px solid #3b82f6;
    transition: background 0.2s;
}
.notice-item:hover { background: #f1f5f9; }
.notice-item.warning { border-left-color: #f59e0b; }
.notice-item.danger { border-left-color: #ef4444; }
.notice-icon {
    width: 28px; height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    flex-shrink: 0;
}
.notice-icon.info { background: #dbeafe; }
.notice-icon.warning { background: #fef3c7; }
.notice-icon.danger { background: #fee2e2; }
.notice-content { flex: 1; }
.notice-title {
    font-size: 12px;
    font-weight: 500;
    color: #334155;
    margin-bottom: 2px;
}
.notice-desc {
    font-size: 11px;
    color: #64748b;
}
.notice-time {
    font-size: 11px;
    color: #94a3b8;
    white-space: nowrap;
}

/* ===== 快捷工具入口 ===== */
.tool-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 12px;
}
.tool-item {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 16px 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    display: block;
}
.tool-item:hover {
    background: #eff6ff;
    border-color: #bfdbfe;
    transform: translateY(-2px);
}
.tool-item-icon { font-size: 28px; margin-bottom: 8px; }
.tool-item-name {
    font-size: 12px;
    color: #1e3a8a;
    font-weight: 500;
}
.tool-item-desc {
    font-size: 11px;
    color: #64748b;
    margin-top: 2px;
}

/* ===== 模态框 ===== */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    width: 100%; height: 100%;
    background: rgba(15, 23, 42, 0.4);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}
.modal-overlay.active { display: flex; }
.modal-box {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    width: 520px;
    max-width: 90vw;
    max-height: 85vh;
    overflow: auto;
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.2);
    margin: auto;
}
.modal-header {
    padding: 16px 20px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.modal-title {
    font-size: 16px;
    font-weight: 600;
    color: #0f172a;
}
.modal-close {
    background: none;
    border: none;
    color: #94a3b8;
    font-size: 20px;
    cursor: pointer;
}
.modal-close:hover { color: #334155; }
.modal-body { padding: 20px; }
.modal-footer {
    padding: 12px 20px;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* ===== 表单 ===== */
.form-group { margin-bottom: 14px; }
.form-label {
    display: block;
    font-size: 12px;
    color: #475569;
    margin-bottom: 5px;
}
.form-input, .form-select, .form-textarea {
    width: 100%;
    padding: 8px 12px;
    border-radius: 6px;
    border: 1px solid #cbd5e1;
    background: #ffffff;
    color: #334155;
    font-size: 13px;
    outline: none;
    transition: border-color 0.2s;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.btn {
    padding: 8px 18px;
    border-radius: 6px;
    border: none;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}
.btn-primary {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: #fff;
}
.btn-primary:hover { background: linear-gradient(135deg, #3b82f6, #2563eb); }
.btn-secondary {
    background: #f1f5f9;
    color: #475569;
    border: 1px solid #e2e8f0;
}
.btn-secondary:hover { background: #e2e8f0; color: #1e293b; }

/* ===== 列表页工具栏 ===== */
.list-toolbar {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}
.search-input {
    flex: 1;
    min-width: 200px;
    padding: 8px 14px;
    border-radius: 6px;
    border: 1px solid #cbd5e1;
    background: #ffffff;
    color: #334155;
    font-size: 13px;
}
.search-input::placeholder { color: #94a3b8; }
.search-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* ===== 信息卡片列表 ===== */
.card-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 12px;
}
.info-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 14px 16px;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(30, 64, 120, 0.05);
    transition: all 0.2s;
}
.info-card:hover {
    border-color: #bfdbfe;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(30, 64, 120, 0.08);
}
.info-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}
.info-card-title {
    font-size: 14px;
    font-weight: 600;
    color: #0f172a;
}
.info-card-meta {
    font-size: 12px;
    color: #64748b;
    display: flex;
    gap: 12px;
}

/* ===== 状态标签 ===== */
.status-tag {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 500;
}
.status-pending { background: #fef9c3; color: #a16207; }
.status-delivering { background: #dbeafe; color: #1d4ed8; }
.status-completed { background: #dcfce7; color: #15803d; }
.status-cancelled { background: #f1f5f9; color: #64748b; }
.status-unpaid { background: #fee2e2; color: #b91c1c; }
.status-paid { background: #dcfce7; color: #15803d; }

/* ===== 加载/空状态 ===== */
.loading-state {
    text-align: center;
    padding: 40px;
    color: #94a3b8;
}
.empty-state {
    text-align: center;
    padding: 40px;
    color: #94a3b8;
}
.empty-state-icon { font-size: 40px; margin-bottom: 8px; opacity: 0.5; }

/* ===== 订单明细内联样式补丁 ===== */
.order-item-row {
    display: flex;
    gap: 8px;
    align-items: center;
    background: #f8fafc;
    padding: 6px 10px;
    border-radius: 4px;
}

/* ===== 每日记录 ===== */
.daily-hero {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    border-radius: 12px;
    padding: 18px 24px;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    color: #fff;
    box-shadow: 0 4px 16px rgba(37, 99, 235, 0.25);
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}
.daily-hero:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(37, 99, 235, 0.35);
}
.daily-hero-left { display: flex; align-items: center; gap: 14px; }
.daily-hero-icon {
    width: 44px; height: 44px;
    background: rgba(255,255,255,0.18);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}
.daily-hero-title { font-size: 16px; font-weight: 600; }
.daily-hero-desc { font-size: 12px; opacity: 0.85; margin-top: 3px; }
.daily-hero-btn {
    background: #ffffff;
    color: #1d4ed8;
    border: none;
    padding: 9px 20px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}
.daily-hero-btn:hover { transform: scale(1.03); }
.daily-hero-btn.done { background: #dcfce7; color: #15803d; }

.daily-today-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}
.daily-block {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 16px;
    box-shadow: 0 1px 3px rgba(30, 64, 120, 0.05);
}
.daily-block-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #1e3a8a;
    margin-bottom: 10px;
}
.daily-block-icon {
    width: 26px; height: 26px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
}
.daily-block-icon.blue { background: #dbeafe; }
.daily-block-icon.green { background: #dcfce7; }
.daily-block-icon.amber { background: #fef3c7; }
.daily-block-text {
    font-size: 13px;
    color: #334155;
    white-space: pre-wrap;
    line-height: 1.7;
    max-height: 200px;
    overflow: auto;
}
.daily-block-empty { color: #94a3b8; font-size: 12px; }

.daily-timeline {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.daily-item {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 14px;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 1px 3px rgba(30, 64, 120, 0.04);
}
.daily-item:hover { border-color: #bfdbfe; transform: translateY(-1px); }
.daily-item-date {
    width: 58px;
    text-align: center;
    flex-shrink: 0;
    padding: 6px 0;
    border-radius: 8px;
    background: #eff6ff;
}
.daily-item-day { font-size: 18px; font-weight: 700; color: #2563eb; line-height: 1.2; }
.daily-item-week { font-size: 11px; color: #64748b; margin-top: 2px; }
.daily-item-body { flex: 1; min-width: 0; }
.daily-item-title {
    font-size: 13px;
    font-weight: 600;
    color: #0f172a;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.daily-item-preview {
    font-size: 12px;
    color: #64748b;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-top: 3px;
}
.daily-item-tags { display: flex; gap: 6px; flex-shrink: 0; }
.daily-streak {
    background: #fef3c7;
    color: #b45309;
    border-radius: 10px;
    padding: 3px 10px;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

@media (max-width: 900px) {
    .daily-today-grid { grid-template-columns: 1fr; }
    .daily-hero { flex-direction: column; align-items: flex-start; }
}

/* ===== 快速记录工具栏 ===== */
.quick-entry-bar {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}
.quick-entry-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    color: #334155;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 1px 3px rgba(30, 64, 120, 0.04);
}
.quick-entry-btn:hover {
    border-color: #93c5fd;
    background: #eff6ff;
    transform: translateY(-1px);
}
.quick-entry-btn .qe-icon {
    width: 20px; height: 20px;
    display: flex; align-items: center; justify-content: center;
    font-size: 14px;
}
.quick-entry-btn.recording {
    background: #fee2e2;
    border-color: #ef4444;
    color: #dc2626;
    animation: pulse-rec 1.2s infinite;
}
@keyframes pulse-rec {
    0%, 100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.3); }
    50% { box-shadow: 0 0 0 6px rgba(239, 68, 68, 0); }
}

/* ===== 四象限网格 ===== */
.quadrant-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 16px;
}
.quadrant-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 14px;
    box-shadow: 0 1px 3px rgba(30, 64, 120, 0.05);
    min-height: 180px;
}
.quadrant-card.q1 { border-top: 3px solid #ef4444; }
.quadrant-card.q2 { border-top: 3px solid #3b82f6; }
.quadrant-card.q3 { border-top: 3px solid #f59e0b; }
.quadrant-card.q4 { border-top: 3px solid #22c55e; }
.quadrant-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}
.quadrant-label {
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
}
.quadrant-label .q-dot {
    width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0;
}
.q1 .quadrant-label .q-dot { background: #ef4444; }
.q2 .quadrant-label .q-dot { background: #3b82f6; }
.q3 .quadrant-label .q-dot { background: #f59e0b; }
.q4 .quadrant-label .q-dot { background: #22c55e; }
.quadrant-count {
    font-size: 11px;
    padding: 1px 7px;
    border-radius: 8px;
    background: #f1f5f9;
    color: #64748b;
}
.quadrant-tasks {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

/* ===== 条目卡片 ===== */
.entry-card {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 8px 10px;
    border-radius: 6px;
    background: #f8fafc;
    border: 1px solid #f1f5f9;
    transition: all 0.15s;
}
.entry-card:hover { border-color: #cbd5e1; background: #f1f5f9; }
.entry-card.done { opacity: 0.5; }
.entry-card.done .entry-text { text-decoration: line-through; }
.entry-check {
    width: 18px; height: 18px;
    border: 2px solid #cbd5e1;
    border-radius: 4px;
    cursor: pointer;
    flex-shrink: 0;
    margin-top: 1px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: transparent;
    transition: all 0.15s;
}
.entry-check:hover { border-color: #3b82f6; }
.entry-card.done .entry-check {
    background: #22c55e;
    border-color: #22c55e;
    color: #fff;
}
.entry-content { flex: 1; min-width: 0; }
.entry-text {
    font-size: 12px;
    color: #334155;
    line-height: 1.5;
    word-break: break-word;
}
.entry-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 4px;
    font-size: 11px;
    color: #94a3b8;
}
.entry-amount {
    font-weight: 600;
    font-size: 12px;
}
.entry-amount.income { color: #dc2626; }
.entry-amount.expense { color: #16a34a; }
.entry-contact {
    background: #eff6ff;
    color: #1d4ed8;
    padding: 1px 6px;
    border-radius: 4px;
    font-size: 10px;
}
.entry-img-thumb {
    width: 48px; height: 48px;
    border-radius: 4px;
    object-fit: cover;
    cursor: pointer;
    flex-shrink: 0;
}
.entry-audio-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    border-radius: 4px;
    background: #fef3c7;
    color: #b45309;
    font-size: 11px;
    cursor: pointer;
    border: none;
}
.entry-del {
    color: #cbd5e1;
    cursor: pointer;
    font-size: 14px;
    padding: 0 4px;
    flex-shrink: 0;
    background: none;
    border: none;
    line-height: 1;
}
.entry-del:hover { color: #ef4444; }

/* ===== 今日时间线 ===== */
.timeline-section {
    margin-bottom: 16px;
}
.timeline-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.timeline-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}
.timeline-time {
    font-size: 11px;
    color: #94a3b8;
    min-width: 42px;
    padding-top: 2px;
    text-align: right;
    flex-shrink: 0;
}
.timeline-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    margin-top: 6px;
    flex-shrink: 0;
}
.timeline-dot.task { background: #3b82f6; }
.timeline-dot.note { background: #8b5cf6; }
.timeline-dot.expense { background: #f59e0b; }
.timeline-dot.communication { background: #06b6d4; }
.timeline-dot.idea { background: #ec4899; }
.timeline-dot.followup { background: #ef4444; }
.timeline-body { flex: 1; min-width: 0; }
.timeline-content {
    font-size: 12px;
    color: #334155;
    line-height: 1.5;
    word-break: break-word;
}
.timeline-type-tag {
    display: inline-block;
    font-size: 10px;
    padding: 1px 6px;
    border-radius: 4px;
    margin-right: 6px;
    font-weight: 500;
}
.t-tag-task { background: #dbeafe; color: #1d4ed8; }
.t-tag-note { background: #ede9fe; color: #6d28d9; }
.t-tag-expense { background: #fef3c7; color: #b45309; }
.t-tag-communication { background: #cffafe; color: #0e7490; }
.t-tag-idea { background: #fce7f3; color: #be185d; }
.t-tag-followup { background: #fee2e2; color: #b91c1c; }

/* ===== 宽模态框 ===== */
.modal-box.wide {
    width: 680px;
    max-width: 95vw;
}

/* ===== 图片预览区 ===== */
.image-preview-area {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}
.image-preview {
    position: relative;
    width: 80px; height: 80px;
    border-radius: 6px;
    overflow: hidden;
    border: 1px solid #e2e8f0;
}
.image-preview img { width: 100%; height: 100%; object-fit: cover; }
.image-preview .img-remove {
    position: absolute;
    top: 2px; right: 2px;
    width: 18px; height: 18px;
    background: rgba(0,0,0,0.6);
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ===== 录音指示器 ===== */
.recording-indicator {
    display: none;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: #fee2e2;
    border-radius: 6px;
    margin-top: 8px;
}
.recording-indicator.active { display: flex; }
.rec-dot {
    width: 10px; height: 10px;
    background: #ef4444;
    border-radius: 50%;
    animation: blink 1s infinite;
}
@keyframes blink { 0%, 50% { opacity: 1; } 51%, 100% { opacity: 0.3; } }

/* ===== 每日总结卡片 ===== */
.daily-summary-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 16px;
    margin-bottom: 16px;
    box-shadow: 0 1px 3px rgba(30, 64, 120, 0.05);
}
.daily-summary-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}
.daily-summary-mood {
    display: flex;
    gap: 8px;
    align-items: center;
}
.mood-pill {
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 11px;
    background: #f1f5f9;
    color: #475569;
}

/* ===== 二维码区域 ===== */
.qr-section { margin-bottom: 16px; }
.qr-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(135deg, #eff6ff 0%, #f0f4f8 100%);
    border: 1px solid #dbeafe;
    border-radius: 10px;
    padding: 16px 20px;
    gap: 16px;
}
.qr-left { flex: 1; }
.qr-right {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.qr-right > div:first-child {
    background: #fff;
    padding: 6px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}
#qrCodeBox img, #qrCodeBox canvas {
    display: block;
}
@media (max-width: 600px) {
    .qr-card { flex-direction: column; text-align: center; }
    .qr-left { text-align: center; }
}

@media (max-width: 768px) {
    .quadrant-grid { grid-template-columns: 1fr; }
    .quick-entry-bar { gap: 6px; }
    .quick-entry-btn { padding: 6px 12px; font-size: 12px; }
}

/* ===== 响应式 ===== */
@media (max-width: 1200px) {
    .content-grid { grid-template-columns: 240px 1fr 240px; }
    .kpi-row { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 900px) {
    .content-grid { grid-template-columns: 1fr; }
    .content-grid-2 { grid-template-columns: 1fr; }
    .content-grid-3 { grid-template-columns: 1fr; }
    .kpi-row { grid-template-columns: 1fr; }
    .dashboard-container { padding: 12px 16px; }
    .dashboard-header { flex-direction: column; gap: 10px; padding: 12px 16px; }
    .dashboard-header-right { flex-direction: column; gap: 8px; }
}

/* ===== 完成凭证 ===== */
.proof-upload-area {
    border: 2px dashed #cbd5e1;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    background: #f8fafc;
    color: #64748b;
}
.proof-upload-area:hover {
    border-color: #3b82f6;
    background: #eff6ff;
}
.proof-thumb-wrap, .proof-doc-wrap {
    position: relative;
    width: 64px;
    height: 64px;
}
.proof-thumb {
    width: 64px;
    height: 64px;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
    cursor: pointer;
}
.proof-doc-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f1f5f9;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
    font-size: 24px;
}
.proof-remove {
    position: absolute;
    top: -6px;
    right: -6px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #ef4444;
    color: #fff;
    border: none;
    font-size: 12px;
    line-height: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}
.proof-remove:hover { background: #dc2626; }
.entry-proof-badge {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    background: #dbeafe;
    color: #1d4ed8;
    padding: 1px 6px;
    border-radius: 10px;
    font-size: 11px;
    cursor: pointer;
    margin-left: 4px;
}
.entry-proof-badge:hover { background: #bfdbfe; }
