/**
 * Product Archive Table Styles
 */

.rec-product-archive-wrapper {
	max-width: 1400px;
	margin: 0 auto;
	padding: 40px 20px;
}

.rec-product-archive-container {
	background: #fff;
}

.rec-archive-title {
	font-size: 32px;
	font-weight: 600;
	color: #1e293b;
	margin-bottom: 30px;
}

/* Filters Bar */
.rec-archive-filters-bar {
	background: #1e3a8a;
	padding: 15px 20px;
	border-radius: 8px;
	display: flex;
	justify-content: space-between;
	align-items: center;
	flex-wrap: wrap;
	gap: 15px;
	margin-bottom: 30px;
}

.rec-filters-left {
	display: flex;
	align-items: center;
	gap: 20px;
	flex-wrap: wrap;
}

.rec-filter-checkbox {
	display: flex;
	align-items: center;
	gap: 8px;
	color: #fff;
	cursor: pointer;
	font-size: 14px;
}

.rec-filter-checkbox input[type="checkbox"] {
	width: 18px;
	height: 18px;
	cursor: pointer;
	accent-color: #f97316;
}

.rec-filters-right {
	display: flex;
	align-items: center;
	gap: 15px;
	flex-wrap: wrap;
}

.rec-quick-dropdown-filter {
	position: relative;
}

.rec-quick-dropdown-button {
	background: transparent;
	border: 1px solid rgba(255, 255, 255, 0.3);
	color: #fff;
	padding: 8px 15px;
	border-radius: 4px;
	cursor: pointer;
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 14px;
	transition: all 0.3s;
}

.rec-quick-dropdown-button:hover {
	background: rgba(255, 255, 255, 0.1);
	border-color: rgba(255, 255, 255, 0.5);
}

.rec-quick-dropdown-arrow {
	transition: transform 0.3s;
}

.rec-quick-dropdown-filter.active .rec-quick-dropdown-arrow {
	transform: rotate(180deg);
}

.rec-quick-dropdown-content {
	position: absolute;
	top: 100%;
	left: 0;
	background: #fff;
	border: 1px solid #e2e8f0;
	border-radius: 4px;
	box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
	min-width: 250px;
	max-height: 300px;
	overflow-y: auto;
	z-index: 1000;
	display: none;
	margin-top: 5px;
}

.rec-quick-dropdown-filter.active .rec-quick-dropdown-content {
	display: block;
}

.rec-quick-dropdown-search {
	padding: 10px;
	border-bottom: 1px solid #e2e8f0;
}

.rec-quick-dropdown-search-input {
	width: 100%;
	padding: 8px;
	border: 1px solid #cbd5e1;
	border-radius: 4px;
	font-size: 14px;
}

.rec-quick-dropdown-options {
	max-height: 250px;
	overflow-y: auto;
}

.rec-quick-dropdown-option {
	display: flex;
	align-items: center;
	padding: 10px 15px;
	cursor: pointer;
	transition: background 0.2s;
}

.rec-quick-dropdown-option:hover {
	background: #f1f5f9;
}

.rec-quick-dropdown-option input[type="checkbox"] {
	margin-right: 10px;
	accent-color: #f97316;
}

.rec-archive-search {
	display: flex;
	align-items: center;
	gap: 0;
	background: #fff;
	border-radius: 4px;
	overflow: hidden;
}

.rec-archive-search-input {
	padding: 8px 15px;
	border: 1px solid rgba(255, 255, 255, 0.3);
	border-right: none;
	border-radius: 4px 0 0 4px;
	font-size: 14px;
	width: 200px;
}

.rec-archive-search-button {
	background: #f97316;
	border: none;
	padding: 8px 12px;
	cursor: pointer;
	color: #fff;
	border-radius: 0 4px 4px 0;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.3s;
}

.rec-archive-search-button:hover {
	background: #ea580c;
}

/* Products Table */
.rec-archive-products-table-wrapper {
	position: relative;
}

.rec-archive-loading {
	text-align: center;
	padding: 40px;
}

.rec-spinner {
	border: 4px solid #f3f4f6;
	border-top: 4px solid #f97316;
	border-radius: 50%;
	width: 40px;
	height: 40px;
	animation: spin 1s linear infinite;
	margin: 0 auto 15px;
}

@keyframes spin {
	0% { transform: rotate(0deg); }
	100% { transform: rotate(360deg); }
}

.rec-archive-products-table-container {
	overflow-x: auto;
	border: 1px solid #e2e8f0;
	border-radius: 8px;
}

.rec-archive-products-table {
	width: 100%;
	border-collapse: collapse;
	background: #fff;
}

.rec-archive-products-table thead {
	background: #f8fafc;
}

.rec-archive-products-table th {
	padding: 15px;
	text-align: left;
	font-weight: 600;
	color: #1e293b;
	border-bottom: 2px solid #e2e8f0;
	font-size: 14px;
	white-space: nowrap;
}

.rec-archive-products-table th.sortable {
	cursor: pointer;
	user-select: none;
	position: relative;
	padding-right: 30px;
}

.rec-archive-products-table th.sortable:hover {
	background: #f1f5f9;
}

.rec-sort-indicator {
	position: absolute;
	right: 10px;
	top: 50%;
	transform: translateY(-50%);
	color: #94a3b8;
}

.rec-archive-products-table th.sortable.active .rec-sort-indicator {
	color: #f97316;
}

.rec-archive-products-table td {
	padding: 15px;
	border-bottom: 1px solid #e2e8f0;
	font-size: 14px;
	color: #475569;
}

.rec-archive-products-table tbody tr:hover {
	background: #f8fafc;
}

.rec-archive-products-table tbody tr:last-child td {
	border-bottom: none;
}

/* Product Image Cell */
.rec-product-image-cell {
	width: 60px;
	height: 60px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #f8fafc;
	border-radius: 4px;
	overflow: hidden;
}

.rec-product-thumb {
	max-width: 100%;
	max-height: 100%;
	object-fit: cover;
}

/* Product Link */
.rec-product-link {
	color: #2563eb;
	text-decoration: none;
	font-weight: 500;
	transition: color 0.2s;
}

.rec-product-link:hover {
	color: #1d4ed8;
	text-decoration: underline;
}

/* RoHS Badge */
.rec-rohs-badge {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	padding: 4px 8px;
	background: #ecfdf5;
	border-radius: 4px;
	color: #10b981;
	font-size: 12px;
	font-weight: 500;
}

.rec-rohs-badge svg {
	width: 16px;
	height: 16px;
}

/* Stock Info */
.rec-stock-info {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 8px;
}

.rec-stock-label {
	color: #64748b;
	font-size: 13px;
}

.rec-stock-value {
	font-weight: 600;
	font-size: 14px;
}

.rec-stock-value.in-stock {
	color: #10b981;
}

.rec-stock-value.out-of-stock {
	color: #f97316;
}

/* Inquiry Button */
.rec-inquiry-btn {
	background: #2563eb;
	color: #fff;
	border: none;
	padding: 6px 15px;
	border-radius: 4px;
	cursor: pointer;
	font-size: 13px;
	font-weight: 500;
	transition: background 0.3s;
}

.rec-inquiry-btn:hover {
	background: #1d4ed8;
}

/* Quantity */
.rec-quantity-value {
	font-weight: 600;
	color: #1e293b;
}

/* MPQ */
.rec-mpq-value {
	color: #64748b;
	font-size: 13px;
}

/* No Products */
.rec-no-products {
	text-align: center;
	padding: 40px;
	color: #94a3b8;
}

/* Pagination */
.rec-archive-pagination {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 15px;
	margin-top: 30px;
	padding: 20px;
}

.rec-pagination-btn {
	background: #f97316;
	color: #fff;
	border: none;
	padding: 10px 20px;
	border-radius: 4px;
	cursor: pointer;
	font-size: 14px;
	font-weight: 500;
	transition: background 0.3s;
}

.rec-pagination-btn:hover:not(:disabled) {
	background: #ea580c;
}

.rec-pagination-btn:disabled {
	background: #cbd5e1;
	cursor: not-allowed;
	opacity: 0.6;
}

.rec-pagination-info {
	color: #64748b;
	font-size: 14px;
}

/* Responsive */
@media (max-width: 768px) {
	.rec-archive-filters-bar {
		flex-direction: column;
		align-items: stretch;
	}
	
	.rec-filters-left,
	.rec-filters-right {
		width: 100%;
		justify-content: flex-start;
	}
	
	.rec-archive-search {
		width: 100%;
	}
	
	.rec-archive-search-input {
		flex: 1;
	}
	
	.rec-archive-products-table-container {
		overflow-x: scroll;
	}
	
	.rec-archive-products-table {
		min-width: 800px;
	}
}

