/**
 * Merchandise Manager Styles
 */

.mlet-merchandise-wrap {
	max-width: 1400px;
	margin: 40px auto;
	padding: 0 20px;
	font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
}

/* Header Section */
.mlet-header-section {
	background: linear-gradient(135deg, #FF6B6B 0%, #FFE66D 100%);
	padding: 40px;
	border-radius: 20px;
	margin-bottom: 30px;
	box-shadow: 0 10px 40px rgba(255, 107, 107, 0.3);
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 20px;
	flex-wrap: wrap;
}

.mlet-header-content {
	display: flex;
	align-items: center;
	gap: 25px;
	flex: 1;
}

.mlet-header-icon {
	font-size: 72px;
	line-height: 1;
	animation: bounce 2s infinite;
}

@keyframes bounce {
	0%, 100% { transform: translateY(0); }
	50% { transform: translateY(-10px); }
}

.mlet-header-text h1 {
	margin: 0 0 8px 0;
	font-size: 36px;
	font-weight: 800;
	color: #1a1a1a;
}

.mlet-subtitle {
	margin: 0;
	font-size: 16px;
	color: #333;
	opacity: 0.9;
}

.mlet-header-actions {
	display: flex;
	gap: 10px;
}

/* Actions Bar */
.mlet-actions-bar {
	background: white;
	padding: 20px 25px;
	border-radius: 16px;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
	margin-bottom: 30px;
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 20px;
	flex-wrap: wrap;
}

.mlet-actions-right {
	display: flex;
	gap: 15px;
	align-items: center;
	flex-wrap: wrap;
}

/* Search Box */
.mlet-search-box {
	position: relative;
}

.mlet-search-icon {
	position: absolute;
	left: 15px;
	top: 50%;
	transform: translateY(-50%);
	font-size: 18px;
	pointer-events: none;
}

#search-products {
	padding: 10px 15px 10px 45px;
	border: 2px solid #e0e0e0;
	border-radius: 8px;
	font-size: 14px;
	min-width: 250px;
	transition: all 0.3s;
}

#search-products:focus {
	outline: none;
	border-color: #FF6B6B;
	box-shadow: 0 0 0 3px rgba(255, 107, 107, 0.1);
}

/* Products Grid */
.mlet-products-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
	gap: 25px;
	margin-bottom: 30px;
}

.mlet-product-card {
	background: white;
	border-radius: 16px;
	overflow: hidden;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
	transition: all 0.3s ease;
	animation: fadeInUp 0.5s ease;
}

@keyframes fadeInUp {
	from {
		opacity: 0;
		transform: translateY(30px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.mlet-product-card:hover {
	transform: translateY(-5px);
	box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}

.mlet-product-image {
	position: relative;
	width: 100%;
	height: 240px;
	background: #f5f5f5;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
}

.mlet-product-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.mlet-product-image-placeholder {
	font-size: 64px;
	opacity: 0.3;
}

.mlet-product-badge {
	position: absolute;
	top: 10px;
	right: 10px;
	background: #FF6B6B;
	color: white;
	padding: 5px 12px;
	border-radius: 20px;
	font-size: 12px;
	font-weight: 600;
	box-shadow: 0 2px 8px rgba(255, 107, 107, 0.4);
}

.mlet-product-badge.sale {
	background: #FF6B6B;
}

.mlet-product-badge.draft {
	background: #999;
}

.mlet-product-body {
	padding: 20px;
}

.mlet-product-title {
	font-size: 18px;
	font-weight: 700;
	color: #1a1a1a;
	margin: 0 0 10px 0;
	line-height: 1.4;
}

.mlet-product-price {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-bottom: 15px;
}

.mlet-price-regular {
	font-size: 24px;
	font-weight: 700;
	color: #FF6B6B;
}

.mlet-price-old {
	font-size: 16px;
	color: #999;
	text-decoration: line-through;
}

.mlet-product-meta {
	display: flex;
	gap: 15px;
	margin-bottom: 15px;
	padding-bottom: 15px;
	border-bottom: 1px solid #f0f0f0;
}

.mlet-meta-item {
	display: flex;
	align-items: center;
	gap: 5px;
	font-size: 13px;
	color: #666;
}

.mlet-product-events {
	margin-bottom: 15px;
}

.mlet-events-label {
	font-size: 12px;
	font-weight: 600;
	color: #666;
	margin-bottom: 5px;
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.mlet-events-list {
	display: flex;
	flex-wrap: wrap;
	gap: 5px;
}

.mlet-event-tag {
	background: #e3f2fd;
	color: #1976d2;
	padding: 4px 10px;
	border-radius: 12px;
	font-size: 12px;
	font-weight: 500;
}

.mlet-product-actions {
	display: flex;
	gap: 10px;
}

.mlet-product-actions button {
	flex: 1;
	padding: 10px;
	border: none;
	border-radius: 8px;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	transition: all 0.3s;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 5px;
}

.mlet-btn-edit {
	background: #FFE66D;
	color: #333;
}

.mlet-btn-edit:hover {
	background: #FFD93D;
	transform: scale(1.05);
}

.mlet-btn-delete {
	background: #ff4444;
	color: white;
}

.mlet-btn-delete:hover {
	background: #cc0000;
	transform: scale(1.05);
}

/* Buttons */
.mlet-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 12px 24px;
	border: none;
	border-radius: 10px;
	font-size: 15px;
	font-weight: 600;
	cursor: pointer;
	transition: all 0.3s ease;
	text-decoration: none;
	color: inherit;
}

.mlet-btn-primary {
	background: linear-gradient(135deg, #FF6B6B 0%, #FF8E53 100%);
	color: white;
	box-shadow: 0 4px 15px rgba(255, 107, 107, 0.4);
}

.mlet-btn-primary:hover {
	transform: translateY(-2px);
	box-shadow: 0 6px 20px rgba(255, 107, 107, 0.6);
}

.mlet-btn-secondary {
	background: white;
	color: #333;
	border: 2px solid #e0e0e0;
}

.mlet-btn-secondary:hover {
	background: #f5f5f5;
	border-color: #ccc;
}

.mlet-icon {
	font-size: 18px;
	line-height: 1;
}

/* Select */
.mlet-select {
	padding: 10px 15px;
	border: 2px solid #e0e0e0;
	border-radius: 8px;
	font-size: 14px;
	background: white;
	cursor: pointer;
	transition: all 0.3s;
}

.mlet-select:focus {
	outline: none;
	border-color: #FF6B6B;
}

/* Modal */
.mlet-modal {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 9999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
}

.mlet-modal-backdrop {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.7);
	backdrop-filter: blur(5px);
}

.mlet-modal-content {
	position: relative;
	background: white;
	border-radius: 20px;
	max-width: 900px;
	width: 100%;
	max-height: 90vh;
	overflow: hidden;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
	z-index: 1;
	animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
	from {
		opacity: 0;
		transform: translateY(-50px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.mlet-modal-header {
	padding: 25px 30px;
	background: linear-gradient(135deg, #FF6B6B 0%, #FFE66D 100%);
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.mlet-modal-header h3 {
	margin: 0;
	font-size: 24px;
	font-weight: 700;
	color: #1a1a1a;
}

.mlet-modal-close {
	background: white;
	border: none;
	width: 36px;
	height: 36px;
	border-radius: 50%;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all 0.3s;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.mlet-modal-close:hover {
	transform: rotate(90deg);
	background: #ff4444;
	color: white;
}

.mlet-modal-body {
	padding: 30px;
	max-height: calc(90vh - 160px);
	overflow-y: auto;
}

.mlet-modal-footer {
	padding: 20px 30px;
	border-top: 2px solid #f0f0f0;
	display: flex;
	justify-content: flex-end;
	gap: 15px;
	background: #fafafa;
}

/* Form Sections */
.mlet-form-section {
	margin-bottom: 30px;
	padding-bottom: 30px;
	border-bottom: 2px solid #f0f0f0;
}

.mlet-form-section:last-child {
	border-bottom: none;
	margin-bottom: 0;
	padding-bottom: 0;
}

.mlet-form-section h4 {
	margin: 0 0 20px 0;
	font-size: 18px;
	font-weight: 700;
	color: #FF6B6B;
	display: flex;
	align-items: center;
	gap: 10px;
}

.mlet-form-row {
	display: grid;
	gap: 20px;
	margin-bottom: 20px;
}

.mlet-form-row-2 {
	grid-template-columns: repeat(2, 1fr);
}

.mlet-form-row-3 {
	grid-template-columns: repeat(3, 1fr);
}

.mlet-form-group {
	display: flex;
	flex-direction: column;
}

.mlet-form-group label {
	margin-bottom: 8px;
	font-weight: 600;
	color: #333;
	font-size: 14px;
}

.mlet-form-group small {
	margin-top: 5px;
	font-size: 12px;
	color: #999;
}

.mlet-input,
.mlet-textarea {
	padding: 12px 15px;
	border: 2px solid #e0e0e0;
	border-radius: 10px;
	font-size: 14px;
	font-family: inherit;
	transition: all 0.3s;
}

.mlet-input:focus,
.mlet-textarea:focus {
	outline: none;
	border-color: #FF6B6B;
	box-shadow: 0 0 0 3px rgba(255, 107, 107, 0.1);
}

.mlet-textarea {
	resize: vertical;
}

/* Image Upload */
.mlet-image-upload {
	border: 2px dashed #e0e0e0;
	border-radius: 10px;
	padding: 20px;
	text-align: center;
	transition: all 0.3s;
}

.mlet-image-upload:hover {
	border-color: #FF6B6B;
	background: rgba(255, 107, 107, 0.05);
}

.mlet-image-preview {
	position: relative;
	display: inline-block;
	margin-bottom: 15px;
}

.mlet-image-preview img {
	max-width: 200px;
	max-height: 200px;
	border-radius: 10px;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.mlet-remove-image {
	position: absolute;
	top: -10px;
	right: -10px;
	background: #ff4444;
	color: white;
	border: 3px solid white;
	width: 30px;
	height: 30px;
	border-radius: 50%;
	font-size: 20px;
	line-height: 1;
	cursor: pointer;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.mlet-upload-btn {
	background: white;
	border: 2px solid #FF6B6B;
	color: #FF6B6B;
	padding: 12px 24px;
	border-radius: 10px;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	transition: all 0.3s;
}

.mlet-upload-btn:hover {
	background: #FF6B6B;
	color: white;
	transform: scale(1.05);
}

/* Gallery */
.mlet-gallery-upload {
	border: 2px dashed #e0e0e0;
	border-radius: 10px;
	padding: 20px;
}

.mlet-gallery-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
	gap: 10px;
	margin-bottom: 15px;
}

.mlet-gallery-item {
	position: relative;
	aspect-ratio: 1;
}

.mlet-gallery-item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: 8px;
}

/* Events Selector */
.mlet-events-selector {
	border: 2px solid #e0e0e0;
	border-radius: 10px;
	padding: 20px;
	max-height: 300px;
	overflow-y: auto;
}

.mlet-event-checkbox {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 12px;
	border-radius: 8px;
	margin-bottom: 8px;
	transition: all 0.3s;
}

.mlet-event-checkbox:hover {
	background: rgba(255, 107, 107, 0.05);
}

.mlet-event-checkbox input[type="checkbox"] {
	width: 20px;
	height: 20px;
	cursor: pointer;
}

.mlet-event-checkbox label {
	cursor: pointer;
	flex: 1;
	margin: 0;
	font-size: 14px;
}

/* Loading & Empty States */
.mlet-loading-state {
	grid-column: 1 / -1;
	text-align: center;
	padding: 60px 20px;
}

.mlet-spinner {
	width: 50px;
	height: 50px;
	margin: 0 auto 20px;
	border: 4px solid #f3f3f3;
	border-top: 4px solid #FF6B6B;
	border-radius: 50%;
	animation: spin 1s linear infinite;
}

@keyframes spin {
	0% { transform: rotate(0deg); }
	100% { transform: rotate(360deg); }
}

.mlet-empty-state {
	text-align: center;
	padding: 80px 20px;
	background: white;
	border-radius: 20px;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.mlet-empty-icon {
	font-size: 80px;
	margin-bottom: 20px;
	opacity: 0.5;
}

.mlet-empty-state h3 {
	margin: 0 0 10px 0;
	font-size: 28px;
	font-weight: 700;
	color: #1a1a1a;
}

.mlet-empty-state p {
	margin: 0 0 30px 0;
	font-size: 16px;
	color: #666;
}

/* Responsive */
@media (max-width: 768px) {
	.mlet-merchandise-wrap {
		padding: 0 15px;
	}
	
	.mlet-header-section {
		padding: 30px 20px;
	}
	
	.mlet-header-text h1 {
		font-size: 28px;
	}
	
	.mlet-products-grid {
		grid-template-columns: 1fr;
	}
	
	.mlet-form-row-2,
	.mlet-form-row-3 {
		grid-template-columns: 1fr;
	}
	
	.mlet-actions-bar {
		flex-direction: column;
		align-items: stretch;
	}
	
	.mlet-actions-right {
		flex-direction: column;
	}
	
	#search-products {
		min-width: 100%;
	}
}
