/* ═══════════════════════════════════════
   ctaform.css — CTA + Form nativo UPA
   Paleta: --upa-dark, --upa-blue, --upa-cyan
═══════════════════════════════════════ */

/* ── Sección CTA ── */
#cta {
  background: var(--upa-dark);
  padding: 100px 5%;
  position: relative;
  overflow: hidden;
}
#cta::before {
  content: '';
  position: absolute;
  top: 0; left: 50%;
  transform: translateX(-50%);
  width: 130%;
  height: 100%;
  background:
    radial-gradient(ellipse 900px 350px at 50% 0%, rgba(0,180,216,0.07) 0%, transparent 70%),
    linear-gradient(rgba(0,180,216,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,180,216,0.02) 1px, transparent 1px);
  background-size: auto, 70px 70px, 70px 70px;
  pointer-events: none;
}

/* ── Layout ── */
.cta-layout {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 60px;
  align-items: start;
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
}

/* ── Lado izquierdo ── */
.cta-left {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding-top: 8px;
}
.cta-heading { margin-bottom: 36px; }
.cta-heading h2 { font-size: clamp(1.8rem, 2.8vw, 2.6rem); }
.cta-heading p {
  color: rgba(255,255,255,0.48);
  font-size: 1rem;
  margin-top: 12px;
  font-weight: 300;
  line-height: 1.8;
}

.cta-checks { display: flex; flex-direction: column; gap: 12px; margin-bottom: 28px; }
.cta-check-card {
  display: flex;
  align-items: center;
  gap: 16px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 10px;
  padding: 18px 20px;
  transition: all 0.3s var(--ease);
}
.cta-check-card:hover {
  background: rgba(0,180,216,0.06);
  border-color: rgba(0,180,216,0.2);
  transform: translateX(5px);
}
.check-icon {
  width: 34px; height: 34px;
  background: rgba(0,180,216,0.1);
  border: 1px solid rgba(0,180,216,0.25);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: var(--upa-cyan);
  font-size: 0.9rem;
  flex-shrink: 0;
}
.cta-check-card span { color: rgba(255,255,255,0.75); font-size: 0.97rem; font-weight: 400; }

.cta-divider { height: 1px; background: rgba(255,255,255,0.06); margin: 4px 0 20px; }
.cta-close {
  font-family: 'Sora', 'Inter', system-ui, sans-serif;
  font-style: italic;
  font-size: 1rem;
  color: rgba(255,255,255,0.35);
  line-height: 1.65;
}

/* ════════════════════════════════
   FORM PANEL (estilo Apple/macOS)
════════════════════════════════ */
.form-panel {
  background: var(--white);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 40px 80px rgba(0,0,0,0.4), 0 0 0 1px rgba(0,180,216,0.12);
}

/* Barra superior macOS */
.form-panel-header {
  background: var(--upa-blue);
  padding: 16px 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  user-select: none;
}
.form-panel-header span {
  color: rgba(255,255,255,0.6);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
}
.form-dots { display: flex; gap: 6px; align-items: center; }
.form-dots i {
  width: 11px; height: 11px;
  border-radius: 50%;
  display: block;
}
.form-dots i:nth-child(1) { background: rgba(255, 95, 87, 0.8); }
.form-dots i:nth-child(2) { background: rgba(255, 189, 46, 0.8); }
.form-dots i:nth-child(3) { background: rgba(40, 201, 64, 0.8); }

/* ── Título dentro del form ── */
.form-title-block {
  padding: 28px 28px 20px;
  border-bottom: 1px solid rgba(30,42,110,0.07);
}
.form-title-block h3 {
  font-family: 'Sora', 'Inter', system-ui, sans-serif;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--upa-blue);
  letter-spacing: -0.5px;
  line-height: 1.3;
  margin-bottom: 6px;
}
.form-title-block p {
  font-size: 0.83rem;
  color: var(--text-light);
  line-height: 1.6;
  font-weight: 300;
}

/* ── Cuerpo del formulario ── */
.upa-form {
  padding: 24px 28px 28px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

/* Fila de dos campos */
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

/* Grupo de campo individual */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.form-group label {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-main);
  letter-spacing: 0.1px;
}
.form-group .req { color: var(--upa-cyan); margin-left: 2px; }

/* Inputs */
.form-group input {
  width: 100%;
  padding: 10px 13px;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--text-main);
  background: var(--bg-soft);
  border: 1.5px solid rgba(30,42,110,0.1);
  border-radius: 8px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
  -webkit-appearance: none;
  appearance: none;
}
.form-group input::placeholder { color: rgba(90,101,133,0.45); font-size: 0.88rem; }
.form-group input:hover { border-color: rgba(30,42,110,0.22); }
.form-group input:focus {
  border-color: var(--upa-cyan);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(0,180,216,0.1);
}

/* Estado de error */
.form-group input.input-error {
  border-color: rgba(220,50,50,0.5);
  box-shadow: 0 0 0 3px rgba(220,50,50,0.08);
}
.field-error {
  display: none;
  font-size: 0.72rem;
  color: #dc3232;
  margin-top: 2px;
}

/* ── Botón submit ── */
.form-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 13px 24px;
  background: var(--upa-blue);
  color: var(--white);
  font-family: 'Sora', 'Inter', system-ui, sans-serif;
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: -0.2px;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.25s var(--ease);
  margin-top: 4px;
  position: relative;
  overflow: hidden;
}
.form-btn:hover {
  background: var(--upa-cyan);
  color: var(--upa-dark);
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(0,180,216,0.3);
}
.form-btn:active { transform: translateY(0); box-shadow: none; }
.form-btn.loading { pointer-events: none; opacity: 0.85; }
.form-btn-icon { font-size: 1rem; }

/* Spinner dentro del botón */
.btn-spinner {
  display: inline-block;
  width: 16px; height: 16px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: var(--white);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  flex-shrink: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Disclaimer ── */
.form-disclaimer {
  font-size: 0.7rem;
  color: var(--text-light);
  text-align: center;
  line-height: 1.5;
  opacity: 0.65;
  margin-top: -4px;
}

/* ── Mensaje de error general ── */
.form-error-msg {
  display: none;
  background: rgba(220,50,50,0.07);
  border: 1px solid rgba(220,50,50,0.2);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 0.83rem;
  color: #c0392b;
  text-align: center;
}

/* ── Estado de éxito ── */
.upa-form.hidden { display: none; }

.form-success {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 52px 28px;
  text-align: center;
  gap: 14px;
  animation: fadeUp 0.5s var(--ease) both;
}
.form-success.active { display: flex; }

.success-icon {
  width: 64px; height: 64px;
  background: rgba(0,180,216,0.08);
  border: 2px solid rgba(0,180,216,0.25);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.6rem;
  margin-bottom: 4px;
}
.form-success h3 {
  font-family: 'Sora', 'Inter', system-ui, sans-serif;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--upa-blue);
  letter-spacing: -0.5px;
}
.form-success p {
  font-size: 0.88rem;
  color: var(--text-light);
  line-height: 1.65;
  max-width: 290px;
}
.form-success .wa-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #25d366;
  color: var(--white);
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s;
  margin-top: 4px;
}
.form-success .wa-link:hover { opacity: 0.88; transform: translateY(-2px); }

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}





/* ════════════════════════════
   VIDEO MODAL
════════════════════════════ */
.video-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99999;
  align-items: center;
  justify-content: center;
}
.video-modal.active { display: flex; }

.video-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10,15,46,0.92);
  backdrop-filter: blur(8px);
  animation: backdropIn 0.3s ease both;
}
@keyframes backdropIn { from { opacity:0; } to { opacity:1; } }

.video-modal-box {
  position: relative;
  z-index: 1;
  width: min(860px, 92vw);
  animation: modalIn 0.4s var(--ease) both;
}
@keyframes modalIn {
  from { opacity:0; transform: scale(0.92) translateY(24px); }
  to   { opacity:1; transform: scale(1) translateY(0); }
}

.video-modal-close {
  position: absolute;
  top: -44px;
  right: 0;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  color: white;
  width: 36px; height: 36px;
  border-radius: 50%;
  font-size: 0.85rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.2s;
}
.video-modal-close:hover {
  background: rgba(255,255,255,0.2);
  transform: scale(1.1);
}

.video-container {
  position: relative;
  width: 100%;
  padding-top: 56.25%; /* 16:9 */
  background: #000;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 32px 80px rgba(0,0,0,0.6);
}
.video-container iframe,
.video-container video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}
