/**
 * Journey Map Styling
 * Styles for the interactive compliance journey map
 */

.journey-map-container {
  position: relative;
  min-height: 400px;
  width: 100%;
  overflow-x: auto;
  padding: 20px 0;
}

.journey-map {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  min-width: 600px;
  margin: 0 auto;
  position: relative;
}

/* Progress line */
.journey-map::after {
  content: '';
  position: absolute;
  top: 40px;
  left: 70px;
  right: 70px;
  height: 4px;
  background-color: #e9ecef;
  z-index: 1;
}

/* Completed progress line */
.journey-map .progress-line {
  position: absolute;
  top: 40px;
  left: 70px;
  height: 4px;
  background-color: #28a745;
  z-index: 2;
  transition: width 0.5s ease-in-out;
}

/* Stage styling */
.journey-stage {
  flex: 1;
  padding: 0 15px;
  position: relative;
  z-index: 3;
  min-width: 180px;
}

.journey-stage-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background-color: #f8f9fa;
  border: 3px solid #e9ecef;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 15px;
  position: relative;
  transition: all 0.3s ease;
}

.journey-stage-icon i {
  font-size: 24px;
  color: #6c757d;
  transition: all 0.3s ease;
}

/* Current stage */
.journey-stage.current .journey-stage-icon {
  border-color: #007bff;
  background-color: #e7f1ff;
  box-shadow: 0 0 0 4px rgba(0, 123, 255, 0.2);
}

.journey-stage.current .journey-stage-icon i {
  color: #007bff;
}

/* Completed stage */
.journey-stage.completed .journey-stage-icon {
  border-color: #28a745;
  background-color: #e9f6e9;
}

.journey-stage.completed .journey-stage-icon i {
  color: #28a745;
}

/* Stage header */
.journey-stage-header {
  text-align: center;
  margin-bottom: 15px;
}

.journey-stage-title {
  font-weight: 600;
  margin: 0 0 5px;
}

.journey-stage-description {
  font-size: 0.85rem;
  color: #6c757d;
  margin: 0;
}

/* Tasks list */
.journey-tasks {
  margin: 20px 0;
  padding: 0;
  list-style: none;
}

.journey-task {
  display: flex;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #f1f1f1;
}

.journey-task:last-child {
  border-bottom: none;
}

.journey-task-checkbox {
  margin-right: 10px;
  flex-shrink: 0;
}

.journey-task-checkbox input[type="checkbox"] {
  cursor: pointer;
}

.journey-task-label {
  font-size: 0.9rem;
  flex-grow: 1;
  margin: 0;
}

/* Task completion check icon */
.journey-task.completed .journey-task-label {
  text-decoration: line-through;
  color: #6c757d;
}

/* Stage actions */
.journey-stage-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.journey-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  font-size: 0.85rem;
  border-radius: 4px;
  transition: all 0.2s ease;
  border: 1px solid #dee2e6;
  background-color: #f8f9fa;
  color: #495057;
  text-decoration: none;
  cursor: pointer;
}

.journey-action-btn:hover {
  background-color: #e9ecef;
}

.journey-action-btn.primary {
  background-color: #007bff;
  border-color: #007bff;
  color: #fff;
}

.journey-action-btn.primary:hover {
  background-color: #0069d9;
  border-color: #0062cc;
}

.journey-action-btn i {
  margin-right: 5px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .journey-map-container {
    overflow-x: auto;
  }
  
  .journey-map {
    min-width: 800px;
  }
}

/* Zoom controls */
.journey-zoom-controls {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 10;
  display: flex;
  gap: 5px;
}

.journey-zoom-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #fff;
  border: 1px solid #dee2e6;
  cursor: pointer;
  transition: all 0.2s ease;
}

.journey-zoom-btn:hover {
  background-color: #f8f9fa;
}

/* Animations */
@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(0, 123, 255, 0.5);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(0, 123, 255, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(0, 123, 255, 0);
  }
}

.journey-stage.current .journey-stage-icon {
  animation: pulse 2s infinite;
}

/* Fade in animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.journey-map {
  animation: fadeIn 0.5s ease-out;
}

.journey-stage {
  opacity: 0;
  animation: fadeIn 0.5s ease-out forwards;
}

.journey-stage:nth-child(1) {
  animation-delay: 0.1s;
}

.journey-stage:nth-child(2) {
  animation-delay: 0.2s;
}

.journey-stage:nth-child(3) {
  animation-delay: 0.3s;
}

.journey-stage:nth-child(4) {
  animation-delay: 0.4s;
}

/* Hover effects */
.journey-stage:hover .journey-stage-icon {
  transform: scale(1.05);
}

.journey-task:hover {
  background-color: #f8f9fa;
}

/* Print styles */
@media print {
  .journey-map-container {
    overflow: visible;
  }
  
  .journey-map {
    min-width: 100%;
  }
  
  .journey-stage-actions {
    display: none;
  }
}