/* SERBUNIB V13: visual-only contrast correction, follows V12.
   Preserves chart colors, chart data, navigation, filters, and form layout. */

/* HOME: more expressive blue/cyan gradient while keeping existing white cards. */
html body:not(.dark-mode):not(.dark):not([data-theme="dark"]):not(:has(.auth-layout)) {
  background-color: #d8eafc !important;
  background-image:
    radial-gradient(ellipse 520px 420px at -5% 8%, rgba(24, 112, 207, .35) 0%, transparent 74%),
    radial-gradient(ellipse 610px 520px at 105% 18%, rgba(0, 165, 208, .29) 0%, transparent 74%),
    radial-gradient(ellipse 550px 440px at 66% 65%, rgba(86, 118, 224, .21) 0%, transparent 75%),
    radial-gradient(ellipse 390px 350px at 10% 95%, rgba(14, 154, 192, .24) 0%, transparent 77%),
    linear-gradient(145deg, #dceefe 0%, #e8f4ff 34%, #d3e7fb 66%, #e6f5ff 100%) !important;
  background-attachment: fixed !important;
  background-repeat: no-repeat !important;
}

/* Home header in screenshot blended into pale-blue background. */
html body:not(.dark-mode):not(.dark):not([data-theme="dark"]):not(:has(.auth-layout)) .navbar .navbar-brand,
html body:not(.dark-mode):not(.dark):not([data-theme="dark"]):not(:has(.auth-layout)) .navbar .app-title,
html body:not(.dark-mode):not(.dark):not([data-theme="dark"]):not(:has(.auth-layout)) .navbar .navbar-brand i {
  color: #084b87 !important;
  text-shadow: 0 1px 0 rgba(255,255,255,.55);
}

/* AUTH: ensure text on dark blue hero always meets readable contrast. */
html body .auth-layout .intro,
html body .auth-layout .intro h1,
html body .auth-layout .intro h2,
html body .auth-layout .intro .crest,
html body .auth-layout .intro .crest *,
html body .auth-layout .intro strong,
html body .auth-layout .intro a {
  color: #fff !important;
  -webkit-text-fill-color: #fff;
  opacity: 1 !important;
}
html body .auth-layout .intro h1 {
  text-shadow: 0 3px 18px rgba(1, 24, 60, .18);
}
html body .auth-layout .intro p,
html body .auth-layout .intro small,
html body .auth-layout .intro li {
  color: #e8f5ff !important;
  -webkit-text-fill-color: #e8f5ff;
  opacity: 1 !important;
}
html body .auth-layout .intro .crest {
  letter-spacing: .14em;
  font-weight: 800;
}
html body .auth-layout .intro {
  background:
    radial-gradient(circle 380px at 100% 8%, rgba(105, 196, 248, .26), transparent 78%),
    radial-gradient(circle 330px at 1% 91%, rgba(58, 146, 232, .24), transparent 76%),
    linear-gradient(138deg, #092c59 0%, #0d5089 48%, #167db5 100%) !important;
}
html body .auth-layout .panel {
  background:
    radial-gradient(circle 360px at 105% 5%, rgba(46, 163, 220, .24), transparent 80%),
    radial-gradient(circle 300px at 3% 100%, rgba(72, 111, 219, .16), transparent 82%),
    linear-gradient(145deg,#e7f2fe 0%,#f3f9ff 58%,#dceefe 100%) !important;
}
html body .auth-layout .card {
  border-color: rgba(67,137,205,.24);
  box-shadow: 0 24px 55px rgba(16,71,122,.17);
}

/* Never override chart canvas/dataset colors, widget foreground, or graph palettes. */
@media (max-width: 840px) {
  html body:not(.dark-mode):not(.dark):not([data-theme="dark"]) { background-attachment: scroll !important; }
  html body .auth-layout .intro h1 { text-shadow: 0 2px 10px rgba(1,24,60,.16); }
}
@media (prefers-color-scheme: dark) {
  html body .auth-layout .panel { background: linear-gradient(145deg,#12263a,#172e46) !important; }
}
/* Follow app dark-mode controls: don't force light home background on dark theme. */
