/* CTM · Plataforma completa — base compartida */
:root {
  --brand: #2f6bff; --brand2: #22c55e; --accent: #ffc93c;
  --ok: #16a34a; --warn: #d97706; --bad: #e11d48; --info: #2563eb;
  --ease: cubic-bezier(.2,.8,.2,1); --spring: cubic-bezier(.34,1.56,.64,1);
  --font: 'Plus Jakarta Sans', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --mono: ui-monospace, 'Cascadia Code', 'SFMono-Regular', Consolas, monospace;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body { font-family: var(--font); -webkit-font-smoothing: antialiased; line-height: 1.45; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
svg { display: block; }
.ic-i, i[data-i] { display: inline-flex; width: 1.15em; height: 1.15em; flex: none; }
.ic-i svg, i[data-i] svg { width: 100%; height: 100%; }
.mono { font-family: var(--mono); font-size: .92em; letter-spacing: -.01em; }
.num { font-variant-numeric: tabular-nums; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.logo-fallback { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: linear-gradient(135deg, var(--brand), var(--brand2)); color: #fff; font-weight: 800; font-size: 12px; }

/* Avisos flotantes */
.toasts { position: fixed; z-index: 9999; left: 50%; bottom: 22px; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: min(92vw, 460px); }
.toast { display: flex; align-items: center; gap: 10px; padding: 11px 16px 11px 12px; border-radius: 14px; background: #0f172a; color: #f8fafc; font-size: 14px; font-weight: 600; box-shadow: 0 12px 34px rgba(2,6,23,.35); opacity: 0; transform: translateY(14px) scale(.97); transition: all .35s var(--spring); }
.toast.show { opacity: 1; transform: none; }
.toast svg { width: 22px; height: 22px; padding: 4px; border-radius: 50%; background: var(--ok); color: #fff; flex: none; }
.toast.bad svg { background: var(--bad); } .toast.info svg { background: var(--info); }

/* Barra de demostración compartida (enlaces entre vistas) */
.demo-bar { position: fixed; z-index: 500; top: 12px; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 4px; padding: 4px; border-radius: 99px; background: rgba(9,14,27,.78); backdrop-filter: blur(14px); border: 1px solid rgba(255,255,255,.1); box-shadow: 0 10px 30px rgba(0,0,0,.3); }
.demo-bar a, .demo-bar button { display: flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 99px; font-size: 13px; font-weight: 600; color: #cbd5e1; white-space: nowrap; transition: background .2s, color .2s; }
.demo-bar a:hover, .demo-bar button:hover { background: rgba(255,255,255,.1); color: #fff; }
.demo-bar a.on { background: #fff; color: #0b1222; }
.demo-bar .db-home { padding: 0 8px 0 6px; }
.demo-bar .db-home img, .demo-bar .db-home .logo-fallback { width: 24px; height: 24px; object-fit: contain; font-size: 8px; }
.demo-bar .ic-i { width: 15px; height: 15px; }
.demo-bar .db-sep { width: 1px; height: 18px; background: rgba(255,255,255,.14); margin: 0 2px; }
@media (max-width: 760px) {
  .demo-bar { top: auto; bottom: 10px; max-width: calc(100vw - 16px); overflow-x: auto; scrollbar-width: none; }
  .demo-bar::-webkit-scrollbar { display: none; }
  .demo-bar .lb { display: none; }
  .demo-bar a, .demo-bar button { padding: 0 10px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }
