/* =========================================================================
   당직자 상담연결 (include/yn_duty.inc.php · js/yn_duty.js)
   새 디자인·예전 디자인 페이지 어디서나 같게 보이도록 필요한 값과 초기화를 이 파일 안에 둡니다.
   ========================================================================= */
.yn-duty-layer, .yn-duty-call {
  --dt-ink: #14171c;
  --dt-ink-2: #3d434d;
  --dt-ink-3: #5f6672;
  --dt-surface: #f2f4f7;
  --dt-sky: #d9eefb;
  --dt-butter: #fff2b8;
  --dt-yellow: #ffd80a;
  --dt-green: #12a15e;
  --dt-ease: cubic-bezier(.16, 1, .3, 1);
}
.yn-duty-ico { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }

/* 살아 있는 상태 점 (초록 + 퍼지는 링) */
.yn-duty-live { position: absolute; top: -1px; right: -1px; width: 10px; height: 10px; border: 2px solid var(--dt-yellow); border-radius: 50%; background: var(--dt-green); }
.yn-duty-live::after { content: ""; position: absolute; inset: -2px; border-radius: 50%; background: var(--dt-green); animation: yn-duty-ping 1.8s ease-out infinite; }
@keyframes yn-duty-ping { from { transform: scale(1); opacity: .7; } to { transform: scale(2.4); opacity: 0; } }

/* ---------- 전화 안내 → 당직자 상담연결 버튼 (원래 자리의 글자색·크기는 그대로 따름) ---------- */
a.yn-duty-call { display: inline-flex !important; flex-direction: row !important; align-items: center !important; gap: 10px; max-width: 100%; text-align: left; text-decoration: none !important; cursor: pointer; white-space: normal; word-break: keep-all; }
a.yn-duty-call--compact { white-space: nowrap; }
a.yn-duty-call:hover .yn-duty-call__txt b { text-decoration: underline; text-underline-offset: 3px; }
a.yn-duty-call .yn-duty-call__ico { position: relative; display: inline-flex; align-items: center; justify-content: center; flex: none; width: 40px; height: 40px; margin: 0; border-radius: 50%; background: var(--dt-yellow); color: var(--dt-ink); font-size: 0; }
a.yn-duty-call .yn-duty-call__ico .yn-duty-ico { width: 22px; height: 22px; }
a.yn-duty-call .yn-duty-call__txt { display: flex; flex-direction: column; margin: 0; font-size: inherit; line-height: 1.25; color: inherit; font-weight: inherit; }
a.yn-duty-call .yn-duty-call__txt small { display: block; margin: 0 0 2px; font-size: 12px; font-weight: 600; letter-spacing: -0.02em; color: inherit; opacity: .8; }
a.yn-duty-call .yn-duty-call__txt b { font-weight: 800; color: inherit; }
/* 문장 속 번호·'전화 상담' 버튼: 작게 */
a.yn-duty-call--compact { gap: 6px; vertical-align: middle; }
a.yn-duty-call--compact .yn-duty-call__ico { width: 22px; height: 22px; }
a.yn-duty-call--compact .yn-duty-call__ico .yn-duty-ico { width: 14px; height: 14px; stroke-width: 2; }
a.yn-duty-call--compact .yn-duty-live { top: -3px; right: -3px; width: 8px; height: 8px; border-width: 1.5px; }

/* ---------- 당직자 상담연결 레이어 ---------- */
html.yn-duty-lock, html.yn-duty-lock body { overflow: hidden !important; }
.yn-duty-layer {
  position: fixed; inset: 0; z-index: 1200; /* 상단 헤더(900)·모바일 메뉴(1100) 위 */
  display: flex; align-items: center; justify-content: center; padding: 16px;
  background: rgba(20, 23, 28, .6);
  font-family: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", sans-serif;
  font-size: 16px; line-height: 1.5; letter-spacing: -0.01em; color: var(--dt-ink); text-align: left; word-break: keep-all;
  -webkit-font-smoothing: antialiased;
}
.yn-duty-layer[hidden] { display: none !important; }
.yn-duty-layer *, .yn-duty-layer *::before, .yn-duty-layer *::after { box-sizing: border-box; font-family: inherit; }
.yn-duty-layer h2, .yn-duty-layer p, .yn-duty-layer ul, .yn-duty-layer li { margin: 0; padding: 0; list-style: none; background: none; border: 0; float: none; }
.yn-duty-layer a { text-decoration: none; }
.yn-duty-layer .yn-sr { position: absolute !important; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.yn-duty-layer__panel { display: flex; flex-direction: column; width: 100%; max-width: 640px; max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); border-radius: 24px; background: #fff; box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .45); overflow: hidden; animation: yn-duty-rise .4s var(--dt-ease); }
@keyframes yn-duty-rise { from { opacity: 0; transform: translateY(6px); } }
.yn-duty-layer__head { flex: none; display: flex; align-items: center; gap: 14px; padding: 22px 24px; background: var(--dt-ink); color: #fff; }
.yn-duty-layer__badge { position: relative; display: flex; align-items: center; justify-content: center; flex: none; width: 48px; height: 48px; border-radius: 50%; background: var(--dt-yellow); color: var(--dt-ink); }
.yn-duty-layer__badge .yn-duty-ico { width: 26px; height: 26px; }
.yn-duty-layer__badge .yn-duty-live { top: 1px; right: 1px; width: 12px; height: 12px; }
.yn-duty-layer__titles { flex: 1; min-width: 0; }
.yn-duty-layer .yn-duty-layer__eyebrow { font-size: 13px; font-weight: 700; color: var(--dt-yellow); }
.yn-duty-layer .yn-duty-layer__head h2 { margin-top: 2px; font-size: 22px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.3; color: #fff; }
.yn-duty-layer__close { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; padding: 0; border: 0; border-radius: 12px; background: rgba(255, 255, 255, .14); color: #fff; cursor: pointer; }
.yn-duty-layer__close:hover { background: rgba(255, 255, 255, .26); }
.yn-duty-layer__close:focus-visible { outline: 3px solid var(--dt-yellow); outline-offset: 3px; }
.yn-duty-layer__body { overflow-y: auto; padding: 20px 24px 24px; overscroll-behavior: contain; }
.yn-duty-layer .yn-duty-layer__time { padding: 12px 16px; border-radius: 14px; background: var(--dt-butter); font-size: 14px; line-height: 1.6; color: var(--dt-ink-2); }
.yn-duty-layer__time b { color: var(--dt-ink); }
.yn-duty-layer .yn-duty-layer__hint { margin-top: 18px; font-size: 13px; font-weight: 700; color: var(--dt-ink-3); }
.yn-duty-layer .yn-duty-layer__faq { display: grid; gap: 8px; margin-top: 8px; }
.yn-duty-layer__faq a { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border-radius: 14px; background: var(--dt-surface); font-size: 15px; font-weight: 700; color: var(--dt-ink); transition: background-color .15s; }
.yn-duty-layer__faq a:hover { background: var(--dt-sky); color: var(--dt-ink); }
.yn-duty-layer__faq .yn-duty-ico { width: 18px; height: 18px; color: var(--dt-ink-3); }
.yn-duty-layer__frame { display: block; width: 100%; height: 640px; margin-top: 18px; border: 0; background: transparent; }

@media (max-width: 760px) {
  .yn-duty-layer { padding: 0; align-items: flex-end; }
  .yn-duty-layer__panel { max-height: 92vh; max-height: 92dvh; border-radius: 24px 24px 0 0; }
  .yn-duty-layer__head { padding: 18px 20px; }
  .yn-duty-layer .yn-duty-layer__head h2 { font-size: 20px; }
  .yn-duty-layer__body { padding: 16px 20px 24px; }
}
@media (prefers-reduced-motion: reduce) {
  .yn-duty-live::after { animation: none; }
  .yn-duty-layer__panel { animation: none; }
}
