/* ============================================
   某某公司 · 工商业储能 - 核心样式
   工业科技 · 数据驱动 · 能源未来
   ============================================ */

/* --- 1. CSS变量 / 设计系统 --- */
:root {
  /* 主色 - 深空科技蓝 */
  --color-primary-50:  #ECFEFF;
  --color-primary-100: #CFFAFE;
  --color-primary-200: #A5F3FC;
  --color-primary-300: #67E8F9;
  --color-primary-400: #22D3EE;
  --color-primary-500: #06B6D4;  /* 主青色 */
  --color-primary-600: #0891B2;
  --color-primary-700: #0E7490;
  --color-primary-800: #155E75;
  --color-primary-900: #164E63;

  /* 背景 */
  --bg-deep:    #020617;  /* 深空黑 */
  --bg-night:   #0A1628;  /* 夜空蓝 */
  --bg-twilight:#0F172A;  /* 暮色蓝 */
  --bg-elevated:#1E293B;  /* 浮起 */
  --bg-paper:   #F8FAFC;  /* 纸白 */
  --bg-snow:    #FFFFFF;
  --bg-soft:    #F1F5F9;

  /* 文字 */
  --text-primary:   #0F172A;
  --text-secondary: #475569;
  --text-muted:     #94A3B8;
  --text-on-dark:   #F8FAFC;
  --text-on-dark-muted: #94A3B8;

  /* 强调色 - 能源橙/收益 */
  --accent-500:  #FB923C;
  --accent-600:  #F97316;
  --accent-glow: rgba(251, 146, 60, 0.4);

  /* 状态色 */
  --success:  #10B981;
  --warning:  #FB923C;
  --danger:   #EF4444;
  --info:     #06B6D4;

  /* 渐变 */
  --gradient-energy:  linear-gradient(135deg, #06B6D4 0%, #0EA5E9 50%, #2563EB 100%);
  --gradient-sunset:  linear-gradient(135deg, #FB923C 0%, #F97316 50%, #DC2626 100%);
  --gradient-night:   linear-gradient(135deg, #020617 0%, #0A1628 50%, #0F2A4A 100%);
  --gradient-light:   linear-gradient(180deg, #F8FAFC 0%, #E2E8F0 100%);
  --gradient-glass:   linear-gradient(135deg, rgba(255,255,255,0.08) 0%, rgba(255,255,255,0.02) 100%);

  /* 字体 */
  --font-display: "Exo", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-body:    "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-mono:    "JetBrains Mono", "Roboto Mono", "SF Mono", Menlo, monospace;

  /* 间距 */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-16: 64px;
  --space-20: 80px;
  --space-24: 96px;
  --space-32: 128px;

  /* 圆角 */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-2xl: 24px;
  --radius-full: 9999px;

  /* 阴影 */
  --shadow-sm:  0 1px 2px rgba(2, 6, 23, 0.06);
  --shadow-md:  0 4px 12px rgba(2, 6, 23, 0.08);
  --shadow-lg:  0 12px 32px rgba(2, 6, 23, 0.12);
  --shadow-xl:  0 24px 60px rgba(2, 6, 23, 0.18);
  --shadow-glow: 0 0 30px rgba(6, 182, 212, 0.4);
  --shadow-glow-orange: 0 0 30px rgba(251, 146, 60, 0.4);

  /* 容器 */
  --container-max: 1280px;
  --container-padding: 24px;

  /* 过渡 */
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 400ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-spring: 500ms cubic-bezier(0.34, 1.56, 0.64, 1);

  /* 头部高度 */
  --header-h: 72px;
}

/* --- 2. 重置 / 基础 --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.65;
  color: var(--text-primary);
  background: var(--bg-paper);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg { display: block; max-width: 100%; height: auto; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, select, textarea { font-family: inherit; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
::selection { background: var(--color-primary-500); color: white; }

/* --- 3. 实用类 --- */
.container { max-width: var(--container-max); margin: 0 auto; padding: 0 var(--container-padding); }
.section { padding: var(--space-24) 0; position: relative; }
.section-sm { padding: var(--space-16) 0; }
.section-dark { background: var(--gradient-night); color: var(--text-on-dark); }
.section-paper { background: var(--bg-paper); }
.section-soft { background: var(--bg-soft); }

.text-gradient {
  background: var(--gradient-energy);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.text-gradient-sunset {
  background: var(--gradient-sunset);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.text-mono { font-family: var(--font-mono); }
.text-muted { color: var(--text-muted); }
.text-center { text-align: center; }

/* --- 4. 排版 --- */
h1, h2, h3, h4, h5, h6 { font-family: var(--font-display); font-weight: 700; line-height: 1.2; color: var(--text-primary); }
.section-dark h1, .section-dark h2, .section-dark h3, .section-dark h4 { color: var(--text-on-dark); }

.h-display { font-size: clamp(2.2rem, 5vw, 4rem); letter-spacing: -0.02em; line-height: 1.1; font-weight: 800; }
.h-1 { font-size: clamp(1.8rem, 3.5vw, 2.8rem); letter-spacing: -0.01em; }
.h-2 { font-size: clamp(1.5rem, 2.5vw, 2rem); }
.h-3 { font-size: clamp(1.2rem, 2vw, 1.5rem); }
.h-4 { font-size: 1.125rem; }

.text-sm { font-size: 0.875rem; }
.text-lg { font-size: 1.125rem; }
.text-xl { font-size: 1.25rem; }
.lead { font-size: 1.125rem; color: var(--text-secondary); line-height: 1.7; }
.section-dark .lead { color: var(--text-on-dark-muted); }

/* --- 5. 按钮 --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  font-size: 14px;
  font-weight: 600;
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
  cursor: pointer;
  white-space: nowrap;
  border: 1px solid transparent;
}
.btn-primary {
  background: var(--gradient-energy);
  color: white;
  box-shadow: 0 4px 12px rgba(6, 182, 212, 0.3);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(6, 182, 212, 0.45);
}
.btn-primary:active { transform: translateY(0); }
.btn-accent {
  background: var(--gradient-sunset);
  color: white;
  box-shadow: 0 4px 12px rgba(251, 146, 60, 0.3);
}
.btn-accent:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(251, 146, 60, 0.45);
}
.btn-ghost {
  background: transparent;
  color: var(--text-primary);
  border: 1.5px solid #E2E8F0;
}
.btn-ghost:hover {
  border-color: var(--color-primary-500);
  color: var(--color-primary-600);
  background: var(--color-primary-50);
}
.section-dark .btn-ghost { color: white; border-color: rgba(255,255,255,0.2); }
.section-dark .btn-ghost:hover { border-color: var(--color-primary-400); color: var(--color-primary-300); background: rgba(6, 182, 212, 0.1); }
.btn-glow {
  background: var(--gradient-energy);
  color: white;
  position: relative;
  box-shadow: 0 4px 20px rgba(6, 182, 212, 0.4);
}
.btn-glow::before {
  content: '';
  position: absolute;
  inset: -2px;
  background: var(--gradient-energy);
  filter: blur(12px);
  opacity: 0.5;
  z-index: -1;
  border-radius: var(--radius-md);
}
.btn-lg { padding: 16px 32px; font-size: 15px; }
.btn-sm { padding: 8px 16px; font-size: 13px; }

/* 按钮内的箭头动画 */
.btn .arrow { display: inline-block; transition: transform var(--transition-base); }
.btn:hover .arrow { transform: translateX(4px); }

/* --- 6. 卡片 --- */
.card {
  background: white;
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  border: 1px solid #E2E8F0;
  transition: all var(--transition-base);
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-primary-300);
}
.card-glass {
  background: var(--gradient-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  color: var(--text-on-dark);
}
.card-dark {
  background: linear-gradient(135deg, #0F172A 0%, #1E293B 100%);
  border: 1px solid rgba(6, 182, 212, 0.2);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  color: var(--text-on-dark);
}
.card-feature {
  position: relative;
  padding: var(--space-8);
  overflow: hidden;
}
.card-feature::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--gradient-energy);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-slow);
}
.card-feature:hover::before { transform: scaleX(1); }

/* --- 7. 表单 --- */
.input, .select {
  width: 100%;
  padding: 12px 16px;
  font-size: 14px;
  background: var(--bg-snow);
  border: 1.5px solid #E2E8F0;
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
  color: var(--text-primary);
}
.input:focus, .select:focus {
  outline: none;
  border-color: var(--color-primary-500);
  box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}
.input-dark, .select-dark {
  background: var(--bg-night);
  border: 1.5px solid rgba(6, 182, 212, 0.2);
  color: var(--text-on-dark);
}
.input-dark:focus, .select-dark:focus {
  border-color: var(--color-primary-400);
  box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.2);
}
.label {
  display: block;
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
}
.section-dark .label { color: var(--text-on-dark-muted); }

/* --- 8. 网格 --- */
.grid { display: grid; gap: var(--space-6); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-auto { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }

/* --- 9. 徽章 / 标签 --- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 500;
  border-radius: var(--radius-full);
  background: var(--color-primary-50);
  color: var(--color-primary-700);
}
.badge-dark {
  background: rgba(6, 182, 212, 0.15);
  color: var(--color-primary-300);
  border: 1px solid rgba(6, 182, 212, 0.3);
}
.badge-success { background: rgba(16, 185, 129, 0.15); color: var(--success); }
.badge-warning { background: rgba(251, 146, 60, 0.15); color: var(--warning); }
.badge-danger { background: rgba(239, 68, 68, 0.15); color: var(--danger); }

/* --- 10. 装饰元素 --- */
.divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, #E2E8F0, transparent);
  margin: var(--space-12) 0;
}
.section-dark .divider { background: linear-gradient(90deg, transparent, rgba(6, 182, 212, 0.3), transparent); }

.bg-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  z-index: 0;
}

/* --- 11. 加载/状态点 --- */
.dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
  position: relative;
}
.dot::before {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  background: var(--success);
  opacity: 0.4;
  animation: pulse-ring 2s ease-out infinite;
}
.dot-warning { background: var(--warning); }
.dot-warning::before { background: var(--warning); }
.dot-danger { background: var(--danger); }
.dot-danger::before { background: var(--danger); }

/* --- 12. 数字大屏风格 --- */
.metric {
  font-family: var(--font-display);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}
.metric-huge { font-size: clamp(2.5rem, 6vw, 5rem); }
.metric-big { font-size: clamp(1.8rem, 4vw, 3rem); }
.metric-mid { font-size: clamp(1.4rem, 3vw, 2rem); }

/* --- 13. 工具类 --- */
.flex { display: flex; }
.flex-col { display: flex; flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.items-end { align-items: flex-end; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }
.gap-1 { gap: var(--space-1); }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-6 { gap: var(--space-6); }
.gap-8 { gap: var(--space-8); }
.mb-2 { margin-bottom: var(--space-2); }
.mb-4 { margin-bottom: var(--space-4); }
.mb-6 { margin-bottom: var(--space-6); }
.mb-8 { margin-bottom: var(--space-8); }
.mb-12 { margin-bottom: var(--space-12); }
.mt-4 { margin-top: var(--space-4); }
.mt-8 { margin-top: var(--space-8); }
.mt-12 { margin-top: var(--space-12); }
.mx-auto { margin-left: auto; margin-right: auto; }
.w-full { width: 100%; }
.relative { position: relative; }
.overflow-hidden { overflow: hidden; }
.cursor-pointer { cursor: pointer; }

/* --- 14. 滚动指示器 --- */
.scroll-indicator {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  width: 26px;
  height: 42px;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-radius: 14px;
  display: flex;
  justify-content: center;
  padding-top: 8px;
}
.scroll-indicator::before {
  content: '';
  width: 3px;
  height: 8px;
  background: var(--color-primary-400);
  border-radius: 2px;
  animation: scroll-bounce 2s ease-in-out infinite;
}
