/* Agentia Lab — versión minimalista (tema claro) */
:root {
  --paper: #f7f6f2;
  --paper-2: #efede6;
  --card: #ffffff;
  --ink: #0d0f1c;
  --ink-2: #363a4d;
  --muted: #6b6f80;
  --line: #e0ded5;
  /* colores del logo + dorado */
  --violet: #6a45f0;
  --blue: #4f6bff;
  --cyan: #17b4ec;
  --gold: #e7b547;
  --gold-soft: #f6dc95;
  --gold-grad: linear-gradient(135deg, #f8d98a, #e6ad42);
  --display: "Bricolage Grotesque", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --body: "Instrument Sans", "Helvetica Neue", "Segoe UI", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --gutter: clamp(16px, 5vw, 56px);
  --radius: 14px;
  --nav-h: 72px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 12px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink-2);
  font: 400 1.0625rem/1.6 var(--body);
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--display); color: var(--ink); line-height: 1.08; margin: 0; letter-spacing: -0.025em; text-wrap: balance; }
p { margin: 0; }
:focus-visible { outline: 2px solid var(--violet); outline-offset: 3px; border-radius: 6px; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 8px; }
.skip:focus { left: 8px; }

.wrap { width: 100%; max-width: 1160px; margin-inline: auto; padding-inline: var(--gutter); }

/* Etiqueta pequeña sobre títulos */
.label {
  display: inline-flex; align-items: center; gap: 10px;
  font: 500 .78rem/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted);
}
.label .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 4px rgba(231,181,71,.22); }
.label .num { color: var(--violet); }

/* Botones */
.btn {
  --h: 52px;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: var(--h); padding: 0 24px; border-radius: 999px; border: 1px solid transparent;
  font: 600 1rem/1 var(--body); text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color .2s ease, border-color .2s ease, color .2s ease, transform .2s ease;
}
.btn:active { transform: translateY(1px); }
.btn svg { width: 20px; height: 20px; }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: var(--violet); }
.btn-line { border-color: #cfccc1; color: var(--ink); background: transparent; }
.btn-line:hover { border-color: var(--ink); }
.btn-gold { background: var(--gold-grad); color: #1b1405; }
.btn-gold:hover { filter: brightness(1.06); }
.btn-sm { --h: 42px; padding: 0 20px; font-size: .95rem; }

/* Menú */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(247,246,242,.86); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent; transition: border-color .2s ease;
}
.nav.is-scrolled { border-color: var(--line); }
.nav-row { height: var(--nav-h); display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand img { height: 34px; width: auto; }
.nav-links { display: flex; gap: 30px; }
.nav-links a { text-decoration: none; font-weight: 500; font-size: .98rem; color: var(--ink-2); }
.nav-links a:hover { color: var(--violet); }
@media (max-width: 820px) { .nav-links { display: none; } .brand img { height: 30px; } }

/* Portada: escenario oscuro con el video de Seedance */
.hero { padding: 8px clamp(8px, 1.4vw, 16px) 0; }
.hero-stage {
  position: relative; overflow: hidden; isolation: isolate;
  border-radius: clamp(18px, 2.4vw, 28px); background: #0a0c17; color: #c9ccd9;
  min-height: min(88svh, 820px); display: flex;
}
.hero-media { position: absolute; inset: 0; z-index: -1; }
.hero-video { width: 100%; height: 100%; object-fit: cover; object-position: 70% center; }
.hero-media::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(10,12,23,.92) 0%, rgba(10,12,23,.72) 38%, rgba(10,12,23,.15) 75%),
    linear-gradient(0deg, rgba(10,12,23,.9) 0%, transparent 38%);
}
.hero-inner { display: flex; flex-direction: column; justify-content: space-between; gap: 48px; padding-block: clamp(56px, 9vw, 112px) 0; }
.hero-copy { display: grid; gap: 24px; justify-items: start; max-width: 640px; }
.hero .label { color: #aab0c4; }
.hero h1 { color: #fff; font-size: clamp(2.6rem, 6vw, 4.8rem); font-weight: 800; letter-spacing: -0.035em; }
.hero h1 mark {
  color: inherit; background: linear-gradient(90deg, #f8d98a, #eab44a);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.hero h1 em {
  font-style: normal;
  background: linear-gradient(90deg, #a58bff, #7f9bff 55%, #4fd2ff);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.lead { font-size: clamp(1.08rem, 1.5vw, 1.22rem); max-width: 34em; color: #d3d6e2; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; padding-top: 4px; }
.hero .btn-dark { background: var(--gold-grad); color: #1b1405; }
.hero .btn-dark:hover { background: var(--gold-grad); filter: brightness(1.06); }
.hero .btn-line { border-color: rgba(255,255,255,.35); color: #fff; background: rgba(10,12,23,.3); backdrop-filter: blur(6px); }
.hero .btn-line:hover { border-color: #fff; }

/* Datos clave (dentro de la portada) */
.facts { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid rgba(255,255,255,.18); }
.facts li { display: grid; gap: 4px; padding: 24px 24px 32px 0; }
.facts li + li { padding-left: 24px; border-left: 1px solid rgba(255,255,255,.12); }
.facts b { font: 700 1.2rem/1.2 var(--display); color: #fff; letter-spacing: -0.01em; }
.facts span { font-size: .93rem; color: #9ea3b8; }

@media (max-width: 900px) {
  .hero-stage { min-height: 0; }
  .hero-video { object-position: center top; }
  .hero-media::after { background: linear-gradient(0deg, rgba(10,12,23,.96) 0%, rgba(10,12,23,.85) 55%, rgba(10,12,23,.35) 100%); }
  .facts { grid-template-columns: 1fr 1fr; }
  .facts li:nth-child(3) { padding-left: 0; border-left: 0; }
  .facts li:nth-child(n+3) { border-top: 1px solid rgba(255,255,255,.12); }
}
@media (max-width: 520px) {
  .cta-row { width: 100%; }
  .cta-row .btn { flex: 1 1 100%; }
  .facts li { padding: 18px 12px 22px 0; }
  .facts li + li { padding-left: 12px; }
  .facts li:nth-child(3) { padding-left: 0; }
}

/* Secciones */
.section { padding: clamp(72px, 10vw, 128px) 0; }
.section-tint {
  background:
    radial-gradient(60% 50% at 0% 0%, rgba(106,69,240,.07), transparent 70%),
    radial-gradient(50% 45% at 100% 100%, rgba(231,181,71,.10), transparent 70%),
    radial-gradient(circle, rgba(13,15,28,.07) 1px, transparent 1.2px) 0 0 / 22px 22px,
    var(--paper-2);
}
#planes {
  background:
    radial-gradient(45% 40% at 100% 0%, rgba(231,181,71,.12), transparent 70%),
    radial-gradient(45% 45% at 0% 60%, rgba(106,69,240,.08), transparent 70%);
}
#servicios, #preguntas { background: radial-gradient(50% 60% at 100% 30%, rgba(106,69,240,.06), transparent 70%); }
.sec-head { display: grid; gap: 16px; margin-bottom: clamp(36px, 5vw, 56px); max-width: 640px; }
.sec-head h2 { font-size: clamp(2rem, 4vw, 3rem); font-weight: 700; }
.sec-head-row { max-width: none; grid-template-columns: 1fr auto; align-items: end; gap: 16px 48px; }
.sec-sub { color: var(--muted); max-width: 26em; }
@media (max-width: 820px) { .sec-head-row { grid-template-columns: 1fr; } }

/* Servicios */
.services { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 64px; border-top: 1px solid var(--ink); }
.services article { position: relative; display: grid; gap: 14px; align-content: start; padding: 32px 0 8px; }
.services article + article::before { content: ""; position: absolute; left: -32px; top: 0; bottom: 0; border-left: 1px solid var(--line); }
.services h3 { font-size: 1.45rem; font-weight: 700; }
.svc-media { margin: 0 0 8px; border-radius: 12px; overflow: hidden; aspect-ratio: 1 / 1; background: var(--ink); box-shadow: 0 24px 40px -28px rgba(13,15,28,.5); }
.svc-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.services article:hover .svc-media img { transform: scale(1.04); }
.svc-flow { display: flex; flex-direction: column; font: 400 .8rem/1.5 var(--mono); color: #c9ccd9;
  background: radial-gradient(80% 70% at 100% 0%, rgba(106,69,240,.35), transparent 70%), radial-gradient(60% 60% at 0% 100%, rgba(231,181,71,.16), transparent 70%), #0d0f1c; }
.flow-bar { display: flex; align-items: center; gap: 5px; padding: 9px 12px; border-bottom: 1px solid rgba(255,255,255,.08); color: #8d92a8; font-size: .7rem; }
.flow-bar i { width: 7px; height: 7px; border-radius: 50%; background: #2c3150; }
.flow-bar em { font-style: normal; margin-left: 8px; }
.svc-flow ol { list-style: none; margin: 0; padding: 12px 16px; display: grid; gap: 6px; }
.services .svc-flow li { display: flex; align-items: baseline; gap: 8px; padding: 0 !important; color: #dfe2ee; font-size: .8rem !important; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.services .svc-flow li::before { display: none; }
.svc-flow b { color: #8d92a8; font-weight: 400; flex: none; }
.svc-flow span { color: var(--gold); flex: none; }
.services ul { list-style: none; padding: 6px 0 0; margin: 0; display: grid; gap: 8px; }
.services li { position: relative; padding-left: 22px; font-size: .97rem; color: var(--ink); }
.services li::before { content: ""; position: absolute; left: 0; top: .62em; width: 10px; height: 2px; background: var(--gold); }
@media (max-width: 860px) {
  .services { grid-template-columns: 1fr; column-gap: 0; }
  .services article, .services article + article { padding: 28px 0; border-left: 0; }
  .services article + article::before { display: none; }
  .services article + article { border-top: 1px solid var(--line); }
}

/* Proyectos */
.projects { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.project { display: grid; gap: 12px; align-content: start; text-decoration: none; }
.project figure {
  margin: 0 0 6px; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: var(--card);
  box-shadow: 0 20px 40px -28px rgba(13,15,28,.35);
}
.project img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top; transition: transform .5s ease; }
.project:hover img { transform: scale(1.03); }
.project-meta { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.project h3 { font-size: 1.3rem; font-weight: 700; }
.project h3::after { content: " ↗"; font-family: var(--body); font-weight: 500; color: var(--violet); opacity: 0; transition: opacity .2s ease; }
.project:hover h3::after { opacity: 1; }
.project-meta span { font: 500 .72rem/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.project p { color: var(--muted); font-size: .98rem; }
@media (max-width: 900px) { .projects { grid-template-columns: 1fr; max-width: 560px; gap: 40px; } }

/* Planes */
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; align-items: stretch; }
.plan {
  display: flex; flex-direction: column; gap: 12px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(26px, 3vw, 34px);
}
.plan-kicker { font: 500 .75rem/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--violet); min-height: 22px; display: flex; align-items: center; }
.plan h3 { font-size: 1.6rem; font-weight: 700; }
.plan-desc { color: var(--muted); }
.plan ul { list-style: none; margin: 10px 0 0; padding: 18px 0 0; border-top: 1px solid var(--line); display: grid; gap: 10px; flex: 1; align-content: start; }
.plan li { position: relative; padding-left: 26px; color: var(--ink); font-size: .98rem; }
.plan li::before {
  content: ""; position: absolute; left: 0; top: .3em; width: 16px; height: 16px; border-radius: 50%;
  background: rgba(106,69,240,.1) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 8.3 7 10.6l4.6-5' fill='none' stroke='%236a45f0' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/100% no-repeat;
}
.plan-time { margin-top: 8px; font: 500 .82rem/1.3 var(--mono); color: var(--muted); }
.plan .btn { margin-top: 6px; width: 100%; }
.plan-featured { background: var(--ink); border-color: var(--ink); color: #c9ccd9; position: relative; overflow: hidden; }
.plan-featured::before {
  content: ""; position: absolute; inset: -40% -30% auto auto; width: 70%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(106,69,240,.45), transparent); pointer-events: none;
}
.plan-featured > * { position: relative; }
.plan-featured h3 { color: #fff; }
.plan-featured .plan-desc, .plan-featured .plan-time { color: #9ea3b8; }
.plan-featured ul { border-color: #2a2e44; }
.plan-featured li { color: #eef0f7; }
.plan-featured li::before {
  background-color: rgba(231,181,71,.16);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 8.3 7 10.6l4.6-5' fill='none' stroke='%23f0c35a' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}
.badge { display: inline-block; padding: 5px 10px; border-radius: 999px; background: var(--gold-grad); color: #1b1405; font: 600 .7rem/1 var(--mono); letter-spacing: .08em; }
@media (max-width: 960px) { .plans { grid-template-columns: 1fr; max-width: 560px; } }

/* Proceso + por qué */
.two-col { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(40px, 6vw, 96px); align-items: start; }
.steps { list-style: none; margin: 0; padding: 0; counter-reset: s; display: grid; }
.steps li { counter-increment: s; display: grid; grid-template-columns: 48px 1fr; gap: 12px; padding: 18px 0; border-top: 1px solid var(--line); color: var(--muted); }
.steps li:last-child { border-bottom: 1px solid var(--line); }
.steps li::before { content: "0" counter(s); font: 500 .85rem/1.9 var(--mono); color: var(--violet); }
.steps b { color: var(--ink); font-weight: 600; }
.why { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(26px, 3.4vw, 40px); }
.why h3 { font-size: 1.5rem; font-weight: 700; margin-bottom: 8px; }
.why dl { margin: 0; display: grid; }
.why dl > div { padding: 16px 0; border-bottom: 1px solid var(--line); }
.why dl > div:last-child { border-bottom: 0; padding-bottom: 0; }
.why dt { font-weight: 600; color: var(--ink); }
.why dd { margin: 2px 0 0; color: var(--muted); font-size: .97rem; }
@media (max-width: 900px) { .two-col { grid-template-columns: 1fr; } }

/* Preguntas */
.two-col-faq { grid-template-columns: .8fr 1.2fr; }
.faq { border-top: 1px solid var(--ink); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 22px 0; font: 600 1.1rem/1.35 var(--body); color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 400 1.6rem/1 var(--display); color: var(--violet); transition: transform .25s ease; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq summary:hover { color: var(--violet); }
.faq details p { padding: 0 0 22px; max-width: 40em; color: var(--muted); }
@media (max-width: 900px) { .two-col-faq { grid-template-columns: 1fr; } .two-col-faq .sec-head { margin-bottom: 8px; } }

/* Cierre */
.closing { padding: 0 var(--gutter) clamp(72px, 10vw, 120px); }
.closing-inner {
  max-width: 1160px; margin-inline: auto; padding: clamp(48px, 8vw, 96px) var(--gutter);
  background: var(--ink); border-radius: 24px; text-align: center; color: #b9bdcc;
  display: grid; justify-items: center; gap: 18px; position: relative; overflow: hidden;
}
.closing-inner::before {
  content: ""; position: absolute; inset: auto auto -60% -10%; width: 60%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(106,69,240,.4), transparent); pointer-events: none;
}
.closing-inner::after {
  content: ""; position: absolute; inset: -50% -10% auto auto; width: 45%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(231,181,71,.22), transparent); pointer-events: none;
}
.closing-inner > * { position: relative; z-index: 1; }
.closing-inner > .closing-bg { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; object-fit: cover; opacity: .4; -webkit-mask-image: radial-gradient(70% 90% at 50% 50%, transparent 20%, #000 90%); mask-image: radial-gradient(70% 90% at 50% 50%, transparent 20%, #000 90%); }
.closing h2 { color: #fff; font-size: clamp(2rem, 4.6vw, 3.4rem); font-weight: 700; }
.closing-phone { font: 500 .9rem/1 var(--mono); color: #8d92a8; }

/* Pie */
.footer { border-top: 1px solid var(--line); padding: 28px 0; }
.footer-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; }
.footer img { height: 26px; width: auto; }
.footer p { font-size: .9rem; color: var(--muted); }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.footer-links a { font-size: .9rem; color: var(--muted); text-decoration: none; }
.footer-links a:hover { color: var(--violet); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

/* Precios */
.plan-price { display: grid; gap: 8px; margin-top: 6px; padding: 16px; border-radius: 12px; background: var(--paper); }
.price { font: 800 2.1rem/1 var(--display); color: var(--ink); letter-spacing: -0.02em; display: flex; align-items: baseline; gap: 2px; }
.price b { font-weight: 800; }
.price-iva { font: 600 .82rem/1 var(--body); color: var(--muted); letter-spacing: 0; margin-left: 6px; }
.plan-featured .price-iva { color: #9ea3b8; }
.price-quote { font-size: 1.6rem; min-height: 2.1rem; align-items: center; }
.price-note { font-size: .88rem; color: var(--muted); line-height: 1.4; }
.price-toggle { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; margin-bottom: 6px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); }
.price-toggle button {
  border: 0; border-radius: 999px; padding: 8px 10px; cursor: pointer; background: transparent;
  font: 600 .82rem/1.1 var(--body); white-space: nowrap; color: var(--muted); transition: background-color .2s ease, color .2s ease;
}
.price-toggle button[aria-pressed="true"] { background: var(--ink); color: #fff; }
.plan-featured .plan-price { background: rgba(255,255,255,.05); }
.plan-featured .price { color: #fff; }
.plan-featured .price-note { color: #9ea3b8; }
.plan-fine { font-size: .8rem; line-height: 1.45; color: var(--muted); margin-top: -4px; }
.plan-price .js-note { min-height: 2.8em; } /* evita saltos al cambiar de opción */

/* Nota de hosting y banda del agente */
.plans-fine { margin-top: 18px; font-size: .88rem; color: var(--muted); max-width: 60em; }
.agent-band {
  margin-top: 28px; display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px 48px; align-items: center;
  background: var(--ink); color: #c9ccd9; border-radius: var(--radius); padding: clamp(28px, 4vw, 44px);
  position: relative; overflow: hidden;
}
.agent-band::before {
  content: ""; position: absolute; inset: -60% auto auto -10%; width: 50%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(106,69,240,.45), transparent); pointer-events: none;
}
.agent-band::after {
  content: ""; position: absolute; inset: auto -8% -70% auto; width: 40%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(231,181,71,.2), transparent); pointer-events: none;
}
.agent-band > * { position: relative; z-index: 1; }
.agent-band > .agent-bg { position: absolute; inset: 0 0 0 auto; z-index: 0; width: 70%; height: 100%; object-fit: cover; opacity: .55; -webkit-mask-image: linear-gradient(90deg, transparent, #000 60%); mask-image: linear-gradient(90deg, transparent, #000 60%); }
.agent-cta { background: rgba(10,12,23,.72); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); border: 1px solid rgba(255,255,255,.08); }
.agent-band { background: linear-gradient(90deg, rgba(13,15,28,.2), rgba(13,15,28,.2)), var(--ink); }
.agent-copy { display: grid; gap: 12px; }
.agent-band h3 { color: #fff; font-size: clamp(1.6rem, 2.6vw, 2rem); font-weight: 700; }
.agent-cta { display: grid; gap: 8px; padding: 22px; border-radius: 12px; background: rgba(255,255,255,.05); }
.agent-cta .price { color: #fff; }
.agent-cta .price-note { color: #9ea3b8; }
.agent-cta .btn { margin-top: 8px; width: 100%; }
@media (max-width: 860px) { .agent-band { grid-template-columns: 1fr; max-width: 560px; } .agent-band > .agent-bg { width: 100%; opacity: .3; -webkit-mask-image: linear-gradient(0deg, transparent, #000 70%); mask-image: linear-gradient(0deg, transparent, #000 70%); } .plans-fine { max-width: 560px; } }

/* Decoración de fondo: íconos del negocio (web, tienda, pago, código, agentes) */
.has-deco { position: relative; overflow: hidden; isolation: isolate; }
.has-deco > .wrap { position: relative; z-index: 1; }
.deco { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.deco-item { position: absolute; color: var(--violet); opacity: .16; animation: floaty 9s ease-in-out infinite; }
@keyframes floaty { 50% { translate: 0 -12px; } }
.d-browser { width: 260px; top: 70px; right: -40px; rotate: 8deg; opacity: .2; }
.d-cart { width: 84px; top: 42%; right: 3%; color: var(--gold); opacity: .45; animation-delay: -2s; }
.d-card { width: 130px; bottom: 90px; left: -24px; rotate: -12deg; color: var(--gold); opacity: .4; animation-delay: -4s; }
.d-code { width: 96px; top: 34%; left: 2%; opacity: .3; animation-delay: -6s; }
.d-nodes { width: 190px; bottom: 30px; right: -30px; opacity: .24; animation-delay: -3s; }
.d-cursor { width: 34px; top: 64px; left: 56%; color: var(--ink); opacity: .22; animation-delay: -1s; }
.d-spark { color: var(--gold); opacity: .75; animation: twinkle 3.6s ease-in-out infinite; }
@keyframes twinkle { 50% { opacity: .15; scale: .7; } }
.s1 { width: 18px; top: 110px; left: 38%; }
.s2 { width: 12px; bottom: 140px; right: 26%; animation-delay: -1.4s; }
.s3 { width: 16px; top: 90px; right: 8%; animation-delay: -2.2s; }
.d-q { opacity: .12; }
.q1 { width: 90px; top: 40px; right: 4%; rotate: 12deg; }
.q2 { width: 56px; bottom: 60px; left: 3%; rotate: -14deg; color: var(--gold); opacity: .35; animation-delay: -5s; }
.d-bubble { width: 120px; bottom: 36px; right: 30%; color: var(--gold); opacity: .3; animation-delay: -3s; }
.n2 { width: 170px; top: -20px; left: -40px; bottom: auto; right: auto; opacity: .12; }
@media (max-width: 900px) {
  .d-browser { width: 170px; top: 20px; right: -60px; }
  .d-code, .d-cursor, .d-bubble, .s1 { display: none; }
  .d-cart { top: auto; bottom: 30%; right: -10px; }
}

/* Chat de ejemplo en Preguntas */
.chat-demo {
  margin-top: 18px; display: grid; gap: 10px; padding: 18px; max-width: 360px;
  background: var(--card); border: 1px solid var(--line); border-radius: 18px;
  box-shadow: 0 30px 50px -34px rgba(13,15,28,.45); rotate: -1.5deg;
}
.chat-head { display: flex; align-items: center; gap: 10px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.chat-head img { border-radius: 8px; }
.chat-head span { display: grid; line-height: 1.2; }
.chat-head b { font-size: .92rem; color: var(--ink); }
.chat-head i { font-style: normal; font-size: .75rem; color: #1fa855; }
.chat-head i::before { content: "● "; }
.msg { max-width: 85%; padding: 9px 13px; border-radius: 16px; font-size: .9rem; line-height: 1.4; }
.msg-in { justify-self: end; background: var(--paper-2); color: var(--ink); border-bottom-right-radius: 5px; }
.msg-out { justify-self: start; background: var(--ink); color: #eef0f7; border-bottom-left-radius: 5px; }
.typing { display: flex; gap: 4px; padding: 12px 14px; }
.typing span { width: 6px; height: 6px; border-radius: 50%; background: var(--gold); animation: dot 1.2s ease-in-out infinite; }
.typing span:nth-child(2) { animation-delay: .15s; }
.typing span:nth-child(3) { animation-delay: .3s; }
@keyframes dot { 30% { translate: 0 -4px; opacity: 1; } 0%, 60%, 100% { opacity: .4; } }
@media (max-width: 900px) { .chat-demo { display: none; } }
@media (prefers-reduced-motion: reduce) { .deco-item, .typing span { animation: none; } }

/* Decoración en Servicios y Cómo trabajamos */
.d-mail { width: 84px; top: 64px; right: 6%; rotate: 10deg; color: var(--gold); opacity: .45; }
.d-sheet { width: 120px; top: 30px; right: 22%; opacity: .14; animation-delay: -3s; }
.d-gear { width: 70px; bottom: 60px; left: 1.5%; opacity: .22; animation: spin 26s linear infinite; }
@keyframes spin { to { rotate: 360deg; } }
.d-bolt { width: 34px; top: 46%; right: 1.5%; color: var(--gold); opacity: .5; animation-delay: -5s; }
.d-phone { width: 52px; bottom: 40px; right: 8%; rotate: -10deg; opacity: .2; animation-delay: -2s; }
.s4 { width: 16px; top: 130px; left: 52%; }
.d-cal { width: 90px; top: 50px; right: 5%; rotate: 8deg; opacity: .18; }
.d-rocket { width: 70px; bottom: 50px; left: 1.5%; rotate: 18deg; color: var(--gold); opacity: .45; animation-delay: -4s; }
.d-list { width: 90px; bottom: 60px; right: 3%; rotate: -8deg; opacity: .16; animation-delay: -2s; }
.d-pencil { width: 58px; top: 12%; left: 50%; opacity: .16; animation-delay: -6s; }
.s5 { width: 18px; top: 80px; left: 34%; }
.s6 { width: 12px; bottom: 90px; right: 36%; animation-delay: -1.8s; }
@media (max-width: 900px) {
  .d-sheet, .d-pencil, .d-phone, .s4 { display: none; }
  .d-mail { width: 60px; top: 24px; right: 4%; }
  .d-cal { width: 64px; top: 20px; }
  .d-bolt { top: 30%; right: 2%; }
}

/* Terminal de automatización: las líneas aparecen una a una, en loop */
.flow-caret i { display: inline-block; width: 7px; height: 13px; background: var(--gold); animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  .services .svc-flow li { opacity: 1; animation: none; }
  .d-gear, .flow-caret i { animation: none; }
}
#servicios { padding-top: clamp(40px, 5vw, 64px); } /* menos aire justo después de la portada */
#servicios .sec-head { margin-bottom: clamp(24px, 3vw, 36px); }

/* Agentes de IA: chat estilo WhatsApp animado (lo arma main.js) */
.svc-wa { display: flex; flex-direction: column; background: #0b141a; font-family: var(--body); color: #e9edef; }
.wa-head { display: flex; align-items: center; gap: 9px; padding: 7px 12px; background: #1f2c34; color: #aebac1; flex: none; }
.svc-wa .wa-head img { width: 26px; height: 26px; flex: none; border-radius: 50%; object-fit: cover; transform: none !important; }
.wa-head span { display: grid; line-height: 1.15; margin-right: auto; }
.wa-head b { font-size: .8rem; font-weight: 600; color: #e9edef; }
.wa-head i { font-style: normal; font-size: .66rem; color: #8696a0; transition: color .2s ease; }
.wa-head i.is-typing { color: #25d366; }
.wa-body {
  flex: 1; min-height: 0; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; gap: 4px; padding: 8px 10px;
  background: radial-gradient(circle at 20% 30%, rgba(255,255,255,.035) 1px, transparent 1.5px) 0 0 / 18px 18px, #0b141a;
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 22px); mask-image: linear-gradient(to bottom, transparent, #000 22px);
  transition: opacity .4s ease;
}
.wa-body.is-clearing { opacity: 0; }
.wa-msg {
  position: relative; max-width: 80%; padding: 5px 8px 4px; border-radius: 8px; font-size: .74rem; line-height: 1.35; flex: none;
  animation: waIn .32s cubic-bezier(.2,.9,.3,1.2) both; box-shadow: 0 1px 1px rgba(0,0,0,.25);
}
.wa-msg small { float: right; margin: 5px 0 -3px 8px; font-size: .58rem; color: rgba(233,237,239,.6); white-space: nowrap; }
.wa-me { align-self: flex-end; background: #005c4b; border-top-right-radius: 2px; transform-origin: bottom right; }
.wa-bot { align-self: flex-start; background: #202c33; border-top-left-radius: 2px; transform-origin: bottom left; }
.wa-tick { color: #8696a0; margin-left: 2px; letter-spacing: -3px; transition: color .3s ease; }
.wa-tick.is-read { color: #53bdeb; }
.wa-typing { display: flex; gap: 3px; padding: 8px 10px; }
.wa-typing i { width: 5px; height: 5px; border-radius: 50%; background: #8696a0; animation: dot 1.1s ease-in-out infinite; }
.wa-typing i:nth-child(2) { animation-delay: .15s; }
.wa-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes waIn { from { opacity: 0; scale: .85; translate: 0 8px; } to { opacity: 1; scale: 1; translate: 0 0; } }
.wa-input { display: flex; align-items: center; gap: 8px; padding: 6px 10px 8px; background: #0b141a; flex: none; }
.wa-input span { flex: 1; min-width: 0; padding: 5px 12px; border-radius: 16px; background: #1f2c34; font-size: .72rem; color: #e9edef; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wa-input em { font-style: normal; color: #8696a0; }
.wa-input span.is-typing::after { content: ""; display: inline-block; width: 1px; height: 11px; margin-left: 1px; vertical-align: -1px; background: #25d366; animation: blink 1s steps(1) infinite; }
.wa-input i { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: #00a884; color: #fff; flex: none; }
@media (prefers-reduced-motion: reduce) { .wa-msg, .wa-typing i { animation: none; } }

/* Las 3 tarjetas de Servicios: mismo tamaño (cuadradas) */
@media (max-width: 860px) { .svc-media { width: 100%; max-width: 460px; } }

/* Terminal de automatización: 8 líneas que aparecen una a una, loop de 12 s */
.svc-flow ol { gap: 9px; padding: 16px; }
.services .svc-flow li { opacity: 0; animation: 12s ease-out infinite; }
.services .svc-flow li:nth-child(1) { animation-name: flow1; }
.services .svc-flow li:nth-child(2) { animation-name: flow2; }
.services .svc-flow li:nth-child(3) { animation-name: flow3; }
.services .svc-flow li:nth-child(4) { animation-name: flow4; }
.services .svc-flow li:nth-child(5) { animation-name: flow5; }
.services .svc-flow li:nth-child(6) { animation-name: flow6; }
.services .svc-flow li:nth-child(7) { animation-name: flow7; }
.services .svc-flow li:nth-child(8) { animation-name: flow8; }
@keyframes flow1 { 0%, 2.5% { opacity: 0; translate: 0 6px; } 5.4%, 86% { opacity: 1; translate: 0 0; } 93%, 100% { opacity: 0; translate: 0 0; } }
@keyframes flow2 { 0%, 11.2% { opacity: 0; translate: 0 6px; } 14.2%, 86% { opacity: 1; translate: 0 0; } 93%, 100% { opacity: 0; translate: 0 0; } }
@keyframes flow3 { 0%, 20.0% { opacity: 0; translate: 0 6px; } 22.9%, 86% { opacity: 1; translate: 0 0; } 93%, 100% { opacity: 0; translate: 0 0; } }
@keyframes flow4 { 0%, 28.8% { opacity: 0; translate: 0 6px; } 31.7%, 86% { opacity: 1; translate: 0 0; } 93%, 100% { opacity: 0; translate: 0 0; } }
@keyframes flow5 { 0%, 37.5% { opacity: 0; translate: 0 6px; } 40.4%, 86% { opacity: 1; translate: 0 0; } 93%, 100% { opacity: 0; translate: 0 0; } }
@keyframes flow6 { 0%, 46.2% { opacity: 0; translate: 0 6px; } 49.2%, 86% { opacity: 1; translate: 0 0; } 93%, 100% { opacity: 0; translate: 0 0; } }
@keyframes flow7 { 0%, 55.0% { opacity: 0; translate: 0 6px; } 57.9%, 86% { opacity: 1; translate: 0 0; } 93%, 100% { opacity: 0; translate: 0 0; } }
@keyframes flow8 { 0%, 63.8% { opacity: 0; translate: 0 6px; } 66.7%, 86% { opacity: 1; translate: 0 0; } 93%, 100% { opacity: 0; translate: 0 0; } }

/* Sitios, landings y tiendas: maquetas que aparecen y se superponen, loop de 12 s */
.svc-sites { position: relative; isolation: isolate;
  background: radial-gradient(70% 60% at 100% 0%, rgba(106,69,240,.4), transparent 70%), radial-gradient(60% 60% at 0% 100%, rgba(231,181,71,.2), transparent 70%),
    radial-gradient(circle, rgba(255,255,255,.06) 1px, transparent 1.5px) 0 0 / 16px 16px, #0d0f1c; }
.svc-sites .mk { position: absolute; opacity: 0; animation: 12s cubic-bezier(.2,.8,.2,1) infinite; will-change: transform, opacity; }
.mk-browser { border-radius: 7px; overflow: hidden; background: #fff; box-shadow: 0 18px 34px -12px rgba(0,0,0,.65), 0 0 0 1px rgba(255,255,255,.08); }
.mk-bar { display: flex; align-items: center; gap: 3px; padding: 4px 6px; background: #eceae4; }
.mk-bar i { width: 5px; height: 5px; border-radius: 50%; background: #c9c6bd; flex: none; }
.mk-bar i:first-child { background: #ff6159; } .mk-bar i:nth-child(2) { background: #ffbd2e; } .mk-bar i:nth-child(3) { background: #28c941; }
.mk-bar em { font-style: normal; font: 500 .5rem/1 var(--mono); color: #6b6f80; margin-left: 6px; padding: 2px 8px; border-radius: 6px; background: #fff; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.svc-sites .mk img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; object-position: top; transform: none !important; }
.mk-phone { padding: 4px; border-radius: 16px; background: #1b1d2a; box-shadow: 0 20px 34px -10px rgba(0,0,0,.7), inset 0 0 0 1px rgba(255,255,255,.14); }
.svc-sites .mk-phone img { aspect-ratio: 1 / 2; border-radius: 12px; }
.mk-pill { display: flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 999px; background: #fff; color: var(--ink); font: 600 .7rem/1 var(--body); white-space: nowrap; box-shadow: 0 14px 26px -10px rgba(0,0,0,.6); }
.mk-ok b { display: grid; place-items: center; width: 16px; height: 16px; border-radius: 50%; background: #1fa855; color: #fff; font-size: .6rem; }
.mk1 { --r: -7deg; left: 4%;  top: 9%;  width: 72%; z-index: 1; }
.mk2 { --r: 6deg;  right: 3%; top: 27%; width: 68%; z-index: 2; }
.mk3 { --r: -2deg; left: 6%;  top: 45%; width: 70%; z-index: 3; }
.mk4 { --r: 9deg;  right: 6%; top: 38%; width: 24%; z-index: 4; }
.mk5 { --r: -4deg; left: 5%;  bottom: 6%; z-index: 5; }
.mk6 { --r: 3deg;  right: 4%; top: 5%;  z-index: 5; }
.svc-sites .mk1 { animation-name: mk1; }
.svc-sites .mk2 { animation-name: mk2; }
.svc-sites .mk3 { animation-name: mk3; }
.svc-sites .mk4 { animation-name: mk4; }
.svc-sites .mk5 { animation-name: mk5; }
.svc-sites .mk6 { animation-name: mk6; }
@keyframes mk1 { 0%, 1.7% { opacity: 0; translate: 0 36px; scale: .82; rotate: calc(var(--r) - 12deg); } 8.3% { opacity: 1; translate: 0 0; scale: 1; rotate: var(--r); } 47.1% { opacity: 1; translate: 0 -5px; scale: 1; rotate: var(--r); } 85.8% { opacity: 1; translate: 0 0; scale: 1; rotate: var(--r); } 92.5%, 100% { opacity: 0; translate: 0 -18px; scale: .95; rotate: var(--r); } }
@keyframes mk2 { 0%, 12.5% { opacity: 0; translate: 0 36px; scale: .82; rotate: calc(var(--r) - 12deg); } 19.2% { opacity: 1; translate: 0 0; scale: 1; rotate: var(--r); } 52.5% { opacity: 1; translate: 0 -5px; scale: 1; rotate: var(--r); } 85.8% { opacity: 1; translate: 0 0; scale: 1; rotate: var(--r); } 92.5%, 100% { opacity: 0; translate: 0 -18px; scale: .95; rotate: var(--r); } }
@keyframes mk3 { 0%, 23.3% { opacity: 0; translate: 0 36px; scale: .82; rotate: calc(var(--r) - 12deg); } 30.0% { opacity: 1; translate: 0 0; scale: 1; rotate: var(--r); } 57.9% { opacity: 1; translate: 0 -5px; scale: 1; rotate: var(--r); } 85.8% { opacity: 1; translate: 0 0; scale: 1; rotate: var(--r); } 92.5%, 100% { opacity: 0; translate: 0 -18px; scale: .95; rotate: var(--r); } }
@keyframes mk4 { 0%, 34.2% { opacity: 0; translate: 0 36px; scale: .82; rotate: calc(var(--r) - 12deg); } 40.8% { opacity: 1; translate: 0 0; scale: 1; rotate: var(--r); } 63.3% { opacity: 1; translate: 0 -5px; scale: 1; rotate: var(--r); } 85.8% { opacity: 1; translate: 0 0; scale: 1; rotate: var(--r); } 92.5%, 100% { opacity: 0; translate: 0 -18px; scale: .95; rotate: var(--r); } }
@keyframes mk5 { 0%, 44.2% { opacity: 0; translate: 0 36px; scale: .82; rotate: calc(var(--r) - 12deg); } 50.8% { opacity: 1; translate: 0 0; scale: 1; rotate: var(--r); } 68.3% { opacity: 1; translate: 0 -5px; scale: 1; rotate: var(--r); } 85.8% { opacity: 1; translate: 0 0; scale: 1; rotate: var(--r); } 92.5%, 100% { opacity: 0; translate: 0 -18px; scale: .95; rotate: var(--r); } }
@keyframes mk6 { 0%, 52.5% { opacity: 0; translate: 0 36px; scale: .82; rotate: calc(var(--r) - 12deg); } 59.2% { opacity: 1; translate: 0 0; scale: 1; rotate: var(--r); } 72.5% { opacity: 1; translate: 0 -5px; scale: 1; rotate: var(--r); } 85.8% { opacity: 1; translate: 0 0; scale: 1; rotate: var(--r); } 92.5%, 100% { opacity: 0; translate: 0 -18px; scale: .95; rotate: var(--r); } }
@media (prefers-reduced-motion: reduce) { .svc-sites .mk { opacity: 1; animation: none; rotate: var(--r); } }
@media (prefers-reduced-motion: reduce) { .services .svc-flow li { opacity: 1; animation: none; } }
