/* ============================================
   VelanSync — Custom Styles
   ============================================ */

/* --- CSS Custom Properties (Design Tokens) --- */
:root {
  --color-primary: #2563eb;
  --color-primary-dark: #1e40af;
  --color-primary-light: #60a5fa;
  --color-secondary: #22c55e;
  --color-accent: #7e22ce;
  --color-surface: #f8fafc;
  --color-text: #0f172a;
  --color-text-muted: #64748b;
  --color-border: #e2e8f0;
  --gradient-primary: linear-gradient(135deg, #2563eb 0%, #7e22ce 100%);
  --gradient-hero: linear-gradient(135deg, #0f172a 0%, #1e3a8a 40%, #2563eb 100%);
  --gradient-cta: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  --shadow-soft: 0 2px 15px -3px rgba(0,0,0,0.07), 0 10px 20px -2px rgba(0,0,0,0.04);
  --shadow-card: 0 4px 24px -4px rgba(0,0,0,0.08);
  --shadow-elevated: 0 20px 60px -15px rgba(0,0,0,0.12);
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-2xl: 2rem;
  --transition-base: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Base --- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--color-text);
  background-color: #ffffff;
  line-height: 1.6;
  overflow-x: hidden;
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Poppins', 'Inter', sans-serif;
  font-weight: 700;
  line-height: 1.2;
}

/* --- Scrollbar --- */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
  background: #94a3b8;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #64748b;
}

/* --- Selection --- */
::selection {
  background-color: rgba(37, 99, 235, 0.15);
  color: #1e3a8a;
}

/* --- Glass Card --- */
.glass-card {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: var(--shadow-card);
}

.glass-card-dark {
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

/* --- Gradient Text --- */
.gradient-text {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- Buttons --- */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 2rem;
  background: var(--gradient-cta);
  color: #ffffff;
  font-weight: 600;
  font-size: 0.9375rem;
  border-radius: 0.75rem;
  border: none;
  cursor: pointer;
  transition: var(--transition-base);
  text-decoration: none;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 15px -3px rgba(37, 99, 235, 0.4);
}

.btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.2) 0%, transparent 50%);
  opacity: 0;
  transition: var(--transition-base);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px -5px rgba(37, 99, 235, 0.5);
}

.btn-primary:hover::before {
  opacity: 1;
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 2rem;
  background: transparent;
  color: var(--color-primary);
  font-weight: 600;
  font-size: 0.9375rem;
  border-radius: 0.75rem;
  border: 2px solid var(--color-primary);
  cursor: pointer;
  transition: var(--transition-base);
  text-decoration: none;
}

.btn-secondary:hover {
  background: var(--color-primary);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px -5px rgba(37, 99, 235, 0.3);
}

.btn-white {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 2rem;
  background: #ffffff;
  color: var(--color-primary);
  font-weight: 600;
  font-size: 0.9375rem;
  border-radius: 0.75rem;
  border: 2px solid rgba(255,255,255,0.3);
  cursor: pointer;
  transition: var(--transition-base);
  text-decoration: none;
}

.btn-white:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px -5px rgba(0, 0, 0, 0.15);
}

/* --- Navbar --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  transition: var(--transition-smooth);
  padding: 0.5rem 0;
  background: #ffffff;
  border-bottom: 1px solid rgba(226, 232, 240, 0.6);
  box-shadow: 0 1px 10px rgba(0, 0, 0, 0.04);
}

/* Nav links always dark */
.navbar .nav-link {
  color: var(--color-text) !important;
}

.navbar .nav-link:hover {
  color: var(--color-primary) !important;
}

/* Scrolled state — slightly more shadow */
.navbar.scrolled {
  box-shadow: 0 1px 20px rgba(0, 0, 0, 0.06);
}

/* Active nav link — current page */
.nav-link.nav-active {
  color: var(--color-primary) !important;
  position: relative;
}

.nav-link.nav-active::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 60%;
  height: 2px;
  background: var(--color-primary);
  border-radius: 1px;
}

/* Logo sizing */
.navbar-logo {
  height: 5rem; /* 80px — desktop */
  width: auto;
}

@media (max-width: 768px) {
  .navbar-logo {
    height: 3.5rem; /* 56px — mobile */
  }
}

/* Push content below fixed navbar */
.navbar-spacer {
  padding-top: 5.5rem; /* matches navbar height */
}

/* Always show colored logo, hide white version */
.navbar-logo-light {
  display: none !important;
}

.navbar-logo-dark {
  display: block !important;
}

/* Dropdown */
.nav-dropdown {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  min-width: 800px;
  background: #ffffff;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-elevated);
  border: 1px solid var(--color-border);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: var(--transition-base);
  padding: 1.5rem;
  z-index: 100;
}

.nav-dropdown.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

.dropdown-category-title {
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-primary);
  margin-bottom: 0.5rem;
  padding-bottom: 0.375rem;
  border-bottom: 2px solid rgba(37, 99, 235, 0.1);
}

.dropdown-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 0.5rem;
  color: var(--color-text);
  text-decoration: none;
  font-size: 0.8125rem;
  border-radius: 0.5rem;
  transition: var(--transition-base);
  font-weight: 450;
}

.dropdown-link:hover {
  background: rgba(37, 99, 235, 0.06);
  color: var(--color-primary);
  transform: translateX(4px);
}

.dropdown-link svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  color: var(--color-primary);
  opacity: 0.6;
}

/* --- Hero Section --- */
/* --- Hero Section (Video Background) --- */
#hero video {
  transition: opacity 1s ease;
}

#hero video.loaded {
  opacity: 1;
}

/* Subtle slow zoom on the video for cinematic feel */
@keyframes heroZoom {
  0% { transform: scale(1.05); }
  50% { transform: scale(1.12); }
  100% { transform: scale(1.05); }
}

#hero video {
  animation: heroZoom 25s ease-in-out infinite;
}

/* On mobile, disable zoom to save GPU */
@media (max-width: 768px) {
  #hero video {
    animation: none;
    transform: scale(1.05);
  }
}

/* Legacy .hero-section support (other pages still use it) */
.hero-section {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: var(--gradient-hero);
}

.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(96, 165, 250, 0.15) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(126, 34, 206, 0.1) 0%, transparent 50%),
    radial-gradient(ellipse at 60% 80%, rgba(34, 197, 94, 0.08) 0%, transparent 50%);
  z-index: 1;
}

/* .hero-grid-bg — replaced grid with subtle radial glow */
.hero-grid-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(59, 130, 246, 0.12) 0%, transparent 55%),
    radial-gradient(ellipse at 70% 60%, rgba(126, 34, 206, 0.08) 0%, transparent 50%);
  z-index: 1;
}

.hero-float-card {
  position: absolute;
  border-radius: var(--radius-xl);
  padding: 1rem 1.25rem;
  font-size: 0.8125rem;
  font-weight: 600;
  z-index: 2;
  animation: float 6s ease-in-out infinite;
}

/* --- Service Cards --- */
.service-card {
  position: relative;
  background: #ffffff;
  border-radius: var(--radius-xl);
  padding: 2rem;
  transition: var(--transition-smooth);
  border: 1px solid rgba(226, 232, 240, 0.8);
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gradient-primary);
  opacity: 0;
  transition: var(--transition-base);
}

.service-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-elevated);
  border-color: transparent;
}

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

.service-card-icon {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  transition: var(--transition-base);
}

.service-card:hover .service-card-icon {
  transform: scale(1.1);
}

/* --- Stats Section --- */
.stat-card {
  text-align: center;
  padding: 2rem;
}

.stat-number {
  font-family: 'Poppins', sans-serif;
  font-size: 3rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 0.5rem;
}

/* --- Section styling --- */
.section-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 1rem;
  background: rgba(37, 99, 235, 0.08);
  color: var(--color-primary);
  font-size: 0.8125rem;
  font-weight: 600;
  border-radius: 50px;
  margin-bottom: 1rem;
}

.section-title {
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1rem;
}

.section-subtitle {
  font-size: 1.125rem;
  color: var(--color-text-muted);
  max-width: 600px;
  line-height: 1.7;
}

/* --- Feature Grid --- */
.feature-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* --- Specialty Cards (Illustrated Icon Version) --- */
.spec-card {
  background: #ffffff;
  border-radius: 1.25rem;
  padding: 1.5rem 1rem 1.25rem;
  text-align: center;
  border: 1px solid rgba(226, 232, 240, 0.6);
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: default;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.625rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
  position: relative;
}

.spec-card:hover {
  border-color: rgba(59, 130, 246, 0.25);
  box-shadow: 0 16px 40px -10px rgba(59, 130, 246, 0.15), 0 4px 12px -2px rgba(0, 0, 0, 0.04);
  transform: translateY(-6px);
}

/* Illustrated icon container */
.spec-icon-illustrated {
  width: 5rem;
  height: 5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.spec-icon-illustrated svg {
  width: 100%;
  height: 100%;
}

/* Image-based specialty icon (for real medical illustrations) */
.spec-icon-img {
  width: 5rem;
  height: 5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.spec-icon-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 0.75rem;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.spec-card:hover .spec-icon-img {
  transform: scale(1.12);
}

.spec-card:hover .spec-icon-img img {
  filter: drop-shadow(0 4px 12px rgba(37, 99, 235, 0.2));
}

/* Hover: background circle glows */
.spec-card:hover .spec-icon-illustrated {
  transform: scale(1.1);
}

.spec-card:hover .spec-bg-circle {
  fill: #DBEAFE;
  transition: fill 0.3s ease;
}

/* Lucide-based fallback icon container */
.spec-icon {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 1rem;
  background: #dbeafe;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #2563eb;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.spec-icon svg {
  stroke-width: 2.2;
}

.spec-card:hover .spec-icon {
  background: #2563eb;
  color: #ffffff;
  transform: scale(1.08);
  box-shadow: 0 4px 14px -2px rgba(37, 99, 235, 0.4);
}

.spec-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #1e293b;
  line-height: 1.3;
  transition: color 0.3s ease;
}

.spec-card:hover .spec-label {
  color: #2563eb;
}

/* Bottom accent line on hover */
.spec-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 3px;
  background: linear-gradient(90deg, #2563eb, #7c3aed);
  border-radius: 3px 3px 0 0;
  transition: width 0.3s ease;
}

.spec-card:hover::after {
  width: 40%;
}

/* Legacy fallback */
.specialty-card {
  background: #ffffff;
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  text-align: center;
  border: 1px solid var(--color-border);
  transition: var(--transition-base);
  cursor: default;
}

.specialty-card:hover {
  border-color: var(--color-primary);
  box-shadow: 0 4px 20px -4px rgba(37, 99, 235, 0.15);
  transform: translateY(-4px);
}

/* --- CTA Section --- */
.cta-section {
  position: relative;
  overflow: hidden;
  background: var(--gradient-hero);
}

.cta-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 50%, rgba(96, 165, 250, 0.2) 0%, transparent 50%),
    radial-gradient(ellipse at 70% 30%, rgba(126, 34, 206, 0.15) 0%, transparent 50%);
}

/* --- Footer --- */
.footer {
  background: var(--color-text);
  color: #94a3b8;
}

.footer a {
  color: #94a3b8;
  text-decoration: none;
  transition: var(--transition-base);
}

.footer a:hover {
  color: #ffffff;
}

/* --- Form Styling --- */
.form-input {
  width: 100%;
  padding: 0.875rem 1rem;
  border: 1.5px solid var(--color-border);
  border-radius: 0.75rem;
  font-size: 0.9375rem;
  font-family: 'Inter', sans-serif;
  transition: var(--transition-base);
  background: #ffffff;
  color: var(--color-text);
}

.form-input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.form-input::placeholder {
  color: #94a3b8;
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 0.375rem;
}

/* --- Blog Cards --- */
.blog-card {
  background: #ffffff;
  border-radius: var(--radius-xl);
  overflow: hidden;
  border: 1px solid var(--color-border);
  transition: var(--transition-smooth);
}

.blog-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-elevated);
  border-color: transparent;
}

.blog-card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  background: linear-gradient(135deg, #dbeafe 0%, #e9d5ff 100%);
}

/* --- Testimonial --- */
.testimonial-card {
  background: #ffffff;
  border-radius: var(--radius-xl);
  padding: 2rem;
  border: 1px solid var(--color-border);
  position: relative;
}

.testimonial-card::before {
  content: '"';
  position: absolute;
  top: -0.25rem;
  left: 1.5rem;
  font-size: 5rem;
  font-family: Georgia, serif;
  color: rgba(37, 99, 235, 0.1);
  line-height: 1;
}

/* --- Loading / Skeleton --- */
.skeleton {
  background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 0.5rem;
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* --- Page Header --- */
.page-header {
  position: relative;
  padding: 10rem 0 5rem;
  background: #0a0f2c;
  overflow: hidden;
}

/* Background image — covers entire header */
.page-header-bg {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  z-index: 0;
}

/* Dark overlay for readability — separate element placed after bg in HTML */
.page-header-overlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(135deg, rgba(10,15,44,0.72) 0%, rgba(15,27,77,0.65) 50%, rgba(26,17,69,0.7) 100%);
  z-index: 1;
}

/* Subtle glow */
.page-header::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(96, 165, 250, 0.1) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(126, 34, 206, 0.08) 0%, transparent 50%);
  z-index: 2;
  pointer-events: none;
}

/* Hero-grid-bg glow layer */
.page-header .hero-grid-bg {
  z-index: 2;
}

/* --- Mobile Menu --- */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  opacity: 0;
  visibility: hidden;
  transition: var(--transition-base);
}

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

.mobile-menu-panel {
  position: absolute;
  top: 0;
  right: 0;
  width: 85%;
  max-width: 400px;
  height: 100%;
  background: #ffffff;
  transform: translateX(100%);
  transition: var(--transition-smooth);
  overflow-y: auto;
  padding: 1.5rem;
}

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

/* --- Process Steps --- */
.process-step {
  position: relative;
  padding-left: 4rem;
}

.process-step::before {
  content: attr(data-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  background: var(--gradient-primary);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1rem;
}

/* --- Responsive --- */
@media (max-width: 1024px) {
  .section-title {
    font-size: 2rem;
  }
  .nav-dropdown {
    min-width: 600px;
  }
}

@media (max-width: 768px) {
  .section-title {
    font-size: 1.75rem;
  }
  .stat-number {
    font-size: 2.25rem;
  }
  .hero-float-card {
    display: none;
  }
}

@media (max-width: 640px) {
  .section-title {
    font-size: 1.5rem;
  }
}

/* --- Marquee --- */
.marquee-container {
  overflow: hidden;
  white-space: nowrap;
}

.marquee-content {
  display: inline-flex;
  animation: marquee 30s linear infinite;
}

@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* --- Cookie Banner --- */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  transform: translateY(100%);
  transition: var(--transition-smooth);
}

.cookie-banner.show {
  transform: translateY(0);
}

/* --- Back to Top --- */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  background: var(--gradient-cta);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 900;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: var(--transition-base);
  border: none;
  box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(37, 99, 235, 0.4);
}

/* --- WhatsApp Floating Button --- */
.whatsapp-btn {
  position: fixed;
  bottom: 6.5rem;
  right: 2rem;
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 50%;
  background: #25D366;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 950;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.35);
  transition: var(--transition-base);
  text-decoration: none;
}

.whatsapp-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 28px rgba(37, 211, 102, 0.5);
}

/* --- Chatbot --- */
.chatbot-container {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 960;
}

.chatbot-toggle {
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 50%;
  background: var(--gradient-cta);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(37, 99, 235, 0.35);
  transition: var(--transition-base);
  position: absolute;
  bottom: 0;
  right: 0;
}

.chatbot-toggle:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 28px rgba(37, 99, 235, 0.5);
}

.chatbot-toggle.active {
  background: #ef4444;
  box-shadow: 0 4px 20px rgba(239, 68, 68, 0.3);
}

.chatbot-window {
  position: absolute;
  bottom: 4.5rem;
  right: 0;
  width: 360px;
  max-height: 520px;
  background: #ffffff;
  border-radius: 1.25rem;
  box-shadow: 0 20px 60px -10px rgba(0, 0, 0, 0.18);
  border: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

@media (max-width: 420px) {
  .chatbot-window {
    width: calc(100vw - 2rem);
    right: -0.5rem;
  }
}

.chatbot-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--color-border);
  background: var(--color-surface);
}

.chatbot-messages {
  flex: 1;
  overflow-y: auto;
  padding: 1rem 1.25rem;
  max-height: 280px;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.chatbot-msg {
  max-width: 90%;
  padding: 0.75rem 1rem;
  border-radius: 1rem;
  font-size: 0.8125rem;
  line-height: 1.5;
}

.chatbot-msg.bot {
  background: var(--color-surface);
  color: var(--color-text);
  border-bottom-left-radius: 0.25rem;
  align-self: flex-start;
}

.chatbot-msg.user {
  background: var(--gradient-cta);
  color: #ffffff;
  border-bottom-right-radius: 0.25rem;
  align-self: flex-end;
}

.chatbot-questions {
  padding: 0.75rem 1rem;
  border-top: 1px solid var(--color-border);
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  max-height: 140px;
  overflow-y: auto;
}

.chatbot-q-btn {
  display: inline-block;
  padding: 0.375rem 0.75rem;
  font-size: 0.6875rem;
  font-weight: 500;
  color: var(--color-primary);
  background: rgba(37, 99, 235, 0.06);
  border: 1px solid rgba(37, 99, 235, 0.12);
  border-radius: 50px;
  cursor: pointer;
  transition: var(--transition-base);
  white-space: nowrap;
  font-family: 'Inter', sans-serif;
}

.chatbot-q-btn:hover {
  background: rgba(37, 99, 235, 0.12);
  border-color: rgba(37, 99, 235, 0.25);
}

/* --- Chatbot Input Area --- */
.chatbot-input-area {
  padding: 0.75rem 1rem;
  border-top: 1px solid var(--color-border);
  background: #ffffff;
}

.chatbot-input {
  flex: 1;
  padding: 0.625rem 0.875rem;
  border: 1.5px solid var(--color-border);
  border-radius: 0.75rem;
  font-size: 0.8125rem;
  font-family: 'Inter', sans-serif;
  color: var(--color-text);
  background: var(--color-surface);
  transition: var(--transition-base);
  outline: none;
  width: 100%;
}

.chatbot-input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.08);
}

.chatbot-input::placeholder {
  color: #94a3b8;
}

.chatbot-send-btn {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.75rem;
  background: var(--gradient-cta);
  color: #ffffff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: var(--transition-base);
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
}

.chatbot-send-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}

.chatbot-send-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
}

/* Typing indicator */
.chatbot-typing {
  display: flex;
  gap: 4px;
  padding: 0.75rem 1rem;
  align-self: flex-start;
}

.chatbot-typing span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #94a3b8;
  animation: typingBounce 1.4s infinite ease-in-out;
}

.chatbot-typing span:nth-child(2) { animation-delay: 0.2s; }
.chatbot-typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typingBounce {
  0%, 80%, 100% { transform: translateY(0); opacity: 0.4; }
  40% { transform: translateY(-6px); opacity: 1; }
}

/* Contact links inside bot messages */
.chatbot-msg a {
  color: var(--color-primary);
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition-base);
}

.chatbot-msg a:hover {
  text-decoration: underline;
}

/* Adjust back-to-top position when chatbot is present */
.back-to-top {
  bottom: 6.5rem;
  right: 5.5rem;
}

/* Adjust WhatsApp when chatbot present */
.whatsapp-btn {
  bottom: 2rem;
  right: 5.5rem;
}

/* ============================================
   Trust Bar (Below Hero)
   ============================================ */
.trust-bar {
  background: #fff;
  border-bottom: 1px solid rgba(0,0,0,0.06);
  padding: 1rem 0;
  position: relative;
  z-index: 10;
}

/* ============================================
   Scroll-Reveal Floating Buttons
   ============================================ */
.scroll-reveal-btn {
  opacity: 0;
  transform: translateY(20px) scale(0.9);
  pointer-events: none;
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.scroll-reveal-btn.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

/* Staggered reveal: chatbot appears 100ms after WhatsApp */
.chatbot-container.scroll-reveal-btn.visible {
  transition-delay: 0.1s;
}

/* ============================================
   Hero Rotating Text Animation
   ============================================ */
/* Wrapper — NO fixed height, NO overflow hidden */
.hero-rotate-wrapper {
  display: block;
  min-height: 1.2em;
}

.hero-rotating-text {
  display: block;
  position: relative;
}

/* All items hidden by default */
.hero-rotate-item {
  display: none;
  line-height: 1.2;
}

/* Only the active item is shown — takes up natural space */
.hero-rotate-item.active {
  display: inline;
  animation: heroFadeIn 0.6s ease-out;
}

@keyframes heroFadeIn {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

@media (max-width: 640px) {
  .hero-rotate-item {
    white-space: normal;
  }
}
