/* Responsive enhancements applied across Kasaloop landing pages */
:root {
  --responsive-inline-gap: clamp(1rem, 4vw, 1.75rem);
  --responsive-table-min-width: 640px;
}

html,
body {
  width: 100%;
  min-width: 0;
  overflow-x: hidden;
}

html {
  scroll-behavior: smooth;
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background: linear-gradient(180deg, #eef2ff 0%, #f9fafb 45%, #ffffff 100%);
  color: #111827;
  transition: background 0.3s ease, color 0.3s ease;
}

html.dark {
  background: radial-gradient(circle at top, rgba(30, 41, 59, 0.92), rgba(15, 23, 42, 0.95));
  color: #e5e7eb;
}

html.dark body {
  background: radial-gradient(circle at top, rgba(30, 41, 59, 0.92), rgba(15, 23, 42, 0.95));
  color: #e5e7eb;
}

.fade-in {
  animation: fadeIn 0.8s ease-in both;
}

.slide-in-left {
  animation: slideInLeft 0.8s ease-out both;
}

.slide-in-right {
  animation: slideInRight 0.8s ease-out both;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Make navbar more compact on mobile */
nav.fixed .container {
  padding-top: 1rem;
  padding-bottom: 1rem;
}

@media (max-width: 640px) {
  nav.fixed .container {
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
  }

  nav.fixed img[alt*="Logo"] {
    width: 3rem !important;
    height: 3rem !important;
  }
}

/* Fixed navbar offset - accounts for navbar height + breathing room */
body.nav-offset {
  padding-top: 6rem !important; /* Consistent across all pages */
}

@media (max-width: 768px) {
  body.nav-offset {
    padding-top: 5rem !important;
  }
}

@media (max-width: 640px) {
  body.nav-offset {
    padding-top: 4.5rem !important;
  }
}

/* Fallback: add safe offset on pages that forgot .nav-offset */
body:not(.nav-offset) {
  padding-top: clamp(4.5rem, 12vw, 6rem);
}

/* Gentle breathing room below the fixed navbar */
nav.fixed ~ * {
  margin-top: clamp(1.5rem, 3vw, 2rem) !important;
}

/* Tighten up and normalize vertical rhythm inside containers */
.container h1,
.container h2,
.container h3,
h1, h2, h3, h4, h5, h6 {
  margin-top: clamp(2rem, 4vw, 3rem);
  margin-bottom: clamp(0.75rem, 2vw, 1.25rem);
  line-height: 1.2;
}

/* First heading in section should have minimal top margin */
section > h1:first-child,
section > h2:first-child,
section > h3:first-child,
section > .container > h1:first-child,
section > .container > h2:first-child,
section > .container > h3:first-child,
.container > h1:first-child,
.container > h2:first-child,
.container > h3:first-child {
  margin-top: 0 !important;
}

.container p,
.container ul,
.container ol,
p {
  margin-top: 0.5rem;
  margin-bottom: clamp(0.75rem, 2vw, 1rem);
  line-height: 1.7;
}

/* Ensure grid/card blocks have consistent spacing without editing each page */
.grid,
.container .grid,
.feature-grid,
.guide-grid,
.comparison-grid {
  gap: clamp(1.5rem, 3vw, 2.25rem) !important;
  margin-top: clamp(1.5rem, 3vw, 2.5rem) !important;
  margin-bottom: clamp(2rem, 4vw, 3rem) !important;
}

/* Space between stacked containers/sections */
.container + .container,
section + section {
  margin-top: clamp(2.5rem, 5vw, 4rem);
}

/* Add consistent top/bottom spacing for the first-level grids in sections */
.section-padding > .container > .grid {
  margin-top: clamp(0.75rem, 2vw, 1.25rem);
  margin-bottom: clamp(2.5rem, 6vw, 4rem);
}

/* Headings following grids/cards: add extra top margin so they don't crowd */
.grid + h1,
.grid + h2,
.grid + h3,
.feature-grid + h1,
.feature-grid + h2,
.feature-grid + h3,
.comparison-table + h1,
.comparison-table + h2,
.comparison-table + h3 {
  margin-top: clamp(1.5rem, 3vw, 2.5rem) !important;
}

/* Dark mode readability for comparison pros/cons headings and text */
/* ============================================
   DARK MODE - COMPREHENSIVE TEXT VISIBILITY
   ============================================ */

/* Base dark mode colors */
html.dark {
  color: #e5e7eb !important;
}

html.dark h1,
html.dark h2,
html.dark h3,
html.dark h4,
html.dark h5,
html.dark h6 {
  color: #f8fafc !important;
}

html.dark p,
html.dark li:not(.mobile-menu-link),
html.dark span:not(.badge):not(.text-white) {
  color: rgba(226, 232, 240, 0.9) !important;
}

html.dark a:not(.mobile-menu-link):not(.cta-button):not(.btn) {
  color: #c4b5fd !important;
}

html.dark a:not(.mobile-menu-link):not(.cta-button):not(.btn):hover {
  color: #ddd6fe !important;
}

/* Card text in dark mode */
html.dark .glass-card p,
html.dark .feature-card p,
html.dark .content-card p,
html.dark .benefit-card p,
html.dark .card p {
  color: rgba(226, 232, 240, 0.88) !important;
}

html.dark .glass-card h2,
html.dark .glass-card h3,
html.dark .feature-card h2,
html.dark .feature-card h3,
html.dark .content-card h2,
html.dark .content-card h3 {
  color: #f8fafc !important;
}

/* Dark mode colors for comparison pros/cons blocks (keep readable on tinted backgrounds) */
html.dark .pros-section {
  background: rgba(16, 185, 129, 0.15) !important;
  border: 1px solid rgba(16, 185, 129, 0.3) !important;
}

html.dark .cons-section {
  background: rgba(239, 68, 68, 0.15) !important;
  border: 1px solid rgba(239, 68, 68, 0.3) !important;
}

html.dark .pros-section h4 {
  color: #86efac !important;
}

html.dark .cons-section h4 {
  color: #fecaca !important;
}

html.dark .pros-section li {
  color: rgba(187, 247, 208, 0.9) !important;
}

html.dark .cons-section li {
  color: rgba(254, 202, 202, 0.9) !important;
}

/* Dark mode fixes for comparison page FAQ accordions */
html.dark .faq-item {
  background: rgba(17, 24, 39, 0.78) !important;
  border-color: rgba(129, 140, 248, 0.35) !important;
}
html.dark .faq-question { color: #e5e7eb !important; }
html.dark .faq-answer { color: rgba(226, 232, 240, 0.9) !important; }
html.dark .faq-question i.fa-chevron-down { color: #c4b5fd !important; }

/* Dark mode readability for comparison tables */
html.dark .comparison-table th {
  background: rgba(31, 41, 55, 0.6) !important; /* gray-800/60 */
  color: #e5e7eb !important; /* gray-200 */
  border-color: rgba(75, 85, 99, 0.6) !important; /* gray-600/60 */
}
html.dark .comparison-table td {
  color: #e5e7eb !important;
  border-color: rgba(75, 85, 99, 0.6) !important;
}

/* Ensure section headings always clear preceding cards/tables */
.glass-card + h1, .glass-card + h2, .glass-card + h3,
.content-card + h1, .content-card + h2, .content-card + h3,
.pros-cons-grid + h1, .pros-cons-grid + h2, .pros-cons-grid + h3,
.comparison-table + h1, .comparison-table + h2, .comparison-table + h3 {
  margin-top: clamp(1.75rem, 3.5vw, 3rem) !important;
}

/* Footer - Professional, Compact & Consistent */
footer.bg-gray-900 {
  padding-top: clamp(2rem, 4vw, 2.5rem) !important;
  padding-bottom: clamp(2rem, 4vw, 2.5rem) !important;
  background: #111827 !important;
}

footer.bg-gray-900 .container {
  max-width: 1200px !important;
  margin: 0 auto !important;
}

footer.bg-gray-900 .grid {
  gap: clamp(1.5rem, 3vw, 2rem) !important;
  margin-bottom: clamp(1rem, 2vw, 1.5rem) !important;
  margin-top: 0 !important;
  align-items: start !important;
}

footer.bg-gray-900 h3 {
  font-size: 1rem !important;
  font-weight: 700 !important;
  margin-bottom: 0.75rem !important;
  margin-top: 0 !important;
  color: #f9fafb !important;
}

/* Footer links */
footer.bg-gray-900 nav .space-y-2 {
  display: flex !important;
  flex-direction: column !important;
  gap: 0.5rem !important;
  align-items: flex-start !important;
}

footer.bg-gray-900 nav .space-y-2 > * {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

footer.bg-gray-900 a {
  color: rgba(229, 231, 235, 0.9) !important;
  font-size: 0.9rem !important;
  transition: color 0.2s ease !important;
}

footer.bg-gray-900 a:hover {
  color: #c4b5fd !important;
}

/* Footer copyright */
footer.bg-gray-900 .border-t {
  margin-top: clamp(1.5rem, 3vw, 2rem) !important;
  padding-top: clamp(1rem, 2vw, 1.5rem) !important;
  border-color: rgba(75, 85, 99, 0.5) !important;
}

footer.bg-gray-900 .border-t p {
  color: rgba(156, 163, 175, 0.9) !important;
  font-size: 0.875rem !important;
  margin: 0 !important;
}

/* Footer responsive layout */
@media (min-width: 768px) {
  footer.bg-gray-900 .grid {
    grid-template-columns: repeat(3, 1fr) !important;
  }
  
  footer.bg-gray-900 .grid > div:first-child {
    text-align: left !important;
  }
  
  footer.bg-gray-900 .grid > div:nth-child(2) {
    text-align: center !important;
  }
  
  footer.bg-gray-900 nav .space-y-2 {
    align-items: center !important;
  }
  
  footer.bg-gray-900 .grid > div:last-child {
    text-align: right !important;
  }
}

@media (max-width: 767px) {
  footer.bg-gray-900 .grid {
    grid-template-columns: 1fr !important;
    text-align: center !important;
  }
  
  footer.bg-gray-900 nav .space-y-2 {
    align-items: center !important;
  }
  
  footer.bg-gray-900 .grid > div {
    text-align: center !important;
  }
}

img,
svg,
video,
canvas,
iframe {
  max-width: 100%;
  height: auto;
}

/* Utility wrapper for horizontally scrollable tables on narrow screens */
.table-scroll {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.table-scroll table {
  min-width: var(--responsive-table-min-width);
  width: 100%;
}

.page-hero {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #ffffff;
  padding: clamp(4rem, 12vw, 6rem) 1rem clamp(3rem, 10vw, 4.5rem);
  position: relative;
  overflow: hidden;
}

.page-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.18), transparent 62%);
}

.page-hero > div {
  position: relative;
  z-index: 1;
}

.page-hero h1 {
  font-weight: 800;
  letter-spacing: -0.02em;
}

.page-hero p {
  color: rgba(255, 255, 255, 0.88);
  max-width: 44rem;
}

.page-hero .badge {
  display: inline-flex;
  align-items: center;
  padding: 0.45rem 1.1rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: rgba(255, 255, 255, 0.95);
}

.glass-card,
.card {
  background: rgba(255, 255, 255, 0.92);
  border-radius: 1.5rem;
  border: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow: 0 25px 60px rgba(102, 126, 234, 0.18);
  backdrop-filter: blur(18px);
  padding: clamp(1.75rem, 3vw, 2.5rem);
}

html.dark .glass-card,
html.dark .card {
  background: rgba(17, 24, 39, 0.75);
  border-color: rgba(167, 139, 250, 0.24);
  box-shadow: 0 35px 70px rgba(15, 23, 42, 0.65);
}

/* Shared hero variants */
.page-hero.page-hero--compact {
  padding-top: clamp(3.5rem, 10vw, 4.5rem);
  padding-bottom: clamp(2.5rem, 8vw, 3.5rem);
}

.page-hero .breadcrumb {
  margin-bottom: clamp(1.25rem, 3vw, 1.75rem);
}

.page-hero .breadcrumb a {
  color: rgba(255, 255, 255, 0.92);
}

/* Badge system reused across features/guides */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.28rem 0.8rem;
  border-radius: 9999px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  line-height: 1;
}


.gradient-bg {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #ffffff;
}

html.dark .gradient-bg {
  background: linear-gradient(135deg, #4c1d95 0%, #6b21a8 50%, #4338ca 100%);
  color: rgba(255, 255, 255, 0.94);
}

/* NUCLEAR FIX FOR GRADIENT TEXT - NO GRADIENTS AT ALL */
.gradient-text {
  /* Force solid brand colors - no gradients */
  color: #667eea !important;
  background: none !important;
  background-color: transparent !important;
  background-image: none !important;
  -webkit-text-fill-color: currentColor !important;
  -webkit-background-clip: unset !important;
  background-clip: unset !important;
}

html.dark .gradient-text {
  color: #a78bfa !important;
  background: none !important;
  background-color: transparent !important;
  background-image: none !important;
  -webkit-text-fill-color: currentColor !important;
}

/* Feature icon - NUCLEAR FIX: NO GRADIENTS AT ALL */
.feature-icon {
  font-size: 2.5rem;
  /* This is just a container div - no styles */
  background: none !important;
  background-image: none !important;
}

/* Simple solid colors for the actual icons - NO GRADIENTS */
.feature-icon i,
.feature-icon svg,
.feature-icon::before,
.feature-icon::after {
  color: #667eea !important;
  font-size: inherit;
  display: block;
  background: none !important;
  background-image: none !important;
  -webkit-text-fill-color: currentColor !important;
}

html.dark .feature-icon i,
html.dark .feature-icon svg {
  color: #a78bfa !important;
}

.back-link-primary,
.inline-link {
  color: #4c51bf;
  font-weight: 600;
}

html.dark .back-link-primary,
html.dark .inline-link {
  color: rgba(196, 181, 253, 0.95);
}

.back-link-primary:hover,
.inline-link:hover {
  color: #5b21b6;
}

html.dark .back-link-primary:hover,
html.dark .inline-link:hover {
  color: rgba(221, 214, 254, 0.95);
}

.badge.badge-gradient {
  background: linear-gradient(135deg, #667eea 0%, #7c3aed 100%);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.4);
}

.badge.badge-outline {
  background: transparent;
  border: 1px solid rgba(124, 58, 237, 0.4);
  color: #4c1d95;
}

.badge.badge-enterprise {
  background: rgba(79, 70, 229, 0.12);
  color: #4338ca;
  border: 1px solid rgba(79, 70, 229, 0.25);
}

.badge.badge-new {
  background: rgba(16, 185, 129, 0.15);
  color: #047857;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

html.dark .badge.badge-outline {
  color: rgba(196, 181, 253, 0.92);
  border-color: rgba(167, 139, 250, 0.45);
}

html.dark .badge.badge-enterprise {
  background: rgba(167, 139, 250, 0.18);
  color: rgba(224, 231, 255, 0.95);
  border-color: rgba(129, 140, 248, 0.45);
}

html.dark .badge.badge-new {
  background: rgba(34, 197, 94, 0.2);
  color: #bbf7d0;
  border-color: rgba(16, 185, 129, 0.4);
}

/* Feature + product grid layouts */
.feature-grid,
.guide-grid,
.comparison-grid {
  display: grid;
  gap: clamp(1.5rem, 3vw, 2.25rem);
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  align-items: stretch;
}

/* Add safe breathing room for the first grid (prevents hover overlap with headings) */
.feature-grid,
.comparison-grid {
  margin-top: clamp(2rem, 4vw, 3.5rem);
  margin-bottom: clamp(3rem, 7vw, 5rem); /* extra space above CTA */
}

.feature-card,
.benefit-card,
.content-card {
  display: flex;
  flex-direction: column;
  gap: clamp(1rem, 1.8vw, 1.35rem);
  height: 100%;
  padding: clamp(1.75rem, 3vw, 2.25rem);
  position: relative; /* for glow layer */
  will-change: transform;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 1.5rem;
  border: 1px solid rgba(226, 232, 240, 0.6);
  box-shadow: 0 20px 50px rgba(102, 126, 234, 0.15);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html.dark .feature-card,
html.dark .benefit-card,
html.dark .content-card {
  background: rgba(17, 24, 39, 0.85) !important;
  border-color: rgba(129, 140, 248, 0.28) !important;
  box-shadow: 0 25px 60px rgba(15, 23, 42, 0.65) !important;
}

.feature-card-header {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

@media (min-width: 640px) {
  .feature-card-header {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
  }
}

.card-hover {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  position: relative;
  will-change: transform;
}

.card-hover:hover {
  transform: translateY(-4px) !important;
  box-shadow: 0 30px 60px rgba(102, 126, 234, 0.28), 0 0 0 1px rgba(129, 140, 248, 0.22) !important;
}

/* Subtle glowing effect - UNIFIED across all cards */
.feature-card::before,
.benefit-card::before,
.content-card::before,
.glass-card.card-hover::before,
.card-hover::before {
  content: '';
  position: absolute;
  inset: -8px;
  border-radius: 1.75rem;
  background: radial-gradient(60% 80% at 50% 0%, rgba(124, 58, 237, 0.25), rgba(99, 102, 241, 0.18), transparent 70%);
  filter: blur(22px);
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: -1;
  pointer-events: none;
}

.feature-card:hover::before,
.benefit-card:hover::before,
.content-card:hover::before,
.glass-card.card-hover:hover::before,
.card-hover:hover::before {
  opacity: 1;
}

html.dark .feature-card::before,
html.dark .benefit-card::before,
html.dark .content-card::before,
html.dark .glass-card.card-hover::before,
html.dark .card-hover::before {
  background: radial-gradient(60% 80% at 50% 0%, rgba(167, 139, 250, 0.28), rgba(129, 140, 248, 0.22), transparent 70%);
}

.feature-card > .feature-icon {
  font-size: clamp(2rem, 5vw, 2.75rem);
}

/* ============================================
   FONT AWESOME ICONS - BULLETPROOF VISIBILITY
   ============================================ */

/* Ensure all icons are visible and properly styled */
i.fas, i.far, i.fab, i.fa,
.fas, .far, .fab, .fa {
  display: inline-block !important;
  font-style: normal !important;
  font-variant: normal !important;
  text-rendering: auto !important;
  -webkit-font-smoothing: antialiased !important;
  -moz-osx-font-smoothing: grayscale !important;
  color: inherit !important;
  /* Remove any gradient background effects that might cause purple boxes */
  background: none !important;
  -webkit-text-fill-color: currentColor !important;
  -webkit-background-clip: initial !important;
  background-clip: initial !important;
}

.feature-icon {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: clamp(3rem, 10vw, 3.5rem);
  height: clamp(3rem, 10vw, 3.5rem);
  border-radius: 1rem;
  background: rgba(102, 126, 234, 0.12);
  color: #4c51bf !important;
}

.feature-icon i,
.feature-icon .fas,
.feature-icon .far,
.feature-icon .fab {
  font-size: clamp(1.5rem, 4vw, 1.85rem) !important;
  color: inherit !important;
}

html.dark .feature-icon {
  background: rgba(76, 81, 191, 0.22);
  color: rgba(224, 231, 255, 0.96) !important;
}

.benefit-card {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: clamp(1.5rem, 3vw, 2rem);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.benefit-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 25px 50px rgba(102, 126, 234, 0.24), 0 0 0 1px rgba(129, 140, 248, 0.18);
}

/* Comparisons: "Which Platform Fits Your Needs?" separation */
.needs-section > .space-y-6 > div {
  border: 1px solid rgba(229, 231, 235, 0.9); /* gray-200 */
  box-shadow: 0 8px 20px rgba(31, 41, 55, 0.08);
}

html.dark .needs-section > .space-y-6 > div {
  background: rgba(17, 24, 39, 0.86) !important; /* slightly lighter than pure gray-900 */
  border-color: rgba(129, 140, 248, 0.28); /* indigo-400 tint for separation */
  box-shadow: 0 12px 24px rgba(2, 6, 23, 0.45);
}

/* Comparisons: cards/tables spacing and dark-mode parity for detail pages */
.comparison-card { margin-bottom: clamp(1.5rem, 3vw, 2rem); }
html.dark .comparison-card {
  background: rgba(17, 24, 39, 0.78) !important;
  border: 1px solid rgba(129, 140, 248, 0.28) !important;
  box-shadow: 0 20px 40px rgba(2, 6, 23, 0.35) !important;
}

/* Feature/Comparison tables on detail pages */
html.dark .feature-table th { 
  background: rgba(31, 41, 55, 0.6) !important;
  color: #e5e7eb !important;
  border-color: rgba(75, 85, 99, 0.6) !important;
}
html.dark .feature-table td {
  color: #e5e7eb !important;
  border-top-color: rgba(75, 85, 99, 0.6) !important;
}

/* Headings should clear comparison blocks and tables */
.comparison-card + h1, .comparison-card + h2, .comparison-card + h3,
.feature-table + h1, .feature-table + h2, .feature-table + h3 {
  margin-top: clamp(1.5rem, 3vw, 2.5rem) !important;
}

.benefit-card .feature-icon {
  margin-bottom: 0.5rem;
}

.benefit-card h3 {
  font-size: clamp(1.2rem, 3vw, 1.5rem);
  font-weight: 700;
  color: #1f2937;
}

.benefit-card p {
  color: #4b5563;
  line-height: 1.65;
}

html.dark .benefit-card h3 {
  color: #f9fafb;
}

html.dark .benefit-card p {
  color: rgba(226, 232, 240, 0.85);
}

.faq-section {
  margin-top: clamp(2rem, 6vw, 3rem);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: clamp(1.5rem, 3vw, 2.5rem);
}

.faq-section h2 {
  margin-bottom: 0.5rem;
}

.content-card {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: clamp(1.5rem, 3vw, 2.25rem);
  background: rgba(255, 255, 255, 0.94);
  border-radius: 1.5rem;
  border: 1px solid rgba(148, 163, 184, 0.25);
  box-shadow: 0 25px 55px rgba(102, 126, 234, 0.18);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.content-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 30px 70px rgba(102, 126, 234, 0.28), 0 0 0 1px rgba(129, 140, 248, 0.22);
  border-color: rgba(99, 102, 241, 0.35);
}

/* Extra cushion above common CTA sections */
.cta-section {
  margin-top: clamp(1.5rem, 4vw, 2rem);
  margin-bottom: clamp(1.5rem, 4vw, 2rem);
}

.content-card h3 {
  font-size: clamp(1.25rem, 3vw, 1.6rem);
  font-weight: 700;
  color: #1f2937;
}

.content-card p {
  color: #4b5563;
  line-height: 1.7;
}

html.dark .content-card {
  background: rgba(17, 24, 39, 0.75);
  border-color: rgba(129, 140, 248, 0.25);
  box-shadow: 0 35px 80px rgba(15, 23, 42, 0.6);
}

html.dark .content-card h3 {
  color: rgba(248, 250, 252, 0.95);
}

html.dark .content-card p {
  color: rgba(203, 213, 225, 0.85);
}

.icon-box {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: clamp(3.25rem, 8vw, 3.75rem);
  height: clamp(3.25rem, 8vw, 3.75rem);
  border-radius: 1.25rem;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #ffffff;
  font-size: clamp(1.4rem, 4vw, 1.8rem);
  box-shadow: 0 15px 35px rgba(102, 126, 234, 0.25);
}

html.dark .icon-box {
  background: linear-gradient(135deg, #7c3aed 0%, #6366f1 100%);
  box-shadow: 0 18px 40px rgba(79, 70, 229, 0.35);
}

.tech-card {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: clamp(1.5rem, 3vw, 2rem);
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 1.5rem;
  box-shadow: 0 20px 55px rgba(102, 126, 234, 0.18);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.tech-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 28px 70px rgba(102, 126, 234, 0.26);
}

.tech-card h3 {
  font-size: clamp(1.1rem, 2.8vw, 1.45rem);
  font-weight: 700;
  color: #1f2937;
}

.tech-card p {
  color: #4b5563;
  line-height: 1.65;
}

.sensor-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: clamp(3rem, 7vw, 3.25rem);
  height: clamp(3rem, 7vw, 3.25rem);
  border-radius: 1rem;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #ffffff;
  font-size: clamp(1.2rem, 3vw, 1.5rem);
  box-shadow: 0 15px 35px rgba(102, 126, 234, 0.25);
}

html.dark .tech-card {
  background: rgba(17, 24, 39, 0.75);
  border-color: rgba(129, 140, 248, 0.25);
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.6);
}

html.dark .tech-card h3 {
  color: rgba(248, 250, 252, 0.95);
}

html.dark .tech-card p {
  color: rgba(203, 213, 225, 0.85);
}

html.dark .sensor-icon {
  background: linear-gradient(135deg, #7c3aed 0%, #6366f1 100%);
  box-shadow: 0 18px 40px rgba(79, 70, 229, 0.35);
}

:is(.comparison-table, table.comparison-table) {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 1.5rem;
  box-shadow: 0 20px 50px rgba(102, 126, 234, 0.18);
}

.comparison-table table {
  width: 100%;
  border-collapse: collapse;
  background: transparent;
}

table.comparison-table {
  width: 100%;
  border-collapse: collapse;
  border-radius: inherit;
  overflow: hidden;
}

:is(.comparison-table, table.comparison-table) thead {
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.15), rgba(118, 75, 162, 0.15));
}

:is(.comparison-table, table.comparison-table) th,
:is(.comparison-table, table.comparison-table) td {
  padding: 1rem 1.25rem;
  text-align: left;
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
  font-size: 0.95rem;
  color: #1f2937;
}

:is(.comparison-table, table.comparison-table) th {
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 0.78rem;
  color: #4338ca;
}

:is(.comparison-table, table.comparison-table) tbody tr:nth-child(even) {
  background: rgba(102, 126, 234, 0.06);
}

html.dark :is(.comparison-table, table.comparison-table) {
  background: rgba(17, 24, 39, 0.72);
  border-color: rgba(129, 140, 248, 0.2);
  box-shadow: 0 25px 60px rgba(15, 23, 42, 0.55);
}

html.dark :is(.comparison-table, table.comparison-table) thead {
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.25), rgba(99, 102, 241, 0.25));
}

html.dark :is(.comparison-table, table.comparison-table) th,
html.dark :is(.comparison-table, table.comparison-table) td {
  color: rgba(226, 232, 240, 0.92);
  border-color: rgba(79, 70, 229, 0.35);
}

html.dark :is(.comparison-table, table.comparison-table) tbody tr:nth-child(even) {
  background: rgba(79, 70, 229, 0.16);
}

/* Comparison page spacing + alignment */
.comparison-intro,
.pros-cons-grid,
.comparison-table {
  margin-top: clamp(0.75rem, 2vw, 1.25rem);
  margin-bottom: clamp(1.75rem, 4vw, 2.5rem);
}

.pros-cons-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: clamp(1rem, 2.5vw, 1.5rem);
}

.pros-section h4,
.cons-section h4 {
  margin-bottom: 0.5rem;
}

.feature-card h2,
.feature-card h3 {
  font-size: clamp(1.4rem, 3vw, 1.8rem);
  font-weight: 700;
  color: #1f2937;
}

html.dark .feature-card h2,
html.dark .feature-card h3 {
  color: #f3f4f6;
}

.feature-card p {
  color: #4b5563;
  line-height: 1.65;
}

html.dark .feature-card p {
  color: rgba(226, 232, 240, 0.85);
}

.feature-card .feature-badges {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.feature-card .feature-link {
  margin-top: auto;
  font-weight: 600;
  color: #4c51bf;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

html.dark .feature-card .feature-link {
  color: rgba(196, 181, 253, 0.92);
}

.feature-card .feature-link:hover {
  color: #5b21b6;
}

html.dark .feature-card .feature-link:hover {
  color: rgba(221, 214, 254, 0.95);
}

.feature-bullets,
.comparison-list,
.guide-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.65rem;
}

.feature-bullets li,
.comparison-list li,
.guide-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  color: #4b5563;
  line-height: 1.6;
}

.feature-bullets i,
.comparison-list i,
.guide-list i {
  flex-shrink: 0;
  color: #4c51bf;
  margin-top: 0.15rem;
}

html.dark .feature-bullets li,
html.dark .comparison-list li,
html.dark .guide-list li {
  color: rgba(226, 232, 240, 0.85);
}

html.dark .feature-bullets i,
html.dark .comparison-list i,
html.dark .guide-list i {
  color: rgba(196, 181, 253, 0.82);
}

/* FAQ accordions */
.faq-group {
  display: grid;
  gap: clamp(1rem, 2vw, 1.5rem);
}

.faq-item {
  border-radius: 0.75rem;
  border: 1px solid rgba(99, 102, 241, 0.15);
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  overflow: hidden;
  transition: all 0.2s ease;
  margin-bottom: 0.75rem;
}

.faq-item:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.1);
  border-color: rgba(99, 102, 241, 0.25);
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  list-style: none;
  padding: 1.25rem 1.5rem;
  font-size: 1.125rem;
  font-weight: 600;
  cursor: pointer;
  color: #1f2937;
  min-height: 4rem;
}

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

.faq-question i {
  color: #4c51bf;
  font-size: 0.95rem;
  transition: transform 0.25s ease;
}

details[open] .faq-question i {
  transform: rotate(180deg);
}

.faq-answer {
  padding: 0 1.5rem 1.5rem 1.5rem;
  color: #4b5563;
  line-height: 1.7;
}

.faq-answer p + p {
  margin-top: 0.9rem;
}

.faq-answer ul {
  margin-top: 0.75rem;
  margin-left: 1.1rem;
  display: grid;
  gap: 0.5rem;
}

html.dark .faq-item {
  background: rgba(17, 24, 39, 0.6);
  border-color: rgba(167, 139, 250, 0.2);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

html.dark .faq-item:hover {
  border-color: rgba(167, 139, 250, 0.35);
  box-shadow: 0 4px 16px rgba(167, 139, 250, 0.1);
}

html.dark .faq-question {
  color: rgba(226, 232, 240, 0.95);
}

html.dark .faq-question i {
  color: rgba(196, 181, 253, 0.85);
}

html.dark .faq-answer {
  color: rgba(226, 232, 240, 0.85);
}

/* Call-to-action blocks */
.cta-section {
  position: relative;
  overflow: hidden;
  border-radius: clamp(1.5rem, 4vw, 2.25rem);
  padding: clamp(3rem, 8vw, 4rem) clamp(2rem, 6vw, 3.5rem);
  background: linear-gradient(135deg, #5b21b6 0%, #7c3aed 100%);
  box-shadow: 0 35px 70px rgba(76, 29, 149, 0.25);
}

.cta-section::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle at 15% 20%, rgba(255, 255, 255, 0.18), transparent 55%);
}

.cta-section > * {
  position: relative;
  z-index: 1;
}

.cta-section h2 {
  color: #fff;
  font-size: clamp(2rem, 5vw, 2.75rem);
  margin-bottom: clamp(1rem, 3vw, 1.5rem);
}

.cta-section p {
  color: rgba(255, 255, 255, 0.88);
  font-size: clamp(1.05rem, 3vw, 1.15rem);
  margin-bottom: clamp(1.5rem, 4vw, 2.5rem);
}

.cta-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  justify-content: center;
}

.cta-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.95rem 2.5rem;
  border-radius: 9999px;
  background: #fff;
  color: #5b21b6;
  font-weight: 700;
  gap: 0.75rem;
  box-shadow: 0 18px 32px rgba(15, 23, 42, 0.2);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 25px 42px rgba(15, 23, 42, 0.3);
}

.cta-button.cta-button-outline {
  background: transparent;
  border: 2px solid rgba(255, 255, 255, 0.65);
  color: #fff;
}

.cta-button.cta-button-outline:hover {
  background: rgba(255, 255, 255, 0.12);
}

html.dark .cta-button {
  color: #4c1d95;
}

.section-heading {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 1.25rem;
}

html.dark .section-heading {
  color: #f3f4f6;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  font-size: 0.9rem;
  color: #6b7280;
}

.breadcrumb a {
  color: #4c51bf;
  font-weight: 600;
}

html.dark .breadcrumb a {
  color: #c4b5fd;
}

.badge-soft {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.95rem;
  border-radius: 9999px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(102, 126, 234, 0.12);
  color: #4c51bf;
}

html.dark .badge-soft {
  background: rgba(167, 139, 250, 0.16);
  color: #c4b5fd;
}

/* Opt-in helper to stack horizontal flex layouts on smaller screens */
.stack-on-mobile {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.stack-on-mobile > * {
  flex: 1 1 auto;
}

@media (max-width: 1024px) {
  .stack-on-mobile {
    gap: 1.25rem;
  }
}

@media (max-width: 768px) {
  .stack-on-mobile {
    flex-direction: column;
    align-items: stretch;
  }

  .stack-on-mobile > * {
    width: 100%;
  }

  /* Single column fallback for dense grids without explicit breakpoints */
  .grid.grid-cols-2,
  .grid.grid-cols-3,
  .grid.grid-cols-4 {
    grid-template-columns: repeat(1, minmax(0, 1fr));
  }

  /* Fluid typography for headings that rely on default element selectors */
  h1 {
    font-size: clamp(2rem, 6.5vw, 2.6rem);
    line-height: 1.15;
  }

  h2 {
    font-size: clamp(1.6rem, 5.5vw, 2rem);
  }

  h3 {
    font-size: clamp(1.3rem, 4.5vw, 1.6rem);
  }

  p,
  li {
    font-size: clamp(1rem, 3.2vw, 1.05rem);
  }

  main,
  section,
  article,
  .policy-container,
  .faq-container,
  .card,
  .content-board,
  .feature-section,
  .guide-container {
    padding-left: var(--responsive-inline-gap);
    padding-right: var(--responsive-inline-gap);
  }

  .section-padding {
    padding-top: clamp(3rem, 7vw, 4rem);
    padding-bottom: clamp(3rem, 7vw, 4rem);
  }

  nav .stack-on-mobile {
    align-items: flex-start;
  }

  .table-scroll {
    margin-left: -0.5rem;
    margin-right: -0.5rem;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }
}

@media (max-width: 480px) {
  :root {
    --responsive-table-min-width: 520px;
  }

  main,
  section,
  article,
  .policy-container,
  .faq-container,
  .card,
  .feature-section,
  .guide-container {
    padding-left: clamp(0.85rem, 5vw, 1rem);
    padding-right: clamp(0.85rem, 5vw, 1rem);
  }

  .table-scroll {
    margin-left: -0.75rem;
    margin-right: -0.75rem;
    padding-left: 0.75rem;
    padding-right: 0.75rem;
  }
}

/* ========================================
   MOBILE NAVIGATION SYSTEM
   ======================================== */

/* CSS Variables for Mobile Menu */
:root {
  --mobile-menu-width: 320px;
  --mobile-menu-bg: #ffffff;
  --mobile-menu-text: #111827;
  --mobile-menu-shadow: 0 0 20px rgba(0, 0, 0, 0.15);
  --backdrop-bg: rgba(0, 0, 0, 0.5);
  --transition-speed: 300ms;
  --safe-area-top: env(safe-area-inset-top, 0px);
  --safe-area-bottom: env(safe-area-inset-bottom, 0px);
  --safe-area-left: env(safe-area-inset-left, 0px);
  --safe-area-right: env(safe-area-inset-right, 0px);
}

/* Dark mode variables */
.dark {
  --mobile-menu-bg: #111827;
  --mobile-menu-text: #f3f4f6;
  --backdrop-bg: rgba(0, 0, 0, 0.7);
}

/* iOS Safe Areas Support */
@supports (padding-top: max(0px)) {
  .nav-container {
    padding-left: max(1rem, env(safe-area-inset-left));
    padding-right: max(1rem, env(safe-area-inset-right));
  }

  .mobile-menu {
    padding-top: max(1rem, env(safe-area-inset-top));
    padding-bottom: max(1rem, env(safe-area-inset-bottom));
  }
}

/* Hamburger Menu Button */
.mobile-nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 48px;
  height: 48px;
  padding: 12px;
  background: transparent;
  border: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: all var(--transition-speed) ease;
}

@media (min-width: 768px) {
  .mobile-nav-toggle {
    display: none;
  }
}

.hamburger-line {
  width: 24px;
  height: 2px;
  background-color: #111827;
  margin: 3px 0;
  transition: all var(--transition-speed) ease;
  border-radius: 2px;
}

.dark .hamburger-line {
  background-color: #f3f4f6;
}

/* Animate hamburger to X when menu is open */
.menu-open .hamburger-line:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.menu-open .hamburger-line:nth-child(2) {
  opacity: 0;
}

.menu-open .hamburger-line:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

/* Mobile Menu Drawer */
.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: var(--mobile-menu-width);
  max-width: 85vw;
  background: var(--mobile-menu-bg);
  transform: translateX(100%);
  transition: transform var(--transition-speed) cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 9999;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  box-shadow: var(--mobile-menu-shadow);
}

.menu-open .mobile-menu {
  transform: translateX(0);
}

/* Mobile Menu Header */
.mobile-menu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.dark .mobile-menu-header {
  border-bottom-color: rgba(255, 255, 255, 0.1);
}

/* Mobile Menu Close Button */
.mobile-menu-close {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--mobile-menu-text);
  font-size: 24px;
  -webkit-tap-highlight-color: transparent;
}

/* Mobile Menu Content */
.mobile-menu-content {
  padding: 1.5rem;
}

.mobile-menu-nav {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.mobile-menu-link {
  display: block;
  padding: 0.75rem 1rem;
  color: var(--mobile-menu-text);
  text-decoration: none;
  border-radius: 0.5rem;
  transition: background var(--transition-speed) ease;
  font-size: 16px;
  min-height: 48px;
  display: flex;
  align-items: center;
}

.mobile-menu-link:hover,
.mobile-menu-link:focus {
  background: rgba(102, 126, 234, 0.1);
}

.mobile-menu-link.active {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
}

/* Mobile Menu CTA Buttons */
.mobile-menu-cta {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.dark .mobile-menu-cta {
  border-top-color: rgba(255, 255, 255, 0.1);
}

.mobile-cta-button {
  display: block;
  width: 100%;
  padding: 1rem;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  text-align: center;
  border-radius: 0.75rem;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: transform var(--transition-speed) ease;
  min-height: 48px;
}

.mobile-cta-button:active {
  transform: scale(0.98);
}

/* Backdrop Overlay */
.mobile-menu-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--backdrop-bg);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition-speed) ease, visibility var(--transition-speed) ease;
  z-index: 9998;
}

.menu-open .mobile-menu-backdrop {
  opacity: 1;
  visibility: visible;
}

/* Prevent body scroll when menu is open */
.menu-open {
  overflow: hidden;
  position: fixed;
  width: 100%;
  height: 100%;
}

/* Touch-friendly sizing for all interactive elements */
@media (max-width: 767px) {
  button, a, input, select, textarea {
    min-height: 44px;
  }

  .touch-target {
    min-width: 48px;
    min-height: 48px;
  }

  /* Fix navigation padding on mobile */
  nav .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  /* Reduce excessive padding-top on mobile */
  .pt-32 {
    padding-top: 5rem !important; /* Was 8rem */
  }

  /* Ensure dark mode toggle is large enough */
  [data-theme-toggle] {
    min-width: 48px;
    min-height: 48px;
    padding: 0.75rem;
  }
}

/* iOS-specific fixes */
@supports (-webkit-touch-callout: none) {
  /* iOS momentum scrolling */
  .mobile-menu {
    -webkit-overflow-scrolling: touch;
  }

  /* Remove tap highlight */
  * {
    -webkit-tap-highlight-color: transparent;
  }

  /* Fix 100vh on iOS */
  .mobile-menu {
    height: 100vh;
    height: -webkit-fill-available;
  }
}

/* Android-specific fixes */
@media screen and (max-width: 767px) {
  /* Account for Android Chrome address bar */
  .mobile-menu {
    height: 100vh;
    height: 100dvh; /* Dynamic viewport height */
  }
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Focus styles for keyboard navigation */
.mobile-menu-link:focus,
.mobile-menu-close:focus,
.mobile-nav-toggle:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
}

/* Landscape orientation fixes */
@media (max-height: 500px) and (orientation: landscape) {
  .mobile-menu {
    width: 50vw;
    max-width: 400px;
  }

  .mobile-menu-content {
    padding: 1rem;
  }

.mobile-menu-link {
    padding: 0.5rem 0.75rem;
    min-height: 40px;
  }
}

/* ============================================================
   Book Demo Modal + Slot Picker
   ============================================================ */

.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: clamp(1.5rem, 5vw, 3rem);
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 4000;
}

.modal.active {
  display: flex;
  animation: modal-fade-in 0.25s ease;
}

.modal.hidden {
  display: none;
}

@keyframes modal-fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal-panel {
  width: min(720px, 100%);
  max-height: min(92vh, 760px);
  overflow-y: auto;
  background: linear-gradient(145deg, #ffffff 0%, #f9f5ff 100%);
  border-radius: 26px;
  box-shadow: 0 35px 80px rgba(79, 70, 229, 0.18);
  position: relative;
  padding: clamp(2rem, 5vw, 2.75rem);
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.modal-open {
  overflow: hidden;
}

.modal-close {
  position: absolute;
  top: clamp(1rem, 2vw, 1.2rem);
  right: clamp(1rem, 2vw, 1.2rem);
  border: none;
  background: rgba(15, 23, 42, 0.08);
  color: #1f2937;
  width: 40px;
  height: 40px;
  border-radius: 9999px;
  font-size: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

.modal-close:hover {
  transform: scale(0.95);
  background: rgba(79, 70, 229, 0.1);
}

.book-demo-header h2 {
  font-size: clamp(1.9rem, 3vw, 2.4rem);
  font-weight: 800;
  color: #1f2937;
  margin-bottom: 0.75rem;
}

.book-demo-header p {
  color: #4b5563;
  font-size: 1rem;
  line-height: 1.7;
}

.book-demo-status {
  border-radius: 16px;
  padding: 1rem 1.25rem;
  font-weight: 600;
  font-size: 0.95rem;
  color: #374151;
  background: rgba(31, 41, 55, 0.05);
  border: 1px solid transparent;
}

.book-demo-status:empty {
  display: none;
}

.book-demo-status.status-success {
  background: rgba(34, 197, 94, 0.12);
  border-color: rgba(22, 163, 74, 0.25);
  color: #166534;
}

.book-demo-status.status-error {
  background: rgba(248, 113, 113, 0.12);
  border-color: rgba(239, 68, 68, 0.25);
  color: #b91c1c;
}

.book-demo-form {
  display: flex;
  flex-direction: column;
  gap: clamp(1.25rem, 3vw, 1.75rem);
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.form-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: #374151;
  letter-spacing: 0.01em;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  padding: 0.85rem 1rem;
  font-size: 0.95rem;
  color: #1f2937;
  background: rgba(255, 255, 255, 0.95);
  transition: border 0.2s ease, box-shadow 0.2s ease;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.04);
}

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

.form-field textarea {
  resize: vertical;
  min-height: 120px;
}

.demo-slot-picker {
  border-radius: 22px;
  border: 1px solid rgba(124, 58, 237, 0.15);
  background: rgba(255, 255, 255, 0.85);
  box-shadow: inset 0 1px 0 rgba(148, 163, 184, 0.2);
  padding: clamp(1.25rem, 3vw, 1.75rem);
  display: grid;
  gap: clamp(1rem, 2vw, 1.5rem);
}

.demo-slot-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.demo-slot-day {
  background: rgba(248, 250, 252, 0.85);
  border-radius: 18px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  border: 1px solid rgba(148, 163, 184, 0.2);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.45);
}

.demo-slot-day h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: #312e81;
  letter-spacing: 0.01em;
}

.demo-slot-options {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.demo-slot-option {
  border: 1px solid rgba(124, 58, 237, 0.25);
  background: rgba(255, 255, 255, 0.9);
  border-radius: 9999px;
  padding: 0.55rem 0.85rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: #4c1d95;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, border 0.2s ease;
}

.demo-slot-option:hover {
  transform: translateY(-1px);
  border-color: rgba(124, 58, 237, 0.45);
}

.demo-slot-option.selected {
  background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
  color: white;
  border-color: transparent;
  box-shadow: 0 12px 18px rgba(109, 40, 217, 0.28);
}

.demo-slot-summary {
  background: rgba(255, 255, 255, 0.55);
  border-radius: 18px;
  border: 1px dashed rgba(124, 58, 237, 0.35);
  padding: 1rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.demo-slot-summary-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.demo-slot-counter {
  font-weight: 700;
  color: #4338ca;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.demo-slot-clear {
  background: none;
  border: none;
  color: #7c3aed;
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.demo-slot-summary-help {
  font-size: 0.9rem;
  color: #4b5563;
}

.demo-slot-list {
  margin: 0;
  padding-left: 1.2rem;
  display: grid;
  gap: 0.4rem;
  color: #1f2937;
  font-weight: 500;
}

.demo-slot-note {
  font-size: 0.8rem;
  color: #6366f1;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.09em;
}

.demo-slot-error {
  color: #b91c1c;
  font-weight: 600;
  font-size: 0.85rem;
}

.demo-turnstile {
  display: flex;
  justify-content: center;
  padding: 0.5rem 0 0;
}

.book-demo-submit {
  border: none;
  border-radius: 16px;
  background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
  color: white;
  font-weight: 700;
  font-size: 1rem;
  padding: 0.95rem 1.2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  min-height: 54px;
  box-shadow: 0 18px 24px rgba(109, 40, 217, 0.25);
}

.book-demo-submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 22px 32px rgba(109, 40, 217, 0.32);
}

.book-demo-submit:disabled {
  opacity: 0.7;
  cursor: progress;
  box-shadow: none;
}

.btn-spinner {
  display: none;
  width: 18px;
  height: 18px;
  color: rgba(255, 255, 255, 0.85);
  animation: spin 0.9s linear infinite;
}

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

@media (max-width: 768px) {
  .modal-panel {
    padding: 1.75rem 1.5rem;
    border-radius: 22px;
  }

  .book-demo-header h2 {
    font-size: 1.75rem;
  }

  .book-demo-form {
    gap: 1.25rem;
  }

  .demo-slot-grid {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  }
}

@media (max-width: 640px) {
  .modal {
    padding: 1rem;
  }

  .modal-panel {
    max-height: 90vh;
    border-radius: 20px;
  }

  .book-demo-header h2 {
    font-size: 1.5rem;
  }

  .demo-slot-grid {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  }

  .demo-slot-summary-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .demo-slot-counter {
    font-size: 0.8rem;
  }
}

.dark .modal-panel {
  background: linear-gradient(145deg, rgba(15, 23, 42, 0.95), rgba(30, 41, 59, 0.95));
  border: 1px solid rgba(167, 139, 250, 0.24);
  box-shadow: 0 35px 70px rgba(15, 23, 42, 0.6);
}

.dark .book-demo-header h2 {
  color: #f8fafc;
}

.dark .book-demo-header p {
  color: rgba(226, 232, 240, 0.85);
}

.dark .form-label {
  color: rgba(226, 232, 240, 0.9);
}

.dark .form-field input,
.dark .form-field select,
.dark .form-field textarea {
  background: rgba(15, 23, 42, 0.85);
  border-color: rgba(148, 163, 184, 0.3);
  color: #f8fafc;
}

.dark .demo-slot-picker {
  background: rgba(15, 23, 42, 0.75);
  border-color: rgba(124, 58, 237, 0.28);
}

.dark .demo-slot-day {
  background: rgba(30, 41, 59, 0.9);
  border-color: rgba(148, 163, 184, 0.24);
}

.dark .demo-slot-day h4 {
  color: rgba(224, 231, 255, 0.9);
}

.dark .demo-slot-option {
  background: rgba(17, 24, 39, 0.85);
  color: rgba(196, 181, 253, 0.9);
  border-color: rgba(167, 139, 250, 0.32);
}

.dark .demo-slot-summary {
  background: rgba(17, 24, 39, 0.8);
  border-color: rgba(167, 139, 250, 0.35);
}

.dark .demo-slot-summary-help {
  color: rgba(203, 213, 225, 0.85);
}

.dark .demo-slot-note {
  color: rgba(196, 181, 253, 0.8);
}

.dark .book-demo-status {
  background: rgba(148, 163, 184, 0.1);
  color: #e2e8f0;
}

.dark .book-demo-status.status-success {
  background: rgba(22, 163, 74, 0.18);
  border-color: rgba(22, 163, 74, 0.45);
  color: #bbf7d0;
}

.dark .book-demo-status.status-error {
  background: rgba(239, 68, 68, 0.18);
  border-color: rgba(239, 68, 68, 0.45);
  color: #fecaca;
}

/* ==========================
   Policy & Legal Pages
   ========================== */

.policy-container {
  max-width: 960px;
  margin: 0 auto;
  padding: clamp(3rem, 6vw, 4.5rem) clamp(1.25rem, 4vw, 2rem) clamp(5rem, 8vw, 6rem);
  display: flex;
  flex-direction: column;
  gap: clamp(1.5rem, 4vw, 2rem);
}

.policy-container h1 {
  font-size: clamp(2.25rem, 5vw, 3rem);
  font-weight: 800;
  color: #1f2937;
  margin-bottom: 0.75rem;
}

.dark .policy-container h1 {
  color: #f8fafc;
}

.policy-container h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  color: #1f2937;
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
}

.policy-container h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-top: 1rem;
  margin-bottom: 0.5rem;
  color: #334155;
}

.dark .policy-container h2,
.dark .policy-container h3 {
  color: #e2e8f0;
}

.policy-container p,
.policy-container li {
  color: #475569;
  line-height: 1.7;
}

.dark .policy-container p,
.dark .policy-container li {
  color: rgba(226, 232, 240, 0.85);
}

.policy-container ul {
  margin-left: 1.25rem;
  padding-left: 0.75rem;
  display: grid;
  gap: 0.45rem;
}

.policy-container .glass-card {
  border-radius: 22px;
  padding: clamp(1.75rem, 3vw, 2.25rem);
  backdrop-filter: blur(12px);
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.25);
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.12);
}

.dark .policy-container .glass-card {
  background: rgba(15, 23, 42, 0.78);
  border-color: rgba(148, 163, 184, 0.25);
  box-shadow: 0 25px 50px rgba(15, 23, 42, 0.4);
}

.policy-container .contact-box {
  border-left: 4px solid #7c3aed;
  background: rgba(124, 58, 237, 0.08);
  border-radius: 14px;
  padding: 1rem 1.25rem;
  margin: 1.25rem 0;
}

.dark .policy-container .contact-box {
  background: rgba(124, 58, 237, 0.16);
}

.policy-container .breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: #6b7280;
}

.policy-container .last-updated {
  font-size: 0.9rem;
  color: #6b7280;
}

.dark .policy-container .last-updated {
  color: rgba(203, 213, 225, 0.8);
}
