<div class="">
    <div class="page-title">
        <div class="title_left">
            <h3>Temario</h3>
        </div>
    </div>
    <div class="clearfix"></div>
    <div class="row">
        <div class="col-md-12 col-sm-12 col-xs-12">
            <div class="x_panel">
                <div class="x_title">
                    <h2>Registrar un nuevo temario</h2>
                    <div class="clearfix"></div>
                </div>
                <div class="x_content">
                    <form id="form-nueva" data-parsley-validate class="form-horizontal form-label-left"
                        enctype="multipart/form-data">
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-form-label col-md-8 col-sm-10 col-xs-12 text-left">
                                <label class="text-sm-left" for="materia">Materia <span class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <select id="materia" name="materia" required="required"
                                    class="form-control form-control-sm">
                                    <option value="">--Seleccione--</option>
                                    @foreach ($mat as $m)
                                        <option value="{{ $m->cve_mat }}">{{ $m->nombre_mat }}</option>
                                    @endforeach
                                </select>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_materiaf" style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-form-label col-md-8 col-sm-10 col-xs-12 text-left">
                                <label class="text-sm-left" for="horasT">Horas
                                    teóricas <span class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <input type="text" id="horasT" name="horasT" required="required"
                                    class="form-control form-control-sm" oninput="total_horas_materias()">
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                                <div class="alert alert-danger" role="alert" id="a_horasT" style="display: none">
                                </div>
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_horasT" style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-form-label col-md-8 col-sm-10 col-xs-12 text-left">
                                <label class="text-sm-left" for="horasP">Horas
                                    practicas <span class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <input type="text" id="horasP" name="horasP" required="required"
                                    class="form-control form-control-sm" oninput="total_horas_materias()">
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_horasP" style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-form-label col-md-8 col-sm-10 col-xs-12 text-left">
                                <label class="text-sm-left" for="totalH">Total
                                    de horas <span class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <input type="text" id="totalH" name="totalH" required="required"
                                    class="form-control form-control-sm" disabled>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-form-label col-md-8 col-sm-10 col-xs-12 text-left">
                                <label class="text-sm-left" for="caracterasig">Caracterización de la asignatura<span
                                        class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <textarea class="form-control form-control-sm" id="caracterasig" name="caracterasig" rows="8"
                                    style="resize: none"></textarea>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_caracter"
                                    style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-form-label col-md-8 col-sm-10 col-xs-12 text-left">
                                <label class="text-sm-left" for="intencion">Intención didáctica<span
                                        class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <textarea class="form-control form-control-sm" id="intencion" name="intencion" rows="8" style="resize: none"></textarea>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_intencion"
                                    style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-form-label col-md-8 col-sm-10 col-xs-12 text-left">
                                <label class="text-sm-left" for="competenciasdesa">Competencias
                                    a desarrollar <span class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <textarea class="form-control form-control-sm" id="competenciasdesa" name="competenciasdesa" rows="5"
                                    style="resize: none"></textarea>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_comdesa" style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-form-label col-md-8 col-sm-10 col-xs-12 text-left">
                                <label class="text-sm-left" for="competenciaspre">Competencias
                                    previas <span class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <textarea class="form-control form-control-sm" id="competenciaspre" name="competenciaspre" rows="5"
                                    style="resize: none"></textarea>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_compre" style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-form-label col-md-8 col-sm-10 col-xs-12 text-left">
                                <label class="text-sm-left" for="numero">No.
                                    de la unidad <span class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <input type="text" id="numero" name="numero" required="required"
                                    class="form-control form-control-sm">
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_numero" style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-form-label col-md-8 col-sm-10 col-xs-12 text-left">
                                <label class="text-sm-left" for="tema">Tema
                                    <span class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <input type="text" id="tema" name="tema" required="required"
                                    class="form-control form-control-sm">
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_tema" style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <label class="text-sm-left" for="subtema">Subtema <span class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <textarea class="form-control form-control-sm" id="subtema" name="subtema" rows="7" style="resize: none"></textarea>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1">
                                <button type="button" class="btn btn-secondary" onClick="mas_unidades()"><i
                                        class="fa fa-plus"></i>
                                </button>
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_subtema" style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div id="contenedor_unidades">
                        </div>
                        <br>
                        <div id="act_apren">
                        </div>
                        <div id="contenedor_competencias">
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <label class="text-sm-left" for="practica">Práctica<span class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <textarea class="form-control form-control-sm" id="practica" name="practica" rows="5" style="resize: none"></textarea>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_practica"
                                    style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <label class="text-sm-left" for="proyecasig">Proyecto de asignatura<span
                                        class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <textarea class="form-control form-control-sm" id="proyecasig" name="proyecasig" rows="5"
                                    style="resize: none"></textarea>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_proyecasig"
                                    style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <label class="text-sm-left" for="evalcom">Evaluación por competencias<span
                                        class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <textarea class="form-control form-control-sm" id="evalcom" name="evalcom" rows="5" style="resize: none"></textarea>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_evalcom" style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>

                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <label class="text-sm-left" for="fuenteinf">Fuentes de información<span
                                        class="required">*</span>
                                </label>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <textarea class="form-control form-control-sm" id="fuenteinf" name="fuenteinf" rows="5" style="resize: none"></textarea>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="mb-1 row">
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                            <div class="col-md-8 col-sm-10 col-xs-12">
                                <div class="alert alert-danger" role="alert" id="a_fuenteinf"
                                    style="display: none">
                                </div>
                            </div>
                            <div class="col-form-label col-md-2 col-sm-1 d-none d-sm-block">
                            </div>
                        </div>
                        <div class="ln_solid"></div>
                        <div class="mb-1 row">
                            <div class="col-md-3 col-sm-12"></div>
                            <div class="col-md-6 col-sm-12">
                                <div class="row">
                                    <div class="col">
                                        <button class="btn btn-dark btn-block" type="button"
                                            onclick="listado_temario()"><i class="fa fa-times"></i>
                                            Cancelar</button>
                                    </div>
                                    <div class="col">
                                        <button type="button" onclick="add_unidad(this.form)"
                                            class="btn btn-success btn-block" form="form-nueva"><i
                                                class=" fa fa-pencil"></i> Guardar </button>
                                    </div>
                                </div>
                            </div>
                            <div class="col-md-3 col-sm-12"></div>
                        </div>
                    </form>
                    <br>
                </div>
            </div>
        </div>
    </div>
</div>
