/* =========================================================
   BASE RESET & THEME TOKENS
   ========================================================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary-color: #3b82f6;
  --secondary-color: #60a5fa;
  --accent-color: #8b5cf6;
  --primary-dark: #1d4ed8;
  --header-bg: rgba(15, 23, 42, 0.85);
  --dark-bg: #0f172a;
  --light-bg: #f8fafc;
  --surface-bg: #ffffff;
  --text-dark: #0f172a;
  --text-muted: #64748b;
  --text-light: rgba(226, 232, 240, 0.9);
  --border-subtle: rgba(148, 163, 184, 0.2);
  --shadow-soft: 0 20px 45px rgba(15, 23, 42, 0.08);
  --shadow-strong: 0 32px 60px rgba(15, 23, 42, 0.16);
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-sm: 12px;
  --hero-overlay: radial-gradient(circle at 20% 20%, rgba(59, 130, 246, 0.35), transparent 55%),
                   radial-gradient(circle at 80% 10%, rgba(139, 92, 246, 0.35), transparent 45%),
                   #0f172a;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Montserrat", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--text-dark);
  background: linear-gradient(180deg, #f1f5f9 0%, #ffffff 100%);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  border: none;
  background: none;
  cursor: pointer;
}

img {
  max-width: 100%;
  display: block;
}

.section-container {
  width: min(1120px, 92vw);
  margin: 0 auto;
}

.section-header {
  text-align: center;
  margin-bottom: 3.5rem;
}

.section-title {
  font-size: clamp(2rem, 4vw, 2.5rem);
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 0.75rem;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 1.5rem;
  font-weight: 700;
  /* max-width: 620px; */
  margin: 0.75rem auto 1.5rem;
  line-height: 1.65;
  letter-spacing: -0.01em;
}

/* =========================================================
   NAVIGATION
   ========================================================= */
nav {
  position: fixed;
  inset: 0 0 auto 0;
  height: 88px;
  display: flex;
  align-items: center;
  background: var(--header-bg);
  backdrop-filter: blur(18px);
  z-index: 1000;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.nav-container {
  width: min(1200px, 92vw);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.logo {
  height: 56px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  list-style: none;
}

.nav-links a {
  color: var(--text-light);
  font-weight: 500;
  transition: color 0.25s ease;
}

.nav-links a:hover,
.nav-links a:focus {
  color: #ffffff;
}

.lang-selector {
  padding: 0.6rem 1.1rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(15, 23, 42, 0.65);
  color: #e2e8f0;
  font-weight: 600;
  transition: border-color 0.25s ease, background 0.25s ease;
}

.lang-selector:hover,
.lang-selector:focus {
  border-color: rgba(148, 163, 184, 0.65);
  background: rgba(30, 41, 59, 0.9);
}

.mobile-menu-toggle {
  display: none;
  padding: 0.55rem 0.75rem;
  border-radius: var(--radius-sm);
  background: var(--primary-color);
  color: #ffffff;
  font-size: 1.35rem;
  transition: transform 0.25s ease, background 0.25s ease;
}

.mobile-menu-toggle:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
}

.mobile-menu {
  position: fixed;
  inset: 88px 0 0 0;
  background: rgba(30, 41, 59, 0.9);
  transform: translateX(100%);
  transition: transform 0.35s ease;
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  color: #ffffff;
}
#mobileMenu {
  background: rgba(30, 41, 59, 0.9);
  height: 360px;
}
.mobile-menu.active {
  transform: translateX(0);
}

.mobile-menu-links {
  list-style: none;
  display: grid;
  gap: 1rem;
}

.mobile-menu-links a {
  list-style: none;
  display: grid;
  width: 100%;
  gap: 1rem;
  padding-inline-start: 0px !important;
  margin-block-start: 0px;
  color: #ffffff;
}

.mobile-menu-links a:hover {
  background: rgba(255, 255, 255, 0.12);
}

.mobile-lang-selector {
  margin-top: auto;
  padding: 1.25rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(15, 23, 42, 0.25);
}

.mobile-lang-selector select {
  width: 100%;
  background: transparent;
  color: #ffffff;
  border: none;
  font-size: 1rem;
}

.mobile-lang-selector option {
  background-color: var(--dark-bg);
  color: white;
}

/* =========================================================
   HERO
   ========================================================= */
.hero {
  margin-top: 88px;
  min-height: calc(100vh - 88px);
  display: flex;
  align-items: center;
  background: var(--hero-overlay);
  position: relative;
  overflow: hidden;
}

.hero-particles {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

.hero-container {
  width: min(1200px, 92vw);
  margin: 0 auto;
  padding: 4rem 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(2.5rem, 6vw, 6rem);
  align-items: center;
  position: relative;
  z-index: 2;
}

.badge-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-bottom: 1.5rem;
}

.badge,
.badge-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 1.25rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.badge::before,
.badge-secondary::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
}

.badge {
  background: rgba(15, 23, 42, 0.65);
  color: rgba(191, 219, 254, 0.95);
  border: 1px solid rgba(96, 165, 250, 0.4);
}

.badge::before {
  background: rgba(96, 165, 250, 0.9);
}

.badge-secondary {
  background: rgba(96, 165, 250, 0.15);
  color: rgba(219, 234, 254, 0.95);
  border: 1px solid rgba(96, 165, 250, 0.3);
}

.badge-secondary::before {
  background: rgba(139, 92, 246, 0.85);
}

.hero-content h1 {
  font-size: clamp(2.75rem, 5vw, 3.8rem);
  font-weight: 800;
  color: #f8fafc;
  line-height: 1.12;
  margin-bottom: 1rem;
  transition: opacity 0.65s ease;
}

.hero-subtitle {
  font-size: 1.125rem;
  color: rgba(226, 232, 240, 0.85);
  max-width: 520px;
  margin-bottom: 2rem;
  transition: opacity 0.65s ease;
}

.hero-cta {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.cta-button,
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.95rem 2.4rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 1rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}

.cta-button {
  background: #ffffff;
  color: var(--primary-color);
  box-shadow: var(--shadow-soft);
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-strong);
}

.btn-secondary {
  border: 1px solid rgba(148, 163, 184, 0.35);
  color: #e2e8f0;
  background: rgba(15, 23, 42, 0.35);
}

.btn-secondary:hover {
  transform: translateY(-2px);
  border-color: rgba(148, 163, 184, 0.65);
  background: rgba(15, 23, 42, 0.55);
}

.trust-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
}

.trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: rgba(226, 232, 240, 0.75);
  font-size: 0.875rem;
}

.trust-badge::before {
  content: "✓";
  color: rgba(148, 197, 253, 0.95);
  font-weight: 700;
}

.hero-visual {
  position: relative;
  height: clamp(420px, 55vw, 600px);
}

.hero-visual-container {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.8s ease;
}

.hero-visual-container.active {
  opacity: 1;
}

.hero-visual-container canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.hero-bullets {
  position: absolute;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  gap: 0.6rem;
  z-index: 3;
}

.hero-bullets button {
  width: 11px;
  height: 11px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.4);
  transition: background 0.25s ease, transform 0.25s ease;
}

.hero-bullets button.active {
  background: #ffffff;
  transform: scale(1.2);
}

/* =========================================================
   FEATURES
   ========================================================= */
.features {
  padding: clamp(4rem, 8vw, 6rem) 0;
  background: var(--surface-bg);
}

.features-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.feature-card {
  padding: 2.25rem 2rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: linear-gradient(160deg, rgba(59, 130, 246, 0.12), rgba(15, 23, 42, 0.05));
  box-shadow: var(--shadow-soft);
  display: grid;
  gap: 1rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-strong);
}

.feature-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(59, 130, 246, 0.2);
  color: var(--primary-color);
}

.feature-card h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-dark);
}

.feature-card p {
  color: var(--text-muted);
}

/* =========================================================
   INTEGRATIONS
   ========================================================= */
.integrations {
  padding: clamp(4rem, 8vw, 6rem) 0;
  background: var(--light-bg);
}

.integrations-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 1.75rem;
  margin-top: 2.5rem;
}

.integration-card {
  padding: 2.25rem 1.5rem;
  border-radius: var(--radius-md);
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  display: grid;
  place-items: center;
  gap: 1rem;
  min-height: 200px;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.integration-card:hover {
  transform: translateY(-6px);
  border-color: rgba(59, 130, 246, 0.45);
  box-shadow: var(--shadow-soft);
}

.integration-logo {
  width: min(120px, 60%);
}

.integration-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-dark);
}

/* =========================================================
   MODULES
   ========================================================= */
.modules {
  padding: clamp(4rem, 8vw, 6rem) 0;
  background: #ffffff;
}

.modules-list {
  display: grid;
  gap: 1.5rem;
}

.module-item {
  padding: 2rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: linear-gradient(160deg, rgba(15, 23, 42, 0.02), rgba(96, 165, 250, 0.08));
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.06);
  display: grid;
  gap: 0.75rem;
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.module-item:hover {
  transform: translateY(-4px);
  border-color: rgba(59, 130, 246, 0.45);
}

.module-item h4 {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-dark);
}

.module-item p {
  color: var(--text-muted);
}

/* =========================================================
   PRICING
   ========================================================= */
.pricing {
  padding: clamp(4rem, 8vw, 6rem) 0;
  background: var(--surface-bg);
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.5rem;
  margin-top: 3rem;
  max-width: 1400px;
  margin-left: auto;
  margin-right: auto;
}

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

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

.pricing-card {
  padding: 3rem 2.25rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: #ffffff;
  text-align: center;
  box-shadow: var(--shadow-soft);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  display: flex;
  flex-direction: column;
}

.pricing-card .cta-button {
  margin-top: auto;
}

.pricing-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-strong);
  border-color: rgba(59, 130, 246, 0.5);
}

.pricing-card.featured {
  background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
  color: #ffffff;
  border: none;
  box-shadow: var(--shadow-strong);
}

.price {
  font-size: 3rem;
  font-weight: 700;
  margin: 1.25rem 0 0.5rem;
}

.pricing-features {
  list-style: none;
  margin: 2rem 0;
  display: grid;
  gap: 0.75rem;
  text-align: left;
}

.pricing-features li {
  padding-left: 1.6rem;
  position: relative;
  color: currentColor;
}

.pricing-features li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: inherit;
  font-weight: 700;
}

/* =========================================================
   FAQ
   ========================================================= */
.faq {
  padding: clamp(4rem, 8vw, 6rem) 0;
  background: var(--light-bg);
}

.faq-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  max-width: 1200px;
  margin: 0 auto;
}

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

.faq-item {
  background: #ffffff;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
  transition: box-shadow 0.3s ease, border-color 0.3s ease;
  overflow: hidden;
}

.faq-item:hover {
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
  border-color: rgba(59, 130, 246, 0.3);
}

.faq-question {
  width: 100%;
  padding: 1.5rem 1.75rem;
  background: transparent;
  border: none;
  text-align: left;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  transition: background-color 0.2s ease;
}

.faq-question:hover {
  background: rgba(59, 130, 246, 0.04);
}

.faq-question h4 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-dark);
  margin: 0;
  flex: 1;
}

.faq-icon {
  font-size: 1.5rem;
  font-weight: 300;
  color: var(--primary-color);
  line-height: 1;
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
}

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

.faq-item.active .faq-answer {
  max-height: 500px;
  padding: 0 1.75rem 1.5rem 1.75rem;
}

.faq-answer p {
  color: var(--text-muted);
  line-height: 1.7;
  margin: 0;
}

/* =========================================================
   CONTACT
   ========================================================= */
.contact {
  padding: clamp(4rem, 8vw, 6rem) 0;
  background: linear-gradient(140deg, rgba(15, 23, 42, 0.95), rgba(30, 58, 138, 0.92));
  color: #ffffff;
}

.contact .section-title {
  color: #ffffff;
}

.contact .section-subtitle {
  color: rgba(255, 255, 255, 0.85);
}

.contact-form {
  width: min(640px, 92vw);
  margin: 3.5rem auto 0;
  background: rgba(15, 23, 42, 0.45);
  padding: 2.5rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(148, 163, 184, 0.2);
  box-shadow: var(--shadow-soft);
  display: grid;
  gap: 1.25rem;
}

.form-group {
  display: grid;
  gap: 0.6rem;
}

.form-group label {
  font-weight: 600;
  color: rgba(226, 232, 240, 0.95);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.95rem 1rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(148, 163, 184, 0.25);
  background: rgba(15, 23, 42, 0.35);
  color: #f8fafc;
  transition: border-color 0.25s ease, background 0.25s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: rgba(96, 165, 250, 0.6);
  background: rgba(15, 23, 42, 0.5);
  outline: none;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: rgba(148, 163, 184, 0.65);
}

.submit-button {
  width: 100%;
  padding: 1rem 1.5rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 1rem;
  background: #ffffff;
  color: var(--primary-color);
  border: none;
  box-shadow: var(--shadow-soft);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.submit-button:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-strong);
}

/* =========================================================
   FOOTER
   ========================================================= */
footer {
  background: var(--dark-bg);
  color: rgba(226, 232, 240, 0.85);
  text-align: center;
  padding: 3rem 1.5rem;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
}

/* =========================================================
   CUSTOM ALERT
   ========================================================= */
.custom-alert-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  display: grid;
  place-items: center;
  z-index: 2000;
  animation: fadeIn 0.25s ease forwards;
}

.custom-alert {
  width: min(380px, 92vw);
  background: #ffffff;
  padding: 2.5rem 2.25rem;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-strong);
  text-align: center;
  display: grid;
  gap: 1rem;
  animation: slideIn 0.3s ease forwards;
}

.custom-alert.success {
  border-top: 5px solid #22c55e;
}

.custom-alert.error {
  border-top: 5px solid #ef4444;
}

.custom-alert-icon {
  font-size: 2.75rem;
}

.custom-alert.success .custom-alert-icon {
  color: #22c55e;
}

.custom-alert.error .custom-alert-icon {
  color: #ef4444;
}

.custom-alert-title {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-dark);
}

.custom-alert-message {
  color: var(--text-muted);
  line-height: 1.6;
}

.custom-alert-button {
  justify-self: center;
  padding: 0.75rem 2.25rem;
  border-radius: var(--radius-sm);
  background: var(--primary-color);
  color: #ffffff;
  font-weight: 600;
  transition: background 0.25s ease, transform 0.25s ease;
}

.custom-alert-button:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
}

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

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 1024px) {
  .hero-container {
    display: grid;
    grid-template-columns: 1fr;
    text-align: center;
    padding-top:1rem;
  }

  .hero-content {
    display: contents;
  }

  .badge-group {
    order: 1;
    margin-bottom: 0px;
  }

  .hero-content h1 {
    order: 2;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 0px;
  }

  .hero-visual {
    order: 3;
    height: 400px;
    margin-top: -110px;
  }

  .hero-subtitle {
    order: 4;
    margin-left: auto;
    margin-right: auto;
  }

  .hero-cta {
    order: 5;
    justify-content: center;
  }

  .trust-badges {
    order: 6;
  }
}

@media (max-width: 820px) {
  .nav-links {
    display: none;
  }

  .mobile-menu-toggle {
    display: inline-flex;
  }
}

@media (max-width: 620px) {
  .feature-card,
  .module-item {
    padding: 2rem 1.5rem;
  }

  .pricing-card {
    padding: 2.5rem 1.75rem;
  }

  .contact-form {
    padding: 2rem 1.75rem;
  }
}

/* =========================================================
   SCROLL ANIMATIONS
   ========================================================= */
.scroll-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

/* Stagger animation for grid items */
.feature-card.scroll-reveal,
.integration-card.scroll-reveal,
.pricing-card.scroll-reveal {
  transition-delay: calc(var(--delay, 0) * 100ms);
}

.feature-card:nth-child(1) { --delay: 1; }
.feature-card:nth-child(2) { --delay: 2; }
.feature-card:nth-child(3) { --delay: 3; }
.feature-card:nth-child(4) { --delay: 4; }
.feature-card:nth-child(5) { --delay: 5; }
.feature-card:nth-child(6) { --delay: 6; }
.feature-card:nth-child(7) { --delay: 7; }

.integration-card:nth-child(1) { --delay: 1; }
.integration-card:nth-child(2) { --delay: 2; }
.integration-card:nth-child(3) { --delay: 3; }
.integration-card:nth-child(4) { --delay: 4; }

.pricing-card:nth-child(1) { --delay: 1; }
.pricing-card:nth-child(2) { --delay: 2; }
.pricing-card:nth-child(3) { --delay: 3; }
.pricing-card:nth-child(4) { --delay: 4; }

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  .scroll-reveal {
    transition: none;
    opacity: 1;
    transform: none;
  }
}
