/* Buzón de mejora · Ventura Abogados — escritorio primero */
:root {
  --ve-gold: #D6C629;
  --ve-gold-hover: #C8B81E;
  --ve-on-gold: #111730;
  --ve-navy: #111730;
  --ve-brand: #131F7A;
  --ve-bg: #F5F3EC;
  --ve-bg-2: #EAE7DE;
  --ve-card: #FFFFFF;
  --ve-field: #FFFFFF;
  --ve-border: rgba(17, 23, 48, .12);
  --ve-border-strong: rgba(17, 23, 48, .26);
  --ve-text: #111730;
  --ve-text-2: rgba(17, 23, 48, .58);
  --ve-link: #5F570B;
  --ve-teal: #50C5B4;
  --ve-green: #9DD18A;
  --ve-salmon: #FF7F6F;
  --ve-lavender: #D7C1DB;
  --ve-gold-soft: rgba(214, 198, 41, .18);
  --ve-teal-soft: rgba(80, 197, 180, .16);
  --ve-salmon-soft: rgba(255, 127, 111, .16);
  --ve-green-soft: rgba(157, 209, 138, .26);
  --ve-shadow: 0 1px 2px rgba(17, 23, 48, .05), 0 6px 20px rgba(17, 23, 48, .06);
  --ve-shadow-hover: 0 2px 4px rgba(17, 23, 48, .06), 0 12px 32px rgba(17, 23, 48, .10);
  --ve-overlay: rgba(17, 23, 48, .42);
  --ve-r: 8px;
  --ve-r-card: 14px;
  --ve-r-pill: 999px;
  --ve-font-display: 'Urbanist', system-ui, sans-serif;
  --ve-font-body: 'Inter', system-ui, sans-serif;
  --ve-font-mono: 'JetBrains Mono', ui-monospace, monospace;
  --ve-pad: 24px;
  --ve-max: 1120px;
  --ve-dur: .22s;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-tema="claro"]) {
    --ve-bg: #151410;
    --ve-bg-2: #22211C;
    --ve-card: linear-gradient(287deg, #3B3932 -1.46%, #232323 92.88%);
    --ve-field: rgba(237, 235, 227, .05);
    --ve-border: rgba(237, 235, 227, .14);
    --ve-border-strong: rgba(237, 235, 227, .3);
    --ve-text: #EDEBE3;
    --ve-text-2: rgba(237, 235, 227, .64);
    --ve-link: var(--ve-gold);
    --ve-gold-soft: rgba(214, 198, 41, .16);
    --ve-shadow: none;
    --ve-shadow-hover: 0 0 0 1px rgba(237, 235, 227, .2);
    --ve-overlay: rgba(0, 0, 0, .6);
    color-scheme: dark;
  }
}
:root[data-tema="oscuro"] {
  --ve-bg: #151410; --ve-bg-2: #22211C;
  --ve-card: linear-gradient(287deg, #3B3932 -1.46%, #232323 92.88%);
  --ve-field: rgba(237, 235, 227, .05); --ve-border: rgba(237, 235, 227, .14); --ve-border-strong: rgba(237, 235, 227, .3);
  --ve-text: #EDEBE3; --ve-text-2: rgba(237, 235, 227, .64); --ve-link: var(--ve-gold);
  --ve-gold-soft: rgba(214, 198, 41, .16); --ve-shadow: none; --ve-shadow-hover: 0 0 0 1px rgba(237, 235, 227, .2); --ve-overlay: rgba(0, 0, 0, .6);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[x-cloak] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--ve-bg);
  color: var(--ve-text);
  font: 400 17px/1.55 var(--ve-font-body);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--ve-link); text-underline-offset: 3px; }
a:hover { color: var(--ve-text); }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--ve-gold); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3, p { margin: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.icon { width: 24px; height: 24px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.icon-sm { width: 20px; height: 20px; }
.mono { font-family: var(--ve-font-mono); }
kbd {
  display: inline-block; min-width: 26px; padding: 1px 7px;
  font: 600 13px/1.5 var(--ve-font-mono); text-align: center; white-space: nowrap;
  color: var(--ve-text);
  background: var(--ve-field); border: 1px solid var(--ve-border-strong); border-bottom-width: 3px; border-radius: 6px;
}
.kbd-lg { font-size: 16px; padding: 4px 12px; min-width: 40px; border-bottom-width: 4px; }

/* ---------- Estructura ---------- */
.app { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; container: app / inline-size; }
.top {
  width: 100%; max-width: calc(var(--ve-max) + 2 * var(--ve-pad)); margin: 0 auto;
  padding: 20px var(--ve-pad);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ve-text); }
.brand:hover { color: var(--ve-text); }
.brand-mark { width: 40px; height: 40px; flex: none; }
.brand-words { display: flex; flex-direction: column; line-height: 1; gap: 5px; }
.brand-name { font: 800 17px/1 var(--ve-font-display); letter-spacing: .2em; }
.brand-sub { white-space: nowrap; font: 200 10px/1 var(--ve-font-display); letter-spacing: .24em; text-transform: uppercase; color: var(--ve-gold); }
.top-actions { display: flex; align-items: center; gap: 8px; }
.hello { display: flex; align-items: center; gap: 10px; font-weight: 500; font-size: 16px; padding-left: 8px; white-space: nowrap; }
.avatar {
  width: 36px; height: 36px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--ve-gold); color: var(--ve-on-gold);
  font: 700 14px/1 var(--ve-font-body);
}
.icon-btn {
  min-width: 48px; height: 48px; padding: 0 16px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid var(--ve-border); border-radius: var(--ve-r-pill);
  background: transparent; color: var(--ve-text); font-weight: 500; font-size: 16px; text-decoration: none; white-space: nowrap;
  transition: background var(--ve-dur), border-color var(--ve-dur);
}
.icon-btn:hover { background: var(--ve-bg-2); border-color: var(--ve-border-strong); color: var(--ve-text); }
.help-btn { font: 700 20px/1 var(--ve-font-display); width: 48px; padding: 0; }

main {
  flex: 1; width: 100%;
  max-width: calc(var(--ve-max) + 2 * var(--ve-pad)); margin: 0 auto;
  padding: 8px var(--ve-pad) 48px;
  display: flex; flex-direction: column;
}

/* ---------- Botones ---------- */
.btn {
  min-height: 56px; padding: 0 24px;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  border-radius: var(--ve-r); border: 1px solid transparent;
  font: 600 17px/1.2 var(--ve-font-body); text-decoration: none; white-space: nowrap;
  transition: background var(--ve-dur), transform .12s, border-color var(--ve-dur), box-shadow var(--ve-dur);
}
.btn:active { transform: scale(.98); }
.btn-gold { background: var(--ve-gold); color: var(--ve-on-gold); }
.btn-gold:hover { background: var(--ve-gold-hover); color: var(--ve-on-gold); box-shadow: 0 6px 18px rgba(214, 198, 41, .35); }
.btn-ghost { background: transparent; color: var(--ve-text); border-color: var(--ve-border-strong); }
.btn-ghost:hover { background: var(--ve-bg-2); color: var(--ve-text); border-color: var(--ve-text-2); }
.btn-quiet { background: transparent; color: var(--ve-text-2); min-height: 48px; padding: 0 14px; }
.btn-quiet:hover { color: var(--ve-text); background: var(--ve-bg-2); }
.btn-xl { min-height: 64px; font-size: 18px; padding: 0 32px; }
.btn[disabled] { opacity: .75; cursor: progress; }
.btn kbd { font-size: 12px; padding: 0 6px; min-width: 0; background: rgba(255, 255, 255, .5); border-color: rgba(17, 23, 48, .25); color: var(--ve-navy); }
.btn-ghost kbd, .btn-quiet kbd { background: var(--ve-field); color: var(--ve-text); border-color: var(--ve-border-strong); }
.spinner {
  width: 20px; height: 20px; border-radius: 50%;
  border: 2.5px solid currentColor; border-right-color: transparent;
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Entrada ---------- */
.entrada { flex: 1; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 64px; align-items: center; padding: 24px 0 64px; }
.entrada-inner { display: flex; flex-direction: column; gap: 28px; }
.eyebrow { font: 600 14px/1 var(--ve-font-body); letter-spacing: .12em; text-transform: uppercase; color: var(--ve-text-2); }
.hero { font: 200 clamp(44px, 4.6vw, 64px)/1.04 var(--ve-font-display); letter-spacing: -.015em; text-wrap: balance; }
.hero strong { font-weight: 700; }
.entrada-kinds { display: flex; flex-wrap: wrap; gap: 8px; }
.kind-chip { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: var(--ve-r-pill); background: var(--ve-card); border: 1px solid var(--ve-border); font-size: 16px; font-weight: 500; }
.dot { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.ms-logo { width: 20px; height: 20px; display: grid; grid-template-columns: 1fr 1fr; gap: 2px; flex: none; }
.ms-logo i { display: block; }
.entrada .btn-xl { align-self: flex-start; }

/* Composición visual de la entrada */
.showcase { position: relative; height: 480px; }
.sc-window {
  position: absolute; top: 0; left: 0; right: 48px;
  padding: 28px; border-radius: 18px;
  background: var(--ve-card); border: 1px solid var(--ve-border); box-shadow: var(--ve-shadow-hover);
  display: flex; flex-direction: column; gap: 18px;
}
.sc-title { font: 200 30px/1.1 var(--ve-font-display); }
.sc-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.sc-card { border: 1.5px solid var(--ve-border); border-radius: 12px; padding: 14px; display: flex; flex-direction: column; gap: 10px; background: var(--ve-bg); }
.sc-card.on { border-color: var(--ve-gold); background: var(--ve-gold-soft); box-shadow: 0 0 0 1.5px var(--ve-gold) inset; }
.sc-card .choice-icon { width: 38px; height: 38px; border-radius: 10px; }
.sc-card .choice-icon .icon { width: 20px; height: 20px; }
.sc-card span:last-child { font: 700 15px/1.2 var(--ve-font-display); }
.sc-summary {
  position: absolute; right: 0; bottom: 0; width: 76%;
  padding: 22px 24px; border-radius: 16px;
  background: var(--ve-card); border: 1px solid var(--ve-border); box-shadow: var(--ve-shadow-hover);
  display: flex; flex-direction: column; gap: 14px;
}
.sc-summary p { font: 300 20px/1.45 var(--ve-font-display); }
.sc-summary b { font-weight: 700; background: linear-gradient(transparent 62%, var(--ve-gold-soft) 62%); text-decoration: underline; text-decoration-color: var(--ve-gold); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.sc-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.sc-send { display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: var(--ve-r); background: var(--ve-gold); color: var(--ve-on-gold); font-weight: 600; font-size: 15px; }
.sc-send .icon { width: 18px; height: 18px; }
.sc-ref { position: absolute; left: 0; bottom: 64px; transform: rotate(-3deg); padding: 10px 16px; border-radius: 12px; background: var(--ve-navy); color: #EDEBE3; font-weight: 600; font-size: 15px; display: flex; gap: 10px; align-items: center; box-shadow: var(--ve-shadow-hover); }
.sc-ref .ref { font-size: 14px; }

/* ---------- Avisos ---------- */
.notice {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 16px; border-radius: var(--ve-r-card);
  font-size: 17px; line-height: 1.45;
}
.notice .icon { margin-top: 1px; }
.notice-info { background: var(--ve-teal-soft); }
.notice-warn { background: var(--ve-salmon-soft); }
.notice-soft { background: var(--ve-gold-soft); }
.notice strong { font-weight: 600; }
.notice-code { margin-top: 10px; font-size: 15px; color: var(--ve-text-2); display: flex; align-items: center; gap: 8px; }
.notice-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.notice-actions .btn { min-height: 48px; }

/* ---------- Asistente a dos columnas ---------- */
.wizard { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 56px; align-items: start; flex: 1; }
.wizard-main { min-width: 0; display: flex; flex-direction: column; }
.wizard-aside { min-width: 0; align-self: stretch; }
.aside-sticky { position: sticky; top: 20px; display: flex; flex-direction: column; gap: 16px; max-height: calc(100vh - 40px); overflow: auto; scrollbar-width: thin; padding: 4px; margin: -4px; }
.forzar-ancho .aside-sticky { max-height: none; overflow: visible; }

.progress { display: flex; flex-direction: column; gap: 8px; padding: 4px 0 0; }
.progress-label { font-size: 15px; font-weight: 600; color: var(--ve-text-2); display: flex; justify-content: space-between; gap: 12px; white-space: nowrap; }
.progress-bar { display: none; height: 6px; border-radius: var(--ve-r-pill); background: var(--ve-bg-2); overflow: hidden; }
.progress-bar span { display: block; height: 100%; background: var(--ve-gold); border-radius: inherit; transition: width .35s ease; }

.step { display: flex; flex-direction: column; gap: 24px; padding: 16px 0 8px; }
.step-head { display: flex; flex-direction: column; gap: 10px; }
.q-hello { font-size: 17px; font-weight: 500; color: var(--ve-text-2); }
.q-title { font: 200 clamp(36px, 3.4vw, 48px)/1.08 var(--ve-font-display); letter-spacing: -.01em; text-wrap: balance; }
.q-title:focus { outline: none; }
.q-help { font-size: 18px; color: var(--ve-text-2); text-wrap: pretty; }
.t-enter { transition: opacity var(--ve-dur) ease, transform var(--ve-dur) ease; }
.t-enter-start { opacity: 0; transform: translateX(calc(var(--dir, 1) * 28px)); }
.t-enter-end { opacity: 1; transform: none; }

/* ---------- Tarjetas de elección (fila de 3) ---------- */
.choices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.choice {
  position: relative; width: 100%;
  display: flex; flex-direction: column; align-items: flex-start; gap: 14px;
  min-height: 236px; padding: 22px 20px 18px;
  text-align: left;
  background: var(--ve-card);
  border: 1.5px solid var(--ve-border); border-radius: var(--ve-r-card);
  box-shadow: var(--ve-shadow);
  transition: border-color var(--ve-dur), background var(--ve-dur), transform var(--ve-dur), box-shadow var(--ve-dur);
}
.choice:hover { border-color: var(--ve-border-strong); transform: translateY(-3px); box-shadow: var(--ve-shadow-hover); }
.choice:hover .choice-icon { transform: scale(1.06); }
.choice[aria-pressed="true"] {
  border-color: var(--ve-gold);
  background: linear-gradient(var(--ve-gold-soft), var(--ve-gold-soft)), var(--ve-card);
  box-shadow: 0 0 0 1.5px var(--ve-gold) inset;
}
.choice-icon { width: 64px; height: 64px; border-radius: 18px; display: grid; place-items: center; flex: none; color: var(--ve-navy); transition: transform var(--ve-dur); }
.choice-icon .icon { width: 32px; height: 32px; }
.choice-text { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.choice-title { font: 700 22px/1.2 var(--ve-font-display); }
.choice-desc { font-size: 16px; line-height: 1.4; color: var(--ve-text-2); text-wrap: pretty; }
.choice-check {
  position: absolute; top: 18px; right: 18px;
  width: 28px; height: 28px; border-radius: 50%; flex: none;
  display: grid; place-items: center;
  border: 1.5px solid var(--ve-border-strong); color: transparent;
  transition: all var(--ve-dur);
}
.choice[aria-pressed="true"] .choice-check { background: var(--ve-gold); border-color: var(--ve-gold); color: var(--ve-on-gold); animation: checkIn .3s ease; }
.choice-check .icon { width: 16px; height: 16px; stroke-width: 3; }
.choice-key { margin-top: auto; font-size: 13px; color: var(--ve-text-2); display: flex; align-items: center; gap: 8px; }
.choice.pop { animation: pop .32s ease; }
@keyframes pop { 0% { transform: scale(1); } 35% { transform: scale(.97); } 70% { transform: scale(1.01); } 100% { transform: scale(1); } }
@keyframes checkIn { 0% { transform: scale(.4); } 70% { transform: scale(1.15); } 100% { transform: scale(1); } }
.bg-salmon { background: var(--ve-salmon); }
.bg-gold { background: var(--ve-gold); }
.bg-green { background: var(--ve-green); }
.bg-teal { background: var(--ve-teal); }
.bg-lavender { background: var(--ve-lavender); }
.bg-brand { background: var(--ve-brand); }
.tool-letter { font: 800 30px/1 var(--ve-font-display); }
/* Frecuencia: rejilla 2×2 de opciones cortas */
.choices-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.choices-grid .choice { min-height: 84px; flex-direction: row; align-items: center; padding: 18px 20px; gap: 14px; }
.choices-grid .choice:hover { transform: translateY(-2px); }
.choices-grid .choice-title { font-size: 20px; flex: 1; }
.choices-grid .choice-check { position: static; }
.choices-grid kbd { flex: none; }

/* ---------- Texto ---------- */
.field { display: flex; flex-direction: column; gap: 10px; }
.field-label { font-weight: 600; font-size: 17px; }
.textbox { position: relative; }
.textarea, .input {
  width: 100%;
  background: var(--ve-field);
  border: 1.5px solid var(--ve-border-strong); border-radius: var(--ve-r);
  font-size: 18px; line-height: 1.5;
  transition: border-color var(--ve-dur), box-shadow var(--ve-dur);
}
.textarea { min-height: 132px; padding: 16px 132px 16px 18px; resize: vertical; display: block; }
.textarea:hover, .input:hover { border-color: var(--ve-text-2); }
.input { min-height: 56px; padding: 12px 16px; }
.textarea:focus, .input:focus { outline: none; border-color: var(--ve-gold); box-shadow: 0 0 0 3px var(--ve-gold-soft); }
.textarea::placeholder, .input::placeholder { color: var(--ve-text-2); }
.example { font-size: 16px; color: var(--ve-text-2); text-wrap: pretty; }
.example em { font-style: normal; font-weight: 600; color: var(--ve-text); }
.mic {
  position: absolute; right: 10px; bottom: 10px;
  height: 44px; min-width: 44px; padding: 0 14px;
  display: inline-flex; align-items: center; gap: 8px;
  border-radius: var(--ve-r-pill); border: 1px solid var(--ve-border);
  background: var(--ve-bg-2); color: var(--ve-text); font-size: 15px; font-weight: 600;
  transition: border-color var(--ve-dur), background var(--ve-dur);
}
.mic:hover { border-color: var(--ve-text-2); background: var(--ve-gold-soft); }
.mic.on { background: var(--ve-salmon); color: var(--ve-navy); border-color: var(--ve-salmon); }
.mic.on .icon { animation: breathe 1.2s ease-in-out infinite; }
@keyframes breathe { 50% { transform: scale(1.18); } }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  min-height: 44px; padding: 0 18px;
  border-radius: var(--ve-r-pill); border: 1.5px solid var(--ve-border-strong);
  background: var(--ve-card); font-size: 16px; font-weight: 500;
  transition: border-color var(--ve-dur), background var(--ve-dur);
}
.chip:hover { border-color: var(--ve-text-2); background: linear-gradient(var(--ve-gold-soft), var(--ve-gold-soft)), var(--ve-card); }
.chip[aria-pressed="true"] { border-color: var(--ve-gold); background: var(--ve-gold-soft); }
.hint { display: flex; gap: 10px; align-items: center; padding: 12px 16px; border-radius: var(--ve-r); background: var(--ve-gold-soft); font-size: 17px; font-weight: 500; animation: hintIn .25s ease; margin-top: 8px; }
@keyframes hintIn { from { opacity: 0; transform: translateY(-4px); } }

/* ---------- Capturas ---------- */
.shot-btn {
  width: 100%; min-height: 96px; padding: 18px 22px;
  display: flex; align-items: center; gap: 18px; text-align: left; cursor: pointer;
  background: var(--ve-card); border: 2px dashed var(--ve-border-strong); border-radius: var(--ve-r-card);
  transition: border-color var(--ve-dur), background var(--ve-dur);
}
.shot-btn:hover { border-color: var(--ve-gold); background: linear-gradient(var(--ve-gold-soft), var(--ve-gold-soft)), var(--ve-card); }
.shot-btn:focus-within { outline: 3px solid var(--ve-gold); outline-offset: 3px; }
.shot-btn .choice-icon { width: 56px; height: 56px; border-radius: 16px; }
.shot-btn .choice-icon .icon { width: 28px; height: 28px; }
.shot-small { min-height: 60px; padding: 10px 16px; border-width: 1.5px; }
.shot-small .choice-icon { width: 40px; height: 40px; border-radius: 10px; }
.shot-small .choice-icon .icon { width: 22px; height: 22px; }
.shot-small .choice-title { font-size: 18px; }
.howto { display: none; }
.howto summary {
  list-style: none; cursor: pointer; min-height: 44px;
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--ve-link); font-weight: 600; font-size: 16px;
}
.howto summary::-webkit-details-marker { display: none; }
.howto summary .icon { transition: transform var(--ve-dur); width: 18px; height: 18px; }
.howto[open] summary .icon { transform: rotate(90deg); }
.howto-body { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 8px; }
.howto-card { padding: 16px; border-radius: var(--ve-r-card); background: var(--ve-bg-2); display: flex; flex-direction: column; gap: 8px; font-size: 16px; }
.howto-card h3 { font: 700 18px/1.2 var(--ve-font-display); display: flex; align-items: center; gap: 8px; }
.thumbs { display: flex; flex-wrap: wrap; gap: 12px; }
.thumb { position: relative; width: 200px; height: 130px; border-radius: 10px; overflow: hidden; border: 1px solid var(--ve-border); background: var(--ve-bg-2); animation: hintIn .25s ease; transition: box-shadow var(--ve-dur), transform var(--ve-dur); }
.thumb:hover { box-shadow: 0 0 0 3px var(--ve-gold), var(--ve-shadow-hover); transform: translateY(-2px); }
.thumb-open { display: block; width: 100%; height: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; }
.thumb-open img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb-zoom { position: absolute; left: 8px; bottom: 8px; padding: 4px 10px; border-radius: var(--ve-r-pill); background: rgba(17, 23, 48, .78); color: #fff; font-size: 13px; font-weight: 600; opacity: 0; transition: opacity var(--ve-dur); pointer-events: none; }
.thumb:hover .thumb-zoom, .thumb:focus-within .thumb-zoom { opacity: 1; }
.thumb-del {
  position: absolute; top: 6px; right: 6px; width: 34px; height: 34px;
  border-radius: 50%; border: 0; background: rgba(17, 23, 48, .8); color: #fff;
  display: grid; place-items: center; transition: background var(--ve-dur);
}
.thumb-del:hover { background: #B3261E; }
.thumb-del .icon { width: 16px; height: 16px; stroke-width: 2.5; }

/* Capa de soltar en toda la ventana */
.dropzone {
  position: fixed; inset: 0; z-index: 45; pointer-events: none;
  display: grid; place-items: center;
  background: rgba(245, 243, 236, .82); backdrop-filter: blur(4px);
}
.dropzone-box {
  width: min(640px, calc(100vw - 48px)); padding: 48px 32px; border-radius: 24px;
  border: 3px dashed var(--ve-gold); background: var(--ve-card);
  display: flex; flex-direction: column; align-items: center; gap: 16px; text-align: center;
}
.dropzone-box .choice-icon { width: 72px; height: 72px; border-radius: 20px; }
.dropzone-box p { font: 300 34px/1.15 var(--ve-font-display); }

/* Visor de capturas */
.visor { position: fixed; inset: 0; z-index: 55; background: rgba(17, 23, 48, .82); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: 32px; }
.visor img { max-width: min(1200px, 100%); max-height: calc(100vh - 140px); border-radius: 10px; box-shadow: 0 30px 80px rgba(0, 0, 0, .4); background: #fff; }
.visor .btn { color: #EDEBE3; border-color: rgba(237, 235, 227, .4); }
.visor .btn:hover { background: rgba(237, 235, 227, .12); color: #fff; }
.visor .btn kbd { background: transparent; color: #EDEBE3; border-color: rgba(237, 235, 227, .4); }

/* ---------- Navegación de pasos ---------- */
.nav { display: flex; gap: 12px; align-items: center; padding: 28px 0 8px; }
.nav .push { margin-left: auto; display: flex; gap: 12px; align-items: center; }
.nav .btn-gold { min-width: 210px; }
.shortcuts { display: flex; flex-wrap: wrap; gap: 6px 18px; padding-top: 8px; font-size: 14px; color: var(--ve-text-2); }
.shortcuts span { display: inline-flex; align-items: center; gap: 6px; }

/* ---------- Panel derecho ---------- */
.aside-card { padding: 22px 24px; display: flex; flex-direction: column; gap: 14px; }
.aside-eyebrow { display: flex; align-items: center; gap: 8px; font: 600 13px/1 var(--ve-font-body); letter-spacing: .1em; text-transform: uppercase; color: var(--ve-text-2); }
.aside-eyebrow .icon { width: 18px; height: 18px; }
.aside-title { font: 700 20px/1.25 var(--ve-font-display); }
.aside-text { font-size: 16px; color: var(--ve-text-2); text-wrap: pretty; }
.help-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.help-list li { display: grid; grid-template-columns: 12px 1fr; gap: 4px 12px; align-items: baseline; font-size: 16px; }
.help-list .dot { transform: translateY(1px); }
.help-list strong { font-weight: 600; }
.help-list span.q { grid-column: 2; color: var(--ve-text-2); font-size: 15px; }
.vc { display: flex; flex-direction: column; gap: 10px; }
.vc-item { padding: 14px 16px; border-radius: 12px; display: grid; grid-template-columns: 28px 1fr; gap: 4px 10px; align-items: start; }
.vc-item .vc-mark { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; color: var(--ve-navy); }
.vc-item .vc-mark .icon { width: 16px; height: 16px; stroke-width: 3; }
.vc-item p { font-size: 16px; line-height: 1.45; }
.vc-item small { grid-column: 2; font-size: 13px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--ve-text-2); }
.vc-bad { background: var(--ve-salmon-soft); }
.vc-good { background: var(--ve-green-soft); }
.keys { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-weight: 600; }
.keys .arrow { color: var(--ve-text-2); padding: 0 4px; }
.help-steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; font-size: 16px; }
.help-steps li { display: flex; flex-direction: column; gap: 8px; }
.help-steps .n { font: 700 13px/1 var(--ve-font-mono); color: var(--ve-text-2); }
.help-sub { border-top: 1px solid var(--ve-border); padding-top: 14px; display: flex; flex-direction: column; gap: 6px; font-size: 16px; }

/* Lo que nos llevas contado */
.live-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.live-row {
  width: 100%; display: grid; grid-template-columns: 26px 1fr; gap: 12px; align-items: start;
  padding: 6px 10px; margin: 0 -10px; border: 0; border-radius: 10px; background: none; text-align: left;
  transition: background var(--ve-dur);
  position: relative;
}
.live-list li:not(:last-child) .live-row::after { content: ''; position: absolute; left: 22px; top: 34px; bottom: -4px; width: 2px; background: var(--ve-border); border-radius: 2px; }
.live-list li:not(:last-child) .live-row.hecho::after { background: var(--ve-gold); opacity: .6; }
.live-row:disabled { cursor: default; }
.live-row:not(:disabled):hover { background: var(--ve-bg-2); }
.live-row:not(:disabled):hover .live-name { text-decoration: underline; text-underline-offset: 3px; }
.live-dot { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; border: 2px solid var(--ve-border-strong); font: 700 12px/1 var(--ve-font-mono); color: var(--ve-text-2); background: var(--ve-bg); position: relative; z-index: 1; }
.live-dot .icon { width: 14px; height: 14px; stroke-width: 3; }
.live-row.hecho .live-dot { background: var(--ve-gold); border-color: var(--ve-gold); color: var(--ve-on-gold); }
.live-row.actual .live-dot { border-color: var(--ve-gold); color: var(--ve-text); box-shadow: 0 0 0 4px var(--ve-gold-soft); }
.live-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding-top: 2px; }
.live-name { font-size: 15px; font-weight: 600; color: var(--ve-text-2); }
.live-row.actual .live-name, .live-row.hecho .live-name { color: var(--ve-text); }
.live-val { font-size: 15px; line-height: 1.4; color: var(--ve-text-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.live-val.sin { font-style: italic; }
.live-shots { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.live-shots button { width: 64px; height: 42px; padding: 0; border-radius: 6px; overflow: hidden; border: 1px solid var(--ve-border); background: var(--ve-bg-2); cursor: zoom-in; transition: box-shadow var(--ve-dur); }
.live-shots button:hover { box-shadow: 0 0 0 2px var(--ve-gold); }
.live-shots img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------- Resumen ---------- */
.card { background: var(--ve-card); border: 1px solid var(--ve-border); border-radius: var(--ve-r-card); box-shadow: var(--ve-shadow); }
.summary { padding: 28px; display: flex; flex-direction: column; gap: 20px; }
.summary-text { font: 300 26px/1.5 var(--ve-font-display); text-wrap: pretty; }
.frag {
  display: inline; padding: 0 2px; margin: 0; border: 0; cursor: pointer;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
  background: linear-gradient(transparent 62%, var(--ve-gold-soft) 62%);
  font: 700 26px/1.5 var(--ve-font-display); color: var(--ve-text); text-align: left;
  text-decoration: underline; text-decoration-color: var(--ve-gold); text-decoration-thickness: 2px; text-underline-offset: 5px;
  border-radius: 3px;
  transition: background var(--ve-dur);
}
.frag:hover { background: var(--ve-gold-soft); text-decoration-thickness: 3px; }
.frag-empty { font-weight: 400; color: var(--ve-text-2); font-style: italic; }
.send-btn { min-width: 240px; }

/* ---------- Gracias ---------- */
.gracias { flex: 1; width: 100%; max-width: 680px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 28px; padding: 48px 0 80px; }
.gracias-check { width: 104px; height: 104px; border-radius: 50%; background: var(--ve-green); color: var(--ve-navy); display: grid; place-items: center; animation: checkIn .5s ease; }
.gracias-check .icon { width: 52px; height: 52px; stroke-width: 2.5; }
.gracias h1 { font: 200 clamp(56px, 6vw, 84px)/1 var(--ve-font-display); letter-spacing: -.02em; }
.gracias h1:focus { outline: none; }
.gracias-num { width: 100%; font-size: 22px; line-height: 1.5; text-wrap: pretty; }
.ref { font: 700 .95em/1 var(--ve-font-mono); padding: 4px 10px; border-radius: var(--ve-r); background: var(--ve-gold); color: var(--ve-on-gold); white-space: nowrap; }
.culture { padding: 20px 24px; font: 300 22px/1.4 var(--ve-font-display); display: flex; gap: 16px; align-items: center; text-align: left; }
.culture .choice-icon { width: 48px; height: 48px; border-radius: 14px; }
.culture .choice-icon .icon { width: 24px; height: 24px; }
.gracias-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
.confetti { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 30; }
.confetti i { position: absolute; top: -16px; width: 10px; height: 14px; border-radius: 2px; animation: fall 2.6s cubic-bezier(.2, .6, .4, 1) forwards; }
@keyframes fall { to { transform: translate3d(var(--x), 105vh, 0) rotate(var(--r)); opacity: .9; } }

/* ---------- Lo que he enviado ---------- */
.envios { display: flex; flex-direction: column; gap: 24px; padding: 16px 0 48px; }
.envios-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.envios-head > div { flex: 1; min-width: 280px; display: flex; flex-direction: column; gap: 8px; }
.envios-legend { display: flex; flex-wrap: wrap; gap: 8px; }
.et { display: flex; flex-direction: column; gap: 8px; }
.et-head, .et-row { display: grid; grid-template-columns: 76px minmax(0, 1fr) 170px 130px 220px; gap: 20px; align-items: center; padding: 0 24px; }
.et-head { font: 600 13px/1 var(--ve-font-body); letter-spacing: .08em; text-transform: uppercase; color: var(--ve-text-2); padding-bottom: 4px; }
.et-row { min-height: 76px; padding-top: 14px; padding-bottom: 14px; transition: box-shadow var(--ve-dur), border-color var(--ve-dur); }
.et-row:hover { border-color: var(--ve-border-strong); box-shadow: var(--ve-shadow-hover); }
.envio-ref { font: 700 16px/1 var(--ve-font-mono); color: var(--ve-text-2); }
.envio-title { font: 700 19px/1.3 var(--ve-font-display); text-wrap: pretty; }
.et-type { display: flex; align-items: center; gap: 8px; font-size: 15px; }
.et-date { font-size: 15px; color: var(--ve-text-2); }
.et-state { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: var(--ve-r-pill); font-size: 14px; font-weight: 600; color: var(--ve-navy); white-space: nowrap; }
.pill-recibido { background: var(--ve-lavender); }
.pill-revisando { background: var(--ve-teal); }
.pill-en_marcha { background: var(--ve-gold); }
.pill-hecho { background: var(--ve-green); }
.track { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; width: 100%; }
.track span { height: 5px; border-radius: var(--ve-r-pill); background: var(--ve-bg-2); }
.track span.on { background: var(--ve-text); opacity: .7; }
.empty { padding: 40px 24px; text-align: center; display: flex; flex-direction: column; gap: 16px; align-items: center; }

/* ---------- Tutorial ---------- */
.overlay { position: fixed; inset: 0; z-index: 40; background: var(--ve-overlay); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); display: flex; align-items: center; justify-content: center; padding: var(--ve-pad); }
.bubble {
  width: 100%; max-width: 640px; padding: 24px 28px 22px;
  background: var(--ve-bg); border-radius: 22px; box-shadow: 0 30px 80px rgba(0, 0, 0, .28);
  display: flex; flex-direction: column; gap: 14px;
}
.bubble-count { font: 600 14px/1 var(--ve-font-body); color: var(--ve-text-2); }
.bubble h2 { font: 300 32px/1.15 var(--ve-font-display); text-wrap: balance; }
.bubble h2:focus { outline: none; }
.bubble p { font-size: 17px; color: var(--ve-text-2); text-wrap: pretty; }
.bubble-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 6px; }
.bubble-foot > div { display: flex; gap: 8px; align-items: center; }
.dots { display: flex; gap: 6px; }
.dots span { width: 8px; height: 8px; border-radius: 50%; background: var(--ve-border-strong); transition: all var(--ve-dur); }
.dots span.on { width: 24px; border-radius: 4px; background: var(--ve-gold); }
/* Imagen de referencia: miniatura hecha con los mismos estilos */
.tut-ref { position: relative; height: 232px; border-radius: 14px; background: var(--ve-bg-2); border: 1px solid var(--ve-border); overflow: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 20px 24px; }
.tut-ref .sc-cards { width: 100%; }
.tut-ref .sc-card { background: var(--ve-card); min-height: 132px; }
.tut-ref .sc-card small { font-size: 12px; line-height: 1.35; color: var(--ve-text-2); }
.tut-ref .keys kbd { font-size: 15px; padding: 3px 10px; border-bottom-width: 4px; }
.tut-row { display: flex; align-items: center; gap: 12px; width: 100%; }
.tut-shot { flex: 1; display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 12px; border: 2px dashed var(--ve-border-strong); background: var(--ve-card); font: 700 16px/1.2 var(--ve-font-display); }
.tut-shot .choice-icon { width: 38px; height: 38px; border-radius: 10px; }
.tut-shot .choice-icon .icon { width: 20px; height: 20px; }
.tut-thumb { width: 108px; height: 70px; border-radius: 8px; border: 1px solid var(--ve-border); background: linear-gradient(#131F7A 0 12px, transparent 12px), linear-gradient(90deg, transparent 60%, #FF7F6F 60% 90%, transparent 90%) 0 38px / 100% 22px no-repeat, #fff; animation: thumbIn 2.4s ease infinite; flex: none; }
@keyframes thumbIn { 0%, 30% { opacity: 0; transform: scale(.8); } 45%, 100% { opacity: 1; transform: none; } }
.tut-chips { display: flex; gap: 6px; width: 100%; }
.tut-chips span { padding: 6px 12px; border-radius: var(--ve-r-pill); border: 1.5px solid var(--ve-border-strong); background: var(--ve-card); font-size: 13px; font-weight: 500; white-space: nowrap; }
.tut-chips span.on { border-color: var(--ve-gold); background: var(--ve-gold-soft); }
.tut-area { position: relative; width: 100%; height: 96px; border-radius: 8px; border: 1.5px solid var(--ve-gold); background: var(--ve-field); box-shadow: 0 0 0 3px var(--ve-gold-soft); padding: 12px 14px; font-size: 15px; }
.tut-type { display: inline-block; max-width: 0; overflow: hidden; white-space: nowrap; vertical-align: bottom; border-right: 2px solid var(--ve-text); animation: typing 3.6s steps(34) infinite; }
@keyframes typing { 0% { max-width: 0; } 70%, 100% { max-width: 34ch; } }
.tut-area .mic { position: absolute; right: 8px; bottom: 8px; height: 36px; font-size: 13px; }
.tut-sum { width: 100%; padding: 14px 16px; border-radius: 12px; background: var(--ve-card); border: 1px solid var(--ve-border); font: 300 17px/1.5 var(--ve-font-display); }
.tut-sum b { font-weight: 700; background: linear-gradient(transparent 62%, var(--ve-gold-soft) 62%); text-decoration: underline; text-decoration-color: var(--ve-gold); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.tut-send { display: inline-flex; align-items: center; gap: 8px; padding: 10px 22px; border-radius: var(--ve-r); background: var(--ve-gold); color: var(--ve-on-gold); font-weight: 600; font-size: 15px; }
.tut-send .icon { width: 18px; height: 18px; }
.tut-ok { display: inline-flex; align-items: center; gap: 10px; padding: 8px 14px; border-radius: 12px; background: var(--ve-green-soft); font: 700 16px/1 var(--ve-font-display); }
.pulse { position: absolute; width: 52px; height: 52px; margin: -26px 0 0 -26px; border-radius: 50%; pointer-events: none; z-index: 2; }
.pulse::before, .pulse::after { content: ''; position: absolute; inset: 0; border-radius: 50%; border: 3px solid var(--ve-gold); animation: pulse 1.6s ease-out infinite; }
.pulse::after { animation-delay: .8s; }
.pulse i { position: absolute; inset: 14px; border-radius: 50%; border: 3px solid var(--ve-gold); box-shadow: 0 0 0 2px rgba(255, 255, 255, .7); }
@keyframes pulse { 0% { transform: scale(.5); opacity: 1; } 100% { transform: scale(1.6); opacity: 0; } }

/* ---------- Toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 32px; transform: translateX(-50%); z-index: 50;
  display: flex; align-items: center; gap: 12px;
  max-width: calc(100vw - 32px); padding: 10px 10px 10px 18px;
  background: var(--ve-navy); color: #EDEBE3; border-radius: var(--ve-r-pill);
  font-size: 16px; font-weight: 500; box-shadow: 0 10px 30px rgba(0, 0, 0, .2);
}
@media (prefers-color-scheme: dark) { :root:not([data-tema="claro"]) .toast { background: #EDEBE3; color: var(--ve-navy); } }
:root[data-tema="oscuro"] .toast { background: #EDEBE3; color: var(--ve-navy); }
.toast button { min-height: 40px; padding: 0 14px; border-radius: var(--ve-r-pill); border: 0; background: var(--ve-gold); color: var(--ve-navy); font-weight: 600; font-size: 15px; }
.toast button:hover { background: var(--ve-gold-hover); }
.toast .toast-plain { min-height: 40px; display: inline-flex; align-items: center; padding-right: 8px; }

/* ---------- Cargando ---------- */
.loading { flex: 1; display: grid; place-items: center; color: var(--ve-text-2); }

/* ---------- Panel de pruebas (solo con ?demo) ---------- */
.demo { position: fixed; left: 12px; bottom: 12px; z-index: 60; font: 500 13px/1.3 var(--ve-font-body); }
.demo > button { min-height: 36px; padding: 0 12px; border-radius: var(--ve-r-pill); border: 1px dashed var(--ve-text-2); background: var(--ve-bg); color: var(--ve-text-2); }
.demo-panel { margin-bottom: 8px; width: 240px; max-height: 70vh; overflow: auto; padding: 12px; border-radius: 12px; background: var(--ve-bg); border: 1px solid var(--ve-border-strong); box-shadow: var(--ve-shadow); display: flex; flex-direction: column; gap: 6px; }
.demo-panel a { color: var(--ve-text); text-decoration: none; padding: 4px 6px; border-radius: 6px; }
.demo-panel a:hover { background: var(--ve-bg-2); }
.demo-panel label { display: flex; gap: 8px; align-items: center; padding: 4px 6px; }
.demo-panel p { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--ve-text-2); margin-top: 6px; }

/* ---------- Pantallas estrechas (secundario) ---------- */
@container app (max-width: 1023px) {
  .wizard { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .aside-sticky { position: static; max-height: none; overflow: visible; }
  .aside-live { display: none; }
  .progress-bar { display: block; }
  .entrada { grid-template-columns: minmax(0, 1fr); }
  .showcase { display: none; }
  .howto { display: block; }
  .aside-help-donde { display: none; }
  .et-head { display: none; }
  .et-row { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "ref state" "title title" "type date"; gap: 8px 16px; padding: 18px 20px; }
  .et-row .envio-ref { grid-area: ref; }
  .et-row .envio-title { grid-area: title; }
  .et-row .et-type { grid-area: type; }
  .et-row .et-date { grid-area: date; text-align: right; }
  .et-row .et-state { grid-area: state; align-items: flex-end; }
  .et-row .track { width: 120px; }
}
@container app (max-width: 720px) {
  .top, main, .overlay { --ve-pad: 16px; }
  .choices { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .choice { flex-direction: row; align-items: center; min-height: 88px; padding: 18px 56px 18px 18px; }
  .choice:hover { transform: none; }
  .choice-icon { width: 56px; height: 56px; border-radius: 16px; }
  .choice-icon .icon { width: 28px; height: 28px; }
  .choice-key { display: none; }
  .choice-check { top: 50%; margin-top: -14px; }
  .choices-grid { grid-template-columns: minmax(0, 1fr); }
  .hello-text, .icon-btn .label, .brand-sub { display: none; }
  .icon-btn { padding: 0; width: 48px; }
  .entrada .btn-xl { align-self: stretch; padding: 0 16px; font-size: 17px; }
  .nav { position: sticky; bottom: 0; z-index: 5; padding: 16px 0 calc(16px + env(safe-area-inset-bottom)); background: linear-gradient(to top, var(--ve-bg) 72%, transparent); }
  .nav .btn-gold { min-width: 0; flex: 1; }
  .nav .push { flex: 1; }
  .howto-body { grid-template-columns: 1fr; }
  .thumb { width: 150px; height: 100px; }
  .textarea { padding-right: 18px; padding-bottom: 64px; }
  .gracias-actions .btn { flex: 1 1 100%; }
  .overlay { align-items: flex-end; }
  .tut-ref { height: 200px; padding: 14px; }
  .toast { bottom: calc(96px + env(safe-area-inset-bottom)); }
}
@media (hover: none) {
  .kbd-hint, .shortcuts, .btn kbd { display: none !important; }
}
@container app (max-width: 720px) {
  .kbd-hint, .shortcuts, .btn kbd { display: none !important; }
}

/* ?movil: fuerza la vista estrecha (solo para sacar capturas en escritorio) */
.forzar-movil .app { max-width: 390px; margin: 0 auto; box-shadow: 0 0 0 1px var(--ve-border); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; }
  .t-enter-start { transform: none; }
  .confetti { display: none; }
  .tut-type { max-width: 34ch; border-right: 0; }
}
