/*
 * LeadSalesHub Marketing CSS
 * Custom styles for the marketing website
 */

/* ===== CUSTOM VARIABLES ===== */
:root {
  --lsh-primary: #0d6efd;
  --lsh-secondary: #6c757d;
  --lsh-success: #198754;
  --lsh-info: #0dcaf0;
  --lsh-warning: #ffc107;
  --lsh-danger: #dc3545;
  --lsh-light: #f8f9fa;
  --lsh-dark: #212529;

  --lsh-gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --lsh-gradient-secondary: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  --lsh-gradient-success: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);

  --lsh-border-radius: 0.375rem;
  --lsh-border-radius-lg: 0.5rem;
  --lsh-border-radius-xl: 0.75rem;

  --lsh-box-shadow-sm: 0 .125rem .25rem rgba(0, 0, 0, .075);
  --lsh-box-shadow: 0 .5rem 1rem rgba(0, 0, 0, .15);
  --lsh-box-shadow-lg: 0 1rem 3rem rgba(0, 0, 0, .175);
}

/* ===== GLOBAL ENHANCEMENTS ===== */
body {
  font-feature-settings: "kern" 1;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Improved focus states for accessibility */
.btn:focus,
.form-control:focus,
.form-select:focus,
.form-check-input:focus {
  box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
  outline: none;
}

/* Skip to content link for screen readers */
.skip-link {
  position: absolute;
  top: -40px;
  left: 6px;
  background: var(--lsh-primary);
  color: white;
  padding: 8px;
  text-decoration: none;
  border-radius: 0 0 4px 4px;
  z-index: 1000;
}

.skip-link:focus {
  top: 0;
}

/* ===== ENHANCED BUTTONS ===== */
.btn {
  font-weight: 500;
  letter-spacing: 0.025em;
  transition: all 0.15s ease-in-out;
  border-radius: var(--lsh-border-radius);
}

.btn-primary {
  background: var(--lsh-primary);
  border-color: var(--lsh-primary);
  box-shadow: 0 2px 4px rgba(13, 110, 253, 0.2);
}

.btn-primary:hover {
  background: #0b5ed7;
  border-color: #0a58ca;
  box-shadow: 0 4px 8px rgba(13, 110, 253, 0.3);
  transform: translateY(-1px);
}

.btn-outline-primary {
  border-width: 2px;
}

.btn-outline-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(13, 110, 253, 0.2);
}

.btn-lg {
  font-size: 1.1rem;
  padding: 0.75rem 2rem;
}

/* Gradient buttons */
.btn-gradient-primary {
  background: var(--lsh-gradient-primary);
  border: none;
  color: white;
}

.btn-gradient-primary:hover {
  background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

/* ===== ENHANCED CARDS ===== */
.card {
  border: none;
  border-radius: var(--lsh-border-radius-lg);
  box-shadow: var(--lsh-box-shadow-sm);
  transition: all 0.3s ease;
}

.card:hover {
  box-shadow: var(--lsh-box-shadow);
  transform: translateY(-2px);
}

.card-header {
  border-radius: var(--lsh-border-radius-lg) var(--lsh-border-radius-lg) 0 0 !important;
  font-weight: 600;
}

/* Pricing cards */
.pricing-card {
  position: relative;
  overflow: hidden;
}

.pricing-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--lsh-gradient-primary);
  opacity: 0;
  transition: opacity 0.3s ease;
}

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

/* Feature cards */
.feature-card {
  height: 100%;
  border-radius: var(--lsh-border-radius-lg);
  overflow: hidden;
  position: relative;
}

.feature-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, rgba(13, 110, 253, 0.05), rgba(102, 126, 234, 0.05));
  opacity: 0;
  transition: opacity 0.3s ease;
}

.feature-card:hover::after {
  opacity: 1;
}

/* ===== ENHANCED ICONS ===== */
.feature-icon {
  width: 80px;
  height: 80px;
  font-size: 2rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  position: relative;
  overflow: hidden;
}

.feature-icon::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.3));
  border-radius: 50%;
}

.feature-icon-sm {
  width: 50px;
  height: 50px;
  min-width: 50px;
  min-height: 50px;
  font-size: 1.25rem;
}

/* ===== ENHANCED FORMS ===== */
.form-control,
.form-select {
  border-radius: var(--lsh-border-radius);
  border: 2px solid #e9ecef;
  transition: all 0.15s ease-in-out;
}

.form-control:focus,
.form-select:focus {
  border-color: var(--lsh-primary);
  box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.1);
}

.form-control-lg,
.form-select-lg {
  padding: 0.75rem 1rem;
  font-size: 1.1rem;
}

/* Enhanced checkboxes and radios */
.form-check-input {
  width: 1.25em;
  height: 1.25em;
  border: 2px solid #dee2e6;
}

.form-check-input:checked {
  background-color: var(--lsh-primary);
  border-color: var(--lsh-primary);
}

/* ===== NAVIGATION ENHANCEMENTS ===== */
.navbar {
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.navbar-brand {
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: -0.025em;
}

.nav-link {
  font-weight: 500;
  transition: color 0.15s ease-in-out;
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--lsh-primary);
  transition: all 0.3s ease;
  transform: translateX(-50%);
}

.nav-link:hover::after {
  width: 100%;
}

.dropdown-menu {
  border: none;
  box-shadow: var(--lsh-box-shadow-lg);
  border-radius: var(--lsh-border-radius-lg);
  padding: 0.5rem 0;
}

.dropdown-item {
  padding: 0.5rem 1.5rem;
  transition: all 0.15s ease;
}

.dropdown-item:hover {
  background: var(--lsh-light);
  color: var(--lsh-primary);
}

/* ===== HERO SECTION ===== */
.hero-section {
  background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="%23e9ecef" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
  opacity: 0.5;
  z-index: -1;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
}

/* ===== SECTIONS ===== */
section {
  position: relative;
}

.section-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, #dee2e6, transparent);
  margin: 4rem 0;
}

/* ===== TESTIMONIALS ===== */
.testimonial-card {
  border-radius: var(--lsh-border-radius-lg);
  position: relative;
  overflow: hidden;
}

.testimonial-card::before {
  content: '"';
  position: absolute;
  top: -10px;
  left: 20px;
  font-size: 4rem;
  color: rgba(13, 110, 253, 0.1);
  font-family: Georgia, serif;
  z-index: 1;
}

.testimonial-card .card-body {
  position: relative;
  z-index: 2;
}

/* ===== LOGO STRIP ===== */
.logo-strip {
  filter: grayscale(100%);
  opacity: 0.7;
  transition: all 0.3s ease;
}

.logo-strip:hover {
  filter: grayscale(0%);
  opacity: 1;
}

/* ===== STATS ===== */
.stat-counter {
  font-size: 3rem;
  font-weight: 700;
  /* Fallback color for browsers that don't support gradient text */
  color: #0d6efd;
  background: var(--lsh-gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Fallback for browsers that don't support background-clip: text */
@supports not (background-clip: text) {
  .stat-counter {
    color: #0d6efd !important;
    background: none !important;
  }
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

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

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.7;
  }
}

.animate-fadeInUp {
  animation: fadeInUp 0.6s ease-out;
}

.animate-fadeInLeft {
  animation: fadeInLeft 0.6s ease-out;
}

.animate-fadeInRight {
  animation: fadeInRight 0.6s ease-out;
}

.animate-pulse {
  animation: pulse 2s infinite;
}

/* ===== COOKIE NOTICE ===== */
.cookie-notice {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1050;
  border-radius: 0;
  backdrop-filter: blur(10px);
}

/* ===== ACCESSIBILITY ENHANCEMENTS ===== */
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  .btn {
    border-width: 2px;
  }

  .card {
    border: 2px solid #000;
  }
}

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

/* ===== RESPONSIVE ENHANCEMENTS ===== */
@media (max-width: 768px) {
  .hero-section {
    padding: 3rem 0;
  }

  .display-1 {
    font-size: 2.5rem;
  }

  .display-4 {
    font-size: 2rem;
  }

  .display-5 {
    font-size: 1.75rem;
  }

  .btn-lg {
    padding: 0.625rem 1.5rem;
    font-size: 1rem;
  }

  .feature-icon {
    width: 60px;
    height: 60px;
    font-size: 1.5rem;
  }

  .card-body {
    padding: 1.5rem;
  }
}

@media (max-width: 576px) {
  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .btn-lg {
    font-size: 0.95rem;
    padding: 0.5rem 1.25rem;
  }

  .navbar-brand {
    font-size: 1.25rem;
  }
}

/* ===== PRINT STYLES ===== */
@media print {
  .navbar,
  .cookie-notice,
  .btn,
  .footer {
    display: none !important;
  }

  body {
    color: #000 !important;
    background: #fff !important;
  }

  .card {
    border: 1px solid #000 !important;
    box-shadow: none !important;
  }
}

/* ===== UTILITY CLASSES ===== */
.bg-gradient {
  background: var(--lsh-gradient-primary) !important;
}

.text-gradient {
  background: var(--lsh-gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.border-radius-lg {
  border-radius: var(--lsh-border-radius-lg) !important;
}

.border-radius-xl {
  border-radius: var(--lsh-border-radius-xl) !important;
}

.shadow-primary {
  box-shadow: 0 0.5rem 1rem rgba(13, 110, 253, 0.15) !important;
}

.shadow-success {
  box-shadow: 0 0.5rem 1rem rgba(25, 135, 84, 0.15) !important;
}

.shadow-warning {
  box-shadow: 0 0.5rem 1rem rgba(255, 193, 7, 0.15) !important;
}

.shadow-danger {
  box-shadow: 0 0.5rem 1rem rgba(220, 53, 69, 0.15) !important;
}

/* ===== ICON FALLBACKS ===== */
/* Only show fallbacks when Bootstrap Icons fail to load */
.icon-fallback .bi-rocket-takeoff::before {
  content: "🚀";
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
}
.icon-fallback .bi-play-circle::before {
  content: "▶";
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
}
.icon-fallback .bi-lightning-charge::before {
  content: "⚡";
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
}
.icon-fallback .bi-graph-up-arrow::before {
  content: "📈";
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
}
.icon-fallback .bi-check-circle-fill::before {
  content: "✓";
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
  color: #198754;
}
.icon-fallback .bi-telephone::before {
  content: "📞";
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
}
.icon-fallback .bi-envelope::before {
  content: "✉";
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
}
.icon-fallback .bi-star-fill::before {
  content: "★";
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
  color: #ffc107;
}