@charset "utf-8";
/* [2026-11] 첫 화면 팝업 (bbs/newwin.inc.php). 화면 가운데 창, 폭은 --pop-w(관리자 설정, PC) / 휴대폰은 화면 폭 - 32px
   main_header.css 가 p·div·span·a·button 에 line-height:1em·굵기 400 을 박으므로 클래스마다 직접 정한다. */
html.pop-lock, html.pop-lock body { overflow: hidden; }

.pop { position: fixed; inset: 0; z-index: 10050; display: flex; align-items: center; justify-content: center; padding: 64px 16px 16px; }
.pop *, .pop *::before, .pop *::after { box-sizing: border-box; }
.pop-dim { position: absolute; inset: 0; background: rgba(17, 24, 28, .62); animation: pop-fade .2s ease-out; }
.pop-box {
  position: relative; display: flex; flex-direction: column; width: min(var(--pop-w, 480px), 100%); max-height: calc(100vh - 80px); max-height: calc(100dvh - 80px);
  border-radius: 14px; background: #fff; box-shadow: 0 24px 60px rgba(0, 0, 0, .28); outline: none;
  animation: pop-in .24s cubic-bezier(.2, .8, .2, 1);
}

/* 닫기 X 는 창 바깥 오른쪽 위 (이미지 속 글자·로고를 가리지 않게) */
.pop-x {
  position: absolute; top: -52px; right: 0; z-index: 2; display: flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .16); color: #fff; cursor: pointer;
}
.pop-x:hover { background: rgba(255, 255, 255, .3); }

.pop-track { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; border-radius: 14px 14px 0 0; }
.pop-slide[hidden] { display: none; }
.pop-media a, .pop-media img { display: block; }
.pop-media img { width: 100%; height: auto; max-height: calc(100vh - 220px); max-height: calc(100dvh - 220px); object-fit: contain; background: #fff; }
.pop-text { padding: 16px 20px 0; font-size: 15px; line-height: 1.7; color: #333; word-break: keep-all; overflow-wrap: anywhere; }
.pop-text p, .pop-text span, .pop-text div { line-height: 1.7; }
.pop-text img { max-width: 100%; height: auto; }
.pop-cta {
  display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px; margin: 14px 16px 0; padding: 0 16px;
  border-radius: 8px; background: #007664; font-size: 15px; font-weight: 700; line-height: 1.3; color: #fff; text-decoration: none;
}
.pop-cta:hover { background: #005c4e; color: #fff; }
.pop-cta span { font-size: 18px; line-height: 1; color: inherit; }

.pop-nav { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 10px 16px 0; }
.pop-arrow {
  display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; padding: 0;
  border: 1px solid #d5dadd; border-radius: 50%; background: #fff; color: #333; cursor: pointer;
}
.pop-arrow:hover { border-color: #007664; color: #007664; }
.pop-count { min-width: 48px; margin: 0; font-size: 14px; line-height: 1.4; text-align: center; color: #6b7680; }
.pop-count b { font-weight: 700; color: #007664; }

.pop-foot { display: flex; flex: none; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 16px 14px; }
.pop-foot button {
  min-height: 44px; padding: 0 6px; border: 0; background: none; font-size: 14px; font-weight: 500; line-height: 1.3; color: #5b6670; cursor: pointer;
}
.pop-skip { text-decoration: underline; text-underline-offset: 3px; }
.pop-close { margin-left: auto; font-weight: 700 !important; color: #1f2a33 !important; }
.pop-foot button:hover { color: #007664; }
.pop a:focus-visible, .pop button:focus-visible { outline: 2px solid #007664; outline-offset: 2px; }
.pop-x:focus-visible { outline-color: #fff; box-shadow: 0 0 0 4px #007664; }

@keyframes pop-fade { from { opacity: 0; } }
@keyframes pop-in { from { opacity: 0; transform: translateY(12px) scale(.98); } }
@media (prefers-reduced-motion: reduce) { .pop-dim, .pop-box { animation: none; } }

@media (max-width: 480px) {
  .pop { padding: 60px 12px 12px; }
  .pop-box { max-height: calc(100vh - 72px); max-height: calc(100dvh - 72px); }
  .pop-media img { max-height: calc(100dvh - 210px); }
}
