/* ============================================
   Canada28 - SaaS Landing Page Styles
   ============================================ */

/* --- Base & Custom Properties --- */
:root {
  --primary: #4f46e5;
  --primary-dark: #4338ca;
  --primary-light: #6366f1;
  --accent: #f59e0b;
  --dark: #1e293b;
  --gray: #64748b;
  --light-bg: #f8fafc;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: #334155;
  overflow-x: hidden;
}

/* --- Navbar --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
  transition: all 0.3s ease;
}

.navbar.scrolled {
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
}

.nav-link {
  position: relative;
  color: #475569;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav-link:hover {
  color: #4f46e5;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: #4f46e5;
  border-radius: 2px;
  transition: width 0.3s ease;
}

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

/* --- Mobile Menu --- */
.mobile-menu {
  display: none;
  position: fixed;
  top: 0;
  right: -100%;
  width: 280px;
  height: 100vh;
  background: white;
  z-index: 2000;
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.12);
  transition: right 0.35s ease;
  padding: 80px 28px 28px;
}

.mobile-menu.active {
  right: 0;
}

.mobile-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 1500;
  opacity: 0;
  transition: opacity 0.35s ease;
}

.mobile-overlay.active {
  opacity: 1;
}

/* --- Hero --- */
.hero-gradient {
  background: linear-gradient(135deg, #eef2ff 0%, #e0e7ff 30%, #dbeafe 70%, #f0f9ff 100%);
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(79, 70, 229, 0.08);
  border: 1px solid rgba(79, 70, 229, 0.2);
  border-radius: 50px;
  padding: 6px 16px;
  font-size: 0.875rem;
  color: #4f46e5;
  font-weight: 500;
}

.hero-badge-dot {
  width: 8px;
  height: 8px;
  background: #22c55e;
  border-radius: 50%;
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.3); }
}

.hero-image-wrapper {
  position: relative;
}

.hero-image-wrapper::before {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 16px;
  background: linear-gradient(135deg, #6366f1, #8b5cf6, #a78bfa);
  z-index: -1;
  filter: blur(40px);
  opacity: 0.35;
}

.hero-float-card {
  position: absolute;
  background: white;
  border-radius: 12px;
  padding: 12px 16px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.1);
  animation: float 3s ease-in-out infinite;
}

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

/* --- Features --- */
.feature-card {
  position: relative;
  background: white;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  padding: 32px 24px;
  transition: all 0.35s ease;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #4f46e5, #8b5cf6);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s ease;
}

.feature-card:hover::before {
  transform: scaleX(1);
}

.feature-card:hover {
  border-color: #c7d2fe;
  box-shadow: 0 12px 32px rgba(79, 70, 229, 0.10);
  transform: translateY(-4px);
}

.feature-icon {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  margin-bottom: 16px;
}

/* --- Stats --- */
.stats-section {
  background: linear-gradient(135deg, #4f46e5 0%, #6366f1 50%, #4f46e5 100%);
  position: relative;
  overflow: hidden;
}

.stats-section::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 30% 50%, rgba(255,255,255,0.06) 0%, transparent 50%);
}

.stat-item {
  position: relative;
  z-index: 1;
}

.stat-number {
  font-size: 2.75rem;
  font-weight: 800;
  color: white;
  line-height: 1.1;
}

/* --- Testimonials --- */
.testimonial-card {
  background: white;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  padding: 28px;
  transition: all 0.3s ease;
}

.testimonial-card:hover {
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.08);
  border-color: #c7d2fe;
}

.testimonial-stars {
  color: #f59e0b;
  font-size: 0.9rem;
}

/* --- FAQ Accordion --- */
.faq-item {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  margin-bottom: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-item:hover {
  border-color: #c7d2fe;
}

.faq-item.active {
  border-color: #4f46e5;
  box-shadow: 0 4px 16px rgba(79, 70, 229, 0.08);
}

.faq-question {
  width: 100%;
  text-align: left;
  padding: 18px 56px 18px 20px;
  background: white;
  border: none;
  font-size: 1rem;
  font-weight: 600;
  color: #1e293b;
  cursor: pointer;
  position: relative;
  transition: color 0.2s ease;
}

.faq-question:hover {
  color: #4f46e5;
}

.faq-item.active .faq-question {
  color: #4f46e5;
}

.faq-icon {
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  transition: transform 0.35s ease;
  color: #94a3b8;
}

.faq-item.active .faq-icon {
  transform: translateY(-50%) rotate(180deg);
  color: #4f46e5;
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
}

.faq-item.active .faq-answer {
  max-height: 300px;
}

.faq-answer-inner {
  padding: 0 20px 20px;
  color: #64748b;
  line-height: 1.7;
}

/* --- CTA --- */
.cta-section {
  background: linear-gradient(135deg, #1e293b 0%, #1e3a5f 50%, #1e293b 100%);
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

/* --- Footer --- */
.footer {
  background: #0f172a;
  color: #94a3b8;
}

.footer a {
  color: #94a3b8;
  transition: color 0.2s ease;
}

.footer a:hover {
  color: #818cf8;
}

.footer-heading {
  color: white;
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* --- Buttons --- */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #4f46e5;
  color: white;
  font-weight: 600;
  padding: 12px 28px;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  transition: all 0.25s ease;
  text-decoration: none;
  font-size: 0.95rem;
}

.btn-primary:hover {
  background: #4338ca;
  box-shadow: 0 8px 24px rgba(79, 70, 229, 0.35);
  transform: translateY(-2px);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: white;
  color: #4f46e5;
  font-weight: 600;
  padding: 12px 28px;
  border-radius: 10px;
  border: 2px solid #4f46e5;
  cursor: pointer;
  transition: all 0.25s ease;
  text-decoration: none;
  font-size: 0.95rem;
}

.btn-secondary:hover {
  background: #eef2ff;
  transform: translateY(-2px);
}

/* --- Contact Form --- */
.contact-input {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid #e2e8f0;
  border-radius: 10px;
  font-size: 0.95rem;
  transition: all 0.25s ease;
  outline: none;
  background: white;
}

.contact-input:focus {
  border-color: #4f46e5;
  box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}

.contact-input.error {
  border-color: #ef4444;
}

/* --- About Page --- */
.about-hero {
  background: linear-gradient(135deg, #eef2ff 0%, #e0e7ff 50%, #dbeafe 100%);
}

.team-card {
  text-align: center;
  background: white;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  padding: 28px 20px;
  transition: all 0.3s ease;
}

.team-card:hover {
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08);
  transform: translateY(-4px);
}

.team-avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #e0e7ff;
  margin: 0 auto 16px;
}

/* --- Page Header (for about/contact) --- */
.page-header {
  padding-top: 120px;
  padding-bottom: 60px;
}

/* --- Animations --- */
.fade-in-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- Counter animation --- */
.count-up {
  transition: all 0.3s ease;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .stat-number {
    font-size: 2rem;
  }

  .feature-card {
    padding: 24px 18px;
  }

  .hero-float-card {
    display: none;
  }
}

@media (max-width: 1024px) {
  .desktop-nav {
    display: none !important;
  }

  .mobile-toggle {
    display: block !important;
  }

  .mobile-menu,
  .mobile-overlay {
    display: block;
  }
}

@media (min-width: 1025px) {
  .mobile-toggle {
    display: none !important;
  }

  .mobile-menu,
  .mobile-overlay {
    display: none !important;
  }
}
