/* ─── Univers Solutions Landing — Refined Editorial ─── */

/* ─── Fonts (loaded via @import, fallback stack below) ─── */
@import url("https://fonts.googleapis.com/css2?family=DM+Sans:ital,wght@0,400;0,500;0,600;0,700;1,400&family=Sora:wght@600;700;800&display=swap");

/* ─── Anchor scroll offset ─── */
[id] {
  scroll-margin-top: 80px;
}

/* ─── Root tokens ─── */
:root {
  --color-primary: #007bff;
  --color-secondary: #0056b3;
  --color-highlight: #cfe3ff;
  --color-text: #0f1117;
  --color-text-muted: #5a5f6e;
  --color-border: #e2e4e8;
  --color-bg: #ffffff;
  --color-bg-subtle: #f5f6f8;
  --color-bg-card: #fafbfc;

  --shadow-soft: 0 24px 64px rgba(0, 0, 0, 0.07);
  --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.055);
  --shadow-card-hover: 0 8px 32px rgba(0, 0, 0, 0.1);

  --font-display: "Sora", "Segoe UI", system-ui, sans-serif;
  --font-body: "DM Sans", "Segoe UI", system-ui, sans-serif;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ─── Base ─── */
body {
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
}

/* ─── Grain overlay (fixed, pointer-events none) ─── */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;
  opacity: 0.018;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 512 512' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ─── Background grid ─── */
.bg-grid {
  background-image: radial-gradient(
    circle at 1px 1px,
    rgba(0, 0, 0, 0.035) 1px,
    transparent 0
  );
  background-size: 32px 32px;
  mask-image: radial-gradient(ellipse at 50% 0%, black 40%, transparent 75%);
  opacity: 0.6;
}

/* ─── Animated background blobs ─── */
.blob {
  animation: blobDrift 18s ease-in-out infinite alternate;
}
.blob--1 { animation-delay: 0s; }
.blob--2 { animation-delay: -6s; animation-duration: 22s; }
.blob--3 { animation-delay: -12s; animation-duration: 26s; }

@keyframes blobDrift {
  0%   { transform: translate(0, 0) scale(1); }
  33%  { transform: translate(30px, -20px) scale(1.05); }
  66%  { transform: translate(-20px, 15px) scale(0.97); }
  100% { transform: translate(10px, 25px) scale(1.02); }
}

/* ─── Header ─── */
.header-light {
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border-bottom: 1px solid var(--color-border);
  z-index: 1000;
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
  isolation: isolate;
  transition: box-shadow 0.3s var(--ease-out);
}
.header-light.scrolled {
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.06);
}

/* nav links — underline slide */
.nav-link {
  position: relative;
  color: var(--color-text-muted);
  transition: color 0.25s ease;
}
.nav-link::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-primary);
  border-radius: 1px;
  transition: width 0.3s var(--ease-out);
}
.nav-link:hover {
  color: var(--color-primary);
}
.nav-link:hover::after {
  width: 100%;
}

/* ─── Buttons ─── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 0.85rem;
  padding: 0.75rem 1.3rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  color: #fff;
  background: linear-gradient(135deg, var(--color-primary) 0%, #0062cc 100%);
  box-shadow: 0 8px 28px rgba(17, 158, 224, 0.28);
  border: none;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition:
    transform 0.25s var(--ease-spring),
    box-shadow 0.25s ease;
}
/* shimmer sweep */
.btn-primary::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(
    105deg,
    transparent 30%,
    rgba(255, 255, 255, 0.28) 50%,
    transparent 70%
  );
  animation: shimmer 3.2s 1.2s ease-in-out infinite;
}
@keyframes shimmer {
  0%   { left: -100%; }
  100% { left: 140%; }
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 36px rgba(17, 158, 224, 0.35);
}
.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 0.85rem;
  padding: 0.75rem 1.3rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--color-text);
  background: var(--color-bg);
  border: 1.5px solid var(--color-border);
  cursor: pointer;
  transition:
    transform 0.25s var(--ease-spring),
    border-color 0.25s ease,
    box-shadow 0.25s ease,
    background 0.25s ease;
}
.btn-secondary:hover {
  transform: translateY(-2px);
  border-color: var(--color-primary);
  box-shadow: var(--shadow-card);
  background: var(--color-bg-subtle);
}

/* ─── Display headings ─── */
.heading-display {
  font-family: var(--font-display);
  color: var(--color-text);
  letter-spacing: -0.02em;
  line-height: 1.15;
}

/* Yellow accent bar under section titles */
.heading-accent {
  display: inline-block;
  position: relative;
}
.heading-accent::after {
  content: "";
  position: absolute;
  bottom: 2px;
  left: 0;
  width: 100%;
  height: 10px;
  background: var(--color-highlight);
  z-index: -1;
  border-radius: 2px;
  opacity: 0.7;
}

/* ─── Shadow helpers ─── */
.shadow-soft { box-shadow: var(--shadow-soft); }

/* ─── Mini cards (bento) ─── */
.card-mini {
  border-radius: 1.1rem;
  border: 1px solid var(--color-border);
  background: var(--color-bg-card);
  padding: 1.1rem;
  transition:
    transform 0.3s var(--ease-out),
    border-color 0.3s ease,
    box-shadow 0.3s ease;
}
.card-mini:hover {
  transform: translateY(-3px);
  border-color: var(--color-primary);
  box-shadow: var(--shadow-card-hover);
}
.card-mini-title {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--color-text);
}
.card-mini-desc {
  margin-top: 0.3rem;
  font-size: 0.83rem;
  color: var(--color-text-muted);
  line-height: 1.45;
}

/* ─── Pain-point cards ─── */
.card {
  border-radius: 1.2rem;
  border: 1px solid var(--color-border);
  background: var(--color-bg-card);
  padding: 1.25rem;
  position: relative;
  overflow: hidden;
  transition:
    transform 0.3s var(--ease-out),
    border-color 0.3s ease,
    box-shadow 0.3s ease;
}
/* subtle corner accent on hover */
.card::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 3px;
  height: 0;
  background: var(--color-primary);
  border-radius: 0 0 2px 0;
  transition: height 0.35s var(--ease-out);
}
.card:hover {
  transform: translateY(-3px);
  border-color: var(--color-primary);
  box-shadow: var(--shadow-card-hover);
}
.card:hover::before {
  height: 48px;
}
.card-title {
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--color-text);
}
.card-desc {
  margin-top: 0.45rem;
  color: var(--color-text-muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

/* ─── Feature cards ─── */
.feature {
  border-radius: 1.2rem;
  border: 1px solid var(--color-border);
  background: var(--color-bg-card);
  padding: 1.4rem;
  transition:
    transform 0.3s var(--ease-out),
    border-color 0.3s ease,
    box-shadow 0.3s ease,
    background 0.3s ease;
}
.feature:hover {
  transform: translateY(-3px);
  border-color: var(--color-primary);
  box-shadow: var(--shadow-card-hover);
  background: #fff;
}
.feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 2rem;
  padding: 0 0.7rem;
  border-radius: 0.7rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--color-primary);
  background: rgba(17, 158, 224, 0.07);
  border: 1px solid rgba(17, 158, 224, 0.18);
  transition: transform 0.4s var(--ease-spring);
}
.feature:hover .feature-icon {
  transform: rotate(4deg) scale(1.08);
}
.feature-title {
  margin-top: 0.9rem;
  font-weight: 700;
  color: var(--color-text);
}
.feature-desc {
  margin-top: 0.45rem;
  color: var(--color-text-muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

/* ─── Cycle steps ─── */
.steps-row {
  position: relative;
}
/* connecting line between steps */
.steps-row::before {
  content: "";
  position: absolute;
  top: 1rem;
  left: 2rem;
  right: 2rem;
  height: 2px;
  background: linear-gradient(
    90deg,
    var(--color-secondary),
    var(--color-primary),
    var(--color-secondary)
  );
  border-radius: 1px;
  opacity: 0.22;
  z-index: 0;
}
/* animated fill */
.steps-row::after {
  content: "";
  position: absolute;
  top: 1rem;
  left: 2rem;
  width: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    var(--color-secondary),
    var(--color-primary)
  );
  border-radius: 1px;
  z-index: 1;
  transition: width 1.2s var(--ease-out);
}
.steps-row.line-animate::after {
  width: calc(100% - 4rem);
}

.step {
  border-radius: 1.2rem;
  border: 1px solid var(--color-border);
  background: var(--color-bg-card);
  padding: 1.3rem;
  position: relative;
  z-index: 2;
  transition:
    transform 0.3s var(--ease-out),
    border-color 0.3s ease,
    box-shadow 0.3s ease;
}
.step:hover {
  transform: translateY(-3px);
  border-color: var(--color-secondary);
  box-shadow: var(--shadow-card-hover);
}
.step-badge {
  display: inline-flex;
  height: 2.1rem;
  width: 2.1rem;
  align-items: center;
  justify-content: center;
  border-radius: 0.75rem;
  font-weight: 900;
  font-size: 0.92rem;
  color: #fff;
  background: var(--color-secondary);
  box-shadow: 0 4px 12px rgba(228, 12, 127, 0.3);
  transition: transform 0.35s var(--ease-spring);
}
.step:hover .step-badge {
  transform: scale(1.12) rotate(-3deg);
}
.step-title {
  margin-top: 0.9rem;
  font-weight: 700;
  color: var(--color-text);
}
.step-desc {
  margin-top: 0.45rem;
  color: var(--color-text-muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

/* ─── Quotes ─── */
.quote {
  border-radius: 1.2rem;
  border: 1px solid var(--color-border);
  background: var(--color-bg-card);
  padding: 1.6rem 1.4rem 1.4rem;
  position: relative;
  overflow: hidden;
  transition:
    transform 0.3s var(--ease-out),
    border-color 0.3s ease,
    box-shadow 0.3s ease;
}
.quote:hover {
  transform: translateY(-3px);
  border-color: var(--color-secondary);
  box-shadow: var(--shadow-card-hover);
}
/* big decorative quote mark */
.quote-mark {
  position: absolute;
  top: 2px;
  left: 14px;
  font-family: var(--font-display);
  font-size: 6.5rem;
  line-height: 0.85;
  color: var(--color-secondary);
  opacity: 0.08;
  font-weight: 800;
  pointer-events: none;
  transition: opacity 0.4s ease, transform 0.4s var(--ease-out);
}
.quote:hover .quote-mark {
  opacity: 0.18;
  transform: scale(1.08);
}
.quote blockquote {
  font-weight: 600;
  color: var(--color-text);
  letter-spacing: -0.01em;
  line-height: 1.5;
  position: relative;
  z-index: 1;
}
.quote figcaption {
  margin-top: 0.8rem;
  font-size: 0.83rem;
  color: var(--color-text-muted);
  position: relative;
  z-index: 1;
}

/* ─── FAQ items (statiques, pas d'accordion) ─── */
.faq-item {
  border-radius: 1.2rem;
  border: 1px solid var(--color-border);
  background: var(--color-bg-card);
  padding: 1.2rem 1.25rem;
  transition:
    border-color 0.3s ease,
    box-shadow 0.3s ease;
}
.faq-item:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-card);
}
.faq-item-title {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--color-text);
  line-height: 1.4;
}
.faq-item-desc {
  margin-top: 0.5rem;
  color: var(--color-text-muted);
  font-size: 0.9rem;
  line-height: 1.55;
}

/* ─── Reveal on scroll — staggered children ─── */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity 0.7s var(--ease-out),
    transform 0.7s var(--ease-out);
  will-change: opacity, transform;
}
.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* stagger direct children when parent has .stagger */
.stagger > * {
  opacity: 0;
  transform: translateY(14px);
  transition:
    opacity 0.55s var(--ease-out),
    transform 0.55s var(--ease-out);
}
.stagger.in-view > *:nth-child(1) { transition-delay: 0.05s; }
.stagger.in-view > *:nth-child(2) { transition-delay: 0.12s; }
.stagger.in-view > *:nth-child(3) { transition-delay: 0.19s; }
.stagger.in-view > *:nth-child(4) { transition-delay: 0.26s; }
.stagger.in-view > *:nth-child(5) { transition-delay: 0.33s; }
.stagger.in-view > *:nth-child(6) { transition-delay: 0.4s; }
.stagger.in-view > *:nth-child(7) { transition-delay: 0.47s; }
.stagger.in-view > *:nth-child(8) { transition-delay: 0.54s; }
.stagger.in-view > * {
  opacity: 1;
  transform: translateY(0);
}

/* ─── Glow dot (live indicator) ─── */
.glow-dot {
  box-shadow: 0 0 0 0 rgba(17, 158, 224, 0.55);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(17, 158, 224, 0.45); }
  70%  { box-shadow: 0 0 0 8px rgba(17, 158, 224, 0); }
  100% { box-shadow: 0 0 0 0 rgba(17, 158, 224, 0); }
}

/* ─── Counter number spin-up ─── */
.counter-num {
  display: inline-block;
  transition: transform 0.6s var(--ease-spring);
}
.counter-num.pop {
  animation: numPop 0.5s var(--ease-spring);
}
@keyframes numPop {
  0%   { transform: translateY(12px); opacity: 0; }
  60%  { transform: translateY(-3px); opacity: 1; }
  100% { transform: translateY(0); opacity: 1; }
}

/* ─── Stats bar ─── */
.stat-item {
  text-align: center;
}
.stat-value {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 2rem;
  color: var(--color-text);
  letter-spacing: -0.03em;
  line-height: 1;
}
.stat-label {
  margin-top: 0.35rem;
  font-size: 0.82rem;
  color: var(--color-text-muted);
  font-weight: 500;
}

/* ─── Dashboard image wrapper ─── */
.dashboard-wrap {
  position: relative;
}
.dashboard-wrap img {
  position: relative;
  z-index: 1;
  transition: transform 0.5s var(--ease-out);
}
.dashboard-wrap:hover img {
  transform: scale(1.015);
}
/* glow behind screenshot */
.dashboard-wrap::before {
  content: "";
  position: absolute;
  inset: 12px -12px -12px 12px;
  background: linear-gradient(135deg, rgba(0,123,255,0.12), rgba(0,86,179,0.08));
  border-radius: 1.5rem;
  filter: blur(12px);
  z-index: 0;
}

/* ─── CTA section bottom band ─── */
.cta-band {
  position: relative;
  overflow: hidden;
}
.cta-band::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0,123,255,0.04) 0%, rgba(0,86,179,0.03) 100%);
  pointer-events: none;
}

/* ─── Footer ─── */
footer {
  background: var(--color-bg);
  border-top: 1px solid var(--color-border);
}

/* ─── Mobile ─── */
@media (max-width: 640px) {
  .header-light {
    background: #fff;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
  header .btn-primary {
    padding: 0.5rem 0.85rem;
    font-size: 0.8rem;
    border-radius: 0.7rem;
  }
  .steps-row::before,
  .steps-row::after {
    display: none;
  }
}

/* ─── Reduce motion ─── */
@media (prefers-reduced-motion: reduce) {
  .reveal, .stagger > * {
    transition: none !important;
    transform: none !important;
    opacity: 1 !important;
  }
  .glow-dot { animation: none; }
  .btn-primary::before { animation: none; display: none; }
  .blob { animation: none; }
  .card-mini, .card, .feature, .step, .quote, .faq-item {
    transition: none !important;
  }
  .feature-icon, .step-badge, .quote-mark {
    transition: none !important;
  }
  .steps-row::after { transition: none; width: calc(100% - 4rem) !important; }
}
