/* 
=====================================================
 KinoFilter - styles like KinoGo.biz
 by megohub
 ALL rules scoped under .kf-bar / .kf-* only
=====================================================
*/

#kf-bar.kf-bar,
.kf-bar {
	background: #2b2b2b !important;
	border-radius: 4px;
	margin: 0 0 15px 0 !important;
	padding: 0 !important;
	font-family: Arial, Helvetica, sans-serif;
	font-size: 13px;
	color: #ccc;
	position: relative;
	z-index: 50;
	width: auto;
	max-width: 100%;
	box-sizing: border-box;
	clear: both;
	overflow: visible;
}

.kf-bar *,
.kf-bar *::before,
.kf-bar *::after {
	box-sizing: border-box;
}

/* Top row */
.kf-bar .kf-top {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 10px 12px 8px;
	border-bottom: 1px solid #333;
	flex-wrap: wrap;
	gap: 8px;
}

.kf-bar .kf-sort-wrap {
	display: flex;
	align-items: center;
	gap: 8px;
}

.kf-bar .kf-label {
	color: #aaa;
}

.kf-bar .kf-select {
	background: #1a1a1a;
	border: 1px solid #e67e22;
	color: #eee;
	padding: 5px 28px 5px 10px;
	border-radius: 2px;
	cursor: pointer;
	appearance: none;
	-webkit-appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23aaa'%3E%3Cpath d='M6 8L1 3h10z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 8px center;
	min-width: 160px;
	max-width: 220px;
	height: auto;
	line-height: normal;
}

.kf-bar .kf-select:hover,
.kf-bar .kf-select:focus {
	border-color: #f39c12;
	outline: none;
}

.kf-bar .kf-right {
	display: flex;
	align-items: center;
	gap: 10px;
	color: #888;
	font-size: 13px;
}

.kf-bar .kf-count b {
	color: #ddd;
	font-weight: normal;
}

.kf-bar #kf-reset {
	background: #555;
	border: none;
	color: #ddd;
	padding: 4px 10px;
	border-radius: 2px;
	cursor: pointer;
	font-size: 12px;
}

.kf-bar #kf-reset:hover {
	background: #666;
}

/* Tabs */
.kf-bar .kf-filters {
	display: flex;
	flex-wrap: wrap;
	gap: 0;
	padding: 0;
	position: relative;
	width: 100%;
}

.kf-bar .kf-dropdown {
	position: static;
	display: inline-block;
}

.kf-bar .kf-btn {
	background: transparent;
	border: none;
	border-bottom: 2px solid transparent;
	color: #ccc;
	padding: 10px 16px;
	border-radius: 0;
	cursor: pointer;
	font-size: 13px;
	line-height: normal;
	height: auto;
	width: auto;
	margin: 0;
}

.kf-bar .kf-btn:hover {
	color: #fff;
	background: #333;
}

.kf-bar .kf-dropdown.open .kf-btn,
.kf-bar .kf-btn.has-active {
	background: #1e5a9c !important;
	border-bottom-color: #1e5a9c !important;
	color: #fff !important;
}

.kf-bar .kf-arrow {
	font-size: 10px;
	margin-left: 4px;
	opacity: .7;
}

/* Panel */
.kf-bar .kf-panel {
	display: none;
	position: absolute;
	left: 0;
	right: 0;
	top: 100%;
	margin: 0;
	background: #2d2d2d;
	border: 1px solid #3a3a3a;
	border-top: none;
	border-radius: 0 0 4px 4px;
	box-shadow: 0 10px 30px rgba(0,0,0,.55);
	z-index: 100;
	width: 100%;
	max-width: 100%;
	padding: 0;
}

.kf-bar .kf-dropdown.open .kf-panel {
	display: block;
}

.kf-bar .kf-panel-head {
	display: flex;
	justify-content: space-between;
	align-items: center;
	background: #252525;
	padding: 8px 14px;
	border-bottom: 1px solid #3a3a3a;
}

.kf-bar .kf-panel-title {
	background: transparent;
	padding: 0;
	font-weight: bold;
	color: #f0a500;
	text-transform: lowercase;
	border: none;
	font-size: 14px;
	margin: 0;
}

.kf-bar .kf-search {
	padding: 0;
	border: none;
	margin: 0;
}

.kf-bar .kf-search-input {
	width: 180px;
	max-width: 40vw;
	background: #1a1a1a;
	border: 1px solid #444;
	color: #eee;
	padding: 5px 10px;
	border-radius: 2px;
	font-size: 12px;
	height: auto;
	line-height: normal;
	margin: 0;
}

.kf-bar .kf-search-input:focus {
	border-color: #1e5a9c;
	outline: none;
}

.kf-bar .kf-list {
	max-height: 320px;
	overflow-y: auto;
	overflow-x: hidden;
	padding: 12px 16px;
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 6px 16px;
}

.kf-bar .kf-check {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 3px 0;
	cursor: pointer;
	color: #ccc;
	font-size: 13px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	margin: 0;
	font-weight: normal;
}

.kf-bar .kf-check:hover {
	color: #fff;
}

.kf-bar .kf-check input {
	margin: 0;
	accent-color: #1e5a9c;
	width: 14px;
	height: 14px;
	flex-shrink: 0;
}

.kf-bar .kf-actions {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 12px 16px;
	border-top: 1px solid #3a3a3a;
	background: #252525;
	flex-wrap: wrap;
}

.kf-bar .kf-apply {
	background: #2a9d8f;
	border: none;
	color: #fff;
	padding: 7px 18px;
	border-radius: 3px;
	cursor: pointer;
	font-size: 13px;
	height: auto;
	width: auto;
	margin: 0;
	line-height: normal;
}

.kf-bar .kf-apply:hover {
	background: #34b3a3;
}

.kf-bar .kf-cancel {
	background: #4a4a4a;
	border: none;
	color: #ddd;
	padding: 7px 18px;
	border-radius: 3px;
	cursor: pointer;
	font-size: 13px;
	height: auto;
	width: auto;
	margin: 0;
	line-height: normal;
}

.kf-bar .kf-cancel:hover {
	background: #5a5a5a;
}

.kf-bar .kf-combine {
	margin-left: auto;
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 12px;
	color: #aaa;
	cursor: pointer;
	font-weight: normal;
}

/* Results (outside bar - only our classes) */
.kf-empty {
	padding: 40px;
	text-align: center;
	color: #888;
	font-size: 16px;
	clear: both;
}

.kf-nav {
	display: flex;
	gap: 4px;
	justify-content: center;
	padding: 20px 0;
	flex-wrap: wrap;
	clear: both;
}

.kf-nav a {
	display: inline-block;
	padding: 6px 12px;
	background: #333;
	color: #ccc;
	border-radius: 3px;
	text-decoration: none;
	font-size: 13px;
}

.kf-nav a:hover,
.kf-nav a.active {
	background: #1e5a9c;
	color: #fff;
}

.kf-bar .kf-list::-webkit-scrollbar {
	width: 6px;
}
.kf-bar .kf-list::-webkit-scrollbar-track {
	background: #222;
}
.kf-bar .kf-list::-webkit-scrollbar-thumb {
	background: #555;
	border-radius: 3px;
}

@media (max-width: 900px) {
	.kf-bar .kf-list {
		grid-template-columns: repeat(3, 1fr);
	}
}

@media (max-width: 600px) {
	.kf-bar .kf-list {
		grid-template-columns: repeat(2, 1fr);
	}
	.kf-bar .kf-search-input {
		width: 120px;
	}
}


#kf-overlay {
	display: none;
	position: fixed;
	left: 0; top: 0; right: 0; bottom: 0;
	background: rgba(0,0,0,.65);
	z-index: 35;
}
#kf-overlay.kf-show { display: block; }

.kf-bar .kf-select {
	appearance: none;
	-webkit-appearance: none;
	padding-right: 32px;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23e67e22' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 10px center;
	box-shadow: 0 0 0 1px rgba(230,126,34,.25);
}

#kf-bar .kf-check.kf-hidden { display: none !important; }

#kf-bar label.kf-check.kf-hidden, #kf-bar .kf-check.kf-hidden { display: none !important; visibility: hidden !important; height: 0 !important; overflow: hidden !important; margin: 0 !important; padding: 0 !important; }


/* Compact pagination */
.kf-nav {
	display: flex;
	flex-wrap: wrap;
	gap: 4px;
	justify-content: center;
	align-items: center;
	padding: 16px 8px 20px;
	clear: both;
}
.kf-nav a,
.kf-nav span {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 32px;
	height: 32px;
	padding: 0 8px;
	background: #333;
	color: #ccc;
	border-radius: 4px;
	text-decoration: none;
	font-size: 13px;
	box-sizing: border-box;
}
.kf-nav a:hover {
	background: #1e5a9c;
	color: #fff;
}
.kf-nav a.active {
	background: #1e5a9c;
	color: #fff;
	font-weight: bold;
}
.kf-nav .kf-nav-dots {
	background: transparent;
	color: #888;
	min-width: 20px;
}
.kf-nav .kf-nav-disabled {
	opacity: 0.35;
	cursor: default;
	background: #2a2a2a;
}

/* Hide default DLE pagination while filter is active */
body.kf-filtered .bot-left,
body.kf-filtered .bot-navigation,
body.kf-filtered .navigation {
	display: none !important;
}
