/**
 * VTD Issues Archive Styles
 *
 * Styles for the [vtd_issues_archive] and [vtd_issues_pagination] shortcodes.
 * Matches the front page issue layout with card-based design.
 */

/* ==========================================================================
   Container
   ========================================================================== */

.vtd-issues-archive {
	max-width: 1200px;
	margin: 0 auto;
}

/* ==========================================================================
   Filter Tabs
   ========================================================================== */

.vtd-issues-filter-tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 30px;
	padding-bottom: 20px;
	border-bottom: 1px solid #e0e0e0;
}

.vtd-issues-filter-tab {
	background: #f5f5f5;
	border: 1px solid #ddd;
	border-radius: 25px;
	padding: 10px 20px;
	font-size: 14px;
	font-weight: 500;
	color: #333;
	cursor: pointer;
	transition: all 0.2s ease;
}

.vtd-issues-filter-tab:hover {
	background: #e8e8e8;
	border-color: #ccc;
}

.vtd-issues-filter-tab.active {
	background: #333;
	border-color: #333;
	color: #fff;
}

.vtd-issues-filter-tab .count {
	opacity: 0.7;
	font-weight: 400;
}

/* ==========================================================================
   Issues Grid
   ========================================================================== */

.vtd-issues-grid {
	display: flex;
	flex-direction: column;
	gap: 30px;
}

/* ==========================================================================
   Issue Card
   ========================================================================== */

.vtd-issue-card {
	display: flex;
	gap: 30px;
	padding: 25px;
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 8px;
	transition: box-shadow 0.2s ease;
}

.vtd-issue-card:hover {
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Image Column */
.vtd-issue-card-image {
	flex: 0 0 200px;
	max-width: 200px;
}

.vtd-issue-card-image img {
	width: 100%;
	height: auto;
	border-radius: 4px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
	transition: transform 0.2s ease;
}

.vtd-issue-card-image a:hover img {
	transform: scale(1.02);
}

/* Content Column */
.vtd-issue-card-content {
	flex: 1;
	display: flex;
	flex-direction: column;
}

/* Header */
.vtd-issue-card-header {
	margin-bottom: 15px;
}

.vtd-issue-type-badge {
	display: inline-block;
	background: #f0f0f0;
	color: #666;
	font-size: 11px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	padding: 4px 10px;
	border-radius: 3px;
	margin-bottom: 8px;
}

.vtd-issue-title {
	font-size: 22px;
	font-weight: 600;
	color: #333;
	margin: 0 0 5px 0;
	line-height: 1.3;
}

.vtd-issue-date {
	font-size: 14px;
	color: #888;
}

/* Featured Articles */
.vtd-issue-articles {
	flex: 1;
	margin-bottom: 20px;
}

.vtd-issue-articles-label {
	display: block;
	font-size: 12px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: #999;
	margin-bottom: 10px;
}

.vtd-issue-articles-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.vtd-issue-article-item {
	padding: 8px 0;
	border-bottom: 1px solid #f0f0f0;
}

.vtd-issue-article-item:last-child {
	border-bottom: none;
}

.vtd-issue-article-title {
	display: block;
	font-size: 15px;
	font-weight: 500;
	color: #333;
	margin-bottom: 3px;
}

.vtd-issue-article-desc {
	display: block;
	font-size: 13px;
	color: #666;
	line-height: 1.4;
}

/* View Button */
.vtd-issue-view-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: #333;
	color: #fff;
	padding: 12px 24px;
	border-radius: 4px;
	text-decoration: none;
	font-size: 14px;
	font-weight: 500;
	transition: background 0.2s ease;
	align-self: flex-start;
}

.vtd-issue-view-btn:hover {
	background: #555;
	color: #fff;
}

.vtd-issue-view-arrow {
	font-size: 16px;
}

/* Empty State */
.vtd-issues-none {
	text-align: center;
	padding: 60px 20px;
	color: #888;
	font-size: 16px;
}

/* ==========================================================================
   Pagination
   ========================================================================== */

.vtd-issues-pagination {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 15px;
	margin-top: 40px;
	padding-top: 30px;
	border-top: 1px solid #e0e0e0;
}

.vtd-issues-page-numbers {
	display: flex;
	align-items: center;
	gap: 5px;
}

.vtd-issues-page-num,
.vtd-issues-page-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 40px;
	height: 40px;
	padding: 0 12px;
	background: #fff;
	border: 1px solid #ddd;
	border-radius: 4px;
	color: #333;
	font-size: 14px;
	text-decoration: none;
	transition: all 0.2s ease;
}

.vtd-issues-page-num:hover,
.vtd-issues-page-btn:hover {
	background: #f5f5f5;
	border-color: #ccc;
	color: #333;
}

.vtd-issues-page-num.active {
	background: #333;
	border-color: #333;
	color: #fff;
}

.vtd-issues-page-btn {
	padding: 0 16px;
	font-weight: 500;
}

.vtd-issues-page-ellipsis {
	color: #888;
	padding: 0 5px;
}

/* ==========================================================================
   Loading State
   ========================================================================== */

.vtd-issues-grid.loading {
	opacity: 0.5;
	pointer-events: none;
}

.vtd-issues-grid.loading::after {
	content: '';
	position: absolute;
	top: 50%;
	left: 50%;
	width: 40px;
	height: 40px;
	margin: -20px 0 0 -20px;
	border: 3px solid #f0f0f0;
	border-top-color: #333;
	border-radius: 50%;
	animation: vtd-issues-spin 0.8s linear infinite;
}

@keyframes vtd-issues-spin {
	to {
		transform: rotate(360deg);
	}
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 768px) {
	.vtd-issue-card {
		flex-direction: column;
		padding: 20px;
	}

	.vtd-issue-card-image {
		flex: none;
		max-width: 100%;
		text-align: center;
	}

	.vtd-issue-card-image img {
		max-width: 200px;
	}

	.vtd-issue-title {
		font-size: 18px;
	}

	.vtd-issues-filter-tabs {
		justify-content: center;
	}

	.vtd-issues-pagination {
		flex-wrap: wrap;
	}

	.vtd-issues-page-btn {
		order: 1;
		width: 100%;
		justify-content: center;
		margin-top: 10px;
	}

	.vtd-issues-page-btn.prev {
		order: 2;
	}

	.vtd-issues-page-btn.next {
		order: 3;
	}

	.vtd-issues-page-numbers {
		order: 1;
		width: 100%;
		justify-content: center;
	}
}

@media (max-width: 480px) {
	.vtd-issues-filter-tab {
		flex: 1;
		text-align: center;
		padding: 8px 12px;
		font-size: 13px;
	}

	.vtd-issue-card {
		padding: 15px;
	}

	.vtd-issue-article-title {
		font-size: 14px;
	}

	.vtd-issue-article-desc {
		font-size: 12px;
	}
}
