*{
  margin:0;
  padding:0;
  box-sizing:border-box;
  font-family:Arial, Helvetica, sans-serif;
}

html{
  -webkit-text-size-adjust:100%;
}

body{
  background:#ffffff;
  overflow-x:hidden;
}

/* ================= LOADER ================= */

#loaderOverlay{
  position:fixed;
  inset:0;
  background:#ffffff;
  display:flex;
  justify-content:center;
  align-items:center;
  flex-direction:column;
  z-index:9999;
  transition:1s;
}

.logoRow{
  display:flex;
  gap:40px;
  margin-bottom:20px;
}

.loader{
  position:relative;
  width:80px;
  height:80px;
}

.loader svg{
  width:100%;
  height:100%;
}

.loader path,
.loader circle{
  fill:none;
  stroke:#000;
  stroke-width:6px;
  stroke-dasharray:220;
  stroke-dashoffset:220;
  animation:draw 1.4s linear infinite;
}

.dot{
  position:absolute;
  width:8px;
  height:8px;
  background:#002b5c;
  border-radius:50%;
  animation:follow 1.4s linear infinite;
}

.loadingText{
  color:#000;
  font-size:22px;
  letter-spacing:4px;
  animation:fadeText 1.5s infinite;
}

@keyframes draw{
  to{stroke-dashoffset:0;}
}

@keyframes follow{
  0%{transform:translate(10px,70px);}
  33%{transform:translate(40px,20px);}
  66%{transform:translate(70px,70px);}
  100%{transform:translate(10px,70px);}
}

@keyframes fadeText{
  0%{opacity:0;}
  50%{opacity:1;}
  100%{opacity:0;}
}

#loaderOverlay.zoomOut{
  opacity:0;
  pointer-events:none;
}

/* ================= APP ================= */

.app{
  width:100%;
  min-height:100vh;
  display:flex;
  align-items:stretch;
  background:#ffffff;
}

/* ================= IZQUIERDA ================= */

.left{
  flex:1 1 auto;
  min-width:0;
  min-height:100vh;
  position:relative;
  overflow:hidden;
  background:#dce4ef;
  display:flex;
  justify-content:center;
  align-items:center;
}

.left::before{
  content:"";
  position:absolute;
  inset:0;
  background-image:url("../assets/MDO DENTAL TRAINING CENTER PORTADA 2026.png");
  background-repeat:no-repeat;
  background-size:cover;
  background-position:center center;
  transform:scale(1.15);
  filter:blur(25px) brightness(.72) saturate(118%);
  z-index:0;
}

.left::after{
  content:"";
  position:absolute;
  inset:0;
  background:
    linear-gradient(
      180deg,
      rgba(255,255,255,.06) 0%,
      rgba(255,255,255,.03) 20%,
      rgba(6,20,44,.10) 50%,
      rgba(6,20,44,.18) 80%,
      rgba(6,20,44,.26) 100%
    );
  z-index:1;
}

.left-image-wrap{
  position:relative;
  z-index:2;
  width:100%;
  height:100%;
  display:flex;
  justify-content:center;
  align-items:center;
}

.left img{
  position:relative;
  z-index:2;
  width:auto;
  max-width:100%;
  max-height:100%;
  height:auto;
  object-fit:contain;
  pointer-events:none;
  filter:drop-shadow(0 18px 36px rgba(0,0,0,.18));
}

/* ================= REDES SOCIALES ================= */

.social-glass{
  position:absolute;
  z-index:3;
  left:50%;
  transform:translateX(-50%);
  bottom:12px;
  background:rgba(0, 0, 0, 0.55);
  border:1px solid rgba(255, 255, 255, 0.12);
  border-radius:30px;
  padding:8px 16px;
  -webkit-backdrop-filter:blur(12px);
  backdrop-filter:blur(12px);
  box-shadow:0 10px 22px rgba(0,0,0,.18);
}

@supports not (backdrop-filter: blur(12px)){
  .social-glass{
    background:rgba(0, 0, 0, 0.7);
  }
}

.social-container{
  display:flex;
  gap:18px;
}

.social-card{
  position:relative;
  width:44px;
  height:44px;
  background:#f1f1f1;
  border-radius:50%;
  display:flex;
  justify-content:center;
  align-items:center;
  text-decoration:none;
  cursor:pointer;
  transition:all .25s ease;
  transform:scale(.9);
}

.social-card i{
  font-size:16px;
  color:#000;
}

.tooltip{
  position:absolute;
  top:-42px;
  background:#000000;
  color:#ffffff;
  padding:6px 12px;
  border-radius:20px;
  font-size:12px;
  opacity:0;
  pointer-events:none;
  transition:.25s;
  white-space:nowrap;
}

.tooltip::after{
  content:"";
  position:absolute;
  bottom:-6px;
  left:50%;
  transform:translateX(-50%);
  border-width:6px 6px 0;
  border-style:solid;
  border-color:#000000 transparent transparent;
}

.social-card:hover{
  transform:scale(1.1);
}

.social-card:hover .tooltip{
  opacity:1;
  top:-52px;
}

.facebook:hover{background:#1877f2;}
.facebook:hover i{color:#ffffff;}
.tiktok:hover{background:#000000;}
.tiktok:hover i{color:#ffffff;}
.instagram:hover{background:#e1306c;}
.instagram:hover i{color:#ffffff;}
.whatsapp:hover{background:#25d366;}
.whatsapp:hover i{color:#ffffff;}

/* ================= DERECHA ================= */

.right{
  width:40%;
  max-width:580px;
  min-width:380px;
  background:#ffffff;
  padding:clamp(28px, 2.8vw, 48px) clamp(26px, 2.4vw, 40px);
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:stretch;
  min-height:100vh;
}

.right h1{
  color:#000;
  margin-bottom:8px;
  font-size:clamp(22px, 2vw, 30px);
  line-height:1.2;
}

.subtitle{
  color:#002b5c;
  margin-bottom:34px;
  font-size:14px;
  line-height:1.55;
  opacity:.85;
}

.screen{
  width:100%;
  display:flex;
  flex-direction:column;
}

/* ================= INTRO ================= */

.intro-container{
  animation:fadeInIntro .6s ease;
}

@keyframes fadeInIntro{
  from{opacity:0; transform:translateY(20px);}
  to{opacity:1; transform:translateY(0);}
}

.form-personal{
  display:flex;
  flex-direction:column;
  gap:22px;
  margin-top:4px;
}

.campo{
  display:flex;
  flex-direction:column;
  gap:10px;
}

.campo label,
.question{
  font-size:14px;
  color:#000;
  line-height:1.45;
  font-weight:500;
}

/* ================= INPUTS ================= */

.input-line,
#grupoInput{
  width:75%;
  background:transparent;
  border:none;
  border-bottom:2px solid #000;
  padding:9px 4px;
  font-size:14px;
  outline:none;
  transition:.3s;
  display:block;
  color:#000;
  font-family:Arial, sans-serif;
}

.input-line:hover,
.input-line:focus,
#grupoInput:hover,
#grupoInput:focus{
  border-bottom:2px solid #0052af;
  box-shadow:0 2px 12px rgba(0,82,175,0.18);
}

#grupoInput{
  width:55px;
}

/* Quitar flechas del input number */
#grupoInput::-webkit-outer-spin-button,
#grupoInput::-webkit-inner-spin-button{
  -webkit-appearance:none;
  margin:0;
}
#grupoInput{
  -moz-appearance:textfield;
  appearance:none;
}

/* ================= BOTONES DEL GRUPO (estilo Recompra) ================= */

.btn-group{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}

.btn-group button{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:12px 20px;
  border-radius:10px;
  border:1.8px solid #cfd6df;
  background:#fff;
  color:#1d2a3d;
  cursor:pointer;
  transition:all .25s ease;
  letter-spacing:.3px;
  font-size:13.5px;
  font-weight:600;
  white-space:nowrap;
  width:auto;
  min-width:fit-content;
  box-shadow:0 4px 14px rgba(0,0,0,.05);
  font-family:Arial, sans-serif;
}

.btn-group button:hover{
  transform:translateY(-1px);
  border-color:#0052af;
  color:#0052af;
}

.btn-group button.activo{
  background:#0052af;
  border-color:#0052af;
  color:#fff;
  box-shadow:0 8px 18px rgba(0,82,175,.18);
}

/* ================= SELECT / INPUT DINÁMICO (BLANCO con texto oscuro) ================= */

#opcionesDinamicas select{
  font-size:13.5px;
  padding:11px 14px;
  width:100%;
  max-width:340px;
  background:#fff;
  color:#1d2a3d;
  border-radius:10px;
  border:1.8px solid #cfd6df;
  cursor:pointer;
  outline:none;
  font-family:Arial, sans-serif;
  font-weight:500;
  box-shadow:0 4px 14px rgba(0,0,0,.05);
  transition:.25s;
}

#opcionesDinamicas select:hover,
#opcionesDinamicas select:focus{
  border-color:#0052af;
}

#opcionesDinamicas select option{
  background:#fff;
  color:#1d2a3d;
}

#opcionesDinamicas .input-full{
  width:100%;
  max-width:340px;
  background:transparent;
  border:none;
  border-bottom:2px solid #000;
  color:#000;
  padding:9px 4px;
  font-size:14px;
  outline:none;
  transition:.3s;
}

#opcionesDinamicas .input-full:focus{
  border-bottom:2px solid #0052af;
  box-shadow:0 2px 12px rgba(0,82,175,0.18);
}

/* ================= BOTONES PRINCIPALES (estilo Recompra, más grandes) ================= */

.send-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:fit-content;
  width:auto;
  max-width:100%;
  height:52px;
  padding:0 28px;
  border:2px solid #000;
  background:#000;
  color:#fff;
  letter-spacing:1px;
  cursor:pointer;
  position:relative;
  overflow:hidden;
  margin-top:0;
  border-radius:12px;
  transition:transform .2s ease, box-shadow .25s ease, border-color .25s ease;
  white-space:nowrap;
  font-family:Arial, sans-serif;
}

.send-btn span{
  position:relative;
  z-index:2;
  font-weight:600;
  font-size:14.5px;
  text-align:center;
  display:inline-flex;
  align-items:center;
  gap:8px;
}

.send-btn::after{
  content:"";
  position:absolute;
  inset:0;
  width:0;
  background:#0052af;
  transition:.35s ease;
  z-index:1;
}

.send-btn:hover::after{
  width:100%;
}

.send-btn:hover{
  transform:translateY(-1px);
  box-shadow:0 10px 22px rgba(0,0,0,.12);
}

.send-btn:active{
  transform:scale(.98);
}

.send-btn:disabled{
  opacity:.55;
  cursor:not-allowed;
  pointer-events:none;
}

.secondary-btn{
  background:linear-gradient(135deg,#111,#2f2f2f);
  color:#fff;
  border-color:#111;
}

.secondary-btn::after{
  background:#0052af;
}

.secondary-btn:hover{
  box-shadow:0 12px 25px rgba(0,0,0,.14);
}

.secondary-btn:active{
  transform:scale(.98);
}

/* ================= ACCIONES INFERIORES ================= */

.acciones-bottom{
  margin-top:32px;
  display:flex;
  gap:12px;
  flex-wrap:wrap;
  align-items:center;
}

.acciones-bottom.doble{
  justify-content:flex-start;
}

/* ================= PANTALLA DE PREGUNTAS ================= */

.quiz-screen{
  animation:fadeInIntro .5s ease;
  display:flex;
  flex-direction:column;
}

.preguntas-scroll{
  display:flex;
  flex-direction:column;
  gap:26px;
  margin-top:8px;
  max-height:60vh;
  overflow-y:auto;
  padding-right:8px;
  padding-bottom:6px;
}

.preguntas-scroll::-webkit-scrollbar{
  width:6px;
}

.preguntas-scroll::-webkit-scrollbar-track{
  background:#f1f1f1;
  border-radius:10px;
}

.preguntas-scroll::-webkit-scrollbar-thumb{
  background:#0052af;
  border-radius:10px;
}

.bloque-pregunta{
  display:flex;
  flex-direction:column;
  gap:8px;
}

.pregunta-num{
  font-size:15px;
  font-weight:400;
  color:#000;
  line-height:1.5;
}

/* Texto resaltado en color MDO dentro de la pregunta personalizada */
.pregunta-num .programa-highlight{
  color:#0052af;
  font-weight:600;
}

.text-line{
  width:100%;
}

.text-line textarea{
  width:100%;
  background:transparent;
  border:none;
  border-bottom:2px solid #000;
  color:#000;
  font-size:14px;
  padding:10px 4px;
  resize:vertical;
  outline:none;
  transition:.35s;
  font-family:Arial, sans-serif;
  min-height:70px;
  line-height:1.5;
}

.text-line textarea:hover{
  border-bottom:2px solid #0052af;
}

.text-line textarea:focus{
  border-bottom:2px solid #0052af;
  box-shadow:0 2px 14px rgba(0,82,175,.15);
}

/* ================= AGRADECIMIENTO (PANTALLA FINAL) ================= */

.agradecimiento{
  width:100%;
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:stretch;
  animation:fadeInIntro .8s ease;
}

.agradecimiento .check-container{
  display:flex;
  justify-content:center;
  margin-bottom:20px;
}

.titulo-final{
  font-size:clamp(22px, 2vw, 30px);
  margin-bottom:18px;
  color:#000;
  line-height:1.25;
  text-align:left;
}

.titulo-final strong{
  color:#0052af;
}

.mensaje-personalizado{
  background:#f7fbff;
  border:1px solid #d7ebff;
  border-radius:14px;
  padding:24px 22px;
  margin-bottom:22px;
  font-size:14.5px;
  line-height:1.6;
  color:#1a1a1a;
  text-align:left;
  width:100%;
  box-shadow:0 4px 14px rgba(0,82,175,.05);
}

.mensaje-personalizado strong{
  color:#0052af;
}

.mensaje-dinamico{
  min-height:60px;
  display:flex;
  align-items:center;
  justify-content:flex-start;
  padding:4px 0;
  margin-bottom:24px;
  width:100%;
}

.mensaje-final{
  width:100%;
  font-size:14px;
  line-height:1.7;
  color:#0052af;
  text-align:justify;
  font-weight:500;
  font-style:italic;
  transition:opacity .5s ease, transform .5s ease;
  padding:0;
}

.visible{
  opacity:1;
  transform:translateY(0);
}

.oculto{
  opacity:0;
  transform:translateY(-8px);
}

.acciones-agradecimiento{
  margin-top:8px;
  display:flex;
  gap:12px;
  flex-wrap:wrap;
  justify-content:flex-start;
  align-items:center;
}

/* ================= ANIMACIÓN ÉXITO ================= */

.subir-agradecimiento{
  transform:translateY(-12px);
  transition:.6s ease;
}

.mensaje-exito{
  margin-top:24px;
  text-align:center;
  animation:fadeIn .6s ease forwards;
  width:100%;
}

.mensaje-exito h2{
  font-size:24px;
  color:#0052af;
  margin-top:14px;
}

.mensaje-exito p{
  margin-top:10px;
  font-size:13px;
  color:#333;
  line-height:1.55;
}

.check-container{
  display:flex;
  justify-content:center;
}

.checkmark{
  width:70px;
  height:70px;
  stroke:#0052af;
  stroke-width:3;
}

.checkmark__circle{
  stroke-dasharray:157;
  stroke-dashoffset:157;
  animation:strokeCircle .6s ease forwards;
}

.checkmark__check{
  stroke-dasharray:48;
  stroke-dashoffset:48;
  animation:strokeCheck .4s .6s ease forwards;
}

@keyframes strokeCircle{
  to{stroke-dashoffset:0;}
}

@keyframes strokeCheck{
  to{stroke-dashoffset:0;}
}

@keyframes fadeIn{
  from{opacity:0;}
  to{opacity:1;}
}

/* ================= LOADING BOTÓN ================= */

.loading-activo{
  background:#0052af;
  border-color:#0052af;
}

.btn-loading{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  position:relative;
  z-index:2;
}

.spinner{
  width:18px;
  height:18px;
  border:3px solid rgba(255,255,255,0.3);
  border-top:3px solid #fff;
  border-radius:50%;
  animation:spin .8s linear infinite;
}

@keyframes spin{
  to{transform:rotate(360deg);}
}

/* ================= BLOQUEO (3 intentos máximo) ================= */

#lockScreen{
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:stretch;
  padding:20px 0;
  animation:fadeInIntro .8s ease;
}

#lockScreen .check-container{
  display:flex;
  justify-content:center;
  margin-bottom:20px;
}

.lock-title{
  margin-bottom:18px;
  font-size:clamp(22px, 2vw, 30px);
  color:#000;
  text-align:left;
  line-height:1.25;
}

.lock-title strong{
  color:#0052af;
}

.lock-mensaje{
  background:#f7fbff;
  border:1px solid #d7ebff;
  border-radius:14px;
  padding:24px 22px;
  margin-bottom:22px;
  font-size:14.5px;
  line-height:1.6;
  color:#1a1a1a;
  text-align:justify;
  width:100%;
  box-shadow:0 4px 14px rgba(0,82,175,.05);
}

.lock-mensaje strong{
  color:#0052af;
  font-weight:700;
}

/* ================= LAPTOP - PANEL IZQUIERDO FIJO ================= */

@media (min-width: 1024px){
  .app{
    align-items:flex-start;
  }

  .left{
    position:sticky;
    top:0;
    height:100vh;
    align-self:flex-start;
  }

  .right{
    min-height:100vh;
  }
}