/* DashboardTour Component Styles - Enhanced Classic Layout */

/* Main Container */
.dashboard-tour-container {
  display: flex;
  gap: 32px;
  background: linear-gradient(135deg, rgba(21, 22, 26, 0.95) 0%, rgba(17, 19, 25, 0.95) 100%);
  border: 1px solid rgba(176, 47, 52, 0.2);
  border-radius: 24px;
  padding: 32px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(176, 47, 52, 0.1);
  backdrop-filter: blur(10px);
  animation: containerFadeIn 600ms cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
}

/* Tour Selection Menu */
.tour-selection-menu {
  width: 340px;
  background: linear-gradient(135deg, rgba(17, 19, 25, 0.8) 0%, rgba(15, 15, 18, 0.8) 100%);
  border: 1px solid rgba(38, 42, 51, 0.8);
  border-radius: 20px;
  padding: 24px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  animation: slideInLeft 600ms cubic-bezier(0.4, 0, 0.2, 1) 200ms backwards;
  overflow: hidden;
}

.tour-selection-title {
  margin: 0 0 24px 0;
  color: #d24449;
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  text-shadow: 0 2px 10px rgba(210, 68, 73, 0.3);
}

.tour-options-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.tour-option-button {
  position: relative;
  padding: 20px 24px;
  border-radius: 16px;
  cursor: pointer;
  font-size: 15px;
  font-weight: 400;
  text-align: left;
  transition: all 300ms cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(42, 47, 57, 0.5);
  background: linear-gradient(135deg, rgba(23, 26, 33, 0.6) 0%, rgba(17, 19, 25, 0.6) 100%);
  color: #f1f2f5;
  overflow: hidden;
}

.tour-option-button::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(176, 47, 52, 0.1) 0%, rgba(210, 68, 73, 0.05) 100%);
  opacity: 0;
  transition: opacity 300ms;
  pointer-events: none;
}

.tour-option-button:hover::before {
  opacity: 1;
}

.tour-option-button.selected {
  background: linear-gradient(135deg, rgba(176, 47, 52, 0.2) 0%, rgba(142, 38, 42, 0.15) 100%);
  border-color: rgba(176, 47, 52, 0.6);
  transform: translateX(4px);
  box-shadow: 0 8px 24px rgba(176, 47, 52, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.tour-option-button.selected::before {
  opacity: 1;
}

.tour-option-button:hover:not(.selected):not(.disabled) {
  background: linear-gradient(135deg, rgba(26, 29, 37, 0.8) 0%, rgba(23, 26, 33, 0.8) 100%);
  border-color: rgba(58, 63, 73, 0.8);
  transform: translateX(2px);
}

.tour-option-button.disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.tour-option-button.disabled:hover {
  transform: none;
  background: linear-gradient(135deg, rgba(23, 26, 33, 0.6) 0%, rgba(17, 19, 25, 0.6) 100%);
  border-color: rgba(42, 47, 57, 0.5);
}

.tour-option-content {
  position: relative;
  z-index: 1;
}

.tour-option-title {
  font-weight: 600;
  margin-bottom: 6px;
  font-size: 17px;
  color: #f1f2f5;
  transition: color 300ms;
}

.tour-option-button.selected .tour-option-title {
  color: #ff6b6b;
  text-shadow: 0 0 10px rgba(255, 107, 107, 0.3);
}

.tour-option-description {
  font-size: 13px;
  opacity: 0.75;
  color: #b9bfca;
  line-height: 1.4;
}

.tour-option-button.selected .tour-option-description {
  color: rgba(255, 255, 255, 0.85);
  opacity: 1;
}

.disabled-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 3px 10px;
  background: rgba(156, 163, 175, 0.15);
  border: 1px solid rgba(156, 163, 175, 0.3);
  border-radius: 999px;
  font-size: 10px;
  color: #9ca3af;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Main Preview */
.main-preview-container {
  flex: 1;
  background: linear-gradient(135deg, rgba(11, 13, 16, 0.6) 0%, rgba(15, 15, 18, 0.6) 100%);
  border: 1px solid rgba(38, 42, 51, 0.5);
  border-radius: 20px;
  overflow: hidden;
  min-height: 600px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  animation: slideInRight 600ms cubic-bezier(0.4, 0, 0.2, 1) 200ms backwards;
}

.preview-image-container {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.preview-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  transition: transform 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.preview-image-container:hover .preview-image {
  transform: scale(1.02);
}

.preview-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0.6) 0%, rgba(0, 0, 0, 0.8) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 250ms ease;
}

.preview-image-container:hover .preview-overlay {
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0.75) 100%);
}

.start-tour-button {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 16px 32px;
  background: linear-gradient(135deg, #b02f34 0%, #d24449 100%);
  color: white;
  border: none;
  border-radius: 14px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(176, 47, 52, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.1) inset;
  transition: all 350ms cubic-bezier(0.4, 0, 0.2, 1);
  transform: scale(1);
  letter-spacing: -0.01em;
}

.start-tour-button:hover {
  background: linear-gradient(135deg, #c0353a 0%, #e04e53 100%);
  transform: translateY(-4px) scale(1.03);
  box-shadow: 0 12px 36px rgba(176, 47, 52, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.15) inset;
}

.start-tour-button:active {
  transform: translateY(-1px) scale(1.01);
  box-shadow: 0 6px 20px rgba(176, 47, 52, 0.4);
}

.start-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  font-size: 0.95rem;
  transition: all 350ms cubic-bezier(0.4, 0, 0.2, 1);
}

.start-tour-button:hover .start-icon {
  background: rgba(255, 255, 255, 0.3);
  transform: scale(1.1) translateX(2px);
}

/* Tour Modal Container - for GuardpotTour and AttackSurfaceTour */
.tour-modal-container {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #0f0f12;
  z-index: 1000;
  animation: modalBackdropFadeIn 250ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
  overflow: hidden;
}

/* Modal */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #0f0f12;
  z-index: 1000;
  animation: modalBackdropFadeIn 250ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
  overflow: hidden;
}

.modal-backdrop.closing {
  animation: modalBackdropFadeOut 250ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.modal-content {
  position: relative;
  width: 100%;
  height: 100%;
  background-color: #0b0d10;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  overflow: hidden;
  animation: modalContentSlideIn 300ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.modal-content.closing {
  animation: modalContentSlideOut 250ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.dashboard-modal {
  padding: 20px;
}

.modal-image-wrapper {
  position: relative;
  max-width: 95vw;
  max-height: calc(100vh - 100px);
  width: auto;
  height: auto;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-image {
  width: auto;
  height: auto;
  max-width: 95vw;
  max-height: calc(100vh - 100px);
  object-fit: contain;
  display: block;
}

/* Overlay System */
.overlay-top {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(0, 0, 0, 0.85);
  pointer-events: none;
  transition: all 500ms ease-in-out;
  opacity: 1;
}

.overlay-left {
  position: absolute;
  left: 0;
  background: rgba(0, 0, 0, 0.85);
  pointer-events: none;
  transition: all 500ms ease-in-out;
  opacity: 1;
}

.overlay-right {
  position: absolute;
  right: 0;
  background: rgba(0, 0, 0, 0.85);
  pointer-events: none;
  transition: all 500ms ease-in-out;
  opacity: 1;
}

.overlay-bottom {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.85);
  pointer-events: none;
  transition: all 500ms ease-in-out;
  opacity: 1;
}

.overlay-transitioning {
  opacity: 0.5;
}

/* Highlight Border */
.highlight-border {
  position: absolute;
  border: 2px solid #b02f34;
  border-radius: 10px;
  pointer-events: none;
  transition: all 500ms ease-in-out;
  box-shadow: 0 0 0 2px rgba(176, 47, 52, 0.3), 0 0 15px rgba(176, 47, 52, 0.2);
  opacity: 1;
  transform: scale(1);
}

.highlight-border.transitioning {
  opacity: 0.5;
  transform: scale(0.98);
}

/* Step Info Popup */
.step-info-popup {
  position: absolute;
  background-color: #111319;
  border: 1px solid #262a33;
  border-radius: 12px;
  padding: 20px;
  color: #f1f2f5;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(176, 47, 52, 0.3);
  min-width: 300px;
  max-width: 400px;
  animation: popupSlideIn 600ms ease-out forwards;
  transition: all 500ms ease-in-out;
}

.step-info-popup.transitioning {
  opacity: 0.3;
  transition: all 500ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.step-info-popup.transitioning.transition-next {
  transform: translateX(80px) scale(0.95);
}

.step-info-popup.transitioning.transition-prev {
  transform: translateX(-80px) scale(0.95);
}

.step-info-popup.closing {
  animation: popupSlideOut 250ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Popup Animated Border */
.popup-animated-border {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 12px;
  border: 2px solid transparent;
  background: linear-gradient(45deg, rgba(176, 47, 52, 0.3), rgba(176, 47, 52, 0.1));
  background-clip: border-box;
  animation: pulseGlow 2s infinite;
  transition: all 400ms ease-in-out;
}

.step-info-popup.transitioning .popup-animated-border {
  pointer-events: none;
}

/* Quit Button */
.quit-button {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 28px;
  height: 28px;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid #262a33;
  border-radius: 50%;
  color: #b9bfca;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: normal;
  line-height: 1;
  z-index: 20;
  transition: all 200ms ease;
}

.quit-button:hover {
  background: rgba(176, 47, 52, 0.8);
  color: white;
  transform: scale(1.1);
}

/* Popup Content */
.popup-content {
  position: relative;
  z-index: 10;
  transition: all 400ms ease-in-out;
}

.popup-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.step-counter {
  background-color: #b02f34;
  color: white;
  font-size: 12px;
  padding: 4px 8px;
  border-radius: 999px;
  font-weight: 600;
}

.popup-title {
  margin: 0;
  font-weight: 600;
  font-size: 1.1rem;
}

.popup-description {
  margin: 0 0 16px 0;
  color: #b9bfca;
  line-height: 1.5;
}

.popup-navigation {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.nav-button {
  padding: 8px 16px;
  border-radius: 8px;
  border: 1px solid #2a2f39;
  background-color: #171a21;
  color: #f1f2f5;
  cursor: pointer;
  font-size: 14px;
  transition: all 200ms ease;
}

.nav-button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.nav-button:hover:not(:disabled) {
  background-color: #1a1d25;
  border-color: #3a3f49;
}

.nav-button.primary {
  border-color: #8e262a;
  background-color: #b02f34;
  color: white;
}

.nav-button.primary:hover {
  background-color: #c0353a;
}

/* Progress Bar - Dashboard specific styles */
.dashboard-progress-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 8px;
  background-color: rgba(0, 0, 0, 0.3);
  display: flex;
  gap: 2px;
  z-index: 1002;
  backdrop-filter: blur(10px);
  animation: progressBarFadeIn 250ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.dashboard-progress-bar.closing {
  animation: progressBarFadeOut 250ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.dashboard-progress-segment {
  flex: 1;
  position: relative;
  cursor: pointer;
  overflow: visible;
  transition: all 300ms cubic-bezier(0.4, 0, 0.2, 1);
  background-color: rgba(255, 255, 255, 0.05);
}

.dashboard-progress-segment:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.dashboard-progress-segment-fill {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: transparent;
  transform: scaleX(0);
  transform-origin: left;
  opacity: 0;
  transition: transform 400ms cubic-bezier(0.4, 0, 0.2, 1), opacity 250ms ease;
}

.dashboard-progress-segment.completed .dashboard-progress-segment-fill {
  background: linear-gradient(90deg, #8e262a 0%, #b02f34 100%);
  transform: scaleX(1);
  opacity: 1;
}

.dashboard-progress-segment.active .dashboard-progress-segment-fill {
  background: linear-gradient(90deg, #b02f34 0%, #d24449 100%);
  transform: scaleX(1);
  opacity: 1;
  animation: progressFillPulse 2s infinite;
}

.dashboard-progress-step-number {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: #1a1d25;
  border: 2px solid #262a33;
  color: #6b7280;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 600;
  transition: all 250ms cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 1003;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.dashboard-progress-segment:hover .dashboard-progress-step-number {
  transform: translateX(-50%) scale(1.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.dashboard-progress-step-number.completed {
  background-color: #8e262a;
  border-color: #b02f34;
  color: #f1f2f5;
  box-shadow: 0 2px 8px rgba(176, 47, 52, 0.3);
}

.dashboard-progress-step-number.active {
  background: linear-gradient(135deg, #b02f34 0%, #d24449 100%);
  border-color: #d24449;
  color: white;
  box-shadow: 0 4px 16px rgba(176, 47, 52, 0.6);
  animation: stepNumberPulse 2s infinite;
}

/* Animations */
@keyframes containerFadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes progressFillPulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.85;
  }
}

@keyframes progressBarFadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes progressBarFadeOut {
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(20px);
  }
}

@keyframes stepNumberPulse {
  0%, 100% {
    transform: translateX(-50%) scale(1);
    box-shadow: 0 4px 16px rgba(176, 47, 52, 0.6);
  }
  50% {
    transform: translateX(-50%) scale(1.05);
    box-shadow: 0 6px 20px rgba(176, 47, 52, 0.8);
  }
}

@keyframes pulseGlow {
  0% { box-shadow: 0 0 0 0 rgba(176, 47, 52, 0.4); }
  50% { box-shadow: 0 0 8px 4px rgba(176, 47, 52, 0.6); }
  100% { box-shadow: 0 0 0 0 rgba(176, 47, 52, 0.4); }
}

@keyframes modalBackdropFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes modalBackdropFadeOut {
  from { opacity: 1; }
  to { opacity: 0; }
}

@keyframes modalContentSlideIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes modalContentSlideOut {
  from {
    opacity: 1;
    transform: scale(1);
  }
  to {
    opacity: 0;
    transform: scale(0.95);
  }
}

@keyframes popupSlideIn {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes popupSlideOut {
  from {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  to {
    opacity: 0;
    transform: translateY(20px) scale(0.9);
  }
}

/* Responsive Design */
@media (max-width: 1200px) {
  .dashboard-tour-container {
    gap: 24px;
    padding: 24px;
  }

  .tour-selection-menu {
    width: 300px;
  }
}

@media (max-width: 1024px) {
  .dashboard-tour-container {
    flex-direction: column;
    gap: 20px;
  }
  
  .tour-selection-menu {
    width: 100%;
  }
  
  .main-preview-container {
    min-height: 500px;
  }
}

@media (max-width: 768px) {
  .dashboard-tour-container {
    padding: 20px;
    gap: 16px;
    border-radius: 16px;
  }
  
  .tour-selection-menu {
    padding: 20px;
    border-radius: 16px;
  }

  .tour-selection-title {
    font-size: 1.3rem;
  }
  
  .tour-option-button {
    padding: 16px 20px;
  }

  .tour-option-title {
    font-size: 16px;
  }

  .tour-option-description {
    font-size: 12px;
  }
  
  .start-tour-button {
    padding: 14px 28px;
    font-size: 1rem;
  }

  .start-icon {
    width: 26px;
    height: 26px;
    font-size: 0.9rem;
  }
  
  .step-info-popup {
    min-width: 280px;
    max-width: 320px;
    padding: 16px;
  }
}

@media (max-width: 480px) {
  .dashboard-tour-container {
    padding: 16px;
  }

  .tour-selection-title {
    font-size: 1.2rem;
  }

  .start-tour-button {
    padding: 13px 26px;
    font-size: 0.95rem;
    gap: 10px;
  }

  .start-icon {
    width: 24px;
    height: 24px;
    font-size: 0.85rem;
  }
}
