/**
 * Story Actions V2 - Simplified action bar styles
 *
 * @package Noxora
 */

.ns-story-reader .ns-story-actions {
	position: fixed;
	left: 50%;
	bottom: calc(4.25rem + env(safe-area-inset-bottom, 0px));
	transform: translateX(-50%);
	z-index: 65;
	width: min(100% - 1rem, 520px);
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
	overflow: visible;
}

.ns-story-actions__label {
	font-size: 0.72rem;
}

.ns-story-actions__type-mark {
	font-weight: 700;
	font-size: 0.85rem;
}

.ns-story-actions__type-wrap {
	position: relative;
	overflow: visible;
}

.ns-story-actions__reaction-wrap {
	position: relative;
	overflow: visible;
	flex: 1 1 0;
	min-width: 0;
}

.ns-story-actions__reaction-panel {
	position: absolute;
	bottom: calc(100% + 0.5rem);
	left: 50%;
	transform: translateX(-50%);
	display: flex;
	gap: 0.35rem;
	padding: 0.5rem;
	border-radius: 12px;
	background: rgba(12, 12, 16, 0.96);
	border: 1px solid rgba(255, 255, 255, 0.1);
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
	z-index: 85;
}

.ns-story-actions__reaction-panel[hidden] {
	display: none !important;
}

.ns-story-actions__reaction-panel button {
	flex: 0 0 auto;
	min-width: 2.25rem;
	padding: 0.4rem;
	font-size: 1.1rem;
	line-height: 1;
}

.ns-story-actions__type-panel {
	position: absolute;
	bottom: calc(100% + 0.5rem);
	right: 0;
	min-width: 160px;
	padding: 0.65rem;
	border-radius: 10px;
	background: rgba(12, 12, 16, 0.96);
	border: 1px solid rgba(255, 255, 255, 0.1);
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
	z-index: 80;
}

.ns-story-actions__type-panel[hidden] {
	display: none !important;
}

.ns-story-actions__type-title {
	display: block;
	margin-bottom: 0.5rem;
	font-size: 0.75rem;
	color: var(--nx-muted, #9a9a9a);
}

.ns-story-actions__type-controls {
	display: flex;
	gap: 0.35rem;
}

.ns-story-actions__type-controls button {
	flex: 1;
	padding: 0.35rem;
	font-size: 0.8rem;
}

[data-story-actions] {
	display: flex;
	align-items: center;
	gap: 0.45rem;
	padding: 0.55rem 0.65rem;
	background: var(--nx-surface, rgba(18, 18, 18, 0.8));
	border: 1px solid var(--nx-border, rgba(255, 255, 255, 0.08));
	border-radius: 12px;
	overflow: visible;
}

[data-story-actions] button {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 0.15rem;
	flex: 1 1 0;
	min-width: 0;
	padding: 0.45rem 0.25rem;
	border: 1px solid var(--nx-border, rgba(255, 255, 255, 0.08));
	border-radius: 8px;
	background: rgba(0, 0, 0, 0.3);
	color: var(--nx-text, #f5f5f5);
	font-size: 0.75rem;
	cursor: pointer;
	transition: all 0.2s ease;
}

[data-story-actions] button:hover {
	background: rgba(255, 255, 255, 0.05);
	border-color: var(--nx-accent, #e10600);
}

[data-story-actions] button.is-active {
	background: var(--nx-accent-soft, rgba(225, 6, 0, 0.18));
	border-color: var(--nx-accent, #e10600);
	color: var(--nx-accent, #e10600);
}

[data-story-actions] button svg {
	width: 20px;
	height: 20px;
	flex-shrink: 0;
}

[data-story-actions] [data-story-count] {
	font-size: 0.85rem;
	color: var(--nx-muted, #9a9a9a);
	font-weight: 500;
}

[data-story-actions] button.is-active [data-story-count] {
	color: var(--nx-accent, #e10600);
}

/* Reaction panel (legacy selector kept) */
[data-story-reaction-panel] {
	display: flex;
	gap: 0.5rem;
	padding: 0.5rem;
	background: rgba(0, 0, 0, 0.5);
	border-radius: 8px;
}

[data-story-reaction-panel] button {
	padding: 0.5rem;
	font-size: 1.25rem;
	border: none;
	background: transparent;
}

[data-story-reaction-panel] button:hover {
	background: rgba(255, 255, 255, 0.05);
}

[data-story-reaction-panel] button.is-active {
	background: var(--nx-accent-soft, rgba(225, 6, 0, 0.18));
}

/* Responsive */
@media (max-width: 768px) {
	[data-story-actions] {
		flex-wrap: nowrap;
		gap: 0.35rem;
		padding: 0.5rem 0.45rem;
	}

	.ns-story-actions__label {
		display: none;
	}

	[data-story-actions] button {
		flex: 1 1 0;
		min-width: 0;
		justify-content: center;
		padding: 0.4rem 0.2rem;
		font-size: 0.7rem;
	}

	.ns-story-actions__type-mark {
		font-size: 0.8rem;
	}

	[data-story-actions] button svg {
		width: 18px;
		height: 18px;
	}
}
