/* LearnDash Group Course Order - Front-end Styles */

.ldgco-ordered-courses-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.ldgco-ordered-courses-list .ldgco-course-item {
    margin-bottom: 10px;
    padding: 12px 15px;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.ldgco-ordered-courses-list .ldgco-course-item:hover {
    border-color: #2271b1;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.ldgco-ordered-courses-list .ldgco-course-item a {
    text-decoration: none;
    color: #1d2327;
    font-weight: 500;
    display: block;
}

.ldgco-ordered-courses-list .ldgco-course-item a:hover {
    color: #2271b1;
}

/* Course List with Filters Styles */
.ldgco-course-list-wrapper {
    margin: 20px 0;
}

.ldgco-course-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.ldgco-filter-group {
    display: flex;
    flex-direction: column;
    min-width: 200px;
}

.ldgco-filter-group label {
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
}

.ldgco-filter-select {
    padding: 10px 40px 10px 15px;
    border: 2px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    background-color: #fff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23555' stroke-width='1.8' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.ldgco-filter-select:hover {
    border-color: #2271b1;
}

.ldgco-filter-select:focus {
    outline: none;
    border-color: #2271b1;
    box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.1);
}

.ldgco-course-list-container {
    margin-top: 20px;
}

.ldgco-course-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.ldgco-course-item {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
}

.ldgco-course-item:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.ldgco-course-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    position: relative;
    margin: 0;
    padding: 0;
}

.ldgco-course-video {
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    position: relative;
    margin: 0;
    padding: 0;
}

.ldgco-course-image {
    background: transparent;
    display: block;
}

.ldgco-course-image.ldgco-has-placeholder {
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ldgco-course-item {
    position: relative;
}

.ldgco-course-image a {
    display: block;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    line-height: 0;
}

.ldgco-course-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
    display: block;
    margin: 0;
    padding: 0;
    vertical-align: top;
}

.ldgco-course-image img.ldgco-placeholder-image {
    object-fit: cover;
    opacity: 1;
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
}

.ldgco-course-item:hover .ldgco-course-image img {
    transform: scale(1.05);
}

.ldgco-course-item:hover .ldgco-course-image img.ldgco-placeholder-image {
    opacity: 0.7;
}

.ldgco-course-video {
    background: #000;
}

.ldgco-course-video iframe,
.ldgco-video-embed {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
    margin: 0;
    padding: 0;
}

.ldgco-course-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.ldgco-course-title {
    margin: 0 0 10px 0;
    font-size: 20px;
    line-height: 1.4;
}

.ldgco-course-title a {
    color: #1d2327;
    text-decoration: none;
    transition: color 0.3s ease;
}

.ldgco-course-title a:hover {
    color: #2271b1;
}

.ldgco-course-short-description {
    color: #555;
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 12px;
    font-weight: 400;
}

.ldgco-course-excerpt {
    color: #666;
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 15px;
}

.ldgco-enrollment-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 10;
    display: inline-block;
    padding: 5px 12px;
    border-radius: 0;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 0;
}

.ldgco-enrollment-badge.enrolled {
    background: #4CAF50;
    color: #fff;
}

.ldgco-enrollment-badge.not-enrolled {
    background: #FFC107;
    color: #000;
}

.ldgco-enrollment-badge.completed {
    background: #2196F3;
    color: #fff;
}

/* Course Progress Bar */
.ldgco-course-progress {
    margin: 15px 0 0;
}

.ldgco-progress-bar {
    width: 100%;
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 8px;
}

.ldgco-progress-fill {
    height: 100%;
    background: #ffc107;
    transition: width 0.3s ease;
    border-radius: 4px;
}

.ldgco-progress-text {
    font-size: 12px;
    color: #666;
    font-weight: 600;
    text-transform: uppercase;
    display: block;
}

.ldgco-course-link {
    display: inline-block;
    padding: 10px 20px;
    background: #FFC107;
    color: #000;
    text-decoration: none;
    border-radius: 0;
    font-weight: 600;
    transition: background 0.3s ease;
    width: 100%;
    text-align: center;
    margin-top: auto;
    box-sizing: border-box;
}

.ldgco-course-link:hover {
    background: #ffb300;
    color: #000;
}

.ldgco-no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px 20px;
    color: #666;
}

.ldgco-no-results p {
    margin: 0;
    font-size: 16px;
}

/* Responsive */
@media (max-width: 768px) {
    .ldgco-course-filters {
        flex-direction: column;
    }
    
    .ldgco-filter-group {
        width: 100%;
    }
    
    .ldgco-course-list {
        grid-template-columns: 1fr;
    }
}
