/**
 * 功能模块样式
 * 客户管理、销售跟进、日程安排、售后维护、目标统计
 */

/* ========== 工作台 ========== */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
}

.stat-card {
    background: #fff;
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    box-shadow: var(--shadow-base);
    display: flex;
    flex-direction: column;
}

.stat-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--spacing-md);
}

.stat-card-title {
    color: var(--color-text-secondary);
    font-size: var(--font-size-base);
}

.stat-card-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-card-icon.primary {
    background-color: #e6f7ff;
    color: var(--color-primary);
}

.stat-card-icon.success {
    background-color: #f6ffed;
    color: var(--color-success);
}

.stat-card-icon.warning {
    background-color: #fff7e6;
    color: var(--color-warning);
}

.stat-card-icon.danger {
    background-color: #fff1f0;
    color: var(--color-danger);
}

.stat-card-value {
    font-size: var(--font-size-xxl);
    font-weight: 600;
    color: var(--color-text);
    line-height: 1.2;
}

.stat-card-footer {
    margin-top: var(--spacing-sm);
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
}

/* ========== 工作台布局 ========== */
.dashboard-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: var(--spacing-lg);
}

.dashboard-main {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.dashboard-sidebar {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

/* ========== 快捷操作 ========== */
.quick-actions {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--spacing-md);
}

.quick-action-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: var(--spacing-lg);
    background: #fff;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all 0.2s;
    border: 1px solid transparent;
}

.quick-action-item:hover {
    border-color: var(--color-primary);
    box-shadow: var(--shadow-base);
}

.quick-action-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--spacing-sm);
    background-color: #e6f7ff;
    color: var(--color-primary);
}

.quick-action-label {
    font-size: var(--font-size-base);
    color: var(--color-text);
}

/* ========== 待办列表 ========== */
.todo-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.todo-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: #fff;
    border-radius: var(--radius-base);
    cursor: pointer;
    transition: background-color 0.2s;
}

.todo-item:hover {
    background-color: var(--color-bg-hover);
}

.todo-checkbox {
    width: 18px;
    height: 18px;
    border: 2px solid var(--color-border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    flex-shrink: 0;
    transition: all 0.2s;
}

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

.todo-checkbox.checked::after {
    content: '✓';
    color: #fff;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
}

.todo-content {
    flex: 1;
    min-width: 0;
}

.todo-title {
    font-size: var(--font-size-base);
    color: var(--color-text);
    margin-bottom: 2px;
}

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

.todo-meta {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
}

/* ========== 客户列表 ========== */
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--spacing-lg);
}

.page-title {
    font-size: var(--font-size-xl);
    font-weight: 500;
    color: var(--color-text);
}

.page-actions {
    display: flex;
    gap: var(--spacing-md);
}

/* ========== 筛选栏 ========== */
.filter-bar {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
    flex-wrap: wrap;
}

.filter-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.filter-item label {
    font-size: var(--font-size-base);
    color: var(--color-text);
    white-space: nowrap;
}

.filter-item .input,
.filter-item .select {
    width: 160px;
}

/* ========== 表格 ========== */
.table-container {
    background: #fff;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-base);
    overflow: visible;
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table thead {
    background-color: var(--color-bg);
}

.table th {
    padding: 12px var(--spacing-md);
    text-align: left;
    font-weight: 500;
    color: var(--color-text);
    font-size: var(--font-size-base);
    border-bottom: 1px solid var(--color-border-light);
}

.table td {
    padding: 12px var(--spacing-md);
    color: var(--color-text);
    border-bottom: 1px solid var(--color-border-light);
}

.table tbody tr {
    transition: background-color 0.2s;
}

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

.table tbody tr:last-child td {
    border-bottom: none;
}

.table-actions {
    display: flex;
    gap: var(--spacing-sm);
}

/* 客户列表：跟进记录悬浮预览 */
.followup-cell {
    position: relative;
    display: inline-block;
    cursor: pointer;
}

.followup-cell-trigger {
    color: var(--color-primary);
    font-size: var(--font-size-sm);
    border-bottom: 1px dashed rgba(24, 144, 255, 0.45);
}

.followup-preview {
    position: absolute;
    left: 0;
    top: calc(100% + 6px);
    width: 360px;
    max-height: 260px;
    overflow-y: auto;
    background: rgba(0, 0, 0, 0.88);
    color: #fff;
    border: none;
    border-radius: var(--radius-base);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    padding: 8px;
    z-index: 1200;
    display: none;
}

.followup-preview::before {
    content: '';
    position: absolute;
    top: -5px;
    left: 18px;
    width: 10px;
    height: 10px;
    background: rgba(0, 0, 0, 0.88);
    transform: rotate(45deg);
}

.followup-cell:hover .followup-preview {
    display: block;
}

.followup-preview-title {
    font-size: var(--font-size-sm);
    color: rgba(255, 255, 255, 0.75);
    margin-bottom: 6px;
    padding: 0 4px;
}

.followup-preview-item {
    width: 100%;
    text-align: left;
    border: 1px solid transparent;
    border-radius: var(--radius-base);
    background: transparent;
    padding: 8px 6px;
    cursor: pointer;
    color: #fff;
    display: grid;
    grid-template-columns: 80px 16px 1fr;
    gap: 8px;
    align-items: start;
    position: relative;
}

.followup-preview-item:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.16);
}

.followup-preview-time {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.72);
    text-align: right;
    line-height: 20px;
    white-space: nowrap;
}

.followup-preview-axis {
    position: relative;
    display: flex;
    justify-content: center;
    min-height: 100%;
}

.followup-preview-axis::after {
    content: '';
    position: absolute;
    top: 10px;
    bottom: -10px;
    width: 1px;
    background: rgba(255, 255, 255, 0.28);
}

.followup-preview-item:last-child .followup-preview-axis::after {
    display: none;
}

.followup-preview-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #1677ff;
    border: 1px solid rgba(255, 255, 255, 0.8);
    margin-top: 6px;
    z-index: 1;
}

.followup-preview-card {
    min-height: 44px;
}

.followup-preview-type {
    font-size: var(--font-size-sm);
    font-weight: 500;
    color: #fff;
}

.followup-preview-meta {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.65);
    margin-top: 2px;
}

.followup-preview-content {
    font-size: var(--font-size-sm);
    color: rgba(255, 255, 255, 0.9);
    margin-top: 4px;
}

.followup-preview-entry {
    font-size: 12px;
    color: #69b1ff;
    margin-top: 6px;
}

.followup-preview-empty {
    padding: 8px;
    font-size: var(--font-size-sm);
    color: rgba(255, 255, 255, 0.75);
}

/* 客户详情：跟进记录时间轴（参考业务时间线样式） */
.followup-timeline {
    display: flex;
    flex-direction: column;
}

.followup-timeline-item {
    display: grid;
    grid-template-columns: 110px 20px 1fr;
    gap: 10px;
    align-items: start;
    position: relative;
    padding-bottom: 14px;
}

.followup-timeline-item:last-child {
    padding-bottom: 0;
}

.followup-timeline-time {
    text-align: right;
    color: var(--color-text-secondary);
    font-size: var(--font-size-sm);
    line-height: 24px;
    white-space: nowrap;
}

.followup-timeline-axis {
    position: relative;
    display: flex;
    justify-content: center;
    min-height: 100%;
}

.followup-timeline-axis::after {
    content: '';
    position: absolute;
    top: 12px;
    bottom: -14px;
    width: 2px;
    background: #e6f4ff;
}

.followup-timeline-item:last-child .followup-timeline-axis::after {
    display: none;
}

.followup-timeline-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--color-primary);
    border: 2px solid #fff;
    box-shadow: 0 0 0 1px #91caff;
    margin-top: 7px;
    z-index: 1;
}

.followup-timeline-content {
    background: #fff;
    border: 1px solid var(--color-border-light);
    border-radius: var(--radius-base);
    padding: 10px 12px;
}

.followup-timeline-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.followup-timeline-type {
    font-weight: 500;
    color: var(--color-text);
}

.followup-timeline-body {
    color: var(--color-text);
    line-height: 1.6;
}

.followup-timeline-footer {
    margin-top: 8px;
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
}

/* ========== 客户详情 ========== */
.customer-detail {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: var(--spacing-lg);
}

.customer-info-section {
    margin-bottom: var(--spacing-lg);
}

.section-title {
    font-size: var(--font-size-lg);
    font-weight: 500;
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-sm);
    border-bottom: 2px solid var(--color-border-light);
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-lg);
}

.info-item {
    display: flex;
    flex-direction: column;
}

.info-label {
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
    margin-bottom: 4px;
}

.info-value {
    font-size: var(--font-size-base);
    color: var(--color-text);
}

.contact-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.contact-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: var(--color-bg);
    border-radius: var(--radius-base);
}

.contact-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-primary), var(--color-cyan));
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 500;
}

.contact-info {
    flex: 1;
}

.contact-name {
    font-size: var(--font-size-base);
    color: var(--color-text);
    margin-bottom: 2px;
}

.contact-detail {
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
}

/* ========== 跟进记录时间轴 ========== */
.timeline {
    position: relative;
    padding-left: 32px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 0;
    bottom: 0;
    width: 2px;
    background-color: var(--color-border-light);
}

.timeline-item {
    position: relative;
    padding-bottom: var(--spacing-lg);
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-dot {
    position: absolute;
    left: -26px;
    top: 4px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: var(--color-primary);
    border: 2px solid #fff;
    box-shadow: 0 0 0 2px var(--color-primary);
}

.timeline-dot.success {
    background-color: var(--color-success);
    box-shadow: 0 0 0 2px var(--color-success);
}

.timeline-dot.warning {
    background-color: var(--color-warning);
    box-shadow: 0 0 0 2px var(--color-warning);
}

.timeline-content {
    padding: var(--spacing-md);
    background: #fff;
    border-radius: var(--radius-base);
    border: 1px solid var(--color-border-light);
}

.timeline-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--spacing-sm);
}

.timeline-type {
    font-size: var(--font-size-base);
    font-weight: 500;
    color: var(--color-text);
}

.timeline-date {
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
}

.timeline-body {
    color: var(--color-text);
    line-height: 1.6;
}

.timeline-footer {
    margin-top: var(--spacing-sm);
    padding-top: var(--spacing-sm);
    border-top: 1px solid var(--color-border-light);
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
}

/* ========== 销售漏斗 ========== */
.funnel-container {
    display: flex;
    align-items: center;
    gap: var(--spacing-xl);
    padding: var(--spacing-xl);
    background: #fff;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-base);
}

.funnel-chart {
    flex: 1;
}

.funnel-legend {
    width: 200px;
}

.funnel-legend-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-sm) 0;
    border-bottom: 1px solid var(--color-border-light);
}

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

.funnel-legend-label {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    font-size: var(--font-size-base);
    color: var(--color-text);
}

.funnel-legend-dot {
    width: 12px;
    height: 12px;
    border-radius: var(--radius-sm);
}

.funnel-legend-value {
    font-weight: 500;
    color: var(--color-text);
}

/* ========== 统计卡片 ========== */
.stats-overview {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
}

.stats-card {
    background: #fff;
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    box-shadow: var(--shadow-base);
}

.stats-card-title {
    font-size: var(--font-size-base);
    color: var(--color-text-secondary);
    margin-bottom: var(--spacing-sm);
}

.stats-card-value {
    font-size: var(--font-size-xxl);
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: var(--spacing-sm);
}

.stats-card-sub {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    font-size: var(--font-size-sm);
}

.stats-card-sub.trend-up {
    color: var(--color-success);
}

.stats-card-sub.trend-down {
    color: var(--color-danger);
}

/* ========== 目标设定 ========== */
.goal-setting {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: #fff;
    border-radius: var(--radius-base);
    margin-bottom: var(--spacing-lg);
}

.goal-setting .input {
    width: 200px;
}

/* ========== 进度展示 ========== */
.progress-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.progress-item {
    padding: var(--spacing-md);
    background: #fff;
    border-radius: var(--radius-base);
}

.progress-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--spacing-sm);
}

.progress-label {
    font-size: var(--font-size-base);
    color: var(--color-text);
}

.progress-value {
    font-size: var(--font-size-base);
    font-weight: 500;
    color: var(--color-text);
}

.progress-bar-bg {
    height: 8px;
    background-color: var(--color-border-light);
    border-radius: 4px;
    overflow: hidden;
}

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

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

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

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

/* ========== 回访列表 ========== */
.visit-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.visit-item {
    padding: var(--spacing-md);
    background: #fff;
    border-radius: var(--radius-base);
    border: 1px solid var(--color-border-light);
}

.visit-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--spacing-sm);
}

.visit-customer {
    font-size: var(--font-size-base);
    font-weight: 500;
    color: var(--color-text);
}

.visit-date {
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
}

.visit-content {
    color: var(--color-text);
    margin-bottom: var(--spacing-sm);
    line-height: 1.6;
}

.visit-feedback {
    padding: var(--spacing-sm);
    background: var(--color-bg);
    border-radius: var(--radius-base);
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
}

.visit-satisfaction {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: var(--spacing-sm);
}

.visit-star {
    color: var(--color-warning);
    font-size: 16px;
}

.visit-star.empty {
    color: var(--color-border-light);
}

/* ========== 表单样式 ========== */
.form-group {
    margin-bottom: var(--spacing-md);
}

.form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: var(--spacing-md);
    margin-top: var(--spacing-lg);
    padding-top: var(--spacing-lg);
    border-top: 1px solid var(--color-border-light);
}

/* ========== 重复项操作 ========== */
.contact-item-add {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: var(--color-bg);
    border-radius: var(--radius-base);
    margin-bottom: var(--spacing-sm);
}

.contact-item-remove {
    color: var(--color-danger);
    cursor: pointer;
    padding: 4px;
    border-radius: var(--radius-base);
    transition: background-color 0.2s;
}

.contact-item-remove:hover {
    background-color: #fff1f0;
}

/* ========== 空状态 ========== */
.empty-state {
    text-align: center;
    padding: var(--spacing-xxl) var(--spacing-lg);
}

.empty-icon {
    font-size: 64px;
    color: var(--color-text-disabled);
    margin-bottom: var(--spacing-md);
}

.empty-text {
    font-size: var(--font-size-lg);
    color: var(--color-text-secondary);
    margin-bottom: var(--spacing-md);
}

.empty-action {
    color: var(--color-primary);
    cursor: pointer;
}

.empty-action:hover {
    text-decoration: underline;
}

/* ========== 响应式 ========== */
@media (max-width: 1024px) {
    .dashboard-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .dashboard-layout {
        grid-template-columns: 1fr;
    }

    .customer-detail {
        grid-template-columns: 1fr;
    }

    .stats-overview {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .quick-actions {
        grid-template-columns: repeat(2, 1fr);
    }

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

    .form-row {
        grid-template-columns: 1fr;
    }

    .page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--spacing-md);
    }

    .filter-bar {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-item .input,
    .filter-item .select {
        width: 100%;
    }

    .table-container {
        overflow-x: auto;
    }
}

/* 客户详情弹窗样式 */
.customer-detail-modal .ant-modal-body {
    padding: 0 !important;
    overflow: hidden !important;
}

.customer-detail-modal-content {
    display: flex;
    height: 60vh;
    min-height: 400px;
    overflow: hidden;
    border-top: 1px solid var(--color-border);
}

.customer-detail-left {
    flex: 0 0 45%;
    border-right: 1px solid var(--color-border);
    background: var(--color-bg);
    overflow-y: auto;
    overflow-x: hidden;
    height: 100%;
}

.customer-detail-right {
    flex: 1;
    background: #fff;
    overflow-y: auto !important;
    overflow-x: hidden;
    height: 100%;
    position: relative;
}

.detail-section {
    padding: 20px;
    border-bottom: 1px solid var(--color-border);
}

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

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

.detail-section-header h3 {
    font-size: 15px;
    font-weight: 600;
    color: var(--color-text);
    margin: 0;
}

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

.detail-info-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.detail-info-item.full-width {
    grid-column: 1 / -1;
}

.detail-label {
    font-size: 12px;
    color: var(--color-text-secondary);
}

.detail-value {
    font-size: 14px;
    color: var(--color-text);
    word-break: break-all;
}

.contact-list-compact {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.contact-item-compact {
    padding: 12px;
    background: var(--color-bg);
    border-radius: 4px;
}

.contact-name {
    font-weight: 500;
    color: var(--color-text);
    margin-bottom: 4px;
}

.contact-phone,
.contact-email {
    font-size: 13px;
    color: var(--color-text-secondary);
    margin-top: 2px;
}

.quick-actions-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.empty-state-small {
    text-align: center;
    padding: 30px 20px;
    color: var(--color-text-secondary);
    font-size: 14px;
}

.followup-list-modal {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding-bottom: 12px;
}

.followup-item-modal {
    padding: 12px;
    background: var(--color-bg);
    border-radius: 4px;
    border-left: 3px solid var(--color-primary);
    cursor: default;
}

.followup-header-modal {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    cursor: pointer;
    user-select: none;
}

.followup-header-modal:hover .followup-time {
    color: var(--color-primary);
}

.followup-type-badge {
    display: inline-block;
    padding: 2px 8px;
    background: var(--color-primary);
    color: #fff;
    font-size: 12px;
    border-radius: 2px;
}

.followup-time {
    font-size: 12px;
    color: var(--color-text-secondary);
    transition: color 0.2s;
}

.followup-content-modal {
    font-size: 14px;
    color: var(--color-text);
    line-height: 1.6;
    margin-bottom: 8px;
}

.followup-content-text {
    display: block;
    max-height: 60px;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.followup-expand-btn {
    display: inline-block;
    margin-left: 8px;
    font-size: 12px;
    color: var(--color-primary);
    cursor: pointer;
    user-select: none;
}

.followup-expand-btn:hover {
    text-decoration: underline;
}

.followup-next-date {
    font-size: 12px;
    color: var(--color-primary);
    margin-top: 6px;
}

.followup-status-tag {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 2px;
    font-size: 12px;
    margin-top: 6px;
}

/* 弹窗头部右侧操作按钮 */
.modal-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.customer-detail-modal .modal-header {
    padding: 12px 16px;
}

.customer-detail-modal .modal-title {
    font-size: 16px;
    font-weight: 500;
}

.ant-btn-sm {
    padding: 4px 12px;
    font-size: 13px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

/* 滚动条样式优化 */
.customer-detail-left::-webkit-scrollbar,
.customer-detail-right::-webkit-scrollbar {
    width: 6px;
}

.customer-detail-left::-webkit-scrollbar-track,
.customer-detail-right::-webkit-scrollbar-track {
    background: transparent;
}

.customer-detail-left::-webkit-scrollbar-thumb,
.customer-detail-right::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
}

.customer-detail-left::-webkit-scrollbar-thumb:hover,
.customer-detail-right::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.3);
}

@media (max-width: 768px) {
    .customer-detail-modal-content {
        flex-direction: column;
        height: auto;
        max-height: 70vh;
        overflow-y: auto;
    }

    .customer-detail-left {
        flex: none;
        border-right: none;
        border-bottom: 1px solid var(--color-border);
        overflow-y: visible;
        height: auto;
    }

    .customer-detail-right {
        overflow-y: visible;
        height: auto;
    }

    .detail-info-grid {
        grid-template-columns: 1fr;
    }

    .modal-header-actions {
        flex-direction: row;
    }
}
