/**
 * Premium Public CSS for MuaThemeWPGiaRe Google Share to Email
 * Modern, elegant front-end styling
 * @package    Muathemewpgiare_Google_Share_To_Email
 * @since      2.0.0
 */

/* ========================================
   Share Form Container
   ======================================== */
.muathemewpgiare-share-form {
	max-width: 600px;
	margin: 30px auto;
	padding: 40px;
	background: #fff;
	border-radius: 16px;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
	border: 1px solid #f0f0f0;
}

.muathemewpgiare-share-form h3 {
	margin: 0 0 10px 0;
	font-size: 28px;
	font-weight: 700;
	color: #2c3e50;
	text-align: center;
}

.muathemewpgiare-share-form .subtitle {
	text-align: center;
	color: #7f8c8d;
	margin-bottom: 30px;
	font-size: 15px;
}

/* ========================================
   Form Fields
   ======================================== */
.muathemewpgiare-form-group {
	margin-bottom: 25px;
}

.muathemewpgiare-form-group label {
	display: block;
	margin-bottom: 8px;
	font-weight: 600;
	color: #34495e;
	font-size: 14px;
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.muathemewpgiare-form-group input[type="text"],
.muathemewpgiare-form-group input[type="email"],
.muathemewpgiare-form-group textarea {
	width: 100%;
	padding: 14px 18px;
	border: 2px solid #e0e0e0;
	border-radius: 10px;
	font-size: 15px;
	transition: all 0.3s ease;
	background: #fafafa;
	box-sizing: border-box;
}

.muathemewpgiare-form-group input[type="text"]:focus,
.muathemewpgiare-form-group input[type="email"]:focus,
.muathemewpgiare-form-group textarea:focus {
	outline: none;
	border-color: #667eea;
	background: #fff;
	box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.muathemewpgiare-form-group textarea {
	min-height: 120px;
	resize: vertical;
}

.muathemewpgiare-form-group .field-description {
	font-size: 13px;
	color: #95a5a6;
	margin-top: 6px;
	font-style: italic;
}

/* ========================================
   Submit Button
   ======================================== */
.muathemewpgiare-submit-wrapper {
	text-align: center;
	margin-top: 30px;
}

.muathemewpgiare-submit-btn {
	display: inline-block;
	padding: 16px 48px;
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: #fff;
	font-size: 16px;
	font-weight: 700;
	text-decoration: none;
	border-radius: 10px;
	border: none;
	cursor: pointer;
	transition: all 0.3s ease;
	box-shadow: 0 6px 20px rgba(102, 126, 234, 0.3);
	text-transform: uppercase;
	letter-spacing: 1px;
}

.muathemewpgiare-submit-btn:hover {
	transform: translateY(-3px);
	box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
	color: #fff;
}

.muathemewpgiare-submit-btn:active {
	transform: translateY(-1px);
}

.muathemewpgiare-submit-btn:disabled {
	opacity: 0.6;
	cursor: not-allowed;
	transform: none;
}

/* ========================================
   Success/Error Messages
   ======================================== */
.muathemewpgiare-message {
	padding: 16px 20px;
	border-radius: 10px;
	margin: 20px 0;
	font-size: 15px;
	border-left: 4px solid;
	animation: slideIn 0.4s ease;
}

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

.muathemewpgiare-message-success {
	background: #d4edda;
	border-color: #28a745;
	color: #155724;
}

.muathemewpgiare-message-error {
	background: #f8d7da;
	border-color: #dc3545;
	color: #721c24;
}

.muathemewpgiare-message-info {
	background: #d1ecf1;
	border-color: #17a2b8;
	color: #0c5460;
}

/* ========================================
   Loading Spinner
   ======================================== */
.muathemewpgiare-loading {
	display: none;
	text-align: center;
	padding: 20px;
}

.muathemewpgiare-loading.active {
	display: block;
}

.muathemewpgiare-spinner {
	display: inline-block;
	width: 40px;
	height: 40px;
	border: 4px solid #f3f3f3;
	border-top: 4px solid #667eea;
	border-radius: 50%;
	animation: spin 1s linear infinite;
}

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

/* ========================================
   File List Display
   ======================================== */
.muathemewpgiare-file-list {
	list-style: none;
	padding: 0;
	margin: 20px 0;
}

.muathemewpgiare-file-item {
	padding: 15px;
	background: #f8f9fa;
	border-radius: 8px;
	margin-bottom: 10px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	transition: all 0.3s ease;
}

.muathemewpgiare-file-item:hover {
	background: #e9ecef;
	transform: translateX(5px);
}

.muathemewpgiare-file-icon {
	width: 40px;
	height: 40px;
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	border-radius: 8px;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #fff;
	font-weight: 700;
	margin-right: 15px;
}

/* ========================================
   Info Cards
   ======================================== */
.muathemewpgiare-info-card {
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: #fff;
	padding: 25px;
	border-radius: 12px;
	margin: 25px 0;
	box-shadow: 0 6px 20px rgba(102, 126, 234, 0.2);
}

.muathemewpgiare-info-card h4 {
	margin: 0 0 10px 0;
	font-size: 20px;
	color: #fff;
}

.muathemewpgiare-info-card p {
	margin: 0;
	opacity: 0.95;
	line-height: 1.6;
}

/* ========================================
   Progress Bar
   ======================================== */
.muathemewpgiare-progress {
	width: 100%;
	height: 8px;
	background: #e9ecef;
	border-radius: 10px;
	overflow: hidden;
	margin: 20px 0;
}

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

/* ========================================
   Responsive Design
   ======================================== */
@media (max-width: 768px) {
	.muathemewpgiare-share-form {
		padding: 25px;
		margin: 20px 15px;
	}
	
	.muathemewpgiare-share-form h3 {
		font-size: 22px;
	}
	
	.muathemewpgiare-submit-btn {
		padding: 14px 40px;
		font-size: 14px;
		width: 100%;
	}
	
	.muathemewpgiare-form-group input[type="text"],
	.muathemewpgiare-form-group input[type="email"],
	.muathemewpgiare-form-group textarea {
		font-size: 16px; /* Prevent zoom on iOS */
	}
}

/* ===================================
   JavaScript Enhanced States
   =================================== */

/* Form group validation states */
.muathemewpgiare-form-group.success input {
	border-color: #28a745;
	box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.1);
}

.muathemewpgiare-form-group.error input {
	border-color: #dc3545;
	box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1);
}

.muathemewpgiare-form-group.focused {
	transform: scale(1.01);
	transition: transform 0.2s ease;
}

/* Form group relative positioning for icons */
.muathemewpgiare-form-group {
	position: relative;
}

/* Copy link button */
.copy-link-btn {
	position: absolute;
	right: 10px;
	top: 50%;
	transform: translateY(-50%);
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: white;
	border: none;
	padding: 8px 12px;
	border-radius: 6px;
	cursor: pointer;
	font-size: 14px;
	transition: all 0.3s ease;
	z-index: 10;
}

.copy-link-btn:hover {
	transform: translateY(-50%) scale(1.1);
	box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.copy-link-btn:active {
	transform: translateY(-50%) scale(0.95);
}

/* Form loading state */
.muathemewpgiare-share-form.loading {
	pointer-events: none;
	opacity: 0.7;
	position: relative;
}

.muathemewpgiare-share-form.loading::after {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(255, 255, 255, 0.8);
	border-radius: 12px;
	z-index: 100;
}

/* Enhanced loading spinner */
.muathemewpgiare-loading {
	display: inline-block;
	width: 16px;
	height: 16px;
	border: 2px solid rgba(255, 255, 255, 0.3);
	border-top-color: white;
	border-radius: 50%;
	animation: spin 0.6s linear infinite;
	margin-right: 8px;
	vertical-align: middle;
}

@keyframes spin {
	to { transform: rotate(360deg); }
}

/* Message animations */
.muathemewpgiare-message {
	animation: slideInDown 0.3s ease-out;
}

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

/* Input focus glow effect */
.muathemewpgiare-form-group input:focus {
	animation: inputGlow 2s ease-in-out infinite;
}

@keyframes inputGlow {
	0%, 100% {
		box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
	}
	50% {
		box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.3);
	}
}

/* Shake animation for validation errors */
.muathemewpgiare-form-group.error {
	animation: shake 0.4s ease-in-out;
}

@keyframes shake {
	0%, 100% { transform: translateX(0); }
	25% { transform: translateX(-10px); }
	75% { transform: translateX(10px); }
}

/* Success state checkmark */
.muathemewpgiare-form-group.success::after {
	content: '✓';
	position: absolute;
	right: 15px;
	top: 50%;
	transform: translateY(-50%);
	color: #28a745;
	font-size: 20px;
	font-weight: bold;
	animation: successPulse 0.5s ease-out;
	pointer-events: none;
}

@keyframes successPulse {
	0% {
		opacity: 0;
		transform: translateY(-50%) scale(0);
	}
	50% {
		transform: translateY(-50%) scale(1.2);
	}
	100% {
		opacity: 1;
		transform: translateY(-50%) scale(1);
	}
}

/* Error state icon */
.muathemewpgiare-form-group.error::after {
	content: '✕';
	position: absolute;
	right: 15px;
	top: 50%;
	transform: translateY(-50%);
	color: #dc3545;
	font-size: 20px;
	font-weight: bold;
	animation: errorShake 0.4s ease-out;
	pointer-events: none;
}

@keyframes errorShake {
	0%, 100% { transform: translateY(-50%) rotate(0deg); }
	25% { transform: translateY(-50%) rotate(-10deg); }
	75% { transform: translateY(-50%) rotate(10deg); }
}

/* Button press effect */
.muathemewpgiare-submit-btn:active {
	transform: scale(0.95);
	box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

/* Smooth transitions for all interactive elements */
.muathemewpgiare-form-group input,
.muathemewpgiare-submit-btn,
.copy-link-btn {
	transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ========================================
   Dark Mode Support
   ======================================== */
@media (prefers-color-scheme: dark) {
	.muathemewpgiare-share-form {
		background: #1e1e1e;
		border-color: #333;
	}
	
	.muathemewpgiare-share-form h3 {
		color: #fff;
	}
	
	.muathemewpgiare-form-group label {
		color: #e0e0e0;
	}
	
	.muathemewpgiare-form-group input[type="text"],
	.muathemewpgiare-form-group input[type="email"],
	.muathemewpgiare-form-group textarea {
		background: #2a2a2a;
		border-color: #444;
		color: #fff;
	}
	
	.muathemewpgiare-file-item {
		background: #2a2a2a;
		color: #e0e0e0;
	}
	
	.muathemewpgiare-file-item:hover {
		background: #333;
	}
}