/* Cashback V36.7.86 (continuation of V36.7.85 scoped glass repair)
   Root-cause repair: remove the light-mode backdrop gradient at its source,
   flatten all Admin tab shells (not their inner cards), and use one shared
   frosted-glass treatment for the seasonal date/time picker. */

/* 1) LIGHT MODE ROOT: use a plain canvas, not a grey gradient beneath a white card. */
html.theme-bootstrap-light,
html body.default-light-mode {
  background: #ffffff !important;
  background-color: #ffffff !important;
  background-image: none !important;
}
body.default-light-mode,
body.theme-default.default-light-mode {
  background: #ffffff !important;
  background-color: #ffffff !important;
  background-image: none !important;
  --bg-dark: #ffffff !important;
  --bg-surface: #ffffff !important;
  --bg-surface-2: #f7f9fc !important;
  --bg-card: #ffffff !important;
}
body.default-light-mode::before,
body.default-light-mode.dashboard-home::before {
  content: none !important;
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  background: none !important;
}
body.default-light-mode .halloween-ambient-layer,
body.default-light-mode .theme-ambient-fx {
  display: none !important;
  opacity: 0 !important;
  background: none !important;
}
body.default-light-mode .main-container,
body.default-light-mode .tab-content,
body.default-light-mode .tab-content.active {
  background: transparent !important;
  background-color: transparent !important;
  background-image: none !important;
}

/* 2) ADMIN: .admin-pane is a layout wrapper, not a card.
   Remove its rectangular surface from every Admin subsection/theme. Inner
   .admin-section-card, forms, tables and individual controls keep their own UI. */
html body #tab-admin > .admin-card > .admin-pane,
html body #tab-admin > .admin-card > .admin-pane.active,
html body #tab-admin .admin-pane,
html body #tab-admin .admin-pane.active {
  background: transparent !important;
  background-color: transparent !important;
  background-image: none !important;
  border: 0 !important;
  border-radius: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
}
html body #tab-admin .admin-pane::before,
html body #tab-admin .admin-pane::after {
  content: none !important;
  display: none !important;
  background: none !important;
  border: 0 !important;
  box-shadow: none !important;
}
/* The Admin permissions pane had a more-specific light-mode card rule. */
html body.default-light-mode #tab-admin #admin-pane-admins {
  background: transparent !important;
  background-color: transparent !important;
  background-image: none !important;
  border: 0 !important;
  border-radius: 0 !important;
  padding: 0 !important;
  box-shadow: none !important;
}

/* 3) SHARED SEASONAL DATE/TIME PICKER GLASS.
   Equal alpha and blur across Halloween, Winter and Underwater. The heading
   and content remain transparent so the panel's glass effect is visible. */
html body.theme-halloween:not(.default-light-mode) .cp-picker-panel,
html body.theme-winter:not(.default-light-mode) .cp-picker-panel,
html body.theme-ocean:not(.default-light-mode) .cp-picker-panel {
  -webkit-backdrop-filter: blur(20px) saturate(138%) !important;
  backdrop-filter: blur(20px) saturate(138%) !important;
  border: 1px solid rgba(190, 215, 245, .30) !important;
  box-shadow: 0 24px 64px rgba(0,0,0,.28), inset 0 1px 0 rgba(255,255,255,.12) !important;
}
html body.theme-halloween:not(.default-light-mode) .cp-picker-panel {
  background: linear-gradient(145deg, rgba(72,42,105,.64), rgba(20,18,48,.58)) !important;
  color: #f2edff !important;
}
html body.theme-winter:not(.default-light-mode) .cp-picker-panel {
  background: linear-gradient(145deg, rgba(44,105,160,.64), rgba(9,35,70,.58)) !important;
  color: #edf6ff !important;
}
html body.theme-ocean:not(.default-light-mode) .cp-picker-panel {
  background: linear-gradient(145deg, rgba(13,112,132,.64), rgba(3,43,65,.58)) !important;
  color: #e9fbff !important;
}
html body.theme-halloween:not(.default-light-mode) .cp-picker-head,
html body.theme-winter:not(.default-light-mode) .cp-picker-head,
html body.theme-ocean:not(.default-light-mode) .cp-picker-head {
  background: rgba(9,23,46,.20) !important;
  border-bottom-color: rgba(190,215,245,.22) !important;
}
html body.theme-halloween:not(.default-light-mode) .cp-picker-content,
html body.theme-winter:not(.default-light-mode) .cp-picker-content,
html body.theme-ocean:not(.default-light-mode) .cp-picker-content {
  background: transparent !important;
}


/* V36.7.86 — landscape Admin legibility.
   Keep the seasonal color tint, but avoid a heavy blur over the whole Admin
   workspace. The outer #tab-admin wrapper stays transparent; only true
   content surfaces receive a restrained glass layer. */
@media (orientation: landscape) and (max-height: 620px) {
  html body.theme-halloween:not(.default-light-mode) #tab-admin .admin-pane {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
  }
  html body.theme-winter:not(.default-light-mode) #tab-admin .admin-pane {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
  }
  html body.theme-ocean:not(.default-light-mode) #tab-admin .admin-pane {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
  }

  html body.theme-halloween:not(.default-light-mode) #tab-admin .admin-pane .admin-card,
  html body.theme-halloween:not(.default-light-mode) #tab-admin .admin-pane .admin-section-card,
  html body.theme-halloween:not(.default-light-mode) #tab-admin .backup-update-subnav,
  html body.theme-halloween:not(.default-light-mode) #tab-admin .backup-update-panel,
  html body.theme-halloween:not(.default-light-mode) #tab-admin .backup-toolbar,
  html body.theme-halloween:not(.default-light-mode) #tab-admin .admin-subnav {
    background: linear-gradient(145deg, rgba(57,39,80,.91), rgba(28,23,49,.93)) !important;
    -webkit-backdrop-filter: blur(5px) saturate(120%) !important;
    backdrop-filter: blur(5px) saturate(120%) !important;
    border-color: rgba(205,174,245,.28) !important;
  }
  html body.theme-winter:not(.default-light-mode) #tab-admin .admin-pane .admin-card,
  html body.theme-winter:not(.default-light-mode) #tab-admin .admin-pane .admin-section-card,
  html body.theme-winter:not(.default-light-mode) #tab-admin .backup-update-subnav,
  html body.theme-winter:not(.default-light-mode) #tab-admin .backup-update-panel,
  html body.theme-winter:not(.default-light-mode) #tab-admin .backup-toolbar,
  html body.theme-winter:not(.default-light-mode) #tab-admin .admin-subnav {
    background: linear-gradient(145deg, rgba(34,67,103,.91), rgba(12,35,62,.93)) !important;
    -webkit-backdrop-filter: blur(5px) saturate(120%) !important;
    backdrop-filter: blur(5px) saturate(120%) !important;
    border-color: rgba(160,205,245,.28) !important;
  }
  html body.theme-ocean:not(.default-light-mode) #tab-admin .admin-pane .admin-card,
  html body.theme-ocean:not(.default-light-mode) #tab-admin .admin-pane .admin-section-card,
  html body.theme-ocean:not(.default-light-mode) #tab-admin .backup-update-subnav,
  html body.theme-ocean:not(.default-light-mode) #tab-admin .backup-update-panel,
  html body.theme-ocean:not(.default-light-mode) #tab-admin .backup-toolbar,
  html body.theme-ocean:not(.default-light-mode) #tab-admin .admin-subnav {
    background: linear-gradient(145deg, rgba(10,76,91,.91), rgba(4,41,60,.93)) !important;
    -webkit-backdrop-filter: blur(5px) saturate(120%) !important;
    backdrop-filter: blur(5px) saturate(120%) !important;
    border-color: rgba(132,225,228,.28) !important;
  }
}
