/**
 * QBK · Tour guiado - estilos
 * Autonomo, sin dependencias. Respeta el color de marca de la app
 * anfitriona via las variables ya definidas en cada app.
 */

/* Impide que el body scrollee mientras el tour esta activo. */
body.qbk-tour-activo { overflow: hidden; }

.qbk-tour-velo {
  position: absolute;
  inset: 0;
  z-index: 9500;
  pointer-events: none;
  background: rgba(6, 20, 24, 0.72);
  transition: clip-path .35s cubic-bezier(.4, 0, .2, 1);
}

.qbk-tour-halo {
  position: absolute;
  z-index: 9510;
  pointer-events: none;
  border: 2px solid #F6C876;
  border-radius: 10px;
  box-shadow:
    0 0 0 4px rgba(246, 200, 118, .22),
    0 20px 40px -10px rgba(0, 0, 0, .5);
  transition:
    left .35s cubic-bezier(.4, 0, .2, 1),
    top .35s cubic-bezier(.4, 0, .2, 1),
    width .35s cubic-bezier(.4, 0, .2, 1),
    height .35s cubic-bezier(.4, 0, .2, 1),
    opacity .3s ease;
}

.qbk-tour-tarjeta {
  position: absolute;
  z-index: 9520;
  background: #FFFFFF;
  color: #171B21;
  border-radius: 12px;
  padding: 20px 22px 18px;
  box-shadow: 0 20px 60px -10px rgba(0, 0, 0, .5);
  width: 340px;
  max-width: calc(100vw - 32px);
  font: 14px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  transition:
    left .35s cubic-bezier(.4, 0, .2, 1),
    top .35s cubic-bezier(.4, 0, .2, 1);
}

/* Modo oscuro (Mesa, apps con data-tema oscuro) */
html[data-tema="oscuro"] .qbk-tour-tarjeta,
html[data-theme="dark"] .qbk-tour-tarjeta {
  background: #1B2229;
  color: #EAF1F3;
}
html[data-tema="oscuro"] .qbk-tour-tarjeta[data-flecha]::before,
html[data-theme="dark"] .qbk-tour-tarjeta[data-flecha]::before {
  background: #1B2229;
}

.qbk-tour-tarjeta[data-flecha]::before {
  content: "";
  position: absolute;
  width: 14px; height: 14px;
  background: #FFFFFF;
  transform: rotate(45deg);
}
.qbk-tour-tarjeta[data-flecha="izquierda"]::before { left: -7px; top: 32px; }
.qbk-tour-tarjeta[data-flecha="derecha"]::before  { right: -7px; top: 32px; }
.qbk-tour-tarjeta[data-flecha="arriba"]::before   { top: -7px; left: 32px; }
.qbk-tour-tarjeta[data-flecha="abajo"]::before    { bottom: -7px; left: 32px; }

.qbk-tour-contador {
  font-size: 10.5px;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: #7B848E;
  font-weight: 700;
  margin: 0 0 6px;
}

.qbk-tour-titulo {
  font-family: Georgia, "DejaVu Serif", "Times New Roman", serif;
  font-style: italic;
  font-weight: 500;
  font-size: 20px;
  letter-spacing: -.01em;
  line-height: 1.15;
  margin: 0 0 8px;
  color: inherit;
}

.qbk-tour-cuerpo {
  font-size: 13.5px;
  color: #4A525C;
  line-height: 1.55;
  margin: 0;
}
html[data-tema="oscuro"] .qbk-tour-cuerpo,
html[data-theme="dark"] .qbk-tour-cuerpo { color: #B4BEC3; }

.qbk-tour-cuerpo strong { font-weight: 600; color: #171B21; }
html[data-tema="oscuro"] .qbk-tour-cuerpo strong,
html[data-theme="dark"] .qbk-tour-cuerpo strong { color: #EAF1F3; }

.qbk-tour-acciones {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 16px;
}

.qbk-tour-progreso { display: flex; gap: 5px; }
.qbk-tour-progreso span {
  width: 22px; height: 3px;
  background: #D5DBDE;
  border-radius: 2px;
}
.qbk-tour-progreso span.on { background: #01717F; }

.qbk-tour-botones { display: flex; gap: 8px; }
.qbk-tour-botones button {
  border: 1px solid #DAE0E3;
  background: transparent;
  color: inherit;
  padding: 7px 14px;
  border-radius: 7px;
  font: inherit;
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  line-height: 1;
}
.qbk-tour-botones button:hover { background: rgba(0,0,0,.04); }
html[data-tema="oscuro"] .qbk-tour-botones button:hover,
html[data-theme="dark"] .qbk-tour-botones button:hover { background: rgba(255,255,255,.06); }

.qbk-tour-botones .qbk-tour-sig {
  background: #01717F;
  color: #FFFFFF;
  border-color: #01717F;
}
.qbk-tour-botones .qbk-tour-sig:hover { background: #014E58; border-color: #014E58; }

.qbk-tour-cerrar {
  position: absolute;
  top: 10px; right: 10px;
  background: transparent;
  border: 0;
  color: #7B848E;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  font: 500 18px/1 sans-serif;
  line-height: 1;
}
.qbk-tour-cerrar:hover { color: #171B21; background: rgba(0,0,0,.05); }
html[data-tema="oscuro"] .qbk-tour-cerrar:hover,
html[data-theme="dark"] .qbk-tour-cerrar:hover { color: #EAF1F3; background: rgba(255,255,255,.08); }

.qbk-tour-fin { text-align: center; padding: 8px 0; }
.qbk-tour-fin-ic {
  width: 44px; height: 44px;
  margin: 0 auto 10px;
  background: #E6F1F2;
  color: #01717F;
  border-radius: 999px;
  display: grid; place-items: center;
}
.qbk-tour-fin h3 {
  font-family: Georgia, serif; font-style: italic;
  font-size: 22px; font-weight: 500;
  margin: 0 0 6px; color: inherit;
}
.qbk-tour-fin p {
  color: #4A525C; font-size: 13.5px; margin: 0 0 16px;
}
html[data-tema="oscuro"] .qbk-tour-fin p,
html[data-theme="dark"] .qbk-tour-fin p { color: #B4BEC3; }

.qbk-tour-btn-fin {
  background: #01717F; color: #FFFFFF; border: 0;
  padding: 9px 22px; border-radius: 8px; font-weight: 600;
  font: inherit; font-weight: 600; cursor: pointer;
}
.qbk-tour-btn-fin:hover { background: #014E58; }

@media (prefers-reduced-motion: reduce) {
  .qbk-tour-velo, .qbk-tour-halo, .qbk-tour-tarjeta { transition: none; }
}
