/*
 * Cashback Pro V36.7.116 — Light Mode Cascade Repair
 *
 * Diagnosis from the supplied screen recording:
 * - V36.7.78 and V36.7.83 contain !important white backgrounds and
 *   background-image:none rules.
 * - Some of those selectors include html body.theme-default.default-light-mode
 *   or .tab-content descendants, giving them greater specificity than the
 *   V36.7.112/V36.7.114 light-glass rules.
 * - Therefore the previous gradient sheet existed but lost the cascade on
 *   key page wrappers and nested surfaces.
 *
 * This stylesheet is loaded AFTER every previous stylesheet and uses matching
 * high-specificity selectors for the built-in Default Light mode only.
 * Seasonal and uploaded themes are not affected.
 */

/* ---------- Root canvas: also cover the early bootstrap state ---------- */
html.theme-bootstrap-light {
  color-scheme: light !important;
  background-color: #e8f0fc !important;
  background-image:
    radial-gradient(ellipse at 8% 10%, rgba(105, 157, 224, .34) 0%, transparent 36%),
    radial-gradient(ellipse at 92% 18%, rgba(178, 139, 226, .30) 0%, transparent 39%),
    radial-gradient(ellipse at 52% 96%, rgba(89, 183, 175, .23) 0%, transparent 43%),
    linear-gradient(128deg, #e8f1fc 0%, #f0eafa 48%, #e6f4f2 100%) !important;
  background-attachment: fixed !important;
  background-size: 160% 160%, 160% 160%, 160% 160%, 180% 180% !important;
  animation: v367116PearlCanvas 30s ease-in-out infinite alternate !important;
}

html.theme-bootstrap-light body,
html.theme-bootstrap-light body.theme-default,
html.theme-bootstrap-light body.theme-default.default-light-mode,
html body.theme-default.default-light-mode {
  color-scheme: light !important;
  color: #26364d !important;
  background-color: #e8f0fc !important;
  background-image:
    radial-gradient(ellipse at 8% 10%, rgba(105, 157, 224, .34) 0%, transparent 36%),
    radial-gradient(ellipse at 92% 18%, rgba(178, 139, 226, .30) 0%, transparent 39%),
    radial-gradient(ellipse at 52% 96%, rgba(89, 183, 175, .23) 0%, transparent 43%),
    linear-gradient(128deg, #e8f1fc 0%, #f0eafa 48%, #e6f4f2 100%) !important;
  background-attachment: fixed !important;
  background-size: 160% 160%, 160% 160%, 160% 160%, 180% 180% !important;
  animation: v367116PearlCanvas 30s ease-in-out infinite alternate !important;
}

@keyframes v367116PearlCanvas {
  0% {
    background-position: 0% 0%, 100% 10%, 42% 100%, 0% 0%;
  }
  100% {
    background-position: 100% 65%, 0% 85%, 100% 0%, 100% 100%;
  }
}

/* ---------- Structural layers: remove legacy opaque white paint ---------- */
html.theme-bootstrap-light body .main-container,
html.theme-bootstrap-light body main,
html.theme-bootstrap-light body .tab-content,
html.theme-bootstrap-light body .tab-content.active,
html.theme-bootstrap-light body .main-content,
html.theme-bootstrap-light body .page-content,
html.theme-bootstrap-light body #tab-finance,
html.theme-bootstrap-light body #tab-orders,
html.theme-bootstrap-light body #tab-converter,
html.theme-bootstrap-light body #tab-profile,
html.theme-bootstrap-light body #tab-support,
html.theme-bootstrap-light body #tab-admin,
html.theme-bootstrap-light body .admin-pane,
html.theme-bootstrap-light body .admin-pane.active,
html body.theme-default.default-light-mode .main-container,
html body.theme-default.default-light-mode main,
html body.theme-default.default-light-mode .tab-content,
html body.theme-default.default-light-mode .tab-content.active,
html body.theme-default.default-light-mode .main-content,
html body.theme-default.default-light-mode .page-content,
html body.theme-default.default-light-mode #tab-finance,
html body.theme-default.default-light-mode #tab-orders,
html body.theme-default.default-light-mode #tab-converter,
html body.theme-default.default-light-mode #tab-profile,
html body.theme-default.default-light-mode #tab-support,
html body.theme-default.default-light-mode #tab-admin,
html body.theme-default.default-light-mode .admin-pane,
html body.theme-default.default-light-mode .admin-pane.active {
  background: transparent !important;
  background-color: transparent !important;
  background-image: none !important;
  color: #26364d !important;
}

/* ---------- All common content cards, with enough tint to SEE the gradient ---------- */
html.theme-bootstrap-light body .main-container .tab-content :is(
  .glass-panel, .modal-card, .seasonal-kpi, .seasonal-orders,
  .balance-card, .finance-card, .withdrawal-card, .bank-management-card,
  .customer-withdrawals-card, .customer-withdrawals-filters,
  .profile-page-card, .converter-card, .table-card, .kpi-card,
  .ai-copilot-box, .admin-section-card, .section-card, .content-card,
  .filter-card, .order-card, .support-card, .commission-card,
  .admin-access-card, .marketplace-list-card, .kb-upload-panel,
  .inbox-split, .result-box, .guidance-box, .admin-card,
  .backup-content-card, .marketplace-editor, .customer-create-user-card,
  .bank-admin-section, .backup-update-panel, .customer-admin-inner-pane,
  .audit-filter-bar, .audit-log-frame, .document-card, .doc-card,
  .card, .panel, .dashboard-card, .info-card, .stat-card, .summary-card,
  .panel-card, .content-panel, .admin-panel, .settings-card, .bank-card,
  .customer-card, .order-panel, .withdraw-panel, .ai-panel,
  .knowledge-card, .support-panel, .profile-card, .history-card
),
html body.theme-default.default-light-mode .main-container .tab-content :is(
  .glass-panel, .modal-card, .seasonal-kpi, .seasonal-orders,
  .balance-card, .finance-card, .withdrawal-card, .bank-management-card,
  .customer-withdrawals-card, .customer-withdrawals-filters,
  .profile-page-card, .converter-card, .table-card, .kpi-card,
  .ai-copilot-box, .admin-section-card, .section-card, .content-card,
  .filter-card, .order-card, .support-card, .commission-card,
  .admin-access-card, .marketplace-list-card, .kb-upload-panel,
  .inbox-split, .result-box, .guidance-box, .admin-card,
  .backup-content-card, .marketplace-editor, .customer-create-user-card,
  .bank-admin-section, .backup-update-panel, .customer-admin-inner-pane,
  .audit-filter-bar, .audit-log-frame, .document-card, .doc-card,
  .card, .panel, .dashboard-card, .info-card, .stat-card, .summary-card,
  .panel-card, .content-panel, .admin-panel, .settings-card, .bank-card,
  .customer-card, .order-panel, .withdraw-panel, .ai-panel,
  .knowledge-card, .support-panel, .profile-card, .history-card
),
html body.theme-default.default-light-mode .seasonal-dashboard :is(
  .seasonal-welcome, .seasonal-shortcuts, .seasonal-kpi, .seasonal-orders,
  .dashboard-card, .stat-card, .glass-panel, .card, .panel
) {
  color: #26364d !important;
  background: linear-gradient(
    132deg,
    rgba(221, 235, 252, .88) 0%,
    rgba(233, 226, 250, .82) 52%,
    rgba(216, 240, 237, .82) 100%
  ) !important;
  background-color: rgba(226, 237, 251, .82) !important;
  background-image:
    radial-gradient(ellipse at 0% 0%, rgba(96, 153, 226, .26), transparent 55%),
    radial-gradient(ellipse at 100% 100%, rgba(171, 133, 224, .23), transparent 56%),
    linear-gradient(132deg, rgba(221,235,252,.88) 0%, rgba(233,226,250,.82) 52%, rgba(216,240,237,.82) 100%) !important;
  background-size: 160% 160%, 160% 160%, 180% 180% !important;
  background-position: 0% 0%, 100% 100%, 0% 0% !important;
  border-color: rgba(113, 143, 188, .38) !important;
  box-shadow:
    0 10px 28px rgba(48, 74, 116, .10),
    inset 0 1px 0 rgba(255, 255, 255, .72) !important;
  -webkit-backdrop-filter: blur(16px) saturate(138%) !important;
  backdrop-filter: blur(16px) saturate(138%) !important;
  animation: v367116CardPearlDrift 32s ease-in-out infinite alternate;
}

@keyframes v367116CardPearlDrift {
  0% { background-position: 0% 0%, 100% 100%, 0% 0%; }
  100% { background-position: 100% 45%, 0% 65%, 100% 100%; }
}

/* Admin has several ID-scoped legacy white panels: beat those selectors too. */
html.theme-bootstrap-light body #tab-admin :is(
  .admin-nav-shell, .admin-subnav, .admin-pane, .admin-card,
  .admin-section-card, .admin-access-card, .backup-update-subnav,
  .backup-update-panel, .backup-content-card, .marketplace-editor,
  .customer-admin-subnav, .customer-admin-inner-pane, .audit-filter-bar,
  .audit-log-frame, .table-card, .inbox-split, .bank-admin-section
),
html body.theme-default.default-light-mode #tab-admin :is(
  .admin-nav-shell, .admin-subnav, .admin-pane, .admin-card,
  .admin-section-card, .admin-access-card, .backup-update-subnav,
  .backup-update-panel, .backup-content-card, .marketplace-editor,
  .customer-admin-subnav, .customer-admin-inner-pane, .audit-filter-bar,
  .audit-log-frame, .table-card, .inbox-split, .bank-admin-section
) {
  color: #26364d !important;
  background-color: rgba(226, 237, 251, .82) !important;
  background-image:
    radial-gradient(ellipse at 0% 0%, rgba(96,153,226,.25), transparent 55%),
    radial-gradient(ellipse at 100% 100%, rgba(171,133,224,.22), transparent 56%),
    linear-gradient(132deg, rgba(221,235,252,.87), rgba(233,226,250,.82) 52%, rgba(216,240,237,.82)) !important;
  border-color: rgba(113,143,188,.38) !important;
  box-shadow: 0 10px 28px rgba(48,74,116,.09), inset 0 1px 0 rgba(255,255,255,.72) !important;
  -webkit-backdrop-filter: blur(16px) saturate(138%) !important;
  backdrop-filter: blur(16px) saturate(138%) !important;
}

/* ---------- Tables: avoid opaque white body cells over the new surfaces ---------- */
html.theme-bootstrap-light body .tab-content table,
html body.theme-default.default-light-mode .tab-content table {
  background: rgba(229, 239, 252, .56) !important;
}
html.theme-bootstrap-light body .tab-content table th,
html body.theme-default.default-light-mode .tab-content table th {
  color: #2c3e59 !important;
  background: linear-gradient(120deg, rgba(190, 211, 243, .92), rgba(218, 202, 244, .90), rgba(190, 225, 224, .90)) !important;
  border-color: rgba(125, 148, 188, .35) !important;
}
html.theme-bootstrap-light body .tab-content table td,
html body.theme-default.default-light-mode .tab-content table td {
  color: #354963 !important;
  background: rgba(229, 239, 252, .48) !important;
  border-color: rgba(136, 159, 196, .25) !important;
}
html.theme-bootstrap-light body .tab-content table tbody tr:nth-child(even) td,
html body.theme-default.default-light-mode .tab-content table tbody tr:nth-child(even) td {
  background: rgba(215, 228, 248, .42) !important;
}

/* ---------- Inputs stay clear; keep legibility and control states ---------- */
html.theme-bootstrap-light body .tab-content input:not([type="checkbox"]):not([type="radio"]),
html.theme-bootstrap-light body .tab-content select,
html.theme-bootstrap-light body .tab-content textarea,
html body.theme-default.default-light-mode .tab-content input:not([type="checkbox"]):not([type="radio"]),
html body.theme-default.default-light-mode .tab-content select,
html body.theme-default.default-light-mode .tab-content textarea {
  color: #26364d !important;
  background: linear-gradient(135deg, rgba(255,255,255,.94), rgba(235,243,253,.90)) !important;
  border-color: rgba(124, 150, 190, .42) !important;
}

/* Text remains crisp and readable on the stronger pastel glass surfaces. */
html body.theme-default.default-light-mode .tab-content h1,
html body.theme-default.default-light-mode .tab-content h2,
html body.theme-default.default-light-mode .tab-content h3,
html body.theme-default.default-light-mode .tab-content h4,
html body.theme-default.default-light-mode .tab-content label,
html body.theme-default.default-light-mode .tab-content strong,
html body.theme-default.default-light-mode .admin-pane h2,
html body.theme-default.default-light-mode .admin-pane h3 {
  color: #26364d !important;
  text-shadow: none !important;
}

@media (prefers-reduced-motion: reduce) {
  html.theme-bootstrap-light,
  html.theme-bootstrap-light body,
  html body.theme-default.default-light-mode,
  html body.theme-default.default-light-mode * {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
  }
}
