/**
 * Cyber Trigon – Request a Quote for WooCommerce
 * Front-end styles
 */

/* ==========================================================================
   CSS Variables
   ========================================================================== */
:root {
	--crq-primary: #534439;
	--crq-secondary: #D2A167;
	--crq-accent: #D07C2F;
	--crq-hover: #8D613D;
	--crq-bg-light: #FFF6EA;
	--crq-font-heading: 'Forum', serif;
	--crq-font-body: 'Lexend', sans-serif;
}

/* ==========================================================================
   Hide default WooCommerce Add to Cart on single product pages
   ========================================================================== */
.single-product div.product form.cart,
.single-product div.product .cart {
	display: none !important;
}

/* ==========================================================================
   Request Quote Button
   ========================================================================== */
.crq-open-modal-btn {
	display: inline-block;
	font-family: var(--crq-font-body);
	font-weight: 300;
	font-size: 16px;
	letter-spacing: 0.03em;
	color: #ffffff;
	background-color: var(--crq-secondary);
	border: none;
	border-radius: 30px;
	padding: 14px 36px;
	cursor: pointer;
	transition: background-color 0.25s ease, transform 0.15s ease;
}

.crq-open-modal-btn:hover,
.crq-open-modal-btn:focus {
	background-color: var(--crq-hover);
	color: #ffffff;
	outline: none;
}

.crq-open-modal-btn:active {
	transform: scale(0.98);
}

/* ==========================================================================
   Modal Overlay
   ========================================================================== */
.crq-modal-overlay {
	display: none;
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	width: 100%;
	height: 100%;
	background-color: rgba(83, 68, 57, 0.6);
	z-index: 99999;
	align-items: center;
	justify-content: center;
	padding: 20px;
	box-sizing: border-box;
}

.crq-modal-overlay.crq-active {
	display: flex;
}

/* ==========================================================================
   Modal Card
   ========================================================================== */
.crq-modal {
	position: relative;
	width: 100%;
	max-width: 520px;
	max-height: 90vh;
	overflow-y: auto;
	background-color: var(--crq-bg-light);
	border-radius: 16px;
	box-shadow: 0 15px 45px rgba(83, 68, 57, 0.35);
	padding: 36px 32px;
	box-sizing: border-box;
	font-family: var(--crq-font-body);
	font-weight: 300;
	color: var(--crq-primary);
	animation: crq-fade-in 0.25s ease;
}

@keyframes crq-fade-in {
	from {
		opacity: 0;
		transform: translateY(15px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* ==========================================================================
   Modal Close Button
   ========================================================================== */
.crq-modal-close {
	position: absolute;
	top: 14px;
	right: 18px;
	background: none;
	border: none;
	font-size: 28px;
	line-height: 1;
	color: var(--crq-primary);
	cursor: pointer;
	padding: 4px;
	transition: color 0.2s ease;
}

.crq-modal-close:hover,
.crq-modal-close:focus {
	color: var(--crq-accent);
	outline: none;
}

/* ==========================================================================
   Modal Title
   ========================================================================== */
.crq-modal-title {
	font-family: var(--crq-font-heading);
	color: var(--crq-primary);
	font-size: 26px;
	font-weight: 400;
	margin: 0 0 20px;
	text-align: left;
}

/* ==========================================================================
   Messages Area
   ========================================================================== */
.crq-modal-messages {
	margin-bottom: 12px;
	font-family: var(--crq-font-body);
	font-size: 14px;
	font-weight: 300;
}

.crq-modal-messages:empty {
	display: none;
}

.crq-modal-messages.crq-success {
	color: #2e7d32;
	background-color: #eef7ee;
	border: 1px solid #b6dfb6;
	border-radius: 8px;
	padding: 12px 14px;
}

.crq-modal-messages.crq-error {
	color: #b3261e;
	background-color: #fdeceb;
	border: 1px solid #f4c3bf;
	border-radius: 8px;
	padding: 12px 14px;
}

/* ==========================================================================
   Form Layout
   ========================================================================== */
.crq-quote-form {
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.crq-form-row {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.crq-form-row label {
	font-family: var(--crq-font-body);
	font-weight: 400;
	font-size: 14px;
	color: var(--crq-primary);
}

.crq-required {
	color: var(--crq-accent);
}

.crq-form-row input[type="text"],
.crq-form-row input[type="email"],
.crq-form-row input[type="tel"],
.crq-form-row input[type="number"],
.crq-form-row textarea {
	font-family: var(--crq-font-body);
	font-weight: 300;
	font-size: 15px;
	color: var(--crq-primary);
	background-color: #ffffff;
	border: 1px solid #e0d3c2;
	border-radius: 10px;
	padding: 10px 14px;
	box-sizing: border-box;
	width: 100%;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.crq-form-row input:focus,
.crq-form-row textarea:focus {
	outline: none;
	border-color: var(--crq-secondary);
	box-shadow: 0 0 0 3px rgba(210, 161, 103, 0.25);
}

.crq-form-row textarea {
	resize: vertical;
	min-height: 90px;
}

.crq-form-row.crq-field-error input,
.crq-form-row.crq-field-error textarea {
	border-color: #b3261e;
}

/* ==========================================================================
   reCAPTCHA Row
   ========================================================================== */
.crq-recaptcha-row {
	display: flex;
	justify-content: flex-start;
}

/* ==========================================================================
   Submit Button
   ========================================================================== */
.crq-submit-row {
	margin-top: 6px;
}

.crq-submit-btn {
	display: inline-block;
	width: 100%;
	font-family: var(--crq-font-body);
	font-weight: 300;
	font-size: 16px;
	letter-spacing: 0.03em;
	color: #ffffff;
	background-color: var(--crq-secondary);
	border: none;
	border-radius: 30px;
	padding: 14px 36px;
	cursor: pointer;
	transition: background-color 0.25s ease, transform 0.15s ease, opacity 0.2s ease;
}

.crq-submit-btn:hover,
.crq-submit-btn:focus {
	background-color: var(--crq-hover);
	outline: none;
}

.crq-submit-btn:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 600px) {
	.crq-modal {
		padding: 26px 20px;
		max-width: 100%;
		border-radius: 12px;
	}

	.crq-modal-title {
		font-size: 22px;
	}

	.crq-open-modal-btn,
	.crq-submit-btn {
		width: 100%;
		text-align: center;
	}
}
