.hab-reactions {
	display: inline-block;
	position: relative;
	vertical-align: middle;
}

.hab-reactions__row {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	flex-wrap: nowrap;
}

.hab-reactions__stack {
	display: inline-flex;
	align-items: center;
	flex-direction: row;
	padding-right: 2px;
}

.hab-reactions__stack-item {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	min-height: 30px;
	margin-left: 4px;
	padding: 4px 4px;
	border: 1px solid var(--bs-bg-offcanvas);
	border-radius: 999px;
	background: var(--bs-bg-offcanvas);
	box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.04);
	line-height: 1;
	cursor: pointer;
	position: relative;
	z-index: 1;
}

.hab-reactions__stack-item:first-child {
	margin-left: 0;
	z-index: 5;
}

.hab-reactions__stack-item:nth-child(2) {
	z-index: 4;
}

.hab-reactions__stack-item:nth-child(3) {
	z-index: 3;
}

.hab-reactions__stack-item:nth-child(4) {
	z-index: 2;
}

.hab-reactions__stack-item:nth-child(5) {
	z-index: 1;
}

body.dle_theme_dark .hab-reactions__stack-item {
	border-color: rgba(255, 255, 255, 0.1);
	background: #3d4349;
	box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.2);
}

.hab-reactions__stack-item.is-active {
	border-color: rgba(13, 110, 253, 0.35);
	background: rgba(13, 110, 253, 0.08);
}

body.dle_theme_dark .hab-reactions__stack-item.is-active {
	border-color: rgba(100, 160, 255, 0.45);
	background: rgba(60, 90, 140, 0.35);
	box-shadow: 0 0 0 1px rgba(100, 160, 255, 0.25);
}

.hab-reactions__stack-emoji {
	font-size: 15px;
	line-height: 1;
	pointer-events: none;
}

.hab-reactions__stack-count {
	font-size: 13px;
	font-weight: 600;
	color: #343a40;
	letter-spacing: -0.02em;
	pointer-events: none;
	white-space: nowrap;
}

body.dle_theme_dark .hab-reactions__stack-count {
	color: #e9ecef;
}

.hab-reactions__stack-item.is-active .hab-reactions__stack-count {
	color: #0d47a1;
}

body.dle_theme_dark .hab-reactions__stack-item.is-active .hab-reactions__stack-count {
	color: #e7f1ff;
}

.hab-reactions__total {
	font-size: 13px;
	font-weight: 600;
	color: #495057;
	min-width: 0.5em;
	letter-spacing: -0.02em;
}

body.dle_theme_dark .hab-reactions__total {
	color: #adb5bd;
}

.hab-reactions__more {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	padding: 0;
	border: 1px solid var(--bs-bg-offcanvas);
	border-radius: 50%;
	background: var(--bs-bg-offcanvas);
	color: #6c757d;
	cursor: pointer;
	flex-shrink: 0;
	box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.04);
}

.hab-reactions__more:hover {
	color: var(--bs-body-color);
	border-color: var(--bs-bg-offcanvas);
	background: var(--bs-bg-offcanvas);
}

body.dle_theme_dark .hab-reactions__more {
	background: #2b3036;
	border-color: rgba(255, 255, 255, 0.15);
	color: #adb5bd;
}

body.dle_theme_dark .hab-reactions__more:hover {
	color: #e9ecef;
	border-color: rgba(255, 255, 255, 0.25);
}

.hab-reactions__picker {
	position: absolute;
	left: 0;
	z-index: 50;
	margin-top: 8px;
	padding: 8px;
	border-radius: 12px;
	background: var(--bs-card-color);
	box-shadow: 0 10px 30px rgba(0, 0, 0, 84%);
}

body.dle_theme_dark .hab-reactions__picker {
	background: #1f2328;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

.hab-reactions__grid {
	display: grid;
	grid-template-columns: repeat(6, minmax(0, 1fr));
	gap: 6px;
}

.hab-reaction--picker {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	justify-content: center;
	min-width: 38px;
	padding: 6px 8px;
	border-radius: 999px;
	border: 1px solid var(--bs-bg-offcanvas);
	background: var(--bs-bg-offcanvas);
	line-height: 1;
	cursor: pointer;
	box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.04);
}

body.dle_theme_dark .hab-reaction--picker {
	border-color: rgba(255, 255, 255, 0.12);
	background: rgba(255, 255, 255, 0.06);
}

.hab-reaction--picker.is-active {
	border-color: rgba(13, 110, 253, 0.35);
	background: rgba(13, 110, 253, 0.08);
}

.hab-reaction__emoji {
	font-size: 16px;
}

.hab-reaction__count {
	font-size: 12px;
	color: #6c757d;
}
