/* ============================================================
   幕栈API · NewAPI 控制台黑金主题（Nginx 注入，不改动 NewAPI 源码）
   覆盖 Tailwind v4 / shadcn 语义变量，light 与 dark 模式均生效
   ============================================================ */

:root,
html.dark,
.dark {
  --background: #0a0a0c !important;
  --foreground: #f3efe4 !important;
  --card: #14141a !important;
  --card-foreground: #f3efe4 !important;
  --popover: #1a1a22 !important;
  --popover-foreground: #f3efe4 !important;
  --primary: #d4af37 !important;
  --primary-foreground: #1a1405 !important;
  --secondary: #1c1c24 !important;
  --secondary-foreground: #f5e08a !important;
  --muted: #1a1a22 !important;
  --muted-foreground: #a79f8c !important;
  --accent: #241f10 !important;
  --accent-foreground: #f5e08a !important;
  --destructive: #e40014 !important;
  --destructive-foreground: #fafafa !important;
  --border: rgba(212, 175, 55, 0.22) !important;
  --input: rgba(212, 175, 55, 0.30) !important;
  --ring: #d4af37 !important;
  --sidebar: #0d0d10 !important;
  --sidebar-foreground: #e8e2d2 !important;
  --sidebar-primary: #d4af37 !important;
  --sidebar-primary-foreground: #1a1405 !important;
  --sidebar-accent: #241f10 !important;
  --sidebar-accent-foreground: #f5e08a !important;
  --sidebar-border: rgba(212, 175, 55, 0.18) !important;
  --sidebar-ring: #d4af37 !important;
  --table-row: #14141a !important;
}

/* 基底强制深色，避免浅色工具类残留 */
html,
body,
#root {
  background-color: #0a0a0c !important;
  color: #f3efe4 !important;
}

/* 滚动条 */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: #0d0d10; }
::-webkit-scrollbar-thumb { background: rgba(212, 175, 55, 0.28); border-radius: 8px; border: 2px solid #0d0d10; }
::-webkit-scrollbar-thumb:hover { background: rgba(212, 175, 55, 0.45); }

/* 选中态 */
::selection { background: rgba(212, 175, 55, 0.35); color: #fff; }

/* 卡片 / 弹层 / 侧边栏底色兜底 */
.bg-card,
.bg-popover,
.bg-sidebar { background-color: var(--card) !important; }

/* 主按钮金色（变量驱动，兜底） */
.bg-primary { background-color: #d4af37 !important; color: #1a1405 !important; }
.bg-primary:hover { background-color: #e6c453 !important; }

/* 原生表单控件深色 */
input,
textarea,
select { color-scheme: dark; }

/* 表格行 hover */
tbody tr:hover { background-color: rgba(212, 175, 55, 0.06) !important; }

/* 链接过渡 */
a { transition: color 0.2s ease; }
