/* First-run tutorial overlay - sits above app UI, click-through on spotlight */

#tutorialOverlay {
  position: fixed;
  inset: 0;
  z-index: 210;
  pointer-events: none;
}

#tutorialOverlay.hidden {
  display: none !important;
}

.tutorial-dim {
  position: fixed;
  background: rgba(27, 35, 51, 0.72);
  pointer-events: auto;
  z-index: 1;
  transition: top 0.18s ease, left 0.18s ease, width 0.18s ease, height 0.18s ease;
}

.tutorial-spotlight-ring {
  position: fixed;
  z-index: 2;
  pointer-events: none;
  border-radius: 12px;
  box-shadow: 0 0 0 3px #F2622E, 0 0 0 6px rgba(242, 98, 46, 0.35);
  transition: top 0.18s ease, left 0.18s ease, width 0.18s ease, height 0.18s ease;
  animation: tutorial-pulse 1.6s ease-in-out infinite;
}

.tutorial-hole-blocker {
  position: fixed;
  z-index: 2;
  pointer-events: auto;
  background: transparent;
}

@keyframes tutorial-pulse {
  0%,
  100% {
    box-shadow: 0 0 0 3px #F2622E, 0 0 0 6px rgba(242, 98, 46, 0.35);
  }
  50% {
    box-shadow: 0 0 0 3px #F2622E, 0 0 0 10px rgba(242, 98, 46, 0.15);
  }
}

.tutorial-card {
  position: fixed;
  left: 16px;
  right: 16px;
  z-index: 3;
  pointer-events: auto;
  max-width: 420px;
  margin-inline: auto;
  padding: 16px;
  border-radius: 16px;
  background: rgba(27, 35, 51, 0.96);
  color: #fff;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  padding-bottom: max(16px, env(safe-area-inset-bottom));
}

.tutorial-card--bottom {
  bottom: max(16px, env(safe-area-inset-bottom));
}

.tutorial-card--top {
  top: max(16px, env(safe-area-inset-top));
}

.tutorial-step-count {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 6px;
}

.tutorial-title {
  font-size: 18px;
  line-height: 26px;
  font-weight: 600;
  margin: 0 0 6px;
}

.tutorial-body {
  font-size: 14px;
  line-height: 20px;
  color: rgba(255, 255, 255, 0.82);
  margin: 0 0 14px;
}

.tutorial-action-hint {
  font-size: 13px;
  line-height: 18px;
  color: #F2622E;
  margin: -6px 0 12px;
}

.tutorial-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.tutorial-btn {
  height: 44px;
  padding: 0 16px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.tutorial-btn:active {
  transform: scale(0.97);
}

.tutorial-btn--primary {
  flex: 1;
  min-width: 100px;
  background: #F2622E;
  color: #fff;
}

.tutorial-btn--ghost {
  background: transparent;
  color: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.tutorial-btn--hidden {
  display: none !important;
}

/* Full-screen language picker (phase 0) */
.tutorial-lang {
  position: fixed;
  inset: 0;
  z-index: 4;
  pointer-events: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  padding-top: max(24px, env(safe-area-inset-top));
  padding-bottom: max(24px, env(safe-area-inset-bottom));
  background: #1B2333;
  color: #fff;
  text-align: center;
}

.tutorial-lang.hidden {
  display: none !important;
}

.tutorial-lang-title {
  font-size: 22px;
  line-height: 30px;
  font-weight: 600;
  margin: 0 0 8px;
}

.tutorial-lang-body {
  font-size: 14px;
  line-height: 20px;
  color: rgba(255, 255, 255, 0.75);
  margin: 0 0 28px;
  max-width: 320px;
}

.tutorial-lang-btns {
  display: flex;
  gap: 12px;
  width: 100%;
  max-width: 320px;
}

.tutorial-lang-btn {
  flex: 1;
  height: 56px;
  border-radius: 14px;
  border: 2px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.tutorial-lang-btn:active {
  transform: scale(0.96);
}

.tutorial-lang-btn:hover,
.tutorial-lang-btn:focus-visible {
  border-color: #F2622E;
  outline: none;
}

.tutorial-lang-flag {
  font-size: 22px;
  line-height: 1;
}

.tutorial-lang-label {
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.85);
}

.tutorial-lang-skip {
  margin-top: 20px;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.55);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  padding: 8px 12px;
}

.tutorial-lang-skip:hover,
.tutorial-lang-skip:focus-visible {
  color: rgba(255, 255, 255, 0.9);
}
