/* Cashback V36.7.88 — Admin shell cleanup, date-filter frame removal, dashboard glow unclipping.
   This file only changes presentation wrappers. It does not modify application logic. */

/* 1) Admin layout wrappers are not cards. Keep the controls/cards inside them,
      but remove the extra translucent rectangle around the entire Admin area. */
html body #tab-admin > .admin-card,
html body #tab-admin > .admin-card:before,
html body #tab-admin > .admin-card:after {
  background: transparent !important;
  background-color: transparent !important;
  background-image: none !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
  padding: 0 !important;
  border-radius: 0 !important;
}

/* The sub-navigation wrapper was re-painted as a glass card by older landscape
   rules. Only its buttons should look like individual surfaces. */
html body #tab-admin .admin-subnav,
html body.default-light-mode #tab-admin .admin-subnav,
html body.theme-halloween:not(.default-light-mode) #tab-admin .admin-subnav,
html body.theme-winter:not(.default-light-mode) #tab-admin .admin-subnav,
html body.theme-ocean:not(.default-light-mode) #tab-admin .admin-subnav {
  background: transparent !important;
  background-color: transparent !important;
  background-image: none !important;
  border: 0 !important;
  border-bottom: 0 !important;
  border-radius: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
  padding: 0 0 10px !important;
}
html body #tab-admin .admin-subnav:before,
html body #tab-admin .admin-subnav:after {
  content: none !important;
  display: none !important;
  border: 0 !important;
  box-shadow: none !important;
}

/* Pane wrappers stay transparent. Real .admin-section-card, tables, forms,
   and each .admin-subnav-btn retain their own styling. */
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;
  outline: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
}

/* 2) Remove the outer rectangle around the customer withdrawal date/time
      filter row. The two datetime controls and action buttons remain rounded. */
html body.default-light-mode .customer-withdrawals-filters,
html body.theme-halloween:not(.default-light-mode) .customer-withdrawals-filters,
html body.theme-winter:not(.default-light-mode) .customer-withdrawals-filters,
html body.theme-ocean:not(.default-light-mode) .customer-withdrawals-filters {
  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;
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
  padding: 0 !important;
}

/* The Admin audit filter is also a layout row, not a card around the fields. */
html body #tab-admin .audit-filter-bar {
  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;
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
  padding: 0 !important;
}

/* 3) Dashboard cards and their light/shadow effects may extend beyond the main
      content box. The old overflow-x:clip on main.main-container cut those
      shadows at both edges. Keep horizontal scrolling confined to the orders
      table and retain body-level overflow protection from dashboard-premium. */
@media (max-width: 980px) {
  html body.dashboard-home main.main-container,
  html body.dashboard-home.sidebar-collapsed main.main-container,
  html body.dashboard-home.sidebar-expanded main.main-container {
    overflow-x: visible !important;
    overflow-y: visible !important;
  }
  html body.dashboard-home #seasonal-dashboard,
  html body.dashboard-home #seasonal-dashboard > .seasonal-main {
    overflow: visible !important;
  }
  html body.dashboard-home #seasonal-dashboard .dashboard-orders-scroll {
    overflow-x: auto !important;
    overflow-y: hidden !important;
    max-width: 100% !important;
  }
}


/* V36.7.89 — Restore the rounded outer shell around the Admin navigation.
   V36.7.88 flattened this wrapper too aggressively. Keep the main Admin
   content pane transparent, but restore one enclosing surface for the
   complete grouped Admin menu. */
html body #tab-admin > .admin-card > .admin-subnav {
  box-sizing: border-box !important;
  display: flex !important;
  flex-direction: column !important;
  width: 100% !important;
  padding: 18px !important;
  margin: 0 0 24px !important;
  border: 1px solid rgba(148,163,184,.34) !important;
  border-radius: 24px !important;
  outline: 0 !important;
  box-shadow: 0 12px 30px rgba(15,23,42,.10) !important;
  -webkit-backdrop-filter: blur(12px) saturate(118%) !important;
  backdrop-filter: blur(12px) saturate(118%) !important;
}
html body.default-light-mode #tab-admin > .admin-card > .admin-subnav {
  background: rgba(255,255,255,.88) !important;
  border-color: rgba(148,163,184,.34) !important;
  box-shadow: 0 10px 26px rgba(51,65,85,.08) !important;
}
html body.theme-halloween:not(.default-light-mode) #tab-admin > .admin-card > .admin-subnav {
  background: linear-gradient(145deg,rgba(63,39,82,.58),rgba(29,22,49,.62)) !important;
  border-color: rgba(205,174,245,.34) !important;
}
html body.theme-winter:not(.default-light-mode) #tab-admin > .admin-card > .admin-subnav {
  background: linear-gradient(145deg,rgba(34,75,116,.60),rgba(10,39,70,.64)) !important;
  border-color: rgba(160,205,245,.34) !important;
}
html body.theme-ocean:not(.default-light-mode) #tab-admin > .admin-card > .admin-subnav {
  background: linear-gradient(145deg,rgba(10,83,99,.60),rgba(4,43,62,.64)) !important;
  border-color: rgba(132,225,228,.34) !important;
}
@media (max-width: 640px) {
  html body #tab-admin > .admin-card > .admin-subnav {
    padding: 14px !important;
    border-radius: 22px !important;
    margin-bottom: 20px !important;
  }
}


/* V36.7.90 — compact Admin navigation: restore the enclosing rounded shell
   without letting the old flex-basis stretch each navigation tile vertically. */
html body #tab-admin > .admin-card > .admin-subnav {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: wrap !important;
  align-items: stretch !important;
  gap: 10px !important;
  padding: 16px !important;
  border-radius: 24px !important;
}
html body #tab-admin .admin-subnav > .admin-subnav-btn {
  box-sizing: border-box !important;
  flex: 1 1 190px !important;
  width: auto !important;
  min-width: 0 !important;
  min-height: 54px !important;
  height: auto !important;
  padding: 12px 16px !important;
  border-radius: 16px !important;
  justify-content: flex-start !important;
  align-items: center !important;
  white-space: normal !important;
  line-height: 1.25 !important;
}
@media (max-width: 640px) {
  html body #tab-admin > .admin-card > .admin-subnav {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 9px !important;
    padding: 13px !important;
    border-radius: 22px !important;
  }
  html body #tab-admin .admin-subnav > .admin-subnav-btn {
    width: 100% !important;
    min-height: 54px !important;
    padding: 10px 11px !important;
    justify-content: flex-start !important;
    font-size: clamp(12px, 3.4vw, 14px) !important;
  }
  html body #tab-admin .admin-subnav > .admin-subnav-btn:last-child:nth-child(odd) {
    grid-column: 1 / -1 !important;
  }
}

/* Month/year list: give taps visible feedback and keep it visually inside the picker. */
.cp-calendar-select-menu {
  z-index: 100520 !important;
  overscroll-behavior: contain !important;
  -webkit-overflow-scrolling: touch !important;
  animation: cp-period-menu-in .14s ease-out both !important;
}
.cp-calendar-select-option {
  cursor: pointer !important;
  touch-action: manipulation !important;
  transition: background .16s ease, border-color .16s ease, transform .12s ease, box-shadow .16s ease !important;
}
.cp-calendar-select-option:hover,
.cp-calendar-select-option:focus-visible {
  border-color: var(--purple, #8b5cf6) !important;
  background: color-mix(in srgb, var(--purple, #8b5cf6) 19%, var(--bg-surface-2, #202b43)) !important;
  outline: none !important;
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--purple, #8b5cf6) 22%, transparent) !important;
}
.cp-calendar-select-option:active { transform: scale(.985) !important; }
@keyframes cp-period-menu-in {
  from { opacity: 0; transform: translateY(-5px) scale(.99); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .cp-calendar-select-menu, .cp-calendar-select-option { animation: none !important; transition: none !important; }
}
