﻿/* /assets/css/bureau-chat.css
   Tokenized version: all colors moved into :root vars for easy tuning.
*/

/* =========================
   THEME TOKENS
   ========================= */
:root {
	/* =========================
	   Purple roles (banner-aligned)
	   ========================= */
	--bureau-purple-brand: #471368; /* identity anchor */
	--bureau-purple-ui: #6b2fa3; /* lifted for dark UI fills */
	--bureau-purple-ui-soft: rgba(107, 47, 163, 0.30);
	--bureau-purple-ui-hover: rgba(107, 47, 163, 0.42);
	--bureau-purple-ui-border: rgba(107, 47, 163, 0.70);
	--bureau-purple-ui-glow: #8a49d3;
	/* =========================
	   Foundation (darker, hero-matched indigo blacks)
	   ========================= */
	--bureau-black: #0b0a10;
	--bureau-bg: #12101a;
	--bureau-surface: #181626;
	--bureau-surface-2: #1f1c31;
	/* =========================
	   Borders / hairlines
	   ========================= */
	--bureau-border: #2a2640;
	--bureau-border-2: #363150;
	--bureau-hairline: rgba(255, 255, 255, 0.06);
	--bureau-hairline-strong: rgba(255, 255, 255, 0.10);
	/* =========================
	   Text
	   ========================= */
	--bureau-text: #f2eef7;
	--bureau-muted: #b8b2d6;
	--bureau-muted-2: #8f89ad;
	/* =========================
	   Accent (brand anchor)
	   ========================= */
	--bureau-accent: var(--bureau-purple-brand);
	--bureau-accent-2: rgba(71, 19, 104, 0.20);
	--bureau-accent-glow: #7b2dbf; /* highlight/glow tone */
	/* =========================
	   Component sizing / shape
	   ========================= */
	--bureau-radius: 18px;
	--bureau-radius-sm: 12px;
	/* =========================
	   Shadow
	   ========================= */
	--bureau-shadow: 0 18px 60px #523c6e, 0 18px 60px #523c6e;
	/* =========================
	   Fonts
	   ========================= */
	--bureau-font: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, "Apple Color Emoji", "Segoe UI Emoji";
	--bureau-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
	/* =========================
	   COLOR TOKENS (tokenized from rules below)
	   ========================= */
	/* Card background gradients */
	--bureau-card-grad-1: radial-gradient(1200px 800px at 20% 10%, rgba(71, 19, 104, 0.18), transparent 55%);
	--bureau-card-grad-2: radial-gradient(900px 700px at 80% 30%, rgba(255, 255, 255, 0.05), transparent 60%);
	--bureau-card-bg: var(--bureau-bg);
	/* Card edges */
	--bureau-card-border: var(--bureau-border-2);
	--bureau-card-outline: rgba(255, 255, 255, 0.05);
	/* Toolbar */
	--bureau-toolbar-bg: linear-gradient(to bottom, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
	--bureau-toolbar-border: var(--bureau-border);
	/* Suggestions */
	--bureau-suggestions-bg: rgba(255, 255, 255, 0.03);
	--bureau-suggestions-border: var(--bureau-border);
	--bureau-suggestion-bg: rgba(255, 255, 255, 0.03);
	--bureau-suggestion-border: var(--bureau-border-2);
	--bureau-suggestion-hover-bg: rgba(255, 255, 255, 0.06);
	--bureau-suggestion-hover-border: rgba(255, 255, 255, 0.20);
	/* Thread well */
	--bureau-thread-bg: rgba(0, 0, 0, 0.26);
	--bureau-thread-border: var(--bureau-border);
	--bureau-thread-inset: inset 0 0 0 1px rgba(255, 255, 255, 0.03);
	/* Scrollbar */
	--bureau-scrollbar-thumb: rgba(255, 255, 255, 0.14);
	--bureau-scrollbar-thumb-hover: rgba(255, 255, 255, 0.20);
	--bureau-scrollbar-thumb-border: rgba(0, 0, 0, 0.15);
	/* Message bubbles */
	--bureau-bubble-bg: rgba(255, 255, 255, 0.04);
	--bureau-bubble-border: var(--bureau-border);
	--bureau-bubble-user-bg: linear-gradient( 180deg, var(--bureau-purple-ui), rgba(107, 47, 163, 0.45) );
	--bureau-bubble-user-border: var(--bureau-purple-ui-border);
	/* --bureau-bubble-assistant-bg: rgba(255, 255, 255, 0.03); */
	--bureau-bubble-assistant-bg: rgb(0 0 0 / 50%);
	/* --bureau-bubble-assistant-border: rgba(255, 255, 255, 0.12); */
	/* Links */
	--bureau-bubble-assistant-border: rgb(255 255 255 / 25%);
	--bureau-link: rgba(210, 185, 255, 0.95);
	/* Blockquote */
	--bureau-blockquote-border: rgba(255, 255, 255, 0.18);
	--bureau-blockquote-bg: rgba(0, 0, 0, 0.18);
	--bureau-blockquote-text: rgba(255, 255, 255, 0.80);
	/* Code */
	--bureau-pre-bg: rgba(0, 0, 0, 0.35);
	--bureau-pre-border: rgba(255, 255, 255, 0.10);
	--bureau-code-bg: rgba(0, 0, 0, 0.25);
	--bureau-code-border: rgba(255, 255, 255, 0.08);
	/* Tables */
	--bureau-table-border: rgba(255, 255, 255, 0.10);
	--bureau-table-bg: rgba(0, 0, 0, 0.20);
	--bureau-table-row-border: rgba(255, 255, 255, 0.08);
	--bureau-table-th-bg: rgba(255, 255, 255, 0.05);
	--bureau-table-th-text: rgba(255, 255, 255, 0.85);
	/* HR */
	--bureau-hr: rgba(255, 255, 255, 0.10);
	/* Composer */
	--bureau-composer-bg: rgba(0, 0, 0, 0.22);
	--bureau-composer-border: var(--bureau-border);
	/* Input */
	--bureau-input-bg: rgba(255, 255, 255, 0.1);
	--bureau-input-border: rgba(255, 255, 255, 0.10);
	--bureau-input-placeholder: rgba(255, 255, 255, 0.45);
	--bureau-input-focus-border: rgba(71, 19, 104, 0.70);
	--bureau-input-focus-ring: var(--bureau-accent-2);
	/* Buttons (UI purple, banner-aligned) */
	--bureau-button-border: var(--bureau-purple-ui-border);
	--bureau-button-bg: var(--bureau-purple-ui-soft);
	--bureau-button-hover-bg: var(--bureau-purple-ui-hover);
	--bureau-button-hover-border: var(--bureau-purple-ui-border);
	/* Thinking dots */
	--bureau-dot-bg: rgba(255, 255, 255, 0.35);
}


.bureau-chat-container {
	position: fixed;
	top: 0;
	left: 0;
	/* background: rgb(0 0 0 / 80%); */
	width: 100vw;
	height: 100vh;
	display: block;
	max-height: 0;
	z-index: 1;
}

body:has(.bureau-chat-container[data-status="prime"]),
body:has(.bureau-chat-container[data-status="chat"]) {
	overflow: hidden;
}

.bureau-chat-container[data-status="prime"],
.bureau-chat-container[data-status="chat"] {
	max-height: 100vh;
	backdrop-filter: blur(4px) brightness(0.5);
	overflow-x: hidden;
	overflow-y: auto;
}

body:has(.bureau-chat-container[data-status="chat"]) .header-bar {
	display: none;
}


body:has(.bureau-chat-container[data-status="prime"]) .ask-pill {
	left: 50%;
	transform: translateX(-50%);
	border-radius: 0;
	width: 65vw;
}


body:has(.bureau-chat-container[data-status="prime"]) .home-btn,
body:has(.bureau-chat-container[data-status="chat"]) .home-btn {
	display: none;
}


.bureau-chat-resume {
	width: 70px;
	position: relative;
	padding-top: 48px;
	cursor: pointer;
	display: none;
	transform-origin: center;
	animation: bureauPulse 2.8s ease-in-out infinite;
}

html[data-node="AI"][data-chat]:not([data-chat="0"]) .bureau-chat-resume {
	display: inline-block;
}



.bureau-chat-resume img {
}

.bureau-chat-resume-bubble {
	background: #4c196b; /* keep yours */
	border-radius: 50%;
	position: absolute;
	top: 45px;
	right: 1px;
	width: 28px; /* enforce circle */
	height: 28px; /* enforce circle */
	padding: 0; /* avoid oval */
	display: flex; /* center the number */
	align-items: center;
	justify-content: center;
	color: #fff;
	line-height: 1;
	white-space: nowrap;
	font-size: 12px;
	box-shadow: 0 0 6px #fff;
}



html[data-node="AI"][data-chat]:not([data-chat="0"]) .ask-pill {
	display: none;
}

.bureau-chat-primer-wrap {
	overflow: hidden;
	background-image: radial-gradient(circle at 0 0, var(--bureau-purple) 0%, #6d006b 5%, var(--deep-blue) 100%);
	box-shadow: 0px 6px 12px #000;
	transition: max-height 1s ease, opacity 180ms ease;
	max-height: 0;
	overflow: hidden;
	/* opacity: 0; */
	background: radial-gradient(circle at 0% 5%, var(--agency-purple) 0%, #6d006b 5%, var(--deep-blue) 60%, var(--black) 100%);
}


.bureau-chat-container[data-status="prime"] .bureau-chat-primer-wrap {
	max-height: none;
}




.bureau-chat-primer {
	margin: 5%;
	color: #fff;
	padding-top: 42px;
}


/* mobile-first */
.bureau-chat-prime-pills {
	display: grid;
	gap: 16px;
	padding: 32px;
	/* default (mobile): 1 column */
	padding-bottom: 16px;
	grid-template-columns: 1fr;
	/* equal height within each row */
	align-items: stretch;
}


.bureau-chat-prime-pill {
	background: var(--bureau-bg);
	border: 1px solid rgb(255 255 255 / 25%);
	padding: 24px;
	font-size: 14px;
	background: var(--bureau-bg);
	display: flex;
	flex-direction: row;
	justify-content: space-between;
	align-items: center;
	flex-wrap: nowrap;
}

	.bureau-chat-prime-pill span.text {
		color: #fff;
	}

	.bureau-chat-prime-pill:hover {
		background: unset;
		background-blend-mode: multiply;
	}

.bureau-chat-prime-pills.secondary-pills .bureau-chat-prime-pill {
	/* background:red; */
	padding: unset;
	font-size: 12px;
}



.bureau-chat-panel-wrap {
	width: 100vw;
	background-image: radial-gradient(circle at 50% 50%, var(--bureau-purple) 0%, #6d006b 5%, var(--deep-blue) 100%);
	/* display: none; */
	transition: max-height 1s ease, opacity 180ms ease;
	max-height: 0;
	overflow: hidden;
}


.bureau-chat-container[data-status="chat"] .bureau-chat-panel-wrap {
	max-height: 100vh;
	max-height: 100dvh;
	height: 100dvh;
}

.bureau-chat-primer-outro {
	text-align: center;
	text-transform: uppercase;
	letter-spacing: 4px;
}


/* --- Hard reset for this component (prevents site styles bleeding in) --- */
.bureau-chat,
.bureau-chat * {
	box-sizing: border-box;
}

.bureau-chat {
	text-align: left; /* stop inherited center alignment */
	line-height: 1.4; /* explicit baseline */
	letter-spacing: normal; /* avoid global tweaks */
}


.bureau-chat-close {
	width: unset;
	height: unset;
	padding: 0 12px;
	align-items: center;
	justify-content: center;
	position: relative;
	z-index: 1;
}

.bureau-chat-close-icon {
	width: 14px;
	height: auto;
	aspect-ratio: 37 / 32;
	z-index: 1;
}

/* Ensure typical block elements inside markdown stay left-aligned too */
.bureau-chat .bureau-msg-body,
.bureau-chat .bureau-msg-body * {
	text-align: left;
}

/* --- Width behavior (prevents "narrow when empty") --- */
/* Use clamp so it has a real minimum, but still responds on small screens. */
.bureau-chat {
	/* width: clamp(520px, 70vw, 1100px); */
	/* min-width: 520px; */ /* optional redundancy */
	/* max-width: 1100px; */ /* optional redundancy */
	margin: 0 auto;
}

/* On small screens, allow it to shrink without horizontal scroll */
@media (max-width: 560px) {
	.bureau-chat {
		width: 100%;
		min-width: 0;
	}
}

/* Card wrapper */
.bureau-chat {
	font-family: var(--bureau-font);
	color: var(--bureau-text);
	background: var(--bureau-card-grad-1), var(--bureau-card-grad-2), var(--bureau-card-bg);
	border: 1px solid var(--bureau-card-border);
	border-radius: 0;
	box-shadow: var(--bureau-shadow);
	outline: 1px solid var(--bureau-card-outline);
	outline-offset: -1px;
	/* Card height constraint so thread scrolls inside */
	height: clamp(520px, 72vh, 860px);
	/* Core layout */
	display: flex;
	flex-direction: column;
	/* Safe spacing */
	padding: 34px;
	height: 100%;
	/* margin: 5%; */
}

/* Toolbar stays fixed (non-scrolling) */
.bureau-chat-toolbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	border-radius: calc(var(--bureau-radius) - 6px);
	background: var(--bureau-toolbar-bg);
	border: 1px solid var(--bureau-toolbar-border);
	padding: 10px 12px;
	margin-bottom: 12px;
	gap: 10px;
}

#bureauChatStatus {
	font-size: 12px;
	color: var(--bureau-muted);
	line-height: 1.2;
	min-height: 14px;
}

/* Body wrapper fills remaining space */
.bureau-chat-body {
	display: flex;
	flex-direction: column;
	min-height: 0; /* critical for inner overflow */
	flex: 1;
}

/* Suggestions area (optional, can hide when thread has messages) */
.bureau-chat-suggestions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	padding: 10px;
	margin-bottom: 12px;
	border-radius: var(--bureau-radius-sm);
	background: var(--bureau-suggestions-bg);
	border: 1px solid var(--bureau-suggestions-border);
}

	.bureau-chat-suggestions:empty {
		display: none;
	}


.bureau-chat-suggestions {
	display: none;
}

html[data-node="AI"][data-chat][data-chat="0"] .bureau-chat-suggestions {
	display: none;
}


.bureau-chat-suggestions .bureau-suggestion {
	appearance: none;
	border: 1px solid var(--bureau-suggestion-border);
	background: var(--bureau-suggestion-bg);
	color: var(--bureau-text);
	border-radius: 999px;
	padding: 10px 12px;
	font-size: 13px;
	line-height: 1;
	cursor: pointer;
	transition: background 140ms ease, border-color 140ms ease, transform 80ms ease;
}

	.bureau-chat-suggestions .bureau-suggestion:hover {
		background: var(--bureau-suggestion-hover-bg);
		border-color: var(--bureau-suggestion-hover-border);
	}

	.bureau-chat-suggestions .bureau-suggestion:active {
		transform: translateY(1px);
	}

/* Thread is the only vertical scroller */
.bureau-chat-thread {
	flex: 1;
	min-height: 0; /* critical for overflow in flex children */
	overflow-y: auto;
	overflow-x: hidden;
	padding: 8px 8px 12px 8px;
	border-radius: var(--bureau-radius-sm);
	border: 1px solid var(--bureau-thread-border);
	box-shadow: var(--bureau-thread-inset);
	background: var(--bureau-thread-bg);
	background-image: radial-gradient(circle at 0% 0%, var(--bureau-purple) 0%, color-mix(in oklab, var(--bureau-purple), var(--deep-blue)) 50%, var(--deep-blue) 100%);
	background-blend-mode: darken;
}

	/* Optional nicer scrollbar (won't affect Firefox much) */
	.bureau-chat-thread::-webkit-scrollbar {
		width: 10px;
	}

	.bureau-chat-thread::-webkit-scrollbar-thumb {
		background: var(--bureau-scrollbar-thumb);
		border-radius: 999px;
		border: 2px solid var(--bureau-scrollbar-thumb-border);
	}

		.bureau-chat-thread::-webkit-scrollbar-thumb:hover {
			background: var(--bureau-scrollbar-thumb-hover);
		}

/* Message rows */
.bureau-msg {
	display: flex;
	flex-direction: column;
	gap: 6px;
	margin: 10px 0;
}

/* Align user vs assistant bubbles */
.bureau-msg-user {
	align-items: flex-end;
}

	.bureau-msg-user .bureau-msg-meta {
		text-align: right;
	}

.bureau-msg-assistant {
	align-items: flex-start;
}

/* Meta (role + timestamp) */
.bureau-msg-meta {
	font-size: 11px;
	color: var(--bureau-muted);
	opacity: 0.9;
	padding: 0 6px;
	text-align: r;
}

/* Bubble */
.bureau-msg-body {
	max-width: min(720px, 86%);
	border-radius: 16px;
	padding: 14px 16px;
	border: 1px solid var(--bureau-bubble-border);
	background: var(--bureau-bubble-bg);
	line-height: 1.45;
	font-size: 15px;
	color: var(--bureau-text);
	/* Prevent long content from breaking card */
	overflow-wrap: anywhere;
	word-break: break-word;
}


.bureau-chat-contact-msg .bureau-msg-body {
	width: max(50vw,320px);
	max-width: 95%;
}


.bureau-msg-body ul {
	margin: 0;
	padding-left: 1.2em; /* tweak */
	list-style-position: outside; /* keep marker stable */
}

	.bureau-msg-body ul li {
		padding-left: 0.4em;
		list-style: disc;
	}

		.bureau-msg-body ul li::marker {
			/* optional */
			opacity: 0.9;
		}


.bureau-msg-body ol {
	margin: 0;
	padding-left: 1.4em; /* controls “inside” feel */
	list-style-position: outside;
}

	.bureau-msg-body ol li {
		padding-left: 0.4em; /* space between number and text */
	}

		.bureau-msg-body ol li::marker {
			font-weight: 600; /* optional */
		}

/* Slightly different treatment for user */
.bureau-msg-user .bureau-msg-body {
	background: var(--bureau-bubble-user-bg);
	border-color: var(--bureau-bubble-user-border);
}

/* Assistant bubble a little more neutral */
.bureau-msg-assistant .bureau-msg-body {
	background: var(--deep-blue);
	border-color: var( --bureau-bubble-assistant-border);
	box-shadow: 0 0 20px 0px #682e9f;
}

/* Markdown defaults inside the bubble */
.bureau-msg-body > :first-child {
	margin-top: 0;
}

.bureau-msg-body > :last-child {
	margin-bottom: 0;
}

.bureau-msg-body p,
.bureau-msg-body ul,
.bureau-msg-body ol,
.bureau-msg-body blockquote,
.bureau-msg-body pre,
.bureau-msg-body table {
	margin: 10px 0;
}

.bureau-msg-body h1,
.bureau-msg-body h2,
.bureau-msg-body h3 {
	margin: 12px 0 8px 0;
	line-height: 1.2;
}

.bureau-msg-body h1 {
	font-size: 18px;
}

.bureau-msg-body h2 {
	font-size: 16px;
}

.bureau-msg-body h3 {
	font-size: 15px;
}

.bureau-msg-body a {
	color: var(--bureau-link);
	text-decoration: underline;
	text-underline-offset: 2px;
}

.bureau-msg-body blockquote {
	padding: 10px 12px;
	border-left: 3px solid var(--bureau-blockquote-border);
	background: var(--bureau-blockquote-bg);
	border-radius: 10px;
	color: var(--bureau-blockquote-text);
}

/* Code blocks should scroll horizontally, not blow out the bubble */
.bureau-msg-body pre {
	background: var(--bureau-pre-bg);
	border: 1px solid var(--bureau-pre-border);
	border-radius: 12px;
	padding: 10px 12px;
	overflow-x: auto;
	font-family: var(--bureau-mono);
	font-size: 12.5px;
}

.bureau-msg-body code {
	font-family: var(--bureau-mono);
	font-size: 0.95em;
	background: var(--bureau-code-bg);
	border: 1px solid var(--bureau-code-border);
	padding: 1px 6px;
	border-radius: 8px;
}

/* Tables: keep inside bubble */
.bureau-msg-body table {
	width: 100%;
	border-collapse: separate;
	border-spacing: 0;
	overflow: hidden;
	border: 1px solid var(--bureau-table-border);
	border-radius: 12px;
	background: var(--bureau-table-bg);
	display: block;
	overflow-x: auto;
}

.bureau-msg-body th,
.bureau-msg-body td {
	padding: 10px 12px;
	border-bottom: 1px solid var(--bureau-table-row-border);
	white-space: nowrap;
}

.bureau-msg-body th {
	color: var(--bureau-table-th-text);
	background: var(--bureau-table-th-bg);
	font-weight: 600;
}

.bureau-msg-body hr {
	border: 0;
	height: 1px;
	background: var(--bureau-hr);
	margin: 14px 0;
}

/* Composer pinned at bottom (within card) */
.bureau-chat-inputrow {
	display: grid;
	grid-template-columns: 1fr auto;
	gap: 10px;
	margin-top: 12px;
	padding: 10px;
	border-radius: var(--bureau-radius-sm);
	border: 1px solid var(--bureau-composer-border);
	background: var(--bureau-composer-bg);
}

#bureauChatInput {
	width: 100%;
	resize: none;
	border-radius: 12px;
	border: 1px solid var(--bureau-input-border);
	background: var(--bureau-input-bg);
	color: var(--bureau-text);
	padding: 10px 12px;
	font-family: var(--bureau-font);
	font-size: 14px;
	line-height: 1.35;
	outline: none;
}

	#bureauChatInput::placeholder {
		color: var(--bureau-input-placeholder);
	}

	/*#bureauChatInput:focus {
		border-color: var(--bureau-input-focus-border);
		box-shadow: 0 0 0 3px var(--bureau-input-focus-ring);
	}
	*/

	#bureauChatInput:focus,
	#bureauChatInput:active {
		border: 1px solid var(--bureau-button-border);
		background: var(--bureau-button-bg);
	}






#bureauChatSend,
#bureauChatNew {
	appearance: none;
	border: 1px solid var(--bureau-button-border);
	background: var(--bureau-button-bg);
	color: var(--bureau-text);
	border-radius: 12px;
	padding: 10px 14px;
	font-size: 13px;
	line-height: 1;
	cursor: pointer;
	transition: transform 80ms ease, background 140ms ease, border-color 140ms ease;
}

	#bureauChatSend:hover,
	#bureauChatNew:hover {
		background: var(--bureau-button-hover-bg);
		border-color: var(--bureau-button-hover-border);
	}

	#bureauChatSend:active,
	#bureauChatNew:active {
		transform: translateY(1px);
	}

	#bureauChatSend[disabled] {
		background: #16141b;
		border: 1px solid #2d2b32;
		color: #747377;
	}



/* Thinking indicator if you render one */
.bureau-thinking {
	display: inline-flex;
	gap: 6px;
	align-items: center;
	font-size: 12px;
	color: var(--bureau-muted);
}

.bureau-dot {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--bureau-dot-bg);
	animation: bureauPulse 900ms infinite ease-in-out;
}

	.bureau-dot:nth-child(2) {
		animation-delay: 150ms;
	}

	.bureau-dot:nth-child(3) {
		animation-delay: 300ms;
	}

@keyframes bureauPulse {
	0%, 100% {
		transform: scale(1);
		opacity: 0.25;
	}

	50% {
		transform: scale(1.05);
		opacity: 0.95;
	}
}


/* Fullscreen mode (hook for your future button)
   Toggle .bureau-chat.is-fullscreen on the card */
.bureau-chat.is-fullscreen {
	position: fixed;
	inset: 16px;
	height: auto;
	z-index: 9999;
}



/* ============================================================
   Bureau Chat Inline Contact Form
   Prefix: bureau-chat-contact-
   Uses bureau chat tokens from bureau-chat.css
   ============================================================ */

.bureau-chat-contact-card {
	border: 1px solid var(--bureau-bubble-assistant-border);
	background: rgba(0, 0, 0, 0.28);
	border-radius: 14px;
	padding: 14px;
	box-shadow: 0 0 18px rgba(104, 46, 159, 0.35);
}

.bureau-chat-contact-header {
	margin-bottom: 10px;
}

.bureau-chat-contact-title {
	font-size: 15px;
	line-height: 1.2;
	margin: 0;
	color: var(--bureau-text);
}

.bureau-chat-contact-subtitle {
	margin: 6px 0 0 0;
	font-size: 12.5px;
	color: var(--bureau-muted);
}

.bureau-chat-contact-form {
	margin: 0;
}

.bureau-chat-contact-fieldset {
	border: 0;
	padding: 0;
	margin: 0;
	min-width: 0;
}

.bureau-chat-contact-sr-only {
	position: absolute;
	left: -9999px;
	top: auto;
	width: 1px;
	height: 1px;
	overflow: hidden;
	white-space: nowrap;
}

/* Honeypot: visually hidden but not type=hidden */
.bureau-chat-contact-hp {
	position: absolute;
	left: -9999px;
	top: auto;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.bureau-chat-contact-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 10px;
}

@media (min-width: 560px) {
	.bureau-chat-contact-grid {
		grid-template-columns: 1fr 1fr;
	}

	.bureau-chat-contact-field-span2 {
		grid-column: 1 / -1;
	}
}

.bureau-chat-contact-field {
	display: flex;
	flex-direction: column;
	gap: 6px;
	min-width: 0;
}

	/*
.bureau-chat-contact-field:has(#bureau-chat-include-chat) {
		flex-direction: row;
		margin: 14px 0;
	}

#bureau-chat-include-chat {
	font-size: 10px;
	width: unset;
}
*/






	/* Make the checkbox row a flex row */
	.bureau-chat-contact-field:has(#bureau-chat-include-chat) {
		/* display: flex; */
		/* align-items: center; */
		padding: 22px 0;
	}


/* HARD hide the real checkbox (no native UI can show) */
#bureau-chat-include-chat.bureau-chat-contact-input {
	position: absolute !important;
	left: -9999px !important;
	top: auto !important;
	/* extra safety */
	opacity: 0 !important;
	appearance: none !important;
	-webkit-appearance: none !important;
}

/* Label becomes the clickable control */
#bureau-chat-include-chat + .bureau-chat-contact-label {
	position: relative;
	display: inline-flex;
	align-items: center;
	gap: 10px;
	cursor: pointer;
	user-select: none;
	padding-left: 28px; /* room for faux box */
	line-height: 18px;
}

	/* Faux box */
	#bureau-chat-include-chat + .bureau-chat-contact-label::before {
		content: "";
		position: absolute;
		left: 0;
		top: 50%;
		transform: translateY(-50%);
		width: 18px;
		height: 18px;
		border-radius: 6px;
		border: 1px solid rgba(255,255,255,0.22);
		background: rgba(255,255,255,0.06);
		box-shadow: inset 0 0 0 1px rgba(0,0,0,0.22);
	}

/* Checked state */
#bureau-chat-include-chat:checked + .bureau-chat-contact-label::before {
	/* border-color: rgba(246,133,0,0.60); */
	/* background: rgba(246,133,0,0.20); */
	/* box-shadow: inset 0 0 0 1px rgba(0,0,0,0.22), 0 0 0 3px rgba(246,133,0,0.16); */
	border: 1px solid var(--bureau-input-border);
	background: rgb(86 38 138);
	/* background: red; */
}

/* Checkmark */
#bureau-chat-include-chat:checked + .bureau-chat-contact-label::after {
	content: "";
	position: absolute;
	left: 6px;
	top: 50%;
	transform: translateY(-55%) rotate(45deg);
	width: 6px;
	height: 10px;
	border-right: 2px solid rgba(255,255,255,0.92);
	border-bottom: 2px solid rgba(255,255,255,0.92);
}

/* Focus ring (since input is offscreen, focus the label when tabbing) */
#bureau-chat-include-chat:focus-visible + .bureau-chat-contact-label::before {
	outline: 2px solid rgba(129,9,127,0.65);
	outline-offset: 2px;
}










.bureau-chat-contact-label {
	font-size: 12px;
	color: var(--bureau-muted);
}

.bureau-chat-contact-input,
.bureau-chat-contact-textarea {
	width: 100%;
	border-radius: 12px;
	border: 1px solid var(--bureau-input-border);
	background: var(--bureau-input-bg);
	color: var(--bureau-text);
	padding: 10px 12px;
	font-family: var(--bureau-font);
	font-size: 13.5px;
	line-height: 1.35;
	outline: none;
}

.bureau-chat-contact-textarea {
	resize: vertical;
	min-height: 110px;
}

	.bureau-chat-contact-input::placeholder,
	.bureau-chat-contact-textarea::placeholder {
		color: var(--bureau-input-placeholder);
	}

	.bureau-chat-contact-input:focus,
	.bureau-chat-contact-textarea:focus {
		border-color: var(--bureau-input-focus-border);
		box-shadow: 0 0 0 3px var(--bureau-input-focus-ring);
	}

/* Actions */
.bureau-chat-contact-actions {
	display: flex;
	gap: 10px;
	align-items: center;
	margin-top: 12px;
	flex-wrap: wrap;
}

.bureau-chat-contact-btn {
	appearance: none;
	border: 1px solid var(--bureau-button-border);
	background: var(--bureau-button-bg);
	color: var(--bureau-text);
	border-radius: 12px;
	padding: 10px 14px;
	font-size: 13px;
	line-height: 1;
	cursor: pointer;
	transition: transform 80ms ease, background 140ms ease, border-color 140ms ease;
	display: inline-flex;
	align-items: center;
	gap: 10px;
}

	.bureau-chat-contact-btn:hover {
		background: var(--bureau-button-hover-bg);
		border-color: var(--bureau-button-hover-border);
	}

	.bureau-chat-contact-btn:active {
		transform: translateY(1px);
	}

	.bureau-chat-contact-btn[disabled] {
		opacity: 0.55;
		cursor: not-allowed;
		transform: none;
	}

.bureau-chat-contact-btn-secondary {
	background: rgba(255, 255, 255, 0.03);
	border-color: var(--bureau-border-2);
}

.bureau-chat-contact-btn-icon {
	font-size: 15px;
	line-height: 1;
	opacity: 0.9;
}

/* Fine print */
.bureau-chat-contact-fineprint {
	margin: 10px 0 0 0;
	font-size: 12px;
	color: var(--bureau-muted-2);
}

.bureau-chat-contact-link {
	color: var(--bureau-link);
	text-decoration: underline;
	text-underline-offset: 2px;
}



@media (min-width: 768px) {
	/* tablet: 2 columns */
	.bureau-chat-prime-pills {
		grid-template-columns: repeat(2, 1fr);
	}


	html[data-node="AI"][data-chat][data-chat="0"] .bureau-chat-suggestions {
		display: inline-block;
	}
}

@media (min-width: 1024px) {
	/* desktop: 3 columns (6 pills = 2 clean rows) */
	.bureau-chat-prime-pills {
		grid-template-columns: repeat(3, 1fr);
	}

		.bureau-chat-prime-pills.secondary-pills {
			grid-template-columns: repeat(2, 1fr);
			padding-top: 0;
			padding-bottom: 32px;
		}
}