/* Converly Form Indemniplus - Estilos */

/* Wrapper principal - se adapta al contenedor padre */
.converly-form-wrapper {
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
}

/* Contenedor del formulario */
.cf-container {
  width: 100%;
  padding: 32px;
  box-sizing: border-box;
  font-family: inherit;
  background-color: #f2f0e8;
  border-radius: 8px;
}

/* Título */
.cf-title {
  font-size: 28px;
  font-weight: 700;
  color: inherit;
  margin: 0 0 12px 0;
  text-align: center;
  font-family: inherit;
}

/* Descripción */
.cf-description {
  font-size: 16px;
  color: inherit;
  opacity: 0.8;
  text-align: center;
  margin: 0 0 28px 0;
  line-height: 1.6;
  font-family: inherit;
}

/* Alertas */
.cf-alert {
  padding: 16px 20px;
  border-radius: 6px;
  margin-bottom: 24px;
  font-size: 15px;
  line-height: 1.5;
  font-family: inherit;
}

.cf-alert-success {
  background-color: #d4edda;
  border: 1px solid #c3e6cb;
  color: #155724;
}

.cf-alert-error {
  background-color: #f8d7da;
  border: 1px solid #f5c6cb;
  color: #721c24;
}

/* Formulario */
.cf-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Filas de campos */
.cf-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

/* Campo individual */
.cf-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* Label */
.cf-label {
  font-size: 14px;
  font-weight: 600;
  color: inherit;
  display: flex;
  align-items: center;
  gap: 4px;
  font-family: inherit;
}

/* Asterisco obligatorio */
.cf-required {
  color: #d9534f;
  font-weight: 700;
}

/* Input base */
.cf-input {
  width: 100%;
  padding: 12px 14px;
  font-size: 15px;
  color: #333;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  font-family: inherit;
  box-sizing: border-box;
}

.cf-input:focus {
  outline: none;
  border-color: #D7B186;
  box-shadow: 0 0 0 2px rgba(215, 177, 134, 0.15);
}

.cf-input:disabled {
  background: #f5f5f5;
  cursor: not-allowed;
  opacity: 0.7;
}

.cf-input-error {
  border-color: #d9534f;
}

.cf-input-error:focus {
  border-color: #d9534f;
  box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.15);
}

/* Texto de error */
.cf-error-text {
  font-size: 13px;
  color: #d9534f;
  font-family: inherit;
}

/* Grupo de teléfono */
.cf-phone-group {
  display: flex;
  gap: 8px;
}

.cf-phone-select {
  flex-shrink: 0;
  width: 110px;
  padding: 12px 8px;
  font-size: 15px;
  color: #333;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
  transition: border-color 0.2s ease;
  cursor: pointer;
  font-family: inherit;
  box-sizing: border-box;
}

.cf-phone-select:focus {
  outline: none;
  border-color: #D7B186;
  box-shadow: 0 0 0 2px rgba(215, 177, 134, 0.15);
}

.cf-phone-select:disabled {
  background: #f5f5f5;
  cursor: not-allowed;
  opacity: 0.7;
}

.cf-phone-input {
  flex: 1;
}

/* Textarea */
.cf-textarea {
  resize: vertical;
  min-height: 100px;
  line-height: 1.5;
}

/* Botón de envío */
.cf-submit-btn {
  width: 100%;
  padding: 14px 28px;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
  background: #D7B186;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.1s ease;
  margin-top: 8px;
  font-family: inherit;
}

.cf-submit-btn:hover:not(:disabled) {
  background: #c9a375;
}

.cf-submit-btn:active:not(:disabled) {
  transform: scale(0.98);
}

.cf-submit-btn:disabled {
  background: #ccc;
  cursor: not-allowed;
}

/* Responsive */
@media (max-width: 768px) {
  .cf-container {
    padding: 24px 16px;
  }

  .cf-title {
    font-size: 24px;
  }

  .cf-row {
    grid-template-columns: 1fr;
  }

  .cf-phone-select {
    width: 100px;
  }
}

@media (max-width: 480px) {
  .cf-container {
    padding: 20px 12px;
  }

  .cf-title {
    font-size: 20px;
  }

  .cf-phone-group {
    flex-direction: column;
  }

  .cf-phone-select {
    width: 100%;
  }
}
