@import url('https://fonts.googleapis.com/css2?family=Jost:wght@400;500&display=swap');
@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/static/pretendard.min.css');

.epb {
	--epb-point: var(--ep-point, #4a4a4a);
	--epb-ink: var(--ep-ink, #222222);
	--epb-muted: var(--ep-muted, #8a8a8a);
	--epb-line: var(--ep-line, #cfcfcf);
	--epb-rule: var(--ep-rule, #555555);
	--epb-mist: var(--ep-mist, #f4f4f4);
	--epb-field: var(--ep-field, #e9e9e9);
	color: var(--epb-ink);
	font-size: 14px;
}
.epb a { color: inherit; text-decoration: none; }

/* ---------- 머리: 제목 + 검색 ---------- */
.epb-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	margin-bottom: 22px;
}
.epb-title {
	margin: 0;
	font-family: var(--ep-font, 'Jost', 'Pretendard', -apple-system, 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif);
	font-weight: 400;
	font-size: 40px;
	line-height: 1.15;
	letter-spacing: -.005em;
	color: var(--epb-ink);
}
.epb-search input {
	width: 194px;
	height: 28px;
	padding: 0 12px;
	box-sizing: border-box;
	border: 1px solid transparent;
	border-radius: 4px;
	background: var(--epb-field);
	color: var(--epb-ink);
	font: inherit;
	font-size: 11px;
	transition: border-color .15s, background .15s;
}
.epb-search input::placeholder { color: var(--epb-muted); }
.epb-search input:focus { outline: 0; background: #fff; border-color: var(--epb-rule); }

/* ---------- 분류 탭 ---------- */
.epb-tabs {
	display: flex;
	gap: 28px;
	border-bottom: 1px solid var(--epb-rule);
	overflow-x: auto;
	scrollbar-width: none;
}
.epb-tabs a {
	flex: none;
	padding: 0 2px 10px;
	font-size: 12px;
	color: var(--epb-muted);
	transition: color .15s;
}
.epb-tabs a:hover { color: var(--epb-ink); }
.epb-tabs a.is-active { color: var(--epb-ink); box-shadow: inset 0 -2px 0 var(--epb-rule); }
.epb-tabs-line { border-bottom: 1px solid var(--epb-rule); }

.epb-result { margin: 14px 0 0; font-size: 12px; color: var(--epb-muted); }
.epb-result a { text-decoration: underline; }

/* ---------- 목록 ---------- */
.epb-list { margin: 0; padding: 0; list-style: none; }
.epb-item { border-bottom: 1px solid var(--epb-line); }
.epb-item__link {
	display: block;
	padding: 13px 12px 13px 24px;
	transition: background .12s;
}
.epb-item__link:hover,
.epb-item.is-current .epb-item__link { background: var(--epb-mist); }

.epb-item__top { display: flex; align-items: center; gap: 8px; min-width: 0; }
.epb-item__title {
	flex: none;
	max-width: 60%;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	font-size: 13px;
	font-weight: 400;
	line-height: 1.6;
}
.epb-item.is-current .epb-item__title { font-weight: 500; }
.epb-item__excerpt {
	flex: 0 1 auto;
	min-width: 0;
	margin-left: 10px;
	padding-left: 12px;
	border-left: 1px solid var(--epb-line);
	font-size: 12px;
	color: var(--epb-muted);
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}
.epb-item__source {
	flex: none;
	padding: 0 7px;
	border-radius: 3px;
	background: var(--epb-field);
	font-size: 10.5px;
	line-height: 18px;
	color: #666;
	white-space: nowrap;
}
.epb-item__count { flex: none; font-size: 11px; color: var(--epb-muted); }
.epb-item__author {
	flex: none;
	margin-left: auto;
	padding-left: 16px;
	font-size: 11px;
	color: var(--epb-muted);
	white-space: nowrap;
}
.epb-item.is-notice .epb-item__title { color: var(--epb-muted); }

.epb-badge {
	flex: none;
	display: inline-block;
	padding: 0 5px;
	border: 1px solid var(--epb-muted);
	border-radius: 2px;
	font-size: 10px;
	line-height: 14px;
	color: var(--epb-muted);
	white-space: nowrap;
}

.epb-empty { padding: 56px 0; text-align: center; color: var(--epb-muted); font-size: 13px; border-bottom: 1px solid var(--epb-line); margin: 0; }

/* ---------- 하단: 페이지 + 글쓰기 ---------- */
.epb-foot {
	display: flex;
	align-items: center;
	justify-content: center;
	position: relative;
	min-height: 30px;
	margin-top: 31px;
}
.epb-foot .epb-btn { position: absolute; right: 0; }
.epb-pager { display: flex; gap: 2px; font-size: 12px; }
.epb-pager a, .epb-pager strong {
	min-width: 26px;
	height: 26px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: var(--epb-muted);
}
.epb-pager a:hover { color: var(--epb-ink); }
.epb-pager strong { color: var(--epb-ink); font-weight: 500; text-decoration: underline; text-underline-offset: 4px; }

.epb-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	height: 30px;
	padding: 0 16px;
	border: 1px solid var(--epb-point);
	border-radius: 3px;
	background: var(--epb-point);
	color: #fff !important;
	font: inherit;
	font-size: 11px;
	font-weight: 500;
	cursor: pointer;
	transition: filter .15s;
}
.epb-btn:hover { filter: brightness(.8); }
.epb-btn.is-line { background: #fff; color: var(--epb-point) !important; border-color: var(--epb-line); }
.epb-btn.is-line:hover { filter: none; background: var(--epb-mist); }

/* ---------- 본문 ---------- */
.epb-read { max-width: 720px; margin: 0 auto; }
.epb-read__head {
	text-align: center;
	padding-bottom: 32px;
	margin-bottom: 40px;
	border-bottom: 1px solid var(--epb-rule);
}
.epb-read__cat { margin: 0 0 10px; font-size: 12px; color: var(--epb-muted); display: flex; justify-content: center; align-items: center; gap: 8px; }
.epb-read__source {
	padding: 0 8px;
	border-radius: 3px;
	background: var(--epb-field);
	line-height: 20px;
	color: #555 !important;
	transition: background .12s;
}
.epb-read__source:hover { background: #dcdcdc; }
.epb-read__title { margin: 0; font-size: 24px; font-weight: 500; line-height: 1.4; }
.epb-read__meta { margin: 12px 0 0; font-size: 12px; color: var(--epb-muted); display: flex; justify-content: center; gap: 12px; }
.epb-read__body { font-size: 15px; line-height: 1.95; word-break: keep-all; overflow-wrap: anywhere; }
.epb-read__body img { max-width: 100%; height: auto; }
.epb-read__body p { margin: 0 0 1em; }
.epb-read__tags { margin: 40px 0 0; display: flex; flex-wrap: wrap; gap: 10px; font-size: 12px; color: var(--epb-muted); }
.epb-read__tags a:hover { color: var(--epb-ink); }
.epb-read__actions { margin-top: 32px; display: flex; gap: 18px; justify-content: flex-end; font-size: 12px; }
.epb-read__actions a { text-decoration: underline !important; text-underline-offset: 3px; }
.epb-read__actions a:hover { opacity: .6; }

/* ---------- 이전 / 다음 글 ---------- */
.epb-pn {
	display: grid;
	grid-template-columns: 1fr 1fr;
	margin-top: 48px;
	border-top: 1px solid var(--epb-rule);
	border-bottom: 1px solid var(--epb-line);
}
.epb-pn a {
	display: flex;
	flex-direction: column;
	gap: 2px;
	padding: 14px 16px;
	min-width: 0;
	transition: background .12s;
}
.epb-pn a:hover { background: var(--epb-mist); }
.epb-pn span { font-size: 11px; color: var(--epb-muted); }
.epb-pn strong { font-size: 13px; font-weight: 400; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.epb-pn__next { grid-column: 2; text-align: right; }
.epb-pn__prev + .epb-pn__next { border-left: 1px solid var(--epb-line); }

/* ---------- 댓글 ---------- */
.epb-comments { margin-top: 56px; }
.epb-comments__title {
	margin: 0;
	padding-bottom: 10px;
	border-bottom: 1px solid var(--epb-rule);
	font-size: 13px;
	font-weight: 500;
}
.epb-comments__title span { color: var(--epb-muted); font-weight: 400; }
.epb-comments__list { margin: 0 0 24px; padding: 0; list-style: none; }
.epb-comment {
	padding: 14px 12px 14px calc(12px + var(--depth, 0) * 24px);
	border-bottom: 1px solid var(--epb-line);
}
.epb-comment__meta { margin: 0 0 4px; font-size: 12px; display: flex; gap: 10px; align-items: baseline; }
.epb-comment__meta strong { font-weight: 500; }
.epb-comment__meta time { color: var(--epb-muted); font-size: 11px; }
.epb-comment__body { font-size: 13px; line-height: 1.75; }
.epb-comment__actions { margin: 4px 0 0; display: flex; gap: 12px; font-size: 11px; color: var(--epb-muted); }
.epb-comment__actions a:hover { color: var(--epb-ink); }
.epb-source { padding: 14px 18px; margin-bottom: 24px; background: var(--epb-mist); border-left: 2px solid var(--epb-rule); }

/* ---------- 폼 ---------- */
.epb-form { display: flex; flex-direction: column; gap: 12px; }
.epb-form__title {
	margin: 0 0 10px;
	padding-bottom: 12px;
	border-bottom: 1px solid var(--epb-rule);
	font-size: 17px;
	font-weight: 500;
}
.epb-row { display: flex; gap: 8px; flex-wrap: wrap; }
.epb-grow { flex: 1; min-width: 200px; }
.epb-form input[type="text"],
.epb-form input[type="password"],
.epb-form input[type="email"],
.epb-form input[type="url"],
.epb-form input[type="number"],
.epb-form select,
.epb-form textarea {
	height: 34px;
	padding: 0 12px;
	box-sizing: border-box;
	border: 1px solid transparent;
	border-radius: 4px;
	background: var(--epb-field);
	color: var(--epb-ink);
	font: inherit;
	font-size: 13px;
}
.epb-form textarea { height: auto; min-height: 80px; padding: 10px 12px; width: 100%; }
.epb-form input::placeholder, .epb-form textarea::placeholder { color: var(--epb-muted); }
.epb-form input:focus, .epb-form select:focus, .epb-form textarea:focus { outline: 0; background: #fff; border-color: var(--epb-rule); }
.epb-extra { display: grid; gap: 12px; }
.epb-field label { display: block; margin-bottom: 4px; font-size: 12px; color: var(--epb-muted); }
.epb-field label em { color: var(--epb-ink); font-style: normal; }
.epb-field input[type="text"] { width: 100%; }
.epb-form__submit { display: flex; align-items: center; justify-content: flex-end; gap: 8px; flex-wrap: wrap; font-size: 12px; margin-top: 6px; }
.epb-form__submit label { display: inline-flex; align-items: center; gap: 4px; margin-right: 8px; color: var(--epb-muted); }
.epb-confirm, .epb-lock { max-width: 440px; margin: 40px auto; text-align: center; }
.epb-confirm .epb-row, .epb-lock .epb-row, .epb-confirm .epb-form__submit { justify-content: center; }

/* ---------- 모바일 ---------- */
@media (max-width: 640px) {
	.epb-head { flex-direction: column; align-items: stretch; gap: 14px; }
	.epb-title { font-size: 32px; }
	.epb-search input { width: 100%; height: 34px; font-size: 13px; }
	.epb-tabs { gap: 22px; }
	.epb-item__link { padding: 13px 8px 13px 12px; }
	.epb-item__top { flex-wrap: wrap; row-gap: 2px; }
	.epb-item__title { max-width: none; flex: 1 1 auto; white-space: normal; }
	.epb-item__excerpt { order: 10; flex-basis: 100%; margin: 0; padding: 0; border: 0; }
	.epb-foot { flex-direction: column; gap: 16px; }
	.epb-foot .epb-btn { position: static; align-self: flex-end; }
	.epb-read__title { font-size: 21px; }
}
