/* Top Banner — site-wide scrolling announcement.
 * Track contains the message repeated N times. translateX(-50%) loops seamlessly
 * because the second half mirrors the first. */

.dw-top-banner {
	background-color: #0f1122;
	overflow: hidden;
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 1001;
	background: #0f1122;
	box-shadow: 0px 4px 25px 0px #ffffff1a;
}

.dw-top-banner__link {
	display: block;
	position: relative;
	color: inherit;
	text-decoration: none;
	padding: 12px 0;
}

.dw-top-banner a.dw-top-banner__link {
	cursor: pointer;
}

.dw-top-banner a.dw-top-banner__link:hover,
.dw-top-banner a.dw-top-banner__link:focus {
	color: inherit;
	text-decoration: none;
	outline: none;
}

.dw-top-banner a.dw-top-banner__link:focus-visible {
	outline: 2px solid #ffffff;
	outline-offset: -2px;
}

.dw-top-banner__track {
	display: inline-flex;
	flex-wrap: nowrap;
	white-space: nowrap;
	align-items: center;
	gap: 1rem;
	will-change: transform;
	animation: dw-top-banner-marquee 60s linear infinite;
	/* The track sits on its own compositor layer (translate3d) and overflows
	 * the link horizontally; let pointer events fall through to the <a>
	 * underneath so the whole banner is clickable. */
	pointer-events: none;
}

.dw-top-banner__item {
	padding-block: 12px;
	color: #ffffff;
	font-size: 16px;
	font-family: inherit;
}

.dw-top-banner__sep {
	opacity: 0.7;
	font-size: 0.85em;
	color: #ffffff;
	font-weight: lighter;
}

/* Push the sticky header and the right-rail sticky menu down by the banner's */
.has-top-banner header.sticky-header #navi,
.has-top-banner .desktop-stick-right-menu {
	top: 56px !important;
	opacity: 1;
	transition: all 0.3s ease;
}

/* Hide the sticky header as expected */
.has-top-banner header #navi {
	top: -1px !important;
	opacity: 0;
	transition: all 0.3s ease;
}

@keyframes dw-top-banner-marquee {
	0% {
		transform: translate3d(0, 0, 0);
	}
	100% {
		transform: translate3d(-50%, 0, 0);
	}
}

/* Respect reduced-motion preferences: stop scrolling, keep first message visible. */
@media (prefers-reduced-motion: reduce) {
	.dw-top-banner__track {
		animation: none;
		transform: none;
	}
}

@media screen and (max-width: 1024px) {
	body.has-top-banner header.sticky-header #navi,
	body.has-top-banner .desktop-stick-right-menu {
		top: 68px !important;
	}

	body.has-top-banner header #navi {
		top: -134px !important;
	}
}

@media screen and (max-width: 768px) {
	body.has-top-banner {
		padding-top: 80px;
	}	
}
