/* Onboarding walkthrough (public/tutorial.js). Deliberately its own file,
   never appended to styles.css/portal.css/admin.css/month.css/
   month-admin.css/gecombineerd-shared.css - the whole point of keeping
   this separate is that every existing stylesheet stays byte-identical.
   No var() references into those files either, for the same reason -
   colors here are self-contained so this file works unmodified no
   matter what page it's loaded on. z-index 1000 - highest anywhere else
   in the app is 32 (.visibility-select-list). */

/* A fixed-position rectangle drawn over the real target element
   (public/tutorial.js's renderSpot/positionSpot/removeSpot), sized/
   positioned from its getBoundingClientRect() - not a class applied to
   the target itself, so it can't collide with that element's own
   styling from styles.css/month.css/etc, and it can't run into any
   target-specific rendering quirks (a <tr>'s own outline/box-shadow only
   actually painting after something forces a repaint, e.g. scrolling). */
.mw-tutorial-spot {
  position: fixed;
  z-index: 999;
  pointer-events: none;
  border-radius: 4px;
  box-shadow: 0 0 0 3px #ffd93b, 0 0 16px 4px rgba(255, 217, 59, 0.75);
  animation: mw-tutorial-pulse 1.4s ease-in-out infinite;
}

@keyframes mw-tutorial-pulse {
  0%, 100% { box-shadow: 0 0 0 3px #ffd93b, 0 0 16px 4px rgba(255, 217, 59, 0.75); }
  50% { box-shadow: 0 0 0 3px #ffd93b, 0 0 24px 8px rgba(255, 217, 59, 0.95); }
}

.mw-tutorial-bubble {
  position: fixed;
  z-index: 1000;
  max-width: 280px;
  background: #ffd93b;
  color: #222222;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.28);
  padding: 14px 16px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 14px;
  line-height: 1.4;
}

/* The welcome step - no target to anchor to, so it's just centered on
   screen instead of positioned from a getBoundingClientRect() (see
   renderBubble/positionBubble, public/tutorial.js). */
.mw-tutorial-bubble-center {
  top: 35%;
  left: 50%;
  transform: translate(-50%, -50%);
  max-width: 320px;
}

.mw-tutorial-bubble-text {
  margin-bottom: 10px;
  white-space: pre-line;
}

.mw-tutorial-bubble-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.mw-tutorial-bubble-actions button {
  font-family: inherit;
  font-size: 12.5px;
  border-radius: 6px;
  padding: 6px 10px;
  cursor: pointer;
  border: 1px solid transparent;
}

.mw-tutorial-next {
  background: #222222;
  color: #ffd93b;
  font-weight: 600;
}

.mw-tutorial-next:hover {
  background: #3a3a3a;
}

.mw-tutorial-badge {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 4px;
  background: #222222;
  color: #ffd93b;
  border-radius: 999px;
  padding: 6px 8px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 12.5px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
}

.mw-tutorial-badge-text {
  padding: 0 2px;
  white-space: nowrap;
}

.mw-tutorial-badge-prev,
.mw-tutorial-badge-next,
.mw-tutorial-badge-stop {
  font-family: inherit;
  font-size: 16px;
  line-height: 1;
  background: transparent;
  color: #ffd93b;
  border: none;
  cursor: pointer;
  padding: 4px 7px;
  border-radius: 50%;
}

.mw-tutorial-badge-prev:hover:not(:disabled),
.mw-tutorial-badge-next:hover,
.mw-tutorial-badge-stop:hover {
  background: rgba(255, 255, 255, 0.15);
}

.mw-tutorial-badge-prev:disabled {
  opacity: 0.3;
  cursor: default;
}

.mw-tutorial-badge-stop {
  font-size: 15px;
}

/* Locks page scroll for the whole tour, phones only (700px matches this
   app's own existing mobile-card breakpoint, styles.css) - a touch-
   scroll gesture doesn't reliably fire the 'scroll' listener
   repositionBubble (public/tutorial.js) relies on quickly/consistently
   enough on iOS Safari, so the highlight/bubble can end up pointing at
   the wrong spot mid-scroll (reported directly). html (not just body) -
   iOS Safari's own rubber-band overscroll can otherwise still move the
   page even with body alone set. */
@media (max-width: 700px) {
  html.mw-tutorial-active {
    overflow: hidden;
    touch-action: none;
  }
  html.mw-tutorial-active body {
    overflow: hidden;
  }
}
