/*--------------------------------------------------
  Import Google Fonts
--------------------------------------------------*/
@import url('https://fonts.googleapis.com/css2?family=Mulish:ital,wght@0,200..1000;1,200..1000&family=Source+Sans+3:ital,wght@0,200..900;1,200..900&display=swap');

/*--------------------------------------------------
  Base Styles & Typography
--------------------------------------------------*/
body {
    margin: 0;
    padding: 0;
    font-family: "Mulish", sans-serif;
}

.course-catalog-wrapper {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0;
}

/*--------------------------------------------------
  Headings & Labels
--------------------------------------------------*/
body header .et_builder_inner_content {
    z-index: 1;
}

.grade-level-label {
    font-family: "Mulish", sans-serif;
    font-weight: 800;
    font-size: 24px;
    margin-bottom: 30px;
}

.course-search-container h3 {
    font-family: "Mulish", sans-serif;
    font-weight: 800;
    font-size: 24px;
    margin-bottom: 19px;
    padding-bottom: 0;
}

.category-filters h3,
.department-filters h3,
.semester-filters h3 {
    font-family: "Mulish", sans-serif;
    font-size: 24px;
    font-weight: 800;
    margin-bottom: 10px;
}

.catalog-left-col h2 {
    font-family: "Mulish", sans-serif;
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 34px;
    text-decoration: underline;
    text-underline-offset: 15px;
}

.catalog-left-col .category-group h3 {
    font-family: "Mulish", sans-serif;
    font-size: 32px;
    font-weight: 700;
    margin: 0;
    padding: 0;
    line-height: 45px;
}

.department-group h4 {
    font-family: "Source Sans 3", sans-serif;
    font-size: 30px;
    font-weight: 600;
    margin-top: 41px;
    margin-bottom: 30px;
    padding: 0;
    line-height: 40px;
}

/* Course item titles and no-courses message */
.course-item h5,
#no-courses-message {
    font-family: "Mulish", sans-serif;
    font-size: 22px;
    font-weight: 800;
    margin: 0;
    line-height: 25px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.course-item p {
    font-family: "Source Sans 3", sans-serif;
    font-size: 16px;
    font-weight: 400;
    margin-bottom: 34px;
    line-height: 20px;
}

/* Utility for SVG icons */
.arrow-icon svg {
    width: 20px;
}

/*--------------------------------------------------
  Grade Filters (Top Buttons)
--------------------------------------------------*/
/* .grade-filters-wrapper {
    margin-bottom: 30px;
} */

.grade-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 10px;
}

.grade-filters button {
    font-family: "Mulish", sans-serif;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 400;
    padding: 10px 20px;
    transition: background-color 0.3s ease;
    width: 283px;
    text-align: left;
}

/*--------------------------------------------------
  Two-Column Layout
--------------------------------------------------*/
.catalog-two-columns {
    display: flex;
    gap: 30px;
}

.catalog-left-col {
    flex: 3;
    padding: 70px 50px;
}

.catalog-right-col {
    flex: 1.3;
    display: flex;
    flex-direction: column;
    padding: 70px 50px;
    background-color: #f5f5f5;
}

/*--------------------------------------------------
  Category & Department Filters
--------------------------------------------------*/

.course-cat-popup-icon {
    height: 16px;
    margin-right: 14px;
}

.course-cat-redo-icon {
    height: 16px;
    margin-right: 6px;
}

/* Category filter select box */
.category-filters select {
    width: 100%;
    font-size: 16px;
    /* margin-bottom: 37px; */
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20512%20512'%3E%3Cpath%20fill='%2354575a'%20d='M233.4%20406.6c12.5%2012.5%2032.8%2012.5%2045.3%200l192-192c12.5-12.5%2012.5-32.8%200-45.3s-32.8-12.5-45.3%200L256%20338.7%2086.6%20169.4c-12.5-12.5-32.8-12.5-45.3%200s-12.5%2032.8%200%2045.3l192%20192z'%3E%3C/path%3E%3C/svg%3E") no-repeat right 10px center;
    background-size: 20px 20px;
    padding: 10px 40px 10px 10px;
    cursor: pointer;
    border-radius: 3px;
}

.arrow-icon {
    height: 30px;
    display: flex;
    margin-right: 12px;
}

/* Department and semester filter headings */
.department-filters h3,
.semester-filters h3 {
    margin-top: 0;
}

/* Department filter containers and dropdowns */
.dept-filter-container {
    margin-bottom: 10px;
}

.dept-dropdown {
    margin-top: 10px;
}

.dept-dropdown-trigger,
.semester-dropdown-trigger {
    border: none;
    cursor: pointer;
    padding: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: "Mulish", sans-serif;
    font-size: 18px;
    font-weight: 800;
    line-height: 25px;
    text-align: left;
}

/* Divider line for filter grouping */
.divider-line {
    padding-bottom: 15px;
}

/* Label styling within department/semester filters */
.department-filter label,
.semester-filter label {
    display: block;
    margin: 5px 0;
    font-family: "Source Sans 3", sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 20px;
}

/* .semester-filter {
    margin-bottom: 40px;
} */

/* Styling for checkbox inputs inside filters */
.department-filter label input,
.semester-filter label input {
    margin-bottom: 5px;
    float: left;
    width: 5%;
}

/* Reset filter buttons */
.reset-department-filters,
.reset-semester-filters {
    border: none;
    cursor: pointer;
    padding: 0;
    margin-bottom: 15px;
    font-family: "Source Sans 3", sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 20px;
    transition: color 0.3s ease;
    display: flex;
}

/*--------------------------------------------------
  Course Grid
--------------------------------------------------*/
.grade-container {
    margin-bottom: 40px;
}

.category-group {
    margin-bottom: 20px;
}

.department-group {
    margin-bottom: 10px;
}

.course-item {
    margin-bottom: 15px;
}

/*--------------------------------------------------
  Modal Windows
--------------------------------------------------*/
.course-modal {
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    display: none;
}

.course-modal-content {
    margin: 20px auto;
    padding: 20px;
    width: 90%;
    max-width: 600px;
    position: relative;
    border-radius: 10px;
}

/* Modal close buttons */
.course-modal-close,
.dynamic-modal-close,
.prereq-modal-close {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

/* Modal headings and labels */
.course-modal-title,
.prereq-modal-title {
    font-family: "Mulish", sans-serif;
    font-size: 22px;
    font-weight: 800;
    margin-bottom: 25px;
    padding: 0;
    line-height: 25px;
}

.course-modal-required-label,
.course-modal-semester-label,
.course-modal-prereq-label {
    font-family: "Source Sans 3", sans-serif;
    font-size: 16px;
    font-weight: 700;
    line-height: normal;
    margin: 0;
}

.course-modal-grades,
.course-modal-desc,
.course-modal-required,
.course-modal-semester,
.course-modal-prereq {
    margin-bottom: 10px;
    font-family: "Source Sans 3", sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 20px;
}

/* Prerequisite buttons */
.prereq-button {
    border: none;
    border-radius: 4px;
    cursor: pointer;
    padding: 8px 16px;
    font-family: "Mulish", sans-serif;
    font-size: 12px;
    font-weight: 800;
    transition: all 0.3s ease;
    margin-bottom: 3px;
}

/* Modal action buttons */
.course-modal-close-btn,
.prereq-modal-close-btn,
.dynamic-modal-close-btn {
    border: none;
    border-radius: 4px;
    cursor: pointer;
    padding: 8px 16px;
    font-family: "Mulish", sans-serif;
    font-size: 18px;
    font-weight: 800;
    display: flex;
    margin: 15px auto 0;
    justify-content: center;
    width: 250px;
    transition: all 0.3s ease;
}

/* Modal close icon sizes */
.course-modal-close svg,
.prereq-modal-close svg,
.dynamic-modal-close svg {
    width: 15px;
}

.hidden {
    display: none !important;
}

/*--------------------------------------------------
  Slick Slider Customization in Prereq Modal
--------------------------------------------------*/
/* Container for the slider inside the prerequisite modal */
.prereq-slider-container {
    margin-top: 20px;
    padding-top: 10px;
    border-top: 1px solid #ddd;
}

/* Styling for each slide in the slider */
.prereq-slider .prereq-slide {
    padding: 20px;
    background-color: #fff;
    border: 1px solid #eaeaea;
    border-radius: 4px;
    position: relative;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/* Styling for the slide close button */
.prereq-slider .prereq-slide .slider-close {
    position: absolute;
    top: 10px;
    right: 10px;
    cursor: pointer;
    width: 20px;
    height: 20px;
    fill: #888b8d;
}

/* Custom Slick arrows styling in the prerequisite modal */
#prereq-modal .slick-prev,
#prereq-modal .slick-next {
    background-color: rgba(0, 0, 0, 0.5);
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
}

#prereq-modal .slick-prev:hover,
#prereq-modal .slick-next:hover {
    background-color: rgba(0, 0, 0, 0.7);
}

/* Center and style Slick slider dot navigation in the prerequisite modal */
#prereq-modal .slick-dots {
    text-align: center;
    bottom: 24px;
    width: 100%;
    padding: 0;
    margin: 10px 0 0 0;
}

#prereq-modal .slick-dots li {
    display: inline-block;
    margin: 0 4px;
}

#prereq-modal .slick-dots li button {
    color: #ccc;
    opacity: 1;
    transition: color 0.3s ease;
    border-radius: 100%;
    border: 1px solid;
    font-family: "Mulish", sans-serif;
    font-size: 15px;
    font-weight: 800;
}

#prereq-modal .slick-dots li.slick-active button {
    color: #333;
}

/* Custom SVG arrows for Slick slider */
/* Left arrow */
#prereq-modal .slick-prev:before {
    content: "";
    display: block;
    width: 32px;
    height: 32px;
    background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 448 512'><path d='M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l160 160c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L109.2 288 416 288c17.7 0 32-14.3 32-32s-14.3-32-32-32l-306.7 0L214.6 118.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-160 160z'/></svg>") no-repeat center center;
    background-size: contain;
}

/* Right arrow */
#prereq-modal .slick-next:before {
    content: "";
    display: block;
    width: 32px;
    height: 32px;
    background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 448 512'><path d='M438.6 278.6c12.5-12.5 12.5-32.8 0-45.3l-160-160c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L338.8 224 32 224c-17.7 0-32 14.3-32 32s14.3 32 32 32l306.7 0L233.4 393.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l160-160z'/></svg>") no-repeat center center;
    background-size: contain;
}

/* Brighten arrows on hover */
#prereq-modal .slick-prev:hover:before,
#prereq-modal .slick-next:hover:before {
    filter: brightness(1.2);
}

.search-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    /* margin-bottom: 30px; */
}

#course-search {
    width: 100%;
    font-size: 16px;
    padding: 10px 40px 10px 10px;
    cursor: pointer;
    border-radius: 3px;
}

#clear-search-btn {
    position: absolute;
    right: 10px;
    background: none;
    border: none;
    font-size: 20px;
    color: #999;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

#clear-search-btn:hover {
    color: #333;
}

/* Scroll-to-top Button */
#scrollToTopBtn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    font-size: 10px;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

#scrollToTopBtn svg {
    width: 20px;
}

/*--------------------------------------------------
  Responsive Design (screens < 980px)
--------------------------------------------------*/
@media (max-width: 980px) {

    .course-search-container h3,
    .category-filters h3,
    .department-filters {
        margin-top: 30px;
    }

	.course-search-container {
        margin-bottom: 35px;
    }
	
/*     .search-input-wrapper {
        display: none !important;
    } */

    /* Stack columns for mobile view */
    .catalog-two-columns {
        display: block;
    }

    .catalog-right-col,
    .catalog-left-col {
        width: 100%;
        margin: 0;
        padding: 0;
    }

    /* Mobile Filter Button */
    #mobile-filter-btn {
        z-index: 100;
        border: none;
        border-radius: 4px;
        cursor: pointer;
        padding: 8px 16px;
        font-family: "Mulish", sans-serif;
        font-size: 18px;
        font-weight: 800;
        display: flex;
        margin: 28px auto 37px;
        justify-content: center;
        width: 150px;
        transition: all 0.3s ease;
    }

    /* Mobile Filter Modal styling */
    #mobile-filter-modal {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 1000000 !important;
    }

    #mobile-filter-modal .modal-content {
        height: 100%;
        overflow-y: auto;
        position: relative;
        box-sizing: border-box;
    }

    #mobile-filter-modal .modal-header {
        position: sticky;
        top: 0;
        left: 0;
        right: 0;
        padding: 10px;
        text-align: right;
        z-index: 100;
    }

    #mobile-filter-modal .modal-header h4 {
        text-align: center;
        font-family: "Mulish", sans-serif;
        font-size: 30px;
        font-weight: 900;
        line-height: 35px;
    }

    #mobile-filter-modal .modal-header button {
        border: none;
        border-radius: 4px;
        cursor: pointer;
        padding: 8px 16px;
        font-family: "Mulish", sans-serif;
        font-size: 18px;
        font-weight: 800;
        display: flex;
        margin: 5px auto;
        justify-content: center;
    }

    .catalog-left-col .category-group h3 {
        font-size: 24px;
        margin-bottom: 34px;
        padding-top: 7px;
        padding-bottom: 12px;
        padding-left: 30px;
        padding-right: 30px;
        background-color: #f5f5f5;
    }

    .modal-body .catalog-left-col .category-group h3,
    .modal-body .grade-level-label,
    .modal-body .catalog-left-col h2,
    .modal-body .dept-dropdown-trigger, 
    .modal-body .semester-dropdown-trigger,
    .modal-body .reset-department-filters, 
    .modal-body .reset-semester-filters {
        background-color: #fff;
    }

    .category-group {
        margin-bottom: -10px;
    }

    .modal-body .grade-filters button {
        width: 100%;
    }

    .modal-body .grade-filters-wrapper {
        margin-top: 20px;
    }

    .department-group {
        padding-left: 30px;
        padding-right: 30px;
    }

    .grade-level-label,
    .catalog-left-col h2 {
        font-size: 24px;
        background-color: #f5f5f5;
        margin-bottom: 0;
        padding-top: 12px;
        padding-left: 30px;
        padding-right: 30px;
    }

    .department-group h4 {
        font-size: 26px;
        margin-bottom: 25px;
        padding: 0;
    }

    .course-item h5,
    #no-courses-message {
        font-size: 18px;
    }

    .grade-level-label,
     .category-filters h3,
     .course-search-container h3{
        text-align: center;
    }

    .grade-filters {
        flex-direction: column;
        gap: 10px;
    }

    .modal-body {
        padding: 20px;
    }

    .grade-filters button {
        transition: all 0.3s ease;
    }

    .semester-filter-container {
        margin-bottom: 15px;
    }
}