/* 트리닥터 베스트 댓글 — 네이버 뉴스 댓글처럼 촘촘하고 깔끔하게 */
.tdc {
	--tdc-ink: #1B2420;
	--tdc-mut: #6B7280;
	--tdc-line: #E7ECE9;
	--tdc-green: #1E6B4A;
	--tdc-green-d: #123F2C;
	--tdc-red: #C8281A;
	margin: 36px 0 8px;
	color: var(--tdc-ink);
	font-size: 15px;
	line-height: 1.65;
}

/* 머리: 제목 + 정렬 탭 */
.tdc-head {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 12px;
	padding-bottom: 10px;
	border-bottom: 2px solid var(--tdc-ink);
}
.tdc-title { margin: 0; font-size: 20px; font-weight: 900; letter-spacing: -0.02em; }
.tdc-count { color: var(--tdc-green); font-weight: 900; }
.tdc-tabs { display: flex; gap: 2px; flex: 0 0 auto; }
.tdc-tab {
	border: 0; background: none; cursor: pointer; padding: 6px 10px; border-radius: 999px;
	font-family: inherit; font-size: 13.5px; font-weight: 600; color: var(--tdc-mut);
	white-space: nowrap;
}
.tdc-tab:hover { background: #F2F5F3; color: var(--tdc-ink); }
.tdc-tab.is-on { background: var(--tdc-green-d); color: #fff; font-weight: 800; }

/* BEST 1·2·3등 */
.tdc-best {
	margin: 14px 0 6px;
	padding: 12px 16px 4px;
	background: linear-gradient(180deg, #F6FAF8 0%, #FFFFFF 100%);
	border: 1px solid #D9E6DE;
	border-radius: 14px;
}
.tdc-best__head { display: flex; align-items: baseline; gap: 8px; margin-bottom: 2px; }
.tdc-best__title { font-size: 14px; font-weight: 900; color: var(--tdc-green-d); letter-spacing: -0.01em; }
.tdc-best__sub { font-size: 12px; color: var(--tdc-mut); }

/* 목록 공통 */
.tdc-best__list, .tdc-list, .tdc-replies { list-style: none; margin: 0; padding: 0; }
.tdc-item { position: relative; padding: 13px 0 11px; border-bottom: 1px solid var(--tdc-line); }
.tdc-best .tdc-item { border-bottom: 0; border-top: 1px dashed #DCE8E2; padding: 12px 0 10px; }
.tdc-best .tdc-item:first-child { border-top: 0; padding-top: 10px; }
.tdc-list > .tdc-item:last-child { border-bottom: 0; }

.tdc-item__head { display: flex; align-items: center; gap: 7px; margin-bottom: 4px; }
.tdc-name { font-size: 13.5px; font-weight: 800; color: var(--tdc-ink); }
.tdc-dot { width: 2px; height: 2px; border-radius: 2px; background: #C6CFCA; }
.tdc-time { font-size: 12.5px; color: var(--tdc-mut); }
.tdc-body { font-size: 15px; line-height: 1.7; color: #2B3631; word-break: keep-all; overflow-wrap: anywhere; }
.tdc-body p { margin: 0 0 6px; }
.tdc-body p:last-child { margin-bottom: 0; }

/* BEST 배지 */
.tdc-badge {
	display: inline-block; margin: 0 0 6px; padding: 2px 9px; border-radius: 999px;
	font-size: 11.5px; font-weight: 900; letter-spacing: 0.01em; color: #fff;
}
.tdc-badge--1 { background: var(--tdc-red); }
.tdc-badge--2 { background: var(--tdc-green); }
.tdc-badge--3 { background: #9A7433; }
.tdc-item--best .tdc-body { font-size: 14.5px; }
.tdc-item--rank1 .tdc-body { font-weight: 600; }

/* 하단: 답글 작성 / 답글 N · 좋아요/싫어요 */
.tdc-item__foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 7px; }
.tdc-acts { display: flex; align-items: center; gap: 12px; }
.tdc-reply-btn, .tdc-thread-btn {
	border: 0; background: none; padding: 2px 0; cursor: pointer;
	font-family: inherit; font-size: 12.5px; font-weight: 700; color: var(--tdc-mut);
}
.tdc-reply-btn:hover, .tdc-thread-btn:hover { color: var(--tdc-green); text-decoration: underline; text-underline-offset: 3px; }
.tdc-thread-btn::before { content: "↳ "; }
.tdc-votes { display: flex; gap: 5px; flex: 0 0 auto; }
.tdc-vote {
	display: inline-flex; align-items: center; gap: 4px;
	border: 1px solid #E1E7E3; background: #fff; border-radius: 999px;
	padding: 3px 9px; font-family: inherit; font-size: 12.5px; font-weight: 700; color: #55605A;
	cursor: pointer; transition: border-color .12s, background .12s, color .12s;
}
.tdc-vote:hover { border-color: #BFD3C8; background: #F7FAF8; }
.tdc-vote.is-voted { border-color: var(--tdc-green); background: #EEF6F1; color: var(--tdc-green-d); }
.tdc-vote:disabled { cursor: default; }
.tdc-vote__icon { font-size: 12px; line-height: 1; }

/* 답글 목록 */
.tdc-replies { margin: 8px 0 0; padding: 0 0 0 12px; border-left: 2px solid #E3EAE6; }
.tdc-replies[hidden] { display: none; }
.tdc-item--reply { border-bottom: 0; padding: 9px 0; }
.tdc-item--reply + .tdc-item--reply { border-top: 1px solid #F0F3F1; }
.tdc-item--reply .tdc-name { font-size: 13px; }
.tdc-item--reply .tdc-body { font-size: 14.5px; }

/* 작성 폼 */
.tdc-form {
	margin: 16px 0 10px; padding: 16px 16px 14px;
	border: 1px solid #E1E7E3; border-radius: 14px; background: #FBFCFB;
}
.tdc-form__title { margin: 0 0 10px; font-size: 15.5px; font-weight: 900; color: var(--tdc-ink); }
.tdc-field { margin: 0 0 10px; }
.tdc-field:last-of-type { margin-bottom: 0; }
.tdc-field label { display: block; margin-bottom: 5px; font-size: 12.5px; font-weight: 700; color: #55605A; }
.tdc-field input[type="text"], .tdc-field textarea {
	width: 100%; box-sizing: border-box; padding: 10px 12px;
	border: 1px solid #DCE4DF; border-radius: 10px; background: #fff;
	font-family: inherit; font-size: 15px; line-height: 1.6; color: var(--tdc-ink);
}
.tdc-field textarea { resize: vertical; min-height: 88px; }
.tdc-field input:focus, .tdc-field textarea:focus { outline: none; border-color: var(--tdc-green); box-shadow: 0 0 0 3px rgba(30, 107, 74, .10); }
.tdc-form .form-submit { margin: 10px 0 0; display: flex; justify-content: flex-end; }
.tdc-form .tdc-submit, .tdc-form .form-submit input[type="submit"] {
	border: 0; border-radius: 999px; background: var(--tdc-green-d); color: #fff;
	padding: 10px 22px; font-family: inherit; font-size: 14.5px; font-weight: 800; cursor: pointer;
}
.tdc-form .tdc-submit:hover { background: var(--tdc-green); }
.tdc-form .comment-form-cookies-consent { display: none; }

/* 숨은 허니팟 */
.tdc-hp { position: absolute !important; left: -9999px !important; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* 답글 폼 */
.tdc-reply { margin-top: 10px; padding: 12px; border: 1px solid #E1E7E3; border-radius: 12px; background: #FBFCFB; }
.tdc-reply[hidden] { display: none; }
.tdc-reply__row { display: flex; flex-direction: column; gap: 8px; }
.tdc-reply__name, .tdc-reply__text {
	width: 100%; box-sizing: border-box; padding: 9px 11px;
	border: 1px solid #DCE4DF; border-radius: 10px; background: #fff;
	font-family: inherit; font-size: 14.5px; color: var(--tdc-ink);
}
.tdc-reply__text { resize: vertical; min-height: 64px; line-height: 1.6; }
.tdc-reply__actions { display: flex; justify-content: flex-end; gap: 6px; margin-top: 8px; }
.tdc-btn {
	border: 0; border-radius: 999px; padding: 8px 16px; cursor: pointer;
	font-family: inherit; font-size: 13.5px; font-weight: 800;
}
.tdc-btn--primary { background: var(--tdc-green-d); color: #fff; }
.tdc-btn--primary:hover { background: var(--tdc-green); }
.tdc-btn--ghost { background: #EEF1EF; color: #4B5563; }

.tdc-empty, .tdc-closed { margin: 16px 0; padding: 18px; text-align: center; color: var(--tdc-mut); font-size: 14px; background: #F8FAF9; border-radius: 12px; }

/* 오류 토스트 */
.tdc-toast {
	position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(12px);
	background: rgba(18, 63, 44, .94); color: #fff; font-size: 13.5px; font-weight: 600;
	padding: 10px 16px; border-radius: 999px; opacity: 0; pointer-events: none;
	transition: opacity .2s, transform .2s; z-index: 9999;
}
.tdc-toast.is-on { opacity: 1; transform: translateX(-50%) translateY(0); }

@media (max-width: 768px) {
	.tdc { margin-top: 28px; font-size: 14.5px; }
	.tdc-head { align-items: center; }
	.tdc-title { font-size: 18px; }
	.tdc-tab { padding: 5px 8px; font-size: 13px; }
	.tdc-best { padding: 10px 12px 2px; }
	.tdc-form { padding: 13px; }
	.tdc-body { font-size: 14.5px; }
	.tdc-item__foot { margin-top: 6px; }
	.tdc-vote { padding: 3px 8px; }
}

/* 2026-12-02 피드백 — 본문에 바짝, 입력창은 낮고 넓게, 닉네임 옆 익명/관리자 배지 */
.tdc { margin: 10px 0 6px; }
.tdc-head { padding-bottom: 8px; }
.tdc-form { margin: 10px 0 8px; padding: 12px 12px 10px; border-radius: 12px; }
.tdc-form__title { margin: 0 0 8px; font-size: 14.5px; }
.tdc-form__row { display: flex; align-items: flex-start; gap: 8px; }
.tdc-form__row .tdc-field { margin: 0; }
.tdc-field--name { flex: 0 0 128px; width: 128px; }
.tdc-field--text { flex: 1 1 auto; min-width: 0; }
.tdc-field input[type="text"] { height: 46px; padding: 0 12px; }
.tdc-field textarea { height: 46px; min-height: 46px; padding: 12px 12px; resize: none; overflow: auto; line-height: 1.5; }
.tdc-form .form-submit { margin: 0; flex: 0 0 auto; }
.tdc-form .tdc-submit { height: 46px; padding: 0 20px; border-radius: 10px; font-size: 14.5px; }

.tdc-item__head { gap: 6px; }
.tdc-anon {
	display: inline-flex; align-items: center;
	margin-left: 2px; padding: 1px 7px; border-radius: 999px;
	border: 1px solid #E1E7E3; background: #F7FAF8;
	font-size: 10.5px; font-weight: 700; color: #6B7280; line-height: 1.7;
}
.tdc-anon--admin { background: var(--tdc-green-d); border-color: var(--tdc-green-d); color: #fff; }
.tdc-best .tdc-item__head .tdc-anon { margin-left: 0; }

@media (max-width: 768px) {
	.tdc { margin-top: 8px; }
	.tdc-form { padding: 11px; }
	.tdc-form__row { flex-wrap: wrap; }
	.tdc-field--name { flex: 1 1 100%; width: 100%; }
	.tdc-field--text { flex: 1 1 100%; }
	.tdc-field textarea { height: 62px; min-height: 62px; }
	.tdc-form .form-submit { flex: 1 1 100%; display: flex; justify-content: flex-end; }
	.tdc-form .tdc-submit { height: 44px; }
}

/* =====================================================================
   2026-12-03 — (1) 댓글 영역 폭을 위 본문(.entry-content)과 정확히 일치
   원인: GeneratePress 의 `.separate-containers .comments-area{padding:40px}`
   (모바일은 인라인 규칙 30px) 때문에 댓글 내부가 본문보다 좌우 40px씩 좁았다.
   ===================================================================== */
.tdc.comments-area,
#comments.tdc {
	padding-left: 0 !important;
	padding-right: 0 !important;
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
}

/* =====================================================================
   2026-12-03 — (2) 삭제용 비밀번호 칸 (입력창 안쪽, 컴팩트)
   ===================================================================== */
.tdc-field--pw { flex: 0 0 118px; width: 118px; }
.tdc-field--pw input[type="password"] {
	height: 46px; padding: 0 10px; font-size: 13.5px;
}
.tdc-form__hint {
	margin-left: 6px; font-size: 11.5px; font-weight: 600; color: var(--tdc-mut);
	letter-spacing: 0;
}

/* 답글 폼 — 닉네임 + 비밀번호 한 줄, 내용은 아래 */
.tdc-reply__row { display: flex; flex-direction: row; flex-wrap: wrap; gap: 8px; }
.tdc-reply__name { flex: 1 1 120px; width: auto; }
.tdc-reply__pw {
	flex: 0 0 130px; width: 130px; height: 38px; padding: 0 10px;
	border: 1px solid #DCE4DF; border-radius: 10px; background: #fff;
	font-family: inherit; font-size: 13.5px; color: var(--tdc-ink);
}
.tdc-reply__pw:focus { outline: none; border-color: var(--tdc-green); box-shadow: 0 0 0 3px rgba(30, 107, 74, .10); }
.tdc-reply__text { margin-top: 8px; }

/* =====================================================================
   2026-12-03 — (3) 내 댓글 삭제 버튼 + 확인 줄
   ===================================================================== */
.tdc-del-btn {
	border: 0; background: none; padding: 2px 0; cursor: pointer;
	font-family: inherit; font-size: 12.5px; font-weight: 700; color: #9AA3A0;
}
.tdc-del-btn:hover { color: var(--tdc-red); text-decoration: underline; text-underline-offset: 3px; }

.tdc-del {
	display: flex; align-items: center; flex-wrap: wrap; gap: 6px;
	margin-top: 8px; padding: 8px 10px;
	border: 1px solid #EED9D6; border-radius: 10px; background: #FFF8F7;
}
.tdc-del[hidden] { display: none; }
.tdc-del__txt { font-size: 12.5px; font-weight: 700; color: #8A5A55; }
.tdc-del__pw {
	width: 120px; height: 34px; padding: 0 9px;
	border: 1px solid #E3C9C5; border-radius: 8px; background: #fff;
	font-family: inherit; font-size: 13px; color: var(--tdc-ink);
}
.tdc-del__pw:focus { outline: none; border-color: var(--tdc-red); box-shadow: 0 0 0 3px rgba(200, 40, 26, .08); }
.tdc-del .tdc-btn { padding: 7px 13px; font-size: 12.5px; }
.tdc-btn--danger { background: var(--tdc-red); color: #fff; }
.tdc-btn--danger:hover { background: #A81F14; }
.tdc-del__msg { font-size: 12px; font-weight: 700; color: var(--tdc-red); }
.tdc-del__msg.is-ok { color: var(--tdc-green); }
.tdc-item.is-removing { opacity: 0; transition: opacity .18s ease; }

@media (max-width: 768px) {
	.tdc-form__hint { display: none; }
	.tdc-field--name,
	.tdc-field--pw { flex: 1 1 calc(50% - 4px); width: auto; min-width: 0; }
	.tdc-field--pw input[type="password"] { height: 44px; font-size: 13px; }
	.tdc-field--text { flex: 1 1 100%; }
	.tdc-form .form-submit { flex: 1 1 100%; }
	.tdc-reply__name { flex: 1 1 calc(50% - 4px); }
	.tdc-reply__pw { flex: 1 1 calc(50% - 4px); width: auto; height: 36px; }
	.tdc-del { gap: 5px; }
	.tdc-del__pw { width: 104px; }
}
