.pagedb-content {
    padding: 10px;
}
/* Thống kê giải đặc biệt theo tuần */
.statistics-filter {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    padding: 20px 10px;
    border-radius: 12px;
    margin-bottom: 25px;
    border: 1px solid #e9ecef;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    position: relative;
    overflow: hidden;
}

.statistics-filter .form-horizontal {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Hàng đầu tiên chứa 3 trường: Chọn tỉnh, Từ ngày, Đến ngày */
.filter-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 15px;
    align-items: end;
}

/* Hàng thứ hai chứa nút Xem kết quả */
.button-row {
    display: flex;
    justify-content: center;
    margin-top: 10px;
}

.statistics-filter .form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 0;
}

.statistics-filter .drp-container {
    position: relative;
}

.statistics-filter label {
    font-weight: 600;
    color: #495057;
    font-size: 14px;
    margin-bottom: 5px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
}

.statistics-filter label::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 30px;
    height: 2px;
    background: #dc3545;
    border-radius: 1px;
}

/* CSS cho input date và select */
.statistics-filter select,
.statistics-filter input[type="text"],
.statistics-filter input[type="date"] {
    padding: 12px 16px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    background: #ffffff;
    transition: all 0.3s ease;
    outline: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    width: 100%;
    font-family: inherit;
}

.statistics-filter select:focus,
.statistics-filter input[type="text"]:focus,
.statistics-filter input[type="date"]:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
    transform: translateY(-1px);
}

.statistics-filter select:hover,
.statistics-filter input[type="text"]:hover,
.statistics-filter input[type="date"]:hover {
    border-color: #ced4da;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Styling đặc biệt cho input date */
.statistics-filter input[type="date"] {
    cursor: pointer;
    position: relative;
    color: #495057;
}

.statistics-filter input[type="date"]::-webkit-calendar-picker-indicator {
    background: url('data:image/svg+xml;charset=US-ASCII,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23007bff"><path d="M19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11zM7 10h5v5H7z"/></svg>') no-repeat;
    background-size: 18px;
    width: 18px;
    height: 18px;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.statistics-filter input[type="date"]::-webkit-calendar-picker-indicator:hover {
    opacity: 1;
}

/* Firefox date input styling */
.statistics-filter input[type="date"]::-moz-focus-inner {
    border: 0;
}

/* Placeholder cho date input khi chưa chọn */
.statistics-filter input[type="date"]:invalid {
    color: #6c757d;
}

.statistics-filter input[type="date"]:valid {
    color: #495057;
}

.statistics-filter select {
    cursor: pointer;
    background-image: url('data:image/svg+xml;charset=US-ASCII,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 4 5"><path fill="%23666" d="M2 0L0 2h4zm0 5L0 3h4z"/></svg>');
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 12px;
    padding-right: 40px;
    appearance: none;
}

.statistics-filter .btn {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.3);
    position: relative;
    overflow: hidden;
    min-width: 150px;
}

.statistics-filter .btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.statistics-filter .btn:hover {
    background: linear-gradient(135deg, #c82333 0%, #a71e2a 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(220, 53, 69, 0.4);
}

.statistics-filter .btn:hover::before {
    left: 100%;
}

.statistics-filter .btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(220, 53, 69, 0.3);
}

/* Container cho date inputs */
.statistics-filter .field-statisticform-fromdate,
.statistics-filter .field-statisticform-todate {
    position: relative;
}

/* Responsive cho form */
@media (max-width: 992px) {
    .filter-row {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
    
    .filter-row .form-group:first-child {
        grid-column: 1 / -1;
        margin-bottom: 10px;
    }
}

@media (max-width: 768px) {
    .statistics-filter {
        padding: 20px;
    }
    
    .filter-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .statistics-filter select,
    .statistics-filter input[type="text"],
    .statistics-filter input[type="date"] {
        padding: 10px 14px;
        font-size: 16px; /* Tránh zoom trên mobile */
    }
    
    .statistics-filter .btn {
        padding: 12px 25px;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .statistics-filter {
        padding: 15px;
        margin-bottom: 20px;
    }
    
    .statistics-filter label {
        font-size: 13px;
    }
    
    .statistics-filter select,
    .statistics-filter input[type="text"],
    .statistics-filter input[type="date"] {
        padding: 10px 12px;
    }
    
    .statistics-filter input[type="date"]::-webkit-calendar-picker-indicator {
        background-size: 16px;
        width: 16px;
        height: 16px;
    }
}

/* Animation cho form khi load */
.statistics-filter {
    animation: slideInUp 0.6s ease-out;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hiệu ứng loading cho button */
.statistics-filter .btn.loading {
    pointer-events: none;
    opacity: 0.7;
}

.statistics-filter .btn.loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    margin: auto;
    border: 2px solid transparent;
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.btn-filter {
    background: #dc3545;
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.3s;
}

.btn-filter:hover {
    background: #c82333;
}

.statistics-summary {
    margin-bottom: 20px;
}

.bg_red {
    background: linear-gradient(135deg, #dc3545, #c82333);
    color: white;
}

.pad10-5 {
    padding: 10px;
    border-radius: 8px;
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    text-align: center;
}

/* Bảng thống kê */
.statistics-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.statistics-table thead {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
}

.statistics-table th {
    padding: 10px 6px;
    font-weight: 600;
    text-align: center;
    border: none;
    font-size: 14px;
}

.statistics-table td {
    padding: 6px;
    text-align: center;
    border-bottom: 1px solid #dee2e6;
    vertical-align: middle;
}

.statistics-table tbody tr:hover {
    background-color: #f8f9fa;
}

/* Styling cho các trạng thái */
.has-result {

}

.no-result {

}

.day-name {
    font-weight: 600;
    color: #495057;
}

.date-cell {
    font-size: 14px;
    color: #6c757d;
    color: black;
    font-weight: 600;
}

.special-prize .prize-number {
    font-size: 18px;
    font-weight: 700;
    color: #dc3545;
    background: #fff3cd;
    padding: 5px 10px;
    border-radius: 4px;
    border: 2px solid #ffc107;
}

.last-digits .highlight-digits {
    font-size: 16px;
    font-weight: 700;
    color: #007bff;
    background: #e3f2fd;
    padding: 4px 8px;
    border-radius: 4px;
    border: 1px solid #2196f3;
}

.no-data {
    color: #6c757d;
    font-style: italic;
}

.status-available {
    color: #28a745;
    font-weight: 600;
    background: #d4edda;
    padding: 4px 8px;
    border-radius: 4px;
    border: 1px solid #28a745;
}

.status-pending {
    color: #ffc107;
    font-weight: 600;
    background: #fff3cd;
    padding: 4px 8px;
    border-radius: 4px;
    border: 1px solid #ffc107;
}

/* Thống kê tổng hợp */
.summary-stats {
    background: #f8f9fa;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #dee2e6;
    margin-top: 20px;
}

.stats-row {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 20px;
}

.stat-item {
    text-align: center;
    padding: 15px;
    background: white;
    border-radius: 8px;
    border: 1px solid #dee2e6;
    min-width: 200px;
}

.stat-label {
    display: block;
    font-weight: 600;
    color: #495057;
    margin-bottom: 5px;
}

.stat-value {
    display: block;
    font-size: 18px;
    font-weight: 700;
    color: #007bff;
}

/* Responsive */
@media (max-width: 768px) {
    .statistics-filter .form-group {
        flex-direction: column;
        align-items: stretch;
    }
    
    .statistics-table {
        font-size: 12px;
    }
    
    .statistics-table th,
    .statistics-table td {
        padding: 8px 5px;
    }
    
    .special-prize .prize-number {
        font-size: 14px;
        padding: 3px 6px;
    }
    
    .last-digits .highlight-digits {
        font-size: 14px;
        padding: 3px 6px;
    }
    
    .stats-row {
        flex-direction: column;
    }
    
    .stat-item {
        min-width: auto;
    }
}

@media (max-width: 480px) {
    .statistics-table {
        font-size: 11px;
    }
    
    .pad10-5 {
        font-size: 16px;
        padding: 10px 15px;
    }
}

/* Styling cho cột Tổng */
.sum-total {
    font-weight: 600;
}

.sum-number {
    font-size: 16px;
    font-weight: 700;
    color: #28a745;
    background: #d4edda;
    padding: 4px 8px;
    border-radius: 4px;
    border: 1px solid #28a745;
    display: inline-block;
    min-width: 30px;
}

/* Hiệu ứng hover cho cột Tổng */
.sum-total:hover .sum-number {
    background: #c3e6cb;
    transform: scale(1.05);
    transition: all 0.2s ease;
}

/* Responsive cho cột Tổng */
@media (max-width: 768px) {
    .sum-number {
        font-size: 14px;
        padding: 3px 6px;
        min-width: 25px;
    }
}

@media (max-width: 480px) {
    .sum-number {
        font-size: 12px;
        padding: 2px 4px;
        min-width: 20px;
    }
}