/* ==========================================
   All Courses Page Layout (Updated Grid)
   ========================================== */
.courses-page-container {
    max-width: 1280px;
    margin: 40px auto 60px auto;
    padding: 0 20px;
}

.page-header {
    text-align: center;
    margin-bottom: 40px;
}

.page-title {
    font-size: 28px;
    color: #0f172a;
    font-weight: 700;
    margin-bottom: 8px;
}

.page-subtitle {
    font-size: 15px;
    color: #64748b;
    margin: 0;
}

/* Courses Grid - Desktop (4 Columns) */
.courses-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

/* Individual Course Card */
.course-card-item {
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.04);
    text-decoration: none;
    color: inherit;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.course-card-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.08);
    border-color: #cbd5e1;
}

/* Thumbnail Box */
.course-thumb-wrapper {
    position: relative;
    width: 100%;
    height: 160px;
    background: #0f172a;
    overflow: hidden;
}

.course-thumb-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.course-card-item:hover .course-thumb-img {
    transform: scale(1.05);
}

/* Card Body */
.course-card-body {
    padding: 16px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.course-title {
    font-size: 15px;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 6px 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.course-desc {
    font-size: 12px;
    color: #64748b;
    margin: 0 0 14px 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Card Footer */
.course-card-footer {
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 12px;
    border-top: 1px solid #f1f5f9;
}

.course-price {
    font-size: 16px;
    font-weight: 700;
    color: #10b981;
}

.view-details-btn {
    font-size: 12px;
    font-weight: 600;
    color: #2563eb;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: gap 0.2s ease;
}

.course-card-item:hover .view-details-btn {
    gap: 8px;
}

/* Empty State */
.no-courses-found {
    text-align: center;
    padding: 60px 20px;
    color: #94a3b8;
}

.no-courses-found i {
    font-size: 48px;
    margin-bottom: 12px;
}

/* ==========================================
   Responsive Adjustments
   ========================================== */

/* Tablet (1024px and below) */
@media (max-width: 1024px) {
    .courses-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
    }
}

/* Small Tablet / Mobile Devices (768px and below) */
@media (max-width: 768px) {
    .courses-page-container {
        margin: 25px auto 40px auto;
        padding: 0 12px;
    }

    .page-header {
        margin-bottom: 24px;
    }

    .page-title {
        font-size: 20px;
    }

    .page-subtitle {
        font-size: 13px;
    }

    /* মোবাইলে একসাথে ২টি কার্ড */
    .courses-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .course-card-item {
        border-radius: 12px;
    }

    .course-thumb-wrapper {
        height: 110px;
    }

    .course-card-body {
        padding: 10px;
    }

    .course-title {
        font-size: 13px;
        margin-bottom: 4px;
    }

    .course-desc {
        font-size: 11px;
        margin-bottom: 8px;
    }

    .course-card-footer {
        padding-top: 8px;
    }

    .course-price {
        font-size: 14px;
    }

    .view-details-btn {
        font-size: 11px;
    }
}