/*content 공통 부분*/
.home-container{
    max-width: 1200px;
    margin: 0 auto;
    padding: 3.5rem 2rem;
}

.home-section{
    margin-bottom: 12rem;
}

.home-section h3{
    font-size: 2.4rem;
    font-weight: 700;
}

/*1. 썸네일 배너*/
.banner-section{
    margin-left: -2rem;
    margin-right: -2rem;
}

.banner-slider{
    position: relative;
    overflow: hidden;     /*넘치는 영역 숨기기*/
    border-radius: 2.4rem;
}

/*배너 영역 - 슬라이드 트랙*/
.banner-track{
    display: flex;
    transition: transform 0.5s ease;
}

/*배너 영역 - 개별 슬라이드*/
.banner-item{
    min-width: 100%;
    position: relative;
}
.banner-item img{
    width: 100%;
    height: 420px;
    object-fit: cover;
    display: block;
}
/*배너 영역 - 제목 오버레이*/
.banner-title{
    position: absolute;
    right: 10rem;
    bottom: 40%;
    font-size: 2.4rem;
    font-weight: 700;
    color: #ffffff;
    text-shadow: 0 0.4rem 1.6rem rgba(0,0,0,0.6);
}

.banner-category {
    position: absolute;
    right: 10rem;
    bottom: calc(40% + 3.6rem);

    display: inline-block;
    padding: 0.4rem 1.2rem;

    font-size: 1.3rem;
    font-weight: 600;
    letter-spacing: 0.02em;

    color: #ffffff;
    background: rgba(0,0,0,0.55);
    backdrop-filter: blur(6px);

    border-radius: 1.6rem;
}

/*배너 영역 - 왼쪽, 오른쪽 버튼*/
.banner-nav{
    position: absolute;
    top: 0;
    bottom: 0;
    width: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 10;
}
.banner-slider:hover .banner-nav {
    opacity: 1;
}

.banner-nav.prev {
    left: 0;
    background: linear-gradient(to right,
    rgba(0,0,0,0.45),
    rgba(0,0,0,0)
    );
}
.banner-nav.next {
    right: 0;
    background: linear-gradient(to left,
    rgba(0,0,0,0.45),
    rgba(0,0,0,0)
    );
}

.arrow-icon{
    width: 20px;
    height: 20px;
    border-top: 3px solid #ffffff;
    border-right: 3px solid #ffffff;
}
.banner-nav.prev .arrow-icon {
    transform: rotate(-135deg);
}
.banner-nav.next .arrow-icon {
    transform: rotate(45deg);
}

.banner-progress{
    position: absolute;
    bottom: 1.8rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
}
.banner-progress span{
    width: 40px;
    height: 3px;
    background: rgba(255, 255, 255, 0.4);
    transition: background 0.3s ease;
}
.banner-progress span.active {
    background: #ffffff;
}

/*2. 인기강좌 목록*/
.course-section{
    background: #f9fafb;
    padding: 5rem 3rem;
}

.course-feature-layout {
    display: grid;
    grid-template-columns: 2fr 3fr;
    gap: 3.2rem;
    align-items: start;

}

.course-sub-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2.4rem;
}

.course-card {
    display: block;
    background: #ffffff;
    border-radius: 1.6rem;
    padding: 2.1rem;
    box-shadow: 0 0.6rem 1.6rem rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.course-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 40px rgba(0,0,0,0.1);
}

.course-card.featured {
    padding: 2rem;
    border: 2px solid #2563eb;
    align-self: center;
}

.course-card.featured .course-thumb img {
    aspect-ratio: 16 / 9;
    min-height: 240px;
}

.course-card.featured h4 {
    font-size: 1.8rem;
}

.course-thumb {
    position: relative;
    margin-bottom: 1.5rem;
}
.course-thumb img {
    width: 100%;
    aspect-ratio: 16 / 10;
    border-radius: 1.6rem;
}
.course-category {
    display: inline-block;
    margin: 0.6rem 0 0.4rem;

    padding: 0.3rem 0.8rem;
    border-radius: 1rem;

    font-size: 1.2rem;
    font-weight: 600;
    color: #4f46e5;
    background: #eef2ff;
}
.course-card.featured .course-category {
    background: #fff7ed;
    color: #ea580c;
}

.course-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(37,99,235,0.9);
    color: #ffffff;
    font-size: 1.2rem;
    padding: 0.4rem 1rem;
    border-radius: 0.8rem;
}
.course-card.featured .course-badge{
    left: 1.2rem;
    right: auto;
    top: 1.2rem;
    padding: 0.5rem 1.1rem;
    border-radius: 1.5rem;
    font-weight: 700;
    background: rgba(246, 110, 33, 0.85);
}

.course-list h4 {
    font-size: 1.6rem;
    font-weight: 600;
    margin-bottom: 1.2rem;
    line-height: 1.4;
}

.course-list p {
    font-size: 1.4rem;
    font-weight: 600;
    color: #2563eb;
}

/*블로그 그리드(반응형으로 인해 위치 변경)*/
.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.4rem;
}

/* ===== 섹션 구분용 ===== */
.section-bg {
    background: #f9fafb;
    padding: 10rem 0;
}

.section-header {
    margin-bottom: 4rem;
}

.section-header h3 {
    font-size: 2.4rem;
    font-weight: 700;
}

.section-header p {
    font-size: 1.4rem;
    color: #6b7280;
    margin-top: 0.8rem;
}

.section-header h3::after {
    content: "";
    display: block;
    width: 36px;
    height: 4px;
    background: #2563eb;
    margin-top: 1.2rem;
    border-radius: 2px;
}

/*반응형 버전*/
@media (max-width: 1024px) {
    .blog-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .home-section {
        margin-bottom: 8rem;
    }

    .banner-item img {
        height: 360px;
    }

    .course-feature-layout {
        grid-template-columns: 1fr;
    }

    .course-sub-list {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .home-container {
        padding: 3rem 1.6rem;
    }
    .home-section {
        margin-bottom: 6rem;
    }

    .course-list {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.6rem;
    }
    .blog-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .course-card {
        padding: 1.6rem;
    }

    .home-section h3 {
        font-size: 2rem;
    }

    .banner-item img {
        height: 280px;
    }

    .banner-title {
        right: 2.4rem;
        bottom: 3.6rem;

        font-size: 1.8rem;
        line-height: 1.3;
        max-width: calc(100% - 4.8rem);
    }

    .banner-category {
        right: 2.4rem;
        bottom: 7.2rem;

        font-size: 1.1rem;
        padding: 0.3rem 0.8rem;
    }
}

@media (max-width: 480px) {
    .blog-grid {
        grid-template-columns: 1fr;
    }

    .home-section {
        margin-bottom: 4rem;
    }

    .banner-item img {
        height: 220px;
    }

    .course-sub-list {
        grid-template-columns: 1fr;
    }

    .banner-title {
        bottom: 3rem;
        font-size: 1.6rem;
    }

    .banner-category {
        bottom: 6.4rem;
        font-size: 1rem;
    }
}

