/* ==========================================================================
   宝贝云官网 (BabyCloud) - 核心样式表 (style.css)
   极简无依赖、秒开性能、完美响应式、高对比度无障碍设计
   ========================================================================== */

:root {
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --primary-light: #eff6ff;
  --secondary: #0ea5e9;
  --accent: #f59e0b;
  --text-main: #0f172a;
  --text-muted: #475569;
  --text-light: #64748b;
  --bg-main: #ffffff;
  --bg-alt: #f8fafc;
  --bg-card: #ffffff;
  --border-color: #e2e8f0;
  --border-focus: #2563eb;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.05);
  --container-max: 1200px;
  --nav-height: 72px;
}

/* 基础重置 */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-main);
  background-color: var(--bg-main);
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* 辅助功能：跳转到主要内容 */
.skip-link {
  position: absolute;
  top: -999px;
  left: 1rem;
  background: var(--primary);
  color: #ffffff;
  padding: 0.75rem 1.25rem;
  z-index: 1000;
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-weight: 600;
}

.skip-link:focus {
  top: 1rem;
}

/* 键盘焦点样式 */
:focus-visible {
  outline: 3px solid var(--border-focus);
  outline-offset: 2px;
}

/* 锚点滚动避开固定页眉 */
section, [id] {
  scroll-margin-top: calc(var(--nav-height) + 1.5rem);
}

/* 容器规范 */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.25rem;
  padding-right: 1.25rem;
}

/* 导航栏 Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-height);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--primary);
  text-decoration: none;
}

.brand-logo svg,
.brand-logo-img {
  width: 38px;
  height: 38px;
  object-fit: contain;
  flex-shrink: 0;
  display: inline-block;
  vertical-align: middle;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.12));
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.nav-links {
  display: flex;
  align-items: center;
  list-style: none;
  gap: 1.25rem;
}

.nav-link {
  text-decoration: none;
  color: var(--text-muted);
  font-weight: 500;
  padding: 0.5rem 0.25rem;
  transition: color 0.2s ease;
}

.nav-link:hover, .nav-link:focus {
  color: var(--primary);
}

/* 按钮基础与 CTA 规范 (触摸区 >= 44x44px) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  min-width: 44px;
  padding: 0.65rem 1.5rem;
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.2s ease;
  text-align: center;
  line-height: 1.2;
}

.btn-primary {
  background-color: var(--primary);
  color: #ffffff;
}

.btn-primary:hover, .btn-primary:focus {
  background-color: var(--primary-hover);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

.btn-secondary {
  background-color: var(--primary-light);
  color: var(--primary);
  border-color: #bfdbfe;
}

.btn-secondary:hover, .btn-secondary:focus {
  background-color: #dbeafe;
}

.btn-accent {
  background-color: #ea580c;
  color: #ffffff;
}

.btn-accent:hover, .btn-accent:focus {
  background-color: #c2410c;
}

/* 主视觉区 Hero Section - 4K 动态场景背景与沉浸式光效 */
.hero-section {
  position: relative;
  padding: 5.5rem 0 4.5rem;
  background-color: #0b1120;
  color: #ffffff;
  text-align: center;
  overflow: hidden;
}

/* 4K 动态背景图像层 (慢速平滑运镜动效) */
.hero-section::before {
  content: "";
  position: absolute;
  top: -5%;
  left: -5%;
  width: 110%;
  height: 110%;
  background: url("hero-bg-4k.jpg") center center / cover no-repeat;
  filter: brightness(0.85) contrast(1.05);
  animation: heroKenBurns 24s ease-in-out infinite alternate;
  transform-origin: center center;
  z-index: 0;
  will-change: transform;
}

/* 动态环境光波与暗化遮罩（保护文本对比度达 4.5:1 以上） */
.hero-section::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 50% 25%, rgba(14, 165, 233, 0.18) 0%, transparent 60%),
    radial-gradient(circle at 80% 75%, rgba(99, 102, 241, 0.22) 0%, transparent 50%),
    linear-gradient(180deg, rgba(11, 17, 32, 0.65) 0%, rgba(11, 17, 32, 0.82) 65%, #0b1120 100%);
  animation: heroGlowPulse 8s ease-in-out infinite alternate;
  z-index: 1;
  pointer-events: none;
}

.hero-section .container {
  position: relative;
  z-index: 2;
}

@keyframes heroKenBurns {
  0% {
    transform: scale(1) translate(0, 0);
  }
  50% {
    transform: scale(1.08) translate(-1%, 1%);
  }
  100% {
    transform: scale(1.04) translate(1%, -1%);
  }
}

@keyframes heroGlowPulse {
  0% {
    opacity: 0.75;
  }
  100% {
    opacity: 1;
  }
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1.15rem;
  background: rgba(37, 99, 235, 0.22);
  border: 1px solid rgba(96, 165, 250, 0.45);
  color: #93c5fd;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
  backdrop-filter: blur(8px);
  box-shadow: 0 0 15px rgba(37, 99, 235, 0.2);
}

.hero-title {
  font-size: 2.85rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.25;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
  text-shadow: 0 4px 24px rgba(0, 0, 0, 0.85);
}

.hero-title .highlight {
  background: linear-gradient(90deg, #38bdf8 0%, #67e8f9 25%, #ffffff 50%, #60a5fa 75%, #a78bfa 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
  text-shadow: none;
  filter: drop-shadow(0 0 18px rgba(56, 189, 248, 0.8)) drop-shadow(0 2px 4px rgba(0, 0, 0, 0.9));
}

.hero-subtitle {
  font-size: 1.3rem;
  font-weight: 600;
  color: #e2e8f0;
  margin-bottom: 1rem;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
}

.hero-desc {
  max-width: 820px;
  margin: 0 auto 2.25rem;
  font-size: 1.05rem;
  color: #cbd5e1;
  line-height: 1.8;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.8);
}

.hero-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 2.75rem;
}

.hero-actions .btn-secondary {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(8px);
}

.hero-actions .btn-secondary:hover, .hero-actions .btn-secondary:focus {
  background: rgba(255, 255, 255, 0.2);
  border-color: #ffffff;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  max-width: 760px;
  margin: 0 auto;
  gap: 1.5rem;
  padding: 1.75rem;
  background: rgba(15, 23, 42, 0.78);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(16px);
}

.stat-item {
  text-align: center;
}

.stat-number {
  font-size: 1.85rem;
  font-weight: 800;
  color: #38bdf8;
  margin-bottom: 0.25rem;
  text-shadow: 0 0 20px rgba(56, 189, 248, 0.35);
}

.stat-label {
  font-size: 0.875rem;
  color: #cbd5e1;
  font-weight: 500;
}

/* 区块通用样式 */
.section {
  padding: 4.5rem 0;
}

.section-alt {
  background-color: var(--bg-alt);
}

.section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 3rem;
}

.section-tag {
  color: var(--primary);
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.5rem;
  display: block;
}

.section-title {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.3;
  margin-bottom: 0.75rem;
}

.section-desc {
  font-size: 1.05rem;
  color: var(--text-muted);
}

/* 产品核心优势 3 个图文卡片 */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.feature-card {
  background: var(--bg-card);
  padding: 2.25rem 1.75rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.feature-icon-wrapper {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-md);
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}

.feature-icon-wrapper svg {
  width: 28px;
  height: 28px;
  fill: currentColor;
}

.feature-title {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--text-main);
}

.feature-text {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.7;
}

/* 流媒体与 AI 支持图卡 */
.support-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

.support-card {
  background: var(--bg-card);
  padding: 2.25rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.support-title {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.badge-tag {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  background: #dcfce7;
  color: #15803d;
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: 9999px;
}

.support-desc {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

.support-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.tag-item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: #f1f5f9;
  color: #334155;
  padding: 0.4rem 0.85rem;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 600;
  border: 1px solid #e2e8f0;
}

/* 套餐价格对比表 */
.pricing-table-wrapper {
  overflow-x: auto;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
  background: #ffffff;
}

.pricing-table {
  width: 100%;
  border-collapse: collapse;
  text-align: center;
  min-width: 680px;
}

.pricing-table caption {
  padding: 1rem;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-main);
  background: #f8fafc;
  border-bottom: 1px solid var(--border-color);
}

.pricing-table th, .pricing-table td {
  padding: 1.25rem 1rem;
  border-bottom: 1px solid var(--border-color);
  vertical-align: middle;
}

.pricing-table th {
  background: #f8fafc;
  color: var(--text-main);
  font-weight: 700;
  font-size: 1rem;
}

.pricing-table .col-highlight {
  background: #f0f7ff;
  border-left: 2px solid var(--primary);
  border-right: 2px solid var(--primary);
}

.pricing-table th.col-highlight {
  background: #e0f2fe;
}

.price-val {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--primary);
}

.price-unit {
  font-size: 0.85rem;
  color: var(--text-light);
  font-weight: 400;
}

/* 用户评价 */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.75rem;
}

.review-card {
  background: var(--bg-card);
  padding: 1.75rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
}

.review-stars {
  color: #eab308;
  font-size: 1.1rem;
  margin-bottom: 0.75rem;
  letter-spacing: 2px;
}

.review-quote {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.7;
  flex: 1;
  margin-bottom: 1.25rem;
}

.review-author {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  border-top: 1px solid var(--border-color);
  padding-top: 1rem;
}

.author-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: var(--text-muted);
}

.author-name {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-main);
}

.author-role {
  font-size: 0.8rem;
  color: var(--text-light);
}

/* FAQ 常见问题解答规范 (原生 details/summary，无需 JS) */
.faq-list {
  max-width: 860px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.faq-item {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.faq-summary {
  padding: 1.25rem 1.5rem;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text-main);
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  user-select: none;
  transition: background-color 0.2s;
}

.faq-summary::-webkit-details-marker {
  display: none;
}

.faq-summary::after {
  content: "+";
  font-size: 1.4rem;
  line-height: 1;
  color: var(--primary);
  font-weight: 700;
  transition: transform 0.2s ease;
}

.faq-item[open] .faq-summary::after {
  content: "−";
  transform: rotate(0deg);
}

.faq-summary:hover, .faq-summary:focus {
  background-color: #f8fafc;
}

.faq-content {
  padding: 0 1.5rem 1.25rem;
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.8;
  border-top: 1px solid #f1f5f9;
}

/* CTA 底部横幅 */
.cta-banner {
  background: linear-gradient(135deg, #1e40af 0%, #2563eb 100%);
  color: #ffffff;
  padding: 4rem 1.5rem;
  border-radius: var(--radius-lg);
  text-align: center;
  margin: 3rem 0;
}

.cta-banner-title {
  font-size: 2.25rem;
  font-weight: 800;
  margin-bottom: 1rem;
}

.cta-banner-desc {
  max-width: 600px;
  margin: 0 auto 2rem;
  font-size: 1.1rem;
  opacity: 0.9;
}

/* 页脚规范 (只保留四个独立新页面入口) */
.site-footer {
  background: #0f172a;
  color: #cbd5e1;
  padding: 3rem 0 2rem;
  margin-top: auto;
  border-top: 1px solid #1e293b;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1.5rem;
}

.footer-brand {
  font-size: 1.25rem;
  font-weight: 700;
  color: #ffffff;
}

.footer-nav {
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
  justify-content: center;
  list-style: none;
}

.footer-nav a {
  color: #94a3b8;
  text-decoration: none;
  font-weight: 500;
  padding: 0.5rem;
  transition: color 0.2s ease;
}

.footer-nav a:hover, .footer-nav a:focus {
  color: #ffffff;
  text-decoration: underline;
}

.footer-copy {
  font-size: 0.875rem;
  color: #64748b;
}

/* 文章正文与科普页面规范 */
.article-header {
  padding: 3.5rem 0 2rem;
  background: linear-gradient(180deg, #f0f7ff 0%, #ffffff 100%);
  text-align: center;
}

.article-title {
  font-size: 2.25rem;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.3;
  margin-bottom: 1rem;
  max-width: 860px;
  margin-left: auto;
  margin-right: auto;
}

.article-meta {
  color: var(--text-light);
  font-size: 0.9rem;
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  margin-bottom: 1rem;
}

.article-body {
  max-width: 820px;
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
  font-size: 1.05rem;
  line-height: 1.85;
  color: #334155;
}

.article-body h2 {
  font-size: 1.6rem;
  font-weight: 700;
  color: #0f172a;
  margin: 2.5rem 0 1rem;
  border-bottom: 2px solid #e2e8f0;
  padding-bottom: 0.5rem;
}

.article-body h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: #1e293b;
  margin: 1.75rem 0 0.75rem;
}

.article-body p {
  margin-bottom: 1.25rem;
}

.article-body ul, .article-body ol {
  margin: 1rem 0 1.5rem 1.5rem;
  padding-left: 1rem;
}

.article-body li {
  margin-bottom: 0.5rem;
}

.article-body blockquote {
  border-left: 4px solid var(--primary);
  background: var(--bg-alt);
  padding: 1rem 1.25rem;
  margin: 1.5rem 0;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: #475569;
}

.article-cta-box {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: var(--radius-md);
  padding: 1.5rem;
  margin: 2.5rem 0;
  text-align: center;
}

/* 知识科普列表页网格 */
.knowledge-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.75rem;
  margin-bottom: 3.5rem;
}

.article-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s, box-shadow 0.2s;
  text-decoration: none;
  color: inherit;
}

.article-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: #cbd5e1;
}

.article-card-tag {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--primary);
  background: var(--primary-light);
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  align-self: flex-start;
  margin-bottom: 0.75rem;
}

.article-card-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.4;
  margin-bottom: 0.75rem;
}

.article-card-excerpt {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
  flex: 1;
  margin-bottom: 1rem;
}

.article-card-link {
  color: var(--primary);
  font-weight: 600;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

/* 响应式媒体查询 @media */
@media (max-width: 992px) {
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .reviews-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .knowledge-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  :root {
    --nav-height: 64px;
  }
  .hero-title {
    font-size: 1.85rem;
  }
  .hero-subtitle {
    font-size: 1.1rem;
  }
  .hero-stats {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .features-grid {
    grid-template-columns: 1fr;
  }
  .support-grid {
    grid-template-columns: 1fr;
  }
  .reviews-grid {
    grid-template-columns: 1fr;
  }
  .knowledge-grid {
    grid-template-columns: 1fr;
  }
  .footer-nav {
    flex-direction: column;
    gap: 0.75rem;
  }
  .header-inner {
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  .main-nav {
    gap: 0.75rem;
  }
  .nav-links {
    gap: 0.75rem;
  }
  .nav-link {
    font-size: 0.9rem;
  }
  .btn {
    width: 100%;
  }
  .hero-actions .btn {
    width: 100%;
  }
}

/* 动效适配 */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
