@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

/* --- Theme Variables --- */
:root {
  --font-title: 'Plus Jakarta Sans', sans-serif;
  --font-body: 'Inter', sans-serif;
  
  /* Dark Theme (Default) */
  --bg-primary: #070913;
  --bg-secondary: #0d1124;
  --bg-card: rgba(17, 24, 48, 0.65);
  --bg-card-hover: rgba(22, 32, 69, 0.8);
  --border-color: rgba(255, 255, 255, 0.08);
  --border-color-hover: rgba(255, 255, 255, 0.16);
  
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  
  --color-primary: #147fd7;
  --color-primary-rgb: 20, 127, 215;
  --color-secondary: #4f46e5;
  --color-accent: #00f2fe;
  
  --glow-color: rgba(20, 127, 215, 0.15);
  --shadow-card: 0 10px 30px -10px rgba(0, 0, 0, 0.7);
  --glass-blur: blur(16px);
}

.light-theme {
  /* Light Theme */
  --bg-primary: #f8fafc;
  --bg-secondary: #f1f5f9;
  --bg-card: rgba(255, 255, 255, 0.8);
  --bg-card-hover: rgba(255, 255, 255, 0.95);
  --border-color: rgba(15, 23, 42, 0.08);
  --border-color-hover: rgba(15, 23, 42, 0.15);
  
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;
  
  --color-primary: #0e5cad;
  --color-primary-rgb: 14, 92, 173;
  --color-secondary: #3b82f6;
  --color-accent: #06b6d4;
  
  --glow-color: rgba(14, 92, 173, 0.06);
  --shadow-card: 0 10px 30px -10px rgba(15, 23, 42, 0.1);
  --glass-blur: blur(16px);
}

/* --- Base & Reset --- */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background-color 0.3s ease, color 0.3s ease;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-title);
  font-weight: 700;
  letter-spacing: -0.02em;
}

a {
  color: inherit;
  text-decoration: none;
  transition: all 0.2s ease;
}

button, input, select {
  font-family: inherit;
}

/* --- Decorative background glows --- */
.ambient-glows {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 1440px;
  height: 100%;
  pointer-events: none;
  z-index: -1;
  overflow: hidden;
}

.glow-1 {
  position: absolute;
  top: -10%;
  left: 20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(20, 127, 215, 0.12) 0%, transparent 70%);
  filter: blur(80px);
}

.glow-2 {
  position: absolute;
  top: 40%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(79, 70, 229, 0.1) 0%, transparent 70%);
  filter: blur(80px);
}

.glow-3 {
  position: absolute;
  bottom: 10%;
  left: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(0, 242, 254, 0.08) 0%, transparent 70%);
  filter: blur(80px);
}

/* --- Layout Container --- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* --- Sticky Navbar --- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-card);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  transition: background 0.3s ease, border-color 0.3s ease;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.logo-wrapper {
  display: flex;
  align-items: center;
  width: 140px;
  height: 38px;
  flex-shrink: 0;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-link {
  font-family: var(--font-title);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
}

.nav-link:hover, .nav-link.active {
  color: var(--text-primary);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  border-radius: 99px;
  font-family: var(--font-title);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  border: 1px solid transparent;
}

.btn-primary {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  color: #ffffff;
  box-shadow: 0 4px 20px rgba(20, 127, 215, 0.25);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(20, 127, 215, 0.4);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text-primary);
  border-color: var(--border-color);
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-color-hover);
  transform: translateY(-2px);
}

/* --- Theme Toggle Switch --- */
.theme-toggle {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 20px;
  cursor: pointer;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s, color 0.2s;
  border: 1px solid var(--border-color);
}

.theme-toggle:hover {
  background: var(--bg-card);
  color: var(--text-primary);
}

.sun-icon {
  display: none;
}

.light-theme .sun-icon {
  display: block;
}

.light-theme .moon-icon {
  display: none;
}

/* Hamburger Menu */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 24px;
  height: 18px;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 101;
}

.hamburger span {
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--text-primary);
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* --- Hero Section --- */
.hero {
  padding-top: 160px;
  padding-bottom: 80px;
  position: relative;
  text-align: center;
  overflow: hidden;
}

/* Animated Particle Canvas Background */
.hero-particles {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* Fade-out mask at bottom of particle area */
.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 180px;
  background: linear-gradient(to top, var(--bg-primary) 0%, transparent 100%);
  z-index: 1;
  pointer-events: none;
}

/* Ensure all hero content sits above canvas */
.hero > .container {
  position: relative;
  z-index: 2;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: rgba(20, 127, 215, 0.1);
  border: 1px solid rgba(20, 127, 215, 0.2);
  border-radius: 99px;
  color: var(--color-primary);
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 24px;
  animation: pulse-tag 2s infinite;
}

.hero-title {
  font-size: 56px;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 24px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.hero-title span {
  background: linear-gradient(135deg, var(--text-primary) 30%, var(--color-primary) 70%, var(--color-accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc {
  font-size: 18px;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 40px auto;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-bottom: 60px;
}

/* --- Interactive Console & Dashboard (Hero Highlight) --- */
.hero-showcase {
  max-width: 1000px;
  margin: 0 auto;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 8px;
  box-shadow: var(--shadow-card);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  position: relative;
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.hero-showcase::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(20, 127, 215, 0.2) 0%, transparent 60%);
  z-index: -1;
  pointer-events: none;
}

.window-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 16px;
  border-bottom: 1px solid var(--border-color);
}

.window-dots {
  display: flex;
  gap: 6px;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.dot-red { background-color: #ef4444; }
.dot-yellow { background-color: #f59e0b; }
.dot-green { background-color: #10b981; }

.window-title {
  font-family: var(--font-title);
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
}

/* Live Demo Flex Layout */
.demo-grid {
  display: grid;
  grid-template-columns: 350px 1fr;
  min-height: 480px;
  border-radius: 0 0 12px 12px;
  overflow: hidden;
}

/* AI Chat Console Panel */
.console-panel {
  background: rgba(8, 11, 23, 0.85);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 16px;
  text-align: left;
}

.console-chat-history {
  flex-grow: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 16px;
  padding-right: 4px;
}

/* Custom scrollbar for chat */
.console-chat-history::-webkit-scrollbar {
  width: 4px;
}
.console-chat-history::-webkit-scrollbar-thumb {
  background-color: var(--border-color);
  border-radius: 2px;
}

.chat-bubble {
  max-width: 90%;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 13px;
  line-height: 1.4;
  animation: slide-up 0.3s ease forwards;
}

.chat-user {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  align-self: flex-end;
  border-bottom-right-radius: 2px;
}

.chat-ai {
  background: rgba(20, 127, 215, 0.1);
  border: 1px solid rgba(20, 127, 215, 0.2);
  align-self: flex-start;
  border-bottom-left-radius: 2px;
}

.chat-bubble .ai-label {
  font-weight: 700;
  color: var(--color-primary);
  font-size: 11px;
  text-transform: uppercase;
  margin-bottom: 4px;
  display: block;
}

.prompt-suggestions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}

.suggestion-btn {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 12px;
  text-align: left;
  cursor: pointer;
  transition: all 0.2s ease;
}

.suggestion-btn:hover {
  background: var(--bg-card-hover);
  border-color: var(--color-primary);
  color: var(--text-primary);
}

.console-input-area {
  position: relative;
}

.console-input {
  width: 100%;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 10px 38px 10px 12px;
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
  transition: border-color 0.2s;
}

.console-input:focus {
  border-color: var(--color-primary);
}

.console-send {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--color-primary);
  cursor: pointer;
  font-size: 16px;
  display: flex;
  align-items: center;
}

/* Dashboard Mockup Panel */
.dashboard-panel {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  text-align: left;
  background: rgba(13, 17, 36, 0.4);
}

.dash-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.dash-title {
  font-size: 18px;
  font-weight: 700;
}

.dash-status {
  font-size: 12px;
  color: #10b981;
  background: rgba(16, 185, 129, 0.1);
  padding: 4px 8px;
  border-radius: 99px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.dash-status::before {
  content: '';
  width: 6px;
  height: 6px;
  background: #10b981;
  border-radius: 50%;
  display: block;
}

.dash-widgets {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.widget {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 14px;
}

.widget-title {
  font-size: 11px;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 6px;
}

.widget-value {
  font-size: 20px;
  font-weight: 700;
  font-family: var(--font-title);
}

.widget-change {
  font-size: 11px;
  font-weight: 500;
  margin-top: 4px;
  display: flex;
  align-items: center;
}

.change-up { color: #10b981; }
.change-down { color: #ef4444; }

.dash-chart-container {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 16px;
  flex-grow: 1;
  position: relative;
  min-height: 200px;
}

.dash-table-wrapper {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
}

.dash-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.dash-table th {
  text-align: left;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.02);
  color: var(--text-muted);
  font-weight: 600;
  border-bottom: 1px solid var(--border-color);
}

.dash-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border-color);
}

.dash-table tr:last-child td {
  border-bottom: none;
}

.status-badge {
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 600;
}

.status-paid {
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
}

.status-pending {
  background: rgba(245, 158, 11, 0.1);
  color: #f59e0b;
}

/* --- SVG Wave Section Dividers --- */
.wave-divider {
  position: relative;
  width: 100%;
  overflow: hidden;
  line-height: 0;
  z-index: 1;
}

.wave-divider svg {
  display: block;
  width: 100%;
  height: auto;
}

/* Top wave: Pricing → Testimonials (fills downward with bg-secondary) */
.wave-divider--top {
  margin-bottom: -2px;
}

.wave-divider--top svg {
  height: 60px;
}

/* Bottom wave: Testimonials → FAQ (fills upward with bg-secondary) */
.wave-divider--bottom {
  margin-top: -2px;
}

.wave-divider--bottom svg {
  height: 60px;
}

/* Gradient wave: FAQ → CTA (decorative brand-colored wave) */
.wave-divider--cta {
  margin-bottom: -2px;
}

.wave-divider--cta svg {
  height: 45px;
}

/* --- Section Formatting --- */
.section {
  padding: 100px 0;
}

.section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 60px auto;
}

.section-tag {
  color: var(--color-primary);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 12px;
  display: block;
}

.section-title {
  font-size: 38px;
  font-weight: 800;
  margin-bottom: 16px;
  line-height: 1.2;
}

.section-desc {
  color: var(--text-secondary);
  font-size: 16px;
}

/* --- Feature Walkthrough Interactive Component --- */
.feature-tabs {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 40px;
}

.tab-btn {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 10px 20px;
  border-radius: 99px;
  cursor: pointer;
  font-family: var(--font-title);
  font-size: 14px;
  font-weight: 600;
  transition: all 0.3s;
}

.tab-btn:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
}

.tab-btn.active {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: #ffffff;
  box-shadow: 0 4px 15px rgba(20, 127, 215, 0.2);
}

.tab-content {
  display: none;
  animation: fade-in 0.4s ease;
}

.tab-content.active {
  display: block;
}

.feature-interactive-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.feature-info h3 {
  font-size: 28px;
  margin-bottom: 16px;
}

.feature-info p {
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.feature-bullets {
  list-style: none;
}

.feature-bullets li {
  position: relative;
  padding-left: 28px;
  margin-bottom: 16px;
  font-size: 15px;
  color: var(--text-secondary);
}

.feature-bullets li::before {
  content: '✓';
  position: absolute;
  left: 0;
  top: 0;
  color: var(--color-accent);
  font-weight: 700;
  font-size: 16px;
}

.feature-visual {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 24px;
  box-shadow: var(--shadow-card);
}

/* OCR Scanner visual demo */
.ocr-demo {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.ocr-dropzone {
  border: 2px dashed rgba(20, 127, 215, 0.3);
  border-radius: 12px;
  padding: 30px;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s;
  background: rgba(20, 127, 215, 0.02);
}

.ocr-dropzone:hover {
  border-color: var(--color-primary);
  background: rgba(20, 127, 215, 0.05);
}

.ocr-icon {
  font-size: 32px;
  margin-bottom: 12px;
  color: var(--color-primary);
}

.ocr-results {
  display: none;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 16px;
  animation: slide-down 0.4s ease;
}

.ocr-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 13px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 6px;
}

.ocr-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 0;
}

.ocr-label {
  color: var(--text-muted);
  font-weight: 600;
}

.ocr-val {
  font-family: monospace;
  font-weight: 600;
}

/* --- Bento Features Grid --- */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.bento-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 32px;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.bento-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 0% 0%, rgba(20, 127, 215, 0.08) 0%, transparent 50%);
  pointer-events: none;
}

.bento-card:hover {
  transform: translateY(-5px);
  border-color: var(--border-color-hover);
  box-shadow: var(--shadow-card);
}

.bento-icon {
  width: 48px;
  height: 48px;
  background: rgba(20, 127, 215, 0.1);
  border: 1px solid rgba(20, 127, 215, 0.2);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary);
  font-size: 20px;
  margin-bottom: 24px;
}

.bento-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 12px;
}

.bento-desc {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.5;
}

.span-2 {
  grid-column: span 2;
}

/* --- Animated Stats Counter Section --- */
.stats-section {
  padding: 80px 0;
  position: relative;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  overflow: hidden;
}

/* Subtle ambient glow behind stats */
.stats-section::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 300px;
  background: radial-gradient(ellipse, rgba(var(--color-primary-rgb), 0.06) 0%, transparent 70%);
  pointer-events: none;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}

.stat-item {
  text-align: center;
  padding: 32px 16px;
  border-radius: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  position: relative;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  /* Start hidden for scroll animation */
  opacity: 0;
  transform: translateY(30px);
}

.stat-item.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger animation delay for each item */
.stat-item:nth-child(1) { transition-delay: 0s; }
.stat-item:nth-child(2) { transition-delay: 0.1s; }
.stat-item:nth-child(3) { transition-delay: 0.2s; }
.stat-item:nth-child(4) { transition-delay: 0.3s; }

/* Gradient accent line at top of card */
.stat-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--color-primary), var(--color-accent), var(--color-secondary));
  opacity: 0.6;
  transition: opacity 0.3s;
}

.stat-item:hover {
  transform: translateY(-4px);
  border-color: var(--border-color-hover);
  box-shadow: 0 12px 40px -12px rgba(var(--color-primary-rgb), 0.2);
}

.stat-item:hover::before {
  opacity: 1;
}

.stat-value {
  font-family: var(--font-title);
  font-size: 48px;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 12px;
  background: linear-gradient(135deg, var(--text-primary) 30%, var(--color-primary) 70%, var(--color-accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat-label {
  font-family: var(--font-title);
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.stat-detail {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.4;
}

/* --- Pricing Section --- */
.pricing-toggle-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 48px;
}

.pricing-label {
  font-family: var(--font-title);
  font-weight: 600;
  font-size: 14px;
  color: var(--text-secondary);
}

.pricing-label.active {
  color: var(--text-primary);
}

.toggle-switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 26px;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  transition: .4s;
  border-radius: 34px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: var(--color-primary);
  transition: .4s;
  border-radius: 50%;
}

input:checked + .slider {
  background-color: var(--bg-card-hover);
}

input:checked + .slider:before {
  transform: translateX(24px);
  background-color: var(--color-accent);
}

.discount-badge {
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
  padding: 2px 8px;
  border-radius: 99px;
  font-size: 11px;
  font-weight: 700;
  margin-left: 8px;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: stretch;
}

.price-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 40px 32px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: all 0.3s;
}

.price-card.popular {
  border-color: var(--color-primary);
  background: linear-gradient(180deg, rgba(20, 127, 215, 0.05) 0%, rgba(13, 17, 36, 0.4) 100%);
  transform: translateY(-8px);
}

.price-card.popular::before {
  content: 'Khuyên Dùng';
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-primary);
  color: #ffffff;
  padding: 4px 14px;
  font-family: var(--font-title);
  font-size: 11px;
  font-weight: 700;
  border-radius: 99px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  box-shadow: 0 4px 10px rgba(20, 127, 215, 0.3);
}

.price-card:hover {
  border-color: var(--border-color-hover);
  box-shadow: var(--shadow-card);
}

.price-card.popular:hover {
  border-color: var(--color-primary);
  box-shadow: 0 20px 40px -10px rgba(20, 127, 215, 0.15);
}

.price-header {
  margin-bottom: 24px;
}

.price-name {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
}

.price-desc {
  color: var(--text-secondary);
  font-size: 13px;
  min-height: 40px;
}

.price-value-wrapper {
  margin-bottom: 32px;
  display: flex;
  align-items: baseline;
}

.price-currency {
  font-size: 24px;
  font-weight: 700;
  margin-right: 4px;
}

.price-value {
  font-size: 48px;
  font-weight: 800;
  font-family: var(--font-title);
  line-height: 1;
}

.price-period {
  color: var(--text-muted);
  font-size: 14px;
  margin-left: 4px;
}

.price-features {
  list-style: none;
  margin-bottom: 40px;
  flex-grow: 1;
}

.price-features li {
  position: relative;
  padding-left: 24px;
  margin-bottom: 14px;
  font-size: 14px;
  color: var(--text-secondary);
}

.price-features li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--color-primary);
  font-weight: 700;
}

.price-card.popular .price-features li::before {
  color: var(--color-accent);
}

.price-btn {
  width: 100%;
}

/* --- Testimonials --- */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.testimonial-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 32px;
}

.stars {
  color: #f59e0b;
  margin-bottom: 16px;
  font-size: 14px;
}

.testimonial-text {
  color: var(--text-secondary);
  font-size: 14px;
  font-style: italic;
  margin-bottom: 24px;
}

.user-profile {
  display: flex;
  align-items: center;
  gap: 12px;
}

.user-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-secondary);
  overflow: hidden;
  border: 1px solid var(--border-color);
}

.user-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.user-name {
  font-size: 14px;
  font-weight: 700;
}

.user-title {
  color: var(--text-muted);
  font-size: 12px;
}

/* --- CTA Section --- */
.cta-section {
  padding: 100px 0;
  position: relative;
}

.cta-box {
  background: linear-gradient(135deg, rgba(13, 17, 36, 0.8) 0%, rgba(8, 11, 23, 0.9) 100%);
  border: 1px solid var(--border-color);
  border-radius: 24px;
  padding: 80px 24px;
  text-align: center;
  position: relative;
  overflow: hidden;
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
}

.cta-box::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(20, 127, 215, 0.08) 0%, transparent 60%);
  pointer-events: none;
}

.cta-title {
  font-size: 40px;
  font-weight: 800;
  margin-bottom: 16px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.cta-desc {
  color: var(--text-secondary);
  font-size: 16px;
  max-width: 500px;
  margin: 0 auto 32px auto;
}

/* --- Footer --- */
.footer {
  border-top: 1px solid var(--border-color);
  background: var(--bg-primary);
  padding: 80px 0 30px 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 48px;
  margin-bottom: 60px;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.footer-logo {
  width: 140px;
  height: 38px;
}

.footer-about {
  color: var(--text-secondary);
  font-size: 14px;
  max-width: 280px;
}

.footer-company-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
  font-size: 13px;
  color: var(--text-secondary);
}

.footer-company-info .company-name {
  font-family: var(--font-title);
  font-weight: 700;
  color: var(--text-primary);
  font-size: 14px;
}

.footer-company-info .company-address {
  line-height: 1.5;
}

.footer-links-col {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.footer-links-title {
  font-family: var(--font-title);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-links a {
  color: var(--text-secondary);
  font-size: 14px;
}

.footer-links a:hover {
  color: var(--text-primary);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 30px;
  border-top: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 13px;
}

.footer-socials {
  display: flex;
  gap: 12px;
  align-items: center;
}

.social-link {
  color: var(--text-secondary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border-color);
  transition: all 0.2s ease;
}

.social-link:hover {
  color: var(--color-primary);
  border-color: var(--color-primary);
  background: rgba(20, 127, 215, 0.05);
  transform: translateY(-2px);
}

/* --- Animations --- */
@keyframes pulse-tag {
  0% {
    box-shadow: 0 0 0 0 rgba(20, 127, 215, 0.4);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(20, 127, 215, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(20, 127, 215, 0);
  }
}

@keyframes slide-up {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* --- Responsive Media Queries --- */
@media (max-width: 1024px) {
  .hero-title {
    font-size: 44px;
  }
  .demo-grid {
    grid-template-columns: 1fr;
  }
  .console-panel {
    border-right: none;
    border-bottom: 1px solid var(--border-color);
    min-height: 350px;
  }
  .bento-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .span-2 {
    grid-column: span 2;
  }
  .pricing-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .price-card.popular {
    grid-column: span 2;
    transform: none;
  }
  .price-card.popular::before {
    top: -12px;
  }
  .testimonials-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }
}

@media (max-width: 768px) {
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
  .stat-value {
    font-size: 36px;
  }
  .stat-item {
    padding: 24px 12px;
  }
  .nav-menu {
    display: none;
    position: fixed;
    top: 72px;
    left: 0;
    width: 100%;
    height: calc(100vh - 72px);
    background: var(--bg-primary);
    flex-direction: column;
    padding: 40px;
    gap: 24px;
    border-top: 1px solid var(--border-color);
    align-items: flex-start;
  }
  .nav-menu.mobile-open {
    display: flex;
  }
  .hamburger {
    display: flex;
  }
  .nav-actions {
    margin-right: 16px;
  }
  
  .hero-title {
    font-size: 34px;
  }
  .hero-desc {
    font-size: 15px;
  }
  .feature-interactive-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .bento-grid {
    grid-template-columns: 1fr;
  }
  .span-2 {
    grid-column: span 1;
  }
  .pricing-grid {
    grid-template-columns: 1fr;
  }
  .price-card.popular {
    grid-column: span 1;
  }
  .testimonials-grid {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .dash-widgets {
    grid-template-columns: 1fr;
  }
}

/* --- Brand Logo Image Styles --- */
.brand-logo {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
}

/* --- Interactive Grid Mesh Background & Mouse Glow --- */
.grid-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: 50px 50px;
  background-image: 
    linear-gradient(to right, rgba(255, 255, 255, 0.015) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.015) 1px, transparent 1px);
  pointer-events: none;
  z-index: -2;
}

.light-theme .grid-overlay {
  background-image: 
    linear-gradient(to right, rgba(15, 23, 42, 0.025) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(15, 23, 42, 0.025) 1px, transparent 1px);
}

.cursor-glow-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 99;
  background: radial-gradient(circle 350px at var(--mouse-x, 0px) var(--mouse-y, 0px), rgba(20, 127, 215, 0.06), transparent 80%);
  transition: background 0.08s ease;
}

/* Animated border glow on bento cards and showcase */
.bento-card, .hero-showcase {
  position: relative;
  overflow: hidden;
}

.bento-card::before, .hero-showcase::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle 220px at var(--card-mouse-x, 0px) var(--card-mouse-y, 0px), rgba(0, 242, 254, 0.08), transparent 80%);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 1;
}

.bento-card:hover::before, .hero-showcase:hover::before {
  opacity: 1;
}

.bento-card:hover {
  transform: translateY(-5px);
  border-color: rgba(20, 127, 215, 0.4) !important;
  box-shadow: 0 15px 35px -10px rgba(20, 127, 215, 0.2);
}

/* --- Toast Container & Individual Toast Alert --- */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 380px;
  width: 100%;
  pointer-events: none;
}

.toast {
  background: rgba(10, 14, 28, 0.95);
  border: 1px solid rgba(20, 127, 215, 0.3);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255,255,255,0.05);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-radius: 12px;
  padding: 16px;
  color: var(--text-primary);
  display: flex;
  align-items: flex-start;
  gap: 12px;
  pointer-events: auto;
  transform: translateX(125%);
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.light-theme .toast {
  background: rgba(255, 255, 255, 0.95);
  border-color: rgba(20, 127, 215, 0.2);
  box-shadow: 0 8px 30px rgba(15, 23, 42, 0.08);
}

.toast.show {
  transform: translateX(0);
  opacity: 1;
}

.toast-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 20px;
  height: 20px;
}

.toast-icon svg.spin {
  animation: spin 2s linear infinite;
}

.toast-content {
  flex-grow: 1;
  text-align: left;
}

.toast-title {
  font-family: var(--font-title);
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 2px;
}

.toast-desc {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.4;
}

.toast-close {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 14px;
  padding: 0 2px;
  align-self: flex-start;
}

/* --- Fin AI chat features & badges --- */
.badge-tk {
  display: inline-block;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  font-family: monospace;
  margin: 0 3px;
}

.badge-tk-debit {
  background: rgba(20, 127, 215, 0.15);
  color: var(--color-accent);
  border: 1px solid rgba(20, 127, 215, 0.25);
}

.badge-tk-credit {
  background: rgba(79, 70, 229, 0.15);
  color: #a5b4fc;
  border: 1px solid rgba(79, 70, 229, 0.25);
}

.btn-approve-ledger {
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.25);
  color: #10b981;
  font-family: var(--font-title);
  font-size: 11px;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  margin-top: 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.btn-approve-ledger:hover:not(:disabled) {
  background: rgba(16, 185, 129, 0.2);
  border-color: #10b981;
  color: #ffffff;
  transform: translateY(-1px);
}

.btn-approve-ledger:disabled {
  background: var(--bg-card);
  border-color: var(--border-color);
  color: var(--text-muted);
  cursor: not-allowed;
}

.typing-cursor::after {
  content: '|';
  animation: blink 1s infinite step-end;
  font-weight: bold;
  color: var(--color-primary);
}

@keyframes blink {
  50% { opacity: 0; }
}

/* --- OCR Visual Invoice Demo styles --- */
.ocr-visual-container {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 32px;
  align-items: start;
  text-align: left;
}

.mock-invoice {
  background: #ffffff;
  color: #0f172a;
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.3);
  position: relative;
  overflow: hidden;
  font-size: 13px;
  border: 1px solid rgba(255,255,255,0.05);
}

.invoice-header {
  display: flex;
  justify-content: space-between;
  border-bottom: 2px solid #f1f5f9;
  padding-bottom: 12px;
  margin-bottom: 16px;
}

.inv-logo {
  font-weight: 800;
  font-size: 16px;
  color: #147fd7;
}

.inv-number {
  color: #64748b;
  font-family: monospace;
}

.inv-meta-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}

.inv-meta-label {
  color: #64748b;
}

.inv-meta-val {
  font-weight: 600;
}

.inv-items-table {
  margin-top: 16px;
  border-top: 1px solid #f1f5f9;
  border-bottom: 1px solid #f1f5f9;
  padding: 12px 0;
}

.inv-item-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
}

.inv-total-row {
  display: flex;
  justify-content: space-between;
  font-weight: 700;
  font-size: 15px;
  margin-top: 12px;
  padding-top: 6px;
  border-top: 2px dashed #f1f5f9;
}

.ocr-target {
  position: relative;
  padding: 2px 4px;
  border-radius: 4px;
  transition: all 0.3s;
}

.ocr-target.highlight-ocr {
  background: rgba(16, 185, 129, 0.15);
  box-shadow: 0 0 0 2px #10b981;
  color: #059669;
}

.ocr-laser {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, transparent, #10b981, transparent);
  box-shadow: 0 0 10px #10b981;
  z-index: 10;
  display: none;
}

.ocr-scanning .ocr-laser {
  display: block;
  animation: laser-sweep 2s ease-in-out infinite;
}

@keyframes laser-sweep {
  0% { top: 0%; }
  50% { top: 100%; }
  100% { top: 0%; }
}

.ocr-actions-panel {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

@media (max-width: 768px) {
  .ocr-visual-container {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

/* --- Scroll Progress Bar --- */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--color-primary), var(--color-accent));
  z-index: 10000;
  transition: width 0.1s ease;
}

/* --- Floating Back to Top Button --- */
.back-to-top {
  position: fixed;
  bottom: 24px;
  left: 24px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  box-shadow: var(--shadow-card);
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--bg-card-hover);
  border-color: var(--color-primary);
  color: var(--color-primary);
  transform: scale(1.1);
}

/* --- FAQ Accordion --- */
.faq-grid {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
  transition: border-color 0.3s;
}

.faq-item:hover {
  border-color: var(--border-color-hover);
}

.faq-trigger {
  width: 100%;
  background: none;
  border: none;
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  color: var(--text-primary);
  font-family: var(--font-title);
  font-size: 16px;
  font-weight: 700;
  text-align: left;
}

.faq-arrow {
  font-size: 12px;
  color: var(--text-muted);
  transition: transform 0.3s ease;
}

.faq-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-in-out;
}

.faq-inner {
  padding: 0 24px 20px 24px;
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.6;
}

.faq-item.active {
  border-color: var(--color-primary);
}

.faq-item.active .faq-arrow {
  transform: rotate(180deg);
  color: var(--color-primary);
}

/* --- Signup Modal Popup --- */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(4, 6, 14, 0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.modal-overlay.show {
  opacity: 1;
  visibility: visible;
}

.modal-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-card);
  border-radius: 20px;
  max-width: 480px;
  width: 100%;
  margin: 24px;
  overflow: hidden;
  position: relative;
  transform: scale(0.9) translateY(20px);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  padding: 40px;
  text-align: center;
}

.modal-overlay.show .modal-card {
  transform: scale(1) translateY(0);
}

.modal-close-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 20px;
  cursor: pointer;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-color);
  transition: all 0.2s;
}

.modal-close-btn:hover {
  background: var(--bg-primary);
  color: var(--text-primary);
}

.modal-title {
  font-size: 24px;
  font-weight: 800;
  margin-bottom: 8px;
}

.modal-desc {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 28px;
}

.form-group {
  margin-bottom: 20px;
  text-align: left;
}

.form-label {
  display: block;
  font-family: var(--font-title);
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 8px;
  letter-spacing: 0.05em;
}

.form-input {
  width: 100%;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 12px 16px;
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
  transition: all 0.2s;
}

.form-input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 15px rgba(20, 127, 215, 0.15);
}

.form-error {
  font-size: 11px;
  color: #ef4444;
  margin-top: 6px;
  display: none;
}

.form-submit-btn {
  width: 100%;
  padding: 12px 24px;
  margin-top: 10px;
  font-size: 15px;
  justify-content: center;
}

.loading-spinner {
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255,255,255,0.3);
  border-radius: 50%;
  border-top-color: #fff;
  animation: spin 1s linear infinite;
  display: none;
}

/* --- Blog Page Styles --- */
.blog-hero {
  padding: 140px 0 50px 0;
  text-align: center;
  position: relative;
  z-index: 1;
  overflow: hidden;
}

.blog-hero::before {
  content: '';
  position: absolute;
  top: 30%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 700px;
  height: 400px;
  background: radial-gradient(ellipse, rgba(20, 127, 215, 0.12) 0%, rgba(79, 70, 229, 0.07) 40%, transparent 70%);
  filter: blur(40px);
  pointer-events: none;
  z-index: -1;
  animation: blogHeroGlow 6s ease-in-out infinite alternate;
}

@keyframes blogHeroGlow {
  0% { transform: translate(-50%, -50%) scale(1); opacity: 0.7; }
  100% { transform: translate(-50%, -50%) scale(1.2); opacity: 1; }
}

.blog-hero .section-tag {
  margin-bottom: 12px;
}

.blog-hero h1 {
  font-size: 46px;
  font-weight: 800;
  margin-bottom: 16px;
  line-height: 1.2;
}

.blog-hero h1 span {
  background: linear-gradient(90deg, var(--color-primary), var(--color-accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.blog-hero-desc {
  color: var(--text-secondary);
  font-size: 16px;
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
}

.blog-section {
  padding: 20px 0 100px 0;
  position: relative;
  z-index: 2;
}

/* Featured Card */
.featured-card {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 40px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 36px;
  margin-bottom: 50px;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  box-shadow: var(--shadow-card);
}

.featured-card:hover {
  transform: translateY(-5px);
  border-color: rgba(20, 127, 215, 0.35);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 25px rgba(20,127,215,0.1);
}

.featured-img {
  border-radius: 12px;
  overflow: hidden;
  height: 340px;
  position: relative;
}

.featured-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}

.featured-card:hover .featured-img img {
  transform: scale(1.03);
}

.featured-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: left;
}

.featured-title {
  font-size: 28px;
  font-weight: 800;
  margin-bottom: 16px;
  line-height: 1.3;
  color: var(--text-primary);
  transition: color 0.2s;
}

.featured-card:hover .featured-title {
  color: var(--color-accent);
}

.featured-excerpt {
  color: var(--text-secondary);
  font-size: 15px;
  margin-bottom: 24px;
  line-height: 1.6;
}

.post-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: var(--text-muted);
}

.post-meta span {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Controls */
.blog-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 40px;
  gap: 24px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 24px;
}

.blog-categories-wrapper {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 6px;
  scrollbar-width: thin;
}

.blog-category-tab {
  background: none;
  border: 1px solid var(--border-color);
  border-radius: 30px;
  padding: 8px 20px;
  color: var(--text-secondary);
  font-family: var(--font-title);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.blog-category-tab:hover {
  border-color: var(--border-color-hover);
  color: var(--text-primary);
}

.blog-category-tab.active {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: #ffffff;
}

.blog-search-box {
  position: relative;
  width: 320px;
  flex-shrink: 0;
}

.blog-search-input {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 30px;
  padding: 10px 16px 10px 42px;
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
  transition: all 0.2s ease;
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
}

.blog-search-input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 15px rgba(20, 127, 215, 0.15);
}

.blog-search-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Articles Grid */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.post-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 18px;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  height: 100%;
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  text-align: left;
}

.post-card:hover {
  transform: translateY(-5px);
  border-color: rgba(20, 127, 215, 0.35);
  box-shadow: 0 15px 35px -10px rgba(20, 127, 215, 0.25);
}

/* Scroll reveal animation for post cards */
.post-card {
  opacity: 0;
  transform: translateY(24px);
}

.post-card.revealed {
  opacity: 1;
  transform: translateY(0);
}

.post-card.revealed:hover {
  transform: translateY(-5px);
}

.post-card:nth-child(1) { transition-delay: 0s; }
.post-card:nth-child(2) { transition-delay: 0.08s; }
.post-card:nth-child(3) { transition-delay: 0.08s; }
.post-card:nth-child(4) { transition-delay: 0.16s; }
.post-card:nth-child(5) { transition-delay: 0.24s; }
.post-card:nth-child(6) { transition-delay: 0.32s; }

.post-card-img {
  height: 210px;
  overflow: hidden;
  position: relative;
}

.post-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}

.post-card:hover .post-card-img img {
  transform: scale(1.04);
}

.post-card-img::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 50%;
  background: linear-gradient(to top, rgba(7, 9, 19, 0.5) 0%, transparent 100%);
  pointer-events: none;
  z-index: 1;
}

.post-card-content {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.post-card-title {
  font-size: 19px;
  font-weight: 700;
  margin-bottom: 12px;
  line-height: 1.4;
  color: var(--text-primary);
  transition: color 0.2s;
}

.post-card:hover .post-card-title {
  color: var(--color-accent);
}

.post-card-excerpt {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 20px;
  line-height: 1.5;
  flex-grow: 1;
}

.post-card-content::after {
  content: 'Đọc bài viết →';
  display: block;
  font-family: var(--font-title);
  font-size: 13px;
  font-weight: 700;
  color: var(--color-primary);
  margin-top: auto;
  padding-top: 8px;
  opacity: 0;
  transform: translateX(-8px);
  transition: all 0.3s ease;
}

.post-card:hover .post-card-content::after {
  opacity: 1;
  transform: translateX(0);
}

.no-results {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px 0;
  color: var(--text-muted);
  font-size: 16px;
  display: none;
}

/* Responsive Blog */
@media (max-width: 1024px) {
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }
  .featured-card {
    grid-template-columns: 1fr;
    gap: 28px;
    padding: 28px;
  }
  .featured-img {
    height: 280px;
  }
  .blog-hero h1 {
    font-size: 38px;
  }
}

@media (max-width: 768px) {
  .blog-grid {
    grid-template-columns: 1fr;
  }
  .blog-controls {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
  }
  .blog-search-box {
    width: 100%;
  }
  .blog-hero h1 {
    font-size: 32px;
  }
  .featured-title {
    font-size: 22px;
  }
}
/* --- Contact Page Styles --- */
.contact-hero {
  padding: 140px 0 30px 0;
  text-align: center;
  position: relative;
  z-index: 1;
}

.contact-hero h1 {
  font-size: 46px;
  font-weight: 800;
  margin-bottom: 16px;
  line-height: 1.2;
}

.contact-hero h1 span {
  background: linear-gradient(90deg, var(--color-primary), var(--color-accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.contact-hero-desc {
  color: var(--text-secondary);
  font-size: 16px;
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
}

.contact-section {
  padding: 20px 0 100px 0;
  position: relative;
  z-index: 2;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.contact-info-col {
  display: flex;
  flex-direction: column;
  gap: 32px;
  text-align: left;
}

.contact-info-title {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 12px;
  line-height: 1.3;
  color: var(--text-primary);
}

.contact-info-desc {
  color: var(--text-secondary);
  font-size: 16px;
  margin-bottom: 8px;
  line-height: 1.6;
}

.contact-cards-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.contact-info-card {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 24px;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
}

.contact-info-card:hover {
  transform: translateY(-2px);
  border-color: rgba(20, 127, 215, 0.3);
  box-shadow: 0 10px 25px -5px rgba(20, 127, 215, 0.15);
}

.contact-card-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: rgba(20, 127, 215, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-accent);
  flex-shrink: 0;
}

.contact-card-content h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--text-primary);
}

.contact-card-content p {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.5;
}

.contact-card-content a {
  color: var(--color-accent);
  font-weight: 600;
  text-decoration: none;
  transition: color 0.2s;
}

.contact-card-content a:hover {
  color: var(--color-primary);
  text-decoration: underline;
}

/* Contact Form Card */
.contact-form-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 40px;
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  box-shadow: var(--shadow-card);
}

.contact-form-card .form-group {
  margin-bottom: 20px;
  text-align: left;
}

.contact-form-card .form-label {
  display: block;
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 11px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 8px;
  letter-spacing: 0.05em;
}

.contact-form-card .form-input,
.contact-form-card .form-select,
.contact-form-card .form-textarea {
  width: 100%;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 12px 16px;
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
  transition: all 0.2s;
  font-family: var(--font-body);
}

.contact-form-card .form-input:focus,
.contact-form-card .form-select:focus,
.contact-form-card .form-textarea:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 15px rgba(20, 127, 215, 0.15);
}

.contact-form-card .form-textarea {
  min-height: 120px;
  resize: vertical;
}

.contact-form-card .form-select {
  appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'></polyline></svg>");
  background-repeat: no-repeat;
  background-position: right 16px center;
  background-size: 16px;
  padding-right: 40px;
}

.light-theme .contact-form-card .form-select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23475569' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'></polyline></svg>");
}

.contact-form-card .form-error {
  font-size: 11px;
  color: #ef4444;
  margin-top: 6px;
  display: none;
}

/* Responsive Contact */
@media (max-width: 1024px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  
  .contact-form-card {
    padding: 30px;
  }
}

@media (max-width: 768px) {
  .contact-hero h1 {
    font-size: 32px;
  }
  
  .contact-info-title {
    font-size: 24px;
  }
}

/* --- Blog Post Detail Page Styles --- */
.blog-detail-section {
  padding: 140px 0 80px 0;
  position: relative;
  z-index: 1;
}

.blog-detail-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 20px;
}

.blog-detail-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--color-accent);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 28px;
  transition: all 0.3s ease;
}

.blog-detail-back:hover {
  transform: translateX(-4px);
  color: var(--color-primary);
}

.blog-detail-header {
  margin-bottom: 32px;
}

.blog-detail-category {
  display: inline-block;
  padding: 6px 14px;
  background: rgba(0, 242, 254, 0.1);
  border: 1px solid rgba(0, 242, 254, 0.2);
  color: var(--color-accent);
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 16px;
}

.blog-detail-title {
  font-size: 40px;
  font-weight: 800;
  line-height: 1.25;
  color: var(--text-primary);
  margin-bottom: 20px;
  font-family: var(--font-title);
}

.blog-detail-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
  font-size: 14px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 20px;
}

.blog-detail-meta span {
  display: flex;
  align-items: center;
  gap: 6px;
}

.blog-detail-meta svg {
  color: var(--color-accent);
}

.blog-detail-featured-img {
  width: 100%;
  border-radius: 20px;
  overflow: hidden;
  margin-bottom: 40px;
  border: 1px solid var(--border-color);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.blog-detail-featured-img img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.blog-detail-featured-img:hover img {
  transform: scale(1.03);
}

.blog-detail-content {
  font-size: 17px;
  line-height: 1.85;
  color: var(--text-secondary);
}

.blog-detail-content p {
  margin-bottom: 24px;
}

.blog-detail-content h2 {
  font-size: 26px;
  font-weight: 700;
  color: var(--text-primary);
  margin-top: 48px;
  margin-bottom: 20px;
  font-family: var(--font-title);
  position: relative;
  padding-bottom: 8px;
}

.blog-detail-content h2::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 3px;
  background: linear-gradient(90deg, var(--color-primary), var(--color-accent));
  border-radius: 2px;
}

.blog-detail-content h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin-top: 36px;
  margin-bottom: 16px;
  font-family: var(--font-title);
}

.blog-detail-content ul, .blog-detail-content ol {
  margin-bottom: 24px;
  padding-left: 20px;
}

.blog-detail-content li {
  margin-bottom: 12px;
}

.blog-detail-content blockquote {
  background: rgba(255, 255, 255, 0.02);
  border-left: 4px solid var(--color-accent);
  padding: 20px 24px;
  margin: 32px 0;
  border-radius: 0 12px 12px 0;
  font-style: italic;
  color: var(--text-primary);
}

.blog-detail-content blockquote p {
  margin-bottom: 0;
}

.blog-detail-content strong {
  color: var(--text-primary);
}

.blog-detail-share {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.blog-detail-share-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.blog-detail-share-btns {
  display: flex;
  gap: 12px;
}

.blog-detail-share-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  text-decoration: none;
  transition: all 0.3s ease;
}

.blog-detail-share-btn:hover {
  background: var(--color-accent);
  color: #0b0f19;
  border-color: var(--color-accent);
  transform: translateY(-2px);
}

/* Related Posts at bottom of detail page */
.blog-detail-related {
  border-top: 1px solid var(--border-color);
  margin-top: 64px;
  padding-top: 48px;
}

.blog-detail-related-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 32px;
  font-family: var(--font-title);
  text-align: center;
}

@media (max-width: 768px) {
  .blog-detail-title {
    font-size: 30px;
  }
  .blog-detail-content {
    font-size: 16px;
  }
}

/* Blog Detail Content Table */
.blog-detail-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 32px 0;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border-color);
  font-size: 15px;
  background: rgba(255, 255, 255, 0.01);
}

.blog-detail-content th {
  background: rgba(20, 127, 215, 0.1);
  color: var(--text-primary);
  font-weight: 700;
  padding: 14px 18px;
  text-align: left;
  border-bottom: 2px solid var(--border-color);
}

.blog-detail-content td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-secondary);
}

.blog-detail-content tr:last-child td {
  border-bottom: none;
}

.blog-detail-content tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

/* --- Blog Inline CTA Banner --- */
.blog-inline-cta {
  transition: border-color 0.4s ease, box-shadow 0.4s ease;
}

.blog-inline-cta:hover {
  border-color: rgba(20, 127, 215, 0.45);
  box-shadow: 0 0 40px rgba(20, 127, 215, 0.08), 0 8px 32px rgba(0, 0, 0, 0.15);
}

.blog-inline-cta .btn {
  transition: all 0.3s ease;
}

.blog-inline-cta .btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(20, 127, 215, 0.4);
}

.blog-inline-cta .btn-secondary:hover {
  transform: translateY(-2px);
}

@media (max-width: 480px) {
  .blog-inline-cta {
    padding: 28px 20px !important;
  }
  .blog-inline-cta h3 {
    font-size: 18px !important;
  }
  .blog-inline-cta p {
    font-size: 14px !important;
  }
}
