.popup-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-color: rgba(0, 0, 0, 0.8);
	z-index: 9999;
	display: flex;
	justify-content: center;
	align-items: center;
	opacity: 0;
	visibility: hidden;
	transition: all 0.3s ease;
	backdrop-filter: blur(3px);
}

.popup-overlay.popup-show {
	opacity: 1;
	visibility: visible;
}

.popup-overlay.popup-fade-out {
	opacity: 0;
	visibility: hidden;
}

.popup-container {
	position: relative;
	max-width: 90vw;
	max-height: 90vh;
	background: white;
	border-radius: 15px;
	box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
	overflow: hidden;
	transform: scale(0.8);
	transition: transform 0.3s ease;
}

.popup-overlay.popup-show .popup-container {
	transform: scale(1);
}

.popup-close {
	position: absolute;
	top: 15px;
	right: 15px;
	width: 40px;
	height: 40px;
	background: rgba(255, 255, 255, 0.9);
	border: none;
	border-radius: 50%;
	cursor: pointer;
	z-index: 10001;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #333;
	transition: all 0.2s ease;
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

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

.popup-close:active {
	transform: scale(0.95);
}

.popup-content {
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
}

.popup-image {
	width: 100%;
	height: auto;
	max-width: 1080px;
	max-height: 80vh;
	object-fit: contain;
	display: block;
}

@media (max-width: 480px) {
	.popup-container {
		max-width: 95vw;
		max-height: 85vh;
		margin: 20px;
		border-radius: 10px;
	}
	
	.popup-close {
		top: 10px;
		right: 10px;
		width: 35px;
		height: 35px;
	}
	
	.popup-image {
		max-height: 75vh;
	}
}

@media (min-width: 481px) and (max-width: 768px) {
	.popup-container {
		max-width: 85vw;
		max-height: 80vh;
	}
	
	.popup-image {
		max-height: 70vh;
	}
}

@media (min-width: 769px) and (max-width: 1024px) {
	.popup-container {
		max-width: 80vw;
		max-height: 85vh;
	}
	
	.popup-image {
		max-height: 75vh;
	}
}

@media (min-width: 1025px) {
	.popup-container {
		max-width: 70vw;
		max-height: 90vh;
	}
	
	.popup-image {
		max-height: 80vh;
	}
}

@media (min-width: 1400px) {
	.popup-container {
		max-width: 60vw;
	}
}

@media (max-height: 500px) and (orientation: landscape) {
	.popup-container {
		max-height: 95vh;
		max-width: 80vw;
	}
	
	.popup-image {
		max-height: 85vh;
	}
}

@media (prefers-reduced-motion: reduce) {
	.popup-overlay,
	.popup-container,
	.popup-close {
		transition: none;
	}
}