/* ============================================================
   OHIF Theme Override — rule-ui.md palette
   Strategy: CSS variable override + Tailwind class overrides
   SAFE: does NOT touch viewer backgrounds (dark = intentional for radiology)
   ============================================================ */

:root {
  --brand-primary: #1E88E5;
  --brand-primary-dark: #1565C0;
  --brand-primary-soft: #EAF4FF;
  --brand-accent: #14B8A6;
  --brand-accent-soft: #E6FFFB;

  /* Override ui-next CSS variable system (HSL format)
     #1E88E5 = hsl(210, 77%, 51%)
     #1565C0 = hsl(211, 80%, 41%)
     #14B8A6 = hsl(174, 80%, 40%)  */
  --primary: 210 77% 51%;
  --secondary: 211 80% 41%;
  --highlight: 174 80% 40%;
  --ring: 210 77% 51%;

  /* Input focus glow */
  --input: 210 77% 51%;
}

/* ── Primary active/action color overrides ────────────────── */
/* Old: #348cfd / #348CFD → New: #1E88E5 */
.bg-primary-active    { background-color: #1E88E5 !important; }
.text-primary-active  { color: #1E88E5 !important; }
.border-primary-active{ border-color: #1E88E5 !important; }
.fill-primary-active  { fill: #1E88E5 !important; }

/* ── Actions primary color ────────────────────────────────── */
.bg-actions-primary    { background-color: #1E88E5 !important; }
.text-actions-primary  { color: #1E88E5 !important; }
.border-actions-primary{ border-color: #1E88E5 !important; }

/* ── Hover state (was rgba(52,140,253,0.2)) ───────────────── */
.bg-actions-hover { background-color: rgba(30, 136, 229, 0.15) !important; }

/* ── Accent / Highlight (cyan → teal) ────────────────────── */
/* Old: #5acce6 / #5ACCE6 → New: #14B8A6 */
.bg-actions-highlight    { background-color: #14B8A6 !important; }
.text-actions-highlight  { color: #14B8A6 !important; }
.border-actions-highlight{ border-color: #14B8A6 !important; }
.fill-actions-highlight  { fill: #14B8A6 !important; }

/* Old primary light (was #5acce6) */
.bg-primary-light    { background-color: #EAF4FF !important; }
.text-primary-light  { color: #1E88E5 !important; }

/* ── Input field focus ────────────────────────────────────── */
/* Old: #5acce6 → New: #1E88E5 */
.text-inputfield-focus  { color: #1E88E5 !important; }
.border-inputfield-focus{ border-color: #1E88E5 !important; }

/* ── Ring / focus ring ────────────────────────────────────── */
.ring-primary-active { --tw-ring-color: #1E88E5 !important; }
.ring-actions-primary{ --tw-ring-color: #1E88E5 !important; }

/* ── Primary main (was #0944b3) ───────────────────────────── */
.bg-primary-main   { background-color: #1565C0 !important; }
.text-primary-main { color: #1565C0 !important; }

/* ── Scrollbar accent (safe — non-functional UI only) ─────── */
.ohif-scrollbar::-webkit-scrollbar-thumb {
  background-color: #1565C0 !important;
}
.ohif-scrollbar::-webkit-scrollbar-thumb:window-inactive {
  background-color: #1E88E5 !important;
}
.ohif-scrollbar {
  scrollbar-color: #1565C0 transparent !important;
}

/* ── Button gradient (targets common OHIF button pattern) ─── */
/* Primary/action buttons get the rule-ui gradient */
[class*="bg-primary-active"]:not([class*="text"]):not([class*="border"]) {
  background: linear-gradient(135deg, #1E88E5 0%, #1565C0 100%) !important;
  border-radius: 12px !important;
}
