@charset "utf-8";
/**
 * demo-harigraft 웹폰트 (자체 호스팅 — CDN 미사용)
 *
 * Noto Sans JP / Noto Sans SC 가변폰트(wght 100~900)를 사이트에 실제로 쓰이는 글자만
 * 남겨 서브셋한 woff2 다. 전체 CJK 폰트는 굵기당 2MB 가 넘어 그대로 쓸 수 없다.
 *   JP 574자 248KB / SC 479자 142KB  (원본 각 9.1MB / 16.9MB TTF)
 *
 * 글자 목록은 languages/{ja,zh}-skin.po 의 번역문 + PHP 소스의 비번역 리터럴에서 뽑는다.
 * 문구를 바꾸거나 번역을 추가하면 assets/fonts/build-fonts.py 를 다시 실행해야
 * 새 글자가 폰트에 포함된다(빠진 글자는 시스템 폰트로 폴백되어 자형이 섞인다).
 *
 * 가변폰트라 파일 하나로 300~900 을 모두 커버한다. 실제로 쓰는 굵기는 300·400·500·700·900.
 */

@font-face {
    font-family: 'Noto Sans JP';
    font-style: normal;
    font-weight: 300 900;
    font-display: swap;
    src: url('/assets/fonts/NotoSansJP-subset.woff2') format('woff2');
}

@font-face {
    font-family: 'Noto Sans SC';
    font-style: normal;
    font-weight: 300 900;
    font-display: swap;
    src: url('/assets/fonts/NotoSansSC-subset.woff2') format('woff2');
}

/* 한국어는 Pretendard(OFL). 한글은 조합 범위가 넓어 완성형 음절 전체를 담았다(1.7MB).
   ko 는 현재 서비스 언어가 아니라 실제로 내려받히지 않는다 — 열게 되면 상용 음절만 남겨 줄일 것. */
@font-face {
    font-family: 'Pretendard';
    font-style: normal;
    font-weight: 300 900;
    font-display: swap;
    src: url('/assets/fonts/Pretendard-subset.woff2') format('woff2');
}

/*
 * 로케일별 폰트 — <html lang> 으로 분기한다.
 * 같은 한자라도 언어별 자형이 다르고(한자 통합), 가나는 일본어 폰트에만 제대로 들어 있다.
 * @font-face 는 실제로 매칭될 때만 다운로드되므로 페이지당 한 벌만 내려받는다.
 * Bootstrap 이 body 에 --bs-body-font-family 를 쓰기 때문에 변수도 함께 지정한다.
 */
html[lang^="ja"],
html[lang^="ja"] body {
    font-family: 'Noto Sans JP', 'Hiragino Kaku Gothic ProN', 'Yu Gothic', system-ui, sans-serif;
}
html[lang^="ja"] {
    --bs-body-font-family: 'Noto Sans JP', 'Hiragino Kaku Gothic ProN', 'Yu Gothic', system-ui, sans-serif;
}

html[lang^="zh"],
html[lang^="zh"] body {
    font-family: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', system-ui, sans-serif;
}
html[lang^="zh"] {
    --bs-body-font-family: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', system-ui, sans-serif;
}

html[lang^="ko"],
html[lang^="ko"] body {
    font-family: 'Pretendard', 'Apple SD Gothic Neo', 'Malgun Gothic', system-ui, sans-serif;
}
html[lang^="ko"] {
    --bs-body-font-family: 'Pretendard', 'Apple SD Gothic Neo', 'Malgun Gothic', system-ui, sans-serif;
}

/* lang 이 없거나 다른 값일 때의 기본값 — 사이트 기본 언어(ja) 기준 */
:root {
    --bs-body-font-family: 'Noto Sans JP', system-ui, -apple-system, sans-serif;
}
