/* ========================================
   微智AI商学院官网 - 全局样式
   ======================================== */

:root {
  --primary: #1565C0;
  --primary-dark: #0D47A1;
  --primary-light: #1976D2;
  --accent: #4FC3F7;
  --accent-glow: #29B6F6;
  --bg: #F8FAFC;
  --bg-soft: #EFF6FB;
  --surface: #FFFFFF;
  --text: #0F172A;
  --text-soft: #475569;
  --text-muted: #94A3B8;
  --border: #E2E8F0;
  --success: #10B981;
  --warning: #F59E0B;
  --pending: #94A3B8;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.05);
  --shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
  --shadow-lg: 0 12px 32px rgba(15, 23, 42, 0.10);
  --shadow-blue: 0 8px 24px rgba(21, 101, 192, 0.20);
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --container: 1200px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  font-size: 17px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

input, textarea {
  font-family: inherit;
  font-size: inherit;
}

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* ========================================
   导航栏
   ======================================== */

.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border);
}

.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  height: 72px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
}

.brand-logo {
  width: 48px;
  height: 48px;
  border-radius: 13px;
  object-fit: cover;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.brand-title {
  font-size: 21px;
  color: var(--primary-dark);
  font-weight: 800;
  letter-spacing: 0.5px;
}

.brand-sub {
  font-size: 12.5px;
  color: var(--text-muted);
  font-weight: 500;
  letter-spacing: 1.5px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  padding: 5px;
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.045);
  border: 1px solid rgba(15, 23, 42, 0.05);
}

.nav-links a {
  display: inline-flex;
  align-items: center;
  padding: 9px 18px;
  border-radius: 10px;
  color: var(--text-soft);
  font-weight: 500;
  font-size: 14.5px;
  letter-spacing: 0.3px;
  transition: all 0.25s ease;
}

.nav-links a:hover {
  color: var(--primary);
  background: rgba(255, 255, 255, 0.85);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
}

.nav-links a.active {
  color: #fff;
  background: var(--primary);
  font-weight: 600;
  box-shadow: 0 4px 14px rgba(21, 101, 192, 0.32);
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  background: var(--primary);
  color: #fff !important;
  border-radius: 10px;
  font-weight: 600;
  font-size: 14px;
  box-shadow: var(--shadow-blue);
  transition: all 0.2s ease;
}

.nav-cta:hover {
  background: var(--primary-dark) !important;
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(21, 101, 192, 0.30);
}

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: var(--bg-soft);
  color: var(--primary);
}

/* 导航栏头像（扁平化） */
.nav-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  margin-left: 6px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(21, 101, 192, 0.25);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.nav-avatar:hover {
  transform: translateY(-1px) scale(1.05);
  box-shadow: 0 6px 16px rgba(21, 101, 192, 0.38);
}

.nav-avatar.active {
  box-shadow: 0 0 0 3px rgba(21, 101, 192, 0.18), 0 4px 12px rgba(21, 101, 192, 0.30);
}

.nav-avatar svg { display: block; }

/* ========================================
   通用组件
   ======================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 15px;
  transition: all 0.2s ease;
  cursor: pointer;
  white-space: nowrap;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
  box-shadow: var(--shadow-blue);
}

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(21, 101, 192, 0.30);
}

.btn-ghost {
  background: #fff;
  color: var(--primary);
  border: 1.5px solid var(--primary);
}

.btn-ghost:hover {
  background: var(--bg-soft);
}

.btn-xiaozhi {
  background: linear-gradient(135deg, #1565C0 0%, #42A5F5 100%);
  color: #fff;
  box-shadow: 0 8px 24px rgba(21, 101, 192, 0.28);
  border: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.btn-xiaozhi:hover {
  background: linear-gradient(135deg, #0D47A1 0%, #1E88E5 100%);
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(21, 101, 192, 0.32);
}

.btn-xiaozhi-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
  background: transparent;
  flex-shrink: 0;
}

.btn-large {
  padding: 16px 32px;
  font-size: 16px;
  border-radius: 12px;
}

.section {
  padding: 80px 0;
}

.section-sm {
  padding: 56px 0;
}

.section-title {
  text-align: center;
  margin-bottom: 48px;
}

.section-title .eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 12px;
  background: var(--bg-soft);
  padding: 6px 14px;
  border-radius: 999px;
}

.section-title h2 {
  font-size: 36px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.5px;
  margin-bottom: 12px;
}

.section-title p {
  font-size: 16px;
  color: var(--text-soft);
  max-width: 640px;
  margin: 0 auto;
}

/* 卡片 */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: all 0.3s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(21, 101, 192, 0.20);
}

/* 标签 */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
}

.tag-primary { background: rgba(21, 101, 192, 0.10); color: var(--primary); }
.tag-success { background: rgba(16, 185, 129, 0.10); color: var(--success); }
.tag-warning { background: rgba(245, 158, 11, 0.10); color: var(--warning); }
.tag-pending { background: rgba(148, 163, 184, 0.15); color: var(--pending); }

/* ========================================
   页脚
   ======================================== */

.footer {
  background: linear-gradient(180deg, #0a1929 0%, #051120 100%);
  color: #94A3B8;
  padding: 56px 0 24px;
  margin-top: 80px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
}

.footer-brand img {
  width: 78px;
  height: 78px;
  border-radius: 50%;
  background: transparent;
  object-fit: contain;
  flex-shrink: 0;
}

.footer-brand-text {
  color: #fff;
  font-weight: 700;
  font-size: 22px;
  line-height: 1.3;
}

.footer-brand-en {
  display: block;
  color: rgba(255,255,255,0.72);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.6px;
  margin-top: 3px;
  text-transform: uppercase;
}

.footer-tagline {
  font-size: 14px;
  line-height: 1.7;
  margin-bottom: 16px;
}

.footer-col h4 {
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 16px;
  letter-spacing: 0.5px;
}

.footer-col ul {
  list-style: none;
}

.footer-col li {
  margin-bottom: 10px;
  font-size: 14px;
}

.footer-col a {
  color: #94A3B8;
  transition: color 0.2s;
}

.footer-col a:hover { color: var(--accent); }

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  flex-wrap: wrap;
  gap: 12px;
}

/* ========================================
   悬浮小智（无圆形背景，气泡箭头指向头像）
   ======================================== */

.floating-xiaozhi {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 999;
  display: flex;
  flex-direction: row;
  align-items: flex-end;
  gap: 12px;
}

.floating-xiaozhi .avatar-btn {
  display: block;
  width: 92px;
  height: 92px;
  cursor: pointer;
  position: relative;
  transition: transform 0.2s ease;
  animation: float 3.2s ease-in-out infinite;
  background: transparent !important;
  border-radius: 0 !important;
  padding: 0 !important;
  box-shadow: none !important;
}

.floating-xiaozhi .avatar-btn::after,
.floating-xiaozhi .avatar-btn::before {
  display: none !important;
}

.floating-xiaozhi .avatar-btn:hover {
  transform: scale(1.06);
}

.floating-xiaozhi .avatar-btn img {
  width: 100%;
  height: 100%;
  border-radius: 0;
  object-fit: contain;
  background: transparent;
  filter: drop-shadow(0 8px 20px rgba(21, 101, 192, 0.35));
}

.floating-xiaozhi .bubble {
  position: relative;
  background: #fff;
  padding: 12px 16px;
  border-radius: 16px 16px 4px 16px;
  font-size: 14px;
  color: var(--text);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.14);
  max-width: 220px;
  font-weight: 500;
  line-height: 1.5;
  animation: bubblePop 0.5s ease 0.6s both;
  margin-bottom: 20px;
}

.floating-xiaozhi .bubble::after {
  content: "";
  position: absolute;
  right: -8px;
  bottom: 12px;
  width: 14px;
  height: 14px;
  background: #fff;
  transform: rotate(45deg);
  border-radius: 0 4px 0 0;
  box-shadow: 2px -2px 4px rgba(15, 23, 42, 0.04);
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

@keyframes pulse {
  0% { transform: scale(1); opacity: 0.6; }
  100% { transform: scale(1.4); opacity: 0; }
}

@keyframes bubblePop {
  0% { transform: scale(0.5) translateY(10px); opacity: 0; }
  100% { transform: scale(1) translateY(0); opacity: 1; }
}

/* ========================================
   响应式
   ======================================== */

@media (max-width: 960px) {
  .nav-links { display: none; }
  .nav-toggle { display: inline-flex; }
  .section { padding: 56px 0; }
  .section-title h2 { font-size: 28px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .floating-xiaozhi { right: 16px; bottom: 16px; }
  .floating-xiaozhi .avatar-btn { width: 76px; height: 76px; }
  .floating-xiaozhi .bubble { font-size: 13px; padding: 10px 14px; max-width: 180px; margin-bottom: 14px; }
}

/* 桌面端：导航按钮整体居中，布局更对称简约 */
/* 注意：限定 .navbar nav，避免命中个人中心 .uc-nav 等其他 nav 元素 */
@media (min-width: 961px) {
  .navbar nav {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
  }
}

@media (max-width: 640px) {
  .container { padding: 0 16px; }
  .navbar-inner { height: 60px; }
  .brand-logo { width: 40px; height: 40px; }
  .brand-title { font-size: 18px; }
  .brand-sub { font-size: 11px; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; text-align: center; }
}

/* 滚动条美化 */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: #CBD5E1; border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary-light); }
