/* ============================================
   FoxAPI × Claude Design System
   全站统一 Claude 桌面端配色
   ============================================ */

:root {
  --fox-canvas: #faf9f5;
  --fox-surface-soft: #f5f0e8;
  --fox-surface-card: #efe9de;
  --fox-hairline: #e6dfd8;
  --fox-hairline-soft: #ebe6df;
  --fox-ink: #141413;
  --fox-body: #3d3d3a;
  --fox-body-strong: #252523;
  --fox-muted: #6c6a64;
  --fox-muted-soft: #8e8b82;
  --fox-primary: #cc785c;
  --fox-primary-active: #a9583e;
  --fox-surface-dark: #181715;
  --fox-surface-dark-elevated: #252320;
  --fox-surface-dark-soft: #1f1e1b;
  --fox-on-dark: #faf9f5;
  --fox-on-dark-soft: #a09d96;
}

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@400;500;600&family=Inter:wght@300;400;500;600&family=JetBrains+Mono:wght@400;500&display=swap');

/* === 全局 — Claude 奶油画布 === */
html:not(.dark) body {
  background: var(--fox-canvas) !important;
  color: var(--fox-body) !important;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
  -webkit-font-smoothing: antialiased;
}

/* 登录/注册页也用同样背景 */
html:not(.dark) div.relative.flex.min-h-screen,
html:not(.dark) div[class*="min-h-screen"] {
  background: var(--fox-canvas) !important;
}

/* 导航栏 */
html:not(.dark) nav,
html:not(.dark) header {
  background: rgba(250, 249, 245, 0.85) !important;
  backdrop-filter: blur(20px) !important;
  border-bottom: 1px solid var(--fox-hairline) !important;
}

/* 卡片 — Claude surface card */
html:not(.dark) .card-glass,
html:not(.dark) div.card-glass,
html:not(.dark) [class*="card"] {
  background: var(--fox-surface-card) !important;
  border: 1px solid var(--fox-hairline-soft) !important;
  border-radius: 12px !important;
  box-shadow: none !important;
  color: var(--fox-ink) !important;
}

/* 输入框 */
html:not(.dark) input,
html:not(.dark) textarea,
html:not(.dark) select {
  background: var(--fox-surface-soft) !important;
  border: 1px solid var(--fox-hairline) !important;
  border-radius: 8px !important;
  color: var(--fox-ink) !important;
}

html:not(.dark) input:focus,
html:not(.dark) textarea:focus {
  border-color: var(--fox-primary) !important;
  box-shadow: 0 0 0 3px rgba(204, 120, 92, 0.12) !important;
  outline: none !important;
}

html:not(.dark) input::placeholder {
  color: var(--fox-muted-soft) !important;
}

/* 按钮 — 珊瑚色 */
button[type="submit"],
.btn-primary,
button[class*="primary"] {
  background: var(--fox-primary) !important;
  color: #ffffff !important;
  border: none !important;
  border-radius: 8px !important;
  font-weight: 600 !important;
  transition: all 0.2s ease !important;
}

button[type="submit"]:hover,
.btn-primary:hover {
  background: var(--fox-primary-active) !important;
}

/* 表格 */
html:not(.dark) th {
  background: var(--fox-surface-soft) !important;
  color: var(--fox-body-strong) !important;
  border-color: var(--fox-hairline-soft) !important;
}

html:not(.dark) td {
  border-color: var(--fox-hairline-soft) !important;
  color: var(--fox-body) !important;
}

html:not(.dark) tr:hover td {
  background: var(--fox-surface-soft) !important;
}

/* 下拉/弹窗 */
html:not(.dark) [class*="dropdown"],
html:not(.dark) [class*="modal"],
html:not(.dark) [class*="dialog"],
html:not(.dark) [class*="menu"] {
  background: var(--fox-canvas) !important;
  border: 1px solid var(--fox-hairline) !important;
  border-radius: 12px !important;
  box-shadow: 0 4px 24px rgba(20, 20, 19, 0.08) !important;
  color: var(--fox-ink) !important;
}

/* 分隔线 */
html:not(.dark) hr,
html:not(.dark) [class*="divider"] {
  border-color: var(--fox-hairline-soft) !important;
}

/* === 深色模式 === */
html.dark body,
html.dark {
  background: var(--fox-surface-dark) !important;
  color: var(--fox-on-dark) !important;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

html.dark nav,
html.dark header,
html.dark [class*="sidebar"],
html.dark [class*="nav"] {
  background: rgba(24, 23, 21, 0.9) !important;
  backdrop-filter: blur(20px) !important;
  border-color: rgba(160, 157, 150, 0.1) !important;
  color: var(--fox-on-dark) !important;
}

html.dark [class*="card"],
html.dark [class*="panel"],
html.dark [class*="box"] {
  background: var(--fox-surface-dark-elevated) !important;
  border: 1px solid rgba(160, 157, 150, 0.08) !important;
  border-radius: 12px !important;
  color: var(--fox-on-dark) !important;
}

html.dark input,
html.dark textarea,
html.dark select {
  background: var(--fox-surface-dark-soft) !important;
  border: 1px solid rgba(160, 157, 150, 0.15) !important;
  border-radius: 8px !important;
  color: var(--fox-on-dark) !important;
}

html.dark input:focus,
html.dark textarea:focus {
  border-color: var(--fox-primary) !important;
  box-shadow: 0 0 0 3px rgba(204, 120, 92, 0.15) !important;
}

html.dark button { color: var(--fox-on-dark) !important; }
html.dark a { color: var(--fox-primary) !important; }
html.dark a:hover { color: var(--fox-primary-active) !important; }

html.dark [class*="dropdown"],
html.dark [class*="modal"],
html.dark [class*="dialog"],
html.dark [class*="menu"] {
  background: var(--fox-surface-dark-elevated) !important;
  border: 1px solid rgba(160, 157, 150, 0.1) !important;
  color: var(--fox-on-dark) !important;
  backdrop-filter: blur(20px) !important;
}

/* === 品牌色 === */
.text-primary-500 { color: var(--fox-primary) !important; }
.bg-primary-500 { background-color: var(--fox-primary) !important; }
.bg-gradient-primary { background: linear-gradient(135deg, var(--fox-primary) 0%, var(--fox-primary-active) 100%) !important; }

/* === 字体 === */
h1, h2 {
  font-family: 'Cormorant Garamond', Georgia, serif !important;
  font-weight: 500 !important;
  letter-spacing: -0.02em !important;
  color: var(--fox-ink) !important;
}
html.dark h1, html.dark h2 { color: var(--fox-on-dark) !important; }

code, pre, .mono {
  font-family: 'JetBrains Mono', ui-monospace, monospace !important;
}

/* === 滚动条 === */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--fox-hairline); border-radius: 3px; }
html.dark ::-webkit-scrollbar-thumb { background: rgba(160, 157, 150, 0.2); }

::selection { background: rgba(204, 120, 92, 0.2); }
html.dark ::selection { background: rgba(204, 120, 92, 0.25); }

/* === 隐藏元素 === */
[class*="totp"], [class*="2fa"], [class*="two-factor"], [class*="security-key"],
a[href*="totp"], a[href*="2fa"] { display: none !important; }

[class*="wechat"], [class*="weixin"], [class*="wx-login"], [class*="wx-bind"],
a[href*="wechat"], a[href*="weixin"],
img[alt*="微信"], img[alt*="wechat"] { display: none !important; }

[class*="contact"], [class*="support"], [class*="customer-service"],
a[href*="contact"], a[href*="support"] { display: none !important; }

/* === 过渡 === */
button, a, input, select, textarea,
[class*="card"], [class*="btn"] {
  transition: all 0.2s ease !important;
}

/* === 登录/注册页 — 去掉装饰圆圈和卡片背景 === */
div[class*="absolute"][class*="-right-40"],
div[class*="absolute"][class*="-bottom-40"],
div[class*="absolute"][class*="left-1/2"] {
  display: none !important;
}

.card-glass.rounded-2xl,
div.card-glass {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 2rem 0 !important;
}
