/* ========================================
   百工AI · 青春活力主题 (Vibrant Youth)
   ======================================== */

/* === 基础背景 === */
body {
  background: linear-gradient(170deg, #eef2ff 0%, #f5f3ff 40%, #fdf2f8 70%, #f0f9ff 100%) !important;
  color: #1e293b !important;
}

/* === 导航栏 === */
.topnav {
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 50%, #c026d3 100%) !important;
  border-bottom: none !important;
  box-shadow: 0 4px 24px rgba(79,70,229,0.35) !important;
}
.topnav .logo, .topnav .nav-brand, .topnav .nav-brand .zh { color: #fff !important; text-shadow: 0 0 12px rgba(255,255,255,0.3); }
.topnav .logo span { color: #fbbf24 !important; }
.topnav .nav-links a, .topnav nav a, .topnav a { color: rgba(255,255,255,0.9) !important; font-weight: 500 !important; }
.topnav .nav-links a:hover, .topnav .nav-links a.active, .topnav nav a:hover, .topnav nav a.active, .topnav a:hover { color: #fff !important; background: rgba(255,255,255,0.12) !important; }
.topnav .nav-right { color: #fff !important; }

/* === Hero区域 === */
.hero {
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 25%, #c026d3 50%, #f43f5e 75%, #fb923c 100%) !important;
}
.hero::before {
  background: radial-gradient(ellipse at center, rgba(255,255,255,0.08) 0%, transparent 70%) !important;
}
.hero .subtitle { color: rgba(255,255,255,0.92) !important; }
.hero .en-title { color: rgba(255,255,255,0.7) !important; }
.hero .badge {
  background: rgba(255,255,255,0.2) !important;
  border-color: rgba(255,255,255,0.35) !important;
  color: #fff !important;
  backdrop-filter: blur(4px);
}
.hero .badge.gold {
  background: rgba(251,191,36,0.25) !important;
  border-color: rgba(251,191,36,0.5) !important;
  color: #fde68a !important;
}
.hero .badge.green {
  background: rgba(74,222,128,0.2) !important;
  border-color: rgba(74,222,128,0.4) !important;
  color: #bbf7d0 !important;
}

/* === 通用卡片 === */
.paper-card, .concept-card, .proof-box, .relation-diagram,
.post-item, .comment-item, .comment-input {
  background: #ffffff !important;
  border-color: #e2e8f0 !important;
  box-shadow: 0 2px 16px rgba(79,70,229,0.07) !important;
}
.paper-card:hover, .concept-card:hover {
  border-color: #818cf8 !important;
  box-shadow: 0 6px 24px rgba(79,70,229,0.15) !important;
}

/* === 区块标题 === */
.section-title { color: #1e293b !important; }

/* === 论文卡片细节 === */
.paper-card .paper-tag {
  background: linear-gradient(135deg, #fbbf24, #f59e0b) !important;
  color: #78350f !important;
  font-size: 12px !important;
}
.paper-card .paper-title { color: #1e293b !important; }
.paper-card .paper-title-en { color: #64748b !important; }
.paper-card .paper-meta { color: #64748b !important; font-size: 13px !important; }
.paper-card .paper-abstract {
  background: #f8fafc !important;
  border-left-color: #818cf8 !important;
  color: #475569 !important;
  font-size: 13px !important;
}

/* === 概念卡片 === */
.concept-card {
  border: 1px solid #e2e8f0 !important;
  background: #fff !important;
}
.concept-card:hover {
  border-color: #818cf8 !important;
  box-shadow: 0 6px 20px rgba(79,70,229,0.12) !important;
}
.concept-card .cc-name { color: #1e293b !important; }
.concept-card .cc-name-en { color: #94a3b8 !important; font-size: 11px !important; }
.concept-card .cc-desc { color: #64748b !important; font-size: 12px !important; }
.concept-card .cc-formula {
  background: #f1f5f9 !important;
  color: #7c3aed !important;
  font-size: 12px !important;
}

/* === 概念关系图 === */
.relation-box {
  background: linear-gradient(135deg, #ede9fe, #e0e7ff) !important;
  border-color: #a78bfa !important;
}
.relation-box .rb-title { color: #7c3aed !important; }
.relation-box .rb-name { color: #1e293b !important; }
.relation-arrow { color: #7c3aed !important; }

/* === 时间戳确权 === */
.proof-box {
  border-color: rgba(34,197,94,0.3) !important;
  background: linear-gradient(135deg, #f0fdf4, #ecfdf5) !important;
}
.proof-box h3 { color: #16a34a !important; }
.proof-item { border-bottom-color: #e2e8f0 !important; color: #475569 !important; }
.proof-item .label { color: #64748b !important; }
.proof-item .value { color: #1e293b !important; }

/* === 全文区域 === */
.fullpaper-toggle {
  background: linear-gradient(135deg, #4f46e5, #7c3aed) !important;
  border: none !important;
  color: #fff !important;
}
.fullpaper-toggle:hover {
  background: linear-gradient(135deg, #6366f1, #8b5cf6) !important;
}
.fullpaper-content {
  background: #fff !important;
  border-color: #e2e8f0 !important;
}
.fullpaper-content h1 { color: #1e293b !important; }
.fullpaper-content h2 { color: #4f46e5 !important; border-bottom-color: #e2e8f0 !important; }
.fullpaper-content h3, .fullpaper-content h4 { color: #6366f1 !important; }
.fullpaper-content p { color: #374151 !important; font-size: 14px !important; }
.fullpaper-content table { font-size: 13px !important; }
.fullpaper-content th { background: #f1f5f9 !important; color: #4f46e5 !important; border-color: #e2e8f0 !important; }
.fullpaper-content td { border-color: #e2e8f0 !important; color: #374151 !important; }
.fullpaper-content ul, .fullpaper-content ol { color: #374151 !important; font-size: 14px !important; }
.fullpaper-content code { background: #f1f5f9 !important; color: #7c3aed !important; font-size: 13px !important; }
.fullpaper-content pre { background: #f8fafc !important; }
.fullpaper-content pre code { background: none !important; }
.fullpaper-content blockquote {
  border-left-color: #818cf8 !important;
  background: #f5f3ff !important;
  color: #64748b !important;
}
.fullpaper-content hr { border-top-color: #e2e8f0 !important; }

/* === 按钮统一 === */
.btn-primary {
  background: linear-gradient(135deg, #4f46e5, #7c3aed) !important;
  color: #fff !important;
  box-shadow: 0 2px 10px rgba(79,70,229,0.3);
}
.btn-primary:hover {
  background: linear-gradient(135deg, #6366f1, #8b5cf6) !important;
  transform: translateY(-1px);
}
.btn-outline {
  background: transparent !important;
  border: 1px solid #c7d2fe !important;
  color: #4f46e5 !important;
}
.btn-outline:hover {
  border-color: #4f46e5 !important;
  background: #eef2ff !important;
  color: #4338ca !important;
}

/* === 表单/输入 === */
input, select, textarea, [contenteditable=true] {
  background: #fff !important;
  border-color: #d1d5db !important;
  color: #1e293b !important;
}
input:focus, select:focus, textarea:focus, [contenteditable=true]:focus {
  border-color: #818cf8 !important;
  box-shadow: 0 0 0 3px rgba(129,140,248,0.15) !important;
}

/* === 论坛Tab === */
.forum-tab {
  background: transparent !important;
  color: #64748b !important;
  border-bottom: 2px solid transparent !important;
}
.forum-tab.active {
  color: #4f46e5 !important;
  border-bottom-color: #4f46e5 !important;
}
.forum-tab:hover { color: #4f46e5 !important; }

/* === 帖子列表 === */
.post-item {
  background: #fff !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 10px !important;
  transition: all .2s;
}
.post-item:hover {
  border-color: #818cf8 !important;
  box-shadow: 0 4px 16px rgba(79,70,229,0.1) !important;
}
.pi-title { color: #1e293b !important; }
.pi-meta { color: #94a3b8 !important; }
.pi-content { color: #64748b !important; }
.pi-category {
  background: #eef2ff !important;
  color: #4f46e5 !important;
}

/* === 评论 === */
.comment-item {
  background: #fff !important;
  border: 1px solid #e2e8f0 !important;
}
.ci-author { color: #1e293b !important; }
.ci-date { color: #94a3b8 !important; }
.ci-text { color: #475569 !important; }

/* === 首发声明 === */
.first-publish-notice {
  background: #fffbeb !important;
  border: 1px solid #fde68a !important;
  color: #92400e !important;
}

/* === 登录提示 === */
.login-hint {
  background: #eff6ff !important;
  border-color: #93c5fd !important;
  color: #1e40af !important;
}

/* === 页脚 === */
footer {
  background: #f8fafc !important;
  color: #94a3b8 !important;
  border-top: 1px solid #e2e8f0 !important;
}
footer .copyright { color: #94a3b8 !important; }
footer a { color: #6366f1 !important; }

/* === 链接 === */
a { color: #4f46e5 !important; }
a:hover { color: #7c3aed !important; }

/* === 空状态 === */
.empty-state { color: #94a3b8 !important; }

/* === 浮动管家按钮 === */
#butler-widget a {
  background: linear-gradient(135deg, #4f46e5, #c026d3) !important;
  box-shadow: 0 4px 20px rgba(192,38,211,0.4) !important;
}

/* === 工具栏 === */
.editor-toolbar, .toolbar-row {
  background: #f8fafc !important;
  border-color: #e2e8f0 !important;
}
.editor-toolbar button, .toolbar-row button {
  color: #64748b !important;
}
.editor-toolbar button:hover, .toolbar-row button:hover {
  color: #4f46e5 !important;
  background: #eef2ff !important;
}

/* === 概念卡片编辑 === */
.cc-edit {
  background: rgba(79,70,229,0.1) !important;
  border-color: rgba(79,70,229,0.25) !important;
  color: #4f46e5 !important;
}
.cc-edit:hover { background: rgba(79,70,229,0.2) !important; }
.concept-card.editing {
  border-color: #f59e0b !important;
  box-shadow: 0 0 0 2px rgba(245,158,11,0.15) !important;
}
.concept-card.editing .cc-edit {
  background: rgba(245,158,11,0.15) !important;
  border-color: rgba(245,158,11,0.3) !important;
  color: #d97706 !important;
}
.cc-input, .cc-textarea {
  background: #fff !important;
  border-color: #d1d5db !important;
  color: #1e293b !important;
}
.cc-input:focus, .cc-textarea:focus {
  border-color: #818cf8 !important;
  box-shadow: 0 0 0 2px rgba(129,140,248,0.15) !important;
}

/* === 滚动条美化 === */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #f1f5f9; }
::-webkit-scrollbar-thumb { background: #c7d2fe; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #818cf8; }

/* === 选择文字颜色 === */
::selection { background: #c7d2fe; color: #1e293b; }

/* === 下拉菜单适配 === */
.topnav .subnav, .topnav .nav-item .subnav { background: rgba(79,70,229,0.95) !important; border-color: rgba(129,140,248,0.3) !important; }
.topnav .subnav a { color: rgba(255,255,255,0.85) !important; }
.topnav .subnav a:hover { color: #fff !important; background: rgba(255,255,255,0.15) !important; }
