/* ===== Reset & Base ===== */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  color: #2B2B2B;
  background: #F7F4F1;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  cursor: pointer;
  border: none;
  font-family: inherit;
}

ul, ol {
  list-style: none;
}

/* ===== Variables ===== */
:root {
  --paper: #F7F4F1;
  --graphite: #2B2B2B;
  --limestone: #8C8C8C;
  --mist: #E8E4E0;
  --cinnabar: #C23A30;
  --cinnabar-dark: #A83028;
  --amber: #F5C842;
  --night: #1A1A1A;
}

/* ===== Typography ===== */
.display-title {
  font-size: clamp(1.6rem, 3.5vw, 2.4rem);
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--graphite);
}

.section-title {
  font-size: clamp(1.25rem, 2.5vw, 1.8rem);
  font-weight: 600;
  line-height: 1.45;
  color: var(--graphite);
}

.card-title {
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.5;
}

.body-text {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--limestone);
}

.caption {
  font-size: 0.85rem;
  line-height: 1.6;
  color: var(--limestone);
}

/* ===== Layout ===== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
}

.section {
  padding: 80px 0;
}

@media (max-width: 768px) {
  .section {
    padding: 56px 0;
  }
  .container {
    padding: 0 20px;
  }
}

/* ===== Navigation ===== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(247, 244, 241, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--mist);
}

.navbar-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.navbar-logo {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--cinnabar);
  display: flex;
  align-items: center;
  gap: 8px;
}

.navbar-links {
  display: flex;
  gap: 32px;
}

.navbar-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--graphite);
  transition: color 0.3s ease;
  padding-bottom: 2px;
  border-bottom: 2px solid transparent;
}

.navbar-links a:hover,
.navbar-links a.active {
  color: var(--cinnabar);
}

.navbar-links a.active {
  border-bottom-color: var(--cinnabar);
}

.navbar-toggle {
  display: none;
  background: none;
  padding: 4px;
}

@media (max-width: 768px) {
  .navbar-links {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: rgba(247, 244, 241, 0.97);
    backdrop-filter: blur(8px);
    flex-direction: column;
    padding: 20px 32px;
    gap: 16px;
    border-bottom: 1px solid var(--mist);
  }
  .navbar-links.open {
    display: flex;
  }
  .navbar-toggle {
    display: block;
  }
}

/* ===== Hero Section ===== */
.hero {
  position: relative;
  padding: 140px 32px 80px;
  text-align: center;
  background: linear-gradient(180deg, #F7F4F1 0%, #EDE8E3 100%);
  overflow: hidden;
  min-height: 520px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-canvas {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.hero-canvas canvas {
  width: 100% !important;
  height: 100% !important;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 700px;
}

.hero-title {
  margin-bottom: 16px;
}

.hero-subtitle {
  margin-bottom: 32px;
}

.hero-cta {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.hero-meta {
  font-size: 0.85rem;
  color: var(--limestone);
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 14px 32px;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 2px;
  transition: all 0.3s ease;
  cursor: pointer;
}

.btn-primary {
  background: var(--cinnabar);
  color: #FFFFFF;
  border: none;
}

.btn-primary:hover {
  background: var(--cinnabar-dark);
}

.btn-outline {
  background: transparent;
  color: var(--cinnabar);
  border: 1px solid var(--cinnabar);
}

.btn-outline:hover {
  background: rgba(194, 58, 48, 0.05);
}

.btn-sm {
  padding: 8px 20px;
  font-size: 0.85rem;
}

.btn-download {
  background: var(--cinnabar);
  color: #FFFFFF;
  border: none;
  padding: 8px 20px;
  font-size: 0.85rem;
  font-weight: 600;
  border-radius: 2px;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.btn-download:hover {
  background: var(--cinnabar-dark);
}

/* ===== Cards ===== */
.card {
  background: #FFFFFF;
  border: 1px solid var(--mist);
  border-radius: 4px;
  padding: 28px;
  transition: all 0.3s ease;
}

.card:hover {
  border-color: var(--cinnabar);
  transform: translateY(-3px);
}

/* ===== Grid ===== */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.grid-5 {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

@media (max-width: 1024px) {
  .grid-5 {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .grid-3,
  .grid-5 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .grid-2,
  .grid-3,
  .grid-5 {
    grid-template-columns: 1fr;
  }
}

/* ===== Platform Cards ===== */
.platform-card {
  background: #FFFFFF;
  border: 1px solid var(--mist);
  border-radius: 4px;
  padding: 28px;
  text-align: center;
  transition: all 0.3s ease;
}

.platform-card:hover {
  border-color: var(--cinnabar);
  transform: translateY(-3px);
}

.platform-icon {
  width: 40px;
  height: 40px;
  margin: 0 auto 12px;
  color: var(--graphite);
}

.platform-name {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 6px;
}

.platform-req {
  font-size: 0.85rem;
  color: var(--limestone);
  margin-bottom: 16px;
}

.platform-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--cinnabar);
  font-weight: 600;
  font-size: 0.9rem;
  transition: gap 0.3s ease;
}

.platform-link:hover {
  gap: 8px;
}

/* ===== Security Bar ===== */
.security-bar {
  background: #EDE8E3;
  padding: 16px 32px;
  text-align: center;
}

.security-bar-inner {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--limestone);
}

/* ===== Feature Cards ===== */
.feature-num {
  font-size: 0.75rem;
  color: var(--cinnabar);
  font-weight: 700;
  margin-bottom: 8px;
}

.feature-name {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.feature-desc {
  font-size: 0.95rem;
  color: var(--limestone);
  line-height: 1.8;
}

/* ===== Testimonial Cards ===== */
.testimonial-stars {
  display: flex;
  gap: 3px;
  margin-bottom: 12px;
}

.testimonial-stars svg {
  width: 16px;
  height: 16px;
  fill: var(--amber);
}

.testimonial-text {
  font-style: italic;
  margin-bottom: 16px;
  line-height: 1.8;
}

.testimonial-author {
  font-size: 0.85rem;
  color: var(--limestone);
}

/* ===== Download Table ===== */
.download-table {
  width: 100%;
  max-width: 1000px;
  margin: 0 auto;
}

.download-table-header {
  display: grid;
  grid-template-columns: 1.2fr 1fr 0.8fr 1.5fr 0.8fr;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--mist);
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--limestone);
}

.download-table-row {
  display: grid;
  grid-template-columns: 1.2fr 1fr 0.8fr 1.5fr 0.8fr;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--mist);
  align-items: center;
  transition: background 0.3s ease;
}

.download-table-row:hover {
  background: rgba(194, 58, 48, 0.03);
}

.download-table-cell {
  font-size: 0.9rem;
}

@media (max-width: 768px) {
  .download-table-header {
    display: none;
  }
  .download-table-row {
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 20px;
    background: #FFFFFF;
    border: 1px solid var(--mist);
    border-radius: 4px;
    margin-bottom: 12px;
  }
  .download-table-row:hover {
    background: rgba(194, 58, 48, 0.03);
  }
}

/* ===== Changelog Timeline ===== */
.timeline {
  position: relative;
  padding-left: 28px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 5px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--mist);
}

.timeline-item {
  position: relative;
  padding-bottom: 32px;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -23px;
  top: 6px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--cinnabar);
}

.timeline-version {
  font-weight: 600;
  margin-bottom: 4px;
}

.timeline-date {
  font-size: 0.85rem;
  color: var(--limestone);
  margin-bottom: 8px;
}

.timeline-content ul {
  padding-left: 18px;
}

.timeline-content li {
  list-style: disc;
  color: var(--limestone);
  font-size: 0.95rem;
  line-height: 1.8;
}

/* ===== FAQ Accordion ===== */
.faq-item {
  border-bottom: 1px solid var(--mist);
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
  cursor: pointer;
  width: 100%;
  background: none;
  text-align: left;
  font-size: 1rem;
  font-weight: 500;
  color: var(--graphite);
}

.faq-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  transition: transform 0.3s ease;
  color: var(--limestone);
}

.faq-item.open .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-item.open .faq-answer {
  max-height: 300px;
  padding-bottom: 24px;
}

.faq-answer p {
  color: var(--limestone);
  line-height: 1.8;
}

/* ===== Feature Detail Section ===== */
.feature-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  margin-bottom: 80px;
}

.feature-detail.reverse {
  direction: rtl;
}

.feature-detail.reverse > * {
  direction: ltr;
}

.feature-detail-image {
  aspect-ratio: 16 / 10;
  border: 1px solid var(--mist);
  border-radius: 4px;
  overflow: hidden;
}

.feature-detail-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.feature-detail-list {
  margin-top: 16px;
}

.feature-detail-list li {
  position: relative;
  padding-left: 16px;
  color: var(--limestone);
  line-height: 2;
  font-size: 0.95rem;
}

.feature-detail-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 11px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--cinnabar);
}

@media (max-width: 768px) {
  .feature-detail {
    grid-template-columns: 1fr;
    gap: 24px;
    margin-bottom: 56px;
  }
  .feature-detail.reverse {
    direction: ltr;
  }
}

/* ===== News ===== */
.news-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.news-item {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 24px;
  padding: 24px;
  background: #FFFFFF;
  border: 1px solid var(--mist);
  border-radius: 4px;
  transition: all 0.3s ease;
}

.news-item:hover {
  border-color: var(--cinnabar);
}

.news-thumb {
  aspect-ratio: 16 / 10;
  border-radius: 4px;
  overflow: hidden;
  background: var(--mist);
}

.news-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-meta {
  display: flex;
  gap: 16px;
  font-size: 0.85rem;
  color: var(--limestone);
  margin-bottom: 8px;
}

.news-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--graphite);
}

.news-excerpt {
  font-size: 0.95rem;
  color: var(--limestone);
  line-height: 1.8;
  margin-bottom: 12px;
}

.news-readmore {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--cinnabar);
  font-weight: 600;
  font-size: 0.9rem;
}

@media (max-width: 768px) {
  .news-item {
    grid-template-columns: 1fr;
  }
  .news-thumb {
    aspect-ratio: 16 / 9;
  }
}

/* ===== Article ===== */
.article-header {
  text-align: center;
  padding: 120px 32px 40px;
  background: linear-gradient(180deg, #F7F4F1 0%, #EDE8E3 100%);
}

.article-meta {
  display: flex;
  justify-content: center;
  gap: 16px;
  font-size: 0.85rem;
  color: var(--limestone);
  margin-bottom: 16px;
}

.article-hero-img {
  max-width: 900px;
  margin: 0 auto 40px;
  aspect-ratio: 16 / 9;
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid var(--mist);
}

.article-hero-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-body {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 32px 80px;
}

.article-body h2 {
  font-size: 1.25rem;
  font-weight: 600;
  margin: 32px 0 16px;
  color: var(--graphite);
}

.article-body p {
  margin-bottom: 16px;
  line-height: 1.9;
  color: var(--graphite);
}

.article-body ul {
  padding-left: 24px;
  margin-bottom: 16px;
}

.article-body ul li {
  list-style: disc;
  margin-bottom: 8px;
  line-height: 1.8;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--cinnabar);
  font-weight: 600;
  margin-top: 40px;
}

/* ===== Footer ===== */
.footer {
  background: var(--night);
  color: var(--limestone);
  padding: 32px;
  text-align: center;
}

.footer-security {
  font-size: 0.85rem;
  margin-bottom: 12px;
}

.footer-copyright {
  font-size: 0.8rem;
  margin-bottom: 16px;
  opacity: 0.8;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 24px;
}

.footer-links a {
  font-size: 0.85rem;
  color: var(--limestone);
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: var(--paper);
}

@media (max-width: 480px) {
  .footer-links {
    flex-direction: column;
    gap: 8px;
  }
}

/* ===== Scroll Reveal ===== */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Loading Spinner ===== */
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.spinner {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid #FFFFFF;
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  vertical-align: middle;
  margin-right: 6px;
}

/* ===== Section Header ===== */
.section-header {
  text-align: center;
  margin-bottom: 48px;
}

.section-header h2 {
  margin-bottom: 8px;
}

.section-header p {
  color: var(--limestone);
}
