/* 028 全局样式（PLAN-656A → PLAN-657E → 660）
 * 颜色用 CSS 变量 --gl-*，与 theme/tokens.ts 对应。
 * 5 风格各一套变量，用 [data-style='xxx'] 匹配；:root 兜底钢蓝。
 * 默认(steel)挂 :root + [data-style='steel']，data-style 未设时也是钢蓝。
 * 侧栏变量：默认白侧栏(4风格继承)，enterprise 单独深蓝覆盖(PLAN-660)。
 */
:root,
[data-style='steel'] {
  --gl-bg-page: #f8fafc;
  --gl-bg-container: #ffffff;
  --gl-text: #1e293b;
  --gl-text-secondary: #64748b;
  --gl-text-tertiary: #94a3b8;
  --gl-border: #e2e8f0;
  --gl-link: #3b82f6;
  --gl-link-hover: #2563eb;
  --gl-scrollbar: #cbd5e1;
  --gl-scrollbar-hover: #94a3b8;
  /* 侧栏：默认白底深字（steel/vercel/orange/floating 继承） */
  --gl-sider-bg: #ffffff;
  --gl-sider-text: var(--gl-text);
  --gl-sider-border: var(--gl-border);
}

[data-style='enterprise'] {
  --gl-bg-page: #f5f7fa;
  --gl-bg-container: #ffffff;
  --gl-text: #1f2937;
  --gl-text-secondary: #4b5563;
  --gl-text-tertiary: #9ca3af;
  --gl-border: #d9e0ea;
  --gl-link: #1e40af;
  --gl-link-hover: #1e3a8a;
  --gl-scrollbar: #cdd6e5;
  --gl-scrollbar-hover: #9ca3af;
  /* 侧栏：深蓝底白字（enterprise 特有） */
  --gl-sider-bg: #0f1f3d;
  --gl-sider-text: rgba(255, 255, 255, 0.92);
  --gl-sider-border: rgba(255, 255, 255, 0.10);
}

[data-style='vercel'] {
  --gl-bg-page: #ffffff;
  --gl-bg-container: #ffffff;
  --gl-text: #000000;
  --gl-text-secondary: #666666;
  --gl-text-tertiary: #999999;
  --gl-border: #eaeaea;
  --gl-link: #000000;
  --gl-link-hover: #333333;
  --gl-scrollbar: #eaeaea;
  --gl-scrollbar-hover: #cccccc;
}

[data-style='orange'] {
  --gl-bg-page: #fffaf7;
  --gl-bg-container: #ffffff;
  --gl-text: #1f2937;
  --gl-text-secondary: #78716c;
  --gl-text-tertiary: #a8a29e;
  --gl-border: #ffe4d6;
  --gl-link: #ff7a59;
  --gl-link-hover: #f8552d;
  --gl-scrollbar: #ffd4c2;
  --gl-scrollbar-hover: #ffb199;
}

[data-style='floating'] {
  --gl-bg-page: #f1f4f9;
  --gl-bg-container: #ffffff;
  --gl-text: #1a1d29;
  --gl-text-secondary: #64748b;
  --gl-text-tertiary: #9aa2b1;
  --gl-border: #e2e8f0;
  --gl-link: #3b82f6;
  --gl-link-hover: #2563eb;
  --gl-scrollbar: #cbd5e1;
  --gl-scrollbar-hover: #94a3b8;
}

*, *::before, *::after {
  box-sizing: border-box;
}

html, body, #root {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
    'Helvetica Neue', Arial, 'Noto Sans', 'Microsoft YaHei', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background: var(--gl-bg-page);
  color: var(--gl-text);
}

a { color: var(--gl-link); }
a:hover { color: var(--gl-link-hover); }

/* 滚动条美化（Webkit）- 跟随主题 */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: var(--gl-scrollbar);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--gl-scrollbar-hover);
}

/* ─── 暖色橙调专属增强（PROMPT-658 → 659 大气化）：仅 [data-style='orange'] ─── */

/* 主按钮：沉稳橙色渐变 + 大圆角矩形 + 去hover蹦跳 */
[data-style='orange'] .ant-btn-primary {
  background: linear-gradient(135deg, #f0714b, #e35a34) !important;
  border: none !important;
  border-radius: 12px !important;
  box-shadow: 0 6px 16px rgba(227, 90, 52, 0.18);
  transition: box-shadow 0.18s;
}
[data-style='orange'] .ant-btn-primary:hover {
  box-shadow: 0 8px 20px rgba(227, 90, 52, 0.22) !important;
  background: linear-gradient(135deg, #f47a55, #e8623c) !important;
  /* 去掉 transform translateY，不再蹦跳 */
}

/* 卡片：沉稳柔投影 + 去hover上浮 */
[data-style='orange'] .ant-card {
  box-shadow: 0 10px 28px rgba(43, 58, 75, 0.05);
  border-radius: 16px;
  transition: box-shadow 0.18s;
}
[data-style='orange'] .ant-card:hover {
  box-shadow: 0 10px 28px rgba(227, 90, 52, 0.10);
  /* 去 translateY，只轻微投影变化 */
}

/* 侧边栏 active 菜单：柔和橙底 + 左色条（非渐变实心块） */
[data-style='orange'] .ant-menu-item-selected {
  background: rgba(240, 113, 75, 0.10) !important;
  color: #e35a34 !important;
  box-shadow: inset 3px 0 0 #f0714b;
}

/* Logo 方块：沉稳橙渐变（Layout 里 .app-logo-box） */
[data-style='orange'] .app-logo-box {
  background: linear-gradient(135deg, #f79068, #f0714b) !important;
}

