:root {
  --azul: #005a9c;
  --verde: #5cb85c;
  --blanco: #ffffff;
  --gris: #f5f7fa;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", sans-serif;
}

body {
  background: var(--gris);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 40px;
}

.contenedor {
  max-width: 900px;
  width: 100%;
  background: white;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.encabezado {
  background: linear-gradient(135deg, var(--azul), #0a7bd9);
  color: white;
  text-align: center;
  padding: 40px;
}

.encabezado img {
  width: 120px;
  margin-bottom: 15px;
}

.encabezado h1 {
  margin-bottom: 15px;
}

form {
  padding: 40px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.grupo {
  display: flex;
  flex-direction: column;
}

.grupo:last-child {
  grid-column: 1/3;
}

label {
  margin-bottom: 5px;
  font-weight: 600;
}

input,
select,
textarea {
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 10px;
}

textarea {
  min-height: 120px;
}

.check {
  grid-column: 1/3;
}

button {
  grid-column: 1/3;
  padding: 15px;
  border: none;
  background: var(--verde);
  color: white;
  font-size: 18px;
  border-radius: 10px;
  cursor: pointer;
}

button:hover {
  background: #49a649;
}

#respuesta {
  grid-column: 1/3;
  text-align: center;
  font-weight: bold;
  color: green;
}

.modal-exito {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;

  opacity: 0;
  visibility: hidden;
  transition: 0.3s;
}

.modal-exito.activo {
  opacity: 1;
  visibility: visible;
}

.modal-contenido {
  background: white;
  width: 90%;
  max-width: 500px;
  padding: 40px;
  border-radius: 20px;
  text-align: center;
  animation: aparecer 0.4s ease;
}

.checkmark {
  width: 90px;
  height: 90px;
  margin: auto;
  margin-bottom: 20px;
  border-radius: 50%;
  background: #28a745;
  color: white;
  font-size: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-contenido h2 {
  color: #005a9c;
  margin-bottom: 15px;
}

.modal-contenido p {
  color: #555;
  line-height: 1.6;
  margin-bottom: 10px;
}

.modal-contenido button {
  margin-top: 20px;
  background: #005a9c;
  color: white;
  border: none;
  padding: 12px 30px;
  border-radius: 10px;
  cursor: pointer;
}

.modal-contenido button:hover {
  background: #00457a;
}
.btn-volver {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.15);
  color: var(--azul);
  text-decoration: none;
  padding: 12px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  margin-bottom: 1px;
  transition: 0.3s;
  font-weight: 600;
  backdrop-filter: blur(10px);
}

.btn-volver:hover {
  background: white;
  color: var(--verde);
  transform: translateX(-3px);
}

@keyframes aparecer {
  from {
    transform: translateY(-30px);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@media (max-width: 768px) {
  form {
    grid-template-columns: 1fr;
  }

  button,
  .check,
  #respuesta,
  .grupo:last-child {
    grid-column: auto;
  }
}
