/**
 * Prescription Uploader Frontend Styles
 */

.prescription-uploader-form {
	background: #f9f9f9;
	border: 1px solid #ddd;
	border-radius: 4px;
	padding: 20px;
	margin: 20px 0;
}

.prescription-uploader-form h3 {
	margin-top: 0;
	color: #333;
	font-size: 18px;
	font-weight: 600;
}

.prescription-uploader-form .description {
	color: #666;
	font-size: 14px;
	margin-bottom: 15px;
}

.prescription-uploader-form .required-notice {
	color: #d9534f;
	font-size: 13px;
	margin-bottom: 15px;
}

.prescription-uploader-form .form-group {
	margin-bottom: 20px;
}

.prescription-uploader-form label {
	display: block;
	margin-bottom: 8px;
	font-weight: 500;
	color: #333;
}

.prescription-uploader-form .required {
	color: #d9534f;
	margin-left: 4px;
}

.pu-file-input {
	display: block;
	width: 100%;
	padding: 10px;
	border: 2px solid #ddd;
	border-radius: 4px;
	cursor: pointer;
	transition: border-color 0.3s ease;
}

.pu-file-input:hover {
	border-color: #999;
}

.pu-file-input:focus {
	outline: none;
	border-color: #0073aa;
	box-shadow: 0 0 0 3px rgba(0, 115, 170, 0.1);
}

.file-info {
	display: block;
	color: #666;
	font-size: 12px;
	margin-top: 8px;
}

.pu-file-list {
	margin: 15px 0;
	padding: 10px;
	background: #fff;
	border: 1px solid #ddd;
	border-radius: 4px;
	min-height: 40px;
}

.pu-file-item {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 10px;
	margin-bottom: 5px;
	background: #f5f5f5;
	border: 1px solid #e0e0e0;
	border-radius: 3px;
	transition: all 0.3s ease;
}

.pu-file-item:last-child {
	margin-bottom: 0;
}

.pu-file-item.uploaded {
	background: #e8f5e9;
	border-color: #4caf50;
}

.pu-file-item .file-name {
	flex: 1;
	word-break: break-word;
	color: #333;
	font-size: 14px;
	font-weight: 500;
}

.pu-file-item .file-size {
	color: #999;
	font-size: 12px;
	margin: 0 10px;
}

.pu-file-item .pu-remove-file {
	background: #f5f5f5;
	border: none;
	cursor: pointer;
	padding: 4px 8px;
	border-radius: 3px;
	transition: background-color 0.3s ease;
}

.pu-file-item .pu-remove-file:hover {
	background: #ddd;
}

.pu-file-item .pu-remove-file .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
	margin: 0;
}

#pu-upload-btn {
	background: #0073aa;
	color: white;
	border: none;
	padding: 10px 20px;
	border-radius: 4px;
	cursor: pointer;
	font-size: 14px;
	font-weight: 600;
	transition: background-color 0.3s ease;
}

#pu-upload-btn:hover:not(:disabled) {
	background: #005a87;
}

#pu-upload-btn:disabled {
	background: #999;
	cursor: not-allowed;
	opacity: 0.7;
}

.pu-upload-progress {
	margin-top: 15px;
	padding: 10px;
	background: #f5f5f5;
	border-radius: 4px;
}

.pu-upload-progress .progress-bar {
	display: block;
	width: 0%;
	height: 20px;
	background: #0073aa;
	border-radius: 3px;
	transition: width 0.3s ease;
	margin-bottom: 5px;
}

.pu-upload-progress .progress-text {
	display: block;
	text-align: center;
	font-size: 12px;
	color: #666;
	font-weight: 600;
}

.pu-notice {
	margin: 15px 0;
	padding: 12px 15px;
	border-radius: 4px;
	border-left: 4px solid;
	animation: slideIn 0.3s ease;
}

@keyframes slideIn {
	from {
		opacity: 0;
		transform: translateY(-10px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.pu-notice.pu-success {
	background: #e8f5e9;
	border-color: #4caf50;
	color: #2e7d32;
}

.pu-notice.pu-error {
	background: #ffebee;
	border-color: #f44336;
	color: #c62828;
}

/* WooCommerce order details page */
.woocommerce-prescription-uploads {
	margin: 20px 0;
	padding: 20px;
	background: #f9f9f9;
	border: 1px solid #ddd;
	border-radius: 4px;
}

.woocommerce-prescription-uploads h2 {
	margin-top: 0;
	font-size: 18px;
	color: #333;
}

.woocommerce-prescription-uploads ul {
	list-style: none;
	padding: 0;
	margin: 0;
}

.woocommerce-prescription-uploads li {
	padding: 8px 0;
	border-bottom: 1px solid #eee;
}

.woocommerce-prescription-uploads li:last-child {
	border-bottom: none;
}

.woocommerce-prescription-uploads a {
	color: #0073aa;
	text-decoration: none;
	word-break: break-word;
}

.woocommerce-prescription-uploads a:hover {
	text-decoration: underline;
}

/* Responsive Design */
@media (max-width: 768px) {
	.prescription-uploader-form {
		padding: 15px;
	}

	.prescription-uploader-form h3 {
		font-size: 16px;
	}

	.pu-file-item {
		flex-direction: column;
		align-items: flex-start;
	}

	.pu-file-item .file-size {
		margin-top: 5px;
		margin-right: 0;
	}

	.pu-file-item .pu-remove-file {
		align-self: flex-end;
		margin-top: -25px;
	}

	#pu-upload-btn {
		width: 100%;
		padding: 12px;
	}
}
