/* ==============================================================
   Sección: Tres Capacidades. Una Misma Ruta.
   Terracotta - Estrategia territorial con responsabilidad social
   ============================================================== */

.section-tres-capacidades {
  position: relative;
  background-color: #191b1d;
  background-image: url('/assets/mismaruta.png');
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  color: #ffffff;
  padding: 110px 20px 100px 20px;
  overflow: hidden;
}


.tres-capacidades-container {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1360px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Encabezado */
.tres-capacidades-header {
  text-align: center;
  max-width: 900px;
  margin: 0 auto 60px auto;
}

.tres-capacidades-title {
  font-family: var(--font-heading, "Instrument Sans", sans-serif);
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: #ffffff;
  margin-bottom: 14px;
  text-transform: uppercase;
  line-height: 1.25;
}

.tres-capacidades-subtitle {
  font-family: var(--font-body, "DM Sans", sans-serif);
  font-size: 0.95rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 8px;
  line-height: 1.6;
}

.tres-capacidades-desc {
  font-family: var(--font-body, "DM Sans", sans-serif);
  font-size: 0.95rem;
  font-weight: 400;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.85);
  max-width: 820px;
  margin: 0 auto;
}

/* Grid de 3 cards del mismo tamaño en desktop */
.tres-capacidades-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  align-items: stretch;
  margin-bottom: 75px;
}

.capacidad-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 44px 30px 40px 30px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.28);
  transition: transform 0.35s ease, background 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
  position: relative;
  overflow: hidden;
}

.capacidad-card:hover {
  transform: translateY(-8px);
  background-color: rgb(138, 182, 167);
  border-color: rgba(255, 255, 255, 0.45);
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.42);
}

.capacidad-card:hover .capacidad-card-text {
  color: #ffffff;
}

.capacidad-card:hover .capacidad-indicadores-label {
  color: rgba(255, 255, 255, 0.9);
}

.capacidad-card:hover .capacidad-indicador-dot {
  color: #ffffff;
}

/* Iconos */
.capacidad-icon-wrapper {
  width: 96px;
  height: 96px;
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.capacidad-icon-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.35));
  transition: transform 0.35s ease;
}

.capacidad-card:hover .capacidad-icon-img {
  transform: scale(1.08);
}

/* Tipografía de cada Card */
.capacidad-card-title {
  font-family: var(--font-heading, "Instrument Sans", sans-serif);
  font-size: 1.15rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #ffffff;
  margin-bottom: 12px;
  line-height: 1.3;
  min-height: 2.8em;
  display: flex;
  align-items: center;
  justify-content: center;
}

.capacidad-card-subtitle {
  font-family: var(--font-body, "DM Sans", sans-serif);
  font-size: 0.95rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 14px;
  line-height: 1.5;
}

.capacidad-card-text {
  font-family: var(--font-body, "DM Sans", sans-serif);
  font-size: 0.95rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.82);
  margin-bottom: 24px;
  flex-grow: 1; /* Garantiza que todas las cards tengan exactamente la misma altura */
}

/* Indicadores / Pills */
.capacidad-indicadores-wrapper {
  margin-top: auto;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  width: 100%;
}

.capacidad-indicadores-label {
  display: block;
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.58);
  margin-bottom: 8px;
  font-weight: 600;
}

.capacidad-indicadores-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: #ffffff;
  text-transform: uppercase;
}

.capacidad-indicador-dot {
  color: var(--color-secondary, #90c2b5);
  font-size: 1.2rem;
  line-height: 1;
}

/* Frase de cierre inferior */
.tres-capacidades-footer {
  text-align: center;
  padding-top: 10px;
}

.tres-capacidades-footer p {
  font-family: var(--font-heading, "Instrument Sans", sans-serif);
  font-size: clamp(1.1rem, 2vw, 1.45rem);
  font-weight: 600;
  color: rgba(255, 255, 255, 0.96);
  letter-spacing: 0.02em;
}

/* ==============================================================
   Modo Móvil: 1 sola columna con cards una sobre otra
   ============================================================== */
@media (max-width: 991px) {
  .section-tres-capacidades {
    padding: 70px 16px 65px 16px;
  }

  .tres-capacidades-header {
    margin-bottom: 40px;
  }

  .tres-capacidades-grid {
    grid-template-columns: 1fr;
    gap: 24px;
    margin-bottom: 45px;
  }

  .capacidad-card {
    padding: 34px 22px 30px 22px;
  }

  .capacidad-card-title {
    min-height: auto;
    margin-bottom: 10px;
  }

  .capacidad-icon-wrapper {
    width: 82px;
    height: 82px;
    margin-bottom: 22px;
  }

  .capacidad-card-text {
    margin-bottom: 20px;
  }
}
