/* =============================================================
 * Grit Guide Filter Bar
 * Matches the editorial wireframe system: Bebas Neue + Helvetica,
 * navy #091A2F ink, white surfaces, grey rules.
 * ========================================================== */

.ggfb-wrap {
	--ggfb-ink: #091A2F;
	--ggfb-text-muted: #585B5D;
	--ggfb-text-soft: #76797C;
	--ggfb-hint: #94989B;
	--ggfb-rule: #DEE0E1;
	--ggfb-rule-soft: #E9EAEB;
	--ggfb-surface: #F4F5F5;
	--ggfb-paper: #FFFFFF;

	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	color: var(--ggfb-ink);
	background: var(--ggfb-paper);
	position: relative;
}

/* ---------- Universal button/input reset (wins over theme/Kit) ---
 * Many WP themes and Elementor Kits style ALL <button>/<input>
 * elements with backgrounds, borders, and box-shadows. We override
 * everything inside .ggfb-wrap so our controls take effect.
 * --------------------------------------------------------- */
.ggfb-wrap button,
.ggfb-wrap input,
.ggfb-wrap select {
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	background: none;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	font-family: inherit;
	font-size: inherit;
	font-weight: inherit;
	letter-spacing: inherit;
	text-transform: none;
	color: inherit;
	cursor: pointer;
	margin: 0;
	padding: 0;
	line-height: inherit;
	text-shadow: none;
	outline: none;
}
.ggfb-wrap input { cursor: text; }
.ggfb-wrap button:focus,
.ggfb-wrap button:focus-visible,
.ggfb-wrap button:active,
.ggfb-wrap input:focus,
.ggfb-wrap input:focus-visible,
.ggfb-wrap select:focus,
.ggfb-wrap select:focus-visible {
	outline: none;
	box-shadow: none;
	background: none;
}
.ggfb-wrap button:hover {
	background: none;
	box-shadow: none;
}

/* ---------- Tabs row -------------------------------------- */
.ggfb-tabs-row {
	position: relative;
	border-bottom: 1px solid var(--ggfb-rule);
	overflow: hidden;
}
/* Sticky variant — uses native position:sticky so the row pins to the
 * top of the viewport on scroll WITHOUT freezing the chip area below.
 * Background defaults to white so content scrolling under it stays
 * legible; override via the Tabs Style controls. */
.ggfb-tabs-row--sticky {
	position: sticky;
	background: var(--ggfb-paper);
}
.ggfb-tabs-scroll {
	display: flex;
	gap: 32px;
	overflow-x: auto;
	scrollbar-width: none;
	-webkit-overflow-scrolling: touch;
	padding: 0 4px;
	scroll-behavior: smooth;
}
.ggfb-tabs-scroll::-webkit-scrollbar { display: none; }

/* Scroll arrows — only render when overflow exists.
 * JS toggles [hidden] based on scrollLeft/scrollWidth.
 * They sit on top of the scroll area with a fade gradient
 * behind so tabs appear to scroll *under* the buttons. */
.ggfb-tabs-arrow {
	position: absolute;
	top: 0;
	bottom: 1px; /* sit above the row's bottom border */
	width: 44px;
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 5;
	color: var(--ggfb-ink);
	cursor: pointer;
	transition: opacity 0.15s ease;
}
.ggfb-tabs-arrow[hidden] { display: none; }
.ggfb-tabs-arrow svg {
	width: 18px;
	height: 18px;
	position: relative;
	z-index: 2;
}
.ggfb-tabs-arrow::before {
	content: '';
	position: absolute;
	inset: 0;
	z-index: 1;
	pointer-events: none;
	background: linear-gradient(to right, var(--ggfb-paper) 40%, rgba(255,255,255,0));
}
.ggfb-tabs-arrow--prev {
	left: 0;
	justify-content: flex-start;
	padding-left: 8px;
}
.ggfb-tabs-arrow--next {
	right: 0;
	justify-content: flex-end;
	padding-right: 8px;
}
.ggfb-tabs-arrow--next::before {
	background: linear-gradient(to left, var(--ggfb-paper) 40%, rgba(255,255,255,0));
}
.ggfb-tabs-arrow:hover { opacity: 0.7; }

.ggfb-tab {
	background: none;
	border: 0;
	padding: 16px 0 14px;
	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 18px;
	font-weight: 500;
	letter-spacing: -0.1px;
	color: var(--ggfb-text-soft);
	cursor: pointer;
	white-space: nowrap;
	display: inline-flex;
	align-items: baseline;
	gap: 8px;
	border-bottom: 2px solid transparent;
	margin-bottom: -1px;
	transition: color 0.15s ease;
}
.ggfb-tab:hover { color: var(--ggfb-ink); }
.ggfb-tab.is-active {
	color: var(--ggfb-ink);
	border-bottom-color: var(--ggfb-ink);
	font-weight: 600;
}
.ggfb-tab__count {
	font-size: 12px;
	font-weight: 500;
	color: var(--ggfb-hint);
	letter-spacing: 0.3px;
}
.ggfb-tab.is-active .ggfb-tab__count {
	color: var(--ggfb-text-muted);
}

/* ---------- Controls row (chips + search) ----------------- */
.ggfb-controls-row {
	background: var(--ggfb-surface);
	padding: 14px 16px;
	display: flex;
	align-items: center;
	gap: 24px;
	flex-wrap: wrap;
}

.ggfb-chip-groups {
	display: flex;
	align-items: center;
	gap: 24px;
	flex-wrap: wrap;
	flex: 1;
	min-width: 0;
}

.ggfb-chip-group {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
}
.ggfb-chip-group__label {
	font-size: 10px;
	font-weight: 700;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	color: var(--ggfb-text-soft);
	flex-shrink: 0;
}
.ggfb-chip-group__chips {
	display: flex;
	gap: 6px;
	flex-wrap: wrap;
	align-items: center;
}

/* Chip — pill-shaped, navy fill on active */
.ggfb-chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: var(--ggfb-paper);
	border: 1px solid var(--ggfb-rule);
	border-radius: 100px;
	padding: 6px 14px;
	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 13px;
	font-weight: 500;
	letter-spacing: 0.1px;
	color: var(--ggfb-ink);
	cursor: pointer;
	transition: all 0.15s ease;
	line-height: 1.4;
}
.ggfb-chip:hover {
	border-color: var(--ggfb-ink);
}
.ggfb-chip.is-active {
	background: var(--ggfb-ink);
	border-color: var(--ggfb-ink);
	color: #fff;
	font-weight: 600;
}

/* Disabled — chip has no posts in the active category tab. Greyed out,
 * not clickable. Active state takes precedence (you can't disable a
 * currently-selected chip; tab change resets selections anyway). */
.ggfb-chip.is-disabled {
	color: var(--ggfb-hint);
	background: var(--ggfb-paper);
	border-color: var(--ggfb-rule-soft);
	cursor: not-allowed;
	opacity: 0.55;
	pointer-events: none;
}
.ggfb-chip.is-disabled:hover {
	border-color: var(--ggfb-rule-soft);
	color: var(--ggfb-hint);
	background: var(--ggfb-paper);
}
/* If a chip is BOTH active and disabled (rare edge case after tab switch
 * with leftover state), keep it interactive so the user can deselect it. */
.ggfb-chip.is-disabled.is-active {
	pointer-events: auto;
	cursor: pointer;
	opacity: 0.75;
}

/* X is hidden entirely when chip is inactive — display:none so it
 * takes no space and text stays centered. */
.ggfb-chip__x {
	display: none;
	font-size: 14px;
	line-height: 1;
}
.ggfb-chip.is-active .ggfb-chip__x {
	display: inline-block;
	margin-right: -2px;
}

.ggfb-chip.is-hidden { display: none; }
/* When +More is clicked, .is-revealed forces display back. Use !important
 * so additional state classes (like .is-disabled added by tab filtering)
 * can never accidentally override the reveal. */
.ggfb-chip.is-hidden.is-revealed { display: inline-flex !important; }

.ggfb-chip--more {
	font-style: normal;
	color: var(--ggfb-text-muted);
	border-style: dashed;
}

/* ---------- Search ---------------------------------------- */
.ggfb-search {
	position: relative;
	background: var(--ggfb-paper);
	border: 1px solid var(--ggfb-rule);
	border-radius: 100px;
	display: flex;
	align-items: center;
	min-width: 280px;
	padding: 0 16px;
	gap: 8px;
	transition: border-color 0.15s ease;
}
.ggfb-search:focus-within {
	border-color: var(--ggfb-ink);
}
.ggfb-search__icon {
	width: 14px;
	height: 14px;
	color: var(--ggfb-text-soft);
	flex-shrink: 0;
}
.ggfb-search__input {
	flex: 1;
	border: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
	-webkit-appearance: none !important;
	-moz-appearance: none !important;
	appearance: none !important;
	padding: 9px 0;
	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 13px;
	color: var(--ggfb-ink);
	outline: none !important;
	min-width: 0;
	height: auto;
}
.ggfb-search__input:focus,
.ggfb-search__input:focus-visible,
.ggfb-search__input:active {
	outline: none !important;
	box-shadow: none !important;
	border: 0 !important;
	background: transparent !important;
}
.ggfb-search__input::placeholder {
	color: var(--ggfb-text-soft);
	opacity: 1;
}
/* Kill WebKit's built-in search input clear button + decoration */
.ggfb-search__input::-webkit-search-decoration,
.ggfb-search__input::-webkit-search-cancel-button,
.ggfb-search__input::-webkit-search-results-button,
.ggfb-search__input::-webkit-search-results-decoration {
	-webkit-appearance: none;
	display: none;
}

/* ---------- Summary row ----------------------------------- */
.ggfb-summary-row {
	display: flex;
	align-items: center;
	gap: 16px;
	padding: 14px 16px 0;
	flex-wrap: wrap;
}

.ggfb-summary-count {
	display: inline-flex;
	align-items: baseline;
	gap: 6px;
	font-size: 14px;
	color: var(--ggfb-text-soft);
}
.ggfb-summary-count__num {
	font-weight: 700;
	color: var(--ggfb-ink);
	font-size: 16px;
}
.ggfb-summary-count__label {
	font-weight: 500;
}

.ggfb-active-filters {
	display: flex;
	align-items: center;
	gap: 6px;
	flex-wrap: wrap;
	flex: 1;
	min-width: 0;
}

.ggfb-active-filter {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: var(--ggfb-ink);
	border: 1px solid var(--ggfb-ink);
	color: #fff;
	border-radius: 100px;
	padding: 5px 12px;
	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.1px;
	cursor: pointer;
	line-height: 1.4;
	transition: opacity 0.15s ease;
}
.ggfb-active-filter:hover { opacity: 0.85; }
.ggfb-active-filter__x {
	font-size: 14px;
	line-height: 1;
	opacity: 0.85;
}

.ggfb-summary-actions {
	display: inline-flex;
	align-items: center;
	gap: 16px;
	margin-left: auto;
}

.ggfb-clear-all {
	background: none;
	border: 0;
	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	color: var(--ggfb-text-muted);
	cursor: pointer;
	text-decoration: underline;
	text-underline-offset: 3px;
	padding: 0;
}
.ggfb-clear-all:hover { color: var(--ggfb-ink); }

.ggfb-sort {
	display: inline-flex;
	align-items: center;
	gap: 8px;
}
.ggfb-sort__label {
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 1.2px;
	text-transform: uppercase;
	color: var(--ggfb-text-muted);
}
.ggfb-sort__select {
	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.5px;
	text-transform: uppercase;
	color: var(--ggfb-ink);
	background: transparent;
	border: 0;
	cursor: pointer;
	padding: 4px 0;
	outline: none;
}

/* ---------- Loading state --------------------------------- */
.ggfb-wrap.is-loading {
	pointer-events: none;
	opacity: 0.85;
}
.is-loading.elementor-widget-loop-grid,
.ggfb-results.is-loading {
	position: relative;
	min-height: 200px;
}
.is-loading.elementor-widget-loop-grid::after,
.ggfb-results.is-loading::after {
	content: '';
	position: absolute;
	inset: 0;
	background: rgba(255, 255, 255, 0.6);
	z-index: 5;
	pointer-events: none;
}

/* ---------- Empty state + pagination ---------------------- */
.ggfb-empty {
	padding: 60px 24px;
	text-align: center;
	border: 1px dashed var(--ggfb-rule);
	background: var(--ggfb-surface);
}
.ggfb-empty-title {
	font-family: "Bebas Neue", "Helvetica Neue", sans-serif;
	font-size: 28px;
	letter-spacing: 1.5px;
	color: var(--ggfb-ink);
	margin: 0 0 6px;
}
.ggfb-empty-sub {
	font-size: 13px;
	color: var(--ggfb-text-muted);
	margin: 0;
}

.ggfb-pagination {
	display: flex;
	gap: 4px;
	justify-content: center;
	padding: 32px 0 8px;
}
.ggfb-page {
	min-width: 36px;
	height: 36px;
	padding: 0 10px;
	background: var(--ggfb-paper);
	border: 1px solid var(--ggfb-rule);
	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 13px;
	font-weight: 600;
	color: var(--ggfb-ink);
	cursor: pointer;
	transition: all 0.15s ease;
}
.ggfb-page:hover { border-color: var(--ggfb-ink); }
.ggfb-page.is-current {
	background: var(--ggfb-ink);
	color: #fff;
	border-color: var(--ggfb-ink);
}

/* ---------- Tablet & below — stack chip groups vertically -----
 * On screens ≤1024px, the controls row stacks: search drops to
 * its own row, and each chip group stacks (label above chips,
 * full-width). This eliminates the awkward gap between groups
 * that appeared when desktop tried to keep them inline.
 * ----------------------------------------------------------- */
@media (max-width: 1024px) {
	.ggfb-controls-row {
		flex-direction: column;
		align-items: stretch;
		gap: 16px;
	}
	.ggfb-chip-groups {
		flex-direction: column;
		align-items: stretch;
		gap: 14px;
	}
	.ggfb-chip-group {
		width: 100%;
		flex-direction: column;
		align-items: flex-start;
		gap: 8px;
	}
	.ggfb-chip-group__label {
		margin-bottom: 0;
	}
	.ggfb-search {
		min-width: 0;
		width: 100%;
	}
}

/* ---------- Mobile (≤768px) — tab + summary tweaks ----------- */
@media (max-width: 768px) {
	.ggfb-tabs-scroll { gap: 20px; padding: 0 16px; }
	.ggfb-tab { font-size: 15px; padding: 14px 0 12px; }
	.ggfb-tab__count { font-size: 11px; }

	.ggfb-controls-row {
		padding: 12px 16px;
		gap: 12px;
	}

	.ggfb-summary-row {
		padding: 12px 16px;
		gap: 12px;
		flex-direction: column;
		align-items: stretch;
	}
	.ggfb-summary-count,
	.ggfb-active-filters,
	.ggfb-summary-actions {
		width: 100%;
	}
	.ggfb-active-filters {
		gap: 6px;
	}
	/* Hide active-filters row when empty so it doesn't add gap */
	.ggfb-active-filters:empty {
		display: none;
	}
	.ggfb-summary-actions {
		margin-left: 0;
		margin-top: 0;
		padding-top: 0;
		border-top: 0;
		justify-content: flex-end; /* push Sort to the right edge */
	}
	/* When Clear All is visible, keep it left-aligned, Sort right-aligned */
	.ggfb-summary-actions .ggfb-clear-all {
		margin-right: auto;
	}

	/* Bulletproof mobile option alignment — force consistent left padding
	 * across all groups so radio/check indicators line up between Audience,
	 * Topic, etc. Avoids drift from custom CSS, scrollbar shift, etc. */
	.ggfb-mobile-group,
	.ggfb-mobile-group__label,
	.ggfb-mobile-option {
		padding-left: 18px;
		padding-right: 18px;
		box-sizing: border-box;
	}
	.ggfb-mobile-group {
		padding-left: 0;
		padding-right: 0;
	}
}

/* ---------- AJAX Loop Grid container fallback --------------
 * When AJAX renders cards, ensure they lay out as a grid even
 * if Elementor's compiled CSS hasn't fully kicked in. These
 * styles match Elementor's default Loop Grid behavior.
 * --------------------------------------------------------- */
.ggfb-results .elementor-loop-container.elementor-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 24px;
}
@media (max-width: 1024px) {
	.ggfb-results .elementor-loop-container.elementor-grid {
		grid-template-columns: repeat(2, 1fr);
	}
}
@media (max-width: 640px) {
	.ggfb-results .elementor-loop-container.elementor-grid {
		grid-template-columns: 1fr;
	}
}
.ggfb-results .e-loop-item {
	display: block;
}

/* ============================================================
 * UNIFIED MOBILE FILTER PANEL
 * Hidden on desktop. At ≤1024px takes over: search on top,
 * single dropdown trigger that expands a sheet containing
 * all filter groups (category, audience, topic, etc.) as
 * radio/checkbox lists.
 * ========================================================== */

.ggfb-mobile-panel {
	display: none;
	background: var(--ggfb-paper);
	position: relative;
}

@media (max-width: 1024px) {
	/* Show the unified mobile panel */
	.ggfb-mobile-panel { display: block; }

	/* Hide all the desktop bits */
	.ggfb-tabs-row,
	.ggfb-controls-row {
		display: none;
	}

	/* Hide the total results count on mobile (the "X results" line) */
	.ggfb-summary-count {
		display: none;
	}

	/* Reorder mobile panel: filters dropdown FIRST, search BELOW.
	 * Flex container with order values lets us flip without JS. */
	.ggfb-mobile-panel {
		display: flex;
		flex-direction: column;
	}
	.ggfb-mobile-trigger        { order: 1; }
	.ggfb-mobile-sheet          { order: 2; }
	.ggfb-mobile-panel__search  { order: 3; }
}

/* Search bar (now positioned below filters via flex order on mobile) */
.ggfb-mobile-panel__search {
	padding: 14px 16px;
}
.ggfb-mobile-panel__search .ggfb-search {
	width: 100%;
	min-width: 0;
}

/* Trigger button — collapsed state. No margin-top now that search sits below. */
.ggfb-mobile-trigger {
	width: 100%;
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 14px 18px;
	background: var(--ggfb-paper);
	border: 0;
	border-top: 1px solid var(--ggfb-rule);
	border-bottom: 1px solid var(--ggfb-rule);
	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 14px;
	font-weight: 700;
	letter-spacing: 1.2px;
	text-transform: uppercase;
	color: var(--ggfb-ink);
	cursor: pointer;
	text-align: left;
	transition: background 0.15s ease;
}
.ggfb-mobile-trigger:hover {
	background: var(--ggfb-rule-soft);
}
.ggfb-mobile-trigger__label {
	flex: 1;
}
.ggfb-mobile-trigger__count {
	background: var(--ggfb-ink);
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.3px;
	text-transform: none;
	padding: 2px 9px;
	border-radius: 100px;
	min-width: 22px;
	text-align: center;
}
.ggfb-mobile-trigger__chevron {
	width: 16px;
	height: 16px;
	color: var(--ggfb-text-muted);
	flex-shrink: 0;
	transition: transform 0.2s ease;
}
.ggfb-mobile-panel.is-open .ggfb-mobile-trigger__chevron {
	transform: rotate(180deg);
}
.ggfb-mobile-panel.is-open .ggfb-mobile-trigger {
	background: var(--ggfb-rule-soft);
}

/* Sheet — the expandable panel containing all groups */
.ggfb-mobile-sheet {
	background: var(--ggfb-paper);
	border-bottom: 1px solid var(--ggfb-rule);
	display: flex;
	flex-direction: column;
	max-height: 70vh;
}
.ggfb-mobile-sheet[hidden] {
	display: none;
}
.ggfb-mobile-sheet__body {
	flex: 1;
	overflow-y: auto;
	padding: 8px 0;
	-webkit-overflow-scrolling: touch;
}

/* Each group inside the sheet (Category, Audience, Topic) */
.ggfb-mobile-group {
	padding: 8px 0;
}
.ggfb-mobile-group + .ggfb-mobile-group {
	border-top: 1px solid var(--ggfb-rule-soft);
}
.ggfb-mobile-group__label {
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	color: var(--ggfb-text-soft);
	padding: 12px 18px 8px;
}

/* Each option (radio or checkbox row) */
.ggfb-mobile-option {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 18px;
	cursor: pointer;
	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 15px;
	font-weight: 500;
	color: var(--ggfb-text-muted);
	transition: background 0.1s ease;
}
.ggfb-mobile-option:hover {
	background: var(--ggfb-rule-soft);
}
.ggfb-mobile-option.is-disabled {
	color: var(--ggfb-hint);
	cursor: not-allowed;
	opacity: 0.5;
	pointer-events: none;
}
.ggfb-mobile-option.is-disabled:hover {
	background: transparent;
}
/* Mobile-only "hide" — when the active category has no posts with this
 * audience/topic term, hide the option entirely. Different UX from desktop
 * (which greys out to preserve layout); on mobile the panel is meant to
 * surface only what's actually selectable. */
.ggfb-mobile-option.is-mobile-hidden {
	display: none !important;
}
/* Empty-state line shown when ALL options in a group are hidden.
 * Pre-rendered in HTML with [hidden] attribute; JS removes that
 * attribute when needed. */
.ggfb-mobile-group__empty {
	padding: 14px 18px;
	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 13px;
	line-height: 1.5;
	color: var(--ggfb-text-soft);
	font-style: italic;
}
.ggfb-mobile-group__empty[hidden] {
	display: none !important;
}

/* See More / See Less button for mobile groups with 10+ options.
 * Overflow items (index 10+) are hidden by default and revealed when
 * the group has .is-expanded. */
.ggfb-mobile-option.is-overflow {
	display: none !important;
}
.ggfb-mobile-group.is-expanded .ggfb-mobile-option.is-overflow:not(.is-mobile-hidden) {
	display: flex !important;
}
.ggfb-mobile-group__see-more {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	width: calc(100% - 36px);
	margin: 8px 18px;
	padding: 12px 14px;
	background: transparent;
	border: 1px dashed var(--ggfb-rule);
	border-radius: 100px;
	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.3px;
	color: var(--ggfb-text-muted);
	cursor: pointer;
	transition: background 0.12s, border-color 0.12s, color 0.12s;
}
/* The [hidden] attribute must trump the display:flex rule above —
 * without this, jQuery's .prop('hidden', true) sets the attribute
 * but the button stays visible. */
.ggfb-mobile-group__see-more[hidden] {
	display: none !important;
}
.ggfb-mobile-group__see-more:hover,
.ggfb-mobile-group__see-more:focus-visible {
	background: var(--ggfb-rule-soft);
	border-color: var(--ggfb-text-muted);
	color: var(--ggfb-ink);
	outline: none;
}
.ggfb-mobile-group__see-more-count {
	color: var(--ggfb-text-soft);
	font-weight: 500;
}
/* Hide See More button when the group's empty-state placeholder is showing
 * (no point in "See more" when there's nothing to see). */
.ggfb-mobile-group.is-all-hidden .ggfb-mobile-group__see-more {
	display: none !important;
}
.ggfb-mobile-option input,
.ggfb-mobile-option input[type="radio"],
.ggfb-mobile-option input[type="checkbox"] {
	position: absolute !important;
	opacity: 0 !important;
	pointer-events: none !important;
	width: 0 !important;
	height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
}

/* Custom check/radio indicator */
.ggfb-mobile-option__check {
	width: 20px;
	height: 20px;
	border: 1.5px solid var(--ggfb-rule);
	background: var(--ggfb-paper);
	flex-shrink: 0;
	transition: all 0.12s ease;
	position: relative;
	border-radius: 50%; /* always circle, regardless of input type */
	box-sizing: border-box;
	display: inline-block;
	vertical-align: middle;
}
/* Override per-input-type rules — keep both as circles */
.ggfb-mobile-option input[type="radio"] + .ggfb-mobile-option__check,
.ggfb-mobile-option input[type="checkbox"] + .ggfb-mobile-option__check {
	border-radius: 50%;
}
/* Checked state — both types fill with ink color */
.ggfb-mobile-option input:checked + .ggfb-mobile-option__check {
	border-color: var(--ggfb-ink);
	background: var(--ggfb-ink);
}
/* Both radio AND checkbox use the same inner-dot when selected */
.ggfb-mobile-option input[type="radio"]:checked + .ggfb-mobile-option__check::after,
.ggfb-mobile-option input[type="checkbox"]:checked + .ggfb-mobile-option__check::after {
	content: '';
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: #fff;
	border: 0;
}

.ggfb-mobile-option:has(input:checked) {
	color: var(--ggfb-ink);
	font-weight: 600;
}

.ggfb-mobile-option__label {
	flex: 1;
}
.ggfb-mobile-option__count {
	font-size: 12px;
	font-weight: 500;
	color: var(--ggfb-hint);
	letter-spacing: 0.3px;
}
.ggfb-mobile-option:has(input:checked) .ggfb-mobile-option__count {
	color: var(--ggfb-text-muted);
}

/* Footer with Clear All + Done buttons */
.ggfb-mobile-sheet__footer {
	display: flex;
	gap: 12px;
	padding: 14px 18px;
	border-top: 1px solid var(--ggfb-rule);
	background: var(--ggfb-paper);
}
.ggfb-mobile-clear,
.ggfb-mobile-done {
	flex: 1;
	padding: 12px 18px;
	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 1.2px;
	text-transform: uppercase;
	cursor: pointer;
	border-radius: 100px;
	transition: all 0.15s ease;
}
.ggfb-mobile-clear {
	background: transparent;
	border: 1px solid var(--ggfb-rule);
	color: var(--ggfb-text-muted);
}
.ggfb-mobile-clear:hover {
	border-color: var(--ggfb-ink);
	color: var(--ggfb-ink);
}
.ggfb-mobile-done {
	background: var(--ggfb-ink);
	border: 1px solid var(--ggfb-ink);
	color: #fff;
}
.ggfb-mobile-done:hover {
	opacity: 0.9;
}

/* Hide initial pagination until JS moves it into the results container.
 * JS removes this class once the move is complete (FOUC prevention). */
.ggfb-pagination--pre-init { visibility: hidden; }
