/* =========================================================================
   Homepage Sidebar Categories — Style/Layout Selector
   (Appearance > Customize > Categories > Homepage Sidebar Categories —
   see inc/home-sidebar-cat-style.php)

   Every single rule below is scoped under `.gzfc-home-sidebar-cats`. That
   wrapper class is only ever printed by gzfc_render_home_sidebar_categories(),
   which itself only ever runs for the main sidebar's Categories block while
   the actual Homepage is being viewed (see the PHP file for exactly how
   that is enforced). Nothing here can affect Post Cards, Category Pages,
   the Footer Categories column, the Header Category Bar, or any sidebar
   on any other page — those all keep using the original
   `.gzf-category-list` markup and CSS, completely untouched.

   Reuses the theme's own color tokens (--gzf-color-*) so every style
   automatically follows the site's existing accent/skin colors.
   ========================================================================= */

.gzfc-home-sidebar-cats .gzfc-hs-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

/* -------------------------------------------------------------------
   0. Classic — pixel-identical to the framework's original vertical
   category list, just rendered through the new wrapper so switching
   back to it is a true "no visual change" option.
   ------------------------------------------------------------------- */
.gzfc-hs-style--classic .gzfc-hs-item {
	border-bottom: 1px solid var(--gzf-color-border);
}
.gzfc-hs-style--classic .gzfc-hs-item a {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 10px 2px;
	color: var(--gzf-color-text);
	font-size: .88rem;
}
.gzfc-hs-style--classic .gzfc-hs-item a:hover {
	color: var(--gzf-color-primary);
}
.gzfc-hs-style--classic .gzfc-hs-icon {
	display: none;
}
.gzfc-hs-style--classic .gzfc-hs-count {
	color: var(--gzf-color-muted);
	font-size: .78rem;
}

/* -------------------------------------------------------------------
   1. Reference Style — bordered rows with an arrow marker, matching
   the supplied reference screenshot ("KATEGORİLER" panel).
   ------------------------------------------------------------------- */
.gzfc-hs-style--reference .gzfc-hs-list {
	border: 1px solid var(--gzf-color-border);
	border-radius: 10px;
	overflow: hidden;
}
.gzfc-hs-style--reference .gzfc-hs-item {
	border-bottom: 1px solid var(--gzf-color-border);
}
.gzfc-hs-style--reference .gzfc-hs-item:last-child {
	border-bottom: none;
}
.gzfc-hs-style--reference .gzfc-hs-item a {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 12px 14px;
	color: var(--gzf-color-text);
	font-size: .86rem;
	font-weight: 600;
	background: var(--gzf-color-surface);
	transition: background-color .2s ease, color .2s ease, padding-left .2s ease;
}
.gzfc-hs-style--reference .gzfc-hs-icon::before {
	content: "\25B8";
	color: var(--gzf-color-primary);
	font-size: .8em;
	flex-shrink: 0;
}
.gzfc-hs-style--reference .gzfc-hs-item a:hover {
	background: rgba(255,255,255,.05);
	color: var(--gzf-color-primary);
	padding-left: 20px;
}
.gzfc-hs-style--reference .gzfc-hs-count {
	margin-left: auto;
	color: var(--gzf-color-muted);
	font-size: .74rem;
}

/* -------------------------------------------------------------------
   2. Gaming Pills — rounded pill-shaped category buttons, wrapping.
   ------------------------------------------------------------------- */
.gzfc-hs-style--pills .gzfc-hs-list {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}
.gzfc-hs-style--pills .gzfc-hs-item {
	border: 0;
}
.gzfc-hs-style--pills .gzfc-hs-item a {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 8px 16px;
	border-radius: 999px;
	background: var(--gzf-color-surface);
	border: 1px solid var(--gzf-color-border);
	color: var(--gzf-color-text);
	font-size: .8rem;
	font-weight: 600;
	transition: background-color .2s ease, border-color .2s ease, color .2s ease, transform .2s ease;
}
.gzfc-hs-style--pills .gzfc-hs-icon {
	display: none;
}
.gzfc-hs-style--pills .gzfc-hs-item a:hover {
	background: var(--gzf-color-primary);
	border-color: var(--gzf-color-primary);
	color: #fff;
	transform: translateY(-2px);
}
.gzfc-hs-style--pills .gzfc-hs-count {
	font-size: .72rem;
	opacity: .8;
}

/* -------------------------------------------------------------------
   3. Neon Gaming — soft neon border + glow on hover.
   ------------------------------------------------------------------- */
.gzfc-hs-style--neon .gzfc-hs-item {
	margin-bottom: 8px;
}
.gzfc-hs-style--neon .gzfc-hs-item a {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 10px 14px;
	border-radius: 8px;
	border: 1px solid var(--gzf-color-border);
	color: var(--gzf-color-text);
	font-size: .85rem;
	background: rgba(255,255,255,.02);
	transition: box-shadow .25s ease, border-color .25s ease, color .25s ease;
}
.gzfc-hs-style--neon .gzfc-hs-icon {
	display: none;
}
.gzfc-hs-style--neon .gzfc-hs-item a:hover {
	border-color: var(--gzf-color-primary);
	color: var(--gzf-color-primary);
	box-shadow: 0 0 10px rgba(255,77,28,.5), 0 0 22px rgba(255,77,28,.25), inset 0 0 8px rgba(255,77,28,.15);
}
.gzfc-hs-style--neon .gzfc-hs-count {
	color: var(--gzf-color-muted);
	font-size: .74rem;
}

/* -------------------------------------------------------------------
   4. Bordered Cards — each category as its own mini bordered card.
   ------------------------------------------------------------------- */
.gzfc-hs-style--bordered .gzfc-hs-item {
	margin-bottom: 10px;
}
.gzfc-hs-style--bordered .gzfc-hs-item:last-child {
	margin-bottom: 0;
}
.gzfc-hs-style--bordered .gzfc-hs-item a {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 12px 14px;
	border: 1px solid var(--gzf-color-border);
	border-left: 3px solid var(--gzf-color-primary);
	border-radius: 8px;
	background: var(--gzf-color-card-bg);
	color: var(--gzf-color-text);
	font-size: .85rem;
	font-weight: 600;
	transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.gzfc-hs-style--bordered .gzfc-hs-icon {
	display: none;
}
.gzfc-hs-style--bordered .gzfc-hs-item a:hover {
	transform: translateY(-3px);
	box-shadow: 0 10px 20px -8px rgba(0,0,0,.6);
	border-color: var(--gzf-color-primary);
}
.gzfc-hs-style--bordered .gzfc-hs-count {
	color: var(--gzf-color-muted);
	font-size: .74rem;
}

/* -------------------------------------------------------------------
   5. Badge Counter — count shown as a round accent-colored badge.
   ------------------------------------------------------------------- */
.gzfc-hs-style--badge .gzfc-hs-item {
	border-bottom: 1px solid var(--gzf-color-border);
}
.gzfc-hs-style--badge .gzfc-hs-item:last-child {
	border-bottom: none;
}
.gzfc-hs-style--badge .gzfc-hs-item a {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 11px 4px;
	color: var(--gzf-color-text);
	font-size: .86rem;
	transition: color .2s ease;
}
.gzfc-hs-style--badge .gzfc-hs-icon {
	display: none;
}
.gzfc-hs-style--badge .gzfc-hs-item a:hover {
	color: var(--gzf-color-primary);
}
.gzfc-hs-style--badge .gzfc-hs-count {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 24px;
	height: 24px;
	padding: 0 7px;
	border-radius: 999px;
	background: var(--gzf-color-primary);
	color: #fff;
	font-size: .72rem;
	font-weight: 700;
}

/* -------------------------------------------------------------------
   6. Gradient Style — gradient sweep accent on hover.
   ------------------------------------------------------------------- */
.gzfc-hs-style--gradient .gzfc-hs-item {
	margin-bottom: 6px;
	border-radius: 8px;
	overflow: hidden;
}
.gzfc-hs-style--gradient .gzfc-hs-item a {
	position: relative;
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 11px 14px;
	color: var(--gzf-color-text);
	font-size: .85rem;
	font-weight: 600;
	background: linear-gradient(90deg, rgba(255,77,28,0) 0%, rgba(255,77,28,0) 100%);
	background-size: 200% 100%;
	background-position: 100% 0;
	transition: background-position .35s ease, color .25s ease;
}
.gzfc-hs-style--gradient .gzfc-hs-icon {
	display: none;
}
.gzfc-hs-style--gradient .gzfc-hs-item a:hover {
	background-image: linear-gradient(90deg, var(--gzf-color-primary) 0%, var(--gzf-color-accent) 100%);
	background-position: 0 0;
	color: #fff;
}
.gzfc-hs-style--gradient .gzfc-hs-count {
	font-size: .74rem;
	opacity: .85;
}

/* -------------------------------------------------------------------
   7. Highlight Box — animated background box slides in on hover.
   ------------------------------------------------------------------- */
.gzfc-hs-style--highlight .gzfc-hs-item {
	position: relative;
}
.gzfc-hs-style--highlight .gzfc-hs-item a {
	position: relative;
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 11px 14px;
	color: var(--gzf-color-text);
	font-size: .85rem;
	overflow: hidden;
	z-index: 0;
}
.gzfc-hs-style--highlight .gzfc-hs-icon {
	display: none;
}
.gzfc-hs-style--highlight .gzfc-hs-item a::before {
	content: "";
	position: absolute;
	inset: 0;
	background: rgba(255,77,28,.14);
	transform: translateX(-100%);
	transition: transform .3s ease;
	z-index: -1;
}
.gzfc-hs-style--highlight .gzfc-hs-item a:hover::before {
	transform: translateX(0);
}
.gzfc-hs-style--highlight .gzfc-hs-item a:hover {
	color: var(--gzf-color-primary);
}
.gzfc-hs-style--highlight .gzfc-hs-count {
	color: var(--gzf-color-muted);
	font-size: .74rem;
}

/* -------------------------------------------------------------------
   8. Animated Highlight Cycle — glow auto-moves from category to
   category, one at a time, in a smooth continuous loop. Fully CSS
   driven (no JS) so it keeps working with any caching setup.

   Per-item timing is derived from two inline custom properties set by
   PHP on the wrapper (--gzfc-hs-step / --gzfc-hs-duration) and on each
   item (--gzfc-hs-index). Every item shares one identical animation
   duration (item_count * step) but starts at a different negative
   delay (index * step), so they all play one shared loop with the
   glow appearing to travel down the list, category by category,
   forever.
   ------------------------------------------------------------------- */
.gzfc-hs-style--animated .gzfc-hs-item a {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 11px 14px;
	border-radius: 8px;
	color: var(--gzf-color-text);
	font-size: .85rem;
	font-weight: 600;
}
.gzfc-hs-style--animated .gzfc-hs-count {
	color: var(--gzf-color-muted);
	font-size: .74rem;
}

/* Static Mode (Animation Off): first category stays highlighted. */
.gzfc-hs-style--animated.is-static .gzfc-hs-item.is-active a {
	background: var(--gzfc-hs-bg, rgba(255,77,28,.14));
	box-shadow: 0 0 0 1px var(--gzfc-hs-glow, #ff4d1c) inset, 0 8px 20px -8px var(--gzfc-hs-glow, #ff4d1c);
	color: var(--gzfc-hs-glow, #ff4d1c);
}
.gzfc-hs-style--animated.is-static.has-lift .gzfc-hs-item.is-active a {
	transform: translateY(-3px);
}

/* Animated Mode: continuous highlight cycle. */
.gzfc-hs-style--animated.is-animated .gzfc-hs-item a {
	animation-name: gzfc-hs-glow-cycle;
	animation-duration: var(--gzfc-hs-duration, 8s);
	animation-timing-function: ease-in-out;
	animation-iteration-count: infinite;
	animation-delay: calc(-1 * var(--gzfc-hs-index, 0) * var(--gzfc-hs-step, 1.6s));
}
.gzfc-hs-style--animated.is-animated:not(.has-lift) .gzfc-hs-item a {
	animation-name: gzfc-hs-glow-cycle-no-lift;
}

/* Manual hover always works too, regardless of automatic cycling. */
.gzfc-hs-style--animated .gzfc-hs-item a:hover {
	background: var(--gzfc-hs-bg, rgba(255,77,28,.14));
	color: var(--gzfc-hs-glow, #ff4d1c);
}
.gzfc-hs-style--animated.has-lift .gzfc-hs-item a:hover {
	transform: translateY(-3px);
	box-shadow: 0 8px 20px -8px var(--gzfc-hs-glow, #ff4d1c);
}

@keyframes gzfc-hs-glow-cycle {
	0%, 88%, 100% {
		transform: translateY(0);
		background: transparent;
		box-shadow: none;
		color: var(--gzf-color-text);
	}
	4%, 10% {
		transform: translateY(-3px);
		background: var(--gzfc-hs-bg, rgba(255,77,28,.14));
		box-shadow: 0 0 0 1px var(--gzfc-hs-glow, #ff4d1c) inset, 0 8px 20px -8px var(--gzfc-hs-glow, #ff4d1c);
		color: var(--gzfc-hs-glow, #ff4d1c);
	}
}
@keyframes gzfc-hs-glow-cycle-no-lift {
	0%, 88%, 100% {
		background: transparent;
		box-shadow: none;
		color: var(--gzf-color-text);
	}
	4%, 10% {
		background: var(--gzfc-hs-bg, rgba(255,77,28,.14));
		box-shadow: 0 0 0 1px var(--gzfc-hs-glow, #ff4d1c) inset;
		color: var(--gzfc-hs-glow, #ff4d1c);
	}
}

/* Respect reduced-motion preferences: fall back to a static first-item
   highlight instead of a continuous animation. */
@media (prefers-reduced-motion: reduce) {
	.gzfc-hs-style--animated.is-animated .gzfc-hs-item a {
		animation: none;
	}
	.gzfc-hs-style--animated.is-animated .gzfc-hs-item:first-child a {
		background: var(--gzfc-hs-bg, rgba(255,77,28,.14));
		box-shadow: 0 0 0 1px var(--gzfc-hs-glow, #ff4d1c) inset;
		color: var(--gzfc-hs-glow, #ff4d1c);
	}
}

/* Mobile: keep pill/gradient/highlight rows comfortable to tap. */
@media (max-width: 782px) {
	.gzfc-home-sidebar-cats .gzfc-hs-item a {
		min-height: 40px;
	}
}

/* =========================================================================
   Optional Custom Font / Color / Border / Spacing / Alignment override.
   Only applied when the wrapper carries .gzfc-hs-custom-style (i.e. the
   "Enable Custom Font, Color & Spacing" toggle is on). Layered ON TOP of
   whichever Style preset is active above — every existing preset's shape
   (pill, card, badge, etc.) is kept; only font/color/spacing/alignment are
   overridden. Independent from Header Categories (--gzfc-hcm-*) and
   Footer Categories (--gzfc-footer-cat-*) — different custom property
   names entirely.
   ========================================================================= */
.gzfc-hs-custom-style {
	font-family: var(--gzfc-hs-custom-font, inherit);
}
.gzfc-hs-custom-style .gzfc-hs-item a {
	font-family: inherit;
	font-weight: var(--gzfc-hs-custom-weight, 600);
	font-size: var(--gzfc-hs-font-size, inherit);
	color: var(--gzfc-hs-custom-text, inherit);
	background-color: var(--gzfc-hs-custom-bg, inherit);
	border-color: var(--gzfc-hs-custom-border, inherit);
	border-radius: var(--gzfc-hs-custom-radius, inherit);
	padding-top: var(--gzfc-hs-custom-padding, inherit);
	padding-bottom: var(--gzfc-hs-custom-padding, inherit);
}
.gzfc-hs-align-center .gzfc-hs-item a {
	justify-content: center;
	text-align: center;
}
.gzfc-hs-align-center .gzfc-hs-icon {
	display: none;
}
