:root {
  --c-primary: #0066FF;
  --c-accent: #00E5FF;
  --c-bg: #F4F7FA;
  --c-surface: #FFFFFF;
  --c-text: #1E293B;
  --c-muted: #64748B;
  --c-border: #E2E8F0;
  --f-body: 'PingFang SC', 'Microsoft YaHei', system-ui, -apple-system, sans-serif;
  --r-lg: 16px;
  --r-md: 10px;
  --shadow-card: 0 6px 24px rgba(0,20,60,0.06);
  --shadow-hover: 0 12px 32px rgba(0,20,60,0.10);
  --space-section: 96px;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--f-body);
  background: var(--c-bg);
  color: var(--c-text);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  text-wrap: balance;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

h1 { font-size: clamp(2.25rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.75rem, 3vw, 2.5rem); margin-bottom: 1.5rem; }
h3 { font-size: 1.25rem; margin-bottom: 0.75rem; }

p { margin-bottom: 1rem; max-width: 68ch; }
a { color: var(--c-primary); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--c-accent); }

img { max-width: 100%; height: auto; display: block; }

.container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

section {
  padding: var(--space-section) 0;
}

.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 32px; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 24px; }
.flex-center { display: flex; align-items: center; justify-content: center; }

/* Header & Nav */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(244,247,250,0.88);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--c-border);
}

.nav-wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 72px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.25rem;
  color: var(--c-text);
}

.logo img { width: 32px; height: 32px; object-fit: contain; }

nav ul {
  display: flex;
  list-style: none;
  gap: 28px;
}

nav a {
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--c-muted);
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  transition: border-color 0.2s, color 0.2s;
}

nav a[aria-current="page"], nav a:hover {
  color: var(--c-primary);
  border-bottom-color: var(--c-primary);
}

/* Footer */
footer {
  background: #0F172A;
  color: #CBD5E1;
  padding: 64px 0 32px;
  margin-top: 60px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 40px;
}

.footer-col h3 { color: #F8FAFC; margin-bottom: 18px; font-size: 1.1rem; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 12px; font-size: 0.9rem; }
.footer-col a { color: #94A3B8; }
.footer-col a:hover { color: #fff; }

.copyright {
  text-align: center;
  padding-top: 30px;
  border-top: 1px solid #1E293B;
  font-size: 0.85rem;
  color: #64748B;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--r-md);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  border: none;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}

.btn-primary {
  background: linear-gradient(135deg, var(--c-primary), var(--c-accent));
  color: #fff;
  box-shadow: 0 4px 16px rgba(0,102,255,0.25);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,102,255,0.35);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--c-primary);
  color: var(--c-primary);
}

.btn-outline:hover {
  background: var(--c-primary);
  color: #fff;
}

.btn-sm { padding: 10px 20px; font-size: 0.9rem; }

/* Cards */
.card {
  background: var(--c-surface);
  border-radius: var(--r-lg);
  padding: 28px;
  box-shadow: var(--shadow-card);
  transition: transform 0.25s, box-shadow 0.25s;
  border: 1px solid rgba(255,255,255,0.5);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

.card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 16px;
  font-size: 0.85rem;
  color: var(--c-muted);
}

/* Table */
.table-wrap { overflow-x: auto; margin: 24px 0; border-radius: var(--r-lg); }
table {
  width: 100%;
  border-collapse: collapse;
  background: var(--c-surface);
  min-width: 500px;
}

th, td {
  padding: 16px 20px;
  text-align: left;
  border-bottom: 1px solid var(--c-border);
}

th { background: #F8FAFC; font-weight: 600; color: var(--c-text); }
tr:last-child td { border-bottom: none; }
td[colspan] { text-align: center; color: var(--c-muted); }

/* FAQ */
details {
  border-bottom: 1px solid var(--c-border);
  background: var(--c-surface);
  border-radius: var(--r-md);
  margin-bottom: 12px;
  overflow: hidden;
}

summary {
  padding: 18px 20px;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  position: relative;
  transition: background 0.2s;
}

summary::-webkit-details-marker { display: none; }
summary::after {
  content: '+';
  position: absolute;
  right: 20px;
  font-size: 1.25rem;
  color: var(--c-primary);
  transition: transform 0.2s;
}

details[open] summary::after { transform: rotate(45deg); }
details p { padding: 0 20px 18px 20px; color: var(--c-muted); line-height: 1.8; }

/* Focus & Accessibility */
:focus-visible {
  outline: 3px solid var(--c-accent);
  outline-offset: 2px;
}

/* SVG Animations */
@keyframes twinkle { 0%, 100% { opacity: 0.3; } 50% { opacity: 1; } }
@keyframes drawPath { 0% { stroke-dashoffset: 1; } 100% { stroke-dashoffset: 0; } }
@keyframes floatSoft { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

.star-dot { animation: twinkle 4.5s ease-in-out infinite; }
.star-dot:nth-child(even) { animation-duration: 6s; animation-delay: 1.2s; }
.conn-path {
  pathLength: 1;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
  animation: drawPath 7s ease forwards;
}
.float-group { animation: floatSoft 8s ease-in-out infinite; }

svg.hero-svg { width: 100%; height: auto; max-width: 640px; }
svg.tech-svg { width: 100%; height: auto; max-width: 480px; margin: 0 auto; display: block; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

@media (max-width: 768px) {
  .grid-2, .grid-3, .footer-grid { grid-template-columns: 1fr; }
  nav ul { display: none; }
  .nav-wrap { padding: 0 16px; }
  section { padding: 64px 0; }
}
