/* /resources/css/portal/popup.css */
/*
 * 대민 메인 공지 팝업(레이아웃 팝업) — 포털 디자인(portal-common) 색·모서리·그림자에 맞춘 FRPS 추가 파일
 * 조각: fragments/frps/popup.html · 동작: js/front/front-popup.js
 * 여러 개면 계단식으로 겹치지 않고 나란히 놓는다
 * 색은 portal-common.css 의 :root 변수(--link·--line·--surface·--muted·--text)를 쓴다
 */

/* 팝업 받침 — 헤더 아래 왼쪽부터 나란히 놓는다. 받침은 클릭을 통과시킨다(팝업이 떠 있어도 본문을 쓸 수 있게) */
.front-popup-layer{position:fixed;top:190px;left:40px;right:40px;z-index:1200;display:flex;flex-wrap:wrap;align-items:flex-start;gap:16px;pointer-events:none}

.front-popup{display:flex;flex-direction:column;width:400px;max-width:100%;max-height:calc(100vh - 220px);pointer-events:auto;background:#fff;border:1px solid var(--line);border-radius:12px;box-shadow:0 18px 40px #1427442e;overflow:hidden;color:var(--text);font-size:16px;line-height:1.6}

/* 머리 — 제목 · 닫기(X) */
.front-popup-head{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 12px 14px 20px;border-bottom:1px solid var(--line);background:#fff}
.front-popup-title{margin:0;font-size:19px;font-weight:700;letter-spacing:-.4px;line-height:1.4;color:var(--black_title)}
.front-popup-x{flex:none;display:inline-flex;align-items:center;justify-content:center;width:40px;height:40px;border:0;border-radius:var(--radius);background:none;color:var(--muted);font-size:24px;line-height:1;cursor:pointer}
.front-popup-x:hover{background:var(--surface);color:var(--text)}

/* 본문 — 관리자가 에디터로 넣은 내용(HTML)이 그대로 들어온다 */
.front-popup-body{flex:1 1 auto;min-height:0;padding:20px;overflow-y:auto;word-break:keep-all;overflow-wrap:anywhere}
.front-popup-body img{display:block;max-width:100%;height:auto;margin-inline:auto}
.front-popup-body p+p{margin-top:8px}
.front-popup-body a{color:var(--link);text-decoration:underline}

/* 바로가기 — 관리자에서 링크 주소를 넣은 팝업만 */
.front-popup-link{display:flex;align-items:center;justify-content:center;gap:6px;margin:0 20px 20px;min-height:48px;padding:10px 20px;border-radius:var(--radius);background:var(--link);color:#fff;font-weight:650;text-decoration:none}
.front-popup-link:hover{background:#005b8a}

/* 발 — 오늘 하루 보지 않기 · 닫기 */
.front-popup-foot{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px 10px 20px;border-top:1px solid var(--line);background:var(--surface);font-size:15px}
.front-popup-today{display:inline-flex;align-items:center;gap:8px;color:var(--muted);cursor:pointer}
.front-popup-today input{width:18px;height:18px;margin:0;accent-color:var(--link);cursor:pointer}
.front-popup-close{min-height:40px;padding:6px 14px;border:0;border-radius:var(--radius);background:none;color:var(--text);font-weight:650;cursor:pointer}
.front-popup-close:hover{background:#fff;color:var(--link)}

/* 모바일 — 화면 아래에 꽉 차게 한 장씩 겹친다. 나중 것이 위에 오고, 닫으면 아래 것이 보인다 */
@media(max-width:900px){
	.front-popup-layer{top:auto;bottom:16px;left:16px;right:16px;display:grid;align-items:end}
	.front-popup{grid-area:1/1;width:auto;max-height:70vh}
}
@media(max-width:480px){
	.front-popup-title{font-size:17px}
	.front-popup-body{padding:16px}
	.front-popup-link{margin:0 16px 16px}
	.front-popup-foot{padding-left:16px;font-size:14px}
}
