/* 澜工 AI 智能平台 · 网关前台主题（科技深蓝 · 暗色背景）
   通过 nginx sub_filter 注入 <head>，随 index.css 之后加载，覆盖 shadcn 令牌。 */
html.dark {
  color-scheme: dark;
  --background: #0a1120;
  --foreground: #e3ecf8;
  --card: #111c31;
  --card-foreground: #e3ecf8;
  --popover: #131f36;
  --popover-foreground: #e3ecf8;
  --primary: #2e7bff;
  --primary-foreground: #ffffff;
  --secondary: #17233b;
  --secondary-foreground: #cfe0f8;
  --muted: #16223a;
  --muted-foreground: #9db3d4;
  --accent: #2e7bff29;
  --accent-foreground: #ffffff;
  --destructive: #ff6568;
  --destructive-foreground: #fafafa;
  --success: #00bb7f;
  --success-foreground: #0a0a0a;
  --warning: #f99c00;
  --warning-foreground: #0a0a0a;
  --info: #018dcf;
  --info-foreground: #0a0a0a;
  --neutral: #b1b1b1;
  --neutral-foreground: #0c0c0c;
  --border: rgba(124, 164, 255, 0.18);
  --input: rgba(124, 164, 255, 0.22);
  --ring: #2e7bff;
  --sidebar: #0d1628;
  --sidebar-foreground: #cfe0f8;
  --sidebar-primary: #2e7bff;
  --sidebar-primary-foreground: #ffffff;
  --sidebar-accent: #2e7bff1f;
  --radius: 0.75rem;
  --cell-radius: 0.5rem;
}

/* 深蓝科技底：深海军蓝 + 两处青蓝辉光 */
html.dark body {
  background:
    radial-gradient(1200px 700px at 85% -10%, rgba(46, 123, 255, 0.20), transparent 60%),
    radial-gradient(1000px 600px at -5% 110%, rgba(0, 201, 209, 0.10), transparent 55%),
    #0a1120 !important;
  background-attachment: fixed;
  color: var(--foreground);
}

html.dark #root {
  background: transparent !important;
}

/* 卡片/弹层玻璃质感 */
html.dark .bg-card,
html.dark [data-slot="card"] {
  background: linear-gradient(180deg, rgba(24, 40, 74, 0.86), rgba(14, 24, 46, 0.92)) !important;
  border: 1px solid var(--border);
}

/* 主按钮渐变 + 辉光 */
html.dark .bg-primary,
html.dark button[data-slot="button"].bg-primary {
  background: linear-gradient(135deg, #3b86ff, #1f6bff) !important;
  box-shadow: 0 6px 22px rgba(46, 123, 255, 0.35);
}

html.dark a,
html.dark .text-primary,
html.dark .text-primary-foreground {
  color: #6ea8ff !important;
}

/* 顶部导航/侧栏半透明 */
html.dark [data-slot="sidebar"],
html.dark .bg-sidebar {
  background: rgba(10, 17, 32, 0.86) !important;
  border-right: 1px solid var(--border);
}

html.dark header,
html.dark .bg-background\/95 {
  background: rgba(10, 17, 32, 0.82) !important;
  backdrop-filter: blur(10px);
}

/* 输入框聚焦蓝边 */
html.dark input:focus,
html.dark textarea:focus,
html.dark [data-slot="input"]:focus {
  border-color: #2e7bff !important;
  box-shadow: 0 0 0 3px rgba(46, 123, 255, 0.22) !important;
}
