/* Blagovist header (blagovist-header.php). Tokens follow the reader and «Сьогодні». */
/* the theme prints our header inside its #page-header: hide only the theme's own parts */
#page-header > *:not(.bvh), #main-nav, .mobile-menu-container, #top-bar { display: none !important; }
#page-header { position: static !important; margin: 0 !important; padding: 0 !important; background: none !important; border: 0 !important; min-height: 0 !important; }

.bvh {
	--h-red: #de3a33; --h-ink: #1e1e1e; --h-text: #2b2724; --h-muted: #6e6862; --h-line: #eeeae6; --h-tint: #fbf6f4; --h-bg: #fff;
	--h-sans: "Open Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	position: relative; z-index: 1000; background: var(--h-bg); border-bottom: 1px solid var(--h-line);
	font-family: var(--h-sans); text-align: left;
}
body.ashe-dark-mode .bvh {
	--h-red: #ef5a52; --h-ink: #ece8e3; --h-text: #d9d4ce; --h-muted: #a29b94; --h-line: #353331; --h-tint: #2b2a29; --h-bg: #222;
}
.bvh *, .bvh *::before, .bvh *::after { box-sizing: border-box; }
.bvh-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.bvh-in { display: flex; align-items: center; gap: 8px; max-width: 1240px; height: 64px; margin: 0 auto; padding: 0 20px; }
.bvh-logo { flex: none; display: block; line-height: 0; }
.bvh-logo img { display: block; height: 40px; width: auto; }
body.ashe-dark-mode .bvh-logo img { filter: none; }
.bvh button { font-family: var(--h-sans); letter-spacing: 0; text-transform: none; box-shadow: none; }
.bvh-ic {
	flex: none; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; margin: 0; padding: 0;
	border: 0; border-radius: 22px; background: transparent; color: var(--h-ink); cursor: pointer;
}
.bvh-ic:hover { background: var(--h-tint); color: var(--h-red); }
.bvh-ic svg { display: block; }
.bvh-tools { flex: none; display: flex; align-items: center; gap: 2px; margin-left: auto; }
.bvh-give {
	display: inline-flex; align-items: center; gap: 6px; height: 40px; margin-left: 8px; padding: 0 16px; border-radius: 20px;
	background: var(--h-red); color: #fff !important; font-size: 14px; font-weight: 700; text-decoration: none !important; white-space: nowrap;
}
.bvh-give:hover { filter: brightness(1.08); }
.bvh-give svg { width: 16px; height: 16px; }
body.ashe-dark-mode .bvh-give { background: #de3a33; }
.bvh-dark[aria-pressed="true"] { color: var(--h-red); }

/* ---------- desktop menu ---------- */
.bvh-nav { flex: 1 1 auto; min-width: 0; }
.bvh-nav-top, .bvh-nav-foot, .bvh-burger { display: none; }
.bvh .bvh-menu { display: flex; align-items: center; justify-content: center; gap: 2px; margin: 0; padding: 0; list-style: none; }
.bvh-it { position: relative; display: flex; align-items: center; margin: 0; padding: 0; }
.bvh .bvh-a {
	display: flex; align-items: center; height: 44px; padding: 0 10px; border-radius: 10px;
	color: var(--h-ink) !important; font-size: 15px; font-weight: 600; text-decoration: none !important; white-space: nowrap;
}
.bvh-it.has-sub > .bvh-a { padding-right: 2px; }
.bvh .bvh-x { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 44px; margin: 0; padding: 0; border: 0; background: transparent; color: var(--h-muted); cursor: pointer; border-radius: 8px; }
.bvh-x svg { width: 16px; height: 16px; transition: transform .18s ease; }
.bvh-it:hover > .bvh-a, .bvh-it.is-open > .bvh-a, .bvh-it:focus-within > .bvh-a { color: var(--h-red) !important; }
.bvh-it.is-cur > .bvh-a { color: var(--h-red) !important; box-shadow: inset 0 -2px 0 var(--h-red); border-radius: 0; }
.bvh-it.is-open > .bvh-x svg { transform: rotate(180deg); }

.bvh-sub {
	position: absolute; top: calc(100% + 6px); left: -8px; z-index: 5; display: none;
	min-width: 260px; padding: 10px; border: 1px solid var(--h-line); border-radius: 14px; background: var(--h-bg);
	box-shadow: 0 12px 36px rgba(0,0,0,.14);
}
.bvh-sub::before { content: ""; position: absolute; left: 0; right: 0; top: -10px; height: 10px; }   /* hover bridge */
.bvh-it.is-open > .bvh-sub { display: block; animation: bvh-in .16s ease-out both; }
@media (hover: hover) and (min-width: 1024px) { .bvh-it.has-sub:hover > .bvh-sub { display: block; } }
.bvh-sub-in { display: flex; gap: 8px; }
.bvh-col { min-width: 220px; }
.bvh-col + .bvh-col { padding-left: 8px; border-left: 1px solid var(--h-line); }
.bvh .bvh-sub ul { margin: 0; padding: 0; list-style: none; }
.bvh .bvh-sub li { margin: 0; padding: 0; }
.bvh .bvh-sa { display: block; padding: 9px 12px; border-radius: 8px; color: var(--h-text) !important; font-size: 15px; line-height: 1.3; text-decoration: none !important; }
.bvh .bvh-sa.is-cur { background: var(--h-tint); color: var(--h-red) !important; }
@media (hover: hover) { .bvh .bvh-sa:hover { background: var(--h-tint); color: var(--h-red) !important; } }
.bvh .bvh-col-h { margin: 4px 12px 4px; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--h-muted); }
.bvh .bvh-col-h a, .bvh .bvh-col-h span { color: inherit !important; text-decoration: none !important; }

/* ---------- search ---------- */
.bvh-search { border-top: 1px solid var(--h-line); background: var(--h-bg); }
.bvh-search[hidden] { display: none; }
.bvh-search form { display: flex; align-items: center; gap: 8px; max-width: 760px; margin: 0 auto; padding: 10px 20px; }
.bvh .bvh-search input {
	flex: 1 1 auto; min-width: 0; height: 46px; margin: 0; padding: 0 16px; border: 1px solid var(--h-line); border-radius: 23px;
	background: var(--h-bg); color: var(--h-ink); font: 17px/1 var(--h-sans); -webkit-appearance: none; appearance: none;
}
.bvh .bvh-search input:focus { outline: none; border-color: var(--h-red); box-shadow: 0 0 0 3px rgba(222, 58, 51,.15); }
.bvh .bvh-search button[type="submit"] { flex: none; height: 46px; margin: 0; padding: 0 20px; border: 0; border-radius: 23px; background: var(--h-red); color: #fff; font-size: 15px; font-weight: 700; cursor: pointer; }

@keyframes bvh-in { from { opacity: 0; transform: translate3d(0, -4px, 0); } to { opacity: 1; transform: none; } }

/* ---------- phones and narrow windows: 56 px row + full-height menu panel ---------- */
@media (max-width: 1023px) {
	.bvh-in { height: 56px; padding: 0 8px 0 14px; }
	.bvh-logo img { height: 34px; }
	.bvh-tools > .bvh-give, .bvh-dark--ic { display: none; }
	.bvh-burger { display: inline-flex; }
	.bvh-nav {
		position: fixed; top: 0; right: 0; bottom: 0; z-index: 1002; display: flex; flex-direction: column;
		width: min(420px, 100%); background: var(--h-bg); box-shadow: -8px 0 30px rgba(0,0,0,.2);
		transform: translate3d(100%, 0, 0); visibility: hidden; transition: transform .26s cubic-bezier(.2,.8,.2,1), visibility 0s linear .26s;
	}
	.bvh.is-menu .bvh-nav { transform: none; visibility: visible; transition: transform .26s cubic-bezier(.2,.8,.2,1); }
	.bvh-nav-top { display: flex; align-items: center; justify-content: space-between; flex: none; height: 56px; padding: 0 8px 0 20px; border-bottom: 1px solid var(--h-line); font-size: 17px; font-weight: 700; color: var(--h-ink); }
	.bvh .bvh-menu { flex: 1 1 auto; display: block; overflow: auto; padding: 8px 12px; -webkit-overflow-scrolling: touch; }
	.bvh-it { flex-wrap: wrap; border-bottom: 1px solid var(--h-line); }
	.bvh .bvh-a { flex: 1 1 auto; height: 56px; padding: 0 8px; font-size: 18px; }
	.bvh-it.is-cur > .bvh-a { box-shadow: none; }
	.bvh-it.is-open:not(.is-cur) > .bvh-a, .bvh-it:focus-within:not(.is-cur) > .bvh-a { color: var(--h-ink) !important; }
	.bvh .bvh-x { width: 52px; height: 52px; border-radius: 26px; }
	.bvh-x svg { width: 20px; height: 20px; }
	.bvh-sub { position: static; display: none; flex: 1 0 100%; min-width: 0; margin: 0 0 10px; padding: 4px 0 4px 8px; border: 0; border-radius: 0; box-shadow: none; }
	.bvh-sub::before { display: none; }
	.bvh-sub-in { display: block; }
	.bvh-col + .bvh-col { padding-left: 0; border-left: 0; margin-top: 6px; }
	.bvh .bvh-sa { padding: 12px 12px; font-size: 16px; }
	.bvh-nav-foot { display: flex; flex-direction: column; gap: 10px; flex: none; padding: 14px 20px calc(16px + env(safe-area-inset-bottom)); border-top: 1px solid var(--h-line); }
	.bvh-row { display: flex; align-items: center; gap: 10px; min-height: 48px; margin: 0; padding: 0 4px; border: 0; background: transparent; color: var(--h-ink); font-size: 16px; font-weight: 600; cursor: pointer; }
	.bvh-nav-foot .bvh-give { justify-content: center; height: 48px; margin: 0; border-radius: 24px; font-size: 16px; }
	.bvh-back { position: fixed; inset: 0; z-index: 1001; background: rgba(0,0,0,.36); }
	.bvh-back[hidden] { display: none; }
	html.bvh-lock, html.bvh-lock body { overflow: hidden; }
	.bvh-search form { padding: 8px 12px; }
}
@media (min-width: 1024px) and (max-width: 1180px) { .bvh .bvh-a { padding: 0 7px; font-size: 14px; } .bvh-give span { display: none; } .bvh-give { padding: 0 12px; } }
@media (prefers-reduced-motion: reduce) { .bvh-nav, .bvh.is-menu .bvh-nav, .bvh-x svg { transition: none; } .bvh-it.is-open > .bvh-sub { animation: none; } }

/* old mobile-header tweaks of the theme header are no longer needed */
.main-content { padding-top: 24px !important; }
@media (max-width: 767px) { .main-content { padding-top: 16px !important; } }

/* social pages: phone menu only */
.bvh-social { display: none; }
@media (max-width: 1023px) {
	.bvh-social { display: flex; justify-content: center; gap: 12px; padding-top: 4px; }
	.bvh-social a { display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; border-radius: 24px; background: var(--h-tint); color: var(--h-ink) !important; }
	.bvh-social a:active { background: var(--h-line); }
}
