/* Studio SaaS · componentes de las pantallas públicas y del panel de clientes.
   Se pintan dentro del layout del tema activo de Webs y heredan sus colores (--w-*); cada tema puede sobrescribir --sc-*.
   Mobile first: las reglas base son para el teléfono y los @media (min-width) amplían para tableta y escritorio. */
.sc {
  --sc-bg: var(--w-bg, #f6f8fc); --sc-surface: var(--w-surface, #fff); --sc-line: var(--w-border, #e3e8f1); --sc-line-2: color-mix(in srgb, var(--sc-line) 55%, #fff);
  --sc-text: var(--w-text, #172033); --sc-ink: var(--w-text, #0c1633);
  --sc-sub: var(--w-muted, #5b6578); --sc-faint: color-mix(in srgb, var(--sc-sub) 72%, #fff);
  --sc-brand: var(--w-primary, #2b5cff); --sc-brand-c: var(--w-primary-contrast, #fff);
  --sc-brand-d: color-mix(in srgb, var(--sc-brand) 84%, #000); --sc-brand-l: color-mix(in srgb, var(--sc-brand) 9%, #fff); --sc-brand-m: color-mix(in srgb, var(--sc-brand) 22%, #fff);
  --sc-ok: #0d8a5f; --sc-ok-l: #e4f6ee; --sc-warn: #a1620b; --sc-warn-l: #fff4dc; --sc-bad: #c8283c; --sc-bad-l: #fde9ec; --sc-info: #2160a8; --sc-info-l: #e7f0fb;
  --sc-radius: var(--w-radius, 14px); --sc-radius-sm: 10px;
  --sc-shadow-sm: 0 1px 2px rgba(16, 24, 40, .05);
  --sc-shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 4px 16px -4px rgba(16, 24, 40, .08);
  --sc-shadow-lg: 0 2px 4px rgba(16, 24, 40, .04), 0 18px 40px -12px rgba(16, 24, 40, .18);
  --sc-ring: 0 0 0 4px color-mix(in srgb, var(--sc-brand) 18%, transparent);
  --sc-ease: cubic-bezier(.2, .7, .2, 1);
  color: var(--sc-text); font-size: 15px; line-height: 1.55; -webkit-tap-highlight-color: transparent;
}
.sc *, .sc *::before, .sc *::after { box-sizing: border-box; }
.sc a { color: var(--sc-brand); text-decoration: none; } .sc a:hover { text-decoration: underline; text-underline-offset: 3px; }
.sc h1, .sc h2, .sc h3, .sc h4 { line-height: 1.2; margin: 0 0 .5em; color: var(--sc-ink); letter-spacing: -.02em; font-weight: 700; }
.sc h1 { font-size: clamp(1.6rem, 6vw, 2.6rem); letter-spacing: -.03em; } .sc h2 { font-size: clamp(1.35rem, 4.4vw, 2rem); } .sc h3 { font-size: 1.05rem; letter-spacing: -.01em; }
.sc p { margin: 0 0 1em; }
.sc .ph { line-height: 1; }
.sc-wrap { width: min(1160px, 100% - 32px); margin-inline: auto; }
.sc-muted { color: var(--sc-sub); } .sc-faint { color: var(--sc-faint); } .sc-right { text-align: right; } .sc-center { text-align: center; }
.sc-small { font-size: .86rem; } .sc-xs { font-size: .78rem; }
.sc-mono { font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace; font-size: .92em; letter-spacing: 0; }
.sc-stack { display: grid; gap: 12px; } .sc-row-gap { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.sc-back { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: .88rem; color: var(--sc-sub) !important; margin-bottom: 10px; } .sc-back:hover { color: var(--sc-brand) !important; text-decoration: none !important; }

/* Botones */
.sc-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px; border-radius: 12px; border: 1px solid var(--sc-brand); background: var(--sc-brand); color: var(--sc-brand-c) !important; font: inherit; font-weight: 600; font-size: .95rem; line-height: 1.2; cursor: pointer; text-decoration: none !important; white-space: nowrap; transition: background .15s, border-color .15s, box-shadow .15s, transform .1s; box-shadow: 0 1px 2px rgba(16, 24, 40, .1), inset 0 1px 0 rgba(255, 255, 255, .14); -webkit-user-select: none; user-select: none; }
.sc-btn:hover { background: var(--sc-brand-d); border-color: var(--sc-brand-d); }
.sc-btn:active { transform: scale(.98); }
.sc-btn:focus-visible { outline: none; box-shadow: var(--sc-ring); }
.sc-btn .ph { font-size: 1.15em; }
.sc-btn--ghost { background: var(--sc-surface); color: var(--sc-ink) !important; border-color: var(--sc-line); box-shadow: var(--sc-shadow-sm); } .sc-btn--ghost:hover { background: var(--sc-surface); border-color: color-mix(in srgb, var(--sc-line) 50%, var(--sc-sub)); }
.sc-btn--soft { background: var(--sc-brand-l); color: var(--sc-brand) !important; border-color: transparent; box-shadow: none; } .sc-btn--soft:hover { background: var(--sc-brand-m); border-color: transparent; }
.sc-btn--text { background: none; border-color: transparent; color: var(--sc-brand) !important; box-shadow: none; padding-inline: 8px; } .sc-btn--text:hover { background: var(--sc-brand-l); border-color: transparent; }
.sc-btn--danger { background: var(--sc-surface); color: var(--sc-bad) !important; border-color: color-mix(in srgb, var(--sc-bad) 30%, #fff); box-shadow: none; } .sc-btn--danger:hover { background: var(--sc-bad-l); border-color: var(--sc-bad); }
.sc-btn--lg { min-height: 52px; padding: 14px 24px; font-size: 1rem; border-radius: 14px; } .sc-btn--sm { min-height: 36px; padding: 6px 12px; font-size: .86rem; border-radius: 10px; } .sc-btn--block { width: 100%; }
.sc-btn[disabled], .sc-btn.is-loading { opacity: .65; pointer-events: none; }
.sc-btn.is-loading::after { content: ''; width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: sc-spin .7s linear infinite; }
@keyframes sc-spin { to { transform: rotate(360deg); } }

/* Formularios */
.sc-field { margin-bottom: 16px; } .sc-field > label, .sc-label { display: block; font-weight: 600; font-size: .875rem; margin-bottom: 6px; color: var(--sc-ink); }
.sc-field > label .sc-opt, .sc-label .sc-opt { font-weight: 500; color: var(--sc-faint); }
.sc-field small, .sc-hint { color: var(--sc-sub); display: block; margin-top: 6px; font-size: .82rem; line-height: 1.45; }
.sc-input, .sc input[type=text], .sc input[type=email], .sc input[type=password], .sc input[type=number], .sc input[type=date], .sc input[type=tel], .sc input[type=url], .sc input[type=search], .sc select, .sc textarea {
  width: 100%; min-height: 48px; padding: 11px 14px; border: 1px solid var(--sc-line); border-radius: 12px; background: #fff; font: inherit; font-size: 16px; color: var(--sc-text); transition: border-color .15s, box-shadow .15s; -webkit-appearance: none; appearance: none; }
.sc select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 256 256'%3E%3Cpath fill='%235b6578' d='M213.66 101.66l-80 80a8 8 0 0 1-11.32 0l-80-80a8 8 0 0 1 11.32-11.32L128 164.69l74.34-74.35a8 8 0 0 1 11.32 11.32Z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 38px; }
.sc input::placeholder, .sc textarea::placeholder { color: var(--sc-faint); }
.sc input:hover, .sc select:hover, .sc textarea:hover { border-color: color-mix(in srgb, var(--sc-line) 55%, var(--sc-sub)); }
.sc input:focus, .sc select:focus, .sc textarea:focus { outline: none; border-color: var(--sc-brand); box-shadow: var(--sc-ring); }
.sc textarea { min-height: 128px; resize: vertical; line-height: 1.5; }
.sc input[type=checkbox], .sc input[type=radio] { accent-color: var(--sc-brand); width: 18px; height: 18px; flex: none; }
.sc-check { display: flex; gap: 10px; align-items: flex-start; font-size: .92rem; cursor: pointer; } .sc-check input { margin-top: 2px; }
.sc-grid2 { display: grid; grid-template-columns: 1fr; gap: 0 16px; }
@media (min-width: 640px) { .sc-grid2 { grid-template-columns: 1fr 1fr; } .sc { font-size: 15.5px; } }

/* Campo con prefijo/sufijo (subdominio, cupón) y campo de contraseña con botón para mostrarla */
.sc-affix { display: flex; align-items: stretch; border: 1px solid var(--sc-line); border-radius: 12px; background: #fff; transition: border-color .15s, box-shadow .15s; overflow: hidden; }
.sc-affix:focus-within { border-color: var(--sc-brand); box-shadow: var(--sc-ring); }
.sc .sc-affix input { border: 0; box-shadow: none !important; border-radius: 0; min-width: 0; flex: 1; }
.sc-affix > span { display: flex; align-items: center; padding: 0 14px; background: #f7f8fb; color: var(--sc-sub); border-left: 1px solid var(--sc-line); font-size: .92rem; white-space: nowrap; }
.sc-affix > button { border: 0; background: none; padding: 0 14px; color: var(--sc-sub); cursor: pointer; font-size: 1.15rem; display: grid; place-items: center; } .sc-affix > button:hover { color: var(--sc-ink); }
.sc-status { display: flex; align-items: center; gap: 6px; } .sc-status.is-ok { color: var(--sc-ok); } .sc-status.is-bad { color: var(--sc-bad); }

/* Archivo: zona para soltar o elegir */
.sc-drop { position: relative; display: flex; align-items: center; gap: 14px; border: 1.5px dashed var(--sc-line); border-radius: 14px; padding: 16px; background: #fbfcfe; cursor: pointer; transition: border-color .15s, background .15s; }
.sc-drop:hover, .sc-drop.is-over { border-color: var(--sc-brand); background: var(--sc-brand-l); }
.sc-drop input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.sc-drop .ph { font-size: 1.6rem; color: var(--sc-brand); flex: none; } .sc-drop strong { display: block; font-size: .92rem; color: var(--sc-ink); } .sc-drop small { margin: 0; }

/* Alertas, chips y tarjetas */
.sc-alert { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 14px; margin-bottom: 16px; border: 1px solid; font-size: .93rem; line-height: 1.5; }
.sc-alert > .ph { font-size: 1.25rem; flex: none; margin-top: 1px; } .sc-alert > div { flex: 1; min-width: 0; } .sc-alert ul { margin: 0; padding-left: 18px; } .sc-alert a { color: inherit; font-weight: 700; text-decoration: underline; }
.sc-alert--ok { background: var(--sc-ok-l); border-color: #bfe7d4; color: #08603f; } .sc-alert--bad { background: var(--sc-bad-l); border-color: #f5c6cd; color: #8c1d2c; } .sc-alert--info { background: var(--sc-info-l); border-color: #c4d9f1; color: #1a4b84; } .sc-alert--warn { background: var(--sc-warn-l); border-color: #f0dba6; color: #74480a; }
.sc-chip { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 99px; font-size: .76rem; font-weight: 600; background: #eef0f5; color: var(--sc-sub); white-space: nowrap; vertical-align: middle; line-height: 1.5; letter-spacing: 0; }
.sc-chip::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .85; }
.sc-chip--ok { background: var(--sc-ok-l); color: var(--sc-ok); } .sc-chip--warn { background: var(--sc-warn-l); color: var(--sc-warn); } .sc-chip--bad { background: var(--sc-bad-l); color: var(--sc-bad); } .sc-chip--info { background: var(--sc-info-l); color: var(--sc-info); }
.sc-card { background: #fff; border: 1px solid var(--sc-line); border-radius: calc(var(--sc-radius) + 2px); padding: 18px; box-shadow: var(--sc-shadow); margin-bottom: 16px; }
.sc-card > h3:first-child, .sc-card-head { margin-bottom: 14px; } .sc-card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; } .sc-card-head h3 { margin: 0; }
.sc-card-head h3, .sc-card > h3 { display: flex; align-items: center; gap: 10px; }
.sc-card-head a:not(.sc-btn) { font-weight: 600; font-size: .88rem; display: inline-flex; align-items: center; gap: 4px; }
.sc-card--flush { padding: 0; overflow: hidden; } .sc-card--flush > .sc-card-head { padding: 16px 18px 0; }
.sc-ico { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--sc-brand-l); color: var(--sc-brand); font-size: 1.25rem; flex: none; }
.sc-ico--sm { width: 32px; height: 32px; border-radius: 10px; font-size: 1.05rem; }
.sc-ico--ok { background: var(--sc-ok-l); color: var(--sc-ok); } .sc-ico--warn { background: var(--sc-warn-l); color: var(--sc-warn); } .sc-ico--bad { background: var(--sc-bad-l); color: var(--sc-bad); } .sc-ico--info { background: var(--sc-info-l); color: var(--sc-info); }
@media (min-width: 640px) { .sc-card { padding: 24px; margin-bottom: 20px; } .sc-card--flush { padding: 0; } .sc-card--flush > .sc-card-head { padding: 20px 24px 0; } }

/* Listas tipo app: fila con icono, texto y acción */
.sc-list { display: flex; flex-direction: column; }
.sc-item { display: flex; align-items: center; gap: 14px; padding: 14px 18px; border-top: 1px solid var(--sc-line-2); color: inherit !important; text-decoration: none !important; transition: background .12s; }
.sc-list > .sc-item:first-child { border-top: 0; } a.sc-item:hover { background: #fafbfd; }
.sc-item-main { flex: 1; min-width: 0; } .sc-item-main strong { display: block; color: var(--sc-ink); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sc-item-main span, .sc-item-main small { display: block; color: var(--sc-sub); font-size: .84rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sc-item-end { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; text-align: right; flex: none; } .sc-item-end strong { color: var(--sc-ink); }
.sc-item > .ph-caret-right { color: var(--sc-faint); flex: none; }
@media (min-width: 640px) { .sc-item { padding: 14px 24px; } }

/* Tablas: en el teléfono cada fila se vuelve una tarjeta con etiquetas (td[data-label]) */
.sc-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; } .sc-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.sc-table th { text-align: left; font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--sc-faint); font-weight: 600; padding: 10px 14px; border-bottom: 1px solid var(--sc-line); white-space: nowrap; background: #fafbfd; }
.sc-table td { padding: 14px; border-bottom: 1px solid var(--sc-line-2); vertical-align: middle; } .sc-table tr:last-child td { border-bottom: 0; } .sc-table tbody tr:hover { background: #fafbfd; }
.sc-table th.sc-right, .sc-table td.sc-right { text-align: right; }
@media (max-width: 719px) {
  .sc-table--cards thead { display: none; }
  .sc-table--cards, .sc-table--cards tbody, .sc-table--cards tr, .sc-table--cards td { display: block; width: 100%; }
  .sc-table--cards tr { padding: 14px 18px; border-bottom: 1px solid var(--sc-line-2); } .sc-table--cards tr:last-child { border-bottom: 0; }
  .sc-table--cards td { padding: 3px 0; border: 0; display: flex; justify-content: space-between; gap: 12px; text-align: right; }
  .sc-table--cards td[data-label]::before { content: attr(data-label); color: var(--sc-sub); font-size: .84rem; text-align: left; }
  .sc-table--cards td.sc-td-main { display: block; text-align: left; padding-bottom: 6px; font-size: 1rem; }
  .sc-table--cards td.sc-td-action { padding-top: 10px; } .sc-table--cards td.sc-td-action .sc-btn { width: 100%; }
  .sc-table--cards td.sc-empty { display: block; text-align: center; }
}
.sc-empty { text-align: center; padding: 40px 20px; color: var(--sc-sub); }
.sc-empty > .ph { font-size: 2.4rem; color: var(--sc-faint); display: block; margin: 0 auto 12px; }
.sc-empty strong { display: block; color: var(--sc-ink); font-size: 1.05rem; margin-bottom: 4px; } .sc-empty p { margin: 0 auto 16px; max-width: 360px; }
.sc-pager { display: flex; justify-content: space-between; align-items: center; margin-top: 16px; }

/* Secciones de portada */
.sc-section { padding: 56px 0; } .sc-section--alt { background: #fff; border-block: 1px solid var(--sc-line); }
.sc-section-head { text-align: center; max-width: 660px; margin: 0 auto 32px; } .sc-section-head p { color: var(--sc-sub); font-size: 1.02rem; margin: 0; }
.sc-eyebrow { display: inline-flex; align-items: center; gap: 6px; font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--sc-brand); margin-bottom: 10px; }
.sc-features { display: grid; grid-template-columns: 1fr; gap: 14px; }
.sc-feature { background: #fff; border: 1px solid var(--sc-line); border-radius: var(--sc-radius); padding: 20px; transition: border-color .2s, box-shadow .2s, transform .2s var(--sc-ease); }
.sc-feature:hover { border-color: var(--sc-brand-m); box-shadow: var(--sc-shadow); }
.sc-feature .ico { width: 44px; height: 44px; border-radius: 12px; background: var(--sc-brand-l); color: var(--sc-brand); display: grid; place-items: center; font-size: 1.35rem; margin-bottom: 14px; font-weight: 700; }
.sc-feature h3 { margin-bottom: 6px; } .sc-feature p { color: var(--sc-sub); margin: 0; font-size: .93rem; }
@media (min-width: 560px) { .sc-features { grid-template-columns: repeat(2, 1fr); gap: 16px; } }
@media (min-width: 960px) { .sc-section { padding: 88px 0; } .sc-section-head { margin-bottom: 48px; } .sc-features { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; } .sc-feature { padding: 24px; } }

/* Planes */
.sc-plans { display: grid; grid-template-columns: 1fr; gap: 16px; align-items: stretch; }
@media (min-width: 680px) { .sc-plans { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; } }
.sc-plan { position: relative; background: #fff; border: 1px solid var(--sc-line); border-radius: 20px; padding: 24px 22px; display: flex; flex-direction: column; box-shadow: var(--sc-shadow); transition: transform .2s var(--sc-ease), box-shadow .2s; }
@media (hover: hover) { .sc-plan:hover { transform: translateY(-4px); box-shadow: var(--sc-shadow-lg); } }
.sc-plan.is-featured { border: 1.5px solid var(--sc-brand); box-shadow: 0 0 0 4px var(--sc-brand-l), var(--sc-shadow-lg); }
.sc-plan .ribbon { position: absolute; top: -12px; left: 22px; background: var(--sc-brand); color: var(--sc-brand-c); font-size: .72rem; font-weight: 700; padding: 4px 12px; border-radius: 99px; letter-spacing: .02em; display: inline-flex; align-items: center; gap: 5px; box-shadow: 0 4px 12px -2px color-mix(in srgb, var(--sc-brand) 50%, transparent); }
.sc-plan h3 { font-size: 1.2rem; margin-bottom: 4px; } .sc-plan .tag { color: var(--sc-sub); font-size: .9rem; }
.sc-price { margin: 18px 0 4px; display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; } .sc-price strong { font-size: 2.4rem; letter-spacing: -.04em; color: var(--sc-ink); line-height: 1; font-weight: 800; } .sc-price span { color: var(--sc-sub); font-size: .92rem; }
.sc-price--quote strong { font-size: 1.5rem; letter-spacing: -.02em; }
.sc-plan .sub { color: var(--sc-sub); font-size: .82rem; min-height: 1.3em; } .sc-plan .sub b { color: var(--sc-ok); font-weight: 700; }
.sc-plan ul { list-style: none; padding: 18px 0 0; margin: 18px 0 22px; flex: 1; border-top: 1px solid var(--sc-line-2); display: grid; gap: 10px; align-content: start; }
.sc-plan li { padding-left: 28px; position: relative; font-size: .92rem; line-height: 1.45; }
.sc-plan li::before { content: ''; position: absolute; left: 0; top: 1px; width: 18px; height: 18px; border-radius: 50%; background: var(--sc-ok-l) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 256 256'%3E%3Cpath fill='%230d8a5f' d='M232.49 80.49l-128 128a12 12 0 0 1-17 0l-56-56a12 12 0 1 1 17-17L96 183 215.51 63.51a12 12 0 0 1 17 17Z'/%3E%3C/svg%3E") center / 10px no-repeat; }
@media (min-width: 680px) { .sc-plan { padding: 28px 26px; } .sc-plan .tag { min-height: 2.8em; } }

/* Selector segmentado (ciclos de pago) */
.sc-tabs { display: inline-flex; background: #eef1f6; border-radius: 14px; padding: 4px; gap: 2px; max-width: 100%; overflow-x: auto; scrollbar-width: none; } .sc-tabs::-webkit-scrollbar { display: none; }
.sc-tabs button { border: 0; background: none; padding: 9px 16px; border-radius: 11px; font: inherit; font-size: .9rem; font-weight: 600; color: var(--sc-sub); cursor: pointer; white-space: nowrap; transition: background .15s, color .15s, box-shadow .15s; }
.sc-tabs button.is-on { background: #fff; color: var(--sc-ink); box-shadow: 0 1px 3px rgba(16, 24, 40, .12); }
.sc-tabs button small { color: var(--sc-ok); font-weight: 700; margin-left: 4px; font-size: .74rem; }
.sc-seg { flex: 1; text-align: center; padding: 9px 12px; border-radius: 11px; font-size: .9rem; font-weight: 600; color: var(--sc-sub); cursor: pointer; white-space: nowrap; transition: background .15s, color .15s, box-shadow .15s; }
.sc-seg.is-on { background: #fff; color: var(--sc-ink); box-shadow: 0 1px 3px rgba(16, 24, 40, .12); }
.sc-cat { margin: 44px 0 16px; font-size: 1.2rem; } .sc-cat:first-of-type { margin-top: 0; }

/* Páginas internas y flujo de compra */
.sc-page { padding: 24px 0 56px; } .sc-page-head { margin-bottom: 20px; } .sc-page-head h1 { font-size: clamp(1.5rem, 5vw, 2.1rem); margin-bottom: 6px; } .sc-page-head p { color: var(--sc-sub); margin: 0; }
@media (min-width: 900px) { .sc-page { padding: 40px 0 80px; } .sc-page-head { margin-bottom: 28px; } }
.sc-layout { display: grid; grid-template-columns: 1fr; gap: 16px; align-items: start; }
.sc-layout > aside { position: static; }
@media (min-width: 960px) { .sc-layout { grid-template-columns: minmax(0, 1fr) 380px; gap: 24px; } .sc-layout > aside { position: sticky; top: 88px; } }
.sc-line { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 9px 0; font-size: .93rem; } .sc-line > span:first-child { color: var(--sc-sub); } .sc-line strong { color: var(--sc-ink); }
.sc-total { display: flex; justify-content: space-between; align-items: baseline; font-size: 1.05rem; font-weight: 700; padding-top: 14px; border-top: 1px solid var(--sc-line); margin-top: 8px; color: var(--sc-ink); } .sc-total span:last-child { font-size: 1.45rem; letter-spacing: -.02em; }
.sc-secure { display: flex; align-items: center; justify-content: center; gap: 6px; color: var(--sc-sub); font-size: .8rem; margin: 12px 0 0; }

/* Pasos del flujo: Plan · Carrito · Pago · Listo */
.sc-steps { display: flex; align-items: center; gap: 6px; list-style: none; margin: 0 0 18px; padding: 0; font-size: .8rem; font-weight: 600; color: var(--sc-faint); overflow-x: auto; scrollbar-width: none; } .sc-steps::-webkit-scrollbar { display: none; }
.sc-steps li { display: flex; align-items: center; gap: 6px; white-space: nowrap; } .sc-steps li + li::before { content: ''; width: 18px; height: 1.5px; background: var(--sc-line); margin-right: 2px; }
.sc-steps b { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; border: 1.5px solid var(--sc-line); font-size: .72rem; background: #fff; }
.sc-steps .is-done { color: var(--sc-ok); } .sc-steps .is-done b { background: var(--sc-ok); border-color: var(--sc-ok); color: #fff; } .sc-steps .is-done + li::before { background: var(--sc-ok); }
.sc-steps .is-on { color: var(--sc-ink); } .sc-steps .is-on b { background: var(--sc-brand); border-color: var(--sc-brand); color: var(--sc-brand-c); box-shadow: 0 0 0 4px var(--sc-brand-l); }
@media (min-width: 640px) { .sc-steps { font-size: .86rem; gap: 10px; } .sc-steps li + li::before { width: 36px; } }

/* Barra fija inferior del flujo (teléfono): total + botón principal */
.sc-mbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 45; display: flex; align-items: center; gap: 14px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); background: rgba(255, 255, 255, .96); backdrop-filter: saturate(1.6) blur(14px); -webkit-backdrop-filter: saturate(1.6) blur(14px); border-top: 1px solid var(--sc-line); box-shadow: 0 -8px 24px -12px rgba(16, 24, 40, .18); }
.sc-mbar > div { flex: 1; min-width: 0; line-height: 1.2; } .sc-mbar small { display: block; color: var(--sc-sub); font-size: .76rem; } .sc-mbar strong { font-size: 1.15rem; color: var(--sc-ink); letter-spacing: -.02em; }
.sc-mbar .sc-btn { flex: none; min-width: 46%; }
.sc-mbar-space { height: calc(78px + env(safe-area-inset-bottom)); }
@media (min-width: 960px) { .sc-mbar, .sc-mbar-space { display: none; } }

/* Datos bancarios */
.sc-bank { border: 1px solid var(--sc-line); border-radius: 14px; padding: 14px 16px; margin-bottom: 10px; background: #fbfcfe; }
.sc-bank-head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; } .sc-bank-head strong { display: block; color: var(--sc-ink); } .sc-bank-head small { color: var(--sc-sub); font-size: .82rem; }
.sc-bank dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: .9rem; align-items: center; } .sc-bank dt { color: var(--sc-sub); } .sc-bank dd { margin: 0; display: flex; align-items: center; gap: 8px; justify-content: space-between; min-width: 0; word-break: break-word; }
.sc-copy { border: 1px solid var(--sc-line); background: #fff; color: var(--sc-sub); border-radius: 8px; padding: 4px 8px; font: inherit; font-size: .76rem; font-weight: 600; cursor: pointer; display: inline-flex; align-items: center; gap: 4px; flex: none; transition: color .15s, border-color .15s; }
.sc-copy:hover { color: var(--sc-brand); border-color: var(--sc-brand-m); } .sc-copy.is-done { color: var(--sc-ok); border-color: #bfe7d4; }

/* Opciones tipo tarjeta (radio) */
.sc-radio { display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 560px) { .sc-radio { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); } }
.sc-radio label { position: relative; display: block; border: 1.5px solid var(--sc-line); border-radius: 14px; padding: 14px 16px 14px 46px; cursor: pointer; font-weight: 500; background: #fff; transition: border-color .15s, background .15s, box-shadow .15s; line-height: 1.4; }
.sc-radio label:hover { border-color: color-mix(in srgb, var(--sc-line) 40%, var(--sc-brand)); }
.sc-radio input { position: absolute; left: 16px; top: 16px; margin: 0; }
.sc-radio label strong { color: var(--sc-ink); } .sc-radio label .sc-muted { font-size: .86rem; }
.sc-radio label:has(input:checked) { border-color: var(--sc-brand); background: var(--sc-brand-l); box-shadow: 0 0 0 3px var(--sc-brand-l); }
.sc-radio .sc-chip { margin-top: 6px; }

/* Acceso: inicio de sesión, registro y recuperación */
.sc-auth { display: grid; grid-template-columns: 1fr; min-height: calc(100vh - 64px); min-height: calc(100dvh - 64px); }
.sc-auth-main { display: flex; flex-direction: column; justify-content: center; padding: 28px 20px 40px; width: 100%; max-width: 460px; margin: 0 auto; }
.sc-auth--wide .sc-auth-main { max-width: 560px; }
.sc-auth-main h1 { font-size: 1.7rem; margin-bottom: 6px; } .sc-auth-main > p.sc-muted { margin-bottom: 24px; }
.sc-auth-mark { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--sc-brand-l); color: var(--sc-brand); font-size: 1.5rem; margin-bottom: 18px; }
.sc-auth-alt { text-align: center; color: var(--sc-sub); margin: 22px 0 0; font-size: .93rem; } .sc-auth-alt a { font-weight: 600; }
.sc-auth-aside { display: none; }
.sc-or { display: flex; align-items: center; gap: 12px; color: var(--sc-faint); font-size: .8rem; margin: 18px 0; } .sc-or::before, .sc-or::after { content: ''; flex: 1; height: 1px; background: var(--sc-line); }
.sc-more { border: 1px solid var(--sc-line); border-radius: 14px; margin-bottom: 16px; background: #fbfcfe; } .sc-more > summary { list-style: none; cursor: pointer; padding: 14px 16px; font-weight: 600; font-size: .92rem; display: flex; align-items: center; gap: 8px; color: var(--sc-ink); } .sc-more > summary::-webkit-details-marker { display: none; }
.sc-more > summary .ph-caret-down { margin-left: auto; transition: transform .2s; color: var(--sc-sub); } .sc-more[open] > summary .ph-caret-down { transform: rotate(180deg); } .sc-more > div { padding: 0 16px 4px; }
@media (min-width: 960px) {
  .sc-auth { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .sc-auth-main { padding: 56px 40px; }
  .sc-auth-aside { display: flex; flex-direction: column; justify-content: center; padding: 56px; background: var(--sc-brand-l); border-left: 1px solid var(--sc-line); position: relative; overflow: hidden; }
  .sc-auth-aside h2 { font-size: 1.7rem; max-width: 440px; } .sc-auth-aside > p { color: var(--sc-sub); max-width: 440px; }
  .sc-auth-aside ul { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 14px; max-width: 440px; }
  .sc-auth-aside li { display: flex; gap: 12px; align-items: flex-start; } .sc-auth-aside li strong { display: block; color: var(--sc-ink); } .sc-auth-aside li span { color: var(--sc-sub); font-size: .92rem; }
}

/* Panel de clientes */
.sc-account { display: grid; grid-template-columns: 1fr; gap: 0; padding: 0 0 48px; align-items: start; }
.sc-side { display: none; }
.sc-subnav { position: sticky; top: var(--sc-top, 56px); z-index: 20; margin: 0 -16px 18px; padding: 10px 16px; background: color-mix(in srgb, var(--sc-bg) 92%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--sc-line); display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.sc-subnav::-webkit-scrollbar { display: none; }
.sc-subnav a { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 99px; font-weight: 600; font-size: .86rem; color: var(--sc-sub) !important; white-space: nowrap; text-decoration: none !important; background: #fff; border: 1px solid var(--sc-line); }
.sc-subnav a.is-on { background: var(--sc-ink); border-color: var(--sc-ink); color: #fff !important; }
.sc-account > section { min-width: 0; padding-top: 4px; }
@media (min-width: 960px) {
  .sc-account { grid-template-columns: 248px minmax(0, 1fr); gap: 32px; padding: 32px 0 80px; }
  .sc-subnav { display: none; }
  .sc-side { display: block; background: #fff; border: 1px solid var(--sc-line); border-radius: 18px; padding: 10px; position: sticky; top: 88px; box-shadow: var(--sc-shadow); }
  .sc-side a, .sc-side button { display: flex; width: 100%; gap: 12px; align-items: center; padding: 10px 12px; border-radius: 10px; color: var(--sc-sub) !important; font: inherit; font-weight: 500; font-size: .93rem; text-decoration: none !important; background: none; border: 0; cursor: pointer; text-align: left; transition: background .12s, color .12s; }
  .sc-side a .ph, .sc-side button .ph { font-size: 1.2rem; }
  .sc-side a:hover, .sc-side button:hover { background: #f4f6fa; color: var(--sc-ink) !important; }
  .sc-side a.is-on { background: var(--sc-brand-l); color: var(--sc-brand) !important; font-weight: 600; }
  .sc-side hr { border: 0; border-top: 1px solid var(--sc-line); margin: 8px 4px; }
  .sc-account > section { padding-top: 0; }
}
.sc-who { display: flex; gap: 12px; align-items: center; padding: 8px 10px 14px; margin-bottom: 6px; border-bottom: 1px solid var(--sc-line); } .sc-who > div { min-width: 0; } .sc-who strong { display: block; color: var(--sc-ink); } .sc-who small { display: block; color: var(--sc-sub); font-size: .8rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sc-avatar { width: 40px; height: 40px; border-radius: 50%; background: linear-gradient(135deg, var(--sc-brand), color-mix(in srgb, var(--sc-brand) 55%, var(--w-accent, #7a4dff))); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: .9rem; flex: none; letter-spacing: .02em; }
.sc-hello { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; } .sc-hello h1 { font-size: clamp(1.4rem, 5vw, 1.9rem); margin: 0 0 2px; } .sc-hello p { margin: 0; color: var(--sc-sub); }
.sc-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-bottom: 16px; }
.sc-stat { background: #fff; border: 1px solid var(--sc-line); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; gap: 10px; color: inherit !important; text-decoration: none !important; box-shadow: var(--sc-shadow-sm); transition: border-color .15s, box-shadow .15s; }
a.sc-stat:hover { border-color: var(--sc-brand-m); box-shadow: var(--sc-shadow); }
.sc-stat div > span { color: var(--sc-sub); font-size: .82rem; } .sc-stat strong { display: block; font-size: 1.45rem; color: var(--sc-ink); letter-spacing: -.03em; line-height: 1.1; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (min-width: 720px) { .sc-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 20px; } .sc-stat { padding: 18px; } .sc-stat strong { font-size: 1.7rem; } }
.sc-next { display: flex; gap: 14px; align-items: center; padding: 16px 18px; border-radius: 18px; background: var(--sc-ink); color: #fff; margin-bottom: 16px; flex-wrap: wrap; }
.sc-next > .ph { font-size: 1.6rem; color: #ffd27a; flex: none; } .sc-next > div { flex: 1; min-width: 200px; } .sc-next strong { display: block; } .sc-next span { color: rgba(255, 255, 255, .75); font-size: .9rem; }
.sc-next .sc-btn { background: #fff; color: var(--sc-ink) !important; border-color: #fff; } .sc-next .sc-btn:hover { background: #eef1f6; }
.sc-quick { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-bottom: 16px; }
.sc-quick a { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 14px 6px; border-radius: 16px; background: #fff; border: 1px solid var(--sc-line); color: var(--sc-ink) !important; font-size: .78rem; font-weight: 600; text-align: center; text-decoration: none !important; line-height: 1.2; transition: border-color .15s, transform .1s; }
.sc-quick a:active { transform: scale(.97); } .sc-quick a:hover { border-color: var(--sc-brand-m); } .sc-quick .ph { font-size: 1.4rem; color: var(--sc-brand); }
@media (min-width: 960px) { .sc-quick { display: none; } }
.sc-kv { display: grid; grid-template-columns: 1fr; gap: 0; margin: 0; } .sc-kv dt { color: var(--sc-sub); font-size: .82rem; padding-top: 10px; } .sc-kv dd { margin: 0; word-break: break-word; padding-bottom: 10px; border-bottom: 1px solid var(--sc-line-2); color: var(--sc-ink); } .sc-kv dd:last-of-type { border-bottom: 0; }
@media (min-width: 640px) { .sc-kv { grid-template-columns: 180px 1fr; } .sc-kv dt, .sc-kv dd { padding: 11px 0; border-bottom: 1px solid var(--sc-line-2); } .sc-kv dt:last-of-type { border-bottom: 0; } }
.sc-svc { display: flex; flex-direction: column; gap: 14px; }
.sc-svc-top { display: flex; gap: 14px; align-items: center; } .sc-svc-top > div { flex: 1; min-width: 0; } .sc-svc-top h3 { margin: 0 0 2px; } .sc-svc-top small { color: var(--sc-sub); display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sc-svc-actions { display: flex; gap: 8px; flex-wrap: wrap; } .sc-svc-actions .sc-btn, .sc-svc-actions form { flex: 1; } .sc-svc-actions form .sc-btn { width: 100%; }
@media (min-width: 640px) { .sc-svc-actions .sc-btn, .sc-svc-actions form { flex: none; } }

/* Mensajes de soporte (tipo chat) */
.sc-thread { display: flex; flex-direction: column; gap: 12px; margin-bottom: 18px; }
.sc-msg { max-width: 92%; border: 1px solid var(--sc-line); border-radius: 18px 18px 18px 6px; padding: 12px 16px; background: #fff; align-self: flex-start; box-shadow: var(--sc-shadow-sm); }
.sc-msg.is-mine { align-self: flex-end; border-radius: 18px 18px 6px 18px; background: var(--sc-brand-l); border-color: var(--sc-brand-m); }
.sc-msg.is-staff { background: #fff; } .sc-msg.is-internal { background: var(--sc-warn-l); border-color: #f1dca4; }
.sc-msg header { display: flex; justify-content: space-between; gap: 12px; font-size: .8rem; color: var(--sc-sub); margin-bottom: 4px; } .sc-msg header strong { color: var(--sc-ink); }
.sc-msg-body { white-space: pre-wrap; word-break: break-word; }
.sc-msg-file { display: inline-flex; align-items: center; gap: 6px; margin-top: 10px; padding: 6px 10px; border-radius: 10px; background: rgba(255, 255, 255, .7); border: 1px solid var(--sc-line); font-size: .86rem; font-weight: 600; }
@media (min-width: 720px) { .sc-msg { max-width: 78%; } }
.sc-progress { height: 8px; border-radius: 99px; background: #e9edf5; overflow: hidden; } .sc-progress i { display: block; height: 100%; background: var(--sc-brand); border-radius: inherit; }

/* Contacto */
.sc-channels { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 640px) { .sc-channels { grid-template-columns: 1fr 1fr; } }
.sc-channel { display: flex; align-items: center; gap: 14px; padding: 16px 18px; border: 1px solid var(--sc-line); border-radius: 16px; background: #fff; color: inherit !important; text-decoration: none !important; box-shadow: var(--sc-shadow-sm); transition: border-color .15s, box-shadow .15s, transform .1s; }
.sc-channel:hover { border-color: var(--sc-brand-m); box-shadow: var(--sc-shadow); } .sc-channel:active { transform: scale(.99); }
.sc-channel > div { flex: 1; min-width: 0; } .sc-channel strong { display: block; color: var(--sc-ink); } .sc-channel span { color: var(--sc-sub); font-size: .88rem; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sc-channel > .ph-arrow-up-right, .sc-channel > .ph-caret-right { color: var(--sc-faint); font-size: 1.1rem; }

/* Notificaciones flotantes (copiado, etc.) */
.sc-toast { position: fixed; left: 50%; bottom: calc(96px + env(safe-area-inset-bottom)); transform: translate(-50%, 12px); background: var(--sc-ink, #0c1633); color: #fff; padding: 10px 16px; border-radius: 12px; font-size: .88rem; font-weight: 600; z-index: 80; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; display: flex; align-items: center; gap: 8px; box-shadow: 0 12px 30px -8px rgba(0, 0, 0, .35); }
.sc-toast.is-on { opacity: 1; transform: translate(-50%, 0); }

@media print { .sc-header, .sc-footer, .sc-side, .sc-subnav, .sc-wa, .sc-tabbar, .sc-mbar, .sc-mbar-space, .no-print { display: none !important; } body.sc { background: #fff; } .sc-card { box-shadow: none; border: 0; } }
@media (prefers-reduced-motion: reduce) { .sc *, .sc *::before, .sc *::after { transition: none !important; animation: none !important; } }
[hidden] { display: none !important; }
