/* BASIC css start */
:root{
    --hd-text:#111;
    --hd-sub:#6b7280;
    --hd-line:#eceef2;
    --hd-bg:#fff;
    --hd-soft:#f7f8fa;
    --hd-point:#111;
    --hd-point2:#ef4444;
    --hd-shadow:0 10px 30px rgba(17,17,17,.06);

    /* ★ [추가] safe-area 변수 — 인앱 브라우저 상단 잘림 해결 핵심 */
    --sat: env(safe-area-inset-top, 0px);
}

html, body{
    font-family:'NanumSquareNeo','Apple SD Gothic Neo',sans-serif;
    color:var(--hd-text);
    background:#fff;
}

/* ============================================================
   ★ 상단 고정 띠배너 — safe-area 대응 완료
   ============================================================ */
.top_notice_bar{
    position:fixed;
    top:0;
    left:0;
    right:0;
    z-index:300;
    background:#111;

    /* ★ [수정] 고정 height 제거 → padding-top으로 safe-area 흡수 */
    height:auto;
    padding-top: constant(safe-area-inset-top); /* iOS 11.0~11.1 */
    padding-top: env(safe-area-inset-top, 0px); /* iOS 11.2+ */
}
.top_notice_bar a{
    display:flex;
    align-items:center;
    justify-content:center;
    width:100%;
    height:42px; /* ★ 내부 콘텐츠만 42px 유지 */
    color:#fff;
    font-size:12px;
    font-weight:800;
    text-align:center;
}

/* ★ [수정] spacer도 safe-area 반영 */
.top_notice_spacer{
    height: 42px;
    height: calc(42px + constant(safe-area-inset-top));
    height: calc(42px + env(safe-area-inset-top, 0px));
}

/* ============================================================
   ★ 헤더 — sticky top 동적 계산
   ============================================================ */
.renew_header{
    position:sticky;
    /* ★ [수정] top도 safe-area 반영 */
    top: 42px;
    top: calc(42px + constant(safe-area-inset-top));
    top: calc(42px + env(safe-area-inset-top, 0px));
    z-index:250;
    background:rgba(255,255,255,.96);
    backdrop-filter:blur(12px);
    border-bottom:1px solid rgba(17,17,17,.05);
}
.renew_header .header_inner{
    height:70px;
    padding:0 7px;
    display:flex;
    align-items:center;
    justify-content:space-between;
}
.renew_header .header_left,
.renew_header .header_right{
    width:84px;
    display:flex;
    align-items:center;
    gap:8px;
}
.renew_header .header_right{
    justify-content:flex-end;
}
.renew_header .header_center{
    flex:1;
    text-align:center;
}
.renew_header .header_center h1 a{
    display:inline-block;
}
.renew_header .header_center h1 img{
    width:118px;
    display:block;
}
.inner_page_header{
    display:none;
}
.inner_page_header .header_center h1 img{
    width:110px;
}

/* MENU 버튼 */
.menu_text_btn{
    min-width:52px;
    height:34px;
    padding:0 12px;
    border:1px solid #111;
    border-radius:999px;
    background:#fff;
    color:#111;
    font-size:11px;
    font-weight:900;
    letter-spacing:.08em;
}

/* 아이콘 버튼 */
.icon_btn{
    width:38px;
    height:38px;
    border:1px solid #edf0f3;
    border-radius:999px;
    display:flex;
    align-items:center;
    justify-content:center;
    background:#fff;
    color:#111;
    position:relative;
}
.icon_btn svg{
    width:19px;
    height:19px;
}
.cart_btn sup{
    min-width:18px;
    height:18px;
    padding:0 4px;
    border-radius:999px;
    background:var(--hd-point2);
    color:#fff;
    font-size:10px;
    line-height:18px;
    text-align:center;
    position:absolute;
    top:-4px;
    right:-4px;
    box-sizing:border-box;
}

/* 카테고리 칩 */
.header_keyword_row{
    padding:0 0 12px;
}
#cate_swiper{
    overflow:hidden;
    padding:0 16px;
}
#cate_swiper .swiper-slide{
    width:auto !important;
}
#cate_swiper .swiper-slide a{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    height:32px;
    padding:0 14px;
    border-radius:999px;
    background:#f4f5f7;
    color:#111;
    font-size:12px;
    font-weight:800;
    white-space:nowrap;
}

/* ============================================================
   ★ 퀵탑 — safe-area-inset-bottom 도 같이 적용
   ============================================================ */
#quick_button{
    display:none;
    position:fixed;
    right:16px;
    bottom:18px;
    bottom: calc(18px + env(safe-area-inset-bottom, 0px));
    width:46px;
    height:46px;
    border:0;
    border-radius:999px;
    background:#111;
    color:#fff;
    z-index:200;
    box-shadow:var(--hd-shadow);
}
#quick_button svg{
    width:22px;
    height:22px;
}

/* 딤 */
.aside_dim{
    display:none;
    position:fixed;
    inset:0;
    background:rgba(17,17,17,.48);
    z-index:1000;
}

/* ============================================================
   ★ 사이드 메뉴 — 상단 safe-area 반영
   ============================================================ */
.renew_aside{
    display:none;
    position:fixed;
    top:0;
    left:0;
    width:88%;
    max-width:380px;
    height:100%;
    background:#fff;
    overflow-y:auto;
    z-index:1001;
    box-shadow:20px 0 40px rgba(0,0,0,.12);
}
.renew_aside .asideTop{
    position:relative;
    /* ★ [수정] safe-area 반영하여 인앱에서도 닫기 버튼/텍스트 안 잘리게 */
    padding:28px 20px 22px;
    padding-top: calc(28px + constant(safe-area-inset-top));
    padding-top: calc(28px + env(safe-area-inset-top, 0px));
    background:linear-gradient(135deg,#111 0%, #2c3546 100%);
}
.renew_aside .ham_close{
    position:absolute;
    top:18px;
    /* ★ [수정] 닫기 버튼도 safe-area 반영 */
    top: calc(18px + constant(safe-area-inset-top));
    top: calc(18px + env(safe-area-inset-top, 0px));
    right:18px;
    min-width:60px;
    height:34px;
    padding:0 12px;
    border:1px solid rgba(255,255,255,.2);
    border-radius:999px;
    background:transparent;
    color:#fff;
    font-size:11px;
    font-weight:900;
    letter-spacing:.08em;
}
.aside_user_box .aside_label{
    font-size:11px;
    color:rgba(255,255,255,.6);
    letter-spacing:.08em;
}
.aside_user_box h1{
    margin-top:12px;
    font-size:22px;
    font-weight:400;
    line-height:1.45;
    color:#fff;
}
.aside_user_box h1 b{
    font-weight:900;
}
.aside_user_box h1 a{
    color:#fff;
}
.aside_user_box .aside_desc{
    margin-top:10px;
    font-size:13px;
    line-height:1.6;
    color:rgba(255,255,255,.82);
}
.aside_user_box .aside_desc a{
    color:#fff;
    text-decoration:underline;
}

/* 유저메뉴 */
.user_menu{
    padding:14px 16px;
    border-bottom:8px solid #f5f6f8;
}
.user_menu ul{
    display:grid;
    grid-template-columns:repeat(4,1fr);
    gap:8px;
}
.user_menu li a{
    display:flex;
    align-items:center;
    justify-content:center;
    min-height:42px;
    border-radius:12px;
    background:#f8f9fb;
    font-size:12px;
    font-weight:800;
    color:#111;
    text-align:center;
}

/* 검색 */
.aside_search_box{
    padding:16px;
    border-bottom:8px solid #f5f6f8;
}
.aside_search_box a{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:12px;
    height:48px;
    padding:0 16px;
    border:1px solid #e7ebf0;
    border-radius:14px;
    background:#fff;
    color:#8b95a1;
    font-size:13px;
    font-weight:700;
}
.aside_search_box svg{
    width:18px;
    height:18px;
    color:#111;
}

/* 카테고리 */
.aside_tit{
    padding:18px 16px 12px;
    font-size:14px;
    font-weight:900;
    color:#111;
    display:flex;
    align-items:center;
    justify-content:space-between;
}
.aside_tit a{
    font-size:12px;
    color:#6b7280;
    font-weight:800;
}
.navCategory{
    border-bottom:8px solid #f5f6f8;
}
.navCategory ul{
    padding:0 16px 18px;
}
.navCategory .cate1{
    border-bottom:1px solid #f1f3f5;
}
.navCategory .cate1:last-child{
    border-bottom:0;
}
.navCategory .cate1_link{
    min-height:54px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    font-size:14px;
    font-weight:900;
    color:#111;
}
.navCategory .cate1_link em{
    font-style:normal;
    color:#9ca3af;
}
.navCategory .cate2{
    display:none;
    padding:0 0 10px;
}
.navCategory .cate2 > dd > a{
    display:flex;
    align-items:center;
    justify-content:space-between;
    min-height:42px;
    padding-left:8px;
    font-size:13px;
    font-weight:700;
    color:#4b5563;
}
.navCategory .cate2 > dd > a i{
    font-style:normal;
    color:#9ca3af;
}
.navCategory .cate3{
    display:none;
    padding:6px 0 10px 8px;
}
.navCategory .cate3 li a{
    display:block;
    padding:8px 0;
    font-size:12px;
    color:#6b7280;
}

.navCommunity{
    border-bottom:8px solid #f5f6f8;
}
.navCommunity ul{
    padding:0 16px 18px;
}
.navCommunity ul li a{
    display:block;
    min-height:42px;
    line-height:42px;
    padding:0 14px;
    border-radius:12px;
    background:#f8f9fb;
    font-size:13px;
    font-weight:800;
}

.navRecent{
    padding-bottom:14px;
}
.navRecent ul{
    display:flex;
    gap:10px;
    padding:0 16px;
}
.navRecent li{
    width:33.333%;
}
.navRecent li img{
    width:100%;
    display:block;
    border-radius:14px;
    background:#f5f5f5;
}

.asideBottom{
    padding:0 16px 24px;
    /* ★ [추가] 하단 safe-area 반영 */
    padding-bottom: calc(24px + env(safe-area-inset-bottom, 0px));
}
.asideBottom a{
    display:flex;
    align-items:center;
    justify-content:center;
    height:50px;
    border-radius:14px;
    background:#111;
    color:#fff;
    font-size:14px;
    font-weight:900;
}

body.aside_open{
    overflow:hidden;
}

/* BASIC css end */

