/* 수학 재건 36강 — 한국어 본문용 조정 */

:root {
  --han: "Pretendard", "Malgun Gothic", "Apple SD Gothic Neo",
         "Noto Sans KR", "NanumGothic", sans-serif;
  --quote-bg: #fbf7ec;      /* 강사 대사 크림색 바탕 (LaTeX quote 환경 재현) */
  --quote-rule: #c8a13a;    /* 금색 세로줄 */
}

html body {
  font-family: var(--han);
  /* 한글은 라틴 문자보다 자간이 촘촘해 보이므로 줄 간격을 넓힌다 */
  line-height: 1.75;
  word-break: keep-all;      /* 어절 중간에서 줄이 끊기지 않게 한다 */
  overflow-wrap: break-word;
}

h1, h2, h3, h4, .bd-sidebar {
  font-family: var(--han);
  word-break: keep-all;
}

/* 강 제목 아래 구분선 */
h1 {
  border-bottom: 2px solid var(--pst-color-border, #ced6dd);
  padding-bottom: 0.35em;
}

/* 강사 대사 — 인용문을 크림색 바탕 + 금색 세로줄로. 교안의 핵심 목소리다. */
blockquote {
  background: var(--quote-bg);
  border-left: 4px solid var(--quote-rule);
  border-radius: 4px;
  padding: 0.6em 1em;
  margin: 1em 0;
  color: inherit;
}
blockquote p:last-child { margin-bottom: 0; }

/* 다크 모드에서 크림 바탕이 눈부시지 않게 낮춘다 */
html[data-theme="dark"] blockquote {
  background: rgba(200, 161, 58, 0.10);
}

/* 표가 넓어질 때 가로 스크롤을 허용한다 (타임라인·매핑표가 넓다) */
.table-wrapper, div.cell_output table, table.docutils {
  display: block;
  overflow-x: auto;
  max-width: 100%;
}

/* 칠판 그림(ASCII 아트)은 그대로 등폭으로 보이게 둔다 */
pre {
  font-size: 0.86em;
  line-height: 1.5;
}

/* 접이식 정답 상자(admonition dropdown)를 본문과 구별한다 */
details.dropdown, .admonition.dropdown {
  border-radius: 4px;
}

/* 좌측 사이드바 부 제목을 또렷하게 */
.bd-sidebar .caption-text {
  font-weight: 700;
}

/* 교재 그림(matplotlib SVG) — 흰 카드로 감싸 다크모드에서도 선이 보이게 */
img.chfig {
  display: block;
  margin: 1em auto;
  max-width: 100%;
  height: auto;
  background: #ffffff;
  border: 1px solid var(--pst-color-border, #e5e7eb);
  border-radius: 8px;
  padding: 10px;
}
