/*
 * 파일명: phantom.css
 * 위치: /theme/기본테마/css/phantom.css
 * 기능: 팬텀디자인 인트라넷 완전 개선 스타일
 * 작성일: 기존
 * 수정일: 2025-06-16 (레이아웃 완전 개선)
 */

/* ===================================
 * 사이드바 스타일 (완전 개선)
 * =================================== */

/* 사이드바 기본 */
.sidebar { 
    width: 100%; 
    max-width: 285px; 
    position: fixed; 
    z-index: 10; 
    background: #fff; 
    left: 0; 
    top: 0; 
    height: 100%; 
    transition: all 0.3s ease; 
    box-shadow: 0 0 21px 0 rgb(89 102 122 / 10%); 
    font-size: 14px; 
}

/* 사이드바 접힌 상태 완전 수정 */
.sidebar.collapsed {
    width: 70px;
}

.sidebar.collapsed .logo {
    padding: 15px 10px;
    justify-content: center;
}

.sidebar.collapsed .logo a {
    display: none;
}

.sidebar.collapsed .general h1,
.sidebar.collapsed .general h2 {
    opacity: 0;
    height: 0;
    padding: 0;
    margin: 0;
    overflow: hidden;
    transition: all 0.3s ease;
}

.sidebar.collapsed .general li.sb_one span {
    padding: 12px 10px;
    justify-content: center;
}

.sidebar.collapsed .general li.sb_one span > div,
.sidebar.collapsed .general li.sb_one span > i:not(.fa-dashboard-web):not(.fa-cloud-download):not(.fa-file-text):not(.fa-wrench):not(.fa-check-circled):not(.fa-circle-o-notch),
.sidebar.collapsed .sb_sum,
.sidebar.collapsed .arrow {
    display: none;
}

.sidebar.collapsed .general li.sb_one span > i:first-child {
    display: block !important;
    margin: 0;
}

.sidebar.collapsed .sb_two {
    display: none !important;
}

.sidebar.collapsed .quick-memo {
    opacity: 0;
    pointer-events: none;
    transform: translateX(-100%);
}

/* 로고 영역 */
.sidebar .logo { 
    width: 100%; 
    max-height: 70px; 
    display: flex; 
    padding: 15px 27px; 
    justify-content: space-between; 
    align-items: center; 
    box-shadow: -9px 0 20px rgb(89 102 122 / 10%);
}

.sidebar.collapsed .logo img {
    width: 30px;
    transition: all 0.3s ease;
}

/* 토글 버튼 */
.sidebar .toggle-sidebar {
    cursor: pointer;
    padding: 8px;
    border-radius: 5px;
    transition: all 0.3s ease;
    background: rgba(115, 102, 255, 0.1);
    color: #7366ff;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.sidebar .toggle-sidebar:hover {
    background: rgba(115, 102, 255, 0.2);
    transform: scale(1.1);
}

/* 사이드바 메뉴 */
.sidebar .general { 
    color: #444; 
    padding-bottom: 12px; 
}

.sidebar .general h1 { 
    padding: 28px 20px; 
    font-weight: 600; 
    padding-bottom: 10px; 
    transition: all 0.3s ease;
}

.sidebar .general h2 { 
    border-top: 1px solid #e1e1e1; 
    font-weight: 600; 
    width: calc(100% - 40px); 
    margin-left: 20px; 
    padding: 22px 0px; 
    margin-top: 10px; 
    padding-bottom: 10px; 
    transition: all 0.3s ease;
}

.sidebar .general li.sb_one { }

.sidebar .general li.sb_one span { 
    display: flex; 
    position: relative; 
    cursor: pointer; 
    font-weight: 500; 
    width: 100%; 
    padding: 12px 20px; 
    align-items: center; 
    flex-wrap: wrap;
    transition: all 0.3s ease;
}

.sidebar .general li.sb_one span:hover {
    background: rgba(115, 102, 255, 0.05);
}

.sidebar .general li.sb_one span.is-active { 
    color: #7366ff; 
    font-weight: 600; 
    background: #f1f0ff; 
    position: relative; 
}

.sidebar .general li.sb_one span.is-active::after { 
    content: ''; 
    position: absolute; 
    right: 0; 
    top: 10%; 
    height: 80%; 
    width: 4px; 
    background: #7366ff; 
    border-radius: 5px 0px 0px 5px; 
}

.sidebar .general li.sb_one i { 
    max-width: 18px; 
    margin-right: 7px; 
}

.sidebar .general li.sb_one span > i { 
    max-width: 18px; 
    margin-right: 10px; 
}

.sidebar .general li.sb_one span > i.arrow { 
    position: absolute; 
    right: 20px; 
    transition: transform 0.3s ease;
}

/* 서브메뉴 개선 */
.sidebar .general li.sb_one > .sb_two { 
    width: 100%; 
    padding: 2px 20px; 
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s ease;
}

.sidebar .general li.sb_one > .sb_two:not(.is-hidden) {
    max-height: 300px;
}

.sidebar .general li.sb_one > .sb_two > a { 
    display: block; 
    width: 100%; 
    position: relative; 
    padding: 10px 0; 
    padding-left: 12px; 
    transition: all 0.3s ease;
}

.sidebar .general li.sb_one > .sb_two > a.active,
.sidebar .general li.sb_one > .sb_two > a:hover { 
    cursor: pointer; 
    color: #7366ff; 
    font-weight: 600;
}

.sidebar .general li.sb_one > .sb_two > a.active::before,
.sidebar .general li.sb_one > .sb_two > a:hover::before { 
    background: #7366ff; 
}

.sidebar .general li.sb_one > .sb_two > a::before { 
    content: ''; 
    width: 4px; 
    height: 4px; 
    background: #444; 
    border-radius: 100%; 
    position: absolute; 
    left: 0; 
    top: calc(50% - 2px); 
}

.sidebar .general li.sb_one > .is-hidden {
    display: none;
}

.sb_sum { 
    position: absolute; 
    right: 60px; 
    top: 11px; 
    background-color: rgba(115, 102, 255, 0.1); 
    color: #7366ff; 
    font-size: 11px; 
    padding: 2px 5px; 
    border-radius: 3px;
    transition: all 0.3s ease;
}

.sidebar .information { 
    position: fixed; 
    display: flex; 
    bottom: 0; 
    left: 0; 
}

.sidebar .information a { 
    width: 50%; 
}

/* ===================================
 * 빠른 메모장
 * =================================== */

.quick-memo {
    position: relative;
    margin: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    border: 1px solid rgba(115, 102, 255, 0.1);
}

.memo-header {
    padding: 15px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    background: rgba(115, 102, 255, 0.02);
}

.memo-header:hover {
    background: rgba(115, 102, 255, 0.05);
}

.memo-header h4 {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin: 0;
    display: flex;
    align-items: center;
}

.memo-header h4 i {
    margin-right: 8px;
    color: #7366ff;
}

.memo-toggle {
    color: #7366ff;
    transition: transform 0.3s ease;
    font-size: 12px;
}

.memo-toggle.collapsed {
    transform: rotate(180deg);
}

.memo-content {
    padding: 15px;
    max-height: 150px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.memo-content.collapsed {
    max-height: 0;
    padding: 0 15px;
}

.memo-textarea {
    width: 100%;
    height: 100px;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 10px;
    font-size: 12px;
    resize: none;
    font-family: inherit;
    transition: border-color 0.3s ease;
    background: #fafafa;
}

.memo-textarea:focus {
    outline: none;
    border-color: #7366ff;
    box-shadow: 0 0 0 2px rgba(115, 102, 255, 0.1);
    background: #fff;
}

.memo-save-btn {
    background: #7366ff;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 11px;
    cursor: pointer;
    margin-top: 8px;
    transition: all 0.3s ease;
}

.memo-save-btn:hover {
    background: #5a52d5;
}

.memo-save-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* ===================================
 * 헤더 스타일 (개선)
 * =================================== */

#phantom_header { 
    position: fixed; 
    top: 0; 
    left: 0; 
    width: 100%; 
    z-index: 5; 
    padding: 10px 30px; 
    padding-left: 315px; 
    height: 100%; 
    max-height: 70px; 
    display: flex; 
    align-items: center; 
    background: #fff; 
    box-shadow: 0px 4px 40px rgb(39 32 120 / 5%); 
    transition: all 0.3s ease; 
    gap: 20px;
}

.sidebar.collapsed ~ #phantom_header {
    padding-left: 100px;
}

/* 전역 검색 */
.global-search {
    position: relative;
    flex: 1;
    max-width: 400px;
}

.search-input {
    width: 100%;
    padding: 8px 40px 8px 15px;
    border: 1px solid #ddd;
    border-radius: 20px;
    font-size: 13px;
    transition: all 0.3s ease;
    background: #f8f9fa;
}

.search-input:focus {
    outline: none;
    border-color: #7366ff;
    box-shadow: 0 0 0 3px rgba(115, 102, 255, 0.1);
    background: #fff;
}

.search-btn {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    background: #7366ff;
    color: #fff;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-size: 12px;
}

.search-btn:hover {
    background: #5a52d5;
    transform: translateY(-50%) scale(1.1);
}

/* 날씨 위젯 */
.weather-widget {
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, rgba(115, 102, 255, 0.1), rgba(116, 204, 244, 0.1));
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 13px;
    color: #7366ff;
    border: 1px solid rgba(115, 102, 255, 0.2);
    transition: all 0.3s ease;
    cursor: pointer;
    min-width: 150px;
    flex-shrink: 0;
}

.weather-widget:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(115, 102, 255, 0.2);
}

.weather-widget i {
    margin-right: 5px;
    font-size: 14px;
}

/* 기존 헤더 요소들 */
#phantom_header .phantom_news { 
    flex: 2;
    min-width: 300px;
    align-content: center; 
    overflow: hidden; 
    display: flex; 
    justify-content: flex-start; 
    align-items: center; 
    height: 100%; 
    z-index: 99999; 
    position: relative; 
    flex-wrap: wrap;
}

#phantom_header .phantom_news .swiper-wrapper { 
    width: 100%; 
    text-align: left; 
    line-height: 1em; 
}

#phantom_header .phantom_news .swiper-wrapper .swiper-slide { 
    font-size: 14px; 
    line-height: 1em; 
    letter-spacing: -0.5px; 
    align-items: center;
}

#phantom_header .phantom_news .swiper-wrapper .swiper-slide > b { 
    color: #7366ff; 
    font-weight: 400; 
    margin: 0 3px;
}

#phantom_header .phantom_news .swiper-wrapper .swiper-slide > img { 
    max-height: 26px; 
    margin-top: -8px; 
}

#phantom_header .phantom_profile { 
    display: flex; 
    align-items: center; 
    flex-shrink: 0;
}

#phantom_header .phantom_profile .user_profile { 
    position: relative; 
    padding: 20px 0; 
    display: flex; 
    flex-wrap: wrap; 
}

#phantom_header .phantom_profile .user_profile .profile_image { 
    margin-right: 10px; 
}

#phantom_header .phantom_profile .user_profile .profile_image img { 
    max-height: 30px; 
    border-radius: 100%; 
    border: 1px solid #e1e1e1; 
}

#phantom_header .phantom_profile .user_profile .profile_content { 
    font-size: 13px; 
    display: flex; 
    flex-direction: row; 
    flex-wrap: wrap; 
    justify-content: center; 
    align-items: center; 
}

#phantom_header .phantom_profile .user_profile:hover .profile_ul { 
    display: block; 
    top: 70px; 
    right: 0; 
    width: 100%; 
    position: absolute;  
    background: #fff; 
    box-shadow: 0 0 21px 0 rgb(89 102 122 / 10%); 
    border-radius: 8px; 
    font-size: 12px; 
}

#phantom_header .phantom_profile .user_profile .profile_ul { 
    display: none; 
}

#phantom_header .phantom_profile .user_profile .profile_ul a { 
    padding: 10px 20px; 
    display: inline-block; 
    width: 100%; 
    border-bottom: 1px solid #dcdcdc; 
}

#phantom_header .phantom_profile .user_profile .profile_ul a:nth-last-child(1) { 
    border: none; 
}

#phantom_header .phantom_profile .user_profile .profile_ul a:hover { 
    transition: 0.3s ease all; 
    color: #7366ff; 
}

#phantom_header .phantom_profile .user_profile .profile_content b { 
    margin-right: 5px; 
}

#phantom_header .clock { 
    font-size: 14px; 
    color: #666; 
    font-weight: 350; 
    letter-spacing: -0.5px; 
    white-space: nowrap;
    flex-shrink: 0;
}

#phantom_header .clock > i { 
    margin-right: 3px; 
}

#phantom_header .clock .clock_ampm { 
    font-size: 14px; 
}

/* ===================================
 * 컨텐츠 스타일 (완전 개선)
 * =================================== */

#phantom_content { 
    width: calc(100% - 285px); 
    margin-left: 285px; 
    min-height: calc(100vh - 70px); 
    margin-top: 70px; 
    transition: all 0.3s ease;
}

.sidebar.collapsed ~ #phantom_content {
    width: calc(100% - 70px); 
    margin-left: 70px; 
}

#phantom_content .navigator { 
    display: inline-block; 
    width: 100%; 
    padding: 14px 30px; 
} 

#phantom_content .navigator .nav_row { 
    width: 100%; 
    display: flex; 
    justify-content: space-between; 
}

#phantom_content .navigator .nav_row h1 { 
    font-size: 20px; 
    letter-spacing: -1px;
}

#phantom_content .navigator .nav_row .right_nav { 
    position: relative; 
    display: flex; 
    font-size: 13px; 
}

#phantom_content .navigator .nav_row .right_nav li:nth-child(1)::after { 
    position: relative; 
    content: '/'; 
    margin: 0 10px; 
    font-size: 10px;
}

#phantom_content .navigator .nav_row .right_nav li:nth-child(2) { 
    color: #7366ff; 
    font-weight: 500; 
}

#phantom_content .content_wrap {
    display: flex; 
    flex-wrap: wrap; 
    padding: 24px; 
    background: rgba(242, 243, 247, 0.5); 
}

/* ===================================
 * 바로가기 메뉴
 * =================================== */

.phantom_quick_access {
    width: 100%;
    background: #fff;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 24px;
    box-shadow: 1px 2px 21px -2px rgb(214 214 227 / 80%);
    transition: all 0.3s ease;
}

.phantom_quick_access:hover {
    transform: translateY(-2px);
    box-shadow: 1px 8px 25px -2px rgb(214 214 227 / 90%);
}

.phantom_quick_access h2 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 15px;
    color: #333;
    display: flex;
    align-items: center;
}

.phantom_quick_access h2 i {
    margin-right: 8px;
    color: #7366ff;
}

.quick_grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.quick_item {
    display: flex;
    align-items: center;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.3s ease;
    border-left: 4px solid transparent;
    color: #333;
}

.quick_item:hover {
    background: #fff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
    border-left-color: #7366ff;
    text-decoration: none;
    color: #333;
}

.quick_icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    color: #fff;
    font-size: 16px;
    transition: all 0.3s ease;
}

.quick_item:hover .quick_icon {
    transform: scale(1.1);
}

.quick_info {
    flex: 1;
}

.quick_title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 2px;
    color: #333;
}

.quick_desc {
    font-size: 12px;
    color: #666;
}

/* ===================================
 * 새로운 레이아웃 (완전 개선)
 * =================================== */

.main_wrapper {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* 상단 섹션: 차트 + 프로젝트 현황 가로 배치 */
.top_section {
    display: flex;
    gap: 24px;
    align-items: stretch;
}

.top_section .main_section_02 {
    flex: 2;
    min-width: 0;
}

.top_section .summary_cards {
    flex: 1;
    min-width: 300px;
    max-width: 400px;
    flex-direction: column;
    justify-content: space-between;
    margin-bottom: 0;
    height: auto;
}

/* 하단 섹션: 위젯 3개 가로 3등분 */
.bottom_widgets {
    display: flex;
    gap: 24px;
    align-items: stretch;
}

.bottom_widgets > * {
    flex: 1;
    min-width: 0;
}

/* ===================================
 * 간단 요약 카드 스타일
 * =================================== */

.summary_cards {
    display: flex;
    gap: 15px;
    background: #fff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 1px 2px 21px -2px rgb(214 214 227 / 80%);
    transition: all 0.3s ease;
    margin-bottom: 24px;
}

.summary_cards:hover {
    transform: translateY(-2px);
    box-shadow: 1px 8px 25px -2px rgb(214 214 227 / 90%);
}

.summary_card {
    flex: 1;
    display: flex;
    align-items: center;
    padding: 20px 15px;
    border-radius: 8px;
    background: #f8f9fa;
    transition: all 0.3s ease;
}

.summary_card:hover {
    background: #fff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.card_icon {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-right: 15px;
}

.card_content {
    flex: 1;
}

.card_number {
    font-size: 28px;
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.card_label {
    font-size: 13px;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* 공통 위젯 스타일 */
.todo_widget,
.favorites_widget,
.recent_files_widget {
    background: #fff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 1px 2px 21px -2px rgb(214 214 227 / 80%);
    transition: all 0.3s ease;
}

.todo_widget:hover,
.favorites_widget:hover,
.recent_files_widget:hover {
    transform: translateY(-2px);
    box-shadow: 1px 8px 25px -2px rgb(214 214 227 / 90%);
}

.widget_header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.widget_header h3 {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 0;
    display: flex;
    align-items: center;
}

.widget_header h3 i {
    margin-right: 8px;
    color: #7366ff;
}

/* ===================================
 * 할 일 목록 위젯
 * =================================== */

.todo_add_btn {
    background: #7366ff;
    color: #fff;
    border: none;
    padding: 6px 8px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.3s ease;
}

.todo_add_btn:hover {
    background: #5a52d5;
    transform: scale(1.05);
}

.todo_list {
    max-height: 600px;
    overflow-y: auto;
    margin-bottom: 15px;
}

.todo_list::-webkit-scrollbar {
    width: 4px;
}

.todo_list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.todo_list::-webkit-scrollbar-thumb {
    background: rgba(115, 102, 255, 0.3);
    border-radius: 4px;
}

.todo_item {
    display: flex;
    align-items: center;
    padding: 12px ;
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.3s ease;
}

.todo_item:last-child {
    border-bottom: none;
}

.todo_item.completed {
    opacity: 0.6;
}

.todo_item.overdue {
    background: rgba(220, 53, 69, 0.05);
    border-radius: 5px;
    padding: 12px 8px;
}

.todo_check {
    margin-right: 12px;
}

.todo_checkbox {
    cursor: pointer;
    transform: scale(1.2);
}

.todo_content {
    flex: 1;
}

.todo_text {
    font-size: 14px;
    color: #333;
    margin-bottom: 4px;
    line-height: 1.3;
}

.todo_item.completed .todo_text {
    text-decoration: line-through;
    color: #999;
}

.todo_meta {
    display: flex;
    align-items: center;
    gap: 8px;
}

.todo_priority {
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 10px;
    font-weight: 500;
}

.todo_priority.priority_high {
    background: #ffe6e6;
    color: #d32f2f;
}

.todo_priority.priority_medium {
    background: #fff3e0;
    color: #f57c00;
}

.todo_priority.priority_low {
    background: #e8f5e8;
    color: #388e3c;
}

.todo_date {
    font-size: 11px;
    color: #666;
}

.todo_delete {
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    padding: 4px;
    border-radius: 3px;
    transition: all 0.3s ease;
    opacity: 0;
}

.todo_item:hover .todo_delete {
    opacity: 1;
}

.todo_delete:hover {
    color: #dc3545;
    background: rgba(220, 53, 69, 0.1);
}

.todo_progress {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #eee;
}

.progress_bar {
    width: 100%;
    height: 8px;
    background: #f0f0f0;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 5px;
}

.progress_fill {
    height: 100%;
    background: linear-gradient(90deg, #7366ff, #5db2f3);
    transition: width 0.3s ease;
    border-radius: 4px;
}

.progress_text {
    font-size: 12px;
    color: #666;
    text-align: center;
    display: block;
}

/* ===================================
 * 즐겨찾기 위젯
 * =================================== */

.favorites_manage_btn {
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    padding: 4px;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.favorites_manage_btn:hover {
    color: #7366ff;
    background: rgba(115, 102, 255, 0.1);
}

.favorites_list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.favorite_item {
    display: flex;
    align-items: center;
    padding: 12px;
    border-radius: 6px;
    text-decoration: none;
    color: #333;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.favorite_item:hover {
    background: #f8f9fa;
    border-color: rgba(115, 102, 255, 0.2);
    text-decoration: none;
    color: #333;
}

.favorite_icon {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    font-size: 14px;
    color: #fff;
}

.favorite_info {
    flex: 1;
}

.favorite_title {
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 2px;
    color: #333;
}

.favorite_desc {
    font-size: 11px;
    color: #666;
}

.favorite_count {
    font-size: 12px;
    font-weight: 600;
    color: #7366ff;
    background: rgba(115, 102, 255, 0.1);
    padding: 2px 6px;
    border-radius: 3px;
}

/* ===================================
 * 최근 파일 위젯
 * =================================== */

.view_all_link {
    font-size: 12px;
    color: #7366ff;
    text-decoration: none;
    transition: all 0.3s ease;
}

.view_all_link:hover {
    color: #5a52d5;
    text-decoration: underline;
}

.recent_files_list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.recent_file_item {
    display: flex;
    align-items: center;
    padding: 10px;
    border-radius: 6px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.recent_file_item:hover {
    background: #f8f9fa;
    border-color: rgba(115, 102, 255, 0.1);
}

.recent_file_item:hover .download_icon {
    opacity: 1;
    transform: scale(1);
}

.download_icon {
    margin-left: auto;
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.3s ease;
    color: #7366ff;
    font-size: 16px;
    padding: 5px;
}

.file_icon {
    width: 32px;
    height: 32px;
    background: rgba(115, 102, 255, 0.1);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    color: #7366ff;
    font-size: 14px;
}

.file_info {
    flex: 1;
    overflow: hidden;
    margin-right: 10px;
}

.file_name {
    font-size: 13px;
    font-weight: 500;
    color: #333;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file_meta {
    display: flex;
    align-items: center;
    gap: 8px;
}

.file_date,
.file_size {
    font-size: 11px;
    color: #666;
}

/* ===================================
 * 기존 메인 섹션들 (수정된 레이아웃)
 * =================================== */

.main_section_01 { 
    width: 100%; 
    display: inline-block; 
    margin-bottom: 24px;
}

.main_section_01 .ms01_content { 
    width: 100%; 
    display: flex; 
}

.main_section_01 .ms01_content .ms_menu { 
    width: 100%; 
    display: flex; 
    flex-wrap: wrap; 
}

.main_section_01 .ms01_content .ms_menu .mnb { 
    width: calc(100% / 5 - 20px); 
    margin-bottom: 24px; 
    margin-right: 24px; 
    align-items: center; 
    box-shadow: 1px 2px 21px -2px rgb(214 214 227 / 80%); 
    display: flex; 
    background: #fff; 
    padding: 20px; 
    border-radius: 8px; 
    transition: all 0.3s ease;
}

.main_section_01 .ms01_content .ms_menu .mnb:hover {
    transform: translateY(-3px);
    box-shadow: 1px 8px 25px -2px rgb(214 214 227 / 90%);
}

.main_section_01 .ms01_content .ms_menu .mnb:nth-child(5n) { 
    margin-right: 0; 
}

.main_section_01 .ms01_content .ms_menu .mnb span { 
    box-shadow: 1px 2px 21px -2px rgb(214 214 227 / 80%); 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    min-width: 50px; 
    min-height: 50px; 
    background: #fff; 
    color: #ff1e1e; 
    border: 1px solid #ff1e1e; 
    border-bottom: 2px solid #ff1e1e; 
    border-left: 2px solid #ff1e1e; 
    border-radius: 100%; 
}

.main_section_01 .ms01_content .ms_menu .mnb span.bg_purple { 
    color: #7366ff; 
    border: 1px solid #7366ff; 
    border-bottom: 2px solid #7366ff; 
    border-left: 2px solid #7366ff; 
}

.main_section_01 .ms01_content .ms_menu .mnb span.bg_orange { 
    color: #FFAA05; 
    border: 1px solid #FFAA05; 
    border-bottom: 2px solid #FFAA05; 
    border-left: 2px solid #FFAA05; 
}

.main_section_01 .ms01_content .ms_menu .mnb span.bg_green { 
    color: #54BA4A; 
    border: 1px solid #54BA4A; 
    border-bottom: 2px solid #54BA4A; 
    border-left: 2px solid #54BA4A; 
}

.main_section_01 .ms01_content .ms_menu .mnb span.bg_mint { 
    color: #4abaab; 
    border: 1px solid #4abaab; 
    border-bottom: 2px solid #4abaab; 
    border-left: 2px solid #4abaab; 
}

.main_section_01 .ms01_content .ms_menu .mnb span.bg_dpurple { 
    color: #c000ff; 
    border: 1px solid #c000ff; 
    border-bottom: 2px solid #c000ff; 
    border-right: 2px solid #c000ff; 
}

.main_section_01 .ms01_content .ms_menu .mnb span.bg_blue { 
    color: #00a9ff; 
    border: 1px solid #00a9ff; 
    border-bottom: 2px solid #00a9ff; 
    border-right: 2px solid #00a9ff; 
}

.main_section_01 .ms01_content .ms_menu .mnb span.bg_dmint { 
    color: #0c00ff; 
    border: 1px solid #0c00ff; 
    border-bottom: 2px solid #0c00ff; 
    border-right: 2px solid #0c00ff; 
}

.main_section_01 .ms01_content .ms_menu .mnb span.bg_pink { 
    color: #e668db; 
    border: 1px solid #e668db; 
    border-bottom: 2px solid #e668db; 
    border-right: 2px solid #e668db; 
}

.main_section_01 .ms01_content .ms_menu .mnb span.bg_gray { 
    color: #999; 
    border: 1px solid #999; 
    border-bottom: 2px solid #999; 
    border-right: 2px solid #999; 
}

.main_section_01 .ms01_content .ms_menu .mnb span > i { 
    font-size: 24px; 
}

.main_section_01 .ms01_content .ms_menu .mnb:hover span > i { 
    animation: tada 1.5s ease infinite; 
}

.main_section_01 .ms01_content .ms_menu .mnb p { 
    margin-left: 10px; 
    display: flex; 
    flex-wrap: wrap; 
    font-size: 16px; 
    font-weight: 400; 
    color: #555; 
    letter-spacing: -1px; 
}

.main_section_01 .ms01_content .ms_menu .mnb p b { 
    width: 100%; 
    font-weight: 600; 
    font-size: 24px; 
    color: #000; 
}

#phantom_main_chart_01 { 
    width: 100%; 
    position: relative; 
    height: 100vh; 
    max-height: 300px; 
    overflow: hidden; 
}

.main_section_02 { 
    display: flex; 
    width: 100%; 
    position: relative; 
    background: #fff; 
    border-radius: 8px; 
    padding: 24px; 
    box-shadow: 1px 2px 21px -2px rgb(214 214 227 / 80%); 
    transition: all 0.3s ease;
    min-height: 420px;
    align-items: stretch;
}

.main_section_02:hover {
    transform: translateY(-2px);
    box-shadow: 1px 8px 25px -2px rgb(214 214 227 / 90%);
}

.main_section_02 .ms02_content { 
    width: 100%; 
    display: flex; 
    max-width: 280px; 
    margin-left: 24px; 
    flex-wrap: wrap; 
    align-items: center; 
    justify-content: flex-start; 
    align-content: flex-start; 
    flex-shrink: 0; 
}

.main_section_02 .ms02_content .graph_sum_box { 
    width: 100%; 
    margin-bottom: 10px; 
    display: flex; 
    padding: 12px 20px; 
    background: #f9f9f9; 
    border-radius: 8px; 
    transition: all 0.3s ease;
}

.main_section_02 .ms02_content .graph_sum_box:hover {
    background: #f0f0f0;
    transform: scale(1.02);
}

.main_section_02 .ms02_content .graph_sum_box .gs_box { 
    box-shadow: 1px 2px 21px -2px rgb(214 214 227 / 80%); 
    font-weight: 300; 
    font-size: 20px; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    min-width: 48px; 
    min-height: 48px; 
    background: #fff; 
    color: #333; 
    border-radius: 20%; 
}

.main_section_02 .ms02_content .graph_sum_box p { 
    margin-left: 12px; 
    font-size: 14px; 
    color: #777; 
    display: flex; 
    flex-wrap: wrap; 
    letter-spacing: -0.5px; 
}

.main_section_02 .ms02_content .graph_sum_box p b { 
    width: 100%; 
    font-size: 16px; 
    color: #222; 
    font-weight: 500;
}

.main_section_04 { 
    display: flex; 
    margin-top: 24px; 
    flex-wrap: wrap; 
    align-content: flex-start; 
    width: 100%;  
}

.main_section_04 .phantom_latest { 
    width: calc(100% / 3 - 16px); 
    border-radius: 8px; 
    margin-right: 24px;
    background: #fff; 
    box-shadow: 1px 2px 21px -2px rgb(214 214 227 / 80%); 
    transition: all 0.3s ease;
}

.main_section_04 .phantom_latest:hover {
    transform: translateY(-2px);
    box-shadow: 1px 8px 25px -2px rgb(214 214 227 / 90%);
}

.main_section_04 .phantom_latest > h1 { 
    font-size: 20px; 
    padding: 24px; 
    letter-spacing: -1px; 
    line-height: 1em; 
    width: 100%; 
    font-weight: 600; 
}

.main_section_04 .phantom_latest:nth-child(3) { 
    margin-right: 0; 
}

.main_section_04 .phantom_latest ul.download { 
    width: 100%; 
    display: flex; 
    flex-wrap: wrap; 
    max-height: 670px; 
    overflow-x: hidden; 
    overflow-y: scroll; 
}

.main_section_04 .phantom_latest ul.download::-webkit-scrollbar-thumb { 
    width: 5px; 
    border-radius: 8px; 
    background: rgba(115, 102, 255, 0.2);
}

.main_section_04 .phantom_latest ul.download::-webkit-scrollbar-track { 
    width: 5px; 
    border-radius: 8px; 
    background: white; 
}

.main_section_04 .phantom_latest ul.download::-webkit-scrollbar { 
    width: 5px; 
    border-radius: 8px; 
    background: white; 
}

.main_section_04 .phantom_latest ul.download > a { 
    width: 100%; 
    border-top: 1px solid #e1e1e1; 
    padding: 24px; 
    display: flex; 
    flex-wrap: wrap; 
    transition: 0.3s ease all; 
}

.main_section_04 .phantom_latest ul.download > a:hover { 
    background: #f2f3f8; 
    transition: 0.3s ease all; 
}

.main_section_04 .phantom_latest ul.download > a > li { 
    width: 100%; 
}

.main_section_04 .phantom_latest ul.download > a > li > p.title { 
    display: flex; 
    width: 100%; 
    align-items: center; 
    justify-content: space-between; 
}

.main_section_04 .phantom_latest ul.download > a > li > p.title b { 
    background: rgba(220, 220, 220, 0.45); 
    color: #666; 
    font-weight: 400; 
    padding: 4px 8px; 
    border-radius: 4px; 
}

.main_section_04 .phantom_latest ul.download > a > li > h1 { 
    width: 100%; 
    overflow: hidden; 
    text-overflow: ellipsis; 
    white-space: nowrap; 
    font-size: 16px; 
    color: #222; 
    letter-spacing: -1px; 
    margin: 8px 0; 
}

.main_section_04 .phantom_latest ul.download > a > li > p.content { 
    width: 100%; 
    overflow: hidden; 
    text-overflow: ellipsis; 
    white-space: nowrap; 
    font-size: 13px; 
    color: #888; 
    letter-spacing: -0.5px; 
}

.main_section_04 .phantom_latest ul.download img { 
    max-width: 100%; 
    height: auto; 
}

.main_section_04 .phantom_latest ul.maintenance { 
    width: 100%; 
    display: flex; 
    flex-wrap: wrap; 
    max-height: 670px; 
    overflow-x: hidden; 
    overflow-y: scroll; 
}

.main_section_04 .phantom_latest ul.maintenance::-webkit-scrollbar-thumb { 
    width: 5px; 
    border-radius: 8px; 
    background: rgba(115, 102, 255, 0.2);
}

.main_section_04 .phantom_latest ul.maintenance::-webkit-scrollbar-track { 
    width: 5px; 
    border-radius: 8px; 
    background: white; 
}

.main_section_04 .phantom_latest ul.maintenance::-webkit-scrollbar { 
    width: 5px; 
    border-radius: 8px; 
    background: white; 
}

.main_section_04 .phantom_latest ul.maintenance > a { 
    width: 100%; 
    border-top: 1px solid #e1e1e1; 
    padding: 23px; 
    display: flex; 
    flex-wrap: wrap; 
    transition: 0.3s ease all; 
}

.main_section_04 .phantom_latest ul.maintenance > a:hover { 
    background: #fafafa; 
    transition: 0.3s ease all; 
}

.main_section_04 .phantom_latest ul.maintenance > a > li { 
    width: 100%; 
}

.main_section_04 .phantom_latest ul.maintenance > a > li > p.title { 
    display: flex; 
    width: 100%; 
    align-items: center; 
    justify-content: flex-start; 
}

.main_section_04 .phantom_latest ul.maintenance > a > li > p.title b { 
    background: #7366ff; 
    margin-right: 4px; 
    color: #fff; 
    font-weight: 400; 
    padding: 4px 8px; 
    border-radius: 4px; 
}

.main_section_04 .phantom_latest ul.maintenance > a > li > p.title b:nth-last-child(1) { 
    margin-right: 0; 
}

.main_section_04 .phantom_latest ul.maintenance > a > li > p.title b.category {
    background: rgba(115, 102, 255, 0.08); 
    color: #7366FF; 
}

.main_section_04 .phantom_latest ul.maintenance > a > li > p.title b.day {
    background: #FFAA05; 
    color: #fff; 
}

.main_section_04 .phantom_latest ul.maintenance > a > li > p.content { 
    width: 100%; 
    overflow: hidden; 
    text-overflow: ellipsis; 
    white-space: nowrap; 
    font-size: 13px; 
    color: #888; 
    margin-top: 4px; 
    letter-spacing: -0.5px; 
}

/* ===================================
 * 기존 스와이퍼 스타일 (유지)
 * =================================== */

.swiper { 
    width: 100%; 
    height: 100%; 
    text-align: left; 
}

.swiper-slide {
    text-align: left; 
    background: #fff; 
    display: -webkit-box;
    display: -ms-flexbox;
    display: -webkit-flex;
    display: flex; 
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    -webkit-justify-content: flex-start; 
    justify-content: flex-start;
    -webkit-box-align: center;
    -ms-flex-align: center; 
    -webkit-align-items: center; 
    align-items: center; 
}

/* ===================================
 * 알림 토스트 시스템
 * =================================== */

.toast {
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    padding: 15px 20px;
    margin-bottom: 10px;
    border-left: 4px solid #7366ff;
    animation: slideInRight 0.3s ease;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
    min-width: 300px;
    max-width: 400px;
}

.toast.show {
    opacity: 1;
    transform: translateX(0);
}

.toast.success {
    border-left-color: #28a745;
}

.toast.error {
    border-left-color: #dc3545;
}

.toast.warning {
    border-left-color: #ffc107;
}

.toast.info {
    border-left-color: #17a2b8;
}

.toast-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px;
}

.toast-title {
    font-weight: 600;
    font-size: 14px;
    color: #333;
}

.toast-close {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: #999;
    padding: 0;
    margin-left: 10px;
    transition: color 0.3s ease;
}

.toast-close:hover {
    color: #666;
}

.toast-body {
    font-size: 13px;
    color: #666;
    line-height: 1.4;
}

/* ===================================
 * 로딩 오버레이
 * =================================== */

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #7366ff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

/* ===================================
 * 버튼 스타일 개선
 * =================================== */

.btn {
    padding: 8px 16px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 13px;
	line-height:1em;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    font-family: inherit;
}

.btn_submit {
    background: #7366ff;
    color: white;
}

.btn_submit:hover {
    background: #5a52d5;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(115, 102, 255, 0.3);
}

.btn_cancel {
    background: #6c757d;
    color: white;
}

.btn_cancel:hover {
    background: #545b62;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(108, 117, 125, 0.3);
}

/* ===================================
 * 상단 이동 버튼 개선
 * =================================== */

.tap-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: #7366ff;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(115, 102, 255, 0.3);
    transition: all 0.3s ease;
    z-index: 1000;
    border: none;
}

.tap-top:hover {
    background: #5a52d5;
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(115, 102, 255, 0.4);
}

/* ===================================
 * 애니메이션 키프레임
 * =================================== */

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes tada {
    0% { transform: scale(1); }
    10%, 20% { transform: scale(0.9) rotate(-3deg); }
    30%, 50%, 70%, 90% { transform: scale(1.1) rotate(3deg); }
    40%, 60%, 80% { transform: scale(1.1) rotate(-3deg); }
    100% { transform: scale(1) rotate(0); }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* ===================================
 * 반응형 스타일 (완전 개선)
 * =================================== */

@media (max-width: 1400px) {
    .top_section {
        flex-direction: column;
        gap: 20px;
    }
    
    .top_section .summary_cards {
        flex-direction: row;
        max-width: none;
        gap: 15px;
    }
    
    .bottom_widgets {
        gap: 20px;
    }
    
    .main_section_01 .ms01_content .ms_menu .mnb {
        width: calc(100% / 4 - 20px);
    }
    
    .main_section_01 .ms01_content .ms_menu .mnb:nth-child(4n) {
        margin-right: 0;
    }
    
    .main_section_01 .ms01_content .ms_menu .mnb:nth-child(5n) {
        margin-right: 24px;
    }
}

@media (max-width: 1200px) {
    .bottom_widgets {
        flex-direction: column;
        gap: 16px;
    }
    
    .quick_grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
}

@media (max-width: 968px) {
    .main_section_01 .ms01_content .ms_menu .mnb {
        width: calc(100% / 3 - 16px);
        margin-right: 16px;
    }
    
    .main_section_01 .ms01_content .ms_menu .mnb:nth-child(3n) {
        margin-right: 0;
    }
    
    .main_section_01 .ms01_content .ms_menu .mnb:nth-child(4n),
    .main_section_01 .ms01_content .ms_menu .mnb:nth-child(5n) {
        margin-right: 16px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        width: 285px;
    }
    
    .sidebar.mobile-open {
        transform: translateX(0);
    }
    
    #phantom_header {
        left: 0;
        width: 100%;
        padding-left: 30px;
        gap: 10px;
    }
    
    #phantom_content {
        margin-left: 0;
        width: 100%;
    }
    
    .global-search {
        max-width: 200px;
    }
    
    .search-input:focus {
        width: 100%;
    }
    
    .weather-widget {
        display: none;
    }
    
    #phantom_header .phantom_news {
        min-width: 200px;
        flex: 1;
    }
    
    .quick_grid {
        grid-template-columns: 1fr;
    }
    
    .summary_cards {
        flex-direction: column;
        gap: 12px;
    }
    
    .summary_card {
        padding: 12px;
    }
    
    .main_section_01 .ms01_content .ms_menu .mnb {
        width: calc(100% / 2 - 12px);
        margin-right: 12px;
    }
    
    .main_section_01 .ms01_content .ms_menu .mnb:nth-child(2n) {
        margin-right: 0;
    }
    
    .main_section_01 .ms01_content .ms_menu .mnb:nth-child(3n),
    .main_section_01 .ms01_content .ms_menu .mnb:nth-child(4n),
    .main_section_01 .ms01_content .ms_menu .mnb:nth-child(5n) {
        margin-right: 12px;
    }
    
    .main_section_04 .phantom_latest {
        width: 100%;
        margin-right: 0;
        margin-bottom: 24px;
    }
    
    .tap-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
    
    #toastContainer {
        right: 10px;
        left: 10px;
        top: 80px;
    }
}

@media (max-width: 480px) {
    #phantom_content .content_wrap {
        padding: 15px;
    }
    
    .phantom_quick_access,
    .todo_widget,
    .favorites_widget,
    .recent_files_widget,
    .main_section_02,
    .summary_cards {
        padding: 15px;
    }
    
    .main_section_01 .ms01_content .ms_menu .mnb {
        width: 100%;
        margin-right: 0;
        margin-bottom: 15px;
    }
    
    .main_section_01 .ms01_content .ms_menu .mnb:nth-child(2n) {
        margin-right: 0;
    }
    
    #phantom_header {
        gap: 5px;
        padding: 10px 15px;
        padding-left: 15px;
    }
    
    .global-search {
        max-width: 150px;
    }
    
    #phantom_header .phantom_news {
        min-width: 150px;
    }
    
    #phantom_header .clock {
        font-size: 12px;
    }
    
    .sidebar .logo {
        padding: 15px 20px;
    }
    
    .sidebar .general h1,
    .sidebar .general h2 {
        padding: 20px 15px 8px;
    }
    
    .sidebar .general li.sb_one span {
        padding: 10px 15px;
    }
    
    .quick-memo {
        left: 15px;
        right: 15px;
        bottom: 15px;
    }
}