/* Chekar — sistema visual (04_UI_UX_DESIGN_BRIEF.md §3) */
:root {
  --bg: #F2E9D9; --surface: #FBF6EC; --surface-2: #EADFCB; --border: #D8C8AC;
  --text: #2A2017; --text-2: #574735; --text-3: #6A5944;
  --primary: #0E6A62; --primary-hover: #0A5650; --on-primary: #FFF8EC; --link: #0E6A62;
  --ok: #2F6B3C; --ok-bg: #DFEAD0; --warn: #8A5300; --warn-bg: #F6E3BF; --danger: #A2372A; --danger-bg: #F5D9CF;
  --info: #0E6A62; --info-bg: #D9E8DF;
  --ink: #A2372A;           /* tinta de sello */
  --paper: #F7EFDF;         /* cartulina de la tarjeta */
  --band: #E9DDC6;          /* franjas alternas */
  --shadow: 0 1px 2px rgba(60,40,15,.08), 0 10px 28px -12px rgba(60,40,15,.25);
  --navy-900: var(--bg); --navy-800: var(--surface); --navy-700: var(--surface-2);
  --teal-500: var(--primary); --teal-600: var(--primary-hover); --teal-700: var(--primary); --mint-400: var(--primary-hover);
  --focus: var(--primary);
  --r-sm: 8px; --r-md: 12px; --r-lg: 16px;
  --font: "Manrope", "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #211A13; --surface: #2B2219; --surface-2: #352A1F; --border: #4B3D2D;
  --text: #F1E5D1; --text-2: #CDBB9F; --text-3: #A8957A;
  --primary: #5CC4B3; --primary-hover: #7AD3C4; --on-primary: #14231F; --link: #6FD0C0;
  --ok: #9CCB8A; --ok-bg: #26331F; --warn: #EFB35A; --warn-bg: #3A2B12; --danger: #F08C78; --danger-bg: #3D1F18;
  --info: #6FD0C0; --info-bg: #1C302C;
  --ink: #F08C78; --paper: #2F261C; --band: #281F17;
  --shadow: 0 1px 2px rgba(0,0,0,.35), 0 12px 30px -14px rgba(0,0,0,.6);
  --navy-900: var(--bg); --navy-800: var(--surface); --navy-700: var(--surface-2);
  --teal-500: var(--primary); --teal-600: var(--primary-hover); --teal-700: var(--primary); --mint-400: var(--primary-hover);
  --focus: var(--primary);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { font-family: var(--font); font-size: 15px; line-height: 1.5; background: var(--bg); color: var(--text); -webkit-font-smoothing: antialiased; }
a { color: var(--link); }
img, svg { max-width: 100%; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5rem; letter-spacing: -.01em; }
h1 { font-size: 1.6rem; } h2 { font-size: 1.2rem; } h3 { font-size: 1rem; }
p { margin: 0 0 .75rem; }
.num, td.num, .tabular { font-variant-numeric: tabular-nums; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.muted { color: var(--text-2); } .small { font-size: .85rem; } .xs { font-size: .78rem; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .85em; }
.row { display: flex; gap: .75rem; align-items: center; flex-wrap: wrap; }
.between { justify-content: space-between; }
.stack > * + * { margin-top: 1rem; }
.grid { display: grid; gap: 1rem; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.grid-kpi { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.right { text-align: right; } .center { text-align: center; }
hr { border: 0; border-top: 1px solid var(--border); margin: 1.25rem 0; }

/* Marca */
.brand { display: inline-flex; align-items: center; gap: .55rem; text-decoration: none; color: inherit; }
.brand img { width: 30px; height: 30px; }
.brand-name { font-weight: 800; font-size: 1.15rem; letter-spacing: -.02em; }
.brand-by { font-size: .62rem; letter-spacing: .25em; color: var(--text-2); display: block; margin-top: -3px; }

/* Botones */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .45rem; min-height: 44px; padding: .55rem 1rem; border-radius: var(--r-sm); border: 1px solid var(--border); background: var(--surface); color: var(--text); font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--surface-2); }
.btn-primary { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.btn-primary:hover { background: var(--primary-hover); }
.btn-danger { color: var(--danger); border-color: var(--danger); background: transparent; }
.btn-ghost { background: transparent; border-color: transparent; }
.btn-sm { min-height: 36px; padding: .3rem .7rem; font-size: .88rem; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; }
.btn-block { width: 100%; }

/* Formularios */
label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: .3rem; }
.field { margin-bottom: 1rem; }
.hint { font-size: .8rem; color: var(--text-2); margin-top: .25rem; }
input:not([type]), input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], input[type=time], input[type=datetime-local], input[type=search], input[type=tel], input[type=file], select, textarea {
  width: 100%; min-height: 44px; padding: .55rem .75rem; border: 1px solid var(--border); border-radius: var(--r-sm); background: var(--surface); color: var(--text); font: inherit;
}
textarea { min-height: 90px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 3px solid color-mix(in srgb, var(--focus) 45%, transparent); border-color: var(--teal-500); }
.check { display: flex; gap: .5rem; align-items: center; font-weight: 500; }
.check input { width: 20px; height: 20px; }
.days { display: flex; gap: .35rem; flex-wrap: wrap; }
.days label { display: inline-flex; align-items: center; gap: .3rem; padding: .35rem .6rem; border: 1px solid var(--border); border-radius: 999px; font-weight: 600; cursor: pointer; margin: 0; }
.days input { width: 16px; height: 16px; }
.error { color: var(--danger); font-size: .85rem; margin-top: .25rem; }
.form-grid { display: grid; gap: 0 1rem; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }

/* Superficies */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-md); padding: 1.25rem; box-shadow: var(--shadow); }
.card-h { display: flex; justify-content: space-between; align-items: center; gap: .75rem; margin-bottom: 1rem; flex-wrap: wrap; }
.card-h h2 { margin: 0; }
.alert { padding: .8rem 1rem; border-radius: var(--r-sm); margin-bottom: 1rem; border: 1px solid transparent; }
.alert-ok { background: var(--ok-bg); color: var(--ok); border-color: color-mix(in srgb, var(--ok) 30%, transparent); }
.alert-err { background: var(--danger-bg); color: var(--danger); border-color: color-mix(in srgb, var(--danger) 30%, transparent); }
.alert-warn { background: var(--warn-bg); color: var(--warn); }
.alert-info { background: var(--info-bg); color: var(--info); }

/* Badges: siempre con texto, nunca solo color */
.badge { display: inline-flex; align-items: center; gap: .3rem; padding: .12rem .55rem; border-radius: 999px; font-size: .78rem; font-weight: 700; background: var(--surface-2); color: var(--text-2); white-space: nowrap; }
.badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.b-ok { background: var(--ok-bg); color: var(--ok); }
.b-warn { background: var(--warn-bg); color: var(--warn); }
.b-danger { background: var(--danger-bg); color: var(--danger); }
.b-info { background: var(--info-bg); color: var(--info); }

/* Tablas */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--r-md); background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { padding: .6rem .75rem; text-align: left; border-bottom: 1px solid var(--border); vertical-align: middle; }
th { font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: var(--text-2); background: var(--surface-2); white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: color-mix(in srgb, var(--surface-2) 60%, transparent); }
.empty { padding: 2rem; text-align: center; color: var(--text-2); }

/* KPIs */
.kpi { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-md); padding: 1rem; }
.kpi .v { font-size: clamp(1.35rem, 2.2vw, 1.9rem); font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.1; }
.kpi .l { font-size: .82rem; color: var(--text-2); font-weight: 600; }
.kpi.k-warn .v { color: var(--warn); } .kpi.k-danger .v { color: var(--danger); } .kpi.k-ok .v { color: var(--ok); } .kpi.k-info .v { color: var(--info); }

/* Shell admin */
.shell { display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; }
.sidebar { background: var(--navy-900); color: var(--text); padding: 1rem .75rem; position: sticky; top: 0; height: 100vh; overflow-y: auto; display: flex; flex-direction: column; gap: 1rem; }
.sidebar .brand-name { color: var(--text); } .sidebar .brand-by { color: var(--text-2); }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a { display: flex; align-items: center; gap: .6rem; padding: .55rem .7rem; border-radius: var(--r-sm); color: var(--text-2); text-decoration: none; font-weight: 600; font-size: .92rem; }
.nav a:hover { background: var(--navy-700); color: var(--text); }
.nav a[aria-current="page"] { background: color-mix(in srgb, var(--teal-500) 22%, var(--navy-900)); color: var(--text); box-shadow: inset 3px 0 0 var(--teal-500); }
.nav .count { margin-left: auto; background: var(--teal-500); color: var(--on-primary); border-radius: 999px; padding: 0 .45rem; font-size: .75rem; font-weight: 800; }
.nav-label { font-size: .7rem; letter-spacing: .12em; text-transform: uppercase; color: var(--text-3); padding: .5rem .7rem .2rem; }
.main { min-width: 0; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: .75rem; padding: .75rem 1.5rem; border-bottom: 1px solid var(--border); background: var(--surface); position: sticky; top: 0; z-index: 10; flex-wrap: wrap; }
.content { padding: 1.5rem; max-width: 1760px; } /* aprovecha monitores anchos; las páginas de lectura limitan su propio ancho */
.page-h { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; margin-bottom: 1.25rem; flex-wrap: wrap; }
.page-h p { margin: 0; color: var(--text-2); }
.menu-toggle { display: none; }
.icon { width: 18px; height: 18px; flex: none; }

@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar { position: fixed; inset: 0 auto 0 0; width: 260px; z-index: 50; transform: translateX(-100%); transition: transform .2s; }
  .sidebar.open { transform: none; box-shadow: 0 0 0 100vmax rgba(0,0,0,.45); }
  .menu-toggle { display: inline-flex; }
  .content { padding: 1rem; }
  .topbar { padding: .6rem 1rem; }
}

/* Empleado (mobile first) */
.emp { max-width: 560px; margin: 0 auto; min-height: 100vh; padding-bottom: 84px; }
.emp-header { display: flex; justify-content: space-between; align-items: center; padding: .9rem 1rem; }
.emp-header > .row { gap: .15rem; flex-wrap: nowrap; }
.avatar { width: 38px; height: 38px; border-radius: 50%; background: linear-gradient(135deg, var(--teal-500), var(--mint-400)); color: var(--on-primary); font-weight: 800; display: grid; place-items: center; font-size: .9rem; }
.emp-body { padding: 0 1rem; }
.clock { font-size: 3rem; font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: -.03em; line-height: 1; }
.state-pill { display: inline-flex; align-items: center; gap: .5rem; padding: .4rem .8rem; border-radius: 999px; font-weight: 700; background: var(--surface-2); }
.state-pill .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--text-3); }
.state-IN .dot { background: var(--ok); } .state-BREAK .dot { background: var(--warn); }
.cta { width: 100%; min-height: 64px; font-size: 1.15rem; border-radius: var(--r-md); }
.cta-secondary { min-height: 52px; }
.receipt { border-radius: var(--r-md); padding: 1rem; margin-top: 1rem; border: 1px solid var(--border); background: var(--surface); }
.receipt[data-decision="ACCEPTED"] { border-color: var(--ok); background: var(--ok-bg); }
.receipt[data-decision="REVIEW"] { border-color: var(--warn); background: var(--warn-bg); }
.receipt[data-decision="REJECTED"], .receipt[data-decision="ERROR"] { border-color: var(--danger); background: var(--danger-bg); }
.receipt .t { font-weight: 800; font-size: 1.05rem; }
.bottom-nav { position: fixed; bottom: 0; left: 0; right: 0; background: var(--surface); border-top: 1px solid var(--border); display: flex; justify-content: center; padding-bottom: env(safe-area-inset-bottom, 0); z-index: 20; }
.bottom-nav a { flex: 1; max-width: 186px; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: .55rem .25rem; color: var(--text-2); text-decoration: none; font-size: .75rem; font-weight: 700; min-height: 56px; }
.bottom-nav a[aria-current="page"] { color: var(--primary); }
.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; justify-content: space-between; align-items: center; gap: .75rem; padding: .7rem 0; border-bottom: 1px solid var(--border); }
.list li:last-child { border-bottom: 0; }

/* Auth / público */
.auth { min-height: 100vh; display: grid; place-items: center; padding: 1.5rem 1rem; background: radial-gradient(1200px 600px at 10% -10%, color-mix(in srgb, var(--teal-500) 16%, transparent), transparent), var(--bg); }
.auth .card { width: 100%; max-width: 440px; }
.steps { display: flex; gap: .4rem; margin-bottom: 1rem; }
.steps span { flex: 1; height: 5px; border-radius: 999px; background: var(--border); }
.steps span.on { background: linear-gradient(90deg, var(--teal-500), var(--mint-400)); }
.hero { background: var(--navy-900); color: var(--text); }
.hero-in { max-width: 1100px; margin: 0 auto; padding: 1rem 1.25rem 4rem; }
.hero h1 { font-size: clamp(2rem, 5vw, 3.2rem); margin: 3rem 0 1rem; max-width: 18ch; }
.hero .lead { font-size: 1.15rem; color: var(--text-2); max-width: 52ch; }
.hero .brand-name { color: var(--text); }
.grad { background: linear-gradient(90deg, var(--primary), var(--primary-hover)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.section { max-width: 1100px; margin: 0 auto; padding: 3rem 1.25rem; }
.feature h3 { margin-top: .5rem; }

/* Kiosco */
.kiosk { min-height: 100vh; display: grid; grid-template-rows: auto 1fr auto; background: var(--navy-900); color: var(--text); }
.kiosk .brand-name { color: var(--text); }
.kiosk-top { display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.5rem; }
.kiosk-main { display: grid; place-items: center; padding: 1rem; }
.kiosk-panel { width: 100%; max-width: 460px; text-align: center; }
.kiosk .clock { font-size: clamp(3rem, 9vw, 5rem); color: var(--text); }
.kiosk input { background: var(--navy-800); border-color: var(--navy-700); color: var(--text); font-size: 1.4rem; text-align: center; min-height: 60px; letter-spacing: .15em; }
.pinpad { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; margin: 1rem 0; }
.pinpad button { min-height: 68px; font-size: 1.6rem; font-weight: 800; border-radius: var(--r-md); border: 1px solid var(--navy-700); background: var(--navy-800); color: var(--text); cursor: pointer; }
.pinpad button:active { background: var(--navy-700); }
.kiosk .btn-primary { background: var(--teal-500); border-color: var(--teal-500); color: var(--on-primary); }
.kiosk .btn { min-height: 60px; font-size: 1.1rem; }
.kiosk-msg { font-size: 1.3rem; font-weight: 700; padding: 1.25rem; border-radius: var(--r-md); }
.kiosk-msg.ok { background: var(--ok-bg); color: var(--ok); } .kiosk-msg.warn { background: var(--warn-bg); color: var(--warn); } .kiosk-msg.err { background: var(--danger-bg); color: var(--danger); }
.kiosk-foot { padding: .75rem 1.5rem; color: var(--text-2); font-size: .85rem; display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem; }

#map { height: 320px; border-radius: var(--r-md); border: 1px solid var(--border); margin-bottom: 1rem; }
.pagination { display: flex; gap: .35rem; flex-wrap: wrap; margin-top: 1rem; }
.pagination a, .pagination span { padding: .35rem .7rem; border: 1px solid var(--border); border-radius: var(--r-sm); text-decoration: none; }
.diff { font-size: .8rem; background: var(--surface-2); padding: .4rem .6rem; border-radius: var(--r-sm); white-space: pre-wrap; word-break: break-word; max-width: 520px; }
details summary { cursor: pointer; font-weight: 600; }
@media print { .sidebar, .topbar, .no-print { display: none !important; } .shell { display: block; } }

/* ── Movimiento, modales y pulido (beta) ─────────────────────────────── */
:root { --ease: cubic-bezier(.2,.8,.2,1); --t-fast: 140ms; --t-med: 240ms; --t-slow: 420ms; }
body, .card, .kpi, .topbar, .bottom-nav, .table-wrap, input, select, textarea, .btn {
  transition: background-color var(--t-med) var(--ease), border-color var(--t-med) var(--ease), color var(--t-med) var(--ease), box-shadow var(--t-med) var(--ease), transform var(--t-fast) var(--ease);
}
.btn:active:not([disabled]) { transform: scale(.97); }
.btn-primary { box-shadow: 0 1px 0 rgba(255,255,255,.08) inset, 0 6px 16px -8px color-mix(in srgb, var(--primary) 70%, transparent); }
a.card:hover, .card.hoverable:hover, .kpi:hover { transform: translateY(-2px); box-shadow: 0 2px 4px rgba(60,40,15,.06), 0 12px 28px -10px rgba(60,40,15,.18); }
a.card { display: block; color: inherit; text-decoration: none; }
.nav a { transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease), padding-left var(--t-fast) var(--ease); }
.nav a:hover { padding-left: .9rem; }
.bottom-nav a .icon { transition: transform var(--t-med) var(--ease); }
.bottom-nav a[aria-current="page"] .icon { transform: translateY(-2px) scale(1.12); }

/* Entrada escalonada del contenido principal */
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes pop { 0% { opacity: 0; transform: scale(.94); } 60% { opacity: 1; transform: scale(1.02); } 100% { transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pulse-ring { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--primary) 45%, transparent); } 100% { box-shadow: 0 0 0 16px transparent; } }
@keyframes shimmer { from { background-position: -400px 0; } to { background-position: 400px 0; } }
.content > *, .emp-body > * { animation: rise var(--t-slow) var(--ease) both; }
.content > *:nth-child(2), .emp-body > *:nth-child(2) { animation-delay: 50ms; }
.content > *:nth-child(3), .emp-body > *:nth-child(3) { animation-delay: 100ms; }
.content > *:nth-child(4), .emp-body > *:nth-child(4) { animation-delay: 150ms; }
.content > *:nth-child(n+5), .emp-body > *:nth-child(n+5) { animation-delay: 200ms; }
.grid > .kpi, .grid > .card { animation: rise var(--t-slow) var(--ease) both; }
.grid > :nth-child(2) { animation-delay: 60ms; } .grid > :nth-child(3) { animation-delay: 120ms; }
.grid > :nth-child(4) { animation-delay: 180ms; } .grid > :nth-child(n+5) { animation-delay: 240ms; }
.receipt, .alert, .kiosk-msg { animation: pop var(--t-slow) var(--ease) both; }
.cta.btn-primary:not([disabled]) { animation: pulse-ring 2.2s var(--ease) infinite; }
.skeleton { border-radius: var(--r-sm); background: linear-gradient(90deg, var(--surface-2) 0, var(--border) 50%, var(--surface-2) 100%); background-size: 800px 100%; animation: shimmer 1.4s linear infinite; min-height: 1em; }

/* Modales (<dialog>) */
dialog.modal { border: 1px solid var(--border); border-radius: var(--r-lg); padding: 1.5rem; width: min(440px, calc(100vw - 32px)); background: var(--surface); color: var(--text); box-shadow: 0 24px 60px -12px rgba(0,0,0,.35); }
dialog.modal[open] { animation: pop var(--t-slow) var(--ease) both; }
dialog.modal::backdrop { background: rgba(33,26,19,.55); backdrop-filter: blur(3px); animation: fade var(--t-med) ease both; }
.howto { padding-left: 1.2rem; margin: 0 0 1rem; } .howto li { margin-bottom: .45rem; }

/* Icono del tema: luna en claro, sol en oscuro */
[data-theme-toggle] .i-sun { display: none; }
:root[data-theme="dark"] [data-theme-toggle] .i-sun { display: block; }
:root[data-theme="dark"] [data-theme-toggle] .i-moon { display: none; }

/* Estados vacíos */
.empty-state { text-align: center; padding: 2.5rem 1rem; color: var(--text-2); }
.empty-state .icon { width: 40px; height: 40px; color: var(--teal-500); margin-bottom: .5rem; }
.empty-state h3 { color: var(--text); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; scroll-behavior: auto !important; }
}

/* ── Guía interactiva ───────────────────────────────────────────────── */
.tour-spot { position: fixed; z-index: 90; border-radius: 12px; box-shadow: 0 0 0 9999px rgba(33,26,19,.62); pointer-events: none;
  outline: 2px solid var(--teal-500); outline-offset: 0; transition: top var(--t-slow) var(--ease), left var(--t-slow) var(--ease), width var(--t-slow) var(--ease), height var(--t-slow) var(--ease); }
.tour-spot.center { top: 50%; left: 50%; width: 0; height: 0; outline: 0; }
.tour-pop { position: fixed; z-index: 91; width: min(340px, calc(100vw - 24px)); background: var(--surface); color: var(--text); border: 1px solid var(--border);
  border-radius: var(--r-lg); padding: 1.1rem 1.1rem .9rem; box-shadow: 0 24px 60px -12px rgba(0,0,0,.45); transition: top var(--t-slow) var(--ease), left var(--t-slow) var(--ease); }
.tour-pop.in { animation: pop var(--t-slow) var(--ease) both; }
.tour-pop.centered { top: 50%; left: 50%; transform: translate(-50%, -50%); animation: none; }
.tour-pop.sheet { left: 12px !important; right: 12px; width: auto; top: auto !important; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); }
.tour-pop.sheet.sheet-top { bottom: auto; top: 12px !important; }
.tour-pop.sheet.centered { transform: none; }
.tour-pop h3 { font-size: 1.05rem; margin: .15rem 1.5rem .35rem 0; }
.tour-body { color: var(--text-2); font-size: .92rem; margin-bottom: .75rem; }
.tour-count { color: var(--primary); font-weight: 700; letter-spacing: .02em; }
.tour-x { position: absolute; top: .45rem; right: .55rem; width: 32px; height: 32px; border: 0; border-radius: 8px; background: transparent; color: var(--text-2); font-size: 1.4rem; line-height: 1; cursor: pointer; }
.tour-x:hover { background: var(--surface-2); }
.tour-dots { display: flex; gap: 5px; margin-bottom: .8rem; }
.tour-dots span { height: 5px; flex: 1; max-width: 26px; border-radius: 999px; background: var(--border); transition: background var(--t-med) var(--ease); }
.tour-dots span.done { background: color-mix(in srgb, var(--teal-500) 45%, var(--border)); }
.tour-dots span.on { background: linear-gradient(90deg, var(--teal-500), var(--mint-400)); }
.tour-actions { display: flex; gap: .4rem; align-items: center; }
html.touring .sidebar { z-index: 89; }
html.touring .sidebar.open { box-shadow: none; }

/* Lista de primeros pasos */
.setup-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.setup-list li { display: flex; align-items: center; gap: .75rem; padding: .65rem .8rem; border: 1px solid var(--border); border-radius: var(--r-sm); background: var(--surface); }
.setup-list .tick { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; flex: none; border: 2px solid var(--border); color: transparent; }
.setup-list li.done .tick { background: var(--ok); border-color: var(--ok); color: var(--on-primary); animation: pop var(--t-slow) var(--ease) both; }
.setup-list li.done .label { color: var(--text-2); text-decoration: line-through; text-decoration-color: var(--text-3); }
.setup-list .label { flex: 1; font-weight: 600; }
.progress { height: 8px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.progress > span { display: block; height: 100%; background: linear-gradient(90deg, var(--teal-500), var(--mint-400)); border-radius: inherit; transition: width var(--t-slow) var(--ease); }

/* Barra superior compacta en celular */
.show-sm { display: none !important; }
@media (max-width: 600px) {
  .hide-sm { display: none !important; }
  .show-sm { display: inline-flex !important; }
  .topbar { flex-wrap: nowrap; gap: .25rem; }
  .topbar > .row { flex-wrap: nowrap; gap: .1rem; min-width: 0; }
  .topbar-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 42vw; font-size: .92rem; }
  .topbar [data-install] { display: none !important; }
  .topbar .btn-sm { padding: .3rem .45rem; }
  .topbar { padding: .5rem .6rem; }
}

/* ── Opiniones ──────────────────────────────────────────────────────── */
.label-like { display: block; font-weight: 600; font-size: .9rem; margin-bottom: .4rem; }
.stars { display: inline-flex; flex-direction: row-reverse; gap: .25rem; }
.stars input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.stars label, .stars a { margin: 0; cursor: pointer; color: var(--border); display: inline-flex; padding: .15rem; border-radius: 8px; }
.stars .icon { width: 36px; height: 36px; fill: currentColor; stroke-width: 1.5; transition: transform var(--t-fast) var(--ease), color var(--t-fast) var(--ease); }
.stars label:hover .icon, .stars a:hover .icon { transform: scale(1.15); }
.stars input:checked ~ label, .stars label:hover, .stars label:hover ~ label,
.stars a:hover, .stars a:hover ~ a { color: var(--warn); }
.stars input:focus-visible + label { outline: 3px solid var(--focus); }
.review-banner { display: flex; align-items: center; gap: .75rem; flex-wrap: wrap; padding: .75rem 1rem; margin-bottom: 1rem; border-radius: var(--r-md);
  background: linear-gradient(90deg, color-mix(in srgb, var(--warn) 18%, var(--surface)), var(--surface)); border: 1px solid color-mix(in srgb, var(--warn) 45%, var(--border)); }
.review-banner > .icon { color: var(--warn); fill: currentColor; width: 22px; height: 22px; }
.review-banner span { flex: 1; min-width: 200px; }
.review-hero { width: 64px; height: 64px; margin: 0 auto .75rem; border-radius: 20px; display: grid; place-items: center; color: var(--on-primary);
  background: linear-gradient(135deg, var(--teal-500), var(--mint-400)); animation: pop var(--t-slow) var(--ease) both; }
.review-hero .icon { width: 32px; height: 32px; }
.quote { position: relative; }
.quote .stars-static { color: var(--warn); display: flex; gap: 2px; margin-bottom: .5rem; }
.quote .stars-static .icon { width: 18px; height: 18px; fill: currentColor; }

/* ── Planes ─────────────────────────────────────────────────────────── */
.plan-current { font-size: 1.8rem; font-weight: 800; margin: .35rem 0 .25rem; letter-spacing: -.02em; }
.seg { display: inline-flex; padding: 4px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); }
.seg button { border: 0; background: transparent; color: var(--text-2); font: inherit; font-weight: 700; padding: .45rem .9rem; border-radius: 999px; cursor: pointer; min-height: 38px; display: inline-flex; gap: .4rem; align-items: center; }
.seg button[aria-checked="true"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }
.seg-save { font-size: .7rem; padding: .1rem .45rem; border-radius: 999px; background: var(--ok-bg); color: var(--ok); }
.plans { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); align-items: stretch; }
.plans[data-interval="monthly"] .show-yearly, .plans[data-interval="yearly"] .show-monthly { display: none; }
.plan-card { position: relative; display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 1.4rem 1.25rem; box-shadow: var(--shadow); animation: rise var(--t-slow) var(--ease) both; }
.plan-card:hover { transform: translateY(-3px); box-shadow: 0 2px 4px rgba(60,40,15,.06), 0 18px 36px -14px rgba(60,40,15,.25); }
.plan-card.featured { border: 2px solid var(--teal-500); background: linear-gradient(180deg, color-mix(in srgb, var(--teal-500) 7%, var(--surface)), var(--surface) 40%); }
.plan-card.current { outline: 2px dashed var(--ok); outline-offset: 3px; }
.plan-card:nth-child(2) { animation-delay: 60ms; } .plan-card:nth-child(3) { animation-delay: 120ms; } .plan-card:nth-child(4) { animation-delay: 180ms; }
.plan-ribbon { position: absolute; top: -12px; left: 50%; transform: translateX(-50%); background: linear-gradient(90deg, var(--teal-500), var(--mint-400)); color: var(--on-primary); font-size: .72rem; font-weight: 800; padding: .25rem .7rem; border-radius: 999px; white-space: nowrap; }
.plan-card h3 { font-size: 1.15rem; margin-bottom: .25rem; }
.plan-tagline { min-height: 2.6em; }
.plan-price { display: flex; align-items: baseline; gap: .4rem; flex-wrap: wrap; margin: .5rem 0 .25rem; }
.plan-price .amount { font-size: 2.1rem; font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.plan-price .per { color: var(--text-2); font-size: .82rem; }
.plan-price .per-month { flex-basis: 100%; color: var(--text-2); font-size: .78rem; margin-top: -.15rem; }
.plan-feats { list-style: none; padding: 0; margin: 1rem 0; display: grid; gap: .45rem; font-size: .9rem; flex: 1; align-content: start; }
.plan-feats li { display: flex; gap: .5rem; align-items: flex-start; }
.plan-feats .icon { color: var(--ok); width: 18px; height: 18px; margin-top: 2px; }
.plan-cta { margin-top: auto; }
.trial-chip { display: inline-flex; align-items: center; gap: .35rem; padding: .2rem .6rem; border-radius: 999px; font-size: .78rem; font-weight: 700; background: var(--info-bg); color: var(--info); text-decoration: none; white-space: nowrap; }
.trial-chip.urgent { background: var(--warn-bg); color: var(--warn); }

/* ── Página pública ─────────────────────────────────────────────────── */
html { scroll-behavior: smooth; }
.lp { overflow-x: clip; }
.lp-wrap { max-width: 1160px; margin: 0 auto; padding: 0 1.25rem; }
.lp-nav { position: sticky; top: 0; z-index: 40; padding: .7rem 0; background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: blur(12px); border-bottom: 1px solid transparent; transition: border-color var(--t-med), box-shadow var(--t-med); }
.lp-nav.scrolled { border-bottom-color: var(--border); box-shadow: 0 6px 20px -16px rgba(0,0,0,.35); }
.lp-links { display: flex; gap: 1.5rem; } .lp-links a { color: var(--text-2); text-decoration: none; font-weight: 600; font-size: .92rem; } .lp-links a:hover { color: var(--text); }
.lp-hero { position: relative; padding: clamp(2.5rem, 7vw, 5.5rem) 0 clamp(3rem, 7vw, 6rem); }
.lp-blob { position: absolute; border-radius: 50%; filter: blur(60px); opacity: .45; pointer-events: none; animation: drift 14s ease-in-out infinite alternate; }
.lp-blob.b1 { width: 520px; height: 520px; background: color-mix(in srgb, var(--teal-500) 55%, transparent); top: -180px; right: -120px; }
.lp-blob.b2 { width: 420px; height: 420px; background: color-mix(in srgb, var(--mint-400) 45%, transparent); bottom: -200px; left: -160px; animation-delay: -6s; }
@keyframes drift { to { transform: translate(-40px, 30px) scale(1.08); } }
.lp-hero-grid { position: relative; display: grid; grid-template-columns: 1.1fr .9fr; gap: 3rem; align-items: center; }
.lp-eyebrow { display: inline-flex; align-items: center; gap: .45rem; padding: .35rem .8rem; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); font-size: .82rem; font-weight: 700; color: var(--text-2); animation: rise var(--t-slow) var(--ease) both; }
.lp-eyebrow .icon { color: var(--teal-500); width: 16px; height: 16px; }
.lp-hero h1 { font-size: clamp(2.3rem, 5.6vw, 4rem); line-height: 1.04; letter-spacing: -.035em; margin: 1.1rem 0 1rem; }
.lp-hero .lead { font-size: clamp(1.02rem, 1.6vw, 1.18rem); color: var(--text-2); max-width: 54ch; }
.lp-hero .row { animation: rise var(--t-slow) var(--ease) 240ms both; }
.lp-cta { min-height: 52px; padding: .7rem 1.4rem; font-size: 1.02rem; border-radius: 12px; }
.lp-cta .icon { transition: transform var(--t-fast) var(--ease); } .lp-cta:hover .icon { transform: translateX(3px); }
.lp-cta-2 { min-height: 52px; padding: .7rem 1.3rem; font-size: 1.02rem; border-radius: 12px; }
.lp-trust { list-style: none; padding: 0; margin: 1.5rem 0 0; display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; font-size: .88rem; color: var(--text-2); animation: rise var(--t-slow) var(--ease) 320ms both; }
.lp-trust li { display: inline-flex; gap: .35rem; align-items: center; } .lp-trust .icon { color: var(--ok); width: 16px; height: 16px; }
.lp-phone-wrap { position: relative; display: grid; place-items: center; animation: pop 700ms var(--ease) 200ms both; }
.lp-phone { width: 290px; height: 580px; border-radius: 46px; padding: 12px; background: linear-gradient(160deg, var(--surface-2), var(--bg)); box-shadow: 0 40px 80px -30px rgba(60,40,15,.55), inset 0 0 0 2px rgba(255,255,255,.06); position: relative; animation: float 6s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-10px); } }
.lp-notch { position: absolute; top: 18px; left: 50%; transform: translateX(-50%); width: 92px; height: 22px; border-radius: 999px; background: var(--bg); z-index: 2; }
.lp-screen { height: 100%; border-radius: 36px; background: var(--bg); padding: 46px 18px 18px; overflow: hidden; display: flex; flex-direction: column; }
.lp-avatar { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: .7rem; color: var(--on-primary); background: linear-gradient(135deg, var(--teal-500), var(--mint-400)); }
.lp-clock { font-size: 2.6rem; font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; margin: .2rem 0 .6rem; }
.lp-pill { display: inline-flex; align-items: center; gap: .4rem; align-self: flex-start; padding: .3rem .7rem; border-radius: 999px; background: var(--surface-2); font-size: .78rem; font-weight: 700; }
.lp-pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--text-3); transition: background var(--t-med); } .lp-pill.on .dot { background: var(--ok); }
.lp-btn { margin-top: 1.4rem; border-radius: 14px; background: var(--primary); color: var(--on-primary); text-align: center; font-weight: 800; padding: 1.05rem; transition: transform 160ms var(--ease), filter 160ms; box-shadow: 0 12px 24px -12px color-mix(in srgb, var(--primary) 80%, transparent); }
.lp-btn.pressed { transform: scale(.95); filter: brightness(1.15); }
.lp-receipt { margin-top: 1rem; display: flex; gap: .6rem; align-items: center; padding: .8rem; border-radius: 14px; background: var(--ok-bg); color: var(--ok); border: 1px solid color-mix(in srgb, var(--ok) 35%, transparent); opacity: 0; transform: translateY(12px) scale(.96); transition: opacity 300ms var(--ease), transform 300ms var(--ease); font-size: .85rem; }
.lp-receipt.show { opacity: 1; transform: none; } .lp-receipt > .icon { width: 26px; height: 26px; flex: none; }
.lp-float { position: absolute; display: inline-flex; gap: .45rem; align-items: center; padding: .55rem .85rem; border-radius: 14px; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow); font-weight: 700; font-size: .82rem; animation: float 7s ease-in-out infinite; }
.lp-float .icon { color: var(--teal-500); } .lp-float.f1 { bottom: 24%; left: -2%; animation-delay: -2s; } .lp-float.f2 { bottom: 9%; right: -2%; animation-delay: -4s; }
:root:not([data-theme="dark"]) .lp .grad { background-image: linear-gradient(90deg, var(--primary), var(--ok)); }
.lp-nav .lp-wrap { flex-wrap: nowrap; }
.lp-section { padding: clamp(3rem, 7vw, 5.5rem) 0; }
.lp-alt { background: var(--surface-2); }
.lp-h2 { font-size: clamp(1.6rem, 3.4vw, 2.4rem); letter-spacing: -.025em; text-align: center; margin-bottom: .6rem; }
.lp-sub { text-align: center; color: var(--text-2); max-width: 60ch; margin: 0 auto 2.2rem; }
.lp-steps { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); margin-top: 2rem; }
.lp-step { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 1.4rem; }
.lp-step-n { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; font-weight: 800; color: var(--on-primary); background: linear-gradient(135deg, var(--teal-500), var(--mint-400)); margin-bottom: .8rem; }
.lp-features { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.lp-feature { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 1.3rem; transition: transform var(--t-med) var(--ease), box-shadow var(--t-med) var(--ease), border-color var(--t-med); }
.lp-feature:hover { transform: translateY(-4px); border-color: color-mix(in srgb, var(--teal-500) 50%, var(--border)); box-shadow: 0 18px 36px -18px rgba(60,40,15,.35); }
.lp-ico { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: color-mix(in srgb, var(--teal-500) 14%, var(--surface)); color: var(--primary); margin-bottom: .8rem; }
.lp-ico .icon { width: 22px; height: 22px; }
.lp-reviews { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); margin-top: 1rem; }
.lp-reviews blockquote { margin: 0 0 1rem; font-size: 1rem; }
.lp-faq { max-width: 760px; }
.lp-q { border-bottom: 1px solid var(--border); padding: 1rem .25rem; }
.lp-q summary { list-style: none; display: flex; justify-content: space-between; gap: 1rem; font-size: 1.02rem; }
.lp-q summary::-webkit-details-marker { display: none; }
.lp-q summary::after { content: "+"; font-size: 1.4rem; line-height: 1; color: var(--primary); transition: transform var(--t-med) var(--ease); }
.lp-q[open] summary::after { transform: rotate(45deg); }
.lp-q p { margin: .7rem 0 0; animation: rise var(--t-med) var(--ease) both; }
.lp-final { padding: clamp(3rem, 7vw, 5rem) 0; background: radial-gradient(800px 300px at 50% 0%, color-mix(in srgb, var(--teal-500) 30%, transparent), transparent), var(--navy-900); color: var(--text); }
.lp-final h2 { font-size: clamp(1.6rem, 3.4vw, 2.4rem); letter-spacing: -.025em; } .lp-final p { color: var(--text-2); }
.lp-final .lp-cta-2 { background: transparent; color: var(--text); border-color: var(--border); }
.lp-foot { padding: 2rem 0; border-top: 1px solid var(--border); } .lp-foot .row { gap: 1rem; }
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 600ms var(--ease), transform 600ms var(--ease); }
.reveal.in { opacity: 1; transform: none; }
@media (max-width: 900px) {
  .lp-hero-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .lp-phone { width: 250px; height: 500px; }
  .lp-float.f1 { left: 0; } .lp-float.f2 { right: 0; }
}
@media (max-width: 600px) { .lp-float { display: none; } .lp-nav .btn-sm { padding: .3rem .55rem; } .lp-nav .brand-by { display: none; } .lp-nav .lp-wrap { padding: 0 .75rem; } }

.io-tone { color: var(--link); }
.kiosk .brand-by, .hero .brand-by { color: var(--text-2); }
.staging-ribbon { position: fixed; bottom: calc(70px + env(safe-area-inset-bottom, 0px)); right: 10px; z-index: 95; pointer-events: none; padding: .25rem .65rem; border-radius: 999px; font-size: .72rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; background: var(--warn); color: var(--bg); box-shadow: var(--shadow); opacity: .92; }

/* ── Horarios de la semana ──────────────────────────────────────────── */
.week-nav { display: flex; align-items: center; justify-content: space-between; gap: .75rem; margin-bottom: 1rem; padding: .75rem 1rem; flex-wrap: wrap; }
.week-title { display: flex; flex-direction: column; align-items: center; line-height: 1.2; }
.week-title strong { font-size: 1.15rem; }
.weekly-layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 1rem; align-items: start; }
.weekly-card { padding: .75rem; }
.weekly { font-size: .82rem; }
.weekly th, .weekly td { padding: .45rem .4rem; vertical-align: top; }
.weekly thead th { text-align: center; }
.weekly thead th.is-today { color: var(--primary); box-shadow: inset 0 -3px 0 var(--teal-500); }
.weekly thead th.is-past { opacity: 1; }
.weekly .sticky-col { position: sticky; left: 0; z-index: 2; background: var(--surface); min-width: 170px; text-align: left; text-transform: none; letter-spacing: 0; font-size: .85rem; color: var(--text); }
.weekly thead .sticky-col { background: var(--surface-2); z-index: 3; }
.weekly .who { font-weight: 700; }
.fill-row { min-height: 32px !important; font-size: .78rem; padding: .2rem .4rem !important; margin-top: .35rem; }
.weekly td.cell { min-width: 98px; border-left: 1px solid var(--border); position: relative; }
.weekly td.cell select { min-height: 34px; font-size: .8rem; padding: .25rem .35rem; }
.cell-label { display: block; font-weight: 700; }
.cell-hours { display: block; font-size: .72rem; color: var(--text-2); margin-top: .2rem; font-variant-numeric: tabular-nums; }
.weekly td.is-today { background: color-mix(in srgb, var(--teal-500) 6%, transparent); }
.weekly td.src-week::before, .weekly td.src-fixed::before { content: ""; position: absolute; left: 0; top: 6px; bottom: 6px; width: 3px; border-radius: 3px; background: var(--tpl, var(--border)); }
.weekly td.src-fixed::before { opacity: .45; }
.weekly td.src-rest { background: repeating-linear-gradient(135deg, transparent 0 6px, color-mix(in srgb, var(--text-3) 10%, transparent) 6px 12px); }
.weekly td.src-rest .cell-label, .weekly td.src-none .cell-label { color: var(--text-2); font-weight: 600; }
.weekly td.dirty { outline: 2px dashed var(--warn); outline-offset: -3px; }
.c1 { --tpl: var(--primary); } .c2 { --tpl: var(--ink); } .c3 { --tpl: var(--warn); } .c4 { --tpl: var(--ok); } .c5 { --tpl: var(--text-2); } .c6 { --tpl: var(--text-3); }
.dot-tpl { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--tpl, var(--border)); margin-right: .35rem; }
.weekly .balance { min-width: 112px; font-size: .78rem; }
.bal-extra { color: var(--ok); font-weight: 700; } .bal-missing { color: var(--danger); font-weight: 700; } .bal-rest { color: var(--warn); font-weight: 700; }
.weekly-actions { display: flex; justify-content: flex-end; align-items: center; gap: 1rem; margin-top: .75rem; position: sticky; bottom: 0; z-index: 4; background: var(--surface); padding: .6rem 0; border-top: 1px solid var(--border); }
.weekly-templates .list li { align-items: flex-start; }
@media (max-width: 1500px) { .weekly-layout { grid-template-columns: minmax(0, 1fr); } .weekly-templates .list { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 0 1.5rem; } }
@media (max-width: 600px) { .weekly .sticky-col { min-width: 132px; max-width: 150px; } .weekly .sticky-col .who { font-size: .8rem; } }

/* ── Panel de plataforma ────────────────────────────────────────────── */
.bars { display: flex; align-items: flex-end; gap: .75rem; height: 180px; padding-top: 1.2rem; }
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; gap: .3rem; }
.bar { width: 100%; max-width: 42px; border-radius: 6px 6px 2px 2px; background: linear-gradient(180deg, var(--teal-500), color-mix(in srgb, var(--teal-500) 55%, var(--mint-400))); animation: grow 700ms var(--ease) both; transform-origin: bottom; }
@keyframes grow { from { transform: scaleY(0); } }
.bar-v { font-weight: 800; font-size: .85rem; font-variant-numeric: tabular-nums; }
.bar-l { font-size: .75rem; color: var(--text-2); text-transform: capitalize; }
.hbars { list-style: none; padding: 0; margin: 0; display: grid; gap: .7rem; }
.hbars li { display: grid; grid-template-columns: minmax(110px, 1.2fr) 2fr auto; align-items: center; gap: .75rem; font-size: .9rem; }
.hb-track { height: 10px; background: var(--surface-2); border-radius: 999px; overflow: hidden; }
.hb { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--teal-500), var(--mint-400)); animation: growx 700ms var(--ease) both; transform-origin: left; }
@keyframes growx { from { transform: scaleX(0); } }
.hb-v { font-weight: 700; min-width: 70px; text-align: right; }
.thread { display: grid; gap: .9rem; }
.msg { border: 1px solid var(--border); border-radius: var(--r-md); padding: .9rem 1rem; background: var(--surface); max-width: 760px; }
.msg.from-platform { border-color: color-mix(in srgb, var(--teal-500) 45%, var(--border)); background: color-mix(in srgb, var(--teal-500) 6%, var(--surface)); margin-left: auto; }
.msg-h { display: flex; justify-content: space-between; gap: .75rem; font-size: .8rem; color: var(--text-2); margin-bottom: .35rem; flex-wrap: wrap; }
.msg-body { white-space: pre-wrap; word-break: break-word; }
.msg-imgs { display: flex; gap: .5rem; flex-wrap: wrap; margin-top: .6rem; }
.msg-imgs a { display: block; width: 120px; height: 90px; border-radius: 8px; overflow: hidden; border: 1px solid var(--border); }
.msg-imgs img { width: 100%; height: 100%; object-fit: cover; }
.contact-card dl { display: grid; grid-template-columns: auto 1fr; gap: .35rem .9rem; margin: 0; font-size: .9rem; }
.contact-card dt { color: var(--text-2); }
.contact-card dd { margin: 0; word-break: break-word; }
.lp-verify { display: grid; grid-template-columns: auto 1fr auto; gap: 1.25rem; align-items: center; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 1.5rem; }
@media (max-width: 760px) { .lp-verify { grid-template-columns: 1fr; text-align: left; } }

/* ── Horario semanal con fichas de color (como en la página de ventas) ──────────── */
.weekly { border-collapse: separate; border-spacing: 6px 6px; font-size: .82rem; }
.weekly th, .weekly td { padding: 0; border: 0; }
.weekly thead th { padding: .35rem .2rem; font-size: .74rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text-2); font-weight: 700; }
.weekly thead th .day-d { display: inline-grid; place-items: center; min-width: 1.7rem; height: 1.7rem; border-radius: 999px; font-variant-numeric: tabular-nums; color: var(--text-2); }
.weekly thead th.is-today { color: var(--primary); box-shadow: none; }
.weekly thead th.is-today .day-d { background: var(--primary); color: var(--on-primary); }
.weekly .sticky-col { padding: .3rem .5rem .3rem 0; min-width: 210px; vertical-align: middle; }
.weekly tbody .sticky-col { border-bottom: 1px dashed var(--border); }
.who-row { display: flex; gap: .6rem; align-items: center; }
.who-row > span:last-child { display: grid; gap: .1rem; min-width: 0; }
.who-av { flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-size: .72rem; font-weight: 800; background: var(--surface-2); color: var(--text-2); }
.weekly .who { font-weight: 700; }
.who-fixed { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.weekly .fill-row { margin-top: .4rem; min-height: 30px; font-size: .74rem; padding: .15rem .4rem; background: transparent; border-style: dashed; }
.weekly td.cell { min-width: 92px; border-left: 0; vertical-align: middle; }
.weekly td.cell::before { display: none; }
.weekly td.is-today { background: transparent; }
.shift-chip { position: relative; display: grid; align-content: center; gap: .1rem; min-height: 54px; padding: .45rem .5rem; border-radius: 10px; text-align: center; transition: transform .12s, box-shadow .12s; }
.shift-chip .chip-hours { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-weight: 700; font-size: .84rem; font-variant-numeric: tabular-nums; }
.shift-chip .chip-name { font-size: .68rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.shift-chip .chip-name:empty { display: none; }
.shift-chip select { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; min-height: 0; }
.weekly td:not(.is-past) .shift-chip:hover { transform: translateY(-1px); box-shadow: 0 6px 14px -8px rgba(40,30,15,.45); }
.shift-chip:focus-within { outline: 3px solid var(--focus); outline-offset: 2px; }
.k-morning { background: var(--k-morning-bg); color: var(--k-morning); }
.k-afternoon { background: var(--k-afternoon-bg); color: var(--k-afternoon); }
.k-night { background: var(--k-night-bg); color: var(--k-night); }
.k-rest { background: repeating-linear-gradient(135deg, var(--surface-2) 0 7px, color-mix(in srgb, var(--surface-2) 55%, var(--border)) 7px 14px); color: var(--text-2); }
.k-rest .chip-hours { font-family: inherit; }
.k-none { background: transparent; border: 1.5px dashed var(--border); color: var(--text-3); }
.k-none .chip-hours { font-family: inherit; font-weight: 600; }
.shift-chip.is-fixed { box-shadow: inset 0 0 0 1.5px color-mix(in srgb, currentColor 30%, transparent); background-image: none; }
.weekly td.is-past .shift-chip { filter: saturate(.35); background-image: none; }
.weekly td.is-past .shift-chip.k-rest { background: var(--surface-2); }
.weekly td.dirty { outline: 0; }
.weekly td.dirty .shift-chip { box-shadow: 0 0 0 2px var(--warn); }
.weekly td.dirty .shift-chip::after { content: ""; position: absolute; top: -4px; right: -4px; width: 10px; height: 10px; border-radius: 50%; background: var(--warn); }
.weekly .balance { min-width: 118px; padding-left: .5rem; vertical-align: middle; }
.weekly .bal-main strong { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .9rem; }
.dot-tpl { display: inline-block; width: 12px; height: 12px; border-radius: 4px; margin-right: .4rem; vertical-align: -1px; }
.shift-legend { display: flex; flex-wrap: wrap; gap: .3rem .8rem; font-size: .74rem; color: var(--text-2); margin-bottom: .8rem; }
.shift-legend span { display: inline-flex; align-items: center; gap: .3rem; }
.shift-legend i { width: 12px; height: 12px; border-radius: 4px; display: inline-block; }
:root { --k-morning: var(--info); --k-morning-bg: var(--info-bg); --k-afternoon: var(--warn); --k-afternoon-bg: var(--warn-bg); --k-night: var(--text); --k-night-bg: var(--surface-2); }

/* Horario semanal compacto: cabe sin barra lateral desde 1280 px */
.weekly .sticky-col { min-width: 186px; }
.weekly td.cell { min-width: 82px; }
.weekly .balance { min-width: 100px; }
@media (max-width: 1700px) { .weekly-layout { grid-template-columns: minmax(0, 1fr); } .weekly-templates .list { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 0 1.5rem; } }
/* Detalle del día (desde el reporte) */
a.badge-link { text-decoration: none; cursor: pointer; } a.badge-link:hover { filter: brightness(.95); text-decoration: underline; }
.day-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: .7rem 1rem; margin: .9rem 0 0; }
.day-facts dt { font-size: .74rem; color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; }
.day-facts dd { margin: .1rem 0 0; font-weight: 700; }
.day-timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: .2rem; }
.day-timeline li { display: grid; grid-template-columns: 5.2rem 1fr auto; gap: .8rem; align-items: center; padding: .65rem 0; border-bottom: 1px dashed var(--border); }
.day-timeline time { font: 700 1.05rem ui-monospace, SFMono-Regular, Menlo, monospace; }
/* Modo kiosco: salida con código */
.kiosk { user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.kiosk input { user-select: text; }
.kiosk-lockhint { position: fixed; left: 50%; bottom: max(1rem, env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); background: var(--text); color: var(--bg); padding: .5rem 1rem; border-radius: 999px; font-size: .85rem; z-index: 5; }
.kiosk-exit-dlg { max-width: 340px; width: calc(100% - 2rem); border: 0; border-radius: 16px; padding: 1.2rem; background: var(--surface); color: var(--text); }
.kiosk-exit-dlg::backdrop { background: rgba(0,0,0,.6); }
.kiosk-exit-dlg h2 { margin-top: 0; }
.kiosk-exit-dlg input { width: 100%; font-size: 1.4rem; text-align: center; letter-spacing: .3em; margin-bottom: .6rem; }
.pinpad.small-pad button { min-height: 48px; font-size: 1.1rem; }
.kiosk-exit-actions { display: grid; gap: .5rem; margin-top: .8rem; }
.kiosk-exit-code { font: 700 1.6rem ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .2em; padding: .4rem .8rem; border: 2px dashed var(--border); border-radius: 10px; }
.audit-diff { display: grid; gap: .5rem; margin-top: .4rem; }
.audit-diff pre { margin: .2rem 0 0; padding: .5rem; background: var(--surface-2); border-radius: 8px; font-size: .74rem; white-space: pre-wrap; word-break: break-word; max-height: 260px; overflow: auto; }

/* Aviso emergente de mantenimiento (partials/announcement-banner) */
.announce-modal { position: fixed; inset: 0; margin: auto; z-index: 90; max-width: min(460px, calc(100vw - 2rem)); max-height: calc(100vh - 2rem); overflow: auto; border: 1px solid var(--border); border-radius: 16px; padding: 1.25rem 1.25rem 1rem; background: var(--surface); color: inherit; box-shadow: 0 0 0 100vmax rgba(28, 25, 23, .45), 0 20px 60px rgba(0, 0, 0, .3); }

/* Facturación: cancelar suscripción */
.cancel-box { margin-top: .75rem; }
.cancel-box form { margin-top: .5rem; }

/* Cupones (Facturación) */
.coupon-active { margin: 0 0 .8rem; padding: .7rem .9rem; border: 2px dashed var(--primary); border-radius: var(--r-md); background: var(--info-bg); }
.coupon-active code { font-weight: 800; letter-spacing: .08em; }
.coupon-price { display: block; margin-top: .35rem; font-size: .82rem; color: var(--ok); }

/* El atributo hidden gana sobre display de .btn (antes el botón de instalar se veía aunque estuviera oculto). */
[hidden] { display: none !important; }
