/* =========================================================
   FluxBoard — 카페형 목록 행 (3.0.0)

   게시판 목록(list_style = cafe)과 프로필 탭(작성글·댓글단 글·좋아요한 글)이 같이 쓴다.
   카드를 나열하지 않는다 — 구분선으로만 나눈 행. 제목 17/500 · 메타 13 · 썸네일 64 · 댓글 박스 56×64.
   숫자는 tabular-nums. 가로 스크롤 0(360px), 터치 높이 44px 이상.

   1. 변수  2. 목록·행  3. 칩 행  4. 제목·메타  5. 썸네일·댓글 박스  6. 하트  7. 상태(읽음·비밀·답글)  8. 반응형  9. 모션 줄이기
   ========================================================= */

/* 1. 변수 --------------------------------------------------- */
.fbcafe-list {
	--fbc-ink: #191919;
	--fbc-sub: #6b6b6b;
	--fbc-line: #e8e8e8;
	--fbc-surface: #f4f4f4;
	--fbc-surface-hover: #f9f9f9;
	--fbc-accent: var(--fb-accent, var(--fs-primary, #222222));
	--fbc-alert: #e5322d;
	--fbc-chip-bg: #2b2b2b;
	--fbc-chip-ink: #ffffff;
	--fbc-focus: var(--fbc-accent);
}

/* 2. 목록·행 ------------------------------------------------ */
.fbcafe-list {
	list-style: none;
	margin: 0;
	padding: 0;
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
	color: var(--fbc-ink);
	font-family: var(--fs-font, 'Pretendard Variable', 'Pretendard', -apple-system, system-ui, sans-serif);
	border-top: 1px solid var(--fbc-line);
}

.fbcafe-list *,
.fbcafe-list *::before,
.fbcafe-list *::after {
	box-sizing: border-box;
}

.fbcafe-row {
	position: relative;
	display: flex;
	align-items: center;
	gap: 4px;
	margin: 0;
	padding: 0;
	border-bottom: 1px solid var(--fbc-line);
	background: transparent;
	transition: background-color 0.2s ease;
}

.fbcafe-row:hover {
	background: var(--fbc-surface-hover);
}

.fbcafe-row__link {
	display: flex;
	flex: 1 1 auto;
	align-items: center;
	gap: 8px;
	min-width: 0;
	min-height: 44px;
	padding: 14px 16px;
	color: inherit;
	text-decoration: none;
	-webkit-tap-highlight-color: transparent;
}

.fbcafe-row__link:hover {
	color: inherit;
	text-decoration: none;
}

.fbcafe-row__link:focus-visible {
	outline: 2px solid var(--fbc-focus);
	outline-offset: -2px;
	border-radius: 4px;
}

.fbcafe-row__main {
	flex: 1 1 auto;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 6px;
}

/* 3. 칩 행 (필독 · 게시판 공지) ------------------------------ */
.fbcafe-row--chip .fbcafe-row__link {
	padding-top: 10px;
	padding-bottom: 10px;
	gap: 10px;
}

.fbcafe-chip {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	gap: 5px;
	height: 24px;
	padding: 0 10px;
	border-radius: 12px;
	background: var(--fbc-chip-bg);
	color: var(--fbc-chip-ink);
	font-size: 12px;
	font-weight: 600;
	line-height: 1;
	white-space: nowrap;
}

.fbcafe-chip__dot {
	display: inline-block;
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--fbc-alert);
}

.fbcafe-row--chip .fbcafe-row__title--chip {
	flex: 1 1 auto;
	min-width: 0;
	font-size: 15px;
	font-weight: 500;
	-webkit-line-clamp: 1;
}

/* 4. 제목·메타 ----------------------------------------------- */
.fbcafe-row__title {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	overflow: hidden;
	margin: 0;
	font-size: 17px;
	font-weight: 500;
	line-height: 1.4;
	color: var(--fbc-ink);
	word-break: break-word;
	overflow-wrap: anywhere;
}

.fbcafe-row__cat {
	color: var(--fbc-sub);
	font-weight: 500;
}

.fbcafe-row__tag {
	display: inline-block;
	margin-right: 4px;
	padding: 1px 6px;
	border-radius: 4px;
	background: var(--fbc-surface);
	color: var(--fbc-ink);
	font-size: 12px;
	font-weight: 600;
	vertical-align: 2px;
}

.fbcafe-row__lock {
	display: inline-block;
	margin-right: 4px;
	vertical-align: -2px;
	color: var(--fbc-sub);
}

.fbcafe-row__reply {
	margin-right: 4px;
	color: var(--fbc-sub);
}

.fbcafe-row__meta {
	display: flex;
	align-items: center;
	flex-wrap: wrap; /* 좁은 폭(썸네일+댓글 박스가 있는 행)에서는 다음 줄로 넘긴다 — 잘라 먹지 않는다 */
	gap: 2px 6px;
	min-width: 0;
	overflow: visible;
	font-size: 13px;
	font-weight: 400;
	line-height: 1.3;
	color: var(--fbc-sub);
	font-variant-numeric: tabular-nums;
}

.fbcafe-row__meta > * {
	flex: 0 0 auto;
	white-space: nowrap;
}

.fbcafe-row__board,
.fbcafe-row__author {
	flex: 0 1 auto;
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
}

.fbcafe-row__author {
	color: var(--fbc-ink);
	font-weight: 500;
}

.fbcafe-row__grade {
	display: inline-flex;
	align-items: center;
	margin-left: -2px;
}

.fbcafe-row__dot {
	color: var(--fbc-sub);
}

/* 5. 썸네일 · 댓글 박스 -------------------------------------- */
.fbcafe-row__thumb {
	position: relative;
	flex: 0 0 64px;
	width: 64px;
	height: 64px;
	border-radius: 8px;
	overflow: hidden;
	background: var(--fbc-surface);
}

.fbcafe-row__thumb img {
	display: block;
	width: 64px;
	height: 64px;
	object-fit: cover;
	max-width: none;
}

.fbcafe-row__badge {
	position: absolute;
	right: 4px;
	bottom: 4px;
	min-width: 22px;
	padding: 2px 6px;
	border-radius: 10px;
	background: rgba(25, 25, 25, 0.72);
	color: #ffffff;
	font-size: 11px;
	font-weight: 600;
	line-height: 1.2;
	text-align: center;
	font-variant-numeric: tabular-nums;
}

.fbcafe-row__count {
	flex: 0 0 56px;
	width: 56px;
	height: 64px;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 2px;
	border-radius: 8px;
	background: var(--fbc-surface);
	color: var(--fbc-ink);
}

.fbcafe-row__count-num {
	font-size: 17px;
	font-weight: 700;
	line-height: 1.1;
	font-variant-numeric: tabular-nums;
}

.fbcafe-row__count-label {
	font-size: 12px;
	font-weight: 400;
	line-height: 1.1;
	color: var(--fbc-sub);
}

/* 6. 하트 (좋아요한 글) ------------------------------------- */
.fbcafe-row__heart {
	flex: 0 0 44px;
	width: 44px;
	height: 44px;
	margin-right: 8px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: var(--fbc-alert);
	cursor: pointer;
	transition: background-color 0.2s ease, transform 0.2s ease;
}

.fbcafe-row__heart:hover {
	background: var(--fbc-surface);
}

.fbcafe-row__heart:active {
	transform: scale(0.92);
}

.fbcafe-row__heart:focus-visible {
	outline: 2px solid var(--fbc-focus);
	outline-offset: 2px;
}

.fbcafe-row__heart--static {
	cursor: default;
}

.fbcafe-row__heart--static:hover {
	background: transparent;
}

/* 7. 상태 ---------------------------------------------------- */
.fbcafe-row--read .fbcafe-row__title {
	color: var(--fbc-sub);
	font-weight: 400;
}

.fbcafe-row--reply .fbcafe-row__link {
	padding-left: 28px;
}

.fbcafe-row--depth-2 .fbcafe-row__link {
	padding-left: 40px;
}

.fbcafe-row--depth-3 .fbcafe-row__link {
	padding-left: 52px;
}

/* 8. 반응형 -------------------------------------------------- */
@media (max-width: 1024px) {
	.fbcafe-row__link {
		padding-left: 14px;
		padding-right: 14px;
	}
}

@media (max-width: 768px) {
	.fbcafe-row__title {
		font-size: 17px;
	}
}

@media (max-width: 480px) {
	.fbcafe-row__link {
		gap: 8px;
		padding: 12px 12px 12px 16px;
	}

	.fbcafe-row--reply .fbcafe-row__link {
		padding-left: 24px;
	}
}

/* 9. 모션 줄이기 --------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
	.fbcafe-row,
	.fbcafe-row__heart {
		transition: none;
	}

	.fbcafe-row__heart:active {
		transform: none;
	}
}
