/* FullCalendar 기본 스타일 사용 - 최소한의 커스터마이징만 */
#calendar {
    margin: 0;
    padding-top: 20px;
    height: auto;
    overflow: visible;
}

/* 달력 일자 셀 높이 통일 */
.fc-daygrid-day-frame {
    height: 150px !important;
    min-height: 150px !important;
}

.fc-daygrid-day {
    height: 150px !important;
    min-height: 150px !important;
}

/* 일자 번호 영역 */
.fc-daygrid-day-top {
    height: 30px !important;
    min-height: 30px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    padding: 4px 8px !important;
}

/* 일자 번호 스타일 */
.fc-daygrid-day-number {
    font-size: 14px !important;
    font-weight: 500 !important;
    color: #333 !important;
    text-decoration: none !important;
}

/* 이벤트 영역 */
.fc-daygrid-day-events {
    height: 120px !important;
    min-height: 120px !important;
    max-height: 120px !important;
    overflow: hidden !important;
    padding: 2px 4px !important;
}

/* 이벤트 컨테이너 */
.fc-daygrid-day-events .fc-daygrid-day-events {
    height: 100% !important;
    min-height: 100% !important;
    max-height: 100% !important;
}

/* 배경 영역 */
.fc-daygrid-day-bg {
    height: 100% !important;
    min-height: 100% !important;
}

/* 요일 헤더 높이 조정 */
.fc-col-header {
    height: auto !important;
}

.fc-col-header-cell {
    height: 40px !important;
    min-height: 40px !important;
    max-height: 40px !important;
    padding: 0 !important;
    border-bottom: 2px solid #dee2e6 !important;
    background-color: #f8f9fa !important;
    vertical-align: middle !important;
    text-align: center !important;
    position: relative !important;
}

.fc-col-header-cell .fc-scrollgrid-sync-inner {
    height: 40px !important;
    min-height: 40px !important;
    max-height: 40px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
}

.fc-col-header-cell-cushion {
    font-size: 14px !important;
    font-weight: 600 !important;
    color: #333 !important;
    text-decoration: none !important;
    padding: 0 !important;
    margin: 0 !important;
    line-height: 1 !important;
    display: block !important;
    width: 100% !important;
    text-align: center !important;
}

/* 스크롤러 하네스 높이 조정 */
.fc-scroller-harness {
    height: auto !important;
}

.fc-scroller {
    height: auto !important;
}

/* 요일 헤더 테이블 전체 높이 조정 */
.fc-col-header table {
    height: auto !important;
    min-height: auto !important;
    max-height: none !important;
}

.fc-col-header thead {
    height: auto !important;
    min-height: auto !important;
    max-height: none !important;
}

.fc-col-header tr {
    height: auto !important;
    min-height: auto !important;
    max-height: none !important;
}

/* 요일 헤더 셀 내부 요소들 높이 조정 */
.fc-col-header-cell .fc-scrollgrid-sync-inner {
    height: 40px !important;
    min-height: 40px !important;
    max-height: 40px !important;
    padding: 0 !important;
    margin: 0 !important;
    text-align: center !important;
}

/* 요일 헤더 전체 컨테이너 높이 조정 */
.fc-scrollgrid-section-header {
    height: auto !important;
    min-height: auto !important;
    max-height: none !important;
}

/* 요일 헤더 스크롤러 하네스 강제 높이 조정 */
.fc-scrollgrid-section-header .fc-scroller-harness {
    height: 40px !important;
    min-height: 40px !important;
    max-height: 40px !important;
}

.fc-scrollgrid-section-header .fc-scroller {
    height: 40px !important;
    min-height: 40px !important;
    max-height: 40px !important;
}

/* prev, next 버튼 화살표 아이콘 명시적 표시 */
.fc-prev-button .fc-icon-chevron-left::before {
    content: "‹";
    font-size: 20px;
    font-weight: bold;
    color: white;
}

.fc-next-button .fc-icon-chevron-right::before {
    content: "›";
    font-size: 20px;
    font-weight: bold;
    color: white;
}

/* prev, next, today 버튼 높이와 정렬 조정 */
.fc-prev-button, .fc-next-button, .fc-today-button {
    height: 38px !important;
    padding: 8px 16px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.fc-prev-button, .fc-next-button {
    width: 38px !important;
    padding: 0 !important;
}

.fc-prev-button .fc-icon, .fc-next-button .fc-icon {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    height: 100% !important;
}

/* 전체 툴바 레이아웃 수정 */
.fc-toolbar {
    margin: 0 !important;
    padding: 10px 0 !important;
}

/* 왼쪽 툴바 가로 정렬 유지 */
.fc-toolbar-chunk:first-child {
    text-align: left !important;
}

/* 오른쪽 툴바 가로 정렬 유지 */
.fc-toolbar-chunk:last-child {
    text-align: right !important;
}

/* 중앙 툴바 */
.fc-toolbar-chunk:nth-child(2) {
    text-align: center !important;
}

/* 툴바 제목 스타일 통일 */
.fc-toolbar-title {
    font-size: 24px !important;
    font-weight: 600 !important;
    color: #333 !important;
    font-family: inherit !important;
}

/* 일정등록 커스텀 버튼 스타일 */
.fc-addSchedule-button {
    background-color: #28a745 !important;
    border-color: #28a745 !important;
    color: white !important;
}

.fc-addSchedule-button:hover {
    background-color: #218838 !important;
    border-color: #218838 !important;
}

/* FullCalendar 버튼 스타일 약간 수정 */
#calendar .fc-toolbar .fc-button,
#custom-list-view .fc-toolbar .fc-button {
    background-color: #1d388d !important;
    border-color: #1d388d !important;
    color: white !important;
    font-weight: 500 !important;
    font-size: 14px !important;
    padding: 8px 16px !important;
    border-radius: 4px !important;
    transition: all 0.3s ease !important;
    font-family: inherit !important;
    line-height: 1.2 !important;
}

/* 버튼 간격 통일 */
.fc-dayGridMonth-button {
    margin-right: 8px !important;
}

.fc-customList-button {
    margin-right: 8px !important;
}

.fc-addSchedule-button {
    margin-right: 0 !important;
}

/* prev, next, today 버튼 간격 통일 */
.fc-prev-button {
    margin-right: 5px !important;
}

.fc-next-button {
    margin-right: 5px !important;
}

.fc-today-button {
    margin-right: 0 !important;
}

/* 목록 뷰에서도 동일한 간격 적용 */
#custom-list-view .fc-prev-button {
    margin-right: 5px !important;
    margin-left: 0 !important;
}

#custom-list-view .fc-next-button {
    margin-right: 5px !important;
    margin-left: 0.75em !important;
}

#custom-list-view .fc-today-button {
    margin-right: 0 !important;
    margin-left: 0.75em !important;
}

/* 목록 뷰의 툴바 청크 내부 버튼 간격 강제 적용 */
#custom-list-view .fc-toolbar-chunk:first-child .fc-prev-button {
    margin-right: 5px !important;
    margin-left: 0 !important;
}

#custom-list-view .fc-toolbar-chunk:first-child .fc-next-button {
    margin-right: 5px !important;
    margin-left: 0.75em !important;
}

#custom-list-view .fc-toolbar-chunk:first-child .fc-today-button {
    margin-right: 0 !important;
    margin-left: 0.75em !important;
}

/* FullCalendar 기본 스타일과 동일하게 적용 */
#custom-list-view .fc-toolbar-chunk:first-child > *:not(:first-child) {
    margin-left: 0.75em !important;
}

#calendar .fc-toolbar .fc-button:hover,
#custom-list-view .fc-toolbar .fc-button:hover {
    background-color: #0056b3 !important;
    border-color: #0056b3 !important;
    transform: translateY(-1px) !important;
}

#calendar .fc-toolbar .fc-button:focus,
#custom-list-view .fc-toolbar .fc-button:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25) !important;
}

#calendar .fc-toolbar .fc-button.fc-button-active,
#custom-list-view .fc-toolbar .fc-button.fc-button-active {
    background-color: #0056b3 !important;
    border-color: #0056b3 !important;
}

/* 이벤트 스타일 약간 수정 */
.fc-event {
    border-radius: 4px !important;
    border: none !important;
    padding: 4px 8px !important;
    margin: 1px 0 !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1) !important;
}

.fc-event:hover {
    transform: translateY(-1px) !important;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15) !important;
}

/* 연속 일정의 중복 표시 제어 */
.fc-daygrid-event-dot {
    display: none !important;
}

/* 연속 일정의 시각적 연결 개선 */
.fc-daygrid-day-events .fc-event {
    border-radius: 0 !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    min-height: 20px !important;
    width: 100% !important;
    max-width: calc(100% - 8px) !important;
    overflow: hidden !important;
}

.fc-daygrid-day-events .fc-event:first-child {
    border-top-left-radius: 4px !important;
    border-bottom-left-radius: 4px !important;
}

.fc-daygrid-day-events .fc-event:last-child {
    border-top-right-radius: 4px !important;
    border-bottom-right-radius: 4px !important;
}

/* 연속 일정에서 중복된 이벤트의 제목만 숨김 (이벤트 자체는 표시) */
.fc-daygrid-day-events .fc-event:not(:first-child) .fc-event-title {
    display: none !important;
}

/* 연속 일정의 경우 첫 번째 셀에만 제목 표시 */
.fc-daygrid-day-events .fc-event:first-child .fc-event-title {
    display: block !important;
}

/* FullCalendar 이벤트 제목 텍스트 오버플로우 처리 */
.fc-event-title {
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    max-width: 100% !important;
    display: block !important;
    word-break: keep-all !important;
    word-wrap: normal !important;
}

/* FullCalendar 이벤트 내부 컨테이너 */
.fc-event-main {
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    max-width: 100% !important;
}

/* FullCalendar 이벤트 컨테이너 전체 오버플로우 제어 */
.fc-daygrid-day-events {
    overflow: visible !important;
    max-width: 100% !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    min-height: 20px !important;
}

/* 연속 일정이 제대로 표시되도록 추가 보장 */
.fc-daygrid-day-events .fc-event {
    position: relative !important;
    z-index: 1 !important;
}

/* FullCalendar 이벤트 내부 모든 요소 오버플로우 제어 */
.fc-event-main-frame {
    overflow: hidden !important;
    max-width: 100% !important;
}

/* fc-daygrid-day-bg 영역에서 제목 말줄임표 처리 */
.fc-daygrid-day-bg .fc-event-title {
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    max-width: 100% !important;
    display: block !important;
    word-break: keep-all !important;
    word-wrap: normal !important;
}

/* fc-daygrid-day-bg 영역의 이벤트 컨테이너 */
.fc-daygrid-day-bg .fc-event {
    max-width: 100% !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

/* fc-daygrid-day-bg 영역의 이벤트 내부 */
.fc-daygrid-day-bg .fc-event-main {
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    max-width: 100% !important;
}

/* 커스텀 목록 뷰 테이블 스타일 */
#custom-list-view {
    margin: 0;
    padding-top: 10px;
    height: auto;
    overflow: visible;
}

/* 목록 뷰에서 복제된 툴바 스타일 */
#custom-list-view .fc-toolbar {
    margin-bottom: 20px;
    margin-top: 0;
    padding: 10px 0;
    border-bottom: 1px solid #e0e0e0;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
}

/* 목록 뷰에서 복제된 툴바의 제목 글씨 크기 키우기 */
#custom-list-view .fc-toolbar-title {
    font-size: 24px !important;
    font-weight: 600 !important;
    color: #333 !important;
    font-family: inherit !important;
}

#custom-list-view .fc-toolbar-chunk:first-child {
    display: flex !important;
    align-items: center !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    gap: 5px !important;
}

#custom-list-view .fc-toolbar-chunk:last-child {
    display: flex !important;
    align-items: center !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
}

#custom-list-view .fc-toolbar-chunk:nth-child(2) {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.list-header {
    margin-bottom: 20px;
}

.list-header h3 {
    color: #333;
    font-size: 18px;
    font-weight: 600;
    margin: 0;
}

.events-table {
    width: 100%;
    border-collapse: collapse;
    background-color: #fff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    border-radius: 4px;
    overflow: visible;
    table-layout: fixed;
}

.events-table th {
    background-color: #f8f9fa;
    color: #333;
    font-weight: 600;
    padding: 10px 8px;
    text-align: center;
    border-bottom: 2px solid #dee2e6;
    font-size: 14px;
}

.events-table td {
    padding: 10px 8px;
    border-bottom: 1px solid #dee2e6;
    font-size: 14px;
    vertical-align: middle;
}

.events-table tbody tr {
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.events-table tbody tr:hover {
    background-color: #f8f9fa;
}

/* 반응형: 표는 고정 레이아웃, 가로 스크롤은 컨테이너에 위임 */
.table-container {
    width: 100%;
    overflow-x: auto;
}

/* 기존 tbody block 스크롤 제거 (thead/th와 td 폭 불일치 방지) */
.events-table tbody {
    display: table-row-group !important;
    overflow: visible !important;
}

.events-table thead {
    display: table-header-group !important;
}

.events-table tbody tr {
    display: table-row !important;
}

/* 컬럼 폭 고정 - thead th / tbody td 동기화 (colgroup과 함께 사용) */
.col-no { width: 80px; }
.col-occs-status { width: 90px; }
.col-apply-status { width: 90px; }
.col-title { width: 420px; }
.col-occs-date { width: 190px; }
.col-apply-date { width: 190px; }
.col-org { width: 140px; }
.col-reg { width: 120px; }

/* 날짜/주관/등록일 가운데 정렬 */
#events-table thead th:nth-child(5),
#events-table thead th:nth-child(6),
#events-table thead th:nth-child(7),
#events-table thead th:nth-child(8),
#events-table tbody td:nth-child(5),
#events-table tbody td:nth-child(6),
#events-table tbody td:nth-child(7),
#events-table tbody td:nth-child(8) {
    text-align: center !important;
}

@media (max-width: 1200px) {
    .col-title { width: 360px; }
    .col-occs-date, .col-apply-date { width: 160px; }
    .col-org { width: 120px; }
}

@media (max-width: 992px) {
    .col-title { width: 300px; }
    .col-occs-status, .col-apply-status { width: 90px; }
    .col-occs-date, .col-apply-date { width: 140px; }
}

@media (max-width: 768px) {
    .col-title { width: 260px; }
    .col-no { width: 64px; }
    .col-occs-status, .col-apply-status { width: 90px; }
}

/* 모바일/태블릿: 목록(커스텀 리스트)에서는 제목/행사상태/신청상태만 노출 */
@media (max-width: 992px) {
    /* 992px 이하에서 숨김: 번호(1), 주관(7), 등록일(8) */
    #custom-list-view col.col-no,
    #custom-list-view col.col-org,
    #custom-list-view col.col-reg,
    #custom-list-view th:nth-child(1),
    #custom-list-view th:nth-child(7),
    #custom-list-view th:nth-child(8),
    #custom-list-view td:nth-child(1),
    #custom-list-view td:nth-child(7),
    #custom-list-view td:nth-child(8) {
        display: none !important;
    }

    /* 769px 이하에서만 추가 숨김: 행사상태(3), 모집상태(4), 모집기간(6) */
    @media (max-width: 769px) {
        /* 769px 이하에서 툴바 제목과 총 건수를 나란히 배치 */
        #custom-list-view .fc-toolbar {
            display: flex !important;
            flex-direction: row !important;
            align-items: center !important;
            justify-content: space-between !important;
            flex-wrap: wrap !important;
            gap: 10px !important;
            margin-bottom: 20px !important;
        }
        
        #custom-list-view .fc-toolbar-title {
            margin: 0 !important;
            font-size: 18px !important;
            font-weight: 600 !important;
            color: #333 !important;
            flex-shrink: 0 !important;
        }
        
        #custom-list-view .listTotal {
            margin: 0 !important;
            font-size: 16px !important;
            font-weight: 600 !important;
            color: #333 !important;
            flex-shrink: 0 !important;
        }
        
        #custom-list-view .listTotal::after {
            display: none !important;
        }
        
        #custom-list-view col.col-occs-status,
        #custom-list-view col.col-apply-status,
        #custom-list-view col.col-apply-date,
        #custom-list-view th:nth-child(3),
        #custom-list-view th:nth-child(4),
        #custom-list-view th:nth-child(6),
        #custom-list-view td:nth-child(3),
        #custom-list-view td:nth-child(4),
        #custom-list-view td:nth-child(6) {
            display: none !important;
        }
        
        /* 769px 이하에서 보이는 셀들: 제목(2번째), 행사일자(5번째) */
        #custom-list-view td:nth-child(2),
        #custom-list-view td:nth-child(5) {
            display: block !important;
            visibility: visible !important;
            opacity: 1 !important;
            height: auto !important;
            width: 100% !important;
            overflow: visible !important;
            position: static !important;
            left: auto !important;
            pointer-events: auto !important;
        }
        
        /* 769px 이하에서 테이블 헤더 완전 숨김 - 최고 우선순위 */
        #custom-list-view thead,
        #custom-list-view thead *,
        #custom-list-view thead tr,
        #custom-list-view thead th {
            display: none !important;
            visibility: hidden !important;
            opacity: 0 !important;
            height: 0 !important;
            width: 0 !important;
            overflow: hidden !important;
            position: absolute !important;
            left: -9999px !important;
        }
        
        /* 769px 이하에서 테이블 전체 스타일 초기화 */
        #custom-list-view table {
            border: none !important;
            background: none !important;
            border-collapse: separate !important;
            border-spacing: 0 !important;
            width: 100% !important;
            max-width: 100% !important;
        }
        
        /* 769px 이하에서 테이블을 카드 형태로 변경 - 강제 적용 */
        #custom-list-view tbody {
            display: block !important;
            width: 100% !important;
            max-width: 100% !important;
        }
        
        #custom-list-view tbody tr {
            display: block !important;
            background: white !important;
            border-top: 1px solid #e6e8ec !important;
            border-bottom: 1px solid #e6e8ec !important;
            border-radius: 0 !important;
            margin-bottom: 0 !important;
            padding: 5px !important;
            width: 100% !important;
            max-width: 100% !important;
            box-sizing: border-box !important;
            float: none !important;
            clear: both !important;
        }
        
        #custom-list-view tbody td {
            display: block !important;
            border: none !important;
            padding: 8px 0 !important;
            height: auto !important;
            text-align: left !important;
            background: none !important;
            width: 100% !important;
            max-width: 100% !important;
            box-sizing: border-box !important;
            float: none !important;
            clear: both !important;
        }
        
        /* 769px 이하에서 카드 내부 레이아웃 */
        #custom-list-view td:nth-child(2) {
            font-size: 16px !important;
            font-weight: 600 !important;
            color: #333 !important;
            padding: 16px 20px !important;
            padding-bottom: 12px !important;
            border-bottom: 1px solid #f0f2f5 !important;
            margin-bottom: 12px !important;
            width: 100% !important;
            max-width: none !important;
            box-sizing: border-box !important;
            white-space: nowrap !important;
            overflow: hidden !important;
            text-overflow: ellipsis !important;
            line-height: 1.4 !important;
        }
        
        #custom-list-view td:nth-child(5) {
            font-size: 14px !important;
            color: #666 !important;
            padding: 0 20px 16px 20px !important;
            text-align: left !important;
            width: 100% !important;
            box-sizing: border-box !important;
        }
        
        /* 769px 이하에서 숨겨진 셀들 - 강제 숨김 */
        #custom-list-view td:nth-child(1),
        #custom-list-view td:nth-child(3),
        #custom-list-view td:nth-child(4),
        #custom-list-view td:nth-child(6),
        #custom-list-view td:nth-child(7),
        #custom-list-view td:nth-child(8) {
            display: none !important;
            visibility: hidden !important;
            opacity: 0 !important;
            height: 0 !important;
            width: 0 !important;
            overflow: hidden !important;
            position: absolute !important;
            left: -9999px !important;
            pointer-events: none !important;
        }
        
        /* 769px 이하에서 "일정이 없습니다" 메시지도 카드 형태로 */
        #custom-list-view .no-data-message,
        #events-table .no-data-message,
        .no-data-message {
            display: block !important;
            background: white !important;
            border: none !important;
            border-radius: 8px !important;
            box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
            padding: 30px 20px !important;
            margin: 12px 0 !important;
            text-align: center !important;
            color: #666 !important;
            font-size: 16px !important;
            font-weight: 500 !important;
            width: 100% !important;
            box-sizing: border-box !important;
        }
        
        /* 769px 이하에서 테이블 셀로 표시되는 "일정이 없습니다" 메시지도 강제로 블록으로 변경 - 최고 우선순위 */
        #custom-list-view td.no-data-message,
        #events-table td.no-data-message,
        td.no-data-message,
        #events-table tbody tr td.no-data-message,
        #events-table tbody tr:last-child td.no-data-message {
            display: block !important;
            background: white !important;
            border: none !important;
            border-radius: 8px !important;
            box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
            padding: 30px 20px !important;
            margin: 12px 0 !important;
            text-align: center !important;
            color: #666 !important;
            font-size: 16px !important;
            font-weight: 500 !important;
            width: 100% !important;
            box-sizing: border-box !important;
            height: auto !important;
            min-height: 100px !important;
            visibility: visible !important;
            opacity: 1 !important;
            position: static !important;
            z-index: 9999 !important;
        }
    }

    /* 992px 이하에서 보이는 컬럼 폭 조정 */
    #custom-list-view th:nth-child(2),
    #custom-list-view td:nth-child(2) {
        width: 90px !important;
        min-width: 90px !important;
        max-width: 90px !important;
    }
    
    #custom-list-view th:nth-child(3),
    #custom-list-view td:nth-child(3) {
        width: 90px !important;
        min-width: 90px !important;
        max-width: 90px !important;
    }
    
    #custom-list-view th:nth-child(4),
    #custom-list-view td:nth-child(4) {
        width: auto !important;
        min-width: 200px !important;
    }
    
    /* 769px~992px 구간에서만 보이는 컬럼: 행사일자(5), 모집기간(6) */
    #custom-list-view th:nth-child(5),
    #custom-list-view td:nth-child(5) {
        width: 140px !important;
        min-width: 140px !important;
        max-width: 140px !important;
    }
    
    #custom-list-view th:nth-child(6),
    #custom-list-view td:nth-child(6) {
        width: 140px !important;
        min-width: 140px !important;
        max-width: 140px !important;
    }
    
    /* 태블릿에서 테이블 구조 강화 */
    #custom-list-view table {
        table-layout: fixed !important;
        width: 100% !important;
    }
    
    #custom-list-view th,
    #custom-list-view td {
        box-sizing: border-box !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        white-space: nowrap !important;
    }
    
    /* 992px 이하에서 "일정이 없습니다" 메시지 강제 표시 */
    .no-data-message {
        display: table-cell !important;
        visibility: visible !important;
        opacity: 1 !important;
        text-align: center !important;
        color: #666 !important;
        font-size: 16px !important;
        font-weight: 500 !important;
        padding: 30px 20px !important;
        background-color: #f8f9fa !important;
        border: 1px solid #e2e5ea !important;
        border-radius: 6px !important;
        margin: 10px !important;
    }
    
    /* 992px 이하에서 테이블 구조 강제 적용 */
    #custom-list-view table {
        display: table !important;
        table-layout: fixed !important;
        width: 100% !important;
        border-collapse: collapse !important;
    }
    
    #custom-list-view thead {
        display: table-header-group !important;
    }
    
    #custom-list-view tbody {
        display: table-row-group !important;
    }
    
    #custom-list-view tr {
        display: table-row !important;
    }
    
    #custom-list-view th,
    #custom-list-view td {
        display: table-cell !important;
        box-sizing: border-box !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        white-space: nowrap !important;
        vertical-align: middle !important;
    }
    
    /* 992px 이하에서 "일정이 없습니다" 메시지 강제 표시 (더 강력한 규칙) */
    #custom-list-view td.no-data-message {
        display: table-cell !important;
        visibility: visible !important;
        opacity: 1 !important;
        position: relative !important;
        z-index: 1000 !important;
        background-color: #f8f9fa !important;
        border: 1px solid #e2e5ea !important;
        border-radius: 6px !important;
        text-align: center !important;
        color: #666 !important;
        font-size: 16px !important;
        font-weight: 500 !important;
        padding: 30px 20px !important;
        margin: 10px !important;
    }
}

/* 768px 이하에서만 필요한 특별한 스타일 */
@media (max-width: 768px) {
    /* 모바일에서는 달력 뷰만 숨김 (툴바는 유지) */
    #calendar {
        display: none !important;
    }
    
    /* 모바일에서는 목록 뷰 강제 표시 */
    #custom-list-view {
        display: block !important;
    }
    
    /* 모바일에서는 달력/목록 버튼 숨김 */
    .fc-dayGridMonth-button,
    .fc-customList-button {
        display: none !important;
    }
    
    /* 모바일에서 오른쪽 툴바(달력/목록 버튼) 숨김 */
    #custom-list-view .fc-toolbar-chunk:last-child {
        display: none !important;
    }
    
    /* 툴바 전체를 세로 배치로 변경 */
    #custom-list-view .fc-toolbar {
        flex-direction: column !important;
        gap: 15px !important;
        align-items: stretch !important;
        margin-bottom: 20px !important;
    }
    
    /* 왼쪽 툴바 (이전/오늘/다음) */
    #custom-list-view .fc-toolbar-chunk:first-child {
        order: 1;
        justify-content: center !important;
        gap: 8px !important;
        width: 100% !important;
    }
    
    /* 중앙 툴바 (제목) */
    #custom-list-view .fc-toolbar-chunk:nth-child(2) {
        order: 2;
        text-align: center !important;
        justify-content: center !important;
        width: 100% !important;
        margin: 10px 0 !important;
    }
    
    /* 오른쪽 툴바 (달력/목록 버튼) - 숨김 */
    #custom-list-view .fc-toolbar-chunk:last-child {
        order: 3;
        display: none !important;
    }
    
    /* 툴바 제목 스타일 */
    #custom-list-view .fc-toolbar-title {
        font-size: 18px !important;
        font-weight: 600 !important;
        color: #333 !important;
        margin: 0 !important;
        text-align: center !important;
        width: 100% !important;
    }
    
    /* 툴바 버튼 스타일 */
    #custom-list-view .fc-button {
        height: 40px !important;
        padding: 0 16px !important;
        font-size: 14px !important;
        border-radius: 8px !important;
        margin: 0 4px !important;
        background: #3b82f6 !important;
        border: 1px solid #2563eb !important;
        color: white !important;
        font-weight: 500 !important;
        box-shadow: 0 2px 4px rgba(59, 130, 246, 0.1) !important;
        transition: all 0.2s ease !important;
    }
    
    #custom-list-view .fc-button:hover {
        background: #2563eb !important;
        border-color: #1d4ed8 !important;
        box-shadow: 0 4px 8px rgba(59, 130, 246, 0.2) !important;
        transform: translateY(-1px) !important;
    }
    
    #custom-list-view .fc-button:active {
        transform: translateY(0) !important;
        box-shadow: 0 1px 2px rgba(59, 130, 246, 0.1) !important;
    }
    
    /* 총 건수 중앙 정렬 */
    #custom-list-view .listTotal {
        text-align: center !important;
        margin: 20px 0 !important;
        font-size: 16px !important;
        font-weight: 600 !important;
        color: #333 !important;
    }
    
    /* 구분선 추가 */
    #custom-list-view .listTotal::after {
        content: '';
        display: block;
        width: 100%;
        height: 1px;
        background: #e2e5ea;
        margin-top: 15px;
    }
}

/* 작은 모바일 (500px 이하) */
@media (max-width: 500px) {
    /* 툴바 제목 폰트 크기 조정 */
    #custom-list-view .fc-toolbar-title {
        font-size: 16px !important;
    }
    
    /* 툴바 버튼 크기 조정 */
    #custom-list-view .fc-button {
        height: 36px !important;
        padding: 0 12px !important;
        font-size: 13px !important;
    }
    
    /* 총 건수 폰트 크기 조정 */
    #custom-list-view .listTotal {
        font-size: 15px !important;
        margin: 15px 0 !important;
    }
    
    /* 작은 모바일에서 "일정이 없습니다" 메시지 스타일 */
    #custom-list-view .no-data-message {
        font-size: 14px !important;
        padding: 25px 15px !important;
        margin: 8px !important;
    }
    
    /* 500px 이하에서 테이블 폭 유동적 조정 */
    #custom-list-view th:nth-child(2),
    #custom-list-view td:nth-child(2) {
        width: 75px !important;
        min-width: 75px !important;
        max-width: 400px !important;
        padding: 6px 3px !important;
        font-size: 12px !important;
        flex-shrink: 0 !important;
    }
    
    #custom-list-view th:nth-child(3),
    #custom-list-view td:nth-child(3) {
        width: 75px !important;
        min-width: 75px !important;
        max-width: 75px !important;
        padding: 6px 3px !important;
        font-size: 12px !important;
        flex-shrink: 0 !important;
    }
    
    #custom-list-view th:nth-child(4),
    #custom-list-view td:nth-child(4) {
        width: 1fr !important;
        min-width: 0 !important;
        max-width: none !important;
        padding: 6px 4px 6px 12px !important;
        font-size: 13px !important;
        flex: 1 !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }
    
    /* 500px 이하에서 테이블 전체 폭 조정 */
    #custom-list-view table {
        width: 100% !important;
        max-width: 100% !important;
        table-layout: auto !important;
    }
    
    /* 500px 이하에서 테이블 셀 패딩 조정 */
    #custom-list-view th,
    #custom-list-view td {
        padding: 6px 3px !important;
        font-size: 12px !important;
    }
    

    /* 500px 이하에서 행사상태 컬럼(3번째) 가운데 정렬 */
    #custom-list-view th:nth-child(3),
    #custom-list-view td:nth-child(3),
    #custom-list-view table tbody tr td:nth-child(3),
    #custom-list-view table thead tr th:nth-child(3) {
        text-align: center !important;
        text-align-last: center !important;
    }
    
    /* 행사상태 컬럼 내부 모든 요소 강제 가운데 정렬 */
    #custom-list-view td:nth-child(3) *,
    #custom-list-view td:nth-child(3) .btn,
    #custom-list-view td:nth-child(3) button,
    #custom-list-view td:nth-child(3) span,
    #custom-list-view td:nth-child(3) div,
    #custom-list-view td:nth-child(3) label,
    #custom-list-view td:nth-child(3) a,
    #custom-list-view td:nth-child(3) .status-btn {
        text-align: center !important;
        text-align-last: center !important;
        display: inline-block !important;
        margin: 0 !important;
        width: auto !important;
        float: none !important;
        position: static !important;
        left: auto !important;
        transform: none !important;
    }
    
    /* 500px 이하에서 모집상태 컬럼(4번째) 가운데 정렬 */
    #custom-list-view th:nth-child(4),
    #custom-list-view td:nth-child(4),
    #custom-list-view table tbody tr td:nth-child(4),
    #custom-list-view table thead tr th:nth-child(4) {
        text-align: center !important;
        text-align-last: center !important;
    }
    
    /* 모집상태 컬럼 내부 모든 요소 강제 가운데 정렬 */
    #custom-list-view td:nth-child(4) *,
    #custom-list-view td:nth-child(4) .btn,
    #custom-list-view td:nth-child(4) button,
    #custom-list-view td:nth-child(4) span,
    #custom-list-view td:nth-child(4) div,
    #custom-list-view td:nth-child(4) label,
    #custom-list-view td:nth-child(4) a,
    #custom-list-view td:nth-child(4) .status-btn,
    #custom-list-view td:nth-child(4) .status-waiting,
    #custom-list-view td:nth-child(4) .status-progress,
    #custom-list-view td:nth-child(4) .status-complete {
        text-align: center !important;
        text-align-last: center !important;
        display: inline-block !important;
        margin: 0 !important;
        width: auto !important;
        float: none !important;
        position: static !important;
        left: auto !important;
        transform: none !important;
    }
    
    /* template.css의 .grid_list 스타일 완전 오버라이드 */
    #custom-list-view table tbody tr td:nth-child(3),
    #custom-list-view table thead tr th:nth-child(3),
    #custom-list-view table tbody tr td:nth-child(4),
    #custom-list-view table thead tr th:nth-child(4) {
        text-align: center !important;
        text-align-last: center !important;
    }
}

/* 매우 작은 모바일 (400px 이하) */
@media (max-width: 400px) {
    /* 매우 작은 모바일에서 테이블 폭 최종 조정 */
    #custom-list-view th:nth-child(2),
    #custom-list-view td:nth-child(2) {
        width: 70px !important;
        min-width: 70px !important;
        max-width: 70px !important;
        padding: 4px 2px !important;
        font-size: 11px !important;
        flex-shrink: 0 !important;
    }
    
    #custom-list-view th:nth-child(3),
    #custom-list-view td:nth-child(3) {
        width: 70px !important;
        min-width: 70px !important;
        max-width: 70px !important;
        padding: 4px 2px !important;
        font-size: 11px !important;
        flex-shrink: 0 !important;
    }
    
    #custom-list-view th:nth-child(4),
    #custom-list-view td:nth-child(4) {
        width: 1fr !important;
        min-width: 0 !important;
        max-width: none !important;
        padding: 4px 3px 4px 10px !important;
        font-size: 12px !important;
        flex: 1 !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        text-align: left !important;
    }
    
    /* 매우 작은 모바일에서 테이블 셀 패딩 최종 조정 */
    #custom-list-view th,
    #custom-list-view td {
        padding: 4px 2px !important;
        font-size: 11px !important;
    }
    
    /* 400px 이하에서 행사상태 컬럼(3번째) 가운데 정렬 */
    #custom-list-view th:nth-child(3),
    #custom-list-view td:nth-child(3),
    #custom-list-view table tbody tr td:nth-child(3),
    #custom-list-view table thead tr th:nth-child(3) {
        text-align: center !important;
        text-align-last: center !important;
    }
    
    /* 행사상태 컬럼 내부 모든 요소 강제 가운데 정렬 */
    #custom-list-view td:nth-child(3) *,
    #custom-list-view td:nth-child(3) .btn,
    #custom-list-view td:nth-child(3) button,
    #custom-list-view td:nth-child(3) span,
    #custom-list-view td:nth-child(3) div,
    #custom-list-view td:nth-child(3) label,
    #custom-list-view td:nth-child(3) a,
    #custom-list-view td:nth-child(3) .status-btn {
        text-align: center !important;
        text-align-last: center !important;
        display: inline-block !important;
        margin: 0 !important;
        width: auto !important;
        float: none !important;
        position: static !important;
        left: auto !important;
        transform: none !important;
    }
    
    /* 400px 이하에서 모집상태 컬럼(4번째) 가운데 정렬 */
    #custom-list-view th:nth-child(4),
    #custom-list-view td:nth-child(4),
    #custom-list-view table tbody tr td:nth-child(4),
    #custom-list-view table thead tr th:nth-child(4) {
        text-align: center !important;
        text-align-last: center !important;
    }
    
    /* 모집상태 컬럼 내부 모든 요소 강제 가운데 정렬 */
    #custom-list-view td:nth-child(4) *,
    #custom-list-view td:nth-child(4) .btn,
    #custom-list-view td:nth-child(4) button,
    #custom-list-view td:nth-child(4) span,
    #custom-list-view td:nth-child(4) div,
    #custom-list-view td:nth-child(4) label,
    #custom-list-view td:nth-child(4) a,
    #custom-list-view td:nth-child(4) .status-btn,
    #custom-list-view td:nth-child(4) .status-waiting,
    #custom-list-view td:nth-child(4) .status-progress,
    #custom-list-view td:nth-child(4) .status-complete {
        text-align: center !important;
        text-align-last: center !important;
        display: inline-block !important;
        margin: 0 !important;
        width: auto !important;
        float: none !important;
        position: static !important;
        left: auto !important;
        transform: none !important;
    }
    
    /* template.css의 .grid_list 스타일 완전 오버라이드 */
    #custom-list-view table tbody tr td:nth-child(3),
    #custom-list-view table thead tr th:nth-child(3),
    #custom-list-view table tbody tr td:nth-child(4),
    #custom-list-view table thead tr th:nth-child(4) {
        text-align: center !important;
        text-align-last: center !important;
    }
    
    /* 매우 작은 모바일에서 "일정이 없습니다" 메시지 최종 조정 */
    #custom-list-view .no-data-message {
        font-size: 13px !important;
        padding: 20px 10px !important;
        margin: 5px !important;
    }
}

/* 극소형 모바일 (360px 이하) */
@media (max-width: 360px) {
    /* 극소형 모바일에서 테이블 폭 최종 조정 */
    #custom-list-view th:nth-child(2),
    #custom-list-view td:nth-child(2) {
        width: 70px !important;
        min-width: 70px !important;
        max-width: 70px !important;
        padding: 4px 6px !important;
        font-size: 11px !important;
        flex-shrink: 0 !important;
    }
    
    #custom-list-view th:nth-child(3),
    #custom-list-view td:nth-child(3) {
        width: 70px !important;
        min-width: 70px !important;
        max-width: 70px !important;
        padding: 4px 2px !important;
        font-size: 11px !important;
        flex-shrink: 0 !important;
    }
    
    #custom-list-view th:nth-child(4),
    #custom-list-view td:nth-child(4) {
        width: 1fr !important;
        min-width: 0 !important;
        max-width: none !important;
        padding: 4px 3px 4px 8px !important;
        font-size: 12px !important;
        flex: 1 !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }
    
    /* 극소형 모바일에서 테이블 셀 패딩 최종 조정 */
    #custom-list-view th,
    #custom-list-view td {
        padding: 4px 2px !important;
        font-size: 11px !important;
    }
    
    /* 360px 이하에서 행사상태 컬럼(3번째) 가운데 정렬 */
    #custom-list-view th:nth-child(3),
    #custom-list-view td:nth-child(3),
    #custom-list-view table tbody tr td:nth-child(3),
    #custom-list-view table thead tr th:nth-child(3) {
        text-align: center !important;
        text-align-last: center !important;
    }
    
    /* 행사상태 컬럼 내부 모든 요소 강제 가운데 정렬 */
    #custom-list-view td:nth-child(3) *,
    #custom-list-view td:nth-child(3) .btn,
    #custom-list-view td:nth-child(3) button,
    #custom-list-view td:nth-child(3) span,
    #custom-list-view td:nth-child(3) div,
    #custom-list-view td:nth-child(3) label,
    #custom-list-view td:nth-child(3) a,
    #custom-list-view td:nth-child(3) .status-btn {
        text-align: center !important;
        text-align-last: center !important;
        display: inline-block !important;
        margin: 0 !important;
        width: auto !important;
        float: none !important;
        position: static !important;
        left: auto !important;
        transform: none !important;
    }
    
    /* 360px 이하에서 모집상태 컬럼(4번째) 가운데 정렬 */
    #custom-list-view th:nth-child(4),
    #custom-list-view td:nth-child(4),
    #custom-list-view table tbody tr td:nth-child(4),
    #custom-list-view table thead tr th:nth-child(4) {
        text-align: center !important;
        text-align-last: center !important;
    }
    
    /* 모집상태 컬럼 내부 모든 요소 강제 가운데 정렬 */
    #custom-list-view td:nth-child(4) *,
    #custom-list-view td:nth-child(4) .btn,
    #custom-list-view td:nth-child(4) button,
    #custom-list-view td:nth-child(4) span,
    #custom-list-view td:nth-child(4) div,
    #custom-list-view td:nth-child(4) label,
    #custom-list-view td:nth-child(4) a,
    #custom-list-view td:nth-child(4) .status-btn,
    #custom-list-view td:nth-child(4) .status-waiting,
    #custom-list-view td:nth-child(4) .status-progress,
    #custom-list-view td:nth-child(4) .status-complete {
        text-align: center !important;
        text-align-last: center !important;
        display: inline-block !important;
        margin: 0 !important;
        width: auto !important;
        float: none !important;
        position: static !important;
        left: auto !important;
        transform: none !important;
    }
    
    /* template.css의 .grid_list 스타일 완전 오버라이드 */
    #custom-list-view table tbody tr td:nth-child(3),
    #custom-list-view table thead tr th:nth-child(3),
    #custom-list-view table tbody tr td:nth-child(4),
    #custom-list-view table thead tr th:nth-child(4) {
        text-align: center !important;
        text-align-last: center !important;
    }
    
    /* 극소형 모바일에서 "일정이 없습니다" 메시지 최종 조정 */
    #custom-list-view .no-data-message {
        font-size: 12px !important;
        padding: 18px 8px !important;
        margin: 4px !important;
    }
    
    /* 극소형 모바일에서 테이블 전체 최적화 */
    #custom-list-view table {
        width: 100% !important;
        max-width: 100% !important;
        font-size: 11px !important;
        table-layout: auto !important;
    }
}


/* 모집상태 컬럼 전역 가운데 정렬 (모든 화면 크기) */
#custom-list-view th:nth-child(3),
#custom-list-view td:nth-child(3) {
    text-align: center !important;
    text-align-last: center !important;
}

/* 모집상태 컬럼 내부 모든 요소 전역 가운데 정렬 */
#custom-list-view td:nth-child(3) *,
#custom-list-view td:nth-child(3) .btn,
#custom-list-view td:nth-child(3) button,
#custom-list-view td:nth-child(3) span,
#custom-list-view td:nth-child(3) div,
#custom-list-view td:nth-child(3) label,
#custom-list-view td:nth-child(3) a,
#custom-list-view td:nth-child(3) .status-btn,
#custom-list-view td:nth-child(3) .status-waiting,
#custom-list-view td:nth-child(3) .status-progress,
#custom-list-view td:nth-child(3) .status-complete {
    text-align: center !important;
    text-align-last: center !important;
    display: inline-block !important;
    margin: 0 auto !important;
    width: auto !important;
    float: none !important;
}



/* 목록 제목 (제목 컬럼에만 적용) */
#custom-list-view td.event-title-cell {
    font-weight: 500;
    color: #000000;
    max-width: 400px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-align: left !important;
}



/* cell 가운데 정렬 */
.center-cell {
    text-align: center !important;
    position: relative;
}

/* center-cell 내부의 status-btn 완벽 중앙 정렬 */
.center-cell .status-btn {
    position: static;
    left: auto;
    top: auto;
    transform: none;
    margin: 0;
    display: inline-block;
}

/* 번호 셀 가운데 정렬 */
.number-cell {
    text-align: center !important;
    font-weight: 500;
    color: #666;
}

/* 행사상태,모집상태 버튼 공통 스타일 */
.status-btn {
    display: inline-block;
    border-radius: 7px;
    padding: 2px 3px;
    font-size: 12px;
    font-weight: 500;
    text-align: center;
    text-align-last: center;
    min-width: 65px;
    border: none;
    cursor: default;
    margin: 0;
    position: static;
    left: auto;
    transform: none;
}

/* 임시저장 상태 */
.status-temp {
    background-color: #E0E0E0;
    color: #666666;
}

/* 모집중,진행중 상태 */
.status-recruiting {
    background-color: #27d8b2;
    color: #ffffff;
}

/* 마감 상태 */
.status-closed {
    background-color: #666666;
    color: white;
}

/* 대기중 상태 */
.status-waiting {
    background-color: #f5d312;
    color: #495057;
}

/* 기본 상태 */
.status-default {
    background-color: #e9ecef;
    color: #495057;
}

/* 일정이 없을 때 표시되는 메시지 스타일 */
.no-data-message {
    text-align: center !important;
    color: #666 !important;
    font-size: 16px !important;
    font-weight: 500 !important;
    padding: 40px 20px !important;
    background-color: #f8f9fa !important;
    border: 1px solid #e2e5ea !important;
    border-radius: 6px !important;
    margin: 10px !important;
    position: relative !important;
    z-index: 100 !important;
}

@media (max-width: 768px) {
    .no-data-message {
        display: table-cell !important;
        visibility: visible !important;
        opacity: 1 !important;
        text-align: center !important;
        color: #666 !important;
        font-size: 16px !important;
        font-weight: 500 !important;
        padding: 30px 20px !important;
        background-color: #f8f9fa !important;
        border: 1px solid #e2e5ea !important;
        border-radius: 6px !important;
        margin: 10px !important;
    }
    
    /* 모바일에서 테이블 헤더 정렬 */
    #custom-list-view th {
        display: table-cell !important;
        text-align: center !important;
        padding: 12px 8px !important;
        font-weight: 600 !important;
        background-color: #f8f9fa !important;
        border-bottom: 2px solid #dee2e6 !important;
    }
    
    /* 모바일에서 숨겨진 헤더 숨김 */
    #custom-list-view th:nth-child(1),
    #custom-list-view th:nth-child(5),
    #custom-list-view th:nth-child(6),
    #custom-list-view th:nth-child(7),
    #custom-list-view th:nth-child(8) {
        display: none !important;
    }
    
    /* 모바일에서 테이블 구조 강제 적용 */
    #custom-list-view table {
        display: table !important;
        width: 100% !important;
        border-collapse: collapse !important;
    }
    
    #custom-list-view thead {
        display: table-header-group !important;
    }
    
    #custom-list-view tbody {
        display: table-row-group !important;
    }
    
    #custom-list-view tr {
        display: table-row !important;
    }
    
    #custom-list-view td {
        display: table-cell !important;
    }
    
    /* 모바일에서 "일정이 없습니다" 메시지 강제 표시 */
    #custom-list-view td.no-data-message {
        display: table-cell !important;
        visibility: visible !important;
        opacity: 1 !important;
        position: relative !important;
        z-index: 1000 !important;
        background-color: #f8f9fa !important;
        border: 1px solid #e2e5ea !important;
        border-radius: 6px !important;
        text-align: center !important;
        color: #666 !important;
        font-size: 16px !important;
        font-weight: 500 !important;
        padding: 30px 20px !important;
        margin: 10px !important;
    }
    
    /* 모바일에서 테이블 셀 너비 조정 */
    #custom-list-view th:nth-child(2),
#custom-list-view td:nth-child(2) {
    width: 90px !important;
    min-width: 90px !important;
    max-width: 400px !important;
}
    
    #custom-list-view th:nth-child(3),
    #custom-list-view td:nth-child(3) {
        width: 90px !important;
        min-width: 90px !important;
    }
    
    #custom-list-view th:nth-child(4),
    #custom-list-view td:nth-child(4) {
        width: auto !important;
        min-width: 120px !important;
    }
}

/* 커스텀 목록 버튼 스타일 */
.fc-customList-button {
    background-color: #007bff !important;
    border-color: #007bff !important;
    color: white !important;
}

.fc-customList-button:hover {
    background-color: #0056b3 !important;
    border-color: #0056b3 !important;
}

.fc-customList-button.fc-button-active {
    background-color: #0056b3 !important;
    border-color: #0056b3 !important;
}

/* 기존 FullCalendar 목록 뷰 스타일 (숨김 처리) */
.fc-list-view {
    display: none !important;
}

.dialogText {
    line-height: 1.6;
    color: #333;
}

/* 테이블 스타일 */
form .table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

form th, td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

form th {
    background-color: #f8f9fa;
    font-weight: 600;
    color: #333;
}

textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.txtCount {
    text-align: right;
    color: #666;
    font-size: 12px;
    margin-top: 5px;
}

/* 더보기 이벤트 팝업 스타일 - 간소화 */
.more-events-popup-container {
    position: fixed;
    z-index: 9999;
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    width: 500px;
    max-height: 500px;
    overflow-y: auto;
}

.more-events-popup {
    padding: 16px;
}

.more-events-popup h4 {
    margin: 0 0 12px 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
    border-bottom: 1px solid #eee;
    padding-bottom: 8px;
}

.event-item {
    padding: 8px 12px;
    margin-bottom: 8px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    background-color: #f9f9f9;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.event-item:hover {
    background-color: #f0f0f0;
}

.event-title {
    font-weight: 500;
    color: #333;
    margin-bottom: 4px;
    font-size: 14px;
}

.event-dates {
    font-size: 12px;
    color: #666;
}

.btn-close-popup {
    background-color: #6c757d;
    color: white;
    border: none;
    padding: 6px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}

/* 더보기 링크 스타일 */
.fc-daygrid-more-link {
    color: #007bff !important;
    text-decoration: none !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    padding: 2px 6px !important;
    border-radius: 3px !important;
    background-color: #f8f9fa !important;
    border: 1px solid #dee2e6 !important;
    transition: all 0.2s ease !important;
}

.fc-daygrid-more-link:hover {
    background-color: #e9ecef !important;
    border-color: #adb5bd !important;
    color: #0056b3 !important;
}

/* 정렬 가능한 헤더 스타일 */
.sortable {
    cursor: pointer !important;
    user-select: none !important;
    position: relative !important;
}

.sortable:hover {
    background-color: #e9ecef !important;
}

.sort-icon {
    margin-left: 5px !important;
    font-size: 12px !important;
    color: #6c757d !important;
    transition: color 0.2s ease !important;
}

.sortable:hover .sort-icon {
    color: #007bff !important;
}

.sortable[data-sort="occsStrDe"] .sort-icon {
    color: #007bff !important;
}

#dlg_diary .modal-header {
    background: #2c3e50;
    color: white;
    border-bottom: none;
    border-radius: 8px 8px 0 0;
    padding: 20px 25px;
}

#dlg_diary .mdlTitWrap p {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

#dlg_diary .mdlClose {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}



#dlg_diary .modal-body {
    padding: 25px;
}

#dlg_diary table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
}

#dlg_diary caption {
    display: none;
}

#dlg_diary th {
    background: #f8f9fa;
    padding: 15px 20px;
    text-align: left;
    border: 1px solid #e9ecef;
    font-weight: 600;
    color: #495057;
    vertical-align: top;
    width: 20%;
}

#dlg_diary td {
    padding: 15px 20px;
    border: 1px solid #e9ecef;
    vertical-align: top;
}

#dlg_diary .detail-content-box,
#dlg_diary .detail-file-box {
    height: 200px;
    width: 100%;
    overflow-y: auto;
    padding: 15px;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    background-color: #f8f9fa;
    white-space: pre-line;
    line-height: 1.6;
    word-wrap: break-word;
    font-size: 14px;
    color: #495057;
}

#dlg_diary .detail-file-box {
    height: 100px;
}

/* 상태 태그 스타일 */
#dlg_diary .status-btn {
    display: inline-block;
    padding: 4px 0px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    margin-right: 8px;
    margin-bottom: 4px;
}

#dlg_diary .status-recruiting {
    background-color: #28a745;
    color: white;
}

#dlg_diary .status-closed {
    background-color: #6c757d;
    color: white;
}

#dlg_diary .status-waiting {
    background-color: #ffedb8;
    color: #212529;
}

#dlg_diary .status-temp {
    background-color: #e9ecef;
    color: #6c757d;
}

#dlg_diary .status-default {
    background-color: #17a2b8;
    color: white;
}

/* 첨부파일 링크 스타일 */
#dlg_diary .detail-file-box a {
    color: #007bff;
    text-decoration: none;
    display: block;
    padding: 4px 0;
}

/* 모달 푸터 및 닫기 버튼 스타일 */
#dlg_diary .modal-footer {
    border-top: 1px solid #e9ecef;
    background: #f8f9fa;
    text-align: center;
    border-radius: 0 0 8px 8px;
}

/* 모달 푸터 및 닫기 버튼 스타일 (서명) */
#dlg_diary .modal-footer-sign {
    text-align: center;
    border-radius: 0 0 8px 8px;
}

#dlg_diary .btn-close-modal {
    background: #6c757d;
    color: white;
    border: none;
    padding: 10px 10px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 70px;
}

#dlg_diary .detail-file-box a:hover {
    text-decoration: underline;
    color: #0056b3;
}

/* 검색 영역 스타일 */
.search-container {
    background: #f5f5f5;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #d5d5d5;
    margin-bottom: 20px;
    display: none; /* 초기에는 숨김 */
}

.search-form {
    display: flex;
    align-items: center;
    gap: 12px;
}

.search-select {
    border: 1px solid #bebebe;
    border-radius: 4px;
    background-color: white;
    font-size: 14px;
    min-width: 120px;
    height: 35px;
}

.search-btn {
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    min-width: 70px;
}

.search-btn-reset {
    background-color: #6c757d;
    color: white;
}

.search-btn-search {
    background-color: #0077ff;
    color: white;
}


/* ===== List/Search custom styles (user skin) ===== */
.srchWrap {
    background: #f7f8fa;
    border-radius: 10px;
    margin-bottom: 18px;
}
.srchWrap .formSt1 fieldset {
    display: flex;
    gap: 10px;
    align-items: center;
}

#custom-list-view .listTotal {
    margin: 20px 10px 12px 5px;
    font-size: 16px;
    font-weight: 600;
    color: #333;
}
.table-container { 
    background: #fff; 
    border: none; 
    border-radius: 10px; 
    overflow: hidden; 
}
#events-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}
#events-table thead th {
    background: #f9fafc;
    color: #333;
    font-weight: 700;
    border-top: 1px solid #e6e8ec;
    border-bottom: 1px solid #e6e8ec;
    padding: 14px 12px;
    text-align: center;
}
#events-table tbody td {
    border-bottom: 1px solid #f0f2f5;
    padding: 20px 12px;
    color: #222;
    height: 60px;
    vertical-align: middle;
}
#events-table tbody tr:last-child td { border-bottom: 0; }
#events-table .number-cell, #events-table .center-cell { text-align: center; }
#events-table .event-title-cell { 
    text-align: left; 
    font-weight: 600; 
    color: #000000; 
    border-bottom: none !important; 
}

/* 페이지네이션 내부 요소 간격 조정 */
.paginationBox .pagination {
    gap: 4px;
}

.paginationBox .pagination li {
    margin: 0 2px;
}

.paginationBox .pagination .pagiNum {
    margin: 0 2px;
}

.paginationBox .pagination .pagiArrow {
    margin: 0 2px;
}

.paginationBox .pagination .pagiPrev1 {
    margin-right: 6px;
}

.paginationBox .pagination .pagiNext1 {
    margin-left: 6px;
}

/* ===== 769px 이하 강제 카드 형태 적용 ===== */
@media (max-width: 769px) {
    /* 769px 이하에서 thead 완전 숨김 - 최고 우선순위 */
    #custom-list-view thead,
    #custom-list-view thead *,
    #custom-list-view thead tr,
    #custom-list-view thead th,
    #custom-list-view thead td {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        height: 0 !important;
        width: 0 !important;
        overflow: hidden !important;
        position: absolute !important;
        left: -9999px !important;
        pointer-events: none !important;
    }
    
    /* 769px 이하에서 테이블 전체를 카드 형태로 강제 변경 */
    #custom-list-view table {
        border: none !important;
        background: none !important;
        border-collapse: separate !important;
        border-spacing: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
        display: block !important;
    }
    
    #custom-list-view tbody {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
    }
    
    #custom-list-view tbody tr {
        display: block !important;
        background: white !important;
        border-top: 1px solid #e6e8ec !important;
        border-bottom: 1px solid #e6e8ec !important;
        border-radius: 0 !important;
        margin-bottom: 0 !important;
        padding: 5px !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        float: none !important;
        clear: both !important;
    }
    
    #custom-list-view tbody td {
        display: block !important;
        border: none !important;
        padding: 8px 0 !important;
        height: auto !important;
        text-align: left !important;
        background: none !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        float: none !important;
        clear: both !important;
    }
    
    /* 769px 이하에서 카드 내부 레이아웃 */
    #custom-list-view td:nth-child(2) {
        font-size: 16px !important;
        font-weight: 600 !important;
        color: #333 !important;
        padding: 16px 20px !important;
        padding-bottom: 12px !important;
        border-bottom: 1px solid #f0f2f5 !important;
        margin-bottom: 12px !important;
        width: 100% !important;
        max-width: none !important;
        box-sizing: border-box !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        line-height: 1.4 !important;
    }
    
    #custom-list-view td:nth-child(5) {
        font-size: 14px !important;
        color: #666 !important;
        padding: 0 20px 16px 20px !important;
        text-align: left !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    /* 769px 이하에서 숨겨진 셀들 - 강제 숨김 */
    #custom-list-view td:nth-child(1),
    #custom-list-view td:nth-child(3),
    #custom-list-view td:nth-child(4),
    #custom-list-view td:nth-child(6),
    #custom-list-view td:nth-child(7),
    #custom-list-view td:nth-child(8) {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        height: 0 !important;
        width: 0 !important;
        overflow: hidden !important;
        position: absolute !important;
        left: -9999px !important;
        pointer-events: none !important;
    }
    
    /* 769px 이하에서 "일정이 없습니다" 메시지도 카드 형태로 */
    #custom-list-view .no-data-message,
    #events-table .no-data-message,
    .no-data-message {
        display: block !important;
        background: white !important;
        border: none !important;
        border-radius: 8px !important;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
        padding: 30px 20px !important;
        margin: 12px 0 !important;
        text-align: center !important;
        color: #666 !important;
        font-size: 16px !important;
        font-weight: 500 !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    /* 769px 이하에서 테이블 셀로 표시되는 "일정이 없습니다" 메시지도 강제로 블록으로 변경 - 최고 우선순위 */
    #custom-list-view td.no-data-message,
    #events-table td.no-data-message,
    td.no-data-message,
    #events-table tbody tr td.no-data-message,
    #events-table tbody tr:last-child td.no-data-message {
        display: block !important;
        background: white !important;
        border: none !important;
        border-radius: 8px !important;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
        padding: 30px 20px !important;
        margin: 12px 0 !important;
        text-align: center !important;
        color: #666 !important;
        font-size: 16px !important;
        font-weight: 500 !important;
        width: 100% !important;
        box-sizing: border-box !important;
        height: auto !important;
        min-height: 100px !important;
        visibility: visible !important;
        opacity: 1 !important;
        position: static !important;
        z-index: 9999 !important;
    }
}

/* 모바일에서 제목 옆 건수 span 스타일 */
#listTotalCountMobile {
    font-size: 14px !important;
    font-weight: 500 !important;
    color: #666 !important;
    margin-left: 8px !important;
    display: inline !important;
    vertical-align: baseline !important;
    white-space: nowrap !important;
}

/* 769px 이하에서 기존 건수 표시 영역 숨김 */
@media (max-width: 769px) {
    #custom-list-view .listTotal {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        height: 0 !important;
        width: 0 !important;
        overflow: hidden !important;
        position: absolute !important;
        left: -9999px !important;
        pointer-events: none !important;
    }
    
    /* 769px 이하에서 툴바 레이아웃 조정 */
    #custom-list-view .fc-toolbar {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 0 !important;
        margin-bottom: 20px !important;
        width: 100% !important;
        box-sizing: border-box !important;
        flex-wrap: nowrap !important;
    }
    
    /* 769px 이하에서 모든 요소를 한 줄로 배치 */
    #custom-list-view .fc-toolbar-chunk:first-child,
    #custom-list-view .fc-toolbar-chunk:nth-child(2) {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: flex-start !important;
        flex-shrink: 0 !important;
        width: auto !important;
        box-sizing: border-box !important;
        flex-wrap: nowrap !important;
    }
    
/* 모든 환경에서 < > 버튼들의 margin 제거 및 간격 통일 */
#custom-list-view .fc-toolbar-chunk:first-child .fc-button {
    margin: 0 !important;
    padding: 0 8px !important;
}

/* 모든 환경에서 버튼들 사이의 간격을 동일하게 설정 */
#custom-list-view .fc-toolbar-chunk:first-child {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
}

/* 모든 환경에서 < > 버튼들이 수직 중앙에 오도록 설정 */
#custom-list-view .fc-toolbar-chunk:first-child .fc-button {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    height: 40px !important;
    line-height: 1 !important;
    vertical-align: middle !important;
}

/* < > 버튼 내부 화살표를 정중앙에 배치 */
#custom-list-view .fc-toolbar-chunk:first-child .fc-button .fc-icon {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    height: 100% !important;
    line-height: 1 !important;
    margin: 0 !important;
    padding: 0 !important;
    vertical-align: middle !important;
}
    
    /* 769px 이하에서 제목과 건수는 오른쪽에 배치 */
    #custom-list-view .fc-toolbar-chunk:nth-child(2) {
        margin-left: auto !important;
        justify-content: flex-end !important;
    }
    
    /* 769px 이하에서 제목 스타일 */
    #custom-list-view .fc-toolbar-title {
        text-align: right !important;
        margin: 0 !important;
        font-size: 18px !important;
        font-weight: 600 !important;
        color: #333 !important;
    }
    
    /* 769px 이하에서 오른쪽 툴바 (달력/목록 버튼) - 숨김 */
    #custom-list-view .fc-toolbar-chunk:last-child {
        display: none !important;
    }
}

/* 모바일에서 "일정이 없습니다" 메시지 강제 표시 - 최고 우선순위 */
@media (max-width: 769px) {
    /* 모든 가능한 선택자로 "일정이 없습니다" 메시지 강제 표시 */
    #custom-list-view td.no-data-message,
    #events-table td.no-data-message,
    td.no-data-message,
    #events-table tbody tr td.no-data-message,
    #events-table tbody tr:last-child td.no-data-message,
    .no-data-message,
    [class*="no-data-message"] {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        position: static !important;
        left: auto !important;
        top: auto !important;
        height: auto !important;
        width: 100% !important;
        overflow: visible !important;
        background: white !important;
        border: none !important;
        border-radius: 8px !important;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
        padding: 30px 20px !important;
        margin: 12px 0 !important;
        text-align: center !important;
        color: #666 !important;
        font-size: 16px !important;
        font-weight: 500 !important;
        box-sizing: border-box !important;
        min-height: 100px !important;
        z-index: 9999 !important;
        pointer-events: auto !important;
    }
    
    /* 추가로 더 강력한 선택자로 강제 표시 */
    table tbody tr td.no-data-message,
    table tbody tr:last-child td.no-data-message,
    tbody tr td.no-data-message,
    tr td.no-data-message {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        position: static !important;
        left: auto !important;
        top: auto !important;
        height: auto !important;
        width: 100% !important;
        overflow: visible !important;
        background: white !important;
        border: none !important;
        border-radius: 8px !important;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
        padding: 30px 20px !important;
        margin: 12px 0 !important;
        text-align: center !important;
        color: #666 !important;
        font-size: 16px !important;
        font-weight: 500 !important;
        box-sizing: border-box !important;
        min-height: 100px !important;
        z-index: 9999 !important;
        pointer-events: auto !important;
    }
}

/* 모바일에서 "일정이 없습니다" 메시지 최종 강제 표시 */
@media (max-width: 769px) {
    /* 모든 테이블 셀 중 no-data-message 클래스를 가진 요소 강제 표시 */
    td[class*="no-data-message"],
    td.no-data-message,
    .no-data-message,
    [class*="no-data-message"] {
        all: unset !important;
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        position: static !important;
        left: auto !important;
        top: auto !important;
        height: auto !important;
        width: 100% !important;
        overflow: visible !important;
        background: white !important;
        border: none !important;
        border-radius: 8px !important;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
        padding: 30px 20px !important;
        margin: 12px 0 !important;
        text-align: center !important;
        color: #666 !important;
        font-size: 16px !important;
        font-weight: 500 !important;
        box-sizing: border-box !important;
        min-height: 100px !important;
        z-index: 99999 !important;
        pointer-events: auto !important;
        float: none !important;
        clear: both !important;
    }
}

/* ===== 상세보기(모달) 폭/스크롤 정책 ===== */
/* 상세보기 모달 자체의 가로 스크롤은 차단 */
#dlg_diary .modal-dialog,
#dlg_diary .modal-content,
#dlg_diary .modal-body { overflow-x: hidden !important; max-width: 100% !important; }

/* 데스크톱(>=992px)에서는 모달이 화면 끝까지 퍼지지 않도록 제한 */
@media (min-width: 992px) {
  #dlg_diary .modal-dialog { 
    max-width: 800px !important; 
    width: auto !important;
    margin-left: auto !important;
    margin-right: auto !important;
  }
  /* 내용 컨테이너는 가로폭 제한을 따르게 하고 별도 max-width 강제는 제거 */
  #dlg_diary .modal-content,
  #dlg_diary .modal-body { 
    max-width: none !important;
  }
}

/* 상세보기 모달 테이블은 고정 레이아웃으로 셀 폭을 강제로 지킴 */
#dlg_diary table { width: 100% !important; table-layout: fixed !important; }
#dlg_diary th, #dlg_diary td { overflow: hidden; }

/* 제목, 첨부는 칸을 넘지 않도록 래핑 (inline style 무력화를 위해 !important) */
#dlg_diary #detail-diffusioTl,
#dlg_diary #detail-atchFileId { 
	width: auto !important;          /* 내용 길이에 맞추되 */
	max-width: 100% !important;      /* 칸을 넘지 않음 */
	display: block !important;
	white-space: normal !important;  /* 자동 줄바꿈 허용 */
	word-break: break-word !important;
	overflow-wrap: anywhere !important;
}
#dlg_diary #detail-atchFileId a { word-break: break-all; overflow-wrap: anywhere; }

/* 주요내용은 칸 내부에서만 가로 스크롤 발생 */
#dlg_diary #detail-stpeCn {
	width: 100% !important;          /* 칸을 꽉 채우고 */
	max-width: 100% !important;
	display: block !important;
	white-space: pre !important;     /* 자동 줄바꿈 방지(원본 개행 유지) */
	word-break: normal !important;
	overflow-wrap: normal !important;
	overflow-x: auto !important;     /* 내부 가로 스크롤 */
	overflow-y: auto !important;     /* 세로 스크롤은 내부에서 */
	max-height: 40vh;                /* 필요시 내부 세로 스크롤 */
	-webkit-overflow-scrolling: touch;
}


/* 상세보기 모달 디자인 스타일 - Bootstrap 기본 스타일 강제 오버라이드 */   
.modal-header{
    margin-bottom : 0px !important;
}

/* 신청하기 버튼 디자인 */
.btn-apply {
    background: #2563eb !important;
    color: #fff !important;
    border: 1px solid #1d4ed8 !important;
    padding: 8px 14px !important;
    border-radius: 6px !important;
    font-weight: 600 !important;
    box-shadow: 0 2px 6px rgba(37, 99, 235, 0.25) !important;
    transition: all .2s ease !important;
}
.btn-apply:hover { background: #1d4ed8 !important; }
.btn-apply:active { transform: translateY(1px); box-shadow: 0 1px 3px rgba(37, 99, 235, 0.25) !important; }

/* 상세보기 모달 모든 modal-content 관련 선택자에 대해 디자인 스타일 적용 */
#dlg_diary .modal-content,
#dlg_diary.modal .modal-content,
.modal-dialog-scrollable .modal-content,
.modal-content {
    border: none !important;
    border-radius: 8px !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3) !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* 상세보기 모달 모든 modal-content 관련 선택자에 대해 padding 제거 */
#dlg_diary .modal-content,
#dlg_diary.modal .modal-content,
.modal-dialog-scrollable .modal-content,
.modal-content,
#dlg_diary .modal-dialog .modal-content {
    padding: 0 !important;
}

/* 상세보기 모달 닫기 X 버튼 스타일 - 강제 흰색 적용 */
#dlg_diary .mdlClose.icon-x,
#dlg_diary .mdlClose.icon-x *,
#dlg_diary .mdlClose.icon-x svg,
#dlg_diary .mdlClose.icon-x svg * {    
    color: white !important;
    fill: white !important;
    stroke: white !important;
    background: none !important;
    font-size: 18px !important;
    cursor: pointer !important;
    padding: 0 !important;
    width: 24px !important;
    height: 24px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

#dlg_diary .mdlClose.icon-x:hover,
#dlg_diary .mdlClose.icon-x:hover *,
#dlg_diary .mdlClose.icon-x:hover svg,
#dlg_diary .mdlClose.icon-x:hover svg * {
    color: white !important;
    fill: white !important;
    stroke: white !important;
    background: none !important;
}

/* 신청하기 모달 스타일 */
#applyModal .modal-content {
    border: none !important;
    border-radius: 8px !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3) !important;
}

#applyModal .modal-header {
    border-bottom: none !important;
    padding: 20px 24px 10px 24px !important;
    margin-bottom: 20px !important;
    background-color: #2c3e50 !important;
    border-radius: 8px 8px 0 0 !important;
}

#applyModal .mdlTitWrap p {
    font-size: 18px !important;
    font-weight: 600 !important;
    color: #fffafa !important;
    margin: 0 !important;
}

#applyModal .mdlClose.icon-x {
    color: #ffffff !important;
    font-size: 18px !important;
    cursor: pointer !important;
    background: none !important;
    border: none !important;
    padding: 0 !important;
    width: 24px !important;
    height: 24px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

#applyModal .modal-body {
    padding: 20px 24px !important;
}

#applyModal .form-group {
    margin-bottom: 20px !important;
    border-bottom: 1px solid #f0f2f5 !important;
    padding-bottom: 20px !important;
}

#applyModal .form-group:last-child {
    border-bottom: none !important;
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
}

#applyModal .form-group label {
    display: block !important;
    margin-bottom: 8px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    color: #000000 !important;
}

#applyModal .form-input {
    width: 100% !important;
    padding: 10px 12px !important;
    border: 1px solid #d1d5db !important;
    border-radius: 4px !important;
    font-size: 14px !important;
    color: #000000 !important;
    background-color: #ffffff !important;
    box-sizing: border-box !important;
}

#applyModal .form-input:focus {
    outline: none !important;
    border-color: #2563eb !important;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1) !important;
}

#applyModal .modal-footer {
    border-top: none !important;
    padding: 0 24px 24px 24px !important;
    text-align: right !important;
}

#applyModal .btn-apply {
    background: #2563eb !important;
    color: #ffffff !important;
    border: 1px solid #1d4ed8 !important;
    padding: 10px 20px !important;
    border-radius: 6px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    margin-right: 12px !important;
    transition: all 0.2s ease !important;
}

#applyModal .btn-apply:hover {
    background: #1d4ed8 !important;
}

#applyModal .btn-close-modal {
    background: #6c757d;
    color: white;
    border: none;
    padding: 10px 10px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 70px;
}

#applyModal .btn-close-modal:hover {
    color: #ffffff !important;
}

/* 모달 배경 개선 - 달력과 구분이 잘 되도록 회색빛 배경 적용 */
#dlg_diary.modal {
    background-color: rgba(128, 128, 128, 0.3) !important;
}

#dlg_diary .modal-backdrop {
    background-color: rgba(128, 128, 128, 0.6) !important;
}

#dlg_diary .modal-dialog {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3) !important;
}

/* 모달이 열렸을 때 배경을 더 어둡게 */
#dlg_diary.modal.show {
    background-color: rgba(64, 64, 64, 0.4) !important;
}

#dlg_diary.modal.show .modal-backdrop {
    background-color: rgba(64, 64, 64, 0.7) !important;
}

/* ===== 모달 높이 문제 해결 ===== */
/* Bootstrap의 calc(100% - var(--bs-modal-margin) * 2) 계산을 오버라이드 */
#dlg_diary .modal-dialog.modal-dialog-centered {
    min-height: auto !important;
    height: auto !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 auto !important;
    position: fixed !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
}

#dlg_diary .modal-dialog.modal-dialog-scrollable {
    height: auto !important;
    max-height: 95vh !important;
}

/* 모달 내용이 적절한 높이를 가지도록 설정 */
#dlg_diary .modal-content {
    max-height: 90vh !important;
    height: auto !important;
}

#dlg_diary .modal-body {
    max-height: 70vh !important;
    overflow-y: auto !important;
}

/* 모바일에서 모달 높이 조정 */
@media (max-width: 768px) {
    #dlg_diary .modal-dialog.modal-dialog-centered {
        margin: 0.5rem auto !important;
        top: 50% !important;
        left: 50% !important;
        transform: translate(-50%, -50%) !important;
    }
    
    #dlg_diary .modal-dialog.modal-dialog-scrollable {
        max-height: 98vh !important;
    }
    
    #dlg_diary .modal-content {
        max-height: 95vh !important;
    }
    
    #dlg_diary .modal-body {
        max-height: 75vh !important;
    }
}