/* lab — /report 영역 공통 스타일 */
*,*::before,*::after { box-sizing: border-box; }
:root {
  --bg: #EEF1F8;
  --surface: #ffffff;
  --ink: #0F1830;
  --ink-2: #4B557A;
  --ink-3: #7A82A0;
  --border: #DEE3F0;
  --primary: #0B1F4A;
  --accent: #00B5D8;
  --accent-2: #6F4BFF;
  --warn: #C7531B;
  --ok: #1B8E5A;
  --shadow-sm: 0 2px 6px rgba(15,24,48,0.05);
  --shadow: 0 6px 22px rgba(15,24,48,0.08);
  --radius: 14px;
  --radius-sm: 10px;
}
html, body { margin: 0; padding: 0; }
body {
  font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  background: var(--bg);
  color: var(--ink);
  font-size: 15px; line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
.page { max-width: 880px; margin: 0 auto; padding: 0 16px 60px; }

/* topbar */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 0;
  color: var(--ink-2);
  font-size: 13px;
  flex-wrap: wrap;
  gap: 6px;
}
.topbar .brand {
  color: var(--primary); font-weight: 800;
  text-decoration: none;
}
.topbar .who { color: var(--ink-2); }
.topbar form { display: inline; }
.topbar .logout {
  background: transparent; border: none; color: var(--ink-3);
  font: inherit; cursor: pointer; padding: 0; margin-left: 10px;
  text-decoration: underline;
}

/* hero */
.hero {
  margin: 0 -16px 16px;
  padding: 28px 22px 22px;
  background:
    radial-gradient(circle at 100% 0%, rgba(0,181,216,0.55) 0%, rgba(0,181,216,0) 55%),
    radial-gradient(circle at 0% 100%, rgba(111,75,255,0.35) 0%, rgba(111,75,255,0) 60%),
    linear-gradient(135deg, #0B1F4A 0%, #1A3A8C 100%);
  color: #fff;
}
.hero .badge {
  display: inline-block; margin-bottom: 8px;
  padding: 4px 10px;
  border: 1px solid rgba(255,255,255,0.45);
  border-radius: 999px;
  font-size: 11px; letter-spacing: 0.08em;
}
.hero h1 { margin: 0; font-size: 22px; font-weight: 800; letter-spacing: -0.02em; }
.hero .sub { margin-top: 4px; font-size: 13px; color: rgba(255,255,255,0.78); }
.hero h1 .role-switch {
  margin-left: 50px;
  font-size: 13px;
  font-weight: 700;
  color: rgba(255,255,255,0.55);
  text-decoration: none;
  letter-spacing: 0;
  vertical-align: middle;
}
.hero h1 .role-switch:hover { color: rgba(255,255,255,0.9); text-decoration: underline; }

/* card */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 16px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 14px;
}

/* button */
.btn {
  display: inline-block;
  min-height: 48px;
  padding: 0 18px;
  border-radius: var(--radius-sm);
  font: 700 15px inherit;
  cursor: pointer;
  text-decoration: none;
  border: none;
  line-height: 48px;
  text-align: center;
  letter-spacing: -0.01em;
}
.btn-primary {
  background: linear-gradient(135deg, #0B1F4A 0%, #6F4BFF 100%);
  color: #fff;
  box-shadow: 0 4px 14px rgba(111,75,255,0.35);
}
.btn-secondary {
  background: var(--surface); color: var(--primary);
  border: 1.5px solid var(--primary);
}
.btn-block { display: block; width: 100%; }

/* form */
input[type=text], input[type=password], input[type=tel] {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font: inherit;
  background: #fff;
}
input:focus { outline: none; border-color: var(--accent-2); box-shadow: 0 0 0 3px rgba(111,75,255,0.12); }
label { display: block; font-size: 12px; color: var(--ink-3); margin-bottom: 4px; font-weight: 600; }
.field { margin-bottom: 12px; }

/* alert */
.alert {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  background: #FFF1EC;
  border: 1px solid #F5C7B7;
  color: var(--warn);
  margin-bottom: 12px;
}

/* activity card */
.activity-card { padding: 0; overflow: hidden; transition: all .15s ease; }
.activity-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.activity-link {
  display: block;
  padding: 18px 16px;
  text-decoration: none;
  color: inherit;
}
.activity-actions {
  border-top: 1px solid var(--border);
  padding: 10px 16px;
  background: #FAFBFE;
  display: flex; justify-content: flex-end;
  margin: 0;
}
.btn-reset {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--ink-2);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font: 600 13px inherit;
  transition: all .12s ease;
}
.btn-reset:hover { color: var(--warn); border-color: var(--warn); }

/* 목록으로 링크 */
.back-link { padding: 8px 0 4px; }
.back-link a {
  color: var(--ink-2);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
}
.back-link a:hover { color: var(--accent-2); }

/* 메인 메뉴 카드 */
.menu-card {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: inherit;
  padding: 22px 20px;
  transition: all .15s ease;
}
.menu-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.menu-icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  background: linear-gradient(135deg, #00B5D8, #6F4BFF);
  display: grid; place-items: center;
  font-size: 26px; color: #fff;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(111,75,255,0.25);
}
.menu-text { flex: 1; min-width: 0; }
.menu-title { font-size: 18px; font-weight: 800; color: var(--ink); letter-spacing: -0.02em; }
.menu-desc { font-size: 13px; color: var(--ink-2); margin-top: 2px; }
.menu-arrow { color: var(--ink-3); font-size: 26px; font-weight: 300; line-height: 1; }
.activity-row { display: flex; align-items: flex-start; gap: 14px; }
.activity-title { font-size: 18px; font-weight: 800; letter-spacing: -0.02em; color: var(--ink); }
.activity-desc { margin-top: 4px; font-size: 13px; color: var(--ink-2); }
.activity-meta { margin-top: 10px; font-size: 12px; color: var(--ink-3); }
.status-pill {
  display: inline-block; padding: 4px 10px; border-radius: 999px;
  font-size: 12px; font-weight: 700; white-space: nowrap;
}
.status-submitted { background: #ECFAF2; color: var(--ok); }
.status-draft     { background: #FFF7E6; color: #A36800; }
.status-todo      { background: #EEF2FF; color: var(--accent-2); }
.status-open      { background: #ECFAF2; color: var(--ok); }
.status-closed    { background: #EEF0F4; color: var(--ink-3); }

/* 교수 카드 — 마감/마감취소 버튼 */
.prof-status-actions { gap: 8px; }
.prof-status-actions form { margin: 0; }
.btn-status {
  background: #fff;
  border: 1px solid var(--border);
  color: var(--ink-2);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font: 600 12px inherit;
  transition: all .12s ease;
}
.btn-status:disabled {
  background: #F4F5F7;
  color: var(--ink-3);
  cursor: not-allowed;
  opacity: 0.6;
}
.btn-close:not(:disabled):hover  { color: var(--warn);    border-color: var(--warn); }
.btn-reopen:not(:disabled):hover { color: var(--accent-2); border-color: var(--accent-2); }

/* helpers */
.muted { color: var(--ink-3); }
.center { text-align: center; }

/* 교수 화면 — 요약 카드 */
.prof-summary {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.prof-summary-item {
  background: #F7F9FE;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  text-align: center;
}
.prof-summary-label { font-size: 11px; color: var(--ink-3); letter-spacing: 0.04em; }
.prof-summary-value { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; color: var(--ink); margin-top: 2px; }
.prof-summary-value.ok    { color: var(--ok); }
.prof-summary-value.warn  { color: #A36800; }
.prof-summary-value.muted { color: var(--ink-3); }
.prof-summary-grade { margin-top: 12px; font-size: 12px; color: var(--ink-2); text-align: center; }

/* 교수 화면 — 학생 표 */
.prof-table-card { padding: 14px 16px; }
.prof-table-title { font-size: 14px; font-weight: 800; color: var(--ink); margin-bottom: 10px; }
.prof-table-wrap { overflow-x: auto; margin: 0 -16px; padding: 0 16px; }
.prof-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  min-width: 540px;
}
.prof-table th, .prof-table td {
  padding: 8px 10px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.prof-table th {
  font-size: 11px; font-weight: 700; color: var(--ink-3);
  letter-spacing: 0.04em; text-transform: uppercase;
  background: #FAFBFE;
  text-align: center;
}
.prof-table td.num { text-align: right; font-variant-numeric: tabular-nums; }
.prof-table th.num { text-align: center; }
.prof-table td.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; }
.prof-table td.small { font-size: 11px; color: var(--ink-2); }
.prof-table tbody tr:hover { background: #F7F9FE; }
.prof-row-link {
  color: var(--accent-2); font-weight: 700; font-size: 12px;
  text-decoration: none; white-space: nowrap;
}
.prof-row-link:hover { text-decoration: underline; }

.prof-table .cell-short { display: none; }

@media (max-width: 520px) {
  .prof-summary { grid-template-columns: repeat(2, 1fr); }
  .prof-table .col-id { display: none; }
  .prof-table { min-width: 0; }
  .prof-table .cell-full  { display: none; }
  .prof-table .cell-short { display: inline; }
}
