* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #005e55;
    --primary-dark: #002f2b;
    --success-color: #005e55;
    --danger-color: #FF3B30;
    --warning-color: #FF9500;
    --bg-color: #F2F2F7;
    --sidebar-bg: linear-gradient(180deg, #005e55 0%, #002f2b 100%);
    --sidebar-text: #FFFFFF;
    --sidebar-hover: rgba(255, 255, 255, 0.1);
    --card-bg: #FFFFFF;
    --text-primary: #1C1C1E;
    --text-secondary: #8E8E93;
    --border-color: #E5E5EA;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --radius: 12px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    min-height: 100vh;
}

.admin-layout {
    display: flex;
    min-height: 100vh;
}

/* 侧边栏 */
.sidebar {
    width: 240px;
    background: var(--sidebar-bg);
    color: var(--sidebar-text);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
}

.sidebar-header {
    padding: 24px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-header h2 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
}

.admin-badge {
    display: inline-block;
    padding: 4px 8px;
    background: linear-gradient(135deg, #005e55 0%, #002f2b 100%);
    color: white;
    font-size: 12px;
    border-radius: 4px;
}

.sidebar-nav {
    flex: 1;
    padding: 16px 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: all 0.2s;
}

.nav-item:hover {
    background: var(--sidebar-hover);
    color: white;
}

.nav-item.active {
    background: var(--sidebar-hover);
    color: white;
    border-left: 3px solid var(--primary-color);
}

.nav-icon {
    font-size: 18px;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.nav-icon svg {
    width: 100%;
    height: 100%;
}

.nav-item:hover .nav-icon,
.nav-item.active .nav-icon {
    opacity: 1;
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.user-info {
    margin-bottom: 12px;
}

.user-name {
    display: block;
    font-weight: 600;
    margin-bottom: 4px;
}

.user-role {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
}

.btn-logout {
    width: 100%;
    padding: 10px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-logout:hover {
    background: rgba(255, 59, 48, 0.5);
}

/* 主内容区 */
.main-content {
    flex: 1;
    margin-left: 240px;
    padding: 24px;
    max-width: calc(100vw - 240px);
    overflow-x: hidden;
}

.page {
    display: none;
}

.page.active {
    display: block;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 24px;
}

.page-header h1 {
    font-size: 24px;
    font-weight: 600;
}

.page-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* 按钮 */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-primary {
    background: linear-gradient(135deg, #005e55 0%, #002f2b 100%);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #004d46 0%, #002522 100%);
}

.btn-secondary {
    background: #E5E5EA;
    color: var(--text-primary);
}

.btn-secondary:hover {
    background: #D1D1D6;
}

.btn-danger {
    background: rgba(255, 59, 48, 0.1);
    color: var(--danger-color);
}

.btn-danger:hover {
    background: rgba(255, 59, 48, 0.2);
}

.btn-block {
    width: 100%;
    justify-content: center;
}

/* 搜索栏 */
.search-bar {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.search-bar input {
    flex: 1;
    min-width: 200px;
    padding: 10px 16px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 14px;
}

/* 筛选栏 */
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
    padding: 16px;
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.filter-bar select,
.filter-bar input {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 14px;
}

/* 多选下拉框 */
.multi-select {
    position: relative;
    min-width: 180px;
}

.multi-select-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: white;
    cursor: pointer;
    font-size: 14px;
    min-height: 38px;
}

.multi-select-trigger:hover {
    border-color: #005e55;
}

.multi-select-placeholder {
    color: var(--text-secondary);
}

.multi-select-arrow {
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid var(--text-secondary);
    margin-left: 8px;
    transition: transform 0.2s;
}

.multi-select.open .multi-select-arrow {
    transform: rotate(180deg);
}

.multi-select-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 4px;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 100;
    max-height: 250px;
    overflow-y: auto;
}

.multi-select-search {
    padding: 8px 12px;
    border-bottom: 1px solid var(--border-color);
}

.multi-select-search-input {
    width: 100%;
    padding: 6px 10px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 13px;
    box-sizing: border-box;
}

.multi-select-search-input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.multi-select-no-results {
    padding: 12px;
    text-align: center;
    color: var(--text-secondary);
    font-size: 13px;
}

.multi-select-options {
    padding: 8px 0;
    max-height: 180px;
    overflow-y: auto;
}

/* 组合框样式 */
.combobox {
    position: relative;
    min-width: 280px;
}

.combobox input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 14px;
    box-sizing: border-box;
}

.combobox input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.combobox-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 4px;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 100;
    max-height: 250px;
    overflow-y: auto;
}

.combobox-options {
    padding: 4px 0;
}

.combobox-option {
    padding: 10px 14px;
    cursor: pointer;
    font-size: 14px;
}

.combobox-option:hover {
    background: #F5F5F5;
}

.combobox-option .merchant-name {
    font-weight: 500;
}

.combobox-option .license-no {
    color: #888;
    font-size: 12px;
    margin-left: 8px;
}

.combobox-no-results {
    padding: 12px;
    text-align: center;
    color: var(--text-secondary);
    font-size: 13px;
}


.multi-select-option {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    cursor: pointer;
    font-size: 14px;
}

.multi-select-option:hover {
    background: #F5F5F5;
}

.multi-select-option.selected {
    background: rgba(0, 94, 85, 0.1);
    color: #005e55;
}

.multi-select-option input[type="checkbox"] {
    margin-right: 8px;
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.multi-select-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.multi-select-tag {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    background: rgba(0, 94, 85, 0.15);
    color: #005e55;
    border-radius: 4px;
    font-size: 12px;
}

.multi-select-trigger.disabled {
    background: #F5F5F5;
    cursor: not-allowed;
    color: var(--text-secondary);
}

.multi-select-tag-remove {
    margin-left: 4px;
    cursor: pointer;
    font-weight: bold;
}

/* 表格 */
.table-container {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow-x: auto;
    overflow-y: visible;
    max-width: 100%;
}

.table-container.wide-table {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.table-container.wide-table .data-table {
    width: 100%;
    min-width: 100%;
}

.table-container.wide-table th {
    position: sticky;
    top: 0;
    left: 0;
    z-index: 10;
    background: #F9F9F9;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 800px;
}

.data-table th,
.data-table td {
    padding: 12px 14px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
    white-space: nowrap;
}

.data-table th {
    background: #F9F9F9;
    font-weight: 600;
    font-size: 12px;
    color: var(--text-secondary);
}

.data-table tr:last-child td {
    border-bottom: none;
}

.data-table tr:hover {
    background: #F9F9F9;
}

.data-table .loading-row td {
    text-align: center;
    color: var(--text-secondary);
    padding: 40px;
}

.data-table td {
    font-size: 14px;
}

.data-table .actions {
    display: flex;
    gap: 8px;
}

.data-table .actions .btn {
    padding: 6px 10px;
    font-size: 12px;
}

.qr-content {
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 分页 */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
}

.pagination button {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    background: white;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.pagination button:hover {
    background: #F9F9F9;
}

.pagination button.active {
    background: linear-gradient(135deg, #005e55 0%, #002f2b 100%);
    color: white;
    border-color: #005e55;
}

.pagination button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* 个人资料卡片 */
.profile-card {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 24px;
    margin-bottom: 20px;
}

.profile-card h3 {
    margin-bottom: 20px;
    font-size: 16px;
}

.profile-info {
    display: grid;
    gap: 16px;
}

.profile-item {
    display: flex;
    align-items: center;
    gap: 16px;
}

.profile-item label {
    width: 100px;
    color: var(--text-secondary);
    font-size: 14px;
}

.profile-item span {
    font-size: 16px;
    font-weight: 500;
}

/* 表单 */
.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 500;
}

.form-group label .hint {
    font-weight: 400;
    color: var(--text-secondary);
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 14px;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #005e55;
}

.password-form {
    max-width: 400px;
}

/* 弹窗 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: var(--radius);
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow: auto;
}

.modal-sm {
    max-width: 400px;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    font-size: 18px;
    font-weight: 600;
}

.modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    font-size: 24px;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    background: var(--bg-color);
}

.modal-body {
    padding: 24px;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 24px;
}

.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

/* 上传区域 */
.upload-area {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius);
    padding: 40px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
}

.upload-area:hover {
    border-color: #005e55;
    background: rgba(0, 94, 85, 0.05);
}

.upload-area.dragover {
    border-color: #005e55;
    background: rgba(0, 94, 85, 0.1);
}

.upload-icon {
    display: block;
    margin-bottom: 12px;
}

.upload-icon svg {
    width: 48px;
    height: 48px;
    opacity: 0.5;
}

.upload-hint p {
    font-size: 14px;
    color: var(--text-secondary);
}

.upload-format {
    font-size: 12px !important;
    margin-top: 8px;
}

.upload-info {
    margin-top: 20px;
    padding: 16px;
    background: #F9F9F9;
    border-radius: 8px;
    font-size: 13px;
}

.upload-info p {
    margin-bottom: 4px;
    color: var(--text-secondary);
}

/* 标签 */
.tag {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.tag-green {
    background: rgba(0, 94, 85, 0.15);
    color: #005e55;
}

.tag-orange {
    background: rgba(255, 149, 0, 0.15);
    color: var(--warning-color);
}

.tag-gray {
    background: #E5E5EA;
    color: var(--text-secondary);
}

/* 表单行 */
.form-row {
    display: flex;
    gap: 16px;
}

.form-row .form-group {
    flex: 1;
}

/* 弹窗大尺寸 */
.modal-lg {
    max-width: 700px;
}

/* 详情卡片（查看弹窗） */
.detail-card {
    background: #F9FAFB;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 8px 4px;
}

.detail-row {
    display: flex;
    gap: 16px;
    padding: 14px 18px;
    border-bottom: 1px solid var(--border-color);
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

.detail-item-full {
    flex: 1 1 100%;
}

.detail-label {
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 500;
}

.detail-value {
    font-size: 15px;
    color: var(--text-primary);
    font-weight: 500;
    word-break: break-all;
}

.detail-value.empty {
    color: #B0B0B5;
    font-weight: 400;
}

/* Toast 提示 */
.toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    padding: 12px 24px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    border-radius: 8px;
    font-size: 14px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 2000;
}

.toast.show {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.toast.success {
    background: rgba(0, 94, 85, 0.95);
}

.toast.error {
    background: rgba(255, 59, 48, 0.95);
}

/* 响应式 */
@media (max-width: 1024px) {
    .sidebar {
        width: 200px;
    }
    
    .main-content {
        margin-left: 200px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        display: none;
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    
    .filter-bar {
        flex-direction: column;
    }

    .filter-bar select,
    .filter-bar input,
    .filter-bar .btn {
        width: 100%;
    }
}

/* ============ 库存管理 ============ */
.tabs-bar {
    display: flex;
    gap: 4px;
    margin-bottom: 16px;
    background: #FFFFFF;
    padding: 6px;
    border-radius: 8px;
    box-shadow: var(--shadow);
    width: fit-content;
}

.tab-btn {
    padding: 8px 20px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s;
}

.tab-btn:hover {
    background: #F2F2F7;
}

.tab-btn.active {
    background: var(--primary-color);
    color: white;
}

.mode-panel {
    display: none;
}

.mode-panel.active {
    display: block;
}

.merchant-hint {
    padding: 14px 18px;
    background: rgba(0, 94, 85, 0.08);
    color: var(--primary-color);
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 13px;
    text-align: center;
}

.merchant-mini-summary {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    background: linear-gradient(135deg, #005e55 0%, #007a6a 100%);
    color: white;
    border-radius: 10px;
    padding: 16px 20px;
    margin-bottom: 16px;
}

.mini-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.mini-label {
    font-size: 12px;
    opacity: 0.85;
}

.mini-value {
    font-size: 16px;
    font-weight: 600;
    word-break: break-all;
}

.qty-badge {
    display: inline-block;
    min-width: 36px;
    text-align: center;
    padding: 4px 10px;
    background: rgba(0, 94, 85, 0.1);
    color: var(--primary-color);
    border-radius: 12px;
    font-weight: 600;
    font-size: 13px;
}

.qty-badge.large {
    background: var(--primary-color);
    color: white;
    font-size: 14px;
    padding: 5px 12px;
}

.distribution-bar {
    background: #F2F2F7;
    border-radius: 4px;
    height: 6px;
    overflow: hidden;
    margin-top: 4px;
}

.distribution-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #005e55 0%, #007a6a 100%);
    border-radius: 4px;
}

/* ============ 库存管理 - 按商户查看 新版样式 ============ */

/* 紧凑按钮 */
.btn-mini {
    padding: 4px 10px;
    font-size: 12px;
}

/* merchant-sub-view：用户列表 / 库存详情 互斥显示 */
.merchant-sub-view {
    display: none;
}
.merchant-sub-view.active {
    display: block;
}

/* 返回栏 */
.detail-back-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    padding: 12px 16px;
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}
.detail-back-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    margin-left: 8px;
}

/* 日历卡片 */
.calendar-card {
    background: var(--card-bg);
    border-radius: var(--radius);
    padding: 20px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
}
.calendar-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}
.calendar-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 8px;
    min-width: 140px;
    text-align: center;
}
.calendar-nav {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    background: white;
    color: var(--text-primary);
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s;
}
.calendar-nav:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}
.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 8px;
}
.calendar-weekdays span {
    padding: 6px 0;
}
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}
.calendar-cell {
    position: relative;
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: #FAFAFC;
    cursor: pointer;
    transition: all 0.15s;
    user-select: none;
}
.calendar-cell.empty {
    background: transparent;
    cursor: default;
}
.calendar-cell:not(.empty):hover {
    background: rgba(0, 94, 85, 0.08);
}
.calendar-cell.today {
    border: 1.5px solid var(--primary-color);
}
.calendar-cell.today .calendar-day {
    color: var(--primary-color);
    font-weight: 700;
}
.calendar-cell.has-report {
    background: rgba(0, 94, 85, 0.06);
}
.calendar-cell.selected {
    background: var(--primary-color) !important;
    color: white;
}
.calendar-cell.selected .calendar-day {
    color: white;
    font-weight: 700;
}
.calendar-day {
    font-size: 14px;
    color: var(--text-primary);
}
.calendar-dot {
    position: absolute;
    bottom: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #FF9500;
}
.calendar-cell.selected .calendar-dot {
    background: white;
}
.calendar-loading {
    grid-column: 1 / -1;
    text-align: center;
    padding: 30px;
    color: var(--text-secondary);
    font-size: 13px;
}
.calendar-legend {
    margin-top: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-secondary);
}
.legend-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #FF9500;
    display: inline-block;
}

/* 上报批次列表 */
.report-day-panel {
    background: var(--card-bg);
    border-radius: var(--radius);
    padding: 20px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
}
.report-day-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
}
.report-day-header h3 {
    font-size: 15px;
    color: var(--text-primary);
}
.report-day-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}
.report-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.report-empty {
    padding: 40px;
    text-align: center;
    color: var(--text-secondary);
    font-size: 13px;
    background: #FAFAFC;
    border-radius: 8px;
}
.report-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: #FAFAFC;
    border: 1.5px solid transparent;
    border-radius: 10px;
    transition: all 0.15s;
}
.report-card.selected {
    background: rgba(0, 94, 85, 0.08);
    border-color: var(--primary-color);
}
.report-check {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    flex-shrink: 0;
}
.report-check input {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--primary-color);
}
.report-card-main {
    flex: 1;
    min-width: 0;
}
.report-time {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 6px;
}
.report-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.meta-chip {
    display: inline-block;
    padding: 2px 8px;
    background: rgba(0, 94, 85, 0.12);
    color: var(--primary-color);
    border-radius: 10px;
    font-size: 12px;
}
.meta-chip.meta-gray {
    background: #E5E5EA;
    color: var(--text-secondary);
}
.report-actions {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
}

/* 日期选择入口（把日历挤进弹窗，主区域留给上报记录） */
.report-date-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 20px;
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin-bottom: 16px;
}

.report-date-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.report-date-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.report-date-hint {
    font-size: 12px;
    color: var(--text-secondary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.report-day-panel-primary {
    padding: 22px 24px;
}

.report-heading {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    min-width: 0;
}

.report-section-kicker {
    font-size: 11px;
    color: var(--text-secondary);
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.report-day-header h2 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.report-day-summary {
    font-size: 13px;
    color: var(--text-secondary);
}

/* 日历弹窗 */
.calendar-modal .modal-content {
    max-width: 460px;
}

.calendar-modal-tip {
    margin: 4px 0 0;
    font-size: 12px;
    color: var(--text-secondary);
}

.calendar-modal-body {
    padding: 16px 20px 0;
}

.calendar-modal-body .calendar-card {
    margin: 0;
    padding: 0;
    background: transparent;
    box-shadow: none;
}

.calendar-modal .modal-footer {
    border-top: 1px solid var(--border-color);
    padding: 12px 20px;
}

@media (max-width: 768px) {
    .report-day-panel-primary {
        padding: 16px;
    }
    .report-day-header h2 {
        font-size: 17px;
    }
    .calendar-modal .modal-content {
        max-width: 95vw;
    }
}

/* ============ 多批次对比弹窗 ============ */
.modal-xl {
    max-width: 1100px;
}
.compare-view {
    display: none;
}
.compare-view.active {
    display: block;
}
.th-sub {
    font-weight: 400;
    color: var(--text-secondary);
    font-size: 11px;
}
.change-up {
    color: #FF9500;
    font-weight: 600;
}
.change-down {
    color: #005e55;
    font-weight: 600;
}
.change-flat {
    color: var(--text-secondary);
}
.chart-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: #FAFAFC;
    border-radius: 8px;
    margin-bottom: 12px;
    font-size: 13px;
    color: var(--text-secondary);
}
.chart-toolbar select {
    padding: 4px 8px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 13px;
    min-width: 200px;
    max-width: 360px;
}
.chart-wrap {
    height: 380px;
    position: relative;
}
.detail-card-loading {
    padding: 20px;
    text-align: center;
    color: var(--text-secondary);
    font-size: 13px;
}
