/* custom-modules.css */
.carta-wrapper {
  overflow: visible;
  background: transparent;
  padding-bottom: 3rem;
}


.carta {
  width: 100%;
  border-radius: 20px;
  background: #f5f5f5;
  padding: 1.8rem;
  border: 2px solid #32244a;
  overflow: visible; 
  transition: 0.5s ease-out;
  position: relative;
  box-shadow: none;
}

.detalles-carta {
  color: black;
  height: 100%;
  gap: .5em;
  display: flex;
  justify-content: center;
  flex-direction: column;
  align-items: center;
}

.carta-button {
  transform: translate(-50%, 125%);
  width: 60%;
  border-radius: 1rem;
  border: none;
  background-color: #32244a;
  color: #fff;
  font-size: 1rem;
  padding: .5rem 1rem;
  position: absolute;
  left: 50%;
  opacity: 0;
  transition: 0.3s ease-out;
  cursor: pointer;
  bottom: -1.5rem;
  z-index: 10;
}

.text-title {
  font-size: 1.5em;
  font-weight: bold;
}

.carta:hover {
  border-color: #32244a;
  box-shadow: 3px 4px 18px 0 rgba(0, 0, 0, 0.25);
}

.carta:hover .carta-button {
  transform: translate(-50%, -20%);
  opacity: 1;
}

/* Modal styles */
.hidden {
  display: none !important;
}

.card-modal-overlay {
  position: fixed;
  top: 0; left: 0;
  width: 100vw; height: 100vh;
  background: rgba(0, 0, 0, 0.5); /* editable desde Divi si expones como campo */
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 999999;
  transition: opacity 0.3s ease;
}

.card-modal-overlay.active {
  display: flex;
}

.card-modal-content {
  background: var(--modal-bg, #fff); /* editable con variable CSS */
  padding: 2rem;
  border-radius: 15px;
  max-width: 600px;
  width: 90%;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
  position: relative;
  animation: fadeIn 0.3s ease-out;
}

.card-modal-close {
  position: absolute;
  top: 10px; right: 10px;
  background: #32244a;
  color: #fff;
  border: none;
  font-size: 1.2rem;
  width: 2rem; height: 2rem;
  border-radius: 50%;
  cursor: pointer;
}

@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes fadeOut {
  from { opacity: 1; transform: scale(1); }
  to { opacity: 0; transform: scale(0.95); }
}

/* === Cool Modules - Botón General === */
.cm-btn-wrapper {
  text-align: center;
}

.cm-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  overflow: hidden;
}

.cm-btn-style::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background: linear-gradient(0deg, rgba(50, 36, 74, 1) 0%, rgba(79, 68, 99, 1) 100%);
  border-radius: 0.5em;
  transition: height 0.3s ease-out;
  z-index: 0;
}

.cm-btn-style:hover::before {
  height: 0%;
}

.cm-btn-style span {
  position: relative;
  display: inline-block;
  font-size: 1.3em;
  padding: 15px 20px;
  color: #fff;
  text-transform: uppercase;
  border: 1px solid rgb(79, 68, 99);
  border-radius: 0.5em;
  transition: color 0.2s 0.1s;
  z-index: 1;
}

.cm-btn-style:hover span {
  color: rgb(28, 31, 30);
}

/*Carousel slider*/

.cm-carousel-title {
  font-size: 3rem;
  font-weight: 700;
  text-align: center;
  margin: 40px 0 20px;
  font-family: 'Arial Black', sans-serif;
}

.cm-carousel-container {
  max-width: 1200px;
  height: 450px;
  margin: auto;
  position: relative;
  perspective: 1000px;
}

.cm-carousel-track {
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  transform-style: preserve-3d;
  transition: transform 0.8s ease;
}

.cm-card {
  position: absolute;
  width: 280px;
  height: 380px;
  background: white;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
  transition: all 0.8s ease;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
}

.cm-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cm-card.center {
  z-index: 10;
  transform: scale(1.1) translateZ(0);
  opacity: 1;
  pointer-events: auto;
}

.cm-card.left-1,
.cm-card.right-1 {
  z-index: 5;
  transform: scale(0.9) translateZ(-100px);
  opacity: 0.9;
  pointer-events: auto;
}

.cm-card.left-1 { transform: translateX(-200px) scale(0.9) translateZ(-100px); }
.cm-card.right-1 { transform: translateX(200px) scale(0.9) translateZ(-100px); }

.cm-card.left-2,
.cm-card.right-2 {
  z-index: 1;
  transform: scale(0.8) translateZ(-300px);
  opacity: 0.7;
  pointer-events: auto;
}

.cm-card.left-2 { transform: translateX(-400px) scale(0.8) translateZ(-300px); }
.cm-card.right-2 { transform: translateX(400px) scale(0.8) translateZ(-300px); }

.cm-member-info {
  text-align: center;
  margin-top: 30px;
  transition: all 0.3s ease;
}

.cm-member-name {
  font-size: 2rem;
  font-weight: bold;
  position: relative;
  margin-bottom: 5px;
}

.cm-member-role {
  color: #848696;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-top: 0;
}

.cm-dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 30px;
}

.cm-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(8, 42, 123, 0.2);
  transition: all 0.3s ease;
  cursor: pointer;
}

.cm-dot.active {
  transform: scale(1.2);
}

.cm-nav-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(8, 42, 123, 0.6);
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 1.5rem;
  border: none;
  cursor: pointer;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.cm-nav-arrow:hover {
  background: rgba(0, 0, 0, 0.8);
  transform: translateY(-50%) scale(1.1);
}

.cm-nav-arrow.left { left: 20px; }
.cm-nav-arrow.right { right: 20px; }

/* Responsive */
@media (max-width: 768px) {
  .cm-carousel-title {
    font-size: 2rem;
  }
  .cm-card {
    width: 200px;
    height: 280px;
  }
  .cm-card.left-1 { transform: translateX(-120px) scale(0.9) translateZ(-100px); }
  .cm-card.right-1 { transform: translateX(120px) scale(0.9) translateZ(-100px); }
  .cm-card.left-2 { transform: translateX(-250px) scale(0.8) translateZ(-300px); }
  .cm-card.right-2 { transform: translateX(250px) scale(0.8) translateZ(-300px); }
}

.dipl_image_accordion_item { position: relative; z-index: 1; }
.dipl_image_accordion_item * { pointer-events: none; }
.dipl_image_accordion_item a,
.dipl_image_accordion_item button { pointer-events: auto; }

.dipl_image_accordion_wrapper { overflow: hidden; }
