@charset "UTF-8";

/* =========================================================================
   [1. 전역 기본 세팅] 파일 관리자 특유의 단정한 배경 및 텍스트 톤
   ========================================================================= */
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  margin: 0;
  padding: 0;
  background-color: #f4f5f7 !important;
  color: #333333 !important;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* =========================================================================
   [2. 상단 탑 바 & 좌측 사이드바 레이아웃] 데스크톱 기본 규격
   ========================================================================= */
.top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 24px;
  background-color: #f4f5f7;
  border-bottom: 1px solid #b4c2d3;
  font-size: 12px;
  box-sizing: border-box;
}
.top-bar a {
  text-decoration: none;
  padding: 4px 12px;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  color: #333333;
  font-weight: bold;
}
.top-bar a:hover {
  background-color: #f1f5f9;
}

/* 데스크톱 전용 모바일 메뉴 열기 버튼 (기본 숨김) */
.mobile-menu-toggle {
  display: none;
}

.main-container {
  display: flex;
  flex: 1;
  width: 100%;
  box-sizing: border-box;
}

.side-nav {
  width: 240px;
  background-color: #ffffff;
  border-right: 1px solid #b4c2d3;
  padding: 16px;
  box-sizing: border-box;
  flex-shrink: 0;
}
.nav-title {
  font-size: 11px;
  font-weight: bold;
  color: #94a3b8;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.nav-item {
  display: block;
  padding: 8px 12px;
  font-size: 13px;
  color: #475569;
  text-decoration: none;
  border-radius: 4px;
  margin-bottom: 2px;
}
.nav-item.active {
  background-color: #e8f1fc;
  color: #2b4266;
  font-weight: bold;
}
.nav-item:hover:not(.active) {
  background-color: #f1f5f9;
}

/* =========================================================================
   [3. 본문 콘텐츠 & 입력 폼 서식] 
   ========================================================================= */
.content-area {
  flex: 1;
  padding: 24px;
  background-color: #f8fafc;
  box-sizing: border-box;
  width: 100%;
}

.main-card {
  background-color: #ffffff !important;
  border: 1px solid #b4c2d3 !important;
  border-radius: 4px !important;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06) !important;
  padding: 20px !important;
  box-sizing: border-box;
}

.card-hover {
  background-color: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 4px !important;
  box-shadow: none;
  transition: all 0.15s ease-in-out;
}
.card-hover:hover {
  background-color: #e8f1fc !important;
  border-color: #a3c4f7 !important;
}

.input-group {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}
.input-group input {
  flex: 1;
  border: 1px solid #cbd5e1 !important;
  border-radius: 4px !important;
  padding: 8px 12px !important;
  font-size: 14px !important;
  background-color: #ffffff !important;
  outline: none;
}
.input-group button {
  background: linear-gradient(to bottom, #4f73a5 0%, #35537d 100%) !important;
  color: #ffffff !important;
  border: 1px solid #2b4266 !important;
  border-radius: 4px !important;
  font-weight: 600 !important;
  font-size: 14px !important;
  padding: 8px 16px !important;
  cursor: pointer;
}

/* =========================================================================
   [4. 테이블 및 리포트 서식]
   ========================================================================= */
table {
  background-color: #ffffff !important;
  border: 1px solid #b4c2d3 !important;
  border-collapse: collapse !important;
  width: 100% !important;
}
table thead tr {
  background: linear-gradient(to bottom, #f3f7fd 0%, #def0ff 100%) !important;
  border-bottom: 2px solid #b4c2d3 !important;
}
table th {
  color: #2b4266 !important;
  font-size: 14px !important;
  font-weight: bold !important;
  padding: 10px 16px !important;
}
table td {
  padding: 8px 16px !important;
  font-size: 13px !important;
  border-bottom: 1px solid #e2e8f0 !important;
}
.report-line {
  display: block;
  border-bottom: 1px solid #f1f5f9;
  padding: 4px 16px;
}
.line-text {
  white-space: pre-wrap;
  word-break: break-all;
}

.mono {
  font-family: 'JetBrains Mono', monospace;
  color: #2b4266 !important;
}
.footer-area {
  text-align: center;
  padding: 16px;
  font-size: 11px;
  color: #94a3b8;
  border-top: 1px solid #b4c2d3;
  background-color: #ffffff;
}

/* =========================================================================
   [5. ★ 모바일 반응형 + 사이드바 기본 접힘(토글) 제어 엔진]
   ========================================================================= */
@media (max-w: 768px) {
  /* 1. 모바일 탑 바 패딩 조정 및 토글 버튼 강제 노출 */
  .top-bar {
    padding: 10px 16px;
    gap: 12px;
  }
  
  /* 정통 파일 관리자 메뉴 모양(☰)의 부드러운 화이트 토글 버튼 */
  .mobile-menu-toggle {
    display: inline-block !important;
    padding: 4px 10px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    color: #2b4266;
    font-weight: bold;
    cursor: pointer;
    font-size: 12px;
    user-select: none;
  }

  .main-container {
    flex-direction: column; /* 세로 정렬 */
    position: relative;
  }

  /* 2. [핵심 요청]: 모바일 진입 시 사이드바가 기본적으로 보이지 않도록 강제 숨김(display: none) 처리 */
  .side-nav {
    display: none; 
    width: 100%;
    border-right: none;
    border-bottom: 1px solid #b4c2d3;
    padding: 12px;
    background-color: #ffffff;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  }

  /* 3. 자바스크립트 토글용 클래스 활성화 규칙 (상단에서 버튼을 누를 때만 열림) */
  .side-nav.show-menu {
    display: block !important;
  }
  
  .nav-title {
    margin-bottom: 6px;
    padding-left: 4px;
  }
  .nav-item {
    margin-bottom: 4px;
    padding: 8px 12px;
  }

  /* 본문 영역 마진 및 배치 조율 */
  .content-area {
    padding: 16px;
  }
  .input-group {
    flex-direction: column;
  }
  .input-group button {
    width: 100%;
  }
  table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }
}
