/* CSS Custom Properties for Scenario Theming */
:root {
  --scenario-bg-dark: rgba(15, 12, 25, 0.98);
  --scenario-bg-dark-end: rgba(30, 20, 50, 0.98);
  --scenario-primary: #6E20F4;
  --scenario-primary-light: #9B59F6;
  --scenario-primary-lighter: #D2B8FF;
  --scenario-premium-gold: #FFD700;
  --scenario-alert-red: #FF4757;
  --scenario-success: #10B981;
}

/* Scenario Container - Carousel Layout */
.scenario-container {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--scenario-bg-dark) 0%, var(--scenario-bg-dark-end) 100%);
  backdrop-filter: blur(12px);
  z-index: 1100;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 2rem 1rem;
  gap: 2rem;
  overflow-y: auto;
  overflow-x: hidden;
}

.scenario-container.active {
  display: flex !important;
}

/* Carousel Wrapper */
.scenario-carousel-wrapper {
  position: relative;
  width: 100%;
  max-width: 520px;
  max-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  padding: 0 80px;
}

/* Carousel Track */
.scenario-carousel-track {
  display: flex;
  width: 100%;
  height: auto;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  align-items: center;
  gap: 1.5rem;
}

/* Scenario Cards - Enhanced Design */
.scenario-card {
  background: linear-gradient(145deg, #ffffff 0%, #f8f5ff 100%);
  border: 2px solid transparent;
  border-radius: 24px;
  padding: 1.5rem;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  box-shadow: 0 8px 32px rgba(110, 32, 244, 0.15), 0 2px 8px rgba(0, 0, 0, 0.05);
  position: relative;
  flex: 0 0 calc(100% - 1.5rem);
  height: auto;
  min-height: 460px;
  max-height: 560px;
  justify-content: flex-start;
  align-items: stretch;
  overflow-y: auto;
  background-image: linear-gradient(145deg, #ffffff 0%, #f8f5ff 100%), 
                    linear-gradient(90deg, #6E20F4 0%, #9B59F6 50%, #D2B8FF 100%);
  background-origin: border-box;
  background-clip: padding-box, border-box;
}

.scenario-card:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 16px 48px rgba(110, 32, 244, 0.25), 0 4px 16px rgba(0, 0, 0, 0.1);
}

.scenario-card.selected {
  border-color: #6E20F4;
  background: linear-gradient(145deg, #f0e6ff 0%, #fff5ff 100%);
  box-shadow: 0 16px 48px rgba(110, 32, 244, 0.35);
  transform: scale(1.03);
}

/* Card Badges */
.scenario-card-badges {
  display: flex;
  gap: 0.5rem;
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 5;
}

.scenario-badge-premium {
  background: linear-gradient(90deg, #FFD700 0%, #FFA500 100%);
  color: #1a1a1a;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 0.3rem 0.6rem;
  border-radius: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 8px rgba(255, 215, 0, 0.4);
}

.scenario-badge-alert {
  background: linear-gradient(90deg, #FF4757 0%, #FF6B81 100%);
  color: white;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 0.3rem 0.6rem;
  border-radius: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  animation: pulse-alert 2s infinite;
  box-shadow: 0 2px 8px rgba(255, 71, 87, 0.4);
}

@keyframes pulse-alert {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

/* Card Icon */
.scenario-card-icon {
  font-size: 3rem;
  text-align: center;
  margin: 0.5rem 0;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
}

.scenario-card-header {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  text-align: center;
}

.scenario-title {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  background: linear-gradient(90.9deg, #6E20F4 2.74%, #9B59F6 102.92%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.3;
}

.scenario-description {
  margin: 0;
  color: #444;
  font-size: 0.95rem;
  line-height: 1.6;
  text-align: center;
  flex-grow: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Goal Section in Card */
.scenario-goal {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  background: linear-gradient(90deg, rgba(110, 32, 244, 0.08) 0%, rgba(155, 89, 246, 0.05) 100%);
  border-radius: 12px;
  margin: 0.25rem 0;
}

.scenario-goal .goal-icon {
  font-size: 1.1rem;
}

.scenario-goal .goal-text {
  font-size: 0.9rem;
  color: #333;
  font-weight: 500;
}

/* Thresholds Preview */
.scenario-thresholds-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  padding: 0.5rem 0;
}

.threshold-item {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.75rem;
  color: #666;
  background: rgba(110, 32, 244, 0.05);
  padding: 0.25rem 0.5rem;
  border-radius: 8px;
}

.threshold-dot {
  width: 6px;
  height: 6px;
  background: #6E20F4;
  border-radius: 50%;
}

.threshold-more {
  font-size: 0.7rem;
  color: #999;
  font-style: italic;
}

/* Tone Section */
.scenario-tone {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 0;
  font-size: 0.85rem;
}

.tone-label {
  color: #888;
}

.tone-value {
  color: #6E20F4;
  font-weight: 600;
}

/* Select Button */
.scenario-select-btn {
  width: 100%;
  padding: 0.9rem 1.5rem;
  background: linear-gradient(90deg, #6E20F4 0%, #8240FF 100%);
  color: white;
  border: none;
  border-radius: 14px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: auto;
  box-shadow: 0 4px 16px rgba(110, 32, 244, 0.3);
}

.scenario-select-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(110, 32, 244, 0.4);
  background: linear-gradient(90deg, #7B2FF4 0%, #9150FF 100%);
}

.scenario-select-btn:active {
  transform: translateY(0);
}

.scenario-badge-selected {
  display: inline-block;
  background: linear-gradient(90.9deg, #10B981 2.74%, #34D399 102.92%);
  color: white;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.4rem 0.8rem;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.scenario-meta {
  display: flex;
  flex-direction: row;
  gap: 1.5rem;
  font-size: 0.95rem;
}

.scenario-meta-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.scenario-meta-item .labels {
  font-weight: 600;
  color: #6E20F4;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.scenario-meta-item .value {
  color: #333;
  font-size: 1rem;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.no-scenarios {
  text-align: center;
  color: #ccc;
  font-size: 1.1rem;
  padding: 2rem;
  grid-column: 1 / -1;
}

/* Carousel Navigation Arrows */
.scenario-carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  border: none;
  background: linear-gradient(135deg, #D2B8FF 0%, #8240FF 100%);
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 20;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(110, 32, 244, 0.2);
}

.scenario-carousel-arrow:hover {
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 6px 20px rgba(110, 32, 244, 0.3);
}

.scenario-carousel-arrow:active {
  transform: translateY(-50%) scale(0.95);
}

.scenario-carousel-arrow.prev {
  left: 10px;
}

.scenario-carousel-arrow.next {
  right: 10px;
}

.scenario-carousel-arrow:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.scenario-carousel-arrow:disabled:hover {
  transform: translateY(-50%);
  box-shadow: 0 4px 15px rgba(110, 32, 244, 0.2);
}

/* Carousel Dots Navigation */
.scenario-carousel-dots {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  align-items: center;
  padding: 0 1rem;
}

.scenario-carousel-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ddd;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.3s ease;
}

.scenario-carousel-dot:hover {
  background: #bbb;
  transform: scale(1.1);
}

.scenario-carousel-dot.active {
  background: #6E20F4;
  width: 32px;
  border-radius: 6px;
  box-shadow: 0 0 0 3px rgba(110, 32, 244, 0.15);
}

/* Swiper-specific adjustments to match design and avoid overlap/click-through */
.scenario-swiper,
.scenario-debug-swiper {
  width: 100%;
  max-width: 520px;
  position: relative;
  box-sizing: border-box;
  padding-bottom: 90px; /* Space for arrows and dots below the card */
}

.scenario-swiper .swiper-wrapper,
.scenario-debug-swiper .swiper-wrapper {
  align-items: center;
}

.scenario-swiper .swiper-slide,
.scenario-debug-swiper .swiper-slide {
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Style Swiper nav buttons to match existing arrows and ensure they sit above slides */
.scenario-swiper .swiper-button-prev,
.scenario-debug-swiper .swiper-button-prev,
.scenario-swiper .swiper-button-next,
.scenario-debug-swiper .swiper-button-next {
  position: absolute;
  top: auto;
  bottom: -70px;
  transform: none;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #8240FF 0%, #5A18E0 100%);
  color: white;
  font-size: 1.5rem;
  z-index: 1200;
  box-shadow: 0 4px 15px rgba(110, 32, 244, 0.2);
  cursor: pointer;
}

.scenario-swiper .swiper-button-prev,
.scenario-debug-swiper .swiper-button-prev {
  left: calc(50% - 100px);
}

.scenario-swiper .swiper-button-next,
.scenario-debug-swiper .swiper-button-next {
  right: calc(50% - 100px);
}

/* Ensure nav buttons don't allow clicks to pass through */
.scenario-swiper .swiper-button-prev,
.scenario-swiper .swiper-button-next,
.scenario-debug-swiper .swiper-button-prev,
.scenario-debug-swiper .swiper-button-next {
  pointer-events: auto;
}

/* Pagination styling */
.scenario-swiper .swiper-pagination,
.scenario-debug-swiper .swiper-pagination {
  position: absolute;
  bottom: -40px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  z-index: 1200;
  pointer-events: auto;
}

/* Swiper pagination bullets (dots) */
.scenario-swiper .swiper-pagination-bullet,
.scenario-debug-swiper .swiper-pagination-bullet {
  width: 10px;
  height: 10px;
  background: #DCD6F7;
  opacity: 1;
  border-radius: 50%;
  margin: 0 6px !important;
  transition: all 0.25s ease;
  box-shadow: none;
}

.scenario-swiper .swiper-pagination-bullet-active,
.scenario-debug-swiper .swiper-pagination-bullet-active {
  background: #6E20F4; /* purple */
  width: 18px;
  height: 10px;
  border-radius: 6px;
  box-shadow: 0 0 0 3px rgba(110, 32, 244, 0.12);
}

/* Arrow chevrons */
.scenario-swiper .swiper-button-prev::after,
.scenario-debug-swiper .swiper-button-prev::after {
  content: '\2039';
  font-size: 22px;
  color: #fff;
}

.scenario-swiper .swiper-button-next::after,
.scenario-debug-swiper .swiper-button-next::after {
  content: '\203A';
  font-size: 22px;
  color: #fff;
}

/* Make sure slides and card area remain clickable but nav sits above */
.scenario-swiper .swiper-slide .scenario-card,
.scenario-debug-swiper .swiper-slide .scenario-card {
  pointer-events: auto;
}


/* Loading Spinner */
.scenario-loading-container {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  gap: 1.5rem;
  padding: 3rem 1.5rem;
  position: relative;
  z-index: 1100;
}

.scenario-spinner {
  display: inline-block;
  width: 48px;
  height: 48px;
  border: 4px solid #e9ecef;
  border-top-color: #6E20F4;
  border-radius: 50%;
  animation: scenario-spin 1s linear infinite;
  box-shadow: 0 0 0 2px rgba(110, 32, 244, 0.1);
}

@keyframes scenario-spin {
  to {
    transform: rotate(360deg);
  }
}

.scenario-loading-text {
  text-align: center;
  color: #666;
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0.3px;
}

.scenario-loading-text .dot {
  display: inline-block;
  animation: scenario-dot 1.5s infinite;
}

.scenario-loading-text .dot:nth-child(2) {
  animation-delay: 0.2s;
}

.scenario-loading-text .dot:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes scenario-dot {
  0%, 20%, 50%, 80%, 100% {
    opacity: 0.3;
  }
  40% {
    opacity: 1;
  }
}

/* Selected Scenario Display in Chat */
.selected-scenario-display {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.5rem;
  background: linear-gradient(135deg, #f8f9fa 0%, #fff 100%);
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  margin: auto;
  margin-bottom: 2rem;
  font-size: 0.9rem;
  animation: slideInDown 0.3s ease;
  max-width: 600px;
  text-align: start;
}

.selected-scenario-display .badge {
  background-color: transparent;
  color: #007bff;
  padding: 0;
  border-radius: 0;
  font-size: 0.75rem;
  font-weight: 700;
  white-space: nowrap;
  flex-shrink: 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 2px;
}

.selected-scenario-display .scenario-info {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  flex-grow: 1;
  width: 100%;
}

/* Scenario Header with Title and Meta */
.selected-scenario-display .scenario-header {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.selected-scenario-display .scenario-name {
  font-weight: 700;
  color: var(--bs-indigo);
  font-size: 1.1rem;
  line-height: 1.3;
  margin: 0;
}

.selected-scenario-display .scenario-meta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.85rem;
}

.selected-scenario-display .scenario-meta-item {
  display: flex;
  flex-direction: column;
  gap: unset;
  color: #666;
}

.selected-scenario-display .scenario-meta-item strong {
  color: #333;
  font-weight: 600;
}

/* Scenario Description */
.selected-scenario-display .scenario-description {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.selected-scenario-display .scenario-description p {
  margin: 0;
  color: #555;
  font-size: 0.9rem;
  line-height: 1.5;
  text-align: justify;
}

/* Scenario Prompt/Instructions */
.selected-scenario-display .scenario-prompt {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1rem;
  background: rgba(110, 32, 244, 0.05);
  border-radius: 6px;
  border-left: 3px solid #6E20F4;
}

.selected-scenario-display .scenario-prompt strong {
  color: #333;
  font-weight: 600;
  font-size: 0.9rem;
}

.selected-scenario-display .scenario-prompt p {
  margin: 0;
  color: #555;
  font-size: 0.85rem;
  line-height: 1.5;
  white-space: pre-wrap;
  word-wrap: break-word;
}

.selected-scenario-display .scenario-details {
  font-size: 0.8rem;
  color: #888;
  line-height: 1.4;
}

/* Enhanced Selected Scenario Header */
.selected-scenario-display .scenario-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.selected-scenario-display .scenario-icon {
  font-size: 1.5rem;
}

.selected-scenario-display .badge-alert-small {
  background: linear-gradient(90deg, #FF4757 0%, #FF6B81 100%);
  color: white;
  font-size: 0.6rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 8px;
  text-transform: uppercase;
  animation: pulse-alert 2s infinite;
}

/* Goal Section in Selected Scenario */
.selected-scenario-goal {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  background: linear-gradient(90deg, rgba(110, 32, 244, 0.1) 0%, rgba(155, 89, 246, 0.05) 100%);
  border-radius: 10px;
  border-left: 3px solid #6E20F4;
}

.selected-scenario-goal .goal-icon {
  font-size: 1.1rem;
}

.selected-scenario-goal .goal-label {
  font-weight: 600;
  color: #6E20F4;
  font-size: 0.8rem;
  text-transform: uppercase;
}

.selected-scenario-goal .goal-text {
  font-size: 0.9rem;
  color: #333;
  font-weight: 500;
}

/* Scenario Situation */
.scenario-situation {
  padding: 0.75rem 1rem;
  background: #f8f9fa;
  border-radius: 10px;
  font-size: 0.9rem;
}

.scenario-situation strong {
  color: #333;
  display: block;
  margin-bottom: 0.5rem;
}

.scenario-situation p {
  margin: 0;
  color: #555;
  font-style: italic;
  line-height: 1.5;
}

/* Progress Bar Container */
.scenario-progress-container {
  padding: 0.75rem 0;
}

.progress-bar-wrapper {
  width: 100%;
  height: 8px;
  background: #e0e0e0;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 0.75rem;
}

.progress-bar-wrapper .progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #6E20F4 0%, #9B59F6 50%, #D2B8FF 100%);
  border-radius: 4px;
  transition: width 0.5s ease;
}

.progress-thresholds {
  display: flex;
  justify-content: space-between;
  position: relative;
}

.progress-threshold {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  flex: 1;
}

.threshold-marker {
  width: 12px;
  height: 12px;
  background: #ddd;
  border-radius: 50%;
  border: 2px solid #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.progress-threshold.achieved .threshold-marker {
  background: linear-gradient(135deg, #6E20F4 0%, #9B59F6 100%);
  box-shadow: 0 2px 8px rgba(110, 32, 244, 0.4);
}

.threshold-label {
  font-size: 0.65rem;
  color: #888;
  text-align: center;
  max-width: 60px;
  line-height: 1.2;
}

.progress-threshold.achieved .threshold-label {
  color: #6E20F4;
  font-weight: 600;
}

/* Goal Achieved Display */
.goal-achieved-display {
  margin: 1rem auto;
  max-width: 500px;
  animation: bounceIn 0.6s ease;
}

.goal-achieved-content {
  padding: 2rem;
  background: linear-gradient(145deg, #f0e6ff 0%, #fff5ff 100%);
  border-radius: 16px;
  text-align: center;
  border: 2px solid #6E20F4;
  box-shadow: 0 8px 32px rgba(110, 32, 244, 0.2);
}

.goal-achieved-icon {
  font-size: 3rem;
  margin-bottom: 0.5rem;
}

.goal-achieved-title {
  font-size: 1.5rem;
  font-weight: 700;
  background: linear-gradient(90deg, #6E20F4 0%, #9B59F6 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 0 0 1rem 0;
}

.final-quote {
  font-style: italic;
  color: #555;
  padding: 1rem;
  margin: 1rem 0;
  border-left: 3px solid #6E20F4;
  background: rgba(110, 32, 244, 0.05);
  border-radius: 0 8px 8px 0;
  font-size: 1rem;
  line-height: 1.6;
}

.goal-achieved-message {
  color: #666;
  font-size: 0.9rem;
  margin: 0;
}

@keyframes bounceIn {
  0% {
    opacity: 0;
    transform: scale(0.8);
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes slideInDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive adjustments */
@media (max-width: 1200px) {
  .scenario-carousel-wrapper {
    padding: 0 70px;
  }
}

@media (max-width: 768px) {
  .scenario-container {
    padding: 1rem 0;
  }

  .scenario-carousel-wrapper {
    max-width: 90%;
    max-height: 550px;
    padding: 0 60px;
  }

  .scenario-card {
    padding: 1.5rem;
    min-height: 400px;
    max-height: 480px;
  }

  .scenario-title {
    font-size: 1.25rem;
  }

  .scenario-description {
    font-size: 0.95rem;
    -webkit-line-clamp: 2;
    line-clamp: 2;
  }

  .scenario-carousel-arrow {
    width: 44px;
    height: 44px;
    font-size: 1.25rem;
  }

  .scenario-carousel-arrow.prev {
    left: 8px;
  }

  .scenario-carousel-arrow.next {
    right: 8px;
  }
}

@media (max-width: 480px) {
  .scenario-container {
    padding: 0.5rem 0;
  }

  .scenario-carousel-wrapper {
    max-width: 95%;
    max-height: 500px;
    padding: 0 50px;
  }

  .scenario-card {
    padding: 1rem;
    min-height: 380px;
    max-height: 450px;
    border-radius: 16px;
  }

  .scenario-title {
    font-size: 1.1rem;
  }

  .scenario-description {
    font-size: 0.9rem;
    -webkit-line-clamp: 2;
    line-clamp: 2;
  }

  .scenario-meta {
    gap: 1rem;
    font-size: 0.85rem;
  }

  .scenario-carousel-arrow {
    width: 40px;
    height: 40px;
    font-size: 1rem;
  }

  .scenario-carousel-arrow.prev {
    left: 5px;
  }

  .scenario-carousel-arrow.next {
    right: 5px;
  }

  .scenario-carousel-dots {
    gap: 0.5rem;
  }

  .scenario-carousel-dot {
    width: 10px;
    height: 10px;
  }

  .scenario-carousel-dot.active {
    width: 28px;
  }
}

/* ============================================
   Milestone Notification Toast
   ============================================ */
.milestone-notification {
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%) translateY(-20px);
  opacity: 0;
  z-index: 10000;
  pointer-events: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.milestone-notification.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.milestone-content {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 1.5rem;
  background: linear-gradient(135deg, #6E20F4 0%, #9B59F6 100%);
  border-radius: 50px;
  box-shadow: 0 8px 32px rgba(110, 32, 244, 0.4), 0 4px 16px rgba(0, 0, 0, 0.2);
  color: white;
  font-size: 0.95rem;
  white-space: nowrap;
}

.milestone-icon {
  font-size: 1.25rem;
  animation: milestoneIconPop 0.5s ease-out;
}

.milestone-text {
  font-weight: 500;
}

.milestone-text strong {
  color: #FFD700;
  font-weight: 700;
}

@keyframes milestoneIconPop {
  0% {
    transform: scale(0);
  }
  50% {
    transform: scale(1.3);
  }
  100% {
    transform: scale(1);
  }
}

/* Progress bar pulse animation when updating */
.scenario-progress-container .progress-bar.updating {
  animation: progressPulse 0.5s ease-out;
}

@keyframes progressPulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(110, 32, 244, 0.5);
  }
  50% {
    box-shadow: 0 0 12px 4px rgba(110, 32, 244, 0.5);
  }
}

/* Threshold achieved celebration */
.progress-threshold.just-achieved .threshold-marker {
  animation: thresholdCelebrate 0.6s ease-out;
}

@keyframes thresholdCelebrate {
  0% {
    transform: scale(1);
  }
  25% {
    transform: scale(1.5);
    background: #FFD700;
  }
  50% {
    transform: scale(1.3);
  }
  100% {
    transform: scale(1);
    background: #FFD700;
  }
}