/*
 * Cashback Pro V36.7.135 — softer default KPI colors + real animated header
 *
 * Base: V36.7.134.
 *
 * Fixes:
 * 1) The header looked static in landscape because previous revisions declared
 *    background-position with !important while trying to animate that same
 *    property in keyframes. Important declarations outrank CSS animations.
 *    This patch animates registered custom properties and feeds them into the
 *    important background-position value, so the movement remains effective.
 * 2) The four Default Light/Dark dashboard KPI cards keep their four distinct
 *    accents, but with softer, less saturated translucent gradients closer
 *    to the Welcome card.
 *
 * No markup changes, no ::before/::after plates, no element transforms.
 */

@property --v135-header-shift {
  syntax: "<percentage>";
  inherits: false;
  initial-value: 0%;
}

@property --v135-kpi-shift {
  syntax: "<percentage>";
  inherits: false;
  initial-value: 0%;
}

/* Header: apply to the real header element on portrait and landscape.
   The landscape rule is explicit because this is where the missing movement
   was reported. All children (logo, brand, mode control, account) remain as-is. */
html body header.app-header,
html body .app-header {
  --v135-header-shift: 0%;
  background-repeat: no-repeat !important;
  background-size: 260% 260%, 260% 260%, 280% 280% !important;
  background-position:
    var(--v135-header-shift) 0%,
    calc(100% - var(--v135-header-shift)) 100%,
    var(--v135-header-shift) 50% !important;
  animation: v367135HeaderGradient 24s ease-in-out infinite alternate !important;
  -webkit-backdrop-filter: blur(17px) saturate(132%) !important;
  backdrop-filter: blur(17px) saturate(132%) !important;
  will-change: background-position;
  isolation: isolate !important;
}

/* Explicit landscape binding keeps the animation active in the wide header
   layout as well as portrait layout. */
@media (orientation: landscape) {
  html body header.app-header,
  html body .app-header {
    animation-name: v367135HeaderGradient !important;
    animation-duration: 21s !important;
    animation-timing-function: ease-in-out !important;
    animation-iteration-count: infinite !important;
    animation-direction: alternate !important;
  }
}

/* DEFAULT LIGHT — distinct but soft pastel accents. */
html body.theme-default.default-light-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-cyan,
html body.default-light-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-cyan {
  color: #30445e !important;
  background:
    radial-gradient(ellipse 76% 116% at 5% 8%, rgba(74, 151, 205, .23), transparent 74%),
    radial-gradient(ellipse 78% 118% at 96% 92%, rgba(111, 171, 204, .18), transparent 74%),
    linear-gradient(118deg, rgba(158, 199, 232, .34), rgba(178, 204, 232, .31) 52%, rgba(153, 207, 202, .28)) !important;
  border-color: rgba(111, 151, 193, .37) !important;
  box-shadow: 0 8px 20px rgba(49, 75, 116, .065),
              inset 0 1px 0 rgba(255,255,255,.42) !important;
}
html body.theme-default.default-light-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-purple,
html body.default-light-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-purple {
  color: #30445e !important;
  background:
    radial-gradient(ellipse 76% 116% at 5% 8%, rgba(146, 108, 202, .22), transparent 74%),
    radial-gradient(ellipse 78% 118% at 96% 92%, rgba(111, 147, 205, .17), transparent 74%),
    linear-gradient(118deg, rgba(187, 165, 222, .33), rgba(173, 181, 224, .30) 52%, rgba(158, 193, 222, .27)) !important;
  border-color: rgba(133, 130, 190, .36) !important;
  box-shadow: 0 8px 20px rgba(60, 65, 112, .06),
              inset 0 1px 0 rgba(255,255,255,.42) !important;
}
html body.theme-default.default-light-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-blue,
html body.default-light-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-blue {
  color: #30445e !important;
  background:
    radial-gradient(ellipse 76% 116% at 5% 8%, rgba(91, 144, 210, .22), transparent 74%),
    radial-gradient(ellipse 78% 118% at 96% 92%, rgba(140, 124, 204, .17), transparent 74%),
    linear-gradient(118deg, rgba(160, 190, 231, .34), rgba(174, 181, 225, .30) 52%, rgba(165, 193, 222, .27)) !important;
  border-color: rgba(114, 142, 192, .36) !important;
  box-shadow: 0 8px 20px rgba(54, 70, 118, .06),
              inset 0 1px 0 rgba(255,255,255,.42) !important;
}
html body.theme-default.default-light-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-green,
html body.default-light-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-green {
  color: #30445e !important;
  background:
    radial-gradient(ellipse 76% 116% at 5% 8%, rgba(77, 164, 139, .21), transparent 74%),
    radial-gradient(ellipse 78% 118% at 96% 92%, rgba(94, 151, 203, .17), transparent 74%),
    linear-gradient(118deg, rgba(157, 207, 190, .33), rgba(164, 197, 214, .30) 52%, rgba(168, 185, 224, .27)) !important;
  border-color: rgba(103, 158, 154, .36) !important;
  box-shadow: 0 8px 20px rgba(49, 82, 102, .06),
              inset 0 1px 0 rgba(255,255,255,.42) !important;
}

/* DEFAULT DARK — keep the navy glass depth, but reduce the saturation/intensity
   of the cyan, purple, blue and green fills. The four hues remain distinct. */
html body.theme-default.default-dark-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-cyan,
html body.default-dark-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-cyan {
  color: #eaf2ff !important;
  background:
    radial-gradient(ellipse 76% 116% at 5% 8%, rgba(48, 139, 177, .25), transparent 74%),
    radial-gradient(ellipse 78% 118% at 96% 92%, rgba(91, 116, 183, .20), transparent 74%),
    linear-gradient(118deg, rgba(31, 78, 108, .56), rgba(30, 57, 91, .56) 52%, rgba(35, 53, 82, .53)) !important;
  border-color: rgba(112, 157, 190, .31) !important;
  box-shadow: 0 8px 21px rgba(0,0,0,.17),
              inset 0 1px 0 rgba(230,241,255,.07) !important;
}
html body.theme-default.default-dark-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-purple,
html body.default-dark-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-purple {
  color: #eaf2ff !important;
  background:
    radial-gradient(ellipse 76% 116% at 5% 8%, rgba(128, 89, 174, .25), transparent 74%),
    radial-gradient(ellipse 78% 118% at 96% 92%, rgba(84, 112, 177, .19), transparent 74%),
    linear-gradient(118deg, rgba(69, 48, 101, .55), rgba(43, 47, 86, .56) 52%, rgba(34, 52, 82, .52)) !important;
  border-color: rgba(145, 127, 190, .31) !important;
  box-shadow: 0 8px 21px rgba(0,0,0,.17),
              inset 0 1px 0 rgba(230,241,255,.07) !important;
}
html body.theme-default.default-dark-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-blue,
html body.default-dark-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-blue {
  color: #eaf2ff !important;
  background:
    radial-gradient(ellipse 76% 116% at 5% 8%, rgba(72, 124, 188, .24), transparent 74%),
    radial-gradient(ellipse 78% 118% at 96% 92%, rgba(105, 99, 174, .20), transparent 74%),
    linear-gradient(118deg, rgba(43, 73, 113, .56), rgba(39, 50, 91, .55) 52%, rgba(36, 51, 78, .52)) !important;
  border-color: rgba(124, 151, 194, .31) !important;
  box-shadow: 0 8px 21px rgba(0,0,0,.17),
              inset 0 1px 0 rgba(230,241,255,.07) !important;
}
html body.theme-default.default-dark-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-green,
html body.default-dark-mode #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi.kpi-green {
  color: #eaf2ff !important;
  background:
    radial-gradient(ellipse 76% 116% at 5% 8%, rgba(57, 139, 119, .23), transparent 74%),
    radial-gradient(ellipse 78% 118% at 96% 92%, rgba(76, 125, 174, .19), transparent 74%),
    linear-gradient(118deg, rgba(34, 82, 77, .55), rgba(29, 60, 79, .55) 52%, rgba(38, 51, 82, .52)) !important;
  border-color: rgba(105, 159, 148, .31) !important;
  box-shadow: 0 8px 21px rgba(0,0,0,.17),
              inset 0 1px 0 rgba(230,241,255,.07) !important;
}

/* Keep the existing title and refresh content untouched. Re-map the real
   animation positions through a registered percentage custom property.
   This fixes the conflict caused by legacy !important background-position. */
html body header.app-header,
html body .app-header {
  background-position:
    var(--v135-header-shift) 0%,
    calc(100% - var(--v135-header-shift)) 100%,
    var(--v135-header-shift) 50% !important;
  background-size: 260% 260%, 260% 260%, 280% 280% !important;
  animation-name: v367135HeaderGradient !important;
}

html body #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi {
  --v135-kpi-shift: 0%;
  background-position:
    var(--v135-kpi-shift) 0%,
    calc(100% - var(--v135-kpi-shift)) 100%,
    var(--v135-kpi-shift) 50% !important;
  background-size: 260% 260%, 260% 260%, 280% 280% !important;
  animation: v367135KpiGradient 25s ease-in-out infinite alternate !important;
}
html body #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi:nth-child(1) {
  animation-delay: 0s !important;
}
html body #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi:nth-child(2) {
  animation-delay: -6s !important;
}
html body #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi:nth-child(3) {
  animation-delay: -12s !important;
}
html body #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi:nth-child(4) {
  animation-delay: -18s !important;
}

@keyframes v367135HeaderGradient {
  from { --v135-header-shift: 0%; }
  to   { --v135-header-shift: 100%; }
}
@keyframes v367135KpiGradient {
  from { --v135-kpi-shift: 0%; }
  to   { --v135-kpi-shift: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html body header.app-header,
  html body .app-header,
  html body #seasonal-dashboard .seasonal-main .seasonal-kpis > article.seasonal-kpi {
    animation: none !important;
    will-change: auto !important;
  }
}
