/* ==========================================================================
   ailo_p01 — 그누보드5 서브 페이지 보정 (css/style.css 다음에 로드)
   - html.ailo-is-index : 메인 / html.ailo-is-sub : 게시판·회원 등 서브 페이지
   - .ailo-page(서브 틀) · .ailo-g5(스킨 영역) 기본 모양은 ailo_common/css/ailo-g5.css
   - 고정 헤더 높이 여백은 ailo-g5.js 가 자동 계산. 직접 정하려면 .ailo-page { --ailo-sub-offset: 80px; }
   ========================================================================== */

/* [변환기 생성] 서브 페이지는 스크롤 전부터 헤더를 '스크롤된 상태' 모양으로 */
html.ailo-is-sub:not(.nav-open) .hd .util { background: var(--p01-soft); border-bottom-color: var(--ailo-line); color: #333; }
html.ailo-is-sub:not(.nav-open) .hd .logo__mark { color: var(--ailo-accent); }

/* [수작업 보정] 아래에 테마별 서브 페이지 보정 */

/* 서브 페이지(게시판·회원·내용관리)에는 히어로가 없으므로 투명 헤더(.ailo-hd--overlay)를 처음부터 단색으로
   — 값은 ailo-base.css 2절 '.is-scrolled' 상태와 같다 */
html.ailo-is-sub .ailo-hd--overlay[data-ailo-header] {
  background: var(--ailo-hd-solid-bg, var(--ailo-bg)); color: var(--ailo-hd-solid-fg, var(--ailo-fg));
  box-shadow: 0 1px 0 var(--ailo-line), 0 8px 24px rgba(0, 0, 0, .06);
}
html.ailo-is-sub .ailo-hd--overlay[data-ailo-header]::before { opacity: 0; }
html.ailo-is-sub .ailo-hd--overlay .ailo-hd__solid { display: revert; }
html.ailo-is-sub .ailo-hd--overlay .ailo-hd__top { display: none; }

/* [수작업 보정 — 이전 수작업 그대로 옮김] 접근성 도구(글자 크기·고대비)를 서브 페이지에도 */
/* 1) 글자 크기 5단계(data-fs)를 서브 페이지 본문에도 적용.
      그누보드 스킨(ailo_board·회원 basic)은 px 기준이라 rem 이 먹지 않으므로 본문 틀 전체를 zoom 으로 키운다.
      login.php 처럼 헤더 없는 단독 화면(body.ailo-win)도 같은 단계로. 기본(1) = 100% */
html[data-fs="0"] .ailo-page__in, html[data-fs="0"] body.ailo-win { zoom: .875; }
html[data-fs="2"] .ailo-page__in, html[data-fs="2"] body.ailo-win { zoom: 1.125; }
html[data-fs="3"] .ailo-page__in, html[data-fs="3"] body.ailo-win { zoom: 1.25; }
html[data-fs="4"] .ailo-page__in, html[data-fs="4"] body.ailo-win { zoom: 1.5; }

/* 2) 고대비(data-contrast="high")를 서브 페이지 본문에도 — 원본 고대비 팔레트(검정 바탕·흰 글자·노랑 강조).
      스킨마다 바탕·글자색을 직접 지정하므로 본문 영역 안에서는 색만 강제로 덮는다(배경 이미지·썸네일은 유지). */
html[data-contrast="high"] .ailo-g5,
html[data-contrast="high"] .ailo-g5 *,
html[data-contrast="high"] body.ailo-win,
html[data-contrast="high"] body.ailo-win * {
  background-color: #000 !important; color: #fff !important; border-color: #fff !important;
  box-shadow: none !important; text-shadow: none !important;
}
html[data-contrast="high"] .ailo-g5 { border: 2px solid #fff; }
html[data-contrast="high"] .ailo-g5 a, html[data-contrast="high"] .ailo-g5 a *,
html[data-contrast="high"] body.ailo-win a, html[data-contrast="high"] body.ailo-win a * { color: #ffd400 !important; }
html[data-contrast="high"] .ailo-g5 a:not([class]), html[data-contrast="high"] body.ailo-win a:not([class]) { text-decoration: underline; }
html[data-contrast="high"] .ailo-g5 :is(button, input[type="submit"], input[type="button"], .btn_submit, .btn_b02, .btn_b01, .btn),
html[data-contrast="high"] .ailo-g5 :is(button, input[type="submit"], input[type="button"], .btn_submit, .btn_b02, .btn_b01, .btn) *,
html[data-contrast="high"] body.ailo-win :is(button, input[type="submit"], .btn_submit),
html[data-contrast="high"] body.ailo-win :is(button, input[type="submit"], .btn_submit) * { background-color: #ffd400 !important; color: #000 !important; }
html[data-contrast="high"] .ailo-g5 :is(input, select, textarea),
html[data-contrast="high"] body.ailo-win :is(input, select, textarea) { border: 2px solid #fff !important; }
html[data-contrast="high"] .ailo-g5 ::placeholder, html[data-contrast="high"] body.ailo-win ::placeholder { color: #d0d0d0 !important; }
html[data-contrast="high"] .ailo-g5 img { filter: grayscale(1) contrast(1.15); }

/* 4) login.php 등 헤더 없는 단독 화면: 회원 스킨 고정 폭(360px)이 글자 확대(zoom) 때 좁은 화면을 넘지 않게 */
body.ailo-win .mbskin { max-width: 100%; box-sizing: border-box; }

/* 3) 회원 링크: 유틸 줄 '화면 보기 설정' 묶음 끝(1차 data-ailo-member 자리) — 원본 .util__link 와 같은 모양, 992px 미만은 모바일 메뉴 안 링크 */
.util__tools .ailo-mem { display: inline-flex; align-self: stretch; gap: 0; font-size: inherit; }
.util__tools .ailo-mem a { display: inline-flex; align-items: center; padding: 0 .625rem; font-weight: 600; color: inherit; opacity: 1; text-decoration: none; }
.util__tools .ailo-mem a:hover { text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 991.98px) { .util__tools .ailo-mem { display: none; } }
