/* =========================================
   ITPM 미래포럼 - 관리자 대시보드 스타일
   ========================================= */

/* ══ 로그인 화면 ══ */
.login-screen {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  position: relative; z-index: 10;
  padding: 20px;
}
.login-card {
  background: #fff;
  border: 1px solid rgba(99,102,241,.15);
  border-radius: 24px;
  padding: 48px 40px;
  width: 100%; max-width: 460px;
  box-shadow: 0 20px 60px rgba(99,102,241,.13), 0 4px 16px rgba(0,0,0,.07);
  animation: fadeInUp .5s ease;
}
@keyframes fadeInUp { from { opacity:0; transform:translateY(24px); } to { opacity:1; transform:translateY(0); } }

.login-logo { text-align: center; margin-bottom: 36px; }
.logo-badge-lg {
  width: 72px; height: 72px; border-radius: 20px;
  background: linear-gradient(135deg, #4f46e5, #0891b2);
  display: grid; place-items: center; font-size: 32px; color: #fff;
  margin: 0 auto 16px;
  box-shadow: 0 8px 24px rgba(79,70,229,.35);
}
.login-title { font-size: 20px; font-weight: 800; color: #1e293b; margin-bottom: 4px; }
.login-sub   { font-size: 13px; color: #64748b; }

.login-form-wrap { }
.login-icon-wrap {
  width: 52px; height: 52px; border-radius: 14px;
  background: rgba(99,102,241,.1); border: 1px solid rgba(99,102,241,.2);
  display: grid; place-items: center;
  font-size: 22px; color: #4f46e5; margin-bottom: 16px;
}
.login-form-title { font-size: 18px; font-weight: 700; color: #1e293b; margin-bottom: 6px; }
.login-form-desc  { font-size: 13px; color: #64748b; margin-bottom: 28px; line-height: 1.6; }

.login-form { display: flex; flex-direction: column; gap: 16px; }
.login-field { display: flex; flex-direction: column; gap: 7px; }
.login-field label {
  font-size: 13px; font-weight: 600; color: #475569;
  display: flex; align-items: center; gap: 6px;
}
.login-field label i { color: #6366f1; }
.login-field input {
  background: #f8faff; border: 1.5px solid rgba(99,102,241,.18);
  border-radius: 10px; padding: 12px 16px;
  color: #1e293b; font-size: 14px; font-family: inherit;
  outline: none; transition: .25s ease;
}
.login-field input:focus {
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99,102,241,.1);
  background: #fff;
}
.pw-wrap { position: relative; }
.pw-wrap input { width: 100%; padding-right: 44px; }
.pw-toggle {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  background: none; border: none; color: #94a3b8; cursor: pointer;
  font-size: 15px; padding: 4px; transition: .2s;
}
.pw-toggle:hover { color: #6366f1; }

.login-error {
  display: flex; align-items: center; gap: 8px;
  background: rgba(220,38,38,.07); border: 1px solid rgba(220,38,38,.2);
  border-radius: 8px; padding: 10px 14px;
  font-size: 13px; color: #dc2626;
}

.login-btn {
  position: relative; overflow: hidden;
  background: linear-gradient(135deg, #4f46e5, #0891b2);
  color: #fff; border: none; border-radius: 12px;
  padding: 14px; font-size: 15px; font-weight: 700;
  font-family: inherit; cursor: pointer;
  box-shadow: 0 6px 24px rgba(79,70,229,.35);
  transition: .25s ease; display: flex; align-items: center; justify-content: center; gap: 8px;
  margin-top: 4px;
}
.login-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 32px rgba(79,70,229,.45); }
.login-btn:disabled { opacity: .7; transform: none; cursor: not-allowed; }

.back-link {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  margin-top: 20px; color: #94a3b8; font-size: 13px; text-decoration: none;
  transition: .2s;
}
.back-link:hover { color: #6366f1; }

/* index.html 관리자 버튼 강조 */
.admin-only-btn {
  background: rgba(99,102,241,.08) !important;
  border-color: rgba(99,102,241,.25) !important;
  color: #6366f1 !important;
}
.admin-only-btn:hover {
  background: rgba(99,102,241,.15) !important;
  border-color: #6366f1 !important;
}

/* ══ 어드민 레이아웃 (사이드바 + 메인) ══ */
#adminDashboard {
  display: flex; min-height: 100vh;
  position: relative; z-index: 5;
}

/* ── 사이드바 ── */
.admin-sidebar {
  width: 240px; flex-shrink: 0;
  background: #fff;
  border-right: 1px solid rgba(99,102,241,.12);
  display: flex; flex-direction: column;
  box-shadow: 2px 0 16px rgba(99,102,241,.07);
  position: sticky; top: 0; height: 100vh;
  overflow-y: auto; z-index: 50;
}
.sidebar-logo {
  display: flex; align-items: center; gap: 12px;
  padding: 20px 20px 18px;
  border-bottom: 1px solid rgba(99,102,241,.1);
}
.logo-badge-sm {
  width: 38px; height: 38px; border-radius: 10px; flex-shrink: 0;
  background: linear-gradient(135deg, #4f46e5, #0891b2);
  display: grid; place-items: center; font-size: 17px; color: #fff;
}
.sidebar-title { font-size: 14px; font-weight: 800; color: #1e293b; display: block; }
.sidebar-sub   { font-size: 11px; color: #94a3b8; display: block; }

.sidebar-nav { flex: 1; padding: 12px 10px; display: flex; flex-direction: column; gap: 2px; }
.sidebar-link {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; border-radius: 10px;
  font-size: 13px; font-weight: 500; color: #64748b;
  text-decoration: none; transition: .2s;
}
.sidebar-link i { width: 18px; text-align: center; color: #94a3b8; transition: .2s; }
.sidebar-link:hover { background: rgba(99,102,241,.07); color: #4f46e5; }
.sidebar-link:hover i { color: #6366f1; }
.sidebar-link.active {
  background: rgba(99,102,241,.1);
  color: #4f46e5; font-weight: 700;
  border-left: 3px solid #6366f1;
}
.sidebar-link.active i { color: #6366f1; }

.sidebar-footer {
  padding: 14px 12px;
  border-top: 1px solid rgba(99,102,241,.1);
  display: flex; flex-direction: column; gap: 8px;
}
.sidebar-survey-link {
  display: flex; align-items: center; justify-content: center; gap: 7px;
  padding: 9px; border-radius: 9px; font-size: 12px; font-weight: 600;
  color: #6366f1; text-decoration: none;
  background: rgba(99,102,241,.07); border: 1px solid rgba(99,102,241,.15);
  transition: .2s;
}
.sidebar-survey-link:hover { background: rgba(99,102,241,.12); }
.logout-btn {
  display: flex; align-items: center; justify-content: center; gap: 7px;
  padding: 9px; border-radius: 9px; font-size: 12px; font-weight: 600;
  color: #dc2626; background: rgba(220,38,38,.06);
  border: 1px solid rgba(220,38,38,.15); cursor: pointer;
  font-family: inherit; transition: .2s;
}
.logout-btn:hover { background: rgba(220,38,38,.1); }

/* 모바일 사이드바 오버레이 */
.sidebar-overlay {
  display: none; position: fixed; inset: 0; z-index: 40;
  background: rgba(0,0,0,.35); backdrop-filter: blur(2px);
}
.sidebar-overlay.show { display: block; }

/* ── 메인 영역 ── */
.admin-main {
  flex: 1; display: flex; flex-direction: column;
  min-width: 0; background: #f4f6ff;
}

/* ── 상단바 ── */
.admin-topbar {
  background: #fff; border-bottom: 1px solid rgba(99,102,241,.1);
  padding: 0 24px; height: 64px;
  display: flex; align-items: center; justify-content: space-between;
  position: sticky; top: 0; z-index: 30;
  box-shadow: 0 2px 8px rgba(99,102,241,.06);
}
.topbar-left { display: flex; align-items: center; gap: 14px; }
.sidebar-toggle {
  display: none; background: none; border: none; cursor: pointer;
  font-size: 18px; color: #475569; padding: 6px;
}
.topbar-title { font-size: 17px; font-weight: 700; color: #1e293b; }
.topbar-right { display: flex; align-items: center; gap: 10px; }
.admin-badge {
  display: flex; align-items: center; gap: 7px;
  background: rgba(99,102,241,.08); border: 1px solid rgba(99,102,241,.2);
  border-radius: 8px; padding: 6px 12px;
  font-size: 13px; font-weight: 600; color: #4f46e5;
}
.refresh-btn {
  width: 36px; height: 36px; border-radius: 8px; border: 1px solid rgba(99,102,241,.2);
  background: #fff; color: #6366f1; cursor: pointer; font-size: 14px;
  display: grid; place-items: center; transition: .2s;
}
.refresh-btn:hover { background: rgba(99,102,241,.08); }
.logout-btn-top {
  display: flex; align-items: center; gap: 6px;
  padding: 8px 16px; border-radius: 8px; font-size: 13px; font-weight: 600;
  color: #dc2626; background: rgba(220,38,38,.06);
  border: 1px solid rgba(220,38,38,.15); cursor: pointer;
  font-family: inherit; transition: .2s;
}
.logout-btn-top:hover { background: rgba(220,38,38,.1); }

/* ── 컨텐츠 영역 ── */
.admin-content { flex: 1; padding: 24px; overflow-y: auto; }
.dash-section { animation: fadeIn .35s ease; }
@keyframes fadeIn { from { opacity:0; transform:translateY(12px); } to { opacity:1; transform:translateY(0); } }

/* ── KPI 카드 ── */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px; margin-bottom: 20px;
}
.kpi-card {
  background: #fff; border: 1px solid rgba(99,102,241,.12);
  border-radius: 16px; padding: 20px 18px;
  display: flex; align-items: center; gap: 16px;
  box-shadow: 0 2px 12px rgba(99,102,241,.07);
  transition: .25s ease;
}
.kpi-card:hover { border-color: rgba(99,102,241,.3); transform: translateY(-2px); box-shadow: 0 6px 20px rgba(99,102,241,.12); }
.kpi-icon {
  width: 48px; height: 48px; border-radius: 13px; flex-shrink: 0;
  display: grid; place-items: center; font-size: 20px;
}
.kpi-icon.purple { background: rgba(99,102,241,.12); color: #6366f1; }
.kpi-icon.blue   { background: rgba(8,145,178,.12);  color: #0891b2; }
.kpi-icon.green  { background: rgba(5,150,105,.12);  color: #059669; }
.kpi-icon.orange { background: rgba(217,119,6,.12);  color: #d97706; }
.kpi-icon.teal   { background: rgba(20,184,166,.12); color: #14b8a6; }
.kpi-body { flex: 1; min-width: 0; }
.kpi-value {
  font-size: 26px; font-weight: 800; color: #1e293b; line-height: 1;
  margin-bottom: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.kpi-value.kpi-text { font-size: 14px; font-weight: 700; }
.kpi-unit { font-size: 14px; font-weight: 600; color: #64748b; margin-left: 2px; }
.kpi-label { font-size: 12px; color: #94a3b8; }
.kpi-trend { font-size: 22px; color: #e2e8f0; margin-left: auto; }

/* ── 대시보드 카드/그리드 ── */
.dash-row {
  display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 20px;
}
.dash-card {
  background: #fff; border: 1px solid rgba(99,102,241,.12);
  border-radius: 16px; padding: 22px 24px;
  box-shadow: 0 2px 12px rgba(99,102,241,.06);
}
.dash-card.wide { grid-column: 1; }
.dash-card.full { width: 100%; margin-bottom: 20px; }
.dash-card-header {
  display: flex; align-items: center; gap: 10px; margin-bottom: 18px; flex-wrap: wrap;
}
.dash-card-header i { font-size: 18px; color: #6366f1; }
.dash-card-header h3 { font-size: 16px; font-weight: 700; color: #1e293b; flex: 1; }
.card-badge {
  background: rgba(99,102,241,.1); border: 1px solid rgba(99,102,241,.2);
  color: #6366f1; font-size: 11px; font-weight: 700;
  padding: 3px 10px; border-radius: 999px;
}
.table-controls { display: flex; align-items: center; gap: 10px; margin-left: auto; flex-wrap: wrap; }

/* ── 순위 리스트 ── */
.ranking-list { display: flex; flex-direction: column; gap: 8px; }
.rank-item { display: flex; align-items: center; gap: 10px; }
.rank-no {
  width: 24px; height: 24px; border-radius: 6px; flex-shrink: 0;
  background: #f1f5f9; color: #64748b;
  display: grid; place-items: center; font-size: 12px; font-weight: 700;
}
.rank-no.rank-top { background: linear-gradient(135deg,#fbbf24,#f59e0b); color: #fff; }
.rank-info { flex: 1; min-width: 0; }
.rank-label {
  font-size: 12px; color: #475569; margin-bottom: 4px;
  display: flex; align-items: center; gap: 5px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.rank-qnum {
  background: linear-gradient(135deg,#4f46e5,#0891b2);
  color: #fff; font-size: 10px; font-weight: 700;
  padding: 1px 6px; border-radius: 4px; flex-shrink: 0;
}
.rank-bar-wrap { height: 8px; background: #f1f5f9; border-radius: 4px; overflow: hidden; }
.rank-bar { height: 100%; border-radius: 4px; transition: width .6s ease; }
.rank-green  { background: rgba(5,150,105,.7); }
.rank-blue   { background: rgba(8,145,178,.7); }
.rank-purple { background: rgba(99,102,241,.7); }
.rank-orange { background: rgba(217,119,6,.7); }
.rank-score {
  font-size: 14px; font-weight: 800; flex-shrink: 0; width: 38px; text-align: right;
}

/* ── 도넛 범례 ── */
.doughnut-wrap { display: flex; align-items: center; gap: 32px; flex-wrap: wrap; }
.doughnut-legend { display: flex; flex-direction: column; gap: 10px; min-width: 200px; }
.dl-item { display: flex; align-items: center; gap: 8px; }
.dl-dot { width: 12px; height: 12px; border-radius: 3px; flex-shrink: 0; }
.dl-label { font-size: 13px; color: #475569; flex: 1; }
.dl-count { font-size: 13px; font-weight: 700; color: #1e293b; }
.dl-pct { font-size: 12px; color: #94a3b8; width: 44px; text-align: right; }

/* ── 테이블 ── */
.table-info { font-size: 12px; color: #94a3b8; margin-bottom: 12px; }
.table-info strong { color: #4f46e5; }
.search-input {
  background: #f8faff; border: 1.5px solid rgba(99,102,241,.18);
  border-radius: 8px; padding: 8px 14px;
  font-size: 13px; color: #1e293b; font-family: inherit;
  outline: none; width: 180px; transition: .2s;
}
.search-input:focus { border-color: #6366f1; box-shadow: 0 0 0 3px rgba(99,102,241,.1); background:#fff; }
.export-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 8px 16px; border-radius: 8px; font-size: 12px; font-weight: 700;
  background: rgba(5,150,105,.1); border: 1.5px solid rgba(5,150,105,.25);
  color: #059669; cursor: pointer; font-family: inherit; transition: .2s;
}
.export-btn:hover { background: rgba(5,150,105,.18); }
.table-wrap { overflow-x: auto; border-radius: 12px; }
.resp-table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 1000px; }
.resp-table th {
  background: rgba(99,102,241,.06); color: #64748b;
  padding: 10px 12px; text-align: center; font-weight: 700;
  border-bottom: 1.5px solid rgba(99,102,241,.1); white-space: nowrap;
}
.resp-table td {
  padding: 10px 12px; text-align: center;
  border-bottom: 1px solid rgba(99,102,241,.07); color: #64748b;
}
.resp-table tr:hover td { background: rgba(99,102,241,.04); }
.resp-table tr:last-child td { border-bottom: none; }
.row-no { color: #cbd5e1; font-size: 12px; }
.score-cell { font-weight: 700; }
.score-cell.s5 { color: #059669; }
.score-cell.s4 { color: #0891b2; }
.score-cell.s3 { color: #6366f1; }
.score-cell.s2 { color: #d97706; }
.score-cell.s1 { color: #dc2626; }
.avg-cell { font-weight: 800; color: #4f46e5; }
.date-cell { font-size: 11px; color: #94a3b8; }
.detail-btn {
  width: 30px; height: 30px; border-radius: 7px; border: 1px solid rgba(99,102,241,.2);
  background: rgba(99,102,241,.07); color: #6366f1; cursor: pointer;
  font-size: 12px; display: grid; place-items: center; transition: .2s;
}
.detail-btn:hover { background: rgba(99,102,241,.15); }
.no-data { text-align: center; padding: 32px; color: #94a3b8; font-size: 14px; }

/* ── 페이지네이션 ── */
.pagination { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; margin-top: 20px; }
.page-btn {
  min-width: 36px; height: 36px; padding: 0 10px; border-radius: 8px;
  border: 1px solid rgba(99,102,241,.2); background: #fff;
  color: #475569; font-size: 13px; font-weight: 600; cursor: pointer;
  font-family: inherit; transition: .2s;
}
.page-btn:hover { border-color: #6366f1; color: #6366f1; }
.page-btn.active { background: #4f46e5; border-color: #4f46e5; color: #fff; }
.page-dots { font-size: 14px; color: #94a3b8; display: flex; align-items: center; padding: 0 4px; }

/* ── 건의사항 공유 ── */
.comment-section { margin-bottom: 28px; }
.comment-qtitle {
  display: flex; align-items: center; gap: 10px;
  font-size: 15px; font-weight: 700; margin-bottom: 12px;
  padding-bottom: 10px; border-bottom: 1px solid rgba(99,102,241,.1);
  color: #1e293b;
}
.q-badge {
  background: linear-gradient(135deg, #4f46e5, #0891b2);
  color: #fff; font-size: 11px; font-weight: 700;
  padding: 3px 10px; border-radius: 999px; flex-shrink: 0;
}
.comment-item {
  background: #fafbff; border: 1px solid rgba(99,102,241,.1);
  border-radius: 10px; padding: 14px 16px; margin-bottom: 8px;
  transition: .2s; box-shadow: 0 1px 4px rgba(99,102,241,.05);
}
.comment-item:hover { border-color: rgba(99,102,241,.25); background: #fff; }
.comment-meta {
  font-size: 12px; color: #94a3b8; margin-bottom: 8px;
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.comment-date { font-size: 11px; color: #cbd5e1; margin-left: auto; }
.cls-badge {
  background: rgba(99,102,241,.1); border: 1px solid rgba(99,102,241,.2);
  color: #6366f1; font-size: 11px; font-weight: 600;
  padding: 2px 8px; border-radius: 999px;
}
.comment-text { font-size: 14px; line-height: 1.6; color: #1e293b; }
.comment-col { text-align: left !important; font-size: 12px; color: #64748b; max-width: 200px; }

/* ── 모달 ── */
.modal-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(15,23,42,.5); backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center; padding: 20px;
  animation: fadeIn .2s ease;
}
.modal-box {
  background: #fff; border-radius: 20px; width: 100%; max-width: 720px;
  max-height: 88vh; overflow-y: auto;
  box-shadow: 0 24px 80px rgba(0,0,0,.2);
  animation: slideUp .3s ease;
}
@keyframes slideUp { from { transform:translateY(24px); opacity:0; } to { transform:translateY(0); opacity:1; } }
.modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 24px 16px; border-bottom: 1px solid rgba(99,102,241,.1);
}
.modal-header h3 { font-size: 16px; font-weight: 700; color: #1e293b; display:flex; align-items:center; gap:8px; }
.modal-close {
  width: 32px; height: 32px; border-radius: 8px; border: none;
  background: #f1f5f9; color: #64748b; cursor: pointer; font-size: 14px;
  display: grid; place-items: center; transition: .2s;
}
.modal-close:hover { background: rgba(220,38,38,.1); color: #dc2626; }
.modal-date { font-size: 12px; color: #94a3b8; padding: 10px 24px; border-bottom: 1px solid rgba(99,102,241,.08); }
.modal-table-wrap { padding: 16px 24px; overflow-x: auto; }
.modal-table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 480px; }
.modal-table th {
  background: rgba(99,102,241,.06); color: #64748b;
  padding: 8px 12px; text-align: center; font-weight: 700;
  border-bottom: 1.5px solid rgba(99,102,241,.1);
}
.modal-table td {
  padding: 9px 12px; border-bottom: 1px solid rgba(99,102,241,.06); color: #475569;
}
.modal-table tr:last-child td { border-bottom: none; }
.modal-q13 {
  margin: 0 24px 24px; padding: 14px 16px;
  background: #f8faff; border: 1px solid rgba(99,102,241,.12); border-radius: 10px;
}
.modal-q13 strong { font-size: 13px; color: #4f46e5; display:flex; align-items:center; gap:6px; margin-bottom:8px; }
.modal-q13 p { font-size: 13px; color: #475569; line-height: 1.6; }

/* ── 문항 분포 (공용) ── */
.dist-card {
  background: #fafbff; border: 1px solid rgba(99,102,241,.1);
  border-radius: 12px; padding: 16px 18px; margin-bottom: 10px;
  transition: .2s;
}
.dist-card:hover { border-color: rgba(99,102,241,.25); }
.dist-header { display:flex; align-items:center; flex-wrap:wrap; gap:10px; margin-bottom:12px; }
.dist-qnum {
  width: 30px; height: 30px; border-radius: 7px; flex-shrink:0;
  background: linear-gradient(135deg,#4f46e5,#0891b2);
  display:grid; place-items:center; font-size:12px; font-weight:700; color:#fff;
}
.dist-qtext { font-size:13px; font-weight:600; flex:1; color:#1e293b; }
.dist-avg { font-size:13px; color:#64748b; margin-left:auto; }
.dist-avg strong { color:#4f46e5; font-size:15px; }
.dist-bars { display:flex; flex-direction:column; gap:5px; }
.dist-row  { display:flex; align-items:center; gap:10px; }
.dist-label { width:36px; font-size:12px; font-weight:700; text-align:right; flex-shrink:0; }
.dist-bar-wrap { flex:1; height:14px; background:rgba(99,102,241,.07); border-radius:7px; overflow:hidden; }
.dist-bar      { height:100%; border-radius:7px; transition:width .6s ease; }
.dist-pct      { width:90px; font-size:12px; color:#64748b; flex-shrink:0; }
.dist-pct small { color:#94a3b8; }

/* ── 로딩 / 빈 상태 ── */
.loading-state, .empty-state {
  text-align: center; padding: 80px 20px; background: #fff;
  border-radius: 16px; border: 1px solid rgba(99,102,241,.1);
}
.spinner {
  width: 48px; height: 48px; border-radius: 50%;
  border: 4px solid rgba(99,102,241,.15);
  border-top-color: #6366f1;
  animation: spin .8s linear infinite; margin: 0 auto 16px;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loading-state p, .empty-state p { color: #64748b; }
.empty-icon {
  width: 72px; height: 72px; border-radius: 50%;
  background: rgba(99,102,241,.08); border: 1px solid rgba(99,102,241,.15);
  display: grid; place-items: center; font-size: 30px;
  color: #94a3b8; margin: 0 auto 20px;
}
.empty-state h2 { font-size: 20px; font-weight: 700; margin-bottom: 8px; color: #1e293b; }

/* ── 삭제 버튼 (테이블 행) ── */
.action-cell { display: flex; align-items: center; justify-content: center; gap: 5px; }
.row-del-btn {
  width: 30px; height: 30px; border-radius: 7px;
  border: 1px solid rgba(220,38,38,.2);
  background: rgba(220,38,38,.06); color: #dc2626;
  cursor: pointer; font-size: 12px;
  display: grid; place-items: center; transition: .2s;
}
.row-del-btn:hover { background: rgba(220,38,38,.15); border-color: rgba(220,38,38,.4); }

/* ── 전체 삭제 버튼 ── */
.delete-all-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 8px 16px; border-radius: 8px;
  font-size: 12px; font-weight: 700;
  background: rgba(220,38,38,.07);
  border: 1.5px solid rgba(220,38,38,.25);
  color: #dc2626; cursor: pointer; font-family: inherit; transition: .2s;
}
.delete-all-btn:hover { background: rgba(220,38,38,.15); }

/* ── 모달 하단 푸터 ── */
.modal-footer {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 24px 20px;
  border-top: 1px solid rgba(99,102,241,.08);
  gap: 10px;
}
.modal-del-btn {
  display: flex; align-items: center; gap: 7px;
  padding: 9px 18px; border-radius: 9px;
  font-size: 13px; font-weight: 700;
  background: rgba(220,38,38,.08);
  border: 1.5px solid rgba(220,38,38,.25);
  color: #dc2626; cursor: pointer; font-family: inherit; transition: .2s;
}
.modal-del-btn:hover { background: rgba(220,38,38,.16); }
.modal-close-btn {
  display: flex; align-items: center; gap: 7px;
  padding: 9px 20px; border-radius: 9px;
  font-size: 13px; font-weight: 600;
  background: #f8faff; border: 1.5px solid rgba(99,102,241,.18);
  color: #64748b; cursor: pointer; font-family: inherit; transition: .2s;
}
.modal-close-btn:hover { border-color: #6366f1; color: #6366f1; }

/* ── 확인 모달 ── */
.confirm-box {
  background: #fff; border-radius: 20px;
  padding: 36px 32px 28px; width: 100%; max-width: 420px;
  box-shadow: 0 24px 80px rgba(0,0,0,.2);
  animation: slideUp .25s ease; text-align: center;
}
.confirm-icon-wrap {
  width: 68px; height: 68px; border-radius: 18px;
  display: grid; place-items: center;
  margin: 0 auto 18px;
}
.confirm-title {
  font-size: 18px; font-weight: 800; color: #1e293b; margin-bottom: 10px;
}
.confirm-msg {
  font-size: 14px; color: #475569; line-height: 1.7; margin-bottom: 22px;
}
.confirm-warn {
  display: inline-block; margin-top: 6px;
  font-size: 12px; color: #dc2626; font-weight: 600;
}
.confirm-input-wrap { margin-bottom: 20px; text-align: left; }
.confirm-input-hint {
  font-size: 12px; color: #64748b; margin-bottom: 8px;
}
.confirm-input-hint kbd {
  background: #f1f5f9; border: 1px solid #cbd5e1;
  border-radius: 4px; padding: 2px 6px;
  font-size: 12px; font-family: monospace; color: #dc2626; font-weight: 700;
}
.confirm-input {
  width: 100%; background: #f8faff;
  border: 1.5px solid rgba(220,38,38,.25); border-radius: 9px;
  padding: 10px 14px; font-size: 14px; font-family: monospace;
  color: #1e293b; outline: none; transition: .2s;
  letter-spacing: .08em; font-weight: 700;
}
.confirm-input:focus { border-color: #dc2626; box-shadow: 0 0 0 3px rgba(220,38,38,.1); }
.confirm-actions {
  display: flex; gap: 10px; justify-content: center;
}
.confirm-cancel {
  flex: 1; padding: 11px 0; border-radius: 10px;
  border: 1.5px solid rgba(99,102,241,.2);
  background: #fff; color: #64748b;
  font-size: 14px; font-weight: 600; font-family: inherit; cursor: pointer;
  transition: .2s;
}
.confirm-cancel:hover { border-color: #6366f1; color: #6366f1; }
.confirm-ok {
  flex: 1; padding: 11px 0; border-radius: 10px;
  border: none; font-size: 14px; font-weight: 700;
  font-family: inherit; cursor: pointer; transition: .2s;
  display: flex; align-items: center; justify-content: center; gap: 7px;
}
.confirm-ok.confirm-danger {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  color: #fff; box-shadow: 0 4px 14px rgba(220,38,38,.3);
}
.confirm-ok.confirm-danger:hover { box-shadow: 0 6px 20px rgba(220,38,38,.45); transform: translateY(-1px); }
.confirm-ok:disabled {
  background: #e2e8f0 !important; color: #94a3b8 !important;
  box-shadow: none !important; cursor: not-allowed; transform: none !important;
}

/* ── 토스트 알림 ── */
.toast {
  position: fixed; bottom: 28px; left: 50%; transform: translateX(-50%) translateY(20px);
  z-index: 9999; display: flex; align-items: center; gap: 10px;
  padding: 13px 22px; border-radius: 12px;
  font-size: 14px; font-weight: 600; font-family: 'Noto Sans KR', sans-serif;
  box-shadow: 0 8px 32px rgba(0,0,0,.18);
  opacity: 0; transition: opacity .3s ease, transform .3s ease;
  white-space: nowrap;
}
.toast.toast-show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast-success { background: #fff; border: 1.5px solid rgba(5,150,105,.3); color: #059669; }
.toast-success i { color: #059669; }
.toast-error   { background: #fff; border: 1.5px solid rgba(220,38,38,.3);  color: #dc2626; }
.toast-error i   { color: #dc2626; }
.toast-info    { background: #fff; border: 1.5px solid rgba(99,102,241,.3); color: #6366f1; }
.toast-info i    { color: #6366f1; }

/* ── 반응형 ── */
@media (max-width: 1024px) {
  .dash-row { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .admin-sidebar {
    position: fixed; left: -240px; top: 0; height: 100vh;
    transition: left .3s ease; z-index: 50;
  }
  .admin-sidebar.open { left: 0; }
  .sidebar-toggle { display: flex !important; }
  .logout-btn-top { display: none; }
  .kpi-grid { grid-template-columns: repeat(2, 1fr); }
  .doughnut-wrap { flex-direction: column; align-items: center; }
}
@media (max-width: 480px) {
  .admin-content { padding: 12px; }
  .kpi-grid { grid-template-columns: 1fr 1fr; }
  .login-card { padding: 32px 22px; }
  .table-controls { width: 100%; }
  .search-input { width: 100%; }
}
