body{margin:0}
/* Tres estilos que escoge cada negocio (Libreta, Plastilina, Cristal), cada uno claro y oscuro.
   Los tokens de cada estilo se generan en temas.js sobre [data-estilo]; aquí solo se usan. */
:root {
  --bg: #f2efe8; --surface: #faf8f4; --surface-solid: #faf8f4; --surface-2: #ebe8e0; --ink: #0a0f1d; --muted: #485267; --line: #dcd8ce;
  --good: #1b7a45; --warn: #9a5c0e; --bad: #b4351f; --info: #2b56c9;
  --wa: #1d9a52; --ig: #b83574; --ms: #2c69e6; --web: #6a55c7;
  --shadow: 0 2px 4px rgb(10 15 29 / .08), 0 16px 34px rgb(10 15 29 / .16);
  --brand: #1e48c7; --brand-ink: #ffffff;
  --f-display: 'Manrope', ui-sans-serif, system-ui, sans-serif;
  --f-body: 'Manrope', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --f-mano: 'Manrope', ui-sans-serif, sans-serif;
  --peso-display: 800; --peso-body: 500;
  --r: 12px; --r-lg: 18px; --r-btn: 999px; --tap: 48px;
  --card-shadow: none; --card-border: var(--line); --card-blur: none; --btn-shadow: none;
  --rule: transparent; --margen: transparent; --marcador: rgb(30 72 199 / .14); --nota: #fff2a1; --nota-ink: #3a330d; --cinta: transparent;
  --deco1: transparent; --deco2: transparent; --deco3: transparent;
  --np-bg: #f4f4f6; --np-ink: #16181d; --np-muted: #5d6270; --np-line: rgb(0 0 0 / .08); --np-accion: #0b57d0;
  --nav-h: 0px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #05070c; --surface: #10141d; --surface-solid: #10141d; --surface-2: #1a1f2a; --ink: #ede9df; --muted: #9ca4b5; --line: #262c38;
    --good: #4cc283; --warn: #e2a54d; --bad: #f2806a; --info: #8aa9ff;
    --wa: #3cc57a; --ig: #ec6aa8; --ms: #6f9bff; --web: #a493ff;
    --shadow: 0 2px 4px rgb(0 0 0 / .4), 0 16px 34px rgb(0 0 0 / .45);
    --np-bg: #2b2d31; --np-ink: #f1f2f4; --np-muted: #b5b9c2; --np-line: rgb(255 255 255 / .08); --np-accion: #a8c7fa;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #05070c; --surface: #10141d; --surface-solid: #10141d; --surface-2: #1a1f2a; --ink: #ede9df; --muted: #9ca4b5; --line: #262c38;
  --good: #4cc283; --warn: #e2a54d; --bad: #f2806a; --info: #8aa9ff;
  --wa: #3cc57a; --ig: #ec6aa8; --ms: #6f9bff; --web: #a493ff;
  --shadow: 0 2px 4px rgb(0 0 0 / .4), 0 16px 34px rgb(0 0 0 / .45);
  --np-bg: #2b2d31; --np-ink: #f1f2f4; --np-muted: #b5b9c2; --np-line: rgb(255 255 255 / .08); --np-accion: #a8c7fa;
  color-scheme: dark;
}
/* Tonos derivados: se calculan donde vive el color del negocio y el estilo */
.scope, [data-estilo] {
  --brand-soft: color-mix(in srgb, var(--brand) 13%, var(--surface-solid));
  --brand-softer: color-mix(in srgb, var(--brand) 7%, var(--surface-solid));
  --brand-line: color-mix(in srgb, var(--brand) 40%, var(--line));
  --brand-text: color-mix(in srgb, var(--brand) 74%, var(--ink));
  --good-bg: color-mix(in srgb, var(--good) 14%, var(--surface-solid));
  --warn-bg: color-mix(in srgb, var(--warn) 15%, var(--surface-solid));
  --bad-bg: color-mix(in srgb, var(--bad) 13%, var(--surface-solid));
  --info-bg: color-mix(in srgb, var(--info) 13%, var(--surface-solid));
  font-family: var(--f-body); font-weight: var(--peso-body);
}
.scope { background: var(--bg); color: var(--ink); position: relative; isolation: isolate; }

html, body { height: 100%; }
body { background: var(--bg); color: var(--ink); font-family: var(--f-body); font-size: 15px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 60; background: var(--bg); }
#app { min-height: 100%; }
* { box-sizing: border-box; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { font-family: var(--f-display); line-height: 1.15; text-wrap: balance; margin: 0; letter-spacing: -.01em; }
h1 { font-size: clamp(1.7rem, 4.6vw, 2.6rem); font-weight: var(--peso-display); }
h2 { font-size: 1.36rem; font-weight: var(--peso-display); }
h3 { font-size: 1.06rem; font-weight: 700; }
p { margin: 0; }
.num, .tab-num { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.small { font-size: .86rem; }
.tiny { font-size: .76rem; }
.label { font-size: .74rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.gutter { padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.stack { display: flex; flex-direction: column; gap: 12px; }
.stack-lg { display: flex; flex-direction: column; gap: 20px; }
.row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.grow { flex: 1 1 auto; min-width: 0; }
.center { text-align: center; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--brand) 60%, transparent); outline-offset: 2px; border-radius: 6px; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }

/* ── Botones ── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: var(--r-btn); border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap; transition: background .15s, border-color .15s, transform .1s; }
.btn:hover { border-color: var(--brand-line); background: var(--brand-softer); }
.btn:active { transform: scale(.98); }
.btn[disabled] { opacity: .45; cursor: not-allowed; transform: none; }
.btn-primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); box-shadow: var(--btn-shadow); }
.btn-primary:hover { background: color-mix(in srgb, var(--brand) 88%, var(--ink)); border-color: transparent; }
.btn-soft { background: var(--brand-soft); border-color: transparent; color: var(--brand-text); }
.btn-ghost { background: transparent; border-color: transparent; }
.btn-danger { color: var(--bad); }
.btn-lg { min-height: 54px; padding: 0 24px; font-size: 1.04rem; }
.btn-sm { min-height: 36px; padding: 0 12px; font-size: .88rem; }
.btn-block { width: 100%; }
.icon-btn { width: 44px; height: 44px; border-radius: 999px; display: inline-grid; place-items: center; border: 0; background: transparent; cursor: pointer; color: inherit; position: relative; flex: none; }
.icon-btn:hover { background: var(--surface-2); }
.ico { width: 22px; height: 22px; flex: none; }
.ico-sm { width: 18px; height: 18px; }
.ico-lg { width: 28px; height: 28px; }

/* ── Formularios ── */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > span { font-weight: 600; font-size: .92rem; }
.field small { color: var(--muted); font-size: .8rem; }
.input, .select, .textarea { width: 100%; min-height: 48px; padding: 10px 14px; border-radius: var(--r); border: 1.5px solid var(--line); background: var(--surface-solid); font-size: 16px; transition: border-color .15s; }
.textarea { min-height: 96px; resize: vertical; line-height: 1.45; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 22%, transparent); }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 14px; }
.check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; }
.check input { width: 22px; height: 22px; accent-color: var(--brand); flex: none; margin-top: 1px; }

.switch { position: relative; display: inline-block; vertical-align: middle; width: 50px; height: 30px; flex: none; }
.switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; border-radius: 99px; background: var(--line); transition: background .15s; }
.switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: var(--surface); box-shadow: 0 1px 3px rgb(0 0 0 / .25); transition: transform .15s; }
.switch input:checked + span { background: var(--brand); }
.switch input:checked + span::after { transform: translateX(20px); }
.switch input:focus-visible + span { outline: 3px solid color-mix(in srgb, var(--brand) 60%, transparent); outline-offset: 2px; }

.seg { display: inline-flex; padding: 4px; gap: 4px; border-radius: 999px; background: var(--surface-2); max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.seg button { border: 0; background: transparent; min-height: 38px; padding: 0 14px; border-radius: 999px; font-weight: 600; cursor: pointer; white-space: nowrap; color: var(--muted); }
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: 0 0 0 1px var(--line), 0 1px 3px rgb(0 0 0 / .12); }

.stepper { display: inline-flex; align-items: center; border: 1.5px solid var(--line); border-radius: 999px; overflow: hidden; }
.stepper button { width: 44px; height: 44px; border: 0; background: var(--surface); font-size: 1.3rem; cursor: pointer; }
.stepper button:hover { background: var(--brand-softer); }
.stepper output { min-width: 44px; text-align: center; font-weight: 700; font-variant-numeric: tabular-nums; }

/* ── Piezas ── */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px; min-width: 0; }
.card-flat { background: var(--surface); border-radius: var(--r-lg); padding: 18px; min-width: 0; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: .78rem; font-weight: 600; background: var(--surface-2); color: var(--muted); white-space: nowrap; }
.pill.good { background: var(--good-bg); color: var(--good); }
.pill.warn { background: var(--warn-bg); color: var(--warn); }
.pill.bad { background: var(--bad-bg); color: var(--bad); }
.pill.info { background: var(--info-bg); color: var(--info); }
.pill.brand { background: var(--brand-soft); color: var(--brand-text); }
.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex: none; }
.canal { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 7px; color: #fff; font-size: .7rem; font-weight: 700; flex: none; }
.canal.whatsapp { background: var(--wa); } .canal.instagram { background: var(--ig); } .canal.messenger { background: var(--ms); } .canal.web { background: var(--web); } .canal.manual { background: var(--muted); }
.badge { position: absolute; top: 4px; right: 4px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; background: var(--bad); color: #fff; font-size: .68rem; font-weight: 700; display: grid; place-items: center; line-height: 1; border: 2px solid var(--surface); }
.list { display: flex; flex-direction: column; }
.list-row { display: flex; align-items: center; gap: 12px; padding: 12px 4px; border-bottom: 1px solid var(--line); min-width: 0; }
.list-row:last-child { border-bottom: 0; }
.list-row.click { cursor: pointer; border-radius: 10px; padding-inline: 10px; }
.list-row.click:hover { background: var(--surface-2); }
.avatar { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; flex: none; background: var(--brand-soft); color: var(--brand-text); font-size: .9rem; }
.empty { padding: 28px 16px; text-align: center; color: var(--muted); border: 1.5px dashed var(--line); border-radius: var(--r-lg); }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(168px, 100%), 1fr)); gap: 12px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 14px 16px; }
.kpi b { display: block; font-family: var(--f-display); font-weight: var(--peso-display); font-size: clamp(1.3rem, .9rem + 1.1vw, 1.9rem); line-height: 1.1; font-variant-numeric: tabular-nums; white-space: nowrap; }
.kpi span { color: var(--muted); font-size: .86rem; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); }
table.t { border-collapse: collapse; width: 100%; font-size: .9rem; }
.t th, .t td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.t th { font-size: .74rem; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); font-weight: 600; background: var(--surface-2); }
.t tr:last-child td { border-bottom: 0; }
.code { font-family: ui-monospace, 'SFMono-Regular', Menlo, monospace; font-size: .9em; background: var(--surface-2); padding: 2px 7px; border-radius: 6px; }

/* ── Plataforma (página pública) ── */
.landing { min-height: 100%; }
.land-top { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: color-mix(in srgb, var(--surface-solid) 82%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.land-top .inner { max-width: 1180px; margin: 0 auto; min-height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.wordmark { display: flex; align-items: center; gap: 10px; font-family: var(--f-display); font-weight: var(--peso-display); font-size: 1.12rem; }
.wordmark i { font-style: normal; font-family: var(--f-body); font-weight: 500; font-size: .72rem; color: var(--muted); display: block; line-height: 1; }
.mark { width: 34px; height: 34px; border-radius: 10px; background: var(--brand); color: var(--brand-ink); display: grid; place-items: center; flex: none; overflow: hidden; }
.mark img { width: 100%; height: 100%; object-fit: cover; }
.section { max-width: 1180px; margin: 0 auto; padding-block: 40px; }
.hero { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 40px; align-items: center; padding-block: 48px 32px; }
.hero h1 em { font-style: normal; color: var(--brand-text); }
.hero .lead { font-size: 1.12rem; color: var(--muted); max-width: 46ch; margin-top: 16px; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 26px; }
.hero-note { margin-top: 14px; font-size: .86rem; color: var(--muted); }
.hero-visual { position: relative; min-height: 360px; }
.hv-chat { position: absolute; right: 0; top: 0; width: min(330px, 92%); background: var(--surface); border: 1px solid var(--line); border-radius: 26px; padding: 14px; box-shadow: var(--shadow); }
.hv-agenda { position: absolute; left: 0; bottom: 0; width: min(300px, 80%); background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 14px; box-shadow: var(--shadow); }
.hv-slot { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-top: 1px dashed var(--line); font-size: .88rem; }
.hv-slot b { font-variant-numeric: tabular-nums; width: 46px; }
.hv-slot .who { flex: 1; min-width: 0; padding: 6px 10px; border-radius: 10px; background: var(--brand-soft); color: var(--brand-text); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hv-slot .who.new { outline: 2px solid var(--brand); animation: pulso 2.4s ease-in-out infinite; }
@keyframes pulso { 50% { outline-color: transparent; } }
.steps3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.step3 { padding: 20px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); }
.step3 .n { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; background: var(--brand-soft); color: var(--brand-text); margin-bottom: 12px; font-variant-numeric: tabular-nums; }
.precios { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; max-width: 760px; }
.precios-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: none; align-items: start; }
.precio.elegido { border-color: var(--brand); }
@media (max-width: 900px) { .precios-3 { grid-template-columns: minmax(0, 1fr); } }
.precio { padding: 24px; border-radius: var(--r-lg); background: var(--surface); border: 1.5px solid var(--line); display: flex; flex-direction: column; gap: 10px; }
.precio.dest { border-color: var(--brand); box-shadow: 0 0 0 4px var(--brand-softer); }
.precio .monto { font-family: var(--f-display); font-size: 2.4rem; font-weight: var(--peso-display); line-height: 1; font-variant-numeric: tabular-nums; }
.precio ul { margin: 6px 0 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 6px; }
.precio li { display: flex; gap: 8px; align-items: flex-start; font-size: .92rem; }
.precio li svg { color: var(--good); margin-top: 2px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--surface); font-weight: 600; cursor: pointer; }
.chip:hover { border-color: var(--brand-line); }
.chip.on { border-color: var(--brand); background: var(--brand-soft); color: var(--brand-text); }
.foot { border-top: 1px solid var(--line); }
.foot .inner { max-width: 1180px; margin: 0 auto; padding-block: 24px 40px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; color: var(--muted); font-size: .88rem; }

/* ── Registro ── */
.wizard { width: 100%; max-width: 720px; margin: 0 auto; padding-block: 20px 120px; }
.progress { height: 6px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.progress i { display: block; height: 100%; background: var(--brand); border-radius: 99px; transition: width .3s; }
.rubros { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(150px, 100%), 1fr)); gap: 10px; }
.rubro { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; padding: 16px; min-height: 112px; border-radius: var(--r-lg); border: 1.5px solid var(--line); background: var(--surface); cursor: pointer; text-align: left; font-weight: 600; position: relative; }
.rubro:hover { border-color: var(--brand-line); }
.rubro.on { border-color: var(--brand); background: var(--brand-soft); }
.rubro .ri { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-2); color: var(--brand-text); }
.rubro.on .ri { background: var(--surface); }
.rubro .tag { font-size: .7rem; font-weight: 600; color: var(--good); }
.wiz-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: var(--surface-solid); border-top: 1px solid var(--line); padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px)); padding-top: 12px; }
.wiz-bar .inner { max-width: 720px; margin: 0 auto; display: flex; gap: 10px; justify-content: space-between; }
.suc-card { border: 1.5px solid var(--line); border-radius: var(--r-lg); padding: 16px; background: var(--surface); display: flex; flex-direction: column; gap: 14px; }
.srv-row { display: grid; grid-template-columns: auto minmax(0, 1fr) 110px 120px; gap: 10px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); }
.srv-row:last-child { border-bottom: 0; }
.exito { text-align: center; max-width: 520px; margin: 0 auto; padding-block: 48px 40px; display: flex; flex-direction: column; gap: 16px; align-items: center; }
.ticket { border: 2px dashed var(--brand-line); border-radius: var(--r-lg); padding: 18px 24px; background: var(--brand-softer); }
.ticket b { font-family: ui-monospace, 'SFMono-Regular', Menlo, monospace; font-size: 2rem; letter-spacing: .04em; color: var(--brand-text); display: block; }

/* ── Panel del negocio ── */
.app { min-height: 100%; display: flex; flex-direction: column; }
.topbar { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 25; background: var(--surface-solid); border-bottom: 1px solid var(--line); }
.topbar .inner { min-height: 60px; display: flex; align-items: center; gap: 8px; }
.biz { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1 1 auto; }
.biz .mark { width: 38px; height: 38px; border-radius: 11px; }
.biz-name { font-family: var(--f-display); font-weight: var(--peso-display); font-size: 1.04rem; line-height: 1.15; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.biz-sub { display: flex; gap: 6px; align-items: center; font-size: .74rem; color: var(--muted); white-space: nowrap; overflow: hidden; }
.ver { font-size: .68rem; font-weight: 700; padding: 1px 6px; border-radius: 6px; background: var(--surface-2); color: var(--muted); }
.main { flex: 1 1 auto; min-width: 0; }
.page { width: 100%; max-width: 1240px; margin: 0 auto; padding-block: 20px 40px; display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.page-head p { color: var(--muted); margin-top: 4px; }

/* Menú lateral */
.shell { display: flex; flex: 1 1 auto; min-height: 0; }
.side { width: 252px; flex: none; border-right: 1px solid var(--line); background: var(--surface); padding: 14px 12px; display: flex; flex-direction: column; gap: 2px; position: sticky; top: calc(60px + env(safe-area-inset-top, 0px)); height: calc(100vh - 60px - env(safe-area-inset-top, 0px)); overflow-y: auto; }
.nav-item { display: flex; align-items: center; gap: 12px; min-height: 46px; padding: 0 12px; border-radius: 12px; border: 0; background: transparent; cursor: pointer; font-weight: 600; color: var(--muted); text-align: left; width: 100%; position: relative; }
.nav-item:hover { background: var(--surface-2); color: var(--ink); }
.nav-item.on { background: var(--brand-soft); color: var(--brand-text); }
.nav-item .badge { position: static; margin-left: auto; border: 0; }
.side-foot { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 2px; }
.drawer-back { position: fixed; inset: 0; background: rgb(0 0 0 / .4); z-index: 40; }
.drawer { position: fixed; z-index: 41; top: 0; bottom: 0; left: 0; width: min(300px, 86vw); background: var(--surface-solid); padding: calc(14px + env(safe-area-inset-top, 0px)) 12px calc(14px + env(safe-area-inset-bottom, 0px)) max(12px, env(safe-area-inset-left, 0px)); display: flex; flex-direction: column; gap: 2px; overflow-y: auto; box-shadow: var(--shadow); animation: entra-izq .2s ease-out; }
@keyframes entra-izq { from { transform: translateX(-100%); } }
/* Menú superior */
.tabsbar { position: sticky; top: calc(60px + env(safe-area-inset-top, 0px)); z-index: 24; background: var(--surface-solid); border-bottom: 1px solid var(--line); }
.tabsbar .inner { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; padding-block: 8px; max-width: 1240px; margin: 0 auto; }
.tabsbar .nav-item { width: auto; flex: none; min-height: 40px; padding: 0 14px; border-radius: 999px; }
.tabsbar .nav-item .badge { margin-left: 4px; }
/* Menú inferior */
.bottomnav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 26; background: var(--surface-solid); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom, 0px); }
.bottomnav .inner { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); max-width: 640px; margin: 0 auto; }
.bn { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 62px; border: 0; background: transparent; font-size: .72rem; font-weight: 600; color: var(--muted); cursor: pointer; position: relative; }
.bn.on { color: var(--brand-text); }
.bn.on .ico { background: var(--brand-soft); border-radius: 99px; width: 52px; padding: 3px 0; height: 28px; }
.bn .badge { top: 4px; right: calc(50% - 26px); }
.app.con-inferior .main { padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
.sheet-back { position: fixed; inset: 0; z-index: 50; background: rgb(8 14 11 / .45); display: flex; align-items: flex-end; justify-content: center; animation: aparece .15s ease-out; }
@keyframes aparece { from { opacity: 0; } }
.sheet { width: 100%; max-width: 640px; max-height: calc(100% - 24px - env(safe-area-inset-top, 0px)); overflow-y: auto; background: var(--surface-solid); border-radius: 22px 22px 0 0; padding: 8px max(18px, env(safe-area-inset-right, 0px)) calc(20px + env(safe-area-inset-bottom, 0px)) max(18px, env(safe-area-inset-left, 0px)); animation: sube .22s ease-out; box-shadow: var(--shadow); }
@keyframes sube { from { transform: translateY(40px); opacity: .6; } }
.sheet .grab { width: 44px; height: 5px; border-radius: 99px; background: var(--line); margin: 4px auto 12px; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 14px; }
@media (min-width: 760px) {
  .sheet-back { align-items: center; padding: 24px; }
  .sheet { border-radius: 22px; max-height: calc(100% - 48px); padding: 8px 24px 24px; }
  .sheet .grab { display: none; }
  .sheet-head { margin-top: 12px; }
}
.mas-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.mas-grid button { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 16px 6px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); font-weight: 600; font-size: .84rem; cursor: pointer; text-align: center; }
.mas-grid button:hover { background: var(--brand-softer); }

/* Aviso tipo WhatsApp (baja desde arriba) */
.toast { position: fixed; z-index: 70; top: calc(10px + env(safe-area-inset-top, 0px)); left: 50%; width: min(420px, calc(100% - 24px)); transform: translateX(-50%); background: color-mix(in srgb, var(--surface) 94%, transparent); backdrop-filter: blur(14px); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); padding: 12px 14px; display: flex; gap: 12px; cursor: pointer; animation: baja .35s cubic-bezier(.2, .9, .3, 1.2); }
@keyframes baja { from { transform: translate(-50%, -140%); } }
.toast .mark { width: 40px; height: 40px; border-radius: 11px; }
.toast-app { display: flex; justify-content: space-between; gap: 8px; font-size: .74rem; color: var(--muted); }
.toast b { display: block; font-size: .95rem; line-height: 1.25; }
.toast p { font-size: .88rem; color: var(--muted); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.pop { position: absolute; right: 8px; top: calc(100% + 6px); width: min(380px, calc(100vw - 24px)); background: var(--surface-solid); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); padding: 10px; z-index: 45; max-height: 70vh; overflow-y: auto; }

/* Inicio */
.demo-banner { display: flex; gap: 14px; align-items: center; justify-content: space-between; flex-wrap: wrap; padding: 14px 18px; border-radius: var(--r-lg); background: var(--brand-soft); color: var(--brand-text); }
.demo-banner b { font-variant-numeric: tabular-nums; }
.two-col { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.quick { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(160px, 100%), 1fr)); gap: 10px; }
.quick button { display: flex; align-items: center; gap: 12px; padding: 14px; min-height: 64px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); font-weight: 600; cursor: pointer; text-align: left; }
.quick button:hover { border-color: var(--brand-line); background: var(--brand-softer); }
.quick .qi { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-text); flex: none; }
.checklist { display: flex; flex-direction: column; gap: 4px; }
.checklist button { display: flex; align-items: center; gap: 12px; min-height: 48px; border: 0; background: transparent; border-radius: 12px; padding: 0 8px; cursor: pointer; text-align: left; font-weight: 500; }
.checklist button:hover { background: var(--surface-2); }
.checklist .ck { width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--line); display: grid; place-items: center; flex: none; }
.checklist .ck.ok { background: var(--good); border-color: var(--good); color: #fff; }
.checklist .ok-text { color: var(--muted); text-decoration: line-through; }
.cita-line { display: flex; gap: 12px; align-items: center; padding: 10px; border-radius: 14px; cursor: pointer; min-width: 0; }
.cita-line:hover { background: var(--surface-2); }
.cita-line .hora { font-weight: 700; font-variant-numeric: tabular-nums; width: 52px; flex: none; }
.cita-line .barra { width: 4px; align-self: stretch; border-radius: 4px; flex: none; }
.tour { border: 1.5px solid var(--brand-line); background: var(--surface); }
.tour ol { margin: 8px 0 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }

/* Agenda */
.ag-tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.datenav { display: inline-flex; align-items: center; gap: 4px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.datenav .dl { min-width: 150px; text-align: center; font-weight: 700; padding: 0 6px; }
.grid-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); }
.ag-grid { display: grid; position: relative; min-width: 100%; }
.ag-head { position: sticky; top: 0; z-index: 2; background: var(--surface-2); border-bottom: 1px solid var(--line); padding: 10px; font-weight: 700; font-size: .9rem; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ag-hours { border-right: 1px solid var(--line); }
.ag-hour { height: 52px; font-size: .74rem; color: var(--muted); padding: 2px 8px; text-align: right; font-variant-numeric: tabular-nums; border-bottom: 1px dashed var(--line); }
.ag-col { position: relative; border-right: 1px solid var(--line); }
.ag-col:last-child { border-right: 0; }
.ag-cell { height: 52px; border-bottom: 1px dashed var(--line); cursor: pointer; }
.ag-cell:nth-child(2n) { border-bottom-style: solid; }
.ag-cell:hover { background: var(--brand-softer); }
.ag-cita { position: absolute; left: 4px; right: 4px; border-radius: 10px; padding: 5px 8px; font-size: .78rem; line-height: 1.25; overflow: hidden; cursor: pointer; border-left: 4px solid; background: var(--surface-2); z-index: 1; }
.ag-cita b { display: block; font-size: .82rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ag-cita span { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--muted); }
.ag-cita.cancelada { opacity: .5; text-decoration: line-through; }
.ag-now { position: absolute; left: 0; right: 0; height: 2px; background: var(--bad); z-index: 3; pointer-events: none; }
.ag-list { display: flex; flex-direction: column; gap: 6px; }
.ag-slot { display: flex; gap: 12px; align-items: stretch; min-height: 48px; }
.ag-slot .h { width: 50px; flex: none; font-weight: 700; font-variant-numeric: tabular-nums; padding-top: 12px; font-size: .9rem; }
.ag-slot .cont { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.ag-free { min-height: 44px; border: 1.5px dashed var(--line); border-radius: 12px; display: flex; align-items: center; padding: 0 14px; color: var(--muted); font-size: .88rem; cursor: pointer; background: transparent; text-align: left; }
.ag-free:hover { border-color: var(--brand-line); color: var(--brand-text); }
.ag-card { border-radius: 14px; padding: 10px 12px; border-left: 5px solid; background: var(--surface); border-top: 1px solid var(--line); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); cursor: pointer; min-width: 0; }
.ag-card b { display: block; }
.slots { display: flex; flex-wrap: wrap; gap: 8px; }
.slot { min-height: 44px; min-width: 76px; padding: 0 12px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--surface); font-weight: 700; font-variant-numeric: tabular-nums; cursor: pointer; }
.slot:hover { border-color: var(--brand-line); }
.slot.on { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.estado-btns { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(140px, 100%), 1fr)); gap: 8px; }

/* Mensajes y bot */
.inbox { display: grid; grid-template-columns: 340px minmax(0, 1fr); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; background: var(--surface); height: min(720px, calc(100vh - 210px)); min-height: 520px; }
.inbox-list { border-right: 1px solid var(--line); overflow-y: auto; display: flex; flex-direction: column; }
.conv { display: flex; gap: 12px; padding: 12px 14px; border: 0; border-bottom: 1px solid var(--line); background: transparent; text-align: left; cursor: pointer; align-items: center; width: 100%; min-width: 0; }
.conv:hover { background: var(--surface-2); }
.conv.on { background: var(--brand-softer); }
.conv .who { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.conv .last { font-size: .84rem; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.conv .av-wrap { position: relative; flex: none; }
.conv .av-wrap .canal { position: absolute; right: -4px; bottom: -4px; width: 18px; height: 18px; border-radius: 6px; font-size: .6rem; border: 2px solid var(--surface); }
.unread { min-width: 20px; height: 20px; border-radius: 99px; background: var(--brand); color: var(--brand-ink); font-size: .72rem; font-weight: 700; display: grid; place-items: center; padding: 0 6px; }
.chat { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.chat-head, .composer, .persona-banner { flex: none; }
.chat-sub { display: flex; align-items: center; gap: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.avatar-foto { object-fit: cover; background: var(--surface-2); }
.chat-nombre { display: flex; align-items: center; gap: 4px; min-width: 0; }
.chat-nombre > span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.verificada { flex: none; display: inline-grid; place-items: center; width: 15px; height: 15px; margin-left: 4px; border-radius: 50%; background: #1d9bf0; color: #fff; font-size: .62rem; font-weight: 800; line-height: 1; vertical-align: 1px; }
.chat-datos { display: block; font-size: .8rem; color: var(--muted); line-height: 1.4; margin-top: 2px; overflow-wrap: anywhere; }
.chat-datos .canal { width: 18px; height: 18px; border-radius: 6px; font-size: .6rem; vertical-align: -4px; margin-right: 5px; }
.chat-head .txt-corto { display: none; }
@media (max-width: 599px) { .chat-head .txt-largo { display: none; } .chat-head .txt-corto { display: inline; } .chat-head { align-items: flex-start; } .chat-head > .pill, .chat-head > .icon-btn { margin-top: 4px; } }
.chat-datos a { color: var(--brand-text); font-weight: 600; text-decoration: none; }
.chat-datos a:hover { text-decoration: underline; }
.chat-head { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--line); min-height: 60px; }
.chat-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 8px; background: color-mix(in srgb, var(--brand) 4%, var(--bg)); }
.msg { max-width: min(78%, 440px); padding: 8px 12px 6px; border-radius: 16px; font-size: .94rem; line-height: 1.4; white-space: pre-wrap; overflow-wrap: anywhere; box-shadow: 0 1px 1px rgb(0 0 0 / .05); }
.msg time { display: block; text-align: right; font-size: .68rem; color: var(--muted); margin-top: 2px; }
.msg.cliente { align-self: flex-start; background: var(--surface); border-bottom-left-radius: 4px; }
.msg.bot, .msg.persona { align-self: flex-end; background: color-mix(in srgb, var(--brand) 16%, var(--surface)); border-bottom-right-radius: 4px; }
.msg .quien { font-size: .7rem; font-weight: 700; color: var(--brand-text); margin-bottom: 2px; display: flex; gap: 4px; align-items: center; }
.msg.sistema { align-self: center; background: var(--surface-2); color: var(--muted); font-size: .8rem; border-radius: 10px; text-align: center; box-shadow: none; max-width: 90%; }
.msg .tabla { margin-top: 6px; display: flex; flex-direction: column; gap: 4px; }
.msg .tabla div { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; border-top: 1px dashed color-mix(in srgb, var(--ink) 15%, transparent); font-size: .88rem; }
.msg .tabla div span:last-child { font-weight: 600; white-space: nowrap; font-variant-numeric: tabular-nums; }
.wa-btns { align-self: flex-end; display: flex; flex-direction: column; gap: 4px; width: min(78%, 440px); }
.wa-btns button { min-height: 42px; border-radius: 12px; border: 0; background: var(--surface); color: var(--info); font-weight: 600; cursor: pointer; box-shadow: 0 1px 1px rgb(0 0 0 / .06); }
.wa-btns button:hover:not([disabled]) { background: var(--info-bg); }
.wa-btns button[disabled] { color: var(--muted); cursor: default; }
.typing { align-self: flex-end; background: color-mix(in srgb, var(--brand) 16%, var(--surface)); padding: 10px 14px; border-radius: 16px; display: flex; gap: 4px; }
.typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); animation: tecla 1s infinite; }
.typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }
@keyframes tecla { 50% { transform: translateY(-4px); opacity: .5; } }
.composer { border-top: 1px solid var(--line); padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; background: var(--surface); }
.composer form { display: flex; gap: 8px; }
.composer .input { border-radius: 999px; }
.persona-banner { display: flex; gap: 10px; align-items: center; justify-content: space-between; flex-wrap: wrap; padding: 8px 14px; background: var(--warn-bg); color: var(--warn); font-size: .86rem; font-weight: 600; }
.sugs { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.sugs button { flex: none; min-height: 34px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: .84rem; cursor: pointer; }
.sugs button:hover { border-color: var(--brand-line); }
.modo-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.opt-card { display: flex; flex-direction: column; gap: 6px; padding: 16px; border-radius: var(--r-lg); border: 1.5px solid var(--line); background: var(--surface); cursor: pointer; text-align: left; }
.opt-card:hover { border-color: var(--brand-line); }
.opt-card.on { border-color: var(--brand); background: var(--brand-softer); box-shadow: 0 0 0 3px var(--brand-soft); }
.opt-card b { font-size: 1rem; color: var(--ink); }
.opt-card span { font-size: .86rem; color: var(--muted); }
.canales { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.canal-card { display: flex; flex-direction: column; gap: 10px; padding: 16px; border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--surface); }
.canal-card .canal { width: 36px; height: 36px; border-radius: 11px; font-size: .9rem; }
.cat-tabs { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.cat-tabs button { flex: none; min-height: 40px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-weight: 600; font-size: .88rem; cursor: pointer; display: flex; gap: 6px; align-items: center; }
.cat-tabs button.on { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.cat-tabs button i { font-style: normal; font-size: .74rem; opacity: .7; font-variant-numeric: tabular-nums; }
.resp { display: flex; gap: 12px; align-items: flex-start; padding: 14px 4px; border-bottom: 1px solid var(--line); }
.resp:last-child { border-bottom: 0; }
.resp .q { font-weight: 600; }
.resp .a { color: var(--muted); font-size: .9rem; margin-top: 2px; overflow-wrap: anywhere; }
.resp.off .q, .resp.off .a { opacity: .5; }
.vars { display: flex; flex-wrap: wrap; gap: 6px; }
.vars button { min-height: 32px; padding: 0 10px; border-radius: 8px; border: 1px dashed var(--brand-line); background: var(--brand-softer); color: var(--brand-text); font-size: .8rem; font-weight: 600; cursor: pointer; font-family: ui-monospace, 'SFMono-Regular', Menlo, monospace; }
.meta-sim { border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px; display: flex; flex-direction: column; gap: 14px; background: var(--surface-2); }
.meta-step { display: flex; gap: 12px; align-items: flex-start; }
.meta-step .n { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); border: 1.5px solid var(--line); font-weight: 700; font-size: .85rem; flex: none; }
.meta-step.ok .n { background: var(--good); color: #fff; border-color: var(--good); }

/* Apariencia */
.menu-opts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.mini { height: 92px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg); position: relative; overflow: hidden; }
.mini i { position: absolute; background: var(--brand); opacity: .85; border-radius: 3px; }
.mini u { position: absolute; background: var(--line); border-radius: 3px; text-decoration: none; }
.colores { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.color { width: 46px; height: 46px; border-radius: 50%; border: 3px solid var(--surface); box-shadow: 0 0 0 1.5px var(--line); cursor: pointer; }
.color.on { box-shadow: 0 0 0 3px var(--ink); }
.color-input { width: 46px; height: 46px; padding: 0; border: 0; border-radius: 50%; overflow: hidden; cursor: pointer; background: none; -webkit-appearance: none; appearance: none; box-shadow: 0 0 0 1.5px var(--line); }
.color-input::-webkit-color-swatch-wrapper { padding: 0; }
.color-input::-webkit-color-swatch { border: 0; border-radius: 50%; }
.color-input::-moz-color-swatch { border: 0; border-radius: 50%; }
.logo-drop { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.logo-big { width: 84px; height: 84px; border-radius: 22px; background: var(--brand); color: var(--brand-ink); display: grid; place-items: center; overflow: hidden; font-family: var(--f-display); font-size: 2rem; font-weight: 700; flex: none; }
.logo-big img { width: 100%; height: 100%; object-fit: cover; }

/* Plan */
.planes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }

/* Página de reservas */
.reserva { width: 100%; max-width: 560px; margin: 0 auto; padding-block: 0 48px; display: flex; flex-direction: column; gap: 18px; }
.reserva-head { background: var(--brand); color: var(--brand-ink); border-radius: 0 0 26px 26px; padding: 22px 20px 26px; display: flex; gap: 14px; align-items: center; }
.reserva-head .mark { width: 54px; height: 54px; border-radius: 16px; background: color-mix(in srgb, var(--brand-ink) 18%, transparent); color: var(--brand-ink); }
.res-srv { display: flex; justify-content: space-between; gap: 12px; align-items: center; width: 100%; padding: 14px 16px; border-radius: 16px; border: 1.5px solid var(--line); background: var(--surface); cursor: pointer; text-align: left; }
.res-srv:hover { border-color: var(--brand-line); }
.res-srv.on { border-color: var(--brand); background: var(--brand-softer); }
.days { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; }
.day { flex: none; width: 70px; min-height: 76px; border-radius: 16px; border: 1.5px solid var(--line); background: var(--surface); cursor: pointer; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
.day b { font-size: 1.3rem; font-variant-numeric: tabular-nums; font-family: var(--f-display); }
.day span { font-size: .74rem; color: var(--muted); text-transform: capitalize; }
.day.on { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.day.on span { color: var(--brand-ink); opacity: .85; }
.day[disabled] { opacity: .4; cursor: not-allowed; }

@media (max-width: 1000px) {
  .two-col { grid-template-columns: minmax(0, 1fr); }
  .canales, .modo-cards { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 899px) {
  .side.desk { display: none; }
  .hero { grid-template-columns: minmax(0, 1fr); padding-block: 28px 8px; gap: 24px; }
  .hero-visual { min-height: 0; display: flex; flex-direction: column; gap: 12px; }
  .hv-chat, .hv-agenda { position: static; width: 100%; }
  .hv-agenda { width: min(320px, 92%); margin: -28px 0 0 auto; }
  .steps3 { grid-template-columns: minmax(0, 1fr); }
  .inbox { grid-template-columns: minmax(0, 1fr); height: auto; min-height: 0; border-radius: var(--r-lg); }
  .inbox.en-chat .inbox-list { display: none; }
  .inbox:not(.en-chat) .chat { display: none; }
  .inbox-list { border-right: 0; }
  .chat { height: calc(100vh - 92px - var(--nav-h) - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px)); height: calc(100dvh - 92px - var(--nav-h) - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px)); min-height: 380px; }
  .app.con-inferior { --nav-h: 66px; }
  .app.menu-superior { --nav-h: 58px; }
}
@media (min-width: 900px) { .solo-movil { display: none !important; } }
@media (max-width: 640px) {
  body { font-size: 15px; }
  .page { padding-block: 14px 32px; gap: 16px; }
  .precios, .planes { grid-template-columns: minmax(0, 1fr); }
  .menu-opts { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .mini { height: 74px; }
  .srv-row { grid-template-columns: auto minmax(0, 1fr); }
  .srv-row .srv-dur, .srv-row .srv-precio { grid-column: 2; }
  .card, .card-flat { padding: 14px; }
  .biz-sub .solo-desk { display: none; }
  .kpi b { font-size: 1.6rem; }
  .hide-sm { display: none !important; }
  .seg { display: flex; width: 100%; }
  .seg button { flex: 1 1 auto; white-space: normal; line-height: 1.2; padding: 6px 10px; }
  .wrap-sm { flex-wrap: wrap; }
  .wrap-sm > .grow { flex-basis: 100%; order: -1; }
}

/* ═══════════════ SUPERFICIES: cada estilo las pinta con sus tokens ═══════════════ */
.card, .kpi, .precio, .step3, .opt-card, .canal-card, .table-wrap, .grid-wrap, .inbox, .quick button, .suc-card, .rubro, .res-srv,
.hv-chat, .hv-agenda, .mas-grid button, .k-col, .funcion, .estilo-card, .day, .slot, .chip, .embudo-mini button, .area {
  border-color: var(--card-border); box-shadow: var(--card-shadow); backdrop-filter: var(--card-blur); -webkit-backdrop-filter: var(--card-blur);
}
.slot, .chip, .day { box-shadow: none; }
.card, .kpi, .precio, .k-col, .area { border-radius: var(--r-lg); }
.nowrap { white-space: nowrap; }
tr.click { cursor: pointer; }
tr.click:hover td { background: var(--brand-softer); }
.label { font-weight: 700; }

/* ── Vista previa de estilos ── */
.estilos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.estilo-card { display: flex; flex-direction: column; gap: 12px; padding: 12px; border-radius: var(--r-lg); border: 1.5px solid var(--card-border); background: var(--surface); cursor: pointer; text-align: left; color: var(--ink); transition: transform .15s; }
.estilo-card:hover { transform: translateY(-2px); }
.estilo-card.on { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft), var(--card-shadow); }
.estilo-txt { display: flex; flex-direction: column; gap: 2px; padding: 0 4px 4px; }
.estilo-txt b { font-family: var(--f-display); font-size: 1.08rem; }
.estilo-txt span { font-size: .86rem; color: var(--muted); }
.estilos.compacto { gap: 10px; }
.estilos.compacto .emini { min-height: 150px; }
.emini { position: relative; isolation: isolate; min-height: 196px; border-radius: calc(var(--r-lg) - 4px); overflow: hidden; background: var(--bg); color: var(--ink); font-family: var(--f-body); font-weight: var(--peso-body); font-size: 11px; line-height: 1.3; border: 1px solid var(--line); pointer-events: none; }
.emini-top { display: flex; align-items: center; gap: 6px; padding: 8px 10px; background: var(--surface-solid); border-bottom: 1px solid var(--line); position: relative; }
.emini-top b { font-family: var(--f-display); font-weight: var(--peso-display); font-size: 12px; }
.emini-logo { width: 18px; height: 18px; border-radius: 6px; background: var(--brand); flex: none; }
.emini-dot { margin-left: auto; width: 8px; height: 8px; border-radius: 50%; background: var(--bad); }
.emini-body { padding: 9px 10px; display: flex; flex-direction: column; gap: 6px; position: relative; }
.emini-h { font-family: var(--f-display); font-weight: var(--peso-display); font-size: 15px; }
.emini-kpis { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.emini-kpi { background: var(--surface); border: 1px solid var(--card-border); box-shadow: var(--card-shadow); border-radius: calc(var(--r) - 2px); padding: 5px 7px; backdrop-filter: var(--card-blur); -webkit-backdrop-filter: var(--card-blur); }
.emini-kpi b { display: block; font-family: var(--f-display); font-weight: var(--peso-display); font-size: 15px; }
.emini-kpi span { color: var(--muted); font-size: 10px; }
.emini-row { display: flex; gap: 6px; align-items: center; padding: 4px 7px; border-radius: 7px; background: var(--surface); border: 1px solid var(--card-border); }
.emini-row i { font-style: normal; font-weight: 800; width: 32px; }
.emini-row span { flex: 1; }
.emini-row u { text-decoration: none; font-size: 9px; font-weight: 800; padding: 1px 6px; border-radius: 99px; background: var(--brand-soft); color: var(--brand-text); }
.emini-btn { align-self: flex-start; padding: 4px 10px; border-radius: var(--r-btn); background: var(--brand); color: var(--brand-ink); font-weight: 800; box-shadow: var(--btn-shadow); }
@media (max-width: 760px) {
  .estilos { grid-template-columns: minmax(0, 1fr); }
  .estilos.compacto { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .estilos.compacto .emini { min-height: 0; height: 128px; font-size: 9px; }
  .estilos.compacto .emini-kpis, .estilos.compacto .emini-row + .emini-row { display: none; }
  .estilos.compacto .estilo-card { padding: 8px; }
}

/* ── Portada ── */
.funciones { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
@media (max-width: 960px) { .funciones { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .funciones { grid-template-columns: minmax(0, 1fr); } }
.funcion { display: flex; gap: 14px; align-items: flex-start; padding: 18px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--card-border); }
.funcion .qi { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-text); flex: none; }
.hv-push { position: absolute; right: 0; bottom: 0; width: min(340px, 72%); z-index: 2; transform: rotate(1.2deg); }
.hero-visual { min-height: 500px; }
.hero-visual .hv-agenda { bottom: 44px; }
@media (max-width: 899px) { .hv-push { position: static; width: 100%; transform: none; } .hero-visual { min-height: 0; } }

/* ═══════════════ NOTIFICACIONES COMO EN CADA APARATO ═══════════════ */
.np { font-family: Roboto, 'Segoe UI', system-ui, -apple-system, sans-serif; font-weight: 400; color: var(--np-ink); background: var(--np-bg); text-align: left; cursor: pointer; line-height: 1.3; }
.np b { font-weight: 600; }
.np p { margin: 1px 0 0; font-size: .88rem; color: var(--np-muted); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.np-av { position: relative; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 700; font-size: .88rem; flex: none; }
.np-av .canal { position: absolute; right: -3px; bottom: -3px; width: 18px; height: 18px; border-radius: 50%; font-size: .58rem; border: 2px solid var(--np-bg); font-style: normal; }
.np-badge { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; background: var(--brand); color: var(--brand-ink); flex: none; }
.np-badge .ico { width: 11px; height: 11px; }
/* Android (Material) */
.np-android { border-radius: 24px; padding: 12px 14px 6px; box-shadow: 0 2px 6px rgb(0 0 0 / .18), 0 10px 30px rgb(0 0 0 / .14); }
.np-head { display: flex; align-items: center; gap: 6px; font-size: .74rem; color: var(--np-muted); }
.np-head .np-app { font-weight: 500; color: var(--np-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 60%; }
.np-head .ico { margin-left: auto; width: 16px; height: 16px; }
.np-main { display: flex; gap: 12px; align-items: center; margin-top: 6px; }
.np-main b { display: block; font-size: .95rem; }
.np-acciones { display: flex; gap: 4px; margin: 4px -6px 0; }
.np-acciones button { border: 0; background: transparent; color: var(--np-accion); font: 600 .84rem Roboto, 'Segoe UI', system-ui, sans-serif; padding: 8px 10px; min-height: 36px; border-radius: 99px; cursor: pointer; }
.np-acciones button:hover { background: var(--np-line); }
/* iPhone */
.np-iphone { display: flex; gap: 10px; align-items: flex-start; padding: 11px 13px; border-radius: 22px; font-family: -apple-system, 'SF Pro Text', system-ui, sans-serif; background: color-mix(in srgb, var(--np-bg) 82%, transparent); backdrop-filter: blur(20px) saturate(180%); -webkit-backdrop-filter: blur(20px) saturate(180%); box-shadow: 0 8px 28px rgb(0 0 0 / .18); }
.np-appicon { border-radius: 9px; display: grid; place-items: center; overflow: hidden; flex: none; font-size: .78rem; }
.np-appicon img { width: 100%; height: 100%; object-fit: cover; }
.np-ihead { display: flex; justify-content: space-between; gap: 8px; font-size: .78rem; color: var(--np-muted); }
.np-ihead b { color: var(--np-ink); text-transform: uppercase; letter-spacing: .02em; font-size: .72rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.np-it { display: block; font-size: .92rem; margin-top: 1px; }
/* Computadora (Chrome en Windows o Mac) */
.np-pc { border-radius: 12px; padding: 10px 12px 8px; box-shadow: 0 4px 12px rgb(0 0 0 / .2), 0 18px 40px rgb(0 0 0 / .18); border: 1px solid var(--np-line); }
.np-pchead { display: flex; align-items: center; gap: 8px; font-size: .74rem; color: var(--np-muted); }
.np-pchead .np-badge { background: var(--np-muted); color: var(--np-bg); }
.np-x { border: 0; background: transparent; color: var(--np-muted); width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; cursor: pointer; }
.np-x:hover { background: var(--np-line); }
.np-fuente { display: block; font-size: .72rem; color: var(--np-muted); margin-top: 3px; }
.np-pc .np-acciones { margin: 8px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 6px; }
.np-pc .np-acciones button { background: var(--np-line); border-radius: 6px; color: var(--np-ink); font-weight: 500; }
/* Dónde aparece el aviso */
.np-capa { position: fixed; z-index: 70; animation: baja .4s cubic-bezier(.2, .9, .3, 1.15); }
.np-capa-android, .np-capa-iphone { top: calc(8px + env(safe-area-inset-top, 0px)); left: 50%; width: min(440px, calc(100% - 20px)); transform: translateX(-50%); }
.np-capa-escritorio { right: max(16px, env(safe-area-inset-right, 0px)); bottom: calc(16px + env(safe-area-inset-bottom, 0px)); width: min(380px, calc(100% - 32px)); animation: sube-pc .35s ease-out; }
.app.con-inferior .np-capa-escritorio { bottom: calc(92px + env(safe-area-inset-bottom, 0px)); }
@keyframes sube-pc { from { transform: translateY(24px); opacity: 0; } }
/* Muestras en Apariencia */
.np-muestras { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 14px; margin: 0; }
.np-marco { margin: 0; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.np-pantalla { border-radius: 22px; padding: 14px 10px; display: flex; flex-direction: column; gap: 8px; background: linear-gradient(160deg, #3b4a6b, #1d2436 60%, #12161f); min-height: 200px; }
.np-pantalla.np-ios { background: linear-gradient(160deg, #8a6d5a, #3e4a6e 55%, #1b2133); }
.np-pantalla.np-escr { background: linear-gradient(160deg, #2f6f8f, #234a6b 50%, #1a2a40); justify-content: flex-end; border-radius: 12px; }
.np-pantalla .np { cursor: default; }
.notas { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }

/* ═══════════════ GRÁFICAS ═══════════════ */
.chart { position: relative; margin: 0; min-width: 0; }
.chart svg { display: block; max-width: 100%; touch-action: pan-y; }
.ch-eje { font-size: 11px; fill: var(--muted); font-family: var(--f-body); font-variant-numeric: tabular-nums; }
.ch-tip { position: absolute; pointer-events: none; width: 140px; padding: 6px 10px; border-radius: 10px; background: var(--surface-solid); color: var(--ink); border: 1px solid var(--line); box-shadow: var(--shadow); font-size: .8rem; display: flex; flex-direction: column; text-align: center; z-index: 3; }
.ch-tip b { font-size: .98rem; font-variant-numeric: tabular-nums; }
.ch-tip span { color: var(--muted); }
.ch-datos { margin-top: 4px; font-size: .84rem; }
.ch-datos summary { cursor: pointer; color: var(--muted); min-height: 32px; display: flex; align-items: center; }
.ch-datos table { margin-top: 6px; }
.hbars { display: flex; flex-direction: column; gap: 10px; }
.hbar { display: grid; grid-template-columns: minmax(0, 40%) minmax(0, 1fr) auto; gap: 10px; align-items: center; font-size: .9rem; }
.hb-l { display: flex; align-items: center; gap: 8px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hb-t { display: block; height: 12px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.hb-t i { display: block; height: 100%; border-radius: 4px; }
.hb-v { font-weight: 700; white-space: nowrap; }
.hb-v small { font-weight: 500; color: var(--muted); }
@media (max-width: 520px) { .hbar { grid-template-columns: minmax(0, 1fr) auto; } .hb-t { grid-column: 1 / -1; grid-row: 2; } }
.stats-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; align-items: start; }
@media (max-width: 1000px) { .stats-2 { grid-template-columns: minmax(0, 1fr); } }
.split { display: flex; gap: 2px; height: 16px; border-radius: 99px; overflow: hidden; }
.split i { display: block; height: 100%; }

/* ═══════════════ VENTAS ═══════════════ */
.kanban { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(250px, 1fr); gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 6px; align-items: start; }
.k-col { scroll-snap-align: start; background: var(--surface-2); border: 1px solid var(--card-border); padding: 10px; display: flex; flex-direction: column; gap: 10px; min-width: 0; backdrop-filter: none; -webkit-backdrop-filter: none; box-shadow: none; }
.k-col header { display: flex; align-items: center; gap: 8px; padding: 2px 4px; }
.k-lista { display: flex; flex-direction: column; gap: 8px; max-height: 520px; overflow-y: auto; }
.k-card { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; text-align: left; padding: 12px; border-radius: var(--r); border: 1px solid var(--card-border); background: var(--surface-solid); box-shadow: var(--card-shadow); cursor: pointer; color: var(--ink); min-width: 0; width: 100%; }
.k-card:hover { border-color: var(--brand-line); }
.k-nom { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.k-vacio { padding: 14px 4px; text-align: center; }
@media (max-width: 640px) { .kanban { grid-auto-columns: 84%; } }
.embudo-mini { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.embudo-mini button { display: flex; flex-direction: column; gap: 2px; align-items: flex-start; padding: 12px; border-radius: var(--r); border: 1px solid var(--card-border); background: var(--surface); cursor: pointer; color: var(--ink); text-align: left; min-width: 0; }
.embudo-mini b { font-family: var(--f-display); font-weight: var(--peso-display); font-size: 1.5rem; line-height: 1.1; }
@media (max-width: 640px) { .embudo-mini { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.linea { list-style: none; margin: 0; padding: 0 0 0 14px; border-left: 2px solid var(--line); display: flex; flex-direction: column; gap: 8px; }
.linea li { display: flex; flex-direction: column; position: relative; }
.linea li::before { content: ""; position: absolute; left: -20px; top: 6px; width: 10px; height: 10px; border-radius: 50%; background: var(--brand); border: 2px solid var(--surface-solid); }
.filtros { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.acum-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 12px; }
.kpi-num { font-family: var(--f-display); font-weight: var(--peso-display); font-size: 1.5rem; }
.anuncios { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); gap: 14px; }
.mini-kpis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.mini-kpis > div { display: flex; flex-direction: column; padding: 10px; border-radius: var(--r); background: var(--surface-2); min-width: 0; }
.mini-kpis b { font-family: var(--f-display); font-weight: var(--peso-display); font-size: 1.2rem; overflow-wrap: anywhere; }
.mini-kpis span { font-size: .78rem; color: var(--muted); }
.retorno-ok { color: var(--good); }
.retorno-mal { color: var(--bad); }
.cat-row { display: grid; grid-template-columns: 130px minmax(0, 1.2fr) 110px minmax(0, 1.4fr) auto; gap: 8px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); }
.cat-row:last-of-type { border-bottom: 0; }
@media (max-width: 760px) { .cat-row { grid-template-columns: 120px minmax(0, 1fr) auto; } .cat-row .ct-desc { grid-column: 1 / -1; } .cat-row > input[aria-label="Precio"] { grid-column: 1; } }
.pill.tipo-servicio { background: var(--surface-2); color: var(--muted); }
.pill.tipo-paquete { background: var(--brand-soft); color: var(--brand-text); }
.pill.tipo-producto { background: var(--warn-bg); color: var(--warn); }
.chat-crm { display: flex; gap: 6px; flex-wrap: wrap; padding: 6px 14px; border-bottom: 1px solid var(--line); flex: none; }
.chat-crm button.pill { border: 0; cursor: pointer; }

/* ═══════════════ RESERVAS CON CUPO ═══════════════ */
.areas { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr)); gap: 16px; align-items: start; }
.ocup { display: flex; flex-direction: column; gap: 6px; }
.ocup-fila { display: grid; grid-template-columns: 48px minmax(70px, 110px) minmax(0, 1fr); gap: 10px; align-items: center; min-height: 36px; }
.ocup-fila .h { font-weight: 800; font-size: .9rem; }
.ocup-barra { position: relative; height: 22px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.ocup-barra i { position: absolute; inset: 0 auto 0 0; border-radius: 99px; opacity: .85; }
.ocup-barra em { position: absolute; inset: 0; display: grid; place-items: center; font-style: normal; font-size: .72rem; font-weight: 800; color: var(--ink); }
.ocup-chips { display: flex; flex-wrap: wrap; gap: 4px; min-width: 0; }
.res-chip { border: 1px solid var(--line); background: var(--surface-solid); color: var(--ink); border-radius: 99px; min-height: 30px; padding: 0 10px; font-size: .8rem; font-weight: 600; cursor: pointer; display: inline-flex; gap: 6px; align-items: center; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.res-chip b { background: var(--brand-soft); color: var(--brand-text); border-radius: 99px; padding: 0 6px; font-size: .74rem; }
.res-chip.por_confirmar { border-color: var(--warn); }
.res-chip.cancelada { opacity: .5; text-decoration: line-through; }
.res-chip.finalizada { opacity: .65; }
.res-chip.no_asistio { border-color: var(--bad); color: var(--bad); }
.res-add { width: 30px; height: 30px; border-radius: 50%; border: 1.5px dashed var(--brand-line); background: transparent; color: var(--brand-text); display: grid; place-items: center; cursor: pointer; }
.slot.slot-cupo { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; min-height: 54px; line-height: 1.1; }
.slot.slot-cupo small { font-weight: 600; font-size: .7rem; opacity: .8; }
.srv-row.con-cupo { grid-template-columns: auto minmax(0, 1fr) 110px auto 120px; }
.srv-row.neg { grid-template-columns: auto minmax(0, 1fr) 110px 120px auto; }
.srv-row.neg.con-cupo { grid-template-columns: auto minmax(0, 1fr) 110px auto 110px auto; }
@media (max-width: 640px) {
  .srv-row.con-cupo, .srv-row.neg, .srv-row.neg.con-cupo { grid-template-columns: auto minmax(0, 1fr) auto; }
  .srv-row .srv-cupo { grid-column: 2; }
  .srv-row.neg .srv-dur, .srv-row.neg .srv-precio { grid-column: 2; }
}

/* ═══════════════ PERSONALIDAD DE CADA ESTILO ═══════════════ */
/* ── Libreta: renglones azules, margen rojo, resaltador, notas pegadas ── */
.scope[data-estilo="libreta"], .emini[data-estilo="libreta"] { background-color: var(--bg); background-image: repeating-linear-gradient(to bottom, transparent 0 31px, var(--rule) 31px 32px); }
.emini[data-estilo="libreta"] { background-image: repeating-linear-gradient(to bottom, transparent 0 15px, var(--rule) 15px 16px), linear-gradient(to right, transparent 0 8px, var(--margen) 8px 9px, transparent 9px); }
.app[data-estilo="libreta"] .main { background-image: linear-gradient(to right, transparent 0 7px, var(--margen) 7px 8px, transparent 8px 10px, var(--margen) 10px 11px, transparent 11px); }
[data-estilo="libreta"] .btn { border: 1.5px solid color-mix(in srgb, var(--ink) 55%, transparent); }
[data-estilo="libreta"] .btn-primary { border-color: color-mix(in srgb, var(--brand) 70%, var(--ink)); }
[data-estilo="libreta"] .btn-ghost { border-color: transparent; }
[data-estilo="libreta"] .page-head h2, [data-estilo="libreta"] .section > h2, [data-estilo="libreta"] .section > div > h2 { display: inline; background-image: linear-gradient(transparent 58%, var(--marcador) 58% 90%, transparent 90%); padding: 0 4px; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
[data-estilo="libreta"] .hero h1 em { background-image: linear-gradient(transparent 60%, var(--marcador) 60% 92%, transparent 92%); color: inherit; padding: 0 4px; }
[data-estilo="libreta"] .label, [data-estilo="libreta"] .kpi span, [data-estilo="libreta"] .emini-kpi span { font-family: var(--f-mano); text-transform: none; letter-spacing: 0; font-size: 1.14rem; font-weight: 600; line-height: 1.1; }
[data-estilo="libreta"] .emini-kpi span { font-size: 12px; }
[data-estilo="libreta"] .kpi { position: relative; }
[data-estilo="libreta"] .kpi:first-child::before, [data-estilo="libreta"] .card.tour::before { content: ""; position: absolute; top: -9px; left: 50%; width: 74px; height: 18px; transform: translateX(-50%) rotate(-3deg); background: var(--cinta); border-radius: 2px; }
[data-estilo="libreta"] .card.tour { position: relative; background: var(--nota); color: var(--nota-ink); border-color: transparent; transform: rotate(-.5deg); box-shadow: 0 12px 20px -14px rgb(0 0 0 / .45); }
[data-estilo="libreta"] .card.tour .btn-soft { background: color-mix(in srgb, var(--nota-ink) 10%, transparent); color: var(--nota-ink); }
[data-estilo="libreta"] .demo-banner { background: var(--nota); color: var(--nota-ink); border-radius: 4px; }
[data-estilo="libreta"] .input, [data-estilo="libreta"] .select, [data-estilo="libreta"] .textarea { border-radius: 6px; background: var(--surface-solid); }
[data-estilo="libreta"] .side { background-color: var(--surface-solid); background-image: radial-gradient(circle at 9px 14px, var(--bg) 0 4px, var(--line) 4px 5px, transparent 5.5px); background-size: 18px 28px; background-repeat: repeat-y; padding-left: 26px; }
[data-estilo="libreta"] .ticket b, [data-estilo="libreta"] .hero-note { font-family: var(--f-mano); font-size: 1.15rem; }
[data-estilo="libreta"] .ticket b { font-size: 2.4rem; }
[data-estilo="libreta"] .pill.brand { border: 1px dashed var(--brand-line); }
[data-estilo="libreta"] .k-col { background: color-mix(in srgb, var(--surface-2) 70%, transparent); }

/* ── Plastilina: piezas suaves con sombra de barro, colores dulces ── */
.scope[data-estilo="plastilina"]::before, .emini[data-estilo="plastilina"]::before { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(38% 30% at 96% 6%, var(--deco1) 0 62%, transparent 63%), radial-gradient(30% 26% at 2% 98%, var(--deco2) 0 62%, transparent 63%), radial-gradient(18% 16% at 70% 78%, var(--deco3) 0 60%, transparent 61%); }
.emini[data-estilo="plastilina"]::before { position: absolute; }
[data-estilo="plastilina"] h1, [data-estilo="plastilina"] h2, [data-estilo="plastilina"] h3 { letter-spacing: 0; }
[data-estilo="plastilina"] .btn { border: 0; background: var(--surface-solid); box-shadow: var(--btn-shadow); font-weight: 800; }
[data-estilo="plastilina"] .btn-primary { background: var(--brand); }
[data-estilo="plastilina"] .btn-ghost { background: transparent; box-shadow: none; }
[data-estilo="plastilina"] .btn:hover { transform: translateY(-1px); }
[data-estilo="plastilina"] .input, [data-estilo="plastilina"] .select, [data-estilo="plastilina"] .textarea { border: 0; background: var(--surface-solid); box-shadow: inset 3px 4px 8px rgb(0 0 0 / .1), inset -2px -3px 6px rgb(255 255 255 / .1); }
[data-estilo="plastilina"] .kpis .kpi:nth-child(4n+1) { background: color-mix(in srgb, var(--deco1) 75%, var(--surface-solid)); }
[data-estilo="plastilina"] .kpis .kpi:nth-child(4n+2) { background: color-mix(in srgb, var(--deco2) 75%, var(--surface-solid)); }
[data-estilo="plastilina"] .kpis .kpi:nth-child(4n+3) { background: color-mix(in srgb, var(--deco3) 75%, var(--surface-solid)); }
[data-estilo="plastilina"] .topbar, [data-estilo="plastilina"] .tabsbar { background: color-mix(in srgb, var(--bg) 92%, transparent); border-bottom-color: transparent; box-shadow: 0 6px 18px rgb(120 80 20 / .08); }
[data-estilo="plastilina"] .side { background: transparent; border-right: 0; }
[data-estilo="plastilina"] .nav-item.on { background: var(--surface-solid); box-shadow: var(--btn-shadow); }
[data-estilo="plastilina"] .bottomnav { border-radius: 26px 26px 0 0; border-top: 0; box-shadow: 0 -8px 24px rgb(120 80 20 / .12); }
[data-estilo="plastilina"] .seg { box-shadow: inset 2px 3px 6px rgb(0 0 0 / .08); }
[data-estilo="plastilina"] .seg button.on { box-shadow: var(--btn-shadow); }
[data-estilo="plastilina"] .msg { box-shadow: 4px 6px 12px rgb(0 0 0 / .08); border-radius: 20px; }
[data-estilo="plastilina"] .card.tour { background: var(--nota); color: var(--nota-ink); }
[data-estilo="plastilina"] .k-col { background: color-mix(in srgb, var(--surface-2) 60%, transparent); }
[data-estilo="plastilina"] .avatar, [data-estilo="plastilina"] .mark { box-shadow: inset -3px -4px 6px rgb(0 0 0 / .12), inset 3px 4px 6px rgb(255 255 255 / .35); }

/* ── Cristal: vidrio esmerilado sobre blanco ostión, azules y negros ── */
.scope[data-estilo="cristal"]::before, .emini[data-estilo="cristal"]::before { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(44% 40% at 90% 4%, var(--deco1), transparent 70%), radial-gradient(38% 42% at 4% 96%, var(--deco2), transparent 70%), radial-gradient(30% 32% at 58% 58%, var(--deco3), transparent 72%); }
.emini[data-estilo="cristal"]::before { position: absolute; }
[data-estilo="cristal"] h1, [data-estilo="cristal"] h2 { letter-spacing: -.025em; }
[data-estilo="cristal"] .btn { background: color-mix(in srgb, var(--surface-solid) 55%, transparent); border-color: var(--card-border); backdrop-filter: blur(16px) saturate(160%); -webkit-backdrop-filter: blur(16px) saturate(160%); }
[data-estilo="cristal"] .btn-primary { background: var(--brand); border-color: color-mix(in srgb, var(--brand) 80%, #fff); }
[data-estilo="cristal"] .btn-ghost { background: transparent; border-color: transparent; backdrop-filter: none; }
[data-estilo="cristal"] .input, [data-estilo="cristal"] .select, [data-estilo="cristal"] .textarea { background: color-mix(in srgb, var(--surface-solid) 72%, transparent); border-color: var(--line); }
[data-estilo="cristal"] .topbar, [data-estilo="cristal"] .tabsbar, [data-estilo="cristal"] .side, [data-estilo="cristal"] .wiz-bar, [data-estilo="cristal"] .bottomnav { background: color-mix(in srgb, var(--surface-solid) 62%, transparent); backdrop-filter: blur(22px) saturate(170%); -webkit-backdrop-filter: blur(22px) saturate(170%); border-color: var(--card-border); }
[data-estilo="cristal"] .bottomnav { left: max(10px, env(safe-area-inset-left, 0px)); right: max(10px, env(safe-area-inset-right, 0px)); bottom: calc(10px + env(safe-area-inset-bottom, 0px)); border: 1px solid var(--card-border); border-radius: 26px; padding-bottom: 0; box-shadow: var(--shadow); }
[data-estilo="cristal"].app.con-inferior .main { padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }
[data-estilo="cristal"] .bottomnav .inner { padding-inline: 4px; }
[data-estilo="cristal"] .nav-item.on { background: color-mix(in srgb, var(--brand) 16%, transparent); }
[data-estilo="cristal"] .sheet, [data-estilo="cristal"] .pop, [data-estilo="cristal"] .drawer { background: color-mix(in srgb, var(--surface-solid) 86%, transparent); backdrop-filter: blur(26px) saturate(170%); -webkit-backdrop-filter: blur(26px) saturate(170%); }
[data-estilo="cristal"] .msg.cliente { background: var(--surface-solid); }
[data-estilo="cristal"] .chat-body { background: color-mix(in srgb, var(--brand) 5%, transparent); }
[data-estilo="cristal"] .k-col { background: color-mix(in srgb, var(--surface-solid) 40%, transparent); }
[data-estilo="cristal"] .card.tour { background: color-mix(in srgb, var(--brand) 9%, var(--surface)); }

/* Pantallas muy anchas: más aire */
@media (min-width: 1600px) { .page { max-width: 1440px; } .tabsbar .inner { max-width: 1440px; } .section, .land-top .inner, .foot .inner { max-width: 1320px; } }
@media (max-width: 420px) { .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } .kpi { padding: 12px; } .kpi b { font-size: 1.3rem; } .mini-kpis { grid-template-columns: minmax(0, 1fr); } }

/* ── Guion de venta, comprobantes y talleres ── */
.canal-chips { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.canal-chip { display: flex; align-items: center; gap: 10px; min-height: 56px; padding: 10px 12px; border-radius: var(--r); border: 1.5px solid var(--line); background: var(--surface); cursor: pointer; text-align: left; color: var(--ink); min-width: 0; }
.canal-chip:hover { border-color: var(--brand-line); }
.canal-chip.on { border-color: var(--brand); background: var(--brand-softer); box-shadow: 0 0 0 3px var(--brand-soft); }
.canal-chip > span:not(.canal) { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.canal-chip small { font-size: .74rem; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.canal-chip .cc-check { width: 22px; height: 22px; border-radius: 7px; border: 1.5px solid var(--line); display: grid; place-items: center; font-style: normal; font-weight: 800; font-size: .8rem; flex: none; }
.canal-chip.on .cc-check { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
@media (max-width: 560px) { .canal-chips { grid-template-columns: minmax(0, 1fr); } }

.adjunto { display: flex; align-items: center; gap: 10px; padding: 8px 10px; margin-bottom: 4px; border-radius: 12px; background: color-mix(in srgb, var(--ink) 6%, transparent); white-space: normal; }
.adjunto b { display: block; font-size: .86rem; }
.adjunto small { display: block; font-size: .72rem; color: var(--muted); }
.adj-ico { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--warn-bg); color: var(--warn); flex: none; }
.comp-aviso { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 14px; border-radius: var(--r); border: 1px solid color-mix(in srgb, var(--warn) 35%, transparent); background: var(--warn-bg); color: var(--ink); text-align: left; }
.comp-aviso.click { cursor: pointer; }
.comp-aviso .adj-ico { background: var(--surface); }
.guion-pill .ico { color: var(--brand-text); }

.guion-pasos { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.guion-paso { border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); overflow: hidden; }
.guion-paso.on { border-color: var(--brand-line); box-shadow: 0 0 0 3px var(--brand-softer); }
.gp-head { display: flex; align-items: flex-start; gap: 12px; width: 100%; padding: 12px 14px; background: none; border: 0; text-align: left; cursor: pointer; color: var(--ink); min-width: 0; }
.gp-head:hover { background: var(--brand-softer); }
.gp-head .grow { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.gp-n { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-text); font-weight: 800; flex: none; font-variant-numeric: tabular-nums; }
.gp-vista { font-size: .84rem; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; white-space: pre-line; }
.gp-body { padding: 0 14px 14px 56px; }
.gp-body textarea { min-height: 120px; resize: vertical; line-height: 1.45; }
.gp-preview { display: flex; flex-direction: column; gap: 6px; padding: 12px; border-radius: var(--r); background: var(--surface-2); }
.gp-preview .msg { align-self: flex-start; max-width: 100%; }
.chip.chip-sm { min-height: 32px; padding: 0 10px; font-size: .8rem; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
@media (max-width: 640px) { .gp-body { padding-left: 14px; } }

.cat-row .ev-campos { grid-column: 1 / -1; display: grid; grid-template-columns: 160px 96px 96px 96px minmax(0, 1fr); gap: 8px; align-items: end; padding: 4px 0 2px; }
.ev-campos .field span { font-weight: 600; }
.ev-lleno { padding-bottom: 12px; }
@media (max-width: 760px) { .cat-row .ev-campos { grid-template-columns: repeat(2, minmax(0, 1fr)); } .ev-lleno { grid-column: 1 / -1; padding: 0; } }

.talleres { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 10px; }
.taller { display: flex; gap: 14px; align-items: flex-start; padding: 14px; border-radius: var(--r); border: 1px solid var(--card-border, var(--line)); background: var(--surface); text-align: left; cursor: pointer; color: var(--ink); min-width: 0; }
.taller:hover { border-color: var(--brand-line); }
.tl-fecha { width: 54px; flex: none; display: flex; flex-direction: column; align-items: center; padding: 6px 0; border-radius: 12px; background: var(--brand-soft); color: var(--brand-text); }
.tl-fecha b { font-family: var(--f-display); font-weight: var(--peso-display); font-size: 1.5rem; line-height: 1; }
.tl-fecha small { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.tl-barra { display: block; height: 8px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.tl-barra i { display: block; height: 100%; border-radius: 99px; background: var(--brand); }
@media (max-width: 640px) { .chat-crm { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; align-items: center; } .chat-crm::-webkit-scrollbar { display: none; } .chat-crm > * { flex: none; } }

/* ── Cobros con varias pasarelas ── */
.pago-ops { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.pago-op { gap: 4px; padding: 12px 14px; }
.pago-op > span { font-size: .86rem; color: var(--muted); }
.pago-op[disabled] { opacity: .6; cursor: not-allowed; }
@media (max-width: 640px) { .pago-ops { grid-template-columns: minmax(0, 1fr); } }
.pas-ini { width: 30px; height: 30px; border-radius: 9px; display: inline-grid; place-items: center; flex: none; background: var(--brand-soft); color: var(--brand-text); font-weight: 800; font-size: .74rem; }
.pas-ini.oxxo { background: var(--warn-bg); color: var(--warn); }
.forma-pago { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: var(--r); border: 1px solid var(--line); background: var(--surface); flex-wrap: wrap; }
.forma-pago .grow { min-width: 160px; }
.pago-ok { display: flex; gap: 14px; align-items: flex-start; padding: 14px; border-radius: var(--r); background: var(--good-bg); }
.pago-ok .mark { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--good); color: #fff; flex: none; }
.pago-mal { padding: 12px 14px; border-radius: var(--r); background: var(--bad-bg); color: var(--ink); border: 1px solid color-mix(in srgb, var(--bad) 30%, transparent); }
.pago-espera { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 28px 12px; text-align: center; }
.spin { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--brand-soft); border-top-color: var(--brand); animation: girar .8s linear infinite; }
@keyframes girar { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spin { animation-duration: 3s; } }
.ficha { display: flex; flex-direction: column; gap: 4px; padding: 16px; border-radius: var(--r-lg); border: 2px dashed var(--line); background: var(--surface); }
.ficha-monto { font-family: var(--f-display); font-size: 1.6rem; }
.ficha-ref { font-size: 1.25rem; letter-spacing: .06em; }
.pasos-simple { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }
.recargas { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.recarga { display: flex; flex-direction: column; gap: 2px; align-items: flex-start; padding: 12px; border-radius: var(--r); border: 1px solid var(--line); background: var(--surface); cursor: pointer; color: var(--ink); text-align: left; }
.recarga:hover { border-color: var(--brand-line); background: var(--brand-softer); }
.recarga span { font-weight: 700; color: var(--brand-text); }
.recarga small { color: var(--muted); font-size: .76rem; }
@media (max-width: 760px) { .recargas { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.muestra { position: relative; border: 1.5px dashed var(--line); border-radius: var(--r-lg); padding: 30px 14px 14px; background: var(--surface-2); }
.muestra-tag { position: absolute; top: 8px; left: 12px; font-size: .7rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.tarjeta-sim, .app-sim { display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); }
.tarjeta-sim input[readonly] { pointer-events: none; color: var(--muted); background: var(--surface-2); }
.app-sim { align-items: center; text-align: center; max-width: 320px; margin-inline: auto; width: 100%; }
.campo-sim { width: 100%; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); font-size: .86rem; color: var(--muted); }
.btn-sim { display: block; width: 100%; text-align: center; padding: 11px; border-radius: 12px; background: var(--surface-2); color: var(--muted); font-weight: 800; border: 1px solid var(--line); }
.barras { width: 100%; max-width: 360px; height: 48px; fill: var(--ink); margin-top: 6px; }
.trampa{position:absolute!important;left:-9999px!important;width:1px;height:1px;opacity:0}

/* ── Sistema real: acceso y guardado ── */
.acceso { width: min(440px, 100%); margin: 28px auto 64px; }
.guardado { position: fixed; z-index: 60; left: 50%; transform: translateX(-50%); bottom: calc(84px + env(safe-area-inset-bottom, 0px)); padding: 8px 14px; border-radius: 999px; background: var(--ink, #0a0f1d); color: var(--bg, #fff); font-size: .85rem; font-weight: 600; box-shadow: var(--shadow); pointer-events: none; }
.guardado.mal { background: var(--bad, #b42318); color: #fff; }
@media (max-width: 420px) { .land-top:has(.btn-entrar) .icon-btn { display: none; } }

/* ── Talleres y cursos ── */
.ses-ops { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr)); gap: 8px; }
.ses-op { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 10px 12px; min-height: 52px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); text-align: left; cursor: pointer; font: inherit; }
.ses-op small { color: var(--muted); font-size: .82rem; }
.ses-op.on { border-color: var(--brand); background: var(--brand-soft); box-shadow: inset 0 0 0 1px var(--brand); }
.ses-op[disabled] { opacity: .5; cursor: not-allowed; }
.ag-cita.ag-taller { background: var(--brand-soft); border-left: 4px solid var(--brand); color: var(--brand-text); cursor: pointer; }

/* Aviso de privacidad bajo el botón de agendar */
.aviso-datos { text-align: center; margin: 2px 0 0; }
.aviso-datos a, .foot a { color: inherit; text-decoration: underline; }

/* ── Mensajes de Facebook e Instagram (versión real) ── */
.conectar-meta .canal { width: 34px; height: 34px; border-radius: 10px; font-size: .9rem; }
.lista-meta { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }
.conexiones-meta > summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.conexiones-meta > summary::-webkit-details-marker { display: none; }
.conexiones-meta > summary::after { content: "▾"; color: var(--muted); margin-left: auto; transition: transform .15s; }
.conexiones-meta[open] > summary::after { transform: rotate(180deg); }
.conexiones-meta .list-row { flex-wrap: wrap; row-gap: 8px; }
