/* 游戏记录页面样式 */

.main-container {
    max-width: 1080px;
    margin: 20px auto;
    padding: 0 20px;
    display: flex;
    gap: 20px;
}

/* 左侧边栏 */
.sidebar {
    width: 240px;
    background: #fff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    height: fit-content;
    position: sticky;
    top: 90px;
}

.sidebar-header {
    margin-bottom: 20px;
    text-align: center;
}

.sidebar-logo {
    height: 40px;
    width: auto;
}

.user-account {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px;
    background: #f5f5f5;
    border-radius: 6px;
    margin-bottom: 20px;
}

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

.account-value {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    flex: 1;
}

.copy-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    transition: color 0.3s;
}

.copy-btn:hover {
    color: #3066ff;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sidebar-nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 6px;
    color: #666;
    text-decoration: none;
    transition: all 0.3s;
    font-size: 14px;
}

.sidebar-nav-item:hover {
    background: #f5f5f5;
    color: #3066ff;
}

.sidebar-nav-item.active {
    background: #e6f4ff;
    color: #3066ff;
    font-weight: 600;
}

.sidebar-nav-item svg {
    flex-shrink: 0;
}

/* 主内容区域 */
.content-area {
    flex: 1;
    background: #fff;
    border-radius: 8px;
    padding: 30px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.content-header {
    margin-bottom: 30px;
}

.page-title {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    position: relative;
    padding-left: 12px;
}

.page-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 24px;
    background: #3066ff;
    border-radius: 2px;
}

/* 筛选区域 */
.filter-section {
    margin-bottom: 30px;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 8px;
}

.filter-row {
    display: flex;
    gap: 20px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.filter-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 0 0 auto;
    min-width: 150px;
    max-width: 180px;
}

.filter-item:has(.date-range) {
    max-width: 248px;
    min-width: 230px;
}

.filter-label {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

.filter-select {
    padding: 10px 12px;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    font-size: 14px;
    background: #fff;
    color: #333;
    cursor: pointer;
    transition: border-color 0.3s;
}

.filter-select:hover {
    border-color: #3066ff;
}

.filter-select:focus {
    outline: none;
    border-color: #3066ff;
}

.date-range {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 12px;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    background: #fff;
    transition: border-color 0.3s;
    position: relative;
    width: 100%;
    box-sizing: border-box;
}

.date-range:hover {
    border-color: #3066ff;
}

.date-range.focused {
    border-color: #3066ff;
}

.date-range-icon {
    display: flex;
    align-items: center;
    color: #999;
    flex-shrink: 0;
}

.date-range-input {
    flex: 1;
    padding: 10px 0;
    border: none;
    font-size: 14px;
    background: transparent;
    color: #333;
    cursor: pointer;
    outline: none;
    min-width: 0;
}

.date-range-input::placeholder {
    color: #999;
}

.date-range-separator {
    color: #999;
    font-size: 14px;
    flex-shrink: 0;
    padding: 0 4px;
}

.date-range-close-icon {
    display: flex;
    align-items: center;
    color: #999;
    cursor: pointer;
    flex-shrink: 0;
    transition: color 0.3s;
}

.date-range-close-icon:hover {
    color: #666;
}

.filter-actions {
    display: flex;
    gap: 12px;
}

.btn-query,
.btn-reset {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
}

.btn-query {
    background: #3066ff;
    color: #fff;
}

.btn-query:hover {
    background: #4d7aff;
}

.btn-reset {
    background: #f5f5f5;
    color: #666;
}

.btn-reset:hover {
    background: #e8e8e8;
}

.btn-query svg,
.btn-reset svg {
    flex-shrink: 0;
}

/* 统计信息 */
.stats-section {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 所有卡片宽度一致 */
    gap: 20px;
    margin-bottom: 30px;
    align-items: start; /* 顶部对齐，避免拉伸 */
}

.stat-card {
    background: #3066ff;
    color: #fff;
    padding: 6px 15px; /* 减小左右内边距，给文字更多空间 */
    border-radius: 8px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0; /* 允许收缩 */
    overflow: visible; /* 允许内容溢出 */
    word-break: keep-all; /* 保持文字不换行 */
    height: 100%; /* 确保所有卡片高度一致 */
    min-height: 80px; /* 设置最小高度 */
}

.stat-label {
    font-size: 15px; /* 增大字体 */
    font-weight: 600; /* 加粗 */
    opacity: 0.9;
    margin-bottom: 2px; /* 减小间距，让数字更靠近标签 */
}

.stat-value {
    font-size: 24px; /* 增大字体 */
    font-weight: 700; /* 保持加粗 */
    margin-bottom: 1px;
    margin-top: 2px; /* 添加顶部间距，让数字往下移 */
}

.stat-note {
    font-size: 12px; /* 增大字体 */
    font-weight: 500; /* 加粗 */
    opacity: 0.8;
    color: #ffeb3b;
    margin-top: 1px;
    white-space: nowrap; /* 固定在一行，防止换行 */
    text-align: left; /* 左对齐 */
    margin-left: -8px; /* 使用负margin向左移动 */
}

/* 日期选择器弹窗 */
.date-picker-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9998;
}

.date-picker-overlay.show {
    display: block;
}

.date-picker-modal {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    z-index: 9999;
    min-width: 700px;
    max-width: 800px;
}

.date-picker-modal.show {
    display: block;
}

.date-picker-header {
    padding: 20px;
    border-bottom: 1px solid #f0f0f0;
}

.date-picker-quick-select {
    display: flex;
    gap: 10px;
}

.quick-date-btn {
    padding: 8px 16px;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    background: #fff;
    color: #666;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
}

.quick-date-btn:hover {
    border-color: #3066ff;
    color: #3066ff;
}

.quick-date-btn.active {
    background: #3066ff;
    border-color: #3066ff;
    color: #fff;
}

.date-picker-content {
    padding: 20px;
}

.date-picker-month-container {
    display: flex;
    gap: 30px;
}

.date-picker-month-wrapper {
    flex: 1;
}

.date-picker-month-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
}

.date-picker-nav-btn {
    background: transparent;
    border: none;
    font-size: 20px;
    color: #666;
    cursor: pointer;
    padding: 5px 10px;
    transition: color 0.3s;
}

.date-picker-nav-btn:hover {
    color: #3066ff;
}

.date-picker-month-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.date-picker-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
    margin-bottom: 10px;
}

.date-picker-weekday {
    text-align: center;
    font-size: 14px;
    color: #999;
    font-weight: 500;
    padding: 8px 0;
}

.date-picker-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
}

.date-picker-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid transparent;
    border-radius: 6px;
    font-size: 14px;
    color: #333;
    cursor: pointer;
    transition: all 0.3s;
    background: #fff;
}

.date-picker-day:hover {
    background: #f5f5f5;
    border-color: #e8e8e8;
}

.date-picker-day.other-month {
    color: #ccc;
}

.date-picker-day.today {
    background: #e6f4ff;
    border-color: #3066ff;
    color: #3066ff;
    font-weight: 600;
}

.date-picker-day.selected {
    background: #3066ff;
    border-color: #3066ff;
    color: #fff;
    font-weight: 600;
}

.date-picker-day.range-start {
    background: #3066ff;
    border-color: #3066ff;
    color: #fff;
    border-radius: 6px 0 0 6px;
}

.date-picker-day.range-end {
    background: #3066ff;
    border-color: #3066ff;
    color: #fff;
    border-radius: 0 6px 6px 0;
}

.date-picker-day.in-range {
    background: #e6f4ff;
    border-color: #e6f4ff;
    color: #3066ff;
    border-radius: 0;
}

.date-picker-footer {
    padding: 20px;
    border-top: 1px solid #f0f0f0;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.date-range-display {
    text-align: center;
    font-size: 14px;
    color: #666;
    padding: 10px;
    background: #f9f9f9;
    border-radius: 6px;
}

.date-picker-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.date-picker-btn {
    padding: 10px 24px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
}

.date-picker-btn-cancel {
    background: #f5f5f5;
    color: #666;
}

.date-picker-btn-cancel:hover {
    background: #e8e8e8;
}

.date-picker-btn-confirm {
    background: #3066ff;
    color: #fff;
}

.date-picker-btn-confirm:hover {
    background: #4d7aff;
}

/* 数据表格 */
.table-section {
    margin-bottom: 30px;
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.data-table thead {
    background: #f5f5f5;
}

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

.data-table td {
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
    color: #666;
}

.data-table tbody tr:hover {
    background: #f9f9f9;
}

.empty-state {
    text-align: center;
    color: #999;
    padding: 40px !important;
}

.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.status-badge.pending {
    background: #fff3cd;
    color: #856404;
}

.status-badge.win {
    background: #d4edda;
    color: #155724;
}

.status-badge.lose {
    background: #f8d7da;
    color: #721c24;
}

.action-btn {
    padding: 6px 12px;
    background: #3066ff;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 12px;
    cursor: pointer;
    transition: background 0.3s;
}

.action-btn:hover {
    background: #4d7aff;
}

/* 分页 */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-top: 30px;
}

.pagination-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 1px solid #e8e8e8;
    background: #fff;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s;
    color: #666;
}

.pagination-btn:hover:not(:disabled) {
    border-color: #3066ff;
    color: #3066ff;
}

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

.pagination-info {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #666;
}

.page-input {
    width: 60px;
    padding: 6px 8px;
    border: 1px solid #e8e8e8;
    border-radius: 4px;
    text-align: center;
    font-size: 14px;
}

.page-input:focus {
    outline: none;
    border-color: #3066ff;
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .stats-section {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .main-container {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        position: static;
    }
    
    .filter-row {
        flex-direction: column;
    }
    
    .filter-item {
        min-width: 100%;
    }
    
    .stats-section {
        grid-template-columns: 1fr;
    }
}

/* 期号单元格样式 */
.period-cell {
    padding: 12px 16px !important;
}

.period-number {
    font-size: 14px;
    color: #333;
    margin-bottom: 4px;
}

.period-time {
    font-size: 12px;
    color: #999;
}

/* 中奖情况样式 */
.win-info-pending {
    color: #666 !important;
}

.win-info-win {
    color: #ff4444 !important;
    font-weight: 500;
}

.win-info-lose {
    color: #07bf00 !important;
    font-weight: 500;
}

/* 确保表格中的中奖情况单元格也应用颜色 */
.data-table td.win-info-pending {
    color: #666 !important;
}

.data-table td.win-info-win {
    color: #ff4444 !important;
}

.data-table td.win-info-lose {
    color: #07bf00 !important;
}

/* 详情按钮 */
.btn-detail {
    background: #3066ff;
    color: #fff;
    border: none;
    padding: 6px 16px;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-detail:hover {
    background: #4d7aff;
}

/* 详情弹窗 */
.detail-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.detail-modal {
    background: #fff;
    border-radius: 8px;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

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

.detail-modal-title {
    font-size: 18px;
    font-weight: 600;
    color: #3066ff;
    margin: 0;
}

.detail-modal-close {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    transition: color 0.3s;
}

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

.detail-modal-body {
    padding: 20px;
}

.detail-lottery-name {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-bottom: 20px;
}

.detail-section {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.detail-row {
    display: flex;
    align-items: flex-start;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}

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

.detail-label {
    width: 100px;
    font-size: 14px;
    color: #666;
    flex-shrink: 0;
}

.detail-value {
    flex: 1;
    font-size: 14px;
    color: #333;
}

.detail-win-amount {
    color: #ff4444;
    font-weight: 600;
}

.detail-lose-amount {
    color: #07bf00;
    font-weight: 600;
}

.detail-bet-content {
    color: #3066ff;
    font-weight: 500;
}

.detail-result-text {
    color: #666;
}

.detail-result-numbers {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.result-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-size: 14px;
    font-weight: 500;
    color: #fff;
    background: #e8e8e8;
}

.result-number.red {
    background: #ff2600;
}

.result-number.blue {
    background: #0092dc;
}

.result-number.green {
    background: #07bf00;
}

.result-zodiac {
    font-size: 14px;
    color: #666;
    margin-left: 4px;
}

