/* =====================================================================
   Signat — sistema de diseño (mobile-first)
   Paleta FileStream: azul «Stream» #1b9bd8 (acento), azul «File» #244e85 (profundo)
   ===================================================================== */
:root {
  --acento: #1b9bd8;
  --acento-osc: #1683b8;
  --acento-suave: #e6f4fb;
  --profundo: #244e85;
  --marino: #0f2440;
  --grad: linear-gradient(135deg, #244e85 0%, #1b9bd8 60%, #35d0e6 100%);
  --tinta: #10182b;
  --texto: #2b3445;
  --gris: #6b7280;
  --gris-claro: #e6e9f0;
  --gris-suave: #f3f5f9;
  --fondo: #f6f7fb;
  --blanco: #fff;
  --verde: #16a570; --verde-claro: #dcf5ea;
  --rojo: #e23d4f; --rojo-claro: #fde4e7;
  --ambar: #e9960c; --ambar-claro: #fff1d8;
  --azul-claro: #e6f4fb;
  --radio: 14px; --radio-sm: 10px;
  --sombra: 0 1px 2px rgba(16,24,43,.04), 0 8px 24px rgba(16,24,43,.06);
  --sombra-alta: 0 24px 60px rgba(16,24,43,.18);
  --fuente: -apple-system, BlinkMacSystemFont, "SF Pro Text", Inter, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --sidebar: 240px;
  --tabbar: 64px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--fuente); color: var(--texto); background: var(--fondo); font-size: 15px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
a { color: var(--acento-osc); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0 0 .4rem; color: var(--tinta); letter-spacing: -.02em; line-height: 1.15; }
h1 { font-size: 1.6rem; font-weight: 800; }
h2 { font-size: 1.2rem; font-weight: 700; }
h3 { font-size: 1rem; font-weight: 700; }
p { margin: 0 0 .8rem; }
.muted { color: var(--gris); }
.small { font-size: .85rem; }
.xs { font-size: .75rem; }
.mono { font-family: var(--mono); font-size: .8rem; word-break: break-all; }
.hidden { display: none !important; }
.center { text-align: center; }
svg.i { width: 1.1em; height: 1.1em; vertical-align: -.18em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
@media (min-width: 760px) { h1 { font-size: 1.9rem; } }

/* ---------- marca ---------- */
.brand { display: inline-flex; align-items: center; gap: .55rem; font-weight: 800; letter-spacing: .1em; font-size: .9rem; color: var(--tinta); }
.brand .mark { width: 30px; height: 30px; border-radius: 9px; background: var(--grad); display: grid; place-items: center; color: #fff; }
.brand .mark svg { width: 18px; height: 18px; }
.brand.light { color: #fff; }

/* ---------- layout público ---------- */
.pub-header { position: sticky; top: 0; z-index: 30; background: rgba(255,255,255,.86); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--gris-claro); }
.pub-header .inner { max-width: 1140px; margin: 0 auto; padding: .65rem 1rem; display: flex; align-items: center; gap: .6rem; }
.pub-header nav { margin-left: auto; display: flex; gap: .2rem; align-items: center; }
.pub-header nav a { padding: .45rem .7rem; border-radius: 10px; font-weight: 600; font-size: .9rem; color: var(--texto); }
.pub-header nav a:hover { background: var(--gris-suave); text-decoration: none; }
.pub-header nav a.cta { background: var(--acento); color: #fff; }
.pub-header nav .hide-m { display: none; }
@media (min-width: 640px) { .pub-header nav .hide-m { display: inline-block; } }
.pub-main { max-width: 1140px; margin: 0 auto; padding: 1.2rem 1rem 3rem; }
.pub-main.narrow { max-width: 480px; }
footer.site { border-top: 1px solid var(--gris-claro); background: #fff; }
footer.site .inner { max-width: 1140px; margin: 0 auto; padding: 1.6rem 1rem; display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between; color: var(--gris); font-size: .82rem; }
footer.site nav { display: flex; gap: 1rem; flex-wrap: wrap; }

/* ---------- layout app ---------- */
.app { min-height: 100vh; }
.app-top { position: sticky; top: 0; z-index: 30; background: #fff; border-bottom: 1px solid var(--gris-claro); display: flex; align-items: center; gap: .6rem; padding: .6rem 1rem; }
.app-top .spacer { flex: 1; }
.app-top .avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--profundo); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: .85rem; }
.app-side { display: none; }
.app-main { padding: 1rem 1rem calc(var(--tabbar) + 1.2rem); max-width: 1180px; margin: 0 auto; }
.tabbar { position: fixed; left: 0; right: 0; bottom: 0; height: var(--tabbar); background: #fff; border-top: 1px solid var(--gris-claro); display: grid; grid-template-columns: repeat(4, 1fr); z-index: 30; padding-bottom: env(safe-area-inset-bottom); }
.tabbar a, .tabbar button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .15rem; font-size: .68rem; font-weight: 600; color: var(--gris); background: none; border: 0; font-family: inherit; }
.tabbar a.active { color: var(--acento-osc); }
.tabbar svg.i { width: 22px; height: 22px; }
.tabbar .new { position: relative; top: -14px; }
.tabbar .new span.btn-round { width: 48px; height: 48px; border-radius: 50%; background: var(--acento); color: #fff; display: grid; place-items: center; box-shadow: 0 8px 20px rgba(27,155,216,.4); }
.sheet { position: fixed; inset: 0; z-index: 40; background: rgba(16,24,43,.45); display: none; align-items: flex-end; }
.sheet.open { display: flex; }
.sheet .panel { background: #fff; width: 100%; border-radius: 18px 18px 0 0; padding: .8rem 1rem calc(1rem + env(safe-area-inset-bottom)); }
.sheet .panel a { display: flex; align-items: center; gap: .7rem; padding: .75rem .4rem; border-bottom: 1px solid var(--gris-suave); color: var(--tinta); font-weight: 600; }
.sheet .panel a:last-child { border-bottom: 0; }
@media (min-width: 960px) {
  .app { display: grid; grid-template-columns: var(--sidebar) 1fr; }
  .app-top { display: none; }
  .tabbar, .sheet { display: none !important; }
  .app-side { display: flex; flex-direction: column; background: var(--marino); color: #c8d3e3; min-height: 100vh; position: sticky; top: 0; height: 100vh; padding: 1.1rem .9rem; }
  .app-side .brand { margin: 0 .4rem 1.4rem; }
  .app-side nav a { display: flex; align-items: center; gap: .65rem; padding: .6rem .7rem; border-radius: 10px; color: #c8d3e3; font-weight: 600; font-size: .92rem; margin-bottom: .15rem; }
  .app-side nav a:hover { background: rgba(255,255,255,.07); text-decoration: none; color: #fff; }
  .app-side nav a.active { background: rgba(27,155,216,.22); color: #fff; }
  .app-side nav .sec { font-size: .68rem; text-transform: uppercase; letter-spacing: .1em; color: #7f8ea6; padding: .9rem .7rem .3rem; }
  .app-side .plan-card { margin-top: auto; background: rgba(255,255,255,.06); border-radius: 12px; padding: .8rem .9rem; font-size: .82rem; }
  .app-side .plan-card strong { color: #fff; }
  .app-side .plan-card .btn { margin-top: .5rem; width: 100%; justify-content: center; }
  .app-main { padding: 1.6rem 2rem 3rem; }
}

/* ---------- utilidades de layout ---------- */
.card { background: #fff; border-radius: var(--radio); box-shadow: var(--sombra); padding: 1.1rem; }
.card.pad-lg { padding: 1.5rem; }
.stack > * + * { margin-top: .8rem; }
.grid { display: grid; gap: 1rem; }
.grid.two, .grid.side, .grid.three, .grid.four { grid-template-columns: 1fr; }
@media (min-width: 760px) { .grid.two { grid-template-columns: 1fr 1fr; } .grid.three { grid-template-columns: repeat(3, 1fr); } .grid.four { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1080px) { .grid.side { grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr); } .grid.side > [style*="order:2"] { order: 1 !important; } .grid.side > [style*="order:1"] { order: 2 !important; } .grid.four { grid-template-columns: repeat(4, 1fr); } }
.row { display: flex; gap: .6rem; align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.page-head { display: flex; flex-direction: column; gap: .7rem; margin-bottom: 1rem; }
.page-head .actions { display: flex; gap: .5rem; flex-wrap: wrap; }
@media (min-width: 760px) { .page-head { flex-direction: row; align-items: flex-start; justify-content: space-between; } }
.toolbar-sticky { position: static; }

/* ---------- botones ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; padding: .62rem 1.05rem; border-radius: 999px; font-weight: 700; font-size: .92rem; border: 1px solid transparent; cursor: pointer; font-family: inherit; background: var(--gris-suave); color: var(--tinta); transition: transform .06s, box-shadow .12s, background .12s; white-space: nowrap; min-height: 42px; }
.btn:hover { text-decoration: none; transform: translateY(-1px); background: var(--gris-claro); }
.btn:active { transform: translateY(0); }
.btn.primary { background: var(--acento); color: #fff; box-shadow: 0 6px 16px rgba(27,155,216,.3); }
.btn.primary:hover { background: var(--acento-osc); }
.btn.deep { background: var(--profundo); color: #fff; }
.btn.deep:hover { background: #1c3f6d; }
.btn.grad { background: var(--grad); color: #fff; }
.btn.ghost { background: transparent; border-color: var(--gris-claro); }
.btn.ghost:hover { background: var(--gris-suave); }
.btn.danger { background: var(--rojo-claro); color: var(--rojo); }
.btn.success { background: var(--verde); color: #fff; }
.btn.sm { padding: .35rem .75rem; font-size: .82rem; min-height: 34px; }
.btn.lg { padding: .85rem 1.5rem; font-size: 1rem; min-height: 50px; }
.btn.block { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn-link { background: none; border: 0; color: var(--acento-osc); cursor: pointer; font: inherit; padding: 0; font-weight: 600; }
.icon-btn { width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--gris-claro); background: #fff; display: inline-grid; place-items: center; color: var(--gris); cursor: pointer; }
.icon-btn:hover { background: var(--gris-suave); color: var(--tinta); }

/* ---------- formularios ---------- */
label { display: block; font-weight: 600; font-size: .86rem; margin-bottom: .3rem; color: var(--tinta); }
input[type=text], input[type=search], input[type=email], input[type=url], input[type=password], input[type=number], input[type=color], textarea, select {
  width: 100%; padding: .7rem .85rem; border: 1px solid #d5d9e3; border-radius: var(--radio-sm); font: inherit; background: #fff; color: var(--tinta); font-size: 16px; min-height: 44px;
}
input[type=color] { padding: .2rem; height: 44px; }
input:focus, textarea:focus, select:focus { outline: 2px solid rgba(27,155,216,.3); border-color: var(--acento); }
input[type=file] { width: 100%; padding: .7rem; border: 1px dashed #c6ccd9; border-radius: var(--radio-sm); background: #fafbfe; font-size: .9rem; }
.field { margin-bottom: .9rem; }
.field .help { color: var(--gris); font-size: .8rem; margin-top: .3rem; }
.errorlist { color: var(--rojo); font-size: .85rem; margin: .25rem 0 0; padding-left: 1rem; }
.checkbox { display: flex; gap: .6rem; align-items: flex-start; font-weight: 500; font-size: .9rem; }
.checkbox input { margin-top: .25rem; width: 18px; height: 18px; }
.dropzone { border: 2px dashed #c6ccd9; border-radius: var(--radio); padding: 1.6rem 1rem; text-align: center; background: #fafbfe; cursor: pointer; transition: border-color .15s, background .15s; }
.dropzone.over, .dropzone:hover { border-color: var(--acento); background: var(--acento-suave); }
.dropzone input { display: none; }
.dropzone .ic { width: 44px; height: 44px; border-radius: 12px; background: var(--acento-suave); color: var(--acento-osc); display: grid; place-items: center; margin: 0 auto .5rem; }
.dropzone .ic svg { width: 22px; height: 22px; }
.dropzone strong { display: block; color: var(--tinta); }
.dropzone .file { margin-top: .5rem; font-weight: 600; color: var(--acento-osc); }
.divider { display: flex; align-items: center; gap: .8rem; color: var(--gris); font-size: .8rem; margin: 1rem 0; }
.divider::before, .divider::after { content: ""; flex: 1; border-top: 1px solid var(--gris-claro); }

/* ---------- mensajes ---------- */
.messages { list-style: none; margin: 0 0 1rem; padding: 0; }
.messages li { padding: .7rem .9rem; border-radius: var(--radio-sm); margin-bottom: .5rem; font-weight: 600; font-size: .88rem; display: flex; gap: .5rem; align-items: flex-start; }
.messages .success { background: var(--verde-claro); color: #0c6b48; }
.messages .error { background: var(--rojo-claro); color: var(--rojo); }
.messages .info, .messages .warning { background: var(--azul-claro); color: var(--profundo); }
.alert { padding: .8rem 1rem; border-radius: var(--radio-sm); font-size: .9rem; }
.alert.err { background: var(--rojo-claro); color: var(--rojo); }
.alert.ok { background: var(--verde-claro); color: #0c6b48; }
.alert.info { background: var(--azul-claro); color: var(--profundo); }
.alert.warn { background: var(--ambar-claro); color: #8a5a00; }

/* ---------- estados ---------- */
.pill { display: inline-flex; align-items: center; gap: .3rem; padding: .18rem .6rem; border-radius: 999px; font-size: .74rem; font-weight: 700; white-space: nowrap; }
.pill.gris { background: var(--gris-suave); color: var(--gris); }
.pill.azul { background: var(--azul-claro); color: var(--profundo); }
.pill.ambar { background: var(--ambar-claro); color: #8a5a00; }
.pill.verde { background: var(--verde-claro); color: #0c6b48; }
.pill.rojo { background: var(--rojo-claro); color: var(--rojo); }
.pill.grad { background: var(--grad); color: #fff; }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--rojo); flex: none; }
.dot.ok { background: var(--verde); }

/* ---------- stats ---------- */
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: .7rem; margin-bottom: 1rem; }
@media (min-width: 760px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.stat { background: #fff; border-radius: var(--radio); box-shadow: var(--sombra); padding: .9rem 1rem; }
.stat .n { font-size: 1.5rem; font-weight: 800; color: var(--tinta); letter-spacing: -.03em; line-height: 1.1; }
.stat .l { font-size: .78rem; color: var(--gris); font-weight: 600; }
.stat .ic { float: right; width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; background: var(--acento-suave); color: var(--acento-osc); }
.meter { height: 8px; background: var(--gris-suave); border-radius: 999px; overflow: hidden; }
.meter span { display: block; height: 100%; background: var(--grad); border-radius: 999px; }
.meter.warn span { background: var(--ambar); }
.meter.full span { background: var(--rojo); }

/* ---------- lista de documentos (filas) ---------- */
.filters { display: flex; gap: .4rem; overflow-x: auto; padding-bottom: .3rem; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.filters::-webkit-scrollbar { display: none; }
.filters a { padding: .4rem .8rem; border-radius: 999px; font-weight: 600; font-size: .85rem; color: var(--gris); white-space: nowrap; background: #fff; border: 1px solid var(--gris-claro); }
.filters a.active { background: var(--tinta); color: #fff; border-color: var(--tinta); }
.filters a:hover { text-decoration: none; }
.search { position: relative; }
.search input { padding-left: 2.4rem; }
.search svg { position: absolute; left: .85rem; top: 50%; transform: translateY(-50%); color: var(--gris); width: 18px; height: 18px; }
.doc-list { display: flex; flex-direction: column; gap: .6rem; }
.doc { background: #fff; border-radius: var(--radio); box-shadow: var(--sombra); padding: .9rem 1rem; display: grid; grid-template-columns: 40px 1fr; gap: .8rem; align-items: center; color: inherit; }
.doc:hover { text-decoration: none; box-shadow: 0 2px 4px rgba(16,24,43,.06), 0 12px 30px rgba(16,24,43,.1); }
.doc .ic { width: 40px; height: 40px; border-radius: 10px; background: var(--acento-suave); color: var(--acento-osc); display: grid; place-items: center; }
.doc .ic svg { width: 20px; height: 20px; }
.doc .t { font-weight: 700; color: var(--tinta); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.doc .m { font-size: .8rem; color: var(--gris); display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; }
.doc .r { grid-column: 1 / -1; display: flex; align-items: center; gap: .6rem; justify-content: space-between; }
.doc .progress { height: 6px; background: var(--gris-suave); border-radius: 999px; overflow: hidden; flex: 1; min-width: 70px; max-width: 160px; }
.doc .progress span { display: block; height: 100%; background: var(--grad); }
@media (min-width: 760px) { .doc { grid-template-columns: 40px 1fr auto; } .doc .r { grid-column: auto; } }

/* ---------- empty state ---------- */
.empty { text-align: center; padding: 2.4rem 1rem; }
.empty .ic { width: 64px; height: 64px; border-radius: 18px; background: var(--acento-suave); color: var(--acento-osc); display: grid; place-items: center; margin: 0 auto 1rem; }
.empty .ic svg { width: 30px; height: 30px; }
.empty h3 { margin-bottom: .3rem; }
.empty p { color: var(--gris); max-width: 28rem; margin: 0 auto 1rem; }

/* ---------- tabla ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.list { width: 100%; border-collapse: collapse; min-width: 520px; }
table.list th, table.list td { text-align: left; padding: .65rem .6rem; border-bottom: 1px solid var(--gris-claro); vertical-align: middle; font-size: .9rem; }
table.list th { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--gris); font-weight: 700; }
table.list tr:last-child td { border-bottom: 0; }

/* ---------- firmantes ---------- */
.signer { display: flex; align-items: center; gap: .7rem; padding: .7rem 0; border-bottom: 1px solid var(--gris-suave); }
.signer:last-child { border-bottom: 0; }
.signer .avatar { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; color: #fff; flex: none; font-size: .85rem; }
.signer .info { flex: 1; min-width: 0; }
.signer .info .name { font-weight: 700; color: var(--tinta); display: flex; gap: .4rem; align-items: center; flex-wrap: wrap; }
.signer .info .email { color: var(--gris); font-size: .83rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.signer form { display: inline; }

/* ---------- editor de cajas ---------- */
.editor-toolbar { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; margin-bottom: .7rem; }
.editor-toolbar select { width: auto; min-height: 38px; padding: .4rem .6rem; font-size: 14px; }
.pages { display: flex; flex-direction: column; gap: 1rem; align-items: center; background: #e8ebf2; border-radius: var(--radio); padding: .7rem; max-height: 70vh; overflow: auto; }
@media (min-width: 960px) { .pages { max-height: 78vh; padding: 1rem; } }
.page { position: relative; box-shadow: 0 4px 18px rgba(0,0,0,.16); background: #fff; width: 100%; max-width: 820px; }
.page img { display: block; width: 100%; height: auto; user-select: none; -webkit-user-drag: none; }
.page .num { position: absolute; top: .3rem; right: .4rem; font-size: .68rem; color: var(--gris); background: rgba(255,255,255,.85); padding: .1rem .4rem; border-radius: 6px; }
.box { position: absolute; border: 2px solid var(--c, #1b9bd8); background: color-mix(in srgb, var(--c, #1b9bd8) 16%, transparent); border-radius: 6px; cursor: move; display: flex; align-items: flex-end; font-size: .7rem; font-weight: 700; color: var(--c, #1b9bd8); padding: .15rem .3rem; overflow: hidden; user-select: none; touch-action: none; }
.box .lbl { pointer-events: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-shadow: 0 0 2px #fff; }
.box .del { position: absolute; top: 0; right: 0; width: 22px; height: 22px; border-radius: 0 4px 0 6px; background: var(--c, #1b9bd8); color: #fff; border: 0; font-size: .75rem; cursor: pointer; line-height: 22px; text-align: center; padding: 0; }
.box .rsz { position: absolute; right: -1px; bottom: -1px; width: 18px; height: 18px; background: var(--c, #1b9bd8); border-radius: 6px 0 4px 0; cursor: nwse-resize; }
.box.ro { cursor: default; }
.box.ro .del, .box.ro .rsz { display: none; }
.box.mine { animation: pulse 1.6s infinite; }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(27,155,216,.45); } 50% { box-shadow: 0 0 0 8px rgba(27,155,216,0); } }
.legend { display: flex; gap: .8rem; flex-wrap: wrap; font-size: .82rem; }
.legend span::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 3px; background: var(--c); margin-right: .35rem; vertical-align: -1px; }

/* ---------- página del firmante ---------- */
.sign-header { background: #fff; border-bottom: 1px solid var(--gris-claro); }
.sign-header .inner { max-width: 1180px; margin: 0 auto; padding: .7rem 1rem; display: flex; align-items: center; gap: .8rem; }
.sign-header .org-logo { height: 30px; max-width: 140px; object-fit: contain; }
.sign-header .who { margin-left: auto; font-size: .8rem; color: var(--gris); text-align: right; }
.sign-layout { max-width: 1180px; margin: 0 auto; padding: 1rem 1rem 6rem; display: grid; grid-template-columns: 1fr; gap: 1rem; align-items: start; }
@media (min-width: 1000px) { .sign-layout { grid-template-columns: minmax(0, 1fr) 380px; padding-bottom: 2rem; } .sign-panel { position: sticky; top: 72px; } }
.steps { counter-reset: s; list-style: none; padding: 0; margin: 0 0 1rem; display: flex; gap: .4rem; }
.steps li { flex: 1; display: flex; flex-direction: column; align-items: center; gap: .3rem; color: var(--gris); font-size: .72rem; font-weight: 600; text-align: center; }
.steps li::before { counter-increment: s; content: counter(s); width: 28px; height: 28px; border-radius: 50%; background: var(--gris-suave); display: grid; place-items: center; font-size: .8rem; font-weight: 800; }
.steps li.done { color: var(--tinta); }
.steps li.done::before { background: var(--verde); color: #fff; content: "✓"; }
.steps li.now { color: var(--tinta); }
.steps li.now::before { background: var(--acento); color: #fff; }
.pad-wrap { border: 2px dashed #c6ccd9; border-radius: var(--radio); background: #fff; position: relative; }
.pad-wrap canvas { display: block; width: 100%; height: 180px; border-radius: var(--radio); touch-action: none; cursor: crosshair; }
.pad-wrap .hint { position: absolute; inset: 0; display: grid; place-items: center; color: #b7bcc9; pointer-events: none; font-size: .9rem; }
.pad-wrap .line { position: absolute; left: 8%; right: 8%; bottom: 40px; border-top: 1px solid #e3e6ee; pointer-events: none; }
.otp-input { font-size: 1.7rem; letter-spacing: .4em; text-align: center; font-family: var(--mono); min-height: 56px; }
.sign-cta { position: fixed; left: 0; right: 0; bottom: 0; background: #fff; border-top: 1px solid var(--gris-claro); padding: .7rem 1rem calc(.7rem + env(safe-area-inset-bottom)); z-index: 20; display: flex; gap: .6rem; }
@media (min-width: 1000px) { .sign-cta { display: none; } }
.big-ok { text-align: center; padding: 1.4rem .6rem; }
.big-ok .icon { width: 72px; height: 72px; border-radius: 50%; background: var(--verde-claro); color: var(--verde); display: grid; place-items: center; margin: 0 auto 1rem; }
.big-ok .icon svg { width: 34px; height: 34px; stroke-width: 2.5; }

/* ---------- registro de eventos ---------- */
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { display: grid; grid-template-columns: 1fr; gap: .1rem; padding: .5rem 0; border-bottom: 1px solid var(--gris-suave); font-size: .84rem; }
.timeline li:last-child { border-bottom: 0; }
.timeline .when { color: var(--gris); font-variant-numeric: tabular-nums; font-size: .76rem; }
@media (min-width: 760px) { .timeline li { grid-template-columns: 150px 1fr; gap: .8rem; } .timeline .when { font-size: .84rem; } }
.sig-check { display: flex; gap: .6rem; align-items: center; padding: .5rem 0; border-bottom: 1px solid var(--gris-suave); font-size: .88rem; }
.sig-check:last-child { border-bottom: 0; }

/* ---------- landing ---------- */
.hero { background: var(--grad); color: #fff; border-radius: 22px; padding: 2.2rem 1.4rem; position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; width: 420px; height: 420px; border-radius: 50%; background: rgba(255,255,255,.08); right: -140px; top: -160px; }
.hero h1 { color: #fff; font-size: 2.1rem; font-weight: 900; letter-spacing: -.035em; margin-bottom: .6rem; }
.hero p.lead { font-size: 1.05rem; opacity: .94; max-width: 30rem; }
.hero .btn.white { background: #fff; color: var(--profundo); }
.hero .demo { margin-top: 1.6rem; background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.35); border-radius: 16px; padding: .9rem 1rem; backdrop-filter: blur(6px); max-width: 30rem; position: relative; }
.hero .demo .ok { display: inline-flex; gap: .3rem; align-items: center; background: #b8f5d2; color: #0f6b3d; padding: .3rem .8rem; border-radius: 999px; font-weight: 700; margin-top: .5rem; font-size: .85rem; }
@media (min-width: 760px) { .hero { padding: 3.4rem 3rem; } .hero h1 { font-size: 3.2rem; } }
.feature { background: #fff; border-radius: var(--radio); box-shadow: var(--sombra); padding: 1.2rem; }
.feature .ic { width: 40px; height: 40px; border-radius: 11px; background: var(--acento-suave); color: var(--acento-osc); display: grid; place-items: center; margin-bottom: .7rem; }
.feature .ic svg { width: 20px; height: 20px; }
.section { margin-top: 2.6rem; }
.section > h2 { font-size: 1.5rem; margin-bottom: .3rem; }
.section > p.lead { color: var(--gris); margin-bottom: 1.2rem; max-width: 40rem; }
.how { counter-reset: h; display: grid; gap: .8rem; }
@media (min-width: 760px) { .how { grid-template-columns: repeat(4, 1fr); } }
.how div { background: #fff; border-radius: var(--radio); box-shadow: var(--sombra); padding: 1rem; position: relative; padding-top: 2.6rem; }
.how div::before { counter-increment: h; content: counter(h); position: absolute; top: .9rem; left: 1rem; width: 28px; height: 28px; border-radius: 50%; background: var(--grad); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: .85rem; }
.faq details { background: #fff; border-radius: var(--radio-sm); box-shadow: var(--sombra); padding: .8rem 1rem; margin-bottom: .5rem; }
.faq summary { cursor: pointer; font-weight: 700; color: var(--tinta); }
.faq details p { margin: .6rem 0 0; color: var(--texto); font-size: .92rem; }

/* ---------- precios ---------- */
.toggle { display: inline-flex; background: #fff; border: 1px solid var(--gris-claro); border-radius: 999px; padding: .25rem; gap: .2rem; }
.toggle button { border: 0; background: none; padding: .45rem .9rem; border-radius: 999px; font: inherit; font-weight: 700; font-size: .88rem; color: var(--gris); cursor: pointer; }
.toggle button.active { background: var(--tinta); color: #fff; }
.toggle .save { color: var(--verde); font-size: .75rem; margin-left: .3rem; }
.plans { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 760px) { .plans { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1080px) { .plans { grid-template-columns: repeat(4, 1fr); } }
.plan { background: #fff; border-radius: 18px; box-shadow: var(--sombra); padding: 1.3rem; display: flex; flex-direction: column; position: relative; border: 2px solid transparent; }
.plan.featured { border-color: var(--acento); }
.plan .badge { position: absolute; top: -12px; left: 1.2rem; background: var(--grad); color: #fff; font-size: .72rem; font-weight: 800; padding: .25rem .7rem; border-radius: 999px; letter-spacing: .04em; }
.plan h3 { font-size: 1.1rem; }
.plan .tag { color: var(--gris); font-size: .85rem; margin-bottom: .8rem; }
.plan .price { font-size: 2.2rem; font-weight: 900; letter-spacing: -.04em; color: var(--tinta); line-height: 1; }
.plan .price small { font-size: .85rem; font-weight: 600; color: var(--gris); letter-spacing: 0; }
.plan .per { color: var(--gris); font-size: .8rem; min-height: 1.2rem; margin-bottom: 1rem; }
.plan ul { list-style: none; padding: 0; margin: 0 0 1.2rem; flex: 1; }
.plan li { display: flex; gap: .5rem; align-items: flex-start; font-size: .9rem; padding: .25rem 0; }
.plan li svg { color: var(--verde); margin-top: .2rem; }
.plan.current { border-color: var(--verde); }
.compare td, .compare th { font-size: .86rem; }

/* ---------- varios ---------- */
.kv { display: grid; grid-template-columns: 1fr; gap: .15rem .8rem; font-size: .9rem; }
.kv dt { color: var(--gris); font-size: .78rem; font-weight: 600; margin-top: .5rem; }
.kv dd { margin: 0; }
@media (min-width: 760px) { .kv { grid-template-columns: 160px 1fr; } .kv dt { margin-top: 0; } }
dialog { border: 0; border-radius: 16px; padding: 1.4rem; max-width: 460px; width: 92vw; box-shadow: var(--sombra-alta); }
dialog::backdrop { background: rgba(16,24,43,.45); }
pre.code { background: var(--marino); color: #e6ecf5; padding: 1rem; border-radius: var(--radio-sm); font-size: .78rem; overflow: auto; line-height: 1.5; }
code { font-family: var(--mono); font-size: .86em; background: var(--gris-suave); padding: .05rem .3rem; border-radius: 4px; }
pre.code code { background: none; padding: 0; }
.logo-preview { max-height: 60px; max-width: 220px; object-fit: contain; background: #fff; border: 1px solid var(--gris-claro); border-radius: 8px; padding: .4rem; }
.trial-banner { background: var(--azul-claro); color: var(--profundo); border-radius: var(--radio-sm); padding: .6rem .9rem; font-size: .86rem; font-weight: 600; display: flex; gap: .6rem; align-items: center; margin-bottom: 1rem; }
.trial-banner > span { flex: 1; min-width: 0; }
.trial-banner a { flex: none; }
