/* ============================================
   New API → Professional Branding (Badboy API)
   ============================================ */

/* === 全局基础 & 背景 === */
html, body, #root, .semi-layout {
  background: #f8fafc !important;
  color: #0f172a !important;
  -webkit-font-smoothing: antialiased !important;
}

body, body[theme-mode="dark"], body[theme-mode="light"] {
  /* --- 专业色板 --- */
  --semi-white:      255,255,255 !important;
  --semi-black:      15,23,42 !important;

  /* 中性灰 */
  --semi-grey-0:     248,250,252 !important;  /* bg-slate-50 */
  --semi-grey-1:     241,245,249 !important;  /* bg-slate-100 */
  --semi-grey-2:     226,232,240 !important;  /* border-slate-200 */
  --semi-grey-3:     203,213,225 !important;  /* border-slate-300 */
  --semi-grey-4:     148,163,184 !important;  /* text-slate-400 */
  --semi-grey-5:     100,116,139 !important;  /* text-slate-500 */
  --semi-grey-6:     71,85,105 !important;    /* text-slate-600 */
  --semi-grey-7:     51,65,85 !important;     /* text-slate-700 */
  --semi-grey-8:     30,41,59 !important;     /* text-slate-800 */
  --semi-grey-9:     15,23,42 !important;     /* text-slate-900 */

  /* 品牌蓝/紫 (Indigo-600) */
  --semi-blue-0:     238,242,255 !important;
  --semi-blue-1:     224,231,255 !important;
  --semi-blue-2:     199,210,254 !important;
  --semi-blue-3:     165,180,252 !important;
  --semi-blue-4:     129,140,248 !important;
  --semi-blue-5:     79,70,229 !important;    /* 主色 */
  --semi-blue-6:     67,56,202 !important;    /* Hover */
  --semi-blue-7:     55,48,163 !important;    /* Active */
  
  /* 语义色 */
  --semi-green-5:    34,197,94 !important;
  --semi-red-5:      239,68,68 !important;
  --semi-orange-5:   249,115,22 !important;

  /* Semi-UI 组件变量 */
  --semi-color-bg-0:   #f8fafc !important;
  --semi-color-bg-1:   #ffffff !important;
  --semi-color-bg-2:   #f1f5f9 !important;
  --semi-color-bg-3:   #ffffff !important;
  --semi-color-nav-bg: #ffffff !important;
  --semi-color-text-0: #0f172a !important;
  --semi-color-text-1: #334155 !important;
  --semi-color-text-2: #64748b !important;
  --semi-color-fill-0: rgba(0,0,0,0.02) !important;
  --semi-color-primary: #4f46e5 !important;
  --semi-color-primary-hover: #4338ca !important;
  --semi-color-primary-active: #3730a3 !important;
  --semi-color-link: #4f46e5 !important;
  --semi-color-border: #e2e8f0 !important;
  --semi-color-white: #ffffff !important;
  --semi-shadow-elevated: 0 4px 6px -1px rgba(0,0,0,0.05), 0 2px 4px -2px rgba(0,0,0,0.05) !important;
  
  --semi-border-radius-small:  6px !important;
  --semi-border-radius-medium: 8px !important;
  --semi-border-radius-large:  12px !important;
}

/* === 侧边栏现代化 === */
.semi-navigation, .semi-layout-sider {
  background: #ffffff !important;
  border-right: 1px solid #e2e8f0 !important;
}

.semi-navigation-item {
  border-radius: 8px !important;
  margin: 4px 12px !important;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.semi-navigation-item:hover {
  background: #f1f5f9 !important;
}

.semi-navigation-item-active {
  background: #eef2ff !important;
  color: #4f46e5 !important;
  font-weight: 600 !important;
}

.semi-navigation-item-text {
  font-weight: 500 !important;
}

/* === 顶部导航 === */
.semi-layout-header {
  background: rgba(255,255,255,0.8) !important;
  backdrop-filter: blur(12px) !important;
  border-bottom: 1px solid #e2e8f0 !important;
  box-shadow: none !important;
}

/* === 卡片 Glassmorphism === */
.semi-card {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 12px !important;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04) !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.semi-card:hover {
  box-shadow: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.08) !important;
  border-color: #cbd5e1 !important;
}

/* === 表格精致化 === */
.semi-table {
  background: #ffffff !important;
  border-radius: 12px !important;
  border-color: #e2e8f0 !important;
  overflow: hidden !important;
}

.semi-table-thead > tr > th {
  background: #f8fafc !important;
  border-bottom: 1px solid #e2e8f0 !important;
  font-weight: 600 !important;
  color: #475569 !important;
  text-transform: uppercase !important;
  font-size: 0.75rem !important;
  letter-spacing: 0.05em !important;
  padding: 12px 16px !important;
}

.semi-table-tbody > tr > td {
  border-bottom: 1px solid #f1f5f9 !important;
  padding: 14px 16px !important;
  color: #334155 !important;
}

.semi-table-tbody > tr:hover > td {
  background: #f8fafc !important;
}

/* === 按钮现代化 === */
.semi-button {
  border-radius: 8px !important;
  font-weight: 500 !important;
  letter-spacing: 0.01em !important;
  transition: all 0.2s !important;
  box-shadow: none !important;
}

.semi-button-primary {
  background: #4f46e5 !important;
  border-color: #4f46e5 !important;
  color: #ffffff !important;
}

.semi-button-primary:hover {
  background: #4338ca !important;
  border-color: #4338ca !important;
  transform: translateY(-1px) !important;
}

.semi-button-secondary {
  background: #ffffff !important;
  border-color: #e2e8f0 !important;
  color: #475569 !important;
}

.semi-button-secondary:hover {
  background: #f8fafc !important;
  border-color: #cbd5e1 !important;
}

/* === 输入框 & 表单 === */
.semi-input, .semi-input-wrapper {
  border-radius: 8px !important;
  border-color: #e2e8f0 !important;
  background: #ffffff !important;
  transition: all 0.2s !important;
}

.semi-input-wrapper-focus, .semi-input:focus {
  border-color: #4f46e5 !important;
  box-shadow: 0 0 0 3px rgba(79,70,229,0.1) !important;
  outline: none !important;
}

.semi-input-wrapper:hover {
  border-color: #cbd5e1 !important;
}

.semi-form-section-header {
  font-weight: 600 !important;
  color: #0f172a !important;
}

/* === 标签 & 状态 === */
.semi-tag {
  border-radius: 9999px !important;
  padding: 2px 10px !important;
  font-size: 0.75rem !important;
  font-weight: 500 !important;
  border: none !important;
}

.semi-tag-green {
  background: #dcfce7 !important;
  color: #16a34a !important;
}

.semi-tag-red {
  background: #fee2e2 !important;
  color: #dc2626 !important;
}

.semi-tag-blue {
  background: #e0e7ff !important;
  color: #4f46e5 !important;
}

.semi-tag-orange {
  background: #ffedd5 !important;
  color: #ea580c !important;
}

/* === 下拉 & 选择器 === */
.semi-select-option-list, .semi-dropdown-menu {
  border-radius: 10px !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 10px 25px rgba(0,0,0,0.08) !important;
  padding: 6px !important;
}

.semi-select-option {
  border-radius: 6px !important;
  padding: 8px 12px !important;
}

.semi-select-option:hover {
  background: #f8fafc !important;
  color: #4f46e5 !important;
}

/* === Modal / Dialog === */
.semi-modal-content {
  border-radius: 16px !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 20px 40px rgba(0,0,0,0.12) !important;
}

.semi-modal-header {
  border-bottom: 1px solid #f1f5f9 !important;
  padding: 20px 24px !important;
}

/* === 滚动条 === */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* === 隐藏默认元素 === */
.semi-icon, .semi-typography-link {
  color: inherit !important;
}

