:root {
  --bg: #ffffff;
  --bg-alt: #f8fafc;
  --surface: #ffffff;
  --surface-tint: #eff6ff;
  --text: #0f172a;
  --text-muted: #475569;
  --primary: #1d4ed8;
  --primary-hover: #1e40af;
  --primary-text: #ffffff;
  --badge-bg: #dbeafe;
  --badge-text: #1e3a8a;
  --success-bg: #dcfce7;
  --success-text: #166534;
  --border: #e2e8f0;
  --border-strong: #cbd5e1;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.08);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.08);
  --container-max: 1120px;
  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2rem;
  --space-5: 3rem;
  --space-6: 4rem;
  --header-offset: 88px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-size: 16px;
  line-height: 1.7;
  color: var(--text);
  background-color: var(--bg);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--primary-hover);
}

:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
}

section[id],
h2[id],
h3[id],
article[id] {
  scroll-margin-top: var(--header-offset);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 1000;
  background: var(--primary);
  color: var(--primary-text);
  padding: 0.75rem 1.25rem;
  border-radius: 0 0 var(--radius-sm) 0;
  font-weight: 600;
  text-decoration: none;
}

.skip-link:focus {
  left: 0;
}

.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: 1.25rem;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 72px;
  padding-block: 0.5rem;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  text-decoration: none;
  color: var(--text);
  font-weight: 800;
  font-size: 1.25rem;
  min-height: 44px;
  flex-shrink: 0;
}

.brand-link:hover {
  color: var(--primary);
}

.main-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.25rem 0.5rem;
}

.main-nav a {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 0.75rem;
  min-height: 44px;
  border-radius: var(--radius-sm);
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
}

.main-nav a:hover,
.main-nav a[aria-current="page"] {
  background-color: var(--surface-tint);
  color: var(--primary);
  font-weight: 600;
}

.header-actions {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 44px;
  min-width: 44px;
  padding: 0.65rem 1.35rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  cursor: pointer;
  border: 2px solid transparent;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

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

.btn-primary:hover {
  background-color: var(--primary-hover);
  color: var(--primary-text);
}

.btn-secondary {
  background-color: var(--surface);
  color: var(--primary);
  border-color: var(--primary);
}

.btn-secondary:hover {
  background-color: var(--surface-tint);
  color: var(--primary-hover);
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
}

/* Sections */
.section {
  padding-block: var(--space-5);
}

.section-alt {
  background-color: var(--bg-alt);
  border-block: 1px solid var(--border);
}

.section-header {
  max-width: 720px;
  margin-bottom: var(--space-4);
}

.section-header h2 {
  margin: 0 0 0.65rem;
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  line-height: 1.3;
  color: var(--text);
}

.section-header p {
  margin: 0;
  color: var(--text-muted);
}

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  padding-block: clamp(3.25rem, 6.5vw, 5.25rem);
  background-color: #dbeafe;
  border-bottom: 1px solid var(--border);
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.hero-bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 70% 45%;
  display: block;
  transform: scale(1.04) translate3d(0, 0, 0);
  transform-origin: 68% 50%;
  animation: heroCloudFloat 18s ease-in-out infinite alternate;
  will-change: transform;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.78) 0%,
    rgba(255, 255, 255, 0.64) 34%,
    rgba(255, 255, 255, 0.24) 52%,
    rgba(255, 255, 255, 0) 68%
  );
}

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

.hero-content {
  max-width: 620px;
  text-align: left;
}

.hero-badge {
  display: inline-block;
  background-color: rgba(219, 234, 254, 0.9);
  color: var(--badge-text);
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  margin-bottom: 1rem;
}

.hero h1 {
  margin: 0 0 1rem;
  font-size: clamp(1.85rem, 3.6vw, 2.75rem);
  line-height: 1.22;
  color: #2257A8;
}

@supports ((-webkit-background-clip: text) or (background-clip: text)) {
  .hero h1 {
    background-image: linear-gradient(
      90deg,
      #2257A8 0%,
      #9271B9 12.5%,
      #D18A49 25%,
      #9271B9 37.5%,
      #2257A8 50%,
      #9271B9 62.5%,
      #D18A49 75%,
      #9271B9 87.5%,
      #2257A8 100%
    );
    background-size: 200% 100%;
    background-position: 100% 50%;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
    animation: heroTitleSunrise 3s linear infinite;
  }
}

@keyframes heroTitleSunrise {
  0% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

@keyframes heroCloudFloat {
  0% {
    transform: scale(1.04) translate3d(-0.6%, -0.4%, 0);
  }
  100% {
    transform: scale(1.06) translate3d(0.6%, 0.4%, 0);
  }
}

.hero-subtitle {
  margin: 0 0 1rem;
  font-size: 1.125rem;
  font-weight: 600;
  color: #1e40af;
}

.hero-desc {
  margin: 0 0 1.75rem;
  color: #1e293b;
  font-size: 1.02rem;
}

.hero-cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-bottom: 1.5rem;
}

.hero-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.92rem;
  color: #1e293b;
  font-weight: 500;
}

/* Grids & Cards */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-3);
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-3);
}

.card {
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  min-width: 0;
  overflow-wrap: break-word;
}

.card-icon {
  margin-bottom: 1rem;
  border-radius: var(--radius-sm);
}

.card h3 {
  margin: 0 0 0.65rem;
  font-size: 1.18rem;
  line-height: 1.35;
}

.card p {
  margin: 0;
  color: var(--text-muted);
}

.card-meta {
  display: inline-block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--badge-text);
  background: var(--badge-bg);
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  margin-bottom: 0.75rem;
}

/* Streaming & AI cards */
.media-card {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
}

.media-card img {
  flex-shrink: 0;
  border-radius: var(--radius-md);
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
}

.tag-list li {
  font-size: 0.85rem;
  background-color: var(--bg-alt);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 0.25rem 0.65rem;
  border-radius: 6px;
}

/* Pricing Table */
.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

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

.pricing-table caption {
  padding: 1rem 1.25rem;
  text-align: left;
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
  background-color: var(--bg-alt);
  border-bottom: 1px solid var(--border);
}

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

.pricing-table thead th {
  background-color: var(--surface-tint);
  color: var(--text);
  font-weight: 700;
  font-size: 0.95rem;
}

.pricing-table tbody tr:last-child th,
.pricing-table tbody tr:last-child td {
  border-bottom: none;
}

.pricing-table tbody th {
  font-weight: 700;
  color: var(--text);
}

.price-value {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--primary);
  white-space: nowrap;
}

.plan-badge {
  display: inline-block;
  margin-left: 0.4rem;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  background-color: var(--success-bg);
  color: var(--success-text);
}

.table-note {
  margin-top: 0.85rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* Reviews */
.rating-summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.5rem;
  background: var(--surface-tint);
  border: 1px solid #bfdbfe;
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  margin-bottom: var(--space-3);
}

.rating-score {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary);
}

.review-author {
  margin-top: 1rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
}

/* FAQ */
.faq-list {
  display: grid;
  gap: 1rem;
}

.faq-item {
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.25rem 1.25rem;
}

.faq-item summary {
  cursor: pointer;
  list-style: none;
  font-weight: 700;
  color: var(--text);
  padding-block: 0.95rem;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

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

.faq-item summary::after {
  content: "+";
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary);
  flex-shrink: 0;
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-answer {
  padding-bottom: 1rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  padding-top: 0.85rem;
}

.faq-answer p {
  margin: 0;
}

/* Subpages & Articles */
.page-banner {
  background: linear-gradient(180deg, #eff6ff 0%, #ffffff 100%);
  border-bottom: 1px solid var(--border);
  padding-block: var(--space-4);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  list-style: none;
  padding: 0;
  margin: 0 0 0.85rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.page-banner h1 {
  margin: 0 0 0.75rem;
  font-size: clamp(1.6rem, 3vw, 2.25rem);
  line-height: 1.3;
}

.page-banner p {
  margin: 0;
  color: var(--text-muted);
  max-width: 760px;
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: var(--space-4);
  align-items: start;
}

.article-body {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 2rem;
  min-width: 0;
  overflow-wrap: break-word;
}

.article-body h2 {
  margin: 1.75rem 0 0.75rem;
  font-size: 1.35rem;
  line-height: 1.35;
}

.article-body h2:first-child {
  margin-top: 0;
}

.article-body p {
  margin: 0 0 1rem;
  color: var(--text);
}

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

.article-body li + li {
  margin-top: 0.45rem;
}

.article-sidebar {
  display: grid;
  gap: 1.25rem;
}

.sidebar-box {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.25rem;
}

.sidebar-box h2,
.sidebar-box h3 {
  margin: 0 0 0.75rem;
  font-size: 1.05rem;
}

.sidebar-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.5rem;
}

.sidebar-links a {
  display: inline-block;
  padding-block: 0.25rem;
}

.cta-banner {
  background-color: var(--surface-tint);
  border: 1px solid #bfdbfe;
  border-radius: var(--radius-md);
  padding: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 2rem;
}

.cta-banner h2,
.cta-banner h3 {
  margin: 0 0 0.35rem;
  font-size: 1.15rem;
}

.cta-banner p {
  margin: 0;
  color: var(--text-muted);
}

.cta-banner .hero-cta-group {
  margin-bottom: 0;
}

.sitemap-list {
  display: grid;
  gap: 0.65rem;
  padding-left: 1.25rem;
  margin: 0;
}

.info-list {
  display: grid;
  gap: 0.65rem;
  padding-left: 1.25rem;
  margin: 0.5rem 0 1rem;
}

/* Footer */
.site-footer {
  background-color: #0f172a;
  color: #e2e8f0;
  padding-block: var(--space-4);
  margin-top: var(--space-5);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-3);
  margin-bottom: var(--space-3);
}

.footer-col h2 {
  margin: 0 0 0.65rem;
  font-size: 1.05rem;
  color: #ffffff;
}

.footer-col a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: #bfdbfe;
  font-weight: 600;
  text-decoration: none;
}

.footer-col a:hover {
  color: #ffffff;
  text-decoration: underline;
}

.footer-col p {
  margin: 0.25rem 0 0;
  font-size: 0.9rem;
  color: #cbd5e1;
}

.footer-bottom {
  border-top: 1px solid #334155;
  padding-top: 1.25rem;
  font-size: 0.88rem;
  color: #cbd5e1;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
}

/* Responsive */
@media (max-width: 960px) {
  .article-layout {
    grid-template-columns: 1fr;
  }

  .grid-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .hero::after {
    background: linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.76) 0%,
      rgba(255, 255, 255, 0.6) 65%,
      rgba(255, 255, 255, 0.45) 100%
    );
  }

  .hero-bg-img {
    object-position: 78% 40%;
  }

  .header-inner {
    flex-wrap: wrap;
  }

  .main-nav {
    order: 3;
    width: 100%;
    border-top: 1px solid var(--border);
    padding-top: 0.5rem;
    gap: 0.25rem;
  }

  .main-nav a {
    padding: 0.5rem 0.65rem;
    font-size: 0.92rem;
  }

  .grid-3,
  .grid-2,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .media-card {
    flex-direction: column;
  }

  .article-body {
    padding: 1.25rem;
  }

  .hero-cta-group .btn,
  .cta-banner .btn {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .hero-bg-img,
  .hero h1 {
    animation: none !important;
  }

  .hero h1 {
    background-position: 0% 50%;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
