* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

body {
	font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	height: 100vh;
	overflow-x: hidden;
	color: #333;
	display: flex;
	flex-direction: column;
}

.container {
	max-width: 1400px;
	width: 95%;
	margin: 0 auto;
	padding: 10px;
	height: 100vh;
	display: flex;
	flex-direction: column;
}

header {
	text-align: center;
	padding: 15px 0;
	color: white;
	flex-shrink: 0;
}

header h1 {
	font-size: 1.8rem;
	margin-bottom: 5px;
	text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

header p {
	font-size: 0.9rem;
	opacity: 0.9;
}

main {
	background: white;
	border-radius: 15px;
	padding: 20px;
	box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
	flex: 1;
	display: flex;
	flex-direction: column;
	overflow: hidden;
}

.upload-area {
	margin-bottom: 15px;
	flex-shrink: 0;
}

.upload-zone {
	border: 2px dashed #ddd;
	border-radius: 10px;
	padding: 20px;
	text-align: center;
	cursor: pointer;
	transition: all 0.3s ease;
	background: #fafafa;
}

.upload-zone:hover {
	border-color: #667eea;
	background: #f0f4ff;
	transform: translateY(-2px);
}

.upload-zone.dragover {
	border-color: #667eea;
	background: #e8f2ff;
	transform: scale(1.02);
}

.upload-icon {
	font-size: 2rem;
	margin-bottom: 10px;
}

.upload-zone h3 {
	font-size: 1.1rem;
	margin-bottom: 5px;
	color: #333;
}

.upload-zone p {
	color: #666;
	font-size: 0.85rem;
}

.thumbnails-container {
	margin-bottom: 15px;
	flex: 1;
	display: flex;
	flex-direction: column;
	overflow: hidden;
}

.thumbnails-container h3 {
	margin-bottom: 10px;
	color: #333;
	font-size: 1rem;
	flex-shrink: 0;
}

.thumbnails-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
	gap: 12px;
	overflow-y: auto;
	padding: 5px;
	flex: 1;
}

.thumbnail-item {
	position: relative;
	border-radius: 8px;
	overflow: hidden;
	box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
	transition: transform 0.3s ease;
	background: white;
}

.thumbnail-item:hover {
	transform: translateY(-3px);
	box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.thumbnail-item img {
	width: 100%;
	height: 100px;
	object-fit: contain;
	background: #f8f9fa;
}

.thumbnail-info {
	padding: 6px;
	background: white;
}

.thumbnail-name {
	font-size: 0.75rem;
	font-weight: 500;
	margin-bottom: 3px;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.thumbnail-size {
	font-size: 0.7rem;
	color: #666;
}

.thumbnail-remove {
	position: absolute;
	top: 4px;
	right: 4px;
	background: rgba(255, 255, 255, 0.9);
	border: none;
	border-radius: 50%;
	width: 20px;
	height: 20px;
	cursor: pointer;
	font-size: 0.9rem;
	color: #ff4757;
	transition: all 0.3s ease;
}

.thumbnail-remove:hover {
	background: #ff4757;
	color: white;
	transform: scale(1.1);
}

.actions {
	display: flex;
	gap: 10px;
	justify-content: center;
	flex-wrap: wrap;
	margin-bottom: 15px;
	flex-shrink: 0;
}

.btn {
	display: flex;
	align-items: center;
	gap: 5px;
	padding: 8px 16px;
	border: none;
	border-radius: 18px;
	font-size: 0.85rem;
	font-weight: 500;
	cursor: pointer;
	transition: all 0.3s ease;
	text-decoration: none;
	min-width: 120px;
	justify-content: center;
}

.btn:disabled {
	opacity: 0.5;
	cursor: not-allowed;
	transform: none !important;
}

.btn-primary {
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: white;
}

.btn-primary:hover:not(:disabled) {
	transform: translateY(-2px);
	box-shadow: 0 6px 15px rgba(102, 126, 234, 0.4);
}

.btn-success {
	background: linear-gradient(135deg, #4ecdc4 0%, #44a08d 100%);
	color: white;
}

.btn-success:hover:not(:disabled) {
	transform: translateY(-2px);
	box-shadow: 0 6px 15px rgba(78, 205, 196, 0.4);
}

.btn-secondary {
	background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
	color: #333;
}

.btn-secondary:hover {
	transform: translateY(-2px);
	box-shadow: 0 6px 15px rgba(252, 182, 159, 0.4);
}

.btn-icon {
	font-size: 0.9rem;
}

.progress-container {
	margin-top: 10px;
	flex-shrink: 0;
}

.progress-bar {
	width: 100%;
	height: 14px;
	background: #f0f0f0;
	border-radius: 7px;
	overflow: hidden;
	margin-bottom: 6px;
}

.progress-fill {
	height: 100%;
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	border-radius: 7px;
	transition: width 0.3s ease;
	width: 0%;
}

.progress-text {
	text-align: center;
	font-weight: 500;
	color: #333;
	font-size: 0.8rem;
}

@media (max-width: 768px) {
	.container {
		padding: 8px;
	}

	main {
		padding: 15px;
	}

	header h1 {
		font-size: 1.6rem;
	}

	header p {
		font-size: 0.8rem;
	}

	.upload-zone {
		padding: 15px;
	}

	.thumbnails-grid {
		grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
		gap: 10px;
	}

	.thumbnail-item img {
		height: 80px;
	}

	.actions {
		flex-direction: column;
		align-items: center;
	}

	.btn {
		width: 100%;
		max-width: 250px;
	}
}
