/* =========================================================
   FULFILIX CLOUD — Elevation Layer
   Final polish pass: ambient background treatment, premium
   card + border language, uniform pill buttons, refined
   typography rhythm, testimonials slider, spacing audit.
   Loaded LAST (after style / responsive / refine / premium / pages).
   ========================================================= */

:root {
  --e-ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --e-sect: 112px;
  --e-sect-sm: 76px;
  --e-radius-card: 20px;
  --e-line: rgba(168, 85, 247, 0.16);
  --e-line-strong: rgba(196, 132, 252, 0.34);
  --e-surface: linear-gradient(168deg, rgba(26, 16, 48, 0.62) 0%, rgba(13, 9, 26, 0.72) 100%);
}

/* ---------------------------------------------------------
   1. AMBIENT BACKGROUND TREATMENT
   --------------------------------------------------------- */
html, body { overflow-x: hidden; max-width: 100%; }

body {
  position: relative;
  background-color: #06060c;
}
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(60% 42% at 78% -4%, rgba(124, 58, 237, 0.28) 0%, transparent 68%),
    radial-gradient(48% 38% at 6% 14%, rgba(168, 85, 247, 0.14) 0%, transparent 70%),
    radial-gradient(70% 50% at 50% 108%, rgba(76, 29, 149, 0.26) 0%, transparent 72%);
}
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.5;
  background-image: linear-gradient(rgba(168, 85, 247, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(168, 85, 247, 0.045) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(120% 90% at 50% 0%, #000 0%, transparent 70%);
  -webkit-mask-image: radial-gradient(120% 90% at 50% 0%, #000 0%, transparent 70%);
}

/* Section band separators — quiet, precise */
.features-section,
.integrations-section,
.industries-section,
.how-it-works,
.testimonials-section,
.faq-section,
.platform-section,
.automation-section,
.product-pricing {
  position: relative;
}
.features-section::before,
.integrations-section::before,
.industries-section::before,
.how-it-works::before,
.testimonials-section::before,
.faq-section::before,
.platform-section::before,
.automation-section::before,
.product-pricing::before {
  content: '';
  position: absolute;
  top: 0;
  left: 8%;
  right: 8%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(168, 85, 247, 0.28), transparent);
  pointer-events: none;
}

/* ---------------------------------------------------------
   2. RHYTHM & CONTAINERS
   --------------------------------------------------------- */
.container { max-width: 1240px; padding-left: 28px; padding-right: 28px; }

.features-section,
.integrations-section,
.industries-section,
.how-it-works,
.testimonials-section,
.faq-section,
.cta-section,
.platform-section,
.automation-section,
.product-pricing,
.trusted-section {
  padding-top: var(--e-sect);
  padding-bottom: var(--e-sect);
}
.trusted-section { padding-top: 56px; padding-bottom: 56px; }

.section-header { max-width: 720px; margin-left: auto; margin-right: auto; margin-bottom: 60px; }
.section-header h2 { margin-bottom: 14px; }
.section-header p { margin-left: auto; margin-right: auto; max-width: 620px; }

.features-grid,
.steps-grid { gap: 22px; }

/* ---------------------------------------------------------
   3. TYPOGRAPHY REFINEMENT
   --------------------------------------------------------- */
body { letter-spacing: -0.002em; }

h1, .hero-title, .product-hero h1 {
  font-weight: 600;
  line-height: 1.14;
  letter-spacing: -0.028em;
}
h2, .section-header h2, .cta-card h2 {
  font-weight: 600;
  line-height: 1.18;
  letter-spacing: -0.024em;
}
h3, .feature-card h3, .industry-content h3 { font-weight: 600; letter-spacing: -0.014em; }
h4, h5 { letter-spacing: -0.008em; }

p, .hero-subtitle, .section-header p, .feature-card p, .testimonial-text {
  line-height: 1.72;
  color: var(--text-secondary);
}
.section-header p, .hero-subtitle { color: #a99dc4; }
.feature-card p { color: #9d92b8; font-size: 0.9375rem; }

.section-tag {
  font-family: var(--nav-mono, 'JetBrains Mono', monospace);
  font-size: 0.6875rem;
  font-weight: 400;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid rgba(168, 85, 247, 0.22);
  background: rgba(168, 85, 247, 0.07);
  color: #cbbfe0;
}
.gradient-text {
  background: linear-gradient(104deg, #c084fc 0%, #a855f7 42%, #ec4899 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ---------------------------------------------------------
   4. BUTTONS — one pill geometry, refined hovers
   --------------------------------------------------------- */
.btn,
.btn-primary,
.btn-outline,
.btn-ghost,
.btn-lg,
button.btn,
a.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  height: 50px;
  min-height: 50px;
  padding: 0 28px;
  border-radius: 999px;
  font-size: 0.9375rem;
  font-weight: 500;
  letter-spacing: 0.004em;
  line-height: 1;
  overflow: hidden;
  isolation: isolate;
  box-shadow: none;
  transition: color 0.32s var(--e-ease), border-color 0.32s var(--e-ease),
    background-color 0.32s var(--e-ease), background-position 0.6s var(--e-ease),
    opacity 0.3s var(--e-ease);
}
.btn-lg { height: 56px; min-height: 56px; padding: 0 34px; font-size: 1rem; }
.btn:hover,
.btn:focus-visible,
.btn:active { transform: none !important; }

.btn-primary {
  background-image: linear-gradient(104deg, #7c3aed 0%, #a855f7 46%, #ec4899 100%);
  background-size: 190% 100%;
  background-position: 0% 50%;
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #fff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
}
.btn-primary::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.18), transparent 55%);
  opacity: 0;
  transition: opacity 0.35s var(--e-ease);
  z-index: -1;
}
.btn-primary:hover { background-position: 100% 50%; }
.btn-primary:hover::after { opacity: 1; }
.btn-primary:active { opacity: 0.94; }

.btn-outline {
  background-color: rgba(168, 85, 247, 0.04);
  border: 1px solid rgba(168, 85, 247, 0.28);
  color: #ece7f7;
}
.btn-outline::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(104deg, rgba(124, 58, 237, 0.26), rgba(236, 72, 153, 0.16));
  opacity: 0;
  transition: opacity 0.38s var(--e-ease);
  z-index: -1;
}
.btn-outline:hover { border-color: var(--e-line-strong); color: #fff; }
.btn-outline:hover::before { opacity: 1; }

.btn-ghost {
  background: transparent;
  border: 1px solid transparent;
  color: #cbbfe0;
  padding: 0 18px;
}
.btn-ghost:hover { color: #fff; background-color: rgba(168, 85, 247, 0.08); }

/* ---------------------------------------------------------
   5. CARD & SURFACE LANGUAGE
   --------------------------------------------------------- */
.feature-card,
.step-card,
.testimonial-card,
.pricing-card,
.industry-panel,
.stat-box,
.integration-list-item,
.faq-item,
.screenshot-card,
.platform-panel {
  border-radius: var(--e-radius-card);
  border: 1px solid var(--e-line);
  background: var(--e-surface);
  box-shadow: 0 18px 44px -30px rgba(2, 0, 10, 0.9);
  transition: border-color 0.42s var(--e-ease), background 0.42s var(--e-ease),
    box-shadow 0.42s var(--e-ease), transform 0.42s var(--e-ease);
}

.feature-card,
.step-card,
.pricing-card {
  position: relative;
  overflow: hidden;
}
.feature-card::after,
.step-card::after,
.pricing-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 18%;
  right: 18%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(196, 132, 252, 0.5), transparent);
  opacity: 0;
  transition: opacity 0.42s var(--e-ease);
}
.feature-card:hover,
.step-card:hover,
.pricing-card:hover,
.testimonial-card:hover {
  border-color: var(--e-line-strong);
  background: linear-gradient(168deg, rgba(38, 22, 70, 0.7) 0%, rgba(16, 10, 32, 0.78) 100%);
  box-shadow: 0 26px 60px -34px rgba(2, 0, 10, 0.95);
  transform: translateY(-3px);
}
.feature-card:hover::after,
.step-card:hover::after,
.pricing-card:hover::after { opacity: 1; }

.faq-item { margin-bottom: 12px; }
.faq-item.open { border-color: var(--e-line-strong); }
.faq-question { font-weight: 500; letter-spacing: -0.008em; }

.footer { border-top: 1px solid var(--e-line); background: linear-gradient(180deg, rgba(10, 6, 20, 0.6), rgba(6, 4, 12, 0.95)); }

/* ---------------------------------------------------------
   6. TESTIMONIALS — premium responsive slider
   --------------------------------------------------------- */
.testimonials-featured { margin-bottom: 54px; }
.testimonial-featured-card {
  border-radius: 26px;
  border: 1px solid var(--e-line);
  background: linear-gradient(168deg, rgba(34, 19, 64, 0.7) 0%, rgba(13, 9, 26, 0.8) 100%);
}

.t-slider {
  position: relative;
  margin-top: 8px;
}
.t-viewport {
  overflow: hidden;
  padding: 6px 4px 10px;
  margin: -6px -4px -10px;
  cursor: grab;
}
.t-viewport.is-dragging { cursor: grabbing; }
.t-track {
  display: flex;
  align-items: stretch;
  gap: 24px;
  will-change: transform;
  transition: transform 0.62s cubic-bezier(0.4, 0.01, 0.2, 1);
}
.t-slide {
  flex: 0 0 calc((100% - 24px) / 2);
  min-width: 0;
  display: flex;
}

.t-card {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  padding: 34px 32px 28px;
  border-radius: 22px;
  border: 1px solid var(--e-line);
  background:
    radial-gradient(120% 100% at 100% 0%, rgba(124, 58, 237, 0.14) 0%, transparent 58%),
    linear-gradient(168deg, rgba(28, 17, 52, 0.72) 0%, rgba(13, 9, 26, 0.82) 100%);
  box-shadow: 0 20px 50px -34px rgba(2, 0, 10, 0.95);
  overflow: hidden;
  transition: border-color 0.42s var(--e-ease), box-shadow 0.42s var(--e-ease),
    transform 0.42s var(--e-ease);
}
.t-card::before {
  content: '"';
  position: absolute;
  top: -18px;
  right: 22px;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 8rem;
  line-height: 1;
  color: rgba(196, 132, 252, 0.13);
  pointer-events: none;
}
.t-card:hover {
  border-color: var(--e-line-strong);
  box-shadow: 0 28px 64px -34px rgba(2, 0, 10, 1);
  transform: translateY(-3px);
}

.t-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 20px;
}
.t-stars { display: flex; gap: 3px; color: #fbbf24; font-size: 0.9rem; letter-spacing: 0.04em; }
.t-score {
  font-family: var(--nav-mono, monospace);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  color: #8b7bb0;
  border: 1px solid rgba(168, 85, 247, 0.18);
  border-radius: 999px;
  padding: 5px 11px;
  white-space: nowrap;
}
.t-quote {
  flex: 1 1 auto;
  margin: 0 0 26px;
  font-size: 1.0625rem;
  line-height: 1.72;
  color: #d5cbe8;
  letter-spacing: -0.008em;
}
.t-foot {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  padding-top: 20px;
  border-top: 1px solid rgba(168, 85, 247, 0.14);
}
.t-avatar {
  width: 46px;
  height: 46px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-size: 0.875rem;
  font-weight: 600;
  color: #fff;
  letter-spacing: 0.03em;
  background: linear-gradient(140deg, #7c3aed, #ec4899);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.14) inset, 0 8px 22px -12px rgba(168, 85, 247, 0.9);
}
.t-who { min-width: 0; }
.t-name { font-size: 0.9375rem; font-weight: 600; color: #fff; letter-spacing: -0.008em; }
.t-role { font-size: 0.8125rem; color: #8b7bb0; margin-top: 2px; }

/* Controls */
.t-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 34px;
}
.t-btn {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  border: 1px solid rgba(168, 85, 247, 0.24);
  background: rgba(168, 85, 247, 0.05);
  color: #cbbfe0;
  transition: color 0.32s var(--e-ease), border-color 0.32s var(--e-ease),
    background-color 0.32s var(--e-ease), opacity 0.32s var(--e-ease);
}
.t-btn svg { width: 17px; height: 17px; }
.t-btn:hover { color: #fff; border-color: var(--e-line-strong); background-color: rgba(168, 85, 247, 0.14); }
.t-btn[disabled] { opacity: 0.35; pointer-events: none; }

.t-dots { display: flex; align-items: center; gap: 8px; }
.t-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  border: 0;
  background: rgba(168, 85, 247, 0.28);
  transition: width 0.4s var(--e-ease), background-color 0.4s var(--e-ease);
}
.t-dot.active { width: 26px; background: linear-gradient(90deg, #a855f7, #ec4899); }

@media (max-width: 900px) {
  .t-slide { flex-basis: 100%; }
  .t-track { gap: 18px; }
  .t-card { padding: 28px 24px 24px; }
  .t-quote { font-size: 1rem; margin-bottom: 22px; }
}

/* ---------------------------------------------------------
   7. RESPONSIVE / OVERFLOW AUDIT
   --------------------------------------------------------- */
img, svg, video { max-width: 100%; }

@media (max-width: 1024px) {
  :root { --e-sect: 92px; }
  .section-header { margin-bottom: 48px; }
}
@media (max-width: 768px) {
  :root { --e-sect: var(--e-sect-sm); }
  .container { padding-left: 20px; padding-right: 20px; }
  .section-header { margin-bottom: 40px; }
  .hero-cta { flex-direction: column; align-items: stretch; }
  .hero-cta .btn { width: 100%; }
  .btn, .btn-lg { height: 50px; min-height: 50px; font-size: 0.9375rem; padding: 0 24px; }
}
@media (max-width: 520px) {
  .container { padding-left: 16px; padding-right: 16px; }
  .t-controls { gap: 12px; margin-top: 26px; }
  .t-btn { width: 42px; height: 42px; }
}

@media (prefers-reduced-motion: reduce) {
  .t-track { transition: none; }
  * { animation-duration: 0.001ms !important; }
}
