/* =====================================================================
 * Trooper Lu's FAQs — front-end styles
 * =====================================================================
 *
 * Self-contained by design. Earlier versions inherited almost everything
 * from the theme, which produced unpredictable results inside Elementor —
 * whatever font size and colour the surrounding widget happened to set.
 * This version ships its own type scale, spacing scale and colours, so the
 * block looks the same wherever it is dropped.
 *
 * Brand colour is set from the plugin settings (default Trooper Lu red).
 * Only the font family is inherited, so it still matches the site's type.
 *
 * Sections:
 *   1. Tokens
 *   2. Elementor container fixes
 *   3. Filter bar (search, dropdowns, pills)
 *   4. Category headings
 *   5. Accordion
 *   6. Feedback + contact prompt
 *   7. Category cards / live search
 *   8. Theme bleed guards  <- load-bearing !important rules, see notes
 *   9. Responsive / print / a11y
 * ------------------------------------------------------------------- */

/* ---------------------------------------------------------------------
 * 1. Tokens
 * ------------------------------------------------------------------ */

.tlg-faqs,
.tlg-faqs-live,
.tlg-faqs-cats {
	--tlg-accent: #d21f26;
	--tlg-accent-ink: #fff;

	--tlg-ink: #1d2327;
	--tlg-ink-soft: #5b6470;
	--tlg-line: #e2e5e9;
	--tlg-line-strong: #cdd2d9;
	--tlg-surface: #fff;
	--tlg-surface-soft: #f6f7f9;

	--tlg-radius: 8px;
	--tlg-shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 1px 3px rgba(16, 24, 40, .06);
	--tlg-shadow-lift: 0 4px 12px rgba(16, 24, 40, .08);

	/* Type scale — fixed, not inherited, so Elementor cannot shrink it. */
	--tlg-fs-body: 1rem;
	--tlg-fs-q: 1.0625rem;
	--tlg-fs-small: .875rem;
	--tlg-fs-label: .75rem;

	/* Spacing scale */
	--tlg-sp-1: .25rem;
	--tlg-sp-2: .5rem;
	--tlg-sp-3: .75rem;
	--tlg-sp-4: 1rem;
	--tlg-sp-5: 1.5rem;
	--tlg-sp-6: 2rem;
	--tlg-sp-7: 3rem;

	/* Type family is the one thing worth inheriting. */
	font-family: inherit;
	font-size: var(--tlg-fs-body);
	line-height: 1.6;
	color: var(--tlg-ink);
	text-align: left;
}

/* ---------------------------------------------------------------------
 * 2. Elementor container fixes
 *
 * A shortcode widget gives the block whatever width and typography the
 * surrounding column has. These rules make it behave predictably.
 * ------------------------------------------------------------------ */

.elementor-widget-shortcode .tlg-faqs,
.elementor-widget-shortcode .tlg-faqs-live,
.elementor-widget-shortcode .tlg-faqs-cats,
.elementor-shortcode .tlg-faqs,
.elementor-widget-container > .tlg-faqs {
	width: 100%;
	max-width: 100%;
}

.tlg-faqs *,
.tlg-faqs *::before,
.tlg-faqs *::after,
.tlg-faqs-cats *,
.tlg-faqs-live * {
	box-sizing: border-box;
}

/* Elementor and themes both set heading margins; normalise inside the block. */
.tlg-faqs h2,
.tlg-faqs h3,
.tlg-faqs h4,
.tlg-faqs h5 {
	margin: 0;
	padding: 0;
	text-transform: none;
	letter-spacing: normal;
}

.tlg-faqs p {
	margin: 0 0 var(--tlg-sp-3);
	font-size: var(--tlg-fs-body);
	line-height: 1.65;
}

.tlg-faqs p:last-child {
	margin-bottom: 0;
}

.tlg-faqs ul,
.tlg-faqs ol {
	margin: 0 0 var(--tlg-sp-3);
	padding-left: 1.25rem;
}

/* ---------------------------------------------------------------------
 * 3. Filter bar
 * ------------------------------------------------------------------ */

.tlg-faqs__toolbar {
	background: var(--tlg-surface-soft);
	border: 1px solid var(--tlg-line);
	border-radius: var(--tlg-radius);
	padding: var(--tlg-sp-4);
	margin: 0 0 var(--tlg-sp-6);
}

.tlg-faqs__searchbar {
	display: flex;
	align-items: center;
	gap: var(--tlg-sp-3);
	flex-wrap: wrap;
	margin: 0;
}

.tlg-faqs__toolbar .tlg-faqs__searchbar + .tlg-faqs__selects,
.tlg-faqs__toolbar .tlg-faqs__searchbar + .tlg-faqs__pills {
	margin-top: var(--tlg-sp-4);
	padding-top: var(--tlg-sp-4);
	border-top: 1px solid var(--tlg-line);
}

.tlg-faqs .tlg-faqs__search {
	flex: 1 1 280px;
	width: 100%;
	min-height: 46px;
	padding: var(--tlg-sp-3) var(--tlg-sp-4);
	border: 1px solid var(--tlg-line-strong);
	border-radius: var(--tlg-radius);
	background: var(--tlg-surface);
	font-family: inherit;
	font-size: var(--tlg-fs-body);
	line-height: 1.4;
	color: var(--tlg-ink);
}

.tlg-faqs .tlg-faqs__search::placeholder {
	color: var(--tlg-ink-soft);
	opacity: 1;
}

.tlg-faqs .tlg-faqs__search:focus,
.tlg-faqs .tlg-faqs__search:focus-visible {
	outline: 2px solid var(--tlg-accent);
	outline-offset: 1px;
	border-color: var(--tlg-accent);
}

.tlg-faqs__count {
	flex: 0 0 auto;
	font-size: var(--tlg-fs-small);
	font-weight: 600;
	color: var(--tlg-ink-soft);
	white-space: nowrap;
}

/* --- Cascading dropdowns --- */

.tlg-faqs__selects {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	gap: var(--tlg-sp-3) var(--tlg-sp-4);
	margin: 0;
}

.tlg-faqs__select-wrap {
	flex: 1 1 240px;
	min-width: 0;
}

.tlg-faqs__select-label {
	display: block;
	margin-bottom: var(--tlg-sp-1);
	font-size: var(--tlg-fs-label);
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .05em;
	color: var(--tlg-ink-soft);
}

.tlg-faqs .tlg-faqs__select {
	width: 100%;
	min-height: 46px;
	padding: var(--tlg-sp-3) 2.4rem var(--tlg-sp-3) var(--tlg-sp-4);
	border: 1px solid var(--tlg-line-strong);
	border-radius: var(--tlg-radius);
	background-color: var(--tlg-surface);
	font-family: inherit;
	font-size: var(--tlg-fs-body);
	line-height: 1.4;
	cursor: pointer;
	appearance: none;
	-webkit-appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath fill='%235b6470' d='M1.4 0 6 4.6 10.6 0 12 1.4 6 7.4 0 1.4z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right var(--tlg-sp-4) center;
	background-size: .7rem;
}

.tlg-faqs .tlg-faqs__select:hover:not(:disabled) {
	border-color: var(--tlg-accent);
}

.tlg-faqs .tlg-faqs__select:focus-visible {
	outline: 2px solid var(--tlg-accent);
	outline-offset: 1px;
	border-color: var(--tlg-accent);
}

.tlg-faqs .tlg-faqs__select:disabled {
	opacity: .6;
	cursor: not-allowed;
	background-color: var(--tlg-surface-soft);
}

.tlg-faqs .tlg-faqs__reset {
	flex: 0 0 auto;
	min-height: 46px;
	padding: var(--tlg-sp-3) var(--tlg-sp-5);
	border: 1px solid var(--tlg-line-strong);
	border-radius: var(--tlg-radius);
	background: var(--tlg-surface);
	font-family: inherit;
	font-size: var(--tlg-fs-small);
	font-weight: 600;
	cursor: pointer;
}

.tlg-faqs .tlg-faqs__reset:hover {
	border-color: var(--tlg-accent);
	color: var(--tlg-accent);
}

.tlg-faqs .tlg-faqs__reset[hidden] {
	display: none;
}

/* --- Pills (alternative style) --- */

.tlg-faqs__pills {
	display: flex;
	flex-wrap: wrap;
	gap: var(--tlg-sp-2);
	margin: 0;
}

.tlg-faqs .tlg-faqs__pill {
	display: inline-flex;
	align-items: center;
	gap: var(--tlg-sp-2);
	min-height: 40px;
	padding: var(--tlg-sp-2) var(--tlg-sp-4);
	border: 1px solid var(--tlg-line-strong);
	border-radius: 999px;
	background: var(--tlg-surface);
	font-family: inherit;
	font-size: var(--tlg-fs-small);
	font-weight: 600;
	line-height: 1.2;
	cursor: pointer;
	transition: border-color .15s ease, background-color .15s ease;
}

.tlg-faqs .tlg-faqs__pill:hover {
	border-color: var(--tlg-accent);
}

.tlg-faqs .tlg-faqs__pill:focus-visible {
	outline: 2px solid var(--tlg-accent);
	outline-offset: 2px;
}

.tlg-faqs .tlg-faqs__pill.is-active {
	background: var(--tlg-accent);
	border-color: var(--tlg-accent);
}

.tlg-faqs__pill-n {
	display: inline-block;
	min-width: 1.6em;
	padding: .1em .45em;
	border-radius: 999px;
	background: var(--tlg-surface-soft);
	font-size: .8em;
	font-weight: 700;
	text-align: center;
}

.tlg-faqs .tlg-faqs__pill.is-active .tlg-faqs__pill-n {
	background: rgba(255, 255, 255, .22);
}

/* ---------------------------------------------------------------------
 * 4. Category headings
 * ------------------------------------------------------------------ */

.tlg-faqs__group {
	margin: 0 0 var(--tlg-sp-6);
}

.tlg-faqs__group[hidden] {
	display: none;
}

.tlg-faqs .tlg-faqs__group-title {
	margin: 0 0 var(--tlg-sp-4);
	padding: 0;
	border: 0;
	font-family: inherit;
	font-size: 1.25rem;
	font-weight: 700;
	line-height: 1.3;
	color: var(--tlg-ink);
}

/* Collapsed sections keep their heading tight to the next one. */
.tlg-faqs__group.is-collapsed .tlg-faqs__group-title { margin-bottom: var(--tlg-sp-2); }

/* The heading is a toggle button. */
.tlg-faqs .tlg-faqs__group-toggle {
	display: flex;
	align-items: center;
	gap: var(--tlg-sp-3);
	width: 100%;
	margin: 0;
	padding: var(--tlg-sp-3) 0;
	border: 0;
	border-bottom: 2px solid var(--tlg-accent);
	border-radius: 0;
	background: transparent;
	font: inherit;
	font-size: inherit;
	font-weight: inherit;
	line-height: inherit;
	text-align: left;
	text-transform: none;
	letter-spacing: normal;
	cursor: pointer;
	transition: opacity .15s ease;
}

.tlg-faqs .tlg-faqs__group-toggle:hover { opacity: .75; }

.tlg-faqs .tlg-faqs__group-toggle:focus-visible {
	outline: 2px solid var(--tlg-accent);
	outline-offset: 2px;
}

.tlg-faqs__group-name { flex: 1 1 auto; min-width: 0; }

.tlg-faqs__group-n {
	flex: 0 0 auto;
	min-width: 2em;
	padding: .15em .55em;
	border-radius: 999px;
	background: var(--tlg-surface-soft);
	font-size: .7em;
	font-weight: 700;
	text-align: center;
}

/* Chevron, matching the question rows. */
.tlg-faqs__group-icon {
	flex: 0 0 auto;
	width: .55em;
	height: .55em;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(-135deg) translate(-2px, -2px);
	transition: transform .2s ease;
	opacity: .6;
}

.tlg-faqs__group.is-collapsed .tlg-faqs__group-icon {
	transform: rotate(45deg) translate(-2px, -2px);
}

/* Expand all / collapse all */
.tlg-faqs__bulk {
	display: flex;
	flex-wrap: wrap;
	gap: var(--tlg-sp-2);
	margin-top: var(--tlg-sp-4);
	padding-top: var(--tlg-sp-4);
	border-top: 1px solid var(--tlg-line);
}

.tlg-faqs .tlg-faqs__bulk-btn {
	padding: var(--tlg-sp-2) var(--tlg-sp-3);
	border: 0;
	background: transparent;
	font: inherit;
	font-size: var(--tlg-fs-small);
	font-weight: 600;
	text-decoration: underline;
	cursor: pointer;
}

.tlg-faqs .tlg-faqs__bulk-btn:hover { color: var(--tlg-accent); }
.tlg-faqs .tlg-faqs__bulk-btn:focus-visible { outline: 2px solid var(--tlg-accent); outline-offset: 2px; }

/* ---------------------------------------------------------------------
 * 5. Accordion
 * ------------------------------------------------------------------ */

.tlg-faqs__list {
	display: flex;
	flex-direction: column;
	gap: var(--tlg-sp-2);
}

/* display:flex above overrides the browser's [hidden] { display:none },
   so collapsed sections need it stated explicitly. */
.tlg-faqs .tlg-faqs__list[hidden] { display: none; }

.tlg-faqs__item {
	border: 1px solid var(--tlg-line);
	border-radius: var(--tlg-radius);
	background: var(--tlg-surface);
	box-shadow: var(--tlg-shadow);
	overflow: hidden;
	transition: border-color .15s ease, box-shadow .15s ease;
}

.tlg-faqs__item[hidden] {
	display: none;
}

.tlg-faqs__item:hover {
	box-shadow: var(--tlg-shadow-lift);
}

.tlg-faqs__item.is-open {
	border-color: var(--tlg-accent);
	box-shadow: var(--tlg-shadow-lift);
}

.tlg-faqs__item:target {
	border-color: var(--tlg-accent);
	box-shadow: 0 0 0 3px rgba(210, 31, 38, .14);
}

.tlg-faqs .tlg-faqs__q {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: var(--tlg-sp-4);
	width: 100%;
	margin: 0;
	padding: var(--tlg-sp-4) var(--tlg-sp-5);
	border: 0;
	border-radius: 0;
	background: transparent;
	font-family: inherit;
	font-size: var(--tlg-fs-q);
	font-weight: 600;
	line-height: 1.45;
	text-align: left;
	text-transform: none;
	letter-spacing: normal;
	cursor: pointer;
	transition: background-color .15s ease;
}

.tlg-faqs__q-text {
	flex: 1 1 auto;
	min-width: 0;
}

/* Chevron */
.tlg-faqs__icon {
	flex: 0 0 auto;
	width: .6em;
	height: .6em;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg) translate(-2px, -2px);
	transition: transform .2s ease;
	opacity: .5;
}

.tlg-faqs__item.is-open .tlg-faqs__icon {
	transform: rotate(-135deg) translate(-2px, -2px);
	opacity: 1;
}

.tlg-faqs__a {
	padding: var(--tlg-sp-4) var(--tlg-sp-5) var(--tlg-sp-5);
	border-top: 1px solid var(--tlg-line);
	font-size: var(--tlg-fs-body);
	line-height: 1.65;
}

.tlg-faqs__a[hidden] {
	display: none;
}

.tlg-faqs__a > *:first-child { margin-top: 0; }
.tlg-faqs__a > *:last-child { margin-bottom: 0; }

.tlg-faqs mark {
	background: #fff3cd;
	padding: 0 .15em;
	border-radius: 2px;
}

/* Empty state */
.tlg-faqs__noresults {
	padding: var(--tlg-sp-6);
	background: var(--tlg-surface-soft);
	border: 1px dashed var(--tlg-line-strong);
	border-radius: var(--tlg-radius);
	text-align: center;
	color: var(--tlg-ink-soft);
}

.tlg-faqs__more {
	margin: var(--tlg-sp-5) 0 0;
}

/* ---------------------------------------------------------------------
 * 6. Feedback + contact prompt
 * ------------------------------------------------------------------ */

.tlg-faqs__fb {
	display: flex;
	align-items: center;
	gap: var(--tlg-sp-2);
	margin-top: var(--tlg-sp-4);
	padding-top: var(--tlg-sp-3);
	border-top: 1px solid var(--tlg-line);
	font-size: var(--tlg-fs-small);
	color: var(--tlg-ink-soft);
}

.tlg-faqs__fb.is-done { font-style: italic; }

.tlg-faqs .tlg-faqs__fb-btn {
	min-width: 40px;
	min-height: 32px;
	border: 1px solid var(--tlg-line-strong);
	background: var(--tlg-surface);
	border-radius: var(--tlg-radius);
	cursor: pointer;
	font-size: 1rem;
	line-height: 1;
	padding: var(--tlg-sp-1) var(--tlg-sp-2);
	transition: border-color .15s ease;
}

.tlg-faqs .tlg-faqs__fb-btn:hover { border-color: var(--tlg-accent); }
.tlg-faqs .tlg-faqs__fb-btn:focus-visible { outline: 2px solid var(--tlg-accent); outline-offset: 1px; }

.tlg-faqs__cta {
	margin-top: var(--tlg-sp-6);
	padding: var(--tlg-sp-5);
	background: var(--tlg-surface-soft);
	border: 1px solid var(--tlg-line);
	border-left: 4px solid var(--tlg-accent);
	border-radius: var(--tlg-radius);
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--tlg-sp-2) var(--tlg-sp-4);
}

.tlg-faqs__cta strong {
	font-size: 1.0625rem;
	flex: 0 0 auto;
}

.tlg-faqs__cta span {
	flex: 1 1 240px;
	color: var(--tlg-ink-soft);
	font-size: var(--tlg-fs-small);
}

.tlg-faqs .tlg-faqs__cta-btn {
	flex: 0 0 auto;
	display: inline-block;
	padding: var(--tlg-sp-3) var(--tlg-sp-5);
	background: var(--tlg-accent);
	border-radius: var(--tlg-radius);
	font-size: var(--tlg-fs-small);
	font-weight: 700;
	text-decoration: none;
	white-space: nowrap;
}

.tlg-faqs .tlg-faqs__cta-btn:hover { filter: brightness(.92); }

/* ---------------------------------------------------------------------
 * 7. Category cards + live AJAX search
 * ------------------------------------------------------------------ */

.tlg-faqs-cats {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
	gap: var(--tlg-sp-4);
	margin: 0 0 var(--tlg-sp-6);
}

.tlg-faqs-cats .tlg-faqs-cat {
	display: block;
	padding: var(--tlg-sp-5);
	border: 1px solid var(--tlg-line);
	border-radius: var(--tlg-radius);
	background: var(--tlg-surface);
	box-shadow: var(--tlg-shadow);
	text-decoration: none;
	transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease;
}

.tlg-faqs-cats .tlg-faqs-cat:hover {
	border-color: var(--tlg-accent);
	transform: translateY(-2px);
	box-shadow: var(--tlg-shadow-lift);
}

.tlg-faqs-cats .tlg-faqs-cat:focus-visible {
	outline: 2px solid var(--tlg-accent);
	outline-offset: 2px;
}

.tlg-faqs-cat__name {
	display: block;
	font-size: 1.0625rem;
	font-weight: 700;
	margin-bottom: var(--tlg-sp-1);
}

.tlg-faqs-cat__count {
	display: block;
	font-size: var(--tlg-fs-label);
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .05em;
	margin-bottom: var(--tlg-sp-2);
}

.tlg-faqs-cat__subs {
	display: block;
	font-size: var(--tlg-fs-small);
	line-height: 1.5;
}

.tlg-faqs-live {
	position: relative;
	max-width: 640px;
	margin: 0 auto var(--tlg-sp-6);
}

.tlg-faqs-live .tlg-faqs-live__input {
	width: 100%;
	min-height: 48px;
	padding: var(--tlg-sp-3) var(--tlg-sp-4);
	border: 1px solid var(--tlg-line-strong);
	border-radius: var(--tlg-radius);
	background: var(--tlg-surface);
	font-family: inherit;
	font-size: var(--tlg-fs-body);
}

.tlg-faqs-live .tlg-faqs-live__input:focus-visible {
	outline: 2px solid var(--tlg-accent);
	outline-offset: 1px;
	border-color: var(--tlg-accent);
}

.tlg-faqs-live__results:not(:empty) {
	margin-top: var(--tlg-sp-2);
	border: 1px solid var(--tlg-line);
	border-radius: var(--tlg-radius);
	background: var(--tlg-surface);
	max-height: 26rem;
	overflow-y: auto;
	box-shadow: var(--tlg-shadow-lift);
}

.tlg-faqs-live .tlg-faqs-live__hit {
	display: block;
	padding: var(--tlg-sp-3) var(--tlg-sp-4);
	border-bottom: 1px solid var(--tlg-line);
	text-decoration: none;
}

.tlg-faqs-live .tlg-faqs-live__hit:last-child { border-bottom: 0; }
.tlg-faqs-live .tlg-faqs-live__hit:hover { background: var(--tlg-surface-soft); }

.tlg-faqs-live .tlg-faqs-live__hit strong {
	display: block;
	margin-bottom: var(--tlg-sp-1);
	font-size: var(--tlg-fs-body);
}

.tlg-faqs-live .tlg-faqs-live__hit span { font-size: var(--tlg-fs-small); }

.tlg-faqs-live__status {
	padding: var(--tlg-sp-3) var(--tlg-sp-4);
	font-size: var(--tlg-fs-small);
	color: var(--tlg-ink-soft);
}

/* =====================================================================
 * 8. THEME BLEED GUARDS
 * =====================================================================
 *
 * Themes and Elementor ship blanket rules such as:
 *
 *     button:hover, button:hover span { color: #fff !important; }
 *     a:hover, a:hover span           { color: #fff !important; }
 *     button:focus                    { background: <accent> !important; }
 *
 * meant for their own components. They leak in here and turn question
 * text white on white, or repaint the clicked row. Specificity cannot
 * beat !important, so every interactive element pins its colour below.
 *
 * These are the only !important rules in the file and all are scoped to
 * this component. Override from FAQs > Settings > Custom CSS.
 * ------------------------------------------------------------------- */

/* Question row, closed */
.tlg-faqs .tlg-faqs__item:not(.is-open) > .tlg-faqs__q,
.tlg-faqs .tlg-faqs__item:not(.is-open) > .tlg-faqs__q:focus,
.tlg-faqs .tlg-faqs__item:not(.is-open) > .tlg-faqs__q:focus-visible,
.tlg-faqs .tlg-faqs__item:not(.is-open) > .tlg-faqs__q:active {
	background: transparent !important;
}

.tlg-faqs .tlg-faqs__item:not(.is-open) > .tlg-faqs__q:hover {
	background: var(--tlg-surface-soft) !important;
}

.tlg-faqs .tlg-faqs__q,
.tlg-faqs .tlg-faqs__q:hover,
.tlg-faqs .tlg-faqs__q:focus,
.tlg-faqs .tlg-faqs__q:focus-visible,
.tlg-faqs .tlg-faqs__q:active,
.tlg-faqs .tlg-faqs__q > *,
.tlg-faqs .tlg-faqs__q:hover > *,
.tlg-faqs .tlg-faqs__q:focus > *,
.tlg-faqs .tlg-faqs__q:active > * {
	color: var(--tlg-ink) !important;
}

/* Question row, open — accent bar with light text */
.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q,
.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q:hover,
.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q:focus,
.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q:focus-visible,
.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q:active {
	background: var(--tlg-accent) !important;
}

.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q,
.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q > *,
.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q:hover,
.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q:hover > *,
.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q:focus,
.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q:focus > *,
.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q:active,
.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q:active > * {
	color: var(--tlg-accent-ink) !important;
}

.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q .tlg-faqs__icon { opacity: 1; }

.tlg-faqs:not(.tlg-open-plain) .tlg-faqs__item.is-open > .tlg-faqs__q:focus-visible {
	outline: 2px solid var(--tlg-accent-ink) !important;
	outline-offset: -4px;
}

/* Answer body */
.tlg-faqs .tlg-faqs__item .tlg-faqs__a,
.tlg-faqs .tlg-faqs__item .tlg-faqs__a p,
.tlg-faqs .tlg-faqs__item .tlg-faqs__a li,
.tlg-faqs .tlg-faqs__item .tlg-faqs__a span:not(.tlg-faqs__fb-q) {
	color: var(--tlg-answer, var(--tlg-ink)) !important;
}

.tlg-faqs .tlg-faqs__item .tlg-faqs__a a {
	color: var(--tlg-accent) !important;
	text-decoration: underline;
}

/* Headings and their toggle */
.tlg-faqs .tlg-faqs__group-title,
.tlg-faqs .tlg-faqs__group-title:hover,
.tlg-faqs .tlg-faqs__group-toggle,
.tlg-faqs .tlg-faqs__group-toggle:hover,
.tlg-faqs .tlg-faqs__group-toggle:focus,
.tlg-faqs .tlg-faqs__group-toggle:active,
.tlg-faqs .tlg-faqs__group-toggle > *,
.tlg-faqs .tlg-faqs__group-toggle:hover > *,
.tlg-faqs .tlg-faqs__group-toggle:focus > * {
	color: var(--tlg-ink) !important;
	background-color: transparent !important;
}

.tlg-faqs .tlg-faqs__group-toggle .tlg-faqs__group-n,
.tlg-faqs .tlg-faqs__group-toggle:hover .tlg-faqs__group-n {
	color: var(--tlg-ink-soft) !important;
	background-color: var(--tlg-surface-soft) !important;
}

.tlg-faqs .tlg-faqs__bulk-btn,
.tlg-faqs .tlg-faqs__bulk-btn:focus,
.tlg-faqs .tlg-faqs__bulk-btn:active { color: var(--tlg-ink-soft) !important; background-color: transparent !important; }
.tlg-faqs .tlg-faqs__bulk-btn:hover { color: var(--tlg-accent) !important; background-color: transparent !important; }

/* Selects, inputs, reset */
.tlg-faqs .tlg-faqs__select,
.tlg-faqs .tlg-faqs__select:hover,
.tlg-faqs .tlg-faqs__select:focus,
.tlg-faqs .tlg-faqs__search,
.tlg-faqs .tlg-faqs__search:hover,
.tlg-faqs .tlg-faqs__search:focus,
.tlg-faqs-live .tlg-faqs-live__input,
.tlg-faqs-live .tlg-faqs-live__input:focus {
	color: var(--tlg-ink) !important;
	background-color: var(--tlg-surface) !important;
}

.tlg-faqs .tlg-faqs__reset,
.tlg-faqs .tlg-faqs__reset:focus,
.tlg-faqs .tlg-faqs__reset:active { color: var(--tlg-ink) !important; }
.tlg-faqs .tlg-faqs__reset:hover { color: var(--tlg-accent) !important; }

/* Pills */
.tlg-faqs .tlg-faqs__pill:not(.is-active),
.tlg-faqs .tlg-faqs__pill:not(.is-active):hover,
.tlg-faqs .tlg-faqs__pill:not(.is-active):focus,
.tlg-faqs .tlg-faqs__pill:not(.is-active):active { color: var(--tlg-ink) !important; }

.tlg-faqs .tlg-faqs__pill:not(.is-active) .tlg-faqs__pill-n,
.tlg-faqs .tlg-faqs__pill:not(.is-active):hover .tlg-faqs__pill-n { color: var(--tlg-ink-soft) !important; }

.tlg-faqs .tlg-faqs__pill.is-active,
.tlg-faqs .tlg-faqs__pill.is-active:hover,
.tlg-faqs .tlg-faqs__pill.is-active:focus,
.tlg-faqs .tlg-faqs__pill.is-active .tlg-faqs__pill-n,
.tlg-faqs .tlg-faqs__pill.is-active:hover .tlg-faqs__pill-n { color: var(--tlg-accent-ink) !important; }

/* Feedback buttons */
.tlg-faqs .tlg-faqs__fb-btn,
.tlg-faqs .tlg-faqs__fb-btn:hover,
.tlg-faqs .tlg-faqs__fb-btn:focus,
.tlg-faqs .tlg-faqs__fb-btn:active { color: var(--tlg-ink) !important; }

/* Category cards */
.tlg-faqs-cats .tlg-faqs-cat,
.tlg-faqs-cats .tlg-faqs-cat:link,
.tlg-faqs-cats .tlg-faqs-cat:visited,
.tlg-faqs-cats .tlg-faqs-cat:hover,
.tlg-faqs-cats .tlg-faqs-cat:focus,
.tlg-faqs-cats .tlg-faqs-cat:active,
.tlg-faqs-cats .tlg-faqs-cat .tlg-faqs-cat__name,
.tlg-faqs-cats .tlg-faqs-cat:hover .tlg-faqs-cat__name { color: var(--tlg-ink) !important; }

.tlg-faqs-cats .tlg-faqs-cat .tlg-faqs-cat__count,
.tlg-faqs-cats .tlg-faqs-cat:hover .tlg-faqs-cat__count { color: var(--tlg-accent) !important; }

.tlg-faqs-cats .tlg-faqs-cat .tlg-faqs-cat__subs,
.tlg-faqs-cats .tlg-faqs-cat:hover .tlg-faqs-cat__subs { color: var(--tlg-ink-soft) !important; }

/* Live search hits */
.tlg-faqs-live .tlg-faqs-live__hit,
.tlg-faqs-live .tlg-faqs-live__hit:link,
.tlg-faqs-live .tlg-faqs-live__hit:visited,
.tlg-faqs-live .tlg-faqs-live__hit:hover,
.tlg-faqs-live .tlg-faqs-live__hit:focus,
.tlg-faqs-live .tlg-faqs-live__hit strong,
.tlg-faqs-live .tlg-faqs-live__hit:hover strong { color: var(--tlg-ink) !important; }

.tlg-faqs-live .tlg-faqs-live__hit span,
.tlg-faqs-live .tlg-faqs-live__hit:hover span { color: var(--tlg-ink-soft) !important; }

/* Links + CTA button */
.tlg-faqs .tlg-faqs__more-link,
.tlg-faqs .tlg-faqs__more-link:link,
.tlg-faqs .tlg-faqs__more-link:visited,
.tlg-faqs .tlg-faqs__more-link:hover,
.tlg-faqs .tlg-faqs__more-link:focus,
.tlg-faqs .tlg-faqs__more-link:active {
	font-weight: 700;
	text-decoration: none;
	color: var(--tlg-accent) !important;
}

.tlg-faqs .tlg-faqs__more-link:hover { text-decoration: underline; }

.tlg-faqs .tlg-faqs__cta-btn,
.tlg-faqs .tlg-faqs__cta-btn:link,
.tlg-faqs .tlg-faqs__cta-btn:visited,
.tlg-faqs .tlg-faqs__cta-btn:hover,
.tlg-faqs .tlg-faqs__cta-btn:focus,
.tlg-faqs .tlg-faqs__cta-btn:active {
	color: var(--tlg-accent-ink) !important;
	background-color: var(--tlg-accent) !important;
}

/* ---------------------------------------------------------------------
 * 9. Responsive / a11y / print
 * ------------------------------------------------------------------ */

@media (max-width: 782px) {
	.tlg-faqs { --tlg-fs-q: 1rem; }

	.tlg-faqs__toolbar { padding: var(--tlg-sp-3); }
	.tlg-faqs__select-wrap { flex: 1 1 100%; }
	.tlg-faqs .tlg-faqs__reset { width: 100%; }

	.tlg-faqs .tlg-faqs__q { padding: var(--tlg-sp-4); }
	.tlg-faqs__a { padding: var(--tlg-sp-4); }

	.tlg-faqs .tlg-faqs__group-title { font-size: 1.125rem; }

	.tlg-faqs__pills {
		flex-wrap: nowrap;
		overflow-x: auto;
		scrollbar-width: none;
		-webkit-overflow-scrolling: touch;
		padding-bottom: var(--tlg-sp-1);
	}

	.tlg-faqs__pills::-webkit-scrollbar { display: none; }
	.tlg-faqs .tlg-faqs__pill { flex: 0 0 auto; }

	.tlg-faqs__cta { flex-direction: column; align-items: flex-start; }
	.tlg-faqs .tlg-faqs__cta-btn { width: 100%; text-align: center; }
}

.screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

@media (prefers-reduced-motion: reduce) {
	.tlg-faqs *,
	.tlg-faqs-cats * { transition: none !important; }
}

@media print {
	.tlg-faqs__toolbar,
	.tlg-faqs-live,
	.tlg-faqs__fb,
	.tlg-faqs__cta { display: none; }

	.tlg-faqs__a[hidden] { display: block !important; }
	.tlg-faqs__item { break-inside: avoid; box-shadow: none; }
}
