/**
 * Sen Concierge Form Styles
 * Matching SENiTy plugin styles and devster_shop theme
 *
 * @package Sen_Concierge
 */

.sen-concierge-wrapper {
	max-width: 100%;
	margin: 0;
	padding: 0;
}

.sen-form-title {
	font-family: 'Questrial', sans-serif;
	font-style: normal;
	font-weight: 400;
	font-size: 3.6rem;
	line-height: 4.3rem;
	color: #1D2032;
	margin-bottom: 30px;
}

/* Messages */
.sen-message {
	margin-bottom: 25px;
	padding: 20px;
	border-radius: 4px;
}

.sen-message.sen-success {
	background: #d4edda;
	border: 1px solid #c3e6cb;
	color: #155724;
}

.sen-message.sen-error {
	background: #f8d7da;
	border: 1px solid #f5c6cb;
	color: #721c24;
}

.sen-message p {
	margin: 0;
	font-size: 1.4rem;
}

/* Form Sections */
.sen-form-section {
	border: none;
	padding: 0;
	margin-bottom: 40px;
}

.sen-section-title {
	font-family: 'Questrial', sans-serif;
	font-weight: 400;
	font-size: 2.8rem;
	line-height: 3.4rem;
	color: #1D2032;
	margin-bottom: 40px;
	padding: 0;
	width: 100%;
}

/* Form Fields */
.sen-form-row {
	margin-bottom: 25px;
}

.sen-form-row label {
	display: block;
	font-style: normal;
	font-weight: 400;
	font-size: 14px;
	line-height: 170%;
	color: #7D7D7D;
	margin-bottom: 12px;
}

.sen-form-row input[type="text"],
.sen-form-row input[type="email"],
.sen-form-row input[type="tel"],
.sen-form-row input[type="date"],
.sen-form-row input[type="time"],
.sen-form-row textarea,
.sen-form-row select {
	width: 100%;
	border: 1px solid #E6E6E6;
	border-radius: 4px;
	padding: 10px 20px;
	font-weight: 400;
	font-size: 1.4rem;
	line-height: 2.4rem;
	color: #7D7D7D;
	box-sizing: border-box;
	font-family: inherit;
}

.sen-form-row select {
	height: 48px;
}

.sen-form-row textarea {
	min-height: 120px;
	resize: vertical;
}

.sen-form-row input:focus,
.sen-form-row textarea:focus,
.sen-form-row select:focus {
	outline: none;
	border-color: #1D2032;
}

/* Radio Group */
.sen-radio-group {
	display: flex;
	flex-direction: column;
	gap: 15px;
}

/* Error state for radio groups */
.sen-radio-group.has-error {
	border-left: 3px solid #dc3545;
	padding-left: 15px;
	margin-left: -15px;
}

.sen-radio-group label {
	display: flex;
	align-items: center;
	cursor: pointer;
	font-weight: 400;
	font-size: 1.4rem;
	color: #1D2032;
	margin-bottom: 0;
}

.sen-radio-group input[type="radio"] {
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	width: 24px;
	height: 24px;
	padding: 5px;
	border: 1px solid #E6E6E6;
	background-clip: content-box;
	border-radius: 50%;
	margin-right: 10px;
	cursor: pointer;
	flex-shrink: 0;
}

.sen-radio-group input[type="radio"]:checked {
	background-color: #1D2032;
}

/* Checkbox Rows */
.sen-checkbox-row {
	margin-bottom: 15px;
}

/* Error state for individual checkboxes */
.sen-checkbox-row.has-error,
.sen-form-row.has-checkbox-error {
	border-left: 3px solid #dc3545;
	padding-left: 15px;
	margin-left: -15px;
}

.sen-checkbox-row label {
	display: flex !important;
	align-items: center !important;
	cursor: pointer;
	font-weight: 400;
	font-size: 1.4rem;
	line-height: 2.4rem;
	color: #1D2032;
}

.sen-checkbox-row input[type="checkbox"] {
	width: 24px;
	height: 24px;
	border: 1px solid #E6E6E6;
	margin-right: 10px;
	-webkit-appearance: none;
	appearance: none;
	background-color: #fff;
	position: relative;
	cursor: pointer;
	flex-shrink: 0;
	margin-top: 2px;
}

.sen-checkbox-row input[type="checkbox"]:before {
	content: "";
	display: inline-block;
	width: 14px;
	height: 10px;
	position: absolute;
	left: 50%;
	top: 50%;
	transform: translate(-50%, -50%) scale(0);
	clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
	transition: 120ms transform ease-in-out;
	box-shadow: inset 1em 1em #1D2032;
}

.sen-checkbox-row input[type="checkbox"]:checked::before {
	transform: translate(-50%, -50%) scale(1);
}

/* Required indicator */
.required {
	color: #dc3545;
}

/* Half-width fields (date/time side by side) */
.sen-row-half {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 20px;
	margin-bottom: 25px;
}

.sen-field-half label {
	display: block;
	font-style: normal;
	font-weight: 400;
	font-size: 14px;
	line-height: 170%;
	color: #7D7D7D;
	margin-bottom: 12px;
}

.sen-field-half input {
	width: 100%;
	border: 1px solid #E6E6E6;
	border-radius: 4px;
	padding: 10px 20px;
	font-weight: 400;
	font-size: 1.4rem;
	line-height: 2.4rem;
	color: #7D7D7D;
	box-sizing: border-box;
	font-family: inherit;
}

.sen-field-half input:focus {
	outline: none;
	border-color: #1D2032;
}

/* Custom select styling for time dropdown */
.sen-field-half select {
	width: 100%;
	border: 1px solid #E6E6E6;
	border-radius: 4px;
	padding: 10px 20px;
	font-weight: 400;
	font-size: 1.4rem;
	line-height: 2.4rem;
	color: #7D7D7D;
	box-sizing: border-box;
	font-family: inherit;
	background-color: #fff;
	background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237D7D7D' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
	background-repeat: no-repeat;
	background-position: right 10px center;
	background-size: 20px;
	padding-right: 40px;
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	cursor: pointer;
	height: 48px; /* Match date input height */
}

.sen-field-half select:focus {
	outline: none;
	border-color: #1D2032;
}

.sen-field-half select::-ms-expand {
	display: none; /* Remove default arrow in IE */
}

/* Submit Section */
.sen-form-submit {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 15px;
	margin-top: 40px;
	margin-bottom: 10px;
}

.sen-submit-btn {
	background: #1D2032;
	color: #fff;
	border: none;
	padding: 15px 40px;
	font-size: 1.6rem;
	font-weight: 400;
	border-radius: 4px;
	cursor: pointer;
	transition: background 0.3s ease;
	font-family: inherit;
}

.sen-submit-btn:hover {
	background: #000;
}

.sen-submit-btn:disabled {
	background: #ccc;
	cursor: not-allowed;
}

.sen-submit-note {
	color: #7D7D7D;
	font-size: 1.4rem;
	margin: 0;
	text-align: center;
}

/* Validation Errors - matching senity */
.sen-form-row input.sen-error,
.sen-form-row textarea.sen-error,
.sen-form-row select.sen-error,
.sen-field-half input.sen-error,
.sen-field-half select.sen-error {
	border-color: #dc3545;
}

/* Radio buttons should NOT change border color on error - only group shows error */
.sen-radio-group input[type="radio"].sen-error {
	border-color: #E6E6E6;
}

/* Checkboxes should NOT change border color on error - only wrapper shows error */
.sen-checkbox-row input[type="checkbox"].sen-error {
	border-color: #E6E6E6;
}

.sen-error-message {
	display: block;
	color: #dc3545;
	font-size: 13px;
	margin-top: 8px;
	font-weight: 400;
}

/* Loading State - spinner inside button */
.sen-submit-btn:disabled {
	background: #ccc;
	cursor: not-allowed;
}

.sen-btn-loading {
	position: relative;
	padding-left: 50px;
}

.sen-btn-spinner {
	position: absolute;
	left: 15px;
	top: 50%;
	transform: translateY(-50%);
	width: 16px;
	height: 16px;
	border: 2px solid rgba(255, 255, 255, 0.3);
	border-top-color: #fff;
	border-radius: 50%;
	animation: sen-btn-spinner-rotate 0.6s linear infinite;
	display: inline-block;
}

@keyframes sen-btn-spinner-rotate {
	0% {
		transform: translateY(-50%) rotate(0deg);
	}
	100% {
		transform: translateY(-50%) rotate(360deg);
	}
}

/* Responsive */
@media (max-width: 768px) {
	.sen-form-title {
		font-size: 2.8rem;
		line-height: 3.4rem;
	}

	.sen-section-title {
		font-size: 2rem;
		line-height: 2.4rem;
		margin-bottom: 25px;
	}

	.sen-row-half {
		grid-template-columns: 1fr;
		gap: 0;
	}

	.sen-radio-group {
		gap: 10px;
	}

	.sen-submit-btn {
		width: 100%;
	}
}
