/* ============================================================================
   Baqqo para Restaurantes · panel · Fase 3: Soporte, Mi cuenta, modales y menú «…» (design.md §4; mockups elegidos
   1=A, 2=A, 3=A, 4=A, 5=B, 6=A, 7=A, 8=B, 9=B, 10=A+a). Solo tokens --bq2-*; los únicos colores fijos son los tonos
   semánticos suaves que ya usa admin-bq2.css (aviso, correcto, error). Se carga después de admin-bq2.css.
   ============================================================================ */
.sr-only { position: absolute; top: 0; left: 0; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.i16 { width: 16px; height: 16px; flex: 0 0 16px; }
.i18 { width: 18px; height: 18px; flex: 0 0 18px; }
.i20 { width: 20px; height: 20px; flex: 0 0 20px; }
.nowrap { white-space: nowrap; }
.tnum, .num { font-variant-numeric: tabular-nums; }

/* ── Menú: punto de aviso en Soporte ── */
.nav-item { position: relative; }
.nav-dot { position: absolute; top: 9px; left: 27px; width: 9px; height: 9px; border-radius: 50%; background: var(--bq2-accent); box-shadow: 0 0 0 2px var(--bq2-bg); pointer-events: none; }

/* ── Menú «…» (solo móvil) ── */
.nav-more-btn { display: none; }
.nav-more-btn[hidden] { display: none !important; }
.nav-more, .nav-more-ov { display: none; }
@media (max-width: 760px) {
  /* Con «…», la píldora usa el botón del diseño (46 px; 42 px a ≤ 360) en vez de repartir el ancho entre 8. */
  .side .nav-item, .side .side__thumb { width: 46px; height: 46px; }
  .side .side__divider[data-ovf] { display: none; }
  .side .nav-more-btn { display: flex; align-items: center; justify-content: center; border: 0; background: transparent; color: var(--bq2-ink); cursor: pointer; font: inherit; }
  .side .nav-more-btn .ic { color: currentColor; }
  .side .nav-more-btn.on, .side .nav-more-btn.on .ic { color: var(--bq2-accent); }
  .side .nav-more-btn[aria-expanded="true"] { background: var(--bq2-ink); color: var(--bq2-bg-elev); }
  .side .nav-more-btn[aria-expanded="true"] .ic { color: currentColor; }
  .nav-more-pip { display: none; position: absolute; bottom: 7px; left: 50%; width: 5px; height: 5px; margin-left: -2.5px; border-radius: 50%; background: var(--bq2-accent); }
  .nav-more-btn.has-active .nav-more-pip { display: block; }
  .nav-item:focus-visible { outline: 2px solid var(--bq2-accent); outline-offset: 2px; }
  .nav-dot { top: 8px; left: auto; right: 8px; }

  /* La hoja: anclada encima de la píldora, se despliega HACIA ARRIBA */
  .nav-more-ov { display: block; position: fixed; inset: 0; z-index: 140; background: rgba(28, 23, 20, .32); opacity: 0; transition: opacity .18s var(--bq2-ease); }
  .nav-more-ov.is-open { opacity: 1; }
  .nav-more { display: block; position: fixed; left: 12px; right: 12px; bottom: calc(82px + env(safe-area-inset-bottom, 0px)); z-index: 160;
    max-height: calc(100dvh - 120px); overflow-y: auto; overscroll-behavior: contain; box-sizing: border-box;
    background: var(--bq2-bg-elev); border: 1px solid var(--bq2-line); border-radius: 24px; box-shadow: var(--bq2-shadow-lg); padding: 8px;
    opacity: 0; transform: translateY(12px); transition: opacity .18s var(--bq2-ease), transform .18s var(--bq2-ease); }
  .nav-more.is-open { opacity: 1; transform: none; }
  .nav-more[hidden], .nav-more-ov[hidden] { display: none; }
  .nav-more:focus { outline: none; }
  .nav-more__t { margin: 6px 10px; font-size: .72rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--bq2-ink-faint); }
  .nav-more__list { display: grid; gap: 2px; }
  #nav-more .nav-item, .nav-more__proxy, #nav-more .side__logout {
    position: relative; width: 100%; height: auto; min-height: 48px; display: flex; align-items: center; justify-content: flex-start; gap: 14px; padding: 0 12px;
    border: 0; border-radius: 14px; background: transparent; color: var(--bq2-ink); font: inherit; font-size: .98rem; font-weight: 600;
    text-align: left; text-decoration: none; cursor: pointer; box-sizing: border-box; margin: 0; }
  #nav-more .nav-item:hover, .nav-more__proxy:hover, #nav-more .side__logout:hover { background: var(--bq2-bg-sunken); }
  #nav-more .nav-item:focus-visible, .nav-more__proxy:focus-visible, #nav-more .side__logout:focus-visible { outline: 2px solid var(--bq2-accent); outline-offset: -2px; }
  #nav-more .ic, .nav-more__proxy .ic { width: 22px; height: 22px; flex: 0 0 22px; color: var(--bq2-accent); }
  #nav-more .nav-item__label { position: static; width: auto; height: auto; overflow: visible; clip: auto; white-space: normal; }
  #nav-more .nav-item.on, .nav-more__proxy.on { background: var(--bq2-accent-soft); color: var(--bq2-accent); }
  .nav-more__proxy { color: var(--bq2-ink-soft); }
  #nav-more .nav-dot { position: static; margin-left: auto; box-shadow: none; }
  .nav-more__sep { height: 1px; margin: 6px 10px; background: var(--bq2-line); }
  #nav-more .side__logout { color: var(--bq2-ink-soft); font-size: .9rem; display: flex; }
}
@media (max-width: 360px) {
  .side .nav-item, .side .side__thumb { width: 42px; height: 42px; }
  .nav-more { left: 8px; right: 8px; bottom: calc(74px + env(safe-area-inset-bottom, 0px)); }
}
@media (prefers-reduced-motion: reduce) {
  .nav-more, .nav-more.is-open { transform: none; transition: opacity .01s; }
  .nav-more-ov { transition: none; }
}

/* ════════════ SOPORTE ════════════ */
.sup { display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr); }
.sup > * { min-width: 0; }
.sup--cols { grid-template-columns: minmax(0, 1.45fr) minmax(320px, 1fr); align-items: start; }
.sup--cols .tk-side { position: sticky; top: 20px; }
.seg button .n { display: inline-grid; place-items: center; min-width: 20px; height: 20px; margin-left: 6px; padding: 0 6px; border-radius: 999px;
  background: var(--bq2-bg-sunken); color: var(--bq2-ink-soft); font-size: .72rem; font-weight: 800; }
.seg button .n[hidden] { display: none; }
.seg button.on .n { background: rgba(255, 255, 255, .2); color: inherit; }
.sup-mseg { display: none; }
@media (max-width: 1100px) { .sup--cols { grid-template-columns: minmax(0, 1fr); } .sup--cols .tk-side { position: static; } }
@media (max-width: 760px) {
  .sup-mseg { display: flex; width: 100%; box-sizing: border-box; margin-bottom: 14px; }
  .sup-mseg button { flex: 1; min-height: 44px; }
  .sup[data-view="chat"] #sup-tk, .sup[data-view="tk"] #sup-chat { display: none; }
}

/* ── Chat del asistente ── */
.chat { display: flex; flex-direction: column; background: var(--bq2-bg-elev); border: 1px solid var(--bq2-line); border-radius: var(--bq2-r-l); overflow: hidden; min-height: 560px; max-height: calc(100dvh - 180px); }
.chat__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--bq2-line); }
.chat__head h2 { margin: 0; font-size: 1.05rem; font-weight: 800; }
.chat__head p { margin: 2px 0 0; font-size: .8rem; color: var(--bq2-ink-soft); }
.chat__head .link-reset { min-height: 44px; flex: none; }
.chat__log { flex: 1; display: flex; flex-direction: column; gap: 14px; padding: 20px; overflow-y: auto; overscroll-behavior: contain; }
.chat__log > * { flex-shrink: 0; }   /* sin esto, las tarjetas se aplastan cuando el hilo llena el alto */
@media (max-width: 760px) {
  /* en móvil el chat crece con la página (sin scroll interno) y la píldora no tapa la caja de texto: .main ya deja hueco abajo */
  .chat { min-height: 0; max-height: none; }
  .chat__log { overflow: visible; padding: 16px; min-height: 260px; }
  .chat__head { padding: 14px 16px; flex-wrap: wrap; }
}
.chat__foot { border-top: 1px solid var(--bq2-line); padding: 12px 14px 14px; display: grid; gap: 8px; background: var(--bq2-bg-elev); }
.chat__quota { margin: 0; font-size: .78rem; color: #8a4f17; font-weight: 700; }   /* el ocre de --bq2-warn no llega a AA en texto pequeño */
.chat__quota[hidden] { display: none; }
.chat__row { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.composer { display: flex; align-items: flex-end; gap: 10px; padding: 6px 6px 6px 16px; border: 1px solid var(--bq2-line); border-radius: 24px; background: var(--bq2-bg); }
.composer:focus-within { border-color: var(--bq2-accent); box-shadow: 0 0 0 2px var(--bq2-accent-soft); }
.composer textarea { flex: 1; min-width: 0; resize: none; border: 0; background: transparent; padding: 10px 0; font: inherit; font-size: .95rem; line-height: 1.4; color: var(--bq2-ink); max-height: 140px; }
.composer textarea:focus { outline: none; }
.composer textarea::placeholder { color: var(--bq2-ink-faint); }
.composer textarea:disabled { cursor: not-allowed; }
.send { flex: none; width: 44px; height: 44px; border-radius: 50%; border: 0; display: grid; place-items: center; background: var(--bq2-accent); color: var(--bq2-accent-ink); cursor: pointer; transition: background .18s, transform .12s; }
.send:hover { background: var(--bq2-accent-deep); }
.send:active { transform: scale(.94); }
.send:focus-visible { outline: 2px solid var(--bq2-accent); outline-offset: 2px; }
.send[disabled] { background: var(--bq2-line); color: var(--bq2-ink-faint); cursor: not-allowed; transform: none; }
.chat__hint { margin: 0; font-size: .74rem; color: var(--bq2-ink-faint); }
.counter { font-size: .74rem; color: var(--bq2-ink-faint); font-variant-numeric: tabular-nums; }
.counter[hidden] { display: none; }

.chat-empty { margin: auto 0; display: grid; gap: 16px; padding: 12px 4px; max-width: 520px; }
.chat-empty__mark { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; background: var(--bq2-accent-soft); color: var(--bq2-accent); }
.chat-empty p { margin: 0; font-size: 1rem; line-height: 1.5; }
.sugg { display: flex; flex-wrap: wrap; gap: 8px; }
.sugg button { min-height: 44px; padding: 8px 14px; border-radius: var(--bq2-r-pill); border: 1.5px solid var(--bq2-line); background: var(--bq2-bg-elev); color: var(--bq2-ink);
  font: inherit; font-size: .86rem; font-weight: 600; cursor: pointer; transition: border-color .18s, transform .18s var(--bq2-ease); }
.sugg button:hover:not(:disabled) { border-color: var(--bq2-accent); transform: translateY(-1px); }
.sugg button:disabled { opacity: .6; cursor: default; }
.sugg button:focus-visible { outline: 2px solid var(--bq2-accent); outline-offset: 2px; }

/* Mensajes · burbujas (2-A) */
.msg { max-width: 82%; font-size: .95rem; line-height: 1.5; overflow-wrap: anywhere; padding: 11px 15px; border-radius: 18px; box-sizing: border-box; }
.msg p { margin: 0; }
.msg p + p, .msg p + ul, .msg ul + p { margin-top: 6px; }
.msg ul { padding-left: 18px; margin: 6px 0 0; }
.msg-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.msg-acts .btn { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; }
.msg--user { align-self: flex-end; background: var(--bq2-accent); color: var(--bq2-accent-ink); border-bottom-right-radius: 6px; }
.msg--bot { align-self: flex-start; background: var(--bq2-bg-sunken); border-bottom-left-radius: 6px; }

.typing { align-self: flex-start; display: inline-flex; align-items: center; gap: 5px; padding: 12px 15px; border-radius: 18px; background: var(--bq2-bg-sunken); }
.typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--bq2-ink-faint); animation: tdot 1.2s infinite ease-in-out; }
.typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }
@keyframes tdot { 0%, 60%, 100% { opacity: .35; transform: translateY(0); } 30% { opacity: 1; transform: translateY(-3px); } }
@media (prefers-reduced-motion: reduce) { .typing i { animation: none; opacity: .7; } }

.chat-off { display: grid; gap: 12px; padding: 18px; border-radius: var(--bq2-r-m); background: var(--bq2-bg-sunken); }
.chat-off b { font-size: .98rem; }
.chat-off p { margin: 0; font-size: .9rem; color: var(--bq2-ink-soft); line-height: 1.45; }

/* Tarjeta de confirmación (3-A) */
.prop { align-self: stretch; max-width: 560px; border: 1px solid var(--bq2-line); border-radius: var(--bq2-r-m); background: var(--bq2-bg-elev); box-shadow: var(--bq2-shadow); overflow: hidden; }
.prop__head { display: flex; align-items: center; gap: 10px; padding: 14px 16px 10px; }
.prop__k { font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; color: var(--bq2-accent); }
.prop__t { margin: 2px 0 0; font-size: 1rem; font-weight: 800; }
.prop__body { padding: 0 16px 14px; display: grid; gap: 10px; }
.prop__mass { justify-self: start; }
.chg { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.chg li { display: grid; gap: 2px; font-size: .92rem; }
.chg__k { font-size: .78rem; font-weight: 700; color: var(--bq2-ink-soft); }
.chg__v { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 8px; }
.chg__old { color: var(--bq2-ink-faint); text-decoration: line-through; }
.chg__arrow { color: var(--bq2-ink-faint); }
.chg__new { font-weight: 800; white-space: pre-wrap; overflow-wrap: anywhere; }
.chg__new.is-long { flex-basis: 100%; font-weight: 600; line-height: 1.45; }
.prop__acts { display: flex; gap: 10px; flex-wrap: wrap; padding: 12px 16px 14px; border-top: 1px solid var(--bq2-line); background: var(--bq2-bg); }
.prop__acts .btn { min-height: 44px; }
.prop__state { display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--bq2-line); font-size: .88rem; font-weight: 700; flex-wrap: wrap; }
.prop__state.is-ok { color: var(--bq2-ok); background: #eef4ee; }
.prop__state.is-muted { color: var(--bq2-ink-soft); background: var(--bq2-bg); }
.prop__state.is-warn { color: #8a4f17; background: #fbf1e6; }
.prop__state.is-err { color: var(--bq2-danger); background: #fbecea; }
.prop__state .btn { margin-left: auto; }
.prop.is-dim .prop__body { opacity: .6; }

/* Oferta de consulta (4-A) */
.offer { align-self: stretch; max-width: 560px; display: grid; gap: 10px; padding: 16px; border-radius: var(--bq2-r-m); border: 1.5px solid var(--bq2-accent-soft); background: #fdf7f5; }
.offer b { font-size: 1rem; }
.offer__type { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; font-size: .86rem; color: var(--bq2-ink-soft); }
.offer__acts { display: flex; gap: 10px; flex-wrap: wrap; }
.offer__acts .btn { min-height: 44px; }
.offer__acts .btn:focus-visible { outline: 2px solid var(--bq2-accent); outline-offset: 2px; }
/* Oferta de acción («Prepáralo», design.md §8): misma tarjeta, acento en el borde izquierdo para distinguirla de la consulta */
.offer--action { border-color: var(--bq2-line); border-left: 3px solid var(--bq2-accent); background: var(--bq2-bg-elev); }
.offer--action b { font-weight: 600; }
/* «Prepáralo» bloqueado mientras la tarjeta del mismo turno esté pendiente: aria-disabled (sigue enfocable, foco visible) */
.offer__acts .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }
.offer__note { margin: 0; font-size: .86rem; color: var(--bq2-ink-soft); }
.plazo { display: inline-flex; align-items: center; gap: 5px; font-size: .8rem; color: var(--bq2-ink-soft); font-weight: 600; }

/* ── Lista de consultas (6-A) ── */
.tk-card { background: var(--bq2-bg-elev); border: 1px solid var(--bq2-line); border-radius: var(--bq2-r-l); overflow: hidden; }
.tk-card__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; padding: 16px 20px 10px; }
.tk-card__head h2 { margin: 0; font-size: 1.05rem; font-weight: 800; }
.tk-card__head .btn { min-height: 40px; }
.tk-filters { padding: 0 20px 12px; border-bottom: 1px solid var(--bq2-line); }
.tk-filters .seg { margin: 0; }
.tk-filters .seg button { min-height: 40px; }
.tk-loading { margin: 0; padding: 20px; color: var(--bq2-ink-soft); font-size: .9rem; }
.tk-rows { list-style: none; margin: 0; padding: 0; }
.tk-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 16px; align-items: center; width: 100%; padding: 14px 20px; border: 0; border-bottom: 1px solid var(--bq2-line);
  background: transparent; font: inherit; color: inherit; text-align: left; cursor: pointer; transition: background .15s; }
.tk-rows li:last-child .tk-row { border-bottom: 0; }
.tk-row:hover { background: var(--bq2-bg); }
.tk-row:focus-visible { outline: 2px solid var(--bq2-accent); outline-offset: -2px; }
.tk-row__t { display: flex; align-items: center; gap: 8px; min-width: 0; }
.tk-row__t b { overflow: hidden; font-size: .95rem; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.tk-row__m { grid-column: 1; display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: .8rem; color: var(--bq2-ink-soft); min-width: 0; }
.tk-row__p { grid-column: 1; font-size: .84rem; color: var(--bq2-ink-soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.tk-row__r { grid-column: 2; grid-row: 1 / span 3; display: grid; justify-items: end; gap: 6px; }
.tk-row__d { font-size: .76rem; color: var(--bq2-ink-faint); white-space: nowrap; }
.ref { font-variant-numeric: tabular-nums; letter-spacing: .02em; color: var(--bq2-ink-faint); font-weight: 600; }
.udot { flex: none; width: 9px; height: 9px; border-radius: 50%; background: var(--bq2-accent); }
.flag { display: inline-flex; align-items: center; gap: 6px; font-size: .76rem; font-weight: 800; white-space: nowrap; }
.flag--reply { color: var(--bq2-accent); }
.flag--wait { color: #8a4f17; }
.tag.st-curso { background: var(--bq2-bg-sunken); color: var(--bq2-ink); }
.tag.st-wait { background: #fbf1e6; color: #8a4f17; }
.tag.st-ok { background: #e9f1e9; color: #3d6340; }
.tag.st-closed { background: var(--bq2-bg-sunken); color: var(--bq2-ink-soft); }
.tk-empty { padding: 28px 20px; display: grid; gap: 12px; justify-items: start; }
.tk-empty p { margin: 0; color: var(--bq2-ink-soft); line-height: 1.5; max-width: 420px; }
@media (max-width: 760px) {
  .tk-row { padding: 14px 16px; grid-template-columns: minmax(0, 1fr); }
  .tk-row__r { grid-column: 1; grid-row: auto; justify-items: start; grid-auto-flow: column; justify-content: start; align-items: center; gap: 10px; }
  .tk-card__head { padding: 14px 16px 10px; }
  .tk-filters { padding: 0 16px 12px; }
}

/* ── Detalle de consulta (7-A) ── */
.tkd__head { padding: 18px 22px; border-bottom: 1px solid var(--bq2-line); display: grid; gap: 8px; }
.tkd__back { justify-self: start; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; }
.tkd__head h2 { margin: 0; font-size: 1.2rem; font-weight: 800; overflow-wrap: anywhere; }
.tkd__head h2:focus { outline: none; }
.tkd__meta { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; font-size: .82rem; color: var(--bq2-ink-soft); }
.thread { padding: 20px 22px; display: flex; flex-direction: column; gap: 14px; max-height: 520px; overflow-y: auto; overscroll-behavior: contain; }
.tm { max-width: 82%; display: grid; gap: 4px; }
.tm__who { font-size: .74rem; font-weight: 700; color: var(--bq2-ink-faint); }
.tm__who b { color: var(--bq2-ink-soft); }
.tm__who span::before { content: " · "; }
.tm__b { font-size: .93rem; line-height: 1.5; overflow-wrap: anywhere; padding: 11px 15px; }
.tm__b p { margin: 0; } .tm__b p + p { margin-top: 6px; }
.tm--me { align-self: flex-end; justify-items: end; }
.tm--me .tm__b { background: var(--bq2-accent); color: var(--bq2-accent-ink); border-radius: 18px 18px 6px 18px; }
.tm--bq { align-self: flex-start; }
.tm--bq .tm__b { background: var(--bq2-bg-sunken); border-radius: 18px 18px 18px 6px; }
.tm-sys { align-self: center; font-size: .76rem; color: var(--bq2-ink-faint); padding: 4px 12px; border-radius: var(--bq2-r-pill); background: var(--bq2-bg); border: 1px solid var(--bq2-line); text-align: center; }
.reply { padding: 16px 22px 20px; border-top: 1px solid var(--bq2-line); display: grid; gap: 10px; }
.reply textarea { min-height: 90px; font: inherit; padding: 12px 14px; border-radius: var(--bq2-r-s); border: 1px solid var(--bq2-line); background: var(--bq2-bg); color: var(--bq2-ink); resize: vertical; box-sizing: border-box; width: 100%; }
.reply textarea:focus-visible { outline: 2px solid var(--bq2-accent); outline-offset: 1px; }
.reply__acts { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; }
.reply__note { margin: 0; font-size: .82rem; color: var(--bq2-ink-soft); }
.closed-note { margin: 0; padding: 18px 22px 20px; border-top: 1px solid var(--bq2-line); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; background: var(--bq2-bg); }
.closed-note p { margin: 0; color: var(--bq2-ink-soft); font-size: .9rem; }
.field-err[hidden], .inline-warn[hidden] { display: none; }
@media (max-width: 760px) {
  .tkd__head, .thread, .reply { padding-left: 16px; padding-right: 16px; }
  .tm { max-width: 92%; }
  .reply__acts .btn { flex: 1 1 100%; }
  .thread { max-height: none; }
}

/* ── Modales de la Fase 3 (consulta y baja): diálogo centrado; en móvil, hoja inferior ── */
.dlg { position: relative; width: min(620px, 100%); max-height: calc(100dvh - 32px); overflow-y: auto; background: var(--bq2-bg-elev); border-radius: var(--bq2-r-m); box-shadow: var(--bq2-shadow-lg);
  padding: 22px 24px 20px; box-sizing: border-box; overscroll-behavior: contain; display: grid; gap: 16px; outline: none; }
.dlg__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.dlg__head h2 { margin: 0; font-size: 1.2rem; font-weight: 800; }
.dlg__head p { margin: 4px 0 0; color: var(--bq2-ink-soft); font-size: .9rem; line-height: 1.45; }
.dlg__x { flex: none; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--bq2-line); background: var(--bq2-bg-elev); color: var(--bq2-ink); display: grid; place-items: center; cursor: pointer; }
.dlg__x:hover { border-color: var(--bq2-ink); }
.dlg__x:focus-visible { outline: 2px solid var(--bq2-accent); outline-offset: 2px; }
.dlg__acts { display: flex; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }
.dlg__acts .btn { min-height: 44px; }
.dlg__note { margin: 0; font-size: .82rem; color: var(--bq2-ink-soft); line-height: 1.45; padding: 10px 12px; border-radius: var(--bq2-r-s); background: var(--bq2-bg-sunken); }
.dlg__steps { display: block; font-size: .74rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--bq2-ink-faint); margin-bottom: 2px; }
.ai-fill { display: inline-flex; align-items: center; gap: 6px; justify-self: start; padding: 4px 10px; border-radius: var(--bq2-r-pill); background: var(--bq2-accent-soft); color: var(--bq2-accent); font-size: .76rem; font-weight: 700; }
.ai-fill[hidden], .sel-plazo[hidden] { display: none; }
.dlg .field textarea { resize: vertical; min-height: 150px; line-height: 1.45; }
.field__row { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.dlg .field input, .dlg .field select, .dlg .field textarea { min-height: 46px; box-sizing: border-box; }
.dlg .field select { appearance: auto; background-color: var(--bq2-bg); color: var(--bq2-ink); }
.dlg .field textarea[aria-invalid="true"], .dlg .field select[aria-invalid="true"] { border-color: var(--bq2-danger); }
.sel-plazo { margin: 0; display: flex; gap: 8px; align-items: center; font-size: .82rem; color: var(--bq2-ink-soft); padding: 8px 12px; border-radius: var(--bq2-r-s); background: var(--bq2-bg-sunken); }
.sel-plazo b { color: var(--bq2-ink); }
fieldset.field { border: 0; padding: 0; margin: 0; min-width: 0; }
fieldset.field legend { font-weight: 600; font-size: .85rem; color: var(--bq2-ink-soft); padding: 0; margin-bottom: 7px; }
@media (max-width: 760px) {
  .sheet-ov { padding: 0; place-items: end stretch; }
  .sheet-ov .dlg { width: 100%; max-height: calc(100dvh - 40px); border-radius: 22px 22px 0 0; padding: 10px 16px calc(16px + env(safe-area-inset-bottom, 0px)); gap: 14px; }
  .sheet-ov .dlg::before { content: ""; justify-self: center; width: 40px; height: 4px; border-radius: 4px; background: var(--bq2-line); }
  .sheet-ov .dlg__acts { position: sticky; bottom: 0; background: var(--bq2-bg-elev); padding-top: 6px; }
  .sheet-ov .dlg__acts .btn { flex: 1 1 100%; }
}

/* ════════════ MI CUENTA (8-B, 9-B) ════════════ */
.acc { display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr); }
.acc > * { min-width: 0; }
.acc > div:empty { display: none; }
.acc .card { margin-bottom: 0; }
.sub { padding: 20px 22px; display: grid; gap: 14px; }
.sub__plan { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; }
.sub__plan b { font-size: 1.35rem; font-weight: 800; letter-spacing: -0.01em; }
.sub__txt { margin: 0; font-size: .95rem; line-height: 1.5; color: var(--bq2-ink); max-width: 620px; }
.sub__txt--soft { color: var(--bq2-ink-soft); font-size: .88rem; }
.sub__acts { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; }
.sub__acts:empty { display: none; }
.sub__acts .btn, .sub__acts .link-reset { min-height: 44px; }
.sub-note { padding: 12px 14px; border-radius: var(--bq2-r-m); font-size: .9rem; line-height: 1.45; }
.sub-note--warn { background: #fbf1e6; color: #6e3f12; }
.sub-note--info { background: var(--bq2-bg-sunken); color: var(--bq2-ink); }
.sub-note--muted { background: var(--bq2-bg-sunken); color: var(--bq2-ink-soft); }
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.plan-opt { position: relative; display: grid; gap: 4px; padding: 14px 14px 14px 42px; border: 1.5px solid var(--bq2-line); border-radius: var(--bq2-r-m); cursor: pointer; min-height: 44px; }
.plan-opt input { position: absolute; left: 14px; top: 16px; width: 18px; height: 18px; margin: 0; accent-color: var(--bq2-accent); }
.plan-opt input:focus-visible { outline: 2px solid var(--bq2-accent); outline-offset: 2px; }
.plan-opt:has(input:checked) { border-color: var(--bq2-accent); background: #fdf7f5; }
.plan-opt b { font-size: .95rem; }
.plan-opt span { font-size: .84rem; color: var(--bq2-ink-soft); }
.plan-opt small { font-size: .76rem; color: var(--bq2-ink-faint); }
.inv-scroll { position: relative; overflow-x: auto; overscroll-behavior-x: contain; }   /* relative: los .sr-only absolutos no escapan del scroll y ensanchan la página */
.inv-tb { width: 100%; border-collapse: collapse; font-size: .9rem; }
.inv-tb th { text-align: left; font-size: .72rem; font-weight: 800; letter-spacing: .03em; text-transform: uppercase; color: var(--bq2-ink-faint); padding: 10px 22px; border-bottom: 1px solid var(--bq2-line); }
.inv-tb td { padding: 12px 22px; border-bottom: 1px solid var(--bq2-line); white-space: nowrap; }
.inv-tb tr:last-child td { border-bottom: 0; }
.inv-tb .num { text-align: right; }
.inv-tb a { display: inline-flex; align-items: center; min-height: 44px; color: var(--bq2-accent); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--bq2-accent-soft); }
.inv-tb a:hover { text-decoration-color: var(--bq2-accent); }
.inv-tb a:focus-visible { outline: 2px solid var(--bq2-accent); outline-offset: 2px; border-radius: 4px; }
.inv-tb a + a { margin-left: 14px; }
.inv-tb td:last-child { padding-top: 0; padding-bottom: 0; }
.bye { padding: 6px 2px 0; border-top: 1px solid var(--bq2-line); display: grid; gap: 6px; justify-items: start; }
.bye p { margin: 0; font-size: .86rem; color: var(--bq2-ink-soft); max-width: 560px; line-height: 1.45; padding-top: 10px; }
.bye .link-reset { font-size: .9rem; color: var(--bq2-ink-soft); padding: 8px 0; min-height: 44px; }
.bye .link-reset:hover { color: var(--bq2-danger); }
.reasons { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 14px; }
.reasons .chk { min-height: 44px; }
.inline-warn { margin: 6px 0 0; font-size: .8rem; color: #8a4f17; font-weight: 600; }
.bye-sum { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.bye-sum li { display: grid; grid-template-columns: 22px 1fr; gap: 10px; font-size: .92rem; line-height: 1.45; }
.bye-sum li span:first-child { width: 22px; height: 22px; border-radius: 50%; background: var(--bq2-bg-sunken); display: grid; place-items: center; font-size: .74rem; font-weight: 800; color: var(--bq2-ink-soft); }
@media (max-width: 760px) {
  .plans, .reasons { grid-template-columns: minmax(0, 1fr); }
  .sub { padding: 16px; }
  .inv-tb th, .inv-tb td { padding-left: 16px; padding-right: 16px; }
  .sub__acts .btn { flex: 1 1 100%; }
}
