/* ==========================================================================
   Casos de Éxito - Estilos específicos
   ========================================================================== */

/* ==========================================================================
   Hero del caso
   ========================================================================== */
.u-case-hero {
  padding: clamp(4rem, 8vw, 6rem) 0 clamp(3rem, 6vw, 5rem);
  background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
  color: #fff;
}

.u-case-hero__content {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
}

.u-case-hero__badge {
  display: inline-block;
  padding: 0.5rem 1.25rem;
  background: rgba(99, 102, 241, 0.2);
  color: #a5b4fc;
  border: 1px solid rgba(99, 102, 241, 0.3);
  border-radius: 2rem;
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

.u-case-hero__title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 800;
  line-height: 1.1;
  margin: 0 0 1rem;
  letter-spacing: -0.02em;
}

.u-case-hero__subtitle {
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.85);
  margin: 0 0 2rem;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.u-case-hero__meta {
  display: flex;
  gap: 2rem;
  justify-content: center;
  flex-wrap: wrap;
}

.u-case-hero__meta-item {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.75);
}

.u-case-hero__meta-item strong {
  color: #a5b4fc;
  font-weight: 700;
}

/* ==========================================================================
   Estadísticas clave
   ========================================================================== */
.u-case-stats {
  padding: clamp(3rem, 6vw, 5rem) 0;
  background: #fff;
}

.u-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.u-case-stats__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
}

.u-case-stats__item {
  text-align: center;
  padding: 2rem 1.5rem;
  background: #f8fafc;
  border-radius: 1rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.u-case-stats__item:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.u-case-stats__number {
  display: block;
  font-size: clamp(3rem, 6vw, 4rem);
  font-weight: 900;
  color: #6366f1;
  line-height: 1;
  margin-bottom: 0.75rem;
  letter-spacing: -0.03em;
}

.u-case-stats__label {
  display: block;
  font-size: 1rem;
  font-weight: 600;
  color: #1e293b;
  line-height: 1.4;
}

/* ==========================================================================
   Galería de imágenes
   ========================================================================== */
.u-case-gallery {
  padding: clamp(3rem, 6vw, 5rem) 0;
  background: #f8fafc;
}

.u-case-gallery__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.u-case-gallery__item {
  overflow: hidden;
  border-radius: 0.75rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.u-case-gallery__item:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

.u-case-gallery__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.u-case-gallery__item--large {
  grid-column: 1 / -1;
}

.u-case-gallery__item--large img {
  height: 500px;
}

@media (max-width: 768px) {
  .u-case-gallery__grid {
    grid-template-columns: 1fr;
  }
  
  .u-case-gallery__item--large img {
    height: 300px;
  }
}

/* ==========================================================================
   Secciones de contenido (Reto, Solución, Resultados)
   ========================================================================== */
.u-case-section {
  padding: clamp(4rem, 8vw, 6rem) 0;
  background: #fff;
}

.u-case-section--alt {
  background: #f8fafc;
}

.u-case-section__header {
  max-width: 900px;
  margin-bottom: 3rem;
}

.u-case-section__number {
  display: inline-block;
  font-size: 1rem;
  font-weight: 700;
  color: #6366f1;
  margin-bottom: 1rem;
  letter-spacing: 0.05em;
}

.u-case-section__title {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  color: #1e293b;
  line-height: 1.2;
  margin: 0;
  letter-spacing: -0.02em;
}

.u-case-section__content {
  max-width: 900px;
}

.u-case-section__content p {
  font-size: 1.125rem;
  line-height: 1.7;
  color: #475569;
  margin: 0 0 1.5rem;
}

.u-case-section__list {
  list-style: none;
  padding: 0;
  margin: 2rem 0 0;
  display: grid;
  gap: 1.5rem;
}

.u-case-section__list li {
  position: relative;
  padding-left: 2.5rem;
  font-size: 1.0625rem;
  line-height: 1.6;
  color: #475569;
}

.u-case-section__list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0;
  width: 1.5rem;
  height: 1.5rem;
  background: #6366f1;
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.875rem;
}

/* ==========================================================================
   Stack tecnológico
   ========================================================================== */
.u-case-stack {
  padding: clamp(3rem, 6vw, 5rem) 0;
  background: #1e293b;
  color: #fff;
}

.u-case-stack__title {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 800;
  margin: 0 0 2.5rem;
  text-align: center;
  letter-spacing: -0.02em;
}

.u-case-stack__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.u-case-stack__item {
  padding: 1.5rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.75rem;
  font-size: 1rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.85);
}

.u-case-stack__item strong {
  color: #a5b4fc;
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 700;
}

/* ==========================================================================
   Testimonial
   ========================================================================== */
.u-case-testimonial {
  padding: clamp(4rem, 8vw, 6rem) 0;
  background: #fff;
}

.u-case-testimonial__quote {
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
  padding: 3rem;
  background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
  border-radius: 1rem;
  border-left: 4px solid #6366f1;
}

.u-case-testimonial__quote p {
  font-size: clamp(1.125rem, 2vw, 1.375rem);
  line-height: 1.7;
  color: #1e293b;
  margin: 0 0 2rem;
  font-style: italic;
  font-weight: 500;
}

.u-case-testimonial__author {
  border-top: 1px solid #cbd5e1;
  padding-top: 1.5rem;
  margin-top: 1.5rem;
}

.u-case-testimonial__author strong {
  display: block;
  font-size: 1.125rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 0.25rem;
}

.u-case-testimonial__author span {
  font-size: 0.95rem;
  color: #64748b;
}

/* ==========================================================================
   CTA final
   ========================================================================== */
.u-cta {
  padding: clamp(4rem, 8vw, 6rem) 0;
  background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
  color: #fff;
}

.u-cta__content {
  max-width: 700px;
  margin: 0 auto;
  text-align: center;
}

.u-cta__title {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  margin: 0 0 1rem;
  letter-spacing: -0.02em;
}

.u-cta__text {
  font-size: 1.125rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.9);
  margin: 0 0 2.5rem;
}

.u-btn {
  display: inline-block;
  padding: 1rem 2.5rem;
  font-size: 1.125rem;
  font-weight: 700;
  text-decoration: none;
  border-radius: 0.5rem;
  transition: all 0.3s ease;
  cursor: pointer;
  border: none;
}

.u-btn--primary {
  background: #fff;
  color: #6366f1;
}

.u-btn--primary:hover {
  background: #f8fafc;
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.u-btn--lg {
  padding: 1.25rem 3rem;
  font-size: 1.25rem;
}

/* ==========================================================================
   Footer de casos
   ========================================================================== */
.u-footer {
  background: #0f172a;
  color: rgba(255, 255, 255, 0.7);
  padding: 4rem 0 2rem;
}

.u-footer__content {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 4rem;
  margin-bottom: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.u-footer__brand img {
  height: 40px;
  margin-bottom: 1rem;
}

.u-footer__brand p {
  font-size: 0.95rem;
  line-height: 1.6;
  max-width: 300px;
}

.u-footer__nav {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.u-footer__column h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  margin: 0 0 1rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.u-footer__column ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.u-footer__column li {
  margin-bottom: 0.75rem;
}

.u-footer__column a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.3s ease;
}

.u-footer__column a:hover {
  color: #a5b4fc;
}

.u-footer__bottom {
  text-align: center;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.5);
}

@media (max-width: 768px) {
  .u-footer__content {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .u-footer__nav {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

/* ==========================================================================
   Animaciones
   ========================================================================== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.u-case-stats__item,
.u-case-gallery__item,
.u-case-section,
.u-case-stack__item,
.u-case-testimonial__quote {
  animation: fadeInUp 0.6s ease-out;
}

.u-case-stats__item:nth-child(1) { animation-delay: 0.1s; }
.u-case-stats__item:nth-child(2) { animation-delay: 0.2s; }
.u-case-stats__item:nth-child(3) { animation-delay: 0.3s; }
.u-case-stats__item:nth-child(4) { animation-delay: 0.4s; }

.u-case-gallery__item:nth-child(1) { animation-delay: 0.1s; }
.u-case-gallery__item:nth-child(2) { animation-delay: 0.2s; }
.u-case-gallery__item:nth-child(3) { animation-delay: 0.3s; }
