/* 캘린더 스타일 - 코넬플라워 블루 기반 */
.page-header {
    margin-bottom: 1rem;
    text-align: center;
    padding: 1rem 0;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
}

.page-header h2 {
    color: var(--cornflower-blue-primary);
    margin-bottom: 0.25rem;
    font-size: 1.75rem;
    font-weight: 700;
}

.page-header p {
    color: var(--gray-600);
    font-size: 0.95rem;
    font-weight: 500;
}

/* 캘린더 컨트롤 */
.calendar-controls {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    padding: 0.75rem;
    background: var(--white);
    border-radius: 1rem;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--gray-200);
}

.toolbar-filters { 
    display: flex; 
    flex-wrap: wrap; 
    align-items: center; 
    gap: 0.5rem; 
    padding: 0.5rem;
    background: var(--gray-50);
    border-radius: 0.75rem;
    border: 1px solid var(--gray-200);
}

.toolbar-top {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 0.5rem;
    position: relative;
    margin-bottom: 0.5rem;
}

.current-month { 
    text-align: center; 
    margin: 0; 
    font-size: 1.5rem; 
    color: #1f2937; /* 검정색 */
    font-weight: 600;
    cursor: pointer;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.2s ease;
    user-select: none;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
}

.nav-buttons { display: flex; align-items: center; gap: .5rem; }
.toolbar-actions { display: flex; justify-content: end; }

.calendar-nav h3 {
    margin: 0;
    font-size: 1.6rem;
    color: var(--cornflower-blue-primary);
    min-width: 200px;
    text-align: center;
    font-weight: 600;
}

.calendar-nav { display:none; }

/* 좁은 화면에서는 한 줄 레이아웃으로 변경 */
@media (max-width: 768px) {
    .toolbar-top { grid-template-columns: 1fr; }
    .toolbar-actions { justify-content: stretch; }
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.filter-group label {
    font-weight: 500;
    color: var(--gray-700);
    white-space: nowrap;
    font-size: 0.875rem;
}

.filter-group select {
    padding: 0.75rem 1rem;
    border: 2px solid var(--gray-200);
    border-radius: 0.5rem;
    font-size: 0.875rem;
    background: var(--white);
    color: var(--gray-800);
    min-width: 140px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.filter-group select:focus {
    outline: none;
    border-color: var(--cornflower-blue-secondary);
    box-shadow: 0 0 0 3px rgba(106, 130, 224, 0.1);
    transform: translateY(-1px);
}

.filter-group select:hover {
    border-color: var(--cornflower-blue-light);
}

/* 캘린더 컨트롤 */
.calendar-controls {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    padding: 0.75rem;
    background: var(--white);
    border-radius: 1rem;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--gray-200);
}

/* 캘린더 레이아웃 - 범례와 캘린더 나란히 배치 */
.calendar-layout {
    display: flex;
    gap: 1rem;
    align-items: stretch;
}

/* 캘린더 컨테이너 */
.calendar-container {
    background: var(--white);
    border-radius: 1rem;
    box-shadow: var(--shadow-md);
    overflow: hidden;
    margin-bottom: 1rem;
    padding: 1rem;
    border: 1px solid var(--gray-200);
    flex: 1;
    margin-top: 0;
    display: flex;
    flex-direction: column;
}

/* 통합 범례 - 왼쪽 세로 배열 */
.unified-legend {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    padding: 1rem 0.875rem 0.875rem 0.875rem;
    border: 1px solid #e5e7eb;
    width: 200px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    margin-top: -15px;
    transform: translateY(-15px);
    align-self: stretch;
    min-height: calc(100% + 15px);
}

/* FullCalendar 커스터마이징 - 코넬플라워 블루 기반 */
#calendar {
    font-family: inherit;
    border-radius: 0.75rem;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    flex: 1;
}

.fc {
    --fc-border-color: var(--gray-200);
    --fc-button-bg-color: var(--cornflower-blue-secondary);
    --fc-button-border-color: var(--cornflower-blue-secondary);
    --fc-button-hover-bg-color: var(--cornflower-blue-primary);
    --fc-button-hover-border-color: var(--cornflower-blue-primary);
    --fc-button-active-bg-color: var(--cornflower-blue-primary);
    --fc-button-active-border-color: var(--cornflower-blue-primary);
    --fc-today-bg-color: var(--cornflower-blue-lightest);
    --fc-highlight-color: rgba(106, 130, 224, 0.1);
}

.fc-toolbar-title {
    color: var(--cornflower-blue-primary) !important;
    font-weight: 600 !important;
    font-size: 1.5rem !important;
}

.fc-daygrid-day-number {
    color: var(--gray-700) !important;
    font-weight: 500 !important;
}

.fc-day-today .fc-daygrid-day-number {
    color: var(--cornflower-blue-primary) !important;
    font-weight: 700 !important;
}

.fc {
    font-size: 14px;
}

.fc-header-toolbar {
    display: none !important; /* 커스텀 헤더 사용 */
}

.fc-daygrid-day {
    min-height: 100px;
}

.fc-daygrid-day-number {
    font-weight: 600;
    padding: 8px;
    font-size: 14px;
}

/* 오늘 날짜 하이라이트 - 배경색 유지, 날짜 번호 굵기 제거 */
.fc-day-today {
    background-color: #fff3cd !important;
}

.fc-day-today .fc-daygrid-day-number {
    background-color: transparent;
    color: inherit;
    border-radius: 0;
    width: auto;
    height: auto;
    display: inline;
    align-items: normal;
    justify-content: normal;
    font-weight: 600; /* 일반 날짜와 동일 굵기 */
}

.fc-event {
    border: 2px solid transparent; /* 테두리 두께 유지, 색상은 JS에서 설정 */
    border-radius: 4px !important;
    padding: 2px 6px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    margin: 1px 0 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
}

.fc-event:hover {
    transform: scale(1.02) !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2) !important;
}

/* 연차 상태별 스타일 */
.fc-event.leave-pending {
    border-style: dashed !important; /* 점선 */
    opacity: 0.95 !important;
    font-style: italic !important;
}

.fc-event.leave-approved {
    border-style: solid !important; /* 실선 */
    opacity: 1 !important;
    font-style: normal !important;
}

.fc-event-title {
    font-weight: 500 !important;
}


/* 버튼 기본 스타일 */
.btn {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.btn:before {
    display: none;
}

.btn:hover:before {
    display: none;
}

.btn-secondary {
    background: #f8f9fa;
    color: #495057;
    border: 1px solid #dee2e6;
}

.btn-secondary:hover {
    background: #e9ecef;
    color: #343a40;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.btn-primary {
    background: #6A82E0;
    color: white;
    border: none;
    box-shadow: 0 2px 4px rgba(106, 130, 224, 0.2);
}

.btn-primary:hover {
    background: #5a6fd8;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(106, 130, 224, 0.3);
}

.btn-success {
    background: #10b981;
    color: white;
    border: none;
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.2);
}

.btn-success:hover {
    background: #059669;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(16, 185, 129, 0.3);
}

/* 오늘 버튼 특별 스타일 */
#todayBtn {
    background: #6A82E0;
    color: white;
    border: none;
    box-shadow: 0 2px 4px rgba(106, 130, 224, 0.2);
    font-weight: 600;
    letter-spacing: 0.5px;
}

#todayBtn:hover {
    background: #5a6fd8;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(106, 130, 224, 0.3);
}

#todayBtn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(106, 130, 224, 0.2);
}

#todayBtn i {
    font-size: 1rem;
    margin-right: 0.25rem;
}

/* 네비게이션 버튼들 개선 */
#prevMonth, #nextMonth {
    background: #f8f9fa;
    color: #495057;
    border: 1px solid #dee2e6;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    transition: all 0.2s ease;
}

#prevMonth:hover, #nextMonth:hover {
    background: #e9ecef;
    color: #343a40;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

#prevMonth:active, #nextMonth:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

/* 연차 신청 버튼 개선 */
#addLeaveBtn {
    background: #10b981;
    color: white;
    border: none;
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.2);
    font-weight: 600;
    letter-spacing: 0.3px;
}

#addLeaveBtn:hover {
    background: #059669;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(16, 185, 129, 0.3);
}

#addLeaveBtn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.2);
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
}

/* 요일 헤더 */
.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    background: rgb(96, 131, 222);
    color: white;
    grid-column: 1 / -1;
}

.weekday-header {
    padding: 1rem;
    text-align: center;
    font-weight: 600;
    font-size: 0.9rem;
}

/* 날짜 셀 */
.calendar-day {
    min-height: 100px;
    border-right: 1px solid #e0e0e0;
    border-bottom: 1px solid #e0e0e0;
    border-top: 1px solid #e0e0e0;
    border-left: 1px solid #e0e0e0;
    padding: 0.5rem;
    position: relative;
    background: white;
    transition: background-color 0.2s ease;
}

.calendar-day:hover {
    background: #f8f9ff;
}

.calendar-day.other-month {
    background: #f8f9fa;
    color: #999;
}

/* 커스텀 캘린더 오늘 날짜 - 배경색 유지, 날짜 번호 굵기 제거 */
.calendar-day.today {
    background: #e3f2fd;
    border: 2px solid #6083de;
}

.calendar-day.today .day-number {
    background: transparent;
    color: inherit;
    border-radius: 0;
    font-weight: normal; /* 굵기 제거 */
}

.day-number {
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

/* 연차 이벤트 */
.leave-event {
    margin-bottom: 2px;
    padding: 2px 4px;
    border-radius: 3px;
    font-size: 0.75rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    position: relative;
}

.leave-event:hover {
    transform: scale(1.02);
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.leave-event.annual-leave {
    background: rgba(96, 131, 222, 0.1);
    color: #6083de;
    border-left: 3px solid #6083de;
}

.leave-event.welfare-leave {
    background: rgba(76, 175, 80, 0.1);
    color: #388e3c;
    border-left: 3px solid #388e3c;
}

.leave-event.pending {
    opacity: 0.7;
    border-style: dashed;
}

.leave-event.approved {
    opacity: 1;
    border-style: solid;
}

/* 연결된 연차 막대 */
.leave-event.multi-day {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    height: 20px;
    z-index: 2;
}

.leave-event.multi-day.start {
    left: 0;
    border-top-left-radius: 10px;
    border-bottom-left-radius: 10px;
}

.leave-event.multi-day.middle {
    left: 0;
    right: 0;
    border-radius: 0;
}

.leave-event.multi-day.end {
    right: 0;
    border-top-right-radius: 10px;
    border-bottom-right-radius: 10px;
}

/* 더보기 인디케이터 */
.more-indicator {
    background: #ff5722;
    color: white;
    padding: 2px 6px;
    border-radius: 10px;
    font-size: 0.7rem;
    font-weight: 600;
    cursor: pointer;
    margin-top: 2px;
    text-align: center;
    transition: all 0.2s ease;
}

.more-indicator:hover {
    background: #e64a19;
    transform: scale(1.05);
}

/* 통합 범례 - 왼쪽 세로 배열 */
.unified-legend {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    padding: 1rem 0.875rem 0.875rem 0.875rem;
    border: 1px solid #e5e7eb;
    width: 200px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    margin-top: -15px;
    transform: translateY(-15px);
}

.unified-legend h4 {
    margin: 0 0 0.875rem 0;
    color: #1f2937;
    font-size: 0.95rem;
    text-align: left;
    font-weight: 700;
    letter-spacing: -0.01em;
    flex-shrink: 0;
}

.legend-sections-vertical {
    display: flex;
    flex-direction: column;
    gap: 0;
    flex: 1;
}

.legend-section {
    max-width: 100%;
    border-bottom: none;
    padding-bottom: 0;
    display: flex;
    flex-direction: column;
}

.legend-section:first-child {
    flex: 0;
    flex-shrink: 0;
}

.legend-section:not(:first-child) {
    flex: 1;
}

.legend-section:not(:last-child) {
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 1rem;
    margin-bottom: 0;
}

.legend-section h5 {
    margin: 0 0 0.625rem 0;
    color: #374151;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    text-transform: none;
    border-bottom: none;
    padding-bottom: 0;
    display: block;
    flex-shrink: 0;
}

.legend-items {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex: 1;
}

.legend-item {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.625rem;
    padding: 0;
    border-radius: 0;
    background: transparent;
    border: none;
}

.legend-color {
    width: 18px;
    height: 18px;
    border-radius: 4px;
    border: none;
    margin-right: 0;
    flex-shrink: 0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.15);
    transition: all 0.2s ease;
}

.legend-color:hover {
    transform: scale(1.1);
    box-shadow: 0 2px 6px rgba(0,0,0,0.25);
}

.legend-label {
    font-size: 0.8rem;
    color: #374151;
    font-weight: 600;
    letter-spacing: -0.01em;
}

/* 연차 상태 범례 박스 스타일 - 자연스러운 버전 */
.legend-status-box {
    display: inline-block;
    padding: 0.35rem 0.625rem;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-right: 0;
    border: 1.5px solid;
    min-width: 55px;
    text-align: center;
    transition: all 0.2s ease;
}

.legend-status-box:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.legend-status-box.approved {
    background: #f0fdf4;
    color: #166534;
    border-color: #86efac;
}

.legend-status-box.pending {
    background: #fffbeb;
    color: #854d0e;
    border-color: #fde047;
    border-style: dashed;
}

.legend-description {
    font-size: 0.75rem;
    color: #6b7280;
    font-weight: 500;
    margin-top: 0;
    display: inline-block;
}

/* 모달 스타일 */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    backdrop-filter: blur(4px);
    overflow-y: auto;
    padding: 20px 0;
    box-sizing: border-box;
}

/* 연차 신청 모달 폼 스타일 */
.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #333;
}

.form-group input,
.form-group select,
.form-group textarea,
.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background-color: #fff;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus,
.form-control:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    outline: none;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 1.5rem;
    padding-top: 1rem;
}

.form-group input:disabled {
    background-color: #f8f9fa;
    color: #6c757d;
    cursor: not-allowed;
    opacity: 0.6;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #e0e0e0;
}

/* 모달용 버튼 스타일 (기존 스타일 유지) */
.modal .btn {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

.modal .btn-secondary {
    background-color: #6c757d;
    color: white;
}

.modal .btn-secondary:hover {
    background-color: #5a6268;
}

.modal .btn-primary {
    background-color: #667eea;
    color: white;
}

.modal .btn-primary:hover {
    background-color: #5a6fd8;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #999;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-btn:hover {
    color: #333;
}

.modal-content {
    background-color: #fff;
    margin: 0 auto;
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    min-height: 200px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    animation: modalSlideIn 0.3s ease;
    display: flex;
    flex-direction: column;
    position: relative;
}

/* Windows 스타일 캘린더 모달 */
.windows-calendar-modal {
    max-width: 320px !important;
    padding: 0 !important;
}

.windows-calendar-header {
    padding: 0.5rem;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    justify-content: flex-end;
}

.windows-calendar-body {
    padding: 1rem;
}

.windows-calendar-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    padding: 0.5rem 0;
}

.calendar-nav-btn {
    background: transparent;
    border: none;
    color: #6b7280;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.calendar-nav-btn:hover {
    background: #F5F5F5;
    color: #374151;
}

.calendar-year-range {
    font-size: 0.9rem;
    font-weight: 600;
    color: #374151;
}

.calendar-year-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.calendar-year-item {
    padding: 0.5rem;
    text-align: center;
    border-radius: 50%;
    cursor: pointer;
    font-size: 0.9rem;
    color: #374151;
    transition: all 0.2s ease;
    user-select: none;
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.calendar-year-item:hover {
    background: #F5F5F5;
}

.calendar-year-item.other-decade {
    color: #9ca3af;
}

.calendar-year-item.selected {
    background: #2563eb;
    color: #ffffff;
    font-weight: 600;
}

.calendar-month-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
}

.calendar-month-item {
    padding: 0.75rem;
    text-align: center;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    color: #374151;
    transition: all 0.2s ease;
    user-select: none;
    border: 1px solid transparent;
}

.calendar-month-item:hover {
    background: #F5F5F5;
    border-color: #d1d5db;
}

.calendar-month-item.selected {
    background: #2563eb;
    color: #ffffff;
    font-weight: 600;
    border-color: #2563eb;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 1.5rem 0;
    border-bottom: 1px solid #e0e0e0;
    margin-bottom: 1.5rem;
    flex-shrink: 0;
}

.modal-header h3 {
    margin: 0;
    color: #333;
    font-size: 1.25rem;
}

.close {
    color: #999;
    font-size: 1.5rem;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.2s ease;
}

.close:hover {
    color: #333;
}

.modal-body {
    padding: 0 1.5rem 1.5rem;
    flex: 1;
    overflow-y: visible;
    max-height: none;
}

/* 연차 상세 정보 */
.leave-detail-item {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1rem;
    border-left: 4px solid #667eea;
}

.leave-detail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.leave-detail-title {
    font-weight: 600;
    color: #333;
    font-size: 1rem;
}

.leave-detail-status {
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
}

.leave-detail-status.approved {
    background: #d4edda;
    color: #155724;
}

.leave-detail-status.pending {
    background: #fff3cd;
    color: #856404;
}

.leave-detail-status.rejected {
    background: #f8d7da;
    color: #721c24;
}

.leave-detail-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #666;
}

.leave-detail-info span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.leave-detail-info i {
    width: 12px;
    color: #999;
}

/* 통합 범례 - 자연스러운 스타일 개선 */
.unified-legend {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    padding: 1.25rem 1.5rem;
    border: 1px solid #e5e7eb;
    margin-top: 1rem;
}

.unified-legend h4 {
    margin: 0 0 1.25rem 0;
    color: #1f2937;
    font-size: 1.1rem;
    text-align: center;
    font-weight: 700;
    letter-spacing: -0.01em;
}


/* 반응형 디자인 */
@media (max-width: 768px) {
    .calendar-controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .calendar-layout {
        flex-direction: column;
    }
    
    .unified-legend {
        width: 100%;
        margin-bottom: 1rem;
    }
    
    .calendar-nav {
        justify-content: center;
    }
    
    .calendar-filters {
        justify-content: center;
    }
    
    .calendar-day {
        min-height: 80px;
        padding: 0.25rem;
    }
    
    .leave-event {
        font-size: 0.7rem;
        padding: 1px 3px;
    }
}

@media (max-width: 480px) {
    .calendar-day {
        min-height: 60px;
    }
    
    .day-number {
        font-size: 0.8rem;
    }
    
    .leave-event {
        font-size: 0.65rem;
    }
    
    .more-indicator {
        font-size: 0.65rem;
        padding: 1px 4px;
    }
}

/* ========================================
   법정공휴일 스타일
   ======================================== */
.holiday-event {
    background-color: #fee2e2 !important;
    border-color: #ef4444 !important;
    color: #dc2626 !important;
    font-weight: 600 !important;
    cursor: default !important;
}

.holiday-event .fc-event-title {
    color: #dc2626 !important;
}

.holiday-event:hover {
    background-color: #fecaca !important;
}

/* FullCalendar 공휴일 배경 */
.fc-day-holiday {
    background-color: #fef2f2 !important;
}

/* 공휴일 이벤트 텍스트 */
.fc-event.holiday-event .fc-event-main {
    color: #dc2626 !important;
}

/* 나의 연차 필터 체크박스 스타일 */
.my-leave-filter {
    margin-left: auto;
}

.my-leave-filter .checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}

.my-leave-filter .checkbox-label:hover {
    background: #f9fafb;
    border-color: #6083de;
}

.my-leave-filter input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #6083de;
}

.my-leave-filter .checkbox-text {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
    color: #374151;
    font-size: 0.95rem;
}

.my-leave-filter .checkbox-text i {
    color: #6083de;
    font-size: 1rem;
}

/* 체크박스 활성화 시 */
.my-leave-filter input[type="checkbox"]:checked + .checkbox-text {
    color: #6083de;
    font-weight: 600;
}

.my-leave-filter:has(input[type="checkbox"]:checked) .checkbox-label {
    background: #eff6ff;
    border-color: #6083de;
}

/* 반응형 - 좁은 화면에서는 전체 너비 */
@media (max-width: 768px) {
    .my-leave-filter {
        margin-left: 0;
        width: 100%;
    }
    
    .my-leave-filter .checkbox-label {
        width: 100%;
        justify-content: center;
    }
}
