/* AFTruck Certificate Validator Styles */

/* Container */
.aftruck-cert-container {
	max-width: 800px;
	margin: 40px auto;
	padding: 20px;
}

/* Header Section */
.aftruck-cert-header {
	text-align: center;
	margin-bottom: 40px;
}

.aftruck-cert-header h2 {
	font-size: 2.5em;
	font-weight: 700;
	color: #222;
	margin-bottom: 15px;
	text-transform: uppercase;
	letter-spacing: 1px;
}

.heading-separator {
	width: 118px;
	height: 4px;
	margin: 15px auto 0;
	display: block;
	background: linear-gradient(
		90deg,
		transparent,
		#333 20%,
		#333 80%,
		transparent
	);
	border-radius: 2px;
}

/* Form Wrapper */
.aftruck-cert-form-wrapper {
	background: #fff !important;
	padding: 40px !important;
	border-radius: 8px !important;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
	border: 1px solid #e5e5e5 !important;
	box-sizing: border-box !important;
}

.aftruck-cert-description {
	color: #666;
	font-size: 1.1em;
	text-align: center;
	margin-bottom: 30px;
	line-height: 1.6;
}

/* Form Styles */
.aftruck-cert-form {
	margin-bottom: 30px;
}

.form-group {
	display: flex !important;
	gap: 15px !important;
	flex-wrap: wrap !important;
	align-items: stretch !important;
}

.aftruck-cert-input {
	flex: 1 !important;
	min-width: 250px !important;
	padding: 15px 20px !important;
	font-size: 1em !important;
	border: 2px solid #ddd !important;
	border-radius: 4px !important;
	transition: all 0.3s ease !important;
	font-family: inherit !important;
	box-sizing: border-box !important;
	width: auto !important;
	max-width: 100% !important;
}

.aftruck-cert-input:focus {
	outline: none !important;
	border-color: #333 !important;
	box-shadow: 0 0 0 3px rgba(51, 51, 51, 0.1) !important;
}

.aftruck-cert-button {
	padding: 15px 40px !important;
	font-size: 1em !important;
	font-weight: 600 !important;
	color: #fff !important;
	background: #333 !important;
	border: 2px solid #333 !important;
	border-radius: 4px !important;
	cursor: pointer !important;
	transition: all 0.3s ease !important;
	text-transform: uppercase !important;
	letter-spacing: 0.5px !important;
	position: relative !important;
	min-width: 180px !important;
	box-sizing: border-box !important;
	display: inline-block !important;
}

.aftruck-cert-button:hover {
	background: #000 !important;
	border-color: #000 !important;
	transform: translateY(-2px) !important;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2) !important;
}

.aftruck-cert-button:active {
	transform: translateY(0) !important;
}

.aftruck-cert-button:disabled {
	opacity: 0.7 !important;
	cursor: not-allowed !important;
	transform: none !important;
}

.button-loader {
	display: inline-block;
	animation: spin 1s linear infinite;
	font-size: 1.2em;
}

@keyframes spin {
	from {
		transform: rotate(0deg);
	}
	to {
		transform: rotate(360deg);
	}
}

/* Result Container */
.aftruck-cert-result {
	margin-top: 30px;
}

/* Success Message */
.aftruck-cert-success {
	background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
	border: 2px solid #0ea5e9;
	border-radius: 8px;
	padding: 30px;
	position: relative;
	animation: slideIn 0.3s ease-out;
}

.aftruck-cert-success::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 4px;
	background: linear-gradient(90deg, #0ea5e9, #06b6d4);
	border-radius: 8px 8px 0 0;
}

.cert-success-icon {
	width: 60px;
	height: 60px;
	background: #0ea5e9;
	color: white;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 2em;
	font-weight: bold;
	margin: 0 auto 20px;
	box-shadow: 0 4px 12px rgba(14, 165, 233, 0.3);
}

.aftruck-cert-success h3 {
	color: #0c4a6e;
	font-size: 1.8em;
	margin: 0 0 25px 0;
	text-align: center;
	font-weight: 700;
}

/* Certificate Details */
.cert-details {
	background: white;
	border-radius: 6px;
	padding: 25px;
	box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.05);
}

.cert-detail-row {
	display: flex;
	padding: 12px 0;
	border-bottom: 1px solid #e5e7eb;
	gap: 15px;
}

.cert-detail-row:last-child {
	border-bottom: none;
}

.cert-label {
	font-weight: 600;
	color: #374151;
	min-width: 180px;
	flex-shrink: 0;
}

.cert-value {
	color: #1f2937;
	flex: 1;
	word-break: break-word;
}

/* Error Message */
.aftruck-cert-error {
	background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
	border: 2px solid #ef4444;
	border-radius: 8px;
	padding: 30px;
	text-align: center;
	position: relative;
	animation: slideIn 0.3s ease-out;
}

.aftruck-cert-error::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 4px;
	background: linear-gradient(90deg, #ef4444, #dc2626);
	border-radius: 8px 8px 0 0;
}

.cert-error-icon {
	width: 60px;
	height: 60px;
	background: #ef4444;
	color: white;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 2em;
	font-weight: bold;
	margin: 0 auto 20px;
	box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.aftruck-cert-error p {
	color: #991b1b;
	font-size: 1.1em;
	margin: 0;
	font-weight: 500;
}

/* Animations */
@keyframes slideIn {
	from {
		opacity: 0;
		transform: translateY(-20px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* Responsive Design */
@media (max-width: 768px) {
	.aftruck-cert-container {
		padding: 15px;
		margin: 20px auto;
	}

	.aftruck-cert-header h2 {
		font-size: 1.6em;
		line-height: 1.3;
	}

	.aftruck-cert-form-wrapper {
		padding: 25px 15px !important;
	}

	.form-group {
		flex-direction: column !important;
		gap: 10px !important;
	}

	.aftruck-cert-input,
	.aftruck-cert-button {
		width: 100% !important;
		min-width: auto !important;
	}

	.cert-detail-row {
		flex-direction: column;
		gap: 5px;
	}

	.cert-label {
		min-width: auto;
		font-size: 0.9em;
	}

	.cert-value {
		font-size: 0.95em;
	}

	.cert-details {
		padding: 15px;
	}

	.aftruck-cert-success h3 {
		font-size: 1.4em;
	}

	.cert-success-icon,
	.cert-error-icon {
		width: 50px;
		height: 50px;
		font-size: 1.6em;
	}
}

@media (max-width: 480px) {
	.aftruck-cert-header h2 {
		font-size: 1.3em;
		padding: 0 10px;
	}

	.aftruck-cert-description {
		font-size: 0.9em;
		padding: 0 5px;
	}

	.aftruck-cert-input {
		padding: 14px 15px !important;
		font-size: 16px !important;
	}

	.aftruck-cert-button {
		padding: 14px 25px !important;
		font-size: 0.95em !important;
	}

	.aftruck-cert-form-wrapper {
		padding: 20px 12px !important;
	}

	.aftruck-cert-success h3 {
		font-size: 1.2em;
	}
}
