/* =============================================
   뷰렌드 협업 플랫폼 v2.0 - Global Styles
   Notion/Google Teams 스타일
============================================= */

/* ─── Reset & Base ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 14px; }
body {
  font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Apple SD Gothic Neo', sans-serif;
  background: #F7F8FC;
  color: #1F2937;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
a { text-decoration: none; color: inherit; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
input, textarea, select { font-family: inherit; font-size: 14px; }
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #D1D5DB; border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: #9CA3AF; }

/* ─── 전체 앱 레이아웃 ─── */
.app-layout {
  display: flex;
  height: 100vh;
  overflow: hidden;
  position: relative;
  z-index: 0;
}

/* ─── 사이드바 ─── */
.sidebar {
  width: 180px;
  background: #ffffff;
  border-right: 1px solid #EAECF0;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  transition: width 0.25s ease;
  z-index: 10;
}
.sidebar.collapsed { width: 60px; }
.sidebar.collapsed .sidebar-header .brand-name,
.sidebar.collapsed .sidebar-header .brand-sub,
.sidebar.collapsed .nav-item span,
.sidebar.collapsed .nav-section-label,
.sidebar.collapsed .user-details,
.sidebar.collapsed .logout-btn { display: none; }
.sidebar.collapsed .nav-item { justify-content: center; padding: 10px; }
.sidebar.collapsed .nav-icon { margin: 0; }
.sidebar.collapsed .brand-icon { margin: 0 auto; }
.sidebar.collapsed .sidebar-header { justify-content: center; }
.sidebar.collapsed .user-info { justify-content: center; }

.sidebar-header {
  padding: 18px 16px;
  border-bottom: 1px solid #EAECF0;
  display: flex;
  align-items: center;
}
.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}
.brand-icon {
  width: 34px; height: 34px;
  background: linear-gradient(135deg, #6366F1, #8B5CF6);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: white; font-size: 14px;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(99,102,241,0.3);
}
.brand-name { font-size: 15px; font-weight: 700; color: #111827; }
.brand-sub { font-size: 11px; color: #9CA3AF; margin-top: 1px; }

.sidebar-nav {
  flex: 1;
  padding: 12px 8px;
  overflow-y: auto;
}
.nav-section-label {
  font-size: 10px;
  font-weight: 600;
  color: #9CA3AF;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0 10px;
  margin-bottom: 4px;
  margin-top: 4px;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 500;
  color: #6B7280;
  transition: background 0.15s, color 0.15s;
  margin-bottom: 2px;
  text-align: left;
}
.nav-item:hover { background: #F3F4FF; color: #4F46E5; }
.nav-item.active { background: #EEF2FF; color: #4F46E5; font-weight: 600; }
.nav-icon {
  width: 16px;
  text-align: center;
  font-size: 13px;
  flex-shrink: 0;
}

.sidebar-footer {
  padding: 12px 12px;
  border-top: 1px solid #EAECF0;
}
.user-info {
  display: flex;
  align-items: center;
  gap: 10px;
}
.user-details { flex: 1; min-width: 0; }
.user-name { font-size: 13px; font-weight: 600; color: #111827; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-pos { font-size: 11px; color: #9CA3AF; }
.logout-btn {
  color: #9CA3AF;
  font-size: 14px;
  padding: 4px;
  border-radius: 6px;
  transition: color 0.15s, background 0.15s;
}
.logout-btn:hover { color: #EF4444; background: #FEF2F2; }

/* ─── 메인 영역 ─── */
.main-area {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-width: 0;
}

/* ─── 상단바 ─── */
.topbar {
  height: 56px;
  background: #ffffff;
  border-bottom: 1px solid #EAECF0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  flex-shrink: 0;
}
.topbar-left { display: flex; align-items: center; gap: 12px; }
.sidebar-toggle {
  color: #6B7280;
  font-size: 16px;
  padding: 6px;
  border-radius: 6px;
  transition: background 0.15s, color 0.15s;
}
.sidebar-toggle:hover { background: #F3F4F6; color: #374151; }
.breadcrumb { display: flex; align-items: center; }
.breadcrumb-title { font-size: 15px; font-weight: 600; color: #111827; }
.topbar-right { display: flex; align-items: center; gap: 12px; position: relative; }
.topbar-date { font-size: 12px; color: #9CA3AF; }
.topbar-avatar { cursor: pointer; }

/* ─── 알림 벨 ─── */
.notif-bell { position: relative; cursor: pointer; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; border-radius: 50%; transition: background .15s; color: #6B7280; font-size: 16px; }
.notif-bell:hover { background: #F3F4F6; color: #4F46E5; }
.notif-badge { position: absolute; top: 2px; right: 2px; min-width: 16px; height: 16px; background: #EF4444; color: #fff; font-size: 10px; font-weight: 700; border-radius: 8px; display: flex; align-items: center; justify-content: center; padding: 0 3px; line-height: 1; }
.notif-panel { position: absolute; top: 52px; right: 12px; width: 320px; background: #fff; border: 1px solid #E5E7EB; border-radius: 12px; box-shadow: 0 8px 24px rgba(0,0,0,.12); z-index: 1000; overflow: hidden; }
.notif-panel-header { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px 10px; border-bottom: 1px solid #F3F4F6; }
.notif-panel-header span { font-weight: 600; font-size: 14px; color: #111827; }
.notif-panel-header button { font-size: 12px; color: #4F46E5; background: none; border: none; cursor: pointer; padding: 0; }
.notif-panel-header button:hover { text-decoration: underline; }
.notif-list { list-style: none; margin: 0; padding: 0; max-height: 360px; overflow-y: auto; }
.notif-empty { padding: 24px 16px; text-align: center; color: #9CA3AF; font-size: 13px; }
.notif-item { display: flex; align-items: flex-start; gap: 10px; padding: 12px 16px; border-bottom: 1px solid #F9FAFB; cursor: pointer; transition: background .12s; }
.notif-item:hover { background: #F9FAFB; }
.notif-item.unread { background: #EEF2FF; }
.notif-item.unread:hover { background: #E0E7FF; }
.notif-item-icon { width: 32px; height: 32px; border-radius: 50%; background: #EEF2FF; display: flex; align-items: center; justify-content: center; color: #4F46E5; font-size: 13px; flex-shrink: 0; margin-top: 2px; }
.notif-item-body { flex: 1; min-width: 0; }
.notif-item-title { font-size: 13px; font-weight: 500; color: #111827; margin-bottom: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.notif-item-desc { font-size: 12px; color: #6B7280; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.notif-item-time { font-size: 11px; color: #9CA3AF; flex-shrink: 0; margin-top: 2px; }

/* ─── 콘텐츠 영역 ─── */
.content-area {
  flex: 1;
  overflow-y: auto;
  background: #F7F8FC;
}
.page-content {
  max-width: 1280px;
  margin: 0 auto;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* ─── 로딩 ─── */
.loading-center {
  display: flex; align-items: center; justify-content: center;
  height: 200px;
}
.spinner {
  width: 28px; height: 28px;
  border: 3px solid #E5E7EB;
  border-top-color: #6366F1;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ─── 카드 ─── */
.card {
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid #EAECF0;
  overflow: hidden;
}
.card-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid #F3F4F6;
}
.card-title {
  display: flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 600; color: #111827;
}
.card-title i { font-size: 14px; }
.card-body { padding: 16px 20px; }
.card-link {
  font-size: 12px; color: #6366F1; font-weight: 500;
  transition: color 0.15s;
}
.card-link:hover { color: #4F46E5; }

/* ─── 통계 카드 ─── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
@media (max-width: 1100px) { .stats-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .stats-grid { grid-template-columns: 1fr; } }

.stat-card {
  background: #ffffff;
  border: 1px solid #EAECF0;
  border-radius: 12px;
  padding: 18px 20px;
  display: flex;
  align-items: flex-start;
  gap: 14px;
}
.stat-icon {
  width: 44px; height: 44px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.stat-info { flex: 1; min-width: 0; }
.stat-value { font-size: 26px; font-weight: 700; color: #111827; line-height: 1.1; }
.stat-label { font-size: 12px; color: #6B7280; font-weight: 500; margin-top: 2px; }
.stat-sub { font-size: 11px; color: #9CA3AF; margin-top: 3px; }

/* ─── 대시보드 ─── */
.welcome-banner {
  background: linear-gradient(135deg, #6366F1 0%, #8B5CF6 100%);
  border-radius: 14px;
  padding: 22px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: white;
}
.welcome-title { font-size: 20px; font-weight: 700; }
.welcome-sub { font-size: 13px; opacity: 0.8; margin-top: 4px; }
.welcome-stats { display: flex; gap: 0; }
.welcome-stat { text-align: center; }
.ws-num { display: block; font-size: 28px; font-weight: 700; }
.ws-label { font-size: 11px; margin-top: 2px; display: block; }

.dash-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
@media (max-width: 900px) { .dash-grid { grid-template-columns: 1fr; } }

.dash-grid-3 {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 20px;
}
@media (max-width: 900px) { .dash-grid-3 { grid-template-columns: 1fr; } }

/* 프로젝트 진행률 */
.progress-item { margin-bottom: 16px; }
.progress-item:last-child { margin-bottom: 0; }
.progress-header {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 6px;
}
.progress-label {
  display: flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 500; color: #374151;
}
.progress-value { font-size: 12px; color: #6B7280; }
.progress-track {
  height: 7px; background: #F3F4F6; border-radius: 99px; overflow: hidden;
}
.progress-fill {
  height: 100%; border-radius: 99px;
  transition: width 0.6s ease;
}

/* 예산 차트 */
.budget-chart-wrap {
  position: relative;
  display: flex;
  justify-content: center;
  margin-bottom: 16px;
}
.budget-center-text {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
}
.budget-pct { font-size: 22px; font-weight: 700; color: #111827; }
.budget-pct-label { font-size: 11px; color: #9CA3AF; }
.budget-legend {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}
.budget-leg-item {
  display: flex; align-items: center; gap: 8px; flex: 1;
}
.leg-dot {
  width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0;
}
.leg-label { font-size: 11px; color: #9CA3AF; }
.leg-val { font-size: 13px; font-weight: 600; }

/* 대시보드 업무 목록 */
.task-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s;
  margin-bottom: 4px;
}
.task-row:hover { background: #F8FAFF; }
.task-row-info { flex: 1; min-width: 0; }
.task-row-title { font-size: 13px; font-weight: 500; color: #111827; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.task-row-sub { font-size: 11px; color: #9CA3AF; margin-top: 2px; }
.task-row-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }

/* 공지사항 */
.notice-row {
  display: flex; align-items: flex-start; gap: 8px;
  padding: 10px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s;
  margin-bottom: 4px;
}
.notice-row:hover { background: #F8FAFF; }
.notice-row-content { flex: 1; min-width: 0; }
.notice-title { font-size: 13px; font-weight: 500; color: #111827; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.notice-meta { font-size: 11px; color: #9CA3AF; margin-top: 3px; }
.pin-badge {
  font-size: 10px; color: #EF4444; font-weight: 600;
  background: #FEF2F2; padding: 2px 7px; border-radius: 99px;
  white-space: nowrap; flex-shrink: 0; line-height: 18px;
}
.pin-badge-lg {
  font-size: 11px; color: #EF4444; font-weight: 600;
  background: #FEF2F2; padding: 3px 10px; border-radius: 99px;
  display: inline-flex; align-items: center; gap: 4px;
}

/* KPI 아이템 */
.kpi-item { margin-bottom: 16px; }
.kpi-item:last-child { margin-bottom: 0; }
.kpi-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 5px; }
.kpi-name { font-size: 13px; font-weight: 500; color: #374151; }
.kpi-rate { font-size: 13px; font-weight: 700; }
.kpi-values { display: flex; justify-content: space-between; font-size: 11px; color: #9CA3AF; margin-top: 4px; }

/* 팀원 업무 */
.member-stat-row {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 14px;
}
.member-stat-row:last-child { margin-bottom: 0; }
.member-stat-info { flex: 1; }
.member-stat-header { display: flex; justify-content: space-between; margin-bottom: 5px; }
.member-stat-name { font-size: 13px; font-weight: 500; color: #374151; }
.member-stat-count { font-size: 11px; color: #9CA3AF; }

/* ─── 버튼 ─── */
.btn-primary {
  display: inline-flex; align-items: center; gap: 6px;
  background: #6366F1; color: white;
  border-radius: 8px; padding: 8px 16px;
  font-size: 13.5px; font-weight: 500;
  transition: background 0.15s, box-shadow 0.15s;
  white-space: nowrap;
}
.btn-primary:hover { background: #4F46E5; box-shadow: 0 2px 8px rgba(99,102,241,0.3); }
.btn-primary:active { background: #4338CA; }
.btn-secondary {
  display: inline-flex; align-items: center; gap: 6px;
  background: white; color: #374151;
  border: 1px solid #D1D5DB; border-radius: 8px; padding: 8px 16px;
  font-size: 13.5px; font-weight: 500;
  transition: background 0.15s, border-color 0.15s;
  white-space: nowrap;
}
.btn-secondary:hover { background: #F9FAFB; border-color: #9CA3AF; }
.btn-danger {
  display: inline-flex; align-items: center; gap: 6px;
  background: #FEF2F2; color: #EF4444;
  border: 1px solid #FECACA; border-radius: 8px; padding: 8px 16px;
  font-size: 13.5px; font-weight: 500;
  transition: background 0.15s;
}
.btn-danger:hover { background: #FEE2E2; }
.btn-sm { padding: 5px 10px; font-size: 12px; }
.w-full { width: 100%; justify-content: center; }
.flex-1 { flex: 1; }

/* ─── 뱃지 ─── */
.badge {
  display: inline-flex; align-items: center;
  padding: 2px 9px; border-radius: 99px;
  font-size: 11.5px; font-weight: 500;
  white-space: nowrap;
}
.badge-todo { background: #F3F4F6; color: #6B7280; }
.badge-inprogress { background: #EEF2FF; color: #4F46E5; }
.badge-done { background: #ECFDF5; color: #059669; }
.badge-high { background: #FEF2F2; color: #DC2626; }
.badge-medium { background: #FFFBEB; color: #D97706; }
.badge-low { background: #F0FDF4; color: #16A34A; }

/* ─── 아바타 ─── */
.avatar-el {
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 600; color: white; flex-shrink: 0;
}

/* ─── 폼 ─── */
.form-group {
  display: flex; flex-direction: column; gap: 5px;
}
.form-group.full { grid-column: span 2; }
.form-group label { font-size: 12.5px; font-weight: 500; color: #374151; }
.form-input {
  width: 100%;
  border: 1px solid #D1D5DB;
  border-radius: 8px;
  padding: 9px 12px;
  font-size: 13.5px;
  color: #111827;
  background: white;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  resize: vertical;
}
.form-input:focus {
  border-color: #6366F1;
  box-shadow: 0 0 0 3px rgba(99,102,241,0.12);
}
.form-input::placeholder { color: #9CA3AF; }
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px 16px;
  margin-bottom: 20px;
}

/* ─── 필터 / 셀렉트 ─── */
.filter-select {
  border: 1px solid #D1D5DB;
  border-radius: 8px;
  padding: 7px 12px;
  font-size: 13px;
  color: #374151;
  background: white;
  outline: none;
  cursor: pointer;
  transition: border-color 0.15s;
}
.filter-select:focus { border-color: #6366F1; }

/* ─── 페이지 툴바 ─── */
.page-toolbar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.toolbar-filters { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

/* ─── 칸반 ─── */
.kanban-board {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  align-items: start;
}
@media (max-width: 900px) { .kanban-board { grid-template-columns: 1fr; } }
.kanban-col {
  background: #F8FAFC;
  border-radius: 12px;
  border: 1px solid #EAECF0;
  overflow: hidden;
  min-height: 300px;
}
.kanban-col-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 14px;
  border-bottom: 1px solid #EAECF0;
  background: white;
}
.kanban-col-title { font-size: 13px; font-weight: 600; color: #374151; }
.kanban-count {
  background: #E5E7EB; color: #6B7280;
  font-size: 11px; font-weight: 600;
  padding: 1px 7px; border-radius: 99px;
}
.kanban-cards { padding: 10px; display: flex; flex-direction: column; gap: 8px; }

.task-card {
  background: white;
  border-radius: 10px;
  padding: 12px 14px;
  border: 1px solid #EAECF0;
  cursor: pointer;
  transition: box-shadow 0.15s, transform 0.1s;
}
.task-card:hover {
  box-shadow: 0 4px 14px rgba(0,0,0,0.09);
  transform: translateY(-1px);
}
.tc-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 7px; }
.tc-no { font-size: 11px; color: #9CA3AF; font-weight: 500; }
.tc-title { font-size: 13px; font-weight: 500; color: #1F2937; line-height: 1.45; margin-bottom: 6px; }
.tc-project {
  display: flex; align-items: center; gap: 5px;
  font-size: 11.5px; color: #9CA3AF; margin-bottom: 8px;
}
.tc-footer { display: flex; align-items: center; justify-content: space-between; }
.tc-assignee { display: flex; align-items: center; gap: 5px; font-size: 11.5px; color: #6B7280; }
.tc-due { font-size: 11px; color: #9CA3AF; }
.tc-due.overdue { color: #EF4444; font-weight: 600; }
.tc-comment {
  margin-top: 8px; padding-top: 8px; border-top: 1px solid #F3F4F6;
  font-size: 11.5px; color: #9CA3AF; display: flex; align-items: flex-start; gap: 5px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.due-date-sm { font-size: 11px; color: #9CA3AF; }
.due-date-sm.overdue { color: #EF4444; font-weight: 600; }

/* ─── 캘린더 ─── */
.cal-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 20px;
  align-items: start;
}
@media (max-width: 1000px) { .cal-layout { grid-template-columns: 1fr; } }
.cal-main { overflow: visible; }
.cal-header {
  display: flex; align-items: center; gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid #F3F4F6;
}
.cal-title { font-size: 16px; font-weight: 700; color: #111827; flex: 1; text-align: center; }
.cal-nav-btn {
  width: 32px; height: 32px;
  border-radius: 8px; display: flex; align-items: center; justify-content: center;
  color: #6B7280; font-size: 13px;
  transition: background 0.15s, color 0.15s;
}
.cal-nav-btn:hover { background: #F3F4F6; color: #374151; }
.cal-today-btn {
  font-size: 12px; padding: 5px 12px;
}
.cal-grid-header {
  display: grid; grid-template-columns: repeat(7, 1fr);
  padding: 8px 12px 4px;
}
.cal-week {
  text-align: center; font-size: 12px; font-weight: 600; color: #9CA3AF; padding: 4px;
}
.cal-week.sun { color: #EF4444; }
.cal-week.sat { color: #3B82F6; }
.cal-grid {
  display: grid; grid-template-columns: repeat(7, 1fr);
  padding: 4px 8px 12px;
  gap: 2px;
}
.cal-cell {
  min-height: 90px;
  border-radius: 8px;
  padding: 6px;
  cursor: pointer;
  transition: background 0.15s;
  display: flex; flex-direction: column;
}
.cal-cell:hover { background: #F8FAFF; }
.cal-cell.empty { cursor: default; }
.cal-cell.empty:hover { background: transparent; }
.cal-cell.today { background: #EEF2FF; }
.cal-day-num {
  font-size: 13px; font-weight: 500; color: #374151;
  width: 26px; height: 26px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%; margin-bottom: 4px; flex-shrink: 0;
}
.cal-day-num.today-num { background: #6366F1; color: white; font-weight: 700; }
.cal-day-num.sun { color: #EF4444; }
.cal-day-num.sat { color: #3B82F6; }
.cal-events { display: flex; flex-direction: column; gap: 2px; flex: 1; overflow: hidden; }
.cal-event-dot {
  font-size: 10.5px; color: white;
  padding: 1px 5px; border-radius: 3px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  line-height: 1.5;
}
.cal-more { font-size: 10px; color: #9CA3AF; padding-left: 4px; }

/* 캘린더 사이드 */
.event-row {
  display: flex; align-items: center; gap: 10px;
  padding: 8px; border-radius: 8px; margin-bottom: 4px;
  transition: background 0.15s;
}
.event-row:hover { background: #F8FAFF; }
.event-dot-lg {
  width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0;
}
.event-row-info { flex: 1; min-width: 0; }
.event-row-title { font-size: 13px; font-weight: 500; color: #1F2937; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.event-row-date { font-size: 11px; color: #9CA3AF; margin-top: 2px; }
.event-detail-row {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 10px 0; border-bottom: 1px solid #F3F4F6;
}
.event-detail-row:last-child { border-bottom: none; }
.icon-btn-danger {
  color: #D1D5DB; font-size: 12px; padding: 4px; border-radius: 4px;
  transition: color 0.15s, background 0.15s; flex-shrink: 0;
}
.icon-btn-danger:hover { color: #EF4444; background: #FEF2F2; }
.icon-btn {
  color: #9CA3AF; font-size: 13px; padding: 4px 6px; border-radius: 6px;
  transition: color 0.15s, background 0.15s;
}
.icon-btn:hover { color: #6366F1; background: #EEF2FF; }

/* ─── 리스트 컨테이너 (공지/회의록 등) ─── */
.list-container {
  background: white; border: 1px solid #EAECF0; border-radius: 12px; overflow: hidden;
}
.list-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px;
  border-bottom: 1px solid #F3F4F6;
  cursor: pointer;
  transition: background 0.15s;
  gap: 12px;
}
.list-row:last-child { border-bottom: none; }
.list-row:hover { background: #F8FAFF; }
.list-row-left { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; }
.list-row-right { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.list-title { font-size: 14px; font-weight: 500; color: #1F2937; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list-title.pinned { font-weight: 600; color: #111827; }
.list-meta { font-size: 12px; color: #9CA3AF; display: flex; align-items: center; gap: 4px; white-space: nowrap; }
.meeting-date-badge {
  background: #EEF2FF; color: #4F46E5;
  font-size: 11.5px; font-weight: 600;
  padding: 3px 10px; border-radius: 99px;
  white-space: nowrap; flex-shrink: 0;
}

/* ─── 테이블 (기획서/요청서) ─── */
.doc-table-wrap {
  background: white; border: 1px solid #EAECF0; border-radius: 12px; overflow: hidden;
}
.doc-table {
  width: 100%; border-collapse: collapse;
}
.doc-table thead tr { background: #F9FAFB; }
.doc-table th {
  padding: 11px 16px;
  text-align: left; font-size: 12px; font-weight: 600; color: #6B7280;
  border-bottom: 1px solid #EAECF0;
  white-space: nowrap;
}
.doc-table td {
  padding: 12px 16px;
  font-size: 13px; color: #374151;
  border-bottom: 1px solid #F3F4F6;
  vertical-align: middle;
}
.doc-table tbody tr:last-child td { border-bottom: none; }
.table-clickrow { cursor: pointer; transition: background 0.12s; }
.table-clickrow:hover { background: #F8FAFF; }
.table-title { font-weight: 500; color: #1F2937; max-width: 260px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.empty-td { text-align: center; color: #9CA3AF; padding: 32px; }
.text-muted { color: #9CA3AF; }
.text-green { color: #10B981; }
.text-purple { color: #6366F1; }
.text-yellow { color: #D97706; }
.font-bold { font-weight: 700; }

/* ─── KPI ─── */
.kpi-chart-row { margin-bottom: 20px; }
.kpi-cards-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px;
}
@media (max-width: 900px) { .kpi-cards-grid { grid-template-columns: 1fr 1fr; } }
.kpi-card {
  background: #F8FAFC; border: 1px solid #EAECF0; border-radius: 10px; padding: 16px;
}
.kpi-card-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.kpi-card-name { font-size: 13px; font-weight: 600; color: #374151; }
.kpi-card-value { font-size: 22px; font-weight: 700; line-height: 1.1; margin-bottom: 2px; }
.kpi-card-target { font-size: 11.5px; color: #9CA3AF; margin-bottom: 8px; }
.kpi-rate-text { font-size: 12px; font-weight: 600; margin-top: 5px; }

/* ─── 팀원 카드 ─── */
.members-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}
.member-card {
  background: white; border: 1px solid #EAECF0; border-radius: 14px;
  padding: 24px 20px; text-align: center;
  transition: box-shadow 0.2s, transform 0.15s;
  position: relative;
}
.member-card:hover { box-shadow: 0 6px 24px rgba(0,0,0,0.08); transform: translateY(-2px); }
.mc-avatar {
  width: 64px; height: 64px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 24px; font-weight: 700; color: white; margin: 0 auto 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}
.mc-name { font-size: 16px; font-weight: 700; color: #111827; margin-bottom: 4px; }
.mc-position { font-size: 13px; color: #6B7280; margin-bottom: 2px; }
.mc-dept { font-size: 12px; color: #9CA3AF; margin-bottom: 14px; }
.mc-divider { height: 1px; background: #F3F4F6; margin: 0 -20px 14px; }
.mc-contact { text-align: left; display: flex; flex-direction: column; gap: 7px; }
.mc-contact-item {
  display: flex; align-items: center; gap: 8px;
  font-size: 12.5px; color: #6B7280;
}
.mc-contact-item i { color: #9CA3AF; font-size: 12px; width: 14px; text-align: center; }
.mc-badge {
  position: absolute; top: 16px; right: 16px;
  font-size: 10.5px; font-weight: 600; padding: 3px 10px; border-radius: 99px;
}
.mc-admin { background: #EEF2FF; color: #4F46E5; }
.mc-manager { background: #ECFDF5; color: #059669; }
.mc-staff { background: #F3F4F6; color: #6B7280; }

/* ─── 모달 ─── */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.45);
  display: flex; align-items: center; justify-content: center;
  z-index: 9000; padding: 16px;
  backdrop-filter: blur(2px);
}
.modal-overlay.hidden { display: none; }
.modal {
  background: white; border-radius: 16px;
  width: 100%; max-width: 640px;
  max-height: 88vh; overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,0.18);
  animation: modalIn 0.2s ease;
  display: flex; flex-direction: column;
}
.modal-inner {
  overflow-y: auto;
  padding: 24px;
  flex: 1;
}
@keyframes modalIn { from { opacity:0; transform: scale(0.96) translateY(6px); } to { opacity:1; transform: none; } }
.modal-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  margin-bottom: 20px; gap: 12px;
}
.modal-title { font-size: 17px; font-weight: 700; color: #111827; line-height: 1.3; }
.modal-close {
  color: #9CA3AF; font-size: 16px;
  padding: 4px; border-radius: 6px;
  transition: color 0.15s, background 0.15s; flex-shrink: 0;
}
.modal-close:hover { color: #374151; background: #F3F4F6; }
.modal-footer {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: 16px; margin-top: 4px; border-top: 1px solid #F3F4F6; gap: 10px;
}

/* ─── 상세 정보 ─── */
.detail-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px;
}
.detail-item {
  background: #F9FAFB; border-radius: 8px; padding: 10px 12px;
}
.detail-label { font-size: 11px; color: #9CA3AF; font-weight: 500; margin-bottom: 4px; text-transform: uppercase; letter-spacing: 0.04em; }
.detail-val { font-size: 13.5px; color: #1F2937; font-weight: 500; }
.detail-section { margin-bottom: 12px; }
.detail-text {
  background: #F9FAFB; border-radius: 8px; padding: 12px;
  font-size: 13.5px; color: #374151; line-height: 1.6; margin-top: 5px;
}
.detail-text.highlight {
  background: #FFFBEB; border: 1px solid #FDE68A;
}
/* ─── 태스크 댓글 ─── */
.task-comments-list {
  max-height: 260px; overflow-y: auto;
  display: flex; flex-direction: column; gap: 10px;
  margin-bottom: 10px; padding: 4px 0;
}
.task-comment-empty { font-size: 12.5px; color: #9CA3AF; text-align: center; padding: 16px 0; }
.task-comment-item { display: flex; gap: 8px; align-items: flex-start; }
.task-comment-avatar { flex-shrink: 0; margin-top: 1px; }
.task-comment-body { flex: 1; min-width: 0; }
.task-comment-meta { display: flex; align-items: center; gap: 6px; margin-bottom: 3px; }
.task-comment-name { font-size: 12.5px; font-weight: 600; color: #1F2937; }
.task-comment-time { font-size: 11px; color: #9CA3AF; }
.task-comment-del {
  margin-left: auto; background: none; border: none; cursor: pointer;
  color: #D1D5DB; font-size: 10px; padding: 2px 4px; line-height: 1;
  opacity: 0; transition: opacity 0.15s;
}
.task-comment-item:hover .task-comment-del { opacity: 1; }
.task-comment-del:hover { color: #EF4444; }
.task-comment-text {
  font-size: 13px; color: #374151; line-height: 1.55;
  background: #F9FAFB; border-radius: 0 8px 8px 8px;
  padding: 8px 10px; word-break: break-word;
}
.task-comment-input-wrap {
  display: flex; gap: 8px; align-items: flex-end;
  background: #F3F4F6; border-radius: 10px; padding: 6px 8px;
  border: 1px solid #E5E7EB;
}
.task-comment-input-row { display: flex; flex: 1; gap: 6px; align-items: flex-end; }
.task-comment-textarea {
  flex: 1; resize: none; border: none; background: transparent;
  font-size: 13px; color: #1F2937; line-height: 1.5; padding: 2px 0;
  outline: none; min-height: 22px; max-height: 120px; overflow-y: auto;
  font-family: inherit;
}
.task-comment-textarea::placeholder { color: #9CA3AF; }
.task-comment-send {
  background: #6366F1; color: white; border: none; border-radius: 7px;
  width: 30px; height: 30px; display: flex; align-items: center; justify-content: center;
  cursor: pointer; flex-shrink: 0; font-size: 12px; transition: background 0.15s;
}
.task-comment-send:hover { background: #4F46E5; }

.notice-content {
  font-size: 14px; color: #374151; line-height: 1.8;
  padding: 4px 0 16px;
}

/* ─── 알림 ─── */
.notification {
  position: fixed; top: 20px; right: 20px; z-index: 100;
  display: flex; align-items: center;
  padding: 12px 18px; border-radius: 10px;
  font-size: 13.5px; font-weight: 500;
  box-shadow: 0 4px 20px rgba(0,0,0,0.12);
  animation: notifIn 0.3s ease;
  max-width: 320px;
}
@keyframes notifIn { from { transform: translateX(100%); opacity:0; } to { transform: none; opacity:1; } }
.notif-success { background: #111827; color: white; }
.notif-error { background: #FEF2F2; color: #DC2626; border: 1px solid #FECACA; }
.notif-info { background: #EEF2FF; color: #4F46E5; border: 1px solid #C7D2FE; }

/* ─── 빈 상태 ─── */
.empty-state {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 60px 20px; color: #9CA3AF; gap: 12px;
  background: white; border: 1px solid #EAECF0; border-radius: 12px;
}
.empty-state i { font-size: 40px; color: #D1D5DB; }
.empty-state p { font-size: 14px; }
.empty-text {
  font-size: 13px; color: #9CA3AF; text-align: center; padding: 16px;
}
.error-state {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 40px; color: #EF4444; gap: 8px;
}
.error-state i { font-size: 32px; }
.error-state p { font-size: 13px; }

/* ─── 유틸 ─── */
.dot {
  width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex-shrink: 0;
}
.overdue { color: #EF4444; font-weight: 600; }

/* ─── 목표 ─── */
.goals-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}
@media (max-width: 900px) { .goals-summary-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .goals-summary-grid { grid-template-columns: 1fr; } }

/* 전체 목표 배너 */
.goal-total-banner {
  background: linear-gradient(135deg, #4F46E5 0%, #7C3AED 100%);
  border-radius: 16px;
  padding: 24px 28px;
  margin-bottom: 20px;
  cursor: pointer;
  transition: box-shadow 0.18s, transform 0.15s;
  box-shadow: 0 4px 20px rgba(99,102,241,0.3);
}
.goal-total-banner:hover { box-shadow: 0 8px 32px rgba(99,102,241,0.45); transform: translateY(-2px); }

.goal-card {
  background: white; border: 1px solid #EAECF0; border-radius: 14px;
  padding: 20px; cursor: pointer;
  transition: box-shadow 0.18s, transform 0.15s;
  display: flex; flex-direction: column; gap: 12px;
}
.goal-card:hover { box-shadow: 0 6px 24px rgba(0,0,0,0.09); transform: translateY(-2px); }
.goal-card-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.goal-card-title { font-size: 15px; font-weight: 700; color: #111827; line-height: 1.3; }
.goal-card-desc { font-size: 13px; color: #6B7280; line-height: 1.5; }
.goal-progress-wrap { display: flex; flex-direction: column; gap: 5px; }
.goal-progress-header { display: flex; justify-content: space-between; align-items: center; }
.goal-card-footer { display: flex; align-items: center; justify-content: space-between; padding-top: 8px; border-top: 1px solid #F3F4F6; }
.goal-status-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex-shrink: 0; }
.goal-assignees { display: flex; align-items: center; gap: 4px; min-height: 24px; }

/* ─── 로그인 ─── */
.login-bg {
  min-height: 100vh;
  background: linear-gradient(135deg, #EEF2FF 0%, #F5F3FF 50%, #FDF2F8 100%);
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.login-container { width: 100%; max-width: 400px; }
.login-logo { text-align: center; margin-bottom: 32px; }
.login-logo-icon {
  width: 60px; height: 60px;
  background: linear-gradient(135deg, #6366F1, #8B5CF6);
  border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  font-size: 24px; color: white; margin: 0 auto 14px;
  box-shadow: 0 8px 24px rgba(99,102,241,0.3);
}
.login-logo h1 { font-size: 28px; font-weight: 800; color: #111827; }
.login-logo p { font-size: 14px; color: #6B7280; margin-top: 4px; }
.login-card {
  background: white; border-radius: 20px;
  padding: 36px; box-shadow: 0 8px 40px rgba(0,0,0,0.08);
  border: 1px solid #EAECF0;
}
.login-error {
  background: #FEF2F2; color: #DC2626; border: 1px solid #FECACA;
  border-radius: 8px; padding: 10px 14px; font-size: 13.5px; margin-bottom: 16px;
}
.login-hint {
  margin-top: 18px; padding: 14px; background: #F9FAFB;
  border-radius: 10px; font-size: 12px; color: #6B7280; line-height: 1.7;
}
.login-hint strong { display: block; color: #374151; margin-bottom: 4px; }

.predecessor-dropdown {
  background: #fff;
  border: 1px solid #E5E7EB;
  border-radius: 10px;
  box-shadow: 0 6px 24px rgba(0,0,0,0.12);
  z-index: 99999;
  max-height: 280px;
  overflow-y: auto;
}
.predecessor-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  font-size: 13px;
  color: #111827;
  cursor: pointer;
  border-bottom: 1px solid #F3F4F6;
}
.predecessor-item:last-child { border-bottom: none; }
.predecessor-item:hover { background: #F5F5FF; }
.predecessor-item strong { font-weight: 700; color: #6366F1; }

.assignee-box {
  cursor: pointer;
  min-height: 38px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
  padding: 4px 8px;
  user-select: none;
}
.assignee-chip {
  background: #EEF2FF;
  color: #4F46E5;
  border-radius: 4px;
  padding: 2px 7px;
  font-size: 12px;
  font-weight: 500;
  display: flex;
  align-items: center;
}
/* Multi-select dropdown (채널 / 판매처) */
.rq-ms-box {
  cursor: pointer;
  min-height: 38px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
  padding: 4px 28px 4px 8px;
  border: 1px solid #E5E7EB;
  border-radius: 6px;
  background: #fff;
  user-select: none;
  position: relative;
  font-size: 13px;
  color: #111827;
  transition: border-color .15s;
}
.rq-ms-box:hover { border-color: #9CA3AF; }
.rq-ms-chevron {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  color: #9CA3AF;
  font-size: 11px;
  pointer-events: none;
}
.rq-ms-chip {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 8px;
  border-radius: 99px;
  font-size: 12px;
  font-weight: 500;
}
.rq-ms-chip .ms-remove {
  cursor: pointer;
  font-size: 11px;
  opacity: .6;
  line-height: 1;
}
.rq-ms-chip .ms-remove:hover { opacity: 1; }
.rq-ms-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  min-width: 200px;
  background: #fff;
  border: 1px solid #E5E7EB;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,.13);
  z-index: 9999;
  padding: 10px;
}
.rq-ms-dropdown .ms-search-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
  padding: 0 2px;
  border-bottom: 1px solid #F3F4F6;
  padding-bottom: 6px;
}
.rq-ms-dropdown .ms-search-wrap i { color: #9CA3AF; font-size: 12px; }
.rq-ms-dropdown .ms-search {
  flex: 1;
  border: none;
  outline: none;
  font-size: 13px;
  background: transparent;
}
.rq-ms-opts {
  display: flex;
  flex-direction: column;
  gap: 3px;
  max-height: 210px;
  overflow-y: auto;
}
.rq-ms-opt {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 3px 4px;
  cursor: pointer;
  border-radius: 6px;
}
.rq-ms-opt:hover { background: #F9FAFB; }
.rq-ms-opt .opt-chip {
  display: inline-flex;
  align-items: center;
  padding: 2px 12px;
  border-radius: 99px;
  font-size: 12px;
  font-weight: 500;
}
.rq-ms-opt .opt-check { color: #6366F1; font-size: 13px; width: 18px; text-align: right; }
