/* CV Builder "How to use" walkthrough (static/js/cv-howto.js). Uses the site tokens
   from style.css (--t1/2/3, --bd, --accent, --font), so it follows light and dark. */

/* Darkened accent derivations for WCAG AA. White text on --accent (#5b5bf6) is
   only ~4.05:1, and small accent text on ivory ~4.1:1 -> both under AA. color-mix
   darkens the *session* accent (so it still respects the per-session colour);
   the @supports guard leaves old browsers on the original accent (no breakage). */
.cvo-tour {
  --cvo-acc-strong: var(--accent);
  --cvo-acc-ink: var(--accent);
}
@supports (color: color-mix(in srgb, red, #000)) {
  .cvo-tour {
    --cvo-acc-strong: color-mix(in srgb, var(--accent) 76%, #000);
    --cvo-acc-ink: color-mix(in srgb, var(--accent) 70%, #000);
  }
}

.cvo-btn-primary {
  font-family: var(--font); font-size: 14px; font-weight: 700; color: #fff;
  background: var(--cvo-acc-strong); border: none; border-radius: 10px;
  padding: 11px 22px; cursor: pointer;
  transition: filter 0.15s, transform 0.1s;
}
.cvo-btn-primary:hover { filter: brightness(1.06); }
.cvo-btn-primary:active { transform: translateY(1px); }
.cvo-tour { position: fixed; inset: 0; z-index: 1000; pointer-events: none; }
.cvo-tour-ring {
  position: fixed; border-radius: 11px;
  border: 2px solid var(--accent);
  box-shadow: 0 0 0 9999px rgba(26, 22, 20, 0.55);
  transition: top 0.25s, left 0.25s, width 0.25s, height 0.25s;
  pointer-events: none;
}
.cvo-tour-card {
  position: fixed; z-index: 1001;
  background: var(--bg2); border: 1px solid var(--bd); border-radius: 13px;
  box-shadow: 0 16px 44px rgba(26, 22, 20, 0.3);
  padding: 16px 18px; font-family: var(--font); color: var(--t1);
  pointer-events: auto;
  animation: cvo-fade 0.2s ease;
}
.cvo-tour-step { font-size: 11px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--cvo-acc-ink); margin-bottom: 5px; }
.cvo-tour-title { font-size: 16px; font-weight: 800; margin-bottom: 5px; }
.cvo-tour-body { font-size: 13.5px; line-height: 1.5; color: var(--t2); margin-bottom: 10px; }
.cvo-tour-hint { font-size: 12px; font-weight: 600; color: var(--cvo-acc-ink); margin-bottom: 12px; }
.cvo-tour-read { display: block; width: 100%; margin-top: 10px; background: none; border: none; cursor: pointer; font-family: var(--font); font-size: 12px; color: var(--t3); text-align: center; }
.cvo-tour-read:hover { color: var(--cvo-acc-ink); text-decoration: underline; }
.cvo-tour-actions { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.cvo-tour-skip { background: none; border: none; cursor: pointer; font-family: var(--font); font-size: 13px; font-weight: 600; color: var(--t3); padding: 6px 2px; }
.cvo-tour-skip:hover { color: var(--t1); }
.cvo-tour-next { padding: 8px 18px; font-size: 13px; }

@keyframes cvo-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes cvo-pop { from { opacity: 0; transform: translateY(10px) scale(0.98); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  .cvo-tour-card { animation: none; }
  .cvo-tour-ring { transition: none; }
}

@media (max-width: 560px) {
  .cvo-tour-card { left: 12px !important; right: 12px; width: auto !important; }
}
