
/* Image loading optimization */
.edu-course .thumbnail img {
    width: 100%;
    height: auto;
    object-fit: cover;
    aspect-ratio: 4/3;
    background-color: #f5f5f5;
}

/* Skeleton loading animation */
.edu-course .thumbnail {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.edu-course .thumbnail img[loading="lazy"] {
    min-height: 250px;
}



/* Custom Course Page Improvements */

/* Make course level badge fit content width */
.edu-course .content .course-level {
    display: inline-block;
    width: auto !important;
    max-width: fit-content;
    padding: 3px 12px;
    font-size: 12px;
    margin-bottom: 12px;
    background-color: rgba(26, 182, 157, 0.1);
    color: var(--color-primary);
    border-radius: 4px;
    font-weight: 500;
    white-space: nowrap;
}

/* Course description styling - visible by default */
.edu-course .content .course-description {
    font-size: 13px;
    line-height: 1.6;
    color: #6b7385;
    margin-bottom: 15px;
    min-height: 60px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

/* Hide course level badge on hover */
.edu-course:hover .content .course-level,
.edu-course .course-hover-content .content .course-level {
    display: none;
}

/* Show full description on hover without truncation */
.edu-course .course-hover-content .content p {
    min-height: auto;
    margin-bottom: 20px;
    font-size: 13px;
    line-height: 1.6;
    overflow: visible;
    text-overflow: initial;
    display: block;
    -webkit-line-clamp: unset;
}

/* Improve course rating alignment */
.edu-course .content .course-rating {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.edu-course .content .course-rating .rating {
    display: flex;
    gap: 2px;
    line-height: 1;
}

.edu-course .content .course-rating .rating i {
    font-size: 14px;
    color: #f8b81f;
}

.edu-course .content .course-rating .rating-count {
    font-size: 13px;
    font-weight: 500;
    color: #6b7385;
    margin-left: 0;
}

/* Improve content padding */
.edu-course .content {
    padding: 25px 20px 20px 20px;
}

/* Enhanced hover effect */
.edu-course:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

/* Improve title spacing */
.edu-course .content .title {
    margin-bottom: 12px;
    min-height: 48px;
}

/* Hover content improvements */
.edu-course .course-hover-content .content p {
    min-height: auto;
    margin-bottom: 20px;
    font-size: 13px;
    line-height: 1.6;
}

.edu-course .course-hover-content .content .course-rating {
    margin-bottom: 20px;
}

/* Improve thumbnail aspect ratio */
.edu-course .thumbnail a {
    display: block;
    position: relative;
    padding-bottom: 65%;
    overflow: hidden;
}

.edu-course .thumbnail a img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Better spacing for course grid */
.course-area-1 .row.g-5 {
    row-gap: 35px !important;
}
