/* Workbook · landing pública (Candidate 23)
   Hoja propia y acotada a .wbh: no depende de los estilos del portal ni del
   agendador, y no los modifica. Base clara, color funcional y movimiento
   breve solo si el sistema lo permite. */

.wbh {
  --wbh-ink: #0b0f1a;
  --wbh-text: #1f2937;
  --wbh-muted: #4b5565;
  --wbh-faint: #6b7280;
  --wbh-line: #e3e7ee;
  --wbh-line-strong: #cdd5e1;
  --wbh-bg: #ffffff;
  --wbh-soft: #f5f7fb;
  --wbh-brand: #2563ff;
  --wbh-brand-strong: #1d4ed8;
  --wbh-brand-deep: #1e40af;
  --wbh-brand-soft: #eef3ff;
  --wbh-violet: #7c3aed;
  --wbh-cyan: #00c6ff;
  --wbh-gradient: linear-gradient(90deg, #00c6ff 0%, #2563ff 55%, #7c3aed 100%);
  --wbh-ok: #067647;
  --wbh-ok-bg: #ecfdf3;
  --wbh-info: #175cd3;
  --wbh-info-bg: #eff8ff;
  --wbh-addon: #5b21b6;
  --wbh-addon-bg: #f4f0ff;
  --wbh-warn: #93370d;
  --wbh-warn-bg: #fffaeb;
  --wbh-r-sm: 8px;
  --wbh-r: 12px;
  --wbh-r-lg: 16px;
  --wbh-shadow-1: 0 1px 2px rgba(16, 24, 40, .06);
  --wbh-shadow-2: 0 12px 28px rgba(16, 24, 40, .08);
  --wbh-shadow-3: 0 24px 60px rgba(11, 15, 26, .16);
  --wbh-font: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --wbh-header-h: 64px;

  font-family: var(--wbh-font);
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: normal;
  line-height: 1.6;
  color: var(--wbh-text);
  background: var(--wbh-bg);
  position: relative;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body.wb-landing-active {
  margin: 0;
  background: #ffffff;
}

.wbh *,
.wbh *::before,
.wbh *::after { box-sizing: border-box; }

.wbh :where(h1, h2, h3, h4, p, ul, ol, dl, dd, figure, fieldset, legend) { margin: 0; }
.wbh :where(ul, ol) { padding: 0; list-style: none; }
.wbh :where(fieldset) { padding: 0; border: 0; min-width: 0; }
.wbh :where(h1, h2, h3, h4) {
  color: var(--wbh-ink);
  font-family: var(--wbh-font);
  line-height: 1.2;
  letter-spacing: -.015em;
  text-wrap: balance;
}
.wbh img { max-width: 100%; height: auto; display: block; }
.wbh a { color: var(--wbh-brand-strong); text-underline-offset: 3px; }
.wbh a:hover { color: var(--wbh-brand-deep); }
.wbh [hidden] { display: none !important; }
.wbh [id] { scroll-margin-top: calc(var(--wbh-header-h) + 16px); }
.wbh .wbh-num { font-variant-numeric: tabular-nums; }

.wbh :focus-visible {
  outline: 3px solid var(--wbh-brand);
  outline-offset: 2px;
  border-radius: 6px;
}

.wbh-sr {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

.wbh-skip {
  position: absolute;
  left: 12px; top: -60px;
  z-index: 100;
  padding: 10px 14px;
  border-radius: var(--wbh-r-sm);
  background: var(--wbh-ink);
  color: #fff !important;
  font-weight: 600;
  text-decoration: none;
}
.wbh-skip:focus { top: 12px; }

.wbh-wrap {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 32px);
}

/* ---------- Botones ---------- */
.wbh-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 10px;
  font: 600 .9375rem/1.2 var(--wbh-font);
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease, box-shadow .15s ease;
  -webkit-tap-highlight-color: transparent;
}
.wbh a.wbh-btn { text-decoration: none; }
.wbh-btn-lg { min-height: 50px; padding: 0 22px; font-size: 1rem; }
.wbh-btn-block { width: 100%; }
.wbh .wbh-btn-primary { background: var(--wbh-brand-strong); color: #fff; box-shadow: var(--wbh-shadow-1); }
.wbh .wbh-btn-primary:hover { background: var(--wbh-brand-deep); color: #fff; }
.wbh .wbh-btn-ghost { background: #fff; color: var(--wbh-ink); border-color: var(--wbh-line-strong); }
.wbh .wbh-btn-ghost:hover { border-color: var(--wbh-brand-strong); color: var(--wbh-brand-strong); }
.wbh .wbh-btn-light { background: #fff; color: var(--wbh-ink); }
.wbh .wbh-btn-light:hover { background: var(--wbh-brand-soft); color: var(--wbh-ink); }
.wbh .wbh-btn-outline-light { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .55); }
.wbh .wbh-btn-outline-light:hover { border-color: #fff; color: #fff; background: rgba(255, 255, 255, .08); }

.wbh-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Encabezado ---------- */
.wbh-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: #fff;
  border-bottom: 1px solid var(--wbh-line);
}
.admin-bar .wbh-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .wbh-header { top: 46px; } }
@media (max-width: 600px) { .admin-bar .wbh-header { top: 0; } }

.wbh-header-in {
  position: relative;
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: var(--wbh-header-h);
}
.wbh-brand { display: inline-flex; align-items: center; flex-shrink: 0; }
.wbh-brand img { height: 40px; width: auto; }

.wbh-nav { margin-left: auto; }
.wbh-nav ul { display: flex; gap: 4px; }
.wbh .wbh-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 12px;
  border-radius: var(--wbh-r-sm);
  color: var(--wbh-text);
  font-size: .9375rem;
  font-weight: 500;
  text-decoration: none;
}
.wbh .wbh-nav a:hover { background: var(--wbh-soft); color: var(--wbh-ink); }
.wbh-header-actions { display: flex; gap: 8px; }

.wbh-menu { display: none; position: static; }
.wbh-menu > summary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--wbh-line-strong);
  border-radius: 10px;
  background: #fff;
  color: var(--wbh-ink);
  font-weight: 600;
  font-size: .9375rem;
  cursor: pointer;
  list-style: none;
  user-select: none;
}
.wbh-menu > summary::-webkit-details-marker { display: none; }
.wbh-menu[open] > summary { background: var(--wbh-soft); border-color: var(--wbh-ink); }
.wbh-menu-icon,
.wbh-menu-icon::before,
.wbh-menu-icon::after {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--wbh-ink);
  transition: transform .2s ease, background-color .2s ease;
}
.wbh-menu-icon { position: relative; }
.wbh-menu-icon::before,
.wbh-menu-icon::after { content: ""; position: absolute; left: 0; }
.wbh-menu-icon::before { top: -6px; }
.wbh-menu-icon::after { top: 6px; }
.wbh-menu[open] .wbh-menu-icon { background: transparent; }
.wbh-menu[open] .wbh-menu-icon::before { transform: translateY(6px) rotate(45deg); }
.wbh-menu[open] .wbh-menu-icon::after { transform: translateY(-6px) rotate(-45deg); }

.wbh-menu-panel {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  padding: 8px clamp(16px, 4vw, 32px) 20px;
  background: #fff;
  border-bottom: 1px solid var(--wbh-line);
  box-shadow: var(--wbh-shadow-2);
  max-height: calc(100vh - var(--wbh-header-h));
  overflow-y: auto;
}
.wbh-menu-panel ul { display: grid; }
.wbh .wbh-menu-panel li a {
  display: flex;
  align-items: center;
  min-height: 48px;
  border-bottom: 1px solid var(--wbh-line);
  color: var(--wbh-ink);
  font-weight: 500;
  text-decoration: none;
}
.wbh-menu-actions { display: grid; gap: 10px; margin-top: 16px; }

@media (max-width: 959px) {
  .wbh-nav { display: none; }
  .wbh-menu { display: block; }
  .wbh-header-actions { margin-left: auto; }
}
@media (max-width: 599px) {
  .wbh-header-in { gap: 10px; }
  .wbh-header-actions .wbh-btn-ghost { display: none; }
  .wbh-header-actions .wbh-btn { padding: 0 14px; }
  .wbh-menu-text { display: none; }
  .wbh-menu > summary { padding: 0 13px; }
  .wbh-brand img { height: 34px; }
}

/* ---------- Secciones ---------- */
.wbh-section { padding: clamp(56px, 8vw, 96px) 0; }
.wbh-tint { background: var(--wbh-soft); }

.wbh-head { max-width: 720px; margin-bottom: clamp(28px, 4vw, 44px); }
.wbh-head h2 { font-size: clamp(1.625rem, 1.2rem + 1.6vw, 2.375rem); font-weight: 750; letter-spacing: -.022em; }
/* Candidate 26: el contenedor de la sección sigue midiendo 720px —eso no
   cambia—, pero el párrafo se limita a una medida de lectura cómoda. A 1024 y
   1440 los párrafos de introducción llegaban a 720px, del orden de 95
   caracteres por línea; 62ch deja unas 65. Solo afecta a .wbh, no al
   agendador ni a los portales. */
.wbh-head p { margin-top: 12px; color: var(--wbh-muted); font-size: 1.0625rem; max-width: 62ch; }
.wbh-head .wbh-head-note { font-size: .9375rem; color: var(--wbh-faint); }

.wbh-subhead { font-size: 1.25rem; font-weight: 700; }
.wbh-subintro { margin-top: 6px; color: var(--wbh-muted); }

/* ---------- Hero ---------- */
.wbh-hero {
  position: relative;
  padding: clamp(40px, 7vw, 88px) 0 clamp(48px, 7vw, 88px);
  background:
    radial-gradient(900px 420px at 88% 8%, rgba(37, 99, 255, .08), transparent 70%),
    radial-gradient(700px 380px at 100% 70%, rgba(124, 58, 237, .05), transparent 70%),
    #fff;
}
.wbh-hero-grid {
  display: grid;
  gap: clamp(36px, 6vw, 64px);
  align-items: center;
}
@media (min-width: 960px) {
  .wbh-hero-grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); }
}
.wbh-eyebrow {
  display: inline-block;
  margin-bottom: 18px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--wbh-brand-soft);
  color: var(--wbh-brand-deep);
  font-size: .875rem;
  font-weight: 600;
}
.wbh-hero h1 {
  font-size: clamp(2.125rem, 1.35rem + 3.1vw, 3.625rem);
  font-weight: 780;
  line-height: 1.07;
  letter-spacing: -.03em;
  max-width: 16ch;
}
.wbh-lead {
  margin-top: 20px;
  max-width: 58ch;
  color: var(--wbh-muted);
  font-size: clamp(1.0625rem, 1rem + .3vw, 1.1875rem);
}
.wbh-hero .wbh-actions { margin-top: 28px; }
.wbh-note { margin-top: 14px; color: var(--wbh-faint); font-size: .9375rem; }
.wbh-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 20px;
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--wbh-line);
}
.wbh .wbh-quick a { display: inline-flex; align-items: center; min-height: 32px; font-weight: 600; font-size: .9375rem; }

.wbh-hero-visual { display: flex; justify-content: center; }
@media (max-width: 959px) {
  .wbh-hero-visual { order: 2; }
}

/* Teléfono: marco neutro que contiene capturas o la agenda real. */
/* Candidate 26: la proporción 390/844 va en la PANTALLA, no en el marco.
   Antes estaba en .wbh-phone, que con box-sizing: border-box la aplicaba al
   borde exterior: con 10px de marco a cada lado la pantalla quedaba en
   298x668 (0.446) mientras la captura es 0.462, así que object-fit: cover
   recortaba ~11px de ancho. Ahora el marco crece con su contenido y la
   pantalla tiene exactamente la proporción de la captura: recorte cero. */
.wbh-phone {
  position: relative;
  width: clamp(236px, 68vw, 318px);
  padding: 10px;
  border-radius: 44px;
  background: var(--wbh-ink);
  box-shadow: var(--wbh-shadow-3), inset 0 0 0 1px rgba(255, 255, 255, .08);
}
.wbh-phone::before {
  content: "";
  position: absolute;
  top: 18px;
  left: 50%;
  z-index: 2;
  width: 30%;
  height: 20px;
  border-radius: 999px;
  background: var(--wbh-ink);
  transform: translateX(-50%);
}
.wbh-phone-screen {
  position: relative;
  width: 100%;
  aspect-ratio: 390 / 844;
  overflow: hidden;
  border-radius: 34px;
  background: #fff;
}
.wbh-phone-screen img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}
/* La demo interactiva se dibuja a 390px lógicos —el ancho de teléfono que el
   agendador está pensado para atender— y se reduce a escala hasta el ancho
   interior del marco. Así se ve la interfaz real sin comprimirla ni recortarla.
   El factor lo fija el JavaScript en --wbh-demo-scale; si no llega, el valor
   por omisión deja el iframe al ancho del marco, que es el comportamiento
   anterior. */
.wbh-phone-screen iframe {
  display: block;
  width: 390px;
  height: 844px;
  border: 0;
  background: #fff;
  transform: scale(var(--wbh-demo-scale, 1));
  transform-origin: top left;
}

/* ---------- Problemas: antes / con Workbook ---------- */
.wbh-contrast { display: grid; border-top: 1px solid var(--wbh-line); }
.wbh-contrast-row {
  display: grid;
  gap: 8px;
  padding: 20px 0;
  border-bottom: 1px solid var(--wbh-line);
}
.wbh-contrast-row p { display: grid; gap: 6px; }
.wbh-contrast-before { color: var(--wbh-muted); }
.wbh-contrast-after { color: var(--wbh-ink); font-weight: 600; }
.wbh-contrast-arrow { display: none; }
@media (min-width: 760px) {
  .wbh-contrast-row {
    grid-template-columns: minmax(0, .8fr) 40px minmax(0, 1.2fr);
    align-items: center;
    gap: 16px;
  }
  .wbh-contrast-arrow {
    display: block;
    justify-self: center;
    width: 12px;
    height: 12px;
    border-top: 2px solid var(--wbh-faint);
    border-right: 2px solid var(--wbh-faint);
    transform: rotate(45deg);
  }
}
.wbh-tag {
  justify-self: start;
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--wbh-brand-soft);
  color: var(--wbh-brand-deep);
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .02em;
}
.wbh-tag-muted { background: #eef0f4; color: var(--wbh-muted); }

/* ---------- Tarjetas ---------- */
.wbh-grid { display: grid; gap: 16px; }
.wbh-grid-4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); }
.wbh-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 22px;
  border: 1px solid var(--wbh-line);
  border-radius: var(--wbh-r-lg);
  background: #fff;
}
.wbh-card h3 { font-size: 1.0625rem; font-weight: 700; }
.wbh-card p { color: var(--wbh-muted); font-size: .9375rem; }
.wbh .wbh-card-foot {
  display: grid;
  gap: 2px;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--wbh-line);
  color: var(--wbh-text);
  font-size: .875rem;
}
.wbh-card-foot-k { color: var(--wbh-faint); font-size: .75rem; font-weight: 600; letter-spacing: .03em; text-transform: uppercase; }
.wbh .wbh-card-foot a { font-weight: 700; }

/* ---------- Pasos ---------- */
.wbh-steps { display: grid; gap: 16px; counter-reset: none; }
@media (min-width: 820px) {
  .wbh-steps { grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 24px; }
}
.wbh-step {
  position: relative;
  display: grid;
  gap: 8px;
  align-content: start;
  padding: 24px 22px 22px;
  border: 1px solid var(--wbh-line);
  border-radius: var(--wbh-r-lg);
  background: #fff;
  overflow: hidden;
}
.wbh-step::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: var(--wbh-gradient);
}
.wbh-step-n {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  margin-bottom: 6px;
  border-radius: 10px;
  background: var(--wbh-ink);
  color: #fff;
  font-weight: 700;
  font-size: .9375rem;
}
.wbh-step h3 { font-size: 1.125rem; font-weight: 700; }
.wbh-step p { color: var(--wbh-muted); }

/* ---------- Funciones ---------- */
.wbh-features {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
}
.wbh-feature {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 18px 18px 16px;
  border: 1px solid var(--wbh-line);
  border-radius: var(--wbh-r);
  background: #fff;
}
.wbh-feature h3 { font-size: 1rem; font-weight: 700; }
.wbh-feature p { color: var(--wbh-muted); font-size: .9375rem; }
.wbh-badge {
  align-self: flex-start;
  margin-top: auto;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 600;
}
.wbh-feature .wbh-badge { margin-top: 8px; }
.wbh-badge-all { background: var(--wbh-ok-bg); color: var(--wbh-ok); }
.wbh-badge-some { background: var(--wbh-info-bg); color: var(--wbh-info); }
.wbh-badge-addon { background: var(--wbh-addon-bg); color: var(--wbh-addon); }

/* ---------- Capturas del portal ---------- */
.wbh-screens {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(78%, 1fr);
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 12px;
  overscroll-behavior-x: contain;
}
@media (min-width: 900px) {
  .wbh-screens {
    grid-auto-flow: row;
    grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
    grid-auto-columns: auto;
    overflow: visible;
    padding-bottom: 0;
  }
}
.wbh-screen { scroll-snap-align: start; }
.wbh-screen figure { display: grid; gap: 12px; }
.wbh-screen img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  object-position: top left;
  border: 1px solid var(--wbh-line);
  border-radius: var(--wbh-r);
  background: var(--wbh-soft);
  box-shadow: var(--wbh-shadow-2);
}
.wbh-screen figcaption { display: grid; gap: 2px; font-size: .9375rem; }
.wbh-screen figcaption strong { color: var(--wbh-ink); }
.wbh-screen figcaption span { color: var(--wbh-muted); }

/* ---------- Demos ---------- */
.wbh-demos { position: relative; display: grid; gap: 24px; }
@media (min-width: 860px) {
  .wbh-demos { grid-template-columns: minmax(240px, 320px) minmax(0, 1fr); gap: 48px; align-items: start; }
}
.wbh-demo-radio {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  margin: 0;
  pointer-events: none;
}
.wbh-demo-picker { display: grid; gap: 10px; align-content: start; }
.wbh-demo-picker-title { color: var(--wbh-faint); font-size: .8125rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.wbh-demo-option {
  position: relative;
  display: grid;
  gap: 2px;
  padding: 14px 16px 14px 46px;
  border: 1px solid var(--wbh-line-strong);
  border-radius: var(--wbh-r);
  background: #fff;
  cursor: pointer;
  transition: border-color .15s ease, background-color .15s ease;
}
.wbh-demo-option::before {
  content: "";
  position: absolute;
  left: 16px;
  top: 50%;
  width: 18px;
  height: 18px;
  border: 2px solid var(--wbh-line-strong);
  border-radius: 50%;
  background: #fff;
  transform: translateY(-50%);
}
.wbh-demo-option strong { color: var(--wbh-ink); font-size: 1rem; }
.wbh-demo-option span { color: var(--wbh-muted); font-size: .875rem; }
.wbh-demo-option:hover { border-color: var(--wbh-brand-strong); }

@media (max-width: 859px) {
  .wbh-demo-picker { grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); }
  .wbh-demo-picker-title { grid-column: 1 / -1; }
}

.wbh-demo-panel { display: none; justify-items: center; gap: 20px; }
.wbh-demo-side { display: grid; gap: 14px; max-width: 360px; justify-items: center; text-align: center; }
.wbh-demo-hint { color: var(--wbh-muted); font-size: .9375rem; }
.wbh-demo-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
@media (min-width: 860px) {
  .wbh-demo-stage .wbh-demo-panel { grid-template-columns: auto minmax(0, 1fr); align-items: center; column-gap: 40px; }
  .wbh-demo-side { justify-items: start; text-align: left; }
  .wbh-demo-actions { justify-content: flex-start; }
}
.wbh-demo-empty { display: grid; place-items: center; height: 100%; padding: 24px; color: var(--wbh-muted); text-align: center; }

#wbh-demo-0:checked ~ .wbh-demo-stage [data-wbh-demo-panel="0"],
#wbh-demo-1:checked ~ .wbh-demo-stage [data-wbh-demo-panel="1"],
#wbh-demo-2:checked ~ .wbh-demo-stage [data-wbh-demo-panel="2"],
#wbh-demo-3:checked ~ .wbh-demo-stage [data-wbh-demo-panel="3"],
#wbh-demo-4:checked ~ .wbh-demo-stage [data-wbh-demo-panel="4"],
#wbh-demo-5:checked ~ .wbh-demo-stage [data-wbh-demo-panel="5"] { display: grid; }

#wbh-demo-0:checked ~ .wbh-demo-picker [for="wbh-demo-0"],
#wbh-demo-1:checked ~ .wbh-demo-picker [for="wbh-demo-1"],
#wbh-demo-2:checked ~ .wbh-demo-picker [for="wbh-demo-2"],
#wbh-demo-3:checked ~ .wbh-demo-picker [for="wbh-demo-3"],
#wbh-demo-4:checked ~ .wbh-demo-picker [for="wbh-demo-4"],
#wbh-demo-5:checked ~ .wbh-demo-picker [for="wbh-demo-5"] {
  border-color: var(--wbh-brand-strong);
  background: var(--wbh-brand-soft);
  box-shadow: inset 0 0 0 1px var(--wbh-brand-strong);
}
#wbh-demo-0:checked ~ .wbh-demo-picker [for="wbh-demo-0"]::before,
#wbh-demo-1:checked ~ .wbh-demo-picker [for="wbh-demo-1"]::before,
#wbh-demo-2:checked ~ .wbh-demo-picker [for="wbh-demo-2"]::before,
#wbh-demo-3:checked ~ .wbh-demo-picker [for="wbh-demo-3"]::before,
#wbh-demo-4:checked ~ .wbh-demo-picker [for="wbh-demo-4"]::before,
#wbh-demo-5:checked ~ .wbh-demo-picker [for="wbh-demo-5"]::before {
  border: 5px solid var(--wbh-brand-strong);
}
#wbh-demo-0:focus-visible ~ .wbh-demo-picker [for="wbh-demo-0"],
#wbh-demo-1:focus-visible ~ .wbh-demo-picker [for="wbh-demo-1"],
#wbh-demo-2:focus-visible ~ .wbh-demo-picker [for="wbh-demo-2"],
#wbh-demo-3:focus-visible ~ .wbh-demo-picker [for="wbh-demo-3"],
#wbh-demo-4:focus-visible ~ .wbh-demo-picker [for="wbh-demo-4"],
#wbh-demo-5:focus-visible ~ .wbh-demo-picker [for="wbh-demo-5"] {
  outline: 3px solid var(--wbh-brand);
  outline-offset: 2px;
}

/* ---------- Planes ---------- */
.wbh-plans {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 208px), 1fr));
  align-items: stretch;
}
.wbh-plan {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 22px 20px 20px;
  border: 1px solid var(--wbh-line);
  border-radius: var(--wbh-r-lg);
  background: #fff;
}
.wbh-plan.is-featured { border-color: var(--wbh-brand-strong); box-shadow: inset 0 0 0 1px var(--wbh-brand-strong), var(--wbh-shadow-2); }
.wbh-plan.is-off { background: #fafbfc; }
.wbh-plan-tag {
  position: absolute;
  top: -12px;
  left: 18px;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--wbh-brand-strong);
  color: #fff;
  font-size: .75rem;
  font-weight: 600;
}
.wbh-plan:not(.is-featured) .wbh-plan-tag { background: var(--wbh-brand-soft); color: var(--wbh-brand-deep); }
.wbh-plan h3 { font-size: 1.125rem; font-weight: 700; }
.wbh-plan-cap { color: var(--wbh-muted); font-size: .875rem; }
.wbh-plan-price { display: grid; gap: 0; margin-top: 4px; }
@media (min-width: 1100px) { .wbh-plan h3 { min-height: 2.4em; } }
.wbh-plan-amount { color: var(--wbh-ink); font-size: 1.75rem; font-weight: 780; letter-spacing: -.02em; }
.wbh-plan-per { color: var(--wbh-muted); font-size: .875rem; }
.wbh-plan-gross { margin-top: -6px; color: var(--wbh-faint); font-size: .8125rem; }
.wbh-plan-desc { color: var(--wbh-muted); font-size: .9375rem; }
.wbh-checks { display: grid; gap: 7px; margin: 4px 0 6px; font-size: .9375rem; }
.wbh-checks li { position: relative; padding-left: 24px; }
.wbh-checks li::before {
  content: "";
  position: absolute;
  left: 3px;
  top: .42em;
  width: 11px;
  height: 6px;
  border-left: 2px solid var(--wbh-ok);
  border-bottom: 2px solid var(--wbh-ok);
  transform: rotate(-45deg);
}
.wbh-plan-meta { color: var(--wbh-muted); font-size: .8125rem; }
.wbh-plan .wbh-btn { margin-top: auto; }
.wbh-plan-off {
  margin-top: auto;
  padding: 10px 12px;
  border-radius: var(--wbh-r-sm);
  background: #eef0f4;
  color: var(--wbh-muted);
  font-size: .875rem;
  font-weight: 600;
  text-align: center;
}
.wbh-empty { padding: 20px; border: 1px dashed var(--wbh-line-strong); border-radius: var(--wbh-r); color: var(--wbh-muted); background: #fff; }

.wbh-addons { margin-top: clamp(36px, 5vw, 56px); }
.wbh-addon-list {
  display: grid;
  gap: 16px;
  margin-top: 18px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
}
.wbh-addon {
  display: grid;
  gap: 8px;
  align-content: start;
  padding: 20px;
  border: 1px solid var(--wbh-line);
  border-radius: var(--wbh-r-lg);
  background: #fff;
}
.wbh-addon h4 { font-size: 1.0625rem; font-weight: 700; }
.wbh-addon p { color: var(--wbh-muted); font-size: .9375rem; }
.wbh .wbh-addon-limit { color: var(--wbh-addon); font-weight: 600; font-size: .875rem; }
.wbh .wbh-addon-price { color: var(--wbh-ink); }
.wbh-addon-price .wbh-num:first-child { font-size: 1.25rem; font-weight: 750; }
.wbh-addon-price small { color: var(--wbh-faint); }
.wbh .wbh-addon-how { font-size: .8125rem; color: var(--wbh-faint); }

/* ---------- Desplegables (comparación y FAQ) ---------- */
.wbh-toggle-icon {
  position: relative;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--wbh-ink);
}
.wbh-toggle-icon::before,
.wbh-toggle-icon::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 2px;
  border-radius: 2px;
  background: #fff;
  transform: translate(-50%, -50%);
  transition: transform .2s ease;
}
.wbh-toggle-icon::after { transform: translate(-50%, -50%) rotate(90deg); }
details[open] > summary .wbh-toggle-icon::after { transform: translate(-50%, -50%) rotate(0deg); }

.wbh-compare {
  margin-top: clamp(32px, 4vw, 48px);
  border: 1px solid var(--wbh-line);
  border-radius: var(--wbh-r-lg);
  background: #fff;
}
.wbh-compare > summary,
.wbh-qa > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  cursor: pointer;
  list-style: none;
  color: var(--wbh-ink);
  font-weight: 650;
}
.wbh-compare > summary::-webkit-details-marker,
.wbh-qa > summary::-webkit-details-marker { display: none; }
.wbh-compare > summary { min-height: 60px; padding: 12px 18px; font-size: 1.0625rem; border-radius: var(--wbh-r-lg); }
.wbh-compare[open] > summary { border-bottom: 1px solid var(--wbh-line); border-radius: var(--wbh-r-lg) var(--wbh-r-lg) 0 0; }
.wbh-compare > summary:hover .wbh-toggle-icon,
.wbh-qa > summary:hover .wbh-toggle-icon { background: var(--wbh-brand-strong); }

/* position:relative: los textos solo para lectores de pantalla de las celdas
   (position:absolute) quedan contenidos y recortados por este contenedor. */
.wbh-table-wrap { position: relative; overflow-x: auto; }
.wbh-table {
  width: 100%;
  min-width: 760px;
  border-collapse: separate;
  border-spacing: 0;
  font-size: .9375rem;
}
.wbh-table th,
.wbh-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--wbh-line);
  text-align: center;
  vertical-align: middle;
}
.wbh-table thead th { color: var(--wbh-ink); font-weight: 700; background: #fff; }
.wbh-th-price { display: block; color: var(--wbh-faint); font-size: .8125rem; font-weight: 500; }
.wbh-table th[scope="row"],
.wbh-table thead th:first-child {
  position: sticky;
  left: 0;
  z-index: 1;
  background: #fff;
  text-align: left;
  font-weight: 600;
  color: var(--wbh-text);
  box-shadow: 1px 0 0 var(--wbh-line);
}
.wbh-table tbody tr:last-child > * { border-bottom: 0; }
.wbh-cell { font-size: .8125rem; font-weight: 600; }
.wbh-cell-yes { color: var(--wbh-ok); }
.wbh-cell-addon { color: var(--wbh-addon); }
.wbh-cell-no { color: var(--wbh-faint); }

/* ---------- Recomendador ---------- */
.wbh-reco { display: grid; gap: 24px; }
@media (min-width: 960px) {
  .wbh-reco { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: 40px; align-items: start; }
  .wbh-reco > .wbh-head { grid-column: 1 / -1; margin-bottom: 8px; }
}
.wbh-reco-form {
  display: grid;
  gap: 24px;
  padding: clamp(20px, 3vw, 28px);
  border: 1px solid var(--wbh-line);
  border-radius: var(--wbh-r-lg);
  background: #fff;
}
.wbh-field { display: grid; gap: 10px; }
.wbh-field legend,
.wbh-label { padding: 0; margin-bottom: 10px; color: var(--wbh-ink); font-weight: 650; }
.wbh-field .wbh-label { margin-bottom: 0; }
.wbh-optional { margin-left: 6px; color: var(--wbh-faint); font-weight: 500; font-size: .8125rem; }
.wbh-hint { color: var(--wbh-faint); font-size: .8125rem; }
.wbh-choice-row { display: flex; flex-wrap: wrap; gap: 10px; }
.wbh-check-grid { display: grid; gap: 10px; }
@media (min-width: 520px) { .wbh-check-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.wbh-choice {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 8px 14px;
  border: 1px solid var(--wbh-line-strong);
  border-radius: 10px;
  background: #fff;
  color: var(--wbh-text);
  font-size: .9375rem;
  cursor: pointer;
}
.wbh-choice input { width: 18px; height: 18px; margin: 0; flex-shrink: 0; accent-color: var(--wbh-brand-strong); }
.wbh-choice:hover { border-color: var(--wbh-brand-strong); }
.wbh-choice:has(input:checked) { border-color: var(--wbh-brand-strong); background: var(--wbh-brand-soft); color: var(--wbh-ink); }
.wbh-input {
  width: 100%;
  max-width: 180px;
  min-height: 46px;
  padding: 8px 12px;
  border: 1px solid var(--wbh-line-strong);
  border-radius: 10px;
  background: #fff;
  color: var(--wbh-ink);
  font: 600 1rem var(--wbh-font);
}
.wbh-input:focus-visible { border-color: var(--wbh-brand-strong); }
.wbh-input:invalid { border-color: #b42318; }

.wbh-reco-result { min-height: 120px; transition: opacity .15s ease; }
.wbh-reco-result[aria-busy="true"] { opacity: .55; }
.wbh-reco-result:focus { outline: none; }
.wbh-reco-result:focus-visible { outline: 3px solid var(--wbh-brand); outline-offset: 4px; border-radius: var(--wbh-r-lg); }
.wbh-reco-placeholder {
  display: grid;
  place-items: center;
  min-height: 200px;
  padding: 24px;
  border: 1px dashed var(--wbh-line-strong);
  border-radius: var(--wbh-r-lg);
  color: var(--wbh-muted);
  text-align: center;
  background: var(--wbh-soft);
}
.wbh-reco-card {
  display: grid;
  gap: 12px;
  padding: clamp(20px, 3vw, 28px);
  border: 1px solid var(--wbh-brand-strong);
  border-radius: var(--wbh-r-lg);
  background: #fff;
  box-shadow: var(--wbh-shadow-2);
}
.wbh-reco-card.is-none { border-color: var(--wbh-line-strong); box-shadow: none; }
.wbh-reco-kicker { color: var(--wbh-brand-deep); font-size: .8125rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.wbh-reco-card.is-none .wbh-reco-kicker { color: var(--wbh-muted); }
.wbh-reco-plan { font-size: 1.5rem; font-weight: 760; }
.wbh-reco-cap { margin-top: -8px; color: var(--wbh-muted); font-size: .9375rem; }
.wbh-reco-reason { color: var(--wbh-text); }
.wbh-reco-lines { display: grid; border-top: 1px solid var(--wbh-line); }
.wbh-reco-lines > div {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 16px;
  padding: 10px 0;
  border-bottom: 1px solid var(--wbh-line);
  font-size: .9375rem;
}
.wbh-reco-lines dt { color: var(--wbh-muted); }
.wbh-reco-lines dd { color: var(--wbh-ink); font-weight: 600; text-align: right; }
.wbh-reco-total dt { color: var(--wbh-ink); font-weight: 700; }
.wbh-reco-total dd small { display: block; color: var(--wbh-faint); font-weight: 500; }
/* Candidate 24: aviso mientras se actualiza o si falla; ocupa la altura fijada por el JS. */
.wbh-reco-result { display: grid; }
.wbh-reco-pending {
  display: grid;
  place-items: center;
  min-height: 120px;
  padding: 20px;
  border: 1px dashed var(--wbh-line-strong);
  border-radius: var(--wbh-r-lg);
  background: var(--wbh-soft);
  color: var(--wbh-muted);
  text-align: center;
}
.wbh-reco-pending.is-error { border-style: solid; border-color: #f3d19e; background: var(--wbh-warn-bg); color: var(--wbh-warn); }
.wbh-reco-optional { padding-top: 12px; border-top: 1px solid var(--wbh-line); }
.wbh-reco-optional-title { margin-bottom: 6px; color: var(--wbh-muted); font-size: .8125rem; font-weight: 600; }
.wbh-reco-optional li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; padding: 4px 0; font-size: .875rem; }

/* ---------- Preguntas frecuentes ---------- */
.wbh-faq { max-width: 860px; border-top: 1px solid var(--wbh-line-strong); }
.wbh-qa { border-bottom: 1px solid var(--wbh-line-strong); }
.wbh-qa > summary { min-height: 64px; padding: 14px 0; font-size: 1.0625rem; }
.wbh-qa > summary > span:first-child { flex: 1; }
.wbh-qa[open] > summary { color: var(--wbh-brand-deep); }
.wbh-qa-body { padding: 0 44px 20px 0; color: var(--wbh-muted); max-width: 70ch; }

/* ---------- Llamado final ---------- */
.wbh-cta {
  position: relative;
  padding: clamp(48px, 7vw, 80px) 0;
  background: var(--wbh-ink);
  color: #d0d5dd;
}
.wbh-cta::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--wbh-gradient); }
.wbh-cta-in { display: grid; gap: 28px; align-items: center; }
@media (min-width: 900px) { .wbh-cta-in { grid-template-columns: minmax(0, 1fr) auto; } }
.wbh .wbh-cta h2 { color: #fff; font-size: clamp(1.625rem, 1.2rem + 1.6vw, 2.375rem); font-weight: 750; }
.wbh-cta p { margin-top: 10px; font-size: 1.0625rem; }
.wbh .wbh-cta :focus-visible { outline-color: #fff; }

/* ---------- Contacto ---------- */
.wbh-contact-list {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr));
}
.wbh-contact-list li {
  display: grid;
  gap: 4px;
  align-content: start;
  padding: 18px 20px;
  border: 1px solid var(--wbh-line);
  border-radius: var(--wbh-r-lg);
  background: #fff;
}
.wbh-contact-k { color: var(--wbh-faint); font-size: .75rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.wbh .wbh-contact-list a { color: var(--wbh-ink); font-weight: 650; font-size: 1.0625rem; text-decoration: underline; text-decoration-color: var(--wbh-line-strong); }
.wbh .wbh-contact-list a:hover { color: var(--wbh-brand-strong); text-decoration-color: currentColor; }
.wbh-contact-list li > span:not(.wbh-contact-k) { color: var(--wbh-ink); font-weight: 650; font-size: 1.0625rem; }
.wbh-contact-list small { color: var(--wbh-muted); font-size: .875rem; }

/* ---------- Pie ---------- */
.wbh-footer { padding: 28px 0 36px; border-top: 1px solid var(--wbh-line); background: #fff; font-size: .875rem; color: var(--wbh-muted); }
.wbh-footer-in { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 28px; }
.wbh-footer-brand { display: inline-flex; align-items: center; gap: 10px; color: var(--wbh-ink); font-weight: 650; }
.wbh-footer-brand img { width: 28px; height: 28px; }
.wbh .wbh-footer-brand a { color: var(--wbh-ink); font-weight: 650; }
.wbh-footer-links { display: flex; flex-wrap: wrap; gap: 4px 18px; }
.wbh .wbh-footer-links a { display: inline-flex; align-items: center; min-height: 36px; color: var(--wbh-muted); text-decoration: none; }
.wbh .wbh-footer-links a:hover { color: var(--wbh-ink); text-decoration: underline; }
.wbh-footer-copy { flex-basis: 100%; color: var(--wbh-faint); }

/* ---------- Movimiento (solo si está permitido) ---------- */
@media (prefers-reduced-motion: no-preference) {
  html:has(.wbh) { scroll-behavior: smooth; }
  .wbh-motion .wbh-reveal {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity .45s ease, transform .45s ease;
  }
  .wbh-motion .wbh-reveal.is-in { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .wbh *,
  .wbh *::before,
  .wbh *::after { transition-duration: 0s !important; animation: none !important; }
  .wbh-motion .wbh-reveal { opacity: 1 !important; transform: none !important; }
}

/* ---------- Uso incrustado por shortcode ---------- */
.wbh.wbh-embed { background: transparent; }

/* ---------- Impresión ---------- */
@media print {
  .wbh-header, .wbh-menu, .wbh-skip, .wbh-demos, .wbh-reco-form, .wbh-cta { display: none !important; }
  .wbh-section { padding: 24px 0; }
  .wbh-compare > .wbh-table-wrap { display: block; }
}
