/* ===============================
   GLOBAL
==================================*/
body {
    background-color: #ffffff;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    margin: 0;
    padding: 0;
}

/* KHUNG CHÍNH */
.page-width {
    width: 100%;
    max-width: 1040px;
    margin: 0 auto;
}

@media (max-width: 576px) {
    .cards-section,
    .courses-section,
    .search-section
    {
        margin: 0 28px 50px !important;
    }
}

/* ===============================
   HERO
==================================*/
.home-hero {
    background: linear-gradient(180deg, #e9fff6 0%, #ffffff 70%);
    padding-top: 48px;
    padding-bottom: 40px;
}

.home-hero-title {
    font-weight: 600;
    font-size: 2.4rem;
}

@media (max-width: 576px) {
    .home-hero {
        padding-top: 28px;
        padding-bottom: 28px;
    }
    .home-hero-title {
        font-size: 1.4rem;
    }
}

/* ===============================
   SEARCH BOX
==================================*/
.search-wrapper {
    max-width: 720px;
    margin: 0 auto;
    position: relative;
}

.search-wrapper .form-control {
    border-radius: 999px;
    padding-left: 22px;
    padding-right: 60px;
    height: 56px;
    border: 1px solid #e2e6ea;
    box-shadow: 0 10px 25px rgba(0,0,0,0.03);
}

.search-btn-icon {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: none;
    background-color: #0da46f;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
}

/* ===============================
   TAG BUTTONS
==================================*/
.pill-btn {
    border-radius: 999px;
    font-size: 0.85rem;
    padding: 0.45rem 1.3rem;
}

.pill-btn-primary {
    background-color: #0da46f;
    color: #fff;
}

.pill-btn-outline {
    background-color: #fff;
    border: 1px solid #dadfe5;
    color: #333;
}

/* ===============================
   CARDS SECTION
==================================*/
.cards-section {
    padding-top: 32px;
    padding-bottom: 48px;
}

/* GRID */
.category-card {
    border-radius: 24px;
    padding: 32px;
    min-height: 180px;
    color: #fff;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-decoration: none;
    height: 100%;
    box-shadow: 0 16px 45px rgba(15, 23, 42, 0.15);
    transition: all 0.25s ease-in-out;
    align-items: center;
}

.category-card:hover {
    transform: translateY(-6px);
    text-decoration: none;
    color: #fff;
    box-shadow: 0 22px 55px rgba(15, 23, 42, 0.25);
}

/* ===============================
   BUTTON VIEW MORE
==================================*/
.btn-view-more {
    width: max-content;
    height: 43px;
    border: 1px solid rgba(255, 255, 255, 0.9);
    border-radius: 999px;
    padding: .45rem 1.5rem;
    background: rgba(255,255,255,0.10);
    color: #ffffff;
    font-weight: 500;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.25s ease-in-out;
}

.btn-view-more i {
    transition: transform 0.25s ease-in-out;
}

.btn-view-more:hover {
    background: #ffffff;
    color: #0da46f;
    box-shadow: 0 6px 18px rgba(255,255,255,0.35);
}

.btn-view-more:hover i {
    transform: translateX(4px);
}


/* ===============================
   COURSES SECTION
==================================*/
.courses-section {
    padding: 16px 0 48px;
}

/* View All button – hidden on mobile */
.btn-view-all {
    border: 1px solid #000;
    border-radius: 24px;
    padding: 6px 16px;
    font-size: 0.9rem;
    color: #111;
}

@media (max-width: 576px) {
    .btn-view-all {
        display: none !important;
    }
}

/* ===============================
   COURSE CARD
==================================*/
.course-card {
    display: block;
    background: #ffffff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.1);
    transition: all 0.25s ease;
    text-decoration: none;
    color: inherit;
}

.course-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 14px 25px rgba(15, 23, 42, 0.15);
}

/* Thumbnail */
.course-thumb {
    height: 160px;
    overflow: hidden;
    border-radius: 14px 14px 0 0;
    background: #f3f4f6;
}

.course-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* giữ tỉ lệ, crop cho đẹp */
    display: block;
}

.course-rating {
    position: absolute;
    top: 12px;
    right: 12px;
    background: #00000070;
    padding: 4px 8px;
    border-radius: 8px;
    font-size: 0.8rem;
    color: #fff;
}

.course-live {
    background: #ef233c;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
}

.course-thumb-title {
    margin-top: 10px;
    font-size: 1rem;
    font-weight: 600;
}

.course-desc {
    margin: 0;
    font-size: 0.85rem;
    color: #555;
    display: -webkit-box;
    -webkit-line-clamp: 2; /* 2 dòng */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Body */
.course-body {
    padding: 16px;
}

.course-title {
    font-size: 1rem;
    font-weight: 600;
    min-height: 50px;
}

.course-meta {
    font-size: 0.85rem;
    margin-top: 6px;
    color: #444;
    display: flex;
    align-items: center;
    gap: 6px;
}

.course-interests {
    margin-top: 6px;
}
/* Explore Now Button */
.btn-explore-now {
    margin-top: 10px;
    border: 1px solid #0da46f;
    color: #0da46f;
    font-weight: 500;
    border-radius: 12px;
    background: transparent;
    padding: 6px 14px;
    font-size: 0.9rem;
    transition: all 0.25s ease;
}
/* ===============================
   Load more button
==================================*/

.course-card:hover .btn-explore-now {
    background: #0da46f;
    color: #fff;
    border-color: #0da46f;
}

.course-load-more-wrapper {
    margin-top: 24px;
}

/* Style nút Load more */
.btn-load-more {
    padding: 0.55rem 1.6rem;
    border-radius: 999px;
    border: 1px solid #0da46f;
    background: #ffffff;
    color: #0da46f;
    font-weight: 500;
    font-size: 0.95rem;
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.08);
    transition: all 0.25s ease;
}

.btn-load-more:hover {
    background: #0da46f;
    color: #ffffff;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.15);
    transform: translateY(-2px);
}

