/*
Theme Name: Central Ocean Child
Theme URI: https://dateck-media.de/
Description: Child Theme für Hotel Central auf Basis von OceanWP.
Author: Dateck Media
Template: oceanwp
Version: 1.1.0
Text Domain: central-ocean-child
*/

/* =========================================================
   CLUB CENTRAL – Announcement Bar
   ========================================================= */

:root {
	--central-club-bar-height: 44px;
	--central-club-sticky-offset: 44px;
}

/* Platz für die fixed Leiste schaffen */
body {
	padding-top: var(--central-club-bar-height);
}

.central-club-announcement {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 999999;
	height: var(--central-club-bar-height);
	overflow: hidden;
	background: linear-gradient(
		90deg,
		#d5aa4e 0%,
		#f7cb68 45%,
		#e9bf60 70%,
		#d5aa4e 100%
	);
	color: #151515;
	box-shadow: 0 3px 14px rgba(0, 0, 0, 0.10);
}

/* Bei eingeloggten WordPress-Nutzern unter der Adminbar */
body.admin-bar .central-club-announcement {
	top: 32px;
}

.central-club-announcement__track {
	display: flex;
	align-items: center;
	width: max-content;
	height: 100%;
	animation: centralClubMarquee 34s linear infinite;
	will-change: transform;
}

.central-club-announcement__item {
	display: flex;
	align-items: center;
	flex-shrink: 0;
	gap: 14px;
	height: 100%;
	padding: 0 30px;
	white-space: nowrap;
	font-size: 14px;
	line-height: 1;
}

.central-club-announcement__item strong {
	font-weight: 700;
}

.central-club-announcement__divider {
	opacity: .45;
	margin: 0 2px;
}

.central-club-announcement__sparkle {
	color: #fff8df;
	font-size: 18px;
	line-height: 1;
	text-shadow:
		0 0 5px rgba(255,255,255,.95),
		0 0 12px rgba(255,255,255,.55);
}

.central-club-announcement a {
	color: #151515 !important;
	font-weight: 700;
	text-decoration: underline;
	text-underline-offset: 3px;
	transition: opacity .2s ease;
}

.central-club-announcement a:hover,
.central-club-announcement a:focus {
	color: #151515 !important;
	opacity: .65;
}

.central-club-announcement:hover .central-club-announcement__track {
	animation-play-state: paused;
}

@keyframes centralClubMarquee {
	from {
		transform: translateX(0);
	}
	to {
		transform: translateX(-50%);
	}
}

/*
 * Wenn Ocean Sticky Header den Header fixed/sticky setzt,
 * wird diese Klasse automatisch per JS ergänzt.
 */
#site-header.central-club-header-offset {
	top: var(--central-club-sticky-offset) !important;
}

/* Auch transparente Header-Wrapper sauber unter der Leiste halten,
   falls OceanWP sie im Sticky-Zustand positioniert. */
#transparent-header-wrap.central-club-header-offset {
	top: var(--central-club-sticky-offset) !important;
}

@media (max-width: 782px) {
	body.admin-bar .central-club-announcement {
		top: 46px;
	}
}

@media (max-width: 767px) {
	:root {
		--central-club-bar-height: 40px;
	}

	.central-club-announcement__item {
		gap: 10px;
		padding: 0 20px;
		font-size: 12px;
	}

	.central-club-announcement__sparkle {
		font-size: 15px;
	}

	.central-club-announcement__track {
		animation-duration: 27s;
	}
}

@media (prefers-reduced-motion: reduce) {
	.central-club-announcement__track {
		animation: none;
	}
}
