/* 
 * Stream Clean Pros - Premium Styling Sheet
 * Built with vanilla CSS, glassmorphism, responsive typography, and native scroll-driven animations.
 */

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

/* --- Design Tokens --- */
:root {
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --header-height: 90px;
  
  /* Stream Clean Pros Brand Color Palette matching #15387C Logo */
  --primary: #15387C; /* Exact Navy/Royal Blue from Logo */
  --primary-rgb: 21, 56, 124;
  --primary-hover: #0E2759;
  --accent: #0088FF; /* Clean Sky Blue Accent */
  --accent-rgb: 0, 136, 255;
  
  --bg-primary: #FFFFFF;
  --bg-secondary: #F4F7FC;
  --bg-tertiary: #E9F0FA;
  --bg-dark: #091326;
  --bg-dark-rgb: 9, 19, 38;
  
  --text-main: #0F172A;
  --text-muted: #475569;
  --text-inverse: #FFFFFF;
  
  --border-color: rgba(21, 56, 124, 0.1);
  --border-color-dark: rgba(255, 255, 255, 0.08);
  
  /* Glassmorphism */
  --glass-bg: rgba(255, 255, 255, 0.85);
  --glass-border: rgba(255, 255, 255, 0.6);
  --glass-shadow: 0 8px 32px 0 rgba(21, 56, 124, 0.06);
  
  --glass-dark-bg: rgba(9, 19, 38, 0.85);
  --glass-dark-border: rgba(255, 255, 255, 0.08);
  --glass-dark-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.4);
  
  /* Transitions */
  --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-bounce: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  
  /* Layout */
  --max-width: 1200px;
}

/* --- Dark Theme Tokens & High-Contrast Component Overrides --- */
[data-theme="dark"] {
  --bg-primary: #070D19;
  --bg-secondary: #0E182A;
  --bg-tertiary: #16253F;
  --primary: #38BDF8; /* Electric Vibrant Cyan-Blue for crisp readability on dark */
  --primary-rgb: 56, 189, 248;
  --primary-hover: #7DD3FC;
  --accent: #60A5FA; /* Soft Bright Blue Accent */
  --accent-rgb: 96, 165, 250;
  --text-main: #F8FAFC;
  --text-muted: #CBD5E1; /* Brighter slate text for WCAG AAA contrast */
  --text-inverse: #070D19;
  --border-color: rgba(56, 189, 248, 0.18);
  --glass-bg: rgba(14, 24, 42, 0.92);
  --glass-border: rgba(56, 189, 248, 0.22);
  --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.6);
}

/* Theme Toggle Button (Floating Fixed Element) */
.theme-toggle-btn {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background-color: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  transition: var(--transition-bounce);
  border: 1px solid var(--border-color);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  z-index: 9999;
  cursor: pointer;
}

.theme-toggle-btn:hover {
  background-color: var(--primary);
  color: var(--text-inverse);
  transform: scale(1.12) rotate(15deg);
  box-shadow: 0 12px 30px rgba(21, 56, 124, 0.3);
}

[data-theme="dark"] .theme-toggle-btn {
  background-color: rgba(22, 37, 63, 0.9);
  color: #38BDF8;
  border-color: rgba(56, 189, 248, 0.3);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .theme-toggle-btn:hover {
  background-color: #38BDF8;
  color: #070D19;
  box-shadow: 0 12px 30px rgba(56, 189, 248, 0.5);
}

/* Dark mode specific component overrides */
[data-theme="dark"] .badge {
  background-color: rgba(56, 189, 248, 0.12);
  color: #38BDF8;
  border-color: rgba(56, 189, 248, 0.25);
}

[data-theme="dark"] .gradient-text {
  background: linear-gradient(135deg, #38BDF8 0%, #818CF8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

[data-theme="dark"] .btn-primary {
  background: linear-gradient(135deg, #0284C7 0%, #0369A1 100%);
  color: #FFFFFF;
  box-shadow: 0 4px 20px rgba(56, 189, 248, 0.25);
}

[data-theme="dark"] .btn-primary:hover {
  background: linear-gradient(135deg, #0369A1 0%, #075985 100%);
  box-shadow: 0 6px 24px rgba(56, 189, 248, 0.4);
}

[data-theme="dark"] .btn-outline {
  border-color: rgba(56, 189, 248, 0.4);
  color: #F8FAFC;
}

[data-theme="dark"] .btn-outline:hover {
  border-color: #38BDF8;
  color: #38BDF8;
  background: rgba(56, 189, 248, 0.12);
}

[data-theme="dark"] .service-card,
[data-theme="dark"] .process-step-num,
[data-theme="dark"] .estimator-card,
[data-theme="dark"] .faq-item,
[data-theme="dark"] .review-card,
[data-theme="dark"] .floating-card {
  background: var(--bg-secondary);
  border: 1px solid rgba(56, 189, 248, 0.15);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

[data-theme="dark"] .service-card:hover {
  background: var(--bg-tertiary);
  border-color: rgba(56, 189, 248, 0.35);
  box-shadow: 0 12px 36px rgba(56, 189, 248, 0.14);
}

[data-theme="dark"] .service-card-icon {
  background-color: rgba(56, 189, 248, 0.15);
  color: #38BDF8;
}

[data-theme="dark"] .service-card-list li {
  color: #E2E8F0;
}

[data-theme="dark"] .service-card-list li i {
  color: #38BDF8;
}

[data-theme="dark"] .stat-item h3 {
  color: #38BDF8;
}

[data-theme="dark"] .stat-item p {
  color: #CBD5E1;
}

[data-theme="dark"] .process-step-num {
  background: var(--bg-tertiary);
  border-color: rgba(56, 189, 248, 0.3);
  color: #38BDF8;
}

[data-theme="dark"] .estimator-outputs {
  background: linear-gradient(135deg, #0A192F 0%, #061020 100%);
  border-left: 1px solid rgba(56, 189, 248, 0.25);
  color: #FFFFFF !important;
}

[data-theme="dark"] .estimator-outputs .price-label {
  color: #38BDF8 !important;
  opacity: 1 !important;
  font-weight: 750;
}

[data-theme="dark"] .estimator-outputs .price-value-container {
  color: #FFFFFF !important;
  text-shadow: 0 0 25px rgba(56, 189, 248, 0.45);
}

[data-theme="dark"] .estimator-outputs .estimator-features-list li {
  color: #F8FAFC !important;
}

[data-theme="dark"] .estimator-outputs .estimator-features-list li i {
  color: #38BDF8 !important;
}

[data-theme="dark"] .estimator-outputs p.disclaimer {
  color: #CBD5E1 !important;
  opacity: 0.9 !important;
}

[data-theme="dark"] .estimator-outputs .btn-primary,
[data-theme="dark"] .cta-banner .btn-primary {
  background: #38BDF8 !important;
  color: #070D19 !important;
  font-weight: 750;
  box-shadow: 0 4px 20px rgba(56, 189, 248, 0.4);
}

[data-theme="dark"] .estimator-outputs .btn-primary:hover,
[data-theme="dark"] .cta-banner .btn-primary:hover {
  background: #7DD3FC !important;
  color: #070D19 !important;
  box-shadow: 0 6px 28px rgba(125, 211, 252, 0.55);
}

[data-theme="dark"] .cta-banner {
  background: linear-gradient(135deg, #0E2042 0%, #091326 100%);
  border-top: 1px solid rgba(56, 189, 248, 0.2);
  border-bottom: 1px solid rgba(56, 189, 248, 0.2);
}

[data-theme="dark"] .cta-banner::before {
  background: radial-gradient(circle, rgba(56, 189, 248, 0.05) 0%, transparent 60%);
  opacity: 0.4;
}

[data-theme="dark"] .cta-text h2 {
  color: #FFFFFF !important;
}

[data-theme="dark"] .cta-text p {
  color: #E2E8F0 !important;
}

[data-theme="dark"] .review-content {
  color: #F1F5F9;
}

[data-theme="dark"] .reviewer-avatar {
  background-color: #38BDF8;
  color: #070D19;
}

[data-theme="dark"] .reviewer-info h4 {
  color: #F8FAFC;
}

[data-theme="dark"] .reviewer-info p {
  color: #94A3B8;
}

[data-theme="dark"] .faq-question {
  color: #F8FAFC;
}

[data-theme="dark"] .faq-answer-inner {
  color: #CBD5E1;
}

[data-theme="dark"] .faq-icon {
  background-color: rgba(56, 189, 248, 0.15);
  color: #38BDF8;
}

[data-theme="dark"] .select-input,
[data-theme="dark"] .dialog-input,
[data-theme="dark"] .lead-form-hero {
  background-color: var(--bg-secondary);
  color: var(--text-main);
  border-color: rgba(56, 189, 248, 0.2);
}

[data-theme="dark"] .lead-form-hero input {
  color: var(--text-main);
}

[data-theme="dark"] dialog {
  background: rgba(14, 24, 42, 0.96);
  border-color: rgba(56, 189, 248, 0.25);
  color: var(--text-main);
}

[data-theme="dark"] .radio-card {
  background-color: var(--bg-tertiary);
  border-color: rgba(56, 189, 248, 0.15);
}

[data-theme="dark"] .footer {
  background-color: #050A14;
  border-top-color: rgba(56, 189, 248, 0.15);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  color-scheme: light;
}

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

img, video {
  max-width: 100%;
  display: block;
  border-radius: var(--border-radius-md, 12px);
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-smooth);
}

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
  border: none;
  background: none;
  outline: none;
}

button {
  cursor: pointer;
}

/* --- Reusable Components --- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.section-padding {
  padding-top: 100px;
  padding-bottom: 100px;
}

@media (max-width: 768px) {
  .section-padding {
    padding-top: 60px;
    padding-bottom: 60px;
  }
}

section[id], header[id] {
  scroll-margin-top: calc(var(--header-height, 80px) + 16px);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  font-weight: 600;
  border-radius: 50px;
  transition: var(--transition-bounce);
  font-size: 0.95rem;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, #0052cc 100%);
  color: var(--text-inverse);
  box-shadow: 0 4px 15px rgba(2, 102, 255, 0.2);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(2, 102, 255, 0.35);
  background: linear-gradient(135deg, #0052cc 0%, #0044bb 100%);
}

.btn-primary:active {
  transform: translateY(1px);
}

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

.btn-secondary:hover {
  background-color: var(--bg-secondary);
  color: var(--primary-hover);
  transform: translateY(-2px);
}

.btn-outline {
  background-color: transparent;
  color: var(--text-main);
  border: 1px solid rgba(28, 36, 52, 0.15);
}

.btn-outline:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-2px);
}

.btn-dark {
  background-color: var(--bg-dark);
  color: var(--text-inverse);
}

.btn-dark:hover {
  background-color: #172033;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(11, 15, 25, 0.25);
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background-color: var(--bg-tertiary);
  color: var(--primary);
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border: 1px solid var(--border-color);
  margin-bottom: 16px;
}

/* Section Header */
.section-header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 60px;
}

.section-header h2 {
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}

.section-header p {
  font-size: clamp(1rem, 1.5vw, 1.15rem);
  color: var(--text-muted);
}

/* Highlight Text */
.gradient-text {
  background: linear-gradient(135deg, #15387C 0%, #0088FF 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* --- Header / Navigation --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height, 80px);
  z-index: 1000;
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  transition: height 0.3s ease, background-color 0.3s ease, box-shadow 0.3s ease;
}

/* Shrinking header scroll animation (Native CSS) */
@supports (animation-timeline: scroll()) {
  @keyframes shrink-header {
    from {
      height: var(--header-height, 80px);
    }
    to {
      height: 64px;
      box-shadow: 0 4px 25px rgba(0, 0, 0, 0.06);
    }
  }
  .navbar {
    animation: shrink-header linear both;
    animation-timeline: scroll(root);
    animation-range: 0 100px;
  }
}

/* Scroll Fallback Class via JS */
.navbar.navbar-scrolled {
  height: 64px;
  box-shadow: 0 4px 25px rgba(0, 0, 0, 0.06);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 16px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  white-space: nowrap;
  flex-shrink: 0;
  transition: var(--transition-smooth);
}

.logo:hover .brand-logo-img {
  transform: scale(1.04);
}

.brand-logo-img {
  height: 62px;
  max-height: 68px;
  width: auto;
  display: block;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(21, 56, 124, 0.12));
  transition: var(--transition-bounce);
}

[data-theme="dark"] .brand-logo-img {
  filter: brightness(0) invert(1) drop-shadow(0 2px 12px rgba(0, 136, 255, 0.4));
}

.footer-logo .brand-logo-img {
  height: 70px;
  max-height: 76px;
}

.mobile-nav-header .brand-logo-img {
  height: 52px;
  max-height: 56px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(16px, 2.2vw, 32px);
  list-style: none;
}

.nav-links a {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-main);
  opacity: 0.85;
  position: relative;
  white-space: nowrap;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--primary);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.3s ease;
}

.nav-links a:hover {
  opacity: 1;
  color: var(--primary);
}

.nav-links a:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.nav-actions .btn {
  padding: 9px 18px;
  font-size: 0.88rem;
  white-space: nowrap;
}

/* Mobile Nav Toggle & Responsive Sizing */
.menu-btn {
  display: none;
  font-size: 1.4rem;
  color: var(--text-main);
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  border-radius: 8px;
  transition: var(--transition-smooth);
}

.menu-btn:hover {
  background-color: var(--bg-tertiary);
  color: var(--primary);
}

@media (max-width: 1024px) {
  .nav-links, .nav-actions .btn-outline {
    display: none;
  }
  .nav-actions {
    gap: 8px;
  }
  .nav-actions .btn-primary {
    padding: 8px 14px;
    font-size: 0.82rem;
  }
  .menu-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background-color: var(--bg-tertiary);
  }
}

@media (max-width: 576px) {
  :root {
    --header-height: 70px;
  }
  .nav-actions .btn-primary {
    padding: 7px 11px;
    font-size: 0.78rem;
  }
  .logo {
    font-size: 1.12rem;
    gap: 8px;
  }
  .logo-icon {
    width: 28px;
    height: 28px;
    font-size: 0.95rem;
  }
}

/* --- Mobile Slide-in Drawer Overlay & Panel --- */
.mobile-nav-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(11, 15, 25, 0.5);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 1998;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-nav-overlay.active {
  opacity: 1;
  visibility: visible;
}

.mobile-nav-panel {
  position: fixed;
  top: 0;
  right: 0;
  width: 300px;
  max-width: 85vw;
  height: 100vh;
  background: var(--glass-bg);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border-left: 1px solid var(--border-color);
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.15);
  z-index: 1999;
  display: flex;
  flex-direction: column;
  padding: 24px;
  transform: translateX(100%);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-nav-panel.active {
  transform: translateX(0);
}

.mobile-nav-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
}

.mobile-nav-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: var(--bg-tertiary);
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  cursor: pointer;
  border: 1px solid var(--border-color);
  transition: var(--transition-bounce);
}

.mobile-nav-close:hover {
  background-color: var(--primary);
  color: var(--text-inverse);
}

.mobile-nav-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 32px;
}

.mobile-nav-links a {
  font-size: 1rem;
  font-weight: 650;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 12px;
  transition: var(--transition-smooth);
}

.mobile-nav-links a:hover {
  background-color: var(--bg-tertiary);
  color: var(--primary);
}

.mobile-nav-actions {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* --- Hero Section --- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: calc(var(--header-height, 80px) + 40px);
  padding-bottom: 80px;
  background: radial-gradient(circle at 80% 20%, rgba(0, 242, 254, 0.08) 0%, rgba(2, 102, 255, 0.03) 50%, transparent 100%);
  overflow: hidden;
}

@media (max-width: 768px) {
  .hero {
    padding-top: calc(var(--header-height, 70px) + 24px);
    padding-bottom: 60px;
  }
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 60px;
}

@media (max-width: 991px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 40px;
    text-align: center;
  }
}

.hero-content {
  z-index: 10;
}

.hero-content h1 {
  font-size: clamp(2.5rem, 5.5vw, 4.25rem);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.04em;
  margin-bottom: 24px;
}

.hero-content p {
  font-size: clamp(1.1rem, 1.8vw, 1.25rem);
  color: var(--text-muted);
  margin-bottom: 40px;
  max-width: 580px;
}

@media (max-width: 991px) {
  .hero-content p {
    margin-left: auto;
    margin-right: auto;
  }
}

/* Hero Lead Form Container */
.lead-form-hero {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  backdrop-filter: blur(20px);
  border-radius: 20px;
  padding: 8px;
  display: flex;
  gap: 8px;
  max-width: 520px;
}

.lead-form-hero input {
  flex-grow: 1;
  padding: 16px 24px;
  font-size: 1rem;
  background: transparent;
  color: var(--text-main);
  border-radius: 12px;
}

.lead-form-hero input::placeholder {
  color: var(--text-muted);
  opacity: 0.7;
}

@media (max-width: 520px) {
  .lead-form-hero {
    flex-direction: column;
    padding: 16px;
    border-radius: 16px;
  }
  .lead-form-hero input {
    border: 1px solid rgba(2, 102, 255, 0.15);
    background-color: var(--bg-secondary);
    margin-bottom: 8px;
  }
}

/* Hero Visual Frame */
.hero-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-image-wrapper {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(2, 102, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.7);
}

.hero-image-wrapper img {
  transform: scale(1.02);
  transition: transform 10s ease-out;
}

.hero-image-wrapper:hover img {
  transform: scale(1.08);
}

/* Floating Clean Badge */
.floating-card {
  position: absolute;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(15px);
  border: 1px solid var(--glass-border);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  border-radius: 16px;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
}

.fc-1 {
  bottom: 30px;
  left: -20px;
  animation: float 6s ease-in-out infinite;
}

.fc-2 {
  top: 30px;
  right: -20px;
  animation: float 6s ease-in-out infinite 3s;
}

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

.floating-card-icon {
  width: 40px;
  height: 40px;
  background-color: var(--bg-tertiary);
  color: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

.floating-card-info h4 {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-main);
}

.floating-card-info p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

@media (max-width: 991px) {
  .hero-visual {
    max-width: 600px;
    margin: 0 auto;
  }
  .fc-1, .fc-2 {
    display: none; /* Hide floating badges on smaller screens */
  }
}

/* --- Features / Stats Banner --- */
.stats-banner {
  background-color: var(--bg-secondary);
  color: var(--text-main);
  padding: 50px 0;
  position: relative;
  z-index: 20;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  text-align: center;
}

.stat-item h3 {
  font-size: clamp(1.6rem, 3vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--primary);
  margin-bottom: 6px;
  white-space: nowrap;
}

.stat-item p {
  font-size: 0.95rem;
  color: var(--text-muted);
}

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

/* --- Services Section --- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

@media (max-width: 991px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .services-grid {
    grid-template-columns: 1fr;
  }
}

.service-card {
  background: var(--bg-secondary);
  border: 1px solid rgba(2, 102, 255, 0.04);
  border-radius: 20px;
  padding: 40px;
  transition: var(--transition-bounce);
  position: relative;
  overflow: hidden;
}

.service-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
}

.service-card:hover {
  background-color: var(--bg-primary);
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(2, 102, 255, 0.05);
  border-color: rgba(2, 102, 255, 0.1);
}

.service-card:hover::after {
  transform: scaleX(1);
}

.service-card-icon {
  width: 60px;
  height: 60px;
  background-color: var(--bg-tertiary);
  color: var(--primary);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 28px;
  transition: var(--transition-bounce);
}

.service-card:hover .service-card-icon {
  background-color: var(--primary);
  color: var(--text-inverse);
  transform: scale(1.1) rotate(5deg);
  box-shadow: 0 8px 20px rgba(2, 102, 255, 0.2);
}

.service-card h3 {
  font-size: 1.35rem;
  font-weight: 750;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.service-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 24px;
}

.service-card-list {
  list-style: none;
  border-top: 1px solid rgba(2, 102, 255, 0.08);
  padding-top: 20px;
}

.service-card-list li {
  font-size: 0.88rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.service-card-list li i {
  color: var(--primary);
  font-size: 0.8rem;
}

/* --- How It Works --- */
.process-section {
  background-color: var(--bg-secondary);
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  position: relative;
}

@media (max-width: 991px) {
  .process-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
  }
}

@media (max-width: 576px) {
  .process-grid {
    grid-template-columns: 1fr;
  }
}

.process-step {
  text-align: center;
  position: relative;
  z-index: 2;
}

.process-step-num {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: var(--bg-primary);
  border: 2px dashed rgba(2, 102, 255, 0.2);
  color: var(--primary);
  font-size: 1.5rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  transition: var(--transition-bounce);
  position: relative;
}

.process-step:hover .process-step-num {
  border-style: solid;
  border-color: var(--primary);
  background: linear-gradient(135deg, var(--primary) 0%, #0052cc 100%);
  color: var(--text-inverse);
  transform: scale(1.1);
  box-shadow: 0 10px 25px rgba(2, 102, 255, 0.15);
}

.process-step h3 {
  font-size: 1.25rem;
  font-weight: 750;
  margin-bottom: 12px;
  letter-spacing: -0.010em;
}

.process-step p {
  color: var(--text-muted);
  font-size: 0.92rem;
  max-width: 240px;
  margin: 0 auto;
}

/* Connecting Line (Only for Desktop) */
.process-line {
  position: absolute;
  top: 35px;
  left: 10%;
  right: 10%;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(2, 102, 255, 0.1) 20%, rgba(2, 102, 255, 0.1) 80%, transparent);
  border-top: 2px dashed rgba(2, 102, 255, 0.15);
  z-index: 1;
}

@media (max-width: 991px) {
  .process-line {
    display: none;
  }
}

/* --- Interactive Before/After Slider Section --- */
.slider-section {
  background-color: var(--bg-primary);
}

.comparison-container {
  max-width: 800px;
  margin: 0 auto;
}

.before-after-slider {
  position: relative;
  width: 100%;
  aspect-ratio: 4/3;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
  user-select: none;
  border: 1px solid rgba(2, 102, 255, 0.1);
}

.before-after-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.before-after-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
}

.image-before {
  z-index: 1;
}

.image-after {
  z-index: 2;
  width: 50%; /* Initial split width */
  overflow: hidden;
}

.image-after img {
  width: 100vw;
  max-width: 800px;
}

/* Slider Handle Bar */
.slider-handle {
  position: absolute;
  top: 0;
  left: 50%; /* Initial center */
  width: 4px;
  height: 100%;
  background: var(--text-inverse);
  z-index: 3;
  cursor: ew-resize;
  transform: translateX(-50%);
  box-shadow: 0 0 10px rgba(0,0,0,0.3);
}

.slider-handle-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 48px;
  height: 48px;
  background: var(--primary);
  border: 3px solid var(--text-inverse);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-inverse);
  box-shadow: 0 4px 15px rgba(2, 102, 255, 0.35);
  font-size: 1.1rem;
}

/* Image Labels */
.slider-label {
  position: absolute;
  bottom: 20px;
  padding: 8px 16px;
  background: rgba(11, 15, 25, 0.7);
  backdrop-filter: blur(8px);
  color: var(--text-inverse);
  border-radius: 30px;
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  z-index: 3;
}

.label-before {
  left: 20px;
}

.label-after {
  right: 20px;
}

/* --- Pricing Cost Estimator Section --- */
.pricing-section {
  background-color: var(--bg-secondary);
}

.estimator-card {
  background: var(--bg-primary);
  border-radius: 24px;
  border: 1px solid rgba(2, 102, 255, 0.08);
  box-shadow: 0 15px 45px rgba(2, 102, 255, 0.03);
  max-width: 900px;
  margin: 0 auto;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
}

@media (max-width: 768px) {
  .estimator-card {
    grid-template-columns: 1fr;
  }
}

.estimator-inputs {
  padding: 40px;
}

.estimator-outputs {
  background: linear-gradient(135deg, #15387C 0%, #1E40AF 100%);
  color: var(--text-inverse);
  padding: 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  position: relative;
}

.estimator-outputs .btn-primary {
  background: var(--text-inverse);
  color: var(--primary);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.estimator-outputs .btn-primary:hover {
  background: var(--bg-secondary);
  color: var(--primary-hover);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.estimator-outputs .price-value-container {
  color: var(--text-inverse);
}

.estimator-inputs h3 {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 24px;
  letter-spacing: -0.02em;
}

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

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 10px;
  font-size: 0.95rem;
  color: var(--text-main);
}

.service-selector-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  background-color: var(--bg-tertiary);
  padding: 6px;
  border-radius: 14px;
  margin-bottom: 20px;
}

.svc-tab {
  padding: 12px 10px;
  font-size: 0.88rem;
  font-weight: 700;
  border-radius: 10px;
  text-align: center;
  transition: var(--transition-smooth);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  border: 1px solid transparent;
}

.svc-tab i {
  width: 16px;
  height: 16px;
}

.svc-tab.active {
  background-color: var(--primary);
  color: var(--text-inverse);
  box-shadow: 0 4px 14px rgba(0, 102, 255, 0.25);
}

[data-theme="dark"] .svc-tab {
  color: var(--text-muted);
}

[data-theme="dark"] .svc-tab.active {
  background-color: var(--primary);
  color: var(--text-inverse);
}

.calculator-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  background-color: var(--bg-tertiary);
  padding: 5px;
  border-radius: 12px;
}

.calc-tab {
  padding: 10px;
  font-weight: 600;
  border-radius: 8px;
  text-align: center;
  transition: var(--transition-smooth);
  cursor: pointer;
}

.calc-tab.active {
  background-color: var(--bg-primary);
  color: var(--primary);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.03);
}

.included-feature-badge {
  background-color: rgba(0, 102, 255, 0.08);
  color: var(--primary);
  padding: 12px 16px;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
}

.included-feature-badge.warning-badge {
  background-color: rgba(237, 137, 54, 0.12);
  color: #DD6B20;
}

[data-theme="dark"] .included-feature-badge {
  background-color: rgba(0, 153, 255, 0.15);
  color: #60A5FA;
}

[data-theme="dark"] .included-feature-badge.warning-badge {
  background-color: rgba(237, 137, 54, 0.2);
  color: #FBD38D;
}

.estimator-features-list {
  list-style: none;
  margin: 15px 0 5px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.estimator-features-list li {
  font-size: 0.88rem;
  display: flex;
  align-items: center;
  gap: 10px;
  opacity: 0.95;
}

.estimator-features-list li i {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.range-slider-wrapper {
  display: flex;
  align-items: center;
  gap: 16px;
}

.range-slider {
  flex-grow: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 6px;
  border-radius: 5px;
  background: var(--bg-tertiary);
  outline: none;
}

.range-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--primary);
  cursor: pointer;
  transition: transform 0.2s ease;
  box-shadow: 0 2px 6px rgba(2, 102, 255, 0.3);
}

.range-slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
}

.range-value {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary);
  min-width: 60px;
  text-align: right;
}

.select-input {
  width: 100%;
  padding: 14px 20px;
  border-radius: 12px;
  background-color: var(--bg-tertiary);
  border: 1px solid transparent;
  font-weight: 600;
  color: var(--text-main);
  transition: var(--transition-smooth);
}

.select-input:focus {
  border-color: var(--primary);
  background-color: var(--bg-primary);
  box-shadow: 0 0 0 4px rgba(2, 102, 255, 0.1);
}

/* Pricing Outputs styles */
.price-display {
  margin: 20px 0;
}

.price-label {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 700;
}

.price-value-container {
  font-size: clamp(3rem, 5vw, 4.5rem);
  font-weight: 900;
  line-height: 1;
  color: #FFFFFF !important;
  margin-top: 6px;
  display: flex;
  align-items: baseline;
  justify-content: center;
  transition: var(--transition-bounce);
  text-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.price-value-container span {
  font-size: 1.5rem;
  font-weight: 700;
  color: #FFFFFF !important;
  margin-left: 4px;
}

.estimator-outputs p.disclaimer {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.85);
  margin-top: auto;
  line-height: 1.45;
}

/* --- Testimonials / Reviews --- */
.reviews-section {
  background-color: var(--bg-primary);
}

.reviews-carousel {
  position: relative;
  overflow: hidden;
  max-width: 900px;
  margin: 0 auto;
}

.carousel-track {
  display: flex;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.review-slide {
  flex: 0 0 100%;
  min-width: 100%;
  padding: 20px;
}

.review-card {
  background: var(--bg-secondary);
  border-radius: 24px;
  padding: 48px;
  position: relative;
  border: 1px solid rgba(2, 102, 255, 0.05);
}

.review-card::before {
  content: '“';
  position: absolute;
  top: 20px;
  left: 30px;
  font-size: 6rem;
  line-height: 1;
  color: var(--primary);
  opacity: 0.08;
  font-family: serif;
}

.star-rating {
  color: #FFB000;
  font-size: 1.25rem;
  margin-bottom: 24px;
}

.review-content {
  font-size: clamp(1.1rem, 2.2vw, 1.35rem);
  font-weight: 500;
  line-height: 1.5;
  color: var(--text-main);
  letter-spacing: -0.01em;
  margin-bottom: 32px;
}

.reviewer-meta {
  display: flex;
  align-items: center;
  gap: 16px;
}

.reviewer-avatar {
  width: 48px;
  height: 48px;
  min-width: 48px;
  min-height: 48px;
  border-radius: 50%;
  background-color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-inverse);
  font-weight: 700;
  flex-shrink: 0;
}

.reviewer-info h4 {
  font-size: 1rem;
  font-weight: 750;
  color: var(--text-main);
}

.reviewer-info p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Carousel controls */
.carousel-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 30px;
}

.carousel-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background-color: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  transition: var(--transition-bounce);
}

.carousel-btn:hover {
  background-color: var(--primary);
  color: var(--text-inverse);
  transform: scale(1.1);
  box-shadow: 0 4px 15px rgba(2, 102, 255, 0.2);
}

/* --- FAQ Section --- */
.faq-section {
  background-color: var(--bg-secondary);
}

.faq-grid {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  background: var(--bg-primary);
  border-radius: 16px;
  margin-bottom: 16px;
  border: 1px solid rgba(2, 102, 255, 0.05);
  overflow: hidden;
  transition: var(--transition-smooth);
}

.faq-item:hover {
  box-shadow: 0 8px 24px rgba(2, 102, 255, 0.03);
  border-color: rgba(2, 102, 255, 0.15);
}

.faq-question {
  width: 100%;
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-main);
  text-align: left;
}

.faq-icon {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background-color: var(--bg-tertiary);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  transition: var(--transition-bounce);
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
  background-color: var(--primary);
  color: var(--text-inverse);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.faq-answer-inner {
  padding: 0 24px 24px;
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* --- Sticky Bottom CTA Bar --- */
.cta-banner {
  background: linear-gradient(135deg, #15387C 0%, #1E40AF 100%);
  color: var(--text-inverse);
  position: relative;
  overflow: hidden;
}

.cta-banner::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.08) 0%, transparent 70%);
  z-index: 1;
  pointer-events: none;
}

.cta-text h2 {
  color: #FFFFFF !important;
  font-size: clamp(2rem, 3.5vw, 2.75rem);
  font-weight: 850;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
  line-height: 1.15;
}

.cta-text p {
  color: rgba(255, 255, 255, 0.9) !important;
  font-size: 1.05rem;
  max-width: 580px;
}

.cta-banner .btn-primary {
  background: #FFFFFF;
  color: var(--primary);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.cta-banner .btn-primary:hover {
  background: #F4F7FC;
  color: var(--primary-hover);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.25);
}

.cta-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  z-index: 2;
  gap: 40px;
}

@media (max-width: 900px) {
  .cta-container {
    flex-direction: column;
    text-align: center;
  }
}

/* --- Footer --- */
.footer {
  background-color: var(--bg-secondary);
  color: var(--text-muted);
  padding-top: 80px;
  padding-bottom: 40px;
  border-top: 1px solid var(--border-color);
}

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

@media (max-width: 991px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 576px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

.footer-col h4 {
  color: var(--text-main);
  font-size: 0.95rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 24px;
}

.footer-logo {
  margin-bottom: 20px;
}

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

.footer-col p {
  font-size: 0.92rem;
  line-height: 1.6;
}

.social-links {
  display: flex;
  gap: 12px;
  margin-top: 24px;
}

.social-btn {
  width: 40px;
  height: 40px;
  background-color: var(--bg-tertiary);
  color: var(--text-main);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  transition: var(--transition-bounce);
}

.social-btn:hover {
  background-color: var(--primary);
  color: var(--text-inverse);
  transform: translateY(-4px);
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 12px;
}

.footer-links a {
  font-size: 0.92rem;
}

.footer-links a:hover {
  color: var(--primary);
  padding-left: 4px;
}

.contact-info-list {
  list-style: none;
}

.contact-info-list li {
  margin-bottom: 16px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.92rem;
}

.contact-info-list li i {
  color: var(--primary);
  font-size: 1.1rem;
  margin-top: 3px;
}

/* Footer Bottom */
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border-color);
  padding-top: 30px;
  font-size: 0.85rem;
}

.footer-bottom-links {
  display: flex;
  gap: 24px;
}

.footer-bottom-links a {
  color: var(--text-muted);
}

.footer-bottom-links a:hover {
  color: var(--primary);
}

@media (max-width: 768px) {
  .footer-bottom {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }

  .estimator-inputs {
    padding: 28px 18px;
  }

  .estimator-outputs {
    padding: 32px 20px;
  }

  .review-card {
    padding: 32px 24px;
  }
}

@media (max-width: 576px) {
  .estimator-inputs {
    padding: 22px 12px;
  }

  .service-selector-tabs {
    gap: 4px;
    padding: 4px;
  }

  .svc-tab {
    padding: 10px 4px;
    font-size: 0.78rem;
    gap: 4px;
    line-height: 1.2;
    text-align: center;
  }

  .svc-tab i {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
  }

  .review-slide {
    padding: 10px 0;
  }

  .review-card {
    padding: 28px 18px;
  }
}

@media (max-width: 380px) {
  .svc-tab {
    flex-direction: column;
    padding: 8px 2px;
    font-size: 0.74rem;
    gap: 3px;
  }
}

/* --- Native Dialog Modal (<dialog>) --- */
/* --- Native Dialog Modal (<dialog>) --- */
dialog {
  box-sizing: border-box;
  margin: auto;
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  background: var(--glass-bg);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(25px);
  max-width: 580px;
  width: calc(100% - 32px);
  max-height: min(640px, calc(100vh - 32px));
  max-height: min(640px, calc(100dvh - 32px));
  padding: 32px;
  overflow: hidden;
  transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  opacity: 0;
  transform: scale(0.9) translateY(20px);
}

/* Open Animation */
dialog[open] {
  opacity: 1;
  transform: scale(1) translateY(0);
  display: flex;
  flex-direction: column;
}

/* Backdrop Blur */
dialog::backdrop {
  background: rgba(11, 15, 25, 0.4);
  backdrop-filter: blur(12px);
  transition: opacity 0.3s ease;
  opacity: 0;
}

dialog[open]::backdrop {
  opacity: 1;
}

.dialog-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  flex-shrink: 0;
}

.dialog-header h3 {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.dialog-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: var(--bg-tertiary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: var(--transition-bounce);
  cursor: pointer;
}

.dialog-close:hover {
  background-color: #E2E8F0;
  color: var(--text-main);
  transform: scale(1.1) rotate(90deg);
}

.dialog-progress {
  height: 4px;
  background-color: var(--bg-tertiary);
  border-radius: 2px;
  margin-bottom: 20px;
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}

.dialog-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  width: 33%;
  transition: width 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

#lead-booking-form {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

/* Dialog Form Wizard Steps */
.dialog-step {
  display: none;
}

.dialog-step.active {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding-right: 4px;
  animation: slide-in-dialog-step 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.dialog-step::-webkit-scrollbar {
  width: 5px;
}
.dialog-step::-webkit-scrollbar-track {
  background: transparent;
}
.dialog-step::-webkit-scrollbar-thumb {
  background: rgba(2, 102, 255, 0.2);
  border-radius: 4px;
}

.dialog-step-label {
  font-weight: 700;
  margin-bottom: 16px;
  display: block;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.dialog-step-sublabel {
  font-weight: 400;
  font-size: 0.85rem;
  color: var(--text-muted);
}

@keyframes slide-in-dialog-step {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

.form-inputs-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-bottom: 20px;
}

.form-inputs-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 20px;
}

@media (max-width: 500px) {
  .form-inputs-grid-2 {
    grid-template-columns: 1fr;
  }
}

.dialog-input {
  width: 100%;
  padding: 14px 20px;
  border-radius: 12px;
  background-color: var(--bg-secondary);
  border: 1px solid rgba(2, 102, 255, 0.08);
  font-weight: 500;
  transition: var(--transition-smooth);
}

.dialog-input::placeholder {
  color: var(--text-muted);
  opacity: 0.6;
}

.dialog-input:focus {
  border-color: var(--primary);
  background-color: var(--bg-primary);
  box-shadow: 0 0 0 4px rgba(2, 102, 255, 0.1);
}

.dialog-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid rgba(2, 102, 255, 0.08);
  flex-shrink: 0;
}

/* Radio Cards inside dialog */
.radio-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}

.radio-card {
  border: 2px solid rgba(2, 102, 255, 0.06);
  background-color: var(--bg-secondary);
  border-radius: 16px;
  padding: 20px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition-smooth);
  position: relative;
}

.radio-card input {
  position: absolute;
  opacity: 0;
}

.radio-card-icon {
  font-size: 1.8rem;
  color: var(--text-muted);
  margin-bottom: 8px;
  transition: var(--transition-bounce);
}

.radio-card h4 {
  font-size: 1rem;
  font-weight: 750;
  margin-bottom: 4px;
}

.radio-card p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.radio-card:hover {
  border-color: rgba(2, 102, 255, 0.15);
  background-color: var(--bg-primary);
}

.radio-card input:checked + .radio-card-content .radio-card-icon {
  color: var(--primary);
  transform: scale(1.1);
}

.radio-card.selected {
  border-color: var(--primary);
  background-color: var(--bg-primary);
  box-shadow: 0 8px 24px rgba(2, 102, 255, 0.06);
}

/* --- Mobile Specific Modal Enhancements (e.g., iPhone 14 Pro) --- */
@media (max-width: 576px) {
  dialog {
    width: calc(100% - 24px);
    max-height: calc(100vh - 24px);
    max-height: calc(100dvh - 24px);
    padding: 20px 16px;
    border-radius: 20px;
  }

  .dialog-header {
    margin-bottom: 12px;
  }

  .dialog-header h3 {
    font-size: 1.35rem;
  }

  .dialog-progress {
    margin-bottom: 14px;
  }

  .dialog-step-label {
    font-size: 0.98rem;
    margin-bottom: 12px;
  }

  .dialog-step-sublabel {
    font-size: 0.78rem;
  }

  .radio-cards-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-bottom: 16px;
  }

  .radio-card {
    padding: 12px 6px;
    border-radius: 12px;
  }

  .radio-card-icon {
    font-size: 1.35rem;
    margin-bottom: 4px;
  }

  .radio-card h4 {
    font-size: 0.8rem;
    line-height: 1.15;
    margin-bottom: 2px;
  }

  .radio-card p {
    font-size: 0.68rem;
    line-height: 1.15;
  }

  .form-inputs-grid,
  .form-inputs-grid-2 {
    gap: 12px;
    margin-bottom: 16px;
  }

  .dialog-input,
  .select-input {
    padding: 12px 14px;
    font-size: 0.92rem;
  }

  .dialog-footer {
    margin-top: 12px;
    padding-top: 12px;
    gap: 8px;
  }

  .dialog-footer .btn {
    padding: 12px 16px;
    font-size: 0.88rem;
  }
}

@media (max-height: 660px) {
  dialog {
    max-height: calc(100vh - 16px);
    max-height: calc(100dvh - 16px);
    padding: 16px 14px;
  }

  .dialog-header {
    margin-bottom: 10px;
  }

  .dialog-progress {
    margin-bottom: 12px;
  }

  .radio-cards-grid {
    margin-bottom: 12px;
  }

  .dialog-footer {
    margin-top: 10px;
    padding-top: 10px;
  }
}

/* Success State Screen */
.success-screen {
  text-align: center;
  padding: 30px 10px;
}

.success-icon {
  width: 80px;
  height: 80px;
  background-color: #DEF7EC;
  color: #0E9F6E;
  font-size: 2.5rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  animation: float 6s ease-in-out infinite;
}

.success-screen h3 {
  font-size: 1.6rem;
  font-weight: 800;
  margin-bottom: 12px;
}

.success-screen p {
  color: var(--text-muted);
  margin-bottom: 30px;
}

/* --- Scroll entry animations (Universal Reveal via Observer) --- */
.scroll-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.scroll-reveal.reveal-active {
  opacity: 1;
  transform: translateY(0);
}

.scroll-reveal-scale {
  opacity: 0;
  transform: scale(0.95);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.scroll-reveal-scale.reveal-active {
  opacity: 1;
  transform: scale(1);
}
