/**
 * HC JOYN MENU — 햄버거 메뉴 위치 (데스크탑/모바일/하이브리드앱)
 *
 * File: assets/css/menu-position.css
 * v2.1.12: hc-joyn-menu.php의 add_menu_position_scripts() 인라인 <style> 에서 분리
 *          → 매 페이지 HTML에 직접 박혀 있던 약 35줄을 캐시 가능한 외부 CSS로 이동
 */

/* 데스크탑 햄버거 메뉴 위치 강제 적용 — 최고 우선순위 */
@media (min-width: 769px) {
    html body .hc-joyn-menu-trigger-top-right.hc-joyn-menu-trigger {
        top: 25px !important;
        right: 50px !important;
    }

    html body.admin-bar .hc-joyn-menu-trigger-top-right.hc-joyn-menu-trigger {
        top: 55px !important;
        right: 50px !important;
    }

    /* data 속성으로 더 구체적으로 지정 */
    html body .hc-joyn-menu-trigger-top-right.hc-joyn-menu-trigger[data-desktop-position="true"] {
        right: 50px !important;
    }
}

/* 모바일 — 헤더 없을 때만 54px 폴백 (헤더 있으면 JS에서 로고와 같은 라인 + 오른쪽) */
@media (max-width: 768px) {
    .hc-joyn-menu-trigger-top-right:not(.hc-joyn-menu-trigger-mobile-header-row),
    .admin-bar .hc-joyn-menu-trigger-top-right:not(.hc-joyn-menu-trigger-mobile-header-row) {
        top: max(54px, calc(env(safe-area-inset-top, 0px) + 12px)) !important;
        right: 16px !important;
    }
    .hc-joyn-menu-trigger.hc-joyn-menu-trigger-mobile-header-row {
        right: 16px !important;
        left: auto !important;
    }
}

/* 하이브리드앱 — 모바일과 동일 (헤더 기준 또는 54px, 오른쪽) */
html body.hcjoyn-hybrid-app .hc-joyn-menu-trigger-top-right.hc-joyn-menu-trigger:not(.hc-joyn-menu-trigger-mobile-header-row),
html body.hcjoyn-hybrid-app.admin-bar .hc-joyn-menu-trigger-top-right.hc-joyn-menu-trigger:not(.hc-joyn-menu-trigger-mobile-header-row) {
    top: max(54px, calc(env(safe-area-inset-top, 0px) + 12px)) !important;
    right: 16px !important;
}
