@if(!empty($course->chapters) and count($course->chapters))
    <section class="cp-curriculum__chapters">
        @include('web.default.course.tabs.contents.chapter')
    </section>
@endif

@if(!empty($sessionsWithoutChapter) and count($sessionsWithoutChapter))
    <section class="cp-curriculum__block mt-20">
        <div class="accordion-content-wrapper" id="sessionsAccordion" role="tablist" aria-multiselectable="true">
            @foreach($sessionsWithoutChapter as $session)
                @include('web.default.course.tabs.contents.sessions', ['session' => $session, 'accordionParent' => 'sessionsAccordion'])
            @endforeach
        </div>
    </section>
@endif

@if(!empty($filesWithoutChapter) and count($filesWithoutChapter))
    <section class="cp-curriculum__block mt-20">
        <div class="accordion-content-wrapper" id="filesAccordion" role="tablist" aria-multiselectable="true">
            @foreach($filesWithoutChapter as $file)
                @include('web.default.course.tabs.contents.files', ['file' => $file, 'accordionParent' => 'filesAccordion'])
            @endforeach
        </div>
    </section>
@endif

@if(!empty($textLessonsWithoutChapter) and count($textLessonsWithoutChapter))
    <section class="cp-curriculum__block mt-20">
        <div class="accordion-content-wrapper" id="textLessonsAccordion" role="tablist" aria-multiselectable="true">
            @foreach($textLessonsWithoutChapter as $textLesson)
                @include('web.default.course.tabs.contents.text_lessons', ['textLesson' => $textLesson, 'accordionParent' => 'textLessonsAccordion'])
            @endforeach
        </div>
    </section>
@endif

@if(!empty($quizzes) and $quizzes->count() > 0)
    <section class="cp-curriculum__block mt-20">
        <h3 class="cp-curriculum__subheading">{{ trans('update.quiz_and_certificates') }}</h3>
        <div class="accordion-content-wrapper" id="quizAccordion" role="tablist" aria-multiselectable="true">
            @foreach($quizzes as $quiz)
                @include('web.default.course.tabs.contents.quiz', ['quiz' => $quiz, 'accordionParent' => 'quizAccordion'])
            @endforeach
        </div>
    </section>
    <section class="cp-curriculum__block">
        @include('web.default.course.tabs.contents.certificate', ['quizzes' => $course->quizzes])
    </section>
@endif

@include('web.default.course.tabs.play_modal.play_modal')
