/* InvestorResearch — sistema visual (imagen de marca: azul marino, verde, pizarra y blanco) */

@font-face { font-family: "Figtree"; font-weight: 300; src: url("fonts/Figtree-Light.ttf") format("truetype"); }
@font-face { font-family: "Figtree"; font-weight: 400; src: url("fonts/Figtree-Regular.ttf") format("truetype"); }
@font-face { font-family: "Figtree"; font-weight: 500; src: url("fonts/Figtree-Medium.ttf") format("truetype"); }
@font-face { font-family: "Figtree"; font-weight: 600; src: url("fonts/Figtree-SemiBold.ttf") format("truetype"); }
@font-face { font-family: "Figtree"; font-weight: 700; src: url("fonts/Figtree-Bold.ttf") format("truetype"); }

/* ---------- Tokens: modo claro ---------- */
:root {
  color-scheme: light;
  --navy: #022454;            /* relleno con texto blanco encima */
  --green: #18AA7B;
  --green-2: #11966B;         /* verde para texto */
  --slate: #9199B0;
  --white: #FFFFFF;

  --bg: #F3F4F8;
  --text: #022454;
  --text-2: #4B5675;
  --text-3: #7C849C;
  --placeholder: #A8AFC2;
  --line: rgba(2, 36, 84, .09);
  --line-2: rgba(2, 36, 84, .16);
  --card: rgba(255, 255, 255, .78);
  --card-edge: rgba(255, 255, 255, .9);
  --surface: #FFFFFF;         /* tarjetas internas, botones secundarios */
  --field: #F6F7FB;
  --inset: rgba(246, 247, 251, .85);
  --hover: rgba(255, 255, 255, .8);
  --bar-bg: rgba(243, 244, 248, .72);
  --drawer: rgba(255, 255, 255, .94);
  --backdrop: rgba(2, 36, 84, .18);
  --navy-soft: #E8EDF6;
  --green-soft: #E4F6EF;
  --amber: #B7791F;
  --amber-soft: #FBF1DE;
  --red: #D14358;
  --red-soft: #FBE8EB;
  --hold: #2A4E8C;
  --toast: #022454;
  --toast-err: #7A1F2E;
  --scroll: rgba(2, 36, 84, .16);
  --scroll-hover: rgba(2, 36, 84, .28);
  --blob1: #B9C5DB;
  --blob2: #AEDFD2;
  --blob3: #D5E9E4;
  --blob-opacity: .75;
  --candle-up: #18AA7B;
  --candle-down: #022454;
  --candle-alpha: .09;

  --radius: 20px;
  --shadow-sm: 0 1px 2px rgba(2, 36, 84, .05), 0 2px 8px rgba(2, 36, 84, .04);
  --shadow: 0 1px 2px rgba(2, 36, 84, .05), 0 12px 32px -12px rgba(2, 36, 84, .14);
  --shadow-lg: 0 2px 4px rgba(2, 36, 84, .05), 0 24px 48px -16px rgba(2, 36, 84, .22);
  --glow-green: 0 0 0 4px rgba(24, 170, 123, .16);
  --ease: cubic-bezier(.22, 1, .36, 1);
  --spring: cubic-bezier(.34, 1.56, .64, 1);
  --mono: "Cascadia Mono", "Cascadia Code", Consolas, monospace;
}

/* ---------- Tokens: modo oscuro (marino profundo) ---------- */
:root[data-theme="dark"] {
  color-scheme: dark;
  --navy: #2A4E8C;
  --green-2: #3DD2A0;
  --bg: #0A1224;
  --text: #E8EDF7;
  --text-2: #A9B3C9;
  --text-3: #7D88A3;
  --placeholder: #5E6982;
  --line: rgba(255, 255, 255, .08);
  --line-2: rgba(255, 255, 255, .15);
  --card: rgba(17, 27, 50, .74);
  --card-edge: rgba(255, 255, 255, .06);
  --surface: #16213D;
  --field: rgba(255, 255, 255, .045);
  --inset: rgba(8, 14, 30, .55);
  --hover: rgba(255, 255, 255, .05);
  --bar-bg: rgba(10, 18, 36, .72);
  --drawer: rgba(15, 24, 46, .96);
  --backdrop: rgba(0, 0, 0, .45);
  --navy-soft: rgba(120, 155, 220, .14);
  --green-soft: rgba(24, 170, 123, .16);
  --amber: #E7B04F;
  --amber-soft: rgba(231, 176, 79, .14);
  --red: #F07083;
  --red-soft: rgba(240, 112, 131, .15);
  --hold: #8FB0EA;
  --toast: #1F3A6B;
  --toast-err: #8C2A3B;
  --scroll: rgba(255, 255, 255, .14);
  --scroll-hover: rgba(255, 255, 255, .26);
  --blob1: #1C3566;
  --blob2: #0E4B40;
  --blob3: #14324A;
  --blob-opacity: .6;
  --candle-up: #3DD2A0;
  --candle-down: #8FA6D6;
  --candle-alpha: .08;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 14px 34px -14px rgba(0, 0, 0, .6);
  --shadow-lg: 0 2px 4px rgba(0, 0, 0, .3), 0 26px 50px -16px rgba(0, 0, 0, .7);
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: "Figtree", "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  user-select: none;
}
input, .feed, .conclusion p, .preview-title, .headline { user-select: text; }
button { font: inherit; color: inherit; cursor: pointer; }
h1, h2, h3, p { margin: 0; }
svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
[hidden] { display: none !important; }
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-thumb { background: var(--scroll); border-radius: 10px; border: 3px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-thumb:hover { background-color: var(--scroll-hover); }

/* Cambio de tema: círculo que se expande desde el botón (View Transitions) */
::view-transition-old(root), ::view-transition-new(root) { animation: none; mix-blend-mode: normal; }
::view-transition-new(root) { z-index: 999; }

/* Cambio de idioma: fundido breve del contenido */
.layout, .topbar .tagline { transition: opacity .18s, filter .18s; }
.lang-swap .layout, .lang-swap .topbar .tagline { opacity: 0; filter: blur(3px); }

/* ---------- Fondo animado ---------- */
.aurora { position: fixed; inset: 0; z-index: -2; overflow: hidden; pointer-events: none; }
.blob { position: absolute; border-radius: 50%; filter: blur(70px); opacity: var(--blob-opacity); will-change: transform; transition: background .6s; }
.b1 { width: 620px; height: 520px; left: -180px; top: -160px; background: var(--blob1); animation: drift1 26s ease-in-out infinite alternate; }
.b2 { width: 640px; height: 560px; right: -200px; bottom: -220px; background: var(--blob2); animation: drift2 30s ease-in-out infinite alternate; }
.b3 { width: 420px; height: 380px; right: 18%; top: -220px; background: var(--blob3); opacity: calc(var(--blob-opacity) * .7); animation: drift3 34s ease-in-out infinite alternate; }
@keyframes drift1 { to { transform: translate(140px, 90px) scale(1.12); } }
@keyframes drift2 { to { transform: translate(-160px, -80px) scale(1.1); } }
@keyframes drift3 { to { transform: translate(-120px, 110px) scale(.9); } }

.market {
  position: fixed; left: 0; top: 0; width: 100%; height: 520px; z-index: -1; pointer-events: none;
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 45%, transparent 100%);
          mask-image: linear-gradient(to bottom, #000 0%, #000 45%, transparent 100%);
}

/* ---------- Entrada escalonada ---------- */
.reveal { opacity: 0; transform: translateY(14px); }
.ready .reveal { animation: rise .7s var(--ease) forwards; animation-delay: calc(var(--d, 0) * 70ms); }
@keyframes rise { to { opacity: 1; transform: none; } }

/* ---------- Barra superior ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 16px 40px;
  border-bottom: 1px solid transparent;
  transition: border-color .3s, box-shadow .3s, background .3s;
}
.topbar.scrolled { background: var(--bar-bg); backdrop-filter: blur(18px) saturate(1.4); border-bottom-color: var(--line); box-shadow: 0 6px 24px -18px rgba(2, 36, 84, .35); }
.brand { display: flex; align-items: center; gap: 14px; min-width: 0; }
.brand-logo { height: 46px; width: auto; transition: transform .5s var(--spring); }
.brand:hover .brand-logo { transform: translateY(-2px) rotate(-4deg) scale(1.05); }
.logo-dark { display: none; }
[data-theme="dark"] .logo-light { display: none; }
[data-theme="dark"] .logo-dark { display: block; }
.wordmark { font-size: 25px; line-height: 1.1; letter-spacing: -.01em; white-space: nowrap; }
.w-a { font-weight: 600; }
.w-b { font-weight: 500; }
.tagline { font-size: 12.5px; color: var(--text-3); margin-top: 2px; white-space: nowrap; }
.top-actions { display: flex; align-items: center; gap: 10px; }

.engine-chip {
  display: inline-flex; align-items: center; gap: 8px;
  height: 38px; padding: 0 14px; border-radius: 999px;
  background: var(--card); border: 1px solid var(--line);
  font-size: 13px; font-weight: 500; color: var(--text-2); white-space: nowrap;
  box-shadow: var(--shadow-sm);
}
.engine-chip .dot, .tag .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--slate); position: relative; }
.engine-chip.ok .dot, .tag-green .dot { background: var(--green); }
.engine-chip.ok .dot::after, .tag-green .dot::after, .live.on i::after {
  content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 2px solid var(--green);
  animation: ping 1.8s var(--ease) infinite;
}
.engine-chip.warn .dot { background: var(--amber); }
@keyframes ping { from { transform: scale(.5); opacity: .9; } to { transform: scale(1.6); opacity: 0; } }
@media (max-width: 1180px) { .engine-chip span { display: none; } .engine-chip { padding: 0 14px; } }

/* Selector de idioma con banderas */
.lang-switch { position: relative; display: inline-flex; padding: 3px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.lang-switch button {
  position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 7px;
  height: 30px; padding: 0 11px 0 8px; border: 0; border-radius: 9px; background: none;
  font-size: 13px; font-weight: 700; letter-spacing: .03em; color: var(--text-3); transition: color .3s;
}
.lang-switch button:hover { color: var(--text); }
.lang-switch button.on { color: var(--text); }
.flag { width: 21px; height: 14px; border-radius: 3px; stroke: none; flex: none; box-shadow: 0 0 0 1px rgba(0, 0, 0, .08); transition: transform .45s var(--spring), filter .3s; filter: saturate(.55) opacity(.75); }
.lang-switch button.on .flag { filter: none; transform: scale(1.08); }
.lang-switch button:active .flag { transform: scale(.9) rotate(-6deg); }
.lang-thumb { position: absolute; top: 3px; bottom: 3px; left: 0; border-radius: 9px; background: var(--surface); box-shadow: var(--shadow-sm), 0 0 0 1px var(--line); transition: transform .45s var(--spring), width .45s var(--spring); }

.icon-btn {
  width: 38px; height: 38px; display: grid; place-items: center; flex: none;
  border-radius: 12px; border: 1px solid var(--line); background: var(--card);
  color: var(--text); box-shadow: var(--shadow-sm);
  transition: transform .25s var(--ease), box-shadow .25s, background .25s;
}
.icon-btn svg { width: 19px; height: 19px; grid-area: 1 / 1; transition: transform .6s var(--ease), opacity .4s; }
.icon-btn:hover { transform: translateY(-1px); box-shadow: var(--shadow); background: var(--surface); }
#openSettings:hover svg { transform: rotate(90deg); }
/* Sol/luna: el icono visible gira y se intercambia */
.theme-btn .moon { opacity: 0; transform: rotate(-90deg) scale(.5); }
[data-theme="dark"] .theme-btn .sun { opacity: 0; transform: rotate(90deg) scale(.5); }
[data-theme="dark"] .theme-btn .moon { opacity: 1; transform: none; }
.theme-btn:hover .sun { transform: rotate(45deg); }
[data-theme="dark"] .theme-btn:hover .moon { transform: rotate(-18deg) scale(1.08); }

/* ---------- Estructura ---------- */
.layout {
  display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 28px;
  max-width: 1440px; margin: 0 auto; padding: 18px 40px 48px;
  align-items: start;
}
.col-main { display: flex; flex-direction: column; min-width: 0; }
.col-side { display: flex; flex-direction: column; gap: 20px; position: sticky; top: 96px; }
@media (max-width: 1080px) {
  .layout { grid-template-columns: minmax(0, 1fr); }
  .col-side { position: static; }
  .tagline { display: none; }
}

.card {
  background: var(--card);
  border: 1px solid var(--card-edge);
  outline: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px) saturate(1.3);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.side-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }

.caps { font-size: 11.5px; font-weight: 600; letter-spacing: .09em; text-transform: uppercase; color: var(--text-3); }

/* ---------- Hero ---------- */
.hero {
  max-height: 320px; overflow: hidden; padding: 26px 4px 26px;
  transition: max-height .6s var(--ease), padding .6s var(--ease), opacity .4s;
}
.has-run .hero { max-height: 0; padding-top: 0; padding-bottom: 0; opacity: 0; }
.has-run .composer { margin-top: 10px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--green-2);
  background: rgba(24, 170, 123, .1); padding: 6px 12px; border-radius: 999px;
}
.eyebrow-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); }
.hero h1 {
  font-size: clamp(34px, 3.4vw, 46px); line-height: 1.08; font-weight: 700; letter-spacing: -.025em;
  margin: 16px 0 12px; max-width: 760px;
}
.lead { font-size: 17px; line-height: 1.55; color: var(--text-2); max-width: 680px; }

/* ---------- Composer ---------- */
.composer { padding: 22px; position: relative; z-index: 2; }
.composer-row { display: flex; gap: 12px; }
.url-field {
  flex: 1; display: flex; align-items: center; gap: 12px; height: 58px; padding: 0 8px 0 18px;
  background: var(--field); border: 1.5px solid var(--line); border-radius: 16px; cursor: text;
  transition: border-color .25s, box-shadow .25s, background .25s;
}
.url-field:hover { border-color: var(--line-2); }
.url-field.focus { background: var(--surface); border-color: var(--green); box-shadow: var(--glow-green); }
.url-field.valid { border-color: rgba(24, 170, 123, .55); }
.url-field.invalid { border-color: var(--red); box-shadow: 0 0 0 4px rgba(209, 67, 88, .12); }
.url-field.shake { animation: shake .45s; }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.yt { width: 26px; height: 26px; flex: none; color: var(--slate); transition: color .3s, transform .4s var(--spring); }
.yt .yt-play { fill: currentColor; stroke: none; }
.url-field.valid .yt { color: #E62117; transform: scale(1.1); }
#url {
  flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent;
  font: 500 16px "Figtree", sans-serif; color: var(--text);
}
#url::placeholder { color: var(--placeholder); font-weight: 400; }
/* Botón ✕ del enlace: aparece cuando hay texto y no se está analizando */
.clear-btn {
  width: 30px; height: 30px; flex: none; display: grid; place-items: center; border: 0; border-radius: 50%;
  background: var(--navy-soft); color: var(--text-2);
  opacity: 0; transform: scale(.6) rotate(-90deg); pointer-events: none;
  transition: opacity .25s, transform .4s var(--spring), background .2s, color .2s;
}
.clear-btn svg { width: 14px; height: 14px; stroke-width: 2.4; }
.url-field.has-text .clear-btn { opacity: 1; transform: none; pointer-events: auto; }
.clear-btn:hover { background: var(--red-soft); color: var(--red); transform: rotate(90deg); }
.busy .clear-btn { opacity: 0; pointer-events: none; }
.busy .url-field { opacity: .75; cursor: default; }
.busy .chip-btn { pointer-events: none; opacity: .5; }

/* Salida de las tarjetas de progreso y resultado al reiniciar */
.run.leaving, .result.leaving { animation: leave .28s var(--ease) forwards; }
@keyframes leave { to { opacity: 0; transform: translateY(12px) scale(.985); } }

.chip-btn {
  height: 40px; padding: 0 16px; border-radius: 11px; border: 1px solid var(--line);
  background: var(--surface); font-size: 14px; font-weight: 600; color: var(--text);
  transition: transform .2s var(--ease), box-shadow .2s, background .2s;
}
.chip-btn:hover { box-shadow: var(--shadow-sm); transform: translateY(-1px); }
.chip-btn:active { transform: scale(.96); }
.field-hint { font-size: 13px; color: var(--text-3); margin: 10px 4px 0; transition: color .2s; }
.field-hint.err { color: var(--red); }

/* Mientras analiza, el editor se reduce a la fila del enlace para dejar sitio al progreso */
.collapsible { display: grid; grid-template-rows: 1fr; transition: grid-template-rows .5s var(--ease), opacity .35s; }
.collapsible > div { overflow: hidden; min-height: 0; }
.busy .collapsible, .has-result .collapsible { grid-template-rows: 0fr; opacity: 0; }
.busy .composer .preview, .has-result .composer .preview { grid-template-rows: 0fr; margin-top: 0; }

/* Botón principal */
.cta {
  position: relative; overflow: hidden; flex: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 58px; padding: 0 26px 0 28px; min-width: 212px;
  border: 0; border-radius: 16px; color: var(--white);
  font-size: 16px; font-weight: 600; letter-spacing: .005em;
  background: linear-gradient(135deg, #1DBB88 0%, var(--green) 45%, #0F8C63 100%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .25) inset, 0 10px 24px -10px rgba(17, 150, 107, .75);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), filter .3s;
}
.cta::before {  /* brillo que cruza el botón */
  content: ""; position: absolute; top: 0; bottom: 0; left: -60%; width: 40%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .35), transparent);
  transform: skewX(-20deg); transition: left .7s var(--ease);
}
.cta:hover { transform: translateY(-2px); box-shadow: 0 1px 0 rgba(255, 255, 255, .25) inset, 0 16px 32px -12px rgba(17, 150, 107, .85), var(--glow-green); }
.cta:hover::before { left: 120%; }
.cta:active { transform: translateY(0) scale(.98); }
.cta-arrow { width: 20px; height: 20px; stroke-width: 2.2; transition: transform .35s var(--spring); }
.cta:hover .cta-arrow { transform: translateX(4px); }
.cta-spinner { display: none; width: 18px; height: 18px; border-radius: 50%; border: 2.4px solid rgba(255, 255, 255, .35); border-top-color: #fff; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.cta:disabled { cursor: default; filter: saturate(.55) brightness(1.05); transform: none; box-shadow: none; }
.cta:disabled .cta-spinner { display: inline-block; }
.cta:disabled .cta-arrow { display: none; }
.cta-sm { height: 44px; min-width: 0; padding: 0 20px; font-size: 15px; border-radius: 13px; }
.ripple { position: absolute; border-radius: 50%; background: rgba(255, 255, 255, .45); transform: scale(0); animation: ripple .6s ease-out forwards; pointer-events: none; }
@keyframes ripple { to { transform: scale(4); opacity: 0; } }

.btn {
  height: 44px; padding: 0 18px; border-radius: 13px; border: 1px solid var(--line-2);
  background: var(--surface); color: var(--text); font-size: 14.5px; font-weight: 600;
  transition: transform .25s var(--ease), box-shadow .25s, border-color .25s;
}
.btn:hover { transform: translateY(-1px); box-shadow: var(--shadow); border-color: var(--line-2); }
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .5; pointer-events: none; }
.link-btn { border: 0; background: none; padding: 4px 0; font-size: 13.5px; font-weight: 600; color: var(--green-2); position: relative; }
.link-btn::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1.5px; background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease); }
.link-btn:hover::after { transform: scaleX(1); }

/* Vista previa del vídeo */
.preview { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .5s var(--ease), margin .5s var(--ease); margin-top: 0; }
.preview.show { grid-template-rows: 1fr; margin-top: 16px; }
.preview-inner {
  overflow: hidden; display: flex; gap: 16px; align-items: center;
  opacity: 0; transform: translateY(-6px); transition: opacity .4s .1s, transform .5s var(--ease);
}
.preview.show .preview-inner { opacity: 1; transform: none; }
.thumb { position: relative; width: 168px; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; flex: none; background: var(--navy-soft); box-shadow: var(--shadow-sm); }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .6s var(--ease); }
.preview:hover .thumb img { transform: scale(1.06); }
.thumb-play { position: absolute; inset: 0; margin: auto; width: 36px; height: 36px; border-radius: 50%; background: rgba(2, 36, 84, .72); backdrop-filter: blur(4px); }
.thumb-play::after { content: ""; position: absolute; left: 14px; top: 11px; border-left: 11px solid #fff; border-top: 7px solid transparent; border-bottom: 7px solid transparent; }
.preview-text { min-width: 0; }
.preview-title { font-size: 16.5px; font-weight: 600; line-height: 1.35; margin: 8px 0 3px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.preview-sub { font-size: 13.5px; color: var(--text-2); }
.tag { display: inline-flex; align-items: center; gap: 7px; height: 24px; padding: 0 10px; border-radius: 999px; font-size: 12px; font-weight: 600; }
.tag-green { background: var(--green-soft); color: var(--green-2); }

/* Opciones */
.options { display: flex; flex-wrap: wrap; gap: 18px 20px; margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line); align-items: flex-end; }
.opt { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.opt-label { font-size: 11.5px; font-weight: 600; letter-spacing: .09em; text-transform: uppercase; color: var(--text-3); }
.seg { position: relative; display: inline-flex; align-self: flex-start; padding: 4px; border-radius: 13px; background: var(--field); border: 1px solid var(--line); }
.seg button {
  position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 15px;
  border: 0; border-radius: 10px; background: none;
  font-size: 14px; font-weight: 500; color: var(--text-2); white-space: nowrap; transition: color .3s;
}
.seg button:hover { color: var(--text); }
.seg button.on { color: #FFFFFF; font-weight: 600; }
.seg button:disabled, .seg button.locked { opacity: .45; cursor: not-allowed; }
.seg-ic { width: 16px; height: 16px; stroke-width: 2; transition: transform .45s var(--spring); }
.seg button.on .seg-ic { transform: scale(1.12); }
.seg-thumb { position: absolute; top: 4px; bottom: 4px; left: 0; width: 0; border-radius: 10px; background: var(--navy); box-shadow: 0 6px 14px -6px rgba(2, 36, 84, .6); transition: transform .45s var(--spring), width .45s var(--spring); }
.opt-meta { flex: 1 1 220px; }

/* Desplegable del motor de análisis. El menú se mueve al <body> al iniciarse: las tarjetas con
   backdrop-filter atrapan los position: fixed y lo recortarían. */
.dd { position: relative; }
.dd-btn {
  display: flex; align-items: center; gap: 10px; height: 46px; min-width: 268px; padding: 0 12px 0 6px;
  border-radius: 13px; border: 1px solid var(--line); background: var(--field); color: var(--text);
  transition: border-color .25s, box-shadow .25s, background .25s;
}
.dd-btn:hover { border-color: var(--line-2); }
.dd.open .dd-btn { border-color: var(--green); box-shadow: var(--glow-green); background: var(--surface); }
.dd-current { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; text-align: left; }
.dd-current b { font-size: 14.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dd-chev { width: 18px; height: 18px; color: var(--text-3); transition: transform .35s var(--spring); flex: none; }
.dd.open .dd-chev { transform: rotate(180deg); }
.dd-menu {
  position: fixed; z-index: 80; margin: 0; padding: 6px; list-style: none; width: 360px; max-width: calc(100vw - 24px);
  background: var(--drawer); backdrop-filter: blur(20px); border-radius: 16px; box-shadow: var(--shadow-lg), 0 0 0 1px var(--line);
  opacity: 0; transform: translateY(-6px) scale(.98); transform-origin: top left; pointer-events: none;
  transition: opacity .2s, transform .3s var(--spring);
}
.dd-menu.open { opacity: 1; transform: none; pointer-events: auto; }
.dd-opt {
  display: grid; grid-template-columns: auto minmax(0, 1fr) 18px; gap: 12px; align-items: center;
  padding: 11px 12px; border-radius: 12px; cursor: pointer; transition: background .2s, transform .2s var(--ease);
}
.dd-opt:hover, .dd-opt.hover { background: var(--field); }
.dd-opt:active { transform: scale(.985); }
.dd-opt[aria-disabled="true"] { opacity: .45; cursor: not-allowed; }
.dd-text { display: flex; flex-direction: column; min-width: 0; }
.dd-text b { font-size: 14.5px; font-weight: 600; }
.dd-text small { font-size: 12.5px; color: var(--text-3); line-height: 1.35; }
.dd-check { width: 18px; height: 18px; color: var(--green); stroke-width: 2.4; opacity: 0; transform: scale(.5); transition: opacity .2s, transform .35s var(--spring); }
.dd-opt[aria-selected="true"] .dd-check { opacity: 1; transform: none; }
.dd-badge {
  display: inline-grid; place-items: center; min-width: 64px; height: 26px; padding: 0 9px; border-radius: 8px;
  font-size: 11px; font-weight: 800; letter-spacing: .08em; white-space: nowrap; position: relative; overflow: hidden;
}
.dd-badge.free { color: #FFFFFF; background: linear-gradient(135deg, #1DBB88, #0F8C63); box-shadow: 0 4px 12px -4px rgba(17, 150, 107, .6); }
.dd-badge.free::after {  /* destello que recorre la etiqueta GRATIS */
  content: ""; position: absolute; top: 0; bottom: 0; width: 40%; left: -60%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .55), transparent); transform: skewX(-20deg);
  animation: badge-shine 3.2s ease-in-out infinite;
}
@keyframes badge-shine { 0%, 60% { left: -60%; } 100% { left: 130%; } }
.dd-badge.plan { color: var(--text); background: var(--navy-soft); }
.dd-badge.api { color: var(--text-2); background: var(--field); box-shadow: inset 0 0 0 1px var(--line-2); }
.meta-line { display: flex; flex-wrap: wrap; gap: 6px; }
.meta-pill { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 11px; border-radius: 999px; background: var(--navy-soft); color: var(--text); font-size: 13px; font-weight: 500; white-space: nowrap; animation: pop .35s var(--spring); }
.meta-pill.green { background: var(--green-soft); color: var(--green-2); }
@keyframes pop { from { transform: scale(.85); opacity: 0; } }
.style-note { font-size: 13px; color: var(--text-2); margin: 14px 2px 0; }
.style-note b { color: var(--text); font-weight: 600; }
.style-note > span { margin: 0 6px; color: var(--text-3); }
.style-note .flag { vertical-align: -2px; margin-right: 4px; filter: none; }
.style-note.flash { animation: note .45s var(--ease); }
@keyframes note { from { opacity: 0; transform: translateY(-4px); } }

/* ---------- Progreso ---------- */
.run, .result { display: none; margin-top: 22px; padding: 26px 28px 28px; }
.run.show, .result.show { display: block; animation: rise-in .6s var(--ease); }
@keyframes rise-in { from { opacity: 0; transform: translateY(18px) scale(.99); } }
.run-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
h2 { font-size: 22px; font-weight: 700; letter-spacing: -.015em; }
.run-sub { font-size: 14px; color: var(--text-2); margin-top: 2px; }
.run-meta { display: flex; align-items: center; gap: 12px; }
.status { height: 30px; display: inline-flex; align-items: center; padding: 0 13px; border-radius: 999px; font-size: 13px; font-weight: 600; background: var(--field); color: var(--text-2); transition: background .3s, color .3s; white-space: nowrap; }
.status.active { background: var(--navy-soft); color: var(--text); }
.status.done { background: var(--green-soft); color: var(--green-2); }
.status.fail { background: var(--red-soft); color: var(--red); }
.timer { font: 500 14px var(--mono); color: var(--text-3); font-variant-numeric: tabular-nums; min-width: 46px; text-align: right; }

.stepper { list-style: none; margin: 26px 0 8px; padding: 0; display: flex; align-items: flex-start; }
.step { flex: 0 0 196px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.node {
  position: relative; width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center;
  background: var(--surface); border: 1.5px solid var(--line-2); color: var(--slate);
  transition: background .4s, border-color .4s, color .4s, transform .5s var(--spring), box-shadow .4s;
}
.node svg { width: 22px; height: 22px; grid-area: 1 / 1; transition: opacity .3s, transform .5s var(--spring); }
.node .ok { opacity: 0; transform: scale(.4); stroke-width: 2.6; stroke-dasharray: 24; stroke-dashoffset: 24; }
.step.active .node { background: var(--navy); border-color: var(--navy); color: var(--white); transform: scale(1.08); box-shadow: 0 10px 22px -8px rgba(2, 36, 84, .55); }
.step.active .node::before, .step.active .node::after {
  content: ""; position: absolute; inset: -2px; border-radius: 50%; border: 2px solid var(--navy); animation: halo 2s var(--ease) infinite;
}
.step.active .node::after { animation-delay: 1s; }
@keyframes halo { from { transform: scale(1); opacity: .5; } to { transform: scale(1.7); opacity: 0; } }
.step.done .node { background: var(--green); border-color: var(--green); color: var(--white); animation: bump .5s var(--spring); }
.step.done .node .ic { opacity: 0; transform: scale(.4); }
.step.done .node .ok { opacity: 1; transform: none; stroke-dashoffset: 0; transition: opacity .2s, transform .5s var(--spring), stroke-dashoffset .5s .15s var(--ease); }
.step.failed .node { background: var(--red); border-color: var(--red); color: var(--white); animation: shake .45s; }
@keyframes bump { 50% { transform: scale(1.18); } }
.step-title { margin-top: 12px; font-size: 14.5px; font-weight: 600; color: var(--text-3); transition: color .3s; }
.step-sub { font-size: 12.5px; color: var(--text-3); margin-top: 1px; }
.step.active .step-title, .step.done .step-title { color: var(--text); }
.track { flex: 1; height: 4px; margin: 24px -72px 0; border-radius: 4px; background: var(--navy-soft); overflow: hidden; position: relative; z-index: -1; }
.track-fill {
  display: block; height: 100%; width: 0; border-radius: 4px;
  background: linear-gradient(90deg, var(--green), #3DD2A0, var(--green)); background-size: 200% 100%;
  transition: width .9s var(--ease); animation: flow 1.6s linear infinite;
}
@keyframes flow { to { background-position: -200% 0; } }

.run-grid { display: grid; grid-template-columns: minmax(0, 1fr) 220px; gap: 18px; margin-top: 22px; }
.feed-wrap { background: var(--inset); border: 1px solid var(--line); border-radius: 16px; padding: 14px 6px 6px 16px; min-width: 0; }
.feed-head { display: flex; justify-content: space-between; align-items: center; padding: 0 10px 8px 0; }
.live { display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 600; color: var(--text-3); }
.live i { width: 8px; height: 8px; border-radius: 50%; background: var(--slate); position: relative; }
.live.on { color: var(--green-2); }
.live.on i { background: var(--green); }
.feed { list-style: none; margin: 0; padding: 0 10px 8px 0; height: 300px; overflow-y: auto; scroll-behavior: smooth; }
.feed li {
  display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; gap: 12px; align-items: start;
  padding: 8px 8px; border-radius: 10px; animation: slide-in .45s var(--ease);
  transition: background .2s;
}
.feed li:hover { background: var(--hover); }
@keyframes slide-in { from { opacity: 0; transform: translateX(-12px); } }
.fi { width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; background: var(--surface); color: var(--slate); border: 1px solid var(--line); }
.fi svg { width: 14px; height: 14px; stroke-width: 2.2; }
.fm { font: 400 13px/1.55 var(--mono); color: var(--text-2); word-break: break-word; padding-top: 3px; }
.ft { font: 400 11.5px var(--mono); color: var(--text-3); padding-top: 5px; font-variant-numeric: tabular-nums; }
.k-step .fi { background: var(--navy); color: var(--white); border-color: var(--navy); }
.k-step .fm { font-family: "Figtree", sans-serif; font-size: 14px; font-weight: 600; color: var(--text); }
.k-search .fi { background: var(--navy-soft); color: var(--text); border-color: transparent; }
.k-search .q { display: inline-block; background: var(--surface); border: 1px solid var(--line); border-radius: 7px; padding: 0 7px; color: var(--text); }
.k-ok .fi { background: var(--green-soft); color: var(--green-2); border-color: transparent; }
.k-ok .fm { color: var(--green-2); }
.k-warn .fi { background: var(--amber-soft); color: var(--amber); border-color: transparent; }
.k-warn .fm { color: var(--amber); }
.k-err .fi { background: var(--red-soft); color: var(--red); border-color: transparent; }
.k-err .fm { color: var(--red); }
.k-dim .fm { color: var(--text-3); font-size: 11.5px; white-space: pre-wrap; }
.feed .typing .fm::after { content: "▍"; animation: blink 1s steps(1) infinite; color: var(--green); margin-left: 2px; }
@keyframes blink { 50% { opacity: 0; } }

.run-side { display: flex; flex-direction: column; gap: 14px; }
.stat {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 18px 12px 16px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line);
}
.ring { width: 104px; height: 104px; transform: rotate(-90deg); }
.ring circle { stroke-width: 6; }
.ring-bg { stroke: var(--navy-soft); }
.ring-fg { stroke: var(--green); stroke-dasharray: 169.6; stroke-dashoffset: 169.6; transition: stroke-dashoffset .8s var(--ease); }
.stat-num { position: absolute; top: 18px; height: 104px; display: flex; align-items: baseline; justify-content: center; padding-top: 35px; font-size: 28px; font-weight: 700; font-variant-numeric: tabular-nums; }
.stat-num small { font-size: 14px; font-weight: 500; color: var(--text-3); margin-left: 1px; }
.stat-num.bump span { animation: bump .45s var(--spring); display: inline-block; }
.stat-label { margin-top: 10px; font-size: 13px; font-weight: 600; color: var(--text-2); }
.video-mini { border-radius: 16px; background: var(--surface); border: 1px solid var(--line); padding: 10px; opacity: 0; transform: translateY(8px); transition: opacity .5s, transform .5s var(--ease); }
.video-mini.show { opacity: 1; transform: none; }
.vm-thumb { aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden; background: var(--navy-soft); }
.vm-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.vm-title { font-size: 13.5px; font-weight: 600; line-height: 1.35; margin-top: 9px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.vm-meta { font-size: 12px; color: var(--text-3); margin-top: 4px; }

/* ---------- Resultado ---------- */
.result { position: relative; overflow: hidden; }
.confetti { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 3; }
.result-head { display: flex; align-items: center; gap: 16px; }
.result-head > div:nth-child(2) { flex: 1; min-width: 0; }
.result-badge { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; background: var(--green); color: var(--white); box-shadow: 0 10px 22px -8px rgba(17, 150, 107, .8); animation: bump .6s .1s var(--spring) both; flex: none; }
.result-badge svg { width: 26px; height: 26px; stroke-width: 2.6; stroke-dasharray: 24; stroke-dashoffset: 24; animation: draw .6s .35s var(--ease) forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.result-actions { display: flex; gap: 10px; }
.headline {
  margin-top: 20px; padding: 18px 22px; border-radius: 16px; position: relative; overflow: hidden;
  background: linear-gradient(120deg, #022454, #0D3572); color: #FFFFFF;
  font-size: 19px; font-weight: 600; line-height: 1.4; letter-spacing: -.005em;
  opacity: 0; animation: rise .6s .1s var(--ease) forwards;
}
.headline::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--green); }
.headline small { display: block; font-size: 11.5px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: #7FE0BD; margin-bottom: 4px; }
.headline:empty { display: none; }
.result-grid { display: grid; grid-template-columns: 1fr 1.3fr; gap: 14px; margin-top: 16px; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px; transition: transform .3s var(--ease), box-shadow .3s; opacity: 0; animation: rise .6s var(--ease) forwards; animation-delay: calc(.15s + var(--d, 0) * 80ms); }
.tile:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.tones { display: flex; align-items: center; gap: 14px; margin-top: 12px; }
.tones > div { display: flex; flex-direction: column; gap: 6px; }
.tones small { font-size: 12.5px; color: var(--text-3); }
.tone-arrow { width: 20px; height: 20px; color: var(--slate); margin-top: 18px; }
.tone { display: inline-flex; align-items: center; height: 32px; padding: 0 14px; border-radius: 10px; font-size: 14px; font-weight: 700; letter-spacing: .03em; background: var(--field); color: var(--text-2); }
.tone.ALCISTA { background: var(--green-soft); color: var(--green-2); }
.tone.BAJISTA { background: var(--red-soft); color: var(--red); }
.tone.MIXTO { background: var(--amber-soft); color: var(--amber); }
.tone.NEUTRAL { background: var(--navy-soft); color: var(--text); }
.vbar { display: flex; height: 12px; border-radius: 6px; overflow: hidden; margin-top: 16px; background: var(--navy-soft); gap: 2px; }
.vbar span { width: 0; transition: width 1s var(--ease); }
.vlegend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 12px; font-size: 13px; color: var(--text-2); }
.vlegend b { color: var(--text); font-variant-numeric: tabular-nums; }
.vlegend i { display: inline-block; width: 9px; height: 9px; border-radius: 3px; margin-right: 6px; }
.keys { list-style: none; margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.keys:empty { display: none; }
.keys li {
  background: var(--green-soft); border-radius: 16px; padding: 14px 16px; font-size: 14px; font-weight: 500; line-height: 1.45;
  opacity: 0; animation: rise .6s var(--ease) forwards; animation-delay: calc(.3s + var(--d, 0) * 90ms);
  transition: transform .3s var(--ease);
}
.keys li:hover { transform: translateY(-2px); }
.keys b { display: block; font-size: 22px; font-weight: 700; color: var(--green-2); line-height: 1.1; margin-bottom: 4px; }
.conclusion { margin-top: 14px; --d: 2; }
.conclusion p { margin-top: 8px; font-size: 15px; line-height: 1.6; color: var(--text-2); }
.actions-head { margin: 22px 0 10px; }
.actions { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.action {
  background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; position: relative; overflow: hidden;
  opacity: 0; animation: rise .6s var(--ease) forwards; animation-delay: calc(.4s + var(--d, 0) * 90ms);
  transition: transform .3s var(--ease), box-shadow .3s;
}
.action:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.action::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--c, var(--slate)); }
.a-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.a-type { font-size: 12px; font-weight: 700; letter-spacing: .06em; padding: 3px 9px; border-radius: 7px; color: var(--c); background: var(--cs); }
.a-ticker { font: 500 12.5px var(--mono); color: var(--text-3); }
.a-name { font-size: 16px; font-weight: 700; margin-top: 10px; line-height: 1.3; }
.a-why { font-size: 13px; color: var(--text-2); margin-top: 4px; line-height: 1.45; }
.a-meta { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.a-meta span { font-size: 11.5px; font-weight: 600; padding: 2px 8px; border-radius: 6px; background: var(--field); color: var(--text-2); }

/* ---------- Panel lateral ---------- */
.side-card { padding: 20px 20px 16px; }
.side-card h3 { font-size: 17px; font-weight: 700; letter-spacing: -.01em; }
.side-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.recent { list-style: none; margin: 0 -8px; padding: 0; max-height: 310px; overflow-y: auto; }
.recent li {
  display: flex; align-items: center; gap: 12px; padding: 10px 8px; border-radius: 12px; cursor: pointer;
  opacity: 0; animation: rise .5s var(--ease) forwards; animation-delay: calc(var(--d, 0) * 60ms);
  transition: background .25s, transform .25s var(--ease);
}
.recent li:hover { background: var(--surface); transform: translateX(3px); box-shadow: var(--shadow-sm); }
.pdf-ic { width: 38px; height: 44px; flex: none; border-radius: 9px; display: grid; place-items: center; background: var(--navy-soft); color: var(--text); font-size: 10px; font-weight: 700; letter-spacing: .04em; transition: transform .4s var(--spring), background .3s, color .3s; }
.recent li:hover .pdf-ic { transform: rotate(-6deg) scale(1.06); background: var(--navy); color: var(--white); }
.recent li.fresh .pdf-ic { background: var(--green); color: var(--white); }
.r-text { min-width: 0; flex: 1; }
.r-title { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.r-date { font-size: 12.5px; color: var(--text-3); }
.r-go { width: 16px; height: 16px; color: var(--slate); opacity: 0; transform: translateX(-4px); transition: opacity .25s, transform .25s var(--ease); }
.recent li:hover .r-go { opacity: 1; transform: none; }
.recent li.empty { font-size: 13.5px; color: var(--text-3); padding: 10px 8px 6px; cursor: default; }
.recent li.empty:hover { background: none; transform: none; box-shadow: none; }
.how-list { list-style: none; margin: 14px 0 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.how-list li { display: flex; gap: 12px; }
.how-n { width: 28px; height: 28px; flex: none; border-radius: 9px; display: grid; place-items: center; font-size: 13.5px; font-weight: 700; background: var(--green-soft); color: var(--green-2); transition: transform .4s var(--spring); }
.how-list li:hover .how-n { transform: scale(1.12) rotate(-6deg); }
.how-list b { font-size: 14px; font-weight: 600; }
.how-list p { font-size: 13px; color: var(--text-2); line-height: 1.45; margin-top: 1px; }
.disclaimer { font-size: 12.5px; color: var(--text-3); padding: 0 6px; }

/* ---------- Ajustes ---------- */
.backdrop { position: fixed; inset: 0; z-index: 40; background: var(--backdrop); backdrop-filter: blur(3px); opacity: 0; pointer-events: none; transition: opacity .35s; }
.drawer {
  position: fixed; top: 12px; right: 12px; bottom: 12px; width: 420px; max-width: calc(100% - 24px); z-index: 50;
  display: flex; flex-direction: column; gap: 22px; padding: 22px 24px;
  background: var(--drawer); backdrop-filter: blur(24px); border-radius: 22px; box-shadow: var(--shadow-lg), 0 0 0 1px var(--line);
  transform: translateX(calc(100% + 24px)); transition: transform .5s var(--ease);
}
.settings-open .backdrop { opacity: 1; pointer-events: auto; }
.settings-open .drawer { transform: none; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; }
.field { display: flex; flex-direction: column; gap: 8px; }
.input-row { display: flex; gap: 8px; }
.input-row input {
  flex: 1; min-width: 0; height: 44px; padding: 0 14px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--field);
  font: 500 14px "Figtree", sans-serif; color: var(--text); outline: 0; transition: border-color .25s, box-shadow .25s, background .25s;
}
.input-row input::placeholder { color: var(--placeholder); }
.input-row input:hover { border-color: var(--line-2); }
.input-row input:focus { border-color: var(--green); box-shadow: var(--glow-green); background: var(--surface); }
.input-row input:disabled { opacity: .55; }
.field-note { font-size: 12.5px; color: var(--text-3); }
.field-note a { color: var(--green-2); font-weight: 600; }
.drawer-foot { margin-top: auto; }
.cli-box { font-size: 13.5px; color: var(--text-2); background: var(--field); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; line-height: 1.5; }
.cli-box b { color: var(--text); }
.cli-box code { font: 12px var(--mono); color: var(--text-3); word-break: break-all; }

/* ---------- Notificaciones ---------- */
.toasts { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); z-index: 60; display: flex; flex-direction: column; gap: 10px; align-items: center; pointer-events: none; }
.toast {
  display: flex; align-items: center; gap: 10px; padding: 12px 18px 12px 14px; border-radius: 14px;
  background: var(--toast); color: #FFFFFF; font-size: 14px; font-weight: 500; box-shadow: var(--shadow-lg);
  animation: toast-in .45s var(--spring); pointer-events: auto; max-width: 560px;
}
.toast.out { animation: toast-out .35s var(--ease) forwards; }
.toast i { width: 22px; height: 22px; flex: none; border-radius: 7px; display: grid; place-items: center; background: rgba(255, 255, 255, .14); }
.toast i svg { width: 14px; height: 14px; stroke-width: 2.4; }
.toast.ok i { background: var(--green); }
.toast.err { background: var(--toast-err); }
.toast .flag { filter: none; }
@keyframes toast-in { from { opacity: 0; transform: translateY(16px) scale(.96); } }
@keyframes toast-out { to { opacity: 0; transform: translateY(10px) scale(.97); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
