워드프레스 폰트 적용하기 +Pretendard 폰트

@font-face {
    font-family: 'Pretendard';
    src: url('https://cdn.jsdelivr.net/gh/projectnoonnu/pretendard@1.0/Pretendard-Regular.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Pretendard';
    src: url('https://cdn.jsdelivr.net/gh/projectnoonnu/pretendard@1.0/Pretendard-Medium.woff2') format('woff2');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

/* ==========================================================
   기본 텍스트 (400)
   ========================================================== */

body,
p,
li,
span,
td,
th,
blockquote,
figcaption,
input,
textarea,
select,
button {
    font-family: 'Pretendard', sans-serif;
    font-weight: 400;
}

/* ==========================================================
   제목 및 소제목 (500)
   ========================================================== */

h1,
h2,
h3,
h4,
h5,
h6,
.entry-title,
.page-title,
.site-title,
.widget-title,
.wp-block-heading,
.ct-post-title {
    font-family: 'Pretendard', sans-serif;
    font-weight: 500;
}

/* ==========================================================
   네비게이션 메뉴
   ========================================================== */

.menu,
.menu a,
.ct-header,
.ct-header a {
    font-family: 'Pretendard', sans-serif;
    font-weight: 500;
}

/* ==========================================================
   버튼
   ========================================================== */

button,
.wp-block-button__link,
.ct-button,
input[type="submit"] {
    font-family: 'Pretendard', sans-serif;
    font-weight: 500;
}

/* ==========================================================
   본문
   ========================================================== */

.entry-content {
    font-family: 'Pretendard', sans-serif;
    font-weight: 400;
}

기본 텍스트는 400 적용, 그 외에는 좀 더 두꺼운 500 bold 를 적용한 CSS 이다.
모양(테마) – 사용자 정의 – CSS 에 추가하면 된다.

사실 워드프레스에 폰트 적용하는 것은 폰트 CDN 만 있다면, AI 를 통해 ‘해줘’ 하는 것이 더 빠르고 편리해진 요즘이다.