/**
 * SeniorStay Front v2 — 플로팅 글래스 GNB, 드로어, 푸터, Sticky 바, 모달
 */

/* ── 스킵 링크 ── */
.skip-link {
	position: absolute; left: 12px; top: -60px; z-index: 300;
	padding: 12px 20px; background: var(--c-text); color: #fff;
	border-radius: 0 0 10px 10px; font-weight: 700; transition: top .2s;
}
.skip-link:focus { top: 0; color: #fff; }

/* 시연 안내는 공통 헤더 위에 작은 띠로 유지한다. */
:root { --demo-notice-h: 40px; }
body { padding-top: var(--demo-notice-h); }
main [id] { scroll-margin-top: calc(var(--demo-notice-h) + 112px); }
.demo-notice { position: fixed; inset: 0 0 auto; z-index: 95; min-height: var(--demo-notice-h); display: flex; align-items: center; justify-content: center; gap: 12px; padding: 8px 16px; background: var(--c-primary-deep); color: #fff; font-size: 1rem; line-height: 24px; }
.demo-notice strong { font-weight: 700; }
.admin-bar .demo-notice { top: 32px; }
@media (max-width: 600px) {
	:root { --demo-notice-h: 64px; }
	.demo-notice { flex-direction: column; gap: 0; }
	.admin-bar .demo-notice { top: 46px; }
}

/* ── GNB: 플로팅 글래스 필 ── */
.gnb {
	position: fixed; top: calc(var(--demo-notice-h) + 16px); left: 0; right: 0; z-index: 90;
	display: flex; justify-content: center; pointer-events: none;
	padding-inline: 16px;
}
.admin-bar .gnb { top: calc(var(--demo-notice-h) + 48px); }
@media (max-width: 600px) { .admin-bar .gnb { top: calc(var(--demo-notice-h) + 62px); } }
.gnb__in {
	pointer-events: auto;
	display: flex; align-items: center; gap: 18px;
	min-height: 68px; padding: 6px 8px 6px 26px;
	background: rgba(253,251,247,.78);
	backdrop-filter: blur(20px) saturate(1.4); -webkit-backdrop-filter: blur(20px) saturate(1.4);
	border: 1px solid rgba(28,25,23,.07);
	border-radius: 999px;
	box-shadow: inset 0 1px 0 rgba(255,255,255,.7), 0 12px 40px -12px rgba(28,25,23,.18);
	max-width: 100%;
}
.gnb__logo { font-size: 22px; font-weight: 800; color: var(--c-primary); text-decoration: none; letter-spacing: -0.04em; margin-right: 6px; }
.gnb__logo { flex-shrink: 0; }
.gnb__logo a, .footer__logo a { display: inline-flex; align-items: center; min-height: 54px; }
.brand-logo { display: block; width: 212px; height: auto; max-width: 100%; }
.gnb__logo .custom-logo { max-height: 48px; max-width: 212px; width: auto; }
.footer__logo .brand-logo { width: 248px; }
.footer__logo .custom-logo { max-height: 56px; max-width: 248px; width: auto; }
@media (max-width: 380px) { .gnb__logo .brand-logo, .gnb__logo .custom-logo { max-width: 172px; } }
.gnb__menu { display: flex; gap: 2px; list-style: none; margin: 0; padding: 0; }
.gnb__menu a {
	display: inline-flex; align-items: center;
	min-height: 52px; padding: 0 20px;
	border-radius: 999px; color: var(--c-text-2);
	font-weight: 600; font-size: var(--fs-small); text-decoration: none;
	transition: background-color .35s var(--ease-premium), color .35s var(--ease-premium);
}
.gnb__menu a:hover { background: rgba(27,67,50,.08); color: var(--c-primary); }
.gnb__menu .current-menu-item > a, .gnb__menu a[aria-current="page"] { color: var(--c-primary); background: var(--c-primary-soft); font-weight: 700; }
.gnb__cta { min-height: 52px; padding: 4px 6px 4px 22px; font-size: var(--fs-small); }
.gnb__cta .btn__icon { width: 40px; height: 40px; }

/* 햄버거 (모바일) */
.gnb__burger {
	display: none; flex-direction: column; justify-content: center; gap: 6px;
	width: 52px; height: 52px; padding: 0 13px; border: 0; background: none; cursor: pointer;
}
.gnb__burger span { display: block; height: 2.5px; border-radius: 2px; background: var(--c-text); transition: transform .3s var(--ease-premium), opacity .3s; }
.gnb__burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(8.5px) rotate(45deg); }
.gnb__burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.gnb__burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8.5px) rotate(-45deg); }

/* ── 모바일 드로어: 풀스크린 오버레이 ── */
.drawer { position: fixed; inset: 0; z-index: 120; display: none; }
.drawer.open { display: block; }
.drawer__dim { position: absolute; inset: 0; background: rgba(15,36,27,.45); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.drawer__panel {
	position: absolute; top: 0; right: 0; bottom: 0; width: min(88vw, 400px);
	background: var(--c-bg); padding: 20px 24px 32px;
	transform: translateX(105%); transition: transform .5s var(--ease-premium);
	display: flex; flex-direction: column;
	border-radius: 28px 0 0 28px;
}
.drawer.open .drawer__panel { transform: translateX(0); }
.drawer__close { align-self: flex-end; min-width: var(--touch-min); min-height: var(--touch-min); border: 0; background: none; font-size: 32px; cursor: pointer; color: var(--c-text); }
.drawer__menu { list-style: none; margin: 8px 0 24px; padding: 0; }
.drawer__menu li { opacity: 0; transform: translateY(14px); }
.drawer.open .drawer__menu li { opacity: 1; transform: none; transition: opacity .5s var(--ease-premium), transform .5s var(--ease-premium); transition-delay: calc(var(--i, 0) * 60ms + .1s); }
.drawer__menu li:nth-child(1){--i:1}.drawer__menu li:nth-child(2){--i:2}.drawer__menu li:nth-child(3){--i:3}.drawer__menu li:nth-child(4){--i:4}.drawer__menu li:nth-child(5){--i:5}
.drawer__menu a {
	display: flex; align-items: center; min-height: 62px; padding: 0 12px;
	font-size: var(--fs-body-lg); font-weight: 700; color: var(--c-text);
	text-decoration: none; border-bottom: 1px solid var(--c-border);
}
.drawer .btn { width: 100%; }
.drawer__tel { margin-top: 16px; text-align: center; color: var(--c-text-2); font-size: var(--fs-small); }

/* ── 푸터: 미니멀 에디토리얼 ── */
.footer { background: var(--c-primary-deep); color: #B9C8BF; padding: 48px 0 72px; font-size: var(--fs-small); }
.footer__brand { display: flex; justify-content: space-between; gap: 40px; flex-wrap: wrap; margin-bottom: 28px; }
.footer strong { color: #fff; display: block; margin-bottom: 12px; font-size: var(--fs-body); }
.footer a { color: #B9C8BF; text-decoration: none; transition: color .3s; }
.footer a:hover { color: #fff; }
.footer__logo { font-size: 26px; font-weight: 800; color: #fff; text-decoration: none; letter-spacing: -0.04em; }
.footer__tag { margin-top: 10px; max-width: 30em; line-height: 1.7; }
.footer__menu { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.footer__biz p { margin: 0 0 6px; line-height: 1.8; }
.footer__copy { margin-top: 40px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.12); font-size: 14px; color: #7C8F84; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

/* ── Sticky 카카오 상담 바 (모바일 전용) ── */
.sticky-kakao { display: none; }
@media (max-width: 767px) {
	.sticky-kakao {
		display: flex; position: fixed; left: 12px; right: 12px; bottom: calc(10px + env(safe-area-inset-bottom, 0px)); z-index: 80;
		min-height: var(--sticky-bar-h); border-radius: 999px;
		background: var(--c-kakao); box-shadow: 0 10px 30px -6px rgba(15,36,27,.35);
		align-items: center; justify-content: center; gap: 10px;
		text-decoration: none; color: var(--c-kakao-text);
		font-size: var(--fs-body); font-weight: 800;
		transition: transform .3s var(--ease-premium);
	}
	.sticky-kakao:active { transform: scale(.98); }
	.sticky-kakao svg { width: 24px; height: 24px; }
	body { padding-bottom: calc(var(--sticky-bar-h) + 24px); }
}

/* ── 데모 상담 안내 ── */
.demo-toast {
	position: fixed; z-index: 1000; left: 50%; transform: translateX(-50%);
	bottom: calc(var(--sticky-bar-h, 64px) + env(safe-area-inset-bottom) + 24px);
	width: max-content; max-width: calc(100vw - 40px); padding: 18px 24px;
	border-radius: 16px; background: #1B4332; color: #FFFFFF;
	font-size: 1.125rem; line-height: 1.7; text-align: center;
	box-shadow: var(--shadow-card); pointer-events: none;
}
.demo-toast[hidden] { display: none; }

/* ── 반응형 GNB ── */
@media (max-width: 860px) {
	.gnb__menu { display: none; }
	.gnb__cta { display: none; }
	.gnb__burger { display: flex; }
	.gnb__in { width: 100%; justify-content: space-between; padding-right: 8px; }
}
@media (prefers-reduced-motion: reduce) {
	.drawer__panel, .gnb__burger span, .sticky-kakao { transition: none; }
}

/* 생성한 시안 사진의 출처는 사진 가까이 읽기 쉬운 글자로 표시한다. */
.demo-photo-group { min-width: 0; }
.demo-image-caption { margin: 14px 0 0; padding: 12px 16px; border-radius: 12px; background: #E8F0EC; color: #1B4332; font-size: 1rem; line-height: 1.5; }
.demo-content-note { margin: 12px 0 0; max-width: 40em; font-size: 1rem; line-height: 1.7; color: var(--c-text-2); }
.section-head p.demo-content-note { margin-top: 12px; font-size: 1rem; }
.hero__media .demo-image-caption { margin-top: 24px; }

.product__body .demo-image-caption { margin: 0 0 16px; padding: 8px 12px; }
.d-hero__in .demo-image-caption { display: inline-block; max-width: 100%; color: #1B4332; font-size: 1rem; }
