@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ==================== DESIGN TOKENS ==================== */
:root {
  --bg-primary: #0a0e1a;
  --bg-secondary: #111827;
  --bg-card: #1a1f35;
  --bg-card-hover: #222844;
  --bg-glass: rgba(26, 31, 53, 0.75);
  --bg-input: #151b2e;

  --text-primary: #e8eaf0;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-white: #ffffff;

  --accent-primary: #7c3aed;
  --accent-primary-hover: #6d28d9;
  --accent-secondary: #a78bfa;
  --accent-gold: #f59e0b;
  --accent-gold-light: #fbbf24;

  --gradient-hero: linear-gradient(135deg, #7c3aed 0%, #2563eb 50%, #06b6d4 100%);
  --gradient-card: linear-gradient(145deg, #1a1f35 0%, #111827 100%);
  --gradient-accent: linear-gradient(135deg, #7c3aed 0%, #a78bfa 100%);
  --gradient-gold: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);

  --border-color: rgba(148, 163, 184, 0.12);
  --border-accent: rgba(124, 58, 237, 0.3);

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 20px rgba(124, 58, 237, 0.3);

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;

  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Cung colors */
  --cung-red: #ef4444;
  --cung-orange: #f97316;
  --cung-amber: #f59e0b;
  --cung-green: #22c55e;
  --cung-blue: #3b82f6;
  --cung-purple: #8b5cf6;
}

/* ==================== RESET & BASE ==================== */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family);
  background-color: var(--bg-primary);
  background-image:
    linear-gradient(rgba(8, 12, 24, 0.95), rgba(8, 12, 24, 0.95)),
    url('../images/trong-dong.jpg');
  background-size: cover, cover;
  background-repeat: no-repeat, no-repeat;
  background-position: center center, center center;
  background-attachment: fixed, fixed;
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

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

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

/* ==================== LAYOUT ==================== */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

.container-narrow {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ==================== HEADER / NAV ==================== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(10, 14, 26, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
}

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

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 700;
  color: var(--text-white);
}

.navbar-brand .logo-icon {
  font-size: 28px;
}

.navbar-brand .brand-text {
  display: inline-flex;
  flex-direction: column;
  line-height: 1.15;
}

.navbar-brand .brand-slogan {
  font-size: 10px;
  font-weight: 500;
  color: var(--text-muted);
  letter-spacing: 0.3px;
  white-space: nowrap;
}

.navbar-brand .logo-icon img {
  width: 28px;
  height: 28px;
  display: block;
}

.footer-logo img {
  width: 26px;
  height: 26px;
  vertical-align: middle;
  margin-right: 8px;
}

.aff-logo img {
  width: 28px;
  height: 28px;
}

@media (max-width: 480px) {
  .navbar-brand .brand-slogan { font-size: 9px; }
}

.navbar-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
}

.navbar-nav a {
  color: var(--text-secondary);
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s;
}

.navbar-nav a:hover,
.navbar-nav a.active {
  color: var(--text-white);
  background: rgba(124, 58, 237, 0.15);
}

/* ==================== HERO SECTION ==================== */
.hero {
  padding: 140px 0 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 800px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.15) 0%, transparent 70%);
  pointer-events: none;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: rgba(124, 58, 237, 0.15);
  border: 1px solid var(--border-accent);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 500;
  color: var(--accent-secondary);
  margin-bottom: 24px;
}

.hero h1 {
  font-size: clamp(32px, 5vw, 56px);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 20px;
  background: var(--gradient-hero);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 18px;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 40px;
  line-height: 1.7;
}

/* ==================== BUTTONS ==================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 28px;
  border: none;
  border-radius: var(--radius-sm);
  font-family: var(--font-family);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s ease;
  text-decoration: none;
}

.btn-primary {
  background: var(--gradient-accent);
  color: var(--text-white);
  box-shadow: var(--shadow-glow);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 30px rgba(124, 58, 237, 0.5);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-accent);
}

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

.btn-outline:hover {
  background: rgba(124, 58, 237, 0.1);
}

.btn-gold {
  background: var(--gradient-gold);
  color: #1a1a2e;
  font-weight: 700;
}

.btn-gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.4);
}

.btn-sm {
  padding: 8px 16px;
  font-size: 13px;
}

.btn-lg {
  padding: 16px 36px;
  font-size: 17px;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* ==================== CARDS ==================== */
.card {
  background: var(--gradient-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: all 0.3s ease;
}

.card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-glow);
  transform: translateY(-4px);
}

.card-glass {
  background: var(--bg-glass);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 32px;
}

/* ==================== FEATURES GRID ==================== */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  padding: 60px 0;
}

.feature-card {
  text-align: center;
  padding: 40px 24px;
}

.feature-icon {
  font-size: 48px;
  margin-bottom: 20px;
  display: block;
}

.feature-card h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--text-white);
}

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

/* ==================== PRICING ==================== */
.pricing-section {
  padding: 80px 0;
}

.pricing-section h2 {
  text-align: center;
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text-white);
}

.pricing-section .subtitle {
  text-align: center;
  color: var(--text-secondary);
  margin-bottom: 48px;
  font-size: 16px;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  max-width: 960px;
  margin: 0 auto;
}

.pricing-card {
  text-align: center;
  position: relative;
  overflow: hidden;
}

.pricing-card.featured {
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-glow);
}

.pricing-card.featured::before {
  content: 'Phổ biến';
  position: absolute;
  top: 16px;
  right: -28px;
  background: var(--gradient-accent);
  color: white;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 36px;
  transform: rotate(45deg);
}

.pricing-name {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-white);
  margin-bottom: 8px;
}

.pricing-price {
  font-size: 42px;
  font-weight: 800;
  color: var(--text-white);
  margin-bottom: 4px;
}

.pricing-price span {
  font-size: 16px;
  font-weight: 400;
  color: var(--text-muted);
}

.pricing-desc {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 24px;
}

.pricing-features {
  list-style: none;
  text-align: left;
  margin-bottom: 28px;
}

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

.pricing-features li::before {
  content: '✓';
  color: var(--accent-gold);
  font-weight: 700;
}

/* ==================== FORM ==================== */
.form-section {
  padding: 100px 0 60px;
}

.form-container {
  max-width: 560px;
  margin: 0 auto;
}

.form-container h2 {
  text-align: center;
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-white);
}

.form-container .subtitle {
  text-align: center;
  color: var(--text-secondary);
  margin-bottom: 36px;
  font-size: 15px;
}

.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-input,
.form-select {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-family: var(--font-family);
  font-size: 15px;
  transition: border-color 0.2s;
}

.form-input:focus,
.form-select:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.15);
}

.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2394a3b8' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
  cursor: pointer;
}

.form-select option {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

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

.form-row-3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 16px;
}

.radio-group {
  display: flex;
  gap: 16px;
}

.radio-label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 15px;
  color: var(--text-primary);
}

.radio-label input[type="radio"] {
  accent-color: var(--accent-primary);
  width: 18px;
  height: 18px;
}

/* ==================== OVERVIEW INFO ==================== */
.overview-panel {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 32px;
}

.overview-item {
  display: flex;
  justify-content: space-between;
  padding: 10px 16px;
  background: var(--bg-input);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
}

.overview-item .label {
  font-size: 13px;
  color: var(--text-muted);
}

.overview-item .value {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-white);
}

/* ==================== LÁ SỐ TABLE ==================== */
.laso-container {
  margin-bottom: 32px;
  overflow-x: auto;
}

.laso-table {
  width: 100%;
  min-width: 800px;
  border-collapse: separate;
  border-spacing: 3px;
}

.laso-cell {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 10px 8px;
  vertical-align: top;
  width: 25%;
  min-height: 180px;
  position: relative;
  cursor: pointer;
  transition: all 0.2s;
}

.laso-cell:hover {
  border-color: var(--accent-primary);
  background: var(--bg-card-hover);
}

.laso-cell.active {
  border-color: var(--accent-primary);
  box-shadow: inset 0 0 0 1px var(--accent-primary);
}

.laso-center {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: var(--text-muted);
  min-height: 180px;
}

.cell-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 6px;
}

.cell-canchi {
  font-size: 11px;
  color: var(--text-muted);
}

.cell-nguhanh {
  font-size: 10px;
  color: var(--text-muted);
}

.cell-cung-name {
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 4px;
}

.cell-chinh-tinh {
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 8px;
  line-height: 1.4;
}

.cell-sao-list {
  font-size: 10px;
  line-height: 1.5;
}

.cell-sao-list .sao-tot {
  color: var(--cung-amber);
}

.cell-sao-list .sao-xau {
  color: var(--cung-red);
}

.cell-footer {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px solid var(--border-color);
  font-size: 10px;
  color: var(--text-muted);
}

.cell-daivan {
  font-size: 11px;
  color: var(--accent-secondary);
  position: absolute;
  top: 8px;
  right: 8px;
}

/* ==================== ANALYSIS PANEL ==================== */
.analysis-section {
  margin-top: 32px;
}

.analysis-section h3 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-white);
  margin-bottom: 16px;
}

.analysis-buttons {
  margin-bottom: 24px;
}

.analysis-buttons h4 {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 12px;
}

.btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.btn-analysis {
  padding: 8px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-family: var(--font-family);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.btn-analysis:hover {
  border-color: var(--accent-primary);
  color: var(--text-white);
  background: var(--bg-card-hover);
}

.btn-analysis.active {
  background: var(--accent-primary);
  border-color: var(--accent-primary);
  color: var(--text-white);
}

.btn-analysis.cached {
  border-color: var(--accent-gold);
}

.btn-analysis.cached::after {
  content: '✓';
  color: var(--accent-gold);
  font-size: 12px;
}

.year-select-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.year-select-group .form-select {
  width: 120px;
  padding: 8px 12px;
  font-size: 13px;
}

/* ==================== ANALYSIS RESULT ==================== */
.analysis-result {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 32px;
  min-height: 200px;
}

.analysis-result.empty {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 15px;
}

.analysis-result h1,
.analysis-result h2,
.analysis-result h3 {
  color: var(--text-white);
  margin-top: 24px;
  margin-bottom: 12px;
}

.analysis-result h2 {
  font-size: 20px;
}

.analysis-result h3 {
  font-size: 16px;
}

.analysis-result p {
  color: var(--text-secondary);
  margin-bottom: 12px;
  line-height: 1.8;
}

.analysis-result ul,
.analysis-result ol {
  color: var(--text-secondary);
  margin-bottom: 12px;
  padding-left: 24px;
}

.analysis-result li {
  margin-bottom: 6px;
  line-height: 1.7;
}

.analysis-result strong {
  color: var(--text-white);
}

.analysis-result em {
  color: var(--accent-secondary);
}

/* ==================== LOADING ==================== */
.loading-spinner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 0;
  gap: 16px;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--border-color);
  border-top-color: var(--accent-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.loading-text {
  font-size: 14px;
  color: var(--text-muted);
}

.loading-sub {
  font-size: 12.5px;
  color: var(--text-muted);
  opacity: 0.75;
  margin-top: 6px;
}

/* ==================== FOOTER ==================== */
.footer {
  padding: 48px 0 24px;
  border-top: 1px solid var(--border-color);
  margin-top: 80px;
  background: rgba(10, 14, 26, 0.86);
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-text {
  font-size: 13px;
  color: var(--text-muted);
}

/* ==================== SECTIONS ==================== */
.section-title {
  text-align: center;
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text-white);
}

.section-subtitle {
  text-align: center;
  color: var(--text-secondary);
  margin-bottom: 48px;
  font-size: 16px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* ==================== APP LAYOUT ==================== */
.app-content {
  padding-top: 80px;
  padding-bottom: 60px;
}

.step {
  display: none;
}

.step.active {
  display: block;
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 768px) {
  .container {
    padding: 0 16px;
  }

  .navbar {
    padding: 0 16px;
  }

  .navbar-nav {
      display: none;
    }

  .hero {
    padding: 120px 0 60px;
  }

  .hero h1 {
    font-size: 28px;
  }

  .hero p {
    font-size: 15px;
  }

  .form-row,
  .form-row-2col,
  .form-row-3 {
    grid-template-columns: 1fr;
  }

  .overview-panel {
    grid-template-columns: 1fr;
  }

  .pricing-grid {
    grid-template-columns: 1fr;
    max-width: 400px;
  }

  .laso-table {
    min-width: 600px;
  }

  .laso-cell {
    padding: 8px 6px;
  }

  .cell-cung-name {
    font-size: 11px;
  }

  .cell-chinh-tinh {
    font-size: 10px;
  }

  .cell-sao-list {
    font-size: 9px;
  }

  .analysis-result {
    padding: 20px;
  }

  .footer-content {
    flex-direction: column;
    gap: 12px;
  }
}

/* ==================== ANIMATIONS ==================== */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-fade-in {
  animation: fadeIn 0.5s ease forwards;
}

.animate-slide-up {
  animation: slideUp 0.6s ease forwards;
}

/* Stagger animation */
.stagger>* {
  opacity: 0;
  animation: fadeIn 0.4s ease forwards;
}

.stagger>*:nth-child(1) {
  animation-delay: 0.05s;
}

.stagger>*:nth-child(2) {
  animation-delay: 0.1s;
}

.stagger>*:nth-child(3) {
  animation-delay: 0.15s;
}

.stagger>*:nth-child(4) {
  animation-delay: 0.2s;
}

.stagger>*:nth-child(5) {
  animation-delay: 0.25s;
}

.stagger>*:nth-child(6) {
  animation-delay: 0.3s;
}

/* ==================== PAYWALL (modal auth/upsell/QR) ==================== */
.pw-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 16px;
  animation: fadeIn 0.2s ease;
}

.pw-modal {
  background: var(--bg-surface, #1e1b2e);
  background: var(--bg-card, #1e1b2e);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 28px 24px;
  width: 100%;
  max-width: 420px;
  position: relative;
  max-height: 92vh;
  overflow-y: auto;
  animation: slideUp 0.25s ease;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
}

.pw-close {
  position: absolute;
  top: 10px;
  right: 14px;
  background: none;
  border: none;
  font-size: 26px;
  color: var(--text-muted);
  cursor: pointer;
  line-height: 1;
  padding: 4px 8px;
}

.pw-close:hover {
  color: var(--text-white);
}

.pw-close-link {
  display: block;
  margin: 14px auto 0;
  background: none;
  border: none;
  color: var(--text-muted);
  text-decoration: underline;
  cursor: pointer;
  font-size: 13px;
}

.pw-title {
  font-size: 19px;
  font-weight: 700;
  color: var(--text-white);
  margin: 0 0 14px;
  padding-right: 28px;
}

.pw-note {
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.6;
  margin: 12px 0;
}

/* Link phụ "Mở trang thanh toán PayOS" dưới QR */
.pw-alt-checkout {
  display: block;
  text-align: center;
  color: var(--text-secondary);
  font-size: 13px;
  text-decoration: underline;
  padding: 4px 0;
}

.pw-alt-checkout:hover {
  color: var(--text-white);
}

.pw-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}

.pw-tab {
  flex: 1;
  padding: 10px;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  font-weight: 600;
  font-size: 14px;
}

.pw-tab.active {
  background: var(--accent-primary, #7c3aed);
  border-color: var(--accent-primary, #7c3aed);
  color: #fff;
}

.pw-input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-white);
  font-size: 16px;
  margin-bottom: 10px;
  box-sizing: border-box;
}

.pw-input:focus {
  outline: none;
  border-color: var(--accent-primary, #7c3aed);
}

.pw-consent {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  font-size: 12px;
  color: var(--text-secondary);
  margin: 6px 0 12px;
  line-height: 1.5;
}

.pw-consent a {
  color: var(--accent-secondary, #a78bfa);
}

.pw-btn-primary {
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 10px;
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  margin-top: 8px;
}

.pw-btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.pw-btn-secondary {
  width: 100%;
  padding: 11px;
  border-radius: 10px;
  border: 1px solid var(--accent-primary, #7c3aed);
  background: transparent;
  color: var(--accent-secondary, #a78bfa);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  margin-top: 8px;
}

.pw-error {
  color: var(--cung-red, #ef4444);
  font-size: 13px;
  min-height: 18px;
  margin: 4px 0;
}

.pw-forgot,
.pw-link-pricing {
  display: block;
  width: 100%;
  text-align: center;
  margin-top: 12px;
  color: var(--accent-secondary, #a78bfa);
  font-size: 13px;
  text-decoration: underline;
  cursor: pointer;
}

.pw-back-login {
  display: block;
  width: 100%;
  text-align: center;
  margin-top: 16px;
  color: var(--text-muted);
  font-size: 13px;
  text-decoration: none;
  cursor: pointer;
}
.pw-back-login:hover { color: var(--text-white); }

.pw-dev {
  font-size: 12px;
  color: var(--text-muted);
  word-break: break-all;
}

/* ===== Đăng nhập bằng Google trong modal ===== */
.pw-auth-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 0 14px;
  color: var(--text-muted);
  font-size: 12px;
}
.pw-auth-divider::before,
.pw-auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-color);
}

.pw-btn-google {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 16px;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  background: #fff;
  color: #1f2937;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s ease;
}
.pw-btn-google:hover {
  background: #f1f5f9;
}

.pw-btn-google svg {
  flex-shrink: 0;
}

.pw-item-label {
  color: var(--text-secondary);
  font-size: 14px;
  margin: 0 0 10px;
}

.pw-price-box {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 6px 0;
}

.pw-price-old {
  color: var(--text-muted);
  text-decoration: line-through;
  font-size: 15px;
}

.pw-price-sale {
  color: #fbbf24;
  font-size: 24px;
  font-weight: 800;
}

.pw-badge {
  background: #ef4444;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 20px;
}

.pw-promo-count {
  color: #f59e0b;
  font-size: 13px;
  font-weight: 600;
  margin: 6px 0;
}

.pw-offer {
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 14px;
  margin: 10px 0;
  display: grid;
  gap: 6px;
  color: var(--text-secondary);
}

.pw-offer small {
  color: var(--text-muted);
}

.pw-qr-wrap {
  text-align: center;
  margin: 12px 0;
}

.pw-qr {
  width: 252px;
  max-width: 100%;
  border-radius: 12px;
  background: #fff;
  padding: 8px;
}

.pw-order-info {
  color: var(--text-secondary);
  font-size: 14px;
  display: grid;
  gap: 6px;
  margin: 8px 0;
}

.pw-amount {
  color: #fbbf24;
  font-size: 18px;
}

.pw-code {
  color: var(--text-white);
  letter-spacing: 1px;
}

.pw-countdown {
  color: #f59e0b;
  font-weight: 700;
}

.pw-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: #22c55e;
  color: #fff;
  padding: 12px 22px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 14px;
  z-index: 1200;
  opacity: 0;
  transition: all 0.3s ease;
  max-width: 90vw;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.pw-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.pw-toast-error {
  background: #ef4444;
}

.pw-chip-login {
  color: var(--accent-secondary, #a78bfa) !important;
  font-weight: 500;
}

.pw-user-menu-box {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.pw-chip-user {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  padding: 6px 12px;
  color: #e2e8f0 !important;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  max-width: 180px;
  font-family: inherit;
}

.pw-chip-user:hover {
  background: rgba(124, 58, 237, 0.18);
}

.pw-chip-avatar {
  line-height: 1;
}

.pw-chip-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pw-chip-caret {
  font-size: 10px;
  transition: transform 0.2s ease;
}

.pw-chip-user[aria-expanded="true"] .pw-chip-caret {
  transform: rotate(180deg);
}

.pw-user-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 200px;
  background: #1c1830;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  padding: 6px;
  display: none;
  flex-direction: column;
  z-index: 1300;
}

.pw-user-dropdown.open {
  display: flex;
}

.pw-user-dropdown-item {
  display: block;
  padding: 10px 12px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  border-radius: 8px;
  text-align: left;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  width: 100%;
}

.pw-user-dropdown-item:hover {
  background: rgba(124, 58, 237, 0.18);
  color: #fff;
}

.pw-user-dropdown-logout {
  color: #fca5a5;
}

.pw-user-dropdown-logout:hover {
  background: rgba(239, 68, 68, 0.18);
  color: #fff;
}

/* ==================== BANNER SOCIAL PROOF (landing) ==================== */
.proof-banner {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 24px;
  padding: 10px 16px;
  background: rgba(124, 58, 237, 0.12);
  border: 1px solid rgba(124, 58, 237, 0.35);
  border-radius: 12px;
  margin: 0 auto 32px;
  max-width: 720px;
  font-size: 13px;
  color: var(--text-secondary);
}

.proof-banner b {
  color: #fbbf24;
}

/* ==================== GIÁ THẬT (landing) ==================== */
.price-item-old {
  color: var(--text-muted);
  text-decoration: line-through;
  font-size: 14px;
}

.price-item-sale {
  font-size: 22px;
  font-weight: 800;
  color: #fbbf24;
}

.price-item-note {
  font-size: 12px;
  color: var(--muted, var(--text-muted));
}

/* Mobile: modal dạng bottom-sheet */
@media (max-width: 768px) {
  .pw-overlay {
    align-items: flex-end;
    padding: 0;
  }

  .pw-modal {
    max-width: 100%;
    border-radius: 18px 18px 0 0;
    padding: 24px 18px calc(20px + env(safe-area-inset-bottom, 0px));
    animation: slideUp 0.25s ease;
  }

  .pw-qr {
    width: min(252px, 70vw);
  }

  .proof-banner {
    font-size: 12px;
    gap: 6px 14px;
  }
}

/* ==================== RESULT TOP ACTIONS ==================== */
.result-action-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.result-export-btns {
  display: flex;
  gap: 10px;
}

.result-switcher {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 6px 12px;
}
.result-switcher .switcher-label {
  color: var(--text-secondary);
  font-size: 12.5px;
  white-space: nowrap;
}
.result-switcher .form-select {
  margin: 0;
  max-width: 240px;
  font-size: 13px;
}

.btn-outline-gold {
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid #f59e0b;
  color: #fbbf24;
  font-weight: 600;
}

.btn-outline-gold:hover {
  background: #f59e0b;
  color: #171425;
}

.btn-gold {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #fff;
  font-weight: 700;
  border: none;
  box-shadow: 0 4px 14px rgba(217, 119, 6, 0.4);
}

.btn-gold:hover {
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  transform: translateY(-1px);
}

.btn-link-sub {
  background: transparent;
  border: none;
  color: var(--accent-secondary, #a78bfa);
  text-decoration: underline;
  cursor: pointer;
  font-size: 13px;
  padding: 6px 12px;
}

.btn-link-sub:hover {
  color: #fff;
}

/* ==================== CARD HEADERS & BADGES ==================== */
.card-head-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}

.card-head-title h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-white);
  margin: 0;
}

.card-head-title .icon {
  font-size: 18px;
}

.badge-tag-gold {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #fbbf24;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
}

/* ==================== LÁ SỐ TABLE & THIÊN BÀN ==================== */
.laso-table-wrap {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--border-color);
  background: #141220;
}

.laso-scroll-hint {
  display: none;
  text-align: center;
  font-size: 12px;
  color: #a78bfa;
  padding: 8px 12px;
  background: rgba(124, 58, 237, 0.1);
  border-bottom: 1px dashed rgba(124, 58, 237, 0.3);
}

@media (max-width: 768px) {
  .laso-scroll-hint {
    display: block;
  }
}

.laso-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  table-layout: fixed;
}

.laso-cell {
  width: 25%;
  height: 220px;
  border: 1px solid var(--border-color);
  background: rgba(255, 255, 255, 0.02);
  padding: 10px 10px 6px;
  vertical-align: top;
  position: relative;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}

.laso-cell:hover {
  background: rgba(124, 58, 237, 0.08);
  border-color: var(--accent-primary);
}

.laso-center {
  background: #191629;
  border: 1px solid var(--border-color);
  padding: 16px;
  vertical-align: middle;
  text-align: center;
}

.thien-ban-box {
  max-width: 380px;
  margin: 0 auto;
}

.tb-title {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 2px;
  color: #f1c40f;
  margin-bottom: 8px;
}

.tb-divider {
  height: 2px;
  background: linear-gradient(90deg, transparent, #f1c40f, transparent);
  margin: 0 auto 12px;
  width: 70%;
}

.tb-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 12px;
  text-align: left;
  font-size: 12px;
  line-height: 1.4;
}

.tb-lbl {
  color: var(--text-muted);
}

.tb-val {
  color: var(--text-white);
}

.tb-hl {
  color: #f59e0b;
  font-weight: 700;
}

.sao-chinh-tinh {
  font-weight: 700;
  font-size: 13px;
  margin-bottom: 3px;
}

.cell-empty-star {
  font-size: 11px;
  color: var(--text-muted);
  font-style: italic;
}

/* ==================== LONG-FORM ARTICLE SECTIONS ==================== */
.article-section {
  margin-top: 40px;
}

.article-section-header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 28px;
}

.section-pill-tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1px;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 10px;
}

.tag-free {
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid rgba(34, 197, 94, 0.4);
  color: #22c55e;
}

.tag-premium {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #fbbf24;
}

.article-section-title {
  font-size: 24px;
  font-weight: 800;
  color: var(--text-white);
  margin: 0 0 8px;
}

.article-section-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
}

.article-content-card {
  padding: 28px 32px;
  min-height: 160px;
}

.article-markdown-body {
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-secondary);
}

.article-markdown-body h1,
.article-markdown-body h2,
.article-markdown-body h3 {
  color: var(--text-white);
  margin: 20px 0 10px;
}

.article-markdown-body h2 {
  font-size: 18px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 6px;
}

.article-markdown-body h3 {
  font-size: 16px;
  color: #fbbf24;
}

.article-markdown-body p {
  margin-bottom: 12px;
}

.article-markdown-body ul,
.article-markdown-body ol {
  padding-left: 20px;
  margin-bottom: 14px;
}

.article-markdown-body li {
  margin-bottom: 6px;
}

.article-markdown-body strong {
  color: var(--text-white);
}

/* ==================== CUNG ARTICLE CARDS ==================== */
.cung-cards-grid,
.timeline-cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}

.cung-article-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 20px 24px;
  transition: all 0.25s ease;
  position: relative;
}

.cung-article-card:hover {
  border-color: rgba(124, 58, 237, 0.4);
}

.cung-article-card.is-unlocked {
  border-color: rgba(34, 197, 94, 0.4);
  background: rgba(34, 197, 94, 0.02);
}

.card-top-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.card-num {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(124, 58, 237, 0.2);
  color: #a78bfa;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 15px;
  flex-shrink: 0;
}

.card-titles {
  flex: 1;
}

.card-main-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-white);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.card-stars-chip {
  font-size: 12px;
  color: #fbbf24;
  font-weight: 500;
}

.card-sub-title {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 2px;
}

.badge-tag-free {
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid rgba(34, 197, 94, 0.4);
  color: #22c55e;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 6px;
  flex-shrink: 0;
}

.badge-tag-locked {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #fbbf24;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 6px;
  flex-shrink: 0;
}

.teaser-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 14px;
}

.card-unlock-cta {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  padding-top: 22px;
}

.cta-btn-wrap {
  position: relative;
  display: inline-block;
}

.cta-price-badge {
  position: absolute;
  top: 0;
  left: 100%;
  transform: translateY(-100%);
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 10.5px;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, #ef4444, #b91c1c);
  padding: 3px 8px 3px 6px;
  border-radius: 3px;
  white-space: nowrap;
  line-height: 1.4;
  pointer-events: none;
  box-shadow: 0 2px 8px rgba(239, 68, 68, 0.45);
  z-index: 2;
  letter-spacing: 0.2px;
}

.cta-price-badge::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 0;
  border-left: 6px solid #b91c1c;
  border-bottom: 6px solid transparent;
}

.cta-discount {
  color: #fde68a;
  font-weight: 800;
  margin-left: 2px;
}

.cta-divider {
  color: var(--text-muted, #94a3b8);
  font-size: 12px;
  font-style: italic;
}

/* ==================== FLOATING TABLE OF CONTENTS (TOC) ==================== */
.floating-toc-btn {
  position: fixed;
  right: 24px;
  bottom: calc(24px + env(safe-area-inset-bottom, 0px));
  background: #241d38;
  background: linear-gradient(135deg, #2b2342, #1b162b);
  border: 1px solid rgba(245, 158, 11, 0.5);
  color: #f8fafc;
  padding: 10px 18px;
  border-radius: 30px;
  cursor: pointer;
  z-index: 950;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5), 0 0 12px rgba(245, 158, 11, 0.2);
  transition: all 0.25s ease;
}

.floating-toc-btn:hover {
  transform: translateY(-2px);
  border-color: #f59e0b;
}

.toc-icon {
  font-size: 15px;
  line-height: 1;
  color: #fbbf24;
}

.toc-text {
  white-space: nowrap;
}

.zalo-float {
  position: fixed;
  right: 24px;
  bottom: calc(88px + env(safe-area-inset-bottom, 0px));
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0aa7ff, #0057ff);
  color: #fff;
  font-size: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  box-shadow: 0 8px 24px rgba(0, 87, 255, 0.4);
  z-index: 940;
  transition: transform 0.25s ease;
}

.zalo-float:hover {
  transform: translateY(-2px);
}

@media (max-width: 768px) {
  .zalo-float {
    right: 16px;
    bottom: calc(76px + env(safe-area-inset-bottom, 0px));
    width: 48px;
    height: 48px;
  }
}

.toc-drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(3px);
  z-index: 1300;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.toc-drawer-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.toc-drawer {
  position: fixed;
  top: 0;
  right: -360px;
  bottom: 0;
  width: min(360px, 85vw);
  background: #181528;
  border-left: 1px solid var(--border-color);
  z-index: 1350;
  transition: right 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

.toc-drawer.open {
  right: 0;
}

.toc-drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  border-bottom: 1px solid var(--border-color);
}

.toc-drawer-header h4 {
  font-size: 15px;
  font-weight: 700;
  color: #f1c40f;
  margin: 0;
}

.toc-drawer-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 22px;
  cursor: pointer;
  padding: 4px 8px;
}

.toc-drawer-body {
  padding: 12px 14px;
  overflow-y: auto;
  flex: 1;
}

.toc-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px;
  border-radius: 8px;
  color: var(--text-secondary);
  font-size: 14px;
  cursor: pointer;
  margin-bottom: 4px;
  transition: background 0.15s, color 0.15s;
}

.toc-item:hover {
  background: rgba(124, 58, 237, 0.15);
  color: #fff;
}

.toc-arrow {
  color: #a78bfa;
  font-size: 12px;
}

@media (max-width: 768px) {
  .floating-toc-btn {
    right: 16px;
    bottom: calc(16px + env(safe-area-inset-bottom, 0px));
    padding: 8px 14px;
    font-size: 13px;
  }

  .toc-drawer {
    top: auto;
    right: 0;
    bottom: -80vh;
    left: 0;
    width: 100%;
    max-height: 75vh;
    border-radius: 20px 20px 0 0;
    border-left: none;
    border-top: 1px solid var(--border-color);
    transition: bottom 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  }

  .toc-drawer.open {
    bottom: 0;
  }
}

/* ==================== MOBILE DRAWER AUTH & USER ==================== */
.pw-hamburger {
  display: none;
  background: none;
  border: none;
  color: var(--text-white);
  font-size: 26px;
  cursor: pointer;
  padding: 8px 10px;
  line-height: 1;
  min-width: 44px;
  min-height: 44px;
}

.pw-drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(3px);
  z-index: 1100;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.pw-drawer-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.pw-drawer {
  position: fixed;
  top: 0;
  right: -300px;
  bottom: 0;
  width: min(300px, 85vw);
  background: #171425;
  border-left: 1px solid var(--border-color);
  z-index: 1200;
  transition: right 0.3s ease;
  padding: 24px 20px calc(24px + env(safe-area-inset-bottom, 0px));
  overflow-y: auto;
}

.pw-drawer.open {
  right: 0;
}

.pw-drawer-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  transition: all 0.2s;
}

.pw-drawer-close:active {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-white);
}

.pw-drawer-user {
  margin-bottom: 12px;
}

.pw-drawer-user-info {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.pw-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.pw-u-name {
  font-weight: 700;
  color: #fff;
  font-size: 15px;
}

.pw-drawer-btn-login {
  width: 100%;
  padding: 12px;
  border-radius: 10px;
  background: var(--accent-primary);
  color: #fff;
  border: none;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  margin-top: 8px;
}

.pw-drawer-btn-logout {
  width: 100%;
  padding: 10px;
  border-radius: 8px;
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  margin-top: 8px;
}

.pw-drawer-divider {
  border: none;
  height: 1px;
  background: var(--border-color);
  margin: 16px 0;
}

.pw-drawer-link {
  display: block;
  padding: 12px 6px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 15px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.pw-drawer-link:hover,
.pw-drawer-link:active {
  color: #a78bfa;
}

.pw-drawer-user-toggle {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 8px 10px;
  cursor: pointer;
  color: #fff;
  font-family: inherit;
}

.pw-drawer-user-toggle .pw-u-name {
  flex: 1;
  text-align: left;
}

.pw-drawer-caret {
  font-size: 12px;
  transition: transform 0.2s ease;
}

.pw-drawer-user-toggle.open .pw-drawer-caret {
  transform: rotate(180deg);
}

.pw-drawer-user-menu {
  display: none;
  flex-direction: column;
  margin-top: 6px;
  padding-left: 8px;
  border-left: 2px solid rgba(124, 58, 237, 0.4);
}

.pw-drawer-user-menu.open {
  display: flex;
}

.pw-drawer-user-menu .pw-drawer-link {
  border-bottom: none;
}

.pw-drawer-btn-logout {
  width: 100%;
  padding: 10px;
  border-radius: 8px;
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  margin-top: 0;
  text-align: left;
}

@media (max-width: 768px) {
  .pw-hamburger {
    display: block;
  }
}

/* ==================== REAL-TIME SOCIAL PROOF TOAST ==================== */
.pw-social-proof {
  position: fixed;
  bottom: 24px;
  left: 24px;
  background: rgba(26, 22, 41, 0.95);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: 14px;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 850;
  opacity: 0;
  transform: translateX(-120%);
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.35s ease;
  pointer-events: none;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  max-width: 340px;
}

.pw-social-proof.show {
  opacity: 1;
  transform: translateX(0);
}

.sp-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 800;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}

.sp-content {
  line-height: 1.35;
}

.sp-text {
  font-size: 12px;
  color: #f8fafc;
  font-weight: 500;
}

.sp-text b {
  color: #fbbf24;
}

.sp-time {
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 3px;
}

@media (max-width: 768px) {
  .pw-social-proof {
    bottom: auto;
    top: 72px;
    left: 16px;
    right: 16px;
    max-width: none;
  }
}

/* ==================== BACKFILL TRỌN GÓI - PROGRESS ==================== */
.pw-bf-track {
  height: 10px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  overflow: hidden;
  margin-top: 14px;
}

.pw-bf-bar {
  height: 100%;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg, #f59e0b, #f97316);
  transition: width 0.6s ease;
}

/* ==================== HIGHLIGHT FLASH & ERRORS ==================== */
.highlight-flash {
  animation: flashHighlight 1.5s ease;
}

@keyframes flashHighlight {
  0% {
    box-shadow: 0 0 0 2px #f59e0b, 0 0 24px rgba(245, 158, 11, 0.4);
  }

  100% {
    box-shadow: none;
  }
}

.reading-error-box {
  text-align: center;
  padding: 24px 16px;
}

.err-title {
  color: #ef4444;
  font-weight: 700;
  margin-bottom: 6px;
}

.err-desc {
  color: var(--text-muted);
  font-size: 13px;
  margin-bottom: 12px;
}

.inline-spinner {
  padding: 24px 0;
}

/* ==================== MOBILE POLISH ==================== */
@media (max-width: 768px) {

  .form-input,
  .form-select,
  .pw-input {
    font-size: 16px;
  }

  .article-section-title {
    font-size: 20px;
  }

  .article-content-card {
    padding: 18px 16px;
  }

  .cung-article-card {
    padding: 16px 14px;
  }
}

/* ==================== EXACT TUVI.VN BIRTH CHART STYLES ==================== */
.laso-card-box {
  padding: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: fit-content;
  max-width: 100%;
  margin: 0 auto;
}

.laso-table-wrap {
  position: relative;
  width: 100%;
  max-width: 748px;
  margin: 0 auto;
  aspect-ratio: 748 / 1000;
  overflow: hidden;
}

#content-la-so {
  width: 100%;
  display: block;
  margin-bottom: 10px;
  background-color: transparent;
}

.table-la-so {
  position: relative;
  width: 748px;
  border-collapse: collapse;
  background-color: #f1ece3;
  color: #000;
  font-family: 'Roboto', -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  table-layout: fixed;
  box-sizing: border-box;
}

.table-la-so::before {
  content: '';
  position: absolute;
  height: 100%;
  width: 100%;
  border: 2px solid #000;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  pointer-events: none;
}

.table-la-so > tbody {
  width: 100%;
}

.cung {
  position: relative;
  width: 25%;
  height: 250px;
  padding: 0;
  vertical-align: top;
  z-index: 1;
  box-sizing: border-box;
}

.cung::before {
  content: '';
  position: absolute;
  height: 100%;
  width: 100%;
  border-right: 2px solid #000;
  border-bottom: 2px solid #000;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  pointer-events: none;
}

.cung-view {
  width: 100%;
  height: 250px;
  position: absolute;
  top: 0;
  left: 0;
  padding: 0;
  box-sizing: border-box;
}

.thien-ban {
  position: relative;
  width: 100%;
  height: 100%;
  font-size: 14px;
  z-index: 0;
  vertical-align: middle;
}

.thien-ban::before {
  content: '';
  position: absolute;
  height: 100%;
  width: 100%;
  border-right: 2px solid #000;
  border-bottom: 2px solid #000;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  pointer-events: none;
}

.cung-top {
  width: 100%;
  height: auto;
}

.view-cung-top {
  display: flex;
  justify-content: space-between;
  padding: 8px 5px 0 5px;
}

.text-dia-chi {
  margin-bottom: 0 !important;
  color: #000 !important;
  line-height: 1.2;
}

.chinh-tinh {
  text-align: center;
  font-weight: 700;
}

.text-chinh-chinh {
  margin: 0;
  text-transform: uppercase;
  font-weight: 700;
  font-size: 12px;
  line-height: 1.2;
}

.text-sao-chinh-tinh {
  text-transform: uppercase;
  cursor: pointer;
  margin-bottom: 0 !important;
  font-weight: 700;
}

.text-sao-chinh-tinh:hover {
  text-decoration-line: underline;
}

.view-cung-dai-van {
  text-align: right;
}

.text-dai-van-number {
  cursor: pointer;
  font-weight: 700;
}

.text-dai-van-number:hover {
  color: #a21313;
  text-decoration-line: underline;
}

.cung-middle {
  width: 100%;
  height: 50%;
  display: flex;
  justify-content: space-between;
  padding: 2px 0;
}

.sao-tot {
  width: 49%;
  float: left;
  padding-left: 5px;
  line-height: 1.25;
}

.sao-xau {
  width: 49%;
  padding-right: 5px;
  text-align: left;
  line-height: 1.25;
}

.text-sao-xau-tot {
  line-height: 1.25;
  white-space: nowrap;
}

.txt-tiny {
  font-size: 11px;
}

.txt-tiny-mid {
  font-size: 11px;
  font-weight: 500;
}

.txt-tiny-bold {
  font-size: 11px;
  font-weight: 700;
}

.txt-sub-content {
  font-size: 12px;
}

.txt-sub-content-mid {
  font-size: 12px;
  font-weight: 500;
}

.txt-sub-content-bold {
  font-size: 12px;
  font-weight: 700;
}

.txt-content-bold {
  font-size: 14px;
  font-weight: 700;
}

.cung-middle-tu-hoa-phai {
  position: absolute;
  bottom: 28px;
  left: 0;
  width: 100%;
  padding: 0 4px;
}

.cung-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  width: 100%;
  display: flex;
  justify-content: space-between;
  padding: 0 5px 8px 5px;
}

.cung-bottom span {
  white-space: nowrap;
  font-size: 11px;
}

.text-tieu-van {
  color: #000;
}

.khoi-tieu-han-bottom {
  position: absolute;
  bottom: -17px;
  display: flex;
  justify-content: center;
  width: 100%;
  font-size: 11px;
  color: #000;
}

.khoi-tieu-han-bottom-0 {
  position: absolute;
  bottom: -17px;
  right: -28px;
  font-size: 11px;
  color: #000;
}

.khoi-tieu-han-bottom-3 {
  position: absolute;
  bottom: -17px;
  left: -30px;
  font-size: 11px;
  color: #000;
}

.khoi-tieu-han-top {
  position: absolute;
  top: -19px;
  display: flex;
  justify-content: center;
  width: 100%;
  font-size: 11px;
  color: #000;
}

.khoi-tieu-han-top-0 {
  position: absolute;
  top: -19px;
  right: -30px;
  font-size: 11px;
  color: #000;
}

.khoi-tieu-han-top-3 {
  position: absolute;
  top: -19px;
  left: -30px;
  font-size: 11px;
  color: #000;
}

.khoi-tieu-han-mid-0 {
  position: absolute;
  height: 100%;
  display: flex;
  align-items: center;
  top: 0;
  right: -25px;
  font-size: 11px;
  color: #000;
}

.khoi-tieu-han-mid {
  position: absolute;
  height: 100%;
  display: flex;
  align-items: center;
  top: 0;
  left: -30px;
  font-size: 11px;
  color: #000;
}

.triet-position-top {
  position: absolute;
  bottom: -7px;
  left: -45px;
  background-color: #000;
  width: 86px;
  color: #fff;
  height: 16px;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 2;
}

.triet-position-top-right {
  position: absolute;
  top: -9px;
  right: -45px;
  background-color: #000;
  width: 86px;
  color: #fff;
  height: 16px;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 2;
}

.triet-position-top-center {
  position: absolute;
  top: -9px;
  right: 42px;
  background-color: #000;
  width: 86px;
  color: #fff;
  height: 16px;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 2;
}

.triet-position-bottom {
  position: absolute;
  bottom: -7px;
  left: 50px;
  background-color: #000;
  width: 86px;
  color: #fff;
  height: 16px;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 2;
}

.tuan-position-top {
  position: absolute;
  bottom: -7px;
  left: -45px;
  background-color: #d00000;
  width: 86px;
  color: #fff;
  height: 16px;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 2;
}

.tuan-position-bottom {
  position: absolute;
  bottom: -7px;
  left: 50px;
  background-color: #d00000;
  width: 86px;
  color: #fff;
  height: 16px;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 2;
}

/* THIEN BAN */
.view-thien-ban {
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 6px 10px;
}

.thien-ban-top {
  width: 80%;
  text-align: center;
}

.title-la-so-thien-ban {
  font-family: 'Segoe UI', cursive, sans-serif;
  font-size: 26px;
  letter-spacing: normal;
  line-height: 28px;
  font-weight: 700;
  color: #a21313;
}

.txt-thien-ban {
  margin-bottom: 0 !important;
  color: #000;
  letter-spacing: -0.42px;
  font-size: 12px;
}

.td-title-thien-ban {
  display: flex;
  align-items: flex-start;
  width: 100px;
  margin-top: 2px;
}

.view-list-year-la-so {
  width: 100%;
  display: flex;
}

.width-item-la-so {
  width: 50%;
}

.logo-dia-ban {
  position: absolute;
  bottom: 12px;
  right: 15px;
  width: 40px;
  height: 40px;
}

.color-black { color: #000 !important; }
.color-blue { color: #0284c7 !important; }
.color-highlight { color: #d00000 !important; }

/* ==================== TEXT TUAN/TRIET (tuvi.vn) ==================== */
.text-triet {
  background-color: #777;
  padding: 3px 5px;
  color: #fff;
  border-radius: 3px;
  -webkit-border-radius: 3px;
  -moz-border-radius: 3px;
}

.text-tuan {
  background-color: red;
  padding: 3px 5px;
  color: #fff;
  border-radius: 3px;
  -webkit-border-radius: 3px;
  -moz-border-radius: 3px;
}

/* ==================== CON GIAP LA SO (tuvi.vn sprite) ==================== */
.view-con-giap-la-so {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  right: 0;
  background-size: 100% 100%;
  background-repeat: no-repeat;
  background-position: center;
}

.view-con-giap-la-so-hover {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  right: 0;
  display: none;
  background-size: 100% 100%;
  background-repeat: no-repeat;
  background-position: center;
}

.view-con-giap {
  position: absolute;
  width: 263px;
  height: 220px;
  -webkit-mask-image: url("../images/con_giap.png");
  -webkit-mask-position-y: -24px;
  -webkit-mask-position-x: -263px;
  background-color: #00f;
  opacity: 0.15;
  pointer-events: none;
}

.overlay-con-giap {
  position: absolute;
  width: 263px;
  height: 220px;
  left: 0;
  opacity: 0.15;
}

.view-con-ty { -webkit-mask-image: url("../images/con_giap.png"); -webkit-mask-position-y: 2px; -webkit-mask-position-x: 0; }
.view-con-suu { -webkit-mask-image: url("../images/con_giap.png"); -webkit-mask-position-y: -24px; -webkit-mask-position-x: -263px; }
.view-con-dan { -webkit-mask-image: url("../images/con_giap.png"); -webkit-mask-position-y: 0; -webkit-mask-position-x: -530px; }
.view-con-mao { -webkit-mask-image: url("../images/con_giap.png"); -webkit-mask-position-x: 263px; }
.view-con-thin { -webkit-mask-image: url("../images/con_giap.png"); -webkit-mask-position-y: -240px; -webkit-mask-position-x: 0; }
.view-con-ti { -webkit-mask-image: url("../images/con_giap.png"); -webkit-mask-position-y: -240px; -webkit-mask-position-x: -263px; }
.view-con-ngo { -webkit-mask-image: url("../images/con_giap.png"); -webkit-mask-position-y: -240px; -webkit-mask-position-x: -510px; }
.view-con-mui { -webkit-mask-image: url("../images/con_giap.png"); -webkit-mask-position-y: -240px; -webkit-mask-position-x: 270px; }
.view-con-than { -webkit-mask-image: url("../images/con_giap.png"); -webkit-mask-position-y: 200px; -webkit-mask-position-x: 0; }
.view-con-dau { -webkit-mask-image: url("../images/con_giap.png"); -webkit-mask-position-y: 222px; -webkit-mask-position-x: -255px; }
.view-con-tuat { -webkit-mask-image: url("../images/con_giap.png"); -webkit-mask-position-y: 222px; -webkit-mask-position-x: -520px; }
.view-con-hoi { -webkit-mask-image: url("../images/con_giap.png"); -webkit-mask-position-y: 230px; -webkit-mask-position-x: 263px; }

/* list-line: đường viền nối cung (tuvi.vn) */
.list-line-0 { background: url("../images/cung-chieu-03.png"); }
.list-line-1 { background: url("../images/cung-chieu-03.png"); -webkit-transform: scaleX(-1); }
.list-line-2 { background: url("../images/cung-chieu-02.png"); -webkit-transform: scaleX(-1); }
.list-line-3 { background: url("../images/cung-chieu-01.png"); -webkit-transform: scaleX(-1); }
.list-line-4 { background: url("../images/cung-chieu-01.png"); transform: rotate(180deg); }
.list-line-5 { background: url("../images/cung-chieu-02.png"); transform: rotate(180deg); }
.list-line-6 { background: url("../images/cung-chieu-03.png"); transform: rotate(180deg); }
.list-line-7 { background: url("../images/cung-chieu-03.png"); -webkit-transform: scaleY(-1); }
.list-line-8 { background: url("../images/cung-chieu-02.png"); -webkit-transform: scaleY(-1); }
.list-line-9 { background: url("../images/cung-chieu-01.png"); -webkit-transform: scaleY(-1); }
.list-line-10 { background: url("../images/cung-chieu-01.png"); }
.list-line-11 { background: url("../images/cung-chieu-02.png"); }

.view-con-ty-la-so { background: url("../images/con_giap_la_so (2).png") 0 0; }
.view-con-suu-la-so { background: url("../images/con_giap_la_so (2).png") -234px 0; }
.view-con-dan-la-so { background: url("../images/con_giap_la_so (2).png") -468px 0; }
.view-con-mao-la-so { background: url("../images/con_giap_la_so (2).png") 234px 0; }
.view-con-thin-la-so { background: url("../images/con_giap_la_so (2).png") 0 -300px; }
.view-con-ti-la-so { background: url("../images/con_giap_la_so (2).png") -234px -300px; }
.view-con-ngo-la-so { background: url("../images/con_giap_la_so (2).png") -468px -300px; }
.view-con-mui-la-so { background: url("../images/con_giap_la_so (2).png") 234px -300px; }
.view-con-than-la-so { background: url("../images/con_giap_la_so (2).png") 0 300px; }
.view-con-dau-la-so { background: url("../images/con_giap_la_so (2).png") -234px 300px; }
.view-con-tuat-la-so { background: url("../images/con_giap_la_so (2).png") -468px 300px; }
.view-con-hoi-la-so { background: url("../images/con_giap_la_so (2).png") 234px 300px; }

/* ==================== HOMEPAGE (index.html) - MOBILE FIRST ==================== */
.home-hero-section {
  padding: 96px 0 48px;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(600px 300px at 80% -10%, rgba(124, 58, 237, 0.18), transparent 70%),
    radial-gradient(500px 300px at 0% 110%, rgba(6, 182, 212, 0.12), transparent 70%),
    linear-gradient(rgba(8, 12, 24, 0.3), rgba(8, 12, 24, 0.3));
}

.hero-grid-2col {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  align-items: center;
}

.hero-left-content {
  order: 1;
}

.hero-right-form-wrap {
  order: 2;
}

.hero-tag-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: rgba(124, 58, 237, 0.12);
  border: 1px solid rgba(124, 58, 237, 0.35);
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-secondary);
  margin-bottom: 18px;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.5);
  animation: pulseDot 1.6s infinite;
}

@keyframes pulseDot {
  0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.5); }
  70% { box-shadow: 0 0 0 8px rgba(34, 197, 94, 0); }
  100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

.hero-main-title {
  font-family: 'Plus Jakarta Sans', var(--font-family);
  font-size: clamp(28px, 8vw, 52px);
  font-weight: 800;
  line-height: 1.2;
  color: var(--text-white);
  margin-bottom: 16px;
}

.gold-gradient-text {
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 50%, #d97706 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.hero-main-desc {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 22px;
}

.hero-main-desc b {
  color: var(--text-white);
}

.hero-value-bullets {
  display: grid;
  gap: 10px;
  margin-bottom: 22px;
}

.v-bullet {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13.5px;
  color: var(--text-secondary);
  line-height: 1.55;
}

.v-bullet b {
  color: var(--text-white);
}

.v-icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid rgba(34, 197, 94, 0.4);
  color: #22c55e;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1px;
}

.hero-social-strip {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.avatars-group {
  display: flex;
}

.mini-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 2px solid var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  margin-left: -8px;
}

.mini-avatar:first-child { margin-left: 0; }

.social-strip-text {
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.4;
}

.social-strip-text b { color: var(--text-white); }

.stars {
  font-size: 13px;
  color: #fbbf24;
  letter-spacing: 1px;
}

.stars b { color: var(--text-white); margin-left: 4px; }

.hero-form-card {
  background: linear-gradient(160deg, rgba(26, 31, 53, 0.92), rgba(17, 24, 39, 0.92));
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 20px;
  padding: 22px 18px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(124, 58, 237, 0.08);
  backdrop-filter: blur(10px);
}

.form-card-header {
  margin-bottom: 18px;
}

.form-card-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-white);
  margin-bottom: 4px;
}

.form-card-subtitle {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.home-tuvi-form .form-group { margin-bottom: 16px; }

.required {
  color: #ef4444;
  margin-left: 2px;
}

.form-row-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.form-row-3col {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
}

.radio-pill-group {
  display: flex;
  gap: 8px;
}

.radio-pill {
  flex: 1;
  cursor: pointer;
}

.radio-pill input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.radio-pill span {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 8px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  font-size: 13px;
  color: var(--text-secondary);
  text-align: center;
  white-space: nowrap;
  transition: all 0.2s;
}

.radio-pill input:checked + span {
  background: rgba(124, 58, 237, 0.18);
  border-color: var(--accent-primary);
  color: var(--text-white);
  font-weight: 600;
}

.btn-submit-hero {
  width: 100%;
  margin-top: 4px;
  font-size: 15px;
  padding: 15px 20px;
}

.form-security-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 12px;
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
}

.trust-stats-bar {
  padding: 28px 0;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  background: rgba(17, 24, 39, 0.5);
}

.stats-counter-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px 12px;
}

.counter-item {
  text-align: center;
}

.counter-number {
  font-size: clamp(20px, 5vw, 30px);
  font-weight: 800;
  background: var(--gradient-gold);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.counter-label {
  font-size: 11.5px;
  color: var(--text-secondary);
  margin-top: 4px;
  line-height: 1.4;
}

.sample-preview-section,
.pricing-matrix-section,
.reviews-section,
.faq-section {
  padding: 48px 0;
}

.section-header-center {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 28px;
}

.section-kicker {
  display: inline-block;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--accent-secondary);
  background: rgba(124, 58, 237, 0.12);
  border: 1px solid rgba(124, 58, 237, 0.3);
  padding: 5px 14px;
  border-radius: 100px;
  margin-bottom: 12px;
}

.section-main-heading {
  font-family: 'Plus Jakarta Sans', var(--font-family);
  font-size: clamp(22px, 5.5vw, 34px);
  font-weight: 800;
  line-height: 1.25;
  color: var(--text-white);
  margin-bottom: 10px;
}

.section-main-sub {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
}

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

.sample-card {
  background: var(--gradient-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 20px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: all 0.25s ease;
}

.sample-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
}

.sample-card-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--accent-secondary);
  background: rgba(124, 58, 237, 0.12);
  border: 1px solid rgba(124, 58, 237, 0.3);
  padding: 4px 10px;
  border-radius: 6px;
  width: fit-content;
}

.sample-card-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-white);
  line-height: 1.4;
}

.sample-card-snippet {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.7;
}

.sample-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: auto;
  flex-wrap: wrap;
}

.tag-free-mini {
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid rgba(34, 197, 94, 0.4);
  color: #22c55e;
  font-size: 10px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 100px;
}

.tag-pro-mini {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #fbbf24;
  font-size: 10px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 100px;
}

.pricing-comparison-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: 14px;
  border: 1px solid var(--border-color);
  background: var(--bg-card);
}

.pricing-table {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
  font-size: 13px;
}

.pricing-table th,
.pricing-table td {
  padding: 12px 12px;
  text-align: left;
  vertical-align: middle;
  border-bottom: 1px solid var(--border-color);
}

.pricing-table thead th {
  text-align: center;
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

.pricing-table .col-feature {
  width: 34%;
  text-align: left;
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 12px;
}

.pricing-table .col-free,
.pricing-table .col-single,
.pricing-table .col-vip {
  width: 22%;
}

.pricing-table .col-vip {
  background: rgba(245, 158, 11, 0.06);
}

.th-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-white);
  margin-bottom: 4px;
}

.th-price {
  font-size: 16px;
  font-weight: 800;
  color: var(--accent-gold-light);
  margin-bottom: 8px;
}

.th-price small {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
}

.old-price {
  font-size: 12px;
  color: var(--text-muted);
  text-decoration: line-through;
  font-weight: 500;
  margin-left: 4px;
}

.vip-badge-ribbon {
  display: inline-block;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #1a1a2e;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.5px;
  padding: 3px 10px;
  border-radius: 100px;
  margin-bottom: 6px;
}

.pricing-table td {
  color: var(--text-secondary);
}

.check-yes {
  color: #22c55e;
  font-weight: 700;
  text-align: center;
}

.check-no {
  color: var(--text-muted);
  text-align: center;
}

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

.review-card {
  background: var(--gradient-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 20px 18px;
}

.review-top {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.review-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(124, 58, 237, 0.15);
  border: 1px solid rgba(124, 58, 237, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}

.review-user-info { min-width: 0; }

.review-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-white);
}

.review-role {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

.review-stars {
  color: #fbbf24;
  font-size: 14px;
  letter-spacing: 1px;
  margin-bottom: 10px;
}

.review-comment {
  font-size: 13.5px;
  color: var(--text-secondary);
  line-height: 1.75;
}

.review-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 700;
  color: #4ade80;
  background: rgba(74, 222, 128, 0.1);
  border: 1px solid rgba(74, 222, 128, 0.25);
  border-radius: 100px;
  padding: 2px 8px;
  margin-top: 6px;
}

.review-meta {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 10px;
}

/* Reveal-on-scroll cho review cards */
.review-card {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.review-card.rv-in {
  opacity: 1;
  transform: translateY(0);
}

.review-card.rv-in:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
  border-color: rgba(245, 158, 11, 0.35);
}

/* ==================== HERO THU HÚT ==================== */
/* Badge khuyến mãi + đếm ngược thật (dữ liệu từ /api/stats/today) */
.hero-promo-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.18), rgba(239, 68, 68, 0.18));
  border: 1px solid rgba(245, 158, 11, 0.45);
  color: #fcd34d;
  font-size: 13px;
  font-weight: 700;
  padding: 7px 14px;
  border-radius: 100px;
  margin-bottom: 14px;
  animation: hpbPulse 2.2s ease-in-out infinite;
}

.hpb-flash {
  font-size: 14px;
}

.hpb-countdown {
  font-variant-numeric: tabular-nums;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 100px;
  padding: 2px 10px;
  color: #fff;
  font-size: 12px;
}

@keyframes hpbPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.35); }
  50% { box-shadow: 0 0 18px 2px rgba(245, 158, 11, 0.25); }
}

/* Nút CTA hero glow pulse */
.btn-submit-hero {
  animation: ctaPulse 2.4s ease-in-out infinite;
}

@keyframes ctaPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.45); }
  50% { box-shadow: 0 0 22px 4px rgba(245, 158, 11, 0.35); }
}

/* Avatar social strip chuyển động nhẹ */
.mini-avatar {
  animation: miniBob 3s ease-in-out infinite;
  display: inline-flex;
}

.mini-avatar:nth-child(2) { animation-delay: 0.4s; }
.mini-avatar:nth-child(3) { animation-delay: 0.8s; }
.mini-avatar:nth-child(4) { animation-delay: 1.2s; }

@keyframes miniBob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

/* Cột VIP bảng giá nổi bật */
.pricing-table .col-vip {
  background: linear-gradient(180deg, rgba(245, 158, 11, 0.14), rgba(245, 158, 11, 0.05));
  border-left: 2px solid rgba(245, 158, 11, 0.6);
  border-right: 2px solid rgba(245, 158, 11, 0.6);
}

.vip-discount-badge {
  display: inline-block;
  background: linear-gradient(90deg, #f59e0b, #ef4444);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  border-radius: 100px;
  padding: 3px 10px;
  margin-left: 6px;
  vertical-align: middle;
}

/* Reviews: PC giữ 3 cột (không carousel); mobile = carousel native scroll-snap */
@media (max-width: 767.98px) {
  .reviews-grid {
    display: flex;
    grid-template-columns: none;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .reviews-grid::-webkit-scrollbar {
    display: none;
  }

  .reviews-grid .review-card {
    flex: 0 0 88%;
    scroll-snap-align: start;
    min-width: 0;
  }
}

.reviews-dots {
  justify-content: center;
  gap: 8px;
  margin-top: 16px;
}

.reviews-dots .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: all 0.3s;
}

.reviews-dots .dot.active {
  background: #f59e0b;
  width: 22px;
  border-radius: 100px;
}

@media (prefers-reduced-motion: reduce) {
  .btn-submit-hero,
  .hero-promo-badge,
  .mini-avatar {
    animation: none;
  }
}

.faq-accordion-wrap {
  display: grid;
  gap: 12px;
}

.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-white);
  cursor: pointer;
  line-height: 1.5;
}

.faq-arrow {
  flex-shrink: 0;
  font-size: 11px;
  color: var(--accent-secondary);
  transition: transform 0.25s ease;
}

.faq-item.open .faq-arrow {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.faq-item.open .faq-answer {
  max-height: 400px;
}

.faq-answer p {
  font-size: 13.5px;
  color: var(--text-secondary);
  line-height: 1.75;
  padding: 0 16px 16px;
}

.site-footer {
  background: rgba(10, 14, 26, 0.86);
  border-top: 1px solid var(--border-color);
  padding: 40px 0 24px;
  margin-top: auto;
}

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

.footer-col-about {
  min-width: 0;
}

.footer-col {
  min-width: 0;
}

.footer-logo {
  font-size: 19px;
  font-weight: 800;
  color: var(--text-white);
  margin-bottom: 10px;
}

.footer-desc {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 320px;
}

.footer-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-white);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
}

.footer-links {
  list-style: none;
  display: grid;
  gap: 8px;
}

.footer-links a {
  font-size: 13px;
  color: var(--text-secondary);
}

.footer-links a:hover {
  color: var(--accent-secondary);
}

.footer-bottom {
  border-top: 1px solid var(--border-color);
  padding-top: 18px;
  text-align: center;
}

.footer-bottom p {
  font-size: 12px;
  color: var(--text-muted);
}

/* Homepage - tablet/desktop */
@media (min-width: 768px) {
  .hero-grid-2col {
    grid-template-columns: 1.05fr 0.95fr;
    gap: 48px;
  }

  .home-hero-section {
    padding: 140px 0 72px;
  }

  .stats-counter-grid {
    grid-template-columns: repeat(4, 1fr);
  }

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

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

  .footer-grid {
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 40px;
  }

  .hero-form-card {
    padding: 28px 26px;
  }
}

/* --- BỔ SUNG CHO TRANG CHỦ MỚI --- */
.pain-icon { font-size: 2.5rem; margin-bottom: 16px; }

/* Demo Interactive */
.demo-info-badge {
  text-align: center;
  background: rgba(212, 175, 55, 0.1);
  color: var(--accent-gold);
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.9rem;
  margin: 0 auto 24px;
  max-width: 600px;
  border: 1px solid rgba(212, 175, 55, 0.2);
}
.demo-tabs {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.demo-tab {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 10px 20px;
  border-radius: 20px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.3s;
}
.demo-tab:hover { border-color: var(--accent-gold); }
.demo-tab.active {
  background: var(--accent-gold);
  color: #000;
  border-color: var(--accent-gold);
}
.demo-tab-content {
  display: none;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 32px;
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  text-align: left;
}
.demo-tab-content.active { display: block; animation: fadeIn 0.5s ease; }
.demo-reader p { margin-bottom: 16px; line-height: 1.7; color: var(--text-secondary); }
.demo-reader h4 { color: var(--accent-gold); margin: 24px 0 12px; font-size: 1.1rem; }
.demo-reader b { color: var(--text-primary); }
.demo-blur-fade {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 120px;
  background: linear-gradient(to bottom, transparent, var(--bg-card) 80%);
  border-bottom-left-radius: 12px;
  border-bottom-right-radius: 12px;
}
.demo-readmore {
  position: absolute;
  bottom: 24px;
  left: 0; right: 0;
  text-align: center;
  color: var(--accent-gold);
  font-weight: 600;
  z-index: 2;
}
.demo-cta {
  text-align: center;
  margin-top: 32px;
}
.demo-cta p { margin-bottom: 12px; color: var(--text-secondary); }

/* Story Section */
.story-blocks {
  display: flex;
  flex-direction: column;
  gap: 24px;
  max-width: 800px;
  margin: 0 auto;
}
.story-block p {
  line-height: 1.8;
  color: var(--text-secondary);
  font-size: 1.05rem;
  background: var(--bg-card);
  padding: 24px;
  border-radius: 12px;
  border: 1px solid var(--border-color);
}
.story-block b { color: var(--accent-gold-light); }

/* Pricing Grid */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  max-width: 1000px;
  margin: 0 auto 24px;
}
.pricing-col {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 32px 24px;
  display: flex;
  flex-direction: column;
  position: relative;
}
.pricing-col.featured {
  border-color: var(--accent-gold);
  background: linear-gradient(180deg, rgba(212,175,55,0.05) 0%, rgba(212,175,55,0) 100%), var(--bg-card);
  transform: translateY(-8px);
}
.pricing-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent-gold);
  color: #000;
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 700;
}
.pricing-header { text-align: center; margin-bottom: 24px; border-bottom: 1px solid var(--border-color); padding-bottom: 24px; }
.pricing-header h3 { font-size: 1.2rem; color: var(--text-primary); margin-bottom: 8px; }
.pricing-price { font-size: 2rem; font-weight: 700; color: var(--accent-gold); }
.pricing-features { list-style: none; padding: 0; margin: 0 0 32px 0; flex-grow: 1; }
.pricing-features li { margin-bottom: 12px; font-size: 0.95rem; display: flex; align-items: flex-start; gap: 8px; }
.pricing-features li::before { content: '✓'; color: var(--success, #28a745); font-weight: bold; }
.pricing-features li.excluded { color: #666; }
.pricing-features li.excluded::before { content: '✕'; color: #666; }
.pricing-cta {
  display: block;
  text-align: center;
  padding: 12px;
  border-radius: 8px;
  border: 1px solid var(--accent-gold);
  color: var(--accent-gold);
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s;
}
.pricing-cta:hover { background: rgba(212,175,55,0.1); }
.pricing-cta-primary { background: var(--accent-gold); color: #000; }
.pricing-cta-primary:hover { background: #bca043; color: #000; }
.pricing-note { text-align: center; color: var(--text-muted); font-size: 0.9rem; }

@media (max-width: 768px) {
  .pricing-grid { grid-template-columns: 1fr; }
  .pricing-col.featured { transform: none; }
  .demo-tab-content { padding: 24px 16px; }
}


/* --- FIX BUG RESPONSIVE & CAROUSEL --- */

@media (max-width: 768px) {
  .mobile-carousel {
    display: flex !important;
    flex-wrap: nowrap;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    gap: 16px;
    padding-bottom: 16px;
    scrollbar-width: thin;
  }
  .mobile-carousel::-webkit-scrollbar { height: 6px; }
  .mobile-carousel::-webkit-scrollbar-track { background: var(--border-color); border-radius: 4px; }
  .mobile-carousel::-webkit-scrollbar-thumb { background: var(--accent-gold); border-radius: 4px; }
  .mobile-carousel > * {
    flex: 0 0 85%;
    scroll-snap-align: center;
    max-width: 85%;
  }
}


/* --- FIX SVG ICONS IN PAIN POINTS --- */
.pain-icon-wrapper {
  width: 52px;
  height: 52px;
  background: rgba(212, 175, 55, 0.1);
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  color: var(--accent-gold);
  box-shadow: 0 4px 15px rgba(212, 175, 55, 0.15);
}
.pain-icon-wrapper svg {
  width: 28px;
  height: 28px;
  stroke-width: 1.5;
}
.sample-card {
  display: flex;
  flex-direction: column;
}



