/* =====================================================
   WPS Office 下载站 - 全局样式
   原创设计 · 必应 SEO 优化 · 纯原生 CSS
   ===================================================== */

/* ---- 变量定义 ---- */
:root {
  --brand-red: #e60012;
  --brand-red-dark: #c4000f;
  --brand-orange: #ff6a00;
  --brand-gradient: linear-gradient(135deg, #e60012 0%, #ff6a00 100%);
  --text-primary: #1a1a2e;
  --text-secondary: #4a4a5a;
  --text-muted: #7a7a8a;
  --bg-body: #fafbfc;
  --bg-white: #ffffff;
  --bg-card: #ffffff;
  --bg-hero: linear-gradient(135deg, #fff5f5 0%, #ffffff 60%, #fff8f0 100%);
  --border-light: #e8e8f0;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.04);
  --shadow-md: 0 8px 24px rgba(0,0,0,0.06);
  --shadow-lg: 0 16px 48px rgba(0,0,0,0.08);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --max-width: 1200px;
  --header-height: 64px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---- 重置与基础 ---- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
  color: var(--text-primary);
  background: var(--bg-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--brand-red);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--brand-red-dark);
}

/* ---- 动画关键帧 ---- */
@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* ---- 工具类 ---- */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 80px 0;
}

.section-title {
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.section-subtitle {
  font-size: 1.05rem;
  text-align: center;
  color: var(--text-muted);
  margin-bottom: 48px;
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
}

.animate-in {
  animation: fadeInUp 0.7s ease-out forwards;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 32px;
  font-size: 1rem;
  font-weight: 600;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
  outline: none;
  position: relative;
  overflow: hidden;
}

.btn:disabled {
  cursor: not-allowed;
  opacity: 0.8;
}

.btn-primary {
  background: var(--brand-gradient);
  color: #ffffff;
  box-shadow: 0 4px 16px rgba(230, 0, 18, 0.25);
}

.btn-primary:hover:not(:disabled) {
  box-shadow: 0 6px 24px rgba(230, 0, 18, 0.35);
  transform: translateY(-2px);
}

.btn-secondary {
  background: #ffffff;
  color: var(--text-primary);
  border: 1.5px solid var(--border-light);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover:not(:disabled) {
  border-color: var(--brand-red);
  color: var(--brand-red);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.btn-large {
  padding: 16px 40px;
  font-size: 1.1rem;
  border-radius: var(--radius-lg);
}

/* ---- 导航栏 ---- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-light);
  z-index: 1000;
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text-primary);
}

.logo svg {
  width: 32px;
  height: 32px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 18px;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.nav-link svg {
  width: 18px;
  height: 18px;
  opacity: 0.7;
}

.nav-link:hover {
  color: var(--brand-red);
  background: rgba(230,0,18,0.04);
}

.nav-link.active {
  color: var(--brand-red);
  background: rgba(230,0,18,0.08);
  font-weight: 600;
}

.nav-link.active svg {
  opacity: 1;
}

/* ---- Hero 区域 ---- */
.hero {
  padding: calc(var(--header-height) + 64px) 0 80px;
  background: var(--bg-hero);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -10%;
  right: -5%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(255,106,0,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.hero-content h1 {
  font-size: 3rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 20px;
  letter-spacing: -0.02em;
}

.hero-content h1 .highlight {
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-desc {
  font-size: 1.15rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-meta {
  display: flex;
  gap: 24px;
  margin-top: 28px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.hero-meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.hero-meta-item svg {
  width: 16px;
  height: 16px;
  color: var(--brand-red);
}

.hero-visual {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.hero-visual-card {
  background: var(--bg-white);
  border-radius: var(--radius-xl);
  padding: 32px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-light);
  animation: float 6s ease-in-out infinite;
  width: 100%;
  max-width: 480px;
}

.hero-visual-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-visual-card h3 svg {
  width: 20px;
  height: 20px;
  color: var(--brand-red);
}

.hero-features-mini {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.hero-features-mini .mini-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px;
  background: var(--bg-body);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.hero-features-mini .mini-item svg {
  width: 18px;
  height: 18px;
  color: var(--brand-orange);
  flex-shrink: 0;
}

/* ---- 特性卡片 ---- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--brand-gradient);
  opacity: 0;
  transition: var(--transition);
}

.feature-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}

.feature-card:hover::before {
  opacity: 1;
}

.feature-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(230,0,18,0.06);
  border-radius: var(--radius-sm);
  margin-bottom: 20px;
}

.feature-icon svg {
  width: 24px;
  height: 24px;
  color: var(--brand-red);
}

.feature-card h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 10px;
}

.feature-card p {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ---- 下载平台卡片 ---- */
.platforms-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.platform-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 28px;
  text-align: center;
  transition: var(--transition);
  position: relative;
}

.platform-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
  border-color: rgba(230,0,18,0.2);
}

.platform-card.featured {
  border: 2px solid var(--brand-red);
  background: linear-gradient(180deg, #fff5f5 0%, #ffffff 100%);
}

.platform-card.featured::after {
  content: '推荐';
  position: absolute;
  top: 12px;
  right: 12px;
  background: var(--brand-gradient);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  text-transform: uppercase;
}

.platform-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-body);
  border-radius: var(--radius-md);
}

.platform-icon svg {
  width: 28px;
  height: 28px;
  color: var(--text-primary);
}

.platform-card.featured .platform-icon {
  background: rgba(230,0,18,0.08);
}

.platform-card.featured .platform-icon svg {
  color: var(--brand-red);
}

.platform-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 6px;
}

.platform-card .version {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.platform-card .size {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

/* ---- 评价/评测 ---- */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.review-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: var(--transition);
}

.review-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.review-stars {
  display: flex;
  gap: 3px;
  margin-bottom: 12px;
}

.review-stars svg {
  width: 18px;
  height: 18px;
  color: #ffb800;
}

.review-text {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 16px;
}

.review-author {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
}

.review-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--brand-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 600;
  font-size: 0.85rem;
}

.review-name {
  font-weight: 600;
  color: var(--text-primary);
}

.review-role {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ---- FAQ ---- */
.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  margin-bottom: 12px;
  overflow: hidden;
  transition: var(--transition);
}

.faq-item.active {
  box-shadow: var(--shadow-sm);
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
}

.faq-question svg {
  width: 20px;
  height: 20px;
  color: var(--text-muted);
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.faq-item.active .faq-question svg {
  transform: rotate(180deg);
  color: var(--brand-red);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease, padding 0.35s ease;
}

.faq-item.active .faq-answer {
  max-height: 500px;
}

.faq-answer-inner {
  padding: 0 24px 20px;
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

.faq-answer-inner a {
  font-weight: 500;
}

/* ---- SEO 内容区 ---- */
.seo-content {
  max-width: 840px;
  margin: 0 auto;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 40px;
}

.seo-content h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--text-primary);
}

.seo-content h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-top: 28px;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.seo-content p {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 16px;
}

.seo-content ul, .seo-content ol {
  margin-bottom: 16px;
  padding-left: 24px;
  color: var(--text-secondary);
  line-height: 1.8;
}

.seo-content li {
  margin-bottom: 8px;
}

.seo-content strong {
  color: var(--text-primary);
}

.seo-cta-box {
  margin-top: 36px;
  padding: 28px;
  background: linear-gradient(135deg, #fff5f5 0%, #fff8f0 100%);
  border: 2px solid var(--brand-red);
  border-radius: var(--radius-lg);
  text-align: center;
}

.seo-cta-box p {
  margin-bottom: 16px;
  font-size: 1.05rem;
  color: var(--text-primary);
}

/* ---- 对比表格 ---- */
.compare-table-wrap {
  overflow-x: auto;
  margin-top: 20px;
}

.compare-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
  min-width: 500px;
}

.compare-table th,
.compare-table td {
  padding: 14px 18px;
  text-align: left;
  border-bottom: 1px solid var(--border-light);
}

.compare-table th {
  font-weight: 600;
  color: var(--text-primary);
  background: var(--bg-body);
}

.compare-table td {
  color: var(--text-secondary);
}

.compare-table tr:hover td {
  background: rgba(230,0,18,0.02);
}

.compare-check {
  color: var(--brand-red);
  font-weight: 700;
}

.compare-cross {
  color: var(--text-muted);
}

/* ---- 更新日志 ---- */
.changelog-list {
  list-style: none;
  padding: 0;
}

.changelog-item {
  display: flex;
  gap: 20px;
  padding: 20px 0;
  border-bottom: 1px solid var(--border-light);
}

.changelog-version {
  flex-shrink: 0;
  width: 80px;
  font-weight: 700;
  color: var(--brand-red);
  font-size: 0.9rem;
}

.changelog-date {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.changelog-text {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ---- 页脚 ---- */
.footer {
  background: var(--text-primary);
  color: rgba(255,255,255,0.7);
  padding: 48px 0 24px;
  margin-top: 60px;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.footer-disclaimer {
  text-align: center;
  font-size: 0.85rem;
  line-height: 1.8;
  margin-bottom: 24px;
}

.footer-disclaimer strong {
  color: #fff;
}

.footer-divider {
  height: 1px;
  background: rgba(255,255,255,0.1);
  margin-bottom: 24px;
}

.footer-copyright {
  text-align: center;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.5);
}

/* ---- 面包屑 ---- */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.breadcrumb a {
  color: var(--text-muted);
}

.breadcrumb a:hover {
  color: var(--brand-red);
}

.breadcrumb svg {
  width: 14px;
  height: 14px;
}

/* ---- 响应式 ---- */
@media (max-width: 1024px) {
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .hero-content h1 {
    font-size: 2.4rem;
  }
  .hero-actions {
    justify-content: center;
  }
  .hero-meta {
    justify-content: center;
  }
  .hero-visual {
    order: -1;
  }
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .platforms-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .section {
    padding: 56px 0;
  }
  .section-title {
    font-size: 1.6rem;
  }
  .hero-content h1 {
    font-size: 2rem;
  }
  .features-grid {
    grid-template-columns: 1fr;
  }
  .platforms-grid {
    grid-template-columns: 1fr;
  }
  .reviews-grid {
    grid-template-columns: 1fr;
  }
  .nav-link {
    padding: 6px 12px;
    font-size: 0.85rem;
  }
  .nav-link svg {
    display: none;
  }
  .seo-content {
    padding: 24px;
  }
}

/* ---- SEO 隐藏但可访问 ---- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---- 强调标签 ---- */
.badge {
  display: inline-block;
  padding: 3px 10px;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 20px;
  background: rgba(230,0,18,0.08);
  color: var(--brand-red);
  margin-right: 6px;
}

/* ---- 统计数字 ---- */
.stats-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  max-width: 900px;
  margin: 0 auto;
}

.stat-item {
  text-align: center;
  padding: 20px;
}

.stat-number {
  font-size: 2.2rem;
  font-weight: 800;
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
}

.stat-label {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: 8px;
}

@media (max-width: 640px) {
  .stats-bar {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
}

/* ---- 下载页特殊 ---- */
.download-hero {
  background: linear-gradient(135deg, #fff5f5 0%, #ffffff 50%, #f0f7ff 100%);
  text-align: center;
  padding: calc(var(--header-height) + 48px) 0 48px;
}

.download-hero h1 {
  font-size: 2.4rem;
  font-weight: 800;
  margin-bottom: 12px;
}

.download-hero p {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 32px;
}

.download-main-card {
  max-width: 720px;
  margin: 0 auto 48px;
  background: var(--bg-white);
  border: 2px solid var(--brand-red);
  border-radius: var(--radius-xl);
  padding: 40px;
  box-shadow: var(--shadow-lg);
}

.download-main-card .platform-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 20px;
  background: rgba(230,0,18,0.08);
  border-radius: 50%;
}

.download-main-card .platform-icon svg {
  width: 36px;
  height: 36px;
  color: var(--brand-red);
}

.download-main-card h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.download-main-card .file-info {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 24px;
}

.download-main-card .btn {
  width: 100%;
  max-width: 280px;
}

.download-steps {
  display: flex;
  justify-content: center;
  gap: 32px;
  flex-wrap: wrap;
  margin-top: 24px;
}

.download-step {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.download-step .step-num {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--brand-gradient);
  color: #fff;
  border-radius: 50%;
  font-size: 0.8rem;
  font-weight: 700;
}
