/* =========================================================================
   OLX555 ADMIN PANEL - HIGH-END PROFESSIONAL THEME ENHANCEMENTS
   Inspired by MPO / Panelm Design System:
   - Crisp Poppins Typography
   - High Contrast, Legible Colors
   - Navy-themed Datatables
   - Clean LIGHT Theme for 5. Report Win / Lose (No Black Background)
   - Image 1 Date Select Dropdown & Full Monthly Days (1 to 30/31)
   - Clean Promotion Setting & Banner Components
   ========================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800&display=swap');

/* Base Typography & Antialiasing */
html, body, .content, .card, table, input, select, button, textarea, label {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    background-color: #f3f5f9 !important;
    color: #1e293b !important;
}

/* Subheader Clean Title */
#kt_subheader {
    background: #ffffff !important;
    border-bottom: 1px solid #e2e8f0 !important;
    padding: 14px 25px !important;
    min-height: 56px !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02) !important;
}

#kt_subheader h5 {
    color: #0f172a !important;
    font-size: 15px !important;
    font-weight: 700 !important;
    letter-spacing: -0.2px;
}

/* Card Improvements */
.card.card-custom {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 8px !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.04), 0 2px 4px -1px rgba(0, 0, 0, 0.02) !important;
}

.card.card-custom .card-header {
    background: #ffffff !important;
    border-bottom: 1px solid #edf2f7 !important;
    padding: 16px 24px !important;
}

.card.card-custom .card-header .card-title {
    font-size: 15px !important;
    font-weight: 700 !important;
    color: #0f172a !important;
}

/* Inputs & Form Controls */
.form-control, .form-control-sm {
    border: 1px solid #cbd5e1 !important;
    border-radius: 6px !important;
    color: #1e293b !important;
    font-size: 13px !important;
    transition: all 0.2s ease !important;
}

.form-control:focus, .form-control-sm:focus {
    border-color: #3b82f6 !important;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15) !important;
}

/* Buttons */
.btn {
    border-radius: 6px !important;
    font-weight: 600 !important;
    transition: all 0.2s ease !important;
}

.btn-primary {
    background-color: #2563eb !important;
    border-color: #2563eb !important;
    color: #ffffff !important;
}

.btn-primary:hover {
    background-color: #1d4ed8 !important;
    border-color: #1d4ed8 !important;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3) !important;
}

.btn-success {
    background-color: #10b981 !important;
    border-color: #10b981 !important;
    color: #ffffff !important;
}

.btn-success:hover {
    background-color: #059669 !important;
    border-color: #059669 !important;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3) !important;
}

/* =========================================================================
   LIGHT TABLES (Promotion List, Member List, Deposit List, etc.)
   Navy Header like MPO Panelm
   ========================================================================= */

.table-responsive {
    border-radius: 6px;
}

.table {
    border-collapse: separate !important;
    border-spacing: 0 !important;
    width: 100% !important;
}

/* Light Table Header - Dark Navy Bar */
#tablePromotionMaster thead tr,
#tablePromoContent thead tr,
.table-head-navy thead tr,
#memberListTable thead tr,
#tableDailyWinLose thead tr {
    background: #1a2638 !important;
    color: #ffffff !important;
}

#tablePromotionMaster thead th,
#tablePromoContent thead th,
.table-head-navy thead th,
#memberListTable thead th,
#tableDailyWinLose thead th {
    background: #1a2638 !important;
    color: #ffffff !important;
    font-size: 11.5px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.3px !important;
    padding: 12px 14px !important;
    border: none !important;
    border-bottom: 2px solid #0f172a !important;
}

/* Table Rows */
#tablePromotionMaster tbody tr,
#tablePromoContent tbody tr,
#memberListTable tbody tr,
#tableDailyWinLose tbody tr {
    transition: background 0.15s ease;
}

#tablePromotionMaster tbody tr:hover,
#tablePromoContent tbody tr:hover,
#memberListTable tbody tr:hover,
#tableDailyWinLose tbody tr:hover {
    background: #f1f5f9 !important;
}

#tablePromotionMaster tbody td,
#tablePromoContent tbody td,
#memberListTable tbody td,
#tableDailyWinLose tbody td {
    padding: 11px 14px !important;
    font-size: 12.5px !important;
    color: #1e293b !important;
    vertical-align: middle !important;
    border-color: #e2e8f0 !important;
}

/* Badges */
.badge-active, .badge-success-pill {
    background-color: #10b981 !important;
    color: #ffffff !important;
    font-weight: 700 !important;
    font-size: 11px !important;
    padding: 4px 10px !important;
    border-radius: 4px !important;
    display: inline-block;
    text-transform: uppercase;
}

.badge-inactive, .badge-danger-pill {
    background-color: #ef4444 !important;
    color: #ffffff !important;
    font-weight: 700 !important;
    font-size: 11px !important;
    padding: 4px 10px !important;
    border-radius: 4px !important;
    display: inline-block;
    text-transform: uppercase;
}

/* =========================================================================
   5. REPORT WIN / LOSE - CLEAN LIGHT MODERN THEME (NO BLACK BACKGROUND)
   Matching User Screenshot 1 & 2
   ========================================================================= */

.rep-light-panel {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 8px !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04) !important;
    overflow: hidden !important;
}

.rep-light-header {
    background: #ffffff !important;
    border-bottom: 1px solid #edf2f7 !important;
    padding: 18px 24px !important;
}

/* Date Range Input Group (Matching Image 1) */
.rep-date-input-group {
    width: 260px;
    cursor: pointer;
}

.rep-date-input-group input {
    background: #ffffff !important;
    color: #1e293b !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    border: 1px solid #cbd5e1 !important;
    border-right: none !important;
    border-radius: 6px 0 0 6px !important;
    cursor: pointer !important;
    height: 38px !important;
}

.rep-date-input-group .input-group-text {
    background: #f8fafc !important;
    border: 1px solid #cbd5e1 !important;
    border-left: none !important;
    border-radius: 0 6px 6px 0 !important;
    color: #64748b !important;
    cursor: pointer !important;
    height: 38px !important;
}

/* Dropdown Menu (Image 1 Style) */
#dateSelectDropdownMenu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    z-index: 1050;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
    padding: 6px 0;
    margin-top: 4px;
}

#dateSelectDropdownMenu .dropdown-item {
    font-size: 13px;
    font-weight: 600;
    color: #475569;
    padding: 8px 18px;
    transition: all 0.15s ease;
    display: block;
    text-decoration: none;
}

#dateSelectDropdownMenu .dropdown-item:hover {
    background-color: #f1f5f9;
    color: #2563eb;
}

#dateSelectDropdownMenu .dropdown-item.active {
    color: #2563eb !important;
    background-color: #eff6ff !important;
    font-weight: 700;
}

/* Top KPI Cards in Header */
.rep-kpi-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 8px 16px;
    display: inline-flex;
    flex-direction: column;
    min-width: 140px;
}

.rep-kpi-card .kpi-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: 2px;
}

.rep-kpi-card .kpi-val {
    font-size: 15px;
    font-weight: 800;
    letter-spacing: -0.2px;
}

.rep-kpi-card.kpi-deposit {
    background: #f0fdf4;
    border-color: #bbf7d0;
}
.rep-kpi-card.kpi-deposit .kpi-val {
    color: #15803d;
}

.rep-kpi-card.kpi-withdraw {
    background: #fef2f2;
    border-color: #fecaca;
}
.rep-kpi-card.kpi-withdraw .kpi-val {
    color: #b91c1c;
}

.rep-kpi-card.kpi-winlose {
    background: #eff6ff;
    border-color: #bfdbfe;
}
.rep-kpi-card.kpi-winlose .kpi-val {
    color: #1d4ed8;
}

/* Interactive Custom Date Range Popover */
#datePickerDropdownPanel {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 1050;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
    padding: 16px;
    width: 320px;
    margin-top: 6px;
    color: #1e293b;
}

#datePickerDropdownPanel label {
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    margin-bottom: 5px;
    display: block;
    text-transform: uppercase;
}

#datePickerDropdownPanel input[type="date"] {
    background: #f8fafc;
    color: #1e293b;
    border: 1px solid #cbd5e1;
    padding: 7px 10px;
    border-radius: 5px;
    font-size: 12px;
    width: 100%;
    outline: none;
}

#datePickerDropdownPanel input[type="date"]:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.2);
}

/* Table Daily Win / Lose (LIGHT THEME) */
#tableDailyWinLose {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    width: 100% !important;
}

#tableDailyWinLose thead th {
    background: #1a2638 !important;
    color: #ffffff !important;
    border: none !important;
    border-bottom: 2px solid #0f172a !important;
    font-weight: 700 !important;
    font-size: 11.5px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.3px !important;
    padding: 12px 14px !important;
    user-select: none;
}

#tableDailyWinLose thead th:hover {
    background: #223249 !important;
    color: #38bdf8 !important;
}

#tableDailyWinLose tbody tr:nth-child(odd) {
    background: #ffffff !important;
}

#tableDailyWinLose tbody tr:nth-child(even) {
    background: #f8fafc !important;
}

#tableDailyWinLose tbody tr:hover {
    background: #f1f5f9 !important;
}

#tableDailyWinLose tbody td {
    border: none !important;
    border-bottom: 1px solid #e2e8f0 !important;
    border-right: 1px solid #edf2f7 !important;
    padding: 10px 14px !important;
    font-size: 12.5px !important;
    vertical-align: middle !important;
    color: #1e293b !important;
}

/* Light Cell Accents */
#tableDailyWinLose tbody td.cell-date {
    border-left: 3px solid #2563eb !important;
    font-weight: 700 !important;
    color: #0f172a !important;
    letter-spacing: 0.2px;
}

#tableDailyWinLose tbody td.cell-amount {
    color: #0f172a !important;
    font-weight: 600 !important;
}

#tableDailyWinLose tbody td.cell-average {
    color: #64748b !important;
    font-size: 11.5px !important;
}

#tableDailyWinLose tbody td.cell-winrate {
    color: #059669 !important;
    font-weight: 800 !important;
    font-size: 12.5px !important;
}

#tableDailyWinLose tbody td.cell-winlose {
    color: #2563eb !important;
    font-weight: 700 !important;
}

/* =========================================================================
   PROMOTION FORM & BANNER ENHANCEMENTS
   ========================================================================= */

.promo-rules-card {
    background: #ffffff;
    border: 1.5px solid #e11d48;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(225, 29, 72, 0.08);
}

.promo-rules-title {
    color: #e11d48;
    font-weight: 700;
    font-size: 13.5px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.promo-rules-list {
    color: #e11d48;
    font-size: 12px;
    margin-bottom: 16px;
    padding-left: 18px;
    line-height: 1.6;
}

.promo-rules-list li {
    margin-bottom: 4px;
}

/* =========================================================================
   CRISP HIGH-CONTRAST ADMIN TABLES (3.3 Banner, 3.2 Promosi, 9. Memo, etc.)
   ========================================================================= */
.olx-admin-view table.table thead th {
    background: #1a2638 !important;
    color: #ffffff !important;
    font-size: 12.5px !important;
    font-weight: 700 !important;
    letter-spacing: 0.4px !important;
    padding: 13px 12px !important;
    text-transform: uppercase !important;
    border-color: #26354d !important;
    vertical-align: middle !important;
}

.olx-admin-view table.table tbody td {
    font-size: 13.5px !important;
    font-weight: 600 !important;
    color: #0f172a !important;
    padding: 11px 12px !important;
    vertical-align: middle !important;
    border-color: #e2e8f0 !important;
    line-height: 1.45 !important;
}

.olx-admin-view table.table tbody td.text-muted,
.olx-admin-view table.table tbody td .text-muted,
.olx-admin-view table.table tbody td.font-size-xs,
.olx-admin-view table.table tbody td .font-size-xs {
    font-size: 13px !important;
    color: #1e293b !important;
    font-weight: 600 !important;
    opacity: 1 !important;
}

.olx-admin-view table.table tbody td.text-primary,
.olx-admin-view table.table tbody td a.text-primary {
    color: #1d4ed8 !important;
    font-weight: 700 !important;
    font-size: 13px !important;
}

.olx-admin-view table.table tbody tr:nth-child(even) {
    background-color: #f8fafc !important;
}

.olx-admin-view table.table tbody tr:hover {
    background-color: #e2e8f0 !important;
}

.olx-pos-ctrl {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 3px 6px;
}

.olx-pos-num {
    min-width: 24px;
    text-align: center;
    font-size: 13.5px !important;
    font-weight: 800 !important;
    color: #0f172a !important;
}

.olx-pos-btn {
    width: 22px;
    height: 22px;
    padding: 0;
    border: 1px solid #94a3b8;
    background: #ffffff;
    color: #1e293b;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}

.olx-pos-btn:hover {
    background: #1a2638;
    color: #ffffff;
    border-color: #1a2638;
}

/* =========================================================================
   PANELM-INSPIRED PAGE CONTENT & WEB SETTING STYLES
   ========================================================================= */
.olx-panelm-filter-bar {
    background: #1a2638;
    border-radius: 8px;
    padding: 18px 24px;
    margin-bottom: 18px;
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.12);
}

.olx-panelm-filter-bar label {
    color: #e2e8f0 !important;
    font-size: 12.5px !important;
    font-weight: 600 !important;
    margin-bottom: 6px !important;
}

.olx-panelm-tabs {
    border-bottom: 2px solid #e2e8f0;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 0 24px;
    background: #ffffff;
}

.olx-panelm-tab-btn {
    padding: 13px 20px;
    font-size: 13.5px;
    font-weight: 600;
    color: #64748b;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: -2px;
    transition: all 0.18s ease;
}

.olx-panelm-tab-btn:hover {
    color: #1e293b;
}

.olx-panelm-tab-btn.active {
    color: #2563eb;
    border-bottom-color: #2563eb;
    font-weight: 700;
}

.olx-rte-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px;
    padding: 8px 12px;
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-bottom: none;
    border-radius: 6px 6px 0 0;
}

.olx-rte-btn {
    padding: 5px 10px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    color: #1e293b;
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease;
}

.olx-rte-btn:hover {
    background: #1a2638;
    color: #ffffff;
    border-color: #1a2638;
}

.olx-rte-editor {
    min-height: 280px;
    max-height: 520px;
    overflow-y: auto;
    padding: 16px 18px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 0 0 6px 6px;
    color: #0f172a;
    font-size: 14px;
    line-height: 1.65;
    outline: none;
}

.olx-rte-editor:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}
