/* =========================================================================
   보이스 플래너 · B안 (흰 바탕). 토큰은 docs 디자인 핸드오프 tokens.css 기준.
   시안에 없는 색·크기는 만들지 않는다. 과목색 옅은 바탕은 color-mix로 계산.
   ========================================================================= */

:root {
  --font-sans: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
  --text-base: 15px;
  --leading-base: 1.5;
  --tracking-base: -0.011em;
  --tracking-title: -0.035em;
  --tracking-hero: -0.045em;

  --fs-hero: 48px;
  --fs-h1: 26px;
  --fs-stat: 34px;
  --fs-h2: 18px;
  /* 본문 타입 스케일: 12 캡션·배지 / 13 메타 / 14 보조 / 15 본문 / 17 강조 / 18 섹션 / 26 페이지 제목.
     반 픽셀(13.5·14.5) 크기는 쓰지 않는다 */

  --ink: #1d1d1f;
  --ink-2: #48484a;
  --ink-3: #6e6e73;
  --ink-4: #86868b;
  --ink-on-gray: #636366;
  --ink-disabled: #aeaeb2;

  --bg: #ffffff;
  --fill-1: #f2f2f5;
  --fill-2: #f7f7f8;
  --fill-3: #fafafb;
  --fill-hover: #f5f5f7;
  --bubble-user: #f4f4f6;
  --avatar: #e8e8ed;

  --line: #e5e5ea;
  --line-2: #ececf0;
  --line-3: #f0f0f3;
  --line-strong: #d2d2d7;

  --blue: #0071e3;
  --blue-link: #0066cc;
  --blue-ink: #0058b0;
  --blue-tint: #e6f0fb;
  --blue-tint-2: #f2f7fe;
  --blue-today: #f5f9ff;
  --blue-field-line: #d6e4f5;
  --focus-ring: 0 0 0 4px rgba(0, 113, 227, 0.14);

  --red: #d70015;
  --red-text: #b0000f;
  --red-tint: #fdecee;
  --red-line: #f3c2c7;
  --red-live: #ff3b30;
  --error-ring: 0 0 0 4px rgba(215, 0, 21, 0.1);

  --orange-text: #b25000;
  --orange-strong: #8a3e00;
  --orange-tint: #fff4e5;
  --orange-dot: #ff9f0a;

  --green: #34c759;
  --green-text: #1f7a35;
  --green-tint: #eaf7ed;

  --gray-dot: #8e8e93;
  --gray-dot-2: #c7c7cc;

  --r-pill: 9999px;
  --r-composer: 14px;
  --r-dialog: 18px;
  --r-panel: 14px;
  --r-card: 12px;
  --r-item: 12px;
  --r-field: 10px;
  --r-tile: 8px;

  --shadow-float: 0 2px 6px rgba(0, 0, 0, 0.12), 0 12px 32px rgba(0, 0, 0, 0.22);
  --shadow-panel: 0 2px 8px rgba(0, 0, 0, 0.08), 0 24px 64px rgba(0, 0, 0, 0.2);
  --shadow-toast: 0 2px 6px rgba(0, 0, 0, 0.06), 0 12px 32px rgba(0, 0, 0, 0.12);
  --shadow-dialog: 0 2px 8px rgba(0, 0, 0, 0.08), 0 30px 80px rgba(0, 0, 0, 0.24);
  --shadow-card-hover: 0 4px 14px rgba(0, 0, 0, 0.06);
  --shadow-seg: 0 1px 2px rgba(0, 0, 0, 0.08);
  --ring-inner: 0 0 0 1px #ececf0;
  --overlay: rgba(0, 0, 0, 0.3);

  --header-h: 64px;
  --header-pad-x: 28px;
  --page-pad-x: clamp(24px, 3vw, 56px); /* 본문 좌우 여백 (1280px에서 약 40px) */
  --content-wide: 1280px; /* 대시보드·할 일·시간표·리포트·관리자 */
  --content-narrow: 960px; /* 메모 목록·받은 편지함·연동 (한 줄 목록·폼) */
  --fab-gap: 28px;

  --ease-out: cubic-bezier(0.2, 0.7, 0.2, 1);
  --dur-fast: 0.15s;
  --dur-rise: 0.3s;
  --skeleton-cycle: 1.4s;

  /* 흰 체크 (체크박스·둥근 체크 공용) */
  --check-svg: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E");
  --chevron-svg: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2386868b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}

/* ---------- 기본 ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  scrollbar-gutter: stable;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-base);
  letter-spacing: var(--tracking-base);
  word-break: keep-all;
  -webkit-font-smoothing: antialiased;
}
h1,
h2,
h3,
p,
ul,
ol {
  margin: 0;
}
ul,
ol {
  padding: 0;
  list-style: none;
}
p,
li,
h1,
h2,
h3 {
  text-wrap: pretty;
}
button,
input,
select,
textarea {
  font-family: inherit;
  font-size: inherit;
  letter-spacing: inherit;
  color: inherit;
}
input::placeholder,
textarea::placeholder {
  color: var(--ink-3);
  opacity: 1;
}
a {
  color: var(--blue-link);
  text-decoration: none;
}
a:hover {
  color: var(--blue-ink);
}
:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
::selection {
  background: var(--blue-tint);
}
.hidden {
  display: none !important;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.num,
.tabular {
  font-variant-numeric: tabular-nums;
}
.muted {
  color: var(--ink-3);
}
.fine {
  font-size: 13px;
  color: var(--ink-3);
}
.grow {
  flex: 1;
  min-width: 0;
}
.clamp-1 {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.i {
  display: inline-block;
  flex: none;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: -0.2em;
}
.i.sm {
  width: 14px;
  height: 14px;
  stroke-width: 2;
}
.link {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-size: 14px;
  font-weight: 600;
  color: var(--blue-link);
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
}
@keyframes shine {
  from {
    background-position: 200% 0;
  }
  to {
    background-position: -200% 0;
  }
}
@keyframes shake {
  20%,
  60% {
    transform: translateX(-6px);
  }
  40%,
  80% {
    transform: translateX(6px);
  }
}
@keyframes blink {
  50% {
    opacity: 0;
  }
}
@keyframes ring {
  from {
    box-shadow: 0 0 0 0 rgba(255, 59, 48, 0.28);
  }
  to {
    box-shadow: 0 0 0 22px rgba(255, 59, 48, 0);
  }
}
@keyframes wave {
  50% {
    transform: scaleY(0.35);
  }
}

/* ---------- 로고 (검정 원 + 막대 3개) ---------- */
.logo {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  gap: 2.5px;
  width: 28px;
  height: 28px;
  border-radius: var(--r-pill);
  background: var(--ink);
}
.logo i {
  width: 2.5px;
  height: 8px;
  border-radius: 2px;
  background: #fff;
}
.logo i:nth-child(2) {
  height: 13px;
}
.logo i:nth-child(3) {
  height: 10px;
}
.logo.sm {
  width: 26px;
  height: 26px;
  gap: 2px;
}
.logo.sm i {
  width: 2px;
  height: 6px;
}
.logo.sm i:nth-child(2) {
  height: 11px;
}
.logo.sm i:nth-child(3) {
  height: 8px;
}

/* ---------- 상단 내비 ---------- */
.gnav {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 20px;
  height: var(--header-h);
  padding: 0 var(--header-pad-x);
  border-bottom: 1px solid var(--line-2);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: saturate(180%) blur(14px);
}
.brand {
  display: flex;
  flex: none;
  align-items: center;
  gap: 9px;
  margin-right: 8px;
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.brand:hover {
  color: var(--ink);
}
.gnav-links {
  display: flex;
  flex: 1;
  min-width: 0;
  gap: 2px;
  overflow-x: auto;
  scrollbar-width: none;
}
.gnav-links a {
  display: flex;
  flex: none;
  align-items: center;
  gap: 6px;
  height: 36px;
  padding: 0 12px;
  border-radius: var(--r-pill);
  color: var(--ink-2);
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  transition: background-color var(--dur-fast) ease;
}
.gnav-links a:hover {
  background: var(--fill-1);
  color: var(--ink);
}
.gnav-links a[aria-current="page"] {
  background: var(--fill-1);
  color: var(--ink);
  font-weight: 600;
}
/* 데스크톱 주 메뉴는 글자만. 아이콘은 모바일 하단 탭에서만 보인다 */
.gnav-links a > .i {
  display: none;
}
.nav-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: var(--r-pill);
  background: var(--blue);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.nav-badge:empty {
  display: none;
}
.gnav-user {
  display: flex;
  flex: none;
  align-items: center;
  gap: 10px;
}
.avatar {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: var(--r-pill);
  background: var(--avatar);
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
}
.gnav-user .name {
  font-size: 14px;
  font-weight: 500;
}
/* 음성 메모: 서비스의 핵심 행동이라 메뉴 줄이 아닌 오른쪽 검정 버튼 */
.gnav-memo[aria-current="page"] {
  box-shadow: 0 0 0 3px var(--fill-1);
}
/* 프로필 메뉴 (리포트·연동·관리자·로그아웃) */
.user-menu {
  position: relative;
}
.user-menu summary {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 10px 0 5px;
  border-radius: var(--r-pill);
  cursor: pointer;
  list-style: none;
}
.user-menu summary::-webkit-details-marker {
  display: none;
}
.user-menu summary:hover,
.user-menu[open] summary,
.user-menu.on summary {
  background: var(--fill-1);
}
.user-menu .chev {
  color: var(--ink-3);
  transform: rotate(90deg);
  transition: transform var(--dur-fast) ease;
}
.user-menu[open] .chev {
  transform: rotate(-90deg);
}
.user-menu .menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 50;
  min-width: 220px;
  padding: 6px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-item);
  background: var(--bg);
  box-shadow: var(--shadow-toast);
}
.menu-who {
  display: flex;
  flex-direction: column;
  padding: 8px 12px 10px;
  margin-bottom: 4px;
  border-bottom: 1px solid var(--line-3);
  font-size: 14px;
}
.menu-who span {
  color: var(--ink-3);
  font-size: 13px;
}
.user-menu .menu a,
.user-menu .menu .logout {
  display: flex;
  align-items: center;
  width: 100%;
  height: 40px;
  padding: 0 12px;
  border: 0;
  border-radius: var(--r-tile);
  background: none;
  color: var(--ink);
  font-size: 14px;
  text-align: left;
  cursor: pointer;
}
.user-menu .menu a:hover,
.user-menu .menu .logout:hover {
  background: var(--fill-hover);
  text-decoration: none;
}
.user-menu .menu a[aria-current="page"] {
  font-weight: 600;
}
.user-menu .menu .logout {
  margin-top: 4px;
  border-top: 1px solid var(--line-3);
  border-radius: 0 0 var(--r-tile) var(--r-tile);
  color: var(--ink-2);
}

/* ---------- 페이지 틀 ---------- */
.container {
  /* 본문 폭은 두 가지뿐: 넓은 화면(1280)과 목록·폼 화면(960). 큰 모니터에서도 가운데에 모은다 */
  max-width: calc(var(--content-wide) + 2 * var(--page-pad-x));
  margin: 0 auto;
  padding: 32px var(--page-pad-x) 120px;
}
.container.narrow,
.container.settings {
  max-width: calc(var(--content-narrow) + 2 * var(--page-pad-x));
}
.page-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}
.page-head h1 {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px;
  font-size: var(--fs-h1);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: var(--tracking-title);
}
.page-head h1 .sub {
  color: var(--ink-3);
  font-weight: 500;
}
.page-head h1 .count {
  color: var(--ink-3);
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.page-head p {
  margin-top: 4px;
  color: var(--ink-3);
  font-size: 15px;
}
.page-head .actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.back {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin: 0 0 14px -2px;
  color: var(--ink-2);
  font-size: 14px;
  font-weight: 500;
}
.back:hover {
  color: var(--ink);
}
.stack > * + * {
  margin-top: 20px;
}
.section-title {
  margin: 36px 0 12px;
  font-size: var(--fs-h2);
  font-weight: 600;
  letter-spacing: -0.02em;
}

/* ---------- 버튼 ---------- */
.btn {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 40px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: var(--r-pill);
  background: var(--ink);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition:
    transform 0.12s ease,
    background-color var(--dur-fast) ease,
    border-color var(--dur-fast) ease;
}
.btn:hover {
  background: #000;
  color: #fff;
}
.btn:active {
  transform: scale(0.96);
}
.btn.line {
  border-color: var(--line-strong);
  background: #fff;
  color: var(--ink);
}
.btn.line:hover {
  background: var(--fill-hover);
}
.btn.gray {
  background: var(--fill-1);
  color: var(--ink);
}
.btn.gray:hover {
  background: var(--avatar);
}
.btn.danger {
  background: var(--red);
  color: #fff;
}
.btn.danger:hover {
  background: var(--red-text);
}
.btn.danger-line {
  border-color: var(--red-line);
  background: #fff;
  color: var(--red);
}
.btn.danger-line:hover {
  background: var(--red-tint);
}
.btn.text {
  height: 36px;
  padding: 0 4px;
  background: none;
  color: var(--blue-link);
}
.btn.text:hover {
  color: var(--blue-ink);
}
.btn.sm {
  height: 36px;
  padding: 0 14px;
  font-size: 14px;
}
.btn.lg {
  height: 44px;
  padding: 0 20px;
  font-size: 15px;
}
.btn.xl {
  width: 100%;
  height: 50px;
  font-size: 16px;
}
.btn:disabled,
.btn.is-off {
  border-color: transparent;
  background: var(--fill-1);
  color: var(--ink-4);
  cursor: not-allowed;
  transform: none;
}
/* 진행 중: 버튼 안 스피너, 다시 못 누름 */
.btn.loading {
  pointer-events: none;
  opacity: 0.85;
}
.btn.loading > .i {
  display: none;
}
.btn.loading::before {
  content: "";
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: var(--r-pill);
  animation: spin 0.8s linear infinite;
}
.btn.line.loading::before,
.btn.gray.loading::before {
  border-color: var(--line);
  border-top-color: var(--ink);
}
.icon-btn {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: var(--r-pill);
  background: transparent;
  color: var(--ink-4);
  cursor: pointer;
  transition:
    background-color var(--dur-fast) ease,
    color var(--dur-fast) ease;
}
.icon-btn:hover {
  background: var(--fill-hover);
  color: var(--ink);
}
.icon-btn.danger:hover {
  background: var(--red-tint);
  color: var(--red);
}

/* ---------- 카드 ---------- */
.card {
  border: 1px solid var(--line);
  border-radius: var(--r-panel);
  background: #fff;
  padding: 20px 22px;
}
.card.flush {
  padding: 0;
  overflow: hidden;
}
.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 36px;
  margin-bottom: 12px;
}
.card-head h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: var(--fs-h2);
  font-weight: 600;
  letter-spacing: -0.02em;
}
.card-head h2 .fine {
  font-weight: 500;
  letter-spacing: 0;
}
.soft {
  border-radius: var(--r-panel);
  background: var(--fill-2);
}
.grid-2 {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  gap: 20px;
  align-items: stretch; /* 나란히 놓인 카드는 아래 끝을 맞춘다 */
}
.grid-2.even {
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
}

/* 숫자 카드 */
/* 지표 묶음: 카드 4장 대신 한 줄 띠 안에서 세로선으로 나눈다 (모든 정보를 카드로 감싸지 않기) */
.stat-grid.strip {
  gap: 0;
  border: 1px solid var(--line);
  border-radius: var(--r-panel);
  overflow: hidden;
}
.stat-grid.strip .stat {
  border: 0;
  border-radius: 0;
}
.stat-grid.strip .stat + .stat {
  border-left: 1px solid var(--line-2);
}
.chart-empty {
  display: grid;
  place-content: center;
  gap: 4px;
  min-height: 170px;
  border-radius: var(--r-item);
  background: var(--fill-2);
  color: var(--ink-3);
  font-size: 14px;
  text-align: center;
}
.chart-empty .title {
  color: var(--ink);
  font-weight: 600;
}
.report-done {
  margin-top: 28px;
}
.report-done h2 {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 12px;
  font-size: var(--fs-h2);
  font-weight: 600;
}
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}
.stat {
  display: block;
  min-width: 0;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  background: #fff;
  color: var(--ink);
  transition:
    border-color var(--dur-fast) ease,
    box-shadow var(--dur-fast) ease;
}
a.stat:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow-card-hover);
  color: var(--ink);
}
.stat-grid.strip a.stat:hover {
  box-shadow: none;
  background: var(--fill-3);
}
.stat .label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--ink-3);
  font-size: 13px;
  font-weight: 500;
}
.stat .label .i {
  width: 16px;
  height: 16px;
  color: var(--ink-4);
}
.stat .value {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
  font-size: var(--fs-stat);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.stat .value.red {
  color: var(--red);
}
.stat .hint {
  margin-top: 2px;
  overflow: hidden;
  color: var(--ink-3);
  font-size: 13px;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.stat .hint.up {
  color: var(--green-text);
  font-weight: 600;
}
.stat .hint.down {
  color: var(--red);
  font-weight: 600;
}
.new-dot {
  width: 8px;
  height: 8px;
  border-radius: var(--r-pill);
  background: var(--blue);
}
.meter {
  height: 6px;
  margin-top: 10px;
  overflow: hidden;
  border-radius: var(--r-pill);
  background: var(--fill-1);
}
.meter > span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--c, var(--ink));
}

/* 목록 (카드 안 행) */
.list > * + * {
  border-top: 1px solid var(--line-3);
}
.row {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 64px;
  padding: 12px 0;
  color: var(--ink);
}
a.row:hover {
  color: var(--ink);
}
.card.flush .row,
.list-card .row {
  padding: 14px 18px;
}
.list-card {
  border: 1px solid var(--line);
  border-radius: var(--r-panel);
  background: #fff;
  overflow: hidden;
}
a.row {
  transition: background-color var(--dur-fast) ease;
}
.list-card a.row:hover {
  background: var(--fill-3);
}
.row-main {
  flex: 1;
  min-width: 0;
}
.row-title {
  display: block;
  overflow: hidden;
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.row-title.struck {
  color: var(--ink-3);
  font-weight: 500;
  text-decoration: line-through;
}
.row-sub {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 6px;
  margin-top: 3px;
  color: var(--ink-3);
  font-size: 13px;
}
.row-end {
  display: flex;
  flex: none;
  align-items: center;
  gap: 8px;
}
.row .chev {
  color: var(--ink-disabled);
}
.tile {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--r-field);
  background: var(--fill-1);
  color: var(--ink-2);
}
.tile.blue {
  background: var(--blue-tint-2);
  color: var(--blue-ink);
}
.tile.course {
  background: color-mix(in srgb, var(--c) 18%, #fff);
}
.tile.course::before {
  content: "";
  width: 12px;
  height: 12px;
  border-radius: var(--r-pill);
  background: var(--c);
}
.dot-sep::before {
  content: "·";
  margin-right: 6px;
}

/* ---------- 칩 · 배지 ---------- */
.chip,
.due,
.badge {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: 6px;
  height: 24px;
  padding: 0 9px;
  border-radius: var(--r-pill);
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
}
/* 과목 표시: 테두리·바탕 없이 과목색 점 + 글자. 화면 어디서든 '칩(채운 모양)'은 마감·상태 하나만 남긴다 */
.chip {
  padding: 0 2px 0 0;
  border: 0;
  background: none;
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 500;
}
.chip::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: var(--r-pill);
  background: var(--c, var(--gray-dot));
}
.chip.none {
  color: var(--ink-3);
}
.chip.none::before {
  background: var(--gray-dot-2);
}
.row-sub .chip,
.chip.sm {
  height: 22px;
  padding: 0 2px 0 0;
}
.row-sub .chip::before,
.chip.sm::before {
  width: 6px;
  height: 6px;
}
/* 마감 칩 */
.due {
  background: var(--fill-1);
  color: var(--ink-on-gray);
  font-variant-numeric: tabular-nums;
}
.due:empty {
  display: none;
}
.due.due-red {
  background: var(--red-tint);
  color: var(--red);
}
/* 이미 지난 마감: 24시간 이내(옅은 빨강)와 모양으로 구분되게 진한 빨강으로 채운다 */
.due.due-over {
  background: var(--red);
  color: #fff;
}
.due.due-orange {
  background: var(--orange-tint);
  color: var(--orange-text);
}
.due.done {
  background: var(--green-tint);
  color: var(--green-text);
}
/* 상태 배지 */
.badge {
  background: var(--fill-1);
  color: var(--ink-2);
}
.badge .i {
  width: 12px;
  height: 12px;
  stroke-width: 2.2;
}
.badge.blue {
  background: var(--blue-tint);
  color: var(--blue-ink);
}
.badge.green {
  background: var(--green-tint);
  color: var(--green-text);
}
.badge.orange {
  background: var(--orange-tint);
  color: var(--orange-text);
}
.badge.ink {
  background: var(--ink);
  color: #fff;
}
.badge.ai {
  height: 22px;
  padding: 0 8px;
  background: var(--blue-tint);
  color: var(--blue-ink);
  font-size: 12px;
}
/* 출처 배지 (음성 메모 / 음성 비서 / 메일) */
.src {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 22px;
  padding: 0 8px;
  border-radius: var(--r-pill);
  background: var(--fill-1);
  color: var(--ink-2);
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
}
.src .i {
  width: 12px;
  height: 12px;
}
/* 우선순위 막대: 높음 3칸 · 보통 2칸 · 낮음 1칸 */
.prio {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ink-2);
  font-size: 12px;
}
.prio .bars {
  display: inline-flex;
  align-items: flex-end;
  gap: 2px;
  height: 12px;
}
.prio .bars i {
  width: 3px;
  height: 6px;
  border-radius: 1px;
  background: var(--line-strong);
}
.prio .bars i:nth-child(2) {
  height: 9px;
}
.prio .bars i:nth-child(3) {
  height: 12px;
}
.prio.low .bars i:nth-child(1),
.prio.mid .bars i:nth-child(-n + 2),
.prio.high .bars i {
  background: var(--ink);
}
/* 상태 점 (연결됨 · 만료 · 안 됨) */
.status-dot {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ink-3);
  font-weight: 600;
}
.status-dot::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: var(--r-pill);
  background: var(--gray-dot);
}
.status-dot.ok {
  color: var(--green-text);
}
.status-dot.ok::before {
  background: var(--green);
}
.status-dot.warn {
  color: var(--orange-text);
}
.status-dot.warn::before {
  background: var(--orange-dot);
}
.status-dot.live {
  color: var(--red);
}
.status-dot.live::before {
  background: var(--red-live);
}
.status-dot.blue {
  color: var(--blue-ink);
}
.status-dot.blue::before {
  background: var(--blue);
}

/* ---------- 체크 ---------- */
/* 둥근 체크(할 일 카드): 20px, 누를 영역 34px */
.check {
  position: relative;
  display: inline-block;
  flex: none;
  width: 20px;
  height: 20px;
  padding: 0;
  border: 1.5px solid var(--gray-dot);
  border-radius: var(--r-pill);
  background: #fff;
  cursor: pointer;
  transition:
    background-color var(--dur-fast) ease,
    border-color var(--dur-fast) ease;
}
button.check::after {
  content: "";
  position: absolute;
  inset: -8px;
}
button.check:hover {
  border-color: var(--ink-2);
}
.check.on {
  border-color: var(--blue);
  background: var(--blue) var(--check-svg) center / 12px no-repeat;
}
/* 네모 체크(할 일 후보) */
input[type="checkbox"].check {
  margin: 0;
  border-radius: 6px;
  appearance: none;
}
input[type="checkbox"].check:checked {
  border-color: var(--blue);
  background: var(--blue) var(--check-svg) center / 12px no-repeat;
}

/* ---------- 입력 ---------- */
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.field + .field {
  margin-top: 16px;
}
.field label,
.label {
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
}
.field label small {
  color: var(--ink-3);
  font-size: 13px;
  font-weight: 500;
}
.input,
.field input,
.field select,
select.pill,
input.pill {
  width: 100%;
  height: 44px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-field);
  background-color: #fff;
  font-size: 15px;
  transition:
    border-color var(--dur-fast) ease,
    box-shadow var(--dur-fast) ease;
}
select {
  appearance: none;
  padding-right: 34px !important;
  background: #fff var(--chevron-svg) right 12px center / 14px no-repeat;
  cursor: pointer;
}
/* 알약 모양 select·작은 입력 (필터, 우선순위, 마감) */
select.pill,
input.pill {
  width: auto;
  height: 40px;
  border-radius: var(--r-pill);
  font-size: 14px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
input:focus,
select:focus,
textarea:focus {
  outline: none;
}
.input:focus,
.field input:focus,
.field select:focus,
select.pill:focus,
input.pill:focus {
  border-color: var(--blue);
  box-shadow: var(--focus-ring);
}
[aria-invalid="true"] {
  border-color: var(--red) !important;
  box-shadow: var(--error-ring) !important;
}
.help {
  color: var(--ink-3);
  font-size: 13px;
}
.error-msg {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  color: var(--red-text);
  font-size: 13px;
  font-weight: 500;
}
.error-msg:empty {
  display: none;
}

/* ---------- 세그먼트 · 탭 ---------- */
.seg {
  display: inline-flex;
  padding: 3px;
  border-radius: var(--r-pill);
  background: var(--fill-1);
}
.seg > button,
.seg > a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 32px;
  padding: 0 14px;
  border: 0;
  border-radius: var(--r-pill);
  background: transparent;
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
  transition:
    background-color var(--dur-fast) ease,
    color var(--dur-fast) ease;
}
.seg > :hover {
  color: var(--ink);
}
.seg > .active {
  background: #fff;
  color: var(--ink);
  font-weight: 600;
  box-shadow: var(--shadow-seg);
}
.seg.lg {
  display: flex;
  width: 100%;
  padding: 4px;
}
.seg.lg > * {
  flex: 1;
  height: 40px;
  font-size: 15px;
}
.tabs {
  display: flex;
  gap: 20px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--line);
}
.tabs button {
  height: 44px;
  margin-bottom: -1px;
  padding: 0 6px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: none;
  color: var(--ink-3);
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
}
.tabs button:hover {
  color: var(--ink);
}
.tabs button.active {
  border-bottom-color: var(--ink);
  color: var(--ink);
  font-weight: 600;
}
.tabs .n {
  margin-left: 4px;
  font-variant-numeric: tabular-nums;
}

/* ---------- 토스트 ---------- */
.toast-wrap {
  position: fixed;
  right: 0;
  bottom: 28px;
  left: 0;
  z-index: 50;
  display: flex;
  justify-content: center;
  pointer-events: none;
}
.toast {
  display: flex;
  align-items: center;
  gap: 4px;
  min-height: 48px;
  max-width: calc(100vw - 48px);
  padding: 6px 6px 6px 16px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: #fff;
  box-shadow: var(--shadow-toast);
  font-size: 14px;
  pointer-events: auto;
  animation: rise var(--dur-rise) var(--ease-out);
}
.toast > .i {
  margin-right: 6px;
  color: var(--ink);
}
.toast.fail > .i {
  color: var(--red);
}
.toast .msg {
  padding-right: 6px;
}
.toast .action {
  height: 36px;
  padding: 0 12px;
  border: 0;
  border-radius: var(--r-pill);
  background: none;
  color: var(--blue-link);
  font-weight: 600;
  cursor: pointer;
}
.toast .action:hover {
  background: var(--blue-tint-2);
}

/* ---------- 배너 ---------- */
.banner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 12px 12px 16px;
  border-radius: var(--r-item);
  background: var(--blue-tint-2);
  font-size: 14px;
}
.banner > .i {
  color: var(--blue-ink);
}
#notion-form.collapsed .setting-form {
  display: none;
}
#notion-form .row-end {
  display: flex;
  gap: 6px;
}
#g-expired {
  margin-bottom: 20px;
}
/* 노션 연결 3단계 안내 */
.steps {
  display: grid;
  gap: 10px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
  counter-reset: step;
}
.steps li {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 2px 10px;
  font-size: 14px;
  counter-increment: step;
}
.steps li::before {
  content: counter(step);
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: var(--r-pill);
  background: var(--fill-1);
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
}
.steps b {
  font-weight: 600;
}
.steps span {
  color: var(--ink-3);
}
.banner.warn {
  background: var(--orange-tint);
}
.banner.warn > .i {
  color: var(--orange-text);
}
.banner b {
  display: block;
  font-weight: 600;
}
.banner p {
  color: var(--ink-2);
  font-size: 14px;
}

/* ---------- 확인 대화상자 · 시트 ---------- */
dialog {
  max-width: none;
  max-height: none;
  padding: 0;
  border: 0;
  background: transparent;
}
dialog::backdrop {
  background: var(--overlay);
}
dialog[open] > * {
  animation: rise 0.22s var(--ease-out);
}
.alert-box {
  width: 400px;
  max-width: calc(100vw - 48px);
  padding: 24px 24px 20px;
  border-radius: var(--r-dialog);
  background: #fff;
  box-shadow: var(--shadow-dialog);
}
.alert-box h2 {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.02em;
  white-space: pre-line;
}
.alert-box p {
  margin-top: 8px;
  color: var(--ink-3);
  font-size: 15px;
  white-space: pre-line;
}
.alert-box p:empty {
  display: none;
}
.alert-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 22px;
}

/* ---------- 빈 상태 · 스켈레톤 ---------- */
.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 40px 20px;
  text-align: center;
}
.empty-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--r-pill);
  background: var(--fill-1);
  color: var(--ink-3);
}
.empty-icon .i {
  width: 20px;
  height: 20px;
}
.empty-icon.green {
  background: var(--green-tint);
  color: var(--green-text);
}
.empty-icon.blue {
  background: var(--blue-tint-2);
  color: var(--blue-ink);
}
.empty .title {
  margin-top: 6px;
  font-size: 15px;
  font-weight: 600;
}
.empty .desc {
  max-width: 340px;
  color: var(--ink-3);
  font-size: 14px;
}
.empty .btn {
  margin-top: 10px;
}
.empty-col {
  padding: 22px 16px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--r-item);
  color: var(--ink-3);
  font-size: 14px;
  text-align: center;
}
.skel {
  display: block;
  height: 12px;
  margin: 10px 0;
  border-radius: 7px;
  background: linear-gradient(90deg, #f2f2f5 25%, #e8e8ed 37%, #f2f2f5 63%);
  background-size: 400% 100%;
  animation: shine var(--skeleton-cycle) ease infinite;
}
.stat .skel {
  margin: 8px 0 6px;
}

/* ---------- 비서에게 말하기 (FAB) ---------- */
.fab {
  position: fixed;
  right: var(--fab-gap);
  bottom: var(--fab-gap);
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 10px;
  height: 52px;
  padding: 0 20px 0 8px;
  border: 0;
  border-radius: var(--r-pill);
  background: var(--ink);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  box-shadow: var(--shadow-float);
  cursor: pointer;
  transition: transform 0.12s ease;
}
.fab:active {
  transform: scale(0.96);
}
.fab .fab-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.16);
}
.fab .fab-icon .i {
  width: 18px;
  height: 18px;
}
.fab.open {
  display: none;
}

/* ---------- 음성 비서 패널 ---------- */
.assist {
  position: fixed;
  right: var(--fab-gap);
  bottom: var(--fab-gap);
  z-index: 45;
  display: flex;
  flex-direction: column;
  width: 404px;
  max-width: calc(100vw - 32px);
  height: min(680px, calc(100vh - 100px));
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--r-dialog);
  background: #fff;
  box-shadow: var(--shadow-panel);
  animation: rise var(--dur-rise) var(--ease-out);
}
.assist-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 12px 14px 16px;
  border-bottom: 1px solid var(--line-2);
}
.assist-head .logo {
  width: 32px;
  height: 32px;
}
.assist-head b {
  display: block;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.25;
}
.assist-head .status-dot {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink-3);
}
.assist-head .icon-btn.speaking {
  color: var(--blue);
}
.assist-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 14px;
  padding: 20px 16px;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.assist-body::before {
  content: "";
  margin-top: auto; /* 대화가 짧을 때 아래에서부터 쌓이게 */
}
.assist-log {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.assist-suggest {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  padding-left: 36px;
}
.assist-suggest button {
  height: 38px;
  padding: 0 16px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-pill);
  background: #fff;
  font-size: 14px;
  cursor: pointer;
}
.assist-suggest button:hover {
  background: var(--fill-hover);
}
.bubble {
  max-width: 100%;
  font-size: 15px;
  line-height: 1.6;
  white-space: pre-line;
  animation: rise 0.25s var(--ease-out);
}
.bubble.bot {
  position: relative;
  padding-left: 36px;
}
.bubble.bot::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 26px;
  height: 26px;
  border-radius: var(--r-pill);
  background:
    linear-gradient(#fff, #fff) 9px 9px / 2px 8px no-repeat,
    linear-gradient(#fff, #fff) 12px 7.5px / 2px 11px no-repeat,
    linear-gradient(#fff, #fff) 15px 9px / 2px 8px no-repeat,
    var(--ink);
}
.bubble.me {
  align-self: flex-end;
  max-width: 85%;
  padding: 10px 14px;
  border-radius: var(--r-panel);
  background: var(--bubble-user);
}
.bubble.me.live {
  color: var(--ink-3);
}
.bubble.me.live::after {
  content: "";
  display: inline-block;
  width: 2px;
  height: 1.1em;
  margin-left: 2px;
  background: var(--red-live);
  vertical-align: -0.15em;
  animation: blink 1s steps(1) infinite;
}
.bubble.thinking {
  display: flex;
  gap: 4px;
  height: 26px;
  align-items: center;
}
.bubble.thinking i {
  width: 6px;
  height: 6px;
  border-radius: var(--r-pill);
  background: var(--ink-4);
  animation: blink 1.2s infinite;
}
.bubble.thinking i:nth-child(2) {
  animation-delay: 0.2s;
}
.bubble.thinking i:nth-child(3) {
  animation-delay: 0.4s;
}
.action-chips,
.assist-choices,
.assist-hint {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: -6px;
  padding-left: 36px;
}
.assist-hint {
  color: var(--ink-3);
  font-size: 13px;
}
.action-chips .badge {
  height: 28px;
  padding: 0 11px;
  font-size: 12.5px;
}
.assist-bar {
  position: relative;
  padding: 10px 12px 12px;
  border-top: 1px solid var(--line-2);
}
.assist-bar input {
  width: 100%;
  height: 52px;
  padding: 0 60px 0 18px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: #fff;
  font-size: 15px;
}
.assist-bar input:focus {
  border-color: var(--blue);
  box-shadow: var(--focus-ring);
}
.assist-mic {
  position: absolute;
  top: 16px;
  right: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: var(--r-pill);
  background: var(--ink);
  color: #fff;
  cursor: pointer;
}
.assist-mic.recording {
  background: var(--red);
  animation: ring 1.4s ease-out infinite;
}

/* 파형 (녹음 중) */
.wave {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  height: 30px;
}
.wave span {
  width: 3px;
  height: 100%;
  border-radius: 2px;
  background: currentColor;
  animation: wave 0.9s ease-in-out infinite;
}
.wave span:nth-child(2n) {
  height: 55%;
  animation-delay: 0.15s;
}
.wave span:nth-child(3n) {
  height: 75%;
  animation-delay: 0.3s;
}
.wave span:nth-child(5n) {
  height: 40%;
  animation-delay: 0.45s;
}
.assist-mic .wave {
  height: 16px;
  gap: 2px;
}
.assist-mic .wave span {
  width: 2px;
}

/* ---------- 로그인 · 회원가입 ---------- */
.auth {
  display: grid;
  grid-template-columns: minmax(0, 700fr) minmax(0, 580fr);
  min-height: 100vh;
}
.auth-hero {
  display: flex;
  flex-direction: column;
  padding: 48px 72px;
  background: var(--fill-2);
}
.auth-hero .brand {
  margin-bottom: auto;
}
.auth-hero h1 {
  margin-top: 96px;
  font-size: 52px;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: var(--tracking-hero);
}
.auth-hero .lead {
  margin-top: 14px;
  color: var(--ink-3);
  font-size: 18px;
  line-height: 1.6;
}
.demo-card {
  max-width: 556px;
  margin-top: 40px;
  padding: 18px;
  border-radius: var(--r-dialog);
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04), 0 18px 40px rgba(0, 0, 0, 0.06);
}
.demo-card .say {
  margin-left: auto;
  width: fit-content;
  padding: 10px 16px;
  border-radius: var(--r-panel);
  background: var(--bubble-user);
  font-size: 15px;
}
.demo-card .say mark {
  padding: 1px 4px;
  border-radius: 5px;
  background: var(--blue-tint);
  color: var(--blue-ink);
}
.demo-card .by {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 14px 0 8px;
  color: var(--ink-3);
  font-size: 13px;
  font-weight: 600;
}
.demo-card .by .logo {
  width: 20px;
  height: 20px;
  gap: 1.5px;
}
.demo-card .by .logo i {
  width: 1.5px;
  height: 5px;
}
.demo-card .by .logo i:nth-child(2) {
  height: 9px;
}
.demo-card .todo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-item);
  font-size: 15px;
  font-weight: 600;
}
.features {
  counter-reset: feat;
  display: grid;
  gap: 16px;
  margin: 40px 0 auto;
}
.features li {
  counter-increment: feat;
  display: grid;
  grid-template-columns: 26px 1fr;
  column-gap: 14px;
  font-size: 16px;
  font-weight: 600;
}
.features li::before {
  content: counter(feat);
  grid-row: span 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: var(--r-pill);
  background: var(--ink);
  color: #fff;
  font-size: 13px;
}
.features li span {
  color: var(--ink-3);
  font-size: 14px;
  font-weight: 400;
}
.auth-main {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 24px;
}
.auth-box {
  width: 380px;
  max-width: 100%;
}
.auth-box h2 {
  margin: 32px 0 18px;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.03em;
}
.auth-box .field input {
  height: 50px;
  font-size: 16px;
}
.auth-box .error-msg {
  margin-top: 14px;
  padding: 11px 14px;
  border-radius: var(--r-field);
  background: var(--red-tint);
  font-size: 14px;
}
.auth-box .btn.xl {
  margin-top: 20px;
}
.auth-box .help {
  margin-top: 2px;
}
.shake {
  animation: shake 0.45s ease;
}
.demo-account {
  margin-top: 24px;
  padding: 12px;
  border-radius: var(--r-field);
  background: var(--fill-2);
  color: var(--ink-3);
  font-size: 14px;
  text-align: center;
}
.demo-account b {
  margin: 0 6px;
  color: var(--ink);
  font-weight: 500;
}

/* ---------- 대시보드 ---------- */
.dash-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(400px, 34%);
  gap: 24px;
  align-items: stretch;
  margin-bottom: 24px;
}
.today .greet {
  color: var(--ink-3);
  font-size: 17px;
  font-weight: 500;
}
.today h1 {
  margin-top: 2px;
  font-size: var(--fs-hero);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: var(--tracking-hero);
}
.today .lead {
  margin-top: 8px;
  color: var(--ink-3);
  font-size: 17px;
}
.today .lead b {
  color: var(--ink);
  font-weight: 700;
}
.today .lead b.red {
  color: var(--red);
}
.today-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 22px;
}
.today-actions .btn {
  height: 44px;
  padding: 0 20px;
  font-size: 15px;
}
.today-actions .fine {
  margin-left: 4px;
}
.btn.line.playing {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
}
.briefing {
  max-width: 640px;
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: var(--r-item);
  background: var(--fill-2);
  color: var(--ink-2);
  font-size: 15px;
  line-height: 1.7;
  white-space: pre-line;
}
.mic-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 28px 24px;
  border-radius: var(--r-dialog);
  background: var(--fill-2);
  text-align: center;
}
.mic-panel .title {
  margin-top: 14px;
  font-size: 15px;
  font-weight: 600;
}
.mic-panel .fine {
  font-size: 13px;
}
.mic {
  display: flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 88px;
  height: 88px;
  border: 0;
  border-radius: var(--r-pill);
  background: var(--ink);
  color: #fff;
  box-shadow: 0 0 0 8px rgba(0, 0, 0, 0.06);
  cursor: pointer;
  transition:
    transform 0.12s ease,
    background-color var(--dur-fast) ease;
}
.mic:hover {
  color: #fff;
  background: #000;
}
.mic:active {
  transform: scale(0.96);
}
.mic .i {
  width: 30px;
  height: 30px;
}
.mic.recording {
  background: var(--red);
  animation: ring 1.4s ease-out infinite;
}

/* 타임라인 */
.timeline > li {
  display: grid;
  grid-template-columns: 96px 52px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 64px;
  padding: 10px 0;
  border-top: 1px solid var(--line-3);
}
.timeline .tl-time {
  font-size: 14px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.timeline .tl-kind {
  color: var(--ink-3);
  font-size: 13px;
}
.timeline .tl-title {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  font-size: 15px;
  font-weight: 600;
}
.timeline .tl-title .t {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.timeline .tl-title .dot {
  flex: none;
  width: 7px;
  height: 7px;
  margin-left: -15px;
  border-radius: var(--r-pill);
  background: var(--c, var(--gray-dot));
}
.timeline .tl-place {
  margin-top: 1px;
  color: var(--ink-3);
  font-size: 13px;
}
.timeline .tl-end {
  color: var(--ink-3);
  font-size: 13px;
}
.timeline .soon {
  background: var(--fill-1);
  color: var(--ink);
  font-weight: 700;
}
.timeline .past .tl-time,
.timeline .past .tl-title,
.timeline .past .tl-place {
  color: var(--ink-3);
  font-weight: 500;
}
.timeline .past .dot {
  opacity: 0.5;
}
.timeline .tl-body {
  padding-left: 15px;
  min-width: 0;
}
.timeline > li.tl-now {
  display: flex;
  min-height: 0;
  padding: 6px 0;
  border-top: 0;
  color: var(--red);
  font-size: 12px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.tl-now span {
  width: 108px;
  flex: none;
}
.tl-now i {
  position: relative;
  flex: 1;
  height: 2px;
  margin-left: 12px;
  border-radius: 2px;
  background: var(--red-live);
}
.tl-now i::before {
  content: "";
  position: absolute;
  top: -3px;
  left: -4px;
  width: 8px;
  height: 8px;
  border-radius: var(--r-pill);
  background: var(--red-live);
}
.timeline > li.tl-day {
  display: block;
  min-height: 0;
  padding: 16px 0 6px;
  color: var(--ink-3);
  font-size: 13px;
  font-weight: 600;
}
.timeline > li.tl-day + li {
  border-top: 0;
}
.timeline > li.empty {
  display: flex;
  border-top: 0;
}
#tl-banner .banner {
  margin-bottom: 10px;
}

/* 오늘 이것부터 */
.top3 {
  counter-reset: top;
}
.top3 > li {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 2px 14px;
  padding: 16px 0;
  border-top: 1px solid var(--line-3);
  counter-increment: top;
}
.top3 > li::before {
  content: counter(top);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border: 1.5px solid var(--ink);
  border-radius: var(--r-pill);
  font-size: 12px;
  font-weight: 700;
}
.top3 > li:first-child::before {
  background: var(--ink);
  color: #fff;
}
.top3 > li.empty::before,
.top3 > li.skeleton::before {
  display: none;
}
.top3 > li.empty,
.top3 > li.skeleton {
  display: block;
}
.top3-title {
  font-size: 15px;
  font-weight: 600;
  line-height: 22px;
}
.top3-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}
.top3-reason {
  margin-top: 8px;
  color: var(--ink-3);
  font-size: 14px;
}
.card-foot {
  padding-top: 14px;
  border-top: 1px solid var(--line-3);
}

/* ---------- 주간 시간표 ---------- */
.tt-wrap {
  overflow-x: auto; /* 열이 최소 폭보다 좁아질 화면에서는 표만 가로로 민다 */
  border: 1px solid var(--line);
  border-radius: var(--r-item);
}
.tt-wrap.bare {
  border: 0;
  border-radius: 0;
}
.tt {
  /* 칸 크기는 글자에 맞춘다: 1시간(80px) 안에 과목명 15px + 시간·강의실 13px 두 줄이 다 들어가고,
     열은 '심화응용프로젝트'(8자)가 잘리지 않는 160px보다 좁아지지 않는다 */
  --hour: 80px;
  --slot: calc(var(--hour) / 2);
  position: relative;
  display: grid;
  grid-template-columns: 64px repeat(var(--days), minmax(160px, 1fr));
  grid-template-rows: auto repeat(var(--slots), var(--slot));
}
.tt.compact {
  /* 대시보드 미니 시간표: 1시간 56px 안에 과목명 + "시간 · 강의실" 한 줄 (그 한 줄이 들어가는 200px) */
  --hour: 56px;
  grid-template-columns: 56px repeat(var(--days), minmax(200px, 1fr));
}
.tt-dayhead {
  grid-row: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  height: 72px;
  border-bottom: 1px solid var(--line);
  border-left: 1px solid var(--line-3);
  color: var(--ink-3);
  font-size: 13px;
  font-weight: 500;
}
.tt-dayhead b {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: var(--r-pill);
  color: var(--ink);
  font-size: 18px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.tt-dayhead.today {
  background: var(--blue-today);
  color: var(--blue-ink);
  font-weight: 600;
}
.tt-dayhead.today b {
  background: var(--blue);
  color: #fff;
}
.tt.compact .tt-dayhead {
  flex-direction: row;
  height: 40px;
  font-size: 13px;
  color: var(--ink-2);
}
.tt.compact .tt-dayhead b {
  width: auto;
  height: auto;
  background: none !important;
  color: inherit !important;
  font-size: 13px;
  font-weight: inherit;
}
.tt.compact .tt-dayhead.today {
  color: var(--blue-ink);
}
.tt-corner {
  grid-row: 1;
  grid-column: 1;
  border-bottom: 1px solid var(--line);
}
.tt-hour {
  grid-column: 1;
  padding: 4px 10px 0 0;
  color: var(--ink-3);
  font-size: 12.5px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
/* 1시간 칸: 위 실선, 30분 옅은 선 */
.tt-cell {
  border-top: 1px solid var(--line-3);
  border-left: 1px solid var(--line-3);
  background: linear-gradient(var(--line-3), var(--line-3)) 0 50% / 100% 1px no-repeat;
}
.tt-cell.today {
  background-color: var(--blue-today);
}
.tt-slot {
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-height: 0;
  margin: 2px 4px;
  padding: 8px 10px 8px 12px;
  overflow: hidden;
  border-left: 3px solid var(--c);
  border-radius: 4px 10px 10px 4px;
  background: color-mix(in srgb, var(--c) 20%, #fff);
  color: var(--ink-2);
  font-size: 13px;
  line-height: 1.4;
  font-variant-numeric: tabular-nums;
  transition: filter var(--dur-fast) ease;
}
.tt-slot:hover {
  color: var(--ink-2);
  filter: brightness(0.97);
}
.tt-slot b {
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
}
.tt.compact .tt-slot {
  padding: 6px 10px 6px 12px;
  font-size: 12.5px;
}
.tt.compact .tt-slot b {
  font-size: 14px;
}
/* 칸이 좁아도 글자가 칸 밖으로 잘려 보이지 않게 한 줄 말줄임 */
.tt-slot b,
.tt-slot span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tt-slot.short {
  padding-top: 5px;
  padding-bottom: 5px;
}
.tt-now {
  z-index: 2;
  grid-row: 2;
  align-self: start;
  height: 2px;
  margin-left: -4px;
  background: var(--red-live);
  pointer-events: none;
}
.tt-now::before {
  content: "";
  position: absolute;
  top: -3px;
  left: 0;
  width: 8px;
  height: 8px;
  border-radius: var(--r-pill);
  background: var(--red-live);
}
.tt-now {
  position: relative;
}
.tt-now-label {
  z-index: 2;
  grid-row: 2;
  grid-column: 1;
  align-self: start;
  padding-right: 8px;
  color: var(--red);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  text-align: right;
  transform: translateY(-50%);
  font-variant-numeric: tabular-nums;
  background: #fff;
}

/* ---------- 할 일 보드 ---------- */
.composer {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 58px;
  margin-bottom: 20px;
  padding: 8px 8px 8px 18px;
  border: 1px solid var(--line);
  border-radius: var(--r-composer);
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  transition:
    border-color var(--dur-fast) ease,
    box-shadow var(--dur-fast) ease;
}
.composer:focus-within {
  border-color: var(--line-strong);
  box-shadow: var(--shadow-card-hover);
}
.composer > .i {
  color: var(--ink-3);
}
.composer .qa-title {
  flex: 1;
  min-width: 140px;
  height: 40px;
  border: 0;
  background: none;
  font-size: 15px;
}
/* 둘째 줄: 마감일(라벨 + 빠른 칩 + 직접 입력) · 우선순위 · 과목 · 추가 */
.composer {
  flex-wrap: wrap;
}
.composer .qa-opts {
  display: flex;
  flex: 1 1 100%;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 8px 0 2px;
  border-top: 1px solid var(--line-3);
}
.composer .qa-opts > .btn {
  margin-left: auto;
}
.qa-due {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.qa-label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--ink-2);
  font-size: 14px;
  font-weight: 600;
}
.due-quick {
  display: inline-flex;
  gap: 4px;
}
.due-quick button {
  height: 32px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: #fff;
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
}
.due-quick button:hover {
  background: var(--fill-hover);
}
.due-quick button.on {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
}
.composer input.pill {
  width: 200px;
  height: 36px;
}
.qa-select {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 36px;
  padding: 0 10px 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-pill);
  color: var(--ink-3);
}
.qa-select:focus-within {
  border-color: var(--ink-3);
}
.qa-select select {
  height: 100%;
  padding-right: 18px;
  border: 0;
  background-color: transparent;
  color: var(--ink);
  font-size: 14px;
  font-weight: 500;
}
.board-filter {
  margin-bottom: 16px;
}
.board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
}
.column {
  padding: 12px;
  border-radius: var(--r-panel);
  background: var(--fill-2);
}
.column-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 6px 12px;
}
.column-head .dot {
  width: 7px;
  height: 7px;
  border-radius: var(--r-pill);
  background: var(--gray-dot);
}
.column[data-status="doing"] .dot {
  background: var(--blue);
}
.column[data-status="done"] .dot {
  background: var(--green);
}
.column-head h3 {
  font-size: 15px;
  font-weight: 600;
}
.column-head .count {
  color: var(--ink-3);
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.cards {
  display: grid;
  gap: 10px;
}
.task {
  position: relative;
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr) auto;
  gap: 0 10px;
  padding: 12px 10px 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-item);
  background: #fff;
  transition:
    box-shadow var(--dur-fast) ease,
    border-color var(--dur-fast) ease;
  animation: rise 0.25s var(--ease-out);
}
.task:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow-card-hover);
}
/* 중요(높음)는 '⚑ 중요' 글자 하나로만 강조. 보통·낮음은 표시하지 않는다 */
.task .check {
  margin-top: 1px;
}
.task-title {
  align-self: center;
  font-size: 15px;
  font-weight: 600;
  line-height: 22px;
  overflow-wrap: anywhere;
}
.task-tools {
  display: flex;
  align-items: flex-start;
  gap: 2px;
  margin: -5px -2px 0 0;
}
.task-tools .icon-btn {
  width: 32px;
  height: 32px;
}
.task-tools .step {
  color: var(--ink-2);
}
.task-meta {
  grid-column: 2 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
}
.task-meta:empty {
  display: none;
}
/* 카드 안 과목은 테두리 없이 점 + 글자만: 마감 칩 하나만 '칩'으로 보이게 해서 배지가 겹쳐 보이지 않게 */
.task-meta .chip {
  height: 22px;
  padding: 0 2px 0 0;
  border: 0;
  background: none;
  font-size: 13px;
}
/* 출처(음성 메모·메일·음성 비서)는 아이콘만. 이름은 마우스를 올리거나 스크린 리더로 */
.task-meta .src {
  width: 22px;
  padding: 0;
  justify-content: center;
  background: none;
  color: var(--ink-3);
}
.task-meta .src .i {
  width: 14px;
  height: 14px;
}
.task-meta .src-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}
.more-done {
  width: 100%;
  height: 36px;
  border: 0;
  border-radius: var(--r-field);
  background: none;
  color: var(--ink-3);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
}
.more-done:hover {
  background: var(--fill-1);
  color: var(--ink);
}
.prio-high {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
}
.prio-high .i {
  width: 13px;
  height: 13px;
}
/* '…' 펼침 메뉴 (할 일 카드) */
.pop {
  position: relative;
}
.pop summary {
  list-style: none;
  cursor: pointer;
}
.pop summary::-webkit-details-marker {
  display: none;
}
.pop[open] summary {
  background: var(--fill-1);
}
.pop .menu {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  z-index: 40;
  min-width: 180px;
  padding: 6px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-item);
  background: var(--bg);
  box-shadow: var(--shadow-toast);
}
.pop .menu button {
  display: flex;
  align-items: center;
  width: 100%;
  height: 38px;
  padding: 0 12px;
  border: 0;
  border-radius: var(--r-tile);
  background: none;
  color: var(--ink);
  font-size: 14px;
  text-align: left;
  cursor: pointer;
}
.pop .menu button:hover {
  background: var(--fill-hover);
}
.pop .menu button.danger {
  color: var(--red-text);
}
.task.done .task-title {
  color: var(--ink-3);
  font-weight: 500;
  text-decoration: line-through;
}
.task.done .chip {
  opacity: 0.7;
}

/* ---------- 음성 메모 ---------- */
.memo-grid {
  display: grid;
  grid-template-columns: 380px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}
.memo-side > * + * {
  margin-top: 14px;
}
.recorder {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 36px 24px 32px;
  border-radius: var(--r-dialog);
  background: var(--fill-2);
  text-align: center;
}
.recorder .mic {
  width: 112px;
  height: 112px;
}
.recorder .mic .i {
  width: 36px;
  height: 36px;
}
.recorder .mic.recording .i {
  width: 40px;
  height: 40px;
  stroke: none;
  fill: #fff;
}
.rec-status {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  margin-top: 22px;
}
.rec-status .wave {
  color: var(--red);
}
.rec-status .timer {
  font-size: 30px;
  font-weight: 600;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
#mic-status {
  font-size: 17px;
  font-weight: 600;
}
#mic-sub {
  color: var(--ink-3);
  font-size: 14px;
}
.recorder:has(.mic.recording) #mic-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--red);
  font-size: 14px;
}
.recorder:has(.mic.recording) #mic-status::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: var(--r-pill);
  background: var(--red-live);
}
.recorder:has(.mic.recording) #mic-sub {
  display: none;
}
/* 강의 녹음: 큰 타이머를 위에 */
.mode-lecture .recorder {
  align-items: stretch;
  padding: 28px 24px;
  text-align: left;
}
.mode-lecture .rec-status {
  align-items: flex-start;
  order: -1;
  margin: 0 0 20px;
}
.mode-lecture .rec-status .timer {
  display: block !important;
  font-size: 56px;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.04em;
}
.mode-lecture .recorder:not(:has(.recording)) .timer {
  color: var(--ink-disabled);
}
.mode-lecture .recorder:has(.recording) .timer {
  color: var(--red);
}
.mode-lecture .recorder .mic {
  align-self: center;
}
.mode-lecture .tips {
  display: none;
}
.seg-list {
  margin-top: 22px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  text-align: left;
}
.seg-list:empty {
  display: none;
}
.seg-list::before {
  content: "받아쓰기 · 10분 조각";
  display: block;
  margin-bottom: 6px;
  color: var(--ink-3);
  font-size: 13px;
  font-weight: 600;
}
.seg-list li {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 40px;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.seg-list li span:first-child {
  width: 104px;
}
.seg-list .ok {
  color: var(--green-text);
  font-weight: 600;
}
.seg-list .wait {
  color: var(--blue-ink);
}
.seg-list .fail {
  color: var(--red-text);
  font-weight: 600;
}
.seg-list .rec {
  color: var(--red);
}
.tips {
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  font-size: 14px;
}
.tips b {
  display: block;
  margin-bottom: 6px;
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 600;
}
.tips ul {
  padding-left: 18px;
  list-style: disc;
  color: var(--ink-2);
  line-height: 1.75;
}
.live {
  display: flex;
  flex-direction: column;
}
/* 예시 문구는 실제 받아쓴 글(.interim, --ink-3)보다 한 단계 옅게 */
.live textarea::placeholder {
  color: var(--ink-4);
}
.analyze-hint {
  margin-left: auto;
}
.analyze-hint:empty {
  display: none;
}
.recorder-mode {
  margin-bottom: 24px;
}
.live textarea {
  min-height: 136px;
  padding: 0;
  border: 0;
  background: none;
  font-size: 21px;
  line-height: 1.7;
  letter-spacing: -0.015em;
  resize: vertical;
}
.interim {
  color: var(--ink-3);
  font-size: 21px;
  line-height: 1.7;
}
.interim:not(:empty)::after {
  content: "";
  display: inline-block;
  width: 2px;
  height: 1.05em;
  margin-left: 2px;
  background: var(--red-live);
  vertical-align: -0.15em;
  animation: blink 1s steps(1) infinite;
}
.live-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line-3);
}
.live-foot .btn {
  height: 44px;
  padding: 0 20px;
  font-size: 15px;
}
.result {
  margin-top: 20px;
  animation: rise var(--dur-rise) var(--ease-out);
}
.summary-line {
  display: flex;
  align-items: center;
  gap: 10px;
}
.summary {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.02em;
  white-space: pre-line;
}
.summary.warn {
  padding: 12px 14px;
  border-radius: var(--r-field);
  background: var(--orange-tint);
  color: var(--orange-strong);
  font-size: 15px;
  font-weight: 500;
}
.summary .skel {
  min-width: 240px;
}
.points {
  display: grid;
  gap: 6px;
  padding-left: 20px;
  list-style: disc;
  font-size: 15px;
  line-height: 1.7;
}
.points li::marker {
  color: var(--ink-3);
}
.exam {
  margin-top: 16px;
  padding: 16px 18px;
  border-radius: var(--r-item);
  background: var(--orange-tint);
}
.exam b {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
  color: var(--orange-text);
  font-size: 14px;
  font-weight: 700;
}
.exam b .i {
  fill: currentColor;
  stroke: none;
  width: 14px;
  height: 14px;
}
.exam .points {
  font-size: 15px;
}
.cand-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 22px 0 6px;
}
.cand-head h3 {
  font-size: 15px;
  font-weight: 600;
}
.candidate {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 60px;
  padding: 8px 0;
  border-top: 1px solid var(--line-3);
  transition: opacity var(--dur-fast) ease;
}
.candidate:last-child {
  border-bottom: 1px solid var(--line-3);
}
.candidate.off {
  opacity: 0.5;
}
.candidate .c-title {
  flex: 1;
  min-width: 120px;
  height: 40px;
  padding: 0 6px;
  margin-left: 30px;
  border: 1px solid transparent;
  border-radius: var(--r-tile);
  background: none;
  font-size: 15px;
  font-weight: 600;
}
.candidate .c-title:hover {
  background: var(--fill-3);
}
.candidate .c-title:focus {
  border-color: var(--blue);
  background: #fff;
  box-shadow: var(--focus-ring);
}
.candidate-meta {
  display: flex;
  flex: none;
  gap: 8px;
}
.candidate .c-due {
  width: 214px;
}

/* ---------- 메모 목록 · 상세 ---------- */
.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.filter-chips a,
.filter-chips button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 36px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  color: var(--ink);
  background: #fff;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
}
.filter-chips a:hover,
.filter-chips button:hover {
  background: var(--fill-hover);
}
.filter-chips a[data-c]::before,
.filter-chips button[data-c]::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: var(--r-pill);
  background: var(--c);
}
.filter-chips a.active,
.filter-chips button.active {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
  font-weight: 600;
}
.dur {
  color: var(--ink-2);
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.list-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 16px;
  padding: 0 2px;
}
.pager {
  display: flex;
  align-items: center;
  gap: 4px;
}
.pager > * {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  border-radius: var(--r-pill);
  color: var(--ink);
  font-size: 14px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.pager a:hover {
  background: var(--fill-hover);
}
.pager .active {
  background: var(--ink);
  color: #fff;
  font-weight: 600;
}
.pager .off {
  color: var(--ink-disabled);
}
.detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}
.detail-head h1 {
  font-size: var(--fs-h1);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: var(--tracking-title);
}
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  color: var(--ink-3);
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.transcript-text {
  font-size: 16px;
  line-height: 1.75;
  white-space: pre-wrap;
}

/* ---------- 시간표 · 과목 시트 ---------- */
.sheet {
  display: flex;
  flex-direction: column;
  width: 580px;
  max-width: calc(100vw - 48px);
  max-height: calc(100vh - 48px);
  border-radius: var(--r-dialog);
  background: #fff;
  box-shadow: var(--shadow-dialog);
}
.sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 16px 8px 24px;
}
.sheet-head h2 {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.sheet-body {
  flex: 1;
  padding: 8px 24px 20px;
  overflow-y: auto;
}
.sheet-foot {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 14px 24px;
  border-top: 1px solid var(--line-2);
}
.swatches {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.swatch {
  width: 28px;
  height: 28px;
  margin: 4px;
  padding: 0;
  border: 0;
  border-radius: var(--r-pill);
  cursor: pointer;
  transition: transform 0.12s ease;
}
.swatch:hover {
  transform: scale(1.08);
}
.swatch.on {
  background-image: var(--check-svg) !important;
  background-position: center !important;
  background-size: 14px !important;
  background-repeat: no-repeat !important;
  box-shadow:
    0 0 0 3px #fff,
    0 0 0 5px var(--ink);
}
.swatches .divider {
  width: 1px;
  height: 24px;
  margin: 0 6px;
  background: var(--line);
}
.color-pick {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  padding: 0 14px 0 10px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-pill);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
.color-pick input {
  width: 22px;
  height: 16px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}
.color-pick input::-webkit-color-swatch-wrapper {
  padding: 0;
}
.color-pick input::-webkit-color-swatch {
  border: 0;
  border-radius: 3px;
}
.preview-line {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  color: var(--ink-3);
  font-size: 13px;
}
.sched-row {
  display: grid;
  grid-template-columns: 72px 128px 12px 128px minmax(0, 1fr) 36px;
  align-items: center;
  gap: 6px;
}
.sched-row + .sched-row {
  margin-top: 8px;
}
.sched-row > :is(input, select) {
  height: 42px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-field);
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}
.sched-row > :is(input, select):focus {
  border-color: var(--blue);
  box-shadow: var(--focus-ring);
}
.sched-row .tilde {
  color: var(--ink-3);
  text-align: center;
}
.add-row {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  padding: 4px 0;
  border: 0;
  background: none;
  color: var(--blue-link);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

/* 과목 모아보기 */
.course-head h1 {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: var(--fs-h1);
  font-weight: 700;
  letter-spacing: var(--tracking-title);
}
.course-dot {
  width: 14px;
  height: 14px;
  border-radius: var(--r-pill);
  background: var(--c);
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--c) 22%, #fff);
}
.course-head p {
  margin: 4px 0 0;
}
/* 인라인 style 대신 쓰는 작은 도우미 */
.card-head.flush {
  margin-bottom: 0;
}
.card-note {
  margin-top: 16px;
}
.grid-2.detail {
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
}
.empty.compact {
  padding: 28px 12px 16px;
}
.sum-line {
  margin-top: 20px;
  padding-top: 14px;
  border-top: 1px solid var(--line-3);
}
.sum-line b {
  color: var(--ink);
}
.scope-list {
  display: flex;
  gap: 6px;
}
.with-icon {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.data td.end {
  text-align: right;
}
.badge.sm {
  height: 22px;
}
/* 카드 제목 작은 크기 (상세 화면 보조 카드) */
.card-head h2.sm {
  font-size: 16px;
}
.ai-label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 6px;
  color: var(--blue-ink);
  font-size: 13px;
  font-weight: 600;
}
.ai-label .i {
  width: 14px;
  height: 14px;
}

/* ---------- 주간 리포트 ---------- */
.chart {
  position: relative;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  align-items: end;
  height: 170px;
  margin: 30px 0 0 24px;
  border-bottom: 1px solid var(--line-strong);
  background: repeating-linear-gradient(to top, transparent 0 calc(50% - 1px), var(--line) calc(50% - 1px) 50%) bottom / 100% calc(100% - 30px) no-repeat;
}
.chart .yaxis {
  position: absolute;
  top: 24px;
  bottom: -8px;
  left: -24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: var(--ink-3);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.chart .col {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  height: 100%;
}
.chart .n {
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.chart .col.future .n {
  color: var(--ink-disabled);
  font-weight: 500;
}
.chart .bar {
  width: 30px;
  max-width: 70%;
  border-radius: 6px 6px 0 0;
  background: var(--ink);
}
.chart .x {
  position: absolute;
  top: calc(100% + 10px);
  color: var(--ink-3);
  font-size: 13px;
  text-align: center;
  line-height: 1.35;
}
.chart .x small {
  display: block;
  color: var(--blue-link);
  font-size: 12px;
  font-weight: 600;
}
.chart .col.today .x {
  color: var(--ink);
  font-weight: 700;
}
.chart-note {
  margin-top: 56px;
}
.subj-progress li + li {
  margin-top: 16px;
}
.sp-head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
}
.sp-head::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: var(--r-pill);
  background: var(--c);
}
.sp-head .grow + b {
  font-variant-numeric: tabular-nums;
}
.sp-head .pct {
  width: 44px;
  color: var(--ink-3);
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.subj-progress .meter {
  height: 7px;
  margin-top: 8px;
}

/* ---------- 받은 편지함 ---------- */
/* 메일 목록: 메일마다 카드를 따로 두지 않고 한 목록 안에서 선으로 나눈다 (카드 안 카드 제거) */
.mail-list {
  border: 1px solid var(--line);
  border-radius: var(--r-panel);
  background: #fff;
  overflow: hidden;
}
.mail-card {
  padding: 18px 20px;
  transition: opacity 0.25s ease;
}
.mail-card + .mail-card {
  border-top: 1px solid var(--line-2);
}

.mail-card.settled.ignored {
  opacity: 0.55;
}
.mail-head {
  display: flex;
  align-items: center;
  gap: 12px;
}
.mail-head .avatar {
  width: 32px;
  height: 32px;
  font-size: 13px;
  background: color-mix(in srgb, var(--c, #8e8e93) 20%, #fff);
}
.mail-from {
  font-size: 14px;
  font-weight: 600;
}
.mail-from small {
  margin-left: 4px;
  color: var(--ink-3);
  font-size: 14px;
  font-weight: 400;
}
.mail-time {
  color: var(--ink-3);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.mail-subject {
  margin-top: 10px;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.02em;
}
/* 메일 미리보기: AI가 근거로 삼은 문장을 2줄까지 */
.mail-preview {
  display: -webkit-box;
  margin-top: 4px;
  overflow: hidden;
  color: var(--ink-3);
  font-size: 14px;
  line-height: 1.5;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.found-read {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 15px;
}
.found-read[hidden],
.found-meta[hidden] {
  display: none;
}
/* AI 제안: 바탕 상자 대신 왼쪽 파란 선 하나로 '메일 원문'과 'AI가 정리한 것'을 구분 */
.found {
  margin-top: 12px;
  padding: 2px 0 2px 14px;
  border-left: 2px solid var(--blue);
}
.found-label .i {
  width: 14px;
  height: 14px;
}
.found-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  justify-content: flex-start;
  gap: 5px;
  margin-bottom: 6px;
  color: var(--blue-ink);
  font-size: 13px;
  font-weight: 600;
}
.found-meta {
  display: flex;
  gap: 8px;
}
.found .f-title {
  flex: 1;
  min-width: 0;
  height: 42px;
  padding: 0 12px;
  border: 1px solid var(--blue-field-line);
  border-radius: var(--r-field);
  background: #fff;
  font-size: 15px;
  font-weight: 600;
}
.found :is(.f-title, .pill):focus {
  border-color: var(--blue);
  box-shadow: var(--focus-ring);
}
.found .pill {
  height: 42px;
  border-color: var(--blue-field-line);
  border-radius: var(--r-field);
}
.found .f-due {
  width: 214px;
}
.found .f-subject {
  width: 176px;
}
.mail-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
}
.added-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  padding: 2px 0 2px 14px;
  border-left: 2px solid var(--green);
  color: var(--green-text);
  font-size: 14px;
  font-weight: 600;
}
.added-line .grow {
  color: var(--ink-2);
  font-weight: 500;
}
.lock-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 24px;
  color: var(--ink-3);
  font-size: 13px;
}

/* ---------- 연동 설정 ---------- */
.group-label {
  margin: 28px 4px 8px;
  color: var(--ink-3);
  font-size: 13px;
  font-weight: 600;
}
.group-label:first-of-type {
  margin-top: 0;
}
.group-foot {
  margin: 8px 4px 0;
  color: var(--ink-3);
  font-size: 13px;
}
.setting-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
}
.setting-row + .setting-row,
.setting-row + .setting-form {
  border-top: 1px solid var(--line-3);
}
.setting-row .tile {
  width: 44px;
  height: 44px;
}
.setting-row .row-title {
  font-size: 16px;
}
.setting-row .row-sub {
  gap: 8px;
  font-size: 14px;
}
.setting-detail {
  padding: 14px 18px 16px 76px;
  border-top: 1px solid var(--line-3);
}
.setting-detail .scopes {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-3);
  font-size: 13px;
}
.setting-detail .scopes > span:first-child {
  width: 44px;
}
.setting-detail .sync-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 10px;
  color: var(--ink-2);
  font-size: 14px;
}
.setting-form {
  padding: 18px;
}
.setting-form .field input {
  height: 44px;
}
.setting-form .help {
  margin-top: 4px;
  font-size: 13px;
}
.setting-form .form-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
}

/* ---------- 관리자 ---------- */
.data {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.data th {
  height: 40px;
  padding: 0 20px;
  border-top: 1px solid var(--line-2);
  border-bottom: 1px solid var(--line-2);
  background: var(--fill-3);
  color: var(--ink-3);
  font-size: 13px;
  font-weight: 500;
  text-align: left;
}
.data td {
  height: 58px;
  padding: 0 20px;
  border-bottom: 1px solid var(--line-3);
}
.data tbody tr:hover {
  background: var(--fill-3);
}
.data .n {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.data .who {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
}
.data .who .avatar {
  width: 32px;
  height: 32px;
}
.table-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
}
.table-head h2 {
  font-size: var(--fs-h2);
  font-weight: 600;
  letter-spacing: -0.02em;
}
.table-foot {
  padding: 14px 20px;
  color: var(--ink-3);
  font-size: 13px;
}

/* ---------- 404 · 500 ---------- */
.error-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - var(--header-h) - 120px);
  padding: 40px 24px;
  text-align: center;
}
.error-page .code {
  font-size: 96px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.05em;
}
.error-page .warn-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border-radius: var(--r-pill);
  background: var(--orange-tint);
  color: var(--orange-text);
}
.error-page .warn-icon .i {
  width: 28px;
  height: 28px;
}
.error-page h1 {
  margin-top: 24px;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.error-page p {
  margin-top: 10px;
  color: var(--ink-3);
}
.error-page .btn {
  margin-top: 28px;
}

/* 대시보드 동기화: 자주 누르지 않는 보조 동작이라 글자 버튼으로 낮춘다 */
.today-actions .btn.sync {
  color: var(--ink-2);
}
.today-actions .btn.sync:hover {
  color: var(--ink);
}

/* ---------- 좁은 화면: 가로 스크롤만 안 생기게 ---------- */
@media (max-width: 1100px) {
  /* 태블릿: 상단 메뉴 5개가 잘리지 않게 음성 메모는 아이콘만, 프로필은 이름 없이 */
  .gnav-memo {
    width: 40px;
    padding: 0;
    justify-content: center;
  }
  .gnav-memo .lbl,
  .user-menu summary .name {
    display: none;
  }
  .dash-top,
  .grid-2,
  .grid-2.even,
  .grid-2.detail,
  .memo-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .stat-grid.strip .stat:nth-child(odd) {
    border-left: 0;
  }
  .stat-grid.strip .stat:nth-child(n + 3) {
    border-top: 1px solid var(--line-2);
  }
  /* 태블릿: 할 일·진행 중을 나란히, 완료는 아래 한 줄 전체 (카드는 2열) */
  .board {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .column[data-status="done"] {
    grid-column: 1 / -1;
  }
  .column[data-status="done"] .cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .composer {
    flex-wrap: wrap;
  }
  .auth {
    grid-template-columns: minmax(0, 1fr);
  }
  .auth-hero {
    display: none;
  }
  .gnav .name {
    display: none;
  }
}

/* ---------- 페이지별 포인트 (제목 옆 아이콘 타일 + 메뉴의 현재 위치 색) ----------
   화면 구조·컴포넌트는 그대로 두고 '지금 어느 화면인지'만 알아보게 한다.
   빨강·주황·초록은 마감 상태색이라 쓰지 않는다. 글자색(--page-ink)은 옅은 바탕(--page-tint) 위 4.5:1 이상 */
body {
  --page-ink: var(--ink);
  --page-tint: var(--fill-1);
}
.gnav-links a[aria-current="page"] {
  background: var(--page-tint);
  color: var(--page-ink);
}
body[class*="page-"] .page-head h1::before {
  content: "";
  flex: none;
  align-self: center;
  width: 36px;
  height: 36px;
  margin-right: 4px;
  border-radius: var(--r-field);
  background: var(--page-icon) center / 20px no-repeat, var(--page-tint);
}
/* 과목 모아보기는 제목 앞에 과목색 점이 이미 있다 */
body[class*="page-"] .course-head h1::before {
  display: none;
}
@media (max-width: 760px) {
  .gnav-links a[aria-current="page"] {
    background: none;
  }
  body[class*="page-"] .page-head h1::before {
    width: 32px;
    height: 32px;
    background-size: 18px;
  }
}
body.page-tasks {
  --page-ink: #3f3db0;
  --page-tint: #efeffc;
  --page-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235856d6' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 6.5l1.5 1.5 3-3M3.5 12.5l1.5 1.5 3-3M3.5 18.5l1.5 1.5 3-3M11 7h9.5M11 13h9.5M11 19h9.5'/%3E%3C/svg%3E");
}
body.page-timetable {
  --page-ink: #075f74;
  --page-tint: #e5f3f6;
  --page-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230a7d98' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3.5' y='5' width='17' height='15.5' rx='3'/%3E%3Cpath d='M3.5 10h17M8 3v4M16 3v4'/%3E%3C/svg%3E");
}
body.page-memo {
  --page-ink: #7330a0;
  --page-tint: #f5edfa;
  --page-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239b45c9' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='9' y='2.5' width='6' height='12' rx='3'/%3E%3Cpath d='M5.5 10.5a6.5 6.5 0 0 0 13 0M12 17v4M8.5 21h7'/%3E%3C/svg%3E");
}
body.page-memos {
  --page-ink: #7330a0;
  --page-tint: #f5edfa;
  --page-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239b45c9' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6.5 3.5h8l4 4v13h-12z'/%3E%3Cpath d='M14 3.5V8h4.5M9.5 13h6M9.5 16.5h4'/%3E%3C/svg%3E");
}
body.page-inbox {
  --page-ink: #0058b0;
  --page-tint: #e6f0fb;
  --page-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230071e3' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='3'/%3E%3Cpath d='m4 7.5 8 5.5 8-5.5'/%3E%3C/svg%3E");
}
body.page-report {
  --page-ink: #3c4655;
  --page-tint: #eef0f3;
  --page-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235e6b7d' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 12h1M7.5 8.5v7M11.5 5v14M15.5 9v6M19.5 7v10'/%3E%3C/svg%3E");
}
body.page-settings {
  --page-ink: #3c4655;
  --page-tint: #eef0f3;
  --page-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235e6b7d' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 14a4 4 0 0 0 5.7 0l3-3a4 4 0 0 0-5.7-5.7l-1 1M14 10a4 4 0 0 0-5.7 0l-3 3a4 4 0 0 0 5.7 5.7l1-1'/%3E%3C/svg%3E");
}
body.page-admin {
  --page-ink: #3c4655;
  --page-tint: #eef0f3;
  --page-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235e6b7d' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3.5l7 2.8v5.4c0 4.2-3 7.7-7 8.8-4-1.1-7-4.6-7-8.8V6.3z'/%3E%3Cpath d='m9 12 2 2 4-4'/%3E%3C/svg%3E");
}

/* ---------- 휴대폰 (760px 이하): 명세 "모바일에서도 깨지지 않게" ----------
   주 메뉴는 아래 탭 5개, 음성 메모·프로필은 위에 아이콘만. 넓은 표·시간표는 그 칸만 가로로 밀어 본다 */
@media (max-width: 760px) {
  .board,
  .column[data-status="done"] .cards {
    grid-template-columns: minmax(0, 1fr);
  }
  :root {
    --page-pad-x: 16px;
    --header-pad-x: 16px;
    --fs-hero: 34px;
    --fs-h1: 26px;
    --tabbar-h: 60px;
  }
  .container {
    padding-top: 20px;
    padding-bottom: calc(var(--tabbar-h) + 96px + env(safe-area-inset-bottom));
  }
  .gnav {
    gap: 8px;
    /* backdrop-filter가 있으면 안쪽 position: fixed(아래 탭)가 헤더 기준으로 붙어 버린다 */
    background: var(--bg);
    backdrop-filter: none;
  }
  .gnav-links {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 30;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0;
    height: calc(var(--tabbar-h) + env(safe-area-inset-bottom));
    padding-bottom: env(safe-area-inset-bottom);
    border-top: 1px solid var(--line-2);
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: saturate(180%) blur(14px);
  }
  .gnav-links a {
    position: relative;
    flex-direction: column;
    justify-content: center;
    gap: 3px;
    height: 100%;
    padding: 0 2px;
    border-radius: 0;
    color: var(--ink-3);
    font-size: 12px;
  }
  .gnav-links a > .i {
    display: block;
    width: 22px;
    height: 22px;
  }
  .gnav-links a:hover,
  .gnav-links a[aria-current="page"] {
    background: none;
    color: var(--ink);
  }
  .gnav-links .nav-badge {
    position: absolute;
    top: 6px;
    left: calc(50% + 6px);
  }
  .gnav-user {
    margin-left: auto;
    gap: 4px;
  }
  .gnav-memo {
    width: 40px;
    height: 40px;
    padding: 0;
    justify-content: center;
  }
  .gnav-memo .lbl,
  .user-menu .chev {
    display: none;
  }
  .gnav-memo .i {
    width: 18px;
    height: 18px;
  }
  .user-menu summary {
    padding: 0 5px;
  }
  /* 비서 버튼은 아래 탭 위로 올리고 동그란 아이콘만 */
  .fab {
    right: 16px;
    bottom: calc(var(--tabbar-h) + 16px + env(safe-area-inset-bottom));
    height: 52px;
    padding: 0 8px;
    font-size: 0;
  }
  /* 대시보드 타임라인: 시간 | 내용, 상태 칩은 내용 아래로 */
  .timeline > li {
    grid-template-columns: 84px minmax(0, 1fr);
    row-gap: 4px;
  }
  .timeline > li .tl-kind {
    display: none;
  }
  .timeline > li > :last-child:not(:empty) {
    grid-column: 2;
  }
  /* 시간표: 칸이 너무 좁아지지 않게 표만 가로 스크롤 */
  .tt-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  /* 할 일 빠른 추가: 옵션을 아래 줄로 내려 감싼다 */
  .composer .qa-opts > .qa-due,
  .composer input.pill {
    flex: 1 1 100%;
    width: 100%;
  }
  .composer .qa-opts > .qa-select {
    flex: 1 1 0;
  }
  .composer .qa-select select {
    flex: 1;
    min-width: 0;
  }
  .found-read b {
    flex-basis: 100%;
  }
  .mail-from small {
    display: block;
    margin-left: 0;
    font-size: 13px;
  }
  .mail-head {
    align-items: flex-start;
  }
  /* 받은 편지함 후보: 제목·마감·과목을 세로로 */
  .found-meta {
    flex-direction: column;
  }
  .found .found-meta > * {
    flex: none;
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
