/* ========================================
   法考地图官网 — 极简高级感
   参考: Linear / Stripe / Vercel
   ======================================== */

:root {
  --white: #ffffff;
  --gray-50: #fafafa;
  --gray-100: #f4f4f5;
  --gray-200: #e4e4e7;
  --gray-300: #d4d4d8;
  --gray-400: #a1a1aa;
  --gray-500: #71717a;
  --gray-600: #52525b;
  --gray-700: #3f3f46;
  --gray-800: #27272a;
  --gray-900: #18181b;
  --gray-950: #09090b;

  --accent: #0f766e;
  --accent-hover: #0d9488;
  --accent-bg: #f0fdfa;
  --accent-subtle: rgba(15,118,110,0.08);

  --success: #22c55e;

  --text: var(--gray-900);
  --text-2: var(--gray-500);
  --text-3: var(--gray-500);

  --border: var(--gray-200);
  --border-subtle: var(--gray-100);

  --max-w: 1080px;
  --max-w-narrow: 680px;
  --header-h: 56px;

  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

/* --- Reset --- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html {
  font-size: 16px;
  /* scroll-behavior: smooth removed — conflicts with GSAP ScrollTrigger */
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--sans);
  color: var(--text);
  background: var(--white);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a { color: var(--accent); text-decoration: none; transition: color 0.15s; }
a:hover { color: var(--accent-hover); }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; }

/* --- Typography --- */
h1, h2, h3, h4 {
  font-weight: 600;
  line-height: 1.2;
  color: var(--gray-950);
  letter-spacing: -0.025em;
}

h1 { font-size: 2.5rem; letter-spacing: -0.035em; }
h2 { font-size: 2rem; }
h3 { font-size: 1.25rem; }
h4 { font-size: 1rem; }

p { color: var(--text-2); margin-bottom: 1rem; line-height: 1.7; }

/* --- Layout --- */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

.container--narrow { max-width: var(--max-w-narrow); }

.section {
  padding: 100px 0;
}

.section--alt {
  background: var(--gray-50);
}

/* --- Header --- */
.header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--header-h);
  background: rgba(255,255,255,0.98);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  z-index: 1000;
  transition: box-shadow 0.3s;
}

.header.scrolled {
  box-shadow: 0 1px 0 var(--border);
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.02em;
}

.logo:hover { color: var(--text); }

.logo-mark {
  width: 32px; height: 32px;
  border-radius: 8px;
  object-fit: contain;
}

.nav {
  display: none;
  gap: 32px;
}

.nav a {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-2);
  transition: color 0.15s;
}

.nav a:hover,
.nav a.active { color: var(--gray-950); }

.nav a.active {
  position: relative;
}

.nav a.active::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0; right: 0;
  height: 1.5px;
  background: var(--accent);
  border-radius: 1px;
}

.header-cta { display: none; }

.mobile-toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.mobile-toggle span {
  display: block;
  width: 18px; height: 1.5px;
  background: var(--gray-900);
  border-radius: 1px;
  transition: all 0.3s ease;
}

.mobile-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(4px, 4px); }
.mobile-toggle.active span:nth-child(2) { opacity: 0; }
.mobile-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(4px, -4px); }

.mobile-menu {
  position: fixed;
  top: var(--header-h);
  left: 0; right: 0;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  z-index: 999;
  padding: 8px 24px 24px;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.3s ease, opacity 0.25s ease;
}

.mobile-menu.active {
  max-height: 400px;
  opacity: 1;
}

.mobile-menu a {
  display: block;
  padding: 14px 0;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text);
  border-bottom: 1px solid var(--border-subtle);
}

.mobile-menu a:last-child { border-bottom: none; }
.mobile-menu .btn { margin-top: 16px; text-align: center; }

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  font-size: 0.8125rem;
  font-weight: 500;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: all 0.15s ease;
  text-decoration: none;
  line-height: 1.4;
  font-family: inherit;
  letter-spacing: -0.01em;
}

.btn-primary {
  background: var(--gray-950);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--gray-800);
  color: var(--white);
}

.btn-accent {
  background: var(--accent);
  color: var(--white);
}

.btn-accent:hover {
  background: var(--accent-hover);
  color: var(--white);
}

.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-outline:hover {
  background: var(--gray-50);
  border-color: var(--gray-300);
  color: var(--text);
}

.btn-white {
  background: var(--white);
  color: var(--gray-950);
  font-weight: 600;
}

.btn-white:hover {
  color: var(--gray-950);
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.btn-lg {
  padding: 12px 28px;
  font-size: 0.875rem;
  border-radius: 10px;
}

.btn-sm {
  padding: 6px 14px;
  font-size: 0.75rem;
}

.btn-block { width: 100%; }

/* --- Hero (Dark) --- */
.hero {
  background: var(--gray-950);
  color: var(--white);
  padding: calc(var(--header-h) + 60px) 0 80px;
  position: relative;
  overflow: hidden;
  min-height: 90vh;
  display: flex;
  align-items: center;
}

/* Map contour lines - subtle topographic pattern */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 800px 400px at 70% 50%, rgba(15,118,110,0.07) 0%, transparent 70%),
    radial-gradient(ellipse 600px 300px at 20% 80%, rgba(15,118,110,0.04) 0%, transparent 70%);
  pointer-events: none;
}

/* Floating contour rings - the visual signature */
.hero::after {
  content: '';
  position: absolute;
  top: 50%;
  right: 10%;
  width: 500px;
  height: 500px;
  transform: translateY(-50%);
  background:
    radial-gradient(circle, transparent 38%, rgba(15,118,110,0.06) 39%, rgba(15,118,110,0.06) 40%, transparent 41%),
    radial-gradient(circle, transparent 53%, rgba(15,118,110,0.04) 54%, rgba(15,118,110,0.04) 55%, transparent 56%),
    radial-gradient(circle, transparent 68%, rgba(15,118,110,0.03) 69%, rgba(15,118,110,0.03) 70%, transparent 71%),
    radial-gradient(circle, transparent 83%, rgba(15,118,110,0.02) 84%, rgba(15,118,110,0.02) 85%, transparent 86%);
  pointer-events: none;
}

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

.hero h1 {
  color: var(--white);
  font-size: 3.25rem;
  line-height: 1.05;
  margin-bottom: 20px;
  letter-spacing: -0.04em;
  font-weight: 800;
}

.hero h1 .accent {
  color: var(--accent);
  position: relative;
  display: inline-block;
}

/* Teal underline accent on "更多" */
.hero h1 .accent::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 2px;
  width: 100%;
  height: 3px;
  background: var(--accent);
  border-radius: 2px;
  opacity: 0.6;
}

.hero-desc {
  color: var(--gray-400);
  font-size: 1.0625rem;
  margin-bottom: 36px;
  line-height: 1.8;
  max-width: 520px;
}

.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: flex-start;
}

.hero-stats {
  display: flex;
  gap: 40px;
  margin-top: 64px;
  padding-top: 40px;
  border-top: 1px solid rgba(255,255,255,0.06);
}

.hero-stat .num {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--white);
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.hero-stat .label {
  font-size: 0.75rem;
  color: var(--gray-500);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* --- Section headers --- */
.sh { margin-bottom: 56px; }

.sh-label {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 12px;
}

.sh h2 { margin-bottom: 12px; }

.sh p {
  font-size: 1.0625rem;
  max-width: 520px;
  color: var(--text-2);
}

/* --- Pain points --- */
.pain-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}

.pain-item {
  padding: 24px;
  border-bottom: 1px solid var(--border-subtle);
  transition: background 0.15s;
}

.pain-item:last-child { border-bottom: none; }

.pain-item:hover { background: var(--gray-50); }

.pain-item h4 {
  font-size: 0.9375rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.pain-item p {
  font-size: 0.8125rem;
  color: var(--text-3);
  margin-bottom: 0;
  line-height: 1.6;
}

/* --- Steps --- */
.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}

.step {
  padding: 28px 24px;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--white);
  transition: background 0.15s;
}

.step:last-child { border-bottom: none; }
.step:hover { background: var(--gray-50); }

.step-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.step-num {
  font-size: 0.6875rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.08em;
}

.step h3 { font-size: 1rem; }

.step p {
  font-size: 0.875rem;
  margin-bottom: 0;
  color: var(--text-2);
}

.step-tag {
  display: inline-block;
  font-size: 0.6875rem;
  font-weight: 500;
  color: var(--text-3);
  margin-top: 10px;
}

/* --- Subjects --- */
.subject-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.subject-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text);
  transition: all 0.15s;
}

.subject-tag:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.subject-tag .free {
  font-size: 0.625rem;
  font-weight: 600;
  color: var(--success);
  background: rgba(34,197,94,0.08);
  padding: 1px 5px;
  border-radius: 3px;
}

.subject-tag small {
  font-size: 0.6875rem;
  font-weight: 400;
  color: var(--text-3);
}

/* --- Testimonials --- */
.testimonial-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
}

.testimonial {
  position: relative;
  padding-left: 20px;
  border-left: 2px solid var(--accent);
}

.testimonial blockquote {
  font-size: 0.9375rem;
  line-height: 1.8;
  color: var(--text);
  margin-bottom: 16px;
  font-style: normal;
}

.testimonial cite {
  display: block;
  font-style: normal;
  font-size: 0.75rem;
  color: var(--text-3);
}

.testimonial cite strong {
  color: var(--text-2);
  font-weight: 600;
}

/* --- Pricing --- */
.pricing-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  max-width: 800px;
  margin: 0 auto;
}

.price-card {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 32px 28px;
  position: relative;
}

.price-card--featured {
  border-color: var(--accent);
}

.price-card--featured::after {
  content: '推荐';
  position: absolute;
  top: -10px;
  right: 24px;
  background: var(--accent);
  color: var(--white);
  font-size: 0.625rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 4px;
  letter-spacing: 0.05em;
}

.price-card h3 { font-size: 1rem; margin-bottom: 4px; }

.price-card .price-sub {
  font-size: 0.8125rem;
  color: var(--text-3);
  margin-bottom: 16px;
}

.price-amount { margin-bottom: 24px; }

.price-amount .cur {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-3);
}

.price-amount .val {
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--gray-950);
  letter-spacing: -0.03em;
}

.price-amount .per {
  font-size: 0.8125rem;
  color: var(--text-3);
}

.price-features { margin-bottom: 24px; }

.price-features li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 5px 0;
  font-size: 0.8125rem;
  color: var(--text-2);
}

.price-features li.yes::before {
  content: '\2713';
  display: inline-block;
  width: 16px; min-width: 16px;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--success);
  text-align: center;
}

.price-features li.no::before {
  content: '\2014';
  display: inline-block;
  width: 16px; min-width: 16px;
  font-size: 0.75rem;
  color: var(--gray-300);
  text-align: center;
}

/* --- Comparison table --- */
.compare-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8125rem;
}

.compare-table th,
.compare-table td {
  padding: 10px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border-subtle);
}

.compare-table th {
  font-weight: 600;
  color: var(--text);
  background: var(--gray-50);
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.compare-table td { color: var(--text-2); }
.compare-table .col-highlight { background: var(--accent-subtle); }

/* --- FAQ --- */
.faq-list { max-width: var(--max-w-narrow); margin: 0 auto; }

.faq-item { border-bottom: 1px solid var(--border-subtle); }
.faq-item:first-child { border-top: 1px solid var(--border-subtle); }

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 18px 0;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text);
  text-align: left;
  font-family: inherit;
  transition: color 0.15s;
}

.faq-question:hover { color: var(--accent); }

.faq-icon {
  width: 20px; height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease;
  flex-shrink: 0;
  color: var(--text-3);
  font-size: 1.125rem;
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
  color: var(--accent);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  padding: 0;
  font-size: 0.875rem;
  color: var(--text-2);
  line-height: 1.8;
}

.faq-item.active .faq-answer {
  max-height: 300px;
  padding: 0 0 18px;
}

/* --- CTA Section --- */
.cta-section {
  background: var(--gray-950);
  color: var(--white);
  padding: 100px 0;
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: -100px;
  right: -100px;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(15,118,110,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.cta-section h2 { color: var(--white); margin-bottom: 12px; }

.cta-section p { color: var(--gray-400); margin-bottom: 28px; }

/* CTA dual-mode */
.cta-desktop { display: none; }
.cta-mobile { display: block; }

.cta-qr {
  width: 180px; height: 180px;
  border-radius: 12px;
  margin: 0 auto 12px;
  border: 2px solid rgba(255,255,255,0.08);
}

.cta-qr-hint {
  font-size: 0.75rem;
  color: var(--gray-500);
  margin-bottom: 0;
}

/* --- Footer --- */
.footer {
  border-top: 1px solid var(--border);
  padding: 48px 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-bottom: 40px;
}

.footer-brand .logo { margin-bottom: 12px; }

.footer-brand p {
  font-size: 0.75rem;
  color: var(--text-3);
}

.footer-col h5 {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-3);
  margin-bottom: 12px;
}

.footer-col a {
  display: block;
  padding: 3px 0;
  font-size: 0.8125rem;
  color: var(--text-2);
}

.footer-col a:hover { color: var(--text); }

.footer-bottom {
  border-top: 1px solid var(--border-subtle);
  padding-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.6875rem;
  color: var(--text-3);
}

/* --- Page Hero (inner pages) --- */
.page-hero {
  padding: calc(var(--header-h) + 56px) 0 56px;
  border-bottom: 1px solid var(--border-subtle);
}

.page-hero h1 { margin-bottom: 8px; }

.page-hero p {
  font-size: 1.0625rem;
  max-width: 520px;
}

/* --- Feature detail (product page) --- */
.feature-section {
  padding: 56px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.feature-section:last-child { border-bottom: none; }

.feature-section .feat-num {
  font-size: 0.6875rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.1em;
  margin-bottom: 8px;
}

.feature-section h3 { font-size: 1.375rem; margin-bottom: 8px; }

.feature-section > .container > p { max-width: 520px; }

.feat-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 28px;
}

.feat-item {
  padding: 20px;
  background: var(--gray-50);
  border-radius: 10px;
}

.feat-item h4 { font-size: 0.875rem; margin-bottom: 4px; font-weight: 600; }

.feat-item p {
  font-size: 0.8125rem;
  color: var(--text-3);
  margin-bottom: 0;
}

/* --- Timeline --- */
.timeline {
  position: relative;
  max-width: 560px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 1px;
  background: var(--border);
}

.timeline-item {
  padding-left: 28px;
  padding-bottom: 28px;
  position: relative;
}

.timeline-item:last-child { padding-bottom: 0; }

.timeline-dot {
  position: absolute;
  left: -4px; top: 6px;
  width: 9px; height: 9px;
  background: var(--accent);
  border-radius: 50%;
}

.timeline-item h4 { font-size: 0.875rem; margin-bottom: 2px; }
.timeline-item p { font-size: 0.8125rem; margin-bottom: 0; }

/* --- Values grid --- */
.values-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.value-item {
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: 10px;
}

.value-item h4 { font-size: 0.9375rem; margin-bottom: 4px; }
.value-item p { font-size: 0.8125rem; margin-bottom: 0; color: var(--text-3); }

/* --- ROI Cards --- */
.roi-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.roi-item {
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: 10px;
  text-align: center;
}

.roi-item .roi-num {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: -0.02em;
}

.roi-item p {
  font-size: 0.8125rem;
  color: var(--text-3);
  margin-bottom: 0;
}

/* --- Animations: Linear-style reveal --- */
.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Legacy support */
.fade-in {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Slide up from below — more dramatic entrance */
.slide-up {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.slide-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Scale in — for images and cards */
.scale-in {
  opacity: 0;
  transform: scale(0.92);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.scale-in.visible {
  opacity: 1;
  transform: scale(1);
}

/* --- Reduced motion --- */
@media (prefers-reduced-motion: reduce) {
  .reveal,
  .fade-in {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .mobile-menu {
    transition: none;
  }
  .faq-answer {
    transition: none;
  }
}

/* --- Responsive: Tablet (768px+) --- */
@media (min-width: 768px) {
  h1 { font-size: 3.25rem; }
  h2 { font-size: 2.25rem; }

  .section { padding: 120px 0; }

  .hero { padding: calc(var(--header-h) + 80px) 0 100px; min-height: 90vh; }
  .hero h1 { font-size: 4.5rem; }
  .hero-actions { flex-direction: row; }
  .hero-stat .num { font-size: 2rem; }

  .hero-phone-stack { width: 280px; height: 500px; }
  .hero-phone-img { width: 230px; }
  .hero-phone-back { top: 70px; }

  .pain-grid { grid-template-columns: repeat(2, 1fr); }
  .pain-item { border-right: 1px solid var(--border-subtle); }
  .pain-item:nth-child(2n) { border-right: none; }

  .steps { grid-template-columns: repeat(2, 1fr); }
  .step { border-right: 1px solid var(--border-subtle); }
  .step:nth-child(2n) { border-right: none; }

  .testimonial-list { grid-template-columns: repeat(2, 1fr); gap: 40px; }
  .pricing-grid { grid-template-columns: repeat(2, 1fr); }
  .feat-grid { grid-template-columns: repeat(2, 1fr); }

  /* CTA dual-mode */
  .cta-desktop { display: block; }
  .cta-mobile { display: none; }

  .hero-layout { flex-direction: row; gap: 64px; align-items: center; }
  .hero-side { width: 320px; flex-shrink: 0; }

  .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; }
  .footer-bottom { flex-direction: row; justify-content: space-between; }

  .mobile-toggle { display: none; }
  .nav { display: flex; }
  .header-cta { display: inline-flex; }

  .page-hero { padding: calc(var(--header-h) + 72px) 0 64px; }

  .roi-grid { grid-template-columns: repeat(3, 1fr); }
  .values-grid { grid-template-columns: repeat(3, 1fr); }
}

/* --- Responsive: Desktop (1024px+) --- */
@media (min-width: 1024px) {
  h1 { font-size: 3.75rem; }
  .hero h1 { font-size: 5.5rem; }

  .steps { grid-template-columns: repeat(4, 1fr); }
  .step { border-right: 1px solid var(--border-subtle); }
  .step:nth-child(2n) { border-right: 1px solid var(--border-subtle); }
  .step:last-child { border-right: none; }

  .pain-grid { grid-template-columns: repeat(3, 1fr); }
  .testimonial-list { grid-template-columns: repeat(3, 1fr); }
  .feat-grid { grid-template-columns: repeat(3, 1fr); }
}

/* --- Utility --- */
.text-center { text-align: center; }
.text-accent { color: var(--accent); }

/* --- Asymmetric hero layout --- */
.hero-layout {
  display: flex;
  flex-direction: column;
  gap: 48px;
  align-items: center;
}

.hero-main {
  flex: 1;
}

.hero-side {
  flex-shrink: 0;
}

/* --- Contour rings slow drift animation --- */
@keyframes contour-drift {
  0%, 100% { transform: translateY(-50%) scale(1); }
  50% { transform: translateY(-50%) scale(1.03); }
}

.hero::after {
  animation: contour-drift 12s ease-in-out infinite;
  transition: none; /* parallax overrides via JS */
}

@media (prefers-reduced-motion: reduce) {
  .hero::after { animation: none; }
}

/* --- Cursor glow that follows mouse --- */
.hero-cursor-glow {
  position: absolute;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(15,118,110,0.12) 0%, rgba(15,118,110,0.03) 40%, transparent 70%);
  pointer-events: none;
  transform: translate(-50%, -50%);
  z-index: 0;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.hero:hover .hero-cursor-glow,
.hero-cursor-glow.active {
  opacity: 1;
}

/* --- Section transition: sharp edge --- */
.hero {
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 40px), 0 100%);
}

.section:first-of-type {
  padding-top: 80px;
}

@media (min-width: 768px) {
  .hero {
    clip-path: polygon(0 0, 100% 0, 100% calc(100% - 60px), 0 100%);
  }
  .section:first-of-type {
    padding-top: 100px;
  }
}

/* --- Hero phone mockup --- */
.hero-phone-stack {
  position: relative;
  width: 240px;
  height: 420px;
}

.hero-phone-img {
  position: absolute;
  width: 200px;
  border-radius: 20px;
  border: 2px solid rgba(255,255,255,0.1);
  box-shadow: 0 24px 80px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,255,255,0.04);
}

.hero-phone-stack:hover .hero-phone-front {
  transform: translateY(-4px);
}

.hero-phone-stack:hover .hero-phone-back {
  opacity: 0.5;
}

.hero-phone-front {
  top: 0;
  right: 0;
  z-index: 2;
}

.hero-phone-back {
  top: 60px;
  left: 0;
  z-index: 1;
  opacity: 0.55;
  transform: scale(0.92);
}

/* --- Pain grid --- */
.pain-highlight {
  grid-column: span 1;
}

/* --- Steps staggered --- */
.step-detail {
  display: none;
  font-size: 0.8125rem;
  color: var(--text-3);
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border-subtle);
}

.step.expanded .step-detail {
  display: block;
}

/* --- Stats bar (inline) --- */
.stats-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}

.stat-cell {
  flex: 1 1 0;
  min-width: 120px;
  padding: 24px 20px;
  text-align: center;
  border-right: 1px solid var(--border-subtle);
}

.stat-cell:last-child { border-right: none; }

.stat-cell .stat-num {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--gray-950);
  letter-spacing: -0.02em;
}

.stat-cell .stat-label {
  font-size: 0.75rem;
  color: var(--text-3);
  margin-top: 2px;
}
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 32px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.hidden { display: none; }

/* --- Product Showcase Gallery --- */
.section--showcase {
  padding: 80px 0 60px;
}

.showcase-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.showcase-item {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  background: var(--gray-50);
  border: 1px solid var(--border);
  aspect-ratio: 4 / 3;
  cursor: pointer;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.showcase-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 60px rgba(0,0,0,0.08);
}

.showcase-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.showcase-item:hover img {
  transform: scale(1.04);
}

.showcase-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px;
  background: linear-gradient(to top, rgba(0,0,0,0.6) 0%, transparent 100%);
  color: var(--white);
  transform: translateY(8px);
  opacity: 0;
  transition: all 0.3s ease;
}

.showcase-item:hover .showcase-caption {
  transform: translateY(0);
  opacity: 1;
}

.showcase-caption h3 {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 2px;
  letter-spacing: 0;
}

.showcase-caption p {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.7);
  margin-bottom: 0;
  line-height: 1.4;
}

/* Placeholder cards for missing screenshots */
.showcase-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--gray-50);
  padding: 24px;
}

.showcase-placeholder-icon {
  font-size: 2.5rem;
  line-height: 1;
}

.showcase-placeholder span {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text);
}

.showcase-placeholder small {
  font-size: 0.75rem;
  color: var(--text-3);
}

@media (min-width: 768px) {
  .showcase-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .showcase-item--large {
    grid-column: span 2;
    aspect-ratio: 16 / 9;
  }

  .section--showcase {
    padding: 60px 0;
  }
}

@media (min-width: 1024px) {
  .showcase-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .showcase-item--large {
    grid-column: span 2;
    aspect-ratio: 4 / 3;
  }
}

/* --- WeChat Float --- */
.wx-float {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 900;
}

.wx-float-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px; height: 44px;
  background: var(--success);
  border-radius: 50%;
  border: none;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(34,197,94,0.25);
  transition: transform 0.15s;
  color: white;
  font-size: 1.125rem;
}

.wx-float-btn:hover { transform: scale(1.06); }

.wx-float-label {
  position: absolute;
  bottom: 52px;
  right: 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 0.6875rem;
  color: var(--text);
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
  opacity: 0;
  transform: translateY(4px);
  transition: all 0.15s;
  pointer-events: none;
}

.wx-float:hover .wx-float-label {
  opacity: 1;
  transform: translateY(0);
}
