/* Custom CSS for Course Catalog 

static/css/course_catalog.css
*/

/* Line clamp for course titles (ensures they don't overflow) */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Smooth hover animations for course tiles */
.course-tile {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.course-tile:hover {
    transform: translateY(-5px);
}

/* Modal transitions */
#course-modal {
    transition: opacity 0.3s ease;
}

#course-modal.hidden {
    opacity: 0;
    pointer-events: none;
}

#course-modal:not(.hidden) {
    opacity: 1;
}

/* Accordion animations for units */
.unit-toggle {
    transition: transform 0.3s ease;
}

/* Ensure the modal doesn't exceed screen height */
#course-modal > div {
    max-height: 90vh;
}

/* Custom scrollbar for modal content */
.overflow-y-auto::-webkit-scrollbar {
    width: 6px;
}

.overflow-y-auto::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.overflow-y-auto::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 10px;
}

.overflow-y-auto::-webkit-scrollbar-thumb:hover {
    background: #a1a1a1;
}