/* ==========================================================
   LawyerAI glossary term: app visual system
   Loaded after single-term.css. Mirrors the blog's lai-app.css
   (lavender atmosphere, white bordered panels, 16px cards,
   14px controls, quiet uppercase labels, DM Sans).
   ========================================================== */

body.vge-term-singular {
	--lai-purple: #7655e9;
	--lai-purple-deep: #6545e7;
	--lai-gradient: linear-gradient(135deg, #7655e9 0%, #a66deb 100%);
	--lai-gradient-hover: linear-gradient(135deg, #6848df 0%, #985edf 100%);
	--lai-text: #251d42;
	--lai-text-sub: #5c5478;
	--lai-muted: #81768f;
	--lai-border: #ded8ef;
	--lai-border-soft: #e8e3f1;
	--lai-border-hover: rgba(118, 85, 233, 0.36);
	--lai-surface: #ffffff;
	--lai-surface-soft: #f8f6fc;
	--lai-control: #ede9fb;
	--lai-control-text: #5b4d8c;
	--lai-active: #e4ddfb;
	--lai-soft-hover: rgba(118, 85, 233, 0.075);
	--lai-focus: rgba(118, 85, 233, 0.18);
	--lai-radius-panel: 20px;
	--lai-radius-card: 16px;
	--lai-radius-control: 14px;
	--lai-shadow-panel: 0 14px 34px rgba(82, 61, 141, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.8);
	--lai-shadow-control: 0 8px 18px rgba(118, 85, 233, 0.2);
	--lai-font: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
	--lai-serif: "Instrument Serif", Georgia, "Times New Roman", serif;

	--sdg-navy: var(--lai-text);
	--sdg-pink: var(--lai-purple);
	--sdg-pink-soft: var(--lai-control);
	--sdg-pink-faint: var(--lai-surface-soft);
	--sdg-text: var(--lai-text);
	--sdg-text-soft: var(--lai-text-sub);
	--sdg-text-faint: var(--lai-muted);
	--sdg-border: var(--lai-border-soft);
	--sdg-border-dark: var(--lai-border);
	--sdg-bg-soft: var(--lai-surface-soft);
}

/* Match the site header container: 1240px wide, same side gutters. */
body.vge-glossary-shell,
body.vge-glossary-shell .sdg-page,
body.vge-glossary-shell .sd-glossary-hero,
body.vge-glossary-shell .vge-glossary-index {
	--vge-content-max: 1240px;
}

body.vge-term-singular .sdg-page .sd-glossary-hero {
	max-width: none;
}

@media (max-width: 980px) {
	body.vge-glossary-shell,
	body.vge-glossary-shell .sdg-page,
	body.vge-glossary-shell .sd-glossary-hero,
	body.vge-glossary-shell .vge-glossary-index {
		--vge-gutter-x: 24px;
	}
}

@media (max-width: 768px) {
	body.vge-glossary-shell,
	body.vge-glossary-shell .sdg-page,
	body.vge-glossary-shell .sd-glossary-hero,
	body.vge-glossary-shell .vge-glossary-index {
		--vge-gutter-x: 14px;
	}
}

/* The site header is sticky (in flow), so no fixed-header offset is needed. */
body.vge-term-singular.et-tb-has-header #main-content,
body.vge-term-singular.et-tb #main-content {
	padding-top: 28px !important;
	background: transparent !important;
}

body.vge-term-singular .sdg-page {
	background: transparent;
	color: var(--lai-text);
	font-family: var(--lai-font);
}

/* ==========================================================
   Breadcrumbs
   ========================================================== */

body.vge-term-singular .sdg-breadcrumbs,
body.vge-term-singular .sdg-breadcrumbs a {
	color: var(--lai-muted) !important;
	font-family: var(--lai-font);
	font-size: 13px;
}

body.vge-term-singular .sdg-breadcrumbs a:hover {
	color: var(--lai-text) !important;
}

body.vge-term-singular .sdg-breadcrumb-separator {
	color: var(--lai-border);
}

body.vge-term-singular .sdg-breadcrumb-current {
	color: var(--lai-text);
	font-weight: 600;
}

/* ==========================================================
   Hero card
   ========================================================== */

body.vge-term-singular .sd-glossary-hero {
	font-family: var(--lai-font);
	color: var(--lai-text);
}

body.vge-term-singular .sdg-page .sd-glossary-card {
	border: 1px solid var(--lai-border-soft);
	border-radius: var(--lai-radius-panel);
	background: var(--lai-surface);
	box-shadow: var(--lai-shadow-panel);
}

body.vge-term-singular .sd-glossary-content {
	padding: 44px 40px 44px 46px;
}

body.vge-term-singular .sd-glossary-pill {
	padding: 6px 11px;
	border: 0;
	border-radius: 999px;
	background: var(--lai-control);
	color: var(--lai-control-text);
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.06em;
}

body.vge-term-singular .sd-glossary-title,
body.vge-term-singular .sd-glossary-title--short {
	margin: 18px 0 24px;
	color: var(--lai-text);
	font-family: var(--lai-font);
	font-size: clamp(36px, 4.2vw, 54px);
	font-weight: 700;
	line-height: 1.08;
	letter-spacing: -0.03em;
}

body.vge-term-singular .sd-definition-wrap {
	padding-top: 22px;
	border-top: 1px solid var(--lai-border-soft);
}

body.vge-term-singular .sd-definition-label,
body.vge-term-singular .sd-example-label {
	padding: 0;
	border: 0;
	border-radius: 0;
	background: none;
	color: var(--lai-muted);
	font-size: 11.5px;
	font-weight: 600;
	letter-spacing: 0.06em;
}

body.vge-term-singular .sd-definition-label {
	margin-bottom: 10px;
}

body.vge-term-singular .sd-definition {
	color: var(--lai-text-sub);
	font-size: 16.5px;
	font-weight: 400;
	line-height: 1.7;
}

body.vge-term-singular .sd-glossary-image-column {
	padding: 28px 28px 28px 12px;
	background: none;
}

body.vge-term-singular .sd-glossary-image-column::before {
	background: linear-gradient(to bottom, transparent, var(--lai-border-soft) 18%, var(--lai-border-soft) 82%, transparent);
}

body.vge-term-singular .sd-glossary-image-shell {
	padding: 0;
	border: 1px solid var(--lai-border-soft);
	border-radius: var(--lai-radius-card);
	background: var(--lai-surface-soft);
	box-shadow: none;
	overflow: hidden;
}

body.vge-term-singular .sd-glossary-image-shell::after {
	content: none;
}

body.vge-term-singular .sd-glossary-image-wrap {
	border-radius: 0;
	background: var(--lai-surface-soft);
}

/* Example usage */
body.vge-term-singular .sd-example {
	gap: 28px;
	margin-top: 16px;
	padding: 24px 30px;
	border: 1px solid var(--lai-border-soft);
	border-left: 3px solid var(--lai-purple);
	border-radius: var(--lai-radius-card);
	background: var(--lai-surface);
	box-shadow: none;
}

body.vge-term-singular .sd-example-text {
	color: var(--lai-text);
	font-family: var(--lai-serif);
	font-size: 24px;
	font-style: italic;
	font-weight: 400;
	line-height: 1.4;
	letter-spacing: 0;
}

/* ==========================================================
   Article
   ========================================================== */

body.vge-term-singular .sdg-main {
	gap: 40px;
	padding: 40px 0 80px;
}

body.vge-term-singular .sdg-content {
	padding: 36px 40px;
	border: 1px solid var(--lai-border-soft);
	border-radius: var(--lai-radius-panel);
	background: var(--lai-surface);
	box-shadow: var(--lai-shadow-panel);
}

body.vge-term-singular .sdg-prose {
	max-width: none;
}

body.vge-term-singular .sdg-prose p,
body.vge-term-singular .sdg-prose li {
	color: var(--lai-text-sub);
	font-family: var(--lai-font);
	font-size: 16.5px;
	line-height: 1.75;
}

body.vge-term-singular .sdg-prose > p:first-child {
	color: var(--lai-text);
	font-size: 17.5px;
}

body.vge-term-singular .sdg-prose p:empty {
	display: none;
}

body.vge-term-singular .sdg-prose h2,
body.vge-term-singular .sdg-prose h3,
body.vge-term-singular .sdg-prose h4 {
	color: var(--lai-text);
	font-family: var(--lai-font);
	font-weight: 700;
	letter-spacing: -0.02em;
}

body.vge-term-singular .sdg-prose h2 {
	margin: 40px 0 14px;
	padding-bottom: 0;
	font-size: clamp(23px, 2.3vw, 27px);
	line-height: 1.2;
}

body.vge-term-singular .sdg-prose h3 {
	margin: 30px 0 10px;
	font-size: 19px;
}

body.vge-term-singular .sdg-prose strong,
body.vge-term-singular .sdg-prose b {
	color: var(--lai-text);
	font-weight: 700;
}

body.vge-term-singular .sdg-prose li::marker {
	color: var(--lai-purple);
}

body.vge-term-singular .sdg-prose blockquote {
	border-left: 3px solid var(--lai-purple);
	border-radius: 0 var(--lai-radius-card) var(--lai-radius-card) 0;
	background: var(--lai-surface-soft);
	color: var(--lai-text);
	font-family: var(--lai-serif);
	font-size: 21px;
}

body.vge-term-singular .sdg-prose table {
	border-color: var(--lai-border-soft);
	border-radius: var(--lai-radius-card);
}

body.vge-term-singular .sdg-prose th {
	background: var(--lai-surface-soft);
	color: var(--lai-muted);
	font-size: 11.5px;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
}

body.vge-term-singular .sdg-prose th,
body.vge-term-singular .sdg-prose td {
	border-color: var(--lai-border-soft);
	color: var(--lai-text-sub);
}

body.vge-term-singular .sdg-bottom-join .sd-intro-cta {
	margin-top: 36px;
}

/* ==========================================================
   Sidebar
   ========================================================== */

body.vge-term-singular .sdg-sidebar {
	top: calc(var(--wp-admin--admin-bar--height, 0px) + 96px);
}

body.vge-term-singular .sdg-sidebar-stack {
	gap: 16px;
}

body.vge-term-singular .sdg-side-card {
	border: 1px solid var(--lai-border-soft);
	border-radius: var(--lai-radius-card);
	background: var(--lai-surface);
	box-shadow: var(--lai-shadow-panel);
}

body.vge-term-singular .sdg-side-inner {
	padding: 22px;
}

body.vge-term-singular .sdg-side-title {
	margin: 0 0 6px;
	color: var(--lai-text);
	font-family: var(--lai-font);
	font-size: 18px;
	font-weight: 700;
	line-height: 1.3;
	letter-spacing: -0.015em;
}

body.vge-term-singular .sdg-side-description {
	margin: 0 0 16px;
	color: var(--lai-muted);
	font-size: 13.5px;
	line-height: 1.55;
}

/* Search */
body.vge-term-singular .sdg-search-input {
	height: 46px;
	border: 1px solid var(--lai-border);
	border-radius: 12px;
	background: var(--lai-surface-soft);
	color: var(--lai-text);
	font-family: var(--lai-font);
	font-size: 14px;
}

body.vge-term-singular .sdg-search-input::placeholder {
	color: var(--lai-muted);
}

body.vge-term-singular .sdg-search-input:focus {
	border-color: var(--lai-border-hover);
	background: var(--lai-surface);
	box-shadow: 0 0 0 4px var(--lai-focus);
}

body.vge-term-singular .sdg-search-button {
	color: var(--lai-muted);
}

body.vge-term-singular .sdg-search-button:hover {
	background: var(--lai-control);
	color: var(--lai-purple);
}

/* A-Z */
body.vge-term-singular .sdg-az-label {
	color: var(--lai-muted);
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.06em;
}

body.vge-term-singular .sdg-letter {
	border: 1px solid transparent;
	border-radius: 8px;
	background: var(--lai-surface-soft);
	color: var(--lai-text-sub);
	font-size: 15px;
	font-weight: 600;
	line-height: 1;
}

body.vge-term-singular .sdg-letter:hover {
	transform: none;
	border-color: transparent;
	background: var(--lai-control);
	color: var(--lai-purple-deep);
}

body.vge-term-singular .sdg-letter.is-active,
body.vge-term-singular .sdg-letter[aria-current="true"] {
	border-color: transparent;
	background: var(--lai-gradient);
	color: #ffffff;
	font-weight: 800;
}

body.vge-term-singular .sdg-all-link {
	border-top-color: var(--lai-border-soft);
	color: var(--lai-purple-deep) !important;
	font-size: 13px;
	font-weight: 600;
}

/* Related / similar */
body.vge-term-singular .sdg-related-item {
	border-bottom-color: var(--lai-border-soft);
}

body.vge-term-singular .sdg-related-name {
	color: var(--lai-text);
	font-size: 14px;
	font-weight: 600;
}

body.vge-term-singular .sdg-related-category {
	color: var(--lai-muted);
	font-size: 10.5px;
	font-weight: 600;
}

body.vge-term-singular .sdg-related-arrow {
	color: var(--lai-border);
}

body.vge-term-singular .sdg-related-item:hover .sdg-related-name,
body.vge-term-singular .sdg-related-item:hover .sdg-related-arrow {
	color: var(--lai-purple-deep);
}

/* CTA: dark app panel */
body.vge-term-singular .sdg-side-cta {
	border-color: rgba(205, 186, 255, 0.16);
	background:
		radial-gradient(circle at top right, rgba(170, 118, 238, 0.32), transparent 45%),
		radial-gradient(circle at 10% 100%, rgba(118, 85, 233, 0.2), transparent 45%),
		linear-gradient(155deg, #171326 0%, #201735 55%, #151221 100%);
	box-shadow: 0 18px 38px rgba(23, 19, 38, 0.22);
}

body.vge-term-singular .sdg-side-cta .sdg-side-label {
	margin-bottom: 10px;
	color: #bcb0d1;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.06em;
}

body.vge-term-singular .sdg-side-cta .sdg-side-title {
	color: #f7f4ff;
	font-size: 21px;
}

body.vge-term-singular .sdg-side-cta .sdg-side-description {
	color: #d2c8e4;
	font-size: 14px;
	line-height: 1.6;
}

body.vge-term-singular .sdg-button {
	min-height: 46px;
	margin-top: 4px;
	border-radius: var(--lai-radius-control);
	background: var(--lai-gradient);
	font-family: var(--lai-font);
	font-size: 14px;
	font-weight: 700;
	box-shadow: var(--lai-shadow-control);
	transition: background 0.16s ease;
}

body.vge-term-singular .sdg-button:hover {
	background: var(--lai-gradient-hover);
}

body.vge-term-singular .sdg-search-button:focus-visible,
body.vge-term-singular .sdg-letter:focus-visible,
body.vge-term-singular .sdg-related-item:focus-visible,
body.vge-term-singular .sdg-all-link:focus-visible,
body.vge-term-singular .sdg-button:focus-visible {
	outline: 3px solid var(--lai-focus);
	outline-offset: 3px;
}

/* Back to top */
body.vge-term-singular .vge-back-to-top {
	position: fixed;
	right: 2.75rem;
	bottom: 3.5rem;
	z-index: 9995;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.75rem;
	height: 2.75rem;
	padding: 0;
	border: 0;
	border-radius: 14px;
	background: var(--lai-gradient);
	color: #ffffff;
	box-shadow: var(--lai-shadow-control);
	cursor: pointer;
	opacity: 0;
	visibility: hidden;
	transform: translateY(8px);
	transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s, background 0.16s ease;
}

body.vge-term-singular .vge-back-to-top.is-visible {
	opacity: 0.94;
	visibility: visible;
	transform: none;
}

body.vge-term-singular .vge-back-to-top:hover,
body.vge-term-singular .vge-back-to-top:focus-visible {
	opacity: 1;
	background: var(--lai-gradient-hover);
	outline: none;
	box-shadow: 0 12px 26px rgba(118, 85, 233, 0.3);
}

@media (max-width: 980px) {
	body.vge-term-singular .vge-back-to-top {
		right: 1.25rem;
		bottom: calc(112px + env(safe-area-inset-bottom, 0px));
	}
}

@media (prefers-reduced-motion: reduce) {
	body.vge-term-singular .vge-back-to-top {
		transition: none;
	}
}

/* ==========================================================
   Responsive
   ========================================================== */

@media (max-width: 980px) {
	body.vge-term-singular.et-tb-has-header #main-content,
	body.vge-term-singular.et-tb #main-content {
		padding-top: 20px !important;
	}

	body.vge-term-singular .sd-glossary-content {
		padding: 36px 30px 28px;
	}

	body.vge-term-singular .sd-glossary-image-column {
		padding: 0 30px 30px;
	}

	body.vge-term-singular .sdg-content {
		padding: 28px 26px;
	}

	body.vge-term-singular .sdg-letter {
		font-size: 16px;
	}
}

@media (max-width: 640px) {
	body.vge-term-singular .sdg-page .sd-glossary-card {
		border-radius: var(--lai-radius-card);
	}

	body.vge-term-singular .sd-glossary-content {
		padding: 28px 20px 24px;
	}

	body.vge-term-singular .sd-glossary-title,
	body.vge-term-singular .sd-glossary-title--short {
		font-size: clamp(32px, 9vw, 42px);
	}

	body.vge-term-singular .sd-glossary-image-column {
		padding: 0 16px 16px;
	}

	body.vge-term-singular .sd-example {
		padding: 20px;
	}

	body.vge-term-singular .sd-example-text {
		font-size: 21px;
	}

	body.vge-term-singular .sdg-main {
		padding: 28px 0 56px;
	}

	body.vge-term-singular .sdg-content {
		padding: 22px 18px;
		border-radius: var(--lai-radius-card);
	}

	body.vge-term-singular .sdg-letter {
		font-size: 18px;
	}

	body.vge-term-singular .sdg-prose p,
	body.vge-term-singular .sdg-prose li {
		font-size: 15.5px;
	}
}
