/*
 * Super Breaking News Ticker - front end styles.
 * Colors come from CSS variables set on every ticker (admin > News Ticker > Edit > Design).
 */

/* ---------- Base ---------- */
.snt-wrap {
	display: flex;
	align-items: stretch;
	position: relative;
	z-index: 1;
	width: 100%;
	max-width: 100%;
	margin: 0;
	padding: 0;
	overflow: hidden;
	box-sizing: border-box;
	background: var(--snt-bg, #000);
	color: var(--snt-text, #fff);
	font-family: inherit;
	font-size: var(--snt-font, 16px);
	line-height: 1.5;
	text-align: left;
}
.snt-wrap *,
.snt-wrap *::before,
.snt-wrap *::after { box-sizing: border-box; }
.snt-wrap p,
.snt-wrap ul,
.snt-wrap li { margin: 0; padding: 0; list-style: none; }
.snt-wrap li::marker { content: none; }
.snt-wrap a { color: inherit; text-decoration: none; border: 0; box-shadow: none; }
.snt-wrap a:hover,
.snt-wrap a:focus { color: inherit; text-decoration: underline; }
.snt-wrap button {
	-webkit-appearance: none;
	appearance: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: auto;
	height: auto;
	min-width: 0;
	min-height: 0;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	color: inherit;
	font: inherit;
	line-height: 1;
	letter-spacing: normal;
	text-transform: none;
	text-shadow: none;
	cursor: pointer;
}
.snt-wrap button:hover,
.snt-wrap button:focus { background: transparent; color: inherit; }
.snt-wrap button:focus-visible { outline: 2px solid currentColor; outline-offset: -4px; }
.snt-wrap svg { display: block; width: 18px; height: 18px; }

.snt-label {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	gap: 8px;
	position: relative;
	z-index: 3;
	padding: 10px 20px;
	background: var(--snt-label-bg, #fbb800);
	color: var(--snt-label-color, #000);
	font-weight: 700;
	white-space: nowrap;
}
.snt-label .dashicons { width: auto; height: auto; font-size: 1.2em; line-height: 1; }

.snt-track {
	flex: 1 1 auto;
	display: flex;
	align-items: center;
	position: relative;
	min-width: 0;
	overflow: hidden;
}

.snt-cw {
	flex: 0 0 auto;
	display: flex;
	position: relative;
	z-index: 3;
	background: var(--snt-bg, #000);
}
.snt-wrap .snt-close { padding: 0 16px; font-size: 1.6em; font-weight: 400; }
.snt-wrap .snt-close:hover { opacity: .75; }

.snt-item { font-weight: 600; white-space: nowrap; }

/* ---------- Scrolling styles (Classic, Gradient, Clock) ---------- */
.snt-move {
	flex: 0 0 auto;
	display: flex;
	white-space: nowrap;
	padding: 10px 0 10px 100%;
	animation: snt-scroll var(--snt-speed, 30s) linear infinite;
	will-change: transform;
}
.snt-loop .snt-move { padding-left: 0; animation: none; }
.snt-loop .snt-move.snt-run { animation: snt-loop 30s linear infinite; }
.snt-pause:hover .snt-move,
.snt-pause:focus-within .snt-move { animation-play-state: paused; }
.snt-set { flex: 0 0 auto; display: flex; align-items: center; }
.snt-set .snt-item { display: inline-flex; align-items: center; padding: 0 26px; }

/* 1. Classic */
.snt-style-classic .snt-item::before { content: "\25CF"; margin-right: 10px; font-size: .55em; opacity: .6; }

/* 2. Animated gradient */
.snt-style-gradient {
	background: var(--snt-gradient, linear-gradient(90deg, #FFBE0B, #FB5607, #FF006E, #8338EC, #3A86FF));
	background-size: 450% 1400%;
	animation: snt-gradient 40s linear infinite;
}
.snt-style-gradient .snt-label { margin-right: 16px; }
.snt-style-gradient .snt-label::after {
	content: "";
	position: absolute;
	top: 0;
	right: -16px;
	width: 16px;
	height: 100%;
	background: inherit;
	-webkit-clip-path: polygon(0 0, 100% 50%, 0 100%);
	clip-path: polygon(0 0, 100% 50%, 0 100%);
}
.snt-style-gradient .snt-set .snt-item { padding: 0 18px; }
.snt-style-gradient .snt-item::before {
	content: "";
	display: inline-block;
	width: .5em;
	height: .5em;
	margin-right: 22px;
	border-right: 3px solid var(--snt-accent, #7cfc00);
	border-bottom: 3px solid var(--snt-accent, #7cfc00);
	transform: rotate(-45deg);
}
.snt-style-gradient .snt-cw,
.snt-style-clock .snt-cw,
.snt-style-typewriter .snt-cw { background: var(--snt-label-bg); color: var(--snt-label-color); }

/* 3. Live clock */
.snt-style-clock .snt-label { font-variant-numeric: tabular-nums; letter-spacing: .5px; }
.snt-style-clock .snt-set .snt-item { padding: 0 20px; }
.snt-style-clock .snt-item::after { content: ","; margin-left: 6px; }

/* ---------- 4. Typewriter ---------- */
.snt-rounded { border-radius: 6px; }
.snt-style-typewriter .snt-label { padding: 14px 20px; }
.snt-style-typewriter .snt-track { padding: 0 14px; }
.snt-style-typewriter .snt-list { width: 100%; }
.snt-style-typewriter .snt-item { display: block; font-weight: 700; overflow: hidden; text-overflow: ellipsis; }
.snt-style-typewriter .snt-item + .snt-item { display: none; }
.snt-js.snt-style-typewriter .snt-list { display: none; }
.snt-type { width: 100%; overflow: hidden; white-space: nowrap; font-weight: 700; }
.snt-cursor {
	display: inline-block;
	width: 2px;
	height: 1.2em;
	margin-left: 2px;
	vertical-align: text-bottom;
	background: var(--snt-accent, #ff9900);
	animation: snt-blink .9s steps(1) infinite;
}

/* ---------- 5. Fade slider ---------- */
.snt-style-fade .snt-label { margin: 10px 0 10px 12px; padding: 8px 14px; border-radius: 2px; }
.snt-style-fade .snt-track { padding: 0 14px; }
.snt-style-fade .snt-list { width: 100%; }
.snt-style-fade .snt-item { display: none; font-weight: 700; overflow: hidden; text-overflow: ellipsis; }
.snt-style-fade:not(.snt-js) .snt-item:first-child,
.snt-style-fade .snt-item.snt-active,
.snt-style-fade .snt-item.snt-leave { display: block; }
.snt-style-fade .snt-item.snt-active { animation: snt-fadein .5s ease both; }
.snt-style-fade .snt-item.snt-leave { animation: snt-fadeout .35s ease both; }
.snt-nav {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	align-self: center;
	margin: 0 12px 0 0;
	padding: 3px;
	border-radius: 2px;
	background: var(--snt-accent, #fff);
	color: var(--snt-bg, #000);
}
.snt-wrap .snt-nav button { padding: 4px; }
.snt-wrap .snt-nav button:hover { opacity: .6; }

/* ---------- Trend arrows (all styles) ---------- */
.snt-wrap .snt-up::before,
.snt-wrap .snt-down::before {
	display: inline-block;
	width: auto;
	height: auto;
	margin: 0 10px 0 0;
	border: 0;
	transform: none;
	font-size: .7em;
	vertical-align: middle;
	opacity: 1;
}
.snt-wrap .snt-up::before { content: "\25B2"; color: #16c60c; }
.snt-wrap .snt-down::before { content: "\25BC"; color: #ff2d2d; }

/* ---------- Fixed top / bottom ---------- */
.snt-holder { position: fixed; left: 0; right: 0; z-index: 99999; }
.snt-holder-top { top: 0; }
.snt-holder-bottom { bottom: 0; }
.admin-bar .snt-holder-top { top: 32px; }
.snt-holder .snt-wrap { border-radius: 0; }

/* ---------- Responsive ---------- */
@media screen and (max-width: 782px) {
	.admin-bar .snt-holder-top { top: 46px; }
}
@media (max-width: 767px) {
	.snt-hide-mobile { display: none !important; }
	.snt-label,
	.snt-style-typewriter .snt-label { padding: 8px 12px; }
	.snt-style-fade .snt-label { margin-left: 8px; padding: 6px 10px; }
	.snt-wrap .snt-close { padding: 0 12px; }
}

/* ---------- Animations ---------- */
@keyframes snt-scroll { from { transform: translateX(0); } to { transform: translateX(-100%); } }
@keyframes snt-loop { from { transform: translateX(0); } to { transform: translateX(calc(-1 * var(--snt-w, 100px))); } }
@keyframes snt-gradient {
	0% { background-position: 0% 50%; }
	50% { background-position: 100% 50%; }
	100% { background-position: 0% 50%; }
}
@keyframes snt-blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }
@keyframes snt-fadein { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes snt-fadeout { from { opacity: 1; transform: none; } to { opacity: 0; transform: translateY(-6px); } }

@media (prefers-reduced-motion: reduce) {
	.snt-style-gradient,
	.snt-cursor { animation: none; }
}
