미디어위키:Common.css: 두 판 사이의 차이

인테리어 위키
둘러보기로 이동 검색으로 이동
편집 요약 없음
태그: 수동 되돌리기
편집 요약 없음
태그: 수동 되돌리기
 
(같은 사용자의 중간 판 190개는 보이지 않습니다)
6번째 줄: 6번째 줄:
@import url('https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap');


/* 본문 */
/* ===============================
  기본 폰트
  =============================== */
.mw-parser-output {
.mw-parser-output {
   font-family: 'Inter', -apple-system, BlinkMacSystemFont,
   font-family: 'Inter', -apple-system, BlinkMacSystemFont,
17번째 줄: 19번째 줄:
.mw-parser-output h2,
.mw-parser-output h2,
.mw-parser-output h3,
.mw-parser-output h3,
.mw-parser-output h4 {
.mw-parser-output h4,
.mw-parser-output h5 {
   font-family: 'Inter', -apple-system, BlinkMacSystemFont,
   font-family: 'Inter', -apple-system, BlinkMacSystemFont,
               'Apple SD Gothic Neo', 'Noto Sans KR',
               'Apple SD Gothic Neo', 'Noto Sans KR',
               system-ui, sans-serif;
               system-ui, sans-serif;
}
}


/* ===============================
/* ===============================
   Heading 번호 매기기 (h2 ~ h4)
   Heading 번호 매기기 (h2 ~ h5)
   1.
   1.
   1.1
   1.1
   1.1.1
   1.1.1
  1.1.1.1
   =============================== */
   =============================== */


/* h2 기준 카운터 초기화 */
/* h2 기준 카운터 초기화 */
.mw-parser-output {
.mw-parser-output { counter-reset: h2; }
  counter-reset: h2;
}


/* ---------- h2 ---------- */
/* ---------- h2 ---------- */
43번째 줄: 43번째 줄:
   font-weight: 500;
   font-weight: 500;
}
}
.mw-parser-output h2 .mw-headline::before {
.mw-parser-output h2 .mw-headline::before {
   counter-increment: h2;
   counter-increment: h2;
55번째 줄: 54번째 줄:
.mw-parser-output h3 {
.mw-parser-output h3 {
   counter-reset: h4;
   counter-reset: h4;
   font-size: 24px;
   font-size: 22px;
   font-weight: 500;
   font-weight: 500;
}
}
.mw-parser-output h3 .mw-headline::before {
.mw-parser-output h3 .mw-headline::before {
   counter-increment: h3;
   counter-increment: h3;
   content: counter(h2) "." counter(h3) " ";
   content: counter(h2) "." counter(h3) " ";
   margin-right: 2px;
   margin-right: 2px;
   font-size: 24px;
   font-size: 22px;
   font-weight: 500;
   font-weight: 500;
 
}
}


/* ---------- h4 ---------- */
/* ---------- h4 ---------- */
.mw-parser-output h4 {
.mw-parser-output h4 {
   font-size: 24px;
  counter-reset: h5;
   font-size: 20px;
   font-weight: 500;
   font-weight: 500;
}
}
.mw-parser-output h4 .mw-headline::before {
.mw-parser-output h4 .mw-headline::before {
   counter-increment: h4;
   counter-increment: h4;
   content: counter(h2) "." counter(h3) "." counter(h4) " ";
   content: counter(h2) "." counter(h3) "." counter(h4) " ";
   margin-right: 2px;
   margin-right: 2px;
   font-size: 24px;
   font-size: 20px;
  font-weight: 500;
}
 
/* ---------- h5 ---------- */
.mw-parser-output h5 {
  font-size: 18px;
  font-weight: 500;
}
.mw-parser-output h5 .mw-headline::before {
  counter-increment: h5;
  content: counter(h2) "." counter(h3) "." counter(h4) "." counter(h5) " ";
  margin-right: 2px;
  font-size: 18px;
   font-weight: 500;
   font-weight: 500;
}
}


/* ===============================
/* ===============================
   Heading 하단 구분선 (h2 ~ h4 통일)
   Heading 하단 구분선 + 여백 (h2 ~ h5)
   =============================== */
   =============================== */
 
.mw-parser-output h1,
.mw-parser-output h2,
.mw-parser-output h2,
.mw-parser-output h3,
.mw-parser-output h3,
.mw-parser-output h4 {
.mw-parser-output h4,
.mw-parser-output h5 {
   border-bottom: 1px solid #ccc;
   border-bottom: 1px solid #ccc;
   padding-bottom: 6px;
   padding-bottom: 5px;
   margin-bottom: 16px;
   margin: 1.2em 0 0.8em;
 
  /* 접기 UX */
  cursor: pointer;
}
}


/* ===============================
/* ===============================
   Heading 제목 ↔ 편집 링크 양끝 정렬
   Heading 제목 ↔ 편집 링크 정렬
   (h2, h3 공통)
   - :has() 제거
  - 기본: flex-start
  - JS가 .mw-has-editsection 클래스를 붙이면 space-between
   =============================== */
   =============================== */
 
.mw-parser-output h1,
.mw-parser-output h2,
.mw-parser-output h2,
.mw-parser-output h3,
.mw-parser-output h3,
.mw-parser-output h4 {
.mw-parser-output h4,
.mw-parser-output h5 {
   display: flex;
   display: flex;
   align-items: center;
   align-items: center;
   justify-content: space-between;
   justify-content: flex-start; /* 기본 */
}
}


/* 제목 텍스트는 왼쪽 고정 */
/* 제목 텍스트 */
.mw-parser-output .mw-headline {
.mw-parser-output .mw-headline {
   flex: 1 1 auto;
   flex: 1 1 auto;
  min-width: 0; /* 긴 제목 줄바꿈 안정화 */
}
}


/* [편집 | 원본 편집]은 오른쪽 */
/* 편집 링크 */
.mw-parser-output .mw-editsection {
.mw-parser-output .mw-editsection {
   flex: 0 0 auto;
   flex: 0 0 auto;
   font-size: 12px;
   font-size: 12px;
   white-space: nowrap;
   white-space: nowrap;
  margin-left: 12px;
}
}


/* 편집 링크가 없을 때(편집 모드 등) 제목이 벌어지지 않게 */
/* 편집 링크가 있을 때만 양끝 정렬 (JS가 클래스 부여) */
.mw-parser-output h2:not(:has(.mw-editsection)),
.mw-parser-output h2.mw-has-editsection,
.mw-parser-output h3:not(:has(.mw-editsection)),
.mw-parser-output h3.mw-has-editsection,
.mw-parser-output h4:not(:has(.mw-editsection)) {
.mw-parser-output h4.mw-has-editsection,
   justify-content: flex-start;
.mw-parser-output h5.mw-has-editsection {
   justify-content: space-between;
}
}


/* ===============================
  [편집 | 원본편집] → [편집]
  =============================== */
/* '원본 편집' 링크 숨김 */
.mw-editsection a:last-of-type { display: none; }
/* 구분자(|) 숨김 */
.mw-editsection .mw-editsection-divider { display: none; }


/* ===============================
/* ===============================
   TOC(목차)에도 제목 번호 표시
   접기/펼치기 (h2~h5)
   Vector 2022(.vector-toc) + 구 TOC(#toc) 모두 지원
   - JS가 h2~h5에 아이콘(.mw-fold-icon)을 직계 자식으로 prepend
  - 접힌 상태: .mw-fold-collapsed
   =============================== */
   =============================== */


/* ---- Vector 2022 TOC ---- */
/* 접힌 상태에서 본문 숨김 */
.vector-toc {
.mw-parser-output .mw-fold-collapsed + .mw-fold-content {
   counter-reset: toc1;
   display: none;
}
}


.vector-toc .vector-toc-level-1 {
/* 기본: 아이콘 없으면 패딩 없음 */
   counter-reset: toc2;
.mw-parser-output h2,
.mw-parser-output h3,
.mw-parser-output h4,
.mw-parser-output h5 {
   position: relative;
  padding-left: 0;
}
}


.vector-toc .vector-toc-level-2 {
/* JS가 붙이는 클래스(.mw-has-fold-icon)로 아이콘 자리만 확보 */
   counter-reset: toc3;
.mw-parser-output h2.mw-has-fold-icon,
.mw-parser-output h3.mw-has-fold-icon,
.mw-parser-output h4.mw-has-fold-icon,
.mw-parser-output h5.mw-has-fold-icon {
   padding-left: 26px;
}
}


/* 1단계 */
/* 아이콘 */
.mw-parser-output .mw-fold-icon {
  position: absolute;
  left: 0;
  top: 50%;
  width: 20px;
  height: 20px;
 
  transform: translateY(-50%) rotate(90deg); /* 기본: 펼침 */
  transform-origin: 50% 50%;
  transition: transform 150ms ease;
 
  background: no-repeat center / contain
    url("https://interior.wiki/images/thumb/e/e3/Icon_caretright.png/600px-Icon_caretright.png?20260120083456");
}
 
/* 접힘 상태 → 오른쪽 */
.mw-parser-output .mw-fold-collapsed .mw-fold-icon {
  transform: translateY(-50%) rotate(0deg);
}
 
/* ===============================
  TOC(목차) 번호 표시
  - Vector 2022(.vector-toc)
  - 구형 TOC(#toc/.toc)
  - 중복 tocnumber 숨김
  =============================== */
 
/* 구형 TOC 기본 숫자 숨김(중복 방지) */
#toc .tocnumber,
.toc .tocnumber { display: none; }
 
/* Vector 2022 TOC: Top(처음 위치) 항목 숨김 */
.vector-toc a[href="#top"],
.vector-toc a[href="#mw-head"],
.vector-toc a[href^="#mw-head"],
.vector-toc a[rel="mw:PageProp/TOC"] {
  display: none !important;
}
 
/* Vector 2022: 카운터 초기화 */
.vector-toc { counter-reset: toc2; }
.vector-toc .vector-toc-level-1 { counter-reset: toc3; }
.vector-toc .vector-toc-level-2 { counter-reset: toc4; }
.vector-toc .vector-toc-level-3 { counter-reset: toc5; }
 
/* 레벨1(h2): 1. */
.vector-toc .vector-toc-level-1 > a .vector-toc-text::before {
.vector-toc .vector-toc-level-1 > a .vector-toc-text::before {
   counter-increment: toc1;
   counter-increment: toc2;
   content: counter(toc1) ". ";
   content: counter(toc2) ". ";
   margin-right: 2px;
   margin-right: 2px;
  font-weight: 600;
}
}


/* 2단계 */
/* 레벨2(h3): 1.1 */
.vector-toc .vector-toc-level-2 > a .vector-toc-text::before {
.vector-toc .vector-toc-level-2 > a .vector-toc-text::before {
   counter-increment: toc2;
   counter-increment: toc3;
   content: counter(toc1) "." counter(toc2) " ";
   content: counter(toc2) "." counter(toc3) " ";
   margin-right: 2px;
   margin-right: 2px;
  font-weight: 500;
}
}


/* 3단계(필요 시) */
/* 레벨3(h4): 1.1.1 */
.vector-toc .vector-toc-level-3 > a .vector-toc-text::before {
.vector-toc .vector-toc-level-3 > a .vector-toc-text::before {
   counter-increment: toc3;
   counter-increment: toc4;
   content: counter(toc1) "." counter(toc2) "." counter(toc3) " ";
   content: counter(toc2) "." counter(toc3) "." counter(toc4) " ";
  margin-right: 2px;
  font-weight: 400;
}
 
/* 레벨4(h5): 1.1.1.1 */
.vector-toc .vector-toc-level-4 > a .vector-toc-text::before {
  counter-increment: toc5;
  content: counter(toc2) "." counter(toc3) "." counter(toc4) "." counter(toc5) " ";
   margin-right: 2px;
   margin-right: 2px;
  font-weight: 400;
}
}


/* ---- 구형 TOC(#toc) ---- */
/* 최상위(=h2 레벨)에서 첫 항목(처음 위치)만 숨김 */
.vector-toc li.vector-toc-level-1:first-child {
  display: none !important;
}
 
/* ---- 구형 TOC(#toc/.toc) 번호 ---- */
#toc,
#toc,
.toc {
.toc { counter-reset: toc1; }
  counter-reset: toc1;
}


#toc .toclevel-1,
#toc .toclevel-1,
.toc .toclevel-1 {
.toc .toclevel-1 { counter-reset: toc2; }
  counter-reset: toc2;
}


#toc .toclevel-2,
#toc .toclevel-2,
.toc .toclevel-2 {
.toc .toclevel-2 { counter-reset: toc3; }
  counter-reset: toc3;
 
}
#toc .toclevel-3,
.toc .toclevel-3 { counter-reset: toc4; }


/* 1단계 */
/* 1단계 */
198번째 줄: 296번째 줄:
}
}


/* 3단계(필요 시) */
/* 3단계 */
#toc .toclevel-3 > a .toctext::before,
#toc .toclevel-3 > a .toctext::before,
.toc .toclevel-3 > a .toctext::before {
.toc .toclevel-3 > a .toctext::before {
206번째 줄: 304번째 줄:
}
}


/* =========================================================
/* 4단계(h5) */
  Vector 2022 사이드 TOC 번호 (h2~h4와 동일)
#toc .toclevel-4 > a .toctext::before,
  - 1 / 1.1 / 1.1.1 규칙
.toc .toclevel-4 > a .toctext::before {
  - '처음 위치(Top)' 항목 제외
  counter-increment: toc4;
  - 중복 숫자(기본 tocnumber) 숨김
  content: counter(toc1) "." counter(toc2) "." counter(toc3) "." counter(toc4) " ";
  ========================================================= */
  margin-right: 2px;
}


/* 0) 혹시 구형 TOC 숫자가 같이 보이면(중복 방지) */
/* TOC 토글 숨김(원본 유지) */
#toc .tocnumber,
span.toctogglespan { display: none; }
.toc .tocnumber {
 
   display: none;
/* ✅ Minerva에서는 TOC 토글(목차 열기 UI)이 필요할 수 있으니 복원 */
body.skin-minerva span.toctogglespan { display: inline !important; }
 
h2#mw-toc-heading { margin: 4px 0 8px; }
 
/* ===============================
  Sticky header 폰트 (Vector 2022)
  =============================== */
.vector-sticky-header-context-bar-primary,
.vector-sticky-header-context-bar-primary a,
.vector-sticky-header-context-bar-primary span {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont,
              'Apple SD Gothic Neo', 'Noto Sans KR',
              system-ui, sans-serif !important;
}
 
/* ===============================
  레거시 Vector: TOC(좌) + 인포박스(우)
  =============================== */
body.skin-vector:not(.skin-vector-2022) #toc.toc {
  float: left;
  margin: 0 16px 12px 0;
}
 
body.skin-vector:not(.skin-vector-2022) .iw-matbox,
body.skin-vector:not(.skin-vector-2022) table.wikitable[style*="float:right"] {
  width: 360px;
  margin-bottom: 12px;
}
 
body.skin-vector:not(.skin-vector-2022) .iw-topclear {
   clear: both;
  height: 8px;
}
}


/* 1) Vector 2022 TOC: Top(처음 위치) 항목은 숨김 (가장 안정적) */
/* ===============================
.vector-toc a[href="#top"],
  하단 분류 박스
.vector-toc a[href="#mw-head"],
  =============================== */
.vector-toc a[href^="#mw-head"],
div#catlinks.catlinks {
.vector-toc a[rel="mw:PageProp/TOC"] {
  margin-top: 80px;
   display: none !important;
  padding: 4px 8px;
  font-size: 14px;
  background: #fff;
   border-radius: 4px;
}
}


/* 2) 카운터 초기화: TOC 전체에서 1단계(h2) 번호를 카운트 */
/* 레거시 Vector: TOC 옆으로 본문 텍스트가 말려 올라오는 현상 방지 */
.vector-toc {
body.skin-vector:not(.skin-vector-2022) #toc.toc + h2,
   counter-reset: toc2;
body.skin-vector:not(.skin-vector-2022) .toc + h2 {
   clear: left;
}
}


/* 3) TOC 레벨별 카운터 리셋 */
/* TOC 제목 접기 아이콘 완전 제거 */
.vector-toc .vector-toc-level-1 { /* == (h2) */
#mw-toc-heading .mw-fold-icon {
   counter-reset: toc3;
   display: none !important;
}
}
.vector-toc .vector-toc-level-2 { /* === (h3) */
 
   counter-reset: toc4;
/* 아이콘 공간 때문에 생긴 왼쪽 여백 제거 */
#mw-toc-heading.mw-has-fold-icon,
#mw-toc-heading.mw-fold-has-content {
   padding-left: 0 !important;
  margin-left: 0 !important;
  text-indent: 0 !important;
}
}


/* 4) 레벨1: 1. (h2) */
/* 가상요소까지 제거 */
.vector-toc .vector-toc-level-1 > a .vector-toc-text::before {
#mw-toc-heading::before,
  counter-increment: toc2;
#mw-toc-heading::after {
   content: counter(toc2) ". ";
   content: none !important;
  margin-right: 2px;
  font-weight: 600;
}
}


/* 5) 레벨2: 1.1 (h3) */
/* 도움말 문서: 헤더 편집 링크 전체 숨김 */
.vector-toc .vector-toc-level-2 > a .vector-toc-text::before {
.ns-12 .mw-editsection {
   counter-increment: toc3;
   display: none;
  content: counter(toc2) "." counter(toc3) " ";
  margin-right: 2px;
  font-weight: 500;
}
}


/* 6) 레벨3: 1.1.1 (h4) */
/* 1) TOC(목차) 내부는 무조건 불릿 제거 */
.vector-toc .vector-toc-level-3 > a .vector-toc-text::before {
#toc ul, .toc ul {
   counter-increment: toc4;
   list-style: none !important;
   content: counter(toc2) "." counter(toc3) "." counter(toc4) " ";
   list-style-image: none !important;
  margin-right: 2px;
}
   font-weight: 400;
#toc li::marker, .toc li::marker {
   content: "" !important;
}
}


/* 최상위(=h2 레벨)에서 첫 항목(처음 위치)만 숨김 */
/* 2) 본문 ul 중에서 "TOC 안에 있는 ul"제외하고 적용 */
.vector-toc li.vector-toc-level-1:first-child {
#mw-content-text .mw-parser-output ul:not(#toc ul):not(.toc ul) {
   display: none !important;
  list-style-image: none !important;
  list-style-type: disc !important;
}
#mw-content-text .mw-parser-output ul:not(#toc ul):not(.toc ul) ul {
  list-style-type: circle !important;
}
#mw-content-text .mw-parser-output ul:not(#toc ul):not(.toc ul) ul ul {
   list-style-type: square !important;
}
}


/* ===============================
/* 대문에서만 내부 링크 색상 */
  [편집 | 원본편집] → [편집]
body.page-대문 .mw-parser-output a:not(.new) {
  =============================== */
  color: #202122;
}


/* '원본 편집' 링크 숨김 */
body.page-대문 .mw-parser-output a:not(.new):visited {
.mw-editsection a:last-of-type {
   color: #202122;
   display: none;
}
}


/* 구분자(|) 숨김 */
body.page-대문 .mw-parser-output a:not(.new):hover {
.mw-editsection .mw-editsection-divider {
   color: #202122;
   display: none;
  text-decoration: underline;
}
}


/* 스크롤 시 나타나는 Sticky header의 제목(문서명) 폰트를 Inter로 고정 */
/* 빨간 링크 */
.vector-sticky-header-context-bar-primary,
body.page-대문 .mw-parser-output a.new {
.vector-sticky-header-context-bar-primary a,
   color: #d32f2f;
.vector-sticky-header-context-bar-primary span {
   font-family: 'Inter', -apple-system, BlinkMacSystemFont,
              'Apple SD Gothic Neo', 'Noto Sans KR',
              system-ui, sans-serif !important;
}
}


/* ===============================
/* ===============================
   레거시 Vector: TOC(좌) + 인포박스(우) 상단 레이아웃 정리
   로고수정
   =============================== */
   =============================== */


/* TOC를 왼쪽으로 고정 */
#p-logo .mw-wiki-logo {
body.skin-vector:not(.skin-vector-2022) #toc.toc {
   width: auto !important;
   float: left;
  height: auto !important;
}


   margin: 0 16px 12px 0/* 오른쪽 여백 + 아래 여백 */
#p-logo .mw-wiki-logo::after {
   content: "인테리어 위키";
   font-size: 20px;
  font-weight: 600;
  color: #1f2937;
  line-height: 1;
}
}


/* 인포박스 테이블이 오른쪽에 고정되도록(템플릿 inline float:right 유지 중이어도 OK) */
#p-logo {
body.skin-vector:not(.skin-vector-2022) .iw-matbox,
  padding-left: 16px;
body.skin-vector:not(.skin-vector-2022) table.wikitable[style*="float:right"] {
  padding-top: 16px;
   width: 360px;           /* 인포박스 폭 통일 */
   height: 48px;
   margin-bottom: 12px;     /* TOC와 아래 여백 통일 */
   align-items: center !important;
}
}


/* TOC/인포박스 아래에서 본문이 시작되도록 clear */
#p-logo a {
body.skin-vector:not(.skin-vector-2022) .iw-topclear {
  display: flex;
   clear: both;
   align-items: center;
   height: 8px;             /* 상단 영역과 본문 사이 간격(원하면 0~12px 조절) */
   text-decoration: none;
}
}
span.toctogglespan{display: none}
h2#mw-toc-heading{margin: 4px 0px 8px 0px}

2026년 1월 28일 (수) 07:47 기준 최신판

/* 이 CSS 설정은 모든 스킨에 적용됩니다 */

/* ===============================
   Google Fonts: Inter
   =============================== */
@import url('https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap');

/* ===============================
   기본 폰트
   =============================== */
.mw-parser-output {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont,
               'Apple SD Gothic Neo', 'Noto Sans KR',
               system-ui, sans-serif;
}

/* 문서 제목 + 섹션 제목 */
#firstHeading,
.mw-parser-output h2,
.mw-parser-output h3,
.mw-parser-output h4,
.mw-parser-output h5 {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont,
               'Apple SD Gothic Neo', 'Noto Sans KR',
               system-ui, sans-serif;
}

/* ===============================
   Heading 번호 매기기 (h2 ~ h5)
   1.
   1.1
   1.1.1
   1.1.1.1
   =============================== */

/* h2 기준 카운터 초기화 */
.mw-parser-output { counter-reset: h2; }

/* ---------- h2 ---------- */
.mw-parser-output h2 {
  counter-reset: h3;
  font-size: 27px;
  font-weight: 500;
}
.mw-parser-output h2 .mw-headline::before {
  counter-increment: h2;
  content: counter(h2) ". ";
  margin-right: 2px;
  font-size: 27px;
  font-weight: 500;
}

/* ---------- h3 ---------- */
.mw-parser-output h3 {
  counter-reset: h4;
  font-size: 22px;
  font-weight: 500;
}
.mw-parser-output h3 .mw-headline::before {
  counter-increment: h3;
  content: counter(h2) "." counter(h3) " ";
  margin-right: 2px;
  font-size: 22px;
  font-weight: 500;
}

/* ---------- h4 ---------- */
.mw-parser-output h4 {
  counter-reset: h5;
  font-size: 20px;
  font-weight: 500;
}
.mw-parser-output h4 .mw-headline::before {
  counter-increment: h4;
  content: counter(h2) "." counter(h3) "." counter(h4) " ";
  margin-right: 2px;
  font-size: 20px;
  font-weight: 500;
}

/* ---------- h5 ---------- */
.mw-parser-output h5 {
  font-size: 18px;
  font-weight: 500;
}
.mw-parser-output h5 .mw-headline::before {
  counter-increment: h5;
  content: counter(h2) "." counter(h3) "." counter(h4) "." counter(h5) " ";
  margin-right: 2px;
  font-size: 18px;
  font-weight: 500;
}

/* ===============================
   Heading 하단 구분선 + 여백 (h2 ~ h5)
   =============================== */
.mw-parser-output h1,
.mw-parser-output h2,
.mw-parser-output h3,
.mw-parser-output h4,
.mw-parser-output h5 {
  border-bottom: 1px solid #ccc;
  padding-bottom: 5px;
  margin: 1.2em 0 0.8em;

  /* 접기 UX */
  cursor: pointer;
}

/* ===============================
   Heading 제목 ↔ 편집 링크 정렬
   - :has() 제거
   - 기본: flex-start
   - JS가 .mw-has-editsection 클래스를 붙이면 space-between
   =============================== */
.mw-parser-output h1,
.mw-parser-output h2,
.mw-parser-output h3,
.mw-parser-output h4,
.mw-parser-output h5 {
  display: flex;
  align-items: center;
  justify-content: flex-start; /* 기본 */
}

/* 제목 텍스트 */
.mw-parser-output .mw-headline {
  flex: 1 1 auto;
  min-width: 0; /* 긴 제목 줄바꿈 안정화 */
}

/* 편집 링크 */
.mw-parser-output .mw-editsection {
  flex: 0 0 auto;
  font-size: 12px;
  white-space: nowrap;
  margin-left: 12px;
}

/* 편집 링크가 있을 때만 양끝 정렬 (JS가 클래스 부여) */
.mw-parser-output h2.mw-has-editsection,
.mw-parser-output h3.mw-has-editsection,
.mw-parser-output h4.mw-has-editsection,
.mw-parser-output h5.mw-has-editsection {
  justify-content: space-between;
}

/* ===============================
   [편집 | 원본편집] → [편집]
   =============================== */

/* '원본 편집' 링크 숨김 */
.mw-editsection a:last-of-type { display: none; }

/* 구분자(|) 숨김 */
.mw-editsection .mw-editsection-divider { display: none; }

/* ===============================
   접기/펼치기 (h2~h5)
   - JS가 h2~h5에 아이콘(.mw-fold-icon)을 직계 자식으로 prepend
   - 접힌 상태: .mw-fold-collapsed
   =============================== */

/* 접힌 상태에서 본문 숨김 */
.mw-parser-output .mw-fold-collapsed + .mw-fold-content {
  display: none;
}

/* 기본: 아이콘 없으면 패딩 없음 */
.mw-parser-output h2,
.mw-parser-output h3,
.mw-parser-output h4,
.mw-parser-output h5 {
  position: relative;
  padding-left: 0;
}

/* JS가 붙이는 클래스(.mw-has-fold-icon)로 아이콘 자리만 확보 */
.mw-parser-output h2.mw-has-fold-icon,
.mw-parser-output h3.mw-has-fold-icon,
.mw-parser-output h4.mw-has-fold-icon,
.mw-parser-output h5.mw-has-fold-icon {
  padding-left: 26px;
}

/* 아이콘 */
.mw-parser-output .mw-fold-icon {
  position: absolute;
  left: 0;
  top: 50%;
  width: 20px;
  height: 20px;

  transform: translateY(-50%) rotate(90deg); /* 기본: 펼침 */
  transform-origin: 50% 50%;
  transition: transform 150ms ease;

  background: no-repeat center / contain
    url("https://interior.wiki/images/thumb/e/e3/Icon_caretright.png/600px-Icon_caretright.png?20260120083456");
}

/* 접힘 상태 → 오른쪽 */
.mw-parser-output .mw-fold-collapsed .mw-fold-icon {
  transform: translateY(-50%) rotate(0deg);
}

/* ===============================
   TOC(목차) 번호 표시
   - Vector 2022(.vector-toc)
   - 구형 TOC(#toc/.toc)
   - 중복 tocnumber 숨김
   =============================== */

/* 구형 TOC 기본 숫자 숨김(중복 방지) */
#toc .tocnumber,
.toc .tocnumber { display: none; }

/* Vector 2022 TOC: Top(처음 위치) 항목 숨김 */
.vector-toc a[href="#top"],
.vector-toc a[href="#mw-head"],
.vector-toc a[href^="#mw-head"],
.vector-toc a[rel="mw:PageProp/TOC"] {
  display: none !important;
}

/* Vector 2022: 카운터 초기화 */
.vector-toc { counter-reset: toc2; }
.vector-toc .vector-toc-level-1 { counter-reset: toc3; }
.vector-toc .vector-toc-level-2 { counter-reset: toc4; }
.vector-toc .vector-toc-level-3 { counter-reset: toc5; }

/* 레벨1(h2): 1. */
.vector-toc .vector-toc-level-1 > a .vector-toc-text::before {
  counter-increment: toc2;
  content: counter(toc2) ". ";
  margin-right: 2px;
  font-weight: 600;
}

/* 레벨2(h3): 1.1 */
.vector-toc .vector-toc-level-2 > a .vector-toc-text::before {
  counter-increment: toc3;
  content: counter(toc2) "." counter(toc3) " ";
  margin-right: 2px;
  font-weight: 500;
}

/* 레벨3(h4): 1.1.1 */
.vector-toc .vector-toc-level-3 > a .vector-toc-text::before {
  counter-increment: toc4;
  content: counter(toc2) "." counter(toc3) "." counter(toc4) " ";
  margin-right: 2px;
  font-weight: 400;
}

/* 레벨4(h5): 1.1.1.1 */
.vector-toc .vector-toc-level-4 > a .vector-toc-text::before {
  counter-increment: toc5;
  content: counter(toc2) "." counter(toc3) "." counter(toc4) "." counter(toc5) " ";
  margin-right: 2px;
  font-weight: 400;
}

/* 최상위(=h2 레벨)에서 첫 항목(처음 위치)만 숨김 */
.vector-toc li.vector-toc-level-1:first-child {
  display: none !important;
}

/* ---- 구형 TOC(#toc/.toc) 번호 ---- */
#toc,
.toc { counter-reset: toc1; }

#toc .toclevel-1,
.toc .toclevel-1 { counter-reset: toc2; }

#toc .toclevel-2,
.toc .toclevel-2 { counter-reset: toc3; }

#toc .toclevel-3,
.toc .toclevel-3 { counter-reset: toc4; }

/* 1단계 */
#toc .toclevel-1 > a .toctext::before,
.toc .toclevel-1 > a .toctext::before {
  counter-increment: toc1;
  content: counter(toc1) ". ";
  margin-right: 2px;
}

/* 2단계 */
#toc .toclevel-2 > a .toctext::before,
.toc .toclevel-2 > a .toctext::before {
  counter-increment: toc2;
  content: counter(toc1) "." counter(toc2) " ";
  margin-right: 2px;
}

/* 3단계 */
#toc .toclevel-3 > a .toctext::before,
.toc .toclevel-3 > a .toctext::before {
  counter-increment: toc3;
  content: counter(toc1) "." counter(toc2) "." counter(toc3) " ";
  margin-right: 2px;
}

/* 4단계(h5) */
#toc .toclevel-4 > a .toctext::before,
.toc .toclevel-4 > a .toctext::before {
  counter-increment: toc4;
  content: counter(toc1) "." counter(toc2) "." counter(toc3) "." counter(toc4) " ";
  margin-right: 2px;
}

/* TOC 토글 숨김(원본 유지) */
span.toctogglespan { display: none; }

/* ✅ Minerva에서는 TOC 토글(목차 열기 UI)이 필요할 수 있으니 복원 */
body.skin-minerva span.toctogglespan { display: inline !important; }

h2#mw-toc-heading { margin: 4px 0 8px; }

/* ===============================
   Sticky header 폰트 (Vector 2022)
   =============================== */
.vector-sticky-header-context-bar-primary,
.vector-sticky-header-context-bar-primary a,
.vector-sticky-header-context-bar-primary span {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont,
               'Apple SD Gothic Neo', 'Noto Sans KR',
               system-ui, sans-serif !important;
}

/* ===============================
   레거시 Vector: TOC(좌) + 인포박스(우)
   =============================== */
body.skin-vector:not(.skin-vector-2022) #toc.toc {
  float: left;
  margin: 0 16px 12px 0;
}

body.skin-vector:not(.skin-vector-2022) .iw-matbox,
body.skin-vector:not(.skin-vector-2022) table.wikitable[style*="float:right"] {
  width: 360px;
  margin-bottom: 12px;
}

body.skin-vector:not(.skin-vector-2022) .iw-topclear {
  clear: both;
  height: 8px;
}

/* ===============================
   하단 분류 박스
   =============================== */
div#catlinks.catlinks {
  margin-top: 80px;
  padding: 4px 8px;
  font-size: 14px;
  background: #fff;
  border-radius: 4px;
}

/* 레거시 Vector: TOC 옆으로 본문 텍스트가 말려 올라오는 현상 방지 */
body.skin-vector:not(.skin-vector-2022) #toc.toc + h2,
body.skin-vector:not(.skin-vector-2022) .toc + h2 {
  clear: left;
}

/* TOC 제목 접기 아이콘 완전 제거 */
#mw-toc-heading .mw-fold-icon {
  display: none !important;
}

/* 아이콘 공간 때문에 생긴 왼쪽 여백 제거 */
#mw-toc-heading.mw-has-fold-icon,
#mw-toc-heading.mw-fold-has-content {
  padding-left: 0 !important;
  margin-left: 0 !important;
  text-indent: 0 !important;
}

/* 가상요소까지 제거 */
#mw-toc-heading::before,
#mw-toc-heading::after {
  content: none !important;
}

/* 도움말 문서: 헤더 편집 링크 전체 숨김 */
.ns-12 .mw-editsection {
  display: none;
}

/* 1) TOC(목차) 내부는 무조건 불릿 제거 */
#toc ul, .toc ul {
  list-style: none !important;
  list-style-image: none !important;
}
#toc li::marker, .toc li::marker {
  content: "" !important;
}

/* 2) 본문 ul 중에서 "TOC 안에 있는 ul"만 제외하고 적용 */
#mw-content-text .mw-parser-output ul:not(#toc ul):not(.toc ul) {
  list-style-image: none !important;
  list-style-type: disc !important;
}
#mw-content-text .mw-parser-output ul:not(#toc ul):not(.toc ul) ul {
  list-style-type: circle !important;
}
#mw-content-text .mw-parser-output ul:not(#toc ul):not(.toc ul) ul ul {
  list-style-type: square !important;
}

/* 대문에서만 내부 링크 색상 */
body.page-대문 .mw-parser-output a:not(.new) {
  color: #202122;
}

body.page-대문 .mw-parser-output a:not(.new):visited {
  color: #202122;
}

body.page-대문 .mw-parser-output a:not(.new):hover {
  color: #202122;
  text-decoration: underline;
}

/* 빨간 링크 */
body.page-대문 .mw-parser-output a.new {
  color: #d32f2f;
}

/* ===============================
   로고수정
   =============================== */

#p-logo .mw-wiki-logo {
  width: auto !important;
  height: auto !important;
}

#p-logo .mw-wiki-logo::after {
  content: "인테리어 위키";
  font-size: 20px;
  font-weight: 600;
  color: #1f2937;
  line-height: 1;
}

#p-logo {
  padding-left: 16px;
  padding-top: 16px;
  height: 48px;
  align-items: center !important;
}

#p-logo a {
  display: flex;
  align-items: center;
  text-decoration: none;
}