/*
 * CyR blue visual override for TryPost 2.0.1.
 * Original application, attribution and behavior remain unchanged.
 * Plain CSS deliberately loaded after Vite: no asset compilation required.
 */
:root,
[data-light-theme] {
  --background: #ffffff;
  --foreground: #183052;
  --card: #ffffff;
  --card-foreground: #183052;
  --popover: #ffffff;
  --popover-foreground: #183052;
  --tooltip: #0b1e44;
  --tooltip-foreground: #ffffff;
  --primary: #dbeafe;
  --primary-foreground: #123d78;
  --primary-hover: #bfdbfe;
  --primary-strong: #075ce8;
  --primary-strong-foreground: #ffffff;
  --primary-subtle: #edf4ff;
  --primary-selected: #075ce826;
  --primary-text: #0752c9;
  --primary-text-hover: #004ac2;
  --secondary: #eaf0f9;
  --secondary-foreground: #183052;
  --muted: #f4f7fd;
  --muted-foreground: #5d6f88;
  --subtle-foreground: #63738b;
  --accent: #edf4ff;
  --accent-foreground: #183052;
  --success: #2563eb;
  --success-subtle: #e5f0ff;
  --success-text: #1557ac;
  --info: #2563eb;
  --info-subtle: #edf4ff;
  --info-text: #1557ac;
  --border: #dce5f2;
  --border-strong: #c6d6ed;
  --input: #7085a3;
  --ring: #367bf0;
  --chart-1: #153e83;
  --chart-2: #075ce8;
  --chart-3: #3b82f6;
  --chart-4: #7eb0fa;
  --chart-5: #c2dafa;
  --series-1: #2563eb;
  --series-3: #0e7490;
  --series-6: #1d4ed8;
  --sidebar: #0b1e44;
  --sidebar-foreground: #eaf1ff;
  --sidebar-primary: #145cdd;
  --sidebar-primary-foreground: #ffffff;
  --sidebar-accent: #183964;
  --sidebar-accent-foreground: #ffffff;
  --sidebar-action-hover: #ffffff12;
  --sidebar-border: #2a4268;
  --sidebar-ring: #71b0ff;
}

.dark {
  --background: #0b1528;
  --raised: #13243b;
  --foreground: #eaf1ff;
  --card: #101e34;
  --card-foreground: #eaf1ff;
  --popover: #15253e;
  --popover-foreground: #eaf1ff;
  --tooltip: #233b60;
  --tooltip-foreground: #ffffff;
  --primary: #8bbcff;
  --primary-foreground: #102a50;
  --primary-hover: #b8d7ff;
  --primary-strong: #8bbcff;
  --primary-strong-foreground: #102a50;
  --primary-subtle: #112e5b;
  --primary-selected: #3b82f633;
  --primary-text: #a8cfff;
  --primary-text-hover: #d2e6ff;
  --secondary: #1d3150;
  --secondary-foreground: #eaf1ff;
  --muted: #12223a;
  --muted-foreground: #b3c5df;
  --subtle-foreground: #95accb;
  --accent: #203a60;
  --accent-foreground: #eaf1ff;
  --success: #8bbcff;
  --success-subtle: #153564;
  --success-text: #b8d7ff;
  --info: #8bbcff;
  --info-subtle: #153564;
  --info-text: #b8d7ff;
  --border: #2b4263;
  --border-strong: #3b567b;
  --input: #7891b2;
  --ring: #8bbcff;
  --chart-1: #c2dafa;
  --chart-2: #8bbcff;
  --chart-3: #60a5fa;
  --chart-4: #3b82f6;
  --chart-5: #1d4ed8;
  --series-1: #8bbcff;
  --series-3: #67cbe8;
  --series-6: #60a5fa;
  --sidebar: #08142c;
  --sidebar-foreground: #eaf1ff;
  --sidebar-primary: #8bbcff;
  --sidebar-primary-foreground: #102a50;
  --sidebar-accent: #1b345a;
  --sidebar-accent-foreground: #ffffff;
  --sidebar-action-hover: #ffffff14;
  --sidebar-border: #243c60;
  --sidebar-ring: #8bbcff;
}

/* Sidebar children also use generic foreground/muted tokens. Scope these
   to the sidebar in both desktop and mobile layouts verified in v2.0.1. */
[data-slot='sidebar'],
[data-sidebar='sidebar'] {
  --foreground: #eaf1ff;
  --muted-foreground: #b4c6e2;
  --subtle-foreground: #a9bedf;
  --background: var(--sidebar);
  --accent: var(--sidebar-accent);
  --accent-foreground: #ffffff;
  --border: var(--sidebar-border);
  --primary-text: #a8cfff;
  --primary-text-hover: #d2e6ff;
}

/* Preserve strong button contrast inside the dark sidebar, where its generic
   hover token is deliberately lighter for links. These are real v2.0.1 hooks. */
[data-testid='sidebar-new']:not(:disabled) {
  background-color: #075ce8;
  color: #ffffff;
}
[data-testid='sidebar-new']:not(:disabled):hover,
[data-testid='sidebar-new'][data-state='open'] {
  background-color: #004ac2;
  color: #ffffff;
}

html,
html.dark {
  background-color: var(--background);
}
