/* =============================================
   RUTGON – landing.css
   Hero, Features, How-It-Works, Stats, Pricing,
   Testimonials, CTA — tất cả sections trang chủ
   ============================================= */

/* ---------- HERO ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 140px 0 60px;
  z-index: 1;
  overflow: hidden;
}

.hero-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
}
.hero-glow-1 {
  width: 700px;
  height: 700px;
  top: -200px;
  left: 50%;
  transform: translateX(-60%);
  background: radial-gradient(ellipse, rgba(99,102,241,0.22) 0%, transparent 70%);
  animation: glow-pulse 6s ease-in-out infinite;
}
.hero-glow-2 {
  width: 500px;
  height: 500px;
  bottom: 0;
  right: -100px;
  background: radial-gradient(ellipse, rgba(6,182,212,0.15) 0%, transparent 70%);
  animation: glow-pulse 8s ease-in-out infinite reverse;
}

.hero-content {
  text-align: center;
  position: relative;
  z-index: 2;
  max-width: 860px;
  width: 100%;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(99,102,241,0.1);
  border: 1px solid rgba(99,102,241,0.25);
  border-radius: 999px;
  padding: 6px 16px;
  font-size: 14px;
  font-weight: 500;
  color: var(--accent-1);
  margin-bottom: 28px;
  animation: fadeInDown 0.6s var(--ease) forwards;
}

.badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-1);
  box-shadow: 0 0 6px var(--accent-1);
  animation: badge-blink 2s ease infinite;
}

.hero-title {
  font-size: clamp(40px, 6vw, 76px);
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -2px;
  margin-bottom: 24px;
  animation: fadeInUp 0.7s var(--ease) 0.1s both;
}

.hero-subtitle {
  font-size: clamp(16px, 2.2vw, 19px);
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 48px;
  line-height: 1.7;
  animation: fadeInUp 0.7s var(--ease) 0.2s both;
}

/* --- HERO STATS --- */
.hero-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  flex-wrap: wrap;
  margin-top: 16px;
  animation: fadeInUp 0.7s var(--ease) 0.45s both;
}

.stat-item {
  text-align: center;
  padding: 16px 36px;
}

.stat-number {
  display: block;
  font-size: clamp(22px, 3vw, 30px);
  font-weight: 800;
  background: var(--gradient-button);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.2;
}

.stat-label {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--border);
}

.hero-scroll-hint {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
  animation: fadeIn 1s 1s both;
}

/* ---------- FEATURES ---------- */
.features {
  padding: var(--section-py) 0;
  position: relative;
  z-index: 1;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: auto auto;
  gap: 20px;
}

.feature-card--large {
  grid-column: 1 / 2;
  grid-row: 1 / 3;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 32px;
  transition: border-color var(--dur), transform var(--dur), box-shadow var(--dur);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at top left, rgba(99,102,241,0.08) 0%, transparent 60%);
  opacity: 0;
  transition: opacity var(--dur);
}

.feature-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(99,102,241,0.15);
}

.feature-card:hover::before { opacity: 1; }

.feature-card-icon {
  font-size: 36px;
  margin-bottom: 16px;
  display: inline-flex;
  background: var(--gradient-main);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 4px 12px rgba(99,102,241,0.3));
}

.feature-card h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 12px;
}

.feature-card p {
  color: var(--text-secondary);
  font-size: 15px;
  line-height: 1.65;
}

.feature-card code {
  background: rgba(99,102,241,0.15);
  color: var(--accent-1);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 13px;
}

.feature-preview { margin-top: 28px; }

.chart-bars {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 100px;
}

.bar {
  flex: 1;
  height: var(--h);
  background: var(--gradient-main);
  border-radius: 6px 6px 0 0;
  opacity: 0.7;
  transition: height 0.5s var(--ease-spring), opacity var(--dur);
  animation: bar-grow 0.8s var(--ease-spring) both;
  animation-play-state: paused;
}

.bar:nth-child(1) { animation-delay: 0.1s; }
.bar:nth-child(2) { animation-delay: 0.2s; }
.bar:nth-child(3) { animation-delay: 0.3s; }
.bar:nth-child(4) { animation-delay: 0.4s; }
.bar:nth-child(5) { animation-delay: 0.5s; }
.bar:nth-child(6) { animation-delay: 0.6s; }
.bar:nth-child(7) { animation-delay: 0.7s; }

.feature-card:hover .bar { opacity: 1; }

/* ---------- HOW IT WORKS ---------- */
.how-it-works {
  padding: var(--section-py) 0;
  position: relative;
  z-index: 1;
}

.steps-wrapper {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0;
  max-width: 760px;
  margin: 0 auto;
}

.steps-line {
  position: absolute;
  left: 38px;
  top: 60px;
  bottom: 60px;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent-1), var(--accent-2), transparent);
  opacity: 0.3;
}

.step {
  display: flex;
  align-items: flex-start;
  gap: 32px;
  padding: 32px;
  border-radius: 20px;
  transition: background var(--dur);
  position: relative;
}

.step:hover { background: rgba(99,102,241,0.06); }

.step-number {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: var(--gradient-main);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 800;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 4px 16px rgba(99,102,241,0.4);
}

.step-content { flex: 1; }

.step-content h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
}

.step-content p {
  color: var(--text-secondary);
  line-height: 1.65;
}

.step-icon-wrap {
  font-size: 32px;
  color: var(--accent-1);
  opacity: 0.6;
  flex-shrink: 0;
  background: var(--gradient-main);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 4px 8px rgba(99,102,241,0.2));
}

/* ---------- STATS SECTION ---------- */
.stats-section {
  padding: var(--section-py) 0;
  position: relative;
  z-index: 1;
  overflow: hidden;
}

.stats-bg-blur {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 50%, rgba(99,102,241,0.12) 0%, transparent 70%);
  pointer-events: none;
}

.big-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.big-stat {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 40px 28px;
  text-align: center;
  transition: border-color var(--dur), transform var(--dur);
}

.big-stat:hover {
  border-color: var(--border-hover);
  transform: translateY(-4px);
}

.big-stat-number {
  font-size: clamp(36px, 4vw, 52px);
  font-weight: 900;
  line-height: 1;
  margin-bottom: 12px;
}

.big-stat-label {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
}

.big-stat-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* ---------- PRICING ---------- */
.pricing {
  padding: var(--section-py) 0;
  position: relative;
  z-index: 1;
}

.pricing-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 56px;
}

.toggle-label {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.toggle-btn {
  position: relative;
  width: 52px;
  height: 28px;
  border-radius: 999px;
  background: rgba(99,102,241,0.2);
  border: 1px solid rgba(99,102,241,0.3);
  cursor: pointer;
  transition: background var(--dur);
}

.toggle-btn[aria-checked="true"] { background: var(--gradient-main); }

.toggle-thumb {
  position: absolute;
  top: 4px;
  left: 4px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  transition: transform var(--dur) var(--ease-spring);
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

.toggle-btn[aria-checked="true"] .toggle-thumb { transform: translateX(24px); }

.save-badge {
  background: rgba(16,185,129,0.15);
  color: #10b981;
  border: 1px solid rgba(16,185,129,0.3);
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: start;
}

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 40px 32px;
  position: relative;
  transition: border-color var(--dur), transform var(--dur), box-shadow var(--dur);
}

.pricing-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-4px);
}

.pricing-card--popular {
  border-color: rgba(99,102,241,0.5);
  background: linear-gradient(135deg, rgba(99,102,241,0.08), rgba(139,92,246,0.08));
  box-shadow: 0 0 0 1px rgba(99,102,241,0.3), 0 20px 60px rgba(99,102,241,0.2);
  transform: scale(1.03);
}

.pricing-card--popular:hover { transform: scale(1.03) translateY(-4px); }

.popular-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gradient-button);
  color: #fff;
  padding: 4px 20px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.plan-name {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 20px;
}

.plan-price {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-bottom: 32px;
}

.price-currency { font-size: 24px; font-weight: 700; color: var(--text-secondary); }

.price-amount {
  font-size: 48px;
  font-weight: 900;
  line-height: 1;
  background: var(--gradient-button);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  transition: all 0.4s var(--ease);
}

.price-period { font-size: 15px; color: var(--text-muted); }

.plan-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 36px;
}

.plan-features li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--text-secondary);
}

.plan-features li.disabled { opacity: 0.4; }

.check { color: var(--icon-success); font-weight: 700; font-size: 14px; display: inline-flex; }
.cross { color: var(--text-muted); font-size: 14px; opacity: 0.5; display: inline-flex; }
.plan-btn { width: 100%; justify-content: center; }

/* ---------- TESTIMONIALS ---------- */
.testimonials {
  padding: var(--section-py) 0;
  position: relative;
  z-index: 1;
  overflow: hidden;
}

.testimonials-track {
  overflow: hidden;
  cursor: grab;
  user-select: none;
}

.testimonials-track:active { cursor: grabbing; }

.testimonials-inner {
  display: flex;
  gap: 24px;
  transition: transform 0.5s var(--ease);
  will-change: transform;
}

.testimonial-card {
  min-width: calc(33.333% - 16px);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 32px;
  flex-shrink: 0;
  transition: border-color var(--dur), box-shadow var(--dur);
}

.testimonial-card:hover {
  border-color: var(--border-hover);
  box-shadow: 0 8px 30px rgba(99,102,241,0.12);
}

.testimonial-stars {
  font-size: 16px;
  color: var(--icon-star);
  margin-bottom: 16px;
  display: flex;
  gap: 4px;
  filter: drop-shadow(0 2px 4px rgba(245, 158, 11, 0.25));
}

.testimonial-card p {
  color: var(--text-secondary);
  font-size: 15px;
  line-height: 1.7;
  margin-bottom: 24px;
  font-style: italic;
}

.testimonial-card p::before { content: '"'; }
.testimonial-card p::after  { content: '"'; }

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 14px;
}

.author-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
  overflow: hidden;
  background: var(--bg-card);
}

.author-avatar img { width: 100%; height: 100%; object-fit: cover; }

.author-name { font-size: 15px; font-weight: 700; }
.author-role { font-size: 13px; color: var(--text-muted); }

.testimonial-dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 32px;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border);
  border: none;
  cursor: pointer;
  transition: all var(--dur) var(--ease-spring);
}

.dot.active {
  background: var(--accent-1);
  width: 24px;
  border-radius: 4px;
}

/* ---------- CTA BANNER ---------- */
.cta-banner {
  padding: 120px 0;
  position: relative;
  z-index: 1;
  overflow: hidden;
  text-align: center;
}

.cta-glow {
  position: absolute;
  inset: -50%;
  background: radial-gradient(ellipse at 50% 50%, rgba(99,102,241,0.2) 0%, transparent 65%);
  pointer-events: none;
}

.cta-content { position: relative; z-index: 2; }

.cta-content h2 {
  font-size: clamp(32px, 4.5vw, 56px);
  font-weight: 900;
  line-height: 1.15;
  margin-bottom: 20px;
}

.cta-content p {
  font-size: 18px;
  color: var(--text-secondary);
  margin-bottom: 48px;
}

.cta-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* ---------- LIGHT THEME LANDING OVERRIDES ---------- */
[data-theme="light"] .hero-glow-1 {
  background: radial-gradient(ellipse, rgba(99,102,241,0.18) 0%, transparent 70%);
}
[data-theme="light"] .hero-glow-2 {
  background: radial-gradient(ellipse, rgba(8,145,178,0.12) 0%, transparent 70%);
}
[data-theme="light"] .hero-badge {
  background: rgba(99,102,241,0.1);
  border-color: rgba(99,102,241,0.25);
  color: var(--accent-1);
}
[data-theme="light"] .feature-card::before {
  background: radial-gradient(ellipse at top left, rgba(99,102,241,0.06) 0%, transparent 60%);
}
[data-theme="light"] .stats-bg-blur {
  background: radial-gradient(ellipse at 50% 50%, rgba(99,102,241,0.08) 0%, transparent 70%);
}
[data-theme="light"] .cta-glow {
  background: radial-gradient(ellipse at 50% 50%, rgba(99,102,241,0.12) 0%, transparent 65%);
}
[data-theme="light"] .pricing-card--popular {
  background: linear-gradient(135deg, rgba(82,83,204,0.06), rgba(124,58,237,0.06));
  box-shadow: 0 0 0 1px rgba(82,83,204,0.35), 0 16px 48px rgba(82,83,204,0.12);
}
[data-theme="light"] .step:hover { background: rgba(99,102,241,0.04); }
[data-theme="light"] .scroll-top { box-shadow: 0 4px 20px rgba(82,83,204,0.35); }
