/*
 * VivaRevize product tour styles — Phase 1
 * All classes prefixed with .vr-tour-* to avoid collisions.
 * Respects html[data-vr-theme="light"] via CSS variable fallbacks.
 */

.vr-tour-overlay {
  position: fixed;
  inset: 0;
  z-index: 14000;
  pointer-events: none;
  opacity: 0;
  transition: opacity .15s ease-out;
}
.vr-tour-overlay--visible {
  opacity: 1;
  pointer-events: auto;
}

.vr-tour-spotlight {
  position: absolute;
  box-shadow: 0 0 0 9999px rgba(0, 0, 0, .55);
  border-radius: 8px;
  pointer-events: none;
  transition: all .18s ease-out;
  outline: 2px solid rgba(50, 232, 117, .55);
  outline-offset: 0;
}

html[data-vr-theme="light"] .vr-tour-spotlight {
  box-shadow: 0 0 0 9999px rgba(15, 23, 42, .38);
  outline-color: rgba(37, 99, 235, .55);
}

.vr-tour-tooltip {
  position: absolute;
  z-index: 14010;
  max-width: 320px;
  width: max-content;
  background: var(--panel, #101216);
  color: var(--text, #eee);
  border: 1px solid var(--border, #333);
  border-radius: 12px;
  padding: 14px 14px 12px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, .55);
  font-family: sans-serif;
  font-size: 14px;
  line-height: 1.45;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity .15s ease-out, transform .15s ease-out;
  outline: none;
}
.vr-tour-tooltip--visible {
  opacity: 1;
  transform: translateY(0);
}
.vr-tour-tooltip:focus-visible {
  box-shadow: 0 0 0 3px rgba(50, 232, 117, .35), 0 20px 50px rgba(0, 0, 0, .55);
}

html[data-vr-theme="light"] .vr-tour-tooltip {
  background: #ffffff;
  color: #1f2937;
  border-color: #cbd8ea;
  box-shadow: 0 20px 50px rgba(31, 41, 55, .18);
}

.vr-tour-counter {
  font-size: 11px;
  letter-spacing: .05em;
  text-transform: uppercase;
  opacity: .65;
  margin-bottom: 6px;
}

.vr-tour-title {
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 800;
  color: inherit;
}

.vr-tour-body {
  margin: 0 0 12px;
  color: inherit;
  opacity: .95;
}

.vr-tour-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
}

.vr-tour-btn {
  appearance: none;
  border: 1px solid var(--border, #333);
  background: transparent;
  color: inherit;
  padding: 7px 12px;
  border-radius: 8px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  transition: background .15s ease, border-color .15s ease, color .15s ease, transform .05s ease;
}
.vr-tour-btn:hover { background: rgba(255, 255, 255, .05); }
.vr-tour-btn:active { transform: translateY(1px); }
.vr-tour-btn:focus-visible {
  outline: 2px solid var(--accent, #32e875);
  outline-offset: 2px;
}

.vr-tour-btn-ghost {
  opacity: .8;
  margin-right: auto;
}

.vr-tour-btn-secondary { }

.vr-tour-btn-primary {
  background: var(--accent, #32e875);
  border-color: var(--accent, #32e875);
  color: #0b1f13;
}
.vr-tour-btn-primary:hover {
  background: var(--accent, #32e875);
  filter: brightness(1.08);
}

html[data-vr-theme="light"] .vr-tour-btn { border-color: #cbd8ea; }
html[data-vr-theme="light"] .vr-tour-btn:hover { background: #eef4ff; }
html[data-vr-theme="light"] .vr-tour-btn-primary {
  background: #2563eb;
  border-color: #1d4ed8;
  color: #ffffff;
}
html[data-vr-theme="light"] .vr-tour-btn-primary:hover {
  background: #1d4ed8;
  filter: none;
}

/* Mobile tooltip: pinned to bottom */
@media (max-width: 640px) {
  .vr-tour-tooltip--mobile,
  .vr-tour-tooltip {
    position: fixed !important;
    left: 12px !important;
    right: 12px !important;
    bottom: 12px !important;
    top: auto !important;
    max-width: none !important;
    width: auto !important;
  }
}

/* === Menu modal === */
.vr-tour-menu-modal {
  position: fixed;
  inset: 0;
  z-index: 14020;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(0, 0, 0, .62);
  font-family: sans-serif;
}
html[data-vr-theme="light"] .vr-tour-menu-modal {
  background: rgba(15, 23, 42, .45);
}

.vr-tour-menu-card {
  width: min(560px, 100%);
  max-height: 90vh;
  overflow: auto;
  background: var(--panel, #101216);
  color: var(--text, #eee);
  border: 1px solid var(--border, #333);
  border-radius: 14px;
  padding: 18px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .5);
}
html[data-vr-theme="light"] .vr-tour-menu-card {
  background: #ffffff;
  color: #1f2937;
  border-color: #cbd8ea;
  box-shadow: 0 24px 70px rgba(31, 41, 55, .18);
}

.vr-tour-menu-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}
.vr-tour-menu-title {
  margin: 0;
  font-size: 18px;
  font-weight: 800;
  flex: 1;
}
.vr-tour-menu-close {
  appearance: none;
  border: 0;
  background: transparent;
  color: inherit;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 8px;
}
.vr-tour-menu-close:hover { background: rgba(255, 255, 255, .06); }
html[data-vr-theme="light"] .vr-tour-menu-close:hover { background: #eef4ff; }
.vr-tour-menu-close:focus-visible {
  outline: 2px solid var(--accent, #32e875);
  outline-offset: 2px;
}

.vr-tour-menu-intro {
  margin: 0 0 12px;
  opacity: .8;
  font-size: 13px;
  line-height: 1.5;
}

.vr-tour-menu-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.vr-tour-menu-empty {
  padding: 20px;
  text-align: center;
  opacity: .6;
  border: 1px dashed var(--border, #333);
  border-radius: 10px;
}

.vr-tour-menu-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--border, #333);
  border-radius: 10px;
  background: rgba(255, 255, 255, .02);
}
html[data-vr-theme="light"] .vr-tour-menu-row {
  background: #f7faff;
  border-color: #d7e2ef;
}

.vr-tour-menu-row-label {
  flex: 1;
  min-width: 0;
}
.vr-tour-menu-row-title {
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 2px;
}
.vr-tour-menu-row-status {
  font-size: 12px;
  opacity: .8;
}
.vr-tour-menu-row-status.is-done { color: var(--accent, #32e875); }
html[data-vr-theme="light"] .vr-tour-menu-row-status.is-done { color: #2563eb; }
.vr-tour-menu-row-status.is-todo { opacity: .6; }

.vr-tour-menu-info {
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px solid var(--border, #333);
  border-radius: 10px;
  background: rgba(255, 190, 60, .08);
  color: inherit;
  font-size: 13px;
  line-height: 1.5;
}
html[data-vr-theme="light"] .vr-tour-menu-info {
  background: #fff7e0;
  border-color: #e7c580;
  color: #6b4b12;
}

/* === NEW badges ("NOVÉ") on freshly-shipped features === */
.vr-tour-new-badge {
  position: absolute;
  top: -6px;
  right: -8px;
  z-index: 5;
  padding: 2px 5px;
  min-width: 18px;
  height: auto;
  font-family: inherit;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .04em;
  line-height: 1.2;
  text-align: center;
  text-transform: uppercase;
  color: #0b1f13;
  background: var(--accent, #32e875);
  border: 1px solid rgba(0, 0, 0, .12);
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, .35), 0 0 0 3px rgba(50, 232, 117, .18);
  pointer-events: none;
  user-select: none;
  animation: vr-tour-badge-pulse 2.2s ease-in-out infinite;
}
html[data-vr-theme="light"] .vr-tour-new-badge {
  color: #ffffff;
  background: #dc2626;
  border-color: rgba(0, 0, 0, .06);
  box-shadow: 0 2px 6px rgba(220, 38, 38, .28), 0 0 0 3px rgba(220, 38, 38, .12);
}
@keyframes vr-tour-badge-pulse {
  0%   { transform: scale(1);    opacity: 1; }
  50%  { transform: scale(1.08); opacity: .92; }
  100% { transform: scale(1);    opacity: 1; }
}
.vr-tour-new-badge--inline {
  position: static;
  display: inline-block;
  margin-left: 6px;
  vertical-align: middle;
}
/* Parent must be positioned to anchor the absolute badge; wrapper class adds it. */
.vr-tour-badge-host { position: relative; }

@media (max-width: 640px) {
  .vr-tour-menu-row {
    flex-direction: column;
    align-items: stretch;
  }
  .vr-tour-menu-row .vr-tour-btn {
    width: 100%;
  }
}


/* -------------------------------------------------------------------------- */
/* Help tooltips (ℹ️) — real DOM bubble appended to <body>, position: fixed.  */
/* Použij <span class="vr-help-tip" tabindex="0" data-tip="...">ℹ️</span>     */
/* -------------------------------------------------------------------------- */

.vr-help-tip {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  margin-left: 6px !important;
  cursor: help !important;
  font-size: 14px !important;
  opacity: 0.75 !important;
  user-select: none !important;
  transition: opacity .15s !important;
}
.vr-help-tip:hover, .vr-help-tip:focus {
  opacity: 1 !important;
  outline: none !important;
}

.vr-help-tip-bubble {
  position: fixed !important;
  z-index: 15000 !important;
  min-width: 200px !important;
  max-width: 340px !important;
  padding: 10px 12px !important;
  background: var(--panel, #101216) !important;
  color: var(--text, #eee) !important;
  border: 1px solid var(--border, #333) !important;
  border-radius: 8px !important;
  font-size: 13px !important;
  line-height: 1.4 !important;
  font-weight: 400 !important;
  box-shadow: 0 8px 24px rgba(0,0,0,0.35) !important;
  pointer-events: none !important;
  white-space: normal !important;
  text-align: left !important;
}

html[data-vr-theme="light"] .vr-help-tip-bubble {
  background: #ffffff !important;
  color: #1f2937 !important;
  border-color: #d1d5db !important;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.15) !important;
}