/* Theme packs — default :root in ui.css is EagerSky blue */

:root {
  --color-brand: #2563eb;
  --color-brand-dark: #1d4ed8;
  --color-brand-soft: #dbeafe;
  --color-brand-ink: #1e3a8a;
}

html[data-theme="blue"] {
  --ui-brand: #2563eb;
  --ui-brand-dark: #1d4ed8;
  --ui-brand-soft: #dbeafe;
  --ui-ink: #0f172a;
  --ui-muted: #64748b;
  --ui-paper: #f8fafc;
  --ui-line: #e2e8f0;
  --ui-sidebar: #1e3a8a;
  --ui-sidebar-ink: #eff6ff;
  --ui-sidebar-muted: #93c5fd;
  --color-brand: #2563eb;
  --color-brand-dark: #1d4ed8;
  --color-brand-soft: #dbeafe;
  --color-brand-ink: #1e3a8a;
  color-scheme: light;
}

html[data-theme="blue"] .ui-sidebar {
  background: linear-gradient(180deg, #1d4ed8 0%, #1e3a8a 55%, #172554 100%);
  border-right-color: #1e40af;
}

html[data-theme="eagersky"] {
  --ui-brand: #1b4d3e;
  --ui-brand-dark: #12352c;
  --ui-brand-soft: #e7f1ed;
  --ui-ink: #1c1917;
  --ui-muted: #57534e;
  --ui-paper: #f3f1ec;
  --ui-line: #e4e1dc;
  --ui-sidebar: #12261f;
  --ui-sidebar-ink: #d7e4de;
  --ui-sidebar-muted: #8aa399;
  --color-brand: #1b4d3e;
  --color-brand-dark: #12352c;
  --color-brand-soft: #e7f1ed;
  --color-brand-ink: #14382e;
  color-scheme: light;
}

html[data-theme="eagersky"] .ui-sidebar {
  background: linear-gradient(180deg, #163429 0%, var(--ui-sidebar) 55%);
}

html[data-theme="white"] {
  --ui-brand: #2563eb;
  --ui-brand-dark: #1d4ed8;
  --ui-brand-soft: #eff6ff;
  --ui-ink: #0f172a;
  --ui-muted: #64748b;
  --ui-paper: #f8fafc;
  --ui-line: #e2e8f0;
  --ui-white: #ffffff;
  --ui-sidebar: #ffffff;
  --ui-sidebar-ink: #334155;
  --ui-sidebar-muted: #94a3b8;
  --color-brand: #2563eb;
  --color-brand-dark: #1d4ed8;
  --color-brand-soft: #eff6ff;
  --color-brand-ink: #1e3a8a;
  color-scheme: light;
}

html[data-theme="white"] .ui-sidebar {
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  border-right-color: var(--ui-line);
  color: var(--ui-sidebar-ink);
  box-shadow: 1px 0 0 rgba(15, 23, 42, 0.04);
}

html[data-theme="white"] .ui-brand-name {
  color: var(--ui-ink);
}

html[data-theme="white"] .ui-brand-portal {
  color: var(--ui-muted);
}

html[data-theme="white"] .ui-brand-mark {
  background: var(--ui-brand-soft);
  color: var(--ui-brand);
}

html[data-theme="white"] .ui-nav-link {
  color: var(--ui-sidebar-muted);
}

html[data-theme="white"] .ui-nav-link:hover {
  background: #f1f5f9;
  color: var(--ui-ink);
}

html[data-theme="white"] .ui-nav-link.is-active {
  background: var(--ui-brand-soft);
  color: var(--ui-brand-dark);
}

html[data-theme="white"] .ui-nav-group.is-active-group > .ui-nav-section-btn {
  color: var(--ui-brand-dark);
  background: var(--ui-brand-soft);
}

html[data-theme="white"] .ui-nav-group-links {
  border-left-color: var(--ui-line);
}

html[data-theme="white"] .ui-nav-section-count {
  background: #e2e8f0;
  color: var(--ui-muted);
}

html[data-theme="midnight"] {
  --ui-brand: #60a5fa;
  --ui-brand-dark: #3b82f6;
  --ui-brand-soft: #1e3a8a;
  --ui-ink: #e7e5e4;
  --ui-muted: #a8a29e;
  --ui-paper: #0c0a09;
  --ui-line: #292524;
  --ui-white: #1c1917;
  --ui-sidebar: #0f172a;
  --ui-sidebar-ink: #dbeafe;
  --ui-sidebar-muted: #64748b;
  --color-brand: #3b82f6;
  --color-brand-dark: #2563eb;
  --color-brand-soft: #1e3a8a;
  --color-brand-ink: #dbeafe;
  color-scheme: dark;
}

html[data-theme="midnight"] .ui-sidebar {
  background: linear-gradient(180deg, #1e293b 0%, var(--ui-sidebar) 55%);
}

html[data-theme="midnight"] .ui-topbar,
html[data-theme="midnight"] .ui-dock {
  background: rgba(28, 25, 23, 0.96);
  border-color: var(--ui-line);
}

html[data-theme="midnight"] .ui-main {
  background: var(--ui-paper);
}

html[data-theme="midnight"] .ui-btn {
  background: #292524;
  border-color: #44403c;
  color: var(--ui-ink);
}

html[data-theme="midnight"] .ui-btn-brand {
  background: var(--ui-brand-dark);
  border-color: var(--ui-brand-dark);
  color: #eff6ff;
}

html[data-theme="midnight"] .ui-units-card,
html[data-theme="midnight"] .ui-metric-chip,
html[data-theme="midnight"] .ui-input,
html[data-theme="midnight"] .ui-select,
html[data-theme="midnight"] main input:not([type="hidden"]),
html[data-theme="midnight"] main select,
html[data-theme="midnight"] main textarea {
  background: #1c1917;
  border-color: #44403c;
  color: var(--ui-ink);
}

html[data-theme="midnight"] .ui-assistant {
  background: #1c1917;
  border-color: #44403c;
}

html[data-theme="midnight"] .ui-assistant-msg.is-bot {
  background: #292524;
}
