/* Floating Tutorial Button */
.tutorial-btn {
  position: fixed;
  top: 155px;
  left: 5px;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background-color: #0066cc;
  color: #ffffff;
  border: none;
  border-radius: 999px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  z-index: 9000;
  transition: transform 0.15s ease-out, box-shadow 0.15s ease-out, background-color 0.15s ease-out, opacity 0.15s ease-out;
}

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

.tutorial-btn:hover {
  transform: translateY(-50%) translateX(1px);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.3);
  background-color: #0052a3;
}

.tutorial-btn:active {
  transform: translateY(-50%) translateX(0);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.2);
}

.tutorial-btn i {
  font-size: 16px;
}

/* Overlay */
.tutorial-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease-out, visibility 0.2s ease-out;
  z-index: 9500;
}

.tutorial-overlay.open {
  opacity: 1;
  visibility: visible;
}

/* Modal */
.tutorial-modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.96);
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.4);
  max-width: 960px;
  width: 90%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease-out, visibility 0.2s ease-out, transform 0.2s ease-out;
  z-index: 9600;
  outline: none;
}

.tutorial-modal.open {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, -50%) scale(1);
}

.tutorial-close-btn {
  position: absolute;
  top: 10px;
  right: 12px;
  background: transparent;
  border: none;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  color: #555;
  padding: 4px;
  transition: color 0.15s ease-out, transform 0.15s ease-out;
}

.tutorial-close-btn:hover {
  color: #000;
  transform: scale(1.05);
}

/* Carousel */
.tutorial-carousel {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 56px;
  box-sizing: border-box;
}

.tutorial-carousel-inner {
  width: 100%;
  max-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.tutorial-slide {
  display: none;
  max-width: 100%;
  max-height: 70vh;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

.tutorial-slide.active {
  display: block;
}

/* Navigation buttons */
.tutorial-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: rgba(0, 0, 0, 0.65);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  cursor: pointer;
  transition: transform 0.15s ease-out, background 0.15s ease-out, opacity 0.15s ease-out;
}

.tutorial-nav-prev {
  left: 18px;
}

.tutorial-nav-next {
  right: 18px;
}

.tutorial-nav-btn:hover {
  transform: translateY(-50%) scale(1.05);
  background: rgba(0, 0, 0, 0.8);
}

.tutorial-nav-btn:disabled {
  opacity: 0.4;
  cursor: default;
  transform: translateY(-50%) scale(1);
}

/* Indicator: dots and counter */
.tutorial-indicator {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 12px 20px 18px;
  border-top: 1px solid #e0e0e0;
  background: #fafafa;
  border-radius: 0 0 12px 12px;
  box-sizing: border-box;
}

.tutorial-dots {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
}

.tutorial-dot {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1px solid #c4c4c4;
  background: #ffffff;
  color: #555;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 500;
  transition: background 0.15s ease-out, transform 0.15s ease-out;
}

.tutorial-dot.active {
  background: #0066cc;
  border-color: #0066cc;
  color: #ffffff;
  transform: scale(1.05);
}

.tutorial-counter {
  font-size: 13px;
  font-weight: 500;
  color: #555;
  margin-left: 4px;
}

/* Responsive tweaks */
@media (max-width: 768px) {
  .tutorial-btn {
    top: auto;
    bottom: 16px;
    left: 50%;
    transform: translate(-50%, 0);
  }

  .tutorial-carousel {
    padding: 20px 40px;
  }

  .tutorial-slide {
    max-height: 60vh;
  }
}

@media (max-width: 480px) {
  .tutorial-carousel {
    padding: 16px 32px;
  }

  .tutorial-nav-btn {
    width: 34px;
    height: 34px;
  }

  .tutorial-indicator {
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }
}

