/* Плавающая кнопка с логотипом → /avelaura/ (page_blocks/avelaura_button.php). Только flex, без grid. */
.mh-logo-btn{
	position:fixed;
	right:20px;
	bottom:calc(20px + var(--mh-logo-panel, 0px));
	z-index:995;
	display:flex;
	align-items:center;
	justify-content:center;
	width:56px;
	height:56px;
	border-radius:50%;
	background:#191713;
	color:#fff;
	box-shadow:0 6px 20px rgba(25,23,19,.28);
	text-decoration:none;
	transition:transform .2s ease, box-shadow .2s ease;
	-webkit-tap-highlight-color:transparent;
}
.mh-logo-btn:hover, .mh-logo-btn:focus{color:#fff;text-decoration:none;}
.mh-logo-btn:hover{transform:scale(1.06);box-shadow:0 8px 26px rgba(25,23,19,.34);}
.mh-logo-btn:focus-visible{outline:2px solid #b8703f;outline-offset:3px;}
.mh-logo-btn__icon{display:block;width:32px;height:32px;}

/* кнопка Aspro «наверх» (right:73px, 44px) упиралась в нашу — отодвигаем и ставим по центру с ней */
@media (min-width:768px){
	body a.scroll-to-top:not(.TOUCH){right:88px;bottom:26px;}
}

@media (max-width:767px){
	.mh-logo-btn{right:16px;bottom:calc(16px + var(--mh-logo-panel, 0px));width:48px;height:48px;}
	.mh-logo-btn__icon{width:28px;height:28px;}
}
@media (prefers-reduced-motion:reduce){
	.mh-logo-btn{transition:none;}
}
@media print{
	.mh-logo-btn{display:none;}
}

/* Окно во весь экран (режим 'modal'): перебиваем штатные max-width/max-height и margin:auto у dialog:modal */
.mh-logo-modal{
	width:100%;
	height:100vh;
	height:100dvh;
	max-width:none;
	max-height:none;
	margin:0;
	padding:0;
	border:0;
	border-radius:0;
	background:#f9f8f6;
	color:#322e29;
	overflow:auto;
}
.mh-logo-modal::backdrop{background:rgba(25,23,19,.45);}
.mh-logo-modal[open]{animation:mh-logo-modal-in .22s ease;}
.mh-logo-modal__box{display:flex;flex-direction:column;min-height:100%;padding-top:56px;}
/* фрейм тянется на всю высоту под крестиком; если приложение сообщит высоту больше — окно прокручивается */
.mh-logo-modal__body{display:flex;flex-direction:column;flex:1 0 auto;}
.mh-logo-modal__body iframe{display:block;flex:1 0 auto;}
.mh-logo-modal__close{
	position:fixed;
	top:8px;
	right:12px;
	z-index:1;
	display:flex;
	align-items:center;
	justify-content:center;
	width:40px;
	height:40px;
	padding:0;
	border:0;
	border-radius:50%;
	background:rgba(249,248,246,.9);
	color:#322e29;
	cursor:pointer;
}
.mh-logo-modal__close:hover{background:#e7e1d7;}
.mh-logo-modal__close:focus-visible{outline:2px solid #b8703f;outline-offset:2px;}
.mh-logo-modal__close svg{width:24px;height:24px;}

html.mh-logo-modal-lock{overflow:hidden;}

@keyframes mh-logo-modal-in{from{opacity:0;}to{opacity:1;}}
@media (prefers-reduced-motion:reduce){
	.mh-logo-modal[open]{animation:none;}
}
