:root { --bg: #f6f6f4; --card: #fff; --text: #1a1a1a; --muted: #666; --line: #e2e2de; --accent: #c2185b; }
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; font: 15px/1.4 system-ui, sans-serif; background: var(--bg); color: var(--text); }
button { font: inherit; color: inherit; cursor: pointer; border: 1px solid var(--line); background: var(--card); border-radius: 8px; padding: 6px 12px; }
button:disabled { opacity: .4; cursor: default; }
.primary { background: var(--accent); color: var(--accent-text, #fff); border-color: var(--accent); }
.top { position: sticky; top: 0; z-index: 1; background: #111; color: #fff; padding: 10px 16px; display: flex; gap: 16px; align-items: center; overflow-x: auto; }
.top a { color: #fff; text-decoration: none; white-space: nowrap; opacity: .85; }
.layout { padding: 16px; max-width: 1200px; margin: auto; }
@media (max-width: 800px) { .layout { grid-template-columns: 1fr; } }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 12px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
.prod { display: flex; flex-direction: column; gap: 4px; text-align: left; padding: 12px; }
.prod small, .muted { color: var(--muted); }
.line { border-bottom: 1px solid var(--line); padding: 8px 0; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
label.row + label.row { margin-top: 10px; } /* interruptores en lista (Menús, Canales, Caja…): que no queden pegados en el celular */
.spread { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
dialog { border: none; border-radius: 14px; width: min(520px, 94vw); padding: 18px; }
fieldset { border: 1px solid var(--line); border-radius: 10px; margin: 10px 0; }
.opt { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 6px 0; }
/* Texto largo: baja de línea y los botones quedan siempre en su columna, sin partirse */
.opt > span:first-child { flex: 1; min-width: 0; }
.opt > span:first-child .muted { white-space: nowrap; }
.opt > .row { flex: none; flex-wrap: nowrap; gap: 4px; align-items: center; }
.opt > .row button { width: 34px; height: 34px; padding: 0; display: grid; place-items: center; flex: none; font-size: 18px; line-height: 1; }
.opt > input { flex: none; }
label.field { display: block; margin: 8px 0; }
.ojito { display: block; position: relative; }
.field .ojito input { padding-right: 44px; }
.vidrio .ojito button, .vidrio .ojito button:hover:not(:disabled) { position: absolute; top: 50%; right: 2px; transform: translateY(-50%); width: 40px; height: 40px; padding: 0; border: 0; background: transparent; color: var(--muted); display: grid; place-items: center; }
label.field input, label.field select { width: 100%; padding: 8px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
.error { color: #b00020; }
/* Las columnas se acomodan al espacio (3, 2 o 1) en vez de esconderse detrás del panel de Nuevo pedido. */
.board { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 12px; padding: 16px; align-items: start; }
.board > section { min-width: 0; }
.board h2 { margin: 0 0 8px; font-size: 16px; }
.order { margin-bottom: 10px; }
.badge { font-size: 12px; padding: 2px 8px; border-radius: 99px; background: #eee; }

button.mini { padding: 2px 8px; }
.pane { max-width: 960px; padding: 16px; }

/* Pestañas */
.tabs { display: flex; gap: 2px; flex-wrap: wrap; }
.tabs button, .tabs a { text-decoration: none; border: 0; background: transparent; border-radius: 0; padding: 8px 12px; border-bottom: 2px solid transparent; color: var(--muted); }
.tabs button.on, .tabs a.on { color: var(--text); border-bottom-color: var(--accent); font-weight: 600; }
/* Lo que muestra un «Ir a …» de SAM: queda marcado unos segundos (shell.js showPlace). */
.aqui { animation: aqui 3s ease-out; border-radius: 6px; }
@keyframes aqui { 0%, 70% { outline: 3px solid var(--accent); outline-offset: 4px; } 100% { outline: 3px solid transparent; outline-offset: 4px; } }
.tabs.sub { border-bottom: 1px solid var(--line); margin-bottom: 12px; }

/* Lista a la izquierda, detalle a la derecha (como Justo) */
.md { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 16px; padding: 16px; align-items: start; }
.md-list { background: var(--card); border: 1px solid var(--line); border-radius: 12px; display: flex; flex-direction: column;
  height: calc(100vh - 100px); position: sticky; top: 16px; }
.md-tools { display: flex; flex-direction: column; gap: 6px; padding: 10px; border-bottom: 1px solid var(--line); }
.md-tools input, .md-tools select, .md-new input { padding: 8px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
.md-items { overflow: auto; flex: 1; }
.md-head { padding: 8px 12px 4px; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.md-item { display: flex; gap: 10px; align-items: center; width: 100%; text-align: left; border: 0; border-bottom: 1px solid var(--line);
  border-radius: 0; padding: 8px 12px; background: transparent; }
.md-item:hover { background: #f7f7f4; }
.md-item.on { background: #fde7ef; box-shadow: inset 3px 0 0 var(--accent); }
.md-new { display: flex; gap: 6px; padding: 10px; border-top: 1px solid var(--line); }
.md-new input { flex: 1; }
.md-detail { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 16px 20px; min-height: 300px; }
.md-detail h2 { margin: 0 0 12px; }
.md-detail .field { display: block; margin: 12px 0; }
.md-detail input:not([type=checkbox]):not([type=file]), .md-detail select, .md-detail textarea {
  display: block; width: 100%; margin-top: 4px; padding: 8px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
.md-foot { display: flex; justify-content: space-between; align-items: center; border-top: 1px solid var(--line); margin-top: 16px; padding-top: 12px; }
.md-empty { padding: 16px; }
.thumb { border-radius: 8px; object-fit: cover; flex: none; }
/* Página web: vista previa y SEO */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }
.preview { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--bg); }
.pv-top { display: flex; gap: 12px; align-items: center; padding: 10px 12px; font-size: 13px; }
.serp { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; max-width: 600px; font-family: Arial, sans-serif; }
.serp-url { color: #202124; font-size: 13px; }
.serp-title { color: #1a0dab; font-size: 19px; margin: 2px 0; }
.serp-desc { color: #4d5156; font-size: 14px; }
.notice { padding: 8px 16px; text-align: center; font-weight: 600; }
.notice.ticker { padding: 8px 0; overflow: hidden; white-space: nowrap; text-align: left; }
.ticker-track { display: inline-flex; animation: ticker linear infinite; }
.ticker-track span { padding: 0 32px; }
.ticker-track span::before { content: "★"; margin-right: 32px; opacity: .6; }
.notice.ticker:hover .ticker-track { animation-play-state: paused; }
@keyframes ticker { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker-track { animation: none; } }
/* En celular, del mismo alto que el recuadro del logo (30 px) */
@media (max-width: 760px) { .notice { padding: 0 12px; font-size: 13px; line-height: 30px; } .notice.ticker { padding: 0; } .ticker-track span { padding: 0 18px; } .ticker-track span::before { margin-right: 18px; } }
.banners { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; background: #000; }
.banners::-webkit-scrollbar { display: none; }
.banner { flex: 0 0 100%; scroll-snap-align: start; position: relative; overflow: hidden; border: 0; border-radius: 0; padding: 0; background: #000; color: #fff; text-align: left; }
/* La imagen se ve completa, con su propia proporción (en celular, la versión para celular si la hay); el video sí se recorta a 16:5. */
.banner img { width: 100%; height: auto; max-height: 480px; object-fit: cover; display: block; }
.banner video { width: 100%; aspect-ratio: 16 / 5; max-height: 480px; object-fit: cover; display: block; }
.banners { align-items: center; }
.banner span { position: absolute; left: 0; right: 0; bottom: 0; padding: 16px 24px; background: linear-gradient(transparent, rgba(0,0,0,.7)); }
.site-foot { border-top: 1px solid var(--line); margin-top: 32px; padding: 24px 16px; background: var(--card); }
.site-foot .cols { max-width: 1200px; margin: auto; display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 24px; }
@media (max-width: 800px) { .site-foot .cols { grid-template-columns: 1fr; } }
.site-foot a { color: inherit; }
.site-foot .powered { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 24px -16px -24px; padding: 14px 16px; background: #000; color: #fff; font-size: 13px; }
.site-foot .powered img { height: 22px; }
.grid-table { width: 100%; border-collapse: collapse; margin-top: 6px; }
.grid-table th, .grid-table td { text-align: left; padding: 6px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
/* Celda de botones (Editar, Borrar…): sigue siendo celda, con los botones en una sola línea. Con display:flex dejaba de serlo:
   los botones se apilaban y su línea no calzaba con la del resto de la fila (Remarketing, 25/11). */
.grid-table td.row { display: table-cell; white-space: nowrap; } .grid-table td.row > * + * { margin-left: 6px; }
.grid-table input[type=number] { display: inline-block !important; width: 110px !important; margin: 0 !important; }
.thumb.empty { display: inline-block; background: #eee; }
.toast { position: fixed; bottom: 20px; right: 20px; background: #111; color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 10; }
@media (max-width: 900px) { .md { grid-template-columns: minmax(0, 1fr); } .md-list { height: 50vh; position: static; } }

/* Selector de etiquetas con buscador */
.tags { position: relative; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; padding: 6px;
  border: 1px solid var(--line); border-radius: 8px; background: var(--card); }
.tags .chips { display: contents; }
.tags .chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 4px 2px 10px; border-radius: 99px;
  background: #fde7ef; color: #7a0f38; font-size: 13px; cursor: grab; }
.tags .chip button { border: 0; background: transparent; padding: 0 6px; color: inherit; font-size: 15px; line-height: 1; }
.tags > input { flex: 1; min-width: 160px; border: 0; outline: none; padding: 4px; font: inherit; background: transparent; }
.tags .drop { position: absolute; left: 0; right: 0; top: 100%; margin-top: 4px; z-index: 5; max-height: 260px; overflow: auto;
  background: var(--card); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 6px 20px rgba(0,0,0,.12); }
.tags .drop > div { padding: 8px 10px; cursor: pointer; }
.tags .drop > div.on, .tags .drop > div:hover { background: #f4f4f1; }

/* App del personal: menú lateral + contenido */
.app { display: grid; grid-template-columns: 224px 1fr; min-height: 100vh; }
#side { background: #111; color: #fff; padding: 16px 12px; display: flex; flex-direction: column; gap: 16px; position: sticky; top: 0; height: 100vh; overflow-y: auto; scrollbar-width: thin; }
#side .brand { font-weight: 700; font-size: 18px; padding: 0 8px; }
#side nav { display: flex; flex-direction: column; gap: 2px; flex: 1; }
#side nav a { color: #ddd; text-decoration: none; padding: 8px; border-radius: 8px; display: flex; align-items: center; gap: 10px; }
#side nav a .ic { width: 18px; height: 18px; color: #888; }
#side nav a:hover { background: #222; }
#side nav a[aria-current="page"] { background: var(--accent); color: #fff; }
#side nav a[aria-current="page"] .ic { color: #fff; }
#side nav .navgroup { color: #777; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; padding: 14px 8px 4px; }
/* Apps de delivery en Fuego para Windows (shell.js, appTabs): la flecha que reinicia cada una y la campana que las silencia. */
#side .apptabs { display: flex; flex-direction: column; gap: 2px; }
#side .apptabs .navgroup { display: flex; align-items: center; justify-content: space-between; }
#side .apptab { display: flex; align-items: center; gap: 2px; }
#side .apptab a { flex: 1; min-width: 0; }
#side .apptabs button { background: none; border: 0; color: #888; padding: 6px; border-radius: 8px; cursor: pointer; display: flex; }
#side .apptabs button:hover { background: #222; color: #fff; }
#side .apptabs button .ic { width: 16px; height: 16px; }
#side .who { display: flex; justify-content: space-between; align-items: end; gap: 8px; padding: 0 8px; color: #bbb; }
.content { min-width: 0; }
.content > .bar { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); background: var(--card); }
.content > .bar h1 { font-size: 18px; margin: 0; }
/* Celular: barra arriba con ☰ y el menú lateral sale como cajón desde la izquierda (como Justo) */
.mbar, #sideShade { display: none; }
@media (max-width: 800px) {
  .app { grid-template-columns: 1fr; }
  .mbar { display: flex; align-items: center; gap: 12px; padding: 10px 14px; background: #111; color: #fff; position: sticky; top: 0; z-index: 4; font-weight: 700; }
  .mbar button { border: 0; background: transparent; color: inherit; font-size: 26px; line-height: 1; padding: 2px 4px; }
  #side { position: fixed; top: 0; left: 0; bottom: 0; width: min(300px, 85vw); height: 100dvh; z-index: 7; overflow: auto;
    transform: translateX(-100%); transition: transform .25s ease-out; box-shadow: 0 0 30px rgba(0,0,0,.3); }
  .side-open #side { transform: none; }
  #sideShade { position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 6; }
  .side-open #sideShade { display: block; }
  .content > .bar { flex-wrap: wrap; gap: 8px; padding: 10px 12px; }
  .content > .bar .tabs { width: 100%; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .content > .bar .tabs button, .content > .bar .tabs a { white-space: nowrap; }
  /* Filtros debajo del título (Reportes, Historial…) y pestañas en una fila que se desliza, como en Carta */
  .content > .bar > #tools, .content > .bar > #filters { flex-basis: 100% !important; } /* gana al flex:1 escrito en el HTML */
  .tabs.sub { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .tabs.sub button, .tabs.sub a { white-space: nowrap; }
}
/* Una tabla ancha se desplaza dentro de sí misma, sin mover toda la página (celular y tablet con menú lateral). */
@media (max-width: 1100px) { .grid-table { display: block; overflow-x: auto; } }

/* Web del cliente: diseño configurable (Página web → Diseño) */
.shop { font-family: var(--font-body, system-ui, sans-serif); }
.shop h1, .shop h2, .shop h3 { font-family: var(--font-title, inherit); }
.shop .prod b, .shop legend, .shop .banner b { font-family: var(--font-subtitle, inherit); }
.shop .top { background: var(--header-bg, #111); color: var(--header-text, #fff); }
.shop .top a, .shop .top #mode { color: var(--header-text, #fff); }
.shop .site-foot { background: var(--footer-bg, #fff); color: var(--footer-text, #1a1a1a); }
/* En el teléfono, estirar la web más allá del final mostraba el fondo claro (y las cintas de Xsmile) bajo el pie: la web de pedidos no se estira. */
html:has(body.shop) { overscroll-behavior-y: none; }
.notice a { text-decoration: underline; }
.prod { position: relative; }
.prod .txt { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.ph { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 8px; display: block; }
.quick { position: absolute; top: 8px; right: 8px; width: 34px; height: 34px; border-radius: 50%; background: var(--accent); color: var(--accent-text, #fff);
  display: grid; place-items: center; font-size: 22px; line-height: 1; box-shadow: 0 2px 6px rgba(0,0,0,.2); }
/* Afiche con información (como las promos de Papa John's): la foto completa arriba, sin recortar, y debajo nombre, descripción, precio y «+» grande abajo a la derecha. */
.cards-afiche { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; align-items: start; }
.cards-afiche .prod { padding: 0; gap: 0; overflow: hidden; }
.cards-afiche .ph { aspect-ratio: auto; border-radius: 0; max-width: none !important; }
.cards-afiche .txt { padding: 16px 18px 20px; gap: 6px; }
.cards-afiche .txt b { font-size: 20px; line-height: 1.2; }
.cards-afiche .txt small { font-size: 15px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cards-afiche .txt > span { margin-top: 10px; font-size: 18px; font-weight: 700; padding-right: 56px; }
.cards-afiche .quick { top: auto; bottom: 16px; right: 16px; width: 46px; height: 46px; font-size: 26px; }
/* Solo imagen (promos como afiche): la foto completa a su tamaño natural, sin texto; si el producto no tiene foto se ve como clásica. */
.cards-imagen { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; align-items: start; } /* afiches de distinta proporción no se estiran */
.cards-imagen .prod:has(.ph) { padding: 0; overflow: hidden; background: none; border: 0; box-shadow: none; } /* solo la foto: sin marco, sin texto y sin «+» */
.cards-imagen .prod:has(.ph) .quick { display: none; }
.cards-imagen .prod:has(.ph) .ph { aspect-ratio: auto; border-radius: 0; max-width: none !important; }
.cards-imagen .prod:has(.ph) .txt { display: none; }
.cards-imagen .prod:has(.ph) .badge { position: absolute; top: 8px; left: 8px; }
.cards-imagen .quick { background: #fff; color: #111; border: 1px solid #ddd; box-shadow: 0 1px 4px rgba(0,0,0,.15); }
/* Animación de marca Xsmile (public/xsmile.js): cintas adhesivas por detrás de la web y sello al agregar al carrito. */
.xs-fondo { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
/* La cinta se mueve con transform (lo anima la tarjeta gráfica, sin redibujar): la tira interior mide un patrón más que el ancho y se desplaza un patrón exacto. */
.xs-cinta { position: absolute; left: -12%; right: -12%; height: 44px; overflow: hidden; }
.xs-cinta > div { width: calc(100% + 662px); height: 100%; background: url('/xsmile-cinta.svg') repeat-x; background-size: 662px 44px; animation: xs-pasar 60s linear infinite; will-change: transform; }
.xs-cinta.c0 { top: 16%; transform: rotate(-6deg); } .xs-cinta.c1 { top: 50%; transform: rotate(4deg); } .xs-cinta.c1 > div { animation-direction: reverse; } .xs-cinta.c2 { top: 82%; transform: rotate(-3deg); }
@keyframes xs-pasar { to { transform: translateX(-662px); } } /* un patrón completo (1536 × 102 a 44 px de alto) */
.xs-on #menu > h2, .xs-on #menu > p.muted { display: inline-flex; align-items: center; gap: 10px; background: var(--bg); padding: 4px 14px 4px 4px; border-radius: 999px; } /* los títulos se leen sobre las cintas */
.xs-sello { position: fixed; inset: 0; width: 100%; height: 100%; margin: 0; border: 0; padding: 0; background: transparent; display: grid; place-items: center; z-index: 60; pointer-events: none; }
.xs-sello div { font-family: 'Barlow Condensed', Impact, sans-serif; font-weight: 900; font-size: clamp(26px, 5vw, 48px); line-height: .92; text-align: center; color: #111; -webkit-text-stroke: 4px #fff; paint-order: stroke fill; transform: rotate(-9deg) scale(3); opacity: 0; animation: xs-timbrar 2.4s cubic-bezier(.2,.9,.3,1) forwards; }
.xs-sello small { display: block; font-size: .45em; letter-spacing: 2px; margin-top: 6px; -webkit-text-stroke: 2px #fff; }
@keyframes xs-timbrar { 0% { transform: rotate(-9deg) scale(2.4); opacity: 0; } 22%, 80% { transform: rotate(-9deg) scale(1); opacity: 1; } 100% { transform: rotate(-9deg) scale(1.04); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .xs-cinta > div { animation: none; } }
/* Tarjetas horizontales como Chicken Love You: texto a un lado, foto cuadrada al otro a toda la altura, "+" sobre la foto. */
.cards-horizontal_izq, .cards-horizontal_der { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
.cards-horizontal_izq .prod, .cards-horizontal_der .prod { flex-direction: row; align-items: stretch; gap: 0; padding: 0; overflow: hidden; box-shadow: 0 1px 6px rgba(0,0,0,.08); }
.cards-horizontal_der .prod { flex-direction: row-reverse; }
.cards-horizontal_izq .ph, .cards-horizontal_der .ph { width: 140px; max-width: none !important; height: auto; aspect-ratio: 1; flex: none; border-radius: 0; align-self: stretch; }
.cards-horizontal_izq .txt, .cards-horizontal_der .txt { flex: 1; padding: 14px 14px 14px 16px; gap: 6px; }
.cards-horizontal_izq .txt b, .cards-horizontal_der .txt b { font-size: 16px; line-height: 1.25; }
.cards-horizontal_izq .txt small, .cards-horizontal_der .txt small { order: 2; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.cards-horizontal_izq .quick, .cards-horizontal_der .quick { top: auto; bottom: 8px; right: 8px; width: 30px; height: 30px; font-size: 20px; background: #fff; color: #111; border: 1px solid #ddd; box-shadow: none; }
.cards-horizontal_izq .quick { right: auto; left: 8px; }
.prod:has(.quick):not(:has(.ph)) .txt { padding-right: 36px; }
.cards-vertical_amplia { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.cards-vertical_amplia .ph { aspect-ratio: 4 / 3; max-width: none !important; }
.cards-vertical_compacta { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.cards-vertical_compacta .prod { padding: 8px; font-size: 13px; }
.cards-vertical_compacta .prod small { display: none; }
@media (max-width: 500px) { .cards-horizontal_izq, .cards-horizontal_der { grid-template-columns: 1fr; } }
/* Vidrio (25/11, pedido del usuario con una referencia de app de comida): tarjeta redondeada y flotante teñida con el color de la marca,
   foto cuadrada arriba, nombre, precio y «+» cuadrado redondeado abajo a la derecha. Dos por fila en el celular. */
.cards-vidrio { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px; }
.cards-vidrio .prod { padding: 8px 8px 12px; gap: 8px; border-radius: 22px; border: 1px solid rgba(255, 255, 255, .7);
  background: color-mix(in srgb, var(--accent) 12%, rgba(255, 255, 255, .78)); -webkit-backdrop-filter: blur(14px) saturate(140%); backdrop-filter: blur(14px) saturate(140%);
  box-shadow: 0 1px 2px rgba(0, 0, 0, .05), 0 10px 26px color-mix(in srgb, var(--accent) 22%, transparent); transition: transform .15s; }
.cards-vidrio .prod:hover:not(:disabled) { transform: translateY(-2px); }
.cards-vidrio .ph { border-radius: 16px; max-width: none !important; }
.cards-vidrio .txt { padding: 0 4px; gap: 6px; flex: 1; }
.cards-vidrio .txt b { font-size: 15px; line-height: 1.2; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cards-vidrio .txt small { display: none; }
.cards-vidrio .txt > span { margin-top: auto; padding-right: 40px; font-weight: 800; font-size: 15px; }
.cards-vidrio .quick { top: auto; bottom: 10px; right: 10px; width: 34px; height: 34px; border-radius: 12px; font-size: 22px; }
@media (max-width: 500px) { .cards-vidrio { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } }
dialog.page { width: 100vw; max-width: 100vw; height: 100vh; max-height: 100vh; margin: 0; border-radius: 0; padding: 24px max(16px, calc(50vw - 360px)); }
fieldset.done { background: #fafaf8; }
dialog.popup { width: min(420px, 92vw); text-align: center; position: relative; }
.pay-spin { width: 40px; height: 40px; margin: 8px auto 0; border: 4px solid rgba(0,0,0,.12); border-top-color: currentColor; border-radius: 50%; animation: pay-spin .9s linear infinite; }
@keyframes pay-spin { to { transform: rotate(360deg); } }
.popup-x { position: absolute; top: 8px; right: 8px; width: 32px; height: 32px; padding: 0; border-radius: 50%; background: rgba(0,0,0,.55); color: #fff; border: 0; font-size: 16px; line-height: 32px; z-index: 1; }

/* Admin → Página web → Diseño */
.designer { display: grid; grid-template-columns: 190px 380px 1fr; gap: 16px; padding: 16px; align-items: start; }
.ds-nav { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; position: sticky; top: 16px; }
.ds-nav button { border: 0; border-bottom: 1px solid var(--line); border-radius: 0; text-align: left; padding: 10px 12px; background: transparent; }
.ds-nav button.on { background: #fde7ef; box-shadow: inset 3px 0 0 var(--accent); font-weight: 600; }
.ds-form { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 16px; max-height: calc(100vh - 100px); overflow: auto; position: sticky; top: 16px; }
.ds-form h2 { margin: 0 0 8px; font-size: 18px; }
.ds-form input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=color]), .ds-form select, .ds-form textarea {
  display: block; width: 100%; margin-top: 4px; padding: 8px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
.ds-form .list-row { flex-wrap: nowrap; margin: 6px 0; }
.ds-form .list-row input { margin: 0 !important; }
.ds-form .bar-item { display: flex; flex-direction: column; gap: 6px; margin: 8px 0; }
.ds-form .md-item { border: 1px solid var(--line); border-radius: 8px; margin: 6px 0; }
.ds-form .md-new { padding: 10px 0; border: 0; }
.field.color { display: flex; flex-direction: column; gap: 4px; flex: 1; }
.field.color input { width: 100%; height: 40px; padding: 2px; border: 1px solid var(--line); border-radius: 8px; }
.choices { display: flex; flex-direction: column; gap: 6px; margin: 8px 0 12px; }
.choice { display: flex; gap: 10px; align-items: start; border: 1px solid var(--line); border-radius: 10px; padding: 10px; cursor: pointer; }
.choice:has(input:checked) { border-color: var(--accent); background: #fdf3f7; }
.pay-extra { padding: 0 10px 6px; } /* «¿Con cuánto vas a pagar?» y el RUT de Amipass, justo bajo su opción */
.choice .pay-ico { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; }
.ds-save { position: sticky; bottom: -16px; background: var(--card); display: flex; justify-content: space-between; align-items: center; gap: 8px;
  border-top: 1px solid var(--line); margin: 16px -16px -16px; padding: 12px 16px; }
.ds-preview { position: sticky; top: 16px; min-width: 0; }
.ds-tools { margin-bottom: 8px; }
.ds-frame { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: #ddd; height: calc(100vh - 140px); }
.ds-frame iframe { border: 0; width: 100%; height: 100%; display: block; background: #fff; }
.ds-frame.mobile { width: 390px; max-width: 100%; margin: auto; border-radius: 28px; border: 8px solid #111; }
@media (max-width: 1200px) { .designer { grid-template-columns: 1fr; } .ds-nav { flex-direction: row; flex-wrap: wrap; position: static; } .ds-form, .ds-preview { position: static; max-height: none; } }

/* Encabezado de la web: menú principal arriba, barra de entrega debajo y categorías fijas en carrusel */
.shop .top { position: static; overflow: visible; gap: 24px; padding: 12px 24px; }
.shop #brand { font-weight: 700; font-size: 20px; opacity: 1; }
.navlinks { display: flex; gap: 20px; }
.navlinks a { font-weight: 600; }
.icons { margin-left: auto; display: flex; align-items: center; gap: 16px; }
.shop .top .icons > a { font-weight: 600; opacity: 1; display: inline-flex; align-items: center; gap: 6px; position: relative; padding: 4px; }
.shop .top .icons > a:hover { opacity: .7; }
.shop .top .icons .lbl { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); } /* solo para lectores de pantalla, como en Shopify */
.shop .top .icons .count { position: absolute; top: -2px; right: -6px; min-width: 18px; height: 18px; line-height: 18px; padding: 0 5px; font-size: 11px; text-align: center; }
.count { background: var(--accent); color: var(--accent-text, #fff); border-radius: 99px; padding: 0 7px; font-size: 12px; line-height: 20px; }
.burger { display: none; position: relative; }
.burger summary { list-style: none; cursor: pointer; font-size: 24px; line-height: 1; padding: 4px; }
.burger summary::-webkit-details-marker { display: none; }
.burger nav { position: absolute; right: 0; top: 100%; margin-top: 8px; min-width: 200px; display: flex; flex-direction: column; z-index: 5;
  background: var(--card); border-radius: 10px; box-shadow: 0 8px 24px rgba(0,0,0,.2); overflow: hidden; }
.shop .burger nav a { color: var(--text); padding: 12px 16px; border-bottom: 1px solid var(--line); opacity: 1; }
.modebar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 24px; background: var(--card); border-bottom: 1px solid var(--line); }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 99px; padding: 3px; background: var(--bg); }
.seg button { border: 0; border-radius: 99px; background: transparent; padding: 6px 14px; font-weight: 600; }
.seg button.on { background: var(--accent); color: var(--accent-text, #fff); }
.modebar .pick { border-radius: 99px; font-weight: 600; }
.modebar .when { color: var(--muted); font-size: 14px; }
.modebar button, .modebar .when, .co svg, .modebar svg { display: inline-flex; align-items: center; gap: 6px; }
.modebar svg { vertical-align: -3px; }
.cats { position: sticky; top: 0; z-index: 2; display: flex; gap: 8px; overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none;
  padding: 10px 24px; background: var(--card); border-bottom: 1px solid var(--line); box-shadow: 0 2px 6px rgba(0,0,0,.04); }
.cats::-webkit-scrollbar { display: none; }
.cats a { flex: none; scroll-snap-align: start; white-space: nowrap; text-decoration: none; color: var(--text); font-weight: 600;
  padding: 7px 14px; border-radius: 99px; border: 1px solid var(--line); background: var(--card); }
.cats a.on { background: var(--accent); color: var(--accent-text, #fff); border-color: var(--accent); }
.shop h2 { scroll-margin-top: 70px; display: flex; align-items: center; gap: 10px; }
.cat-ico { display: inline-flex; width: 40px; height: 40px; border-radius: 50%; align-items: center; justify-content: center; background: var(--icon-fill, var(--accent)); color: var(--icon-fill-text, #111); }
.cat-ico .ico { --icon-fill: transparent; }
.cats a .ico { vertical-align: -4px; margin-right: 4px; }
.cats a.on .ico { --icon-fill: transparent; }
.ico { vertical-align: -5px; }
@media (max-width: 760px) {
  .shop .top { gap: 8px; padding: 10px 16px; }
  .navlinks { display: none; }
  .burger { display: block; }
  /* En celular: menú de hamburguesa a la izquierda, logo al centro y solo el carrito a la derecha; Ingresar va dentro del menú */
  .shop .top .icons { display: contents; }
  .shop .top .icons > .account-link { display: none; }
  .shop .top .burger { order: -1; }
  .shop .top .cartbtn { margin-left: auto; }
  /* El menú sube desde abajo hasta media pantalla, como la ficha de producto; tocar fuera lo cierra */
  .burger[open]::before { content: ''; position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 5; }
  .burger nav { position: fixed; left: 0; right: 0; bottom: 0; top: auto; margin: 0; height: 50dvh; border-radius: 18px 18px 0 0; padding: 8px 0 16px; z-index: 6;
    overflow: auto; animation: slideup .25s ease-out; }
  .shop .burger nav a { padding: 16px 20px; font-size: 17px; font-weight: 600; }
  .shop .top .burger nav .lbl { position: static; width: auto; height: auto; clip: auto; }
  .shop .top .icons > a { gap: 2px; }
  .modebar { padding: 8px 16px; gap: 8px; }
  .modebar .seg { width: 100%; }
  .modebar .seg button { flex: 1; }
  .modebar .when { font-size: 13px; }
  .cats { padding: 8px 16px; }
}

/* Encabezado "cápsula": flotante, redondeado, logo al centro y fijo al bajar (Página web → Diseño → Encabezado) */
.capsula .top { position: sticky; top: 8px; z-index: 3; margin: 8px 12px 0; border-radius: 99px; padding: 8px 20px; box-shadow: 0 6px 20px rgba(0,0,0,.18);
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; }
.capsula .navlinks { order: -1; }
.capsula .navlinks a { border: 1.5px solid currentColor; border-radius: 99px; padding: 5px 14px; opacity: 1; font-size: 14px; }
.capsula #brand { justify-self: center; }
.logo-round #brand img { aspect-ratio: 1; width: auto; object-fit: cover; border-radius: 50%; }
.capsula #brand img { height: 48px !important; }
.capsula .icons { justify-self: end; }
.capsula .cats { top: 72px; }
.logo-text { display: inline-block; background: var(--accent); color: var(--accent-text, #fff); font-family: var(--font-title, inherit); font-weight: 700;
  text-transform: uppercase; letter-spacing: .5px; font-size: 22px; line-height: 1; padding: 9px 14px; border-radius: 6px; }
@media (max-width: 760px) { .logo-text { font-size: 13px; padding: 6px 10px; letter-spacing: 0; } .capsula .icons { gap: 10px; } .capsula .top { padding: 6px 10px; } }
@media (max-width: 760px) {
  .capsula .top { margin: 8px 8px 0; padding: 6px 14px; grid-template-columns: 1fr auto 1fr; }
  .capsula #brand img { height: 40px !important; }
  .capsula .cartbtn { justify-self: end; }
  .capsula .cats { top: 64px; }
}

/* Páginas aparte de la web: Locales y Mi cuenta */
.page-view { display: none; max-width: 1100px; margin: auto; padding: 16px; }
body[data-view=locales] #storesView, body[data-view=cuenta] #accountView, body[data-view=checkout] #checkoutView, body[data-view=suscripcion] #subsView, body[data-view=puntos] #pointsView, body[data-view=reservar] #reserveView { display: block; }
body[data-view=reservar] #mode { display: none !important; } /* reservar no es pedir: sin retiro ni delivery */
.reserve { max-width: 520px; margin: auto; } .reserve .times { display: flex; flex-wrap: wrap; gap: 8px; } .reserve .times button { min-width: 72px; }
.rewards { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; margin: 16px 0; }
.reward { display: grid; gap: 4px; align-content: start; text-align: left; font: inherit; color: inherit; cursor: pointer; }
.faq { display: grid; gap: 8px; max-width: 760px; margin-bottom: 24px; }
.faq details { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.faq summary { cursor: pointer; font-weight: 600; }
.faq p { margin: 8px 0 0; color: var(--muted); }
.reward.solo { padding: 0; border: 0; background: none; border-radius: 12px; overflow: hidden; } /* tarjeta propia del premio: solo la imagen */
.reward.solo .ph { display: block; width: 100%; max-width: none !important; border-radius: 0; }
.reward .ph-empty { aspect-ratio: 1; display: grid; place-items: center; background: #f3f3f3; border-radius: 8px; color: #999; }
.reward .ph-empty .ic { width: 40px; height: 40px; }
body[data-view] .layout, body[data-view] .cats, body[data-view] .banners { display: none !important; }
body[data-view=checkout] #mode { display: none !important; } /* en el checkout se cambia desde "Detalles de entrega" */
.auth { max-width: 420px; margin: 24px auto; }
.account { display: grid; grid-template-columns: 1fr 1.3fr; gap: 16px; align-items: start; }
@media (max-width: 760px) { .account { grid-template-columns: 1fr; } }
.stores { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.badge.open { background: #d8f3dc; color: #1b5e20; }
.hours { width: 100%; border-collapse: collapse; font-size: 14px; }
.hours td { padding: 3px 0; border-bottom: 1px solid var(--line); }
.hours td + td { text-align: right; }
.hours tr.today { font-weight: 700; }

/* Paneles laterales (producto y carrito), como Chicken Love You: a la derecha en PC, pantalla completa en celular */
dialog.sheet { padding: 0; }
dialog.sheet[open] { display: flex; flex-direction: column; }
dialog.panel { margin: 0 0 0 auto; width: min(460px, 100vw); max-width: 100vw; height: 100dvh; max-height: 100dvh; border-radius: 0; }
dialog.panel[open] { animation: slidein .2s ease-out; }
@keyframes slidein { from { transform: translateX(40px); opacity: 0; } }
@keyframes slideup { from { transform: translateY(100%); } }
dialog.sheet::backdrop { background: rgba(0,0,0,.45); }
dialog.sheet.page { padding: 0; }
/* Se estira entre los bordes de la pantalla en vez de calcular su altura: en la app instalada del iPhone 100vh y 100dvh no calzan y el botón de abajo quedaba afuera. */
dialog.panel, dialog.sheet.page { top: 0; bottom: 0; height: auto; max-height: none; }
dialog.sheet.page .sheet-body, dialog.sheet.page .sheet-head, dialog.sheet.page .sheet-foot { padding-inline: max(16px, calc(50vw - 360px)); }
.sheet-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 14px 16px; border-bottom: 1px solid var(--line); font-size: 17px; }
.sheet-head button { border: 0; background: transparent; font-size: 18px; }
.sheet-body { flex: 1; overflow: auto; padding: 16px; }
/* La foto completa, en su forma (antes se recortaba cuadrada y una horizontal se veía con zoom; 25/11, aviso del usuario).
   Una muy alta no pasa del 70% de la pantalla y se achica sin cortarse. */
.sheet-body .ph { max-width: none !important; border-radius: 12px; aspect-ratio: auto; height: auto; max-height: 70vh; object-fit: contain; }
.sheet-foot { display: flex; gap: 10px; align-items: center; padding: 12px 16px; border-top: 1px solid var(--line); background: var(--card); }
.sheet-foot .grow, .grow { flex: 1; padding: 12px; font-weight: 700; border-radius: 10px; }
.sheet textarea { width: 100%; padding: 8px; border: 1px solid var(--line); border-radius: 8px; font: inherit; resize: vertical; }
.stepper { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 99px; padding: 2px; background: var(--bg); }
.stepper button { border: 0; background: transparent; border-radius: 99px; width: 34px; height: 34px; padding: 0; display: grid; place-items: center; flex: none; font-size: 18px; line-height: 1; color: var(--text); }
.stepper button:disabled { opacity: .3; }
.stepper .ic { width: 16px; height: 16px; }
/* Ficha del producto y carrito de la web, con los colores de la marca (25/11, pedido del usuario con una referencia de app de comida):
   foto grande redondeada, grupos como tarjetas suaves, píldoras para elegir uno, interruptores para lo que se marca una vez,
   «−» y «+» redondos (el «+» del color de la marca) y «Agregar | $precio» en una píldora. */
.shop .sheet-head { border-bottom: 0; font-size: 19px; }
.shop .sheet-head button { width: 36px; height: 36px; padding: 0; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: color-mix(in srgb, var(--accent) 14%, var(--card, #fff)); }
.shop .sheet-body .ph { border-radius: 22px; box-shadow: 0 12px 30px rgba(0, 0, 0, .14); }
.shop .sheet-price { font-size: 20px; font-weight: 800; }
.shop #product fieldset { border: 0; border-radius: 18px; padding: 12px 14px; margin: 12px 0; background: color-mix(in srgb, var(--accent) 8%, var(--card, #fff)); }
.shop #product fieldset.done { background: color-mix(in srgb, var(--accent) 5%, var(--card, #fff)); }
.shop #product legend { float: left; width: 100%; padding: 0; margin-bottom: 2px; font-size: 16px; } /* dentro de la tarjeta, no sobre su borde */
.shop #product legend + small { display: block; clear: both; }
.shop .opt + .opt { border-top: 1px solid color-mix(in srgb, var(--accent) 12%, transparent); }
.shop .opt input[type=checkbox] { appearance: none; -webkit-appearance: none; position: relative; width: 46px; height: 28px; margin: 0; border-radius: 99px;
  background: color-mix(in srgb, var(--text, #1a1a1a) 18%, #fff); cursor: pointer; transition: background .15s; }
.shop .opt input[type=checkbox]::after { content: ''; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .15s; }
.shop .opt input[type=checkbox]:checked { background: var(--accent); }
.shop .opt input[type=checkbox]:checked::after { transform: translateX(18px); }
.shop .opt input[type=checkbox]:disabled { opacity: .4; cursor: default; }
.shop .opt input[type=checkbox]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.pills { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.pill { border: 1.5px solid color-mix(in srgb, var(--accent) 40%, transparent); background: var(--card, #fff); border-radius: 99px; padding: 8px 14px; font-weight: 600; }
.pill small { font-weight: 500; opacity: .75; }
.pill.on { background: var(--accent); border-color: var(--accent); color: var(--accent-text, #fff); }
.shop .stepper { border: 0; padding: 4px; gap: 10px; font-weight: 700; background: color-mix(in srgb, var(--accent) 12%, var(--card, #fff)); }
.shop .stepper button, .shop .opt > .row button { border: 0; border-radius: 50%; background: var(--card, #fff); color: var(--text, #1a1a1a); box-shadow: 0 1px 3px rgba(0, 0, 0, .12); }
.shop .stepper button:last-child, .shop .opt > .row button[data-d="1"] { background: var(--accent); color: var(--accent-text, #fff); }
.shop .opt > .row { gap: 8px; font-weight: 700; }
.shop .sheet-foot { border-top: 0; box-shadow: 0 -8px 24px rgba(0, 0, 0, .06); }
.shop .sheet-foot .add-btn { border-radius: 99px; padding: 14px 18px; display: flex; justify-content: center; align-items: center; gap: 12px; font-size: 16px; }
.shop .sheet-foot .add-btn b { padding-left: 12px; border-left: 1.5px solid color-mix(in srgb, currentColor 45%, transparent); }
/* Líneas del carrito */
.cline { display: flex; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.cthumb { width: 56px; height: 56px; border-radius: 8px; object-fit: cover; flex: none; background: #eee; display: block; }
.ctxt { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ctxt a { color: var(--accent); font-size: 13px; }
.cright { display: flex; flex-direction: column; align-items: flex-end; justify-content: space-between; gap: 6px; }
.total { font-size: 17px; }
.sug-title { margin: 16px 0 8px; text-transform: uppercase; font-size: 12px; letter-spacing: .04em; color: var(--muted); }
.sugs { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: none; }
.sug { position: relative; flex: 0 0 116px; display: flex; flex-direction: column; gap: 2px; text-align: left; padding: 0; border: 0; background: transparent; }
.sug .cthumb { width: 116px; height: 116px; }
.sug b { color: var(--accent); font-size: 13px; }
.sug .quick { top: 84px; right: 6px; width: 28px; height: 28px; font-size: 18px; }
/* Checkout en su propia página */
.back { display: inline-block; margin: 4px 0 8px; color: var(--muted); }
.co { display: grid; grid-template-columns: 1fr 380px; gap: 16px; align-items: start; padding-bottom: 90px; }
.co h2 { font-size: 17px; margin: 0 0 8px; }
.co .card { margin-bottom: 12px; }
.co-sum { position: sticky; top: 16px; }
.co-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 3; background: var(--card); border-top: 1px solid var(--line);
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; align-items: center; gap: 4px; }
.co-bar .error { margin: 0; text-align: center; }
.co-bar button { width: min(600px, 100%); padding: 14px; font-weight: 700; font-size: 16px; border-radius: 10px; }
.btnlink { display: inline-block; padding: 10px 18px; border-radius: 10px; text-decoration: none; }
.pts-pierdes { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: space-between; border: 2px solid var(--accent); }
.pts-pierdes p { margin: 0; font-size: 17px; }
.pts-pierdes small { color: var(--muted); font-size: 13px; }
@media (max-width: 860px) { .co { grid-template-columns: 1fr; } .co-sum { position: static; } }
#modeDlg .seg { display: flex; }
#modeDlg .seg button { flex: 1; }

/* Tablero de Pedidos: luces de los canales de venta */
/* Va en la barra de arriba, al lado del título "Pedidos" */
.content > .bar { flex-wrap: wrap; }
#channels { min-width: 0; }
.chan { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.chan > b { margin-right: 4px; }
.statusbar { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; padding: 8px 16px; border-bottom: 1px solid var(--line); background: var(--card); }
/* Pedidos: tiempos, autoaceptar, vista y sonido juntos; en el computador ocupan el resto de la barra. */
.bar-tools { flex: 1; min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.bar-tools .chan { flex-wrap: nowrap; }
.bar-tools .chan > * { flex: none; white-space: nowrap; }
.bar-tools > .seg, .bar-tools > #sound, .bar-tools .seg button { flex: none; white-space: nowrap; }
/* Celular: «Pedidos · Local» arriba y debajo una sola fila de opciones que se desliza hacia el lado (también luces y caja). */
@media (max-width: 800px) {
  .bar-tools, .statusbar { flex: 1 1 100%; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; gap: 8px; }
  .bar-tools::-webkit-scrollbar, .statusbar::-webkit-scrollbar { display: none; }
  .bar-tools .chan, .statusbar .row { flex-wrap: nowrap; }
  .bar-tools > *, .bar-tools .chan > *, .statusbar > *, .statusbar .row > * { flex: none; white-space: nowrap; }
  .bar-tools .seg { margin-left: 0 !important; }
  .statusbar .row { margin-left: 0 !important; }
}

.light { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: 14px; }
.light i { width: 10px; height: 10px; border-radius: 50%; background: #d32f2f; box-shadow: 0 0 0 3px rgba(211,47,47,.18); }
.light.on i { background: #2e7d32; box-shadow: 0 0 0 3px rgba(46,125,50,.2); }
.light.off { color: inherit; text-decoration: none; opacity: .65; }
.light.off i { background: #9e9e9e; box-shadow: 0 0 0 3px rgba(0,0,0,.08); }
.chan select { padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; font: inherit; font-weight: 700; }
.chan .lights { display: inline-flex; flex-wrap: wrap; gap: 6px; }
.counter { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 99px; padding: 3px 4px 3px 12px; font-weight: 600; }
.counter button { width: 30px; height: 30px; padding: 0; border-radius: 50%; font-size: 18px; line-height: 1; }
.counter b { min-width: 52px; text-align: center; }
dialog.wide { width: min(980px, 96vw); }
.scroll-x { overflow-x: auto; }
.cuadre td, .cuadre th { white-space: nowrap; }
.cuadre input { width: 110px; padding: 6px; border: 1px solid var(--line); border-radius: 6px; font: inherit; }
.ok { color: #2e7d32; font-weight: 600; }
/* Turnos y caja */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-bottom: 12px; }
.kpi { display: flex; flex-direction: column; gap: 4px; }
.kpi b { font-size: 22px; }
.aud-grid { display: grid; align-items: start; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
a.mini.btnlink { padding: 4px 10px; border: 1px solid var(--line); border-radius: 8px; color: inherit; font-size: 13px; }
.grid-table.info td:first-child { color: var(--muted); width: 200px; }
.cfg-row { margin: 6px 0; flex-wrap: nowrap; }
@media (max-width: 800px) { .cfg-row { flex-wrap: wrap; } .cfg-row > * { max-width: 100%; } }
.cfg-row input:not([type=checkbox]), .cfg-row select { padding: 6px 8px; border: 1px solid var(--line); border-radius: 6px; font: inherit; }
#side .place { display: flex; flex-direction: column; gap: 4px; padding: 0 8px; }
#side .place small { color: #999; text-transform: uppercase; letter-spacing: .05em; font-size: 11px; }
#side .place select { width: 100%; padding: 6px 8px; border-radius: 8px; border: 1px solid #333; background: #1d1d1d; color: #fff; font: inherit; font-weight: 600; }
#side nav a.switch { margin-top: 12px; border-top: 1px solid #2a2a2a; border-radius: 0; padding-top: 14px; color: #bbb; }
.cfg-row label.row { flex-wrap: nowrap; white-space: nowrap; }
.cfg-row select { width: auto !important; display: inline-block !important; margin: 0 !important; }
/* Interruptores (Bloquear productos, Ajustes) */
.block-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.block-row.off > span:first-child { color: var(--muted); text-decoration: line-through; }
.switch { display: inline-flex; align-items: center; gap: 8px; flex: none; }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.switch i { width: 42px; height: 24px; border-radius: 99px; background: #d32f2f; position: relative; transition: background .15s; }
.switch i::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .15s; }
.switch input:checked + i { background: #2e7d32; }
.switch input:checked + i::after { transform: translateX(18px); }
.switch input:focus-visible + i { outline: 2px solid var(--accent); outline-offset: 2px; }
.switch small { width: 72px; font-weight: 600; }
/* Todas las casillas de las pantallas del personal (.app) se ven como interruptor de prendido y apagado, con los colores de .switch
   (pedido del usuario, 21/11). Siguen siendo casillas: se marcan con el teclado y los lectores de pantalla las leen igual. No toca las
   que ya tienen su propio diseño (.switch, fichas y locales) ni la web de los clientes. */
.app input[type=checkbox]:not(.switch input, .chipset input, .store-row > input) { appearance: none; -webkit-appearance: none; flex: none; width: 34px; height: 20px;
  margin: 0 6px 0 0; border-radius: 99px; background: #d32f2f; position: relative; vertical-align: middle; cursor: pointer; transition: background .15s; }
.app input[type=checkbox]:not(.switch input, .chipset input, .store-row > input)::after { content: ''; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px;
  border-radius: 50%; background: #fff; transition: transform .15s; }
.app input[type=checkbox]:not(.switch input, .chipset input, .store-row > input):checked { background: #2e7d32; }
.app input[type=checkbox]:not(.switch input, .chipset input, .store-row > input):checked::after { transform: translateX(14px); }
.app input[type=checkbox]:not(.switch input, .chipset input, .store-row > input):disabled { opacity: .45; cursor: default; }
.app input[type=checkbox]:not(.switch input, .chipset input, .store-row > input):focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
/* Historial */
.history tbody tr { cursor: pointer; }
.history tbody tr:hover { background: #f7f7f4; }
#tools input, #tools select { padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
/* KDS */
/* Todas las tarjetas del mismo alto (el del pedido más largo, al menos 220 px), con «Listo» siempre abajo. */
.kds { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); grid-auto-rows: minmax(220px, 1fr); gap: 12px; padding: 16px; }
.ticket > .primary { margin-top: auto; }
.ticket header { align-items: center; flex-wrap: nowrap; }
.ticket header > span { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ticket header .timer { flex: none; }
/* Pantalla completa (KDS): sin el menú lateral */
:fullscreen .app { grid-template-columns: 1fr; }
:fullscreen #side { display: none; }
.ticket { background: var(--card); border: 1px solid var(--line); border-top: 8px solid #2e7d32; border-radius: 10px; padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.ticket.late { border-top-color: #f9a825; }
.ticket.very-late { border-top-color: #d32f2f; }
.ticket header { display: flex; justify-content: space-between; gap: 8px; font-size: 18px; }
.ticket .mins { font-weight: 700; }
.ticket.very-late .mins { color: #d32f2f; }
.kitem { font-size: 17px; padding: 6px 0; border-top: 1px dashed var(--line); cursor: pointer; }
.kitem.done { opacity: .35; text-decoration: line-through; }
.kmod { font-size: 15px; padding-left: 10px; }
.knote { font-size: 15px; background: #fff7d6; border-radius: 6px; padding: 2px 6px; margin-top: 2px; }
.promo-price { color: var(--accent); }
.promo-tag { display: inline-block; background: var(--accent); color: var(--accent-text, #fff); font-weight: 700; font-size: 12px; border-radius: 6px; padding: 1px 6px; margin-left: 4px; }
.knote.sched { background: #e3f0ff; font-weight: 700; }
.ticket .primary { padding: 12px; font-size: 16px; font-weight: 700; }
.danger { background: #c62828; color: #fff; border-color: #c62828; }
/* Pedidos: tablero + panel "Nuevo pedido" a la derecha */
.pedidos-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 12px var(--pos-w, minmax(380px, 50%)); align-items: start; } /* la toma de pedido: media pantalla, o lo que se arrastre su orilla */
.pos-resize { position: sticky; top: 16px; height: calc(100vh - 140px); margin-top: 16px; display: flex; align-items: center; justify-content: center; cursor: col-resize; touch-action: none; }
.pos-resize::before { content: ""; width: 4px; height: 48px; border-radius: 2px; background: var(--line); }
.pos-resize:hover::before, .pos-resize.dragging::before { background: var(--accent); }
.pedidos-wrap .board { min-width: 0; padding-right: 8px; }
.pedidos-wrap .board .order { font-size: 14px; }
.pos { margin: 16px 16px 16px 0; position: sticky; top: 16px; max-height: calc(100vh - 140px); overflow: auto; display: flex; flex-direction: column; gap: 10px; }
.pos h2 { margin: 0; font-size: 18px; }
/* Las partes del panel no se encogen (si no, la carta con scroll quedaba en 0 de alto al abrir Cliente en delivery): el panel hace scroll. */
.pos > * { flex-shrink: 0; }
.pos-types { display: flex; } .pos-types button { flex: 1; padding: 6px 4px; font-size: 13px; }
.pos-client { display: flex; flex-direction: column; gap: 6px; border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; }
.pos-client[open] > *:not(summary) { margin-top: 6px; display: block; }
.pos-client summary { cursor: pointer; font-weight: 600; list-style-position: inside; }
.pos-points { background: var(--soft, rgba(255,200,0,.08)); border-radius: 8px; padding: 6px 8px; }
.pos-points .pos-cats, .pos-points input { margin-top: 6px; width: 100%; }
.pos input { padding: 7px 8px; border: 1px solid var(--line); border-radius: 8px; font: inherit; width: 100%; }
.pos-cats { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.pos-cats button { flex: none; border-radius: 99px; padding: 4px 10px; font-size: 13px; }
.pos-cats button.on { background: var(--accent); color: var(--accent-text, #fff); border-color: var(--accent); }
/* grid-auto-rows: en el celular la hoja tiene alto fijo y, sin esto, las filas quedaban en 56 px y las fotos se montaban. */
.pos-products { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); grid-auto-rows: max-content; gap: 8px; max-height: 42vh; overflow: auto; }
.pos-products button { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; text-align: left; padding: 8px; font-size: 13px; min-height: 56px; }
.pos-products img { width: 100%; height: 80px; object-fit: cover; border-radius: 8px; margin-bottom: 4px; }
.pos-products button:disabled img { opacity: .4; }
.pos-lines { border-top: 1px solid var(--line); }
.pos-line { display: flex; justify-content: space-between; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.pos-line-r { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.pos-total .row { flex-wrap: nowrap; }
/* Sin columnas no hay ancho que arrastrar: la manilla sobra y su touch-action bloqueaba el scroll en el celular. */
@media (max-width: 1100px) { .pedidos-wrap { grid-template-columns: minmax(0, 1fr); } .pos-resize { display: none; } .pos { margin: 0 16px 16px; position: static; max-height: none; } }
/* Partes del panel (pos.js): cabecera y cliente, productos, lo pedido y el cobro. Una debajo de otra (Mesas y celular). */
.pos-head, .pos-pick, .pos-cart { display: flex; flex-direction: column; gap: 10px; }
.pos-head > *, .pos-pick > *, .pos-cart > * { flex-shrink: 0; }
/* Botón brasa «+ Nuevo pedido», solo en Pedidos (.toggle-pos; Mesas usa el mismo panel sin botón): abre o cierra la toma de pedido.
   En computador es una barra angosta pegada a la derecha y la toma de pedido ocupa toda la pantalla (abajo);
   en el celular es una barra fija abajo y el panel se abre como hoja encima. */
#posFab { padding: 6px 14px; border: 0; border-radius: 99px; background: var(--lime, #FF7A1A); color: #1C0A02; font: inherit; font-weight: 700; white-space: nowrap; }
.toggle-pos { grid-template-columns: minmax(0, 1fr); }
.toggle-pos > .pos-resize, .toggle-pos:not(.pos-open) > .pos { display: none; }
body:has(.toggle-pos.pos-open) { overflow: hidden; }
body:has(.toggle-pos.pos-open) .sam-barra { display: none; } /* tapaba el cobro */
/* Computador: como un punto de venta (25/11, pedido del usuario con una foto de referencia): productos a la izquierda; a la derecha,
   tipo de pedido y cliente arriba, y lo pedido con el cobro abajo. Si la derecha es larga, baja toda la pantalla y los productos quedan fijos. */
@media (min-width: 701px) {
  /* Flota como una tarjeta bajo la barra de la caja (pedidos.js pone --fab-top) hasta abajo, en naranjo (25/11, pedido del usuario: primero más claro, después «más intenso»). */
  body:has(#posFab:not([hidden])) .toggle-pos > .board { padding-right: 76px; } /* que la barra no tape pedidos */
  body:has(#posFab:not([hidden])) .wa-alert { right: 76px; }
  #posFab { position: fixed; top: var(--fab-top, 140px); right: 16px; bottom: 16px; z-index: 31; width: 48px; padding: 0; border-radius: 20px; writing-mode: vertical-rl;
    background: #FF8A33; font-size: 15px; box-shadow: 0 1px 2px rgba(20, 20, 30, .04), 0 8px 24px rgba(255, 122, 26, .3); }
  #posFab:hover { background: #FF7A1A; }
  .toggle-pos.pos-open #posFab { top: 16px; right: 20px; bottom: auto; width: auto; padding: 8px 16px; border-radius: 99px; writing-mode: horizontal-tb; z-index: 41; box-shadow: none; }
  .toggle-pos.pos-open .pos { position: fixed; inset: 0; z-index: 40; margin: 0; max-height: none; overflow: auto; border: 0; border-radius: 0; box-shadow: none;
    padding: 16px 20px; background: var(--app-bg, #f4f4f1); display: grid; grid-template-columns: minmax(0, 1fr) minmax(360px, 34%);
    grid-template-rows: auto 1fr; grid-template-areas: "pick head" "pick cart"; gap: 12px 20px; align-items: start; }
  .toggle-pos.pos-open .pos > :is(h2, p) { grid-column: 1 / -1; } /* caja cerrada: solo el aviso */
  .toggle-pos.pos-open :is(.pos-head, .pos-pick, .pos-cart) { background: var(--glass, #fff); border-radius: 20px; padding: 14px; box-shadow: var(--lift, 0 1px 3px rgba(0, 0, 0, .08)); }
  .toggle-pos.pos-open .pos-head { grid-area: head; }
  .toggle-pos.pos-open .pos-head h2 { padding-right: 100px; line-height: 36px; } /* al lado va «✕ Cerrar» */
  .toggle-pos.pos-open .pos-client summary { pointer-events: none; list-style: none; } /* Cliente siempre abierto (pedidos.js lo abre) */
  .toggle-pos.pos-open .pos-client summary::-webkit-details-marker { display: none; }
  .toggle-pos.pos-open .pos-cart { grid-area: cart; }
  .toggle-pos.pos-open .pos-pick { grid-area: pick; position: sticky; top: 0; max-height: calc(100vh - 32px); overflow: auto; }
  .toggle-pos.pos-open .pos-products { max-height: none; overflow: visible; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
  .toggle-pos.pos-open .pos-products img { height: 110px; }
  /* Opciones de un producto, en el lugar de los productos (pos.js → choose): el nombre arriba y «Agregar» abajo, siempre a la vista. */
  .pos-choose > .spread:first-child, .pos-choose > .spread:last-child { position: sticky; z-index: 1; background: var(--glass, #fff); padding: 6px 0; }
  .pos-choose > .spread:first-child { top: -14px; padding-top: 14px; margin-top: -14px; }
  .pos-choose > .spread:last-child { bottom: -14px; padding-bottom: 14px; margin-bottom: -14px; }
  body:has(.wa-alert) .toggle-pos.pos-open .pos { padding-bottom: 84px; } /* el aviso de WhatsApp no tapa los botones de cobro */
}
@media (max-width: 700px) {
  #posFab { position: fixed; left: 16px; right: 16px; bottom: calc(12px + env(safe-area-inset-bottom)); z-index: 31; padding: 14px; font-size: 16px;
    box-shadow: 0 6px 20px rgba(255, 90, 31, .35); }
  .toggle-pos > .board { padding-bottom: 80px; }
  .toggle-pos.pos-open .pos { position: fixed; inset: 6vh 0 0; z-index: 30; margin: 0; max-height: none; overflow: auto; padding-bottom: 90px;
    border-radius: 22px 22px 0 0; box-shadow: 0 -10px 40px rgba(0, 0, 0, .25); }
}
.pos-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.pos-actions button { display: flex; flex-direction: column; gap: 2px; padding: 10px 6px; border-radius: 10px; }
.pos-actions small { font-size: 11px; opacity: .8; }
.pos-table { flex-wrap: nowrap; } .pos-table input { flex: 1; }
.pos select { padding: 7px 8px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
.pos-disc { flex-wrap: nowrap; }
/* Cuenta regresiva del pedido (Pedidos y KDS) */
.timer { font-weight: 700; font-variant-numeric: tabular-nums; padding: 2px 8px; border-radius: 99px; white-space: nowrap; }
.timer.ok { background: #e6f6ea; color: #1b5e20; }
.timer.soon { background: #fff4cc; color: #8a6100; }
.timer.urgent { background: #ffe0cc; color: #b34700; }
.timer.late { background: #fde0e0; color: #b71c1c; }
@keyframes blink { 50% { opacity: .6; } }
.order:has(.timer.urgent) { border-left: 4px solid #ef6c00; }
.order:has(.timer.late) { border-left: 4px solid #d32f2f; }
.ticket:has(.timer.ok) { border-top-color: #2e7d32; }
.ticket:has(.timer.soon) { border-top-color: #f9a825; }
.ticket:has(.timer.urgent) { border-top-color: #ef6c00; }
.ticket:has(.timer.late) { border-top-color: #d32f2f; }
.suggest { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; margin: 2px 0 4px; }
.suggest button { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; text-align: left; padding: 6px 10px; background: var(--card); }
.suggest button:hover { background: #f4f4f1; }
/* Pedidos: menú ⋮ y vista lista */
.dots { border: 0; background: transparent; font-size: 20px; line-height: 1; padding: 2px 6px; border-radius: 6px; }
.dots:hover { background: #eee; }
.order > .primary { width: 100%; margin-top: 4px; }
.omenu { position: fixed; z-index: 20; display: flex; flex-direction: column; min-width: 200px; background: var(--card); border: 1px solid var(--line);
  border-radius: 10px; box-shadow: 0 8px 24px rgba(0,0,0,.18); overflow: hidden; }
.omenu button { border: 0; border-radius: 0; text-align: left; padding: 10px 14px; background: transparent; }
.omenu button:hover { background: #f4f4f1; }
.danger-text { color: #c62828; }
.board.list { grid-template-columns: 1fr; }
.board.list section { min-width: 0; }
.orow { display: grid; grid-template-columns: 130px 120px 1fr 2fr 110px auto; gap: 10px; align-items: center; background: var(--card);
  border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; margin-bottom: 6px; font-size: 14px; }
.orow-id { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.orow-items { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.orow-total { text-align: right; }
/* Todas las filas del mismo alto: etiquetas en una línea y cliente en otra, cortados con «…»; lo completo está en la ficha. */
.orow-who { min-width: 0; } .orow-tags, .orow-name { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.orow:has(.timer.urgent) { border-left: 4px solid #ef6c00; }
.orow:has(.timer.late) { border-left: 4px solid #d32f2f; }
/* La lista se adapta al ancho del tablero (que comparte la pantalla con Nuevo pedido), no al de la ventana. */
.board.list { container-type: inline-size; }
@container (max-width: 900px) {
  .orow { grid-template-columns: 100px 1fr 90px auto; }
  .orow > span:nth-child(2), .orow-items { display: none; }
  .orow .primary { white-space: nowrap; }
}
/* ⋮ siempre en la esquina superior derecha de la tarjeta */
.order { position: relative; }
.order > .spread:first-child { padding-right: 30px; flex-wrap: wrap; gap: 4px; }
.order > .spread:first-child .dots { position: absolute; top: 6px; right: 4px; }
.order .badge { white-space: normal; }
/* Tarjetas grandes, todas del mismo alto: arriba y abajo (pago y botón) siempre a la vista; al medio, lo que quepa.
   Si no cabe todo, se desvanece y sale «Ver pedido completo» (pedidos.js → markMore); la ficha lo muestra entero. */
.board.cards .order { height: 300px; display: flex; flex-direction: column; }
.board.cards .order > * { flex: none; }
.board.cards .order > .obody { flex: 1 1 0; min-height: 0; overflow: hidden; }
.obody.more { mask-image: linear-gradient(#000 70%, transparent); }
.omore { display: none; color: var(--muted); text-align: right; }
.obody.more + .omore { display: block; }
/* Tarjetas pequeñas: las filas de la Lista puestas en columnas. Cada columna es su propio contenedor, así que toman la forma
   angosta de tres líneas (@container 560px, abajo), todas del mismo alto. ponytail: en pantallas de más de ~2.500 px la columna
   pasa de 560 px y queda la fila de la Lista mediana; si pasa, repetir esas reglas para .board.small. */
.board.small > section { container-type: inline-size; }
/* Ficha del pedido */
.order, .orow { cursor: pointer; }
.order:hover, .orow:hover { box-shadow: 0 2px 10px rgba(0,0,0,.08); }
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.detail-grid h4, dialog h4 { margin: 12px 0 4px; }
.detail-actions { flex-wrap: wrap; margin-top: 12px; border-top: 1px solid var(--line); padding-top: 12px; }
@media (max-width: 700px) { .detail-grid { grid-template-columns: 1fr; } }
/* Reportes */
.reports h2 { margin: 20px 0 10px; }
.reports h3 { margin: 4px 0 10px; font-size: 15px; }
.reports .md-detail { margin-bottom: 16px; min-height: 0; }
.chart { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; padding: 16px 0 24px; }
.chart-y { display: flex; flex-direction: column; justify-content: space-between; align-items: flex-end; height: 200px; font-size: 10.5px; color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.chart-y span { line-height: 0; } /* cada número queda centrado en su línea guía */
.bars { display: flex; align-items: flex-end; gap: 4px; height: 200px; border-bottom: 1px solid var(--line);
  background: repeating-linear-gradient(90deg, var(--line) 0 4px, transparent 4px 9px) 0 0 / 100% 1px no-repeat, repeating-linear-gradient(90deg, var(--line) 0 4px, transparent 4px 9px) 0 50% / 100% 1px no-repeat; }
.bar-col { position: relative; flex: 1; min-width: 4px; height: 100%; display: flex; align-items: flex-end; justify-content: center; cursor: default; border-radius: 8px 8px 0 0; }
.bar-col:hover { background: color-mix(in srgb, currentColor 5%, transparent); }
.bar-fill { position: relative; width: 100%; max-width: 40px; min-height: 3px; background: var(--accent); border-radius: 6px 6px 0 0; transform-origin: bottom;
  animation: crece .8s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(var(--i, 0) * 18ms); }
.bar-fill.zero { background: var(--line); }
@keyframes crece { from { transform: scaleY(0); } }
.bar-col small { position: absolute; top: calc(100% + 7px); font-size: 10.5px; color: var(--muted); white-space: nowrap; }
.bar-col:hover .bar-fill::after { content: attr(data-v); position: absolute; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%); z-index: 2; padding: 6px 10px; border-radius: 10px;
  background: #0b0b0c; color: #fff; font-size: 11.5px; font-weight: 600; white-space: nowrap; box-shadow: 0 6px 18px rgba(0, 0, 0, .25); pointer-events: none; }
.share td { padding: 6px 8px; }
.share-bar { width: 35%; }
.share-bar div { height: 8px; border-radius: 99px; background: color-mix(in srgb, currentColor 8%, transparent); overflow: hidden; }
.share-bar span { display: block; height: 100%; border-radius: 99px; background: var(--accent); min-width: 3px; transform-origin: left; animation: ancho .8s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes ancho { from { transform: scaleX(0); } }
@media (prefers-reduced-motion: reduce) { .bar-fill, .share-bar span { animation: none; } }
.share td:not(:first-child) { white-space: nowrap; }
@media (max-width: 600px) { .share-bar { display: none; } .share td { padding: 6px 4px; } } /* en el celular, la barra no cabe: queda el % */
#filters select, #filters input { padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
/* Lista angosta (poco espacio al lado de Nuevo pedido), en tres líneas:
   código + tiempo | total  ·  tipo y cliente | cómo paga  ·  botón a lo ancho con su ⋮ al final. */
@container (max-width: 560px) {
  .orow, .vidrio .orow { grid-template-columns: minmax(0, 1fr) auto; row-gap: 6px; align-items: center; }
  .orow > .orow-id { grid-column: 1; grid-row: 1; flex-direction: row; align-items: center; gap: 8px; }
  .orow > span:nth-child(3) { grid-column: 1; grid-row: 2; min-width: 0; }
  .orow > .orow-total { grid-column: 2; grid-row: 1 / span 2; }
  .orow-total small, .orow > span:last-child small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .orow-total small { display: inline-block; max-width: 150px; vertical-align: top; }
  .orow > span:last-child small { min-width: 0; }
  .orow > span:last-child { grid-column: 1 / -1; grid-row: 3; flex-wrap: nowrap; }
  .orow > span:last-child .primary { flex: 1; }
}
.orow .badge { white-space: nowrap; }
.code-time { gap: 8px; flex-wrap: nowrap; }
.orow-id .timer, .code-time .timer { flex: none; }
/* Ventanas largas (ficha del local): título con ✕ arriba y Guardar/Cancelar siempre visibles abajo */
dialog .dlg-head { position: sticky; top: -18px; z-index: 2; background: var(--card, #fff); margin: -18px -18px 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
dialog .dlg-foot { position: sticky; bottom: -18px; z-index: 2; background: var(--card, #fff); margin: 12px -18px -18px; padding: 12px 18px; border-top: 1px solid var(--line); }

/* Menú lateral ocultable (Pedidos) */
.app.side-hidden { grid-template-columns: 1fr; }
.app.side-hidden #side { display: none; }
@media (max-width: 800px) { .app.side-hidden #side { display: flex; } #sideToggle { display: none; } } /* en celular manda el cajón de la barra de arriba */
.side-toggle { font-size: 18px; line-height: 1; padding: 6px 10px; }
.auto { border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; margin-top: 8px; }
.auto summary { cursor: pointer; list-style: none; }
.auto-form { margin-top: 10px; }
.auto-form textarea { width: 100%; font: inherit; padding: 8px; border: 1px solid var(--line); border-radius: 8px; }
.mb { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 10px 0; }
.mb-blocks { display: flex; flex-direction: column; gap: 8px; max-height: 60vh; overflow: auto; }
.mb-block { border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; }
.mb-block textarea, .mb-block input:not([type=checkbox]) { width: 100%; font: inherit; padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; }
.mb-add { flex-wrap: wrap; gap: 6px; }
.mb-tools { gap: 4px; margin: 4px 0; }
.mb-tools [aria-pressed=true] { background: var(--text); color: var(--card); }
.mb-block .mb-color input[type=color] { width: 18px; height: 18px; padding: 0; border: 0; margin-left: 4px; vertical-align: middle; cursor: pointer; }
.mb-bar { display: flex; gap: 6px; align-items: center; margin-bottom: 6px; } .mb-bar .seg { margin-left: auto; }
.mb-preview.cel iframe { width: 375px; max-width: 100%; display: block; margin: 0 auto; }
.mb-prods { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; max-height: 260px; overflow: auto; }
.mb-cat { grid-column: 1 / -1; margin-top: 6px; font-size: 13px; }
.mb-cat:first-child { margin-top: 0; }
.mb-preview iframe { width: 100%; height: 60vh; border: 1px solid var(--line); border-radius: 10px; background: #f4f4f5; }
.btnlike { cursor: pointer; border: 1px solid var(--line); border-radius: 8px; padding: 4px 10px; }
@media (max-width: 900px) { .mb { grid-template-columns: 1fr; } }
.wiz-steps { display: flex; gap: 18px; list-style: none; padding: 0; margin: 10px 0 14px; flex-wrap: wrap; }
.wiz-steps li { display: flex; align-items: center; gap: 6px; color: var(--muted); cursor: pointer; }
.wiz-steps li span { width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; font-size: 12px; }
.wiz-steps li.on { color: inherit; font-weight: 700; } .wiz-steps li.on span, .wiz-steps li.done span { background: var(--accent); color: #fff; border-color: transparent; }
.tpl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.tpl { display: flex; flex-direction: column; gap: 4px; text-align: left; padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); cursor: pointer; font: inherit; }
.tpl:hover { border-color: var(--accent); }
.tpl-prev { height: 220px; overflow: hidden; border-radius: 8px; background: #f4f4f5; pointer-events: none; }
.tpl-prev iframe { width: 560px; height: 620px; border: 0; transform: scale(0.36); transform-origin: 0 0; }
.aud-pick { cursor: pointer; border: 2px solid transparent; } .aud-pick.on { border-color: var(--accent); }
.wiz-review { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; } .wiz-review .mb-preview iframe { height: 70vh; }
.wiz-nav { margin-top: 14px; }
@media (max-width: 900px) { .wiz-review { grid-template-columns: 1fr; } }
input[type=color] { width: 46px; height: 34px; padding: 2px; border: 1px solid var(--line); border-radius: 8px; background: var(--card); cursor: pointer; }

/* WhatsApp: conversación con burbujas (cliente a la izquierda; IA, local y avisos a la derecha) */
.wa-chat { display: flex; flex-direction: column; gap: 8px; max-height: 60vh; overflow: auto; padding: 12px; background: #efeae2; border-radius: 10px; }
.wa-msg { max-width: 80%; padding: 6px 10px; border-radius: 10px; background: #fff; align-self: flex-start; box-shadow: 0 1px 1px #0001; }
.wa-msg small { display: block; color: var(--muted); font-size: 11px; }
.wa-msg.ia, .wa-msg.persona, .wa-msg.sistema { align-self: flex-end; background: #d9fdd3; }
.wa-msg.persona { background: #cfe9ff; }
.wa-msg.sistema { background: #fff7d6; }
/* Simulador del agente: se ve como WhatsApp, desde el lado del cliente */
.wa-sim { max-width: 560px; margin: 0 auto; }
.wa-phone { display: flex; flex-direction: column; height: calc(100dvh - 170px); min-height: 420px; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; background: #efeae2; box-shadow: 0 6px 24px #0000001a; }
.wa-head { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: #008069; color: #fff; }
.wa-avatar { flex: none; width: 38px; height: 38px; display: grid; place-items: center; border-radius: 50%; background: #ffffff33; font-weight: 700; }
.wa-who { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.wa-who b, .wa-who small { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.wa-who small { opacity: .85; font-size: 12px; }
.wa-head button { flex: none; background: #ffffff26; color: #fff; border: 0; border-radius: 999px; padding: 7px 12px; font-size: 13px; font-weight: 600; cursor: pointer; }
.wa-head button:hover { background: #ffffff40; }
.wa-sim .wa-chat { flex: 1; max-height: none; min-height: 0; border-radius: 0; padding: 14px; }
.wa-sim .wa-msg { display: flex; flex-direction: column; max-width: 85%; font-size: 15px; line-height: 1.4; overflow-wrap: anywhere; }
.wa-sim .wa-msg small { order: 2; align-self: flex-end; margin-top: 2px; font-size: 11px; }
.wa-sim .wa-msg .wa-btns { order: 3; }
.wa-sim .wa-msg.cliente { align-self: flex-end; background: #d9fdd3; }
.wa-sim .wa-msg.ia, .wa-sim .wa-msg.persona { align-self: flex-start; background: #fff; }
.wa-sim .wa-msg.sistema { align-self: center; max-width: 90%; background: #fff7d6; text-align: center; font-size: 13px; }
.wa-empty { margin: auto; padding: 8px 14px; border-radius: 10px; background: #ffffffcc; color: var(--muted); font-size: 14px; text-align: center; }
.wa-typing { flex-direction: row !important; gap: 4px; padding: 11px 12px; }
.wa-typing i { width: 7px; height: 7px; border-radius: 50%; background: #8696a0; animation: wa-dot 1.2s infinite; }
.wa-typing i:nth-child(2) { animation-delay: .15s; }
.wa-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes wa-dot { 0%, 60%, 100% { opacity: .35; } 30% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .wa-typing i { animation: none; } }
.wa-handoff { margin: 0; padding: 10px 14px; background: #fff7d6; border-top: 1px solid var(--line); font-size: 13px; }
.wa-compose { display: flex; gap: 8px; padding: 10px; background: #f0f2f5; }
.wa-compose input { flex: 1; min-width: 0; height: 44px; padding: 0 16px; border: 1px solid var(--line); border-radius: 999px; background: #fff; font-size: 16px; }
.wa-compose button { flex: none; height: 44px; padding: 0 18px; border-radius: 999px; }
.wa-compose .wa-pin { padding: 0 12px; background: #fff; border: 1px solid var(--line); font-size: 18px; }
.wa-pin-dlg { width: min(560px, calc(100vw - 32px)); }
.wa-pin-map { height: min(420px, 60vh); border-radius: 10px; }
.wa-pin-map::after { content: 'Cargando el mapa…'; position: absolute; inset: 0; display: grid; place-items: center; color: #666; font-size: 14px; } /* debajo de los cuadros: se ve solo donde todavía no llegan */
.wa-sim-note { margin-top: 8px; font-size: 13px; text-align: center; }
.wa-fix { margin-top: 8px; border-top: 1px solid var(--line); padding-top: 6px; }
.badge.closed { background: #ffe0e0; color: #b00020; }
.badge.warn { background: #fff1d6; color: #8a5200; } /* Chats de WhatsApp: «Revisar» */
#main .card { margin-bottom: 14px; }
#main .card h2 { margin: 0 0 8px; font-size: 18px; }
/* Sin conexión en vivo (shell.js) y sonido sin activar (comanda.js): a la vista, para que nadie trabaje el turno a ciegas. */
.offline { position: fixed; left: 16px; bottom: 16px; z-index: 60; background: #fff; color: #b00020; border: 2px solid #b00020; font-weight: 700; padding: 8px 14px; border-radius: 99px; box-shadow: 0 4px 14px #0003; }
.sound-banner { position: fixed; top: 12px; left: 50%; transform: translateX(-50%); z-index: 60; max-width: calc(100vw - 32px); background: #b00020; color: #fff; border: 0;
  font-size: 17px; font-weight: 700; padding: 14px 22px; border-radius: 12px; box-shadow: 0 6px 20px #0005; }
/* Alarma del local (shell.js setAlarm): caja sin internet, app de delivery desconectada o comanda que no salió. Grande y arriba, que se vea desde lejos.
   Va primera en la página y empuja todo hacia abajo: fija encima tapaba la barra de arriba (16/11). */
.alarm { position: relative; z-index: 70; background: #b00020; color: #fff; font-size: 18px; font-weight: 700; line-height: 1.35;
  padding: 10px 16px; text-align: center; box-shadow: 0 6px 20px #0006; animation: alarm-blink 1.2s ease-in-out infinite alternate; }
.alarm p { margin: 4px auto; max-width: 1100px; }
.alarm .alarm-btn { background: #fff; color: #b00020; border: 0; border-radius: 8px; font: inherit; padding: 6px 18px; cursor: pointer; }
@keyframes alarm-blink { to { background: #e0002a; } }
@media (prefers-reduced-motion: reduce) { .alarm { animation: none; } }
/* Círculo de WhatsApp de la web del restaurante. En el pago se esconde: taparía el botón de pagar. */
.wa-float { position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 4; width: 56px; height: 56px; border-radius: 50%;
  background: #25d366; color: #fff; display: grid; place-items: center; box-shadow: 0 4px 14px #0004; }
.wa-float svg { width: 30px; height: 30px; fill: currentColor; }
body:has(.co-bar) .wa-float { display: none; }
.wa-alert { position: fixed; right: 16px; bottom: 16px; z-index: 50; max-width: 360px; background: #25d366; color: #fff; font-weight: 700; padding: 12px 16px; border-radius: 12px; box-shadow: 0 6px 20px #0003; text-decoration: none; }
#cfg .field textarea, #cfg .field select { width: 100%; box-sizing: border-box; }
.wa-btns { display: flex; flex-direction: column; gap: 3px; margin-top: 6px; }
.wa-btns button { background: #fff; color: #027eb5; border: 0; border-top: 1px solid #0001; border-radius: 0; padding: 7px; font-weight: 600; }
.wa-btns button:disabled { opacity: 1; cursor: default; }

/* Dirección de delivery: sugerencias del mapa y pin para confirmar */
.addr-sug { display: grid; gap: 4px; margin-top: 6px; }
.addr-sug button { text-align: left; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; padding: 10px 4px; display: flex; gap: 6px; align-items: center; }
.geo-btn { width: 100%; margin-top: 4px; display: flex; gap: 6px; justify-content: center; align-items: center; padding: 10px; font-weight: 600; }
.pin-map { height: 240px; border-radius: 10px; margin-bottom: 6px; background: var(--line); }
.linkbtn { width: 100%; border: 0; background: transparent; text-decoration: underline; margin-top: 6px; }

/* Gato negro que pasea por abajo de la web (public/gato.js) */
.gato { position: fixed; left: 0; bottom: 0; width: 140px; z-index: 5; pointer-events: none; color: #111; }
.gato svg { display: block; width: 100%; fill: currentColor; transition: transform .2s; }
.gato.left svg { transform: scaleX(-1); }
body[data-view=checkout] .gato { display: none; } /* en el checkout no distrae */
.gato svg > * { pointer-events: auto; cursor: pointer; }
.gato.flop svg { transform: translateY(30%) rotate(180deg); transition: transform .35s cubic-bezier(.5, -0.4, .6, 1.4); }
.gato.left.flop svg { transform: translateY(30%) rotate(180deg) scaleX(-1); }
.gato.flop .leg { animation: cat-step .18s ease-in-out infinite alternate; }
.gato.flop .l2, .gato.flop .l3 { animation-direction: alternate-reverse; }
.gato.flop .cat-tail { animation-duration: .4s; }
.gato .leg { transform-box: fill-box; transform-origin: 50% 10%; }
.gato .cat-tail { transform-box: view-box; transform-origin: 34px 44px; animation: cat-tail 1.8s ease-in-out infinite alternate; }
.gato .eye { fill: #f5d90a; transform-box: fill-box; transform-origin: center; animation: cat-blink 4s infinite; }
.gato .yarn { display: none; fill: var(--accent, #e2001a); }
.gato.walking svg { animation: cat-bob .25s ease-in-out infinite alternate; }
.gato.walking .l1, .gato.walking .l4 { animation: cat-step .5s ease-in-out infinite alternate; }
.gato.walking .l2, .gato.walking .l3 { animation: cat-step .5s ease-in-out -.5s infinite alternate-reverse; }
.gato.left.walking svg { animation-name: cat-bob-left; }
.gato.playing .paw { animation: cat-bat .35s ease-in-out infinite alternate; }
.gato.playing .cat-tail { animation-duration: .5s; }
.gato.playing .yarn { display: block; transform-box: fill-box; transform-origin: center; animation: cat-yarn .7s ease-in-out infinite alternate; }
@keyframes cat-step { from { transform: rotate(-22deg); } to { transform: rotate(22deg); } }
@keyframes cat-bob { to { transform: translateY(1.5px); } }
@keyframes cat-bob-left { from { transform: scaleX(-1); } to { transform: scaleX(-1) translateY(1.5px); } }
@keyframes cat-tail { from { transform: rotate(-10deg); } to { transform: rotate(12deg); } }
@keyframes cat-bat { from { transform: rotate(0); } to { transform: rotate(-65deg); } }
@keyframes cat-yarn { from { transform: translateX(0) rotate(0); } to { transform: translateX(5px) rotate(90deg); } }
@keyframes cat-blink { 0%, 94%, 100% { transform: scaleY(1); } 97% { transform: scaleY(.1); } }
@media (max-width: 760px) { .gato { width: 95px; } }
/* Suscripción: lista de beneficios del plan */
.perks { list-style: none; padding: 0; margin: 12px 0 16px; display: grid; gap: 6px; }
/* Mesas: plano por sector (libre gris, en cocina con acento, servida en verde) y rondas en la cocina */
.msector { padding: 12px 16px 4px; }
.msector h3 { margin: 0 0 8px; font-size: 15px; }
.mgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; }
.mesa { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-height: 92px; padding: 10px; border-radius: 14px; text-align: left; border: 1px solid var(--line); background: var(--card); color: var(--text); }
.mesa b { font-size: 20px; } .mesa small, .mesa span { font-size: 12px; color: var(--muted); }
.mesa.busy { border-color: var(--accent); box-shadow: inset 0 4px 0 var(--accent); }
.mesa.busy span { color: var(--accent); font-weight: 600; }
.mesa.served { border-color: #2e7d32; box-shadow: inset 0 4px 0 #2e7d32; }
.mesa.served span { color: #2e7d32; font-weight: 600; }
.mesa.on { outline: 3px solid var(--lime, var(--accent)); outline-offset: 1px; }
.mesa.reserved { border: 2px dashed #9c27b0; } .mesa.reserved span { color: #9c27b0; font-weight: 600; } /* reservada dentro de las próximas horas */
.mround { border-top: 1px dashed var(--line); padding-top: 6px; display: flex; flex-direction: column; gap: 4px; }
.mrows { display: flex; flex-direction: column; gap: 6px; } .mrow input { min-width: 0; }
.pos-in { display: flex; flex-direction: column; gap: 10px; }
.kround { font-size: 12px; font-weight: 700; text-transform: uppercase; color: var(--muted); margin-top: 4px; }
.kround.new { color: #fff; background: #d32f2f; border-radius: 6px; padding: 2px 8px; align-self: flex-start; }
.kitem.old { opacity: .45; }

/* Código de 6 dígitos (como en Justo): un solo campo dibujado como 6 casillas; pegar y autocompletar siguen funcionando. */
label.field input.codigo, label.field input.codigo:focus {
  --cell: 1.9ch; --gap: .5ch;
  background-color: transparent !important; border: 0 !important;
  display: block; box-sizing: content-box; width: calc(6 * (var(--cell) + var(--gap))); height: 2.2em; margin-top: 6px;
  padding: 0 0 0 calc((var(--cell) - 1ch) / 2); border: 0; border-radius: 0; outline: none; overflow: hidden;
  font: 600 1.5rem/1 ui-monospace, Consolas, monospace; letter-spacing: calc(var(--cell) + var(--gap) - 1ch);
  background-image: repeating-linear-gradient(90deg, color-mix(in srgb, currentColor 12%, transparent) 0 var(--cell), transparent 0 calc(var(--cell) + var(--gap))) !important;
  background-repeat: no-repeat !important; background-size: calc(6 * var(--cell) + 5 * var(--gap)) 100% !important;
}
#orderAlert { background: #111; } /* pedido nuevo mientras la app está en otra pantalla del local */
/* Diagnóstico de la cuenta de Meta (Anuncios → Configuración): una fila por verificación con su círculo. */
.diag { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; margin: 6px 0; }
.diag span { width: 22px; height: 22px; flex: none; display: grid; place-items: center; border: 2px solid var(--line); border-radius: 50%; font-size: 13px; font-weight: 700; }
.diag.ok span { background: #16a34a; border-color: #16a34a; color: #fff; }
.diag.bad span { background: #f59e0b; border-color: #f59e0b; color: #fff; }
.diag small { flex-basis: 100%; margin-left: 32px; }

/* Anuncios: asistente de campaña (anuncios.js). Píldoras = radios o casillas escondidas dentro de su etiqueta */
.chipset { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0; }
.chipset label { position: relative; display: inline-flex; align-items: center; padding: 7px 14px; border: 1.5px solid var(--line); border-radius: 99px; cursor: pointer; font-weight: 600; font-size: 14px; background: var(--card, #fff); }
.chipset.sm label { padding: 3px 10px; font-size: 12px; }
.chipset label:has(:checked) { background: var(--accent); border-color: var(--accent); color: var(--accent-text, #fff); }
.chipset label:has(:disabled) { opacity: .5; cursor: default; }
.chipset input { position: absolute; opacity: 0; pointer-events: none; }
/* Pasos: círculos numerados unidos por una línea; hecho = brasa con ✓, actual = tinta */
ol.stepper { display: flex; list-style: none; padding: 0; margin: 16px 0 6px; }
ol.stepper li { flex: 1; position: relative; }
ol.stepper li + li::before { content: ''; position: absolute; left: calc(-50% + 14px); right: calc(50% + 14px); top: 13px; height: 2px; background: var(--line); }
ol.stepper li.done + li::before { background: var(--lime, #FF7A1A); }
ol.stepper button { position: relative; white-space: nowrap; display: flex; flex-direction: column; align-items: center; gap: 6px; width: 100%; border: 0 !important; background: transparent !important; box-shadow: none !important; padding: 0; color: var(--muted); font-size: 12px; font-weight: 600; }
ol.stepper button:hover { transform: none !important; }
ol.stepper i { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; border: 2px solid var(--line); background: var(--card, #fff); font-style: normal; font-weight: 700; font-size: 12px; color: var(--muted); }
ol.stepper li.on button { color: var(--ink, #111); }
ol.stepper li.on i { background: var(--accent); border-color: var(--accent); color: var(--accent-text, #fff); }
ol.stepper li.done i { background: var(--lime, #FF7A1A); border-color: var(--lime, #FF7A1A); color: #fff; font-size: 0; }
ol.stepper li.done i::before { content: '✓'; font-size: 12px; }
@media (max-width: 600px) { ol.stepper span { display: none; } ol.stepper li.on span { display: block; position: absolute; top: 34px; left: 50%; transform: translateX(-50%); white-space: nowrap; } ol.stepper { margin-bottom: 26px; } }
.wz { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 16px; align-items: start; }
.wz section { padding-top: 6px; }
.wz-pv { position: sticky; top: 12px; text-align: center; }
.wz-pv .seg { margin-bottom: 10px; }
@media (max-width: 900px) { .wz { grid-template-columns: 1fr; } .wz-pv { position: static; } }
.pill-dark { display: inline-block; padding: 6px 12px; border-radius: 99px; background: var(--accent); color: var(--accent-text, #fff); font-weight: 700; font-size: 13px; white-space: nowrap; }
.stat b { display: block; font-size: 22px; letter-spacing: -.02em; line-height: 1.1; }
/* Estrategia: barra con la repartición del gasto y una tarjeta por público */
.funnel { max-width: 860px; }
.funnel-bar { display: flex; gap: 4px; margin: 14px 0 12px; height: 34px; border-radius: 10px; overflow: hidden; }
.funnel-bar span { display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 13px; }
.funnel-bar .nuevos, .strategy.nuevos .strategy-ico { background: #2563eb; }
.funnel-bar .tibio, .strategy.tibio .strategy-ico { background: var(--lime, #FF7A1A); }
.strategy.general .strategy-ico { background: var(--line, #ddd); }
.funnel-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 760px) { .funnel-cards { grid-template-columns: 1fr; } }
.strategy { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; text-align: left; padding: 18px 20px; border-radius: 16px !important; border: 1.5px solid var(--line) !important; background: var(--card, #fff) !important; box-shadow: none !important; cursor: pointer; font-weight: 400; color: inherit; }
.strategy:hover:not(:disabled) { border-color: var(--ink, #111) !important; transform: none !important; }
.strategy:disabled { opacity: .6; cursor: default; }
.strategy b { font-size: 18px; letter-spacing: -.02em; }
.strategy p { margin: 0; color: var(--muted); font-size: 13.5px; line-height: 1.45; }
.strategy-ico { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; font-size: 20px; }
.strategy-go { margin-top: 6px; font-weight: 700; font-size: 13px; }
/* Locales: una fila por local con casilla redonda, nombre, dirección y el radio en píldoras chicas */
.store-row { position: relative; display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; margin: 8px 0; border: 1.5px solid var(--line); border-radius: 14px; cursor: pointer; }
.store-row.off { opacity: .55; cursor: default; }
.store-row > input { position: absolute; opacity: 0; pointer-events: none; }
.store-check { flex: 0 0 22px; width: 22px; height: 22px; margin-top: 1px; border-radius: 50%; border: 2px solid var(--line); display: grid; place-items: center; color: #fff; font-size: 13px; font-weight: 700; }
.store-row:has(> :checked) { border-color: var(--ink, #111); }
.store-row:has(> :checked) .store-check { background: var(--accent); border-color: var(--accent); }
.store-row:has(> :checked) .store-check::before { content: '✓'; }
.store-info { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.store-info b { font-size: 15px; }
/* Subida de archivos y miniaturas */
.drop { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 22px; margin: 10px 0 0; border: 2px dashed var(--line); border-radius: 14px; cursor: pointer; text-align: center; }
.drop:hover { border-color: var(--ink, #111); }
.thumb { position: relative; width: 92px; height: 92px; border-radius: 10px; overflow: hidden; background: #eee; }
.thumb img, .thumb video { width: 100%; height: 100%; object-fit: cover; }
.thumb button { position: absolute; top: 4px; right: 4px; padding: 0 7px; background: #fff; }
.thumb small { position: absolute; left: 0; right: 0; bottom: 0; padding: 2px 4px; font-size: 10px; line-height: 1.2; background: #000a; color: #fff; }
.thumb small.bad { background: #d32f2f; }
/* Vista previa: una publicación de Instagram (feed) o una historia / reel a pantalla completa */
.pv-card { border: 1px solid #8884; border-radius: 14px; overflow: hidden; background: #fff; color: #111; text-align: left; font-size: 13px; }
.pv-head { display: flex; align-items: center; gap: 8px; padding: 10px 12px; }
.pv-head span { display: flex; flex-direction: column; line-height: 1.2; } .pv-head small { color: #666; } .pv-head i { margin-left: auto; font-style: normal; font-weight: 700; }
.pv-avatar { flex: 0 0 32px; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--lime, #FF7A1A); color: #fff; font-weight: 800; overflow: hidden; position: relative; }
.pv-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pv-media { position: relative; background: #eee; display: grid; place-items: center; color: #888; font-size: 13px; overflow: hidden; }
.pv-media img, .pv-media video { width: 100%; height: 100%; object-fit: cover; }
.pv-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; width: 100%; height: 100%; background: #fff; }
.pv-grid figure { margin: 0; position: relative; overflow: hidden; background: #eee; }
.pv-grid figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 6px 8px; background: #fffd; color: #111; font-size: 11px; line-height: 1.25; }
.pv-link { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 12px; background: #f2f3f5; }
.pv-link span:first-child { display: flex; flex-direction: column; min-width: 0; } .pv-link small { color: #666; text-transform: uppercase; font-size: 10px; }
.pv-btn { flex-shrink: 0; background: #e4e6eb; color: #111; border-radius: 8px; padding: 7px 12px; font-size: 13px; font-weight: 700; text-align: center; }
.pv-icons { display: flex; gap: 14px; padding: 10px 12px 4px; } .pv-icons svg, .pv-side svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.pv-msg { margin: 0; padding: 0 12px 12px; white-space: pre-wrap; line-height: 1.4; }
.pv-tall { position: relative; aspect-ratio: 9 / 16; max-width: 300px; margin: 0 auto; border-radius: 18px; overflow: hidden; background: #222; color: #fff; text-align: left; font-size: 13px; }
.pv-tall .pv-media { position: absolute; inset: 0; background: #333; color: #aaa; }
.pv-top, .pv-bottom { position: absolute; left: 0; right: 0; padding: 12px; }
.pv-top { top: 0; background: linear-gradient(#0009, transparent); } .pv-top small { color: #ddd; }
.pv-prog { display: block; height: 3px; margin-bottom: 10px; border-radius: 3px; background: #fff5; } .pv-prog i { display: block; width: 45%; height: 100%; border-radius: 3px; background: #fff; }
.pv-side { position: absolute; right: 10px; bottom: 90px; display: flex; flex-direction: column; gap: 16px; }
.pv-bottom { bottom: 0; display: grid; gap: 10px; padding-right: 48px; background: linear-gradient(transparent, #000c); }
.pv-bottom p { margin: 0; white-space: pre-wrap; max-height: 4.2em; overflow: hidden; }
.pv-tall .pv-btn { background: #fff; }
/* Resumen antes de crear */
.review > div { display: grid; grid-template-columns: 110px 1fr; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); line-height: 1.4; }
.review > div:first-child { border-top: 0; }
.review small { color: var(--muted); text-transform: uppercase; letter-spacing: .04em; font-size: 11px; font-weight: 600; padding-top: 2px; }
/* Texto por anuncio: la foto o el video con su texto al lado; barra de avance al crear */
.tcard { display: grid; grid-template-columns: 92px 1fr; gap: 14px; align-items: start; padding: 12px 0; border-top: 1px solid var(--line); }
.tcard:first-child { border-top: 0; padding-top: 0; }
.tcard img, .tcard video, .tcard-cat { width: 92px; height: 92px; border-radius: 10px; object-fit: cover; background: #eee; }
.tcard-cat { display: grid; place-items: center; text-align: center; font-size: 12px; font-weight: 700; color: var(--muted); line-height: 1.3; }
.tcard .field { margin-bottom: 8px; }
#prog { display: grid; gap: 4px; margin-top: 12px; }
#prog progress { width: 100%; height: 8px; accent-color: var(--lime, #FF7A1A); }
/* Dónde: mapa con las zonas; intereses elegidos; Campañas agrupadas por tráfico */
.wz-map { height: 260px; border-radius: 12px; margin: 10px 0; background: #eee; }
.ichip { display: inline-flex; align-items: center; gap: 4px; padding: 5px 6px 5px 12px; border-radius: 99px; background: var(--accent); color: var(--accent-text, #fff); font-weight: 600; font-size: 13px; }
.ichip button { border: 0 !important; background: transparent !important; color: inherit !important; padding: 0 4px; font-size: 13px; box-shadow: none !important; }
.grid-table tr.grp th { text-align: left; padding-top: 16px; font-size: 14px; text-transform: none; letter-spacing: 0; color: inherit; }
/* Vista previa: la carta debajo del anuncio (artículos del catálogo) */
.pv-strip { display: flex; gap: 3px; padding: 3px 0; background: #fff; }
.pv-strip figure { margin: 0; flex: 1; position: relative; }
.pv-strip img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; }
.pv-strip figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 2px 4px; background: #fffd; color: #111; font-size: 10px; font-weight: 700; }
/* Versión por ubicación: la vertical al lado de su original, o el botón para sumarla */
.thumb.tall { width: 56px; }
.thumb.add { display: grid; place-items: center; width: 76px; border: 2px dashed var(--line); background: transparent; color: var(--muted); font-size: 11px; font-weight: 700; text-align: center; line-height: 1.3; cursor: pointer; }
.thumb.add:hover { border-color: var(--ink, #111); color: var(--ink, #111); }
/* Números del negocio: cuatro números grandes y el detalle plegado */
.neg-top .neg-big b { font-size: 30px; }
.neg-avisos { margin: 0 0 12px; padding: 10px 14px 10px 30px; border-radius: 12px; background: #fff6e5; font-size: 13px; }
.neg-avisos li + li { margin-top: 4px; }
.neg-sec { margin-bottom: 10px; padding: 0; }
.neg-sec > summary { cursor: pointer; padding: 14px 16px; font-weight: 700; list-style: none; display: flex; gap: 10px; align-items: baseline; }
.neg-sec > summary::-webkit-details-marker { display: none; }
.neg-sec > summary::after { content: '›'; margin-left: auto; display: inline-block; font-size: 20px; transition: transform .15s; }
.neg-sec[open] > summary::after { transform: rotate(90deg); }
.neg-sec > summary small { font-weight: 400; }
.neg-sec > div { padding: 0 16px 16px; }
button.link { border: 0; background: none; padding: 0; color: inherit; text-decoration: underline; cursor: pointer; font: inherit; }
.neg-er { margin-bottom: 12px; padding: 16px; }
.neg-er h3 { margin: 0 0 8px; }
.neg-er tr.er-total td { font-weight: 700; border-top: 2px solid var(--line); }
.neg-er tr.er-sub td { font-size: 12px; color: var(--muted); padding-top: 2px; padding-bottom: 2px; }
.neg-er tr.er-sub td:first-child { padding-left: 22px; }
.er-mark { cursor: help; margin-left: 4px; }
.neg-tips { margin: 10px 0 8px; padding-left: 20px; }
.neg-tips li + li { margin-top: 6px; }
/* iPhone hace zoom al escribir en campos con letra menor a 16 px (incluye el cupón del checkout). */
@media (max-width: 700px) { input, select, textarea { font-size: 16px !important; } }
/* Íconos chicos de línea (ic() en icons.js) */
.ic { width: 1.15em; height: 1.15em; vertical-align: -0.2em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
/* Seguimiento del pedido: barra de pasos y avisos al celular */
.track { text-align: center; }
.track h1 { margin: 4px 0 2px; }
.steps { list-style: none; display: flex; padding: 0; margin: 22px 0 18px; }
.steps li { flex: 1; position: relative; display: flex; flex-direction: column; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.steps li + li::before { content: ''; position: absolute; top: 25px; left: calc(-50% + 32px); right: calc(50% + 32px); height: 3px; border-radius: 3px; background: var(--line); }
.steps li.done::before, .steps li.on::before { background: var(--accent); }
.step-ico { width: 52px; height: 52px; border-radius: 50%; display: flex; align-items: center; justify-content: center; border: 2px solid var(--line); color: var(--muted); --icon-fill: transparent; }
.steps li.done .step-ico, .steps li.on .step-ico { border-color: var(--accent); color: var(--text); --icon-fill: var(--accent); }
.steps li.done b, .steps li.on b { color: var(--text); }
.steps li.on .step-ico { animation: paso 1.8s infinite; }
@keyframes paso { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 45%, transparent); } 70%, 100% { box-shadow: 0 0 0 12px transparent; } }
@media (prefers-reduced-motion: reduce) { .steps li.on .step-ico { animation: none; } }
.track-push { display: flex; align-items: center; gap: 12px; text-align: left; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; margin: 0 0 14px; }
.track-push > .ic { width: 26px; height: 26px; color: var(--accent); }
.track-push span { flex: 1; display: flex; flex-direction: column; }
.track-push small { color: var(--muted); }
.track-push.ok { background: color-mix(in srgb, var(--accent) 8%, transparent); }
.ic.ok { color: #2e7d32; } .ic.warn { color: #c77700; } .ic.bad { color: #c62828; } .ic.tip { color: #b8860b; } .ic.star { color: #e0a100; } .ic.muted { color: #999; }
/* Pestañas de arriba: si no caben, se deslizan en vez de agrandar la página */
#tabs.seg { max-width: 100%; overflow-x: auto; scrollbar-width: none; }
#tabs.seg button { white-space: nowrap; flex: none; }

/* Vistas previas de Remarketing: el correo de ejemplo y el celular con la notificación */
.mail-look { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 16px; align-items: start; }
/* Identidad del correo: los colores del mismo tamaño (antes cada uno medía lo que su etiqueta) y el logo con su franja (25/11). */
.mail-look .md-detail input[type=color][data-mb] { width: 72px; height: 34px; padding: 2px; margin-top: 0; flex: none; }
.mail-logo-prev { height: 44px; max-width: 200px; object-fit: contain; padding: 6px; border-radius: 8px; border: 1px solid var(--line); }
.mail-look-prev { position: sticky; top: 12px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 12px; }
.mail-look-prev iframe { display: block; width: 100%; height: 620px; margin-bottom: 6px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.inbox-line { display: flex; flex-direction: column; margin: 8px 0; font-size: 13px; }
.push-look { display: grid; grid-template-columns: minmax(0, 1fr) 240px; gap: 16px; align-items: start; }
.phone-box { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; }
.phone { width: 220px; padding: 7px; border-radius: 30px; background: #111; }
.phone-screen { height: 300px; padding: 12px 8px; border-radius: 24px; overflow: hidden; background: linear-gradient(160deg, #27324a, #5b3f5f); }
.phone-time { margin: 8px 0 16px; text-align: center; color: #fff; font-size: 36px; font-weight: 300; }
.phone-note { display: flex; gap: 8px; padding: 9px; border-radius: 14px; background: #f4f4f5; color: #111; font-size: 12px; text-align: left; }
.phone-note img { flex: none; width: 30px; height: 30px; border-radius: 7px; object-fit: cover; }
.phone-note > div { min-width: 0; }
.phone-note small { display: block; color: #555; font-size: 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pn-title { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; overflow-wrap: anywhere; }
.pn-body { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 4; overflow: hidden; overflow-wrap: anywhere; }
@media (max-width: 1000px) { .mail-look, .push-look { grid-template-columns: minmax(0, 1fr); } .mail-look-prev { position: static; } }

/* Campañas: medidor del asunto, bandeja de entrada, revisión antes de enviar y resultados */
.meter { display: block; margin-top: 5px; }
.meter .bar { display: block; height: 4px; border-radius: 2px; background: var(--line); position: relative; margin-bottom: 3px; }
.meter .bar::after { content: ''; position: absolute; inset: 0; width: var(--w); border-radius: 2px; background: #d32f2f; }
.meter .bar.mid::after { background: #f9a825; } .meter .bar.high::after { background: #2e7d32; }
.meter small { display: block; color: var(--muted); }
.seg.small button { padding: 3px 10px; font-size: 12px; }
.inbox-prev { display: grid; grid-template-columns: 150px 1fr auto; gap: 2px 12px; align-items: baseline; margin-top: 8px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); font-size: 14px; }
.inbox-prev .ip-from { font-weight: 700; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.inbox-prev .ip-subj { font-weight: 600; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.inbox-prev .ip-pre { grid-column: 2; color: var(--muted); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.inbox-prev .ip-when { color: var(--muted); font-size: 12px; }
.wiz-review.mobile .inbox-prev { grid-template-columns: 1fr auto; max-width: 375px; }
.wiz-review.mobile .inbox-prev .ip-subj, .wiz-review.mobile .inbox-prev .ip-pre { grid-column: 1 / -1; white-space: normal; }
.wiz-review.mobile .mb-preview iframe { display: block; width: 375px; max-width: 100%; margin: 0 auto; }
.checklist { list-style: none; padding: 0; margin: 6px 0; }
.checklist li::before { content: '✓ '; color: #2e7d32; font-weight: 700; } .checklist li.no { color: #d32f2f; } .checklist li.no::before { content: '✗ '; }
.reach td { padding: 4px 0; }
.res-kpis .kpi { padding: 12px 16px; min-height: 0; }
.res-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 12px; align-items: start; } .res-grid .md-detail { min-height: 0; }
.when-bars { margin: 4px 0 12px; } .when-row { display: grid; grid-template-columns: 110px 1fr 40px; gap: 8px; align-items: center; font-size: 13px; margin: 3px 0; }
.when-row i { display: block; height: 8px; border-radius: 4px; background: var(--line); position: relative; } .when-row i::after { content: ''; position: absolute; inset: 0; width: var(--w); border-radius: 4px; background: var(--accent); }
.when-row b { text-align: right; }
.linkbtn { border: 0; background: none; padding: 0; font: inherit; color: inherit; cursor: pointer; text-decoration: underline; text-align: left; }

/* Audiencia de la campaña: la tarjeta elegida se marca con un borde y «Elegida» (el tema vidrio pisa el borde normal) */
.aud-grid .md-detail { min-height: 0; } .aud-pick.on { outline: 2px solid var(--accent); outline-offset: -2px; }
.pick-tag { display: none; margin-top: 8px; font-weight: 700; color: var(--accent); } .aud-pick.on .pick-tag { display: block; }

/* Resumen del checkout: "Editar" con el color de la marca, no el azul del navegador */
[data-opencart] { color: var(--accent); }

/* Avisos en iPhone: guía animada para agregar la web al inicio */
.track-push.ios { flex-wrap: wrap; }
.track-push.ios button { flex: none; }
.ios-guide { max-width: 360px; width: calc(100% - 32px); border: 0; border-radius: 20px; padding: 20px; text-align: center; color: var(--text); background: var(--card); }
.ios-guide::backdrop { background: rgba(0, 0, 0, .5); }
.ios-guide h3 { margin: 0 0 4px; }
.ios-guide > p { margin: 0 0 14px; color: var(--muted); font-size: 14px; }
.ios-phone { position: relative; height: 220px; width: 170px; margin: 0 auto 16px; border: 5px solid #111; border-radius: 26px; overflow: hidden; background: #f4f4f4; }
.ios-frame { position: absolute; inset: 0; opacity: 0; animation: iosFrame 10.5s infinite; display: flex; flex-direction: column; justify-content: flex-end; }
.ios-frame.f2 { animation-delay: 3.5s; }
.ios-frame.f3 { animation-delay: 7s; justify-content: flex-start; background: linear-gradient(160deg, #5b7fa6, #2c3e57); padding: 22px 16px; }
@keyframes iosFrame { 0%, 30% { opacity: 1; } 33.34%, 100% { opacity: 0; } }
.ios-bar { display: flex; align-items: center; gap: 6px; padding: 8px; background: #fff; border-top: 1px solid #ddd; }
.ios-url { flex: 1; height: 20px; border-radius: 8px; background: #e9e9ec; }
.ios-share { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; color: #0a7aff; animation: iosTap 1.2s ease-in-out infinite; }
.ios-sheet { background: #fff; border-radius: 12px 12px 0 0; padding: 6px 10px 12px; text-align: left; font-size: 12px; color: #111; }
.ios-sheet div { padding: 8px 6px; border-bottom: 1px solid #eee; }
.ios-sheet div:last-child { border-bottom: 0; }
.ios-sheet .hit { border-radius: 8px; background: #e7f1ff; color: #0a7aff; font-weight: 700; animation: iosTap 1.2s ease-in-out infinite; }
.ios-app { width: 54px; height: 54px; border-radius: 13px; margin: 0 auto; display: grid; place-items: center; background: var(--accent); color: #fff; font-weight: 800; font-size: 22px; overflow: hidden; animation: iosTap 1.2s ease-in-out infinite; }
.ios-app img { width: 100%; height: 100%; object-fit: cover; }
.ios-frame.f3 small { display: block; margin-top: 6px; color: #fff; font-size: 11px; text-align: center; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
@keyframes iosTap { 50% { transform: scale(1.14); } }
.ios-steps { list-style: none; margin: 0 0 16px; padding: 0; text-align: left; display: grid; gap: 8px; font-size: 14px; }
.ios-steps li { display: flex; gap: 10px; padding: 8px 10px; border-radius: 10px; background: var(--bg); }
.ios-steps b { flex: none; }
.ios-guide button { width: 100%; }
@media (prefers-reduced-motion: reduce) { .ios-frame { animation: none; } .ios-frame.f1 { opacity: 1; } .ios-share, .ios-sheet .hit, .ios-app { animation: none; } }

/* Gallina de Chicken Bites asomada abajo a la izquierda (public/gallina.js) */
.gallina { position: fixed; left: 12px; bottom: 0; width: 110px; z-index: 5; pointer-events: none; transition: transform .4s cubic-bezier(.5, -0.4, .5, 1.4); }
.gallina:popover-open { inset: auto auto 0 12px; margin: 0; padding: 0; border: 0; background: none; overflow: visible; }
.gallina svg { display: block; width: 100%; margin-bottom: -30%; }
.gallina svg > * { pointer-events: auto; cursor: pointer; }
body[data-view=checkout] .gallina { display: none; }
.gallina.hide { transform: translateY(105%); }
.gallina .gh-body { fill: #fff; stroke: #1a1a1a; stroke-width: 4.5; stroke-linejoin: round; }
.gallina .gh-comb ellipse { stroke: #1a1a1a; stroke-width: 3.5; }
.gallina .gh-comb .c1 { fill: #f7d23e; } .gallina .gh-comb .c2 { fill: #f28c28; } .gallina .gh-comb .c3 { fill: #e8333c; }
.gallina .gh-mouth { fill: #e8333c; stroke: #1a1a1a; stroke-width: 4; stroke-linejoin: round; }
.gallina .gh-eye { fill: #1a1a1a; transform-box: fill-box; transform-origin: center; animation: cat-blink 3.5s infinite; }
.gallina .gh-crumbs { fill: #d99a3a; opacity: 0; }
.gallina .gh-all { transform-box: view-box; transform-origin: 52px 110px; animation: gh-idle 2.4s ease-in-out infinite alternate; }
.gallina .gh-comb { transform-box: view-box; transform-origin: 48px 34px; }
.gallina.peck .gh-all { animation: gh-peck .32s ease-in-out 4 alternate; }
.gallina.peck .gh-crumbs { opacity: 1; transition: opacity .2s; }
.gallina.jump { animation: gh-jump .5s ease-out 2; }
.gallina.jump .gh-comb { animation: gh-flap .12s ease-in-out infinite alternate; }
.gh-say { position: absolute; left: 70%; bottom: 95%; background: #fff; color: #222; border: 2.5px solid #222; border-radius: 14px 14px 14px 2px;
  padding: 4px 10px; font: 800 15px/1.2 var(--font-title, inherit); white-space: nowrap; animation: gh-pop .25s ease-out; }
.gh-nugget { position: absolute; left: 60%; bottom: 40%; width: 26px; height: 20px; background: radial-gradient(circle at 35% 35%, #f7c463, #c8791f);
  border: 2px solid #7a4512; border-radius: 48% 52% 44% 56% / 55% 45% 55% 45%; animation: gh-nugget 1.4s cubic-bezier(.3, .6, .5, 1) forwards; }
@keyframes gh-idle { from { transform: rotate(-3deg); } to { transform: rotate(4deg); } }
@keyframes gh-peck { from { transform: rotate(0); } to { transform: rotate(16deg); } }
@keyframes gh-jump { 0%, 100% { transform: translateY(0); } 40% { transform: translateY(-34px); } }
@keyframes gh-flap { from { transform: rotate(-8deg); } to { transform: rotate(10deg); } }
@keyframes gh-pop { from { transform: scale(.3); opacity: 0; } }
@keyframes gh-nugget { 0% { transform: translate(0, 0) rotate(0); } 45% { transform: translate(40px, -70px) rotate(200deg); } 100% { transform: translate(80px, 10px) rotate(420deg); opacity: 0; } }
@media (max-width: 760px) { .gallina { width: 80px; left: 6px; } }
/* Franjas a cuadros rojos y blancos por detrás de la web, como el papel de sus sándwiches (public/gallina.js) */
.gh-fondo { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.gh-franja { position: absolute; left: -12%; right: -12%; height: 36px; overflow: hidden; box-shadow: 0 1px 0 rgba(0,0,0,.08), 0 -1px 0 rgba(0,0,0,.08); }
.gh-franja > div { width: calc(100% + 24px); height: 100%; background: repeating-conic-gradient(#e8333c 0 25%, #fff 0 50%) 0 0 / 24px 24px; animation: gh-pasar 3s linear infinite; will-change: transform; }
.gh-franja.f0 { top: 18%; transform: rotate(-5deg); } .gh-franja.f1 { top: 52%; transform: rotate(3deg); } .gh-franja.f1 > div { animation-direction: reverse; } .gh-franja.f2 { top: 84%; transform: rotate(-2deg); }
@keyframes gh-pasar { to { transform: translateX(-24px); } }
@media (prefers-reduced-motion: reduce) { .gh-franja > div { animation: none; } }
.gh-on #menu > h2, .gh-on #menu > p.muted { display: inline-flex; align-items: center; gap: 10px; background: var(--bg); padding: 4px 14px 4px 4px; border-radius: 999px; } /* los títulos se leen sobre las franjas */
/* Pedir ayuda (shell.js): botón al pie del menú y la conversación con Fuego */
#side .help-btn { display: flex; align-items: center; gap: 8px; width: 100%; padding: 8px 14px; border-radius: 999px; background: #1C1D1F; border: 1px solid #2E3033; color: #fff; font-weight: 600; }
#side .help-btn:hover:not(:disabled) { background: #2A2C2F; }
#side .help-btn .badge { margin-left: auto; background: var(--lime, var(--accent)); color: var(--ink, #fff); font-weight: 700; }
.help-form { display: grid; gap: 8px; margin-top: 12px; }
.help-form .error:empty { display: none; }
.help-form textarea { display: block; width: 100%; margin-top: 4px; padding: 8px; border: 1px solid var(--line); border-radius: 8px; font: inherit; background: transparent; color: inherit; resize: vertical; }
.help-form input[type=file] { width: 100%; }
.help-case { border-top: 1px solid var(--line); padding: 10px 0; }
.help-case summary { cursor: pointer; }
.help-msg { margin: 8px 0; padding: 8px 10px; border-radius: 10px; background: color-mix(in srgb, currentColor 6%, transparent); }
.help-msg.fuego { background: color-mix(in srgb, var(--accent) 14%, transparent); }
.help-msg p { margin: 4px 0 0; white-space: pre-line; overflow-wrap: anywhere; }
.help-msg img { display: block; max-width: 100%; max-height: 320px; border-radius: 8px; margin-top: 6px; }
.help-msg img.sam-av { display: inline-block; width: 14px; height: 17px; margin: 0 4px -3px 0; border-radius: 0; } /* la llama de SAM junto a su nombre */
/* Inicio del admin: SAM, la llama de Fuego, y su cuadro grande para preguntarle o pedirle algo */
.inicio { max-width: 680px; margin: 14vh auto 24px; text-align: center; }
.inicio h2 { font-size: 28px; margin: 10px 0 6px; }
.inicio-box { display: grid; gap: 8px; margin-top: 20px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 18px; background: var(--card); text-align: left; box-shadow: 0 6px 24px rgba(0,0,0,.06); }
.inicio .inicio-box textarea { width: 100%; border: 0; outline: 0; padding: 4px 2px; resize: none; font: inherit; font-size: 16px; background: transparent; color: inherit; }
/* Arreglo en la caja que propuso el asistente: el botón «Sí, hazlo» o cómo terminó, debajo de su mensaje. */
.help-msg .help-act { display: block; width: 100%; margin-top: 8px; white-space: normal; text-align: center; }
.help-msg .help-ir { display: inline-block; margin-top: 4px; padding: 6px 14px; border: 1px solid var(--accent); border-radius: 999px; color: inherit; font-weight: 600; text-decoration: none; } /* «Ir a …» de SAM */
.help-msg > small.muted:last-child:not(:first-child) { display: block; margin-top: 6px; }
/* Pedir ayuda como chat: cabecera fija, mensajes que se desplazan y caja para escribir abajo */
dialog.help-dlg { padding: 0; }
/* Al lado y sin bloquear (se abre con show(), no showModal()): en pantallas anchas el panel se corre a la izquierda para que se vea entero
   y se puedan hacer los pasos que da SAM; en el celular queda encima y se cierra con ✕. */
dialog.help-dlg[open] { position: fixed; inset: 0 0 0 auto; z-index: 100; box-shadow: -8px 0 28px rgba(0,0,0,.14); }
@media (min-width: 1100px) { html.chat-al-lado .app { margin-right: min(460px, 100vw); } }
/* Como Sidekick de Shopify (21/11): modo «centro» (lo abre el Inicio) en el lugar de la pantalla al lado del menú, con la conversación en
   una columna centrada; botones de cabecera sin borde (nueva, agrandar o achicar, cerrar); burbujas grises; el cuadro para escribir con
   el botón abajo; lo nuevo aparece suave y la llama de SAM flota con tres puntos mientras piensa. Sin animaciones si el equipo lo pide. */
dialog.help-dlg.centro[open] { inset: 0 0 0 224px; width: auto; max-width: none; margin: 0; border-radius: 0; box-shadow: none; background: var(--app-bg, var(--bg)); animation: aparece .25s ease-out; }
.help-dlg.centro .help-head { border-bottom: 0; }
.help-dlg.centro .help-body, .help-dlg.centro .help-compose { padding-inline: max(16px, calc(50% - 360px)); }
.help-dlg.centro .help-compose { border-top: 0; padding-bottom: 20px; }
.help-dlg.centro .help-chat .help-msg { max-width: 80%; }
@media (max-width: 800px) { dialog.help-dlg.centro[open] { inset: 0; } .help-head .help-ico.help-modo { display: none; } }
.help-head .help-ico { display: grid; place-items: center; flex: none; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 8px; background: transparent; color: inherit; }
.help-head .help-ico:hover { background: color-mix(in srgb, currentColor 8%, transparent); }
.help-head .help-ico .ic { width: 16px; height: 16px; }
.help-msg.fuego { background: color-mix(in srgb, currentColor 5%, transparent); }
.help-chat .help-msg.local { background: color-mix(in srgb, currentColor 10%, transparent); }
.help-compose .help-compose-row { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 6px 8px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 18px; background: var(--glass-strong, var(--card)); box-shadow: 0 4px 18px rgba(0,0,0,.05); }
.help-compose .help-compose-row textarea { background: transparent; grid-column: 1 / -1; grid-row: 1; border: 0; border-radius: 0; padding: 2px; outline: 0; }
.help-compose .help-compose-row .help-attach { grid-row: 2; grid-column: 1; width: 32px; height: 32px; }
.help-compose .help-compose-row > button { grid-row: 2; grid-column: 3; border-radius: 999px; }
.help-msg.pensando { display: flex; align-items: center; gap: 8px; width: fit-content; }
.help-msg.pensando img.sam-av { width: 16px; height: 19px; margin: 0; animation: flota 1.6s ease-in-out infinite; }
.puntos { display: inline-flex; gap: 4px; }
.puntos i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .3; animation: punto 1.2s ease-in-out infinite; }
.puntos i:nth-child(2) { animation-delay: .15s; }
.puntos i:nth-child(3) { animation-delay: .3s; }
.pensando-texto { font-size: 12.5px; font-weight: 500; color: var(--muted); animation: entra .3s ease-out both; } /* «Revisando tu tienda…» si SAM tarda */
.help-chat .entra { animation: entra .28s ease-out both; }
@keyframes aparece { from { opacity: 0; transform: scale(.985); } }
@keyframes entra { from { opacity: 0; transform: translateY(6px); } }
@keyframes punto { 0%, 80%, 100% { opacity: .25; transform: none; } 40% { opacity: .9; transform: translateY(-3px); } }
@keyframes flota { 50% { transform: translateY(-2px) rotate(-4deg); } }
@media (prefers-reduced-motion: reduce) { dialog.help-dlg[open], .help-chat .entra, .help-msg.pensando img.sam-av, .puntos i { animation: none; } }
.inicio-box-pie { display: flex; align-items: center; gap: 8px; }
.inicio-box-pie .sam-mini { width: 18px; height: 22px; margin-right: auto; }
.inicio-recientes { display: inline-flex; align-items: center; gap: 6px; border: 0; background: transparent; color: var(--muted); }
.inicio-recientes .ic { width: 16px; height: 16px; }
/* Para abrir tu local (Inicio, bajo SAM): una tarjeta con el avance y las tareas, cada una se abre con su texto y sus botones (21/11). */
.para-abrir { margin-top: 28px; padding: 18px 20px; border: 1px solid var(--line); border-radius: 18px; background: var(--glass-strong, var(--card)); text-align: left; animation: entra .3s ease-out both; }
.pa-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; font-size: 15px; }
.pa-cuenta { color: var(--muted); font-size: 13px; font-weight: 500; }
.pa-avance { height: 6px; margin: 10px 0 6px; border-radius: 999px; background: color-mix(in srgb, currentColor 10%, transparent); overflow: hidden; }
.pa-avance i { display: block; height: 100%; border-radius: inherit; background: var(--lime, var(--accent)); transition: width .4s ease-out; }
.para-abrir h4 { margin: 16px 0 4px; font-size: 12px; font-weight: 600; color: var(--muted); }
.pa-tarea { border-radius: 12px; }
.pa-tarea summary { display: flex; align-items: center; gap: 10px; padding: 8px 6px; cursor: pointer; list-style: none; font-weight: 600; border-radius: 12px; }
.pa-tarea summary::-webkit-details-marker { display: none; }
.pa-tarea summary:hover { background: color-mix(in srgb, currentColor 5%, transparent); }
.pa-tarea[open] { background: color-mix(in srgb, currentColor 4%, transparent); }
.pa-check { display: grid; place-items: center; flex: none; width: 20px; height: 20px; border: 1.5px dashed color-mix(in srgb, currentColor 45%, transparent); border-radius: 50%; }
.pa-tarea.hecha .pa-check { border: 0; background: var(--lime, var(--accent)); color: #fff; }
.pa-tarea.hecha summary { color: var(--muted); font-weight: 500; }
.pa-check .ic { width: 13px; height: 13px; stroke-width: 3; }
.pa-tarea p { margin: 0 6px 0 36px; font-size: 14px; font-weight: 500; color: var(--muted); }
.pa-tarea[open] p, .pa-tarea[open] .pa-acciones { animation: entra .22s ease-out both; }
.pa-acciones { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 6px 12px 36px; }
.pa-link { display: flex; gap: 8px; margin: 10px 6px 0 36px; }
#main .pa-link input { flex: 1; min-width: 0; padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--glass-strong, var(--card)); } /* #main: gana al estilo de campos del tema */
.pa-link button { border-radius: 999px; }
.pa-tarea[open] .pa-link { animation: entra .22s ease-out both; }
.pa-acciones button { display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; }
.pa-acciones .sam-mini { width: 13px; height: 16px; }
.pa-listo { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 0; font-weight: 600; }
.pa-listo .ic { width: 18px; height: 18px; color: var(--lime, var(--accent)); }
/* Menú: días de prueba gratis o mes vencido, con el enlace a Tu cuenta (cuenta.js) */
.cuenta-chip { display: flex; flex-direction: column; gap: 2px; margin: 0 12px 10px; padding: 8px 12px; border-radius: 12px; font-size: 12px; text-decoration: none;
  color: inherit; background: color-mix(in srgb, var(--lime, var(--accent)) 16%, transparent); border: 1px solid color-mix(in srgb, var(--lime, var(--accent)) 40%, transparent); }
.cuenta-chip b { font-size: 13px; }
/* Traer la carta desde el link: cómo va, el resultado y lo que hay que revisar */
.pa-import { margin: 0 0 16px; padding: 12px 14px; border-radius: 14px; background: color-mix(in srgb, currentColor 5%, transparent); font-size: 14px; }
.pa-import p { margin: 0 0 6px; } .pa-import ul { margin: 0 0 8px; padding-left: 20px; } .pa-import li { margin: 4px 0; }
.pa-import .ic { width: 16px; height: 16px; vertical-align: -3px; color: var(--lime, var(--accent)); }
.pa-import.error { background: color-mix(in srgb, #e5484d 9%, transparent); }
.pa-import .pa-acciones { margin: 8px 0 0; }
.pa-import .pa-acciones .btn { display: inline-flex; align-items: center; padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; color: inherit; }
.pa-girando { display: inline-block; width: 12px; height: 12px; margin-right: 8px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; vertical-align: -1px; animation: gira .8s linear infinite; }
@keyframes gira { to { transform: rotate(360deg); } }
/* Sin web: subir fotos o PDF de la carta, o la carta de ejemplo */
.pa-sin-web { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 10px 6px 0 36px; font-size: 14px; color: var(--muted); }
.pa-sin-web .btn-like, .pa-sin-web button { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border: 1px solid var(--line); border-radius: 999px; font: inherit; font-weight: 600; color: var(--text, inherit); background: transparent; cursor: pointer; }
.pa-sin-web .btn-like .ic { width: 15px; height: 15px; }
.pa-sin-web .primary { color: #fff; background: var(--lime, var(--accent)); border-color: transparent; }
@media (prefers-reduced-motion: reduce) { .para-abrir, .pa-tarea[open] p, .pa-tarea[open] .pa-acciones { animation: none; } .pa-girando { animation-duration: 3s; } }
/* Barra «Trabaja con SAM» abajo al centro en las otras pantallas del admin, como Sidekick (21/11); se esconde con el chat abierto.
   Es un textarea (no un input) para que el estilo de los campos del tema no le ponga borde ni fondo. */
.sam-barra { position: fixed; bottom: 16px; left: calc(224px + (100vw - 224px) / 2); transform: translateX(-50%); z-index: 90; display: flex; align-items: center; gap: 8px;
  width: min(400px, calc(100vw - 256px)); padding: 6px 6px 6px 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--glass-strong, var(--card)); box-shadow: 0 8px 28px rgba(0,0,0,.12); animation: sube-barra .3s ease-out both; }
@keyframes sube-barra { from { opacity: 0; transform: translate(-50%, 8px); } }
form.sam-barra textarea, form.sam-barra textarea:focus { flex: 1; min-width: 0; height: 32px; padding: 7px 0; border: 0; outline: 0; resize: none; overflow: hidden; background: transparent; color: inherit; font: inherit; line-height: 18px; white-space: nowrap; }
.sam-barra .sam-mini { width: 16px; height: 19px; flex: none; }
.sam-barra .help-ico { display: grid; place-items: center; flex: none; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 999px; background: transparent; color: var(--muted); }
.sam-barra .help-ico:hover { background: color-mix(in srgb, currentColor 10%, transparent); }
.sam-barra .help-ico .ic { width: 16px; height: 16px; }
/* Enviar: en el celular no hay Enter que mande (22/11, captura del usuario). Siempre a la vista (escondido sin texto no lo encontraba):
   gris con la barra vacía y naranja al escribir. Flecha rellena y redondeada en un círculo lleno, como la de Sidekick (22/11, pedido del usuario). */
.sam-barra .sam-enviar, .sam-barra .sam-enviar:hover { width: 34px; height: 34px; color: var(--accent-text, #fff);
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 78%, #fff), var(--accent) 60%);
  box-shadow: 0 3px 10px color-mix(in srgb, var(--accent) 50%, transparent), inset 0 1px 0 rgba(255,255,255,.35); transition: background .15s, box-shadow .15s, transform .12s; }
.sam-barra .sam-enviar .ic { width: 20px; height: 20px; fill: currentColor; stroke: none; }
.sam-barra .sam-enviar:active { transform: scale(.88); }
form.sam-barra:has(textarea:placeholder-shown) .sam-enviar { background: color-mix(in srgb, var(--muted) 22%, transparent); color: var(--muted); box-shadow: none; }
html.chat-abierto .sam-barra { display: none; }
html.con-sam .content { padding-bottom: 72px; } /* que la barra no tape lo último de la pantalla */
@media (max-width: 800px) { .sam-barra { left: 50%; width: calc(100vw - 32px); } }
/* Con lista y detalle (Carta, Clientes, Turnos), sobre el detalle: al medio tapaba «Nuevo producto» y su «+» al pie de la lista (23/11).
   596 px = menú 224 + margen 16 + lista 340 + espacio 16. */
@media (min-width: 901px) { html.con-sam:has(.md-list) .sam-barra { left: calc(596px + (100vw - 612px) / 2); width: min(400px, calc(100vw - 644px)); } }
@media (prefers-reduced-motion: reduce) { .sam-barra { animation: none; } }
/* Plan Web: lo del plan Completo con candado en el menú y en las pestañas, y la ventana «Pasar al plan completo» (21/11). */
.bloqueado { opacity: .55; }
.bloqueado:hover { opacity: .85; }
.bloqueado .candado { width: 13px; height: 13px; margin-left: auto; }
.bloqueado .pronto { margin-left: auto; font-size: 11px; }
.tabs .bloqueado .candado { margin-left: 4px; vertical-align: -1px; }
dialog.plan-dlg { max-width: 460px; }
dialog.plan-dlg h3 { display: flex; align-items: center; gap: 8px; margin-top: 0; }
dialog.plan-dlg h3 .ic { width: 18px; height: 18px; color: var(--lime, var(--accent)); }
/* Letra con más cuerpo en SAM (pedido del usuario, 21/11: «la letra tan fina no me gusta»): medio en vez de normal, y un poco más grande. */
.inicio p, .inicio .inicio-box textarea, form.sam-barra textarea, .help-dlg .help-msg p, .help-dlg .help-note, .help-dlg .help-body > p,
.help-compose .help-compose-row textarea, .help-dlg .help-row { font-weight: 500; }
.inicio p, .help-dlg .help-msg p, .help-compose .help-compose-row textarea { font-size: 14.5px; line-height: 1.5; }
.inicio .inicio-box textarea, form.sam-barra textarea { font-size: 15px; }
dialog.help-dlg[open] { display: flex; flex-direction: column; }
.help-head { display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.help-head .help-title { flex: 1; min-width: 0; display: grid; gap: 2px; }
.help-head .help-title b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.help-head .help-title small:empty { display: none; }
.help-body { flex: 1; overflow-y: auto; padding: 12px 16px; }
.help-dlg .help-new { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; }
.help-dlg .help-row { display: grid; gap: 4px; width: 100%; margin-top: 8px; padding: 10px 12px; border-radius: 12px; text-align: left; font-weight: 400; }
.help-row-top { display: flex; justify-content: space-between; gap: 8px; }
.help-row-top b, .help-row-sub small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.help-row-top small { flex: none; }
.help-row-sub { display: flex; align-items: center; gap: 6px; min-width: 0; }
.help-chat { display: flex; flex-direction: column; }
.help-chat .help-msg { max-width: 85%; margin-right: auto; }
.mine-local .help-msg.local, .mine-fuego .help-msg.fuego { margin-left: auto; margin-right: 0; }
.help-note { align-self: center; font-size: 13px; color: var(--muted); margin: 8px 0; text-align: center; }
.help-compose { display: grid; gap: 6px; padding: 10px 16px; border-top: 1px solid var(--line); }
.help-compose .error:empty { display: none; }
.help-compose-row { display: flex; align-items: flex-end; gap: 8px; }
.help-compose textarea { flex: 1; min-width: 0; max-height: 140px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 12px; font: inherit; background: transparent; color: inherit; resize: none; }
.help-attach { display: grid; place-items: center; flex: none; width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 50%; cursor: pointer; }
.help-urgent { display: flex; align-items: flex-start; gap: 8px; font-size: 14px; }
.help-file { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0; font-size: 13px; }
.help-thumb { position: relative; display: block; }
.help-thumb img { display: block; width: 56px; height: 56px; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); }
.help-thumb-video { display: grid; place-items: center; gap: 2px; width: 56px; height: 56px; border-radius: 10px; border: 1px solid var(--line); font-size: 11px; }
.help-thumb button { position: absolute; top: -6px; right: -6px; width: 20px; height: 20px; padding: 0; border-radius: 50%; font-size: 11px; line-height: 1; }
.badge.urgent, .vidrio .badge.urgent { background: #d92d20; color: #fff; } /* Pedir ayuda: caso urgente */
.help-dlg .help-row { grid-template-columns: minmax(0, 1fr); }
.help-row-top b, .help-row-sub small { min-width: 0; }
.help-row-sub .badge { flex: none; white-space: nowrap; }
.help-body { overflow-x: hidden; }

/* Tótem de autoatención (/totem): sin cuenta, delivery ni pie de página; número grande al terminar. */
.shop.totem .top .icons > .account-link, .totem .burger, .totem .navlinks, .totem #mode, .totem .site-foot { display: none; }
.totem { user-select: none; -webkit-user-select: none; }
.totem-done { text-align: center; max-width: 560px; margin: 40px auto; }
.totem-num { font-size: 72px; font-weight: 800; letter-spacing: 2px; margin: 4px 0 12px; }
.totem-closed { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 16px; background: rgba(0, 0, 0, .65); }
.totem-closed .card { max-width: 520px; text-align: center; }
/* Carta QR de la mesa (/mesa/CÓDIGO): sin cuenta ni menú de la web. «Solo carta»: sin carrito ni botón para agregar. */
.shop.en-mesa .top .icons > .account-link, .en-mesa .burger, .en-mesa .navlinks, .en-mesa #notice, .en-mesa #banners { display: none !important; } /* avisos y banners de la web (delivery, cupones) no aplican en la mesa */
.solo-carta .cartbtn, .solo-carta .quick, .solo-carta #product .sheet-foot, .solo-carta #product .field { display: none !important; }
/* Mesas: la mesa que pidió por su QR y espera que la confirmen. */
.mesa.qr { border: 2px solid #e8590c; animation: qrpulse 1s ease-in-out infinite alternate; } .mesa.qr span { color: #e8590c; font-weight: 600; }
@keyframes qrpulse { to { border-color: transparent; } }
@media (prefers-reduced-motion: reduce) { .mesa.qr { animation: none; } }
.mesa-llamar { display: grid; gap: 8px; margin-top: 12px; } .mesa-llamar button { justify-content: center; width: 100%; } /* carta QR: pedir la cuenta, llamar al garzón */
/* Mesas que llamaron al garzón o pidieron la cuenta desde su QR (mesas.js) */
.mcalls { display: grid; gap: 8px; padding: 0 16px; grid-column: 1 / -1; } .mcalls p.card { margin: 0; align-items: center; gap: 10px; border: 2px solid #e8590c; } .mcalls p span { flex: 1; }

/* Estado de tu tienda (rediseño 24/11, pedido del usuario: «visualmente floja»): arriba un aro que se llena con lo que está bien y las
   tres cuentas; abajo una tarjeta por grupo con su resumen y cada revisión como una fila con su ícono de color y su botón. */
.est-hero, .est-fila, .est-chip { --c: #2e7d32; }
.est-hero.warn, .est-fila.warn, .est-chip.warn { --c: #d97706; }
.est-hero.bad, .est-fila.bad, .est-chip.bad { --c: #d32f2f; }
.est-fila.off, .est-chip.off { --c: #8a8e98; }
.md-detail.est-hero { display: flex; align-items: center; gap: 24px; min-height: 0; padding: 22px 24px; }
.est-aro { flex: none; width: 112px; height: 112px; border-radius: 50%; display: grid; place-content: center; text-align: center;
  background: radial-gradient(closest-side, var(--card, #fff) 79%, transparent 81%), conic-gradient(#2e7d32 var(--a), #f59e0b 0 var(--b), #d32f2f 0);
  filter: drop-shadow(0 6px 14px color-mix(in srgb, var(--c) 30%, transparent)); }
.est-aro b { font-size: 32px; line-height: 1; } .est-aro small { font-size: 11px; color: var(--muted); }
.est-hero h2 { margin: 0 0 4px; font-size: 22px; } .est-hero p { margin: 0; }
.est-cuentas { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.est-chip { display: inline-flex; align-items: baseline; gap: 5px; padding: 5px 12px; border-radius: 999px; font-size: 12.5px; font-weight: 600; white-space: nowrap;
  background: color-mix(in srgb, var(--c) 13%, transparent); color: var(--c); }
.est-chip b { font-size: 14px; }
.est-grupos { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(380px, 100%), 1fr)); gap: 16px; margin-top: 16px; align-items: start; }
.md-detail.est-grupo { min-height: 0; margin: 0; }
.est-grupo header { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 10px; } .est-grupo h3 { margin: 0; }
.est-filas { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.est-fila { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 12px; padding: 10px 12px; border-radius: 14px; background: color-mix(in srgb, currentColor 3%, transparent); }
.est-fila.warn, .est-fila.bad { background: color-mix(in srgb, var(--c) 8%, transparent); }
.est-fila.off .est-txt { color: var(--muted); }
.est-ico { flex: none; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 16%, transparent); color: var(--c); }
.est-ico .ic { width: 16px; height: 16px; color: inherit; }
.est-txt { flex: 1; min-width: 180px; }
@media (max-width: 600px) { .md-detail.est-hero { gap: 16px; padding: 16px; } .est-aro { width: 88px; height: 88px; } .est-aro b { font-size: 26px; } .est-hero h2 { font-size: 18px; } }
li.est-fila.ok, li.est-fila.warn, li.est-fila.bad { color: inherit; } /* .ok y compañía pintan el texto en otras pantallas; aquí el color va solo en el ícono */
.est-fila a.primary { color: var(--btn-text, #fff); }
