<div class="accordion accordion-bordered mt-3" id="accordionOtTasks">
    <div class="card accordion-item active">
        <h2 class="accordion-header">
            <button type="button" class="accordion-button" data-bs-toggle="collapse" data-bs-target="#accordionOtTasksTip" aria-expanded="false" aria-controls="accordionOtTasksTip">

                <div class="d-flex flex-row justify-content-start align-items-stretch gap-2">
                    <span><i class="ti-subtask ti-md ti"></i></span>
                    <h4> Tareas </h4>
                </div>
            </button>
        </h2>

        <div id="accordionOtTasksTip" class="accordion-collapse collapse show" data-bs-parent="#accordionOtTasks">
            <div class="accordion-body">
                <div class="card text-center">
                    <div class="card-header">
                        <div class="nav-align-top">
                            <ul class="nav nav-pills" role="tablist">
                                <li class="nav-item">
                                    <button type="button" class="nav-link d-flex flex-column gap-1 active" role="tab" data-bs-toggle="tab" data-bs-target="#nav-ot-task-general" aria-controls="nav-ot-task-general-active" aria-selected="true">Tareas</button>
                                </li>
                                <li class="nav-item">
                                    <button type="button" class="nav-link d-flex flex-column gap-1" role="tab" data-bs-toggle="tab" data-bs-target="#nav-ot-task-preimpresion" aria-controls="nav-ot-task-preimpresion" aria-selected="false">Preimpresion</button>
                                </li>
                                <li class="nav-item">
                                    <button type="button" class="nav-link d-flex flex-column gap-1" role="tab" data-bs-toggle="tab" data-bs-target="#nav-ot-task-ferro-envio" aria-controls="nav-ot-task-ferro-envio" aria-selected="false">Ferros y envíos</button>
                                </li>

                            </ul>
                        </div>
                    </div>
                    <!-- CARD BODY -->
                    <div class="card-body">
                        <div class="tab-content p-0">
                            <!-- TAREAS -->
                            <div class="tab-pane fade show active" id="nav-ot-task-general" role="tabpanel">
                                <div class="row text-start">
                                    <div class="col-md-12">

                                        <?= view("themes/vuexy/components/tables/ot_task_table", ["id" => "ot-task-table"]) ?>
                                    </div>
                                </div>

                                <div class="row d-flex flex-row justify-content-between align-items-center mt-2 gap-2">
                                    <div class="col-md-3 text-start">
                                        <!-- <button type="button" class="btn btn-primary btn-md align-items-center" id="btn-add-tarea"><span class="ti ti-plus ti-sm me-1"></span> Insertar tarea</button> -->
                                    </div>
                                    <div class="col-md-3 gap-2 text-end">
                                        <!-- <button type="button" class="btn btn-warning btn-md" id="btn-reset-tareas-time"><span class="ti ti-clock ti-sm me-1"></span> Actualizar tiempo</button> -->
                                        <?php if (!$is_finalizada): ?>
                                            <button type="button" class="btn btn-danger btn-md" id="btn-reset-tareas"><span class="ti ti-trash ti-sm me-1"></span> Reiniciar tareas</button>
                                        <?php endif; ?>
                                    </div>
                                </div>
                            </div>
                            <!-- PREIMPRESION -->
                            <div class="tab-pane fade" id="nav-ot-task-preimpresion" role="tabpanel">
                                <div class="row text-start">
                                    <?= view("themes/vuexy/form/produccion/ot/otPreimpresionReview") ?>
                                </div>
                            </div>
                            <!-- FERROS Y ENVIOS -->
                            <div class="tab-pane fade" id="nav-ot-task-ferro-envio" role="tabpanel">
                                <div class="row text-start">
                                    <?= view("themes/vuexy/form/produccion/ot/otFerrosEnvios") ?>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>