.section8 {
  max-width: 1100px;
  margin: 0 auto;
}

.section8-container-wrapper {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  margin-bottom: 2em;
  transition: all 0.8s ease-out;
}

.section8-h1 {
  background: linear-gradient(135deg, #FF6680 5%, #FF4DA9 45%, #CD42D7 85%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  font-size: 4.5em;
  font-family: Inconsolata, sans-serif;
  font-weight: 700;
  transition: all 0.8s ease-out;
}

.section8-container-wrapper-inner {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.section8-content {
  max-width: 300px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-right: 20px;
  transition: all 0.6s ease-out;
}

.section8-content:hover {
  transform: translateY(-5px);
}

.section8-span {
  font-size: 5em;
  color: #dad1e6;
  font-family: Inconsolata, sans-serif;
  font-weight: 700;
  transition: all 0.3s ease;
}

.section8-content:hover .section8-span {
  background: linear-gradient(135deg, #FF6680 5%, #FF4DA9 45%, #CD42D7 85%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.section8-content-h1 {
  color: #dad1e6;
  font-size: 2.25em;
  font-family: Inconsolata, sans-serif;
  font-weight: 700;
  transition: color 0.3s ease;
}

.section8-content:hover .section8-content-h1 {
  color: #FF4DA9;
}

.section8-p {
  color: #dad1e6;
  font-size: 1.8em;
  font-family: 'Fira Sans', sans-serif;
  max-width: 280px;
  text-align: center;
  transition: color 0.3s ease;
}

.section8-content:hover .section8-p {
  color: #e8e0f0;
}

.section8-end-content {
  color: #dad1e6;
  font-size: 1.8em;
  font-family: 'Fira Sans', sans-serif;
  max-width: 580px;
  transition: all 0.8s ease-out;
}

.section8-image {
  width: 400px;
  height: 550px;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  margin-top: 20px;
  background: linear-gradient(45deg, #FF6680, #FF4DA9, #CD42D7);
  background-size: cover;
  transition: all 0.8s ease-out;
}

.section8-image:hover {
  transform: scale(1.02);
  box-shadow: 0 8px 25px rgba(255, 77, 169, 0.3);
}

.section8-content-wrapper-main {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: start;
  margin-top: 2em;
  margin-bottom: 2em;
  margin-left: 5em;
}

/* Scroll Animation States */
.section8-container-wrapper.fade-hidden {
  opacity: 0;
  transform: translateY(50px);
}

.section8-h1.fade-hidden {
  opacity: 0;
  transform: translateY(-30px);
}

.section8-content.fade-hidden {
  opacity: 0;
  transform: translateY(40px) scale(0.9);
}

.section8-end-content.fade-hidden {
  opacity: 0;
  transform: translateX(-30px);
}

.section8-image.fade-hidden {
  opacity: 0;
  transform: scale(0.8);
}

.section8-span.fade-hidden {
  opacity: 0;
  transform: scale(0.7);
}

/* Visible states */
.section8-container-wrapper.fade-in {
  opacity: 1;
  transform: translateY(0);
}

.section8-h1.fade-in {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.2s;
}

.section8-content.fade-in {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.section8-content.fade-in:nth-child(1) {
  transition-delay: 0.4s;
}

.section8-content.fade-in:nth-child(2) {
  transition-delay: 0.6s;
}

.section8-end-content.fade-in {
  opacity: 1;
  transform: translateX(0);
  transition-delay: 0.8s;
}

.section8-image.fade-in {
  opacity: 1;
  transform: scale(1);
  transition-delay: 0.1s;
}

.section8-span.fade-in {
  opacity: 1;
  transform: scale(1);
  transition-delay: 0.5s;
  animation: numberPulse 3s ease-in-out infinite 2s;
}

/* Number pulse animation */
@keyframes numberPulse {
  0%, 100% { 
      transform: scale(1); 
  }
  50% { 
      transform: scale(1.05); 
  }
}

/* Responsive Design */
@media (max-width: 1024px) {
  .section8-container-wrapper {
      flex-direction: column;
      align-items: center;
      padding: 1em;
  }

  .section8-content-wrapper-main {
      margin-left: 0;
      align-items: center;
      text-align: center;
  }

  .section8-container-wrapper-inner {
      flex-direction: column;
      gap: 2em;
  }

  .section8-content {
      margin-right: 0;
  }

  .section8-image {
      width: 100%;
      max-width: 350px;
      height: auto;
  }

  .section8-h1 {
      font-size: 2em;
  }

  .section8-p, .section8-end-content {
      font-size: 1em;
      max-width: 90%;
  }
}

@media (max-width: 600px) {
  .section8-h1 {
      font-size: 1.8em;
  }

  .section8-span {
      font-size: 2.2em;
  }

  .section8-content-h1 {
      font-size: 1.1em;
  }

  .section8-p,
  .section8-end-content {
      font-size: 1em;
  }
}

@media (max-width: 480px) {
  .section8-h1 {
      font-size: 3.5rem;
  }

  .section8-content-h1 {
      font-size: 2rem;
  }

  .section8-p {
    font-size: 1.3rem;
  }
  .section8-end-content {
      font-size: 1.3rem;
  }
}