.cta {
  width: 100%;
  background-color: var(--mesana-white);
  position: relative;
  z-index: 2;
  margin-top: -1px;
}

.cta-container {
  max-width: var(--max-width-container);
  margin: 0 auto;
  padding: 100px 82px;
}

.cta-content {
  background: linear-gradient(0deg, #5F1C21 0%, #010101 165%);
  position: relative;
  
  border-radius: 8px;
  padding: 80px 60px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  overflow: hidden;
}

.cta-content::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url('../images/cta-pattern.png');
  background-repeat: no-repeat;
  background-position: 100% 48%;
  background-size: cover;
  opacity: 0.8;
  mix-blend-mode: color-burn;
  pointer-events: none;
}

.cta-content > * {
  position: relative;
  z-index: 1;
}

.cta-heading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.cta-title {
  font-family: 'Libre Franklin', sans-serif;
  font-size: 48px;
  font-weight: 400;
  font-style: normal;
  line-height: 1.2;
  color: var(--mesana-cream);
  margin: 0;
  opacity: 0;
}

.cta-title.in-view {
  animation: fadeIn 0.8s ease-out 0.2s forwards;
}

.cta-title-highlight {
  font-family: 'PT Serif Regular', sans-serif;
  font-weight: 400;
  font-style: italic;
}

.cta-title-italic {
  font-family: 'PT Serif Italic', serif;
  font-weight: 400;
  font-style: italic;
}

.cta-description {
  font-family: 'Libre Franklin', sans-serif;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.4;
  color: var(--mesana-white);
  margin: 0;
  max-width: 520px;
  opacity: 0;
}

.cta-description.in-view {
  animation: fadeIn 0.8s ease-out 0.4s forwards;
}

.cta-button {
  font-family: 'Libre Franklin', sans-serif;
  font-size: 16px;
  font-weight: 400;
  color: var(--mesana-red);
  background-color: transparent;
  padding: 8px 24px;
  border-radius: 999px;
  text-decoration: none;
  display: inline-block;
  transition: color 0.2s ease, transform 0.3s ease;
  margin-top: 8px;
  opacity: 0;
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.cta-button.in-view {
  animation: fadeIn 0.8s ease-out 0.6s forwards;
}

/* CTA button hover effect (similar to .projects-button, but text turns white) */
.cta-button::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--mesana-cream);
  z-index: -2;
}

.cta-button::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, #fff 0%, rgba(95, 28, 33, 0) 100%);
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform 0.2s ease;
  z-index: -1;
}

.cta-button:hover::after {
  transform: scaleY(7);
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@media (max-width: 968px) {
  .cta-container {
    padding: 60px 40px;
  }

  .cta-content {
    padding: 60px 40px;
  }

  .cta-title {
    font-size: 36px;
  }

  .cta-description {
    font-size: 16px;
  }
}

@media (max-width: 768px) {
  .cta-container {
    padding: 40px 20px;
    padding-bottom: 0;
  }

  .cta-content {
    padding: 60px 16px;
  }

  .cta-title {
    font-size: 32px;
    width: 80%;
  }

  .cta-description {
    font-family: 'Libre Franklin Regular', sans-serif;
    font-size: 16px;
    width: 85%;
  }

  .cta-button {
    font-size: 12px;
    padding: 8px 24px;
  }

  .cta-content::before {
    background-size: 250%;
  }
}

