/* FocalSales — web pública. Estilo: oscuro cinematográfico, esmeralda. */

@font-face {
  font-family: "Geist";
  src: url("/fuentes/geist.woff2") format("woff2-variations"), url("/fuentes/geist.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --bg: #050b09;
  --bg-2: #08120f;
  --surface: #0b1714;
  --surface-2: #10211c;
  --line: rgba(var(--fg-rgb), 0.08);
  --line-2: rgba(var(--fg-rgb), 0.14);
  --text: #eaf5f1;
  --muted: #9db5ad;
  --mint: #6ee7b7;
  --emerald: #34d399;
  --teal: #22d3ee;
  --sage: #84b6ab;
  --on-mint: #04201a;
  --fg-rgb: 234, 245, 241;       /* el texto en RGB, para bordes y velos translúcidos */
  --nav-glass: rgba(8, 18, 15, 0.62);
  --doc-ink: #cfe0da;
  --warn-ink: #fcd34d;

  --font: "Geist", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --fs-small: clamp(0.8125rem, 0.78rem + 0.12vw, 0.875rem);
  --fs-body: clamp(1rem, 0.96rem + 0.2vw, 1.125rem);
  --fs-lead: clamp(1.125rem, 1rem + 0.55vw, 1.375rem);
  --fs-h3: clamp(1.25rem, 1.1rem + 0.6vw, 1.5rem);
  --fs-h2: clamp(2.25rem, 1.4rem + 3.6vw, 4.5rem);
  --fs-hero: clamp(3rem, 1.2rem + 7.4vw, 8rem);

  --max: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  --r-lg: 24px;
  --r-md: 16px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--bg); }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
/* Grano de película solo sobre los fondos con luces (encima del texto lo ensuciaba) */
.aurora::after {
  content: ""; position: absolute; inset: -50%; pointer-events: none; opacity: 0.06;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1.2s steps(6) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); } 20% { transform: translate(-3%, 2%); } 40% { transform: translate(2%, -3%); }
  60% { transform: translate(-2%, -1%); } 80% { transform: translate(3%, 3%); } 100% { transform: translate(0, 0); }
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; }
::selection { background: var(--mint); color: var(--on-mint); }
:focus-visible { outline: 2px solid var(--mint); outline-offset: 3px; border-radius: 6px; }

h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -0.035em; line-height: 1.02; }
p { margin: 0; }
.wrap { width: min(100% - var(--gutter) * 2, var(--max)); margin-inline: auto; }
.grad {
  background: linear-gradient(100deg, var(--mint) 0%, var(--teal) 50%, var(--mint) 100%);
  background-size: 200% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: shine 6s linear infinite;
}
@keyframes shine { to { background-position: -200% 0; } }

.skip { position: absolute; left: 16px; top: -60px; z-index: 200; background: var(--mint); color: var(--on-mint); padding: 10px 14px; border-radius: 8px; text-decoration: none; font-weight: 600; }
.skip:focus { top: 16px; }

/* ---------- Botones ---------- */
.btn {
  --mx: 0px; --my: 0px;
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 26px; border-radius: 999px; border: 0; cursor: pointer;
  font: 600 1rem/1 var(--font); letter-spacing: -0.01em; text-decoration: none; white-space: nowrap;
  transform: translate(var(--mx), var(--my));
  transition: transform 400ms var(--ease), box-shadow 300ms var(--ease), background-color 200ms ease;
}
.btn-primary { background: var(--mint); color: var(--on-mint); box-shadow: 0 0 0 1px rgba(110, 231, 183, 0.4), 0 10px 40px -10px rgba(52, 211, 153, 0.7); }
.btn-primary:hover { box-shadow: 0 0 0 1px rgba(110, 231, 183, 0.7), 0 14px 60px -8px rgba(52, 211, 153, 0.9); }
.btn-ghost { background: rgba(var(--fg-rgb), 0.06); color: var(--text); box-shadow: inset 0 0 0 1px var(--line-2); }
.btn-ghost:hover { background: rgba(var(--fg-rgb), 0.1); }
.btn:active { transform: translate(var(--mx), var(--my)) scale(0.97); }
.btn svg { width: 18px; height: 18px; transition: transform 300ms var(--ease); }
.btn:hover svg { transform: translateX(3px); }

/* ---------- Encabezado ---------- */
.nav {
  position: fixed; top: 14px; left: 50%; z-index: 50; transform: translateX(-50%);
  width: min(100% - 24px, 1120px); display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 10px 10px 10px 18px; border-radius: 999px;
  transition: background-color 300ms ease, box-shadow 300ms ease;
}
.nav.is-scrolled { background: var(--nav-glass); backdrop-filter: blur(16px) saturate(140%); -webkit-backdrop-filter: blur(16px) saturate(140%); box-shadow: inset 0 0 0 1px var(--line), 0 20px 40px -20px rgba(0, 0, 0, 0.6); }
.brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; font-weight: 650; font-size: 1.3125rem; letter-spacing: -0.035em; }
.brand img { width: 34px; height: 34px; }
.brand b { font-weight: 650; color: var(--mint); }
.nav ul { display: flex; gap: 6px; list-style: none; margin: 0; padding: 0; }
.nav ul a { display: block; padding: 10px 14px; border-radius: 999px; text-decoration: none; color: var(--muted); font-size: 0.9375rem; transition: color 200ms ease, background-color 200ms ease; }
.nav ul a:hover { color: var(--text); background: rgba(var(--fg-rgb), 0.06); }
.nav .btn { min-height: 44px; padding: 0 20px; font-size: 0.9375rem; }
.nav-actions { display: flex; align-items: center; gap: 6px; }
.t-short { display: none; }
@media (max-width: 420px) { .t-long { display: none; } .t-short { display: inline; } .nav .brand { font-size: 1.0625rem; gap: 8px; } .nav .brand img { width: 28px; height: 28px; } .nav { padding-left: 12px; } .nav-actions { gap: 2px; } .nav-login { padding: 0 10px; } }
@media (max-width: 360px) { .nav .brand { font-size: 1.0625rem; gap: 7px; } .nav .brand img { width: 28px; height: 28px; } .nav-login { padding: 0 8px; } .nav .btn { padding: 0 14px; } }
.nav-login { display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border-radius: 999px; text-decoration: none; font-size: 0.9375rem; font-weight: 500; color: var(--text); transition: background-color 200ms ease; }
.nav-login:hover { background: rgba(var(--fg-rgb), 0.08); }

/* Página provisoria de ingreso */
.access { position: relative; min-height: 100svh; display: grid; place-items: center; padding: 120px var(--gutter) 80px; text-align: center; overflow: hidden; }
.access .box { position: relative; z-index: 1; max-width: 520px; }
.access .badge-icon { width: 72px; height: 72px; margin: 0 auto 28px; border-radius: 22px; display: grid; place-items: center; color: var(--mint); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line-2), 0 0 60px -10px rgba(110, 231, 183, 0.6); }
.access .badge-icon svg { width: 30px; height: 30px; }
.access h1 { font-size: clamp(2.25rem, 1.5rem + 3vw, 3.5rem); letter-spacing: -0.045em; }
.access p { margin: 18px auto 32px; color: var(--muted); font-size: var(--fs-lead); max-width: 40ch; }
.access .row-btns { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }

/* ---------- Auroras ---------- */
.aurora { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.aurora i { position: absolute; border-radius: 50%; filter: blur(80px); opacity: 0.55; will-change: transform; }
.aurora i:nth-child(1) { width: 52vw; height: 52vw; left: -10vw; top: -18vw; background: radial-gradient(circle, rgba(52, 211, 153, 0.55), transparent 65%); animation: float1 18s ease-in-out infinite alternate; }
.aurora i:nth-child(2) { width: 46vw; height: 46vw; right: -12vw; top: -6vw; background: radial-gradient(circle, rgba(34, 211, 238, 0.4), transparent 65%); animation: float2 22s ease-in-out infinite alternate; }
.aurora i:nth-child(3) { width: 60vw; height: 40vw; left: 20vw; bottom: -24vw; background: radial-gradient(circle, rgba(110, 231, 183, 0.35), transparent 65%); animation: float3 26s ease-in-out infinite alternate; }
@keyframes float1 { to { transform: translate(12vw, 8vw) scale(1.15); } }
@keyframes float2 { to { transform: translate(-10vw, 10vw) scale(0.9); } }
@keyframes float3 { to { transform: translate(-8vw, -6vw) scale(1.1); } }
.grid-bg {
  position: absolute; inset: 0; pointer-events: none; z-index: 0; opacity: 0.5;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 75%);
}

/* ---------- Portada ---------- */
.hero { position: relative; min-height: 100svh; padding: 150px 0 60px; text-align: center; overflow: hidden; }
.hero .wrap { position: relative; z-index: 1; }
.pill {
  display: inline-flex; align-items: center; gap: 10px; padding: 7px 14px 7px 8px; border-radius: 999px;
  background: rgba(var(--fg-rgb), 0.05); box-shadow: inset 0 0 0 1px var(--line-2); font-size: var(--fs-small); color: var(--muted);
}
.pill .dot { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: rgba(110, 231, 183, 0.14); }
.pill .dot::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 12px var(--mint); animation: pulse 2s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(0.6); opacity: 0.6; } }
.hero h1 { font-size: var(--fs-hero); letter-spacing: -0.055em; line-height: 0.95; margin: 26px auto 0; }
.hero h1 .line { display: block; }
/* El texto con degradé se recorta a su caja: aire abajo para que no se corten la g, la p o la q */
.hero h1 .grad, .cta h2 .grad, .sec-head h2 .grad { padding-bottom: 0.12em; margin-bottom: -0.12em; }
.cta h2 .grad, .sec-head h2 .grad { display: inline-block; }
.hero-lead { margin: 28px auto 0; max-width: 40ch; font-size: var(--fs-lead); color: var(--muted); line-height: 1.5; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 36px; }

/* Escena: canales que convergen en la bandeja */
.scene { position: relative; margin: 72px auto 0; width: min(100%, 1040px); height: clamp(420px, 52vw, 600px); perspective: 1600px; }
/* Sin transform en reposo: el texto se dibuja nítido (la inclinación 3D es solo la entrada) */
.inbox {
  position: absolute; inset: 0; margin: auto; width: min(86%, 760px); height: 82%;
  border-radius: 20px; background: linear-gradient(180deg, rgba(22, 48, 42, 0.92), rgba(11, 23, 20, 0.96));
  box-shadow: inset 0 0 0 1px var(--line-2), 0 60px 120px -40px rgba(0, 0, 0, 0.9), 0 0 80px -20px rgba(52, 211, 153, 0.35);
  display: grid; grid-template-columns: 210px 1fr; overflow: hidden; text-align: left;
}
.inbox::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; background: radial-gradient(600px 200px at 50% 0%, rgba(110, 231, 183, 0.12), transparent 70%); }
.ib-side { border-right: 1px solid var(--line); padding: 16px 10px; display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
.ib-side .ib-brand { display: flex; align-items: center; gap: 8px; padding: 4px 8px 14px; color: var(--text); font-weight: 600; font-size: 14px; }
.ib-side .ib-brand img { width: 22px; height: 22px; }
.ib-side span { display: flex; justify-content: space-between; padding: 8px 10px; border-radius: 8px; }
.ib-side span.on { background: rgba(110, 231, 183, 0.1); color: var(--text); }
.ib-side em { font-style: normal; font-size: 12px; min-width: 22px; text-align: center; padding: 1px 6px; border-radius: 999px; background: rgba(var(--fg-rgb), 0.08); }
.ib-side .need-row em { background: rgba(251, 191, 36, 0.18); color: var(--warn-ink); }
.ib-list { padding: 14px; display: flex; flex-direction: column; gap: 8px; overflow: hidden; }
.ib-list h4 { margin: 2px 4px 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
.row {
  display: grid; grid-template-columns: 34px 1fr auto; gap: 12px; align-items: center; padding: 11px 12px; border-radius: 12px;
  background: rgba(var(--fg-rgb), 0.03); box-shadow: inset 0 0 0 1px var(--line); font-size: 13px;
}
.row.is-new { box-shadow: inset 0 0 0 1px rgba(110, 231, 183, 0.45), 0 0 30px -10px rgba(110, 231, 183, 0.6); }
.row .who { min-width: 0; }
.row .who b { display: block; color: var(--text); font-weight: 600; font-size: 13.5px; }
.row .who small { display: block; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 12.5px; }
.row time { color: var(--muted); font-size: 12px; }
.chan { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: rgba(var(--fg-rgb), 0.06); }
.chan i, .orb i, .ico { display: block; width: 18px; height: 18px; background: currentColor; -webkit-mask: var(--icon) center / contain no-repeat; mask: var(--icon) center / contain no-repeat; }
.c-wa { color: #25d366; --icon: url("/iconos/whatsapp.svg"); }
.c-ig { color: #f472b6; --icon: url("/iconos/instagram.svg"); }
.c-ms { color: #38bdf8; --icon: url("/iconos/messenger.svg"); }
.c-gm { color: #f87171; --icon: url("/iconos/gmail.svg"); }
.c-tg { color: #38b6f0; --icon: url("/iconos/telegram.svg"); }
.c-hm { color: #4ea1ff; --icon: url("/iconos/hotmail.svg"); }
.c-ml { color: #ffe600; --icon: url("/iconos/mercadolibre.svg"); }
.orb {
  position: absolute; z-index: 3; width: 64px; height: 64px; border-radius: 20px; display: grid; place-items: center;
  background: rgba(16, 33, 28, 0.85); box-shadow: inset 0 0 0 1px var(--line-2), 0 20px 40px -12px rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.orb i { width: 28px; height: 28px; }
.orb::after { content: ""; position: absolute; inset: -6px; border-radius: 24px; box-shadow: 0 0 0 1px currentColor; opacity: 0; animation: ring 3s ease-out infinite; }
@keyframes ring { 0% { opacity: 0.6; transform: scale(0.9); } 100% { opacity: 0; transform: scale(1.35); } }
/* 7 canales alrededor de la bandeja: 3 a la izquierda, 4 a la derecha */
.o-wa { left: 0; top: 2%; animation: bob 6s ease-in-out infinite; }
.o-ms { left: -1%; top: 40%; animation: bob 7.5s ease-in-out -3s infinite; }
.o-ml { left: 2%; bottom: 2%; animation: bob 8s ease-in-out -4s infinite; }
.o-ig { right: 0; top: 0; animation: bob 7s ease-in-out -2s infinite; }
.o-tg { right: -1%; top: 30%; animation: bob 6.8s ease-in-out -5s infinite; }
.o-gm { right: 2%; bottom: 28%; animation: bob 6.5s ease-in-out -1s infinite; }
.o-hm { right: 9%; bottom: -2%; animation: bob 7.2s ease-in-out -6s infinite; }
.o-ig::after { animation-delay: 0.4s; } .o-ms::after { animation-delay: 0.9s; } .o-tg::after { animation-delay: 1.3s; }
.o-gm::after { animation-delay: 1.8s; } .o-hm::after { animation-delay: 2.2s; } .o-ml::after { animation-delay: 2.6s; }
.scene-note { margin: 28px auto 0; max-width: 60ch; font-size: var(--fs-small); color: var(--muted); }
.scene-note strong { color: var(--mint); font-weight: 600; }
@keyframes bob { 50% { transform: translateY(-14px); } }
.bubble {
  position: absolute; z-index: 4; left: 0; top: 0; pointer-events: none; padding: 9px 13px; border-radius: 14px 14px 14px 4px;
  background: rgba(16, 33, 28, 0.95); box-shadow: inset 0 0 0 1px var(--line-2), 0 12px 30px -10px rgba(0, 0, 0, 0.8);
  font-size: 13px; line-height: 1.35; color: var(--text); text-align: left; white-space: nowrap;
}
.bubble b { display: block; font-size: 11px; font-weight: 600; margin-bottom: 2px; }
.focal { position: absolute; z-index: 2; left: 50%; top: 50%; width: 160px; height: 160px; margin: -80px 0 0 -80px; border-radius: 50%; pointer-events: none; background: radial-gradient(circle, rgba(110, 231, 183, 0.4), transparent 70%); filter: blur(10px); opacity: 0; }

/* ---------- Rubros (cinta) ---------- */
.marquee { position: relative; padding: 20px 0; overflow: hidden; border-block: 1px solid var(--line); background: var(--bg-2); }
.marquee::before, .marquee::after { content: ""; position: absolute; top: 0; bottom: 0; width: 18vw; z-index: 1; pointer-events: none; }
.marquee::before { left: 0; background: linear-gradient(90deg, var(--bg-2), transparent); }
.marquee::after { right: 0; background: linear-gradient(-90deg, var(--bg-2), transparent); }
.marquee-track { display: flex; gap: 40px; width: max-content; animation: marquee 38s linear infinite; }
.marquee-track span { display: inline-flex; align-items: center; gap: 40px; font-size: clamp(1rem, 0.92rem + 0.45vw, 1.3125rem); font-weight: 500; letter-spacing: -0.015em; color: rgba(var(--fg-rgb), 0.32); white-space: nowrap; }
.marquee-track span::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 14px var(--mint); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Secciones ---------- */
section { position: relative; }
.sec { padding: clamp(96px, 12vw, 180px) 0; }
.sec-head { max-width: 760px; margin-bottom: clamp(48px, 6vw, 80px); }
.sec-head.center { margin-inline: auto; text-align: center; }
.sec-head h2 { font-size: var(--fs-h2); letter-spacing: -0.045em; }
.sec-head p { margin-top: 20px; font-size: var(--fs-lead); color: var(--muted); max-width: 48ch; }
.sec-head.center p { margin-inline: auto; }
.kicker { display: inline-block; margin-bottom: 18px; font-size: var(--fs-small); color: var(--mint); font-weight: 500; }

/* ---------- Un día de mensajes (fijo con el scroll) ---------- */
.day-pin { min-height: 100svh; display: flex; align-items: center; padding: 110px 0 60px; }
.day-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 96px); align-items: center; }
.day-grid h2 { font-size: var(--fs-h2); letter-spacing: -0.045em; margin-bottom: 18px; }
.day-intro { color: var(--muted); font-size: var(--fs-lead); margin-bottom: 30px; max-width: 34ch; }
.clock-label { display: block; margin-bottom: 6px; font-size: var(--fs-small); color: var(--mint); font-weight: 500; }
.clock small { font-size: 0.28em; letter-spacing: -0.02em; font-weight: 500; color: var(--muted); margin-left: 0.15em; }
.clock { font-size: clamp(4.5rem, 2rem + 8vw, 9.5rem); font-weight: 600; letter-spacing: -0.06em; line-height: 0.9; font-variant-numeric: tabular-nums; }
.day-caption { margin-top: 18px; font-size: var(--fs-h3); font-weight: 500; letter-spacing: -0.02em; min-height: 2.6em; color: var(--text); }
.day-steps { display: flex; gap: 8px; margin: 30px 0 0; list-style: none; padding: 0; }
.day-steps li { flex: 1; }
.day-steps button {
  width: 100%; appearance: none; border: 0; background: none; cursor: pointer; padding: 14px 0 6px; text-align: left;
  color: var(--muted); font: 500 0.875rem/1.2 var(--font); position: relative; min-height: 44px;
}
.day-steps button::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; border-radius: 3px; background: var(--line-2); }
.day-steps button::after { content: ""; position: absolute; left: 0; top: 0; height: 3px; border-radius: 3px; width: var(--fill, 0%); background: var(--mint); box-shadow: 0 0 12px var(--mint); }
.day-steps button[aria-selected="true"] { color: var(--text); }

.chat {
  position: relative; border-radius: var(--r-lg); padding: 1px;
  background: linear-gradient(160deg, rgba(110, 231, 183, 0.5), rgba(var(--fg-rgb), 0.06) 40%, rgba(34, 211, 238, 0.3));
  box-shadow: 0 50px 100px -40px rgba(0, 0, 0, 0.9), 0 0 120px -40px rgba(52, 211, 153, 0.5);
}
.chat-in { border-radius: calc(var(--r-lg) - 1px); background: var(--surface); overflow: hidden; }
.chat-head { display: flex; align-items: center; gap: 12px; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.avatar img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block; }
.avatar:has(img) { background: none; box-shadow: 0 0 0 2px rgba(110, 231, 183, 0.35); }
.avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; flex: none; font-weight: 600; font-size: 13px; color: var(--on-mint); background: linear-gradient(135deg, var(--mint), var(--teal)); }
.chat-who { flex: 1; min-width: 0; }
.chat-who b { display: block; font-weight: 600; }
.chat-who small { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 13px; }
.chat-who small .ico { width: 14px; height: 14px; }
.state { font-size: 12.5px; padding: 5px 11px; border-radius: 999px; white-space: nowrap; background: rgba(var(--fg-rgb), 0.07); color: var(--muted); }
.state.ok { background: rgba(110, 231, 183, 0.14); color: var(--mint); }
.state.warn { background: rgba(251, 191, 36, 0.15); color: var(--warn-ink); }
.chat-body { padding: 20px 18px; display: flex; flex-direction: column; gap: 12px; min-height: 200px; background: radial-gradient(400px 200px at 80% 0%, rgba(110, 231, 183, 0.05), transparent 70%); }
.msg { max-width: 86%; padding: 11px 14px; border-radius: 16px 16px 16px 4px; background: var(--surface-2); font-size: 15px; line-height: 1.45; align-self: flex-start; }
.msg time { display: block; margin-top: 4px; text-align: right; font-size: 12px; color: var(--muted); }
.msg.out { align-self: flex-end; border-radius: 16px 16px 4px 16px; background: rgba(110, 231, 183, 0.14); }
.audio { display: flex; align-items: center; gap: 10px; min-width: 220px; }
.audio .play { width: 30px; height: 30px; border-radius: 50%; background: var(--mint); flex: none; position: relative; }
.audio .play::after { content: ""; position: absolute; left: 12px; top: 9px; border-left: 9px solid var(--on-mint); border-top: 6px solid transparent; border-bottom: 6px solid transparent; }
.wave { display: flex; align-items: center; gap: 3px; height: 26px; flex: 1; }
.wave span { width: 3px; border-radius: 3px; background: rgba(110, 231, 183, 0.6); height: 30%; animation: wave 1.1s ease-in-out infinite; }
.wave span:nth-child(3n) { animation-delay: -0.3s; } .wave span:nth-child(4n) { animation-delay: -0.6s; } .wave span:nth-child(5n) { animation-delay: -0.9s; }
@keyframes wave { 50% { height: 100%; } }
.transcript { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line-2); font-size: 14.5px; color: #cfe3dc; }
.transcript em { display: block; font-style: normal; font-size: 12px; color: var(--mint); margin-bottom: 3px; }
.chat-ai { padding: 16px 18px 18px; border-top: 1px solid var(--line); }
.ai-label { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; color: var(--mint); margin-bottom: 10px; }
.ai-label::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 10px var(--mint); }
.draft { padding: 12px 14px; border-radius: 12px; background: rgba(110, 231, 183, 0.06); box-shadow: inset 0 0 0 1px rgba(110, 231, 183, 0.2); font-size: 15px; }
.actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.actions span { font-size: 13px; padding: 7px 14px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line-2); color: var(--muted); }
.actions span.primary { background: var(--mint); color: var(--on-mint); box-shadow: none; font-weight: 600; }
.note { padding: 12px 14px; border-radius: 12px; background: rgba(251, 191, 36, 0.1); box-shadow: inset 0 0 0 1px rgba(251, 191, 36, 0.25); color: #fde68a; font-size: 14.5px; }

/* ---------- Bento ---------- */
.bento { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px; }
.card {
  --x: 50%; --y: 50%;
  position: relative; overflow: hidden; border-radius: var(--r-lg); padding: 28px; min-height: 320px;
  background: var(--surface); box-shadow: inset 0 0 0 1px var(--line);
  display: flex; flex-direction: column; justify-content: flex-end; gap: 10px;
}
.card::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity 300ms ease; background: radial-gradient(420px circle at var(--x) var(--y), rgba(110, 231, 183, 0.12), transparent 45%); }
.card::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity 300ms ease; padding: 1px; background: radial-gradient(300px circle at var(--x) var(--y), rgba(110, 231, 183, 0.75), transparent 50%); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; }
.card:hover::before, .card:hover::after { opacity: 1; }
.card h3 { font-size: var(--fs-h3); position: relative; }
.card p { color: var(--muted); position: relative; max-width: 40ch; }
.card .viz { position: relative; flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; margin-bottom: 18px; min-height: 140px; }
.span-6 { grid-column: span 6; } .span-4 { grid-column: span 4; } .span-3 { grid-column: span 3; } .span-2 { grid-column: span 2; }
.card-wide { min-height: 0; flex-direction: row; align-items: center; gap: 32px; }
.card-wide p { max-width: 70ch; }

.seg-viz { display: inline-flex; padding: 5px; border-radius: 999px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); position: relative; }
.seg-viz span { position: relative; z-index: 1; padding: 10px 18px; font-size: 14px; color: var(--muted); transition: color 400ms ease; white-space: nowrap; }
.seg-viz span.on { color: var(--on-mint); font-weight: 600; }
.seg-viz .knob { position: absolute; z-index: 0; top: 5px; bottom: 5px; left: 5px; width: 0; border-radius: 999px; background: var(--mint); box-shadow: 0 0 24px -4px var(--mint); transition: left 600ms var(--ease), width 600ms var(--ease); }
.reply-viz { margin-top: 18px; max-width: 360px; font-size: 14px; color: #cfe3dc; text-align: center; min-height: 2.8em; transition: opacity 300ms ease; }
.wave-big { display: flex; align-items: center; gap: 5px; height: 90px; }
.wave-big span { width: 5px; border-radius: 5px; background: linear-gradient(var(--mint), var(--teal)); height: 20%; animation: wave 1.3s ease-in-out infinite; }
.wave-big span:nth-child(2n) { animation-delay: -0.4s; } .wave-big span:nth-child(3n) { animation-delay: -0.8s; } .wave-big span:nth-child(5n) { animation-delay: -1.1s; }
.typing { margin-top: 14px; font-size: 14px; color: #cfe3dc; min-height: 1.4em; text-align: center; }
.typing::after { content: "▍"; color: var(--mint); animation: blink 1s steps(2) infinite; margin-left: 2px; }
@keyframes blink { 50% { opacity: 0; } }
.faces { display: flex; }
.faces span { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; font-weight: 600; font-size: 15px; margin-left: -12px; box-shadow: 0 0 0 4px var(--surface); color: var(--on-mint); }
.faces span:nth-child(1) { margin-left: 0; background: linear-gradient(135deg, #6ee7b7, #22d3ee); }
.faces span:nth-child(2) { background: linear-gradient(135deg, #a7f3d0, #34d399); }
.faces span:nth-child(3) { background: linear-gradient(135deg, #67e8f9, #6ee7b7); }
.assign { margin-top: 16px; font-size: 13.5px; padding: 8px 14px; border-radius: 999px; background: rgba(110, 231, 183, 0.12); color: var(--mint); transition: opacity 250ms ease; }
.need { position: relative; width: 120px; height: 120px; display: grid; place-items: center; }
.need .bell { width: 64px; height: 64px; color: var(--warn-ink); animation: ring-bell 3s ease-in-out infinite; transform-origin: 50% 10%; }
.need .badge { position: absolute; top: 18px; right: 16px; min-width: 30px; height: 30px; padding: 0 8px; border-radius: 999px; background: #fbbf24; color: #1c1300; font-weight: 700; font-size: 14px; display: grid; place-items: center; box-shadow: 0 0 24px -2px rgba(251, 191, 36, 0.9); }
@keyframes ring-bell { 0%, 70%, 100% { transform: rotate(0); } 75% { transform: rotate(14deg); } 80% { transform: rotate(-12deg); } 85% { transform: rotate(8deg); } 90% { transform: rotate(-5deg); } }
.chips { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; max-width: 360px; }
.chips span { padding: 9px 14px; border-radius: 999px; font-size: 14px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line-2); animation: bob 5s ease-in-out infinite; }
.chips span:nth-child(2) { animation-delay: -1s; } .chips span:nth-child(3) { animation-delay: -2s; } .chips span:nth-child(4) { animation-delay: -3s; } .chips span:nth-child(5) { animation-delay: -4s; }
.shield { width: 96px; height: 96px; color: var(--mint); filter: drop-shadow(0 0 20px rgba(110, 231, 183, 0.6)); }
.shield .check { stroke-dasharray: 40; stroke-dashoffset: 40; animation: draw 3s var(--ease) infinite; }
@keyframes draw { 30%, 80% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: -40; } }

/* ---------- Demo interactiva ---------- */
.demo { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(28px, 5vw, 72px); align-items: center; }
.controls { display: flex; flex-direction: column; gap: 30px; }
.ctl h3 { font-size: var(--fs-h3); margin-bottom: 6px; }
.ctl p { color: var(--muted); margin-bottom: 14px; }
.seg { display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 4px; border-radius: 999px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.seg button {
  appearance: none; border: 0; cursor: pointer; min-height: 44px; padding: 0 18px; border-radius: 999px;
  font: 500 0.9375rem/1 var(--font); background: transparent; color: var(--muted);
  transition: background-color 250ms ease, color 250ms ease, transform 200ms var(--ease);
}
.seg button:hover { color: var(--text); background: rgba(var(--fg-rgb), 0.06); }
.seg button:active { transform: scale(0.96); }
.seg button[aria-pressed="true"] { background: var(--mint); color: var(--on-mint); }
.toggle { display: inline-flex; align-items: center; gap: 12px; cursor: pointer; font-weight: 500; min-height: 44px; }
.toggle input { appearance: none; margin: 0; width: 52px; height: 30px; border-radius: 999px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line-2); position: relative; cursor: pointer; transition: background-color 250ms ease; }
.toggle input::after { content: ""; position: absolute; top: 4px; left: 4px; width: 22px; height: 22px; border-radius: 50%; background: var(--muted); transition: transform 300ms var(--ease), background-color 250ms ease; }
.toggle input:checked { background: rgba(110, 231, 183, 0.25); }
.toggle input:checked::after { transform: translateX(22px); background: var(--mint); box-shadow: 0 0 12px var(--mint); }
.field { display: flex; flex-direction: column; gap: 8px; font-weight: 500; }
.field input { font: 400 1rem/1.3 var(--font); color: var(--text); padding: 14px 16px; min-height: 50px; border-radius: 14px; border: 0; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line-2); transition: box-shadow 200ms ease; max-width: 420px; }
.field input:focus { outline: none; box-shadow: inset 0 0 0 1px var(--mint), 0 0 0 4px rgba(110, 231, 183, 0.15); }

/* ---------- Cómo se conecta ---------- */
.steps { position: relative; display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.steps-line { position: absolute; left: 34px; right: 34px; top: 34px; height: 2px; z-index: 0; }
.steps-line svg { width: 100%; height: 4px; overflow: visible; }
.steps-line path { stroke-width: 2; fill: none; }
.steps-line .base { stroke: var(--line-2); }
.steps-line .glow { stroke: var(--mint); filter: drop-shadow(0 0 6px var(--mint)); }
.step { position: relative; z-index: 1; }
.step .n { width: 68px; height: 68px; border-radius: 22px; display: grid; place-items: center; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line-2), 0 0 40px -10px rgba(110, 231, 183, 0.5); color: var(--mint); margin-bottom: 26px; }
.step .n svg { width: 28px; height: 28px; }
.step strong { display: block; font-size: var(--fs-h3); font-weight: 600; letter-spacing: -0.02em; margin-bottom: 8px; }
.step p { color: var(--muted); max-width: 32ch; }

/* ---------- Preguntas ---------- */
.faq { max-width: 860px; margin-inline: auto; display: flex; flex-direction: column; gap: 10px; }
.faq details { border-radius: var(--r-md); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow 300ms ease, background-color 300ms ease; }
.faq details[open] { background: var(--surface-2); box-shadow: inset 0 0 0 1px rgba(110, 231, 183, 0.25); }
.faq summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 22px 24px; font-size: var(--fs-h3); font-weight: 500; letter-spacing: -0.02em; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .plus { position: relative; width: 32px; height: 32px; flex: none; border-radius: 50%; display: grid; place-items: center; background: rgba(var(--fg-rgb), 0.06); transition: transform 400ms var(--ease), background-color 300ms ease; }
.faq summary .plus::before, .faq summary .plus::after { content: ""; position: absolute; width: 12px; height: 2px; border-radius: 2px; background: var(--text); }
.faq summary .plus::after { transform: rotate(90deg); transition: transform 400ms var(--ease); }
.faq details[open] .plus { background: var(--mint); transform: rotate(180deg); }
.faq details[open] .plus::before, .faq details[open] .plus::after { background: var(--on-mint); }
.faq details[open] .plus::after { transform: rotate(0deg); }
.faq .answer { padding: 0 24px 24px; color: var(--muted); max-width: 64ch; }
.faq .answer a { color: var(--mint); }

/* ---------- Cierre ---------- */
.cta { position: relative; overflow: hidden; text-align: center; padding: clamp(110px, 14vw, 200px) 0; }
.cta .wrap { position: relative; z-index: 1; }
.cta h2 { font-size: clamp(2.75rem, 1.4rem + 6vw, 7rem); letter-spacing: -0.055em; line-height: 0.98; }
.cta p { margin: 24px auto 40px; max-width: 42ch; font-size: var(--fs-lead); color: var(--muted); }
.focal-ring { position: absolute; left: 50%; top: 50%; width: 900px; height: 900px; margin: -450px 0 0 -450px; border-radius: 50%; z-index: 0; pointer-events: none; box-shadow: inset 0 0 0 1px var(--line), 0 0 0 120px rgba(var(--fg-rgb), 0.012), 0 0 0 240px rgba(var(--fg-rgb), 0.01); animation: spin 60s linear infinite; }
.focal-ring::before { content: ""; position: absolute; left: 50%; top: -5px; width: 10px; height: 10px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 20px var(--mint); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Pie ---------- */
.foot { border-top: 1px solid var(--line); padding: 64px 0 40px; background: var(--bg-2); overflow: hidden; }
.foot-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 40px; }
.foot-top .brand { font-size: 1.375rem; }
.foot-top p { margin-top: 14px; color: var(--muted); max-width: 34ch; }
.foot-cols { display: flex; gap: clamp(32px, 6vw, 88px); flex-wrap: wrap; }
.foot-cols h3 { font-size: var(--fs-small); color: var(--muted); font-weight: 500; letter-spacing: 0; margin-bottom: 14px; }
.foot-cols ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.foot-cols a { text-decoration: none; color: var(--text); opacity: 0.85; transition: color 200ms ease, opacity 200ms ease; }
.foot-cols a:hover { opacity: 1; color: var(--mint); }
.foot-word { margin-top: 64px; font-weight: 700; letter-spacing: -0.07em; line-height: 0.85; font-size: clamp(3rem, 15.5vw, 13.5rem); text-align: center; background: linear-gradient(180deg, rgba(var(--fg-rgb), 0.16), rgba(var(--fg-rgb), 0)); -webkit-background-clip: text; background-clip: text; color: transparent; user-select: none; white-space: nowrap; }
.foot-legal { margin-top: 24px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: var(--fs-small); color: var(--muted); }

/* ---------- Páginas legales ---------- */
.doc-top { position: relative; z-index: 2; padding: 28px var(--gutter) 0; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.doc-top a { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 650; letter-spacing: -0.03em; font-size: 1.125rem; }
.doc-top i { width: 34px; height: 34px; display: block; background: url("/marca/ficha.svg") center / contain no-repeat; }
.doc { position: relative; width: min(100% - var(--gutter) * 2, 760px); margin: 0 auto; padding: clamp(56px, 8vw, 110px) 0 clamp(80px, 10vw, 140px); }
.doc h1 { font-size: clamp(2.5rem, 1.6rem + 4vw, 4.5rem); letter-spacing: -0.05em; }
.doc .updated { margin: 16px 0 48px; color: var(--muted); }
.doc h2 { font-size: var(--fs-h3); margin: 44px 0 12px; }
.doc p, .doc li { color: var(--doc-ink); line-height: 1.7; }
.doc p + p { margin-top: 12px; }
.doc ul, .doc ol { padding-left: 1.2em; display: flex; flex-direction: column; gap: 8px; margin: 12px 0 0; }
.doc a { color: var(--mint); }
.foot-small { padding: 48px var(--gutter) 40px; }
.foot-small .foot-name { font-weight: 700; letter-spacing: -0.06em; font-size: clamp(2.5rem, 8vw, 6rem); line-height: 0.9; margin: 0 0 24px; }
.foot-small .foot-name span { color: var(--mint); }
.foot-small .foot-legal { margin-top: 0; }
.foot-small .foot-legal a { color: var(--text); }

/* ---------- Entradas (las controla GSAP; sin JS se ve todo) ---------- */
.js [data-reveal] { opacity: 0; }

/* ---------- Teléfono y tablet ---------- */
@media (max-width: 900px) {
  .nav ul { display: none; }
  .nav { padding-left: 14px; }
  .nav .btn { padding: 0 16px; }
  .nav-login { padding: 0 12px; }
  .hero { padding-top: 120px; }
  .scene { height: 460px; margin-top: 56px; }
  .inbox { width: 100%; height: 80%; grid-template-columns: 1fr; }
  .ib-side { display: none; }
  .orb { width: 52px; height: 52px; border-radius: 16px; }
  .orb i { width: 22px; height: 22px; }
  /* En pantallas chicas, 4 canales en las esquinas */
  .o-ms, .o-gm, .o-hm { display: none; }
  .o-wa { left: 0; top: 0; } .o-ig { right: 0; top: 0; } .o-ml { left: 0; bottom: 0; } .o-tg { right: 0; top: auto; bottom: 0; }
  .day-pin { min-height: 0; padding: 96px 0 40px; }
  .day-grid, .demo { grid-template-columns: 1fr; }
  .bento { grid-template-columns: 1fr; }
  .span-6, .span-4, .span-3, .span-2 { grid-column: auto; }
  .card-wide { flex-direction: column; align-items: flex-start; }
  .card { min-height: 280px; }
  .steps { grid-template-columns: 1fr; gap: 40px; }
  .steps-line { display: none; }
  .faq summary { padding: 18px; font-size: 1.0625rem; }
  .faq .answer { padding: 0 18px 20px; }
  .focal-ring { width: 600px; height: 600px; margin: -300px 0 0 -300px; }
}
@media (max-width: 520px) {
  .hero-cta .btn { width: 100%; }
  .bubble { font-size: 12px; }
  .row { grid-template-columns: 30px 1fr auto; padding: 10px; }
  .chan { width: 30px; height: 30px; }
  .seg-viz span { padding: 10px 12px; font-size: 13px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
  .aurora::after { display: none; }
  .js [data-reveal] { opacity: 1; }
}

/* ---------- Selector de tema ---------- */
.theme-toggle {
  appearance: none; border: 0; cursor: pointer; width: 44px; height: 44px; flex: none; border-radius: 50%;
  display: grid; place-items: center; background: transparent; color: var(--text);
  transition: background-color 200ms ease, transform 200ms var(--ease);
}
.theme-toggle:hover { background: rgba(var(--fg-rgb), 0.08); }
.theme-toggle:active { transform: scale(0.92); }
.theme-toggle svg { width: 19px; height: 19px; }
.theme-toggle .moon, html[data-theme="light"] .theme-toggle .sun { display: none; }
html[data-theme="light"] .theme-toggle .moon { display: block; }
@media (max-width: 360px) { .theme-toggle { width: 38px; height: 38px; } }

/* ---------- Modo claro "vidrio" ----------
   Paneles blancos translúcidos y esmerilados sobre un fondo claro con luces de menta y turquesa.
   Mismos colores de marca, con la menta oscurecida donde tiene que leerse sobre claro. */
html[data-theme="light"] {
  --bg: #eaf4f0;
  --bg-2: rgba(255, 255, 255, 0.4);
  --surface: rgba(255, 255, 255, 0.58);
  --surface-2: rgba(255, 255, 255, 0.78);
  --line: rgba(16, 64, 52, 0.1);
  --line-2: rgba(16, 64, 52, 0.17);
  --text: #0b2620;
  --muted: #4e6a61;
  --mint: #0b7a5e;
  --emerald: #059669;
  --teal: #0e7490;
  --sage: #3f7d6f;
  --on-mint: #ffffff;
  --fg-rgb: 11, 38, 32;
  --nav-glass: rgba(255, 255, 255, 0.55);
  --doc-ink: #26453c;
  --warn-ink: #92400e;
  color-scheme: light;
}
html[data-theme="light"] body {
  background:
    radial-gradient(60vw 60vw at 5% -10%, rgba(110, 231, 183, 0.55), transparent 60%),
    radial-gradient(55vw 55vw at 100% 25%, rgba(34, 211, 238, 0.32), transparent 60%),
    radial-gradient(70vw 50vw at 40% 105%, rgba(132, 182, 171, 0.45), transparent 60%),
    var(--bg);
  background-attachment: fixed;
}
html[data-theme="light"] .aurora::after { opacity: 0.025; }
html[data-theme="light"] .aurora i { opacity: 0.7; }

/* El vidrio: todo lo que era un panel oscuro se esmerila y gana un canto de luz. */
html[data-theme="light"] :is(.card, .chat-in, .faq details, .seg, .seg-viz, .step .n, .chips span, .pill, .orb, .bubble, .access .badge-icon, .field input, .toggle input, .chan, .ib-list > *) {
  -webkit-backdrop-filter: blur(20px) saturate(170%);
  backdrop-filter: blur(20px) saturate(170%);
}
html[data-theme="light"] :is(.card, .faq details, .step .n, .access .badge-icon) {
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.8), 0 10px 34px -16px rgba(11, 38, 32, 0.22);
}
html[data-theme="light"] .faq details[open] { box-shadow: inset 0 0 0 1px rgba(11, 122, 94, 0.3), 0 10px 34px -16px rgba(11, 38, 32, 0.22); }
html[data-theme="light"] .inbox {
  background: rgba(255, 255, 255, 0.5);
  -webkit-backdrop-filter: blur(24px) saturate(170%);
  backdrop-filter: blur(24px) saturate(170%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.85), 0 40px 80px -40px rgba(11, 38, 32, 0.35);
}
html[data-theme="light"] :is(.orb, .bubble) {
  background: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.9), 0 16px 34px -14px rgba(11, 38, 32, 0.28);
}
html[data-theme="light"] .nav.is-scrolled { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.8), 0 18px 40px -22px rgba(11, 38, 32, 0.3); }
html[data-theme="light"] .btn-primary { box-shadow: 0 10px 30px -12px rgba(11, 122, 94, 0.6); }
html[data-theme="light"] .btn-primary:hover { box-shadow: 0 14px 40px -12px rgba(11, 122, 94, 0.75); }
html[data-theme="light"] .note { color: #78350f; }
html[data-theme="light"] .marquee, html[data-theme="light"] .foot {
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
}

/* ---------- Portada: mensajes que flotan (fondo del modo claro) ---------- */
.drift { display: none; position: absolute; inset: 0; z-index: 0; pointer-events: none; }
html[data-theme="light"] .grid-bg { display: none; }
html[data-theme="light"] .drift { display: block; }
.drift span {
  position: absolute; display: inline-flex; align-items: center; gap: 8px; white-space: nowrap;
  padding: 10px 14px; border-radius: 14px; font-size: 14px; color: var(--text);
  background: rgba(255, 255, 255, 0.55); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.85), 0 14px 30px -16px rgba(11, 38, 32, 0.3);
  -webkit-backdrop-filter: blur(14px) saturate(160%); backdrop-filter: blur(14px) saturate(160%);
  animation: drift 14s ease-in-out infinite alternate;
}
.drift .ico { width: 16px; height: 16px; flex: none; }
/* Más lejos = más chico, más borroso y más transparente */
.drift .d1 { left: 4%;  top: 520px; animation-duration: 15s; }
.drift .d2 { right: 4%; top: 490px; animation-duration: 17s; animation-delay: -4s; }
.drift .d3 { left: 11%; top: 650px; scale: 0.88; filter: blur(1.2px); opacity: 0.75; animation-duration: 19s; animation-delay: -8s; }
.drift .d4 { right: 11%; top: 640px; scale: 0.9; filter: blur(1px); opacity: 0.8; animation-duration: 16s; animation-delay: -2s; }
.drift .d5 { left: 1.5%; top: 300px; scale: 0.8; filter: blur(2.5px); opacity: 0.5; animation-duration: 21s; animation-delay: -10s; }
.drift .d6 { right: 1.5%; top: 330px; scale: 0.8; filter: blur(2px); opacity: 0.55; animation-duration: 20s; animation-delay: -6s; }
.drift .d7 { left: 20%; top: 118px; scale: 0.75; filter: blur(3px); opacity: 0.4; animation-duration: 23s; animation-delay: -12s; }
@keyframes drift { from { translate: 0 0; } to { translate: 18px -26px; } }
@media (max-width: 1360px) { .drift .d5, .drift .d6 { display: none; } }
@media (max-width: 1100px) { .drift .d3, .drift .d4, .drift .d7 { display: none; } }
@media (max-width: 720px) { .drift { display: none !important; } }

/* ---------- Sonido de los mensajes ---------- */
.sound-toggle {
  appearance: none; border: 0; cursor: pointer; display: inline-flex; align-items: center; gap: 9px;
  margin: 26px auto 0; min-height: 44px; padding: 0 18px; border-radius: 999px;
  font: 500 0.9375rem/1 var(--font); color: var(--text);
  background: rgba(var(--fg-rgb), 0.06); box-shadow: inset 0 0 0 1px var(--line-2);
  transition: background-color 200ms ease, box-shadow 200ms ease, transform 200ms var(--ease);
}
.sound-toggle:hover { background: rgba(var(--fg-rgb), 0.1); }
.sound-toggle:active { transform: scale(0.96); }
.sound-toggle svg { width: 18px; height: 18px; }
.sound-toggle .s-on, .sound-toggle[aria-pressed="true"] .s-off { display: none; }
.sound-toggle[aria-pressed="true"] .s-on { display: block; color: var(--mint); }
.sound-toggle[aria-pressed="true"] { box-shadow: inset 0 0 0 1px var(--mint); }
html[data-theme="light"] .sound-toggle { background: rgba(255, 255, 255, 0.6); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
@media (prefers-reduced-motion: reduce) { .drift span { animation: none; } }

.sound-float {
  position: fixed; right: 18px; bottom: 18px; z-index: 60; display: inline-flex; align-items: center; gap: 8px;
  appearance: none; border: 0; cursor: pointer; min-height: 44px; padding: 0 16px; border-radius: 999px;
  font: 500 0.9375rem/1 var(--font); color: var(--text);
  background: var(--nav-glass); box-shadow: inset 0 0 0 1px var(--line-2), 0 14px 34px -14px rgba(0, 0, 0, 0.5);
  -webkit-backdrop-filter: blur(16px) saturate(140%); backdrop-filter: blur(16px) saturate(140%);
  animation: float-in 300ms var(--ease) both; transition: transform 200ms var(--ease), background-color 200ms ease;
}
.sound-float[hidden] { display: none; }
.sound-float:hover { background: rgba(var(--fg-rgb), 0.12); }
.sound-float:active { transform: scale(0.95); }
.sound-float svg { width: 18px; height: 18px; }
@keyframes float-in { from { opacity: 0; transform: translateY(10px); } }

/* ---------- Bandeja de la portada: grupos (la IA clasifica cada conversación) ---------- */
.ib-groups-title { margin: 14px 10px 4px; font-size: 12px; font-weight: 600; color: var(--muted); }
.ib-side .grp { align-items: center; gap: 8px; justify-content: flex-start; transition: background-color 300ms ease, color 300ms ease; }
.ib-side .grp em { margin-left: auto; }
.ib-side .grp i { width: 8px; height: 8px; border-radius: 50%; flex: none; background: var(--g); }
.ib-side .grp.is-hit { background: color-mix(in srgb, var(--g) 16%, transparent); color: var(--text); }
.ib-side .grp.is-hit em { background: var(--g); color: #04201a; }
.g-ventas { --g: #34d399; }
.g-cobranzas { --g: #fbbf24; }
.g-consultas { --g: #38bdf8; }
.g-reclamos { --g: #fb7185; }
html[data-theme="light"] .g-ventas { --g: #059669; }
html[data-theme="light"] .g-cobranzas { --g: #d97706; }
html[data-theme="light"] .g-consultas { --g: #0284c7; }
html[data-theme="light"] .g-reclamos { --g: #e11d48; }
.row .who b { display: flex; align-items: center; gap: 8px; min-width: 0; }
.tag {
  display: inline-flex; align-items: center; flex: none; padding: 1px 8px; border-radius: 999px;
  font-size: 11px; font-weight: 600; letter-spacing: 0; line-height: 1.5;
  color: var(--g); background: color-mix(in srgb, var(--g) 15%, transparent);
}
.tag.is-new { animation: tag-in 600ms var(--ease) both; }
@keyframes tag-in { 0% { opacity: 0; transform: scale(0.4); } 60% { opacity: 1; transform: scale(1.12); } 100% { transform: none; } }
@media (prefers-reduced-motion: reduce) { .tag.is-new { animation: none; } }

/* Celulares muy angostos: en la barra queda solo el ícono de la marca */
@media (max-width: 359px) { .nav .brand > span { display: none; } }

/* Celular: la columna de grupos no entra; van como una fila de fichas arriba de las conversaciones */
.ib-chips { display: none; }
@media (max-width: 900px) {
  .ib-chips { display: flex; flex: none; flex-wrap: wrap; gap: 6px; margin: 0 0 4px; }
  .ib-chips .grp {
    display: inline-flex; align-items: center; gap: 6px; flex: none; padding: 5px 9px; border-radius: 999px;
    font-size: 11.5px; font-weight: 600; color: var(--muted); background: rgba(var(--fg-rgb), 0.05);
    transition: background-color 300ms ease, color 300ms ease;
  }
  .ib-chips .grp i { width: 7px; height: 7px; border-radius: 50%; background: var(--g); }
  .ib-chips .grp em { font-style: normal; font-size: 11px; padding: 0 5px; border-radius: 999px; background: rgba(var(--fg-rgb), 0.08); }
  .ib-chips .grp.is-hit { background: color-mix(in srgb, var(--g) 18%, transparent); color: var(--text); }
  .ib-chips .grp.is-hit em { background: var(--g); color: #04201a; }
}
