/* App shell: tokens, header, tabbar, pickers, modals — all routes except login */

:root {
	--fighoo-header-pad-block: 10px;
	--fighoo-header-pill-min-h: 60px;
	--glass-header-h: calc(
		var(--fighoo-header-pad-block) * 2 + var(--fighoo-header-pill-min-h)
	);
	--fighoo-shell-header-clearance: calc(
		var(--glass-header-h) + env(safe-area-inset-top, 0px)
	);
	/* channel-glass-bottom: 12px + 48px row + 12px (safe-area on toolbar, not here). */
	--fighoo-channel-bottom-toolbar-h: 72px;
	--glass-channel-bottom-h: var(--fighoo-channel-bottom-toolbar-h);
	--fighoo-channel-feed-chrome-gap-top: 10px;
	--fighoo-channel-feed-chrome-gap-bottom: 4px;
	--channel-scroll-fab-size: 40px;
	/* Fixed tab bar footprint: outer pad + pill pad + tab item block (icon + label). */
	--fighoo-tabbar-outer-pad: 10px;
	--fighoo-tabbar-pill-pad-block: 8px;
	--fighoo-tabbar-item-block: 52px;
	--fighoo-tabbar-side-margin: 4px;
	--fighoo-tabbar-slot-pad-inline: 4px;
	--fighoo-tabbar-track-max-w: min(calc(100vw - (var(--fighoo-tabbar-side-margin) * 2)), 520px);
	--fighoo-tabbar-inner-gap: 6px;
	--fighoo-tabbar-item-pad-inline: 7px;
	--glass-tabbar-h: calc(
		var(--fighoo-tabbar-outer-pad) * 2 + var(--fighoo-tabbar-pill-pad-block) * 2 +
			var(--fighoo-tabbar-item-block)
	);
	--fighoo-tabbar-scroll-clearance: calc(
		var(--glass-tabbar-h) + env(safe-area-inset-bottom, 0px) + 12px
	);
	--fighoo-tabbar-indicator-dur: 0.34s;
	--fighoo-tabbar-indicator-dur-back: 0.38s;
	--fighoo-tabbar-indicator-ease: cubic-bezier(0.33, 1, 0.68, 1);
	--fighoo-chat-compose-h: 60px;
	--fighoo-chat-compose-pad: 60px;
	--fighoo-chat-thread-head-h: var(--glass-header-h);
	--color-bg: #e8eef5;
	--color-text: #1a1d21;
	--color-accent: #c62828;
	--color-primary: #c62828;
	--color-danger: #c62828;
	--fighoo-tabbar-pill-bg: rgba(254, 242, 242, 0.92);
	--fighoo-tabbar-pill-border: rgba(198, 40, 40, 0.28);
	--fighoo-tabbar-active-bg: rgba(198, 40, 40, 0.18);
	--font: "Vazirmatn", "Tahoma", system-ui, sans-serif;
	--fighoo-shell-max-w: 440px;
}

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	overscroll-behavior-y: none;
	touch-action: manipulation;
}

body.fighoo-theme {
	margin: 0;
	min-height: 100vh;
	font-family: var(--font);
	background: var(--color-bg);
	color: var(--color-text);
	direction: rtl;
	overscroll-behavior-y: none;
	touch-action: manipulation;
	-webkit-user-select: none;
	user-select: none;
	-webkit-touch-callout: none;
}

body.fighoo-theme :where(input, textarea, select, [contenteditable="true"]) {
	-webkit-user-select: text;
	user-select: text;
	-webkit-touch-callout: default;
}

/* —— Global press feedback (unified) —— */
body.fighoo-theme button:not(:disabled):not(.fighoo-no-press):not(.category-picker__item),
body.fighoo-theme a[href]:not(.fighoo-no-press),
body.fighoo-theme [role="button"]:not([aria-disabled="true"]):not(.fighoo-no-press),
body.fighoo-theme .glass-tabbar__item,
body.fighoo-theme .glass-btn,
body.fighoo-theme .tg-post__btn,
body.fighoo-theme .home-cat-card:not(.is-locked) {
	transition: transform 150ms ease, opacity 150ms ease, box-shadow 150ms ease;
	-webkit-tap-highlight-color: transparent;
}

body.fighoo-theme button:not(:disabled):not(.fighoo-no-press):not(.category-picker__item):active,
body.fighoo-theme button:not(:disabled):not(.fighoo-no-press):not(.category-picker__item).is-pressed,
body.fighoo-theme a[href]:not(.fighoo-no-press):not(.fighoo-chat-list__link):active,
body.fighoo-theme a[href]:not(.fighoo-no-press):not(.fighoo-chat-list__link).is-pressed,
body.fighoo-theme [role="button"]:not([aria-disabled="true"]):not(.fighoo-no-press):active,
body.fighoo-theme [role="button"]:not([aria-disabled="true"]):not(.fighoo-no-press).is-pressed,
body.fighoo-theme .glass-tabbar__item:active,
body.fighoo-theme .glass-tabbar__item.is-pressed,
body.fighoo-theme .glass-btn:active,
body.fighoo-theme .glass-btn.is-pressed,
body.fighoo-theme .tg-post__btn:active,
body.fighoo-theme .tg-post__btn.is-pressed,
body.fighoo-theme .home-cat-card:not(.is-locked):active,
body.fighoo-theme .home-cat-card:not(.is-locked).is-pressed {
	transform: scale(0.96);
	opacity: 0.92;
	box-shadow: 0 0 0 3px rgba(198, 40, 40, 0.25);
	transition: transform 150ms ease, opacity 150ms ease, box-shadow 150ms ease;
}

/* Fixed glass header bar (same vertical rhythm as home-topbar) */
.glass-header {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 1000;
	padding: calc(var(--fighoo-header-pad-block) + env(safe-area-inset-top, 0px)) 0
		var(--fighoo-header-pad-block);
	pointer-events: none;
}

/* Same horizontal track as .site-main--home (max width + 16px side padding) */
.glass-header__slot {
	width: 100%;
	max-width: var(--fighoo-shell-max-w);
	margin: 0 auto;
	padding-left: 16px;
	padding-right: 16px;
	box-sizing: border-box;
	pointer-events: auto;
}

/* Elliptical glass pill */
.glass-header__pill,
.glass-header__pill--home {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	min-height: var(--fighoo-header-pill-min-h);
	box-sizing: border-box;
	border-radius: 9999px;
	padding: 8px 10px 8px 12px;
	background: rgba(255, 255, 255, 0.42);
	border: 1px solid rgba(255, 255, 255, 0.65);
	box-shadow:
		0 4px 24px rgba(15, 23, 42, 0.08),
		inset 0 1px 0 rgba(255, 255, 255, 0.75);
	-webkit-backdrop-filter: blur(18px) saturate(1.35);
	backdrop-filter: blur(18px) saturate(1.35);
}

.glass-header__brand {
	display: flex;
	align-items: center;
	flex: 1;
	min-width: 0;
	gap: 10px;
	text-decoration: none;
	color: inherit;
	min-height: 44px;
}

.glass-header__logo {
	flex-shrink: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	overflow: hidden;
	background: #fff;
	border: 1px solid rgba(15, 23, 42, 0.06);
	box-shadow: 0 1px 4px rgba(15, 23, 42, 0.06);
}

.glass-header__logo--placeholder {
	background: linear-gradient(135deg, rgba(198, 40, 40, 0.28), rgba(255, 255, 255, 0.5));
}

.glass-header__logo-img {
	display: block;
	width: 100%;
	height: 100%;
	padding: 5px;
	box-sizing: border-box;
	object-fit: contain;
	object-position: center;
}

.glass-header__title-wrap {
	flex: 1;
	min-width: 0;
	display: flex;
	align-items: center;
	justify-content: flex-start;
	gap: 8px;
}

.glass-header__tagline {
	flex: 0 1 auto;
	min-width: 0;
	text-align: start;
	font-size: 0.86rem;
	font-weight: 600;
	line-height: 1.45;
	letter-spacing: -0.01em;
	color: rgba(26, 29, 33, 0.92);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.glass-header__my-ads-submit {
	flex-shrink: 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	max-width: 54%;
	min-height: 40px;
	padding: 8px 12px 8px 10px;
	border-radius: 9999px;
	text-decoration: none;
	font-weight: 700;
	font-size: 0.68rem;
	line-height: 1.25;
	color: rgba(26, 29, 33, 0.92);
	background: rgba(255, 255, 255, 0.58);
	border: 1px solid rgba(255, 255, 255, 0.78);
	box-shadow:
		0 2px 10px rgba(15, 23, 42, 0.06),
		inset 0 1px 0 rgba(255, 255, 255, 0.85);
	-webkit-backdrop-filter: blur(12px) saturate(1.2);
	backdrop-filter: blur(12px) saturate(1.2);
	transition: background 0.15s ease, transform 0.15s ease;
}

.glass-header__my-ads-submit:hover {
	background: rgba(255, 255, 255, 0.72);
}

.glass-header__my-ads-submit-icon {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	width: 1.35rem;
	height: 1.35rem;
	border-radius: 50%;
	font-size: 1.05rem;
	font-weight: 700;
	line-height: 1;
	color: #fff;
	background: var(--color-primary, #c62828);
}

.glass-header__my-ads-submit-label {
	min-width: 0;
	text-align: center;
}

button.glass-header__my-ads-submit {
	margin: 0;
	font: inherit;
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
}

/* Header CTAs: ثبت آگهی جدید — red glass pill */
body.fighoo-view-my-ads a.glass-header__my-ads-submit {
	flex-shrink: 0;
	min-height: 48px;
	padding: 10px 16px;
	max-width: none;
	border-radius: 9999px;
	font-size: 0.78rem;
	line-height: 1.3;
	color: #fff;
	background: linear-gradient(
		180deg,
		rgba(229, 57, 53, 0.92) 0%,
		rgba(198, 40, 40, 0.88) 100%
	);
	border: 1px solid rgba(183, 28, 28, 0.65);
	box-shadow:
		0 3px 14px rgba(198, 40, 40, 0.28),
		inset 0 1px 0 rgba(255, 255, 255, 0.35);
	-webkit-backdrop-filter: blur(12px) saturate(1.2);
	backdrop-filter: blur(12px) saturate(1.2);
}

body.fighoo-view-my-ads a.glass-header__my-ads-submit:hover {
	background: linear-gradient(
		180deg,
		rgba(239, 83, 80, 0.95) 0%,
		rgba(211, 47, 47, 0.92) 100%
	);
}

body.fighoo-view-my-ads a.glass-header__my-ads-submit .glass-header__my-ads-submit-label {
	font-weight: 800;
	letter-spacing: -0.02em;
}

body.fighoo-view-my-ads .glass-header__pill--my-ads,
body.fighoo-view-my-channels-tab .glass-header__pill--my-ads,
body.fighoo-view-my-branches .glass-header__pill--my-ads {
	padding: 8px 10px 8px 12px;
	gap: 8px;
	align-items: center;
}

.glass-header__wallet {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 5px;
	flex: 0 0 auto;
	min-height: 36px;
	padding: 0 10px 0 8px;
	margin-inline-start: auto;
	border-radius: 9999px;
	border: 1px solid rgba(22, 101, 52, 0.2);
	background: rgba(255, 255, 255, 0.78);
	color: #14532d;
	box-shadow: 0 2px 10px rgba(15, 23, 42, 0.06);
	cursor: pointer;
	-webkit-tap-highlight-color: transparent;
}

.glass-header__wallet-icon {
	display: flex;
	line-height: 0;
}

.glass-header__wallet-icon svg {
	width: 20px;
	height: 20px;
}

.glass-header__wallet-balance {
	font-size: 0.68rem;
	font-weight: 700;
	white-space: nowrap;
	max-width: 5rem;
	overflow: hidden;
	text-overflow: ellipsis;
}

body.fighoo-view-my-channels-tab .glass-header__brand,
body.fighoo-view-my-branches .glass-header__brand {
	flex: 0 0 auto;
	min-width: 0;
}

body.fighoo-view-my-channels-tab .glass-header__pill--my-ads,
body.fighoo-view-my-branches .glass-header__pill--my-ads {
	gap: 8px;
}

body.fighoo-view-my-ads .glass-header__brand {
	flex: 0 1 auto;
	min-width: 0;
}

body.fighoo-view-my-ads .glass-header__title-wrap {
	flex: 0 1 auto;
	min-width: 0;
}

body.fighoo-view-my-ads .glass-header__tagline {
	flex: 0 0 auto;
	max-width: none;
	overflow: visible;
	text-overflow: clip;
	white-space: nowrap;
	font-size: 0.84rem;
	font-weight: 700;
}

.site-main {
	padding-top: var(--fighoo-shell-header-clearance);
	padding-bottom: calc(var(--fighoo-tabbar-scroll-clearance) + 4px);
	min-height: 100vh;
	max-width: var(--fighoo-shell-max-w);
	margin: 0 auto;
	padding-left: 16px;
	padding-right: 16px;
	box-sizing: border-box;
}

/* Reserve header lane — never scroll body under fixed glass-header */
body.fighoo-theme:not(.fighoo-view-home):not(.fighoo-view-ad-channel):not(.fighoo-view-chat-thread):not(
		.fighoo-view-login
	)
	.site-main:not(.site-main--home):not(.site-main--channel):not(.site-main--login) {
	padding-top: var(--fighoo-shell-header-clearance);
}


.page-shell--guide {
	padding-top: calc(10px + env(safe-area-inset-top, 0px));
	padding-bottom: calc(var(--fighoo-tabbar-scroll-clearance) + 4px);
}

body.fighoo-theme:has(.glass-tabbar) .fighoo-chat-list__item:last-child .fighoo-chat-list__link {
	scroll-margin-bottom: var(--fighoo-tabbar-scroll-clearance);
}

.fighoo-seo-guide__cta {
	margin: 20px 0 0;
	text-align: center;
}

.fighoo-seo-guide__cta .glass-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 12px 20px;
	border-radius: 9999px;
	text-decoration: none;
	font-weight: 700;
	font-size: 0.88rem;
	color: #fff;
	background: var(--color-primary);
	border: none;
	box-shadow: 0 4px 16px rgba(198, 40, 40, 0.25);
}

.home-location__trigger {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 7px;
	width: auto;
	max-width: 100%;
	border: none;
	background: transparent;
	box-shadow: none;
	-webkit-backdrop-filter: none;
	backdrop-filter: none;
	font: inherit;
	font-size: 0.96rem;
	line-height: 1.35;
	cursor: pointer;
	padding: 8px 4px;
	border-radius: 0;
	color: #2b3138;
	transition: opacity 0.15s ease;
}

.home-location__trigger:hover {
	opacity: 0.82;
}

.home-location__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	width: auto;
	height: auto;
	margin-inline-end: 1px;
	color: #5f6773;
	background: transparent;
	border: none;
	box-shadow: none;
}

.home-location__icon svg {
	display: block;
	width: 1.125em;
	height: 1.125em;
	stroke: currentColor;
}

.home-location__content {
	display: flex;
	flex-direction: row;
	align-items: center;
	justify-content: center;
	flex-wrap: wrap;
	gap: 5px;
	flex: 0 1 auto;
	min-width: 0;
	text-align: center;
}

.home-location__label {
	font-size: inherit;
	font-weight: 700;
	color: #1f2937;
	line-height: inherit;
	flex-shrink: 0;
}

.home-location__city {
	font-size: inherit;
	font-weight: 700;
	color: var(--color-primary, #c62828);
	line-height: inherit;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	min-width: 0;
	flex: 0 1 auto;
	max-width: min(70vw, 280px);
}

.fighoo-toast {
	position: fixed;
	z-index: 1200;
	left: 16px;
	right: 16px;
	bottom: calc(var(--fighoo-tabbar-scroll-clearance) + 4px);
	max-width: 480px;
	margin: 0 auto;
	padding: 10px 14px;
	border-radius: 12px;
	font-size: 0.82rem;
	font-weight: 600;
	text-align: center;
	color: #111827;
	background: rgba(255, 255, 255, 0.95);
	border: 1px solid rgba(15, 23, 42, 0.08);
	box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
}

.fighoo-toast[hidden] {
	display: none !important;
}

/* PWA install banner — top of home (mobile browser, not standalone). */
.fighoo-pwa-install-prompt-root:not([hidden]) {
	display: block;
}

.fighoo-pwa-install-prompt {
	position: fixed;
	z-index: 1205;
	top: calc(env(safe-area-inset-top, 0px) + 8px);
	bottom: auto;
	left: 6px;
	right: 6px;
	max-width: min(520px, calc(100vw - 12px));
	margin: 0 auto;
	padding: 14px 16px;
	border-radius: 16px;
	border: 1px solid rgba(255, 255, 255, 0.78);
	background: rgba(255, 255, 255, 0.98);
	box-shadow:
		0 8px 32px rgba(15, 23, 42, 0.14),
		inset 0 1px 0 rgba(255, 255, 255, 0.92);
	-webkit-backdrop-filter: blur(18px) saturate(1.3);
	backdrop-filter: blur(18px) saturate(1.3);
	pointer-events: auto;
}

.fighoo-pwa-install-prompt__inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px 14px;
}

.fighoo-pwa-install-prompt__title {
	margin: 0;
	flex: 1 1 10rem;
	min-width: 0;
	font-size: 1rem;
	font-weight: 800;
	line-height: 1.35;
	color: var(--color-primary, #c62828);
}

.fighoo-pwa-install-prompt__actions {
	display: flex;
	flex-wrap: nowrap;
	gap: 8px;
	align-items: center;
	flex-shrink: 0;
}

.fighoo-pwa-install-prompt__install {
	font: inherit;
	font-size: 0.92rem;
	font-weight: 800;
	padding: 10px 18px;
	border: none;
	border-radius: 999px;
	background: var(--color-primary, #c62828);
	color: #fff;
	cursor: pointer;
	min-height: 44px;
}

.fighoo-pwa-install-prompt__install:disabled {
	opacity: 0.55;
	cursor: wait;
}

.fighoo-pwa-install-prompt__dismiss {
	font: inherit;
	font-size: 0.88rem;
	font-weight: 700;
	padding: 10px 14px;
	border: none;
	border-radius: 999px;
	background: rgba(15, 23, 42, 0.06);
	color: rgba(15, 23, 42, 0.62);
	cursor: pointer;
	min-height: 44px;
}

body.fighoo-pwa-install-prompt-visible .site-main {
	padding-top: var(--fighoo-pwa-install-prompt-h, 64px);
	box-sizing: border-box;
}

body.fighoo-pwa-install-prompt-visible.fighoo-view-home .site-main--home {
	padding-top: var(--fighoo-pwa-install-prompt-h, 64px);
	box-sizing: border-box;
}

.fighoo-pwa-ios-add-sheet {
	position: fixed;
	inset: 0;
	z-index: 1210;
	display: flex;
	align-items: flex-start;
	justify-content: center;
	padding: calc(env(safe-area-inset-top, 0px) + 72px) 16px 16px;
	background: rgba(15, 23, 42, 0.35);
}

.fighoo-pwa-ios-add-sheet__panel {
	width: min(100%, 400px);
	padding: 18px 16px;
	border-radius: 16px;
	background: #fff;
	box-shadow: 0 12px 40px rgba(15, 23, 42, 0.2);
	text-align: center;
}

.fighoo-pwa-ios-add-sheet__title {
	margin: 0 0 8px;
	font-size: 1.05rem;
	font-weight: 800;
	color: var(--color-primary, #c62828);
}

.fighoo-pwa-ios-add-sheet__hint {
	margin: 0 0 14px;
	font-size: 0.95rem;
	font-weight: 700;
	color: rgba(15, 23, 42, 0.78);
}

.fighoo-pwa-ios-add-sheet__close {
	font: inherit;
	font-size: 0.9rem;
	font-weight: 700;
	padding: 10px 20px;
	border: none;
	border-radius: 999px;
	background: rgba(15, 23, 42, 0.08);
	color: rgba(15, 23, 42, 0.7);
	cursor: pointer;
}


.category-picker__search-wrap {
	padding: 0 14px 10px;
	flex-shrink: 0;
}

.category-picker__search {
	display: block;
	width: 100%;
	box-sizing: border-box;
	padding: 10px 14px;
	border-radius: 12px;
	border: 1px solid rgba(15, 23, 42, 0.12);
	background: rgba(255, 255, 255, 0.92);
	font-family: inherit;
	font-size: 0.98rem;
	color: #1a1d21;
	-webkit-user-select: text;
	user-select: text;
}

.category-picker__search:focus {
	outline: none;
	border-color: rgba(198, 40, 40, 0.55);
	box-shadow: 0 0 0 3px rgba(198, 40, 40, 0.15);
}

.category-picker__search::placeholder {
	color: rgba(55, 65, 81, 0.55);
}

.category-picker__body {
	padding-top: 0;
	flex: 1 1 auto;
	min-height: 0;
	overflow-x: hidden;
	overflow-y: auto;
	-webkit-overflow-scrolling: touch;
}

.category-picker__breadcrumb {
	margin: 0;
	padding: 0 16px 8px;
	font-size: 0.86rem;
	color: rgba(26, 29, 33, 0.55);
	line-height: 1.45;
}

.category-picker__list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.category-picker__status {
	padding: 24px 16px;
	text-align: center;
	font-size: 1rem;
	color: rgba(26, 29, 33, 0.55);
}

.category-picker__item {
	width: 100%;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 15px 16px;
	border: none;
	border-bottom: 1px solid rgba(0, 0, 0, 0.06);
	background: transparent;
	font: inherit;
	font-size: 1.02rem;
	font-weight: 600;
	text-align: right;
	color: #000;
	cursor: pointer;
}

.category-picker__item-main {
	display: flex;
	align-items: center;
	gap: 7px;
	flex: 1;
	min-width: 0;
}

.category-picker__icon {
	display: inline-flex;
	flex-shrink: 0;
	width: 32px;
	height: 32px;
	color: rgba(26, 29, 33, 0.62);
}

.category-picker__icon svg {
	width: 100%;
	height: 100%;
}

.category-picker__item-label {
	flex: 1;
	min-width: 0;
	font-size: inherit;
	line-height: 1.5;
}

.category-picker__item.has-children::after {
	content: "›";
	color: rgba(26, 29, 33, 0.45);
	font-size: 1.25rem;
	flex-shrink: 0;
}

.category-picker__item:focus {
	outline: none;
}

.category-picker__item:focus-visible {
	outline: 2px solid var(--color-accent);
	outline-offset: -2px;
}

.fighoo-modal__panel--tall {
	max-height: min(78vh, calc(100vh - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px) - 24px));
	max-height: min(78dvh, calc(100dvh - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px) - 24px));
	min-height: 0;
	justify-content: flex-start;
}

#modal-category-picker .fighoo-modal__panel--tall,
#modal-location .fighoo-modal__panel--tall {
	display: flex;
	flex-direction: column;
}

#modal-category-picker .fighoo-modal__body,
#modal-location .fighoo-modal__body {
	flex: 1 1 auto;
	min-height: 0;
	padding-top: 0;
}

.fighoo-modal__back {
	border: none;
	background: rgba(15, 23, 42, 0.06);
	font-size: 1.4rem;
	line-height: 1;
	padding: 0;
	cursor: pointer;
	color: inherit;
	flex-shrink: 0;
	width: 40px;
	height: 40px;
	border-radius: 12px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
}

.fighoo-modal__back[hidden] {
	display: inline-flex;
	visibility: hidden;
	pointer-events: none;
}

.fighoo-back-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 1.25rem;
	height: 1.25rem;
	flex-shrink: 0;
	color: inherit;
}

.fighoo-back-icon svg {
	display: block;
	width: 100%;
	height: 100%;
	stroke: currentColor;
}

.glass-btn {
	width: 100%;
	padding: 16px 20px;
	border: 1px solid rgba(255, 255, 255, 0.65);
	border-radius: 9999px;
	background: rgba(255, 255, 255, 0.42);
	box-shadow:
		0 4px 24px rgba(15, 23, 42, 0.08),
		inset 0 1px 0 rgba(255, 255, 255, 0.75);
	-webkit-backdrop-filter: blur(18px) saturate(1.35);
	backdrop-filter: blur(18px) saturate(1.35);
	font: inherit;
	font-size: 1rem;
	font-weight: 600;
	color: #000000;
	cursor: pointer;
	-webkit-tap-highlight-color: transparent;
	transition: background 0.15s ease, transform 0.1s ease;
}

.glass-btn:focus {
	outline: none;
}

.glass-btn:focus-visible {
	outline: 2px solid var(--color-accent);
	outline-offset: 3px;
}

.glass-btn--green {
	color: #064e3b;
	border-color: rgba(167, 243, 208, 0.8);
	background: rgba(52, 211, 153, 0.4);
	box-shadow:
		0 4px 24px rgba(16, 185, 129, 0.2),
		inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.glass-btn--green:focus-visible {
	outline-color: #10b981;
}

.glass-btn--green:disabled {
	opacity: 0.55;
	cursor: not-allowed;
}

.fighoo-modal[hidden] {
	display: none !important;
}

.fighoo-modal {
	position: fixed;
	inset: 0;
	z-index: 1200;
	display: flex;
	align-items: flex-end;
	justify-content: center;
	padding:
		max(12px, env(safe-area-inset-top, 0px))
		16px
		max(12px, env(safe-area-inset-bottom, 0px));
}

.fighoo-modal__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(15, 23, 42, 0.35);
}

@keyframes fighoo-picker-sheet-up {
	from {
		transform: translate3d(0, 100%, 0);
		opacity: 0.88;
	}

	to {
		transform: translate3d(0, 0, 0);
		opacity: 1;
	}
}

@keyframes fighoo-picker-backdrop-in {
	from {
		opacity: 0;
	}

	to {
		opacity: 1;
	}
}

@keyframes fighoo-picker-list-rise {
	from {
		transform: translate3d(0, 22px, 0);
		opacity: 0;
	}

	to {
		transform: translate3d(0, 0, 0);
		opacity: 1;
	}
}

#modal-location:not([hidden]) .fighoo-modal__panel,
#modal-category-picker:not([hidden]) .fighoo-modal__panel,
#modal-channel-sort:not([hidden]) .fighoo-modal__panel,
#modal-ad-report:not([hidden]) .fighoo-modal__panel,
#modal-ad-forward:not([hidden]) .fighoo-modal__panel {
	animation: fighoo-picker-sheet-up 0.42s cubic-bezier(0.22, 1, 0.36, 1) both;
	will-change: transform;
}

#modal-location:not([hidden]) .fighoo-modal__backdrop,
#modal-category-picker:not([hidden]) .fighoo-modal__backdrop,
#modal-channel-sort:not([hidden]) .fighoo-modal__backdrop,
#modal-ad-report:not([hidden]) .fighoo-modal__backdrop,
#modal-ad-forward:not([hidden]) .fighoo-modal__backdrop {
	animation: fighoo-picker-backdrop-in 0.34s ease both;
}

.category-picker__body.category-picker__body--slide-in .category-picker__list {
	animation: fighoo-picker-list-rise 0.36s cubic-bezier(0.22, 1, 0.36, 1) both;
	transform: none;
}

.category-picker__item:active {
	background: rgba(15, 23, 42, 0.06);
	opacity: 1;
	transform: none;
	box-shadow: none;
}

@media (prefers-reduced-motion: reduce) {
	#modal-location:not([hidden]) .fighoo-modal__panel,
	#modal-category-picker:not([hidden]) .fighoo-modal__panel,
	#modal-channel-sort:not([hidden]) .fighoo-modal__panel,
	#modal-ad-report:not([hidden]) .fighoo-modal__panel,
	#modal-ad-forward:not([hidden]) .fighoo-modal__panel,
	#modal-location:not([hidden]) .fighoo-modal__backdrop,
	#modal-category-picker:not([hidden]) .fighoo-modal__backdrop,
	#modal-channel-sort:not([hidden]) .fighoo-modal__backdrop,
	#modal-ad-report:not([hidden]) .fighoo-modal__backdrop,
	#modal-ad-forward:not([hidden]) .fighoo-modal__backdrop,
	.category-picker__body.category-picker__body--slide-in .category-picker__list {
		animation: none;
	}
}

.fighoo-modal__panel {
	position: relative;
	z-index: 1;
	width: 100%;
	max-width: 400px;
	max-height: min(70vh, calc(100vh - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px) - 24px));
	max-height: min(70dvh, calc(100dvh - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px) - 24px));
	background: rgba(255, 255, 255, 0.92);
	border-radius: 20px;
	border: 1px solid rgba(255, 255, 255, 0.8);
	box-shadow: 0 12px 40px rgba(15, 23, 42, 0.15);
	-webkit-backdrop-filter: blur(20px);
	backdrop-filter: blur(20px);
	display: flex;
	flex-direction: column;
}

.fighoo-modal__header {
	display: grid;
	grid-template-columns: 40px 1fr 40px;
	align-items: center;
	gap: 8px;
	padding: 12px 14px;
	border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.fighoo-modal__header h2 {
	margin: 0;
	font-size: 0.95rem;
	font-weight: 700;
	grid-column: 2;
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	text-align: center;
}

.fighoo-modal__back {
	grid-column: 1;
	grid-row: 1;
}

.fighoo-modal__close {
	grid-column: 3;
	grid-row: 1;
	position: relative;
	z-index: 2;
	border: none;
	background: rgba(15, 23, 42, 0.06);
	cursor: pointer;
	padding: 0;
	color: inherit;
	width: 40px;
	height: 40px;
	border-radius: 12px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	pointer-events: auto;
	-webkit-tap-highlight-color: transparent;
}

.fighoo-modal__close-glyph {
	position: relative;
	display: block;
	width: 16px;
	height: 16px;
}

.fighoo-modal__close-glyph::before,
.fighoo-modal__close-glyph::after {
	content: "";
	position: absolute;
	left: 50%;
	top: 50%;
	width: 14px;
	height: 2px;
	margin-top: -1px;
	margin-left: -7px;
	border-radius: 1px;
	background: #374151;
}

.fighoo-modal__close-glyph::before {
	transform: rotate(45deg);
}

.fighoo-modal__close-glyph::after {
	transform: rotate(-45deg);
}

.fighoo-modal__body {
	padding: 16px;
	overflow: auto;
}

.fighoo-modal__hint {
	margin: 0;
	color: rgba(26, 29, 33, 0.6);
	font-size: 0.9rem;
}

body.fighoo-modal-open {
	overflow: hidden;
}

/* Tab swipe transform breaks position:fixed pickers inside the stage — reset while modal open */
body.fighoo-modal-open .fighoo-tab-stage {
	transform: none !important;
	transition: none !important;
}

body.fighoo-modal-open .fighoo-tab-stage.fighoo-tab-swipe-host {
	will-change: auto;
}

/* Home pickers live outside #fighoo-tab-stage (footer) — own stacking layer */
.fighoo-home-modals {
	position: fixed;
	inset: 0;
	z-index: 1250;
	pointer-events: none;
}

.fighoo-home-modals .fighoo-modal:not([hidden]) {
	pointer-events: auto;
}

body.fighoo-modal-open #modal-category-picker,
body.fighoo-modal-open #modal-location,
.fighoo-home-modals .fighoo-modal:not([hidden]) {
	z-index: 1310;
}

/* Modals inside .site-main (channel etc.); lift main above fixed tabbar/header while open. */
body.fighoo-modal-open .site-main {
	position: relative;
	z-index: 1100;
}

body.fighoo-modal-open .glass-header,
body.fighoo-modal-open .glass-tabbar,
body.fighoo-modal-open .channel-glass-header,
body.fighoo-modal-open .channel-glass-bottom {
	z-index: 900;
	pointer-events: none;
}

#modal-ad-forward .fighoo-modal__panel {
	background: #fff;
	border: 1px solid rgba(198, 40, 40, 0.2);
	box-shadow:
		0 12px 40px rgba(15, 23, 42, 0.14),
		0 0 0 1px rgba(198, 40, 40, 0.06);
	-webkit-backdrop-filter: none;
	backdrop-filter: none;
}

#modal-channel-sort .channel-sort-modal__panel {
	background: rgba(255, 255, 255, 0.96);
	border: 1px solid rgba(255, 255, 255, 0.85);
	border-radius: 22px;
	box-shadow:
		0 24px 64px rgba(15, 23, 42, 0.18),
		0 2px 8px rgba(15, 23, 42, 0.06),
		inset 0 1px 0 rgba(255, 255, 255, 0.95);
	-webkit-backdrop-filter: blur(20px) saturate(1.35);
	backdrop-filter: blur(20px) saturate(1.35);
	overflow: hidden;
	max-width: min(420px, calc(100vw - 24px));
}

#modal-ad-report .ad-report-modal__panel {
	background: rgba(255, 255, 255, 0.96);
	border: 1px solid rgba(255, 255, 255, 0.85);
	border-radius: 22px;
	box-shadow:
		0 24px 64px rgba(15, 23, 42, 0.18),
		0 2px 8px rgba(15, 23, 42, 0.06),
		inset 0 1px 0 rgba(255, 255, 255, 0.95);
	-webkit-backdrop-filter: blur(20px) saturate(1.35);
	backdrop-filter: blur(20px) saturate(1.35);
	display: flex;
	flex-direction: column;
	min-height: 0;
	overflow: hidden;
	max-width: min(420px, calc(100vw - 24px));
}

#modal-ad-forward .fighoo-modal__header {
	border-bottom-color: rgba(198, 40, 40, 0.12);
}

#modal-channel-sort .channel-sort-modal__header {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	position: relative;
	gap: 0;
	padding: 20px 20px 16px;
	border-bottom: 1px solid rgba(15, 23, 42, 0.06);
	background: linear-gradient(180deg, rgba(254, 242, 242, 0.55) 0%, rgba(255, 255, 255, 0) 100%);
}

#modal-channel-sort .channel-sort-modal__title {
	grid-column: unset;
	grid-row: unset;
	min-width: 0;
	overflow: visible;
	text-overflow: unset;
	white-space: normal;
	text-align: center;
}

#modal-ad-report .ad-report-modal__header {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	position: relative;
	flex: 0 0 auto;
	gap: 0;
	padding: 20px 20px 16px;
	border-bottom: 1px solid rgba(15, 23, 42, 0.06);
	background: linear-gradient(180deg, rgba(254, 242, 242, 0.55) 0%, rgba(255, 255, 255, 0) 100%);
}

#modal-ad-report .ad-report-modal__title {
	grid-column: unset;
	grid-row: unset;
	min-width: 0;
	overflow: visible;
	text-overflow: unset;
	white-space: normal;
	text-align: center;
}

#modal-ad-forward .fighoo-modal__header h2 {
	color: var(--color-primary);
}

#modal-channel-sort .channel-sort-modal__close {
	position: absolute;
	top: 14px;
	inset-inline-start: 14px;
	grid-column: unset;
	grid-row: unset;
	z-index: 2;
	background: rgba(15, 23, 42, 0.06);
	border-radius: 50%;
	width: 36px;
	height: 36px;
}

#modal-channel-sort .channel-sort-modal__close:hover {
	background: rgba(15, 23, 42, 0.1);
}

#modal-ad-forward .fighoo-modal__close {
	background: rgba(198, 40, 40, 0.1);
}

#modal-ad-report .ad-report-modal__close {
	position: absolute;
	top: 14px;
	inset-inline-start: 14px;
	grid-column: unset;
	grid-row: unset;
	z-index: 2;
	background: rgba(15, 23, 42, 0.06);
	border-radius: 50%;
	width: 36px;
	height: 36px;
}

#modal-ad-report .ad-report-modal__close:hover {
	background: rgba(15, 23, 42, 0.1);
}

#modal-ad-forward .fighoo-modal__close-glyph::before,
#modal-ad-forward .fighoo-modal__close-glyph::after {
	background: var(--color-primary);
}

#modal-channel-sort .channel-sort-modal__close .fighoo-modal__close-glyph::before,
#modal-channel-sort .channel-sort-modal__close .fighoo-modal__close-glyph::after {
	background: #374151;
}

#modal-ad-report .ad-report-modal__close .fighoo-modal__close-glyph::before,
#modal-ad-report .ad-report-modal__close .fighoo-modal__close-glyph::after {
	background: #374151;
}

#modal-ad-forward .fighoo-modal__body--channel-sort {
	background: #fff;
	padding: 14px 16px 18px;
}

#modal-channel-sort .channel-sort-modal__backdrop {
	background: rgba(15, 23, 42, 0.42);
	-webkit-backdrop-filter: blur(4px);
	backdrop-filter: blur(4px);
}

#modal-ad-forward .fighoo-modal__hint {
	margin: 0 0 12px;
	text-align: center;
	font-size: 0.82rem;
	font-weight: 600;
	color: rgba(55, 65, 81, 0.88);
}

.fighoo-exit-confirm__text {
	margin: 0 0 20px;
	text-align: center;
	font-size: 0.95rem;
	line-height: 1.6;
	color: rgba(26, 29, 33, 0.78);
}

/* Exit app confirm — centered dialog (not bottom sheet). */
#fighoo-exit-confirm-modal.fighoo-modal:not([hidden]) {
	align-items: center;
	justify-content: center;
	z-index: 1400;
	padding:
		max(20px, env(safe-area-inset-top, 0px))
		max(20px, env(safe-area-inset-left, 0px))
		max(20px, env(safe-area-inset-bottom, 0px))
		max(20px, env(safe-area-inset-right, 0px));
}

#fighoo-exit-confirm-modal .fighoo-modal__backdrop {
	background: rgba(15, 23, 42, 0.42);
	-webkit-backdrop-filter: blur(6px);
	backdrop-filter: blur(6px);
	animation: fighoo-exit-backdrop-in 0.28s ease both;
}

#fighoo-exit-confirm-modal .fighoo-exit-confirm__panel {
	max-width: min(340px, calc(100vw - 40px));
	max-height: none;
	padding: 28px 22px 22px;
	border-radius: 24px;
	text-align: center;
	border: 1px solid rgba(255, 255, 255, 0.88);
	background: rgba(255, 255, 255, 0.96);
	box-shadow:
		0 24px 64px rgba(15, 23, 42, 0.18),
		0 0 0 1px rgba(198, 40, 40, 0.06),
		inset 0 1px 0 rgba(255, 255, 255, 0.95);
	animation: fighoo-exit-dialog-in 0.34s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.fighoo-exit-confirm__badge {
	width: 56px;
	height: 56px;
	margin: 0 auto 14px;
	border-radius: 18px;
	display: flex;
	align-items: center;
	justify-content: center;
	color: var(--color-primary, #c62828);
	background: linear-gradient(145deg, rgba(198, 40, 40, 0.14), rgba(198, 40, 40, 0.05));
	border: 1px solid rgba(198, 40, 40, 0.14);
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.65);
}

.fighoo-exit-confirm__title {
	margin: 0 0 10px;
	font-size: 1.1rem;
	font-weight: 800;
	line-height: 1.35;
	color: var(--color-primary, #c62828);
}

.fighoo-exit-confirm__actions {
	display: flex;
	flex-direction: column;
	gap: 10px;
	width: 100%;
}

.fighoo-exit-confirm__actions .glass-btn {
	width: 100%;
	min-width: 0;
	min-height: 48px;
	padding: 14px 18px;
	font-size: 0.95rem;
	font-weight: 700;
}

.fighoo-exit-confirm__stay {
	color: #fff;
	border-color: rgba(198, 40, 40, 0.35);
	background: var(--color-primary, #c62828);
	box-shadow:
		0 8px 24px rgba(198, 40, 40, 0.28),
		inset 0 1px 0 rgba(255, 255, 255, 0.22);
}

.fighoo-exit-confirm__stay:focus-visible {
	outline-color: var(--color-primary, #c62828);
}

.fighoo-exit-confirm__leave {
	color: rgba(15, 23, 42, 0.72);
	border-color: rgba(15, 23, 42, 0.1);
	background: rgba(15, 23, 42, 0.04);
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

body.fighoo-exit-confirm-open .fighoo-login,
body.fighoo-exit-confirm-open .site-main {
	filter: none;
}

@keyframes fighoo-exit-dialog-in {
	from {
		opacity: 0;
		transform: translate3d(0, 12px, 0) scale(0.96);
	}

	to {
		opacity: 1;
		transform: translate3d(0, 0, 0) scale(1);
	}
}

@keyframes fighoo-exit-backdrop-in {
	from {
		opacity: 0;
	}

	to {
		opacity: 1;
	}
}

@media (prefers-reduced-motion: reduce) {
	#fighoo-exit-confirm-modal .fighoo-exit-confirm__panel,
	#fighoo-exit-confirm-modal .fighoo-modal__backdrop {
		animation: none;
	}
}

.ad-report-modal__intro {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	width: 100%;
	box-sizing: border-box;
	padding: 36px 8px 0;
	gap: 10px;
}

.ad-report-modal__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 52px;
	height: 52px;
	border-radius: 16px;
	color: var(--color-primary, #c62828);
	background: rgba(255, 255, 255, 0.85);
	border: 1px solid rgba(198, 40, 40, 0.12);
	box-shadow:
		0 8px 24px rgba(198, 40, 40, 0.1),
		inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.ad-report-modal__title {
	margin: 0;
	font-size: 1.05rem;
	font-weight: 800;
	line-height: 1.35;
	color: #111827;
	letter-spacing: -0.02em;
	white-space: normal;
	text-align: center;
}

.ad-report-modal__lead {
	margin: 0;
	width: 100%;
	max-width: none;
	font-size: 0.8rem;
	font-weight: 500;
	line-height: 1.65;
	color: rgba(55, 65, 81, 0.88);
	text-wrap: pretty;
}

.ad-report-modal__body {
	flex: 1 1 auto;
	min-height: 0;
	overflow-x: hidden;
	overflow-y: auto;
	-webkit-overflow-scrolling: touch;
	overscroll-behavior: contain;
	padding: 12px 14px calc(18px + env(safe-area-inset-bottom, 0px));
	background: rgba(248, 250, 252, 0.65);
}

.ad-report-modal__backdrop {
	background: rgba(15, 23, 42, 0.42);
	-webkit-backdrop-filter: blur(4px);
	backdrop-filter: blur(4px);
}

.ad-report-reason-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.ad-report-reason-list__item {
	margin: 0;
}

.ad-report-reason {
	display: flex;
	flex-direction: row;
	align-items: center;
	gap: 10px;
	width: 100%;
	padding: 12px 14px;
	border-radius: 14px;
	border: 1px solid rgba(15, 23, 42, 0.08);
	background: rgba(255, 255, 255, 0.92);
	box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
	font-family: inherit;
	font-size: 0.84rem;
	font-weight: 600;
	line-height: 1.35;
	color: #1f2937;
	cursor: pointer;
	text-align: start;
	transition:
		background 0.15s ease,
		border-color 0.15s ease,
		box-shadow 0.15s ease,
		transform 0.12s ease,
		opacity 0.15s ease;
	-webkit-tap-highlight-color: transparent;
}

.ad-report-reason:hover {
	border-color: rgba(198, 40, 40, 0.22);
	background: #fff;
	box-shadow: 0 4px 14px rgba(15, 23, 42, 0.07);
}

.ad-report-reason:active {
	transform: scale(0.985);
}

.ad-report-reason:focus {
	outline: none;
}

.ad-report-reason:focus-visible {
	outline: 2px solid var(--color-primary, #c62828);
	outline-offset: 2px;
}

.ad-report-reason:disabled {
	opacity: 0.55;
	cursor: wait;
}

.ad-report-reason__dot {
	flex: 0 0 8px;
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: rgba(198, 40, 40, 0.45);
	box-shadow: 0 0 0 3px rgba(198, 40, 40, 0.1);
}

.ad-report-reason__label {
	flex: 1 1 auto;
	min-width: 0;
}

.ad-report-reason__arrow {
	flex: 0 0 auto;
	display: flex;
	color: rgba(15, 23, 42, 0.28);
	line-height: 0;
	transition: color 0.15s ease, transform 0.15s ease;
}

.ad-report-reason:hover .ad-report-reason__arrow {
	color: var(--color-primary, #c62828);
	transform: translateX(2px);
}

.ad-report-reason.is-active {
	border-color: rgba(198, 40, 40, 0.45);
	background: rgba(254, 242, 242, 0.95);
	color: var(--color-primary, #c62828);
	box-shadow: 0 4px 16px rgba(198, 40, 40, 0.12);
}

.ad-report-reason.is-active .ad-report-reason__dot {
	background: var(--color-primary, #c62828);
	box-shadow: 0 0 0 3px rgba(198, 40, 40, 0.18);
}

.ad-report-modal__step--other[hidden] {
	display: none !important;
}

#modal-ad-report.is-step-other .ad-report-modal__other-title {
	display: none;
}

#modal-ad-report.is-step-other .ad-report-modal__intro {
	padding-top: 28px;
}

.ad-report-modal__other-title {
	margin: 0 0 10px;
	font-size: 0.88rem;
	font-weight: 700;
	color: #111827;
}

.ad-report-modal__other-input {
	display: block;
	width: 100%;
	box-sizing: border-box;
	padding: 12px 14px;
	border-radius: 14px;
	border: 1px solid rgba(15, 23, 42, 0.12);
	background: #fff;
	font-family: inherit;
	font-size: 0.84rem;
	line-height: 1.55;
	color: #1f2937;
	resize: vertical;
	min-height: 6.5rem;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.ad-report-modal__other-input:focus {
	outline: none;
	border-color: rgba(198, 40, 40, 0.45);
	box-shadow: 0 0 0 3px rgba(198, 40, 40, 0.12);
}

.ad-report-modal__other-hint {
	margin: 8px 0 0;
	font-size: 0.72rem;
	line-height: 1.5;
	color: rgba(55, 65, 81, 0.75);
}

.ad-report-modal__other-count {
	margin: 6px 0 0;
	font-size: 0.72rem;
	font-weight: 600;
	line-height: 1.4;
	color: rgba(55, 65, 81, 0.55);
	text-align: end;
}

.ad-report-modal__other-count.is-near-limit {
	color: #b45309;
}

.ad-report-modal__other-count.is-at-limit {
	color: #b91c1c;
}

#modal-ad-report.is-submitting .ad-report-modal__other-submit {
	cursor: wait;
	opacity: 0.88;
}

.ad-report-modal__other-actions {
	display: flex;
	flex-direction: row;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	margin-top: 16px;
}

.ad-report-modal__other-back,
.ad-report-modal__other-submit {
	flex: 1 1 0;
	min-height: 44px;
	padding: 10px 14px;
	border-radius: 14px;
	font-family: inherit;
	font-size: 0.84rem;
	font-weight: 700;
	cursor: pointer;
	border: 1px solid transparent;
	transition: background 0.15s ease, border-color 0.15s ease, opacity 0.15s ease;
}

.ad-report-modal__other-back {
	background: rgba(15, 23, 42, 0.06);
	color: #374151;
	border-color: rgba(15, 23, 42, 0.08);
}

.ad-report-modal__other-submit {
	color: #fff;
	background: linear-gradient(135deg, #047857 0%, #059669 38%, #10b981 100%);
	border-color: transparent;
	box-shadow:
		0 1px 0 rgba(255, 255, 255, 0.22) inset,
		0 8px 22px rgba(5, 150, 105, 0.32);
	transition:
		transform 0.14s ease,
		box-shadow 0.14s ease,
		filter 0.14s ease,
		opacity 0.14s ease;
}

.ad-report-modal__other-submit:not(:disabled):hover {
	filter: brightness(1.06);
	box-shadow:
		0 1px 0 rgba(255, 255, 255, 0.28) inset,
		0 10px 26px rgba(5, 150, 105, 0.38);
}

body.fighoo-theme .ad-report-modal__other-submit:not(:disabled):active,
body.fighoo-theme .ad-report-modal__other-submit:not(:disabled).is-pressed {
	transform: scale(0.985);
	opacity: 1;
	box-shadow:
		0 1px 0 rgba(255, 255, 255, 0.15) inset,
		0 4px 14px rgba(5, 150, 105, 0.28);
}

.ad-report-modal__other-submit:focus-visible {
	outline: 2px solid #10b981;
	outline-offset: 3px;
}

.ad-report-modal__other-submit:disabled,
.ad-report-modal__other-back:disabled {
	opacity: 0.55;
	cursor: wait;
}

/* Channel sort modal — modern sheet (matches ad report modal). */
.channel-sort-modal__intro {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	width: 100%;
	box-sizing: border-box;
	padding: 36px 8px 0;
	gap: 10px;
}

.channel-sort-modal__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 52px;
	height: 52px;
	border-radius: 16px;
	color: var(--color-primary, #c62828);
	background: rgba(255, 255, 255, 0.85);
	border: 1px solid rgba(198, 40, 40, 0.12);
	box-shadow:
		0 8px 24px rgba(198, 40, 40, 0.1),
		inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.channel-sort-modal__title {
	margin: 0;
	font-size: 1.05rem;
	font-weight: 800;
	line-height: 1.35;
	color: #111827;
	letter-spacing: -0.02em;
	white-space: normal;
	text-align: center;
}

.channel-sort-modal__lead {
	margin: 0;
	width: 100%;
	font-size: 0.8rem;
	font-weight: 500;
	line-height: 1.65;
	color: rgba(55, 65, 81, 0.88);
	text-wrap: pretty;
}

#modal-channel-sort .channel-sort-modal__body {
	padding: 12px 14px calc(18px + env(safe-area-inset-bottom, 0px));
	background: rgba(248, 250, 252, 0.65);
}

#modal-channel-sort .channel-sort-modal__list {
	gap: 8px;
	margin: 0;
	padding: 0;
}

#modal-channel-sort .channel-sort-option {
	display: flex;
	flex-direction: row;
	align-items: center;
	gap: 12px;
	width: 100%;
	padding: 12px 14px;
	border-radius: 14px;
	border: 1px solid rgba(15, 23, 42, 0.08);
	background: rgba(255, 255, 255, 0.92);
	box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
	font-family: inherit;
	font-size: 0.84rem;
	font-weight: 600;
	line-height: 1.4;
	color: #1f2937;
	cursor: pointer;
	text-align: start;
	-webkit-backdrop-filter: none;
	backdrop-filter: none;
	transition:
		background 0.15s ease,
		border-color 0.15s ease,
		box-shadow 0.15s ease,
		color 0.15s ease,
		transform 0.12s ease;
}

#modal-channel-sort .channel-sort-option:hover {
	border-color: rgba(198, 40, 40, 0.22);
	background: #fff;
	box-shadow: 0 4px 14px rgba(15, 23, 42, 0.07);
}

#modal-channel-sort .channel-sort-option:active {
	transform: scale(0.985);
}

#modal-channel-sort .channel-sort-option.is-active {
	border-color: rgba(198, 40, 40, 0.45);
	background: rgba(254, 242, 242, 0.95);
	color: var(--color-primary, #c62828);
	box-shadow: 0 4px 16px rgba(198, 40, 40, 0.12);
}

#modal-channel-sort .channel-sort-option__mark {
	flex: 0 0 22px;
	width: 22px;
	height: 22px;
	border-radius: 50%;
	border: 2px solid rgba(15, 23, 42, 0.18);
	display: flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	transition: border-color 0.15s ease, background 0.15s ease;
}

#modal-channel-sort .channel-sort-option__check {
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: transparent;
	transform: scale(0);
	transition: transform 0.15s ease, background 0.15s ease;
}

#modal-channel-sort .channel-sort-option.is-active .channel-sort-option__mark {
	border-color: var(--color-primary, #c62828);
	background: rgba(255, 255, 255, 0.9);
}

#modal-channel-sort .channel-sort-option.is-active .channel-sort-option__check {
	background: var(--color-primary, #c62828);
	transform: scale(1);
}

#modal-channel-sort .channel-sort-option__label {
	flex: 1 1 auto;
	min-width: 0;
}

.ad-forward-empty {
	margin: 0;
	text-align: center;
	font-size: 0.82rem;
	font-weight: 600;
	color: rgba(55, 65, 81, 0.85);
	line-height: 1.5;
}

.ad-forward-target-list {
	gap: 8px;
	max-height: min(52vh, 420px);
	overflow-y: auto;
	-webkit-overflow-scrolling: touch;
}

.ad-forward-target {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 3px;
	padding: 10px 14px !important;
	font-size: 0.82rem !important;
}

.ad-forward-target__peer {
	font-weight: 700;
	line-height: 1.25;
}

.ad-forward-target__meta {
	font-size: 0.72rem;
	font-weight: 600;
	opacity: 0.72;
	line-height: 1.2;
}

.channel-sort-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.channel-sort-list li {
	margin: 0;
}

.channel-sort-option {
	width: 100%;
	text-align: center;
	padding: 13px 16px;
	border-radius: 9999px;
	border: 1px solid rgba(198, 40, 40, 0.22);
	background: var(--fighoo-tabbar-pill-bg, rgba(254, 242, 242, 0.55));
	box-shadow:
		0 2px 10px rgba(198, 40, 40, 0.06),
		inset 0 1px 0 rgba(255, 255, 255, 0.75);
	-webkit-backdrop-filter: blur(14px) saturate(1.25);
	backdrop-filter: blur(14px) saturate(1.25);
	font-family: inherit;
	font-size: 0.88rem;
	font-weight: 700;
	color: #1f2937;
	cursor: pointer;
	transition:
		background 0.15s ease,
		border-color 0.15s ease,
		color 0.15s ease,
		box-shadow 0.15s ease;
}

.channel-sort-option:focus {
	outline: none;
}

.channel-sort-option:focus-visible {
	outline: 2px solid var(--color-primary);
	outline-offset: 2px;
}

.channel-sort-option.is-active {
	border-color: rgba(198, 40, 40, 0.58);
	background: rgba(198, 40, 40, 0.14);
	color: var(--color-primary);
	box-shadow:
		0 2px 12px rgba(198, 40, 40, 0.12),
		inset 0 1px 0 rgba(255, 255, 255, 0.65);
}

.page-shell {
	padding: 8px 0 24px;
}

.page-shell__title {
	margin: 0 0 12px;
	font-size: 1.25rem;
	font-weight: 700;
}

.page-shell__placeholder {
	margin: 0;
	color: rgba(26, 29, 33, 0.55);
	font-size: 0.9rem;
}

.page-shell__placeholder a {
	color: var(--color-primary);
	font-weight: 600;
	text-decoration: none;
}

/* Shared circular avatars (chats, channel chrome, my-channels, category icon). */
.channel-avatar {
	position: relative;
	width: 42px;
	height: 42px;
	border-radius: 50%;
	background: linear-gradient(145deg, #e53935, var(--color-primary, #c62828));
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}

.channel-avatar__base {
	display: flex;
	align-items: center;
	justify-content: center;
	color: #fff;
}

.channel-avatar__base svg {
	display: block;
	width: 22px;
	height: 22px;
	stroke: currentColor;
}

.channel-avatar__badge {
	position: absolute;
	bottom: -3px;
	inset-inline-start: -3px;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: #fff;
	color: var(--color-primary, #c62828);
	box-shadow: 0 1px 5px rgba(15, 23, 42, 0.18);
	border: 1.5px solid rgba(255, 255, 255, 0.9);
}

.channel-avatar__badge svg {
	display: block;
	width: 11px;
	height: 11px;
	stroke: currentColor;
}

/* Tab swipe — animate header + main together; tab bar stays fixed outside stage */
.fighoo-tab-stage {
	display: flex;
	flex-direction: column;
	min-height: 100vh;
	max-width: var(--fighoo-shell-max-w);
	margin: 0 auto;
	width: 100%;
	box-sizing: border-box;
}

body.fighoo-tab-swipe-enabled .fighoo-tab-stage > .glass-header {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	flex-shrink: 0;
}

body.fighoo-tab-swipe-enabled .site-main--chats .page-shell--chats,
body.fighoo-tab-swipe-enabled .saved-ads-feed,
body.fighoo-tab-swipe-enabled .my-ads-feed,
body.fighoo-tab-swipe-enabled .my-branches-feed,
body.fighoo-tab-swipe-enabled .page-shell--my-ads,
body.fighoo-tab-swipe-enabled .page-shell--submit-ad {
	touch-action: pan-y;
}

.fighoo-tab-stage.fighoo-tab-swipe-host {
	will-change: auto;
}

body.fighoo-tab-transition-active .fighoo-tab-stage.fighoo-tab-swipe-host {
	will-change: transform;
}

body.fighoo-tab-swipe-active {
	touch-action: none;
}

body.fighoo-tab-swipe-active .tg-channel__feed,
body.fighoo-tab-swipe-active .saved-ads-feed,
body.fighoo-tab-swipe-active .my-ads-feed,
body.fighoo-tab-swipe-active .my-branches-feed {
	touch-action: none;
	overflow: hidden;
}

body.fighoo-tab-transition-active {
	overflow: hidden;
}

body.fighoo-tab-transition-active .fighoo-tab-stage.fighoo-tab-swipe-host {
	transform-style: preserve-3d;
	backface-visibility: hidden;
}

/* Tab transitions — RTL: forward/back classes set in tabbar.js (swipeDirFromDx) */
.fighoo-tab-stage.fighoo-tab-enter[class*='fighoo-tab-enter--'] {
	animation-duration: 0.26s;
	animation-timing-function: cubic-bezier(0.32, 0.72, 0, 1);
	animation-fill-mode: both;
}

html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-enter--slide-rtl.fighoo-tab-from-forward {
	animation-name: fighoo-tab-rtl-enter-from-start;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-enter--slide-rtl.fighoo-tab-from-back {
	animation-name: fighoo-tab-rtl-enter-from-end;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-exit--slide-rtl.fighoo-tab-from-forward {
	animation-name: fighoo-tab-rtl-exit-to-end;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-exit--slide-rtl.fighoo-tab-from-back {
	animation-name: fighoo-tab-rtl-exit-to-start;
}

html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-enter--fade-slide.fighoo-tab-from-forward {
	animation-name: fighoo-tab-rtl-fade-slide-start;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-enter--fade-slide.fighoo-tab-from-back {
	animation-name: fighoo-tab-rtl-fade-slide-end;
}

.fighoo-tab-stage.fighoo-tab-exit[class*='fighoo-tab-exit--'] {
	animation-duration: 0.2s;
	animation-timing-function: cubic-bezier(0.32, 0.72, 0, 1);
	animation-fill-mode: both;
}

.fighoo-tab-stage.fighoo-tab-exit--fade {
	animation-name: fighoo-tab-exit-fade;
}
.fighoo-tab-stage.fighoo-tab-exit--scale {
	animation-name: fighoo-tab-exit-scale;
}
.fighoo-tab-stage.fighoo-tab-exit--push.fighoo-tab-from-forward {
	animation-name: fighoo-tab-exit-push-forward;
}
.fighoo-tab-stage.fighoo-tab-exit--push.fighoo-tab-from-back {
	animation-name: fighoo-tab-exit-push-back;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-exit--fade-slide.fighoo-tab-from-forward {
	animation-name: fighoo-tab-rtl-fade-slide-exit-end;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-exit--fade-slide.fighoo-tab-from-back {
	animation-name: fighoo-tab-rtl-fade-slide-exit-start;
}

.fighoo-tab-stage.fighoo-tab-enter--fade {
	animation-name: fighoo-tab-enter-fade;
}
.fighoo-tab-stage.fighoo-tab-enter--scale {
	animation-name: fighoo-tab-enter-scale;
}
.fighoo-tab-stage.fighoo-tab-enter--push.fighoo-tab-from-forward {
	animation-name: fighoo-tab-enter-push-forward;
}
.fighoo-tab-stage.fighoo-tab-enter--push.fighoo-tab-from-back {
	animation-name: fighoo-tab-enter-push-back;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-enter--flip.fighoo-tab-from-forward {
	animation-name: fighoo-tab-rtl-flip-forward;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-enter--flip.fighoo-tab-from-back {
	animation-name: fighoo-tab-rtl-flip-back;
}

.fighoo-tab-stage.fighoo-tab-enter--push-scale,
.fighoo-tab-stage.fighoo-tab-exit--push-scale,
.fighoo-tab-stage.fighoo-tab-enter--card-stack,
.fighoo-tab-stage.fighoo-tab-exit--card-stack,
.fighoo-tab-stage.fighoo-tab-enter--card-flip,
.fighoo-tab-stage.fighoo-tab-exit--card-flip,
.fighoo-tab-stage.fighoo-tab-enter--modal,
.fighoo-tab-stage.fighoo-tab-exit--modal {
	animation-duration: 0.28s;
}

html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-enter--push-scale.fighoo-tab-from-forward {
	animation-name: fighoo-tab-push-scale-enter-forward;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-enter--push-scale.fighoo-tab-from-back {
	animation-name: fighoo-tab-push-scale-enter-back;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-exit--push-scale.fighoo-tab-from-forward {
	animation-name: fighoo-tab-push-scale-exit-forward;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-exit--push-scale.fighoo-tab-from-back {
	animation-name: fighoo-tab-push-scale-exit-back;
}

html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-enter--card-stack.fighoo-tab-from-forward {
	animation-name: fighoo-tab-card-stack-enter-forward;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-enter--card-stack.fighoo-tab-from-back {
	animation-name: fighoo-tab-card-stack-enter-back;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-exit--card-stack.fighoo-tab-from-forward {
	animation-name: fighoo-tab-card-stack-exit-forward;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-exit--card-stack.fighoo-tab-from-back {
	animation-name: fighoo-tab-card-stack-exit-back;
}

html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-enter--card-flip.fighoo-tab-from-forward {
	animation-name: fighoo-tab-card-flip-enter-forward;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-enter--card-flip.fighoo-tab-from-back {
	animation-name: fighoo-tab-card-flip-enter-back;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-exit--card-flip.fighoo-tab-from-forward {
	animation-name: fighoo-tab-card-flip-exit-forward;
}
html[dir='rtl'] .fighoo-tab-stage.fighoo-tab-exit--card-flip.fighoo-tab-from-back {
	animation-name: fighoo-tab-card-flip-exit-back;
}

.fighoo-tab-stage.fighoo-tab-enter--modal {
	animation-name: fighoo-tab-modal-enter;
}
.fighoo-tab-stage.fighoo-tab-exit--modal {
	animation-name: fighoo-tab-modal-exit;
}

@keyframes fighoo-tab-rtl-enter-from-start {
	from {
		transform: translate3d(38%, 0, 0);
		opacity: 0.9;
	}
	to {
		transform: translate3d(0, 0, 0);
		opacity: 1;
	}
}
@keyframes fighoo-tab-rtl-enter-from-end {
	from {
		transform: translate3d(-38%, 0, 0);
		opacity: 0.9;
	}
	to {
		transform: translate3d(0, 0, 0);
		opacity: 1;
	}
}
@keyframes fighoo-tab-rtl-exit-to-end {
	from {
		transform: translate3d(0, 0, 0);
		opacity: 1;
	}
	to {
		transform: translate3d(-38%, 0, 0);
		opacity: 0.88;
	}
}
@keyframes fighoo-tab-rtl-exit-to-start {
	from {
		transform: translate3d(0, 0, 0);
		opacity: 1;
	}
	to {
		transform: translate3d(38%, 0, 0);
		opacity: 0.88;
	}
}
@keyframes fighoo-tab-rtl-fade-slide-start {
	from {
		transform: translate3d(18%, 0, 0);
		opacity: 0;
	}
	to {
		transform: none;
		opacity: 1;
	}
}
@keyframes fighoo-tab-rtl-fade-slide-end {
	from {
		transform: translate3d(-18%, 0, 0);
		opacity: 0;
	}
	to {
		transform: none;
		opacity: 1;
	}
}
@keyframes fighoo-tab-enter-fade {
	from {
		opacity: 0;
	}
	to {
		opacity: 1;
	}
}
@keyframes fighoo-tab-enter-scale {
	from {
		transform: scale(0.96);
		opacity: 0.85;
	}
	to {
		transform: scale(1);
		opacity: 1;
	}
}
@keyframes fighoo-tab-enter-push-forward {
	from {
		transform: scale(0.98) translate3d(12%, 0, 0);
		opacity: 0.9;
	}
	to {
		transform: none;
		opacity: 1;
	}
}
@keyframes fighoo-tab-enter-push-back {
	from {
		transform: scale(0.98) translate3d(-12%, 0, 0);
		opacity: 0.9;
	}
	to {
		transform: none;
		opacity: 1;
	}
}
@keyframes fighoo-tab-rtl-flip-forward {
	from {
		transform: perspective(900px) rotateY(14deg);
		opacity: 0.88;
	}
	to {
		transform: none;
		opacity: 1;
	}
}
@keyframes fighoo-tab-rtl-flip-back {
	from {
		transform: perspective(900px) rotateY(-14deg);
		opacity: 0.88;
	}
	to {
		transform: none;
		opacity: 1;
	}
}
@keyframes fighoo-tab-exit-fade {
	from {
		opacity: 1;
	}
	to {
		opacity: 0;
	}
}
@keyframes fighoo-tab-exit-scale {
	from {
		transform: scale(1);
		opacity: 1;
	}
	to {
		transform: scale(0.97);
		opacity: 0.7;
	}
}
@keyframes fighoo-tab-exit-push-forward {
	to {
		transform: scale(0.98) translate3d(-10%, 0, 0);
		opacity: 0.85;
	}
}
@keyframes fighoo-tab-exit-push-back {
	to {
		transform: scale(0.98) translate3d(10%, 0, 0);
		opacity: 0.85;
	}
}
@keyframes fighoo-tab-rtl-fade-slide-exit-end {
	to {
		transform: translate3d(-16%, 0, 0);
		opacity: 0;
	}
}
@keyframes fighoo-tab-rtl-fade-slide-exit-start {
	to {
		transform: translate3d(16%, 0, 0);
		opacity: 0;
	}
}

@keyframes fighoo-tab-push-scale-enter-forward {
	from {
		transform: translate3d(-14%, 0, 0) scale(1.06);
		opacity: 0.82;
	}
	to {
		transform: none;
		opacity: 1;
	}
}
@keyframes fighoo-tab-push-scale-enter-back {
	from {
		transform: translate3d(14%, 0, 0) scale(1.06);
		opacity: 0.82;
	}
	to {
		transform: none;
		opacity: 1;
	}
}
@keyframes fighoo-tab-push-scale-exit-forward {
	to {
		transform: translate3d(10%, 0, 0) scale(0.84);
		opacity: 0.72;
		filter: brightness(0.94);
	}
}
@keyframes fighoo-tab-push-scale-exit-back {
	to {
		transform: translate3d(-10%, 0, 0) scale(0.84);
		opacity: 0.72;
		filter: brightness(0.94);
	}
}
@keyframes fighoo-tab-card-stack-enter-forward {
	from {
		transform: translate3d(-36%, 0, 0) scale(0.9);
		opacity: 0.9;
	}
	to {
		transform: none;
		opacity: 1;
	}
}
@keyframes fighoo-tab-card-stack-enter-back {
	from {
		transform: translate3d(36%, 0, 0) scale(0.9);
		opacity: 0.9;
	}
	to {
		transform: none;
		opacity: 1;
	}
}
@keyframes fighoo-tab-card-stack-exit-forward {
	to {
		transform: translate3d(14%, 0, 0) scale(0.86);
		opacity: 0.65;
	}
}
@keyframes fighoo-tab-card-stack-exit-back {
	to {
		transform: translate3d(-14%, 0, 0) scale(0.86);
		opacity: 0.65;
	}
}
@keyframes fighoo-tab-card-flip-enter-forward {
	from {
		transform: perspective(1000px) rotateY(68deg) scale(0.94);
		opacity: 0.75;
	}
	to {
		transform: none;
		opacity: 1;
	}
}
@keyframes fighoo-tab-card-flip-enter-back {
	from {
		transform: perspective(1000px) rotateY(-68deg) scale(0.94);
		opacity: 0.75;
	}
	to {
		transform: none;
		opacity: 1;
	}
}
@keyframes fighoo-tab-card-flip-exit-forward {
	to {
		transform: perspective(1000px) rotateY(-32deg) scale(0.9);
		opacity: 0.55;
	}
}
@keyframes fighoo-tab-card-flip-exit-back {
	to {
		transform: perspective(1000px) rotateY(32deg) scale(0.9);
		opacity: 0.55;
	}
}
@keyframes fighoo-tab-modal-enter {
	from {
		transform: scale(0.78) translate3d(0, 5%, 0);
		opacity: 0;
		border-radius: 22px;
	}
	to {
		transform: none;
		opacity: 1;
		border-radius: 0;
	}
}
@keyframes fighoo-tab-modal-exit {
	to {
		transform: scale(0.9) translate3d(0, 2%, 0);
		opacity: 0;
	}
}

/* Cross-document view transitions — off when theme tab FX run (see header meta + body.fighoo-tab-fx-*) */
@view-transition {
	navigation: none;
}

@media (prefers-reduced-motion: reduce) {
	@view-transition {
		navigation: none;
	}

	.fighoo-tab-stage.fighoo-tab-enter[class*='fighoo-tab-enter--'],
	.fighoo-tab-stage.fighoo-tab-exit[class*='fighoo-tab-exit--'] {
		animation: none !important;
	}

	.glass-tabbar__indicator {
		transition: none !important;
	}
}

/* Fixed glass bottom tab bar */
.glass-tabbar {
	position: fixed;
	bottom: 0;
	left: 0;
	right: 0;
	z-index: 1000;
	padding: var(--fighoo-tabbar-outer-pad) var(--fighoo-tabbar-side-margin)
		calc(var(--fighoo-tabbar-outer-pad) + env(safe-area-inset-bottom, 0px));
	pointer-events: none;
	background: transparent;
	border: none;
	box-shadow: none;
}

.glass-tabbar__slot {
	display: flex;
	justify-content: center;
	align-items: center;
	width: 100%;
	max-width: var(--fighoo-tabbar-track-max-w);
	margin-inline: auto;
	padding-inline: var(--fighoo-tabbar-slot-pad-inline);
	box-sizing: border-box;
	pointer-events: auto;
}

html[dir='ltr'] .glass-tabbar__slot {
	justify-content: center;
}

/* Single elliptical glass capsule — all tabs visible (no horizontal scroll). */
.glass-tabbar__pill {
	display: block;
	width: 100%;
	max-width: var(--fighoo-tabbar-track-max-w);
	overflow-x: hidden;
	overflow-y: hidden;
	overflow-anchor: none;
	overscroll-behavior-x: none;
	touch-action: manipulation;
	border-radius: 9999px;
	padding: var(--fighoo-tabbar-pill-pad-block) 12px;
	background: var(--fighoo-tabbar-pill-bg);
	border: 1px solid var(--fighoo-tabbar-pill-border);
	box-shadow:
		0 4px 24px rgba(15, 23, 42, 0.08),
		inset 0 1px 0 rgba(255, 255, 255, 0.75);
	-webkit-backdrop-filter: blur(18px) saturate(1.35);
	backdrop-filter: blur(18px) saturate(1.35);
}

.glass-tabbar__pill-inner {
	display: flex;
	align-items: stretch;
	justify-content: stretch;
	flex-wrap: nowrap;
	gap: var(--fighoo-tabbar-inner-gap);
	direction: rtl;
	position: relative;
	width: 100%;
	min-width: 0;
	box-sizing: border-box;
}

.glass-tabbar__indicator {
	position: absolute;
	top: 0;
	left: 0;
	z-index: 0;
	border-radius: 12px;
	background: var(--fighoo-tabbar-active-bg);
	box-shadow: inset 0 0 0 1px rgba(198, 40, 40, 0.1);
	pointer-events: none;
	transform: translate3d(0, 0, 0);
	transition: transform var(--fighoo-tabbar-indicator-dur) var(--fighoo-tabbar-indicator-ease);
}

.glass-tabbar__pill[data-indicator-dir='back'] .glass-tabbar__indicator {
	transition-duration: var(--fighoo-tabbar-indicator-dur-back);
}

.glass-tabbar__pill.is-indicator-instant .glass-tabbar__indicator {
	transition: none !important;
}

.glass-tabbar__pill:not(.is-indicator-ready) .glass-tabbar__indicator {
	opacity: 0;
}

.glass-tabbar__pill.is-indicator-ready .glass-tabbar__indicator {
	opacity: 1;
	transition:
		opacity 0.12s ease,
		transform var(--fighoo-tabbar-indicator-dur) var(--fighoo-tabbar-indicator-ease);
}

@media (prefers-reduced-motion: reduce) {
	.glass-tabbar__indicator {
		transition: none !important;
	}
}

.glass-tabbar__item {
	flex: 1 1 0;
	min-width: 0;
	max-width: none;
	scroll-margin-inline: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 4px;
	padding: 6px var(--fighoo-tabbar-item-pad-inline);
	border-radius: 12px;
	text-decoration: none;
	font-size: 0.62rem;
	font-weight: 600;
	line-height: 1.15;
	position: relative;
	z-index: 1;
	background: transparent;
	transition: background 0.15s ease, color 0.2s ease;
}

.glass-tabbar__item:active {
	outline: none;
}

.glass-tabbar__item:focus:not(:focus-visible) {
	outline: none;
	box-shadow: none;
}

/* Keyboard focus — visible for accessibility */
.glass-tabbar__item:focus-visible {
	outline: 2px solid var(--color-accent);
	outline-offset: 3px;
}

.glass-tabbar__label {
	color: #000000;
}

.glass-tabbar__pill.is-indicator-ready .glass-tabbar__item.is-active {
	background: transparent;
}

.glass-tabbar__item.is-active {
	background: var(--fighoo-tabbar-active-bg);
}

.glass-tabbar__item.is-active .glass-tabbar__label {
	color: var(--color-primary, #c62828);
	font-weight: 700;
}

.glass-tabbar__icon-wrap {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}

.glass-tabbar__badge {
	position: absolute;
	top: -1px;
	inset-inline-end: -5px;
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: #ef4444;
	border: 2px solid #fff;
	box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.08);
	pointer-events: none;
}

/* Tab switch: no global press scale — avoids shake with sliding indicator. */
body.fighoo-theme .glass-tabbar__item:active,
body.fighoo-theme .glass-tabbar__item.is-pressed {
	transform: none;
	opacity: 1;
	box-shadow: none;
}

/* Header back: same press language as tab bar (no global scale ring). */
body.fighoo-theme .channel-glass-header__back-circle:active,
body.fighoo-theme .channel-glass-header__back-circle.is-pressed,
body.fighoo-theme a.fighoo-chat-thread__back:active,
body.fighoo-theme a.fighoo-chat-thread__back.is-pressed {
	transform: none;
	opacity: 1;
	box-shadow: inset 0 0 0 1px rgba(198, 40, 40, 0.12);
}

.glass-tabbar__badge--count {
	width: auto;
	min-width: 16px;
	height: 16px;
	padding: 0 4px;
	border-radius: 999px;
	font-size: 10px;
	font-weight: 700;
	line-height: 12px;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #fff;
}

.glass-tabbar__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	flex-shrink: 0;
	color: #6b7280;
}

.glass-tabbar__icon svg {
	display: block;
	width: 22px;
	height: 22px;
	stroke: currentColor;
}

.glass-tabbar__item.is-active .glass-tabbar__icon {
	color: var(--color-primary, #c62828);
}

.glass-tabbar__label {
	max-width: 100%;
	overflow: hidden;
	text-overflow: clip;
	white-space: nowrap;
	text-align: center;
	width: 100%;
}

@media (min-width: 480px) {
	.glass-header__tagline {
		font-size: 0.95rem;
	}

	.glass-header__pill {
		padding: 12px 24px 12px 18px;
	}

	.glass-tabbar__item {
		font-size: 0.68rem;
		min-width: 0;
		padding: 8px 6px;
	}
}

/*
 * Mobile / touch / TWA / PWA: backdrop-filter is costly (scroll jank, WebView GPU).
 * Use opaque glass; desktop keeps blur.
 */
@media (max-width: 1024px), (hover: none), (pointer: coarse), (display-mode: standalone), (display-mode: fullscreen), (display-mode: minimal-ui), (prefers-reduced-motion: reduce), (prefers-reduced-transparency: reduce) {
	body.fighoo-theme {
		--fighoo-glass-solid: rgba(255, 255, 255, 0.96);
		--fighoo-glass-solid-muted: rgba(255, 255, 255, 0.92);
	}

	body.fighoo-theme * {
		-webkit-backdrop-filter: none !important;
		backdrop-filter: none !important;
	}

	.glass-header__pill:not(.channel-glass-bottom__pill),
	.glass-btn,
	.glass-header__my-ads-submit,
	.channel-glass-bottom__circle,
	.channel-scroll-fab,
	.channel-glass-bottom__join,
	.channel-glass-bottom__submit,
	.channel-sort-option,
	.tg-post__save,
	.tg-post__btn,
	.tg-post__copy-fab,
	.tg-post__forward-fab,
	.tg-post__share-fab,
	.tg-post__report-fab,
	.tg-post > .tg-post__bubble,
	.submit-ad__picker-btn,
	.fighoo-chat-thread__pill.glass-header__pill,
	.earn-panel__lead,
	.earn-card,
	.earn-stat,
	.earn-referrals-panel,
	.earn-referrals-orders__item,
	.category-picker__item,
	.fighoo-modal__panel {
		background: var(--fighoo-glass-solid);
	}

	/* Bottom tab bar — frosted capsule without backdrop-filter; items stay clear */
	body.fighoo-theme .glass-tabbar__pill {
		background: linear-gradient(
			180deg,
			rgba(255, 253, 253, 0.98) 0%,
			rgba(254, 242, 242, 0.96) 100%
		);
		border: 1px solid var(--fighoo-tabbar-pill-border);
		box-shadow:
			0 10px 32px rgba(15, 23, 42, 0.12),
			0 2px 8px rgba(198, 40, 40, 0.05),
			inset 0 1px 0 rgba(255, 255, 255, 0.92);
	}

	body.fighoo-theme .glass-tabbar__item:not(.is-active) {
		background: transparent;
	}

	body.fighoo-theme .glass-tabbar__item.is-active {
		background: var(--fighoo-tabbar-active-bg);
		box-shadow: inset 0 0 0 1px rgba(198, 40, 40, 0.1);
	}

	body.fighoo-view-earn .earn-invite__input,
	body.fighoo-view-earn .earn-card-form__input {
		background: var(--fighoo-glass-solid-muted);
		-webkit-backdrop-filter: none;
		backdrop-filter: none;
	}

	.glass-btn--green {
		background: rgba(52, 211, 153, 0.88);
	}

	.fighoo-modal__panel {
		background: rgba(255, 255, 255, 0.98);
	}

	.tg-post__btn--call {
		background: var(--fighoo-glass-solid-muted);
	}

	.tg-post__btn--msg {
		background: var(--fighoo-glass-solid-muted);
	}

	.tg-post__save.is-active {
		background: rgba(254, 242, 242, 0.95);
	}

	#modal-channel-sort .channel-sort-modal__panel {
		background: #fff;
		-webkit-backdrop-filter: none;
		backdrop-filter: none;
	}

	#modal-ad-report .ad-report-modal__panel {
		background: #fff;
		-webkit-backdrop-filter: none;
		backdrop-filter: none;
	}
}

/* Visually hidden labels (pickers, chat input, a11y). */
.screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.glass-header__my-ads-submit-icon {
	position: relative;
}

.glass-header__my-ads-submit-glyph {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	line-height: 0;
}

.glass-header__my-ads-submit-glyph svg {
	width: 0.85rem;
	height: 0.85rem;
	stroke: #fff;
}

.glass-header__my-ads-submit-plus {
	position: absolute;
	right: -3px;
	bottom: -3px;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 0.72rem;
	height: 0.72rem;
	border-radius: 50%;
	font-size: 0.58rem;
	font-weight: 800;
	line-height: 1;
	color: #c62828;
	background: #fff;
	box-shadow: 0 1px 3px rgba(15, 23, 42, 0.18);
}

/* ثبت کانال جدید — compact floating control (channels + branches tabs). */
.branch-create-fab-wrap {
	position: fixed;
	z-index: 1002;
	left: max(12px, env(safe-area-inset-left, 0px));
	right: auto;
	bottom: calc(var(--glass-tabbar-h) + env(safe-area-inset-bottom, 0px) + 10px);
	pointer-events: none;
}

a.branch-create-fab {
	text-decoration: none;
	color: #fff;
}

.branch-create-fab {
	pointer-events: auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	max-width: min(calc(100vw - 24px), 220px);
	min-height: 38px;
	padding: 7px 11px 7px 9px;
	margin: 0;
	border: 1px solid rgba(183, 28, 28, 0.6);
	border-radius: 9999px;
	font: inherit;
	font-size: 0.68rem;
	font-weight: 700;
	line-height: 1.2;
	color: #fff;
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
	background: linear-gradient(
		180deg,
		rgba(229, 57, 53, 0.96) 0%,
		rgba(198, 40, 40, 0.94) 100%
	);
	box-shadow:
		0 4px 16px rgba(198, 40, 40, 0.3),
		inset 0 1px 0 rgba(255, 255, 255, 0.3);
	transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.branch-create-fab:hover {
	box-shadow:
		0 5px 18px rgba(198, 40, 40, 0.34),
		inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.branch-create-fab:active {
	transform: scale(0.97);
}

.branch-create-fab__icon {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	width: 1.5rem;
	height: 1.5rem;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.2);
}

.branch-create-fab__glyph {
	display: inline-flex;
	line-height: 0;
}

.branch-create-fab__glyph svg {
	width: 14px;
	height: 14px;
	stroke: #fff;
}

.branch-create-fab__plus {
	position: absolute;
	right: -2px;
	bottom: -2px;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 0.58rem;
	height: 0.58rem;
	border-radius: 50%;
	font-size: 0.48rem;
	font-weight: 800;
	line-height: 1;
	color: #c62828;
	background: #fff;
	box-shadow: 0 1px 2px rgba(15, 23, 42, 0.16);
}

.branch-create-fab__label {
	min-width: 0;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

body.fighoo-my-branches-form-open .branch-create-fab-wrap,
body.fighoo-modal-open .branch-create-fab-wrap {
	opacity: 0;
	pointer-events: none;
	visibility: hidden;
}

body:has(.branch-create-fab-wrap) .site-main.site-main--my-channels,
body:has(.branch-create-fab-wrap) .site-main.site-main--my-ads {
	padding-bottom: max(
		var(
			--fighoo-tabbar-measured-feed-pad-bottom,
			var(--fighoo-tabbar-scroll-clearance, calc(var(--glass-tabbar-h) + env(safe-area-inset-bottom, 0px) + 12px))
		),
		var(
			--fighoo-branch-fab-measured-clearance,
			calc(var(--fighoo-tabbar-scroll-clearance, calc(var(--glass-tabbar-h) + env(safe-area-inset-bottom, 0px) + 12px)) + 52px)
		)
	);
}
