/* ===================================================================
   포항양덕초등학교 온라인 교무실 - 모던 디자인 시스템 & 스타일시트
   Apple & Toss 감성의 정제된 UI/UX, 고대비 가독성, 글래스모피즘
   =================================================================== */

@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard/dist/web/static/pretendard.css');

:root {
  /* 메인 브랜드 컬러 (포항양덕초 - 깊고 신뢰감 있는 코발트 & 에메랄드) */
  --primary: #2563EB;
  --primary-hover: #1D4ED8;
  --primary-light: #EFF6FF;
  --primary-dark: #1E3A8A;
  
  --accent: #10B981;
  --accent-light: #ECFDF5;
  --warning: #F59E0B;
  --warning-light: #FEF3C7;
  --danger: #EF4444;
  --danger-light: #FEE2E2;

  /* 중립색 (Neutral Grayscale) */
  --bg-page: #F8FAFC;
  --bg-card: #FFFFFF;
  --bg-subtle: #F1F5F9;
  
  --text-main: #0F172A;
  --text-secondary: #475569;
  --text-muted: #94A3B8;
  
  --border-light: #E2E8F0;
  --border-focus: #93C5FD;
  
  /* 그림자 & 블러 */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 10px 25px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -4px rgba(15, 23, 42, 0.04);
  --shadow-hover: 0 14px 28px -4px rgba(37, 99, 235, 0.12), 0 6px 12px -3px rgba(0, 0, 0, 0.04);

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-pill: 9999px;

  --transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  overflow-x: hidden;
  width: 100%;
}

body {
  font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, Roboto, sans-serif;
  background-color: var(--bg-page);
  color: var(--text-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  word-break: keep-all;
}

/* 통일된 글로벌 레이아웃 컨테이너 (좌우 간격 완벽 일치) */
.layout-container,
.header-container,
.notice-container,
.widgets-container,
.nav-tabs-container,
.main-content,
.footer-container {
  max-width: 1560px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
  width: 100%;
}

/* 1. 상단 글로벌 알림 배너 */
.top-notice-banner {
  background: linear-gradient(90deg, #1E3A8A, #2563EB);
  color: #FFFFFF;
  padding: 8px 0;
  font-size: 0.875rem;
  font-weight: 500;
  position: relative;
  z-index: 50;
  width: 100%;
}

.notice-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.notice-content {
  display: flex;
  align-items: center;
  gap: 10px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.notice-badge {
  background-color: rgba(255, 255, 255, 0.25);
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.notice-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

/* 구글 로그인 & 인증 상태 박스 */
.guest-mode-box {
  display: flex;
  align-items: center;
  gap: 8px;
}

.guest-pill {
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #FFFFFF;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  font-size: 0.78rem;
  font-weight: 600;
}

.btn-google-login {
  background: #FFFFFF;
  border: none;
  color: #1E3A8A;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.btn-google-login:hover {
  background: #F1F5F9;
  transform: translateY(-1px);
}

.user-profile-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.15);
  padding: 3px 10px 3px 4px;
  border-radius: var(--radius-pill);
}

.user-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1.5px solid #FFFFFF;
}

.user-info-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
  font-size: 0.75rem;
}

.btn-auth-logout {
  background: none;
  border: none;
  color: #FED7AA;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  margin-left: 6px;
}

.btn-auth-logout:hover {
  text-decoration: underline;
}

/* 2. 메인 헤더 & 학교 브랜딩 */
.site-header {
  background-color: #FFFFFF;
  border-bottom: 1px solid var(--border-light);
  position: sticky;
  top: 0;
  z-index: 40;
  box-shadow: var(--shadow-sm);
}

.header-container {
  max-width: 1560px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand-wrapper {
  display: flex;
  align-items: center;
  gap: 14px;
}

.school-emblem {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #2563EB, #1D4ED8);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #FFFFFF;
  font-size: 1.5rem;
  font-weight: 800;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.brand-text h1 {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.5px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.year-tag {
  background-color: var(--primary-light);
  color: var(--primary);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
}

.brand-text p {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

/* 헤더 검색창 */
.header-search-box {
  flex: 1;
  max-width: 420px;
  position: relative;
}

.search-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.search-input-wrapper i {
  position: absolute;
  left: 14px;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.header-search-input {
  width: 100%;
  padding: 10px 16px 10px 40px;
  background-color: var(--bg-subtle);
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  font-size: 0.875rem;
  color: var(--text-main);
  transition: var(--transition);
}

.header-search-input:focus {
  outline: none;
  background-color: #FFFFFF;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.header-right-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  text-align: right;
}

.live-clock-box {
  display: flex;
  flex-direction: column;
}

.clock-date {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.clock-time {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  font-variant-numeric: tabular-nums;
}

/* 3. 오늘의 퀵 알림 & 요약 위젯 바 (상단) */
.quick-widgets-section {
  background: #FFFFFF;
  border-bottom: 1px solid var(--border-light);
  padding: 12px 0 10px;
}

.widgets-container {
  max-width: 1560px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.widgets-left-group {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  width: 100%;
}

@media (max-width: 1200px) {
  .widgets-left-group {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .widgets-left-group {
    grid-template-columns: 1fr;
  }
}

.widget-card {
  background: var(--bg-subtle);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 9px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  transition: var(--transition);
}

.widget-card:hover {
  background: #FFFFFF;
  border-color: var(--primary);
  box-shadow: var(--shadow-sm);
}

.widget-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.widget-icon.calendar { background: #DBEAFE; color: #1E40AF; }
.widget-icon.lunch { background: #FEF3C7; color: #B45309; }
.widget-icon.period { background: #D1FAE5; color: #065F46; }

.widget-info {
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.widget-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
}

.widget-val {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.today-event-chip {
  display: inline-block;
  color: var(--primary);
  font-weight: 700;
}

.quick-tools-launcher {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding-top: 6px;
  border-top: 1px dashed var(--border-light);
  width: 100%;
}

.btn-tool-quick {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  padding: 7px 14px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition);
  white-space: nowrap;
}

.btn-tool-quick:hover {
  color: var(--primary);
  border-color: var(--primary);
  background: var(--primary-light);
  transform: translateY(-1px);
}

/* 4. 메인 네비게이션 탭 바 */
.nav-tabs-wrapper {
  background: #FFFFFF;
  border-bottom: 1px solid var(--border-light);
  position: relative;
  z-index: 20;
}

.nav-tabs-container {
  max-width: 1560px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
}

.nav-tabs-container::-webkit-scrollbar {
  display: none;
}

.nav-tab-btn {
  background: none;
  border: none;
  padding: 14px 18px;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 3px solid transparent;
  transition: var(--transition);
  white-space: nowrap;
}

.nav-tab-btn i {
  font-size: 1.05rem;
}

.nav-tab-btn:hover {
  color: var(--primary);
}

.nav-tab-btn.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.tab-lock-icon {
  font-size: 0.75rem;
  color: #94A3B8;
  margin-left: 2px;
}

/* 5. 메인 레이아웃 본문 */
.main-content {
  max-width: 1560px;
  margin: 0 auto;
  padding: 24px;
}

.tab-pane {
  display: none;
  animation: fadeIn 0.25s ease-in-out;
}

.tab-pane.active {
  display: block;
}

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

/* 홈 대시보드 그리드 (캘린더 + 자료실) */
.home-layout-grid {
  display: grid;
  grid-template-columns: 1.18fr 0.82fr;
  gap: 24px;
  align-items: start;
}

@media (max-width: 1200px) {
  .home-layout-grid {
    grid-template-columns: 1fr;
  }
}

.home-layout-grid > * {
  min-width: 0;
  overflow: hidden;
}

/* 카드 공통 스타일 */
.content-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  min-width: 0;
  overflow: hidden;
}

.card-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
  gap: 12px;
  flex-wrap: wrap;
}

.card-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 10px;
}

.card-title i {
  color: var(--primary);
}

/* 학사일정 뷰 전환 탭 (달력형 vs 3월 교육계획 표형) */
.cal-view-switcher {
  display: flex;
  background: var(--bg-subtle);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  padding: 3px;
  gap: 4px;
}

.cal-view-btn {
  background: transparent;
  border: none;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition);
}

.cal-view-btn.active {
  background: #FFFFFF;
  color: var(--primary);
  box-shadow: var(--shadow-sm);
}

.cal-view-btn:hover:not(.active) {
  color: var(--text-main);
}

/* 인터랙티브 캘린더 스타일 */
.calendar-widget {
  background: #FFFFFF;
}

.cal-header-nav {
  display: flex;
  align-items: center;
  gap: 10px;
}

.cal-nav-btn {
  background: var(--bg-subtle);
  border: 1px solid var(--border-light);
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.cal-nav-btn:hover {
  background: var(--primary-light);
  color: var(--primary);
}

/* 요일 헤더: 날짜 그리드와 100% 동일한 repeat(7, minmax(0, 1fr)) 및 gap: 4px */
.calendar-grid-weekdays {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
  text-align: center;
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--text-secondary);
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-light);
  width: 100%;
  box-sizing: border-box;
}

.calendar-grid-weekdays div {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 2px 0;
}

.calendar-grid-weekdays div:first-child { color: #EF4444; }
.calendar-grid-weekdays div:last-child { color: #2563EB; }

/* 날짜 그리드 */
.calendar-grid-days {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
  margin-top: 8px;
  width: 100%;
  box-sizing: border-box;
}

.cal-day {
  min-height: 84px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 6px;
  background: #FFFFFF;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  overflow: hidden;
  transition: var(--transition);
  box-sizing: border-box;
}

.cal-day:hover {
  border-color: var(--primary);
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.18);
  transform: translateY(-2px);
  z-index: 2;
}

.cal-day.prev-month {
  background: #F8FAFC;
  opacity: 0.4;
  pointer-events: none;
}

.cal-day.today {
  background: #EFF6FF;
  border: 1.5px solid var(--primary);
}

.cal-date-number {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1;
}

.cal-events-list {
  display: flex;
  flex-direction: column;
  gap: 3px;
  overflow: hidden;
  min-width: 0;
  width: 100%;
}

.cal-event-pill {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  cursor: pointer;
  min-width: 0;
  max-width: 100%;
  display: block;
  box-sizing: border-box;
}

.cal-event-pill.academic {
  background: #DBEAFE;
  color: #1E40AF;
  border-left: 3px solid #2563EB;
}

.cal-event-pill.department {
  background: #EDE9FE;
  color: #6D28D9;
  border-left: 3px solid #8B5CF6;
}

.cal-event-pill.holiday {
  background: #FEE2E2;
  color: #B91C1C;
  border-left: 3px solid #EF4444;
}

/* 2026학년도 월중 교육계획 표 뷰어 (공문 1:1 완벽 양식) */
.monthly-plan-table-container {
  display: none;
  margin-top: 12px;
  overflow: hidden;
}

.monthly-plan-table-container.active {
  display: block;
}

.monthly-plan-banner {
  background: linear-gradient(135deg, #1E3A8A, #2563EB);
  color: #FFFFFF;
  padding: 14px 18px;
  border-radius: var(--radius-md);
  margin-bottom: 14px;
}

.monthly-plan-banner-title {
  font-size: 1.05rem;
  font-weight: 800;
  margin-bottom: 6px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.monthly-plan-goals {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 4px 14px;
  font-size: 0.78rem;
  color: #E0E7FF;
}

@media (max-width: 768px) {
  .monthly-plan-goals {
    grid-template-columns: 1fr;
  }
}

.plan-table-tools {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.plan-search-input {
  padding: 6px 12px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  font-size: 0.8rem;
  width: 220px;
  outline: none;
}

.plan-search-input:focus {
  border-color: var(--primary);
}

.monthly-plan-table-wrapper {
  max-height: 480px;
  overflow-y: auto;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
}

.monthly-plan-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  text-align: left;
}

.monthly-plan-table th {
  background: #F1F5F9;
  color: #334155;
  font-weight: 800;
  padding: 8px 10px;
  border-bottom: 2px solid var(--border-light);
  position: sticky;
  top: 0;
  z-index: 5;
  white-space: nowrap;
}

.monthly-plan-table td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--border-light);
  vertical-align: top;
  line-height: 1.45;
}

.monthly-plan-table tr:hover td {
  background: #F8FAFC;
}

.monthly-plan-table .td-day {
  text-align: center;
  font-weight: 800;
  width: 36px;
}

.monthly-plan-table .td-dow {
  text-align: center;
  font-weight: 700;
  width: 36px;
}

.monthly-plan-table .td-dow.sun { color: #EF4444; }
.monthly-plan-table .td-dow.sat { color: #2563EB; }

.monthly-plan-table .td-event {
  font-weight: 700;
  color: #1E40AF;
  width: 130px;
}

.monthly-plan-table .td-plan {
  color: #1E293B;
  white-space: pre-line;
}

.monthly-plan-table .td-manager {
  color: var(--text-secondary);
  font-size: 0.78rem;
  width: 110px;
  white-space: normal;
}

/* 자주 찾는 자료 및 서식 그리드 (잘림 방지 및 유연한 2열) */
.materials-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.material-card {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  min-width: 0;
  transition: var(--transition);
}

.material-card:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.mat-icon-box {
  width: 40px;
  height: 40px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  flex-shrink: 0;
}

.mat-content {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.mat-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mat-desc {
  font-size: 0.75rem;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 2px;
}

.mat-arrow {
  color: var(--text-muted);
  font-size: 0.8rem;
}

/* 6. 부서 & 학년 드라이브 섹션 */
.section-intro-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.section-intro-bar h2 {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 8px;
}

.drives-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 18px;
  margin-bottom: 32px;
}

.drive-card {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 18px;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
}

.drive-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

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

.drive-icon-badge {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
}

.drive-manager {
  font-size: 0.8rem;
  font-weight: 600;
  background: var(--bg-subtle);
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  color: var(--text-secondary);
}

.drive-name {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 6px;
}

.drive-note {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.4;
  margin-bottom: 16px;
  flex: 1;
}

.drive-actions {
  display: flex;
  gap: 8px;
  border-top: 1px solid var(--border-light);
  padding-top: 12px;
}

.btn-drive-open {
  flex: 1;
  background: var(--bg-subtle);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  font-size: 0.85rem;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: var(--transition);
}

.btn-drive-open:hover {
  background: var(--primary-light);
  border-color: var(--primary);
}

.btn-copy-link {
  background: var(--bg-subtle);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
}

.btn-copy-link:hover {
  color: var(--primary);
  background: #FFFFFF;
}

/* ===================================================================
   하이브리드 이원화 스토리지 (학교 NAS + 구글 드라이브) 스타일
   =================================================================== */
.hybrid-info-banner {
  background: linear-gradient(135deg, #EFF6FF 0%, #EEF2FF 50%, #F5F3FF 100%);
  border: 1px solid #C7D2FE;
  border-radius: var(--radius-lg);
  padding: 18px 22px;
  margin-bottom: 24px;
  box-shadow: 0 4px 14px rgba(79, 70, 229, 0.06);
}

.hybrid-banner-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  flex-wrap: wrap;
  gap: 10px;
}

.hybrid-banner-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #4F46E5;
  color: #FFFFFF;
  font-size: 0.78rem;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  box-shadow: 0 2px 6px rgba(79, 70, 229, 0.25);
}

.hybrid-banner-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

@media (max-width: 768px) {
  .hybrid-banner-grid {
    grid-template-columns: 1fr;
  }
}

.hybrid-banner-card {
  background: #FFFFFF;
  border: 1px solid #E0E7FF;
  border-radius: var(--radius-md);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.hybrid-banner-card.nas {
  border-left: 4px solid #3B82F6;
}

.hybrid-banner-card.gdrive {
  border-left: 4px solid #10B981;
}

.hybrid-card-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--text-main);
}

.hybrid-card-desc {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.45;
}

.hybrid-card-tip {
  font-size: 0.74rem;
  color: #4F46E5;
  background: #EEF2FF;
  padding: 4px 8px;
  border-radius: 6px;
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
}

.hybrid-card-tip code {
  background: #E0E7FF;
  padding: 1px 4px;
  border-radius: 4px;
  font-weight: 700;
  font-family: monospace;
}

/* 하이브리드 드라이브 카드 액션 2행 구조 */
.drive-actions-hybrid {
  display: flex;
  flex-direction: column;
  gap: 7px;
  border-top: 1px solid var(--border-light);
  padding-top: 12px;
}

.drive-row-hybrid {
  display: flex;
  align-items: center;
  gap: 6px;
}

.row-tag {
  font-size: 0.7rem;
  font-weight: 800;
  padding: 4px 7px;
  border-radius: 6px;
  white-space: nowrap;
  min-width: 66px;
  text-align: center;
}

.row-tag.gdrive {
  background: #ECFDF5;
  color: #065F46;
  border: 1px solid #A7F3D0;
}

.row-tag.nas {
  background: #EFF6FF;
  color: #1E40AF;
  border: 1px solid #BFDBFE;
}

.btn-hybrid-open {
  flex: 1;
  background: var(--bg-subtle);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 6px 10px;
  font-size: 0.8rem;
  font-weight: 700;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: var(--transition);
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.btn-hybrid-open:hover {
  transform: translateY(-1px);
}

.btn-hybrid-open.gdrive:hover {
  background: #ECFDF5;
  border-color: #10B981;
  color: #047857;
}

.btn-hybrid-open.nas:hover {
  background: #EFF6FF;
  border-color: #3B82F6;
  color: #1D4ED8;
}

.btn-hybrid-icon {
  background: var(--bg-subtle);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 6px 8px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.btn-hybrid-icon:hover {
  background: #FFFFFF;
  color: var(--primary);
  border-color: var(--primary);
  transform: translateY(-1px);
}

.drive-type-badge.hybrid {
  font-size: 0.65rem;
  background: linear-gradient(135deg, #4F46E5 0%, #3B82F6 100%);
  color: #FFFFFF;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 4px;
  letter-spacing: 0.02em;
}

/* 7. 스마트 자율점검 섹션 */
.checklist-top-stats {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}

.stat-box {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: var(--shadow-sm);
}

.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.stat-icon.rate { background: #DBEAFE; color: #2563EB; }
.stat-icon.done { background: #D1FAE5; color: #10B981; }
.stat-icon.pending { background: #FEF3C7; color: #F59E0B; }
.stat-icon.failed { background: #FEE2E2; color: #EF4444; }

.stat-detail h4 {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 700;
  text-transform: uppercase;
}

.stat-number {
  font-size: 1.65rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.2;
}

.stat-sub {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.progress-bar-container {
  width: 100%;
  height: 6px;
  background: var(--bg-subtle);
  border-radius: var(--radius-pill);
  overflow: hidden;
  margin-top: 6px;
}

.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #2563EB, #10B981);
  border-radius: var(--radius-pill);
  transition: width 0.4s ease;
}

/* 점검 컨트롤 툴바 */
.checklist-toolbar {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 14px 20px;
  margin-bottom: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.toolbar-left, .toolbar-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.term-toggle-group {
  display: flex;
  background: var(--bg-subtle);
  padding: 3px;
  border-radius: var(--radius-sm);
}

.btn-term-toggle {
  background: none;
  border: none;
  padding: 6px 14px;
  font-size: 0.85rem;
  font-weight: 700;
  border-radius: 6px;
  cursor: pointer;
  color: var(--text-secondary);
  transition: var(--transition);
}

.btn-term-toggle.active {
  background: #FFFFFF;
  color: var(--primary);
  box-shadow: var(--shadow-sm);
}

.inspector-select-box {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.custom-select {
  padding: 6px 12px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  background: #FFFFFF;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
  outline: none;
}

.btn-hwpx-download {
  background: #2563EB;
  color: #FFFFFF;
  border: none;
  padding: 10px 18px;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
  transition: var(--transition);
}

.btn-hwpx-download:hover {
  background: #1D4ED8;
  transform: translateY(-1px);
}

.checklist-content-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 20px;
}

/* 좌측 분야별 사이드바 */
.checklist-sidebar {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  height: fit-content;
}

.cat-nav-btn {
  background: none;
  border: none;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  text-align: left;
  transition: var(--transition);
}

.cat-nav-btn:hover {
  background: var(--bg-subtle);
  color: var(--primary);
}

.cat-nav-btn.active {
  background: var(--primary-light);
  color: var(--primary);
  font-weight: 800;
}

.cat-badge {
  background: var(--bg-subtle);
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  font-size: 0.75rem;
  font-weight: 700;
}

.cat-badge.all-done {
  background: #D1FAE5;
  color: #065F46;
}

/* 점검 항목 카드 */
.checklist-items-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.check-item-card {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  transition: var(--transition);
}

.check-item-card:hover {
  border-color: #CBD5E1;
  box-shadow: var(--shadow-sm);
}

.check-item-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.check-cat-pill {
  background: #EFF6FF;
  color: #1E40AF;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
}

.check-target-pill {
  background: var(--bg-subtle);
  color: var(--text-secondary);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
}

.check-item-meta {
  margin-left: auto;
}

.inspector-badge {
  font-size: 0.75rem;
  font-weight: 600;
  color: #059669;
  background: #ECFDF5;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
}

.inspector-badge.empty {
  color: var(--text-muted);
  background: var(--bg-subtle);
}

.check-item-body {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 12px;
}

.check-item-title {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.4;
  flex: 1;
}

.check-action-group {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.check-btn {
  border: 1px solid var(--border-light);
  background: #FFFFFF;
  padding: 8px 14px;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition);
}

.check-btn.btn-done:hover { border-color: #10B981; color: #10B981; }
.check-btn.btn-pending:hover { border-color: #F59E0B; color: #F59E0B; }
.check-btn.btn-failed:hover { border-color: #EF4444; color: #EF4444; }

.check-btn.btn-done.selected {
  background: #10B981;
  border-color: #059669;
  color: #FFFFFF;
}

.check-btn.btn-pending.selected {
  background: #F59E0B;
  border-color: #D97706;
  color: #FFFFFF;
}

.check-btn.btn-failed.selected {
  background: #EF4444;
  border-color: #DC2626;
  color: #FFFFFF;
}

.check-item-footer {
  border-top: 1px dashed var(--border-light);
  padding-top: 10px;
}

.notes-input-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-subtle);
  border-radius: var(--radius-sm);
  padding: 4px 10px;
}

.notes-input-wrapper i {
  color: var(--text-muted);
  font-size: 0.85rem;
}

.check-notes-input {
  flex: 1;
  background: none;
  border: none;
  font-size: 0.85rem;
  color: var(--text-main);
  outline: none;
}

.btn-save-note {
  background: var(--primary);
  color: #FFFFFF;
  border: none;
  width: 24px;
  height: 24px;
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
}

/* 8. 교직원 법정의무연수 섹션 */
.training-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 18px;
}

.training-card {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 18px;
  display: flex;
  flex-direction: column;
}

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

.tr-badge {
  background: #EFF6FF;
  color: #1E40AF;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
}

.tr-deadline {
  font-size: 0.75rem;
  color: #EF4444;
  font-weight: 600;
}

.tr-title {
  font-size: 1rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 14px;
  line-height: 1.4;
}

.tr-progress-wrapper {
  margin-bottom: 16px;
}

.tr-progress-bar {
  height: 8px;
  background: var(--bg-subtle);
  border-radius: var(--radius-pill);
  overflow: hidden;
  margin-bottom: 6px;
}

.tr-progress-fill {
  height: 100%;
  border-radius: var(--radius-pill);
  transition: width 0.4s ease;
}

.tr-progress-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.tr-footer {
  display: flex;
  gap: 8px;
  margin-top: auto;
  border-top: 1px solid var(--border-light);
  padding-top: 12px;
}

.btn-tr-check, .btn-tr-my {
  flex: 1;
  padding: 8px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
}

.btn-tr-check {
  background: var(--bg-subtle);
  border: 1px solid var(--border-light);
  color: var(--text-secondary);
}

.btn-tr-my {
  background: var(--primary-light);
  border: 1px solid var(--border-focus);
  color: var(--primary);
}

.btn-tr-my:hover {
  background: var(--primary);
  color: #FFFFFF;
}

/* 9. 임베드 센터 레이아웃 */
.embed-center-container {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.embed-tabs-bar {
  background: var(--bg-subtle);
  border-bottom: 1px solid var(--border-light);
  padding: 10px 16px;
  display: flex;
  gap: 8px;
  overflow-x: auto;
}

.embed-nav-tab {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 8px 14px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition);
}

.embed-nav-tab:hover {
  color: var(--primary);
  border-color: var(--primary);
}

.embed-nav-tab.active {
  background: var(--primary);
  color: #FFFFFF;
  border-color: var(--primary);
}

.embed-meta-header {
  padding: 12px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-light);
}

.embed-iframe-box {
  width: 100%;
  height: 750px;
  background: #FAFAFA;
}

.embed-iframe-box iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* 10. 관리자 설정 패널 */
.admin-panel-grid {
  display: flex;
  flex-direction: column;
  gap: 24px;
  max-width: 900px;
  margin: 0 auto;
}

.admin-panel-card {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

.admin-panel-card h3 {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.panel-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 18px;
}

.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 6px;
}

.admin-input {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  outline: none;
  transition: var(--transition);
}

.admin-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.admin-drive-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 18px;
}

.admin-drive-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.drive-label {
  width: 140px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-secondary);
}

.btn-primary {
  background: var(--primary);
  color: #FFFFFF;
  border: none;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
}

.btn-primary:hover {
  background: var(--primary-hover);
}

.btn-secondary {
  background: var(--bg-subtle);
  border: 1px solid var(--border-light);
  color: var(--text-main);
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-secondary.danger {
  color: #EF4444;
  border-color: #FCA5A5;
  background: #FEF2F2;
}

/* 11. 모달 팝업 공통 디자인 */
.modal-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 100;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-wrapper.active {
  display: flex;
}

.modal-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(4px);
}

.modal-box {
  position: relative;
  z-index: 10;
  background: #FFFFFF;
  border-radius: var(--radius-lg);
  max-width: 780px;
  width: 100%;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 40px -8px rgba(0, 0, 0, 0.2);
  animation: modalScale 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

@keyframes modalScale {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}

.modal-header {
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-light);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h3 {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-close-btn {
  background: none;
  border: none;
  font-size: 1.3rem;
  color: var(--text-muted);
  cursor: pointer;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.modal-close-btn:hover {
  background: var(--bg-subtle);
  color: var(--text-main);
}

.modal-body {
  padding: 24px;
  overflow-y: auto;
}

/* 모달 내부 테이블 */
.modal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.modal-table th {
  background: var(--bg-subtle);
  color: var(--text-secondary);
  font-weight: 700;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-light);
  text-align: left;
}

.modal-table td {
  padding: 12px;
  border-bottom: 1px solid var(--border-light);
  color: var(--text-main);
}

.modal-table tr:hover td {
  background: #F8FAFC;
}

/* SMS 카드 */
.sms-template-card {
  background: var(--bg-subtle);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 14px;
}

.sms-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 8px;
}

.sms-body {
  font-size: 0.85rem;
  line-height: 1.6;
  color: var(--text-secondary);
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 12px;
  margin-bottom: 10px;
}

.btn-copy-sms {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  color: var(--text-main);
  transition: var(--transition);
}

.btn-copy-sms:hover {
  border-color: var(--primary);
  color: var(--primary);
}

/* 결재라인 카드 */
.approval-card {
  background: var(--bg-subtle);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 14px;
}

.approval-task {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 10px;
}

.approval-steps {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.step-node {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-secondary);
}

.step-node.final {
  background: var(--primary-light);
  border-color: var(--border-focus);
  color: var(--primary);
}

.step-arrow {
  color: var(--text-muted);
  font-size: 0.8rem;
}

/* 검색 결과 모달 */
.search-results-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.search-result-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--bg-subtle);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
}

.search-result-item:hover {
  background: var(--primary-light);
}

.search-pill {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  color: var(--primary);
}

/* 토스트 알림창 */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #0F172A;
  color: #FFFFFF;
  padding: 12px 20px;
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  font-weight: 600;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
  z-index: 1000;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}

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

/* 푸터 */
.site-footer {
  background: #FFFFFF;
  border-top: 1px solid var(--border-light);
  padding: 32px 0;
  margin-top: 60px;
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.footer-container {
  max-width: 1560px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

/* 5종 핵심 구글 문서/시트 통합 업무 허브 스타일 */
.integrated-docs-hub {
  background: linear-gradient(135deg, #1E293B, #0F172A);
  border-radius: var(--radius-lg);
  padding: 22px 24px;
  margin-bottom: 24px;
  color: #FFFFFF;
  box-shadow: var(--shadow-md);
  border: 1px solid #334155;
}

.hub-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 10px;
}

.hub-title-group h2 {
  font-size: 1.15rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #FFFFFF;
}

.hub-title-group p {
  font-size: 0.82rem;
  color: #94A3B8;
  margin-top: 3px;
}

.hub-docs-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 1100px) {
  .hub-docs-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .hub-docs-grid {
    grid-template-columns: 1fr;
  }
}

.hub-doc-card {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-md);
  padding: 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: var(--transition);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.hub-doc-card:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: #38BDF8;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.hub-doc-icon-badge {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  margin-bottom: 10px;
}

.hub-doc-icon-badge.sheet {
  background: rgba(16, 185, 129, 0.2);
  color: #34D399;
}

.hub-doc-icon-badge.doc {
  background: rgba(59, 130, 246, 0.2);
  color: #60A5FA;
}

.hub-doc-badge-type {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #94A3B8;
  margin-bottom: 4px;
}

.hub-doc-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #FFFFFF;
  margin-bottom: 6px;
  line-height: 1.35;
}

.hub-doc-desc {
  font-size: 0.75rem;
  color: #94A3B8;
  line-height: 1.4;
  margin-bottom: 12px;
  flex: 1;
}

.hub-doc-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  font-weight: 700;
  color: #38BDF8;
  text-decoration: none;
  padding-top: 6px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

/* 교직원 승인 대기 상태 박스 */
.approval-status-card {
  background: #FFFBEB;
  border: 1.5px solid #F59E0B;
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin-bottom: 20px;
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.approval-status-icon {
  width: 40px;
  height: 40px;
  background: #FEF3C7;
  color: #D97706;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  flex-shrink: 0;
}

.approval-status-content h4 {
  font-size: 0.98rem;
  font-weight: 800;
  color: #92400E;
  margin-bottom: 4px;
}

.approval-status-content p {
  font-size: 0.84rem;
  color: #B45309;
  line-height: 1.4;
}

/* 워크아웃 참석 수합 인터랙티브 위젯 */
.workout-voting-card {
  background: #F8FAFC;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-top: 14px;
}

.workout-stats-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  font-size: 0.84rem;
}

.workout-progress-track {
  width: 100%;
  height: 8px;
  background: #E2E8F0;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 12px;
}

.workout-progress-fill {
  height: 100%;
  background: var(--primary);
  border-radius: 4px;
  transition: width 0.3s ease;
}

/* 반응형 미디어 쿼리 */
@media (max-width: 1024px) {
  .home-layout-grid {
    grid-template-columns: 1fr;
  }
  .widgets-container {
    grid-template-columns: 1fr 1fr;
  }
  .checklist-top-stats {
    grid-template-columns: 1fr 1fr;
  }
  .checklist-content-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .header-container {
    flex-direction: column;
    align-items: stretch;
  }
  .widgets-container {
    grid-template-columns: 1fr;
  }
  .materials-grid {
    grid-template-columns: 1fr;
  }
  .checklist-top-stats {
    grid-template-columns: 1fr;
  }
}

/* 일일 학사일정 및 월중계획 상세 팝업 스타일 */
.day-event-detail-card {
  transition: all 0.2s ease;
}
.day-event-detail-card:hover {
  transform: translateX(4px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

/* 학사일정 교직원용 / 공개용 필터 바 */
.cal-filter-bar {
  display: inline-flex;
  background: #F1F5F9;
  padding: 3px;
  border-radius: 10px;
  border: 1px solid var(--border-light);
  gap: 4px;
}

.cal-filter-btn {
  border: none;
  background: transparent;
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 0.8rem;
  font-weight: 700;
  color: #64748B;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.cal-filter-btn:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.6);
}

.cal-filter-btn.active {
  background: #FFFFFF;
  color: var(--primary);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

/* 대형 전면 달력 모달 (Large Expanded Calendar) */
.modal-box-large {
  max-width: 1400px;
  width: 95vw;
  max-height: 94vh;
  display: flex;
  flex-direction: column;
}

.expanded-cal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  background: #F8FAFC;
  border-bottom: 1px solid var(--border-light);
}

.expanded-cal-weekdays {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
  background: #F8FAFC;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border-light);
  font-weight: 800;
  font-size: 0.88rem;
  text-align: center;
}

.expanded-cal-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
  padding: 16px;
  background: #F1F5F9;
  overflow-y: auto;
  max-height: calc(88vh - 140px);
}

.expanded-cal-day {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: 12px;
  min-height: 130px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 1px 3px rgba(0,0,0,0.03);
}

.expanded-cal-day:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
  box-shadow: 0 8px 16px rgba(37, 99, 235, 0.12);
}

.expanded-cal-day.today {
  border: 2px solid var(--primary);
  background: #EFF6FF;
}

.expanded-cal-day.other-month {
  opacity: 0.4;
  background: #F8FAFC;
}

.expanded-day-num {
  font-size: 1rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 6px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.expanded-event-pill {
  font-size: 0.76rem;
  font-weight: 700;
  padding: 3px 6px;
  border-radius: 6px;
  margin-bottom: 4px;
  line-height: 1.3;
  display: block;
  white-space: normal;
  word-break: break-all;
  border-left: 3px solid;
}

/* 학교 인트로 영상 시네마틱 모달 */
.video-cinema-box {
  background: #0B0F19;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6);
  border: 1px solid #1E293B;
  max-width: 900px;
  width: 90vw;
}

.video-cinema-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 20px;
  background: #111827;
  color: #FFFFFF;
}

.video-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.video-wrapper video,
.video-wrapper iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* 관리자 허브 순서 재정렬 버튼 */
.btn-reorder {
  border: 1px solid #334155;
  background: #0F172A;
  color: #94A3B8;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
  font-size: 0.75rem;
}

.btn-reorder:hover:not(:disabled) {
  background: #2563EB;
  color: #FFFFFF;
  border-color: #2563EB;
}

.btn-reorder:disabled {
  opacity: 0.25;
  cursor: not-allowed;
}

/* 승인 대기 / 승인 완료 뱃지 */
.badge-status-pending {
  background: #FEF3C7;
  color: #D97706;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 9999px;
  border: 1px solid #FDE68A;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.badge-status-approved {
  background: #D1FAE5;
  color: #059669;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 9999px;
  border: 1px solid #A7F3D0;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* 교직원 출장·복무 스타일 */
.cal-event-pill.trip {
  background: #FEF3C7;
  color: #92400E;
  border-left: 3px solid #D97706;
  font-weight: 700;
  transition: all 0.15s ease;
}

.cal-event-pill.trip:hover {
  background: #FDE68A;
  transform: translateY(-1px);
}

.widget-icon.trip {
  background: rgba(245, 158, 11, 0.12);
  color: #D97706;
}

/* ==========================================
   구글 로그인 & 개인정보 보호 모드 스타일
   ========================================== */
.btn-google-sign-in {
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}
.btn-google-sign-in:hover {
  background: #F8FAFC !important;
  border-color: #94A3B8 !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12) !important;
  transform: translateY(-1px);
}
.btn-google-sign-in:active {
  transform: translateY(0);
}

.guest-mode-box {
  display: flex;
  align-items: center;
  gap: 10px;
}

.guest-pill {
  background: rgba(255, 255, 255, 0.18);
  color: #FFFFFF;
  font-size: 0.76rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(4px);
}

.btn-google-login {
  background: #FFFFFF;
  color: #1E3A8A;
  border: 1px solid #BFDBFE;
  font-size: 0.8rem;
  font-weight: 800;
  padding: 5px 12px;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  transition: all 0.2s ease;
}

.btn-google-login:hover {
  background: #EFF6FF;
  color: #1D4ED8;
  border-color: #93C5FD;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.user-profile-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.15);
  padding: 4px 12px;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.user-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1.5px solid #6EE7B7;
  object-fit: cover;
}

.user-info-text {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.user-name {
  font-size: 0.8rem;
  color: #FFFFFF;
}

.user-dept {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.8);
}

.btn-auth-logout {
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #FFFFFF;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.15s ease;
  margin-left: 4px;
}

.btn-auth-logout:hover {
  background: #EF4444;
  border-color: #DC2626;
}



