/* --- Life Changes Page Styles --- */

/* Theme: Transformation Violet */
.page-title-area.theme-violet {
  text-align: left;
  margin-bottom: 3rem;
}
.page-title-area.theme-violet .page-title-text {
  color: #7c3aed; /* Violet-600 */
}
.page-title-area.theme-violet .title-underline {
  background: #a78bfa; /* Violet-400 */
}

.header-violet {
  border-left-color: #7c3aed;
  color: #4c1d95;
}

.num-violet {
  color: #8b5cf6;
}

.highlight-box-violet {
  background: #f5f3ff; /* Violet-50 */
  border-left: 5px solid #8b5cf6;
  padding: 2rem;
  margin: 2rem 0;
  border-radius: 0 12px 12px 0;
  color: #5b21b6;
  font-weight: bold;
}

/* Sidebar Advice */
.advice-violet {
  background: #fdf4ff; /* Light Pink/Violet mix */
  border: 2px solid #e879f9;
}
.advice-highlight-violet {
  background: linear-gradient(
    120deg,
    rgba(232, 121, 249, 0) 0%,
    rgba(232, 121, 249, 0.2) 100%
  );
  box-shadow: inset 0 -0.5em 0 rgba(232, 121, 249, 0.3);
}

/* Quote Style: Domino vertical list feel */
.quote-style-domino {
  background-image:
    repeating-linear-gradient(
      45deg,
      rgba(124, 58, 237, 0.05) 0px,
      rgba(124, 58, 237, 0.05) 1px,
      transparent 1px,
      transparent 6px
    ),
    linear-gradient(135deg, #f5f3ff 0%, #ede9fe 100%);
  border-left-color: #7c3aed; /* Violet-600 */
  box-shadow: 0 10px 30px -5px rgba(124, 58, 237, 0.15);
  margin-bottom: 5rem;
}

.quote-style-domino .quote-text-vertical p {
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
  color: #1e293b;
  border-left: 3px solid #ddd6fe;
  padding-left: 1rem;
  transition: all 0.3s ease;
  
  /* Initial State for Animation */
  opacity: 0;
  transform: translateX(-20px);
}

/* Animation triggered when parent (.quote-style-domino) gets .active class */
.quote-style-domino.active .quote-text-vertical p {
  opacity: 1;
  transform: translateX(0);
  transition: opacity 1.2s ease, transform 1.2s ease;
}

/* Staggered Delay - Slower Pacing */
.quote-style-domino.active .quote-text-vertical p:nth-child(1) { transition-delay: 0.8s; }
.quote-style-domino.active .quote-text-vertical p:nth-child(2) { transition-delay: 1.9s; }
.quote-style-domino.active .quote-text-vertical p:nth-child(3) { transition-delay: 3.0s; }
.quote-style-domino.active .quote-text-vertical p:nth-child(4) { transition-delay: 4.1s; }
.quote-style-domino.active .quote-text-vertical p:nth-child(5) { transition-delay: 5.2s; }
.quote-style-domino.active .quote-text-vertical p:nth-child(6) { transition-delay: 6.3s; }

.quote-style-domino .quote-text-vertical p:hover {
  border-left-color: #7c3aed;
  transform: translateX(5px) !important; /* Keep hover effect working even after animation */
  /* Note: adding !important to override the specific transform(0) from active state if needed, 
     but simpler is to rely on cascade. Let's make sure hover wins if active. */
}
/* Refined hover to work with animation state */
.quote-style-domino.active .quote-text-vertical p:hover {
    transform: translateX(5px);
}

.quote-style-domino .highlight {
  font-weight: bold;
  color: #6d28d9;
  font-size: 1.2rem;
}

/* Contrast List */
.contrast-list {
  display: flex;
  justify-content: space-around;
  align-items: center;
  list-style: none;
  padding: 0;
  margin: 2rem 0;
  flex-wrap: wrap;
  gap: 1rem;
}
.contrast-list li {
  padding: 1.5rem;
  border-radius: 12px;
  text-align: center;
  flex: 1;
  min-width: 200px;
}
.negative-item {
  background: #f1f5f9;
  color: #64748b;
  border: 1px solid #cbd5e1;
}
.positive-item {
  background: #fffbeb;
  color: #b45309;
  border: 1px solid #fcd34d;
  box-shadow: 0 4px 6px rgba(251, 191, 36, 0.2);
}
.arrow-item {
  flex: 0 0 auto;
  font-size: 1.5rem;
  color: #94a3b8;
  background: none !important;
  border: none !important;
  min-width: auto;
}

/* --- Domino Animation --- */
.domino-stage {
  background: #f8fafc;
  padding: 3rem 1rem;
  border-radius: 16px;
  margin: 2rem 0;
  text-align: center;
  perspective: 1000px; /* Essential for 3D fall */
  overflow: hidden;
  cursor: pointer;
  border: 1px solid #e2e8f0;
}

.domino-container {
  display: flex;
  justify-content: center;
  gap: 10px;
  align-items: flex-end;
  height: 150px;
  margin-bottom: 2rem;
  /* Angle view */
  transform-style: preserve-3d;
  transform: rotateY(-10deg) rotateX(10deg);
}

.domino {
  width: 60px;
  height: 100px;
  background: #7c3aed;
  color: white;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 1rem;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.3);
  transform-origin: bottom center;
  transition: transform 0.5s ease-in;
  position: relative;
  user-select: none;
}
/* Side thickness illusion */
.domino::after {
  content: "";
  position: absolute;
  right: -5px;
  top: 0;
  width: 5px;
  height: 100%;
  background: #5b21b6;
  transform: skewY(45deg);
  transform-origin: left;
}

/* Falling State handled by JS adding .falling class to individual dominos */
/* But we might have stage-based overrides if any */

/* Special Last Domino */
.domino.last {
  background: #10b981;
  transition: transform 1s cubic-bezier(0.175, 0.885, 0.32, 1.275); /* Bounce effect */
}
.domino.last::after {
  background: #047857;
}

.domino.last.falling {
  /* Instead of falling, it jumps up or opens */
  transform: scale(1.5) rotateX(0deg) translateY(-20px);
  background: radial-gradient(circle, #fbbf24, #f59e0b);
  box-shadow: 0 0 30px rgba(245, 158, 11, 0.6);
  z-index: 10;
}
.domino.last .content-back {
  display: none;
}
.domino.last.falling .content-front {
  content: "";
}

.domino-message {
  color: #64748b;
  font-size: 0.9rem;
  min-height: 1.5rem;
  transition: color 0.3s;
}
.domino-message.complete {
  color: #7c3aed;
  font-weight: bold;
  font-size: 1.1rem;
}

/* --- Ripple Effect --- */
.ripple-visual {
  position: relative;
  height: 300px;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 2rem 0;
  background: #f0f9ff;
  border-radius: 50%;
  overflow: hidden;
}

.ripple-core {
  width: 60px;
  height: 60px;
  background: #f43f5e;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  color: white;
  font-size: 1.5rem;
  z-index: 10;
  box-shadow: 0 0 15px rgba(244, 63, 94, 0.5);
  animation: pulse-core 2s infinite;
}

@keyframes pulse-core {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
  100% {
    transform: scale(1);
  }
}

.ripple {
  position: absolute;
  border-radius: 50%;
  border: 2px solid rgba(244, 63, 94, 0.3);
  background: rgba(244, 63, 94, 0.05);
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding-top: 10px;
  font-size: 0.8rem;
  color: #be123c;
  font-weight: bold;
  opacity: 0;
  animation: ripple-spread 4s infinite linear;
}

.ripple.r1 {
  width: 100px;
  height: 100px;
  animation-delay: 0s;
}
.ripple.r2 {
  width: 160px;
  height: 160px;
  animation-delay: 1s;
}
.ripple.r3 {
  width: 220px;
  height: 220px;
  animation-delay: 2s;
}
.ripple.r4 {
  width: 280px;
  height: 280px;
  animation-delay: 3s;
}

@keyframes ripple-spread {
  0% {
    transform: scale(0.5);
    opacity: 0;
  }
  20% {
    opacity: 1;
  }
  80% {
    opacity: 0;
  }
  100% {
    transform: scale(1.5);
    opacity: 0;
  }
}

/* Conclusion Box Theme Override */
.theme-violet-box {
  border-color: #a78bfa;
  background: #f5f3ff;
}

/* --- Domino Reset Button --- */
.domino-reset-btn {
  background: #fff;
  border: 1px solid #a78bfa;
  color: #7c3aed;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.85rem;
  cursor: pointer;
  margin-left: 1rem;
  transition: all 0.3s;
}
.domino-reset-btn:hover {
  background: #a78bfa;
  color: white;
}

/* Falling State - Restored */
.domino.falling {
  transform: rotateX(70deg); /* Fall flat */
  background: #a78bfa; /* Lighter when down */
}
