/* * Icon System: Lucide Icons (License: ISC & MIT) */

/* =========================================
   1. Variables & Base
   ========================================= */
:root { 
    --header-main-height: 68px; 
    --header-border: #f3f4f6; 
    --text-primary: #222; 
    --text-secondary: #6b7280; 
}

#dugtem-header-wrapper button, 
#dugtem-header-wrapper a, 
.mobile-search-layer button, 
.mobile-search-layer a, 
.full-search-layer button, 
.full-search-layer a { 
    color: var(--text-primary); 
}
#dugtem-header-wrapper a, 
.mobile-search-layer a, 
.full-search-layer a { 
    text-decoration: none; 
    color: inherit; 
}
#rb_sidemenu { top: 182px !important; }
.rb_bbs_wrap .btns_gr_wrap { top: 237px !important; }


/* =========================================
   2. Layout Common (Header Wrappers)
   ========================================= */
#header-spacer {
    width: 100%;
    position: relative;
}

#dugtem-header-wrapper { 
    position: relative;
    top: 0; 
    background: #fff; 
    z-index: 999; 
    width: 100%; 
    border-bottom: 1px solid var(--header-border);
    transition: transform 0.2s ease-out;
}

#dugtem-header-wrapper.is-fixed {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
}

#dugtem-header-wrapper .inner { 
    max-width: var(--rb-header-width); 
    margin: 0 auto; 
    height: 100%; 
    position: relative; 
}


/* =========================================
   3. Single App Bar Styling
   ========================================= */
.dugtem-app-bar {
    height: var(--header-main-height);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.dugtem-app-bar .inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 16px;
    box-sizing: border-box;
}

.bar-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-area {
    display: flex;
    align-items: center;
}

.logo-area img {
    height: 46px;
    width: auto;
    display: block;
}

.sub-page-title {
    font-size: 16px;
    font-weight: 700;
    color: #222;
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    letter-spacing: -0.5px;
}

.bar-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Icons Common */
.icon-btn { 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    padding: 0; 
    border: none; 
    background: none; 
    cursor: pointer; 
    color: #222; 
    position: relative;
}
.icon-btn i { 
    width: 24px; 
    height: 24px; 
    stroke-width: 1.8px; 
}





/* --- Full Screen Search Layer --- */
.full-search-layer {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: #fff;
    z-index: 9999;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}
.fsl-header {
    max-width: 1280px; margin: 0 auto; height: 60px;
    display: flex; justify-content: flex-end; align-items: center;
}
.btn-close-layer { background: none; border: none; cursor: pointer; padding: 8px; display: flex; }
.btn-close-layer i { width: 28px; height: 28px; color: #222; }

.fsl-inner { max-width: 800px; margin: 0 auto; padding: 0 20px 60px; }
.fsl-search-box { margin-bottom: 40px; text-align: center; }
.fsl-input {
    width: 100%; border: none; border-bottom: 2px solid #000;
    padding: 15px 0; font-size: 24px; font-weight: 700; color: #000;
    outline: none; border-radius: 0; background: #fff;
}
.fsl-search-box #fullSearchInput { border: 0px; border-bottom: 3px solid #222; padding-bottom: 20px; border-radius: 0px; }
.fsl-search-box #fullSearchInput:focus { border: 0px !important; border-bottom: 3px solid #222 !important;}
.fsl-input::placeholder { color: #ccc; font-weight: 400; }

.fsl-section { margin-bottom: 40px; }
.fsl-title-wrap { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 15px; }
.fsl-title { font-size: 14px; font-weight: 700; color: #000; }
.fsl-date { font-size: 12px; color: #999; }

.fsl-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-item {
    display: inline-block; padding: 8px 16px;
    background: #f4f4f4; border: 1px solid #f4f4f4; border-radius: 20px;
    font-size: 14px; color: #333; transition: all 0.2s;
}
.tag-item:hover { background: #fff; border-color: #ddd; color: #000; }

.fsl-ranking-grid { display: grid; grid-template-columns: repeat(4, 1fr); column-gap: 40px; row-gap: 15px; }
.rank-item { display: flex; align-items: center; padding: 5px 0; font-size: 14px; color: #333; }
.rank-item:hover .rank-word { text-decoration: underline; }
.rank-num { font-weight: 800; color: #000; margin-right: 10px; width: 16px; }
.rank-word { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-state { font-size: 11px; color: #999; margin-left: 5px; font-weight: 500; }
.rank-state.state-new { color: #f15746; font-size: 9px; }
.rank-state.state-up { color: #f15746; }
.rank-state.state-down { color: #3b82f6; }

.fsl-recent-list { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.fsl-recent-list li { display: flex; align-items: center; background: #fff; border: 1px solid #ddd; border-radius: 16px; padding: 6px 12px; }
.fsl-recent-list li a { font-size: 13px; color: #555; margin-right: 6px; }
.fsl-recent-list .btn-del { padding: 0; border: none; background: none; color: #999; cursor: pointer; display: flex; }

/* 이슈 탭 스타일 */
.issue-tab-header {
    display: flex;
    gap: 20px;
    border-bottom: 1px solid #f1f1f1;
    margin-bottom: 15px;
}

.issue-tab-btn {
    background: none;
    border: none;
    padding: 10px 0;
    font-size: 14px;
    font-weight: 500;
    color: #999;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
}

.issue-tab-btn.active {
    color: #222;
    font-weight: 700;
    border-bottom-color: #222;
}

/* 이슈 리스트 스타일 */
.issue-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.issue-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
}

.issue-item a {
    flex: 1;
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 14px;
    color: #333;
    padding-right: 10px;
}
.issue-item a:hover {
    text-decoration: underline;
}

.issue-meta {
    font-size: 11px;
    color: #999;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}
.issue-meta span { display:flex; align-items:center; gap:3px; }
.issue-meta i { width: 12px; height: 12px; }

/* 뱃지 스타일 (마켓/덕아웃 구분용) */
.board-badge {
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 4px;
    background: #f3f4f6;
    color: #666;
    margin-right: 6px;
    font-weight: 500;
}

/* =========================================
   7. Popups (Notification & User Menu)
   ========================================= */
.noti-wrapper, .user-wrapper { position: relative; }

/* 공통 팝업 컨테이너 */
.noti-popup, .user-popup {
    display: none;
    position: absolute; top: 40px; right: -10px;
    background: #fff;
    border: 1px solid #e5e7eb;
    box-shadow: 0 10px 25px rgba(0,0,0,0.12);
    z-index: 2100; overflow: hidden; text-align: left;
}

/* 알림 팝업 크기 */
.noti-popup { width: 320px; border-radius: 12px; }

/* [수정됨] 유저 팝업 (그리드형) 크기 및 위치 */
.user-popup {
    width: 300px;
    right: -10px;
    border-radius: 16px;
}

/* --- Notification Inner (기존 스타일 유지) --- */
.noti-header { padding: 15px 20px; border-bottom: 1px solid #f3f4f6; display: flex; justify-content: space-between; align-items: center; }
.noti-header h3 { font-size: 14px; font-weight: 700; color: #222; margin: 0; }
.noti-close { cursor: pointer; color: #999; display: flex; align-items: center; }
.noti-list { list-style: none; padding: 0; margin: 0; max-height: 400px; overflow-y: auto; }
.noti-item { padding: 15px 20px; border-bottom: 1px solid #f9fafb; cursor: pointer; transition: background 0.2s; display: flex; gap: 12px; align-items: flex-start; }
.noti-item:hover { background-color: #f9fafb; }
.noti-icon-box { width: 32px; height: 32px; background: #f3f4f6; color: #000; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.noti-content { flex: 1; }
.noti-text { font-size: 13px; color: #333; line-height: 1.4; margin-bottom: 4px; }
.noti-date { font-size: 11px; color: #999; display: block; }
.noti-empty { padding: 40px 20px; text-align: center; color: #999; font-size: 13px; }

/* --- [NEW] User Popup Inner (유틸리티 그리드 스타일) --- */

/* 1. 상단 프로필 */
.up-profile { padding: 24px 20px 20px; background: #fff; text-align: center; }
.up-avatar { width: 64px; height: 64px; margin: 0 auto 12px; border-radius: 50%; overflow: hidden; border: 1px solid #f3f4f6; display: flex; align-items: center; justify-content: center; }
.up-avatar img { width: 100% !important; height: 100% !important; object-fit: cover; }
.up-info .up-nick { display: block; font-size: 16px; font-weight: 700; color: #111; margin-bottom: 4px; }
.up-info .up-grade { display: inline-block; font-size: 11px; color: #6b7280; background: #f3f4f6; padding: 2px 8px; border-radius: 10px; font-weight: 500; }

/* 2. 그리드 메뉴 (포인트, 쪽지 등 4칸) */
.up-grid-nav { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid #f3f4f6; border-bottom: 1px solid #f3f4f6; background: #fafafa; }
.up-grid-item { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 16px 0; transition: background 0.2s; position: relative; cursor: pointer; text-decoration: none; }
.up-grid-item:hover { background: #f0f0f0; }
/* 칸막이 선 (옵션) */
.up-grid-item:not(:last-child)::after { content: ''; position: absolute; right: 0; top: 25%; height: 50%; width: 1px; background: #eee; }

.up-icon-box { position: relative; margin-bottom: 6px; color: #4b5563; display: flex; align-items: center; justify-content: center; }
.up-icon-box i { width: 20px; height: 20px; }
.up-badge-dot { position: absolute; top: -2px; right: -2px; width: 6px; height: 6px; background: #ef4444; border-radius: 50%; border: 1px solid #fff; }

.up-label { font-size: 11px; color: #666; font-weight: 500; letter-spacing: -0.5px; }
.up-grid-item.is-point .up-label { color: #222; font-weight: 700; } /* 포인트 강조 */

/* 3. 하단 리스트 메뉴 */
.up-list-nav { list-style: none; margin: 0; background: #fff; }
.up-list-nav li a { display: flex; align-items: center; gap: 10px; padding: 10px 20px; font-size: 13px; color: #444; transition: background 0.2s; text-decoration: none; }
.up-list-nav li a:hover { background: #f9fafb; color: #000; font-weight: 600; }
.up-list-nav li a i { width: 16px; height: 16px; color: #9ca3af; }
.up-list-nav li a.logout { color: #ef4444; }
.up-list-nav li a.logout:hover { background: #fef2f2; }

/* =========================================
   8. Mobile Specifics (Responsive)
   ========================================= */
/* Helper Classes */
.icon-btn-mobile { display: none; }

/* Mobile Search Layer */
.mobile-search-layer { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: #fff; z-index: 9999; overflow-y: auto; }
.ms-header { display: flex; align-items: center; padding: 10px 16px; height: 54px; border-bottom: 1px solid #f1f1f1; background: #fff; gap: 12px; }
.ms-back-btn { background: none; border: none; padding: 4px; margin: 0; cursor: pointer; color: #222; display: flex; align-items: center; justify-content: center; }
.ms-form { flex: 1; position: relative; display: flex; align-items: center; }
.ms-input { width: 100%; height: 40px; background: #f3f4f6; border-radius: 8px; border: none; padding: 0 40px 0 15px; font-size: 15px; color: #222; outline: none; box-sizing: border-box; margin: 0; }
.ms-submit-btn { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); background: none; border: none; padding: 4px; color: #222; cursor: pointer; display: flex; }
.ms-body { padding: 24px 20px; background: #fff; }
.ms-section-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.ms-section-header .title { font-size: 14px; font-weight: 700; color: #222; }

#mobile_recent_list { list-style: none; padding: 0; margin: 0; }
#mobile_recent_list li { display: flex; justify-content: space-between; align-items: center; padding: 14px 0; border-bottom: 1px solid #f9fafb; }
#mobile_recent_list li a { font-size: 14px; color: #333; flex: 1; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#mobile_recent_list .btn-del { background: none; border: none; padding: 8px; color: #ccc; cursor: pointer; display: flex; }
#mobile_no_recent_msg { text-align: center; padding: 60px 0; color: #999; font-size: 14px; }

/* =========================================
   11. GNB Tooltip (말풍선)
   ========================================= */

/* 메뉴 아이템 감싸는 래퍼 (Flex 정렬 유지) */
.gnb-item-wrap {
    position: relative;
    display: flex;
    align-items: center;
    overflow: visible; /* 말풍선 잘림 방지 */
}

/* 말풍선 본체 */
.gnb-tooltip {
    position: absolute;
    top: 30px;            /* 메뉴 텍스트 아래쪽 위치 */
    left: 50%;
    transform: translateX(-50%);
    background-color: #222; /* 진한 검정 (이미지와 동일) */
    color: #fff;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 500;
    white-space: nowrap;  /* 줄바꿈 방지 */
    z-index: 100;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
    opacity: 1;
    pointer-events: none; /* 마우스 클릭 통과 (선택사항) */
    
    /* 둥둥 떠다니는 애니메이션 (삭제 가능) */
    animation: bounceTooltip 1.5s infinite ease-in-out;
}

/* 말풍선 꼬리 (위쪽 화살표) */
.gnb-tooltip::before {
    content: '';
    position: absolute;
    top: -5px;            /* 말풍선 상단 */
    left: 50%;
    transform: translateX(-50%);
    border-width: 0 5px 6px 5px; /* 삼각형 크기 조절 */
    border-style: solid;
    border-color: transparent transparent #222 transparent; /* 아래쪽만 색상 */
}

/* 포인트 강조 텍스트 (노란/주황색) */
.gnb-tooltip .point-txt {
    color: var(--rb-main-color); /* 눈에 띄는 포인트 컬러 */
    font-weight: 700;
}

/* 애니메이션 키프레임 */
@keyframes bounceTooltip {
    0%, 100% { top: 35px; }
    50% { top: 30px; }
}

/* =========================================
   12. Search Suggestion Style
   ========================================= */
.suggest-group { margin-bottom: 20px; }
.suggest-label { 
    font-size: 12px; color: #999; margin-bottom: 8px; 
    font-weight: 600; padding-left: 10px; 
}

.suggest-list { list-style: none; padding: 0; margin: 0; }
.suggest-item { 
    display: flex; align-items: center; padding: 10px 10px; 
    border-radius: 8px; transition: background 0.1s; 
    text-decoration: none; color: #333;
}
.suggest-item:hover { background-color: #f7f7f7; }

.sug-icon { 
    width: 32px; height: 32px; display: flex; align-items: center; 
    justify-content: center; background: #f3f4f6; 
    border-radius: 50%; margin-right: 12px; flex-shrink: 0; color: #888;
}
.sug-icon i { width: 16px; height: 16px; }

.sug-info { display: flex; flex-direction: column; overflow: hidden; }
.sug-text { font-size: 14px; font-weight: 500; color: #222; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sug-path, .sug-meta { font-size: 11px; color: #999; margin-top: 2px; }

/* 검색어 하이라이트 (형광펜 효과) */
.sug-highlight { background-color: #fff3c4; color: #d97706; padding: 1px 3px; border-radius: 3px; font-weight: bold; }


/* --- Banner --- */
.top-banner { background: #000; color: #fff; font-size: 13px; }
.banner-inner { display: flex; justify-content: space-between; align-items: center; max-width: var(--rb-header-width); margin: 0 auto; padding: 8px 20px; }
.banner-content a { display: flex; align-items: center; gap: 4px; }
.banner-side { display: flex; gap: 15px; align-items: center; }
.btn-today-close, .btn-close { background: none; border: none; color: #fff; cursor: pointer; padding: 0; font-size: 11px; }




/* 1. 기본 설정 (숨김 상태 & 변수 적용 준비) */
.sv_wrap .sv {
    display: none; /* 평소엔 숨김 */
    
    /* 그리드 레이아웃 설정 */
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    
    width: 280px !important;
    padding: 12px !important;
    background: #fff !important;
    
    /* ★ 테두리에 메인 컬러 적용 */
    border: 1px solid var(--rb-main-color) !important;
    border-radius: 16px !important;
    
    /* 메인 컬러를 활용한 부드러운 그림자 (color-mix 미지원 브라우저 대비 fallback 포함) */
    box-shadow: 0 10px 25px rgba(0,0,0,0.1) !important; 
    box-shadow: 0 10px 25px color-mix(in srgb, var(--rb-main-color), transparent 85%) !important;
    
    /* 초기화 */
    height: auto !important;
    min-width: unset !important;
    box-sizing: border-box !important;
}

/* 2. 클릭 시 활성화 (그리드로 표시) */
.sv_wrap .sv.sv_on {
    display: grid !important;
    position: absolute !important;
    top: 28px !important; /* 닉네임과 간격 조절 */
    left: 0 !important;
    z-index: 9999 !important;
}

/* 3. 말풍선 꼬리 제거 */
.sv_wrap .sv:before {
    display: none !important;
}

/* 4. 메뉴 버튼 (타일) 디자인 */
.sv_wrap .sv a {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    
    width: auto !important;
    height: auto !important;
    margin: 0 !important;
    padding: 12px 4px !important;
    
    background: #f8f9fa !important; /* 평소엔 연한 회색 */
    border-radius: 8px !important;
    border: 1px solid transparent !important; /* 호버 시 흔들림 방지용 투명 테두리 */
    
    color: #4b5563 !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    text-align: center !important;
    line-height: 1.3 !important;
    word-break: keep-all !important;
    
    transition: all 0.2s ease !important;
}

/* 5. 마우스 호버 효과 (★ 메인 컬러 적용) */
.sv_wrap .sv a:hover {
    background: #fff !important;
    
    /* ★ 테두리와 글자색을 메인 컬러로 변경 */
    border-color: var(--rb-main-color) !important;
    color: var(--rb-main-color) !important;
    
    transform: translateY(-2px) !important;
    
    /* 그림자에도 메인 컬러 살짝 섞기 */
    box-shadow: 0 4px 12px rgba(0,0,0,0.08) !important;
    box-shadow: 0 4px 12px color-mix(in srgb, var(--rb-main-color), transparent 85%) !important;
}

/* Desktop PC View Constraints (Screens wider than mobile) */
/* PC 데스크톱용 브랜딩 패널 기본 숨김 */
.dugtem-pc-brand-panel {
    display: none;
}

/* PC 데스크톱 전용 스타일 (1024px 이상) */
@media (min-width: 1024px) {
    :root {
        --rb-main-width: min(100%, 512px) !important;
        --rb-sub-width: min(100%, 512px) !important;
        --rb-header-width: min(100%, 512px) !important;
        --rb-footer-width: min(100%, 512px) !important;
        --vw: min(100vw, 512px) !important;
    }
    
    html {
        background-color: #f3f4f6 !important; /* Neutral background for PC desktop */
    }

    html::before {
        content: "";
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: -1;
        background-image: url('img/branding_bg.png'); /* 석고 질감 배경 */
        background-size: cover;
        background-position: center;
        opacity: 0.45; /* 배경 불투명도 설정 */
        pointer-events: none;
    }

    .dugtem-pc-brand-panel {
        display: block;
        position: fixed;
        left: calc(50% - 456px); /* 912px 컨테이너 기준 좌측 정렬 (400px 브랜딩 + 512px 메인) */
        top: 0;
        width: 400px;
        height: 100vh;
        background: transparent; /* 전체 배경이 비치도록 투명 설정 */
        box-sizing: border-box;
        z-index: 10;
    }
    
    .brand-panel-inner {
        position: relative;
        height: 100%;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        padding: 40px;
        box-sizing: border-box;
    }
    
    .brand-logo-area {
        margin-bottom: 28px;
        animation: fadeInUpBrand 0.8s cubic-bezier(0.25, 1, 0.5, 1) forwards;
    }
    
    .brand-logo-area img {
        max-width: 180px;
        height: auto;
        display: block;
        filter: drop-shadow(0 4px 6px rgba(0,0,0,0.05));
    }
    
    .brand-copy-area {
        text-align: center;
        margin-bottom: 24px;
        animation: fadeInUpBrand 1s cubic-bezier(0.25, 1, 0.5, 1) forwards;
    }
    
    .brand-sub-title {
        display: block;
        font-size: 26px;
        font-weight: 900;
        color: #1a1a1a;
        letter-spacing: 3px;
        margin-bottom: 12px;
        text-transform: uppercase;
        font-family: 'Outfit', 'Inter', 'Noto Sans KR', sans-serif;
    }
    
    .brand-description {
        display: block;
        font-size: 13px;
        color: #555;
        font-weight: 500;
        letter-spacing: -0.5px;
    }
    
    .brand-copyright-area {
        text-align: center;
        margin-bottom: 120px;
        animation: fadeInUpBrand 1.2s cubic-bezier(0.25, 1, 0.5, 1) forwards;
    }
    
    .brand-copyright {
        font-size: 11px;
        color: #888;
        font-weight: 500;
        letter-spacing: 0.5px;
        line-height: 1.5;
    }
    
    .brand-sns-area {
        position: absolute;
        bottom: 70px;
        left: 50%;
        transform: translateX(-50%);
        display: flex;
        flex-direction: column;
        gap: 16px;
        align-items: flex-start;
        width: max-content;
        animation: fadeInUpBrandSNS 1.4s cubic-bezier(0.25, 1, 0.5, 1) forwards;
    }
    
    .brand-sns-link {
        display: flex;
        align-items: center;
        gap: 12px;
        color: #2b2b2b !important;
        text-decoration: none !important;
        font-size: 14px;
        font-weight: 600;
        transition: transform 0.2s ease, color 0.2s ease;
    }
    
    .brand-sns-link:hover {
        transform: translateX(4px);
        color: var(--rb-main-color, #dc2626) !important;
    }
    
    .brand-sns-link i {
        width: 20px;
        height: 20px;
        stroke-width: 2px;
        color: #333;
        transition: color 0.2s ease;
    }
    .brand-sns-link:hover i {
        color: var(--rb-main-color, #dc2626);
    }
    
    /* 메인 바디 및 고정 레이아웃 우측 이동 및 512px 제약 */
    body {
        max-width: 512px;
        margin-left: calc(50% - 56px) !important;
        margin-right: auto !important;
        background-color: #ffffff !important;
        box-shadow: 0 0 30px rgba(0, 0, 0, 0.15);
        position: relative;
        min-height: 100vh;
        border-left: 1px solid #e5e7eb;
    }
    
    .index, 
    .sub,
    main {
        max-width: 512px !important;
        width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        box-sizing: border-box !important;
    }

    /* 레이아웃 내부의 와이드 섹션 및 모듈 탈출 차단 및 좌우 여백 (-) 현상 제거 */
    .rb_module_wide,
    .rb_module_mid,
    .rb_sec_wide,
    .rb_carousel_img,
    .sec_wide_set,
    .rb_section_box,
    .content_box,
    .flex_box {
        max-width: 100% !important;
        width: 100% !important;
        min-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        left: auto !important;
        right: auto !important;
        transform: none !important;
        box-sizing: border-box !important;
        padding-left: 6px !important;
        padding-right: 6px !important;
    }
    
    /* 모바일용 레이아웃 배치와 여백 스타일 적용 (데스크톱에서도 모바일 미디어쿼리 스타일을 강제) */
    .rb_section_box {
        display: block !important;
    }
    .rb_section_box .flex_box {
        width: 100% !important;
    }
    .flex_box {
        width: 100% !important;
        margin-bottom: 0px !important;
    }
    .index {
        margin-top: 0px !important;
        margin-bottom: 0px !important;
    }
    
    #dugtem-header-wrapper.is-fixed {
        max-width: 512px;
        left: calc(50% - 56px) !important;
        right: auto !important;
        margin: 0 !important;
        width: 100%;
        transform: none !important;
        transition: none !important;
        border-left: 1px solid #e5e7eb;
    }
    
    .mobile-search-layer, 
    .full-search-layer {
        max-width: 512px;
        left: calc(50% - 56px) !important;
        right: auto !important;
        margin: 0 !important;
        width: 100% !important;
        transform: none !important;
        transition: none !important;
        border-left: 1px solid #e5e7eb;
    }
}

@keyframes fadeInUpBrand {
    from {
        opacity: 0;
        transform: translateY(15px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUpBrandSNS {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(15px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}