/* ==================================================================
   MODERN LIGHTBOX SLIDER - Adobe Stock Inspired Design
   ================================================================== */

/* Main Container */
#LightboxSlider {
	position: fixed;
	left: 20px;
	right: 20px;
	bottom: 0;
	width: auto;
	background: #ffffff;
	border: 1px solid #e5e5e5;
	border-top-left-radius: 12px;
	border-top-right-radius: 12px;
	box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
	z-index: 1000;
	font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

/* Screen reader only content */
.sr-only {
	position: absolute !important;
	width: 1px !important;
	height: 1px !important;
	padding: 0 !important;
	margin: -1px !important;
	overflow: hidden !important;
	clip: rect(0, 0, 0, 0) !important;
	white-space: nowrap !important;
	border: 0 !important;
}

/* ==================================================================
   TABS SECTION
   ================================================================== */
.lightbox-tabs {
	display: flex;
	background: #f8f9fa;
	border-bottom: 1px solid #e5e5e5;
	border-top-left-radius: 12px;
	border-top-right-radius: 12px;
	overflow: hidden;
}

/* When slider is closed (no menu present), style tabs as standalone */
#LightboxSlider:not(:has(.lightbox-menu)) .lightbox-tabs {
	border-bottom-left-radius: 12px;
	border-bottom-right-radius: 12px;
	border-bottom: 1px solid #e5e5e5;
}

.lightbox-tab {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 12px 20px;
	background: transparent;
	border: none;
	border-bottom: 3px solid transparent;
	color: #666f76;
	font-size: 14px;
	font-weight: 500;
	cursor: pointer;
	transition: all 0.2s ease;
	position: relative;
}

.lightbox-tab:hover {
	color: #495057;
	background: rgba(0, 0, 0, 0.02);
}

.lightbox-tab.active {
	color: #000000;
	border-bottom-color: #000000;
	background: #ffffff;
}

.lightbox-tab.active .item-count {
	background: #000000;
	color: white;
}

.lightbox-tab:focus {
	outline: 2px solid #000000;
	outline-offset: -2px;
	z-index: 1;
}

.lightbox-tab i {
	font-size: 16px;
}

.item-count {
	background: #666f76;
	color: white;
	border-radius: 10px;
	padding: 2px 8px;
	font-size: 12px;
	font-weight: 600;
	min-width: 20px;
	text-align: center;
	transition: all 0.2s ease;
}

/* ==================================================================
   MENU SECTION
   ================================================================== */
.lightbox-menu {
	background: #ffffff;
	border-bottom: 1px solid #e5e5e5;
}

.menu-panel {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 12px 20px;
	min-height: 56px;
}

.menu-controls {
	display: flex;
	align-items: center;
	gap: 16px;
}

.menu-actions {
	display: flex;
	align-items: center;
	gap: 16px;
}

/* ==================================================================
   FORM CONTROLS
   ================================================================== */
.lightbox-select {
	background: #ffffff;
	border: 1px solid #ced4da;
	border-radius: 6px;
	padding: 8px 12px;
	font-size: 14px;
	color: #495057;
	min-width: 200px;
	transition: all 0.2s ease;
}

.lightbox-select:focus {
	outline: none;
	border-color: #000000;
	box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.1);
}

.lightbox-select:hover {
	border-color: #adb5bd;
}

.new-lightbox-btn {
	display: flex;
	align-items: center;
	gap: 6px;
	background: #000000;
	color: white;
	border: none;
	border-radius: 6px;
	padding: 8px 16px;
	font-size: 14px;
	font-weight: 500;
	cursor: pointer;
	transition: all 0.2s ease;
}

.new-lightbox-btn:hover {
	background: #333333;
	transform: translateY(-1px);
}

.new-lightbox-btn:focus {
	outline: 2px solid #000000;
	outline-offset: 2px;
}

.new-lightbox-btn:active {
	transform: translateY(0);
}

.cart-info {
	display: flex;
	align-items: center;
	gap: 8px;
	color: #495057;
	font-size: 14px;
	font-weight: 500;
}

.cart-info i {
	color: #000000;
}

.slider-toggle {
	background: transparent;
	border: 1px solid #ced4da;
	border-radius: 6px;
	padding: 8px;
	color: #666f76;
	cursor: pointer;
	transition: all 0.2s ease;
	width: 40px;
	height: 40px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.slider-toggle:hover {
	background: #f8f9fa;
	border-color: #adb5bd;
	color: #495057;
}

.slider-toggle:focus {
	outline: 2px solid #000000;
	outline-offset: 2px;
}

.slider-toggle i {
	font-size: 16px;
	transition: transform 0.2s ease;
}

/* ==================================================================
   ARROW NAVIGATION
   ================================================================== */
.arrow-nav {
	display: flex;
	align-items: center;
	gap: 12px;
}

.arrow-btn {
	background: transparent;
	border: 1px solid #ced4da;
	border-radius: 4px;
	padding: 6px 10px;
	color: #495057;
	cursor: pointer;
	transition: all 0.2s ease;
	display: flex;
	align-items: center;
	justify-content: center;
}

.arrow-btn:hover:not(:disabled) {
	background: #f8f9fa;
	border-color: #adb5bd;
	color: #000000;
}

.arrow-btn:focus {
	outline: 2px solid #000000;
	outline-offset: 2px;
}

.arrow-btn:disabled {
	opacity: 0.4;
	cursor: not-allowed;
}

.arrow-btn i {
	font-size: 12px;
}

.page-info {
	color: #666f76;
	font-size: 13px;
	font-weight: 500;
	min-width: 50px;
	text-align: center;
}

/* ==================================================================
   CONTENT AREA
   ================================================================== */
.lightbox-content {
	background: #f8f9fa;
	max-height: 0;
	overflow: hidden;
	transition: max-height 0.3s ease;
}

.lightbox-content.expanded {
	max-height: 200px;
}

.content-wrapper {
	padding: 20px;
	opacity: 1;
	transition: opacity 0.2s ease;
}

/* ==================================================================
   ITEM GRID
   ================================================================== */
.items-grid {
	display: flex;
	flex-wrap: nowrap;
	gap: 16px;
	max-height: 100px;
	overflow: hidden;
	padding: 4px;
	align-items: flex-start;
}

.item-card {
	width: 80px;
	height: 80px;
	flex-shrink: 0;
}

/* Custom scrollbar */
.items-grid::-webkit-scrollbar {
	width: 8px;
}

.items-grid::-webkit-scrollbar-track {
	background: #f1f1f1;
	border-radius: 4px;
}

.items-grid::-webkit-scrollbar-thumb {
	background: #c1c1c1;
	border-radius: 4px;
}

.items-grid::-webkit-scrollbar-thumb:hover {
	background: #a8a8a8;
}

.item-card {
	width: 80px;
	height: 80px;
	flex-shrink: 0;
	position: relative;
	background: white;
	border-radius: 8px;
	overflow: hidden;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
	transition: all 0.2s ease;
}

.item-card:hover {
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.item-card:focus-within {
	outline: 2px solid #000000;
	outline-offset: 2px;
}

.item-thumbnail {
	position: relative;
	aspect-ratio: 1;
	overflow: hidden;
}

.thumbnail-btn {
	width: 100%;
	height: 100%;
	background: transparent;
	border: none;
	padding: 0;
	cursor: pointer;
	transition: transform 0.2s ease;
}

.thumbnail-btn:hover {
	transform: scale(1.05);
}

.thumbnail-btn:focus {
	outline: none;
}

.thumbnail-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: all 0.2s ease;
}

.thumbnail-img.vertical {
	object-position: center;
}

.item-actions {
	position: absolute;
	top: 4px;
	right: 4px;
	opacity: 1;
	transition: opacity 0.2s ease;
}

.remove-btn {
	background: rgba(220, 53, 69, 0.9);
	color: white;
	border: none;
	border-radius: 50%;
	width: 24px;
	height: 24px;
	min-width: 14px !important;
    min-height: 14px !important;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: all 0.2s ease;
	backdrop-filter: blur(4px);
}

.remove-btn:hover {
	background: rgba(220, 53, 69, 1);
	transform: scale(1.1);
}

.remove-btn:focus {
	outline: 2px solid #A70606;
	outline-offset: 2px;
}

.remove-btn i {
	font-size: 10px;
}

/* ==================================================================
   EMPTY STATE
   ================================================================== */
.empty-state {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	/*padding: 40px 20px;*/
	color: #666f76;
	text-align: center;
	width: 100%;
}

.empty-state i {
	font-size: 48px;
	margin-bottom: 16px;
	opacity: 0.5;
}

.empty-state p {
	margin: 0;
	font-size: 16px;
	font-weight: 500;
}

/* ==================================================================
   RESPONSIVE DESIGN
   ================================================================== */

/* Mobile optimizations */
@media (max-width: 768px) {
	#LightboxSlider {
		font-size: 14px;
		left: 10px;
		right: 10px;
		bottom: 0;
		margin-bottom: 0;
		z-index: 1001;
	}

	.lightbox-tab {
		padding: 10px 16px;
		font-size: 13px;
	}

	.lightbox-tab i {
		font-size: 14px;
	}

	.menu-panel {
		padding: 8px 12px;
		flex-direction: row;
		flex-wrap: wrap;
		gap: 6px;
		align-items: center;
		min-height: auto;
	}

	.menu-controls {
		flex: 1;
		display: flex;
		align-items: center;
		gap: 8px;
		min-width: 0;
	}

	.menu-actions {
		display: flex;
		align-items: center;
		gap: 8px;
		flex-shrink: 0;
	}

	.lightbox-select {
		min-width: 0;
		flex: 1;
		max-width: 100%;
	}

	.lightbox-selector {
		flex: 1;
		min-width: 0;
		display: flex;
	}

	.new-lightbox-btn {
		flex-shrink: 0;
		padding: 6px 10px;
		font-size: 12px;
	}

	/* Hide "New" text on mobile, show only + icon */
	.new-lightbox-btn i {
		margin-right: 0;
	}

	.new-lightbox-btn .btn-text {
		display: none;
	}

	.arrow-nav {
		gap: 4px;
		order: -1;
		margin-right: auto;
	}

	.arrow-btn {
		padding: 4px 6px;
		min-width: 32px;
		height: 32px;
	}

	.page-info {
		font-size: 11px;
		min-width: 35px;
	}

	.slider-toggle {
		order: 1;
		width: 32px;
		height: 32px;
		padding: 6px;
	}

	.items-grid {
		grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
		gap: 12px;
		max-height: 120px;
	}

	.content-wrapper {
		padding: 16px;
	}

	.pagination {
		gap: 1px;
	}

	.pagination-btn,
	.pagination-current {
		min-width: 24px;
		height: 24px;
		font-size: 11px;
		padding: 0 4px;
	}
}

/* Tablet optimizations */
@media (min-width: 769px) and (max-width: 1024px) {
	.items-grid {
		grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
		gap: 14px;
	}
}

/* Large desktop optimizations */
@media (min-width: 1400px) {
	.items-grid {
		grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
		gap: 18px;
		max-height: 160px;
	}

	.lightbox-content.expanded {
		max-height: 220px;
	}
}

/* High contrast mode support */
@media (prefers-contrast: high) {
	.lightbox-tab,
	.pagination-btn,
	.slider-toggle,
	.lightbox-select {
		border-width: 2px;
	}

	.item-card {
		border: 2px solid #000;
	}
}

/* Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
	* {
		transition: none !important;
		animation: none !important;
	}
}

.img-slider-view {
	width: 100%;
    max-width: 640px;
    max-height: 640px;
}

/* Dark mode support */
/* @media (prefers-color-scheme: dark) {
	#LightboxSlider {
		background: #2d3748;
		border-top-color: #4a5568;
		color: #e2e8f0;
	}

	.lightbox-tabs {
		background: #1a202c;
		border-bottom-color: #4a5568;
	}

	.lightbox-tab {
		color: #a0aec0;
	}

	.lightbox-tab:hover {
		color: #e2e8f0;
		background: rgba(255, 255, 255, 0.05);
	}

	.lightbox-tab.active {
		background: #2d3748;
		color: #63b3ed;
	}

	.lightbox-menu {
		background: #2d3748;
		border-bottom-color: #4a5568;
	}

	.lightbox-content {
		background: #1a202c;
	}

	.item-card {
		background: #2d3748;
		box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
	}

	.lightbox-select {
		background: #2d3748;
		border-color: #4a5568;
		color: #e2e8f0;
	}

	.cart-info {
		color: #e2e8f0;
	}
} */