/**
 * Frontend Stylesheet
 *
 * Implements the professional automotive UI using Poppins, Gold Yellow (#FFC107),
 * and Dark Blue (#0F172A) with rounded inputs, smooth transitions, and premium overlays.
 *
 * @package T_Permit_Sell_Vehicle_Enquiry
 */

/* Import Google Poppins Font if not already loaded */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

.tpsve-form-wrapper {
	font-family: 'Poppins', sans-serif;
	color: #334155;
	max-width: 900px;
	margin: 40px auto;
	padding: 0 15px;
	box-sizing: border-box;
}

.tpsve-form-wrapper * {
	box-sizing: border-box;
}

/* Form container */
#tpsve-sell-vehicle-form {
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 16px;
	box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.08);
	overflow: hidden;
}

/* Sections */
.tpsve-form-section {
	padding: 35px;
	border-bottom: 1px solid #f1f5f9;
}

.tpsve-form-section:last-of-type {
	border-bottom: none;
	background: #f8fafc;
}

/* Headers */
.tpsve-section-title {
	font-size: 20px;
	font-weight: 600;
	color: #0f172a;
	margin-top: 0;
	margin-bottom: 25px;
	display: flex;
	align-items: center;
	gap: 12px;
}

.tpsve-step-num {
	background: #ffc107;
	color: #0f172a;
	font-size: 14px;
	font-weight: 700;
	width: 28px;
	height: 28px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
}

.tpsve-section-subtitle {
	font-size: 12px;
	font-weight: 400;
	color: #64748b;
	margin-left: auto;
}

/* Responsive Grid Layout */
.tpsve-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 20px;
}

.tpsve-field-group {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.tpsve-col-full {
	grid-column: span 2;
}

/* Input Fields styling */
.tpsve-field-group label {
	font-size: 13px;
	font-weight: 500;
	color: #475569;
}

.tpsve-required {
	color: #ef4444;
	font-weight: bold;
}

.tpsve-field-group input[type="text"],
.tpsve-field-group input[type="tel"],
.tpsve-field-group input[type="email"],
.tpsve-field-group input[type="number"],
.tpsve-field-group input[type="date"],
.tpsve-field-group select,
.tpsve-field-group textarea {
	width: 100%;
	padding: 12px 16px;
	font-family: 'Poppins', sans-serif;
	font-size: 14px;
	color: #1e293b;
	background-color: #ffffff;
	border: 1.5px solid #cbd5e1;
	border-radius: 10px;
	transition: all 0.3s ease;
	outline: none;
}

.tpsve-field-group input:focus,
.tpsve-field-group select:focus,
.tpsve-field-group textarea:focus {
	border-color: #ffc107;
	box-shadow: 0 0 0 4px rgba(255, 193, 7, 0.15);
	background-color: #ffffff;
}

.tpsve-field-group select {
	appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23475569' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 16px center;
	background-size: 16px;
	padding-right: 40px;
	cursor: pointer;
}

.tpsve-field-group textarea {
	resize: vertical;
}

/* Separator line */
.tpsve-separator {
	border: 0;
	border-top: 1px solid #e2e8f0;
	margin: 25px 0;
}

/* Checkbox confirmation */
.tpsve-confirm-container {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	margin-bottom: 25px;
}

.tpsve-confirm-container input[type="checkbox"] {
	margin-top: 4px;
	width: 18px;
	height: 18px;
	accent-color: #ffc107;
	cursor: pointer;
}

.tpsve-checkbox-label {
	font-size: 13.5px;
	font-weight: 500;
	color: #334155;
	line-height: 1.4;
	cursor: pointer;
	user-select: none;
}

/* Submit premium button */
.tpsve-submit-container {
	text-align: right;
}

.tpsve-submit-btn {
	background: #0f172a;
	color: #ffffff;
	border: none;
	border-radius: 12px;
	padding: 16px 40px;
	font-size: 15px;
	font-weight: 600;
	cursor: pointer;
	transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
	box-shadow: 0 4px 12px rgba(15, 23, 42, 0.15);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	min-width: 200px;
}

.tpsve-submit-btn:hover {
	background: #ffc107;
	color: #0f172a;
	transform: translateY(-2px);
	box-shadow: 0 8px 20px rgba(255, 193, 7, 0.25);
}

.tpsve-submit-btn:active {
	transform: translateY(0);
}

.tpsve-submit-btn:disabled {
	background: #94a3b8 !important;
	color: #ffffff !important;
	cursor: not-allowed;
	transform: none !important;
	box-shadow: none !important;
}

/* Loading Spinner inside button */
.tpsve-btn-spinner {
	width: 20px;
	height: 20px;
	border: 2.5px solid rgba(255, 255, 255, 0.3);
	border-top-color: #ffffff;
	border-radius: 50%;
	animation: tpsve-spin 0.8s linear infinite;
	display: inline-block;
}

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

/* File Upload Grid and Box styling */
.tpsve-upload-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 20px;
}

.tpsve-upload-box {
	background: #f8fafc;
	border: 1.5px dashed #cbd5e1;
	border-radius: 12px;
	padding: 20px;
	transition: all 0.3s ease;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.tpsve-upload-box:hover,
.tpsve-upload-box.tpsve-drag-over {
	border-color: #ffc107;
	background: rgba(255, 193, 7, 0.02);
}

.tpsve-upload-label {
	font-size: 13px;
	font-weight: 600;
	color: #1e293b;
}

.tpsve-file-dropzone {
	position: relative;
	width: 100%;
	height: 80px;
	border-radius: 8px;
	background: #ffffff;
	border: 1px solid #e2e8f0;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	overflow: hidden;
}

.tpsve-file-dropzone input[type="file"] {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	opacity: 0;
	cursor: pointer;
	z-index: 2;
}

.tpsve-dropzone-content {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 6px;
	z-index: 1;
	pointer-events: none;
}

.tpsve-dz-icon {
	font-size: 20px;
}

.tpsve-dz-text {
	font-size: 11.5px;
	color: #64748b;
	text-align: center;
	padding: 0 10px;
}

/* File preview list */
.tpsve-file-preview-list {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.tpsve-preview-item {
	display: flex;
	align-items: center;
	justify-content: space-between;
	background: #ffffff;
	padding: 6px 12px;
	border-radius: 6px;
	border: 1px solid #e2e8f0;
	font-size: 12px;
}

.tpsve-preview-name {
	color: #334155;
	font-weight: 500;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	max-width: 180px;
}

.tpsve-preview-remove {
	color: #ef4444;
	font-weight: bold;
	cursor: pointer;
	border: none;
	background: none;
	font-size: 14px;
	line-height: 1;
}

.tpsve-preview-remove:hover {
	color: #b91c1c;
}

/* Success Modal Overlay */
.tpsve-modal-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(15, 23, 42, 0.6);
	backdrop-filter: blur(4px);
	z-index: 99999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
}

.tpsve-modal-card {
	background: #ffffff;
	border-radius: 20px;
	max-width: 500px;
	width: 100%;
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
	overflow: hidden;
	animation: tpsve-modal-bounce 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes tpsve-modal-bounce {
	from { transform: scale(0.8); opacity: 0; }
	to { transform: scale(1); opacity: 1; }
}

.tpsve-modal-header {
	background: #0f172a;
	padding: 35px 20px;
	text-align: center;
	position: relative;
}

.tpsve-success-badge {
	width: 60px;
	height: 60px;
	background: #ffc107;
	color: #0f172a;
	border-radius: 50%;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 30px;
	font-weight: bold;
	box-shadow: 0 0 0 8px rgba(255, 193, 7, 0.15);
}

.tpsve-modal-body {
	padding: 35px;
	text-align: center;
}

.tpsve-modal-title {
	font-size: 22px;
	font-weight: 700;
	color: #0f172a;
	margin-top: 0;
	margin-bottom: 12px;
}

.tpsve-modal-message {
	font-size: 14px;
	color: #64748b;
	line-height: 1.6;
	margin-bottom: 30px;
}

/* Modal Actions Buttons */
.tpsve-modal-actions {
	display: flex;
	gap: 15px;
}

.tpsve-action-btn-back {
	flex: 1;
	background: #f1f5f9;
	color: #475569;
	border: 1px solid #cbd5e1;
	padding: 14px 20px;
	border-radius: 10px;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	transition: all 0.2s ease;
}

.tpsve-action-btn-back:hover {
	background: #e2e8f0;
	color: #0f172a;
}

.tpsve-action-btn-whatsapp {
	flex: 1.2;
	background: #25d366;
	color: #ffffff;
	text-decoration: none !important;
	padding: 14px 20px;
	border-radius: 10px;
	font-size: 14px;
	font-weight: 600;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	box-shadow: 0 4px 10px rgba(37, 211, 102, 0.2);
	transition: all 0.2s ease;
}

.tpsve-action-btn-whatsapp:hover {
	background: #128c7e;
	box-shadow: 0 6px 15px rgba(18, 140, 126, 0.3);
	transform: translateY(-1px);
}

/* Alert styles */
.tpsve-alert-danger {
	background: #fef2f2;
	color: #991b1b;
	border: 1px solid #fca5a5;
	padding: 12px 16px;
	border-radius: 8px;
	font-size: 13px;
	font-weight: 500;
	margin-top: 20px;
	text-align: center;
}

/* Responsive breakdowns */
@media (max-width: 768px) {
	.tpsve-grid,
	.tpsve-upload-grid {
		grid-template-columns: 1fr;
	}
	
	.tpsve-col-full {
		grid-column: span 1;
	}
	
	.tpsve-form-section {
		padding: 20px;
	}
	
	.tpsve-submit-container {
		text-align: center;
	}
	
	.tpsve-submit-btn {
		width: 100%;
	}
	
	.tpsve-modal-actions {
		flex-direction: column;
	}
}
