/* =============================================
 * Top Ranking Widget
 * ============================================= */
.tr-ranking-widget {
	position: relative;
}

/* Header */
.tr-header {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	margin-bottom: 16px;
}

.tr-title {
	font-size: 22px;
	font-weight: 700;
	color: #222;
	line-height: 1.3;
}

.tr-subtitle {
	font-size: 14px;
	color: #666;
	margin-top: 4px;
	line-height: 1.4;
}

.tr-more {
	display: inline-flex;
	align-items: center;
	font-size: 14px;
	color: #333;
	text-decoration: none;
	white-space: nowrap;
	flex-shrink: 0;
	margin-top: 4px;
}

.tr-more:hover {
	opacity: 0.7;
}

/* Card */
.tr-card {
	display: flex;
	flex-direction: column;
	text-decoration: none;
	background: #fff;
	border-radius: 12px;
	overflow: hidden;
	height: 100%;
}

/* Image */
.tr-image {
	display: block;
	width: 100%;
	height: 240px;
	overflow: hidden;
	position: relative;
}

.tr-image img {
	width: 100%;
	height: 100%;
	display: block;
	object-fit: cover;
	object-position: center;
	transition: transform 0.3s ease;
}

.tr-card:hover .tr-image img {
	transform: scale(1.05);
}

.tr-placeholder {
	display: block;
	width: 100%;
	height: 100%;
	background: #f0f0f0;
}

/* Badge */
.tr-badge {
	position: absolute;
	bottom: 8px;
	left: 50%;
	transform: translateX(-50%);
	width: 42px;
	height: 42px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #3d3d3d;
	color: #fff;
	font-size: 10px;
	font-weight: 700;
	clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
	z-index: 2;
	line-height: 1;
	text-transform: uppercase;
}

/* Name */
.tr-name {
	display: block;
	padding: 10px 12px 0;
	font-size: 14px;
	font-weight: 600;
	color: #222;
	line-height: 1.4;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* Label */
.tr-label {
	display: block;
	padding: 4px 12px 12px;
	font-size: 13px;
	color: #999;
	line-height: 1.4;
}

/* =============================================
 * Navigation (same style as cf-nav-btn)
 * ============================================= */
.tr-nav-btn {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 10;
	width: 40px;
	height: 40px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #fff;
	border-radius: 50%;
	box-shadow: 0 2px 8px rgba(0,0,0,0.15);
	cursor: pointer;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.2s ease, visibility 0.2s ease;
	color: #333;
}

.tr-nav-btn svg {
	width: 20px;
	height: 20px;
}

.tr-nav-prev { left: 12px; }
.tr-nav-next { right: 12px; }

.tr-ranking-widget:hover .tr-nav-btn:not(.swiper-button-disabled) {
	opacity: 1;
	visibility: visible;
}

.tr-nav-btn:hover {
	box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.tr-nav-btn.swiper-button-disabled {
	opacity: 0 !important;
	pointer-events: none;
}

/* Responsive */
@media (max-width: 768px) {
	.tr-header {
		flex-direction: column;
	}
	.tr-more {
		margin-top: 8px;
	}

	.tr-nav-btn {
		opacity: 1;
		visibility: visible;
		width: 28px;
		height: 28px;
	}

	.tr-nav-btn svg {
		width: 16px;
		height: 16px;
	}

	.tr-nav-prev { left: 4px; }
	.tr-nav-next { right: 4px; }

	.tr-nav-btn.swiper-button-disabled {
		opacity: 0.3 !important;
		visibility: visible !important;
		pointer-events: none;
	}
}
