/* ==========================================================================
   FAi Agentes — subpágina /agentes/ (vista previa)
   Paleta y tipografías de Fabio AI. Un solo acento: naranja #E85002.
   ========================================================================== */

:root {
  --orange: #E85002;
  --orange-hot: #F16001;
  --black: #000000;
  --white: #F9F9F9;
  --sand: #D9C3AB;
  --bone: #EEE6DE;
  --gray-600: #555555;
  --line: rgba(0, 0, 0, .18);
  --font-display: "Bricolage Grotesque", "Arial Black", Arial, sans-serif;
  --font-ui: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-serif: "Instrument Serif", Georgia, serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --wrap: 1200px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  /* Respaldo si el video no carga: negro con degradado naranja sutil */
  background: radial-gradient(120% 80% at 80% 100%, rgba(232, 80, 2, .28), transparent 60%), var(--black);
  background-attachment: fixed;
  color: var(--black);
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, video, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; background: none; border: 0; padding: 0; }
h1, h2, h3, p, ol, ul { margin: 0; }
ol, ul { padding: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; border-radius: 6px; }
[hidden] { display: none !important; }

.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--black); color: var(--white); padding: 10px 16px; border-radius: 999px; }
.skip:focus { top: 12px; }

.wrap { width: min(var(--wrap), 100% - 64px); margin-inline: auto; }

/* ---------- Video de fondo fijo ---------- */
.bg { position: fixed; inset: 0; z-index: 0; pointer-events: none; }
.bg__video { width: 100%; height: 100%; object-fit: cover; }
.bg__shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.45) 0%, rgba(0,0,0,.6) 55%, rgba(0,0,0,.75) 100%); }
main, .footer { position: relative; z-index: 1; }

/* ---------- FadeUp ---------- */
.fade { opacity: 0; transform: translateY(24px); transition: opacity .7s var(--ease), transform .7s var(--ease); transition-delay: var(--d, 0s); }
.fade.is-in { opacity: 1; transform: none; }
.words .w { display: inline-block; opacity: 0; transform: translateY(32px); transition: opacity .7s var(--ease), transform .7s var(--ease); transition-delay: var(--d, 0s); }
.words.is-in .w { opacity: 1; transform: none; }
.no-js .fade, .no-js .words .w { opacity: 1; transform: none; }

/* ---------- Nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 20px 32px;
  border-bottom: 1px solid var(--line);
  background: transparent;
  transition: background .3s, backdrop-filter .3s;
}
.nav.is-scrolled { background: rgba(249, 249, 249, .86); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.nav__brand { display: flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 700; letter-spacing: .12em; }
.nav__brand img { width: 28px; height: 28px; }
.ai { color: var(--orange); }
.nav__center { display: flex; gap: 48px; }
.nav__right { display: flex; gap: 32px; }
.nav__center a, .nav__right a { font-size: 11px; font-weight: 600; letter-spacing: .06em; transition: opacity .2s; }
.nav__center a:hover, .nav__right a:hover, .nav__brand:hover { opacity: .6; }
.nav__toggle { display: none; width: 40px; height: 40px; position: relative; }
.nav__toggle span { position: absolute; left: 10px; right: 10px; height: 1.5px; background: currentColor; transition: transform .3s var(--ease); }
.nav__toggle span:first-child { top: 16px; }
.nav__toggle span:last-child { top: 23px; }
.nav__toggle[aria-expanded="true"] span:first-child { transform: translateY(3.5px) rotate(45deg); }
.nav__toggle[aria-expanded="true"] span:last-child { transform: translateY(-3.5px) rotate(-45deg); }
.nav__menu {
  position: absolute; top: 100%; left: 0; right: 0;
  display: flex; flex-direction: column;
  background: rgba(249, 249, 249, .97); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line); padding: 8px 18px 18px;
}
.nav__menu a { padding: 14px 0; font-size: 13px; font-weight: 600; letter-spacing: .06em; border-bottom: 1px solid rgba(0,0,0,.08); }
.nav__menu a:last-child { border-bottom: 0; color: var(--orange); }

/* ---------- Píldoras ---------- */
.btns { display: flex; gap: 12px; flex-wrap: wrap; }
.pill {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 46px; padding: 0 24px; border-radius: 999px;
  font-size: 12px; font-weight: 700; letter-spacing: .06em; text-align: center;
  border: 1.5px solid transparent;
  transition: background .25s, color .25s, border-color .25s, transform .25s var(--ease);
}
.pill:hover { transform: translateY(-1px); }
.pill--lg { min-height: 54px; padding: 0 30px; font-size: 13px; }
/* Acción (WhatsApp / agenda): naranja sólido, texto blanco, pulso */
.pill--primary, .pill--orange, .pill[data-wa], .pill--ghost-light { background: var(--orange); border-color: var(--orange); color: #fff; animation: pillPulse 2.2s ease-in-out infinite; }
.pill--primary:hover, .pill--orange:hover, .pill[data-wa]:hover, .pill--ghost-light:hover,
.pill--primary:focus-visible, .pill--orange:focus-visible, .pill[data-wa]:focus-visible, .pill--ghost-light:focus-visible { background: var(--orange-hot); border-color: var(--orange-hot); color: #fff; animation: none; }
/* No-acción (navegación/secundarios): negro, hover relleno negro */
.pill--ghost:not([data-wa]) { background: transparent; border-color: #1a1a1a; color: #1a1a1a; animation: none; }
.pill--ghost:not([data-wa]):hover { background: #1a1a1a; border-color: #1a1a1a; color: #fff; }
@keyframes pillPulse {
  0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(232, 80, 2, .55); }
  50% { transform: scale(1.03); box-shadow: 0 0 0 12px rgba(232, 80, 2, 0); }
}

.counter { font-family: var(--font-ui); font-size: 12px; font-weight: 600; letter-spacing: .12em; color: var(--gray-600); }
.counter--light { color: rgba(249, 249, 249, .75); }

/* ---------- Hero ---------- */
.hero { position: relative; height: 100vh; height: 100svh; min-height: 600px; }
.hero__top { position: absolute; top: 0; left: 0; right: 0; height: 48%; background: var(--bone); padding: 70px 32px 0; display: flex; align-items: center; }
.hero__row { display: flex; gap: 48px; width: 100%; align-items: flex-end; }
.hero__left { flex: 0 0 32%; display: flex; flex-direction: column; gap: 18px; }
.hero__right { flex: 1; display: flex; flex-direction: column; gap: 24px; max-width: 640px; margin-left: auto; }
.hero__title { font-family: var(--font-display); font-size: clamp(26px, 3vw, 42px); font-weight: 700; text-transform: uppercase; line-height: 1.05; letter-spacing: -.02em; }
.hero__lede { font-size: 18px; line-height: 1.45; color: #1a1a1a; }
.hero__bottom { position: absolute; top: auto; bottom: 92px; left: 0; right: 0; padding: 0 32px; text-align: center; color: #fff; font-family: var(--font-display); font-weight: 800; text-transform: uppercase; text-shadow: 0 2px 24px rgba(0,0,0,.45); }
.hero__bottom .ln { display: block; white-space: nowrap; }
.hero__bottom .ln--kicker { font-size: clamp(13px, 1.4vw, 18px); font-weight: 600; letter-spacing: .12em; line-height: 1.3; color: rgba(255,255,255,.85); margin-bottom: clamp(8px, 1.4vh, 16px); }
.hero__bottom .ln--big { font-size: clamp(40px, min(7vw, 12vh), 104px); font-weight: 800; line-height: .95; letter-spacing: -.02em; }
.hero__bottom .ln--accent { color: #E85002; }
.hero__bottom .ln--big .w { transition-delay: calc(var(--d, 0s) + .25s); }

/* ---------- Declaración ---------- */
.statement { min-height: 100vh; display: flex; align-items: center; color: var(--white); text-align: center; padding: 120px 0; }
.statement__title { font-family: var(--font-display); font-size: clamp(36px, 7vw, 104px); font-weight: 800; line-height: .98; letter-spacing: -.03em; text-shadow: 0 2px 24px rgba(0,0,0,.35); }
.statement__title .ln { display: block; white-space: nowrap; }
.statement__sub { margin: 28px auto 0; max-width: 820px; font-size: 18px; font-weight: 700; font-style: italic; color: rgba(249, 249, 249, .92); text-shadow: 0 1px 12px rgba(0,0,0,.5); }

/* ---------- Secciones claras ---------- */
section[id] { scroll-margin-top: 64px; }
.panel-sec { position: relative; z-index: 2; padding: clamp(80px, 11vw, 140px) 0; }
.panel-sec--light { background: var(--white); }
.panel-sec--bone { background: var(--bone); }
.sec-head { display: flex; flex-direction: column; gap: 18px; max-width: 760px; margin-bottom: 56px; }
.sec-title { font-family: var(--font-display); font-size: clamp(32px, 5vw, 68px); font-weight: 800; line-height: 1; letter-spacing: -.03em; }
.statement__sub .br { color: var(--orange); }
#servicios .sec-head { max-width: 980px; }
.sec-lede { font-size: 18px; color: #333; max-width: 600px; }

/* Tarjetas de servicio */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card { border: 1px solid var(--line); border-radius: 20px; overflow: hidden; background: var(--white); display: flex; flex-direction: column; }
.card__media { aspect-ratio: 4 / 3; background: linear-gradient(135deg, #1a1a1a, #000 60%, rgba(232,80,2,.5)); }
.card__media video { width: 100%; height: 100%; object-fit: cover; }
.card__body { padding: 24px 24px 28px; display: flex; flex-direction: column; gap: 14px; flex: 1; }
.card__list { display: flex; flex-direction: column; gap: 9px; }
.card__list li { position: relative; padding-left: 20px; color: #333; font-size: 15px; }
.card__list li::before { content: ""; position: absolute; left: 0; top: .5em; width: 7px; height: 7px; background: var(--orange); }
.card h3 { font-family: var(--font-display); font-size: 22px; font-weight: 700; letter-spacing: -.02em; }
.card p { color: #333; font-size: 15px; }

/* Proceso */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; counter-reset: s; }
.step { border-top: 2px solid var(--black); padding-top: 22px; display: flex; flex-direction: column; gap: 10px; }
.step__n { font-family: var(--font-serif); font-style: italic; font-size: 44px; line-height: 1; color: var(--orange); }
.step h3 { font-family: var(--font-display); font-size: 20px; font-weight: 700; letter-spacing: -.02em; }
.step p { color: #333; font-size: 15px; }

/* Paquetes */
.pricing { overflow: hidden; }
.tag { display: inline-block; align-self: flex-start; padding: 6px 14px; border-radius: 999px; border: 1px solid var(--orange); color: #B33E00; font-size: 12px; font-weight: 700; letter-spacing: .06em; }
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; align-items: stretch; }
.plan { position: relative; border: 1px solid var(--line); border-radius: 20px; padding: 32px 28px; display: flex; flex-direction: column; gap: 20px; background: var(--white); }
.plan--featured { border: 2px solid var(--orange); background: var(--bone); }
.plan__badge { position: absolute; top: -13px; left: 28px; background: var(--orange); color: var(--black); font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: 4px 12px; border-radius: 999px; }
.plan__name { font-family: var(--font-display); font-size: 24px; font-weight: 700; }
.plan__price { font-family: var(--font-display); font-size: 56px; font-weight: 800; line-height: 1; letter-spacing: -.03em; }
.plan__price span { font-size: 16px; font-weight: 700; vertical-align: top; letter-spacing: .04em; }
.plan__price small { font-family: var(--font-ui); font-size: 15px; font-weight: 500; color: var(--gray-600); letter-spacing: 0; }
.plan__list { display: flex; flex-direction: column; gap: 10px; flex: 1; }
.plan__list li { position: relative; padding-left: 22px; font-size: 15px; color: #222; }
.plan__list li::before { content: ""; position: absolute; left: 0; top: .55em; width: 8px; height: 8px; border-radius: 50%; background: var(--orange); }
.plan__cta { width: 100%; }
.note { margin-top: 32px; font-size: 14px; color: var(--gray-600); }

/* Piloto (sobre el video, oscuro) */
.pilot { position: relative; z-index: 2; padding: clamp(96px, 12vw, 160px) 0; color: var(--white); background: rgba(0, 0, 0, .55); }
.pilot__inner { display: flex; flex-direction: column; gap: 22px; max-width: 820px; }
.pilot__kicker { font-family: var(--font-serif); font-style: italic; font-size: 26px; color: var(--sand); }
.pilot .sec-lede { color: rgba(249, 249, 249, .9); }
.pilot__list { display: flex; flex-direction: column; gap: 10px; }
.pilot__list li { padding-left: 22px; position: relative; color: rgba(249, 249, 249, .92); }
.pilot__list li::before { content: ""; position: absolute; left: 0; top: .55em; width: 8px; height: 8px; border-radius: 50%; background: var(--orange); }

/* FAQ (patrón .faq de la home) */
.faq-layout { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 56px; align-items: start; }
.faq h3 { font: inherit; }
.faq__item { border-top: 1px solid rgba(0, 0, 0, .16); }
.faq__item:last-child { border-bottom: 1px solid rgba(0, 0, 0, .16); }
.faq__q { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 24px; padding: 24px 0; text-align: left; font-size: 18px; font-weight: 600; letter-spacing: -.02em; }
.faq__icon { flex: none; width: 34px; height: 34px; border-radius: 50%; border: 1px solid rgba(0, 0, 0, .25); display: grid; place-items: center; font-size: 20px; line-height: 1; transition: transform .3s var(--ease), background .3s, border-color .3s; }
.faq__q[aria-expanded="true"] .faq__icon { transform: rotate(45deg); background: var(--orange); border-color: var(--orange); }
.faq__panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .4s var(--ease); }
.faq__panel > div { overflow: hidden; }
.faq__item.is-open .faq__panel { grid-template-rows: 1fr; }
.faq__a { padding: 0 60px 26px 0; color: #444; }
.faq__a a { text-decoration: underline; }

/* Contacto */
.contact { position: relative; z-index: 2; padding: clamp(96px, 12vw, 160px) 0; color: var(--white); background: linear-gradient(180deg, rgba(0,0,0,.6), rgba(0,0,0,.85)); }
.contact__inner { display: flex; flex-direction: column; gap: 22px; align-items: flex-start; }
.contact .sec-lede { color: rgba(249, 249, 249, .9); }
.contact__hint { font-size: 15px; color: rgba(249, 249, 249, .85); }
.contact__hint strong { color: var(--orange); letter-spacing: .06em; }

/* Footer */
.footer { z-index: 2; background: var(--black); color: rgba(249, 249, 249, .75); padding: 32px 0; font-size: 14px; border-top: 1px solid #222; }
.footer__inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.footer nav { display: flex; gap: 24px; }
.footer a:hover { color: var(--orange); }

/* Indicador de scroll */
.scroll-ind {
  position: fixed; left: 50%; bottom: 24px; z-index: 40; transform: translateX(-50%);
  width: 22px; height: 36px; border: 1.5px solid var(--white); border-radius: 999px;
  transition: opacity .4s;
}
.scroll-ind span { position: absolute; left: 50%; top: 7px; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: var(--white); animation: scrollBounce 2s infinite; }
.scroll-ind.is-hidden { opacity: 0; }
@keyframes scrollBounce {
  0% { transform: translateY(0); opacity: 1; }
  60% { transform: translateY(14px); opacity: 0; }
  100% { transform: translateY(0); opacity: 0; }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .nav { padding: 16px 18px; }
  .nav__center, .nav__right { display: none; }
  .nav__toggle { display: block; }
  .nav.menu-open { background: rgba(249, 249, 249, .97); }
  .wrap { width: calc(100% - 36px); }
  .hero__top { padding: 70px 18px 24px; }
  .hero__row { flex-direction: column; align-items: stretch; gap: 18px; }
  .hero__left { flex: none; }
  .hero__right { margin-left: 0; gap: 18px; }
  .hero__lede { font-size: 16px; }
  .hero__bottom { padding: 0 18px; }
  .cards, .steps, .plans, .faq-layout { grid-template-columns: 1fr; }
  .faq-layout { gap: 24px; }
  .faq-layout .sec-head { margin-bottom: 0; }
  .plans { gap: 28px; }
}
@media (max-width: 600px) {
  .hero__top { height: 56%; }
  .hero__title { font-size: 26px; }
  .statement__title { font-size: clamp(22px, 7.6vw, 40px); }
  .hero__bottom { bottom: 84px; }
  .hero__bottom .ln--kicker { font-size: 12px; letter-spacing: .1em; }
  .hero__bottom .ln--big { font-size: clamp(36px, 12vw, 56px); }
  .hero__bottom .ln--kicker { white-space: normal; text-wrap: balance; }
  .hero__lede { font-size: 15px; }
  .btns { flex-wrap: wrap; }
  .pill { padding: 0 18px; }
  .faq__a { padding-right: 0; }
}
@media (max-width: 600px) and (max-height: 700px) {
  .hero__top { height: auto; min-height: 56%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; transition-delay: 0s !important; }
  .fade, .words .w { opacity: 1; transform: none; }
}
