/* ============================================
   MRO ONE 2026 Custom Styles
   카테고리 마퀴, 고객 선택, 인기 카테고리 등
   ============================================ */

/* ============================================
   1. 카테고리 마퀴 스타일
   ============================================ */
.category-marquee-wrapper {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    overflow: hidden;
}

.marquee-row {
    display: flex;
    overflow: hidden;
    position: relative;
    width: 100%;
}

.marquee-content {
    display: flex;
    gap: 20px;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
}

/* 왼쪽에서 오른쪽으로 */
.marquee-left-to-right .marquee-content {
    animation: marquee-ltr 30s linear infinite;
}

/* 오른쪽에서 왼쪽으로 */
.marquee-right-to-left .marquee-content {
    animation: marquee-rtl 30s linear infinite;
}

@keyframes marquee-ltr {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-33.333%);
    }
}

@keyframes marquee-rtl {
    0% {
        transform: translateX(-33.333%);
    }
    100% {
        transform: translateX(0);
    }
}

/* 글래스모피즘 카드 */
.category-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 30px 12px 12px;
    text-decoration: none;
    color: #2c3e50;
    white-space: nowrap;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.glassmorphism {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 50px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.15);
}

.category-card:hover {
    background: rgba(255, 255, 255, 0.4);
    transform: translateY(-3px);
    box-shadow: 0 12px 40px 0 rgba(31, 38, 135, 0.25);
    border-color: rgba(255, 255, 255, 0.3);
}

.category-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.5);
}

.category-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.category-icon-fallback {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: var(--mro-category-icon-bg, linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%));
    border: 1px solid rgba(255, 255, 255, 0.35);
    box-shadow:
        0 6px 10px rgba(15, 23, 42, 0.24),
        inset 0 1px 0 rgba(255, 255, 255, 0.45),
        inset 0 -4px 7px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

.category-icon-fallback::before {
    content: '';
    position: absolute;
    top: -35%;
    left: -10%;
    width: 120%;
    height: 55%;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.52), rgba(255, 255, 255, 0));
    pointer-events: none;
}

.category-icon-fallback.is-hidden {
    display: none;
}

.category-icon-fallback i {
    position: relative;
    z-index: 1;
    font-size: 16px;
    line-height: 1;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.category-name {
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
}

/* 호버 시 애니메이션 일시정지 */
.marquee-row:hover .marquee-content {
    animation-play-state: paused;
}

/* 반응형 */
@media (max-width: 768px) {
    .category-card {
        padding: 10px 20px 10px 10px;
        gap: 10px;
    }

    .category-icon {
        width: 32px;
        height: 32px;
    }

    .category-name {
        font-size: 14px;
    }

    .marquee-left-to-right .marquee-content,
    .marquee-right-to-left .marquee-content {
        animation-duration: 20s;
    }
}

/* ============================================
   2. 고객 선택 슬라이더 스타일
   ============================================ */
.customer-choice-swiper {
    padding: 10px 0;
}

.customer-choice-swiper .type01_group {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.customer-choice-swiper .type01_group:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.12) !important;
}

/* Navigation Buttons */
.choice-nav-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 2px solid #e0e0e0;
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    color: #2c3e50;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    position: relative;
    overflow: hidden;
}

.choice-nav-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(86, 171, 85, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.4s ease, height 0.4s ease;
}

.choice-nav-btn:hover::before {
    width: 100%;
    height: 100%;
}

.choice-nav-btn:hover {
    border-color: #56ab55;
    background: linear-gradient(135deg, #ffffff 0%, #f0f8f0 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(86, 171, 85, 0.25);
}

.choice-nav-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

.choice-nav-btn i {
    font-size: 16px;
    position: relative;
    z-index: 1;
    transition: color 0.3s ease;
}

.choice-nav-btn:hover i {
    color: #56ab55;
}

.choice-nav-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    border-color: #e0e0e0;
    background: #f5f5f5;
    box-shadow: none;
}

.choice-nav-btn:disabled:hover {
    transform: none;
    border-color: #e0e0e0;
    background: #f5f5f5;
}

/* Page Info */
.choice-page-info {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border-radius: 24px;
    border: 2px solid #e0e0e0;
    font-weight: 600;
    font-size: 16px;
    color: #2c3e50;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    min-width: 100px;
    justify-content: center;
}

.choice-current {
    color: #56ab55;
    font-size: 18px;
    font-weight: 700;
}

.choice-divider {
    color: #adb5bd;
    font-weight: 400;
    font-size: 14px;
    margin: 0 2px;
}

.choice-total {
    color: #6c757d;
    font-size: 16px;
}

/* Responsive */
@media (max-width: 768px) {
    .choice-nav-btn {
        width: 42px;
        height: 42px;
    }

    .choice-nav-btn i {
        font-size: 14px;
    }

    .choice-page-info {
        padding: 6px 16px;
        font-size: 14px;
        min-width: 90px;
    }

    .choice-current {
        font-size: 16px;
    }

    .choice-total {
        font-size: 14px;
    }
}

/* ============================================
   3. 인기 카테고리 그리드 스타일
   ============================================ */
.popular-categories-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 24px;
    margin-top: 30px;
}

@media (max-width: 576px) {
    .popular-categories-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }
}

@media (min-width: 577px) and (max-width: 768px) {
    .popular-categories-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (min-width: 769px) and (max-width: 992px) {
    .popular-categories-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (min-width: 993px) {
    .popular-categories-grid {
        grid-template-columns: repeat(6, 1fr);
        gap: 24px;
    }
}

.popular-category-card {
    position: relative;
    display: block;
    aspect-ratio: 4 / 5;
    background: #1f2937;
    border-radius: 16px;
    text-decoration: none;
    color: #fff;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.popular-category-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(8, 15, 26, 0.8) 0%, rgba(8, 15, 26, 0.2) 45%, rgba(8, 15, 26, 0.05) 100%);
    z-index: 1;
    pointer-events: none;
}

.popular-category-card:hover::before {
    background: linear-gradient(to top, rgba(8, 15, 26, 0.9) 0%, rgba(8, 15, 26, 0.35) 45%, rgba(8, 15, 26, 0.1) 100%);
}

.popular-category-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 28px rgba(0, 0, 0, 0.2);
}

.category-image-wrapper {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border-radius: 16px;
    overflow: hidden;
    background: #d1d5db;
    transition: transform 0.4s ease;
}

.popular-category-card:hover .category-image-wrapper {
    transform: scale(1.03);
}

.category-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.popular-category-card:hover .category-image {
    transform: scale(1.08);
}

.popular-category-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 3;
    width: 36px;
    height: 36px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: var(--mro-category-icon-bg, linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%));
    border: 1px solid rgba(255, 255, 255, 0.42);
    box-shadow:
        0 8px 14px rgba(15, 23, 42, 0.28),
        inset 0 1px 0 rgba(255, 255, 255, 0.45),
        inset 0 -5px 8px rgba(0, 0, 0, 0.18);
    transform: translateZ(0);
    transition: transform 0.35s ease, box-shadow 0.35s ease;
    overflow: hidden;
}

.popular-category-badge::before {
    content: '';
    position: absolute;
    top: -40%;
    left: -10%;
    width: 120%;
    height: 55%;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0));
    pointer-events: none;
}

.popular-category-badge i {
    position: relative;
    z-index: 1;
    font-size: 15px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

.popular-category-card:hover .popular-category-badge {
    transform: translateY(-2px);
    box-shadow:
        0 12px 20px rgba(15, 23, 42, 0.34),
        inset 0 1px 0 rgba(255, 255, 255, 0.5),
        inset 0 -6px 10px rgba(0, 0, 0, 0.2);
}

.category-title {
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: 12px;
    z-index: 2;
    font-size: 15px;
    font-weight: 700;
    text-align: left;
    line-height: 1.4;
    color: #fff;
    transition: color 0.3s ease;
    word-break: keep-all;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.55);
}

.popular-category-card:hover .category-title {
    color: #fff;
}

.category-hover-overlay {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    background: rgba(8, 15, 26, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 999px;
    padding: 6px 10px;
    opacity: 0;
    transform: translateY(-4px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.popular-category-card:hover .category-hover-overlay {
    opacity: 1;
    transform: translateY(0);
}

.view-more {
    color: white;
    font-size: 11px;
    font-weight: 600;
    text-align: center;
    display: block;
    letter-spacing: 0.2px;
}

@media (max-width: 576px) {
    .popular-category-card {
        aspect-ratio: 1 / 1.15;
        border-radius: 14px;
    }

    .popular-category-badge {
        top: 8px;
        left: 8px;
        width: 32px;
        height: 32px;
        border-radius: 10px;
    }

    .popular-category-badge i {
        font-size: 13px;
    }

    .category-title {
        font-size: 13px;
        left: 10px;
        right: 10px;
        bottom: 10px;
    }
}

/* ============================================
   4. 모바일 슬라이드 스타일
   ============================================ */
.onmobile_slide {
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-top: 50px;
}

.onmobile_slide .slick-slide {
    margin: 0 10px;
}

/* 첫번째와 마지막 슬라이드의 마진 제거 */
.onmobile_slide .slick-list {
    margin: 0 -10px;
    padding: 0;
}

/* ============================================
   5. 사용후기 이미지 스타일
   ============================================ */
.qa_memo img {
    max-width: 100%;
    display: none;
}

/* ============================================
   6. 상품문의 최신글 스타일
   ============================================ */
.lat_item_qa {
    position: relative;
    margin-bottom: 15px;
}

.lat_item_qa h2 {
    padding: 0 0 10px;
    font-size: 32px;
    border-bottom: none;
    text-align: center;
}

.lat_item_qa .bodys {
    padding: 0 0 10px;
    border-bottom: 1px solid #eaeaea;
    background: #fff;
    border-radius: 16px;
    height: 100%;
}

.lat_item_qa li:after {
    display: block;
    visibility: hidden;
    clear: both;
    content: "";
}

.lat_item_qa li:last-child {
    padding: 0px 0 0;
    border-bottom: 0;
}

.lat_item_qa .qa_img {
    position: relative;
    display: block;
    width: 100%;
    displaY: block;
    border-radius: 16px;
    max-height: 250px;
    overflow: hidden;
}

.lat_item_qa .qa_img img {
    position: relative;
    display: block;
    width: 100%;
    displaY: block;
    border-radius: 16px;
    box-shadow: 5x 3px 6px rgba(0, 0, 0, .3);
}

.lat_item_qa .qa_con {
    width: 100%;
    display: block;
    min-height: 150px;
    padding: 5px 15px 15px;
}

.lat_item_qa .qa_subject {
    margin: 5px 0 10px;
    font-weight: bold;
}

.lat_item_qa .qa_subject a {
    color: #000;
}

.lat_item_qa .qa_memo {
    margin-bottom: 10px;
    color: #19232d;
    line-height: 17px;
    overflow: hidden;
}

.lat_item_qa .qa_date {
    font-size: 11px;
    color: #a1a3b2;
}

.lat_item_qa .qa_date strong {
    padding-right: 10px;
    font-weight: normal;
}

.bgs {
    box-shadow: 3px 4px 12px rgba(0, 0, 0, 0.3);
}

.sit_use_star {
    padding: 5px 0 10px;
}

.pro-name {
    padding: 15px;
}

/* 모바일 반응형 */
@media (max-width:768px) {
    .lat_item_qa {
        position: relative;
        margin-bottom: 15px;
    }

    .lat_item_qa h2 {
        padding: 0 0 10px;
        font-size: 32px;
        border-bottom: none;
        text-align: center;
    }

    .lat_item_qa .bodys {
        padding: 0 0 10px;
        border-bottom: 1px solid #eaeaea;
        background: #fff;
        border-radius: 16px;
        height: 100%;
    }

    .lat_item_qa li:after {
        display: block;
        visibility: hidden;
        clear: both;
        content: "";
    }

    .lat_item_qa li:last-child {
        padding: 0px 0 0;
        border-bottom: 0;
    }

    .lat_item_qa .qa_img {
        position: relative;
        display: block;
        width: 100%;
        displaY: block;
        border-radius: 16px;
        max-height: 170px;
        overflow: hidden;
    }

    .lat_item_qa .qa_img img {
        position: relative;
        display: block;
        width: 100%;
        displaY: block;
        border-radius: 16px;
        box-shadow: 5x 3px 6px rgba(0, 0, 0, .3);
    }

    .lat_item_qa .qa_con {
        width: 100%;
        display: block;
        min-height: 125px;
        padding: 5px 15px 0px;
    }

    .lat_item_qa .qa_subject {
        margin: 5px 0 10px;
        font-weight: bold;
    }

    .lat_item_qa .qa_subject a {
        color: #000;
    }

    .lat_item_qa .qa_memo {
        margin-bottom: 10px;
        color: #19232d;
        line-height: 17px;
        overflow: hidden;
    }

    .lat_item_qa .qa_date {
        font-size: 11px;
        color: #a1a3b2;
    }

    .lat_item_qa .qa_date strong {
        padding-right: 10px;
        font-weight: normal;
    }

    .bgs {
        box-shadow: 3px 4px 12px rgba(0, 0, 0, 0.3);
    }

    .sit_use_star {
        padding: 5px 0 10px;
    }

    .pro-name {
        padding: 15px;
    }
}

/* ============================================
   7. MD's Pick 섹션 여백
   ============================================ */
.md-pick-title-area {
    margin-bottom: 3rem !important;
    padding-bottom: 2rem !important;
}

.md-pick-title-area h4 {
    margin-bottom: 1rem !important;
}

.md-pick-title-area p {
    margin-bottom: 1rem !important;
}

.md-pick-products-area {
    margin-top: 3rem !important;
    padding-top: 2rem !important;
}

/* ============================================
   8. 쿠팡 스타일 카테고리 슬라이드 메뉴
   ============================================ */
/* 2026-02-02: Bootstrap offcanvas와 충돌하여 메뉴가 2개 열리는 문제로 비활성화
   Bootstrap의 #offCanvasNavBar 사용으로 대체됨 */

/*
.category-menu-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    z-index: 1099;
}

.category-menu-backdrop.visible {
    opacity: 1;
    visibility: visible;
}

.category-slide-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    max-width: none;
    height: 100vh;
    background: #FFFFFF;
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
    z-index: 1100;
    display: flex;
    overflow: hidden;
    will-change: transform;
}

.category-slide-menu.open {
    transform: translateX(0);
}

body.category-menu-open {
    overflow: hidden;
}

.category-menu-left {
    width: 25%;
    background: #F5F5F5;
    overflow-y: auto;
    flex-shrink: 0;
}

.category-menu-right {
    width: 75%;
    background: #FFFFFF;
    overflow-y: auto;
    position: relative;
}

.category-menu-header {
    position: sticky;
    top: 0;
    background: #FFFFFF;
    padding: 16px;
    border-bottom: 1px solid #E5E5E5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 10;
}

.category-menu-title {
    font-size: 18px;
    font-weight: 700;
    color: #111111;
    margin: 0;
}

.category-menu-close {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    font-size: 24px;
    color: #666666;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.category-menu-close:hover {
    color: #111111;
}

.category-menu-left-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-menu-left-item {
    padding: 16px 12px;
    font-size: 14px;
    font-weight: 500;
    color: #666666;
    cursor: pointer;
    transition: all 0.2s;
    border-left: 3px solid transparent;
    position: relative;
}

.category-menu-left-item:hover {
    background: #EBEBEB;
    color: #111111;
}

.category-menu-left-item.active {
    background: #FFFFFF;
    color: #00ac5d;
    border-left-color: #00ac5d;
    font-weight: 700;
}

.category-menu-panel {
    display: none;
    padding: 16px;
    animation: slideInRight 0.25s ease-out;
}

.category-menu-panel.active {
    display: block;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.category-2nd-title {
    font-size: 16px;
    font-weight: 700;
    color: #111111;
    margin: 0 0 12px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid #E5E5E5;
}

.category-2nd-title a {
    color: inherit;
    text-decoration: none;
}

.category-2nd-title a:hover {
    color: #00ac5d;
}

.category-2nd-item {
    margin-bottom: 20px;
}

.category-2nd-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px;
    background: #F8F8F8;
    border-radius: 6px;
    text-decoration: none;
    color: #333333;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.2s;
    margin-bottom: 8px;
}

.category-2nd-link:hover {
    background: #E8F5EE;
    color: #00ac5d;
}

.category-2nd-link .arrow {
    font-size: 12px;
    color: #999999;
    transition: transform 0.2s;
}

.category-2nd-item.expanded .category-2nd-link .arrow {
    transform: rotate(90deg);
}

.category-3rd-list {
    list-style: none;
    padding: 0 0 0 16px;
    margin: 0;
    display: none;
}

.category-2nd-item.expanded .category-3rd-list {
    display: block;
}

.category-3rd-item {
    margin-bottom: 8px;
}

.category-3rd-link {
    display: block;
    padding: 8px 12px;
    font-size: 14px;
    color: #555555;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.2s;
}

.category-3rd-link:hover {
    background: #F5F5F5;
    color: #00ac5d;
    padding-left: 16px;
}

.category-2nd-simple {
    display: block;
    padding: 12px;
    background: #F8F8F8;
    border-radius: 6px;
    text-decoration: none;
    color: #333333;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.2s;
    margin-bottom: 8px;
}

.category-2nd-simple:hover {
    background: #E8F5EE;
    color: #00ac5d;
}

.category-slide-menu.dragging {
    transition: none;
}

.category-menu-left::-webkit-scrollbar,
.category-menu-right::-webkit-scrollbar {
    width: 6px;
}

.category-menu-left::-webkit-scrollbar-track,
.category-menu-right::-webkit-scrollbar-track {
    background: transparent;
}

.category-menu-left::-webkit-scrollbar-thumb,
.category-menu-right::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
}

.category-menu-left::-webkit-scrollbar-thumb:hover,
.category-menu-right::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.3);
}

@media (max-width: 480px) {
    .category-slide-menu {
        width: 90%;
        max-width: none;
    }

    .category-menu-left {
        width: 30%;
    }

    .category-menu-right {
        width: 70%;
    }
}
*/

/* ============================================
   9. 쿠팡 스타일 하단 네비게이션 바
   ============================================ */
@media (max-width: 767px) {
    /* Bottom Navigation Container */
    .coupang-bottom-nav {
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
        height: 56px;
        background: #FFFFFF;
        border-top: 1px solid #E5E5E5;
        display: flex;
        align-items: center;
        justify-content: space-around;
        z-index: 1050 !important;
        padding-bottom: env(safe-area-inset-bottom);
        box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.08);
    }

    /* Individual Tab */
    .coupang-nav-tab {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 4px;
        min-height: 44px;
        text-decoration: none;
        color: #999999;
        background: none;
        border: none;
        cursor: pointer;
        transition: color 0.2s ease, transform 0.15s ease;
        -webkit-tap-highlight-color: transparent;
        padding: 6px 8px;
    }

    /* Active Tab State */
    .coupang-nav-tab.active {
        color: #FF0000;
    }

    .coupang-nav-tab.active .coupang-nav-icon {
        color: #FF0000;
        transform: scale(1.05);
    }

    .coupang-nav-tab.active .coupang-nav-label {
        font-weight: 700;
        color: #FF0000;
    }

    /* Tab Press Effect */
    .coupang-nav-tab:active {
        transform: scale(0.95);
    }

    /* Icon */
    .coupang-nav-icon {
        width: 24px;
        height: 24px;
        display: flex;
        align-items: center;
        justify-content: center;
        color: inherit;
        transition: color 0.2s ease, transform 0.2s ease;
    }

    .coupang-nav-icon i {
        font-size: 24px;
    }

    /* Label */
    .coupang-nav-label {
        font-size: 11px;
        font-weight: 400;
        line-height: 1;
        color: inherit;
        transition: font-weight 0.2s ease, color 0.2s ease;
    }

    /* Body Padding to Account for Fixed Bottom Nav */
    body.has-bottom-nav {
        padding-bottom: calc(56px + env(safe-area-inset-bottom));
    }

    /* Hide existing mobile footer menu when bottom nav is active */
    .has-bottom-nav .footer_fixed {
        display: none !important;
    }
}

/* ============================================
   10. 모바일 푸터 스타일 (꽉 차게)
   ============================================ */
@media (max-width: 767px) {
    #ft,
    #ft_copy {
        max-width: none !important;
        width: 100% !important;
        margin: 0 !important;
        padding: 20px 16px !important;
        box-sizing: border-box !important;
        background-color: #f8f8f8;
        border-top: 1px solid #e0e0e0;
        overflow-x: hidden !important;
    }

    /* 푸터가 하단 네비게이션 위에 표시되도록 */
    body.has-bottom-nav #ft,
    body.has-bottom-nav #ft_copy {
        margin-bottom: calc(56px + env(safe-area-inset-bottom)) !important;
    }
}

/* ============================================
   11. 모바일 전체 화면 검색 모달
   ============================================ */
.mobile-search-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #FFFFFF;
    z-index: 2000;
    transform: translateY(100%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: transform 0.3s ease, opacity 0.3s ease, visibility 0s linear 0.3s;
    display: flex;
    flex-direction: column;
}

.mobile-search-modal.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.mobile-search-header {
    position: sticky;
    top: 0;
    background: #FFFFFF;
    border-bottom: 1px solid #E0E0E0;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 10;
}

.mobile-search-back {
    background: none;
    border: none;
    font-size: 24px;
    color: #333333;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.mobile-search-form {
    flex: 1;
    display: flex;
    align-items: center;
    background: #F5F5F5;
    border-radius: 8px;
    padding: 8px 12px;
}

.mobile-search-input {
    flex: 1;
    border: none;
    background: none;
    font-size: 16px;
    color: #333333;
    outline: none;
}

.mobile-search-input::placeholder {
    color: #999999;
}

.mobile-search-submit {
    background: none;
    border: none;
    font-size: 20px;
    color: #666666;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.mobile-search-content {
    flex: 1;
    overflow-y: auto;
    padding: 20px 16px;
}

.search-section {
    margin-bottom: 32px;
}

.search-section-title {
    font-size: 18px;
    font-weight: 700;
    color: #111111;
    margin-bottom: 16px;
}

.popular-keywords {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.keyword-tag {
    display: inline-block;
    padding: 8px 16px;
    background: #F5F5F5;
    border-radius: 20px;
    font-size: 14px;
    color: #333333;
    text-decoration: none;
    transition: all 0.2s;
}

.keyword-tag:hover,
.keyword-tag:active {
    background: #E8F5EE;
    color: #00ac5d;
}

.recommended-products {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.recommended-item {
    display: flex;
    gap: 12px;
    padding: 12px;
    background: #FFFFFF;
    border: 1px solid #E0E0E0;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s;
}

.recommended-item:active {
    background: #F8F8F8;
}

.recommended-item-img {
    width: 80px;
    height: 80px;
    flex-shrink: 0;
    background: #F5F5F5;
    border-radius: 6px;
    overflow: hidden;
}

.recommended-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.recommended-item-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
}

.recommended-item-name {
    font-size: 14px;
    color: #333333;
    font-weight: 500;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.recommended-item-price {
    font-size: 16px;
    color: #111111;
    font-weight: 700;
}

/* ============================================
   12. Task #24 모바일 레이아웃 완벽 최적화
   ============================================ */
@media (max-width: 767px) {

    /* 모든 요소 가로 스크롤 제거 */
    html,
    body {
        overflow-x: hidden !important;
        max-width: 100vw !important;
        width: 100% !important;
    }

    /* 카테고리 메뉴 전체 화면(100%) */
    #offCanvasNavBar.offcanvas,
    #offCanvasNavBar.offcanvas.offcanvas-start {
        width: 100% !important;
        max-width: 100% !important;
        --bs-offcanvas-width: 100% !important;
    }

    /* 카테고리 마퀴 모바일 최적화 */
    .category-marquee-wrapper {
        width: 100% !important;
        max-width: 100% !important;
        overflow: hidden !important;
        padding: 0 !important;
    }

    .marquee-row {
        width: 100% !important;
        max-width: 100% !important;
    }

    .category-card {
        padding: 8px 20px 8px 8px;
        gap: 8px;
        min-height: 44px;
    }

    /* 고객 선택 슬라이더 모바일 */
    .customer-choice-swiper {
        width: 100% !important;
        max-width: 100% !important;
        overflow: hidden !important;
        padding: 10px 16px !important;
    }

    /* 고객님들의 선택 카드 링크가 전역 터치 영역 규칙에 영향받지 않도록 보정 */
    .customer-choice-swiper .card-img-top > a {
        display: block !important;
        min-width: 0 !important;
        min-height: 0 !important;
        padding: 0 !important;
    }

    .customer-choice-swiper .card-img-top img {
        display: block !important;
        width: 100% !important;
        height: auto !important;
        object-fit: cover;
    }

    .customer-choice-swiper .row > .col {
        padding-left: 8px !important;
        padding-right: 8px !important;
    }

    .customer-choice-swiper .product-title a {
        display: -webkit-box !important;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        word-break: break-word;
    }

    .choice-nav-btn {
        min-width: 44px !important;
        min-height: 44px !important;
        -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
    }

    /* 인기 카테고리 그리드 모바일 */
    .popular-categories-grid {
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 8px !important;
        box-sizing: border-box !important;
    }

    .popular-category-card {
        min-height: 44px;
        -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
    }

    /* 쿠팡 스타일 슬라이드 메뉴 모바일 */
    .category-slide-menu {
        width: 100% !important;
        max-width: 100vw !important;
    }

    .category-menu-left-item {
        min-height: 44px !important;
        padding: 12px 16px !important;
    }

    .category-2nd-link,
    .category-3rd-link {
        min-height: 44px !important;
        padding: 12px 16px !important;
    }

    /* 하단 네비게이션 */
    .coupang-bottom-nav {
        width: 100% !important;
        max-width: 100% !important;
        left: 0 !important;
        right: 0 !important;
    }

    .coupang-nav-tab {
        min-width: 44px !important;
        min-height: 44px !important;
        -webkit-tap-highlight-color: transparent;
    }

    /* 모바일 검색 모달 */
    .mobile-search-modal {
        width: 100% !important;
        max-width: 100vw !important;
        left: 0 !important;
        right: 0 !important;
    }

    .mobile-search-back,
    .mobile-search-submit {
        min-width: 44px !important;
        min-height: 44px !important;
    }

    .keyword-tag {
        min-height: 44px !important;
        padding: 12px 16px !important;
        -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
    }

    /* Safe area support */
    @supports (padding: env(safe-area-inset-bottom)) {
        body {
            padding-bottom: env(safe-area-inset-bottom);
        }

        .coupang-bottom-nav {
            padding-bottom: calc(env(safe-area-inset-bottom) + 8px) !important;
        }

        #ft,
        #ft_copy {
            padding-bottom: calc(20px + env(safe-area-inset-bottom)) !important;
        }

        body.has-bottom-nav #ft,
        body.has-bottom-nav #ft_copy {
            padding-bottom: calc(20px + 56px + env(safe-area-inset-bottom)) !important;
        }
    }

    /* 모든 이미지 반응형 */
    img {
        max-width: 100% !important;
        height: auto !important;
    }

    /* 컨테이너 최적화 */
    .container,
    .container-fluid,
    section,
    .section {
        width: 100% !important;
        max-width: 100% !important;
        padding-left: 16px !important;
        padding-right: 16px !important;
        box-sizing: border-box !important;
    }
}

/* 아주 작은 화면 (480px 이하) */
@media (max-width: 480px) {
    .container,
    .container-fluid,
    section {
        padding-left: 12px !important;
        padding-right: 12px !important;
    }

    .category-card {
        padding: 6px 16px 6px 6px;
    }

    .popular-categories-grid {
        gap: 10px !important;
    }
}

/* ============================================
   Mobile Hamburger Menu Button (Fixed Display)
   ============================================ */
@media (max-width: 1199px) {
    .main-header .d-xl-none {
        display: flex !important;
        align-items: center;
        justify-content: center;
    }

    /* Ensure button is always visible on mobile */
    .px-3.d-xl-none button {
        display: flex !important;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 0 !important;
    }

    .px-3.d-xl-none button svg {
        display: block !important;
    }

    .px-3.d-xl-none button .fs-12px {
        display: block !important;
        margin-top: 4px;
    }
}

/* ============================================
   Mobile Category Offcanvas Redesign
   ============================================ */
@media (max-width: 767px) {
    #offCanvasNavBar {
        background: #fff;
    }

    #offCanvasNavBar .offcanvas-header {
        padding: 12px 14px 10px;
        border-bottom: 1px solid #efefef;
    }

    #offCanvasNavBar .offcanvas-header .offcanvas-title {
        margin: 0;
    }

    #offCanvasNavBar .offcanvas-header .main_top_logo {
        padding: 0 !important;
        display: block;
    }

    #offCanvasNavBar .offcanvas-header .main_top_logo img {
        height: 36px;
        width: auto;
    }

    #offCanvasNavBar .offcanvas-header .btn-close {
        color: #222 !important;
        opacity: .6;
        filter: none;
    }

    #offCanvasNavBar .icons-actions {
        display: flex;
        justify-content: center;
        align-items: center;
        gap: 28px;
        padding: 10px 0 12px;
        border-bottom: 1px solid #f1f1f1;
    }

    #offCanvasNavBar .icons-actions .icon-action-link {
        position: relative;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 26px;
        height: 26px;
        color: #222;
        text-decoration: none;
    }

    #offCanvasNavBar .icons-actions .icon-action-link .badge {
        top: -1px;
        left: 100%;
        transform: translate(-20%, -35%);
    }

    #offCanvasNavBar .offcanvas-body {
        padding: 0 0 calc(70px + env(safe-area-inset-bottom));
        margin: 0 !important;
        overflow: hidden;
    }

    #offCanvasNavBar .mp-feature-strip {
        display: flex;
        gap: 10px;
        overflow-x: auto;
        overflow-y: hidden;
        padding: 12px 14px 10px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    #offCanvasNavBar .mp-feature-strip::-webkit-scrollbar {
        display: none;
    }

    #offCanvasNavBar .mp-feature-item {
        display: block;
        flex: 0 0 auto;
        width: 74px;
        text-align: center;
        color: #111;
        text-decoration: none;
    }

    #offCanvasNavBar .mp-feature-thumb {
        width: 74px;
        height: 74px;
        border-radius: 18px;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #fff;
        font-size: 11px;
        font-weight: 700;
        letter-spacing: -0.01em;
        margin-bottom: 6px;
        line-height: 1.2;
    }

    #offCanvasNavBar .mp-feature-01 { background: linear-gradient(135deg, #3c6f9a, #2c4062); }
    #offCanvasNavBar .mp-feature-02 { background: linear-gradient(135deg, #884a5a, #4a2630); }
    #offCanvasNavBar .mp-feature-03 { background: linear-gradient(135deg, #4d557d, #2b2f45); }
    #offCanvasNavBar .mp-feature-04 { background: linear-gradient(135deg, #2a313a, #101418); }
    #offCanvasNavBar .mp-feature-05 { background: linear-gradient(135deg, #887a63, #59524a); }

    #offCanvasNavBar .mp-feature-label {
        display: block;
        color: #222;
        font-size: 12px;
        font-weight: 600;
        white-space: nowrap;
    }

    #offCanvasNavBar .mp-mode-tabs {
        display: flex;
        align-items: center;
        gap: 8px;
        padding: 2px 14px 10px;
    }

    #offCanvasNavBar .mp-mode-tab {
        flex: 1;
        border: 1px solid #ececec;
        background: #f3f3f3;
        color: #9b9b9b;
        height: 40px;
        border-radius: 12px;
        font-size: 14px;
        font-weight: 700;
    }

    #offCanvasNavBar .mp-mode-tab.is-active {
        background: #fff;
        color: #222;
        border-color: #e0e0e0;
        box-shadow: inset 0 0 0 1px #e0e0e0;
    }

    #offCanvasNavBar .mp {
        display: flex;
        width: 100%;
        height: calc(100vh - 320px);
        min-height: 420px;
        margin: 0;
        border-top: 1px solid #eeeeee;
        overflow: hidden;
    }

    #offCanvasNavBar .mp .left.tlt {
        flex: 0 0 36%;
        max-width: 36%;
        min-height: 0;
        margin: 0;
        padding: 0;
        list-style: none;
        border-right: 1px solid #ececec;
        background: #f7f7f7;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    #offCanvasNavBar .mp .left.tlt li {
        margin: 0;
        padding: 0;
        border-bottom: 1px solid #ececec;
    }

    #offCanvasNavBar .mp .left.tlt li a {
        display: block;
        margin: 0;
        padding: 13px 12px;
        color: #a0a0a0;
        font-size: 14px;
        font-weight: 600;
        line-height: 1.25;
        text-decoration: none;
    }

    #offCanvasNavBar .mp .left.tlt li.on {
        background: #fff;
        border-left: 3px solid #111;
    }

    #offCanvasNavBar .mp .left.tlt li.on a {
        color: #111;
        font-weight: 700;
        padding-left: 9px;
    }

    #offCanvasNavBar .mp .right.tlt {
        flex: 1;
        min-height: 0;
        margin: 0;
        padding: 0;
        background: #fff;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    #offCanvasNavBar .mp .right.tlt > li {
        display: none;
        margin: 0;
        padding: 10px 0 20px;
        max-height: none;
        overflow: visible;
    }

    #offCanvasNavBar .mp .right.tlt .nd_title {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin: 0 12px 8px;
        padding: 10px 12px;
        background: #f2f2f2;
        border-radius: 12px;
        border: 0;
        color: #111;
        font-size: 15px;
        font-weight: 700;
        text-decoration: none;
    }

    #offCanvasNavBar .mp .right.tlt .nd_title::after {
        content: "";
        width: 28px;
        height: 28px;
        border-radius: 50%;
        background: linear-gradient(135deg, #c9c9c9, #ececec);
        flex-shrink: 0;
    }

    #offCanvasNavBar .mp .right.tlt .cateBox,
    #offCanvasNavBar .mp .right.tlt .cateBoxWithSub {
        display: block !important;
        width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    #offCanvasNavBar .mp .right.tlt .cateBox > a,
    #offCanvasNavBar .mp .right.tlt .cateBoxWithSub > a {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 13px 14px;
        color: #222;
        font-size: 15px;
        font-weight: 600;
        text-decoration: none;
        border-bottom: 1px solid #f0f0f0;
    }

    #offCanvasNavBar .mp .right.tlt .cateBox > a::after,
    #offCanvasNavBar .mp .right.tlt .cateBoxWithSub > a::after {
        content: "\203A";
        font-size: 18px;
        color: #c6c6c6;
        line-height: 1;
    }

    #offCanvasNavBar .mp .right.tlt .cateBox span,
    #offCanvasNavBar .mp .right.tlt .cateBoxWithSub strong {
        color: #222;
        font-size: 15px;
        font-weight: 600;
    }

    #offCanvasNavBar .mp .right.tlt .subCateList {
        display: none !important;
    }

    #offCanvasNavBar .offcanvas-footer {
        display: none;
    }
}
