/* =============================================================================
   Cerrojo Trust Vault — hoja de estilos
   Rediseño minimalista monocromo, mobile-first.

   Principios:
   - Una sola familia sans (Inter) para display y body; mono (JetBrains Mono)
     reservada a IDs, timestamps y etiquetas técnicas — la "signature" del
     dominio criptográfico.
   - Paleta neutra: blanco off, escala de grises, un solo acento slate.
     Estados semánticos apagados (nada eléctrico).
   - Sin gradientes decorativos, sin backdrop-filter, sin box-shadow flotante
     salvo modales y toasts.
   - Radius 4px consistente. Solo el avatar es circular.
   - Mobile-first: layout base a 1 columna, se expande con min-width.
   ========================================================================== */

/* -------- Tokens -------- */
:root {
  --bg-body: #F8F9FA;
  --bg: var(--bg-body);
  --surface: #FFFFFF;
  --surface-hover: #F1F3F5;
  --surface-2: var(--surface-hover);
  --surface-3: #E9ECEF;
  --ink: #212529;
  --ink-2: #495057;
  --muted: #6C757D;
  --line: #E9ECEF;
  --line-2: #CED4DA;
  --accent: #1f2937;
  --accent-hover: #6D28D9;
  --accent-cyan: #0EA5E9;
  --accent-purple: #7C3AED;
  --surface-dark: #111827;
  --primary: #0D9488;
  --error: #EF4444;
  --focus: rgba(14, 165, 233, 0.2);

  --ok: #0D9488;
  --ok-bg: #E6FFFA;
  --ok-line: #99F6E4;
  --warn: #B45309;
  --warn-bg: #FFF7ED;
  --warn-line: #FED7AA;
  --danger: #EF4444;
  --danger-bg: #FEF2F2;
  --danger-line: #FECACA;
  --info: #0EA5E9;
  --info-bg: #F0F9FF;
  --info-line: #BAE6FD;

  --radius: 12px;
  --radius-lg: 12px;
  --shadow-modal: 0 24px 60px rgba(0, 0, 0, 0.18);
  --shadow-toast: 0 12px 32px rgba(0, 0, 0, 0.16);

  --max: 1200px;

  --sans: "Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  --serif: Georgia, "Times New Roman", serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* -------- Base -------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
html, body { overflow-x: hidden; }
body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background: var(--bg-body);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.618;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: "cv11", "ss01";
}
h1, h2, h3, h4 { color: #111827; font-family: var(--sans); font-weight: 600; letter-spacing: -0.015em; margin: 0; }
h1 { font-size: clamp(28px, 5vw, 44px); line-height: 1.1; }
h2 { font-size: clamp(20px, 3vw, 28px); line-height: 1.2; }
h3 { font-size: 17px; }
p { margin: 0 0 12px; }
a { color: inherit; text-decoration: none; }
a.link { color: var(--accent); border-bottom: 1px solid var(--line-2); }
a.link:hover { border-bottom-color: var(--accent); }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
main { min-height: 60vh; }
img { max-width: 100%; height: auto; display: block; }
::selection { background: var(--accent-purple); color: var(--surface); }

.mono { font-family: var(--mono); font-size: 0.92em; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.hide { display: none !important; }
.copy { user-select: all; }
.help { font-size: 12px; color: var(--muted); margin-top: 6px; }

/* -------- Container -------- */
.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 16px;
  min-width: 0;
}
@media (min-width: 640px) { .container { padding: 0 24px; } }
@media (min-width: 1024px) { .container { padding: 0 32px; } }

.section { padding: 32px 0; }
.dashboard { padding: 24px 0 48px; }
.hero { padding: 40px 0 24px; }
@media (min-width: 900px) {
  .section { padding: 48px 0; }
  .hero { padding: 64px 0 32px; }
}

h1, h2, h3, p, .job-summary, .lead { overflow-wrap: break-word; word-break: break-word; }

/* -------- Top strip -------- */
.top-strip {
  background: var(--ink);
  color: var(--surface-2);
  font-size: 12px;
  border-bottom: 1px solid var(--ink);
  font-family: var(--mono);
}
.top-strip .container {
  min-height: 30px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 6px;
  padding-bottom: 6px;
  flex-wrap: wrap;
}
.top-strip strong { color: #fff; font-weight: 500; }

/* -------- Header / Nav -------- */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.nav {
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 16px;
  letter-spacing: -0.01em;
  white-space: nowrap;
  color: var(--ink);
}
.brand-mark {
  width: 28px;
  height: 28px;
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--surface);
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 600;
  font-family: var(--mono);
  flex: 0 0 auto;
}
.brand small {
  display: block;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--muted);
  font-weight: 400;
  margin-top: -2px;
  text-transform: uppercase;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.nav-links > a:not(.btn), .plain-btn {
  color: var(--ink-2);
  font-weight: 500;
  font-size: 14px;
  padding: 8px 12px;
  border-radius: var(--radius);
}
.nav-links > a:not(.btn):hover, .plain-btn:hover { color: var(--ink); background: var(--surface-2); }
.user-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line);
  padding: 6px 10px 6px 6px;
  border-radius: var(--radius);
  background: var(--surface);
  font-weight: 500;
  font-size: 13px;
  max-width: 240px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: border-color 0.15s ease;
}
button.user-pill:hover { border-color: var(--line-2); background: var(--surface-2); }
button.user-pill:active { transform: translateY(1px); }
.avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--surface-3);
  color: var(--ink-2);
  font-weight: 600;
  font-size: 11px;
  flex: 0 0 auto;
}
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
  width: 40px;
  height: 40px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  flex: 0 0 auto;
}
.nav-toggle span {
  display: block;
  width: 18px;
  height: 1.5px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.15s ease;
}
.nav-toggle.open span:nth-child(1) { transform: translateY(5.5px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-5.5px) rotate(-45deg); }

@media (max-width: 768px) {
  .nav { flex-wrap: wrap; align-items: center; min-height: 56px; }
  .brand { font-size: 15px; }
  .nav-toggle { display: flex; }
  .nav-links {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 8px 0 4px;
    order: 3;
  }
  .nav-links.open { display: flex; }
  .nav-links > a:not(.btn), .nav-links > .plain-btn {
    padding: 12px;
    border-radius: var(--radius);
  }
  .nav-links > a:not(.btn):not(:last-child) { border-bottom: 1px solid var(--line); }
  .nav-links .btn { width: 100%; }
  .user-pill { width: 100%; max-width: 100%; justify-content: flex-start; }
}

/* -------- Botones -------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: var(--radius);
  border: 1px solid var(--line-2);
  padding: 10px 16px;
  background: var(--surface);
  color: var(--ink);
  font-weight: 500;
  font-size: 14px;
  min-height: 40px;
  text-align: center;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
  white-space: nowrap;
}
.btn:hover { background: var(--surface-2); border-color: var(--ink-2); }
.btn:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.btn:active { transform: translateY(1px); }
.btn.primary {
  background: #111827;
  border-color: #111827;
  color: #FFFFFF;
}
.btn.primary:hover {
  background: #1F2937;
  border-color: #1F2937;
  box-shadow: 0 4px 12px rgba(17, 24, 39, 0.16);
}
.btn.secondary { background: var(--ink); border-color: var(--ink); color: var(--surface); }
.btn.secondary:hover { background: var(--ink-2); border-color: var(--ink-2); }
.btn.ghost { background: transparent; border-color: var(--line); color: var(--ink-2); }
.btn.ghost:hover { background: var(--surface-2); color: var(--ink); }
.btn.green { background: var(--ok); border-color: var(--ok); color: #fff; }
.btn.green:hover { background: #14532D; border-color: #14532D; }
.btn.danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn.danger:hover { background: #7F1D1D; border-color: #7F1D1D; }
.btn.small { min-height: 32px; padding: 6px 12px; font-size: 12px; }
.btn.block { display: flex; width: 100%; }

@media (max-width: 640px) {
  .btn.small { min-height: 40px; padding: 9px 14px; font-size: 13px; }
  .hero-actions .btn, .form-actions .btn { width: 100%; }
}

/* -------- Panels / Cards -------- */
.panel, .premium-card, .auth-card, .viewer-card, .hero-card, .card, .job-card, .filter-sidebar {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  transition: all 0.25s ease;
}
.card:hover, .job-card:hover, .filter-sidebar:hover {
  transform: translateY(-2px);
  border-color: rgba(124, 58, 237, 0.2);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
}
.panel.flat { border-color: transparent; padding: 0; }
.elevated { box-shadow: 0 4px 12px rgba(15, 15, 16, 0.04); }
@media (min-width: 768px) {
  .panel, .premium-card, .auth-card, .viewer-card, .hero-card { padding: 28px; }
}

.panel-title {
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
  margin-bottom: 16px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
  flex-wrap: wrap;
}
.panel-title h2, .panel-title h3 {
  margin: 0;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 600;
  color: var(--ink-2);
  font-family: var(--mono);
}
.panel-title p { margin: 0; color: var(--muted); font-size: 13px; }

/* -------- Eyebrow (subject signature: CLI-style) -------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.02em;
  /*text-transform: lowercase;*/
  color: var(--muted);
  font-weight: 400;
  padding: 0;
  background: transparent;
  border: 0;
}
.eyebrow::before { content: "· "; color: var(--line-2); }
.eyebrow.green { color: var(--ok); }
.eyebrow.dark { color: var(--ink-2); }

/* -------- Tags / Pills (rectangulares, sin color eléctrico) -------- */
.pill, .chip, .tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 500;
  color: var(--ink-2);
  font-family: var(--mono);
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.pill.good, .tag.green, .chip.good { background: var(--ok-bg); border-color: var(--ok-line); color: var(--primary); }
.tag.amber, .tag.orange { background: var(--warn-bg); border-color: var(--warn-line); color: var(--warn); }
.tag.red { background: var(--danger-bg); border-color: var(--danger-line); color: var(--danger); }
.tag.blue { background: var(--info-bg); border-color: var(--info-line); color: var(--info); }
.tag.live, .tag.dark { background: var(--ink); color: var(--surface); border-color: var(--ink); }

/* -------- Lead / prose -------- */
.lead { font-size: 17px; color: var(--ink-2); max-width: 720px; }
.lead-sm { font-size: 15px; color: var(--muted); }

/* -------- Grids -------- */
.grid { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 640px) {
  .grid.two, .grid.three, .grid.four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 900px) {
  .grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .grid.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

.split { display: grid; grid-template-columns: 1fr; gap: 20px; }
.split.reverse { grid-template-columns: 1fr; }
@media (min-width: 900px) {
  .split { grid-template-columns: 300px 1fr; }
  .split.reverse { grid-template-columns: 1fr 320px; }
}

/* -------- Hero / Landing -------- */
.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  align-items: stretch;
}
@media (min-width: 1000px) {
  .hero-grid { grid-template-columns: minmax(0, 1.2fr) minmax(360px, 0.8fr); gap: 40px; }
}
.hero h1 {
  font-size: clamp(32px, 5vw, 52px);
  line-height: 1.05;
  letter-spacing: -0.025em;
  margin: 16px 0 12px;
  font-weight: 600;
  color: var(--ink);
}
.hero-actions, .form-actions, .row-actions, .trust-row, .active-filter-row {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.trust-row { margin-top: 16px; }

.section-head { margin-bottom: 20px; }
.section-head h2 {
  font-size: clamp(22px, 3vw, 32px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  max-width: 820px;
  margin: 8px 0 8px;
}
.section-head p { max-width: 720px; color: var(--muted); font-size: 15px; margin: 0; }
.section-head.inverted h2, .section-head.inverted p { color: var(--ink); }
.section-head.inverted p { color: var(--ink-2); }
.dark-section {
  background: var(--surface-dark);
  color: var(--surface);
  margin: 24px 0;
  padding: 48px 0;
}
.dark-section .section-head h2 { color: #FFFFFF; }
.dark-section .section-head p { color: rgba(255, 255, 255, 0.7); }

/* Preview mock del hero — antes tenía gradiente púrpura, ahora es una
   maqueta técnica en escala de grises con líneas sutiles */
.product-preview {
  background: var(--surface-dark);
  border-radius: var(--radius-lg);
  color: var(--surface);
  overflow: hidden;
  min-height: 360px;
  display: flex;
  flex-direction: column;
}
.preview-top, .preview-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-family: var(--mono);
  font-size: 11px;
  color: rgba(255, 255, 255, 0.7);
}
.preview-foot { margin-top: auto; border-top: 1px solid rgba(255, 255, 255, 0.08); border-bottom: 0; }
.traffic {
  width: 42px; height: 8px;
  background:
    linear-gradient(90deg, #4B5563 0 33%, transparent 33% 34%, #4B5563 34% 66%, transparent 66% 67%, #4B5563 67%);
  border-radius: 999px;
}
.preview-body { padding: 0 16px 16px 16px; display: grid; gap: 10px; }
.wire { height: 10px; border-radius: 2px; background: rgba(255, 255, 255, 0.08); }
.wire.wide { width: 92%; }
.wire.mid { width: 68%; }
.wire.short { width: 45%; }
.message-card {
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  padding: 12px 14px;
  border-radius: 20px;
  max-width: 84%;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.85);
}
.message-card.right {
  justify-self: end;
  background: rgba(156, 163, 175, 0.15);
  border: 1px solid rgba(156, 163, 175, 0.2);
  color: #d1d5db;
}
.chat-expiry {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  max-width: 100%;
  padding: 6px 10px;
  border: 1px solid rgba(234, 179, 8, 0.2);
  border-radius: 999px;
  background: rgba(234, 179, 8, 0.1);
  color: #eab308;
  font-size: 11px;
  line-height: 1.35;
}
.product-preview .chat-expiry {
  justify-self: center;
  margin: 16px auto;
}

@media (max-width: 640px) {
  .preview-top, .preview-foot { flex-direction: column; align-items: flex-start; }
  .message-card { max-width: 100%; }
}

/* -------- Features / Arch / Flow -------- */
.feature { min-height: auto; padding: 20px; }
.feature h3 { margin: 0 0 6px; font-size: 16px; font-weight: 600; }
.feature p { margin: 0; color: var(--ink-2); font-size: 14px; }
.feature .icon {
  width: 32px; height: 32px;
  border-radius: var(--radius);
  background: var(--surface-2);
  color: var(--ink);
  display: grid; place-items: center;
  font-weight: 600;
  font-family: var(--mono);
  font-size: 13px;
  margin-bottom: 14px;
}

.flow-board { overflow: hidden; }
.flow-steps { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 640px) { .flow-steps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .flow-steps { grid-template-columns: repeat(4, 1fr); } }
.flow-step {
  padding: 16px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--line);
}
.flow-step span {
  display: inline-block;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 8px;
}
.flow-step strong { display: block; font-size: 15px; font-weight: 600; }
.flow-step p { margin: 6px 0 0; color: var(--muted); font-size: 13px; }

.arch-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 640px) { .arch-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 900px) { .arch-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.arch-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  padding: 18px;
  min-height: 180px;
}
.arch-card h3 { margin: 0 0 8px; font-size: 15px; color: var(--ink); }
.arch-card p { margin: 0; color: var(--ink-2); font-size: 13px; }

.final-cta .panel { display: grid; gap: 16px; }
@media (min-width: 768px) {
  .final-cta .panel { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
}
.final-cta h2 { font-size: 22px; margin: 4px 0; }

/* -------- Metrics -------- */
.metric {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 16px;
}
.metric.glass { background: var(--surface); }
.metric strong {
  display: block;
  font-size: 24px;
  color: var(--ink);
  letter-spacing: -0.02em;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.metric span { color: var(--muted); font-size: 12px; }
.progress { height: 4px; background: var(--surface-3); border-radius: 999px; overflow: hidden; margin-top: 8px; }
.progress span { display: block; height: 100%; background: var(--primary); border-radius: 999px; }

/* -------- Formularios -------- */
label { display: block; font-weight: 500; font-size: 13px; margin: 8px 0 6px; color: var(--ink-2); }
.field label { display: block; font-weight: 500; font-size: 13px; margin: 8px 0 6px; color: var(--ink-2); }
input, select, textarea, .field input, .field select, .field textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: var(--radius);
  padding: 10px 12px;
  min-height: 44px;
  color: var(--ink);
  font-size: 15px;
  outline: none;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
input:focus, select:focus, textarea:focus,
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 3px var(--focus);
}
textarea { min-height: 96px; resize: vertical; padding: 10px 12px; }
input[type="file"] { padding: 6px; }

.form-row { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 640px) { .form-row { grid-template-columns: 1fr 1fr; } }

.stack-form { display: grid; gap: 8px; }
.operator-hint { font-size: 12px; color: var(--muted); margin-top: 16px; }
.operator-hint code { background: var(--surface-2); border: 1px solid var(--line); padding: 1px 6px; border-radius: 3px; font-family: var(--mono); font-size: 11px; }

/* Search del listado de trabajos */
.search-form {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  align-items: end;
}
@media (min-width: 768px) { .search-form { grid-template-columns: 1fr 220px 180px 140px; } }

/* -------- Auth -------- */
.auth-wrap { max-width: 960px; margin: 32px auto; }
.auth-card { display: grid; grid-template-columns: 1fr; overflow: hidden; padding: 0; }
@media (min-width: 900px) { .auth-card { grid-template-columns: 380px 1fr; } }
.auth-side {
  padding: 28px;
  background: var(--ink);
  color: var(--surface);
  display: flex; flex-direction: column; gap: 12px;
}
.auth-side h1 { font-size: clamp(24px, 3vw, 34px); line-height: 1.1; margin: 8px 0 4px; color: var(--surface); }
.auth-side p { color: var(--surface-2); font-size: 14px; }
.auth-main { padding: 28px; }
@media (min-width: 768px) {
  .auth-side { padding: 36px; }
  .auth-main { padding: 36px; }
}
.access-map { display: grid; gap: 8px; margin-top: 12px; }
.access-map div {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.03);
  border-radius: var(--radius);
  padding: 12px;
  font-size: 13px;
}
.access-map strong { display: block; color: var(--ink); font-weight: 600; }
.access-map span { display: block; color: var(--ink-2); margin-top: 2px; font-size: 12px; }

.tabs {
  display: flex;
  background: var(--surface-2);
  border: 1px solid var(--line);
  padding: 3px;
  border-radius: var(--radius);
  gap: 3px;
  margin-bottom: 16px;
}
.tab {
  flex: 1;
  padding: 8px 10px;
  border-radius: 3px;
  font-weight: 500;
  font-size: 13px;
  color: var(--muted);
}
.tab.active { background: var(--surface); color: var(--ink); }

.toggle-row { display: flex; gap: 8px; margin-bottom: 14px; }
.toggle-row .btn { flex: 1; }
@media (max-width: 480px) {
  .toggle-row { flex-direction: column; }
  .toggle-row .btn { width: 100%; }
}
.access-form h2 { font-size: 20px; margin: 0 0 4px; font-weight: 600; }

/* -------- Market / Jobs -------- */
.market-hero { padding: 24px 0 8px; }
.market-hero .container {
  display: grid; grid-template-columns: 1fr; gap: 16px; align-items: end;
}
@media (min-width: 900px) { .market-hero .container { grid-template-columns: 1fr auto; } }
.market-copy h1 { font-size: clamp(26px, 4vw, 40px); max-width: 800px; }
.market-stats { display: flex; gap: 8px; flex-wrap: wrap; }
.market-stats div {
  min-width: 120px; flex: 1 1 auto;
  background: var(--ink); color: var(--surface);
  border-radius: var(--radius-lg); padding: 14px;
}
.market-stats strong { display: block; font-size: 22px; color: var(--surface); font-weight: 600; font-variant-numeric: tabular-nums; }
.market-stats span { font-size: 11px; color: var(--surface-2); font-family: var(--mono); }

.active-filter-row { margin-top: 12px; }
.chip a { font-weight: 500; color: var(--danger); padding-left: 4px; }

.jobs-layout { display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 900px) { .jobs-layout { grid-template-columns: 280px 1fr; gap: 28px; } }
.sidebar { position: static; align-self: start; }
@media (min-width: 900px) { .sidebar { position: sticky; top: 84px; } }
.sticky-card { position: static; }
@media (min-width: 900px) { .sticky-card { position: sticky; top: 84px; } }

.filters-card h3 {
  font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--muted); margin: 16px 0 8px; font-family: var(--mono); font-weight: 500;
}
.filter-list { display: grid; gap: 2px; }
.filter-link {
  display: flex; justify-content: space-between; align-items: center;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  color: var(--ink-2); font-size: 14px;
}
.filter-link:hover { background: var(--surface-2); color: var(--ink); }

.results-toolbar {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 12px; margin-bottom: 16px; flex-wrap: wrap;
}
.results-toolbar h2 { font-size: 22px; margin: 0; }

.job-list { display: grid; gap: 12px; }
.job-card {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 14px;
  align-items: flex-start;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 16px;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}
.job-card:hover {
  transform: translateY(-2px);
  border-color: rgba(124, 58, 237, 0.2);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
}
.public-catalog-grid {
  display: grid;
  grid-template-columns: 250px 1fr;
  gap: 24px;
  align-items: start;
  margin-top: 32px;
}
.filter-sidebar {
  background: var(--surface);
  padding: 20px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
}
.filter-sidebar h3 { margin: 0 0 16px; font-size: 16px; }
.filter-sidebar label { display: grid; gap: 6px; margin-top: 14px; color: var(--ink-2); font-size: 13px; }
.public-job-card { grid-template-columns: 48px 1fr auto; }
.public-job-card .job-main { min-width: 0; }
@media (max-width: 767px) {
  .public-catalog-grid { grid-template-columns: 1fr; }
}
@media (min-width: 768px) {
  .job-card { grid-template-columns: 64px 1fr auto; padding: 18px; }
  .job-list.compact .job-card { grid-template-columns: 48px 1fr auto; }
}
.logo-tile {
  width: 56px; height: 56px;
  border-radius: var(--radius);
  background: var(--surface-2);
  border: 1px solid var(--line);
  color: var(--ink);
  display: grid; place-items: center;
  font-weight: 600;
  font-family: var(--mono);
  font-size: 14px;
}
.logo-tile.rich { background: var(--surface-2); }
.logo-tile.jumbo { width: 96px; height: 96px; font-size: 22px; }
.job-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.job-card h3 { font-size: 16px; letter-spacing: -0.01em; margin: 0 0 2px; font-weight: 600; }
.job-summary { color: var(--ink-2); margin: 8px 0 0; font-size: 14px; }
.job-meta { display: flex; gap: 10px; flex-wrap: wrap; font-size: 12px; color: var(--muted); font-family: var(--mono); margin-top: 8px; }
.job-meta.clean span:not(:last-child)::after { content: " / "; margin: 0 6px; color: var(--line-2); }
.job-actions { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.job-actions.vertical { flex-direction: column; align-items: stretch; }
@media (max-width: 640px) {
  .job-actions.vertical { flex-direction: row; }
  .job-actions.vertical .btn { flex: 1 1 auto; }
}

.match-ring {
  width: 56px; height: 56px;
  border-radius: 50%;
  border: 3px solid var(--surface-3);
  display: grid; place-items: center; text-align: center;
  line-height: 1;
  background: var(--surface);
}
.match-ring strong { font-size: 14px; color: var(--ink); font-weight: 600; font-variant-numeric: tabular-nums; }
.match-ring span { font-size: 9px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); font-family: var(--mono); }
.match-ring.neutral { background: var(--surface-2); border-color: var(--line); border-radius: var(--radius); width: auto; height: auto; padding: 6px 10px; }
.match-ring.big { width: 76px; height: 76px; }
.match-ring.big strong { font-size: 18px; }

.job-detail-layout { display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 900px) { .job-detail-layout { grid-template-columns: 1fr 320px; gap: 28px; } }
.detail-card section { margin-top: 24px; }
.detail-card h2 { font-size: 18px; }
.detail-hero { display: flex; justify-content: space-between; gap: 16px; margin-top: 12px; flex-wrap: wrap; }
.detail-hero h1 { font-size: clamp(28px, 4vw, 40px); }

.match-panel {
  display: flex; gap: 14px; align-items: center;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 14px; margin: 18px 0;
  flex-wrap: wrap;
}
.match-panel h3 { margin: 0; font-size: 15px; }
.match-panel p { margin: 2px 0 0; color: var(--muted); font-size: 13px; }
.check-list { display: flex; gap: 6px; flex-wrap: wrap; }
.check-list span {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 4px 8px; font-weight: 500; font-size: 12px;
}
.check-list.soft span { background: var(--ok-bg); border-color: var(--ok-line); color: var(--ok); }

.timeline { display: grid; grid-template-columns: 1fr; gap: 8px; }
@media (min-width: 640px) { .timeline { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .timeline { grid-template-columns: repeat(4, 1fr); } }
.timeline div {
  background: var(--surface-dark); color: var(--surface);
  border-radius: var(--radius); padding: 12px;
  font-family: var(--mono); font-size: 12px;
}
.timeline strong { display: block; color: rgba(255, 255, 255, 0.6); font-size: 10px; text-transform: uppercase; letter-spacing: 0.08em; }
.timeline span { font-size: 12px; }

.fact-list { display: grid; gap: 10px; }
.fact-list div { border-bottom: 1px solid var(--line); padding-bottom: 10px; }
.fact-list span { display: block; color: var(--muted); font-size: 11px; text-transform: uppercase; font-weight: 500; letter-spacing: 0.08em; font-family: var(--mono); }
.fact-list strong { display: block; color: var(--ink); margin-top: 3px; font-size: 14px; font-weight: 500; }

/* -------- Dashboard -------- */
.dash-head { display: grid; grid-template-columns: 1fr; gap: 12px; align-items: flex-start; margin-bottom: 20px; }
@media (min-width: 768px) { .dash-head { display: flex; justify-content: space-between; gap: 16px; } }
.dash-head h1 { font-size: clamp(24px, 4vw, 34px); font-weight: 600; }
.dash-head .eyebrow { margin-bottom: 4px; }

.table-wrap { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th {
  text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--muted); padding: 10px 8px; border-bottom: 1px solid var(--line);
  white-space: nowrap; font-family: var(--mono); font-weight: 500;
}
.table td { padding: 12px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table .actions { display: flex; gap: 6px; flex-wrap: wrap; }
@media (max-width: 640px) { .table { min-width: 640px; } }

.panel:has(> table.table) { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.admin-table-wrap { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }

.empty {
  border: 1px dashed var(--line-2);
  border-radius: var(--radius);
  background: var(--surface-2);
  padding: 20px; text-align: center; color: var(--muted); font-size: 13px;
}
.empty.large { padding: 36px; }

.vault-card { display: grid; grid-template-columns: 1fr; gap: 12px; align-items: center; }
@media (min-width: 768px) { .vault-card { grid-template-columns: 1fr auto; } }

.drop {
  border: 1.5px dashed var(--line-2);
  border-radius: var(--radius-lg);
  background: var(--surface-2);
  padding: 20px; text-align: center;
}
.drop h3 { font-size: 15px; margin: 0 0 4px; }
.drop input { max-width: 520px; margin: 10px auto 0; }

.share-list, .request-list, .room-list { display: grid; gap: 10px; }
.share-row, .request-row, .room-row {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  padding: 14px;
}
.share-row h3, .room-row h3 { margin: 0 0 6px; font-size: 15px; }

.security-grid { display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 768px) { .security-grid { grid-template-columns: repeat(3, 1fr); } }
.security-cell {
  background: var(--surface-2); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 14px; font-size: 13px;
}
.security-cell strong { display: block; font-size: 15px; color: var(--ink); font-weight: 600; }
.candidate-profile-aside { display: grid; gap: 0; align-content: start; }
.insurance-upsell-card {
  margin-top: 24px;
  padding: 20px;
  background: var(--surface);
  border: 1px solid var(--line-2);
  border-radius: var(--radius-lg);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}
.insurance-icon { font-size: 28px; margin-bottom: 12px; }
.insurance-upsell-card h4 { margin: 0 0 6px; font-size: 16px; }
.insurance-upsell-card p { margin: 0; color: var(--muted); font-size: 13px; }
.btn.full-width { display: flex; width: 100%; margin-top: 16px; }
.badge-verified {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 6px;
  padding: 4px 8px;
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: 999px;
  background: rgba(16, 185, 129, 0.1);
  color: #059669;
  font-size: 11px;
  font-weight: 600;
}

.application-section { display: grid; gap: 10px; }
.application-section > h3 { margin: 0; font-size: 14px; font-weight: 600; }
.history-section { margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line); }

/* -------- Chat -------- */
.chat-layout { display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 900px) { .chat-layout { grid-template-columns: 320px 1fr; gap: 24px; } }
@media (max-width: 899px) { .chat-layout .chat-box { order: -1; } }
.chat-box {
  height: 60vh; min-height: 400px;
  display: flex; flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.chat-head {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  display: flex; justify-content: space-between; gap: 10px;
  background: var(--surface-2);
  align-items: center;
}
.chat-head-actions { display: flex; align-items: center; justify-content: flex-end; gap: 8px; flex-wrap: wrap; }
.messages { flex: 1; overflow: auto; padding: 16px; display: grid; gap: 10px; background: var(--surface); }
.bubble {
  max-width: 72%;
  padding: 10px 12px;
  border-radius: var(--radius);
  background: var(--surface-2);
  border: 1px solid var(--line);
  font-size: 14px;
}
.bubble.me { justify-self: end; background: var(--surface-dark); color: var(--surface); border-color: var(--line-2); }
.bubble .meta { font-size: 10px; color: var(--muted); margin-top: 6px; font-family: var(--mono); }
.bubble.me .meta { color: rgba(255, 255, 255, 0.6); }
.bubble.system { max-width: 100%; justify-self: center; background: var(--warn-bg); border-color: var(--warn-line); color: var(--warn); text-align: center; font-weight: 500; }
@media (max-width: 640px) { .bubble { max-width: 92%; } .chat-box { height: 66vh; } }

.composer {
  padding: 12px;
  border-top: 1px solid var(--line);
  display: grid; grid-template-columns: 1fr auto; gap: 8px;
  background: var(--surface-2);
}
.composer input { min-height: 40px; }
@media (max-width: 640px) {
  .composer { grid-template-columns: 1fr; }
  .composer .btn { width: 100%; }
}

.key-warning {
  border: 1px solid var(--warn-line);
  background: var(--warn-bg);
  color: var(--warn);
  border-radius: var(--radius);
  padding: 12px; margin-bottom: 10px; font-size: 13px;
}

.side-stack { display: grid; gap: 12px; }

.status-dot {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 8px;
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: 999px;
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  font-family: var(--mono);
  font-size: 12px;
}
.status-dot::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: #ef4444;
}
.status-dot.off::before { background: var(--muted); }

/* -------- Share viewer -------- */
.share-viewer { max-width: 1000px; margin: 32px auto; }
.viewer-card { padding: 20px; }
@media (min-width: 768px) { .viewer-card { padding: 28px; } }
.viewer-grid { display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 900px) { .viewer-grid { grid-template-columns: 1fr 340px; } }
.secure-view {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface-2);
  min-height: 320px;
  display: grid; place-items: center;
  overflow: hidden; position: relative;
}
.secure-view::before {
  content: "· visor temporal";
  position: absolute; top: 12px; right: 12px;
  background: var(--ink); color: var(--surface);
  border-radius: var(--radius);
  padding: 4px 8px;
  font-size: 10px;
  font-family: var(--mono);
  letter-spacing: 0.04em;
  z-index: 2;
}
.secure-view img, .secure-view iframe {
  max-width: 100%; width: 100%; height: 100%;
  min-height: 460px;
  border: 0; object-fit: contain;
}
.doc-placeholder { text-align: center; padding: 24px; font-size: 14px; color: var(--muted); }
.doc-placeholder h2 { margin: 0 0 6px; color: var(--ink-2); font-size: 16px; }

@media (max-width: 640px) {
  .secure-view img { min-height: 240px; height: auto; }
  .secure-view iframe { min-height: 56vh; height: 56vh; }
}

/* -------- Modal -------- */
#modal-root { position: fixed; inset: 0; z-index: 2000; }
#modal-root:empty { display: none; pointer-events: none; }
.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(15, 15, 16, 0.6);
  display: flex; align-items: center; justify-content: center;
  padding: 16px;
}
.modal-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  max-width: 640px; width: 100%;
  max-height: 86vh; overflow: auto;
  padding: 24px;
  box-shadow: var(--shadow-modal);
}
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.modal-content {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 32px;
  width: 90%;
  max-width: 480px;
  position: relative;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}
.modal-close {
  position: absolute;
  top: 12px;
  right: 16px;
  background: transparent;
  color: var(--muted);
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}
.modal-close:hover { color: var(--ink); }
.modal-content h3 { margin: 0 28px 6px 0; }
.modal-subtitle { color: var(--muted); font-size: 14px; }
.insurance-plans {
  display: grid;
  gap: 16px;
  margin: 24px 0;
}
.plan-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  position: relative;
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.plan-card:hover { border-color: var(--line-2); box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05); }
.plan-card.recommended {
  border-color: var(--accent);
  box-shadow: 0 4px 12px rgba(31, 41, 55, 0.12);
}
.plan-card h5 { margin: 0 0 4px; font-size: 15px; }
.plan-card p { margin: 0 0 12px; color: var(--muted); font-size: 13px; }
.plan-badge {
  display: inline-flex;
  margin-bottom: 8px;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--info-bg);
  color: var(--info);
  font-size: 11px;
  font-weight: 600;
}
.plan-price { color: var(--ink); font-size: 24px; font-weight: 700; }
.plan-price span { color: var(--muted); font-size: 12px; font-weight: 400; }
@media (max-width: 640px) {
  .modal-card { padding: 18px; }
  .modal-backdrop { padding: 12px; }
}

/* -------- Protected surface (anti-captura) -------- */
.protected-surface { position: relative; }
.protected-surface.privacy-hidden { filter: blur(18px) grayscale(0.4); transition: filter 0.15s ease; }
.protected-surface.privacy-hidden::after {
  content: "Contenido oculto por seguridad";
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(15, 15, 16, 0.6);
  color: var(--surface); font-weight: 500;
  text-align: center; padding: 20px; z-index: 5;
  font-size: 14px;
}
.secure-view.protected-surface, #app-secure-view { user-select: none; -webkit-user-select: none; }
.secure-view.protected-surface img, #app-secure-view img { pointer-events: none; }
.secure-view.protected-surface iframe, #app-secure-view iframe {
  pointer-events: auto; touch-action: auto; display: block;
  height: min(68vh, 720px); min-height: 460px;
}
.chat-box.protected-surface .messages { user-select: none; -webkit-user-select: none; }
.watermark {
  position: absolute; inset: 0; pointer-events: none;
  background-image: repeating-linear-gradient(30deg, rgba(15, 15, 16, 0.02) 0 1px, transparent 1px 90px);
}
.blurred { filter: blur(4px); }

/* -------- Quick nav (dashboard) -------- */
.quick-nav {
  position: sticky; top: 72px; z-index: 30;
  display: flex; flex-wrap: wrap; gap: 4px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 6px;
  margin: 16px 0;
}
.quick-nav a {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 10px;
  border-radius: 3px;
  color: var(--ink-2);
  font-weight: 500; font-size: 13px;
  border: 1px solid transparent;
  white-space: nowrap;
}
.quick-nav a:hover { background: var(--surface-2); color: var(--ink); }
.quick-nav .qn-icon { font-size: 13px; line-height: 1; opacity: 0.7; }
@media (max-width: 768px) {
  .quick-nav {
    top: 60px;
    overflow-x: auto; flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch; scrollbar-width: none;
  }
  .quick-nav::-webkit-scrollbar { display: none; }
  .quick-nav a { flex: 0 0 auto; }
}
.panel.section, .section.grid { scroll-margin-top: 130px; }

@keyframes anchorFlash {
  0% { box-shadow: 0 0 0 2px var(--focus); }
  100% { box-shadow: 0 0 0 2px transparent; }
}
.anchor-flash { animation: anchorFlash 1.5s ease-out; }

/* -------- Toast -------- */
.toast {
  position: fixed; right: 16px; bottom: 16px; z-index: 1000;
  display: grid; gap: 8px; max-width: calc(100% - 32px);
}
.toast-item {
  background: var(--ink); color: var(--surface);
  border-radius: var(--radius);
  padding: 12px 14px;
  box-shadow: var(--shadow-toast);
  max-width: 400px;
  font-size: 14px;
  border: 1px solid var(--ink);
}
.toast-item.good { background: var(--ok); border-color: var(--ok); }
.toast-item.bad { background: var(--danger); border-color: var(--danger); }
.toast-item.warn { background: var(--warn); border-color: var(--warn); }
@media (max-width: 640px) {
  .toast { left: 16px; right: 16px; max-width: none; }
  .toast-item { max-width: none; }
}

/* -------- Footer -------- */
.footer {
  margin-top: 40px;
  padding: 28px 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
  background: var(--surface);
  font-size: 13px;
}
.footer .container {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.footer-links { display: flex; gap: 12px; flex-wrap: wrap; }
.footer strong { color: var(--ink-2); font-weight: 600; }

/* -------- Back button -------- */
.back-nav-bar { padding-top: 12px; }
.back-btn {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-2);
  font-weight: 500; font-size: 13px;
  padding: 7px 12px 7px 10px;
  border-radius: var(--radius);
  transition: border-color 0.15s ease, color 0.15s ease;
}
.back-btn:hover { border-color: var(--line-2); color: var(--ink); }
.back-btn span[aria-hidden] { font-size: 13px; line-height: 1; }

/* -------- Insecure context banner -------- */
.insecure-context-banner {
  position: sticky; top: 0; z-index: 2000;
  background: var(--danger); color: #fff;
  padding: 10px 16px; text-align: center;
  font-size: 13px; font-weight: 500; line-height: 1.4;
}
.insecure-context-banner strong { font-weight: 600; }

/* -------- Demo pública -------- */
.demo-banner-card {
  display: grid; gap: 12px; align-items: start;
  background: var(--surface-2);
  border: 1px solid var(--line);
}
@media (min-width: 768px) {
  .demo-banner-card { display: flex; justify-content: space-between; align-items: center; }
}
.demo-banner-card h1 { font-size: clamp(20px, 3vw, 26px); margin: 4px 0 4px; }
.demo-limits { display: flex; gap: 6px; flex-wrap: wrap; max-width: 260px; }
.demo-card .job-actions.vertical .help {
  color: var(--muted); font-size: 11px; text-align: center; margin-top: 4px;
}
.demo-widget { display: block; }
.demo-crypto-box {
  display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin: 12px 0;
}
@media (max-width: 640px) {
  .demo-crypto-box { flex-direction: column; align-items: stretch; }
  .demo-crypto-box input[type="file"] { width: 100%; }
}
.demo-crypto-result { margin-top: 8px; }
.demo-confirm {
  display: flex; align-items: center; gap: 12px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
}
.demo-check {
  display: grid; place-items: center;
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--ok); color: #fff; font-weight: 600;
  flex: 0 0 auto; font-size: 14px;
}
.demo-chat-box {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 16px; margin: 12px 0;
}
.demo-chat-box .bubble { max-width: 80%; }
.demo-chat-box .chat-expiry { margin-bottom: 12px; }

/* -------- Utilidades finales -------- */
main { display: block; }

/* 1. Asegurar que los padres permitan que los elementos sobresalgan */
.product-preview.enterprise-preview {
  overflow: visible !important; 
  position: relative;
}


/* 2. El contenedor que desborda a la izquierda y derecha */
.preview-vault-overlay {
  position: relative; 
  margin: 0 -28px -40px -28px; 
  
  width: calc(100% + 56px);
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 10;
}


/* 3. Estilo de la Imagen de la Bóveda */
.vault-hero-image {
  display: block;
  width: 100%; 
  max-width: none;
  
  /* Sombra suave con tintes*/
  filter: drop-shadow(0 15px 35px rgba(124, 58, 237, 0.18)) 
          drop-shadow(0 5px 15px rgba(14, 165, 233, 0.12));
          
  /* Opcional: Pequeña animación de levitación para que se sienta dinámico e interactivo */
  animation: levitate 4s ease-in-out infinite;
}


/* Acercar la etiqueta a la imagen */
.local-badge {
  position: absolute;
  top: 5px;
  background: rgba(13, 148, 136, 0.1); /* Verde suave */
  border: 1px solid rgba(13, 148, 136, 0.3);
  color: #0d9488;
  font-size: 11px;
  font-weight: 600;
  padding: 4px 14px;
  border-radius: 999px;
  z-index: 20;
  backdrop-filter: blur(4px);
}
/* Animación de levitación flotante */
@keyframes levitate {
  0%, 100% {
    transform: translateY(0) scale(1);
  }
  50% {
    transform: translateY(-6px) scale(1.01);
  }
}

/* 5. Ajustes para móvil para que no se salga de la pantalla en pantallas ultra pequeñas */
@media (max-width: 480px) {
  .preview-vault-overlay {
    margin: 14px -16px;
    width: calc(100% + 32px);
  }
}

.preview-chat-expiry {
  width: 100%;
  text-align: center;
  padding: 16px 12px 12px 12px;
  font-size: 12px;
  color: #D4AF37;
  background: linear-gradient(to bottom, transparent 0%, rgba(200, 150, 40, 0.15) 100%);
  border-bottom-left-radius: 12px; 
  border-bottom-right-radius: 12px;
  margin-top: auto; 
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}
