/* ===========================
   CSS Variables - Dark Theme
   =========================== */
:root {
  --bg-primary:    #0f1117;
  --bg-secondary:  #161b22;
  --bg-tertiary:   #1c2128;
  --bg-hover:      #21262d;

  --text-primary:   #e6edf3;
  --text-secondary: #8b949e;
  --text-muted:     #6e7681;

  --accent-blue:   #58a6ff;
  --accent-purple: #a371f7;
  --accent-green:  #3fb950;

  --border-color:  #30363d;
  --border-subtle: #21262d;

  --font-sans: 'Noto Sans KR', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;

  --shadow:    0 1px 3px rgba(0,0,0,0.4);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.5);

  --transition: 0.2s ease;
}

/* ===========================
   Reset & Base
   =========================== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-sans);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition);
}

ul, ol { list-style: none; }
img    { max-width: 100%; display: block; }

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
}

/* ===========================
   Accessibility
   =========================== */
.screen_out {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
}

#dkIndex { display: none; }

/* ===========================
   Outer Layout
   =========================== */
.wrap_skin {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ===========================
   Header
   =========================== */
.area_head {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: rgba(15,17,23,0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  padding: 0 24px;
  height: 60px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.area_head h1 { font-size: 0; }

/* 헤더 요소 순서 */
.btn_cate      { order: 1; flex-shrink: 0; display: none; } /* 데스크탑에서 숨김 */
.area_profile  { order: 2; flex-shrink: 0; }
.area_search   { order: 3; flex: 1; max-width: 400px; }

/* 블로그 타이틀 */
.area_profile {
  display: flex;
  align-items: center;
  gap: 10px;
}

.area_profile .tit_post { font-size: 0; }

.area_profile .link_post {
  font-size: 17px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.3px;
}

.area_profile .link_post:hover { color: var(--accent-blue); }

/* 검색 */
.area_search {
  display: flex;
  align-items: center;
}

.frm_search {
  display: flex;
  align-items: center;
  width: 100%;
}

.frm_search fieldset {
  border: none;
  padding: 0;
  margin: 0;
  width: 100%;
  display: flex;
  align-items: center;
}

.ico_skin {
  font-size: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 14px;
}

.ico_cate::before {
  content: '';
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  box-shadow: 0 5px 0 currentColor, 0 10px 0 currentColor;
}

.tf_search {
  width: 100%;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 14px;
  outline: none;
  transition: border-color var(--transition);
}

.tf_search:focus          { border-color: var(--accent-blue); }
.tf_search::placeholder   { color: var(--text-muted); }

/* 햄버거 버튼 (모바일에서만 보임) */
.btn_cate {
  display: none;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  min-height: 44px;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-size: 14px;
  transition: all var(--transition);
}

.btn_cate:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

/* ===========================
   2단 레이아웃
   =========================== */
.layout-body {
  display: flex;
  align-items: flex-start;
  flex: 1;
  max-width: 1380px;
  width: 100%;
  margin: 0 auto;
  padding: 0 24px;
  gap: 48px;
}

/* ===========================
   사이드바 (고정 노출)
   =========================== */
.area_side {
  flex-shrink: 0;
  width: 220px;
  position: sticky;
  top: 76px;
  max-height: calc(100vh - 90px);
  overflow-y: auto;
  padding: 32px 0;
}

.area_side::-webkit-scrollbar       { width: 3px; }
.area_side::-webkit-scrollbar-track { background: transparent; }
.area_side::-webkit-scrollbar-thumb { background: var(--border-color); border-radius: 2px; }

.side_inner {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

/* 사이드바 프로필 */
.side_profile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-color);
}

.thumb_profile {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg-tertiary);
  border: 2px solid var(--border-color);
  display: block;
}

.img_profile {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.txt_profile {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

/* ===========================
   카테고리 네비 (서브 카테고리 포함)
   =========================== */
.area_navi {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.area_navi ul {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

/* 분류 전체보기 숨김 */
.area_navi .tt_category > li:first-child > a.link_tit {
  display: none;
}

/* 상위 카테고리 링크 */
.area_navi .tt_category > li > a.link_tit,
.area_navi .category_list > li > a.link_item {
  display: flex;
  align-items: center;
  padding: 5px 8px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.2px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  transition: all var(--transition);
}

.area_navi .tt_category > li > a.link_tit:hover,
.area_navi .category_list > li > a.link_item:hover {
  background: var(--bg-hover);
  color: var(--accent-blue);
}

/* 글 개수 */
.area_navi .c_cnt {
  font-size: 10px;
  color: var(--text-muted);
  margin-left: 4px;
}

/* 하위 카테고리 목록 */
.area_navi .link_sub_item {
  margin: 1px 0 4px 8px;
  padding-left: 10px;
  border-left: 1px solid var(--border-subtle);
  display: flex;
  font-size: 11px;
  gap: 0;
}

/* 하위 카테고리 링크 */
.area_navi .link_sub_item li a {
  display: block;
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.2px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  transition: all var(--transition);
}

.area_navi .link_sub_item li a:hover {
  background: var(--bg-hover);
  color: var(--accent-blue);
}

/* 방명록 링크 */
.link_guestbook {
  display: block;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  transition: all var(--transition);
  border-top: 1px solid var(--border-color);
  margin-top: 6px;
  padding-top: 10px;
}

.link_guestbook:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

/* ===========================
   사이드바 위젯
   =========================== */
.box_aside {
  margin-bottom: 16px;
}

.tit_aside {
  display: block;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.list_board li {
  border-bottom: 1px solid var(--border-subtle);
}

.list_board a {
  display: block;
  padding: 5px 0;
  font-size: 12px;
  color: var(--text-secondary);
  transition: color var(--transition);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.list_board a:hover { color: var(--accent-blue); }

.list_tag {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.link_tag {
  display: inline-block;
  padding: 2px 8px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  font-size: 11px;
  color: var(--text-secondary);
  transition: all var(--transition);
}

.link_tag:hover {
  border-color: var(--accent-blue);
  color: var(--accent-blue);
}

.list_keep li {
  border-bottom: 1px solid var(--border-subtle);
}

.link_keep {
  display: block;
  padding: 5px 0;
  font-size: 12px;
  color: var(--text-secondary);
  transition: color var(--transition);
}

.link_keep:hover { color: var(--accent-blue); }

.box_visitor {
  display: flex;
  gap: 16px;
}

.list_visitor,
.list_total {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.list_visitor dt,
.list_total dt {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
}

.list_visitor dd,
.list_total dd {
  font-family: var(--font-mono);
  font-size: 17px;
  font-weight: 500;
  color: var(--accent-blue);
}

.link_more {
  display: inline-block;
  margin-top: 8px;
  font-size: 11px;
  color: var(--accent-blue);
  font-family: var(--font-mono);
}

.link_more:hover { color: var(--accent-purple); }

/* 티스토리 위젯 다크모드 오버라이드 */
.area_side table, .area_side td, .area_side th,
.area_side caption, .area_side [class*="calendar"],
.area_side [class*="widget"], .area_side form, .area_side fieldset {
  background: transparent !important;
  color: var(--text-primary) !important;
  border-color: var(--border-color) !important;
}

.area_side a { color: var(--text-secondary) !important; }
.area_side a:hover { color: var(--accent-blue) !important; }

/* 관리 메뉴 */
.list_control { display: none; }

/* 모바일 오버레이 */
.sidebar_overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 199;
}

.sidebar_overlay.is_open { display: block; }

/* ===========================
   메인 콘텐츠
   =========================== */
.cont_skin {
  flex: 1;
  min-width: 0;
  padding: 40px 0;
}

#cMain {
  width: 100%;
}

/* ===========================
   Article List
   =========================== */
.list_title {
  margin-bottom: 24px;
}

.tit_skin {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-primary);
}

.txt_title {
  color: var(--text-secondary);
  font-weight: 400;
  font-size: 16px;
}

.index_title {
  margin-bottom: 32px;
}

.index_title .tit_skin   { font-size: 28px; font-weight: 700; }
.index_title .txt_title  { font-size: 28px; font-weight: 700; color: var(--text-primary); }

.article_skin {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

/* ===========================
   섹션
   =========================== */
.section-recent {
  display: none;
}

.section-all {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.section-heading {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  margin-bottom: 16px;
  font-family: var(--font-mono);
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-color);
}

/* 전체글 리스트 스타일 */
.section-all .list_content {
  flex: unset;
  width: 100%;
  height: auto;
  flex-direction: row;
  align-items: flex-start;
  gap: 20px;
  padding: 20px 0;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border-color);
  border-radius: 0;
  overflow: visible;
  scroll-snap-align: unset;
  box-shadow: none;
}

.section-all .list_content:hover {
  border-color: transparent;
  border-bottom-color: var(--border-color);
  box-shadow: none;
}

.section-all .list_content:hover .tit_post { color: var(--accent-blue); }

.section-all .thumbnail_post {
  flex-shrink: 0;
  width: 120px;
  height: 90px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
}

.section-all .link_post { padding: 0; gap: 8px; }

.section-all .tit_post {
  font-size: 16px;
  overflow: visible;
  display: block;
  -webkit-line-clamp: unset;
  line-clamp: unset;
}

.section-all .txt_post {
  font-size: 14px;
  -webkit-line-clamp: 2;
  line-clamp: 2;
}

.section-all .detail_info {
  padding: 0;
  margin-top: 4px;
}

/* ===========================
   캐러셀
   =========================== */
.carousel-wrapper {
  position: relative;
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--transition), border-color var(--transition), opacity var(--transition);
}

.carousel-btn::before {
  content: '';
  display: block;
  width: 8px;
  height: 8px;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
}

.carousel-btn--prev { left: -18px; }
.carousel-btn--prev::before { transform: rotate(-135deg) translate(-2px,2px); }
.carousel-btn--next { right: -18px; }
.carousel-btn--next::before { transform: rotate(45deg) translate(-2px,2px); }

.carousel-btn:hover {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
  color: #fff;
}

.carousel-btn:disabled {
  opacity: 0.25;
  pointer-events: none;
}

.card-carousel {
  display: flex;
  flex-wrap: nowrap;
  gap: 16px;
  overflow-x: auto;
  overflow-y: visible;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding: 8px 0 12px;
}

.card-carousel::-webkit-scrollbar        { height: 4px; }
.card-carousel::-webkit-scrollbar-track  { background: var(--bg-tertiary); border-radius: 2px; }
.card-carousel::-webkit-scrollbar-thumb  { background: var(--border-color); border-radius: 2px; }

/* ===========================
   카드 (캐러셀용)
   =========================== */
.list_content {
  flex: 0 0 300px;
  width: 300px;
  height: 250px;
  display: flex;
  flex-direction: column;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  scroll-snap-align: start;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.list_content:hover {
  border-color: var(--accent-blue);
  box-shadow: 0 6px 20px rgba(0,0,0,0.45);
}

/* 썸네일 없는 카드 — 플레이스홀더 */
.card-carousel .list_content:not(:has(.thumbnail_post))::before {
  content: '';
  display: block;
  width: 100%;
  height: 110px;
  flex-shrink: 0;
  background: var(--bg-tertiary);
  background-image:
    repeating-linear-gradient(
      45deg,
      transparent,
      transparent 10px,
      rgba(88, 166, 255, 0.03) 10px,
      rgba(88, 166, 255, 0.03) 20px
    );
  border-bottom: 1px solid var(--border-color);
}

.thumbnail_post {
  display: block;
  width: 100%;
  height: 110px;
  flex-shrink: 0;
  overflow: hidden;
  background: var(--bg-tertiary);
  border-bottom: 1px solid var(--border-color);
}

.thumbnail_post img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.list_content:hover .thumbnail_post img {
  transform: scale(1.05);
}

.list_content .link_post {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px 6px;
  overflow: hidden;
}

.tit_post {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.4;
  transition: color var(--transition);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
}

.list_content:hover .tit_post { color: var(--accent-blue); }

.txt_post {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.5;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  line-clamp: 1;
  -webkit-box-orient: vertical;
}

.detail_info {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 14px 12px;
  flex-shrink: 0;
}

.link_cate {
  font-size: 12px;
  color: var(--accent-blue);
  font-weight: 500;
  font-family: var(--font-mono);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100px;
}


.link_cate:hover { text-decoration: underline; }

.txt_bar {
  display: inline-block;
  width: 1px;
  height: 10px;
  background: var(--border-color);
}

.txt_date {
  font-size: 12px;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

/* ===========================
   Article View (퍼마링크)
   =========================== */
.area_title {
  margin-bottom: 40px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border-color);
}

.tit_category {
  display: inline-block;
  margin-bottom: 12px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
}

.tit_category a {
  color: var(--accent-blue);
  transition: color var(--transition);
}

.tit_category a:hover { color: var(--accent-purple); }

.area_title .tit_post {
  font-size: 32px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.5px;
  color: var(--text-primary);
  display: block;
  -webkit-line-clamp: unset;
  line-clamp: unset;
  -webkit-box-orient: horizontal;
  overflow: visible;
  margin-bottom: 16px;
}

.info_post {
  font-size: 13px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  display: flex;
  align-items: center;
  gap: 8px;
}

.area_view {
  font-size: 16px;
  line-height: 1.9;
  color: var(--text-primary);
  max-width: 720px;
}

.area_view h1,
.area_view h2,
.area_view h3,
.area_view h4 {
  font-weight: 700;
  line-height: 1.4;
  margin: 2em 0 0.8em;
  color: var(--text-primary);
}

.area_view h1 { font-size: 28px; }
.area_view h2 { font-size: 22px; border-bottom: 1px solid var(--border-color); padding-bottom: 8px; }
.area_view h3 { font-size: 18px; }
.area_view h4 { font-size: 16px; }

.area_view p { margin-bottom: 1.2em; }

.area_view a {
  color: var(--accent-blue);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.area_view a:hover { color: var(--accent-purple); }

.area_view ul,
.area_view ol {
  padding-left: 1.5em;
  margin-bottom: 1.2em;
}

.area_view ul { list-style: disc; }
.area_view ol { list-style: decimal; }
.area_view li { margin-bottom: 0.4em; }

#tt-body-page blockquote[data-ke-style='style1'] {
  text-align: left !important;
  font-size: 14px !important;
  width: 100% !important;
  margin: 1.8em 0 !important;
  color: var(--text-secondary) !important;
  padding: 12px 16px !important;
  border-left: 3px solid var(--accent-blue) !important;
  line-height: 1.8 !important;
  position: relative !important;
  background: rgba(88, 166, 255, 0.07) !important;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0 !important;
}

#tt-body-page blockquote[data-ke-style='style1'] span {
  color: var(--text-primary) !important;
  font-style: normal !important;
  font-weight: 600 !important;
  margin-top: 0 !important;
}

.area_view blockquote::after  { display: none; }
.area_view blockquote p       { margin-bottom: 0; font-size: 14px; }
.area_view blockquote strong,
.area_view blockquote b       { color: var(--text-primary); }
.area_view blockquote code    { font-style: normal; }

.area_view code {
  font-family: var(--font-mono);
  font-size: 0.875em;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 4px;
  padding: 2px 6px;
  color: var(--accent-purple);
}

.area_view pre {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 20px;
  overflow-x: auto;
  margin: 1.5em 0;
}

.area_view pre code {
  background: none;
  border: none;
  padding: 0;
  color: var(--text-primary);
  font-size: 14px;
}

.area_view img {
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  margin: 1em 0;
}

.area_view table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5em 0;
  font-size: 14px;
}

.area_view th,
.area_view td {
  padding: 10px 14px;
  border: 1px solid var(--border-color);
  text-align: left;
}

.area_view th {
  background: var(--bg-secondary);
  font-weight: 600;
  color: var(--text-primary);
}

.area_view td { color: var(--text-secondary); }

/* Tags */
.area_etc {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
}

.area_etc .list_tag {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.area_etc .list_tag dt {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
}

/* Related */
.area_related {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid var(--border-color);
}

.tit_related {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 20px;
}

.list_related {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px,1fr));
  gap: 16px;
}

.link_related {
  display: block;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: all var(--transition);
}

.link_related:hover {
  border-color: var(--accent-blue);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.thumb_related {
  display: block;
  width: 100%;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--bg-tertiary);
}

.img_related { width: 100%; height: 100%; object-fit: cover; }

.txt_related {
  display: block;
  padding: 12px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  line-height: 1.4;
}

.date_related {
  display: block;
  padding: 0 12px 12px;
  font-size: 11px;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.frame_related { display: none; }

.area_related .link_more {
  display: inline-block;
  margin-top: 16px;
  font-size: 13px;
  color: var(--accent-blue);
  font-family: var(--font-mono);
}

.area_related .link_more:hover { color: var(--accent-purple); }

/* ===========================
   Tistory 주입 요소 숨김
   =========================== */
.revenue_unit_wrap, .revenue_unit_wrap_n, .tt_ad_unit,
.blogInfo_wrap, .blog_info_wrap, .wrap_blog_info,
.inner_bloghead, .wrap_bloginfo, #profileImage,
.profile_post, .postblog,
[class*="blogInfo"], [class*="blog_info"] {
  display: none !important;
}

.area_view > div[style*="background"],
.area_view > div[style*="border"] {
  background: transparent !important;
  border: none !important;
  color: var(--text-primary) !important;
}

/* ===========================
   Comments
   =========================== */
.area_reply {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid var(--border-color);
}

.area_reply *,
#cmt_wrap, .wrap_comment, .list_comment, .cmt_info, .cmt_wrap {
  color: var(--text-primary);
  background: transparent;
  border-color: var(--border-color);
  font-family: var(--font-sans);
}

.area_reply .cmt_wrap, .area_reply .wrap_cmt,
.area_reply [class*="comment_item"], .area_reply [class*="cmt_item"] {
  padding: 16px 0;
  border-bottom: 1px solid var(--border-color);
}

.area_reply [class*="cmt_author"],
.area_reply [class*="comment_author"],
.area_reply .name_cmt {
  font-weight: 600;
  font-size: 14px;
  color: var(--text-primary);
}

.area_reply [class*="cmt_date"],
.area_reply [class*="comment_date"],
.area_reply .date_cmt {
  font-size: 12px;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.area_reply [class*="cmt_desc"],
.area_reply [class*="comment_body"],
.area_reply .desc_cmt {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-top: 6px;
}

.area_reply textarea,
.area_reply input[type="text"],
.area_reply input[type="password"],
.area_reply .tf_cmt {
  width: 100%;
  background: var(--bg-secondary) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  color: var(--text-primary) !important;
  -webkit-text-fill-color: var(--text-primary) !important;
  caret-color: var(--text-primary);
  color-scheme: dark;
  font-family: var(--font-sans);
  font-size: 14px;
  outline: none;
  resize: vertical;
  transition: border-color var(--transition);
}

.area_reply textarea:focus,
.area_reply input[type="text"]:focus,
.area_reply input[type="password"]:focus {
  border-color: var(--accent-blue) !important;
}

.area_reply textarea::placeholder,
.area_reply input::placeholder { color: var(--text-muted); }

.area_reply button[type="submit"],
.area_reply input[type="submit"],
.area_reply .btn_cmt {
  padding: 8px 20px;
  background: var(--accent-blue) !important;
  color: #fff !important;
  border: none !important;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity var(--transition);
}

.area_reply button[type="submit"]:hover,
.area_reply input[type="submit"]:hover { opacity: 0.85; }

.area_reply label {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 4px;
  display: block;
}

/* ===========================
   TOC
   =========================== */
.toc-container { display: none; }

@media (min-width: 1280px) {
  .toc-container {
    display: block;
    position: fixed;
    top: 50vh;
    transform: translateY(-50%);
    right: 24px;
    width: 200px;
    max-height: 70vh;
    overflow-y: auto;
    padding: 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 12px;
    z-index: 50;
  }

  .toc-container::-webkit-scrollbar       { width: 4px; }
  .toc-container::-webkit-scrollbar-track { background: transparent; }
  .toc-container::-webkit-scrollbar-thumb { background: var(--border-color); border-radius: 2px; }

  .toc-title {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-bottom: 10px;
    font-family: var(--font-mono);
  }

  .toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
  }

  .toc-item a {
    display: block;
    padding: 4px 8px;
    border-radius: 4px;
    color: var(--text-muted);
    line-height: 1.5;
    transition: all var(--transition);
    border-left: 2px solid transparent;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .toc-item a:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
  }

  .toc-item.is-active > a {
    color: var(--accent-blue);
    border-left-color: var(--accent-blue);
    background: var(--bg-hover);
  }

  .toc-item[data-level="2"] > a { padding-left: 16px; font-size: 11px; }
  .toc-item[data-level="3"] > a { padding-left: 26px; font-size: 11px; color: var(--text-muted); }
}

/* ===========================
   Password Protected
   =========================== */
.protected_form {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  padding: 32px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  max-width: 400px;
}

.protected_form p { color: var(--text-secondary); font-size: 14px; }

.protected_form input[type="password"] {
  width: 100%;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 14px;
  outline: none;
  transition: border-color var(--transition);
}

.protected_form input[type="password"]:focus { border-color: var(--accent-blue); }

.protected_form button[type="submit"] {
  padding: 10px 24px;
  background: var(--accent-blue);
  color: #fff;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 14px;
  transition: opacity var(--transition);
}

.protected_form button[type="submit"]:hover { opacity: 0.85; }

/* ===========================
   Pagination (현재 페이지 수정)
   =========================== */
.area_paging {
  margin-top: 40px;
  display: flex;
  justify-content: center;
}

.inner_paging {
  display: flex;
  align-items: center;
  gap: 4px;
}

.btn_prev, .btn_next, .link_page {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 8px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  color: var(--text-secondary);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  transition: all var(--transition);
  font-family: var(--font-mono);
}

.btn_prev:hover, .btn_next:hover, .link_page:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  border-color: var(--accent-blue);
}

/* ── 현재 페이지: a.link_page > span.selected ── */
.link_page .selected {
  display: none; /* span 텍스트 숨기고 부모 a에 스타일 줌 */
}

.link_page:has(.selected) {
  background: var(--accent-blue) !important;
  color: #fff !important;
  border-color: var(--accent-blue) !important;
  font-weight: 700;
  pointer-events: none;
}

/* :has() 미지원 브라우저 대비 — span.selected 텍스트 직접 노출 */
.link_page .selected {
  display: inline;
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 700;
}

.link_page:has(.selected) .selected { display: inline; }

/* ── Prev / Next → 화살표 ── */
.btn_prev,
.btn_next {
  font-size: 0; /* 텍스트 노드 숨김 */
  position: relative;
}

.btn_prev .ico_prev,
.btn_next .ico_next {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 12px;
  height: 12px;
  font-size: 0;
}

.btn_prev .ico_prev::before,
.btn_next .ico_next::before {
  content: '';
  display: block;
  width: 8px;
  height: 8px;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
}

.btn_prev .ico_prev::before {
  transform: rotate(-135deg) translate(-1px, 1px);
}

.btn_next .ico_next::before {
  transform: rotate(45deg) translate(-1px, 1px);
}

.btn_prev.no_more,
.btn_next.no_more {
  opacity: 0.3;
  pointer-events: none;
}

/* ===========================
   Footer
   =========================== */
.area_foot {
  border-top: 1px solid var(--border-color);
  padding: 24px;
  text-align: center;
}

.info_copyright {
  font-size: 12px;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.info_copyright .emph_t { color: var(--accent-blue); transition: color var(--transition); }
.info_copyright .emph_t:hover { color: var(--accent-purple); }

hr.hide { display: none; }

/* ===========================
   Cursor Trail Canvas
   =========================== */
#cursor-trail-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
}

/* ===========================
   Responsive — Tablet (≤ 1024px)
   =========================== */
@media (max-width: 1024px) {
  .layout-body {
    gap: 32px;
  }

  .area_side {
    width: 180px;
  }

  .list_related {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ===========================
   Responsive — Mobile (≤ 768px)
   사이드바: 오버레이 드로어로 전환
   =========================== */
@media (max-width: 768px) {
  /* 햄버거 버튼 노출 */
  .btn_cate {
    display: flex;
  }

  /* 레이아웃 1단 */
  .layout-body {
    flex-direction: column;
    padding: 0 16px;
    gap: 0;
  }

  /* 사이드바: fixed 드로어로 */
  .area_side {
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100vh;
    max-height: none;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border-color);
    z-index: 200;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    overflow-y: auto;
    padding: 24px;
  }

  .area_side.is_open {
    transform: translateX(0);
  }

  .cont_skin {
    padding: 24px 0;
  }

  .area_head {
    height: auto;
    min-height: 60px;
    flex-wrap: wrap;
    padding: 8px 16px;
    gap: 4px 12px;
  }

  .area_search {
    order: 10;
    flex-basis: 100%;
    max-width: 100%;
    padding: 0 0 8px;
  }

  .area_title .tit_post { font-size: 22px; }
  .area_view            { font-size: 15px; }

  .list_related         { grid-template-columns: 1fr; }
}