/*!
 * Knights Quest Map - front-end styles
 * Hand-rolled (no Tailwind runtime). All selectors prefixed .kqm to avoid theme bleed.
 */

.kqm,
.kqm * {
	box-sizing: border-box;
}

/* Full-bleed wrapper - dark background extends edge-to-edge regardless of the
 * page container's max-width. Uses calc + viewport-width trick so it works
 * inside themes that constrain content to a centered column. */
/* Full-bleed wrapper - dark background extends edge-to-edge regardless of the
 * page container's max-width.
 *
 * Uses `calc(-1 * (100vw - 100%) / 2)` for the negative margins: this derives
 * the breakout distance from the difference between the viewport and the
 * parent's content width, which correctly accounts for scrollbar width AND
 * any parent padding. Avoids the horizontal-scroll bug caused by `-50vw`
 * which assumes no scrollbar.
 */
.kqm-fullbleed {
	width: auto;
	margin-left: calc(-1 * (100vw - 100%) / 2);
	margin-right: calc(-1 * (100vw - 100%) / 2);
	background: #0A0A0A;
	padding: 4rem 1.5rem;
	/* Safety net: in case any browser still computes the breakout
	 * a fraction wider than the viewport, clip horizontally so it
	 * never causes the document to scroll. `clip` (vs `hidden`)
	 * doesn't create a scroll context, so position:sticky etc still work. */
	overflow-x: clip;
	/* Containment: create our own stacking context at z-index: 0 so all
	 * descendants (header buttons, map, sections) stay inside it. Without
	 * this, our content - which appears later in DOM than the page header -
	 * can outrank the header's dropdown via natural document order when
	 * neither side has an explicit z-index. */
	position: relative;
	z-index: 0;
	isolation: isolate;
}

/* When the last enabled section exists, fade the wrapper background from
 * dark to white. The .kqm-section--last element sits ON the gradient near
 * the white end. This works without :has() and without depending on what
 * the page renders below the shortcode. */
.kqm-fullbleed.kqm-fullbleed--has-fade {
	background: linear-gradient(to bottom,
		#0A0A0A 0%,
		#0A0A0A 70%,
		#ffffff 100%);
	padding-bottom: 5rem;
}

/* The last regular section gets a transparent background so the gradient
 * shows through. The CTA strip is exempt - it's always a dark island. */
.kqm-fullbleed--has-fade .kqm-section.kqm-section--last {
	background: transparent;
	margin-top: 4rem;
}

/* No fade (all sections disabled): plain radial gradient like before. */
.kqm-fullbleed:not(.kqm-fullbleed--has-fade) {
	background-image: radial-gradient(ellipse at center top, #111111 0%, #0A0A0A 65%);
}

@media (max-width: 700px) {
	.kqm-fullbleed {
		padding: 2.5rem 1rem;
	}
}

/* Inner boxed area - centred 1200px column inside the full-bleed band. */
.kqm {
	--kqm-gold: #C9A84C;
	--kqm-gold-hover: #d9b85e;
	--kqm-bg: #0A0A0A;
	--kqm-bg-2: #111111;
	--kqm-bg-3: #1A1A1A;
	--kqm-bg-4: #2A2A2A;
	--kqm-text: #ffffff;
	--kqm-text-muted: #E8E8E8;
	--kqm-text-faint: #888888;
	--kqm-border: rgba(201, 168, 76, 0.3);
	--kqm-border-faint: rgba(255, 255, 255, 0.08);
	--kqm-emerald: #3BB88A;
	--kqm-radius: 1.25rem;
	--kqm-radius-sm: 0.75rem;

	color: var(--kqm-text);
	font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
	line-height: 1.5;
	max-width: 1200px;
	margin: 0 auto;
}

/* ----- Header ----- */

.kqm-header-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	flex-wrap: wrap;
	margin-bottom: 2rem;
}

.kqm-brand {
	display: flex;
	align-items: center;
	gap: 1rem;
}

.kqm-brand-mark {
	width: 3rem;
	height: 3rem;
	border-radius: 9999px;
	background: var(--kqm-gold);
	display: flex;
	align-items: center;
	justify-content: center;
	color: #000;
	flex-shrink: 0;
}

.kqm-brand-mark svg {
	width: 1.75rem;
	height: 1.75rem;
}

.kqm-title {
	font-family: 'Playfair Display', Georgia, serif;
	font-size: 2.25rem;
	font-weight: 700;
	margin: 0;
	color: var(--kqm-text);
	line-height: 1.1;
}

.kqm-subtitle {
	color: var(--kqm-gold);
	font-size: 1rem;
	margin: 0;
}

.kqm-header-actions {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	flex-wrap: wrap;
}

.kqm-live-count {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	background: var(--kqm-bg-3);
	padding: 0.5rem 1rem;
	border-radius: 9999px;
	font-size: 0.85rem;
	color: var(--kqm-text);
	border: 1px solid var(--kqm-border-faint);
}

.kqm-live-dot {
	width: 0.6rem;
	height: 0.6rem;
	border-radius: 9999px;
	background: var(--kqm-emerald);
	animation: kqm-pulse 2s ease-in-out infinite;
}

@keyframes kqm-pulse {
	0%, 100% { opacity: 1; }
	50% { opacity: 0.4; }
}

/* ----- Buttons ----- */

.kqm-btn {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.65rem 1.4rem;
	border-radius: 9999px;
	border: 1px solid transparent;
	cursor: pointer;
	font-weight: 600;
	font-size: 0.9rem;
	transition: background-color 0.2s ease, color 0.2s ease, transform 0.1s ease, border-color 0.2s ease;
	text-decoration: none;
	font-family: inherit;
}

.kqm-btn:focus-visible {
	outline: 2px solid var(--kqm-gold);
	outline-offset: 3px;
}

.kqm-btn-primary,
button.kqm-btn-primary,
input.kqm-btn-primary {
	background: var(--kqm-gold);
	color: #000;
}

.kqm-btn-primary:hover,
button.kqm-btn-primary:hover,
input.kqm-btn-primary:hover {
	background: var(--kqm-gold-hover);
	color: #000;
}

a.kqm-btn-primary,
a.kqm-btn-primary:visited,
a.kqm-btn-primary:link,
a.kqm-btn-primary:hover {
	color: #000;
	text-decoration: none;
}

/* Defensive overrides for theme submit button styles.
 * Themes like Astra, GeneratePress, Hello Elementor target
 * button[type="submit"] / input[type="submit"] with their own styling.
 * These selectors raise specificity to win the cascade. */
button.kqm-btn,
button.kqm-btn-primary,
button[type="submit"].kqm-btn,
button[type="submit"].kqm-btn-primary,
input[type="submit"].kqm-btn,
input[type="submit"].kqm-btn-primary {
	background: var(--kqm-gold);
	color: #000;
	border: 1px solid var(--kqm-gold);
	font-family: inherit;
	cursor: pointer;
	text-shadow: none;
	box-shadow: none;
}

button.kqm-btn-primary:hover,
button[type="submit"].kqm-btn-primary:hover,
input[type="submit"].kqm-btn-primary:hover {
	background: var(--kqm-gold-hover);
	color: #000;
	border-color: var(--kqm-gold-hover);
}

button.kqm-btn-outline,
button[type="button"].kqm-btn-outline {
	background: transparent;
	color: #fff;
	border: 1px solid var(--kqm-gold);
	font-family: inherit;
	cursor: pointer;
	text-shadow: none;
	box-shadow: none;
}

button.kqm-btn-outline:hover,
button[type="button"].kqm-btn-outline:hover {
	background: rgba(201, 168, 76, 0.1);
	color: var(--kqm-gold);
	border-color: var(--kqm-gold);
}

.kqm-btn-lg {
	padding: 0.9rem 1.75rem;
	font-size: 1rem;
}

.kqm-btn-outline {
	background: transparent;
	color: #fff;
	border-color: var(--kqm-gold);
}

.kqm-btn-outline:hover {
	background: rgba(201, 168, 76, 0.1);
	color: var(--kqm-gold);
}

/* Safety net: if any anchor inherits a darker theme colour, force light */
a.kqm-btn-outline,
a.kqm-btn-outline:visited,
a.kqm-btn-outline:link {
	color: #fff;
	text-decoration: none;
}

a.kqm-btn-outline:hover {
	color: var(--kqm-gold);
}

.kqm-link {
	background: none;
	border: 0;
	color: var(--kqm-gold);
	font-size: 0.85rem;
	font-weight: 600;
	cursor: pointer;
	padding: 0.25rem 0.5rem;
	font-family: inherit;
}

.kqm-link:hover {
	color: var(--kqm-text);
}

/* ----- Map ----- */

.kqm-map-wrap {
	border: 1px solid var(--kqm-border);
	border-radius: var(--kqm-radius);
	overflow: hidden;
	box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.8);
	margin-bottom: 3rem;
	background: var(--kqm-bg-2);
	/* Contain Leaflet's internal pane z-indexes (200-1000 for tiles,
	 * markers, popups, controls) so they don't escape into the page's
	 * main stacking context and paint over the site header's drop-down
	 * menus. `isolation: isolate` creates a stacking context without
	 * needing position+z-index, which is the cleanest containment. */
	isolation: isolate;
	position: relative;
	z-index: 0;
}

.kqm-map {
	width: 100%;
	height: 520px;
}

@media (max-width: 700px) {
	.kqm-map {
		height: 380px;
	}
}

.kqm-noscript {
	padding: 1rem;
	color: var(--kqm-text-muted);
	background: var(--kqm-bg-3);
}

/* ----- Featured section ----- */

.kqm-section-header {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 1rem;
	margin-bottom: 1.5rem;
	flex-wrap: wrap;
}

.kqm-section-title {
	font-family: 'Playfair Display', Georgia, serif;
	font-size: 2rem;
	margin: 0;
	color: var(--kqm-text);
}

.kqm-section-sub {
	color: var(--kqm-text-muted);
	margin: 0;
	font-size: 0.95rem;
}

.kqm-empty {
	padding: 3rem;
	text-align: center;
	color: var(--kqm-text-faint);
	background: var(--kqm-bg-2);
	border: 1px solid var(--kqm-border-faint);
	border-radius: var(--kqm-radius);
}

.kqm-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 1.5rem;
}

/* Cap individual card width so a single card doesn't visually stretch */
.kqm-grid > .kqm-card {
	max-width: 420px;
	width: 100%;
}

@media (max-width: 960px) {
	.kqm-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 640px) {
	.kqm-grid {
		grid-template-columns: 1fr;
	}
}

.kqm-card {
	background: var(--kqm-bg-2);
	border: 1px solid var(--kqm-border-faint);
	border-radius: var(--kqm-radius);
	overflow: hidden;
	cursor: pointer;
	transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
	text-align: left;
	width: 100%;
	padding: 0;
	font-family: inherit;
	color: inherit;
}

.kqm-card:hover,
.kqm-card:focus-visible {
	transform: translateY(-4px);
	border-color: var(--kqm-border);
	box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.6);
	outline: none;
}

.kqm-card-media {
	position: relative;
	height: 200px;
	overflow: hidden;
	background: var(--kqm-bg-3);
}

.kqm-card-media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.7s ease;
}

.kqm-card:hover .kqm-card-media img {
	transform: scale(1.05);
}

/* Placeholder shown when a card has no image */
.kqm-card-media-empty {
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	color: var(--kqm-text-faint);
	font-size: 0.85rem;
	background: linear-gradient(135deg, #1a1a1a 0%, #111111 100%);
}

.kqm-badge {
	position: absolute;
	top: 0.75rem;
	right: 0.75rem;
	padding: 0.3rem 0.75rem;
	font-size: 0.7rem;
	font-weight: 700;
	letter-spacing: 0.05em;
	border-radius: 9999px;
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	z-index: 2;
}

.kqm-badge-live {
	background: var(--kqm-emerald);
	color: #fff;
}

.kqm-badge-done {
	background: rgba(255, 255, 255, 0.9);
	color: #000;
}

/* Photo count badge sits bottom-left of the card image */
.kqm-photo-count {
	position: absolute;
	bottom: 0.75rem;
	left: 0.75rem;
	background: rgba(0, 0, 0, 0.75);
	color: #fff;
	padding: 0.3rem 0.65rem;
	border-radius: 9999px;
	font-size: 0.75rem;
	font-weight: 500;
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	z-index: 2;
	backdrop-filter: blur(4px);
}

.kqm-photo-count svg {
	width: 0.85rem;
	height: 0.85rem;
}

.kqm-dot {
	width: 0.4rem;
	height: 0.4rem;
	border-radius: 9999px;
	background: currentColor;
	animation: kqm-pulse 2s ease-in-out infinite;
}

.kqm-card-body {
	padding: 1.25rem;
}

.kqm-card-head {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 1rem;
}

.kqm-card-title {
	font-weight: 600;
	font-size: 1.15rem;
	color: var(--kqm-text);
	line-height: 1.3;
	font-family: 'Playfair Display', Georgia, serif;
}

.kqm-card-region {
	color: var(--kqm-gold);
	font-size: 0.85rem;
	margin-top: 0.15rem;
}

.kqm-card-likes {
	text-align: right;
	flex-shrink: 0;
}

.kqm-card-likes-num {
	font-weight: 700;
	font-size: 1.1rem;
	display: block;
	color: var(--kqm-gold);
}

.kqm-card-likes-label {
	font-size: 0.7rem;
	color: var(--kqm-text-faint);
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

.kqm-card-excerpt {
	color: var(--kqm-text-muted);
	font-size: 0.9rem;
	margin: 0.75rem 0 0;
	line-height: 1.6;
}

.kqm-card-foot {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-top: 1rem;
	padding-top: 1rem;
	border-top: 1px solid var(--kqm-border-faint);
	font-size: 0.8rem;
}

.kqm-card-date {
	color: var(--kqm-text-faint);
}

.kqm-card-link {
	color: var(--kqm-gold);
	font-weight: 600;
}

.kqm-card:hover .kqm-card-link {
	text-decoration: underline;
}

/* ----- Modal ----- */

.kqm-modal {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1rem;
}

.kqm-modal[hidden] {
	display: none;
}

.kqm-modal-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.85);
	backdrop-filter: blur(6px);
}

.kqm-modal-panel {
	position: relative;
	background: var(--kqm-bg-2);
	color: var(--kqm-text);
	border: 1px solid var(--kqm-border);
	border-radius: var(--kqm-radius);
	max-width: 720px;
	width: 100%;
	max-height: 92vh;
	overflow-y: auto;
	animation: kqm-modal-pop 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
	box-shadow: 0 40px 80px -20px rgba(0, 0, 0, 0.9);
}

@keyframes kqm-modal-pop {
	from { opacity: 0; transform: scale(0.95); }
	to { opacity: 1; transform: scale(1); }
}

.kqm-modal-close {
	position: absolute;
	top: 0.75rem;
	right: 0.75rem;
	z-index: 5;
	width: 2.4rem;
	height: 2.4rem;
	background: rgba(0, 0, 0, 0.7);
	color: #fff;
	border: 1px solid var(--kqm-border-faint);
	border-radius: 9999px;
	font-size: 1.4rem;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	font-family: inherit;
}

.kqm-modal-close:hover {
	background: rgba(0, 0, 0, 0.9);
	border-color: var(--kqm-gold);
}

.kqm-modal-content {
	padding: 0;
}

.kqm-loading {
	padding: 3rem;
	text-align: center;
	color: var(--kqm-text-muted);
}

.kqm-modal-hero {
	position: relative;
	height: 320px;
	overflow: hidden;
	background: var(--kqm-bg-3);
}

.kqm-modal-hero img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	cursor: zoom-in;
}

.kqm-modal-hero-overlay {
	position: absolute;
	inset: 0;
	background: linear-gradient(to top, rgba(0, 0, 0, 0.95) 0%, rgba(0, 0, 0, 0.5) 50%, transparent 100%);
	pointer-events: none;
}

.kqm-modal-hero-text {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	padding: 1.5rem;
}

.kqm-modal-quest-title {
	font-family: 'Playfair Display', Georgia, serif;
	font-size: 2.25rem;
	margin: 0.5rem 0 0.25rem;
	color: #fff;
	line-height: 1.15;
}

.kqm-modal-quest-region {
	color: var(--kqm-gold);
	font-size: 1.1rem;
	margin: 0;
}

.kqm-modal-body {
	padding: 1.75rem;
}

.kqm-modal-meta {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
	gap: 1rem;
	margin-bottom: 1.5rem;
}

.kqm-modal-meta-item small {
	color: var(--kqm-text-faint);
	text-transform: uppercase;
	letter-spacing: 0.05em;
	font-size: 0.7rem;
	display: block;
}

.kqm-modal-meta-item strong {
	display: block;
	font-weight: 600;
	margin-top: 0.25rem;
	color: var(--kqm-text);
}

.kqm-divider {
	height: 1px;
	background: linear-gradient(to right, transparent, var(--kqm-gold), transparent);
	margin: 1.25rem 0;
}

.kqm-modal-story {
	color: var(--kqm-text);
	font-size: 1rem;
	line-height: 1.75;
}

.kqm-modal-story p {
	margin: 0 0 1rem;
}

/* Photo strip in the modal */
.kqm-photo-strip {
	display: flex;
	gap: 0.5rem;
	overflow-x: auto;
	overflow-y: hidden;
	margin: 1.25rem 0;
	padding-bottom: 0.5rem;
	scrollbar-width: thin;
	scrollbar-color: var(--kqm-gold) var(--kqm-bg-3);
}

.kqm-photo-strip::-webkit-scrollbar {
	height: 6px;
}

.kqm-photo-strip::-webkit-scrollbar-track {
	background: var(--kqm-bg-3);
	border-radius: 3px;
}

.kqm-photo-strip::-webkit-scrollbar-thumb {
	background: var(--kqm-gold);
	border-radius: 3px;
}

.kqm-photo-thumb {
	flex: 0 0 auto;
	width: 140px;
	height: 100px;
	border-radius: var(--kqm-radius-sm);
	overflow: hidden;
	cursor: zoom-in;
	background: var(--kqm-bg-3);
	border: 1px solid var(--kqm-border-faint);
	padding: 0;
	transition: border-color 0.15s ease, transform 0.15s ease;
}

.kqm-photo-thumb:hover,
.kqm-photo-thumb:focus-visible {
	border-color: var(--kqm-gold);
	outline: none;
	transform: scale(1.03);
}

.kqm-photo-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.kqm-modal-actions {
	display: flex;
	gap: 0.75rem;
	margin-top: 1.5rem;
	flex-wrap: wrap;
}

.kqm-modal-actions .kqm-btn {
	flex: 1;
	justify-content: center;
	min-width: 0;
}

/* ----- Lightbox ----- */

.kqm-lightbox {
	position: fixed;
	inset: 0;
	z-index: 100001;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, 0.95);
	padding: 2rem;
	animation: kqm-lightbox-fade 0.15s ease;
}

.kqm-lightbox[hidden] {
	display: none;
}

@keyframes kqm-lightbox-fade {
	from { opacity: 0; }
	to { opacity: 1; }
}

.kqm-lightbox img {
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
	border-radius: var(--kqm-radius-sm);
	box-shadow: 0 0 60px rgba(0, 0, 0, 0.8);
}

.kqm-lightbox-close {
	position: absolute;
	top: 1rem;
	right: 1rem;
	width: 2.75rem;
	height: 2.75rem;
	background: rgba(0, 0, 0, 0.7);
	color: #fff;
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: 9999px;
	font-size: 1.6rem;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	font-family: inherit;
	z-index: 2;
}

.kqm-lightbox-close:hover {
	background: rgba(0, 0, 0, 0.95);
	border-color: var(--kqm-gold);
}

.kqm-lightbox-prev,
.kqm-lightbox-next {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 3rem;
	height: 3rem;
	background: rgba(0, 0, 0, 0.7);
	color: #fff;
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: 9999px;
	font-size: 1.5rem;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	font-family: inherit;
	z-index: 2;
}

.kqm-lightbox-prev { left: 1rem; }
.kqm-lightbox-next { right: 1rem; }

.kqm-lightbox-prev:hover,
.kqm-lightbox-next:hover {
	background: rgba(0, 0, 0, 0.95);
	border-color: var(--kqm-gold);
}

.kqm-lightbox-counter {
	position: absolute;
	bottom: 1.25rem;
	left: 50%;
	transform: translateX(-50%);
	background: rgba(0, 0, 0, 0.7);
	color: #fff;
	padding: 0.4rem 1rem;
	border-radius: 9999px;
	font-size: 0.85rem;
	font-weight: 500;
}

/* ----- Submission form (dark theme) ----- */

.kqm-submit-wrap {
	max-width: 880px;
	margin: 0 auto;
}

.kqm-submit {
	background: var(--kqm-bg-2);
	color: var(--kqm-text);
	border: 1px solid var(--kqm-border-faint);
	border-radius: var(--kqm-radius);
	padding: 2.5rem;
	margin: 0 auto 3rem;
}

@media (max-width: 700px) {
	.kqm-submit {
		padding: 1.5rem;
	}
}

.kqm-submit .kqm-label {
	display: block;
	font-weight: 600;
	margin-bottom: 0.4rem;
	color: var(--kqm-text);
}

.kqm-submit .kqm-hint {
	color: var(--kqm-text-faint);
	font-size: 0.8rem;
	display: inline-block;
	margin-top: 0.25rem;
}

.kqm-form-row {
	margin-bottom: 1.5rem;
}

.kqm-form-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 1.25rem;
	margin-bottom: 1.5rem;
}

@media (max-width: 600px) {
	.kqm-form-grid {
		grid-template-columns: 1fr;
	}
}

.kqm-input {
	display: block;
	width: 100%;
	padding: 0.75rem 0.9rem;
	font-size: 1rem;
	border: 1px solid rgba(255, 255, 255, 0.15);
	border-radius: 0.5rem;
	background: var(--kqm-bg-3);
	color: var(--kqm-text);
	font-family: inherit;
	line-height: 1.4;
	transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.kqm-input::placeholder {
	color: var(--kqm-text-faint);
	opacity: 0.7;
}

.kqm-input:focus {
	outline: none;
	border-color: var(--kqm-gold);
	background: var(--kqm-bg-4);
	box-shadow: 0 0 0 3px rgba(201, 168, 76, 0.2);
}

/* Number spinner buttons - keep visible on dark */
.kqm-input[type="number"] {
	color-scheme: dark;
}

/* Select dropdown styling */
.kqm-input[type="select"],
select.kqm-input {
	appearance: none;
	-webkit-appearance: none;
	-moz-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='%23C9A84C' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 0.9rem center;
	background-size: 0.7rem;
	padding-right: 2.25rem;
}

select.kqm-input option {
	background: var(--kqm-bg-3);
	color: var(--kqm-text);
}

/* File input - WordPress-style "Browse" button */
input[type="file"].kqm-input {
	padding: 0.5rem;
	cursor: pointer;
}

input[type="file"].kqm-input::file-selector-button {
	margin-right: 0.75rem;
	padding: 0.45rem 1rem;
	border: 1px solid var(--kqm-gold);
	background: transparent;
	color: var(--kqm-gold);
	border-radius: 9999px;
	cursor: pointer;
	font-family: inherit;
	font-size: 0.85rem;
	font-weight: 600;
	transition: background 0.15s ease;
}

input[type="file"].kqm-input::file-selector-button:hover {
	background: rgba(201, 168, 76, 0.1);
}

.kqm-textarea {
	resize: vertical;
	min-height: 200px;
}

.kqm-fieldset {
	border: 1px solid var(--kqm-border-faint);
	border-radius: 0.75rem;
	padding: 1.25rem;
	margin-bottom: 1.5rem;
	background: rgba(0, 0, 0, 0.2);
}

.kqm-fieldset legend {
	padding: 0 0.5rem;
	color: var(--kqm-text);
	font-weight: 600;
}

.kqm-checkbox {
	display: flex;
	align-items: flex-start;
	gap: 0.65rem;
	margin: 0.75rem 0;
	cursor: pointer;
	font-size: 0.9rem;
	color: var(--kqm-text-muted);
	line-height: 1.5;
}

.kqm-checkbox input {
	margin-top: 0.2rem;
	flex-shrink: 0;
	accent-color: var(--kqm-gold);
	cursor: pointer;
}

.kqm-req {
	color: var(--kqm-gold);
	font-weight: 700;
}

/* Helper links in hints (e.g. itilog.com) */
.kqm-submit .kqm-hint a,
.kqm-submit a {
	color: var(--kqm-gold);
	text-decoration: underline;
}

.kqm-submit .kqm-hint a:hover {
	color: var(--kqm-gold-hover);
}

/* Notices */

.kqm-notice {
	padding: 1rem 1.25rem;
	border-radius: 0.75rem;
	margin-bottom: 1.5rem;
	font-weight: 500;
}

.kqm-notice-success {
	background: rgba(59, 184, 138, 0.15);
	color: #6ee7b7;
	border: 1px solid rgba(59, 184, 138, 0.4);
}

.kqm-notice-error {
	background: rgba(220, 38, 38, 0.15);
	color: #fca5a5;
	border: 1px solid rgba(220, 38, 38, 0.4);
}

/* Word counter colour signalling - JS toggles class on the span */
.kqm-submit [data-kqm-wordcount] {
	color: var(--kqm-gold);
	font-weight: 600;
}

/* ----- Leaflet pin (campervan icon) ----- */

.kqm-pin-wrap {
	background: none !important;
	border: 0 !important;
	pointer-events: auto;
}

.kqm-pin {
	width: 44px;
	height: 32px;
	cursor: pointer;
	filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.45));
	transition: transform 0.15s ease;
	position: relative;
	z-index: 2;
}

.kqm-pin svg {
	width: 100%;
	height: 100%;
	display: block;
}

.kqm-pin:hover,
.kqm-pin:focus-visible {
	transform: translateY(-3px) scale(1.1);
	outline: none;
}

/* Soft pulsing ground shadow underneath the van */
.kqm-pin-shadow {
	position: absolute;
	bottom: -3px;
	left: 50%;
	transform: translateX(-50%);
	width: 30px;
	height: 8px;
	border-radius: 50%;
	background: radial-gradient(ellipse, rgba(201, 168, 76, 0.5) 0%, rgba(201, 168, 76, 0) 70%);
	animation: kqm-pin-pulse 2s ease-in-out infinite;
	pointer-events: none;
	z-index: 1;
}

@keyframes kqm-pin-pulse {
	0%, 100% {
		transform: translateX(-50%) scale(1);
		opacity: 0.7;
	}
	50% {
		transform: translateX(-50%) scale(1.3);
		opacity: 0.35;
	}
}

/* ----- Card foot adjustments (3-column layout) ----- */

.kqm-card-foot {
	flex-wrap: wrap;
	gap: 0.5rem;
}

.kqm-card-photos-link {
	color: var(--kqm-text-muted);
	font-size: 0.8rem;
	display: inline-flex;
	align-items: center;
	gap: 0.3rem;
	flex-basis: 100%;
	margin-top: 0.5rem;
	padding-top: 0.5rem;
	border-top: 1px dashed var(--kqm-border-faint);
	transition: color 0.15s ease;
}

.kqm-card:hover .kqm-card-photos-link {
	color: var(--kqm-gold);
}

/* ----- Page sections (How it works / Why submit / Recent / CTA) ----- */

.kqm-section {
	margin-top: 4rem;
	padding-top: 2rem;
}

.kqm-section-title-wrap {
	text-align: center;
	margin-bottom: 2.5rem;
}

.kqm-section-title-wrap .kqm-section-title {
	font-family: 'Playfair Display', Georgia, serif;
	font-size: 2.25rem;
	margin: 0 0 0.5rem;
	color: var(--kqm-text);
}

.kqm-section-title-wrap .kqm-section-sub {
	color: var(--kqm-text-muted);
	margin: 0;
	font-size: 1rem;
}

/* How it works - 3 numbered steps */

.kqm-steps {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 1.5rem;
}

@media (max-width: 900px) {
	.kqm-steps {
		grid-template-columns: 1fr;
		max-width: 480px;
		margin: 0 auto;
	}
}

.kqm-step {
	background: var(--kqm-bg-2);
	border: 1px solid var(--kqm-border-faint);
	border-radius: var(--kqm-radius);
	padding: 2rem 1.5rem;
	text-align: center;
	transition: border-color 0.2s ease, transform 0.2s ease;
}

.kqm-step:hover {
	border-color: var(--kqm-border);
	transform: translateY(-3px);
}

.kqm-step-num {
	font-family: 'Playfair Display', Georgia, serif;
	font-size: 2.5rem;
	font-weight: 700;
	color: var(--kqm-gold);
	line-height: 1;
	margin-bottom: 1rem;
}

.kqm-step-title {
	font-family: 'Playfair Display', Georgia, serif;
	font-size: 1.35rem;
	color: var(--kqm-text);
	margin: 0 0 0.75rem;
}

.kqm-step-body {
	color: var(--kqm-text-muted);
	margin: 0;
	font-size: 0.95rem;
	line-height: 1.6;
}

/* Why submit - 3 benefits with icon */

.kqm-benefits {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 1.5rem;
}

@media (max-width: 900px) {
	.kqm-benefits {
		grid-template-columns: 1fr;
		max-width: 480px;
		margin: 0 auto;
	}
}

.kqm-benefit {
	background: var(--kqm-bg-2);
	border: 1px solid var(--kqm-border-faint);
	border-radius: var(--kqm-radius);
	padding: 2rem 1.5rem;
	text-align: center;
}

.kqm-benefit-icon {
	width: 4rem;
	height: 4rem;
	margin: 0 auto 1rem;
	border-radius: 9999px;
	background: rgba(201, 168, 76, 0.1);
	border: 1px solid var(--kqm-border);
	color: var(--kqm-gold);
	display: flex;
	align-items: center;
	justify-content: center;
}

.kqm-benefit-icon svg {
	width: 1.75rem;
	height: 1.75rem;
}

.kqm-benefit-title {
	font-family: 'Playfair Display', Georgia, serif;
	font-size: 1.25rem;
	color: var(--kqm-text);
	margin: 0 0 0.75rem;
}

.kqm-benefit-body {
	color: var(--kqm-text-muted);
	margin: 0;
	font-size: 0.95rem;
	line-height: 1.6;
}

/* Recent quests strip */

.kqm-recent-strip {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 1rem;
}

@media (max-width: 900px) {
	.kqm-recent-strip {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 560px) {
	.kqm-recent-strip {
		grid-template-columns: 1fr;
	}
}

.kqm-recent-card {
	background: var(--kqm-bg-2);
	border: 1px solid var(--kqm-border-faint);
	border-radius: var(--kqm-radius-sm);
	overflow: hidden;
	cursor: pointer;
	font-family: inherit;
	color: inherit;
	text-align: left;
	padding: 0;
	display: flex;
	gap: 0.75rem;
	align-items: center;
	transition: border-color 0.15s ease, transform 0.15s ease;
}

.kqm-recent-card:hover,
.kqm-recent-card:focus-visible {
	border-color: var(--kqm-border);
	transform: translateY(-2px);
	outline: none;
}

.kqm-recent-media {
	flex: 0 0 90px;
	width: 90px;
	height: 90px;
	overflow: hidden;
	background: var(--kqm-bg-3);
}

.kqm-recent-media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.kqm-recent-body {
	padding: 0.75rem 1rem 0.75rem 0;
	min-width: 0;
	flex: 1;
}

.kqm-recent-title {
	font-family: 'Playfair Display', Georgia, serif;
	font-size: 1rem;
	font-weight: 600;
	color: var(--kqm-text);
	line-height: 1.3;
	margin-bottom: 0.25rem;
	overflow: hidden;
	text-overflow: ellipsis;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
}

.kqm-recent-meta {
	color: var(--kqm-text-faint);
	font-size: 0.8rem;
}

/* CTA strip */

.kqm-cta-strip {
	margin-top: 4rem;
	padding: 2.5rem 2rem;
	background: var(--kqm-bg);
	border: 1px solid var(--kqm-border);
	border-radius: var(--kqm-radius);
	text-align: center;
	box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.5);
}

.kqm-cta-strip-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 2rem;
	flex-wrap: wrap;
	max-width: 900px;
	margin: 0 auto;
}

.kqm-cta-strip-inner > div {
	text-align: left;
	flex: 1;
	min-width: 280px;
}

@media (max-width: 640px) {
	.kqm-cta-strip-inner {
		flex-direction: column;
		text-align: center;
	}
	.kqm-cta-strip-inner > div {
		text-align: center;
		min-width: 0;
	}
}

.kqm-cta-title {
	font-family: 'Playfair Display', Georgia, serif;
	font-size: 1.75rem;
	color: var(--kqm-text);
	margin: 0 0 0.5rem;
}

.kqm-cta-sub {
	color: var(--kqm-text-muted);
	margin: 0;
	font-size: 1rem;
}

.kqm-cta-admin-notice {
	margin: 0.75rem 0 0;
	padding: 0.5rem 0.85rem;
	background: rgba(201, 168, 76, 0.15);
	border: 1px dashed var(--kqm-border);
	border-radius: 0.5rem;
	color: var(--kqm-gold);
	font-size: 0.8rem;
	font-style: italic;
}

.kqm-cta-admin-notice a {
	color: var(--kqm-gold);
	text-decoration: underline;
	font-weight: 600;
}

/* ----- Fade-to-white text colour adjustments -----
 *
 * The fade gradient itself lives on .kqm-fullbleed--has-fade above; here
 * we just tweak text colours in the last section so they remain readable
 * as the background gets lighter.
 */

.kqm-fullbleed--has-fade .kqm-section--last .kqm-section-title-wrap .kqm-section-title,
.kqm-fullbleed--has-fade .kqm-section--last .kqm-cta-title {
	color: var(--kqm-text);
}

/* CTA strip remains a dark island regardless of where it sits in the page. */

/* ----- Location picker on the submission form ----- */

.kqm-picker-search {
	display: flex;
	gap: 0.5rem;
	margin: 1rem 0 0.5rem;
	flex-wrap: wrap;
}

.kqm-picker-search .kqm-input {
	flex: 1 1 240px;
	min-width: 200px;
	margin: 0;
}

.kqm-picker-search .kqm-btn {
	flex-shrink: 0;
}

/* Geolocate button - SVG icon + text label */
.kqm-btn-geolocate {
	display: inline-flex !important;
	align-items: center;
	gap: 0.4rem;
}

.kqm-btn-geolocate svg {
	flex-shrink: 0;
}

@media (max-width: 480px) {
	.kqm-picker-search .kqm-input {
		flex-basis: 100%;
	}
	.kqm-picker-search .kqm-btn {
		flex: 1;
		justify-content: center;
	}
}

.kqm-picker-results {
	margin: 0 0 0.75rem;
	background: var(--kqm-bg-3);
	border: 1px solid var(--kqm-border-faint);
	border-radius: 0.5rem;
	max-height: 240px;
	overflow-y: auto;
}

.kqm-picker-result-list {
	list-style: none;
	margin: 0;
	padding: 0.25rem;
}

.kqm-picker-result-item {
	width: 100%;
	text-align: left;
	background: transparent;
	border: 0;
	color: var(--kqm-text);
	padding: 0.6rem 0.85rem;
	font-family: inherit;
	font-size: 0.9rem;
	cursor: pointer;
	border-radius: 0.35rem;
	transition: background 0.15s ease;
	line-height: 1.4;
}

.kqm-picker-result-item:hover,
.kqm-picker-result-item:focus-visible {
	background: rgba(201, 168, 76, 0.15);
	outline: none;
}

.kqm-picker-map {
	width: 100%;
	height: 380px;
	border-radius: var(--kqm-radius-sm);
	border: 1px solid var(--kqm-border);
	margin-bottom: 0.5rem;
	overflow: hidden;
	background: var(--kqm-bg-3);
}

@media (max-width: 600px) {
	.kqm-picker-map {
		height: 300px;
	}
}

/* Make sure the kqm-pin works inside the picker map too */
.kqm-picker-map .kqm-pin {
	cursor: grab;
}
.kqm-picker-map .kqm-pin:active {
	cursor: grabbing;
}

/* ----- Video embed in modal ----- */

.kqm-modal-video {
	margin: 1.25rem 0;
	border-radius: var(--kqm-radius-sm);
	overflow: hidden;
	background: #000;
}

.kqm-video-embed {
	position: relative;
	width: 100%;
	aspect-ratio: 16 / 9;
}

/* Force iframes/embeds inside the wrapper to fill responsively. */
.kqm-video-embed iframe,
.kqm-video-embed object,
.kqm-video-embed embed,
.kqm-video-embed video {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	border: 0;
	display: block;
}

/* Fallback for browsers without aspect-ratio support (very old). */
@supports not (aspect-ratio: 16 / 9) {
	.kqm-video-embed {
		padding-bottom: 56.25%;
		height: 0;
	}
}

/* ----- Z-index defence for page navigation -----
 *
 * Themes that don't set z-index on their header (especially Hello Elementor
 * with no extra styling) cause dropdown menus to render behind subsequent
 * positioned content. The fix lives here so it's automatic - no theme edits
 * needed - and is scoped via :has() to only apply on pages that contain our
 * shortcode, so other pages keep their original behaviour.
 *
 * Browser support: :has() ships in Chrome 105+, Safari 15.4+, Firefox 121+.
 * Older browsers fall back to the original (broken) behaviour, which is
 * the same as before this plugin was installed.
 *
 * The selector list deliberately covers common patterns across themes and
 * page-builder header types. Each rule only adds z-index, leaving the
 * existing position untouched - this preserves position: sticky / fixed
 * that themes may rely on for sticky headers.
 */

body:has(.kqm-fullbleed) header,
body:has(.kqm-fullbleed) [role="banner"],
body:has(.kqm-fullbleed) .site-header,
body:has(.kqm-fullbleed) .main-header,
body:has(.kqm-fullbleed) #masthead,
body:has(.kqm-fullbleed) #site-header,
body:has(.kqm-fullbleed) #header,
body:has(.kqm-fullbleed) .elementor-location-header,
body:has(.kqm-fullbleed) [data-elementor-type="header"],
body:has(.kqm-fullbleed) .ehp-header,
body:has(.kqm-fullbleed) .site-branding,
body:has(.kqm-fullbleed) .elementor-section.elementor-top-section:first-of-type {
	/* z-index needs a positioned element to take effect. Use relative
	 * only as a fallback - sticky/fixed positioning (often set by the
	 * theme for sticky headers) wins over relative if both are set,
	 * so we don't break that pattern. */
	position: relative;
	z-index: 999;
}

/* Dropdown / sub-menu containers - lift to a value higher than the
 * header itself, so they always paint above everything when open. */
body:has(.kqm-fullbleed) .elementor-nav-menu .sub-menu,
body:has(.kqm-fullbleed) .elementor-nav-menu--dropdown,
body:has(.kqm-fullbleed) .menu-item-has-children .sub-menu,
body:has(.kqm-fullbleed) ul.sub-menu,
body:has(.kqm-fullbleed) .kcc-mega-menu ul.sub-menu,
body:has(.kqm-fullbleed) .kcc-mega-column {
	z-index: 1000;
}

/* ----- Team reply in modal -----
 *
 * A distinctive block that makes it visually clear this isn't part of
 * the submitter's story - it's an official reply from the team. Gold
 * left-border accent + slightly different background. Heading uses the
 * branded gold colour.
 */

.kqm-modal-reply {
	margin: 1.5rem 0 0.5rem;
	padding: 1.25rem 1.5rem;
	background: rgba(201, 168, 76, 0.08);
	border-left: 3px solid var(--kqm-gold);
	border-radius: 0 var(--kqm-radius-sm) var(--kqm-radius-sm) 0;
}

.kqm-modal-reply__heading {
	font-family: var(--kqm-font-display, 'Playfair Display', serif);
	font-size: 1.1rem;
	font-weight: 600;
	color: var(--kqm-gold);
	margin-bottom: 0.5rem;
	letter-spacing: 0.01em;
}

.kqm-modal-reply__body {
	color: var(--kqm-text);
	line-height: 1.6;
	font-size: 0.95rem;
}

.kqm-modal-reply__body p:first-child {
	margin-top: 0;
}

.kqm-modal-reply__body p:last-child {
	margin-bottom: 0;
}

.kqm-modal-reply__body a {
	color: var(--kqm-gold);
	text-decoration: underline;
}

.kqm-modal-reply__body a:hover {
	text-decoration: none;
}

/* ----- Quest grid pagination ----- */

.kqm-pagination {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.75rem;
	margin: 2.5rem 0 1rem;
	flex-wrap: wrap;
	font-family: var(--kqm-font-body, 'Inter', sans-serif);
}

.kqm-pagination__btn {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	padding: 0.55rem 1.1rem;
	border-radius: 9999px;
	border: 1px solid var(--kqm-border);
	color: var(--kqm-text);
	background: var(--kqm-bg-3);
	text-decoration: none;
	font-size: 0.9rem;
	font-weight: 500;
	transition: border-color 0.2s ease, color 0.2s ease, background-color 0.2s ease;
}

.kqm-pagination__btn:hover,
.kqm-pagination__btn:focus-visible {
	border-color: var(--kqm-gold);
	color: var(--kqm-gold);
	background: rgba(201, 168, 76, 0.06);
}

.kqm-pagination__pages {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.kqm-pagination__page {
	display: inline-flex;
}

.kqm-pagination__page a,
.kqm-pagination__page--current {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2.25rem;
	height: 2.25rem;
	padding: 0 0.65rem;
	border-radius: 0.5rem;
	font-size: 0.9rem;
	font-weight: 500;
	color: var(--kqm-text-muted);
	text-decoration: none;
	transition: color 0.2s ease, background-color 0.2s ease;
}

.kqm-pagination__page a:hover,
.kqm-pagination__page a:focus-visible {
	color: var(--kqm-gold);
	background: rgba(201, 168, 76, 0.08);
}

.kqm-pagination__page--current {
	color: var(--kqm-bg);
	background: var(--kqm-gold);
	font-weight: 600;
	cursor: default;
}

.kqm-pagination__ellipsis {
	color: var(--kqm-text-faint);
	padding: 0 0.25rem;
	user-select: none;
}

/* On narrow screens, stack the prev/pages/next more loosely. */
@media (max-width: 480px) {
	.kqm-pagination {
		gap: 0.5rem;
	}
	.kqm-pagination__pages {
		order: 3;
		width: 100%;
		justify-content: center;
	}
	.kqm-pagination__btn {
		font-size: 0.85rem;
		padding: 0.5rem 0.9rem;
	}
}

/* ----- Welcome-back banner for returning submitters ----- */

.kqm-welcome-back {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding: 1rem 1.25rem;
	margin-bottom: 1.5rem;
	background: rgba(201, 168, 76, 0.08);
	border: 1px solid rgba(201, 168, 76, 0.3);
	border-left: 3px solid var(--kqm-gold);
	border-radius: var(--kqm-radius-sm);
	color: var(--kqm-text);
	font-size: 0.92rem;
	flex-wrap: wrap;
}

.kqm-welcome-back__text strong {
	color: var(--kqm-gold);
	font-weight: 600;
	margin-right: 0.4rem;
}

.kqm-welcome-back__clear {
	background: transparent;
	border: none;
	color: var(--kqm-text-muted);
	font-size: 0.85rem;
	text-decoration: underline;
	cursor: pointer;
	padding: 0;
	font-family: inherit;
	white-space: nowrap;
	transition: color 0.2s ease;
}

.kqm-welcome-back__clear:hover,
.kqm-welcome-back__clear:focus-visible {
	color: var(--kqm-gold);
}

/* ----- Email-recovery prefill (cross-device returning submitters) ----- */

.kqm-prefill-email {
	margin-bottom: 1.5rem;
	padding: 0;
	border: 1px solid var(--kqm-border);
	border-radius: var(--kqm-radius-sm);
	background: var(--kqm-bg-3);
	overflow: hidden;
}

.kqm-prefill-email__summary {
	cursor: pointer;
	padding: 0.85rem 1.25rem;
	font-size: 0.9rem;
	color: var(--kqm-text-muted);
	font-weight: 500;
	user-select: none;
	transition: color 0.2s ease, background-color 0.2s ease;
	list-style: none;
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

/* Custom disclosure arrow, since `list-style: none` removes the default. */
.kqm-prefill-email__summary::before {
	content: '›';
	display: inline-block;
	font-size: 1.1rem;
	color: var(--kqm-gold);
	transition: transform 0.2s ease;
	font-weight: 700;
}

.kqm-prefill-email[open] .kqm-prefill-email__summary::before {
	transform: rotate(90deg);
}

.kqm-prefill-email__summary:hover,
.kqm-prefill-email__summary:focus-visible {
	color: var(--kqm-gold);
	background: rgba(201, 168, 76, 0.04);
}

/* Hide the native marker in Chrome/Safari. */
.kqm-prefill-email__summary::-webkit-details-marker {
	display: none;
}

.kqm-prefill-email__body {
	padding: 0 1.25rem 1.25rem;
	border-top: 1px solid var(--kqm-border);
	padding-top: 1rem;
}

.kqm-prefill-email__intro {
	margin: 0 0 0.85rem;
	font-size: 0.88rem;
	color: var(--kqm-text-muted);
	line-height: 1.5;
}

.kqm-prefill-email__row {
	display: flex;
	gap: 0.5rem;
	flex-wrap: wrap;
	align-items: stretch;
}

.kqm-prefill-email__row .kqm-input {
	flex: 1 1 220px;
	min-width: 0;
}

.kqm-prefill-email__row .kqm-btn {
	flex: 0 0 auto;
}

.kqm-prefill-email__notice {
	margin-top: 0.75rem;
	padding: 0.65rem 0.9rem;
	border-radius: var(--kqm-radius-sm);
	font-size: 0.88rem;
	line-height: 1.4;
}

.kqm-prefill-email__notice--success {
	background: rgba(59, 184, 138, 0.12);
	color: #6ee7b7;
	border: 1px solid rgba(59, 184, 138, 0.3);
}

.kqm-prefill-email__notice--error {
	background: rgba(220, 38, 38, 0.12);
	color: #fca5a5;
	border: 1px solid rgba(220, 38, 38, 0.3);
}

/* Tiny screens: button drops below the input. */
@media (max-width: 420px) {
	.kqm-prefill-email__row {
		flex-direction: column;
	}
	.kqm-prefill-email__row .kqm-input,
	.kqm-prefill-email__row .kqm-btn {
		width: 100%;
	}
}
