/**
 * Klicaki — Página de pedido de orçamento
 */

.quote-page {
	position: relative;
	background: #0a0e1a;
	padding: 7.5rem 0 5rem;
	overflow: hidden;
	max-width: 100%;
	min-height: 70vh;
}

.quote-page__blob {
	position: absolute;
	width: min(720px, 70%);
	height: min(720px, 70vw);
	top: -12%;
	right: -10%;
	border-radius: 50%;
	background: radial-gradient(
		circle at center,
		rgba(107, 33, 168, 0.22) 0%,
		rgba(0, 85, 255, 0.1) 42%,
		transparent 70%
	);
	pointer-events: none;
	filter: blur(8px);
}

.quote-page__inner {
	position: relative;
	z-index: 1;
	max-width: 720px;
	min-width: 0;
	box-sizing: border-box;
}

.quote-page__header {
	margin-bottom: 2rem;
}

.quote-page__title {
	font-family: var(--font-title);
	font-weight: 800;
	font-size: clamp(1.65rem, 6.2vw, 2.85rem);
	color: var(--white, #fff);
	margin: 0.35rem 0 0.85rem;
	line-height: 1.15;
	overflow-wrap: break-word;
}

.quote-page__lead {
	margin: 0;
	color: var(--text-soft, rgba(255, 255, 255, 0.72));
	font-size: 1.05rem;
	line-height: 1.65;
	max-width: 38rem;
	overflow-wrap: break-word;
}

.quote-form {
	margin-top: 0.5rem;
}

.quote-form__types {
	border: 0;
	margin: 0 0 1.75rem;
	padding: 0;
	min-width: 0;
	max-width: 100%;
	width: 100%;
}

.quote-form__legend {
	font-size: 0.75rem;
	text-transform: uppercase;
	letter-spacing: 0.1em;
	color: var(--muted);
	margin-bottom: 0.75rem;
}

.quote-type-tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	width: 100%;
	max-width: 100%;
	min-width: 0;
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
	overscroll-behavior-x: contain;
	padding-bottom: 0.25rem;
	scrollbar-width: thin;
}

.quote-type-tab {
	flex: 0 0 auto;
	appearance: none;
	border: 1px solid rgba(255, 255, 255, 0.12);
	background: rgba(255, 255, 255, 0.04);
	color: rgba(255, 255, 255, 0.78);
	font-family: var(--font-body);
	font-size: 0.88rem;
	font-weight: 600;
	padding: 0.55rem 0.95rem;
	border-radius: 999px;
	cursor: pointer;
	transition:
		background 0.2s ease,
		border-color 0.2s ease,
		color 0.2s ease;
	white-space: nowrap;
}

.quote-type-tab:hover,
.quote-type-tab:focus-visible {
	border-color: rgba(147, 197, 253, 0.55);
	color: #fff;
	outline: none;
}

.quote-type-tab.is-active {
	background: linear-gradient(135deg, rgba(0, 85, 255, 0.35), rgba(107, 33, 168, 0.4));
	border-color: rgba(168, 85, 247, 0.55);
	color: #fff;
}

.quote-form.contact-form label {
	color: rgba(255, 255, 255, 0.62);
}

.quote-form.contact-form input[type="text"],
.quote-form.contact-form input[type="email"],
.quote-form.contact-form input[type="tel"],
.quote-form.contact-form select,
.quote-form.contact-form textarea {
	width: 100%;
	max-width: 100%;
	min-width: 0;
	background: rgba(255, 255, 255, 0.06);
	border: 1px solid rgba(255, 255, 255, 0.12);
	border-radius: 8px;
	color: #fff;
	margin-bottom: 1.15rem;
	box-sizing: border-box;
}

.quote-form.contact-form select {
	appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%2393c5fd' d='M1.4.6 6 5.2 10.6.6 12 2 6 8 0 2z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 1rem center;
	padding-right: 2.5rem;
}

.quote-form.contact-form select option {
	color: #111;
	background: #fff;
}

.quote-form.contact-form input:focus,
.quote-form.contact-form select:focus,
.quote-form.contact-form textarea:focus {
	border-color: rgba(59, 130, 246, 0.7);
	box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.18);
}

.quote-form .contact-consent {
	color: rgba(255, 255, 255, 0.7);
	overflow-wrap: break-word;
}

.quote-form .contact-consent a {
	color: #93c5fd;
}

.quote-form .klicaki-service-area-notice {
	color: rgba(255, 255, 255, 0.75);
	background: rgba(59, 130, 246, 0.12);
	border-left-color: #60a5fa;
	overflow-wrap: break-word;
}

.quote-panel {
	display: none;
	margin-bottom: 0.5rem;
}

.quote-panel.is-active {
	display: block;
}

.quote-photos {
	margin: 0.25rem 0 1.5rem;
}

.quote-photos__label {
	display: block;
	font-size: 0.75rem;
	text-transform: uppercase;
	letter-spacing: 0.1em;
	color: rgba(255, 255, 255, 0.62);
	margin-bottom: 0.35rem;
}

.quote-photos__optional {
	text-transform: none;
	letter-spacing: 0;
	opacity: 0.75;
	font-size: 0.85em;
}

.quote-photos__hint {
	margin: 0 0 0.85rem;
	font-size: 0.85rem;
	color: rgba(255, 255, 255, 0.5);
}

.quote-photos__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.65rem;
	margin-bottom: 0.85rem;
}

.quote-photos__btn {
	cursor: pointer;
	margin: 0 !important;
	padding: 0.65rem 1rem !important;
	font-size: 0.9rem !important;
}

/* Desktop: só «Anexar fotos» (explorador de ficheiros). Câmara só em ecrãs tácteis / telemóvel. */
.quote-photos__btn--camera,
.quote-photos__input--camera {
	display: none !important;
}

@media (max-width: 768px), (hover: none) and (pointer: coarse) {
	.quote-photos__btn--camera {
		display: inline-flex !important;
	}

	.quote-photos__input--camera {
		/* Mantém o input acessível mas visualmente oculto (como os outros file inputs). */
		display: block !important;
		position: absolute !important;
		width: 1px !important;
		height: 1px !important;
		padding: 0 !important;
		margin: -1px !important;
		overflow: hidden !important;
		clip: rect(0, 0, 0, 0) !important;
		border: 0 !important;
	}
}

.quote-photos__input {
	position: absolute !important;
	width: 1px !important;
	height: 1px !important;
	padding: 0 !important;
	margin: -1px !important;
	overflow: hidden !important;
	clip: rect(0, 0, 0, 0) !important;
	border: 0 !important;
}

.quote-photos__preview {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
	gap: 0.65rem;
}

.quote-photos__thumb {
	position: relative;
	aspect-ratio: 1;
	border-radius: 8px;
	overflow: hidden;
	border: 1px solid rgba(255, 255, 255, 0.14);
	background: rgba(0, 0, 0, 0.35);
}

.quote-photos__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.quote-photos__remove {
	position: absolute;
	top: 4px;
	right: 4px;
	width: 1.6rem;
	height: 1.6rem;
	border: 0;
	border-radius: 50%;
	background: rgba(0, 0, 0, 0.72);
	color: #fff;
	font-size: 1rem;
	line-height: 1;
	cursor: pointer;
	display: grid;
	place-items: center;
	padding: 0;
}

.quote-photos__remove:hover,
.quote-photos__remove:focus-visible {
	background: #b91c1c;
	outline: none;
}

.quote-photos__error {
	margin: 0.65rem 0 0;
	font-size: 0.9rem;
	color: #fca5a5;
}

.quote-form__submit {
	width: 100%;
	justify-content: center;
}

.quote-form__alt {
	margin: 1.25rem 0 0;
	text-align: center;
	font-size: 0.9rem;
	color: rgba(255, 255, 255, 0.55);
}

.quote-form__alt a {
	color: #93c5fd;
}

.quote-form.is-busy .quote-form__submit {
	opacity: 0.7;
	pointer-events: none;
}

@media (max-width: 768px) {
	.quote-page {
		padding: 6.5rem 0 6.5rem;
	}

	.quote-type-tabs {
		flex-wrap: nowrap;
		max-width: 100%;
	}

	.quote-photos__btn--camera {
		flex: 1 1 auto;
	}

	.quote-form.contact-form input[type="text"],
	.quote-form.contact-form input[type="email"],
	.quote-form.contact-form input[type="tel"],
	.quote-form.contact-form select,
	.quote-form.contact-form textarea {
		font-size: 16px;
		max-width: 100%;
	}

	.quote-form .klicaki-service-area-notice,
	.quote-form .contact-consent {
		font-size: 0.88rem;
		max-width: 100%;
		overflow-wrap: break-word;
	}

	.quote-form .contact-form__turnstile,
	.quote-form .cf-turnstile {
		max-width: 100%;
		overflow: hidden;
	}

	.quote-form .contact-form__turnstile iframe {
		max-width: 100% !important;
	}
}

@media (max-width: 380px) {
	.quote-page__title {
		font-size: clamp(1.45rem, 7.5vw, 1.85rem);
	}
}

@media (prefers-reduced-motion: reduce) {
	.quote-type-tab {
		transition: none;
	}
}
