/* =========================================
   Subpage (List) Unique Styles
   (Default.Style.css에 없는 스타일 모음)
   ========================================= */

/* 1. Typography Utilities */
.font-black {
	font-weight: 900;
}

.text-muted {
	color: var(--text-muted);
}

.text-brand {
	color: var(--c-brand-600);
}

html.dark .text-brand {
	color: var(--c-brand-500);
}

/* 2. Page Header (Subpage Specific) */
/* 제목, 설명, 검색창이 있는 상단 헤더 박스 */
.page-header-card {
	background-color: var(--bg-card);
	border: 1px solid var(--border-color);
	border-radius: 1.5rem;
	padding: 2rem;
	box-shadow: var(--shadow-sm);
}

.ph-layout {
	display: flex;
	flex-direction: column;
	gap: 1.5rem;
}

@media (min-width: 768px) {
	.ph-layout {
		flex-direction: row;
		align-items: flex-end;
		justify-content: space-between;
	}
}

.ph-tag {
	font-size: 0.75rem;
	font-weight: 700;
	color: var(--c-brand-600);
	letter-spacing: 0.05em;
}

html.dark .ph-tag {
	color: var(--c-brand-500);
}

.ph-title {
	font-size: 1.875rem;
	font-weight: 900;
	margin-top: 0.5rem;
	line-height: 1.2;
}

@media (min-width: 768px) {
	.ph-title {
		font-size: 2.25rem;
	}
}

.ph-desc {
	font-size: 0.875rem;
	color: var(--text-muted);
	margin-top: 0.75rem;
	line-height: 1.6;
}

/* 3. Search & Controls */
/* 검색창 및 정렬 셀렉트 박스 */
.controls-group {
	display: flex;
	gap: 0.5rem;
}

.search-wrapper {
	position: relative;
}

.search-icon {
	position: absolute;
	left: 1rem;
	top: 50%;
	transform: translateY(-50%);
	color: var(--c-slate-400);
	font-size: 0.875rem;
}

.form-input {
	padding: 0.75rem 1rem 0.75rem 2.5rem;
	width: 18rem;
	max-width: 100%;
	border-radius: 1rem;
	background-color: var(--bg-input);
	/* Root 변수에 추가 필요 */
	border: 1px solid var(--border-color);
	color: var(--text-main);
	font-size: 0.875rem;
	transition: box-shadow 0.2s;
}

.form-select {
	padding: 0.75rem 1rem;
	border-radius: 1rem;
	background-color: var(--bg-input);
	/* Root 변수에 추가 필요 */
	border: 1px solid var(--border-color);
	color: var(--text-main);
	font-size: 0.875rem;
	cursor: pointer;
}

.form-input:focus,
.form-select:focus {
	box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.3);
}

/* 4. Content Layout Grid */
/* 본문(리스트)과 사이드바를 나누는 레이아웃 */
.content-layout {
	display: grid;
	grid-template-columns: 1fr;
	gap: 1.5rem;
}

@media (min-width: 768px) {
	.content-layout {
		grid-template-columns: repeat(12, 1fr);
	}
}

.col-main {
	grid-column: span 1;
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.col-side {
	grid-column: span 1;
	display: flex;
	flex-direction: column;
	gap: 1.5rem;
}

@media (min-width: 768px) {
	.col-main {
		grid-column: span 8;
	}

	.col-side {
		grid-column: span 4;
	}
}

/* 5. List Items (Articles) */
/* 리스트 형태의 게시글 카드 스타일 */
.list-card {
	background-color: var(--bg-card);
	border: 1px solid var(--border-color);
	border-radius: 1rem;
	padding: 1.5rem;
	transition: box-shadow 0.3s;
}

.list-card:hover {
	box-shadow: var(--shadow-lg);
}

.lc-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 0.75rem;
}

.lc-category {
	font-size: 0.75rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	color: var(--c-brand-600);
}

html.dark .lc-category {
	color: var(--c-brand-500);
}

.lc-date {
	font-size: 0.75rem;
	color: var(--c-slate-400);
}

.lc-title {
	font-size: 1.125rem;
	font-weight: 700;
	margin-bottom: 0.5rem;
}

@media (min-width: 768px) {
	.lc-title {
		font-size: 1.25rem;
	}
}

.lc-title a:hover {
	color: var(--c-brand-500);
}

.lc-desc {
	font-size: 0.875rem;
	color: var(--text-muted);
	line-height: 1.5;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.lc-tags {
	display: flex;
	gap: 0.5rem;
	margin-top: 1rem;
}

.tag-pill {
	padding: 0.25rem 0.5rem;
	border-radius: 0.5rem;
	font-size: 0.75rem;
	background-color: var(--bg-hover);
	color: var(--text-muted);
}

/* 6. Pagination */
/* 하단 페이지 이동 버튼 */
.pagination {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding-top: 1rem;
}

.btn-page {
	padding: 0.5rem 1rem;
	border-radius: 0.75rem;
	font-size: 0.875rem;
	background-color: var(--bg-card);
	border: 1px solid var(--border-color);
	color: var(--text-main);
	transition: background-color 0.2s;
}

.btn-page:hover {
	background-color: var(--bg-hover);
}

/* 7. Sidebar Widgets */
/* 우측 사이드바 위젯 (인기글, 태그 등) */
.side-widget {
	background-color: var(--bg-card);
	border: 1px solid var(--border-color);
	border-radius: 1rem;
	padding: 1.5rem;
	box-shadow: var(--shadow-sm);
}

.sw-title {
	font-weight: 700;
	margin-bottom: 0.75rem;
	display: flex;
	align-items: center;
}

.sw-title i {
	color: var(--c-slate-400);
	margin-right: 0.5rem;
}

.popular-list {
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
	font-size: 0.875rem;
}

.popular-list a:hover {
	color: var(--c-brand-500);
}

.tag-cloud {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
}

.tag-btn {
	padding: 0.25rem 0.75rem;
	border-radius: 9999px;
	font-size: 0.75rem;
	background-color: var(--bg-hover);
	color: var(--text-muted);
	transition: all 0.2s;
}

.tag-btn:hover {
	background-color: var(--c-brand-500);
	color: white;
}