/* ===========================================================
   Camino Financiero — estilos custom
   Tipografía: Outfit (heading) + Manrope (body) + JetBrains Mono
   =========================================================== */

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: "ss01", "cv11";
}

::selection {
  background: rgba(104, 44, 205, 0.95);
  color: #FFFFFF;
}

:focus-visible {
  outline: 2px solid #682CCD;
  outline-offset: 3px;
  border-radius: 4px;
}

/* Outfit con micro-ajustes */
.font-heading {
  font-feature-settings: "ss01", "ss02", "cv11";
  font-optical-sizing: auto;
}

/* JetBrains Mono — números tabulares para fintech */
.font-mono {
  font-feature-settings: "tnum", "ss02";
}

/* ============ GRAIN OVERLAY ============ */
.grain-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 60;
  opacity: 0.035;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ============ HERO MESH ============ */
.hero-mesh {
  background:
    radial-gradient(50% 50% at 80% 10%, rgba(245, 93, 174, 0.18) 0%, rgba(245, 93, 174, 0) 60%),
    radial-gradient(45% 45% at 10% 20%, rgba(104, 44, 205, 0.18) 0%, rgba(104, 44, 205, 0) 70%),
    radial-gradient(40% 40% at 30% 80%, rgba(243, 175, 19, 0.10) 0%, rgba(243, 175, 19, 0) 70%),
    radial-gradient(50% 50% at 70% 90%, rgba(70, 148, 250, 0.10) 0%, rgba(70, 148, 250, 0) 70%),
    linear-gradient(180deg, #FCFAFF 0%, #FAF8FF 100%);
}

/* ============ STICKERS FLOTANTES ============ */
@keyframes float-y {
  0%, 100% { transform: translateY(0) rotate(var(--rot, -6deg)); }
  50%      { transform: translateY(-12px) rotate(calc(var(--rot, -6deg) + 2deg)); }
}
.sticker-float        { --rot: -6deg; animation: float-y 6s ease-in-out infinite; }
.sticker-float-delayed{ --rot: 6deg;  animation: float-y 7s ease-in-out -2s infinite; }
.sticker-float-slow   { --rot: -3deg; animation: float-y 9s ease-in-out -4s infinite; }

/* ============ MARQUEE ============ */
@keyframes marquee {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
.marquee {
  animation: marquee 38s linear infinite;
  will-change: transform;
}
.marquee:hover { animation-play-state: paused; }

/* ============ SCROLL REVEAL ============ */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s cubic-bezier(0.2, 0.65, 0.25, 1),
              transform 0.8s cubic-bezier(0.2, 0.65, 0.25, 1);
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============ ESTADOS DEL FORM ============ */
.field-error {
  border-color: #FD665B !important;
  box-shadow: 0 0 0 1px #FD665B;
}
.status-error   { color: #FD665B; font-weight: 500; }
.status-success { color: #41CC94; font-weight: 500; }

/* ============ PROSE LEGAL ============ */
.prose-legal h2 {
  font-family: 'Outfit', system-ui, sans-serif;
  font-size: clamp(1.35rem, 2.5vw, 1.75rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
  color: #0B0418;
}
.prose-legal h3 {
  font-family: 'Outfit', system-ui, sans-serif;
  font-size: 1.15rem;
  font-weight: 600;
  margin-top: 1.75rem;
  margin-bottom: 0.5rem;
  color: #0B0418;
}
.prose-legal p,
.prose-legal li {
  color: rgba(11, 4, 24, 0.78);
  line-height: 1.75;
  margin-bottom: 0.75rem;
  font-size: 0.975rem;
}
.prose-legal ul,
.prose-legal ol {
  margin-left: 1.25rem;
  margin-bottom: 1rem;
}
.prose-legal ul { list-style: disc; }
.prose-legal ol { list-style: decimal; }
.prose-legal a {
  color: #4F1FA3;
  text-decoration: underline;
  text-decoration-color: rgba(104, 44, 205, 0.3);
  text-underline-offset: 2px;
  transition: text-decoration-color 0.2s;
}
.prose-legal a:hover { text-decoration-color: #4F1FA3; }
.prose-legal strong  { color: #0B0418; font-weight: 600; }
.prose-legal hr {
  border: 0;
  border-top: 1px solid #E8E2F4;
  margin: 2rem 0;
}

/* ============ MOTION REDUCED ============ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  .marquee { animation: none; }
  .sticker-float, .sticker-float-delayed, .sticker-float-slow { animation: none; }
}
