/* =========================================================================
   [MAIN] Slider Style (Nexon Style Full Width with Tabs)
   ========================================================================= */
.main-slider-container.full-width {
    position: relative;
    padding: 0;
    max-width: none;
    margin: 0 0 50px 0; /* 하단 마진 50px 추가하여 컨텐츠와 분리 */
    z-index: 5;
    background: #000;
}

.main-slider {
    width: 100%;
    height: 550px; /* 높이 확대 */
    border-radius: 0; /* 라운드 제거 */
    overflow: hidden;
}

.slide-content-wrapper {
    max-width: var(--container-width);
    margin: 0 auto;
    width: 100%;
    height: 100%;
    position: relative;
    z-index: 10;
}

.slide-item {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    overflow: hidden;
}

.slide-content {
    height: 100%;
    display: flex;
    align-items: center;
    padding: 0 40px;
    color: var(--white);
    max-width: 700px;
    transition: padding-bottom 0.3s;
    position: relative;
    z-index: 20;
}

/* 포인트 이미지 영역 */
.point-img-area {
    position: absolute;
    top: 0;
    right: 0;
    width: 50%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 15;
    pointer-events: none;
}

.point-img {
    max-width: 80%;
    max-height: 80%;
    object-fit: contain;
    transition: all 1.2s cubic-bezier(0.34, 1.56, 0.64, 1); /* 더 탄력 있고 긴 지속 시간 */
    opacity: 0;
    transform: translateX(300px); /* 이동 거리 대폭 확대 (패럴랙스 강화) */
    will-change: transform, opacity;
}

/* Swiper 애니메이션 연동 강화 */
.swiper-slide-active .point-img {
    opacity: 1;
    transform: translateX(0);
    transition-delay: 0.2s; /* 배경보다 살짝 늦게 시작하여 속도감 강조 */
}

/* 활성화되지 않은 모든 슬라이드의 이미지는 숨김 처리 */
.swiper-slide:not(.swiper-slide-active) .point-img {
    opacity: 0;
    transform: translateX(200px); /* 우측으로 퇴장 */
    transition: all 0.7s ease-in;
}

/* 이전 슬라이드에서 온 경우(좌측에서 등장)와 이전 슬라이드로 가는 경우(좌측으로 퇴장) 대응 */
.swiper-slide-prev .point-img {
    transform: translateX(-300px) !important;
}

/* 탭이 있을 때 컨텐츠를 위로 올림 (탭 높이 80px 고려) */
.main-slider-container.has-tabs .slide-content {
    padding-bottom: 80px;
}

/* 이미지가 없을 때 스타일 - Canvas가 배경이 됨 */
.slide-item.no-img {
    background: transparent;
}

/* Canvas 배경 스타일 */
.slider-background-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

.slide-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(90deg, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.2) 50%, rgba(0,0,0,0.7) 100%);
    z-index: 5;
}

.slide-content .badge {
    display: inline-block;
    padding: 6px 16px;
    background: var(--point-color);
    color: var(--white);
    border-radius: 50px; /* 알약 모양으로 복구 */
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 20px;
}

.slide-content .title {
    font-size: 56px;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 20px;
    letter-spacing: -2px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.slide-content .desc {
    font-size: 20px;
    line-height: 1.6;
    margin-bottom: 40px;
    opacity: 0.9;
    text-shadow: 0 2px 5px rgba(0,0,0,0.3);
}

.btn-more {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 35px;
    background: var(--white);
    color: var(--black);
    border-radius: 50px; /* 버튼 형태 복구 */
    font-size: 16px;
    font-weight: 700;
    transition: var(--transition);
}

.btn-more:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
    background: var(--point-color);
    color: var(--white);
}

/* 탭 메뉴 스타일 (PC) */
.slider-tabs-container {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 20;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(10px);
}

.slider-tabs-wrapper {
    max-width: var(--container-width);
    margin: 0 auto;
    display: flex;
    align-items: center;
    position: relative;
}

.slider-tabs {
    flex: 1;
    overflow: hidden;
}

.tabs-inner {
    display: flex;
    transition: transform 0.3s ease;
}

.tab-item {
    flex: 0 0 20%; /* 5개 노출 */
    height: 80px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    padding: 0 20px;
    color: rgba(255,255,255,0.6);
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    transition: all 0.3s;
    position: relative;
}

.tab-item:hover, .tab-item.active {
    color: #fff;
    background: rgba(255,255,255,0.1);
}

.tab-item .tab-cat {
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 4px;
    text-transform: uppercase;
}

.tab-item .tab-name {
    font-size: 15px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
}

.tab-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: rgba(255,255,255,0.1);
}

.tab-item.active .tab-progress .bar {
    height: 100%;
    background: var(--point-color);
    width: 0%; /* JS에서 애니메이션 처리 */
}

/* 탭 화살표 */
.btn-tab-prev, .btn-tab-next {
    width: 40px;
    height: 80px;
    background: rgba(0,0,0,0.3);
    color: #fff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: background 0.3s;
    z-index: 5;
}

.btn-tab-prev:hover, .btn-tab-next:hover {
    background: rgba(0,0,0,0.6);
}

/* 모바일 페이지네이션 숨김 (PC) */
.mobile-pagination {
    display: none !important;
}

/* 모바일 스타일 */
@media screen and (max-width: 1024px) {
    .main-slider {
        height: 450px; /* 모바일 높이 약간 확대 */
    }
    .slide-content {
        padding-top: 40px; /* 상단 여백 추가 */
        padding-bottom: 0 !important; /* PC용 하단 패딩 해제 */
        align-items: flex-start; /* 상단 정렬 유지하되 여백으로 조절 */
    }
    .point-img-area {
        width: 100%;
        height: 100%;
        justify-content: flex-end;
        align-items: flex-end;
        padding-bottom: 60px;
        padding-right: 20px;
    }
    .point-img {
        max-width: 50%;
        max-height: 50%;
        transform: translateX(50px);
    }
    .swiper-slide-active .point-img {
        transform: translateX(0);
    }
    .slide-content .title {
        font-size: 32px;
    }
    .slide-content .desc {
        font-size: 16px;
    }
    .slider-tabs-container {
        display: none; /* 모바일에서 탭 숨김 */
    }
    .mobile-pagination {
        display: block !important;
        bottom: 20px !important;
    }
    .mobile-pagination .swiper-pagination-bullet {
        background: #fff;
        opacity: 0.5;
    }
    .mobile-pagination .swiper-pagination-bullet-active {
        opacity: 1;
        background: var(--point-color);
    }
}

/* 랜덤 테마 색상 설정 (JS에서 Canvas 색상으로 활용) */
.slide-item[data-theme-index="1"] { --theme-color-1: #ff00cc; --theme-color-2: #3333ff; --theme-color-3: #00d4ff; }
.slide-item[data-theme-index="2"] { --theme-color-1: #f093fb; --theme-color-2: #f5576c; --theme-color-3: #ff0844; }
.slide-item[data-theme-index="3"] { --theme-color-1: #84fab0; --theme-color-2: #8fd3f4; --theme-color-3: #2af598; }
.slide-item[data-theme-index="4"] { --theme-color-1: #fa709a; --theme-color-2: #fee140; --theme-color-3: #ffb199; }
.slide-item[data-theme-index="5"] { --theme-color-1: #4facfe; --theme-color-2: #00f2fe; --theme-color-3: #7367f0; }
.slide-item[data-theme-index="6"] { --theme-color-1: #6a11cb; --theme-color-2: #2575fc; --theme-color-3: #b122e5; }
.slide-item[data-theme-index="7"] { --theme-color-1: #f9d423; --theme-color-2: #ff4e50; --theme-color-3: #f06292; }
.slide-item[data-theme-index="8"] { --theme-color-1: #00c6fb; --theme-color-2: #005bea; --theme-color-3: #667eea; }
.slide-item[data-theme-index="9"] { --theme-color-1: #5ee7df; --theme-color-2: #b490ca; --theme-color-3: #43e97b; }
.slide-item[data-theme-index="10"] { --theme-color-1: #f6d365; --theme-color-2: #fda085; --theme-color-3: #fccb90; }
