/* Voces · Nextia: recorder + admin, on top of app.css (Laguna tokens) */
body.voz { background: var(--crema); }
.angosto { width: min(720px, 100% - 32px); }
main.angosto { padding: 22px 0 60px; }
.ghost.chico, .chico { min-height: 34px; padding: 0 12px; font-size: .84rem; }
a.ghost { display: inline-flex; align-items: center; text-decoration: none; }
.quien { max-width: 30vw; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tarjeta { background: var(--papel); border: 1px solid color-mix(in oklab, var(--nogal) 12%, transparent); border-radius: 20px; padding: 22px; box-shadow: var(--sombra); }
.lead { color: var(--tinta-2); margin: 8px 0 4px; }
.t-perfil { font-size: 1.7rem; margin-top: 8px; }
.err.centro { text-align: center; }
select, textarea { width: 100%; min-height: 44px; padding: 10px 13px; border-radius: 11px; border: 1px solid var(--crema-3); background: #fff; font: inherit; color: inherit; }
textarea { resize: vertical; min-height: 64px; }
select:focus, textarea:focus { outline: none; border-color: var(--nogal-2); box-shadow: 0 0 0 3px color-mix(in oklab, var(--nogal-2) 18%, transparent); }

/* profile form */
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 16px; }
.form .ancho { grid-column: 1 / -1; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-size: .9rem; color: var(--tinta); background: color-mix(in oklab, var(--ambar) 12%, var(--papel)); border: 1px solid color-mix(in oklab, var(--ambar) 40%, transparent); padding: 12px 14px; border-radius: 12px; cursor: pointer; }
.check input { width: 20px; height: 20px; min-height: 0; flex: none; margin-top: 2px; }
.form .btn { width: 100%; }

/* progress */
.avance { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; font-size: .86rem; color: var(--tinta-2); }
.barra-av { flex: 1; height: 8px; border-radius: 99px; background: var(--crema-2); overflow: hidden; }
.barra-av i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--laton), var(--nogal-2)); border-radius: 99px; transition: width .5s var(--ease); }

/* phrase card */
.frase { display: grid; gap: 10px; }
.tags { display: flex; align-items: center; gap: 10px; }
.pill { font-size: .74rem; font-weight: 700; letter-spacing: .02em; padding: 4px 10px; border-radius: 99px; background: var(--nogal); color: var(--sobre); }
.pill[data-lang="jo"] { background: var(--ambar); color: var(--nogal-osc); }
.num { font: 400 .62rem var(--f-dial); letter-spacing: .1em; color: var(--tinta-2); }
.texto { font: 400 clamp(1.6rem, 6vw, 2.3rem)/1.2 var(--f-tit); letter-spacing: -.01em; color: var(--tinta); margin: 6px 0 2px; overflow-wrap: anywhere; }
.signif { color: var(--tinta-2); font-size: .95rem; }
.signif span:first-child { font-weight: 600; }
.frase .link { justify-self: start; }
#editBox label { margin-top: 4px; }

/* recorder */
.grabador { display: grid; justify-items: center; gap: 8px; padding: 22px 0 8px; }
.medidor { width: 100%; height: 56px; }
.medidor canvas { width: 100%; height: 100%; display: block; }
.mic { position: relative; width: 104px; height: 104px; border-radius: 50%; border: 0; cursor: pointer; display: grid; place-items: center; color: var(--sobre);
  background: radial-gradient(circle at 35% 30%, var(--nogal-2), var(--nogal)); box-shadow: 0 2px 4px rgba(10,32,36,.25), 0 18px 34px -14px rgba(10,32,36,.7), inset 0 1px 0 rgba(255,255,255,.15);
  transition: transform .2s var(--ease), background .2s; -webkit-tap-highlight-color: transparent; }
.mic:active { transform: scale(.96); }
.mic svg { width: 40px; height: 40px; }
.mic .i-stop { display: none; }
.grabador[data-modo="rec"] .mic { background: radial-gradient(circle at 35% 30%, #d0553a, var(--rojo)); }
.grabador[data-modo="rec"] .mic .i-mic { display: none; }
.grabador[data-modo="rec"] .mic .i-stop { display: block; width: 34px; height: 34px; }
.grabador[data-modo="rec"] .mic::before, .grabador[data-modo="rec"] .mic::after { content: ""; position: absolute; inset: -8px; border-radius: 50%; border: 2px solid var(--rojo); animation: onda 1.5s ease-out infinite; }
.grabador[data-modo="rec"] .mic::after { animation-delay: .5s; }
.grabador[data-modo="saving"] .mic, .grabador[data-modo="pedir"] .mic { opacity: .5; pointer-events: none; }
.grabador[data-modo="saved"] .mic { background: radial-gradient(circle at 35% 30%, #3f9a72, var(--verde)); }
@media (prefers-reduced-motion: reduce) { .grabador .mic::before, .grabador .mic::after { animation: none !important; } }
.estado { font-weight: 600; text-align: center; min-height: 1.5em; }
.reloj { font: 400 .8rem var(--f-dial); letter-spacing: .08em; color: var(--rojo); min-height: 1.2em; }
.acciones { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.acciones .ghost, .acciones .btn { min-height: 46px; }
.acciones .ghost { display: inline-flex; align-items: center; gap: 6px; }
.acciones svg { width: 16px; height: 16px; }
.nav { display: flex; justify-content: space-between; margin: 10px 2px 20px; }
.link:disabled { opacity: .35; cursor: default; }
.consejos { background: var(--papel); border-radius: 14px; padding: 12px 16px; border: 1px solid var(--crema-2); font-size: .92rem; }
.consejos summary { cursor: pointer; font-weight: 600; }
.consejos ul { margin: 10px 0 2px; padding-left: 20px; color: var(--tinta-2); display: grid; gap: 6px; }

/* list */
.lista-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.lista-h h2 { font-size: 1.5rem; }
.chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 8px; margin-bottom: 8px; scrollbar-width: thin; }
.chip { flex: none; border: 1px solid var(--crema-3); background: var(--papel); border-radius: 99px; padding: 6px 12px; font-size: .84rem; cursor: pointer; }
.chip.on { background: var(--nogal); color: var(--sobre); border-color: var(--nogal); }
.items { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.items button { width: 100%; display: flex; gap: 12px; align-items: flex-start; text-align: left; padding: 11px 14px; border-radius: 12px; border: 1px solid var(--crema-2); background: var(--papel); cursor: pointer; }
.items button:hover { border-color: var(--crema-3); }
.items .marca-ok { flex: none; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: .78rem; border: 1.5px solid var(--crema-3); color: #fff; }
.items li.ok .marca-ok { background: var(--verde); border-color: var(--verde); }
.it { display: grid; gap: 2px; min-width: 0; }
.it-t { font-weight: 600; }
.it-s { font-size: .82rem; color: var(--tinta-2); }
.vacio { padding: 24px; text-align: center; color: var(--tinta-2); }

@media (max-width: 560px) {
  .form { grid-template-columns: 1fr; }
  .tarjeta { padding: 18px; border-radius: 18px; }
  .barra-in { gap: 10px; }
  .quien { display: none; }
  .acciones .btn, .acciones .ghost { flex: 1 1 40%; }
  .acciones .btn.ambar { flex-basis: 100%; }
}

/* ------------------------------------------------ admin */
.admin main { padding: 24px 0 60px; }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 18px; }
.tab { border: 1px solid var(--crema-3); background: var(--papel); border-radius: 99px; padding: 8px 16px; cursor: pointer; font-weight: 600; font-size: .9rem; }
.tab.on { background: var(--nogal); color: var(--sobre); border-color: var(--nogal); }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-bottom: 18px; }
.kpi { background: var(--papel); border: 1px solid var(--crema-2); border-radius: 14px; padding: 14px 16px; }
.kpi b { display: block; font: 400 1.7rem/1.1 var(--f-tit); }
.kpi span { font-size: .8rem; color: var(--tinta-2); }
.tabla-w { overflow-x: auto; background: var(--papel); border: 1px solid var(--crema-2); border-radius: 14px; }
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--crema-2); vertical-align: middle; }
th { font-size: .74rem; text-transform: uppercase; letter-spacing: .06em; color: var(--tinta-2); font-weight: 600; background: color-mix(in oklab, var(--crema) 60%, var(--papel)); position: sticky; top: 0; }
tr:last-child td { border-bottom: 0; }
td .ghost { min-height: 30px; padding: 0 10px; font-size: .8rem; }
td input, td select { min-height: 34px; padding: 5px 8px; border-radius: 8px; font-size: .88rem; }
td.t-txt { min-width: 240px; }
tr.off td { opacity: .5; }
tr.bad td { background: color-mix(in oklab, var(--rojo) 8%, transparent); }
.fila { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; margin-bottom: 14px; }
.fila > div { flex: 1 1 180px; }
.fila .btn { flex: none; }
.secreto { margin: 12px 0 18px; padding: 14px 16px; border-radius: 12px; background: color-mix(in oklab, var(--ambar) 16%, var(--papel)); border: 1px solid color-mix(in oklab, var(--ambar) 50%, transparent); }
.secreto pre { white-space: pre-wrap; font-size: .88rem; margin: 8px 0; background: #fff; padding: 10px 12px; border-radius: 8px; border: 1px solid var(--crema-3); }
.muted { color: var(--tinta-2); font-size: .85rem; }
.h3 { font: 400 1.25rem var(--f-tit); margin: 22px 0 10px; }
