/* 패밀리 사이트 공통 '관리 화면 위쪽 메뉴바'(2026-10-12 사용자: 형제 관리 화면 머리줄 모양을 허브 기준으로 통일, 공지사항 7번 2).
   허브가 이 파일 하나로 관리하고, 각 사이트 관리 화면은 불러 쓰기만 한다. 모양을 바꾸려면 여기만 고친다.
     <link rel="stylesheet" href="https://arapshow.net/lib/admin-bar.css?v=1">

   기본 틀(메뉴 글자·개수만 사이트마다 다름):
     <header class="ab-top">
       <span class="ab-name"><b>똥킹</b> 관리</span>
       <nav class="ab-menu" aria-label="관리 메뉴">
         <a href="/admin" aria-current="page">HOME</a>             ← 지금 메뉴: aria-current="page"|"true" 또는 class="is-active"
         <a href="/admin-settings">설정 <span class="ab-n">3</span></a>   ← 숫자 동그라미(비면 안 보임)
         <span class="ab-sep"></span>                              ← 묶음 사이 얇은 세로선
         <span class="ab-sub"><a href="…">하위 메뉴</a></span>        ← 부모 바로 뒤 작은 글씨
       </nav>
       <span class="ab-end"><a href="https://arapshow.net/admin/?site=visits" target="_blank" rel="noopener">방문 통계 ↗</a><a href="/" target="_blank" rel="noopener">공개 화면 ↗</a></span>
     </header>
   첫 메뉴 HOME(지금 방문자에게 보이는 공개 첫 화면 미리보기)은 머리줄 바로 아래에:
     <div class="ab-home" style="--ab-top-h: 머리줄 높이px">
       <div class="ab-view"><span class="ab-what">지금 방문자에게 보이는 첫 화면</span><button type="button" class="ab-w" aria-pressed="true">PC</button><button type="button" class="ab-w" aria-pressed="false">폰</button><button type="button">새로고침</button></div>
       <div class="ab-stage"><iframe src="/" title="첫 화면 미리보기"></iframe></div>     ← 폰 폭은 class="ab-stage is-phone"
     </div>
   색은 허브 관리자와 같게 고정. 사이트 색은 숫자 동그라미에만(--ab-accent를 그 사이트 :root에 두면 됨). */
@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/variable/pretendardvariable-dynamic-subset.min.css');

.ab-top, .ab-home {
  --ab-paper: #f6f5f1; --ab-card: #fff; --ab-ink: #1b1b19; --ab-muted: #7d7b74; --ab-line: #e3e0d8; --ab-stage: #e9e7e1;
}
@media (prefers-color-scheme: dark) {
  .ab-top, .ab-home { --ab-paper: #1d1d1b; --ab-card: #262624; --ab-ink: #ecebe6; --ab-muted: #a3a19a; --ab-line: #3a3935; --ab-stage: #141413; }
}

.ab-top {
  position: sticky; top: 0; z-index: 30; box-sizing: border-box;
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px 22px;
  width: auto; max-width: none; min-height: 52px; margin: 0; padding: 9px 22px; border-radius: 0; box-shadow: none;
  background: var(--ab-paper); color: var(--ab-ink); border-bottom: 1px solid var(--ab-line);
  font: 500 13px/1.4 'Pretendard Variable', Pretendard, -apple-system, 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  letter-spacing: 0; word-break: keep-all; -webkit-font-smoothing: antialiased; text-align: left;
}
.ab-top * { box-sizing: border-box; }
.ab-name { flex: none; white-space: nowrap; color: var(--ab-muted); font-size: 13px; font-weight: 500; }
.ab-name b { color: var(--ab-ink); font-size: 15px; font-weight: 800; letter-spacing: -.2px; margin-right: 3px; }

.ab-menu { display: flex; align-items: center; gap: 2px; min-width: 0; overflow-x: auto; scrollbar-width: none; margin: 0; padding: 0; }
.ab-menu::-webkit-scrollbar { display: none; }
.ab-sub { display: flex; flex: none; align-items: center; gap: 0; }
.ab-menu :is(a, button) {
  flex: none; display: inline-flex; align-items: center; gap: 4px;
  margin: 0; padding: 6px 12px; border: 0; border-radius: 99px; background: none; box-shadow: none;
  color: var(--ab-muted); font: inherit; font-size: 13px; font-weight: 700; line-height: 1.4;
  text-decoration: none; white-space: nowrap; cursor: pointer;
}
.ab-sub :is(a, button) { padding: 6px 9px; font-size: 12px; font-weight: 500; }
.ab-menu :is(a, button):hover { color: var(--ab-ink); background: none; }
.ab-menu :is(a, button):is([aria-current="page"], [aria-current="true"], .is-active) { background: var(--ab-ink); color: var(--ab-paper); box-shadow: none; }
.ab-menu :is(a, button):focus-visible { outline: 2px solid var(--ab-accent, #e8452c); outline-offset: 1px; }
.ab-sep { flex: none; width: 1px; height: 14px; margin: 0 6px; background: var(--ab-line); }
.ab-n:empty { display: none; }
.ab-n { min-width: 18px; padding: 1px 6px; border-radius: 99px; background: var(--ab-accent, #e8452c); color: #fff; font-size: 10px; font-weight: 700; line-height: 1.5; text-align: center; }

.ab-end { display: flex; align-items: center; gap: 16px; margin-left: auto; white-space: nowrap; }
.ab-end :is(a, button) { margin: 0; padding: 0; border: 0; background: none; color: var(--ab-muted); font: inherit; font-size: 12px; font-weight: 500; text-decoration: none; cursor: pointer; }
.ab-end :is(a, button):hover { color: var(--ab-ink); text-decoration: underline; background: none; }

/* 좁으면 메뉴가 둘째 줄로, 휴대폰은 메뉴 줄을 옆으로 밀어 봄(페이지 전체는 안 밀림) */
@media (max-width: 1100px) { .ab-menu { order: 3; flex-basis: 100%; margin: 0 -6px; } }
/* 메뉴가 많은 사이트(요주처럼 하위 메뉴까지)는 <header class="ab-top" data-ab-long>: 더 넓은 화면까지 메뉴를 둘째 줄에 */
@media (max-width: 1480px) { .ab-top[data-ab-long] .ab-menu { order: 3; flex-basis: 100%; margin: 0 -6px; } }
@media (max-width: 480px) {
  .ab-top { gap: 6px 12px; padding: 9px 12px 6px; }
  .ab-end { gap: 12px; }
  .ab-end :is(a, button) { font-size: 11px; }
  .ab-menu :is(a, button) { padding: 6px 10px; }
}

/* HOME: 지금 방문자에게 보이는 공개 첫 화면 미리보기(머리줄 아래를 꽉 채움) */
.ab-home { display: flex; flex-direction: column; height: calc(100dvh - var(--ab-top-h, 52px)); background: var(--ab-paper); }
.ab-view {
  flex: none; display: flex; align-items: center; gap: 8px; padding: 8px 22px;
  border-bottom: 1px solid var(--ab-line); color: var(--ab-muted);
  font: 500 12px/1.4 'Pretendard Variable', Pretendard, -apple-system, 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif; word-break: keep-all;
}
.ab-what { margin-right: auto; }
.ab-view button { margin: 0; padding: 3px 12px; border: 1px solid var(--ab-line); border-radius: 99px; background: none; color: var(--ab-muted); font: inherit; font-size: 12px; cursor: pointer; }
.ab-view button:hover { color: var(--ab-ink); }
.ab-view button[aria-pressed="true"] { background: var(--ab-ink); border-color: var(--ab-ink); color: var(--ab-paper); font-weight: 700; }
.ab-stage { flex: 1; min-height: 0; display: flex; justify-content: center; background: var(--ab-stage); }
.ab-stage iframe { display: block; width: 100%; height: 100%; border: 0; background: #fff; }
.ab-stage.is-phone { padding: 12px 0; }
.ab-stage.is-phone iframe { width: 390px; max-width: 100%; border-radius: 12px; box-shadow: 0 2px 12px #00000026; }
@media (max-width: 480px) { .ab-view { padding: 8px 12px; } .ab-view .ab-w { display: none; } }
