/* ===== Reset ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ===== Fondo general ===== */
body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(135deg, rgb(0, 0, 34) 0%, white 100%);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

/* ===== Contenedor principal ===== */
.container {
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  max-width: 600px;
  width: 100%;
  overflow: hidden;
  transition: all 0.3s ease;
}

/* ===== Encabezado ===== */
.header {
  background: linear-gradient(135deg, #ffffff 0%, #ffffff 100%);
  padding: 40px 30px;
  text-align: center;
  color: rgb(6, 0, 0);
}

/* ===== Contenedor del logo (ajustado para evitar recorte) ===== */
.logo-container {
  background: #fff;
  width: 120px;
  height: 120px;
  margin: 0 auto 20px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  padding: 10px; /* Espacio interior para evitar cortes */
}

/* Imagen del logo */
.logo-container img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* Evita recortes y mantiene proporción */
  border-radius: 50%; /* Mantiene forma redonda limpia */
  display: block;
}

/* ===== Títulos ===== */
.header h1 {
  font-size: 28px;
  margin-bottom: 10px;
}

.header p {
  font-size: 16px;
  opacity: 0.9;
}

/* ===== Formulario ===== */
.form-container {
  padding: 40px 30px;
}

.form-group {
  margin-bottom: 25px;
}

label {
  display: block;
  margin-bottom: 8px;
  color: #333;
  font-weight: 600;
  font-size: 14px;
}

label .required {
  color: #e74c3c;
}

input[type="text"],
input[type="email"],
input[type="tel"],
select,
textarea {
  width: 100%;
  padding: 12px 15px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 15px;
  transition: all 0.3s ease;
  font-family: inherit;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

textarea {
  resize: vertical;
  min-height: 120px;
}

/* Flechita select */
select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 15px center;
  padding-right: 40px;
}

/* ===== Checkbox ===== */
.checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

input[type="checkbox"] {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  cursor: pointer;
  accent-color: #667eea;
}

.checkbox-group label {
  margin: 0;
  font-weight: 400;
  font-size: 13px;
  cursor: pointer;
}

.checkbox-group a {
  color: #667eea;
  text-decoration: none;
}

.checkbox-group a:hover {
  text-decoration: underline;
}

/* ===== Errores ===== */
.error-message {
  color: #e74c3c;
  font-size: 12px;
  margin-top: 5px;
  display: none;
}

.form-group.error input,
.form-group.error select,
.form-group.error textarea {
  border-color: #e74c3c;
}

.form-group.error .error-message {
  display: block;
}

/* ===== Botón ===== */
.submit-btn {
  width: 100%;
  padding: 15px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(102, 126, 234, 0.4);
}

.submit-btn:active {
  transform: translateY(0);
}

.submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* ===== Éxito ===== */
.success-message {
  background: #d4edda;
  color: #155724;
  padding: 15px;
  border-radius: 8px;
  margin-bottom: 20px;
  display: none;
}

/* ===== RESPONSIVE ===== */

/* Tablets */
@media (max-width: 900px) {
  body {
    padding: 15px;
  }

  .container {
    max-width: 90%;
  }

  .header h1 {
    font-size: 24px;
  }

  .header p {
    font-size: 14px;
  }
}

/* Celulares */
@media (max-width: 600px) {
  .container {
    border-radius: 0;
    box-shadow: none;
    max-width: 100%;
  }

  .form-container {
    padding: 25px 15px;
  }

  .header {
    padding: 25px 15px;
  }

  .logo-container {
    width: 90px;
    height: 90px;
    padding: 8px;
  }

  .header h1 {
    font-size: 22px;
  }

  .header p {
    font-size: 13px;
  }

  label {
    font-size: 13px;
  }

  input, select, textarea {
    font-size: 14px;
    padding: 10px 12px;
  }

  .submit-btn {
    font-size: 15px;
    padding: 12px;
  }
}

/* Muy pequeñas (teléfonos antiguos) */
@media (max-width: 400px) {
  .header h1 {
    font-size: 20px;
  }

  .logo-container {
    width: 80px;
    height: 80px;
    padding: 6px;
  }
}
