/* ============================================================
   yk 面板 · Deep Space 主题 v2（2026-11-28）
   覆盖主 bundle 的 CSS 变量 + 登录页背景，只改颜色/材质，不改结构
   加载顺序：main-*.css → 本文件（index.html 里已加 ?v=2 防缓存）
   ============================================================ */

/* ---------- 1. 主色板：酒红/石墨 → 午夜蓝/靛紫 ---------- */
:root {
  /* 石墨系（页面底色/边框）→ 深蓝灰 */
  --fc-palette-graphite-950: #050a14;
  --fc-palette-graphite-900: #0a1220;
  --fc-palette-graphite-850: #0e1728;
  --fc-palette-graphite-800: #121d31;
  --fc-palette-graphite-750: #16233a;
  --fc-palette-graphite-700: #1b2a44;
  --fc-palette-graphite-650: #22334f;
  --fc-palette-graphite-600: #2c3f60;
  --fc-palette-graphite-500: #3f5678;
  --fc-palette-graphite-400: #5a7398;
  --fc-palette-graphite-300: #7d93b5;
  --fc-palette-graphite-200: #a7b8d3;
  --fc-palette-graphite-100: #cfdaea;
  --fc-palette-graphite-50:  #e8eef8;
  --fc-palette-graphite-25:  #f4f8fd;

  /* 强调色（原酒红）→ 靛紫 */
  --fc-palette-violet-700: #4338ca;
  --fc-palette-violet-600: #4f46e5;
  --fc-palette-violet-500: #6366f1;
  --fc-palette-violet-400: #818cf8;
  --fc-palette-violet-300: #a5b4fc;
  --fc-palette-violet-200: #c7d2fe;
  --fc-palette-violet-100: #e0e7ff;

  /* ---------- 2. 面板/侧栏/顶栏 ---------- */
  --fc-bg-body: #070b14;
  --fc-bg-root: #070b14;
  --fc-bg-shell: #0b1220;
  --fc-bg-panel: rgba(20, 29, 48, 0.72);
  --fc-bg-sidebar: rgba(11, 18, 32, 0.86);
  --fc-bg-topbar: rgba(13, 21, 38, 0.82);
  --fc-bg-page: #070b14;
  --fc-input-bg: rgba(255, 255, 255, 0.05);

  --fc-text-secondary: #dbe4f3;
  --fc-text-muted: #93a4bf;
  --fc-text-topbar: #e6edf9;
  --fc-text-topbar-muted: #9fb0cc;

  --fc-accent-blue: #6366f1;
  --fc-accent-purple: #22d3ee;
  --fc-hover-bg: rgba(99, 102, 241, 0.10);
  --fc-sidebar-nav: #a8b6cf;
  --fc-sidebar-nav-hover: #ffffff;
  --fc-sidebar-active-bg: rgba(99, 102, 241, 0.18);
  --fc-sidebar-active-border: rgba(99, 102, 241, 0.45);
  --fc-table-row-border: rgba(148, 163, 184, 0.12);
  --fc-th-bg: rgba(148, 163, 184, 0.06);
  --fc-toast-bg: rgba(11, 18, 32, 0.94);
  --fc-toast-border: rgba(99, 102, 241, 0.35);
  --fc-toast-text: #e2e8f0;
  --fc-scrollbar: #2b3a55;
  --fc-link: #8b9dff;
  --fc-form-label: #dbe4f3;
  --fc-form-hint: #93a4bf;

  --fc-border: rgba(148, 163, 184, 0.14);
  --fc-shadow: 0 10px 30px rgba(2, 6, 23, 0.45);
  --fc-shadow-sm: 0 2px 8px rgba(2, 6, 23, 0.35);

  /* ---------- 3. 旧 soy 变量 ---------- */
  --soy-bg: #0b1220;
  --soy-card: rgba(20, 29, 48, 0.72);
  --soy-border: rgba(148, 163, 184, 0.14);
  --soy-border-soft: rgba(148, 163, 184, 0.08);
  --soy-text: #dbe4f3;
  --soy-text-2: #93a4bf;
  --soy-muted: #7e90ad;
  --soy-primary: #6366f1;
  --soy-primary-soft: rgba(99, 102, 241, 0.14);
  --soy-success: #10b981;
  --soy-danger: #f43f5e;
  --soy-warning: #f59e0b;
  --soy-radius: 10px;
  --soy-radius-lg: 14px;
  --soy-shadow: 0 10px 30px rgba(2, 6, 23, 0.45);

  /* ---------- 4. 登录页变量 ---------- */
  --lg-bg-1: #050a14;
  --lg-bg-2: #0a1220;
  --lg-bg-3: #121d31;
  --lg-border: rgba(148, 163, 184, 0.16);
  --lg-border-focus: #6366f1;
  --lg-danger: #f43f5e;
  --lg-primary: #6366f1;
  --lg-primary-glow: rgba(99, 102, 241, 0.45);
  --lg-primary-hi: #4338ca;
  --lg-primary-lo: #818cf8;
  --lg-primary-soft: rgba(99, 102, 241, 0.16);
  --lg-shadow: 0 4px 14px rgba(2, 6, 23, 0.5), 0 2px 4px rgba(2, 6, 23, 0.4);
  --lg-shadow-lg: 0 16px 34px rgba(2, 6, 23, 0.55), 0 6px 10px rgba(2, 6, 23, 0.4);
  --lg-shadow-sm: 0 1px 3px rgba(2, 6, 23, 0.45);
  --lg-shadow-xl: 0 30px 70px rgba(2, 6, 23, 0.65), 0 10px 20px rgba(2, 6, 23, 0.45);
  --lg-success: #10b981;
  --lg-warning: #f59e0b;
  --lg-text: #dbe4f3;
  --lg-text-2: #93a4bf;
  --lg-text-3: #7e90ad;
  --lg-white: rgba(18, 27, 45, 0.86);
}

/* ---------- 5. 页面底色：午夜蓝 + 极光光晕 ---------- */
html {
  background: #070b14 !important;
}

body {
  background:
    radial-gradient(1100px 560px at 10% -8%, rgba(99, 102, 241, 0.16), transparent 60%),
    radial-gradient(900px 520px at 100% 0%, rgba(34, 211, 238, 0.08), transparent 55%),
    radial-gradient(900px 600px at 50% 110%, rgba(139, 92, 246, 0.10), transparent 60%),
    linear-gradient(180deg, #070b14 0%, #070d18 55%, #060a12 100%) !important;
  background-attachment: fixed !important;
  background-repeat: no-repeat !important;
}

/* ---------- 6. 登录页：玻璃卡片 + 靛紫/青色光斑 ---------- */
.login-page {
  background:
    radial-gradient(1200px 620px at 50% -12%, rgba(99, 102, 241, 0.30), transparent 60%),
    radial-gradient(900px 540px at 94% 108%, rgba(34, 211, 238, 0.16), transparent 55%),
    radial-gradient(820px 520px at 4% 98%, rgba(139, 92, 246, 0.16), transparent 60%),
    linear-gradient(160deg, #050a14 0%, #0a1220 45%, #0d1729 100%) !important;
  color: var(--lg-text) !important;
}

.login-container {
  background: rgba(13, 21, 38, 0.86) !important;
  border-color: rgba(99, 102, 241, 0.28) !important;
  box-shadow: 0 30px 70px rgba(2, 6, 23, 0.65), 0 0 90px rgba(99, 102, 241, 0.16) !important;
  backdrop-filter: blur(18px);
}

.login-form-section {
  background: transparent !important;
}

.login-brand:after {
  background: radial-gradient(ellipse at center, rgba(34, 211, 238, 0.22), transparent 70%) !important;
}

/* ---------- 7. 滚动条 ---------- */
* {
  scrollbar-color: #2b3a55 transparent;
  scrollbar-width: thin;
}

*::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

*::-webkit-scrollbar-thumb {
  background: #26344d;
  border-radius: 10px;
  border: 2px solid transparent;
  background-clip: content-box;
}

*::-webkit-scrollbar-thumb:hover {
  background: #33456a;
  background-clip: content-box;
}

*::-webkit-scrollbar-track {
  background: transparent;
}

/* ---------- 8. 侧边栏菜单整体加大（2026-11-28 追加） ---------- */
/* 宽度只在桌面端加宽，避免窄屏被挤爆 */
@media (min-width: 900px) {
  .rc-sidebar,
  .dark .rc-sidebar {
    width: 296px !important;
  }
}

.rc-sidebar {
  padding: 30px 0 18px !important;
}

.rc-sidebar nav {
  padding: 0 12px !important;
  gap: 4px !important;
}

/* 菜单项：42px/14px → 52px/16px */
.rc-sidebar nav button {
  height: 52px !important;
  font-size: 16px !important;
  padding: 0 18px !important;
  gap: 12px !important;
  border-radius: 10px !important;
  font-weight: 500 !important;
}

.rc-sidebar nav button + button {
  margin-top: 2px !important;
}

/* 图标跟着放大：内联 svg / anticon 一起管 */
.rc-sidebar nav button > svg,
.rc-sidebar nav button .anticon,
.rc-sidebar nav button > span > svg {
  width: 22px !important;
  height: 22px !important;
  font-size: 22px !important;
  flex-shrink: 0;
}

/* 分组标题（数据中心/系统管理…）文字也提一点 */
.rc-sidebar .nav-group-title,
.rc-sidebar nav .group-label {
  font-size: 13px !important;
  letter-spacing: .04em;
}

/* ---------- 10. Ant Design 侧边栏 + 菜单加大（真正生效的一套） ---------- */
/* 侧栏宽度：antd Sider 是行内 width，必须 !important 覆盖 */
.ant-layout-sider,
.ant-layout-sider.ant-layout-sider-dark,
.ant-layout-sider.ant-layout-sider-light {
  width: 288px !important;
  min-width: 288px !important;
  max-width: 288px !important;
  flex: 0 0 288px !important;
}

/* 菜单整体字号 */
.ant-menu.ant-menu-inline,
.ant-menu.ant-menu-vertical,
.ant-menu.ant-menu-inline .ant-menu-sub,
.ant-menu.ant-menu-vertical .ant-menu-sub {
  font-size: 16px !important;
}

/* 一级菜单项 / 折叠标题统一 52px 高 */
.ant-menu-inline > .ant-menu-item,
.ant-menu-inline > .ant-menu-submenu > .ant-menu-submenu-title,
.ant-menu-vertical > .ant-menu-item,
.ant-menu-vertical > .ant-menu-submenu > .ant-menu-submenu-title,
.ant-menu-inline .ant-menu-sub > .ant-menu-item {
  height: 52px !important;
  line-height: 52px !important;
  font-size: 16px !important;
  margin: 4px 10px !important;
  width: calc(100% - 20px) !important;
  border-radius: 10px !important;
  padding-left: 16px !important;
}

/* 图标跟着放大 */
.ant-menu-inline .ant-menu-item .anticon,
.ant-menu-inline .ant-menu-submenu-title .anticon,
.ant-menu-inline .ant-menu-item svg,
.ant-menu-inline .ant-menu-submenu-title svg,
.ant-menu-vertical .ant-menu-item .anticon,
.ant-menu-vertical .ant-menu-submenu-title .anticon {
  font-size: 20px !important;
  width: 20px !important;
  height: 20px !important;
  min-width: 20px !important;
}

/* 右侧展开箭头稍微大一点 */
.ant-menu-submenu-title .ant-menu-submenu-arrow,
.ant-menu-submenu-title .anticon-down {
  font-size: 13px !important;
}

/* 选中/悬浮态圆角更明显 */
.ant-menu-item,
.ant-menu-submenu-title,
.ant-menu-item-selected,
.ant-menu-item-active,
.ant-menu-submenu-active > .ant-menu-submenu-title {
  border-radius: 10px !important;
}

/* ---------- 9. 细节：选中文本 / 分组高亮 ---------- */
::selection {
  background: rgba(99, 102, 241, 0.35);
  color: #fff;
}

/* ---------- 11. 登录页配色统一到 Deep Space（2026-11-30） ---------- */
/* 原来左侧品牌区是酒红→橙的渐变，大字是橙色描边，整块跟深空蓝主题对冲 */
.login-page {
  background:
    radial-gradient(1200px 620px at 50% -12%, rgba(99, 102, 241, 0.30), transparent 60%),
    radial-gradient(900px 540px at 94% 108%, rgba(34, 211, 238, 0.14), transparent 55%),
    radial-gradient(820px 520px at 4% 98%, rgba(139, 92, 246, 0.14), transparent 60%),
    linear-gradient(160deg, #050a14 0%, #0a1220 45%, #0d1729 100%) !important;
}

.login-brand {
  background:
    radial-gradient(620px 440px at 50% 18%, rgba(99, 102, 241, 0.40), transparent 62%),
    radial-gradient(520px 380px at 50% 112%, rgba(34, 211, 238, 0.22), transparent 60%),
    linear-gradient(165deg, #070b14 0%, #0b1220 45%, #101a2e 78%, #0d1526 100%) !important;
}

.login-brand:after {
  background: radial-gradient(ellipse at center, rgba(34, 211, 238, 0.30), transparent 70%) !important;
}

/* 大字：从橙色描边改成白→靛紫→青 的渐变描边 */
.brand-line {
  -webkit-text-stroke: 8px rgba(99, 102, 241, 0.55) !important;
  background: linear-gradient(180deg, #ffffff, #dfe7ff, #a5b4fc, #818cf8, #22d3ee) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  filter: drop-shadow(0 2px 18px rgba(34, 211, 238, 0.35)) !important;
}

.brand-sub {
  color: #93a4bf !important;
}

.brand-divider:before {
  background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.75)) !important;
}

.brand-divider:after {
  background: linear-gradient(90deg, rgba(99, 102, 241, 0.75), transparent) !important;
}

.brand-divider-flame {
  background: linear-gradient(135deg, #a5b4fc, #22d3ee) !important;
  box-shadow: 0 0 12px rgba(34, 211, 238, 0.6) !important;
}

/* 特性卡片：琥珀边 → 石板/靛紫 */
.feature-item {
  background: rgba(255, 255, 255, 0.04) !important;
  border-color: rgba(148, 163, 184, 0.16) !important;
}

.feature-item:hover {
  background: rgba(99, 102, 241, 0.14) !important;
  border-color: rgba(99, 102, 241, 0.45) !important;
  box-shadow: 0 0 22px rgba(99, 102, 241, 0.30), inset 0 0 0 1px rgba(34, 211, 238, 0.18) !important;
}

.feature-icon {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.28), rgba(34, 211, 238, 0.18)) !important;
  border-color: rgba(99, 102, 241, 0.40) !important;
  color: #a5b4fc !important;
}

.feature-text {
  color: #dbe4f3 !important;
}

.deco-circle-2 {
  background: radial-gradient(circle, rgba(34, 211, 238, 0.18), transparent 70%) !important;
}

.brand-ring {
  background: conic-gradient(from 0deg, rgba(34, 211, 238, 0), rgba(34, 211, 238, 0.95) 70deg, rgba(99, 102, 241, 0.90), rgba(99, 102, 241, 0) 200deg) !important;
}

.brand-glow {
  background: radial-gradient(circle, rgba(34, 211, 238, 0.45), rgba(99, 102, 241, 0.28) 55%, transparent 75%) !important;
}

/* 顶栏品牌字（右上角的 清风logo 文本）也一起换色 */
.brand-lockup-name {
  background: linear-gradient(135deg, #ffffff, #a5b4fc 45%, #22d3ee) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
}
