/**
 * AR Capability Advisor Stylesheet
 * Brand System: Deep Navy (#0B132B, #0A192F), Emerald Green (#10B981, #059669), Slate (#F8FAFC)
 * 100% British English and Zero Dash Compliant
 */

/* ==========================================================================
   1. Floating Launcher Button (Green Circle)
   ========================================================================== */
.arc-launcher-wrapper {
	position: fixed;
	bottom: 24px;
	right: 24px;
	z-index: 99999;
	display: flex;
	align-items: center;
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.arc-launcher-btn {
	position: relative;
	width: 60px;
	height: 60px;
	border-radius: 50%;
	background: #10B981;
	border: 2px solid #059669;
	box-shadow: 0 10px 25px -5px rgba(16, 185, 129, 0.45), 0 8px 10px -6px rgba(11, 19, 43, 0.25);
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0;
	transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), background 0.2s ease, box-shadow 0.25s ease;
}

.arc-launcher-btn:hover {
	transform: scale(1.05);
	background: #059669;
	box-shadow: 0 14px 28px -4px rgba(16, 185, 129, 0.55), 0 10px 14px -5px rgba(11, 19, 43, 0.35);
}

.arc-launcher-btn:focus-visible {
	outline: 2px solid #10B981;
	outline-offset: 3px;
}

.arc-pulse-ring {
	position: absolute;
	top: -4px;
	left: -4px;
	right: -4px;
	bottom: -4px;
	border-radius: 50%;
	border: 2px solid rgba(16, 185, 129, 0.6);
	animation: arc-pulse 2.5s infinite;
	pointer-events: none;
}

@keyframes arc-pulse {
	0% {
		transform: scale(0.95);
		opacity: 0.8;
	}
	70% {
		transform: scale(1.2);
		opacity: 0;
	}
	100% {
		transform: scale(1.2);
		opacity: 0;
	}
}

.arc-launcher-icon {
	display: flex;
	align-items: center;
	justify-content: center;
}

.arc-launcher-badge {
	position: absolute;
	top: -2px;
	right: -2px;
	background: #0B132B;
	color: #FFFFFF;
	font-size: 11px;
	font-weight: 700;
	line-height: 1;
	padding: 3px 6px;
	border-radius: 10px;
	border: 2px solid #10B981;
}

.arc-launcher-tooltip {
	display: none !important;
}

.arc-launcher-tooltip.arc-tooltip-visible {
	opacity: 1;
	visibility: visible;
	transform: translateX(0);
	pointer-events: auto;
}

.arc-tooltip-dismiss {
	background: none;
	border: none;
	color: #94A3B8;
	font-size: 14px;
	cursor: pointer;
	padding: 0 2px;
	line-height: 1;
}

.arc-tooltip-dismiss:hover {
	color: #FFFFFF;
}

/* ==========================================================================
   2. Drawer Container & Layout
   ========================================================================== */
.arc-drawer-panel {
	position: fixed;
	bottom: 96px;
	right: 24px;
	width: 410px;
	max-width: calc(100vw - 32px);
	height: 620px;
	max-height: calc(100vh - 120px);
	background: #FFFFFF;
	border: 1px solid rgba(16, 185, 129, 0.25);
	border-radius: 16px;
	box-shadow: 0 20px 40px -10px rgba(11, 19, 43, 0.3), 0 0 1px 1px rgba(16, 185, 129, 0.15);
	z-index: 99999;
	display: flex;
	flex-direction: column;
	overflow: hidden;
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
	opacity: 0;
	visibility: hidden;
	transform: translateY(20px) scale(0.96);
	transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.25s;
}

.arc-drawer-panel.arc-drawer-open {
	opacity: 1;
	visibility: visible;
	transform: translateY(0) scale(1);
}

/* ==========================================================================
   3. Drawer Header (Navy with Green Accents)
   ========================================================================== */
.arc-drawer-header {
	background: #0B132B;
	color: #FFFFFF;
	padding: 16px 18px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	border-bottom: 2px solid #10B981;
	flex-shrink: 0;
}

.arc-header-left {
	display: flex;
	align-items: center;
	gap: 12px;
}

.arc-crest-monogram {
	width: 38px;
	height: 38px;
	border-radius: 8px;
	background: #0A192F;
	border: 1.5px solid #10B981;
	color: #10B981;
	font-weight: 800;
	font-size: 15px;
	display: flex;
	align-items: center;
	justify-content: center;
	letter-spacing: 0.5px;
	flex-shrink: 0;
}

.arc-header-meta {
	display: flex;
	flex-direction: column;
}

.arc-title {
	margin: 0;
	font-size: 14px;
	font-weight: 700;
	color: #FFFFFF;
	letter-spacing: -0.2px;
}

.arc-subtitle {
	font-size: 11px;
	color: #94A3B8;
	margin-top: 1px;
}

.arc-header-right {
	display: flex;
	align-items: center;
	gap: 8px;
}

.arc-status-pill {
	display: flex;
	align-items: center;
	gap: 5px;
	background: rgba(16, 185, 129, 0.15);
	border: 1px solid rgba(16, 185, 129, 0.3);
	padding: 3px 8px;
	border-radius: 12px;
	font-size: 11px;
	font-weight: 600;
	color: #10B981;
}

.arc-status-dot {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: #10B981;
	box-shadow: 0 0 6px #10B981;
}

.arc-control-btn {
	background: rgba(255, 255, 255, 0.08);
	border: 1px solid rgba(255, 255, 255, 0.12);
	color: #CBD5E1;
	width: 30px;
	height: 30px;
	border-radius: 6px;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: background 0.2s, color 0.2s;
	padding: 0;
}

.arc-control-btn:hover {
	background: rgba(255, 255, 255, 0.18);
	color: #FFFFFF;
}

/* ==========================================================================
   4. Chat Stream & Messages
   ========================================================================== */
.arc-chat-stream {
	flex: 1;
	overflow-y: auto;
	padding: 16px;
	background: #F8FAFC;
	display: flex;
	flex-direction: column;
	gap: 16px;
	scroll-behavior: smooth;
}

.arc-chat-stream::-webkit-scrollbar {
	width: 6px;
}

.arc-chat-stream::-webkit-scrollbar-track {
	background: transparent;
}

.arc-chat-stream::-webkit-scrollbar-thumb {
	background: #CBD5E1;
	border-radius: 3px;
}

.arc-msg {
	display: flex;
	gap: 10px;
	max-width: 90%;
	animation: arc-msg-fade 0.25s ease-out;
}

@keyframes arc-msg-fade {
	from {
		opacity: 0;
		transform: translateY(8px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.arc-msg-advisor {
	align-self: flex-start;
}

.arc-msg-user {
	align-self: flex-end;
	flex-direction: row-reverse;
}

.arc-msg-avatar {
	width: 30px;
	height: 30px;
	border-radius: 6px;
	background: #0B132B;
	color: #10B981;
	font-weight: 700;
	font-size: 11px;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	margin-top: 2px;
	border: 1.5px solid #10B981;
}

.arc-msg-bubble {
	background: #FFFFFF;
	color: #1E293B;
	border: 1px solid #E2E8F0;
	border-radius: 12px;
	padding: 12px 14px;
	font-size: 13px;
	line-height: 1.5;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.arc-msg-advisor .arc-msg-bubble {
	border-left: 3px solid #10B981;
}

.arc-msg-user .arc-msg-bubble {
	background: #0B132B;
	color: #FFFFFF;
	border: 1px solid #0A192F;
}

.arc-msg-text p {
	margin: 0 0 8px 0;
}

.arc-msg-text p:last-child {
	margin-bottom: 0;
}

.arc-msg-text strong {
	color: inherit;
	font-weight: 600;
}

.arc-chat-link {
	color: #10B981;
	text-decoration: underline;
	font-weight: 600;
	transition: color 0.15s ease;
	word-break: break-all;
}

.arc-chat-link:hover {
	color: #059669;
	text-decoration: none;
}

.arc-chat-quote-banner {
	margin-top: 10px;
	padding-top: 8px;
	border-top: 1px dashed #E2E8F0;
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
	align-items: center;
}

.arc-chat-primary-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: #10B981;
	color: #FFFFFF;
	font-size: 12px;
	font-weight: 700;
	padding: 7px 14px;
	border-radius: 6px;
	text-decoration: none;
	transition: background 0.2s, transform 0.15s;
}

.arc-chat-primary-btn:hover {
	background: #059669;
	color: #FFFFFF;
	transform: translateY(-1px);
}

.arc-chat-secondary-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: #F1F5F9;
	color: #0F172A;
	border: 1px solid #CBD5E1;
	font-size: 12px;
	font-weight: 700;
	padding: 7px 14px;
	border-radius: 6px;
	text-decoration: none;
	transition: all 0.2s;
}

.arc-chat-secondary-btn:hover {
	background: #E2E8F0;
	border-color: #94A3B8;
	color: #0F172A;
	transform: translateY(-1px);
}

.arc-msg-text ul {
	margin: 6px 0 8px 16px;
	padding: 0;
}

.arc-msg-text li {
	margin-bottom: 4px;
}

/* ==========================================================================
   5. Starter Action Chips
   ========================================================================== */
.arc-chips-wrapper {
	display: flex;
	flex-direction: column;
	gap: 6px;
	margin-top: 10px;
}

.arc-chip {
	display: flex;
	align-items: center;
	gap: 8px;
	background: #F1F5F9;
	border: 1px solid #CBD5E1;
	border-radius: 8px;
	padding: 8px 10px;
	color: #0F172A;
	font-size: 12px;
	font-weight: 600;
	text-align: left;
	cursor: pointer;
	transition: background 0.15s, border-color 0.15s, transform 0.15s;
}

.arc-chip:hover {
	background: #FFFFFF;
	border-color: #10B981;
	transform: translateX(2px);
	box-shadow: 0 2px 6px rgba(16, 185, 129, 0.15);
}

.arc-chip-icon {
	font-size: 14px;
}

.arc-chip-text {
	flex: 1;
}

/* ==========================================================================
   6. Structured Course & Programme Cards in Dialogue
   ========================================================================== */
.arc-cards-container {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-top: 10px;
}

.arc-course-card {
	background: #F8FAFC;
	border: 1px solid #E2E8F0;
	border-radius: 8px;
	padding: 10px 12px;
	transition: border-color 0.2s;
}

.arc-course-card:hover {
	border-color: #10B981;
}

.arc-card-meta {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 6px;
	margin-bottom: 4px;
}

.arc-card-code {
	background: #0B132B;
	color: #10B981;
	font-size: 11px;
	font-weight: 700;
	padding: 2px 6px;
	border-radius: 4px;
	border: 1px solid rgba(16, 185, 129, 0.3);
}

.arc-card-duration {
	font-size: 11px;
	color: #64748B;
	font-weight: 500;
}

.arc-card-title {
	font-size: 13px;
	font-weight: 700;
	color: #0B132B;
	margin: 0 0 6px 0;
	line-height: 1.35;
}

.arc-card-actions {
	display: flex;
	gap: 6px;
	margin-top: 8px;
}

.arc-card-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 11px;
	font-weight: 600;
	padding: 4px 8px;
	border-radius: 4px;
	text-decoration: none;
	transition: background 0.15s, color 0.15s;
}

.arc-btn-syllabus {
	background: #E2E8F0;
	color: #1E293B;
}

.arc-btn-syllabus:hover {
	background: #CBD5E1;
	color: #0B132B;
}

.arc-btn-quote {
	background: #10B981;
	color: #FFFFFF;
	border: 1px solid #059669;
}

.arc-btn-quote:hover {
	background: #059669;
	color: #FFFFFF;
}

/* ==========================================================================
   7. Typing Indicator
   ========================================================================== */
.arc-typing-wrapper {
	padding: 0 16px 8px 16px;
	background: #F8FAFC;
}

.arc-typing-bubble {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	background: #FFFFFF;
	border: 1px solid #E2E8F0;
	padding: 8px 12px;
	border-radius: 12px;
	border-left: 3px solid #10B981;
}

.arc-typing-dot {
	width: 5px;
	height: 5px;
	border-radius: 50%;
	background: #10B981;
	animation: arc-dot-bounce 1.4s infinite ease-in-out;
}

.arc-typing-dot:nth-child(2) {
	animation-delay: 0.2s;
}

.arc-typing-dot:nth-child(3) {
	animation-delay: 0.4s;
}

@keyframes arc-dot-bounce {
	0%, 80%, 100% {
		transform: scale(0.6);
		opacity: 0.4;
	}
	40% {
		transform: scale(1.1);
		opacity: 1;
	}
}

.arc-typing-caption {
	font-size: 11px;
	color: #64748B;
	margin-left: 6px;
	font-style: italic;
}

/* ==========================================================================
   8. Inline Lead Form Card
   ========================================================================== */
.arc-lead-card {
	background: #0B132B;
	color: #FFFFFF;
	border: 1px solid #10B981;
	border-radius: 10px;
	padding: 14px;
	margin-top: 10px;
}

.arc-lead-card-header {
	margin-bottom: 10px;
}

.arc-lead-title {
	margin: 0 0 4px 0;
	font-size: 13px;
	font-weight: 700;
	color: #10B981;
}

.arc-lead-sub {
	margin: 0;
	font-size: 11px;
	color: #94A3B8;
	line-height: 1.4;
}

.arc-lead-form {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.arc-form-group {
	display: flex;
	flex-direction: column;
	gap: 3px;
}

.arc-form-label {
	font-size: 10px;
	font-weight: 600;
	color: #CBD5E1;
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.arc-form-input {
	background: rgba(255, 255, 255, 0.08);
	border: 1px solid rgba(255, 255, 255, 0.15);
	color: #FFFFFF;
	padding: 6px 8px;
	border-radius: 6px;
	font-size: 12px;
	font-family: inherit;
}

.arc-form-input:focus {
	outline: none;
	border-color: #10B981;
	background: rgba(255, 255, 255, 0.12);
}

.arc-lead-submit-btn {
	background: #10B981;
	color: #FFFFFF;
	border: none;
	border-radius: 6px;
	padding: 8px 12px;
	font-size: 12px;
	font-weight: 700;
	cursor: pointer;
	margin-top: 4px;
	transition: background 0.2s, transform 0.15s;
}

.arc-lead-submit-btn:hover {
	background: #059669;
	transform: translateY(-1px);
}

/* ==========================================================================
   9. Drawer Footer & Textarea
   ========================================================================== */
.arc-drawer-footer {
	background: #FFFFFF;
	padding: 12px 16px;
	border-top: 1px solid #E2E8F0;
	flex-shrink: 0;
}

.arc-input-form {
	margin: 0;
}

.arc-input-wrapper {
	display: flex;
	align-items: center;
	gap: 8px;
	background: #F1F5F9;
	border: 1px solid #CBD5E1;
	border-radius: 10px;
	padding: 6px 8px;
	transition: border-color 0.2s, background 0.2s;
}

.arc-input-wrapper:focus-within {
	border-color: #10B981;
	background: #FFFFFF;
	box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

.arc-chat-textarea {
	flex: 1;
	border: none;
	background: transparent;
	resize: none;
	font-size: 13px;
	line-height: 1.4;
	color: #0F172A;
	max-height: 80px;
	font-family: inherit;
	padding: 4px;
}

.arc-chat-textarea:focus {
	outline: none;
}

.arc-chat-textarea::placeholder {
	color: #94A3B8;
	font-size: 12px;
}

.arc-send-btn {
	width: 34px;
	height: 34px;
	border-radius: 8px;
	background: #10B981;
	border: 1px solid #059669;
	color: #FFFFFF;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	padding: 0;
	flex-shrink: 0;
	transition: background 0.2s, transform 0.15s, opacity 0.2s;
}

.arc-send-btn:hover:not(:disabled) {
	background: #059669;
	transform: scale(1.05);
}

.arc-send-btn:disabled {
	opacity: 0.4;
	cursor: not-allowed;
}

.arc-footer-legal {
	margin-top: 8px;
	font-size: 10px;
	color: #94A3B8;
	text-align: center;
	line-height: 1.3;
}

/* ==========================================================================
   10. Mobile Responsiveness (< 640px)
   ========================================================================== */
@media (max-width: 639px) {
	.arc-launcher-wrapper {
		bottom: 16px;
		right: 16px;
	}

	.arc-launcher-btn {
		width: 52px;
		height: 52px;
	}

	.arc-drawer-panel {
		bottom: 0;
		right: 0;
		left: 0;
		width: 100vw;
		max-width: 100vw;
		height: 100dvh;
		max-height: 100dvh;
		border-radius: 0;
		border: none;
	}

	.arc-drawer-header {
		padding: 14px 16px;
	}

	.arc-chat-stream {
		padding: 12px;
	}
}
