/* Perfectil Blank — сумісність блоків WordPress зі старою розміткою сайту */
.elementor figure.wp-block-image { margin: 0; }
.elementor figure.wp-block-image img { vertical-align: middle; }
.elementor .wp-block-image img { height: auto; }
.elementor :where(.wp-block-group) { box-sizing: border-box; }
.elementor .wp-block-heading, .elementor .wp-block-list { box-sizing: border-box; }

/* Закріплена шапка (як Elementor Pro «Sticky») */
.pfb-sticky.elementor-sticky--active { position: fixed !important; top: 0; z-index: 99; margin-top: 0 !important; }
body.admin-bar .pfb-sticky.elementor-sticky--active { top: 32px; }
@media (max-width: 782px) { body.admin-bar .pfb-sticky.elementor-sticky--active { top: 46px; } }

/* Спливаючі вікна */
.elementor-popup-modal { display: none; }
.elementor-popup-modal.pfb-open { display: flex !important; }

.pfb-404 { max-width: 1140px; margin: 80px auto; padding: 0 20px; text-align: center; }

/* Перегляд зображення */
.pfb-lightbox { position: fixed; inset: 0; z-index: 9999; background: rgba(0,0,0,.87); display: flex; align-items: center; justify-content: center; }
.pfb-lightbox .dialog-widget-content { width: 100%; height: 100%; position: relative; background: transparent !important; }
.pfb-lightbox .dialog-message { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }
.pfb-lightbox .elementor-lightbox-image { max-width: 90vw; max-height: 90vh; width: auto; height: auto; box-shadow: 0 0 30px rgba(0,0,0,.3); }
.pfb-lightbox .pfb-lb-close { position: absolute; top: 15px; right: 20px; font-size: 32px; line-height: 1; color: #eee; text-decoration: none; }

/* Діалог спливаючого вікна (раніше стилі додавав скрипт Elementor) */
.dialog-widget-content { background-color: #fff; border-radius: 3px; box-shadow: 2px 8px 23px 3px rgba(0,0,0,.2); overflow: hidden; position: absolute; }
.dialog-message { box-sizing: border-box; line-height: 1.5; }
.dialog-close-button { color: #191970; cursor: pointer; font-size: 15px; inset-inline-end: 15px; line-height: 1; margin-block-start: 15px; position: absolute; }
.dialog-type-lightbox { background-color: rgba(0,0,0,.8); bottom: 0; height: 100%; left: 0; position: fixed; -webkit-user-select: none; user-select: none; width: 100%; z-index: 9999; }
.elementor-popup-modal .dialog-close-button svg { width: 1em; height: 1em; fill: currentColor; }

