.text-image {
  padding: 5rem 2rem;
  background: var(--color-bg, #ffffff);
}

.text-image .container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.text-image.image-left .container {
  grid-template-columns: 1fr 1fr;
}

.text-image.image-left .image-content {
  order: -1;
}

.text-content h2 {
  font-size: clamp(1.75rem, 4vw, 2rem);
  font-weight: 700;
  margin: 0 0 1.5rem 0;
  color: var(--color-text, #1e293b);
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.text-content p {
  font-size: clamp(1rem, 2vw, 1.1rem);
  line-height: 1.7;
  color: var(--color-neutral, #64748b);
  margin: 0 0 1.5rem 0;
}

.text-content .button {
  display: inline-block;
  padding: 0.875rem 1.75rem;
  background: var(--color-primary, #2563eb);
  color: var(--color-bg, #ffffff);
  text-decoration: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 1rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.2);
}

.text-content .button:hover {
  background: var(--color-primary-dark, #1d4ed8);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.text-content .button:focus-visible {
  outline: 2px solid var(--color-primary, #2563eb);
  outline-offset: 4px;
}

@media (prefers-reduced-motion: reduce) {
  .text-content .button {
    transition: none;
  }

  .text-content .button:hover {
    transform: none;
  }
}

.image-content {
  position: relative;
}

.image-content img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08), 0 2px 6px rgba(0, 0, 0, 0.04);
  transition: box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.image-content img:hover {
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.12), 0 4px 8px rgba(0, 0, 0, 0.06);
}

/* Responsive */
@media (max-width: 768px) {
  .text-image {
    padding: 3rem 1.5rem;
  }

  .text-image .container {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .text-image.image-left .image-content {
    order: 0;
  }
}

/* Accessibility: High contrast mode */
@media (prefers-contrast: high) {
  .text-content .button {
    border: 2px solid var(--color-bg, #ffffff);
  }

  .text-content .button:focus-visible {
    outline-width: 3px;
  }
}
