/* ==========  BASE  ========== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
  font-family: 'Roboto', sans-serif;
  background: #f6f4fe;
  color: #27204a;
}

/* ==========  CARD  ========== */
.card {
  width: 90%;
  height: 650px;                        /* Alto fijo */
  margin: 50px auto;
  background: #fff;
  border-radius: 25px;
  box-shadow: 0 18px 50px rgba(30, 16, 72, .12);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* ==========  HEADER  ========== */
.card-header {
  flex: 0 0 auto;
  display: flex;
  gap: 20px;
  align-items: center;
  padding: 30px 40px;
  background: #50227d;
  color: #fff;
  
}
.logo {
  width: 135px;
  height: auto;
}
.card-header h1 {
  flex: 1;
  text-align: center;
  font-size: 1.6rem;
  font-weight: 500;
	margin-left: -137px;
}

/* ==========  BODY (dos columnas)  ========== */
.card-body {
  flex: 1 1 auto;
  display: flex;
  border-top: 1px solid #ece7fd;
}

/* columna genérica */
.col {
  flex: 1;
  padding: 42px 40px;
}

/* --------  IZQUIERDA (.info)  -------- */
.info {
  border-right: 1px solid #ece7fd;
}
.programa {
font-size: 44px;
  font-weight: 800;
  color: #4d267d;
  margin-bottom: 20px;
}
.info h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 18px;
}
.pasos {
  margin: 14px 0 22px;
  padding-left: 22px;
}
.pasos li {
  margin: 6px 0;
}
.pasos span {
  font-weight: 700;
  color: #4d267d;
}
.dest {
  color: #4d267d;
  font-weight: 600;
  margin: 24px 0;
}

/* --------  DERECHA (.pay)  -------- */
.pay {
  background: #f4f1ff;
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-height: 100%;
}

/* ==========  INFO-ROW: ICONO ARRIBA  ========== */
.info-row {
  display: flex;
  flex-direction: column;       /* Icono encima del texto */
  align-items: center;
  text-align: center;
  padding: 24px 16px;
  margin-bottom: 20px;
  border-radius: 18px;
  background: linear-gradient(145deg, #472271 0%, #5a2c9a 100%);
  color: #fff;
  box-shadow: 0 6px 18px rgba(47, 23, 95, .25);
}

/* Contenedor del ícono */
.row-ico {
  width: 180px;
  border-radius: 4%;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
  flex-shrink: 0;
}

/* Si el contenido es imagen */
.row-ico img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
}

/* Ícono de candado en span.lock */
.lock {
  font-size: 32px;
  color: #4d267d;
}

/* Títulos y párrafos */
.row-text h4 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 8px;
}
.row-text p {
  font-size: .95rem;
  line-height: 1.4;
  margin: 0;
}

/* ==========  CHECK & BOTONES  ========== */
.check {
  display: flex;
  gap: 8px;
  font-size: .95rem;
  margin-top: 16px;
}
.check input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: #4d267d;
}
.check a {
  color: #4d267d;
  text-decoration: underline;
}

button {
  width: 210px;
  padding: 14px 0;
  border: none;
  border-radius: 14px;
  background: linear-gradient(135deg, #765bb0 0%, #2d0c5d 100%);
  color: #fff;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: .25s;
margin-top: 20px;
}
button:disabled {
  opacity: .55;
  cursor: not-allowed;
}
button:not(:disabled):hover {
  filter: brightness(1.15);
  transform: translateY(-2px);
}

/* ==========  FORM PASO 2  ========== */
.hidden {
  display: none;
}
.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.form-grid input {
  padding: 12px 14px;
  border: 1px solid #c8c4de;
  border-radius: 8px;
  font-size: .95rem;
}
.form-grid input:focus {
  border-color: #4d267d;
  outline: none;
}
.small-note {
  font-size: .85rem;
  color: #555;
  margin-top: 10px;
}

/* ==========  IFRAME CONEKTA  ========== */
#conekta-frame {
  width: 100%;
  max-width: 420px;
  height: 100%;
  min-height: 560px;           /* Ajuste para encajar en 650px totales */
  margin: 0 auto;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 6px 20px rgba(47, 23, 95, .15);
}

/* ==========  ANIMACIÓN  ========== */
.fade-in {
  animation: fade .45s ease-out forwards;
  opacity: 0;
}
.fade-out {
  animation: fade .35s ease-in reverse forwards;
}
@keyframes fade {
  to {
    opacity: 1;
  }
}

/* ==========  RESPONSIVE  ========== */
@media (max-width: 900px) {
  .card-body {
    flex-direction: column;
  }
  .info {
    border-right: none;
    border-bottom: 1px solid #ece7fd;
  }
  .col {
    padding: 28px 24px;
  }
  .card-header {
    flex-direction: column;
    gap: 12px;
  }
  .logo {
    width: 110px;
  }
  .programa {
    font-size: 1.3rem;
  }
  .info-row {
    padding: 20px;
  }
  .row-ico {
    width: 150px;
    height: 44px;
    margin-bottom: 12px;
  }
  #conekta-frame {
    max-width: 100%;
  }
}

/* contenedor centrado y con padding */
.success-container {
  text-align: center;
  padding: 24px 0;
}

/* ─── Contenedor de la imagen de éxito ─── */
.success-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 24px 0;
  /* no tocamos ancho aquí, que herede el de .col */
}

/* ─── Imagen de éxito ─── */
.success-icon {
  display: block;         /* evita que flex la trate como línea */
  width: 415px;           /* ancho fijo, ya no (%) */
  height: auto;           /* mantiene proporción */
  border-radius: 12px;    /* opcional, bordes redondeados */
  /* si quieres añadir transición: */
  transition: transform 0.2s ease;
}


.success-message {
  text-align: center;
  padding: 40px 20px;
  background: #f4f1ff;
  border-radius: 12px;
}

.success-message__title {
  font-size: 33px;
  color: #28a745;
  margin-bottom: 6px;
}

.success-message__subtitle {
  font-size: 1.5rem;
  color: #37205f;
  margin-bottom: 16px;
}

.success-message__text {
  font-size: 33px;
  color: #27204a;
  margin: 12px 0;
  line-height: 1.5;
}

.success-message__list {
  text-align: left;
  display: inline-block;
  margin: 8px 0 0 0;
  padding-left: 20px;
}

.success-message__list li {
  margin-bottom: 6px;
}

.contact-info {
  margin-top: 24px;
}

.contact-info p {
  font-size: 0.95rem;
  color: #37205f;
  margin: 4px 0;
}


/* ─── tarjeta de generaciones ─── */

.gen-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
  border-radius: 10px;
  background-color: white;
  color: white;
  transition: all 0.3s ease;
  margin: 20px 0;
  cursor: pointer;
  border: solid 3px;
  border-color: #cecece;

}

.gen-card:hover {
  background-color: #5e1fbb1c;
  border-color: #4d287b7a;
  transform: translateY(-2px);
}

.gen-card input[type="radio"] {
  margin-top: 6px;
  transform: scale(1.3);
  accent-color: #50227d;
}

.gen-info {
  flex-grow: 1;
}

.gen-info h3 {
  margin: 0 0 8px;
  font-size: 1.15rem;
  color: black;
}

.gen-info p {
  margin: 4px 0;
  font-size: 0.9rem;
  color: black;
}

.gen-restante {
  margin-top: 8px;
  font-weight: bold;
  font-size: 0.9rem;
}

.gen-restante .activa {
  color: #1a9f3b;
  font-size: 18px;
}

.gen-restante .expirado {
  color: #ff5b5b;
}

.gen-card.selected {
background-color: #5e1fbb1c;
  border-color: #542a88;
}


/* ─── Resumen checkout ─── */

.pago-resumen-tarjeta {
  padding: 22px 24px;
  border-radius: 18px;
  background: #f8fafd;
  border: 1px solid #e4e8f0;
  box-shadow: 0 2px 8px #e7edf67a;
  margin-bottom: 15px;
  font-size: 1.07em;
}
.pago-titulo {
  font-weight: 700;
  font-size: 1.16em;
  margin-bottom: 8px;
  color: #3049b4;
  letter-spacing: 0.01em;
}
.pago-generacion {
  font-size: 1.1em;
  font-weight: bold;
  margin-bottom: 2px;
  color: #222255;
}
.pago-postgrado {
  color: #6474b1;
  font-size: 1.02em;
  margin-bottom: 8px;
}
.pago-resumen-tarjeta hr {
  border: none;
  border-top: 1px solid #e6e6ec;
  margin: 12px 0 10px 0;
}
.pago-observaciones {
  margin-top: 7px;
  color: #444b6d;
  background: #eef4fb;
  border-radius: 5px;
  padding: 5px 10px;
  font-size: .99em;
}
.pago-final-msg {
  margin-top: 15px;
  color: #156a26;
  font-weight: 500;
  font-size: 1em;
  letter-spacing: .01em;
  background: #eafbe7;
  border-radius: 6px;
  padding: 8px 10px;
  display: block;
}
.pago-trust-msg {
  margin-top: 11px;
  color: #5d638b;
  font-size: .95em;
  background: #f4f7ff;
  border-radius: 6px;
  padding: 7px 11px;
  border-left: 4px solid #0811332e;
  display: block;
}
