/*
 * 손으로 쓴 공통 규칙 — 생성 CSS(header·footer·popup·pages)가 담지 못한 상태값.
 * 옛 화면에서 Elementor JS·위젯 CSS 가 하던 일(메뉴 화살표·「지금 페이지」·하위 메뉴 열림, 펼침 메뉴 열림, 팝업 열고 닫기)을 같은 값으로.
 * 값은 옛 헤더 CSS(post-23)·Elementor Pro widget-nav-menu.css 그대로. 헤더 HTML 위젯 코드(옛것 그대로, body 안)가 스크롤 뒤 글자색·
 * 펼침 메뉴 색을 !important 로 바꾸는 것은 그 코드가 한다.
 */

/*
 * 헤더 고정 — 옛 Elementor 「고정: 위」(데스크톱·태블릿·폰). 옛 화면은 헤더 컨테이너(hd-1a114d9, z-index 999)를 fixed 로 띄우고
 * 같은 크기의 빈 칸을 남겼다 — 헤더 전체를 sticky 로 붙여 같은 자리·같은 쌓임으로 둔다.
 * 헤더 아래의 빈 코드 칸(hd-5885fcb, 데스크톱 20px — 병원 HTML 위젯의 style·script 만 있다)은 같이 붙어 다니므로 누름을 아래로 넘긴다.
 */
.lam-hd {
	position: sticky;
	top: 0;
	z-index: 999;
}

.lam-hd .hd-5885fcb {
	pointer-events: none;
}

/* 하위 메뉴 화살표 — 옛 SmartMenus 가 링크 끝에 붙이던 것(.elementor-nav-menu .sub-arrow, chevron-down 0.7em). */
.lam-hd .hd-4452871 .sub-arrow {
	align-items: center;
	display: flex;
	line-height: 1;
	margin-block-end: -10px;
	margin-block-start: -10px;
	padding: 10px;
	padding-inline-end: 0;
}

.lam-hd .hd-4452871 .sub-arrow .e-font-icon-svg {
	height: 0.7em;
	width: 0.7em;
}

/* 가로 메뉴: 지금 페이지·하위 메뉴 열림이면 밑줄(옛 e--pointer-underline · e--animation-fade). 마우스 올림·포커스는 생성 CSS 에 있다. */
.lam-hd .hd-4452871__horizontal .elementor-nav-menu .elementor-item:is(.elementor-item-active, .highlighted)::after {
	opacity: 1;
}

/* 하위 메뉴·펼침 메뉴 링크: 마우스 올림·지금 페이지·열림(옛 post-23 — 바탕 #2D9DC7, 글자 #FFFFFFCC, 지금 페이지 #FFFFFF) */
.lam-hd .hd-4452871 .elementor-nav-menu--dropdown a:is(:hover, :focus, .elementor-item-active, .highlighted) {
	background-color: #2d9dc7;
	color: #ffffffcc;
}

.lam-hd .hd-4452871 .elementor-nav-menu--dropdown a.elementor-item-active {
	color: #ffffff;
}

/* 펼침 메뉴(1024px 이하) 열림 — 옛 .elementor-nav-menu--toggle .elementor-menu-toggle.elementor-active + .elementor-nav-menu__container */
.lam-hd .hd-4452871__toggle.elementor-active + .hd-4452871__container {
	animation: lam-hide-scroll 0.3s backwards;
	max-height: var(--menu-height, 100vh);
	overflow-x: hidden;
	overflow-y: auto;
	transform: scaleY(1);
}

@keyframes lam-hide-scroll {
	0%,
	to {
		overflow: hidden;
	}
}

/* 펼침 메뉴 버튼 마우스 올림·포커스(옛 post-23 div.elementor-menu-toggle:hover·:focus — 흰색). 스크롤 뒤·열림 색은 병원 코드가 !important 로. */
.lam-hd .hd-4452871 .hd-4452871__toggle:is(:hover, :focus) {
	color: #ffffff;
}

.lam-hd .hd-4452871 .hd-4452871__toggle:is(:hover, :focus) svg {
	fill: #ffffff;
}

.lam-hd .hd-4452871__toggle.elementor-active .hd-4452871__open {
	display: none;
}

.lam-hd .hd-4452871__toggle.elementor-active .hd-4452871__close {
	display: inline;
}

/* 전체 메뉴 팝업 — 닫힌 동안 숨김(열면 site.js 가 hidden 을 뗀다). */
.lam-pp[hidden] {
	display: none !important;
}

/*
 * 등장 효과(옛 Elementor entrance animation — .elementor-invisible 로 감췄다가 화면에 들어오면 .animated + 효과 이름).
 * 동작은 carousel.js(data-lam-anim · data-lam-delay). 기본 1.25초, 「느리게」(animated-slow) 2초.
 * 효과 모양은 옛 elementor/assets/lib/animations/styles/*.css 그대로. 슬라이드 글 등장(contentAnim)도 같은 효과를 쓴다.
 */
[data-lam-anim]:not(.lam-animated) {
	visibility: hidden;
}

.lam-animated {
	animation-duration: 1.25s;
}

.lam-animated.animated-slow {
	animation-duration: 2s;
}

.lam-fadeIn {
	animation-name: lam-fadeIn;
}

.lam-fadeInUp {
	animation-name: lam-fadeInUp;
}

.lam-fadeInDown {
	animation-name: lam-fadeInDown;
}

.lam-fadeInLeft {
	animation-name: lam-fadeInLeft;
}

.lam-fadeInRight {
	animation-name: lam-fadeInRight;
}

.lam-zoomIn {
	animation-name: lam-zoomIn;
}

@keyframes lam-fadeIn {
	from {
		opacity: 0;
	}

	to {
		opacity: 1;
	}
}

@keyframes lam-fadeInUp {
	from {
		opacity: 0;
		transform: translate3d(0, 100%, 0);
	}

	to {
		opacity: 1;
		transform: none;
	}
}

@keyframes lam-fadeInDown {
	from {
		opacity: 0;
		transform: translate3d(0, -100%, 0);
	}

	to {
		opacity: 1;
		transform: none;
	}
}

@keyframes lam-fadeInLeft {
	from {
		opacity: 0;
		transform: translate3d(-100%, 0, 0);
	}

	to {
		opacity: 1;
		transform: none;
	}
}

@keyframes lam-fadeInRight {
	from {
		opacity: 0;
		transform: translate3d(100%, 0, 0);
	}

	to {
		opacity: 1;
		transform: none;
	}
}

@keyframes lam-zoomIn {
	from {
		opacity: 0;
		transform: scale3d(0.3, 0.3, 0.3);
	}

	50% {
		opacity: 1;
	}
}

@media (prefers-reduced-motion: reduce) {
	.lam-animated {
		animation: none !important;
	}
}
