/**
 * WPMediaVerse — Frontend Styles
 *
 * Base styles for templates, shortcodes, and unstyled blocks.
 * Mobile-first. RTL-ready via [dir="rtl"] overrides.
 * Dark mode via BuddyNext [data-theme="dark"] token cascade.
 *
 * @package WPMediaVerse
 */

/* ==========================================================================
   0. Design Tokens
   ========================================================================== */

:root {
	/* Typography — BuddyNext first, then system stack fallback */
	--mvs-font:           var(--font-body, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif);
	--mvs-font-heading:   var(--font-display, var(--mvs-font));

	/* Brand — BuddyNext first, then hardcoded fallback */
	--mvs-primary:        var(--brand, #0073aa);
	--mvs-primary-hover:  var(--brand-hover, #005a87);
	--mvs-primary-rgb:    0, 115, 170;
	--mvs-danger:         var(--red, #d63638);
	--mvs-success:        var(--green, #44b700);

	/* Surfaces — BuddyNext first, then hardcoded fallback */
	--mvs-bg:             var(--bg, #ffffff);
	--mvs-surface:        var(--bg-subtle, #f6f7f7);
	--mvs-surface-2:      var(--bg-hover, #eeeeee);
	--mvs-overlay:        rgba(0, 0, 0, 0.72);

	/* Text — BuddyNext first, then hardcoded fallback */
	--mvs-text:           var(--text-1, #1e1e1e);
	--mvs-text-secondary: var(--text-2, #646970);
	--mvs-text-muted:     var(--text-3, #a7aaad);

	/* Borders & Shadows — BuddyNext first where applicable */
	--mvs-border:         var(--border, #dcdcde);
	--mvs-border-light:   var(--border-soft, #e9e9ea);
	--mvs-shadow-sm:      0 1px 3px rgba(0, 0, 0, 0.10);
	--mvs-shadow-md:      0 4px 16px rgba(0, 0, 0, 0.14);
	--mvs-shadow-lg:      0 8px 32px rgba(0, 0, 0, 0.18);

	/* Radii — BuddyNext first, then hardcoded fallback */
	--mvs-radius-sm:      var(--r-sm, 6px);
	--mvs-radius-md:      var(--r-md, 8px);
	--mvs-radius-lg:      var(--r-lg, 12px);
	--mvs-radius-pill:    var(--r-full, 100px);

	/* Breakpoints (reference only — used in @media rules) */
	--mvs-bp-mobile:      480px;
	--mvs-bp-tablet:      768px;
	--mvs-bp-desktop:     1024px;
}

/* Dark mode: two layers.
   Dark mode is ONLY controlled by the WordPress theme via [data-theme="dark"]
   attribute on <html>. We do NOT use OS prefers-color-scheme because the theme
   must explicitly enable dark mode — we can't assume the user wants it. */
[data-theme="dark"] {
	--mvs-bg:             #121212;
	--mvs-surface:        #1e1e1e;
	--mvs-surface-2:      #2a2a2a;
	--mvs-text:           #f0f0f0;
	--mvs-text-secondary: #b0b0b0;
	--mvs-text-muted:     #888888;
	--mvs-border:         #363636;
	--mvs-border-light:   #2e2e2e;
	--mvs-shadow-sm:      0 1px 3px rgba(0, 0, 0, 0.35);
	--mvs-shadow-md:      0 4px 16px rgba(0, 0, 0, 0.45);
	--mvs-shadow-lg:      0 8px 32px rgba(0, 0, 0, 0.55);
}

/* ==========================================================================
   0a. Type Reset — lock down all typography inside MVS templates.
       Follows BuddyNext type scale. Works with or without BuddyNext.
   ========================================================================== */

/* Scope: all MVS template wrappers use these classes.
   font-family set here so BuddyNext's Inter/Plus Jakarta Sans carries through. */
.mvs-single-media,
.mvs-single-album,
.mvs-single-collection,
.mvs-explore,
.mvs-dashboard,
.mvs-profile-edit {
	font-family: var(--mvs-font);
	font-size: 0.9375rem;
	line-height: 1.6;
	color: var(--mvs-text);
}

/* Heading reset within any MVS template — uses display font for headings */
.mvs-single-media h1, .mvs-single-album h1, .mvs-single-collection h1,
.mvs-explore h1, .mvs-dashboard h1, .mvs-profile-edit h1 { font-family: var(--mvs-font-heading); font-size: 1.375rem; font-weight: 700; line-height: 1.3; margin: 0 0 0.5em; }

.mvs-single-media h2, .mvs-single-album h2, .mvs-single-collection h2,
.mvs-explore h2, .mvs-dashboard h2, .mvs-profile-edit h2 { font-family: var(--mvs-font-heading); font-size: 1.25rem; font-weight: 700; line-height: 1.3; margin: 0 0 0.5em; }

.mvs-single-media h3, .mvs-single-album h3, .mvs-single-collection h3,
.mvs-explore h3, .mvs-dashboard h3, .mvs-profile-edit h3 { font-family: var(--mvs-font-heading); font-size: 1.125rem; font-weight: 600; line-height: 1.35; margin: 0 0 0.5em; }

.mvs-single-media h4, .mvs-single-album h4, .mvs-single-collection h4,
.mvs-explore h4, .mvs-dashboard h4, .mvs-profile-edit h4 { font-size: 0.875rem; font-weight: 600; margin: 0 0 0.5em; }

/* Form elements inherit font from wrapper */
.mvs-single-media button, .mvs-single-media input, .mvs-single-media select, .mvs-single-media textarea,
.mvs-dashboard button, .mvs-dashboard input, .mvs-dashboard select, .mvs-dashboard textarea,
.mvs-profile-edit button, .mvs-profile-edit input, .mvs-profile-edit select, .mvs-profile-edit textarea { font-family: inherit; font-size: inherit; }

/* ==========================================================================
   0b. Profile Header Card (explore grid filtered by user)
   ========================================================================== */

.mvs-profile-header-card {
	display: flex;
	align-items: flex-start;
	gap: 32px;
	padding: 32px;
	margin-bottom: 24px;
	background: #fff;
	border-radius: 12px;
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

.mvs-profile-header-avatar {
	width: 120px;
	height: 120px;
	border-radius: 50%;
	object-fit: cover;
	flex-shrink: 0;
	border: 3px solid #f0f0f0;
}

.mvs-profile-header-info {
	flex: 1;
	min-width: 0;
}

.mvs-profile-header-top {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-bottom: 12px;
	flex-wrap: wrap;
}

.mvs-profile-header-name {
	margin: 0;
	font-size: 1.5rem;
	font-weight: 700;
}

.mvs-follow-toggle {
	cursor: pointer;
	transition: background 0.15s, color 0.15s;
}

.mvs-follow-toggle--following {
	background: #f0f0f0;
	color: #1e1e1e;
	border: 1px solid #ddd;
}

.mvs-follow-toggle--following:hover {
	background: #fde8e8;
	color: #d63638;
	border-color: #f5c6c6;
}

.mvs-follow-toggle:disabled {
	opacity: 0.6;
	cursor: wait;
}

.mvs-message-btn {
	transition: background 0.15s;
}

.mvs-profile-header-stats {
	display: flex;
	gap: 28px;
	font-size: 0.9375rem;
	color: var(--mvs-text-secondary);
	margin-bottom: 12px;
}

.mvs-profile-header-stats span {
	display: flex;
	align-items: baseline;
	gap: 4px;
}

.mvs-profile-header-stats strong {
	color: var(--mvs-text);
	font-size: 1.125rem;
	font-weight: 700;
}

.mvs-profile-header-bio {
	margin: 0;
	color: var(--mvs-text);
	font-size: 0.9rem;
	line-height: 1.6;
	max-width: 600px;
}

@media (max-width: 640px) {
	.mvs-profile-header-card {
		flex-direction: column;
		align-items: center;
		text-align: center;
		gap: 16px;
		padding: 24px 16px;
	}

	.mvs-profile-header-avatar {
		width: 96px;
		height: 96px;
	}

	.mvs-profile-header-top {
		justify-content: center;
	}

	.mvs-profile-header-stats {
		justify-content: center;
	}

	.mvs-profile-header-bio {
		max-width: 100%;
	}
}

/* ==========================================================================
   1. Single Media Template
   ========================================================================== */

.mvs-single-media {
	max-width: 680px;
	margin: 0 auto;
	padding: 20px 16px;
}

.mvs-media-article {
	background: var(--mvs-bg);
	border-radius: 8px;
	overflow: hidden;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.mvs-media-header {
	padding: 16px 24px;
}

.mvs-media-header-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 12px;
}

.mvs-media-author-info {
	display: flex;
	align-items: center;
	gap: 10px;
	min-width: 0;
}

.mvs-media-author-avatar {
	width: 40px;
	height: 40px;
	border-radius: 50%;
	object-fit: cover;
	flex-shrink: 0;
}

.mvs-media-author-text {
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.mvs-media-author-name {
	font-weight: 600;
	font-size: 0.9375rem;
	color: #1a1a1a;
	text-decoration: none;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.mvs-media-author-name:hover {
	color: var(--mvs-primary);
}

.mvs-media-date {
	font-size: 0.8125rem;
	color: #8e8e8e;
}

.mvs-media-sep {
	margin: 0 2px;
}

.mvs-media-title {
	margin: 0;
	font-size: 1.5em;
	line-height: 1.3;
}

/* Media Content */
.mvs-media-content {
	padding: 0;
}

.mvs-media-image {
	width: 100%;
	background: #f0f0f0;
}

.mvs-media-image img {
	display: block;
	width: 100%;
	height: auto;
}

.mvs-media-video {
	width: 100%;
	background: #000;
}

.mvs-media-video video {
	display: block;
	width: 100%;
	height: auto;
}

.mvs-media-audio {
	padding: 16px 24px;
}

.mvs-media-audio audio {
	width: 100%;
}

.mvs-media-description {
	padding: 12px 16px 0;
	line-height: 1.6;
	color: #262626;
	font-size: 0.9375rem;
}

.mvs-media-description p:first-child {
	margin-top: 0;
}

/* Footer & Tags */
.mvs-media-footer {
	padding: 8px 16px 16px;
}

.mvs-media-tags {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
}

.mvs-tag {
	display: inline-block;
	padding: 4px 12px;
	background: #eff7ff;
	border-radius: 16px;
	font-size: 0.8125rem;
	color: var(--mvs-primary);
	text-decoration: none;
	transition: all 0.2s;
}

.mvs-tag:hover {
	background: var(--mvs-primary);
	color: var(--mvs-bg);
}

/* ==========================================================================
   2. Album Template
   ========================================================================== */

.mvs-single-album {
	max-width: 1200px;
	margin: 0 auto;
	padding: 20px;
}

.mvs-album-article {
	background: var(--mvs-bg);
	border-radius: 8px;
	overflow: hidden;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
	padding: 24px;
}

.mvs-album-header {
	margin-bottom: 24px;
}

.mvs-album-title {
	margin: 0 0 8px;
	font-size: 1.75em;
}

.mvs-album-description {
	color: #555;
	margin-bottom: 12px;
	line-height: 1.6;
}

.mvs-album-count {
	display: inline-block;
	padding: 4px 12px;
	background: #f0f0f0;
	border-radius: 16px;
	font-size: 0.85em;
	color: var(--mvs-text-secondary);
}

/* ==========================================================================
   3. Explore / Archive Template
   ========================================================================== */

.mvs-explore-page {
	max-width: 1200px;
	margin: 0 auto;
	padding: 20px;
	width: 100%;
}

.mvs-explore-header {
	margin-bottom: 24px;
}

.mvs-explore-header h1 {
	margin: 0;
	font-size: 1.75em;
}

/* ==========================================================================
   4. Media Grid (shared by explore, album, shortcodes)
   ========================================================================== */

.mvs-media-grid {
	display: grid;
	gap: 16px;
	max-width: 100%;
	overflow: hidden;
	box-sizing: border-box;
}

.mvs-cols-2 {
	grid-template-columns: repeat(2, 1fr);
}

.mvs-cols-3 {
	grid-template-columns: repeat(3, 1fr);
}

.mvs-cols-4 {
	grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 768px) {
	.mvs-cols-3,
	.mvs-cols-4 {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 480px) {
	.mvs-cols-2,
	.mvs-cols-3,
	.mvs-cols-4 {
		grid-template-columns: 1fr;
	}
}

.mvs-grid-item {
	position: relative;
	overflow: hidden;
	border-radius: 8px;
	background: #f5f5f5;
	aspect-ratio: 1;
	min-width: 0;
}

.mvs-grid-item a {
	display: block;
	width: 100%;
	height: 100%;
}

.mvs-grid-item img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.3s;
}

.mvs-grid-item:hover img {
	transform: scale(1.05);
}

.mvs-grid-item-placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	color: #999;
}

.mvs-grid-item-placeholder .dashicons {
	font-size: 48px;
	width: 48px;
	height: 48px;
}

.mvs-grid-item-overlay {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, 0.4);
	color: var(--mvs-bg);
	font-size: 0.9em;
	opacity: 0;
	transition: opacity 0.3s;
}

.mvs-grid-item:hover .mvs-grid-item-overlay,
.mvs-grid-item-link:hover .mvs-grid-item-overlay {
	opacity: 1;
}

.mvs-grid-item-stats {
	display: flex;
	gap: 16px;
	font-size: 1.1em;
	font-weight: 700;
}

.mvs-grid-stat {
	display: flex;
	align-items: center;
	gap: 4px;
}

.mvs-grid-item-title {
	display: block;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* Instagram-like feed: author row below each card */
.mvs-feed {
	gap: 6px;
}

.mvs-feed .mvs-grid-item {
	aspect-ratio: auto;
	border-radius: 4px;
	overflow: hidden;
	background: var(--mvs-bg);
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.mvs-feed .mvs-grid-item-link {
	display: block;
	aspect-ratio: 1;
	overflow: hidden;
	position: relative;
}

.mvs-feed .mvs-grid-item-overlay {
	pointer-events: none;
}

.mvs-grid-item-info {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 8px 10px;
	background: var(--mvs-bg);
	font-size: 0.85em;
}

.mvs-grid-avatar {
	border-radius: 50%;
	width: 24px !important;
	height: 24px !important;
}

.mvs-grid-item-author {
	font-weight: 600;
	color: #262626;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* -- Album badge (carousel indicator) in feed */
.mvs-album-badge {
	position: absolute;
	top: 8px;
	right: 8px;
	display: flex;
	align-items: center;
	gap: 2px;
	background: rgba(0, 0, 0, 0.6);
	color: var(--mvs-bg);
	padding: 4px 8px;
	border-radius: 4px;
	font-size: 0.8em;
	font-weight: 600;
	pointer-events: none;
	z-index: 2;
}

.mvs-album-badge .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
	color: var(--mvs-bg);
}

/* -- Gallery badge (multi-image group indicator) */
.mvs-gallery-badge {
	position: absolute;
	top: 8px;
	right: 8px;
	display: flex;
	align-items: center;
	gap: 2px;
	background: rgba(0, 0, 0, 0.6);
	color: #fff;
	padding: 4px 8px;
	border-radius: 4px;
	font-size: 0.8em;
	font-weight: 600;
	pointer-events: none;
	z-index: 2;
}

.mvs-gallery-badge .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
	color: #fff;
}

/* ==========================================================================
   5. Pagination
   ========================================================================== */

.mvs-pagination {
	margin-top: 32px;
	text-align: center;
}

.mvs-pagination .nav-links {
	display: flex;
	justify-content: center;
	gap: 8px;
	flex-wrap: wrap;
}

.mvs-pagination .page-numbers {
	display: inline-block;
	padding: 8px 14px;
	background: #f0f0f0;
	border-radius: 4px;
	text-decoration: none;
	color: #333;
	font-size: 0.9em;
	transition: background 0.2s;
}

.mvs-pagination .page-numbers.current,
.mvs-pagination .page-numbers:hover {
	background: var(--mvs-primary);
	color: var(--mvs-bg);
}

/* ==========================================================================
   6. Empty State
   ========================================================================== */

.mvs-no-media {
	text-align: center;
	padding: 48px 24px;
	color: #999;
	font-size: 1.1em;
}

/* ==========================================================================
   9. Story Viewer
   ========================================================================== */

.mvs-story-viewer {
	position: relative;
	max-width: 400px;
	margin: 0 auto;
	background: #000;
	border-radius: 12px;
	overflow: hidden;
	aspect-ratio: 9/16;
}

.mvs-story-viewer img,
.mvs-story-viewer video {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.mvs-story-progress {
	display: flex;
	gap: 4px;
	padding: 8px 12px;
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	z-index: 2;
}

.mvs-story-progress-bar {
	flex: 1;
	height: 3px;
	background: rgba(255, 255, 255, 0.4);
	border-radius: 2px;
	overflow: hidden;
}

.mvs-story-progress-fill {
	height: 100%;
	background: var(--mvs-bg);
	width: 0;
	transition: width linear;
}

.mvs-story-header {
	position: absolute;
	top: 24px;
	left: 12px;
	right: 12px;
	z-index: 2;
	display: flex;
	align-items: center;
	gap: 8px;
	color: var(--mvs-bg);
	text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.mvs-story-nav {
	position: absolute;
	top: 0;
	bottom: 0;
	width: 50%;
	z-index: 1;
	cursor: pointer;
	background: none;
	border: none;
}

.mvs-story-nav--prev {
	left: 0;
}

.mvs-story-nav--next {
	right: 0;
}

/* ==========================================================================
   10. Stats Cards
   ========================================================================== */

.mvs-stats-cards {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
	gap: 16px;
}

.mvs-stat-card {
	background: var(--mvs-bg);
	border-radius: 8px;
	padding: 20px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
	text-align: center;
}

.mvs-stat-value {
	display: block;
	font-size: 2em;
	font-weight: 700;
	color: var(--mvs-primary);
	line-height: 1.2;
}

.mvs-stat-label {
	display: block;
	margin-top: 4px;
	font-size: 0.9em;
	color: var(--mvs-text-secondary);
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

/* ==========================================================================
   11. Lock Overlay (Paywall)
   ========================================================================== */

.mvs-lock-overlay {
	position: relative;
	border-radius: 8px;
	overflow: hidden;
}

.mvs-lock-preview {
	filter: blur(8px);
	pointer-events: none;
}

.mvs-lock-prompt {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	text-align: center;
	background: rgba(255, 255, 255, 0.95);
	padding: 32px 40px;
	border-radius: 12px;
	box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
	z-index: 2;
	max-width: 360px;
	width: 90%;
}

.mvs-lock-icon {
	font-size: 36px;
	color: var(--mvs-primary);
	margin-bottom: 12px;
}

.mvs-lock-title {
	font-size: 1.2em;
	font-weight: 600;
	margin-bottom: 8px;
}

.mvs-lock-message {
	color: var(--mvs-text-secondary);
	font-size: 0.9em;
	margin-bottom: 16px;
	line-height: 1.5;
}

.mvs-lock-button {
	display: inline-block;
	padding: 10px 24px;
	background: var(--mvs-primary);
	color: var(--mvs-bg);
	border: none;
	border-radius: 6px;
	font-size: 1em;
	cursor: pointer;
	text-decoration: none;
	transition: background 0.2s;
}

.mvs-lock-button:hover {
	background: var(--mvs-primary-hover);
	color: var(--mvs-bg);
}

/* ==========================================================================
   12. Social Interactions Bar (for Step 47d)
   ========================================================================== */

.mvs-social-bar {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px 12px;
	padding: 12px 24px;
	border-top: 1px solid #eee;
}

.mvs-reactions {
	display: flex;
	align-items: center;
	gap: 6px;
	flex-wrap: wrap;
}

.mvs-social-bar button {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 12px;
	background: none;
	border: 1px solid #ddd;
	border-radius: 20px;
	cursor: pointer;
	font-size: 0.9em;
	color: #555;
	transition: all 0.2s;
}

.mvs-social-bar button:hover {
	border-color: var(--mvs-primary);
	color: var(--mvs-primary);
}

.mvs-social-bar button.active {
	background: var(--mvs-primary);
	border-color: var(--mvs-primary);
	color: var(--mvs-bg);
}

.mvs-social-bar .mvs-count {
	font-weight: 600;
}

.mvs-social-bar button.mvs-view-count {
	color: #999;
	font-size: 0.85em;
}

.mvs-social-actions {
	display: flex;
	align-items: center;
	padding: 8px 24px 12px;
}

.mvs-social-actions-left {
	display: flex;
	align-items: center;
	gap: 8px;
}

.mvs-social-actions .mvs-view-count {
	flex: 1;
	text-align: center;
}

.mvs-social-actions-right {
	display: flex;
	align-items: center;
	gap: 6px;
}

.mvs-social-actions button {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 12px;
	background: none;
	border: 1px solid #ddd;
	border-radius: 20px;
	cursor: pointer;
	font-size: 0.9em;
	color: #555;
	transition: all 0.2s;
}

.mvs-social-actions button:hover {
	border-color: var(--mvs-primary);
	color: var(--mvs-primary);
}

.mvs-social-actions button.active {
	background: var(--mvs-primary);
	border-color: var(--mvs-primary);
	color: var(--mvs-bg);
}

/* ==========================================================================
   13. Comments Section (for Step 47d)
   ========================================================================== */

.mvs-comments-section {
	padding: 12px 16px 16px;
	border-top: 1px solid #efefef;
}

.mvs-comments-title {
	font-size: 0.9375rem;
	font-weight: 600;
	margin: 0 0 12px;
	color: #262626;
}

.mvs-comment-form {
	display: flex;
	gap: 8px;
	margin-bottom: 16px;
}

.mvs-comment-form textarea {
	flex: 1;
	padding: 10px 12px;
	border: 1px solid #dbdbdb;
	border-radius: 8px;
	resize: none;
	min-height: 40px;
	font-family: inherit;
	font-size: 0.875rem;
}

.mvs-comment-form button {
	padding: 10px 16px;
	background: var(--mvs-primary);
	color: var(--mvs-bg);
	border: none;
	border-radius: 6px;
	cursor: pointer;
	font-size: 0.9em;
	align-self: flex-end;
	transition: background 0.2s;
}

.mvs-comment-form button:hover {
	background: var(--mvs-primary-hover);
}

.mvs-comment-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.mvs-comment-item {
	padding: 12px 0;
	border-bottom: 1px solid #f0f0f0;
}

.mvs-comment-item:last-child {
	border-bottom: none;
}

.mvs-comment-author-link {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	text-decoration: none;
	color: inherit;
}
.mvs-comment-author-link:hover .mvs-comment-author { text-decoration: underline; }

.mvs-comment-author {
	font-weight: 600;
	font-size: 0.9em;
}

.mvs-comment-date {
	font-size: 0.8em;
	color: #999;
	margin-left: 8px;
}

.mvs-comment-text {
	margin-top: 4px;
	font-size: 0.9em;
	line-height: 1.5;
	color: #333;
}

/* ==========================================================================
   14. Dashboard
   ========================================================================== */

.mvs-dashboard {
	max-width: 1200px;
	margin: 0 auto;
	padding: 20px;
}

.mvs-dashboard-header h1 {
	margin: 0 0 20px;
	font-size: 1.75em;
}

.mvs-dashboard-tabs {
	display: flex;
	gap: 0;
	border-bottom: 2px solid #eee;
	margin-bottom: 24px;
}

.mvs-dashboard-tab {
	padding: 12px 24px;
	background: none;
	border: none;
	border-bottom: 2px solid transparent;
	margin-bottom: -2px;
	cursor: pointer;
	font-size: 0.95em;
	font-weight: 600;
	color: var(--mvs-text-secondary);
	transition: all 0.2s;
}

.mvs-dashboard-tab:hover,
.mvs-dashboard-tab:focus {
	color: var(--mvs-primary);
	background: none;
	border: none;
	border-bottom: 2px solid var(--mvs-primary);
	border-radius: 0;
}

.mvs-dashboard-tab:first-child {
	padding-left: 0;
}

.mvs-dashboard-tab.active {
	color: var(--mvs-primary);
	border-bottom-color: var(--mvs-primary);
}

.mvs-dashboard-panel {
	min-height: 200px;
}

/* Interactivity API uses [hidden] attribute for show/hide */
.mvs-dashboard-panel[hidden] {
	display: none !important;
}

.mvs-dashboard-actions {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 20px;
}

.mvs-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 10px 20px;
	background: var(--mvs-primary);
	color: var(--mvs-bg);
	border: none;
	border-radius: 6px;
	font-size: 0.9em;
	cursor: pointer;
	transition: background 0.2s;
}

.mvs-btn:hover {
	background: var(--mvs-primary-hover);
}

.mvs-btn--secondary {
	background: #f0f0f0;
	color: #333;
}

.mvs-btn--secondary:hover {
	background: var(--mvs-border);
}

.mvs-btn--danger {
	background: #dc3545;
}

.mvs-btn--danger:hover {
	background: #c82333;
}

.mvs-btn--small {
	padding: 6px 12px;
	font-size: 0.8em;
}

/* Dashboard Grid */
.mvs-dashboard-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
	gap: 16px;
}

.mvs-dashboard-card {
	position: relative;
	display: flex;
	flex-direction: column;
	background: var(--mvs-bg);
	border-radius: 8px;
	overflow: hidden;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
	transition: box-shadow 0.2s;
}

.mvs-dashboard-card:hover {
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.mvs-dashboard-card-thumb {
	display: block;
	aspect-ratio: 1;
	background: #f5f5f5;
	overflow: hidden;
	text-decoration: none;
	color: inherit;
}

.mvs-dashboard-card-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.mvs-dashboard-card-body {
	padding: 12px;
	flex: 1;
	display: flex;
	flex-direction: column;
}

.mvs-dashboard-card-title {
	display: block;
	font-weight: 600;
	font-size: 0.9em;
	margin: 0 0 6px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	color: #262626;
	text-decoration: none;
}

a.mvs-dashboard-card-title:hover {
	color: var(--mvs-primary);
}

.mvs-dashboard-card-meta {
	font-size: 0.8em;
	color: #999;
	margin-bottom: 8px;
}

.mvs-dashboard-card-actions {
	display: flex;
	gap: 6px;
	margin-top: auto;
	padding-top: 8px;
}

.mvs-privacy-badge {
	display: inline-block;
	padding: 2px 8px;
	border-radius: 10px;
	font-size: 0.7em;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.mvs-privacy-badge--public {
	background: #e8f5e9;
	color: #2e7d32;
}

.mvs-privacy-badge--members {
	background: #fff3e0;
	color: #e65100;
}

.mvs-privacy-badge--private {
	background: #fce4ec;
	color: #c62828;
}

/* Load More */
.mvs-load-more-wrap {
	text-align: center;
	margin-top: 24px;
}

/* ==========================================================================
   15. Modal
   ========================================================================== */

.mvs-modal-overlay {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.6);
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
}

.mvs-modal {
	background: var(--mvs-bg);
	border-radius: 12px;
	width: 100%;
	max-width: 560px;
	max-height: 85vh;
	overflow-y: auto;
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.mvs-modal-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 20px 24px;
	border-bottom: 1px solid #eee;
}

.mvs-modal-header h2 {
	margin: 0;
	font-size: 1.2em;
}

.mvs-modal-close {
	background: none;
	border: none;
	font-size: 1.5em;
	cursor: pointer;
	color: #999;
	padding: 0;
	line-height: 1;
}

.mvs-modal-close:hover {
	background: none;
	border: none;
	color: #333;
}

.mvs-modal-body {
	padding: 24px;
}

.mvs-modal-footer {
	display: flex;
	justify-content: flex-end;
	gap: 8px;
	padding: 16px 24px;
	border-top: 1px solid #eee;
}

/* Form Fields */
.mvs-field {
	margin-bottom: 16px;
}

.mvs-field label {
	display: block;
	margin-bottom: 4px;
	font-weight: 600;
	font-size: 0.9em;
	color: #333;
}

.mvs-field input[type="text"],
.mvs-field textarea,
.mvs-field select {
	width: 100%;
	padding: 8px 12px;
	border: 1px solid #ddd;
	border-radius: 6px;
	font-size: 0.9em;
	font-family: inherit;
	box-sizing: border-box;
}

.mvs-field textarea {
	resize: vertical;
	min-height: 80px;
}

.mvs-field select {
	max-width: 200px;
}

/* ==========================================================================
   16. Tag Input
   ========================================================================== */

.mvs-tag-input-wrap {
	position: relative;
}

.mvs-tag-pills {
	display: flex;
	flex-wrap: wrap;
	gap: 4px;
	padding: 6px;
	border: 1px solid #ddd;
	border-radius: 6px;
	min-height: 38px;
	align-items: center;
	cursor: text;
}

.mvs-tag-pill {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	padding: 2px 8px;
	background: var(--mvs-primary);
	color: var(--mvs-bg);
	border-radius: 12px;
	font-size: 0.8em;
}

.mvs-tag-pill-remove {
	background: none;
	border: none;
	color: var(--mvs-bg);
	cursor: pointer;
	font-size: 1em;
	padding: 0;
	line-height: 1;
	opacity: 0.8;
}

.mvs-tag-pill-remove:hover {
	opacity: 1;
}

.mvs-tag-text-input {
	border: none !important;
	outline: none;
	padding: 2px 4px !important;
	font-size: 0.9em;
	min-width: 80px;
	flex: 1;
}

.mvs-tag-autocomplete {
	position: absolute;
	top: 100%;
	left: 0;
	right: 0;
	background: var(--mvs-bg);
	border: 1px solid #ddd;
	border-top: none;
	border-radius: 0 0 6px 6px;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
	z-index: 10;
	max-height: 160px;
	overflow-y: auto;
}

.mvs-tag-autocomplete-item {
	padding: 8px 12px;
	cursor: pointer;
	font-size: 0.9em;
}

.mvs-tag-autocomplete-item:hover {
	background: #f0f7fc;
	color: var(--mvs-primary);
}

/* ==========================================================================
   17. Confirm Dialog
   ========================================================================== */

.mvs-confirm-overlay {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.5);
	z-index: 100001;
	display: flex;
	align-items: center;
	justify-content: center;
}

.mvs-confirm {
	background: var(--mvs-bg);
	border-radius: 12px;
	padding: 28px;
	max-width: 380px;
	width: 90%;
	text-align: center;
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.mvs-confirm p {
	margin: 0 0 20px;
	font-size: 1em;
	color: #333;
}

.mvs-confirm-actions {
	display: flex;
	justify-content: center;
	gap: 8px;
}

/* ==========================================================================
   18. Toast Notification
   ========================================================================== */

.mvs-toast {
	position: fixed;
	bottom: 24px;
	right: 24px;
	padding: 12px 24px;
	background: #333;
	color: var(--mvs-bg);
	border-radius: 8px;
	font-size: 0.9em;
	z-index: 100002;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
	animation: mvsToastIn 0.3s ease;
}

.mvs-toast--success {
	background: #2e7d32;
}

.mvs-toast--error {
	background: #c62828;
}

@keyframes mvsToastIn {
	from {
		opacity: 0;
		transform: translateY(20px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* ==========================================================================
   Interactivity API [hidden] overrides
   Elements with display:flex/fixed need explicit [hidden] rules because
   data-wp-bind--hidden toggles the HTML hidden attribute.
   ========================================================================== */

.mvs-modal-overlay[hidden],
.mvs-confirm-overlay[hidden],
.mvs-toast[hidden],
.mvs-inline-edit[hidden],
.mvs-dashboard-upload-fields[hidden],
.mvs-dashboard-upload-status[hidden],
.mvs-tag-autocomplete[hidden],
.mvs-load-more-wrap[hidden],
.mvs-no-media[hidden] {
	display: none !important;
}

/* ==========================================================================
   19. Media Picker (for album creation)
   ========================================================================== */

.mvs-media-picker {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
	gap: 8px;
	max-height: 300px;
	overflow-y: auto;
	padding: 8px;
	border: 1px solid #eee;
	border-radius: 6px;
	margin-top: 8px;
}

.mvs-media-picker-item {
	position: relative;
	aspect-ratio: 1;
	border-radius: 4px;
	overflow: hidden;
	cursor: pointer;
	border: 2px solid transparent;
	transition: border-color 0.2s;
}

.mvs-media-picker-item.selected {
	border-color: var(--mvs-primary);
}

.mvs-media-picker-item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.mvs-media-picker-check {
	position: absolute;
	top: 4px;
	right: 4px;
	width: 22px;
	height: 22px;
	background: var(--mvs-primary);
	color: var(--mvs-bg);
	border-radius: 50%;
	display: none;
	align-items: center;
	justify-content: center;
	font-size: 0.75em;
	font-weight: 700;
}

.mvs-media-picker-item.selected .mvs-media-picker-check {
	display: flex;
}

/* ==========================================================================
   20. Owner Actions (on single pages)
   ========================================================================== */

.mvs-owner-actions {
	display: inline-flex;
	gap: 6px;
}

.mvs-collection-card-info .mvs-owner-actions {
	display: flex;
	margin-left: 0;
	padding: 12px 0 0;
}

/* Inline edit form on single pages */
.mvs-inline-edit {
	padding: 16px 24px;
	border-top: 1px solid #eee;
	background: #fafafa;
}

.mvs-inline-edit .mvs-field {
	margin-bottom: 12px;
}

.mvs-inline-edit-actions {
	display: flex;
	gap: 8px;
	margin-top: 12px;
}

/* ==========================================================================
   21. Explore Search + Tag Cloud
   ========================================================================== */

.mvs-explore-search {
	margin-bottom: 24px;
}

.mvs-tag-cloud {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 24px;
}

.mvs-tag-cloud-item {
	display: inline-block;
	padding: 4px 14px;
	background: #f0f0f0;
	border-radius: 16px;
	font-size: 0.85em;
	color: #333;
	text-decoration: none;
	transition: background 0.2s, color 0.2s;
}

.mvs-tag-cloud-item:hover,
.mvs-tag-cloud-item.active {
	background: var(--mvs-primary);
	color: var(--mvs-bg);
}

/* ==========================================================================
   22. Upload Form Enhancement
   ========================================================================== */

.mvs-upload-fields {
	margin-top: 16px;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.mvs-upload-fields input[type="text"],
.mvs-upload-fields textarea {
	width: 100%;
	padding: 8px 12px;
	border: 1px solid #ddd;
	border-radius: 6px;
	font-size: 0.9em;
	font-family: inherit;
	box-sizing: border-box;
}

.mvs-upload-fields textarea {
	resize: vertical;
	min-height: 60px;
}

/* ==========================================================================
   23. Dashboard Inline Upload
   ========================================================================== */

.mvs-dashboard-upload {
	margin-bottom: 24px;
	background: var(--mvs-bg, #fff);
	border: 1px solid var(--mvs-border, #dcdcde);
	border-radius: 12px;
	padding: 20px;
}

.mvs-dashboard-dropzone {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	margin: 0 0 1rem;
	padding: 28px 20px;
	border: 2px dashed #d0d5dd;
	border-radius: 8px;
	cursor: pointer;
	transition: border-color 0.2s, background 0.2s;
	background: #fafbfc;
}

.mvs-dashboard-dropzone:hover {
	border-color: var(--mvs-primary);
	background: #f0f7fc;
}

.mvs-dashboard-dropzone.mvs-drag-active {
	border-color: var(--mvs-primary);
	background: #e6f2fa;
	border-style: solid;
}

.mvs-dashboard-dropzone-icon {
	font-size: 1.5em;
	line-height: 1;
}

.mvs-dashboard-dropzone-label {
	font-size: 0.95em;
	color: #555;
}

.mvs-dashboard-upload-fields {
	display: flex;
	flex-direction: column;
	gap: 10px;
	margin-top: 12px;
	padding: 12px;
	background: #f9fafb;
	border-radius: 6px;
}

.mvs-dashboard-upload-fields input[type="text"],
.mvs-dashboard-upload-fields textarea,
.mvs-dashboard-upload-fields select {
	width: 100%;
	padding: 8px 12px;
	border: 1px solid #ddd;
	border-radius: 6px;
	font-size: 0.9em;
	font-family: inherit;
	box-sizing: border-box;
}

.mvs-dashboard-upload-fields textarea {
	resize: vertical;
	min-height: 60px;
}

.mvs-dashboard-upload-row {
	display: flex;
	gap: 10px;
}

.mvs-dashboard-upload-row input {
	flex: 1;
}

.mvs-dashboard-upload-row select {
	max-width: 160px;
}

.mvs-dashboard-upload-status {
	margin-top: 12px;
	font-size: 0.9em;
	color: var(--mvs-primary);
	font-weight: 600;
}

.mvs-dashboard-upload-status:empty {
	display: none;
}

@media (max-width: 600px) {
	.mvs-dashboard-dropzone {
		flex-direction: column;
		padding: 20px;
	}
	.mvs-dashboard-upload-row {
		flex-direction: column;
	}
	.mvs-dashboard-upload-row select {
		max-width: 100%;
	}
}

/* ==========================================================================
   15. Empty State (shared)
   ========================================================================== */

.mvs-empty-state {
	text-align: center;
	padding: 48px 24px;
	color: var(--mvs-text-secondary);
}

.mvs-empty-state .dashicons {
	font-size: 48px;
	width: 48px;
	height: 48px;
	color: #ccc;
	display: block;
	margin: 0 auto 12px;
}

.mvs-empty-state p {
	font-size: 1em;
	margin: 8px 0 0;
	color: #999;
}

/* ==========================================================================
   16. BuddyPress Profile Media Tab
   ========================================================================== */

.mvs-bp-profile-actions {
	display: flex;
	gap: 10px;
	margin-bottom: 20px;
	flex-wrap: wrap;
}

.mvs-bp-profile-actions .mvs-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.mvs-bp-profile-actions .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
	line-height: 1;
}

/* BP inline upload dropzone */
.mvs-bp-upload-wrap {
	margin-bottom: 20px;
}

.mvs-bp-dropzone {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 16px 20px;
	border: 2px dashed #ccc;
	border-radius: 8px;
	cursor: pointer;
	transition: border-color 0.2s, background 0.2s;
	background: #fafafa;
}

.mvs-bp-dropzone:hover,
.mvs-bp-dropzone--active {
	border-color: var(--mvs-primary);
	background: #f0f7fc;
}

.mvs-bp-dropzone .dashicons {
	font-size: 24px;
	width: 24px;
	height: 24px;
	color: var(--mvs-primary);
}

.mvs-bp-dropzone-text {
	font-size: 0.9em;
	color: var(--mvs-text-secondary);
}

.mvs-bp-upload-status {
	padding: 10px 16px;
	margin-top: 8px;
	border-radius: 6px;
	background: #f0f6fc;
	color: var(--mvs-primary);
	font-size: 0.9em;
}

.mvs-bp-upload-status--success {
	background: #e6f7e6;
	color: #00a32a;
}

/* ==========================================================================
   24. BuddyPress Activity Media
   ========================================================================== */

/* Thumbnail in activity stream items — single image */
/* Constrain ALL images in BP activity content — covers both MVS-wrapped
   and raw images uploaded via the activity form. */
#buddypress .activity-content img:not(.avatar):not(.emoji),
.activity-list .activity-content img:not(.avatar):not(.emoji) {
	max-width: 100%;
	max-height: 600px;
	width: auto;
	height: auto;
	object-fit: contain;
	border-radius: 12px;
	display: block;
	margin: 8px 0;
}

.mvs-activity-media {
	position: relative;
	overflow: hidden;
	margin-top: 10px;
	max-height: 600px;
	border-radius: 12px;
}

.mvs-activity-media a {
	display: block;
	height: 100%;
}

.mvs-activity-media img {
	width: 100%;
	height: 100%;
	max-height: 600px;
	object-fit: cover;
	display: block;
	border-radius: 12px;
}

/* Multi-image grid in activity stream (Facebook-style) */
/* ── Facebook/Instagram-style multi-image grid ── */
.mvs-activity-media-grid {
	display: grid;
	gap: 3px;
	margin-top: 10px;
	border-radius: 10px;
	overflow: hidden;
}

.mvs-activity-media-grid .mvs-activity-media {
	margin-top: 0;
	overflow: hidden;
	position: relative;
	background: #f0f2f5;
}

.mvs-activity-media-grid .mvs-activity-media a {
	display: block;
	width: 100%;
	height: 100%;
}

.mvs-activity-media-grid .mvs-activity-media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: 0;
	display: block;
}

/* "+N more" overlay on last cell */
.mvs-activity-media-more {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.55);
	color: var(--mvs-bg);
	font-size: 32px;
	font-weight: 600;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	letter-spacing: -0.5px;
}

/* ── Grid layouts ── */

/* 2 images: side by side */
/* Single item: same 600px cap, cover-crop tall images */
.mvs-activity-grid-1 .mvs-activity-media {
	background: transparent;
	max-height: 600px;
}

.mvs-activity-grid-1 .mvs-activity-media img {
	width: 100%;
	max-height: 600px;
	object-fit: cover;
	border-radius: 10px;
}

.mvs-activity-grid-2 {
	grid-template-columns: 1fr 1fr;
	grid-template-rows: 280px;
}

/* 3 images: 1 big left + 2 stacked right */
.mvs-activity-grid-3 {
	grid-template-columns: 3fr 2fr;
	grid-template-rows: 175px 175px;
}
.mvs-activity-grid-3 .mvs-activity-media:first-child {
	grid-row: 1 / 3;
}

/* 4 images: 1 big top + 3 bottom */
.mvs-activity-grid-4 {
	grid-template-columns: 1fr 1fr 1fr;
	grid-template-rows: 280px 160px;
}
.mvs-activity-grid-4 .mvs-activity-media:first-child {
	grid-column: 1 / 4;
}

/* Activity stream media images — single image (not in grid) */
.activity-content a[href*="/media/"] img:not(.emoji):not(.avatar) {
	max-width: 100%;
	max-height: 500px;
	width: auto;
	height: auto;
	border-radius: 12px;
	display: block;
	object-fit: contain;
	margin: 8px 0;
}

/* Override: grid images use cover fill */
.mvs-activity-media-grid .mvs-activity-media a[href*="/media/"] img:not(.emoji):not(.avatar) {
	width: 100%;
	height: 100%;
	max-height: none;
	object-fit: cover;
	border-radius: 0;
	margin: 0;
}

.mvs-activity-comment-text {
	margin-top: 8px;
	font-size: 0.95em;
	color: #333;
	line-height: 1.5;
}

/* Activity form media attachment button */
.mvs-activity-media-btn-wrap {
	display: block;
	padding: 0;
	width: 100%;
	clear: both;
}

.mvs-activity-media-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 14px;
	background: #f7f8fa;
	border: 1px solid #ddd;
	border-radius: 20px;
	cursor: pointer;
	color: #555;
	font-size: 13px;
	font-weight: 500;
	transition: all 0.2s;
}

.mvs-activity-media-btn:hover {
	border-color: #0095f6;
	color: #0095f6;
	background: #f0f7ff;
}

.mvs-activity-media-btn .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
}

/* Preview grid in activity form — see section 29 for primary styles */
.mvs-activity-media-thumb {
	width: 110px;
	height: 110px;
	border-radius: 8px;
	display: block;
	object-fit: cover;
}

.mvs-preview-audio,
.mvs-preview-video {
	display: flex;
	align-items: center;
	justify-content: center;
	color: var(--mvs-bg);
	border-radius: 8px;
	width: 100%;
	height: 100%;
}

.mvs-preview-audio {
	background: linear-gradient(135deg, #6c3483, #1a1a2e);
}

.mvs-preview-video {
	background: linear-gradient(135deg, #1a5276, #1a1a2e);
}

/* Make all thumb types fill the preview cell */
.mvs-preview-item .mvs-activity-media-thumb {
	width: 100%;
	height: 100%;
	border-radius: 0;
}

.mvs-activity-media-uploading {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	color: #0095f6;
	font-size: 13px;
	font-weight: 600;
	padding: 8px 0;
}

.mvs-activity-media-uploading::before {
	content: "";
	width: 16px;
	height: 16px;
	border: 2px solid #0095f6;
	border-top-color: transparent;
	border-radius: 50%;
	animation: mvs-spin 0.8s linear infinite;
	display: inline-block;
}

@keyframes mvs-spin {
	to { transform: rotate(360deg); }
}

.mvs-activity-media-error {
	color: #d63638;
	font-size: 13px;
}

/* ── 25. Activity Media Lightbox ── */

/* Left: Image panel — takes remaining space */
/* Prev / Next navigation arrows */
/* Right: Social panel — Facebook/X style wide sidebar */
/* Reactions bar */
/* Action buttons */
/* Comments section — fills remaining space */
/* Comment form — pinned to bottom */
/* Responsive: stack on mobile */
@media (max-width: 900px) {
	}

/* ── 26. BP Profile — Inline Album Creation ── */
.mvs-bp-album-form {
	margin: 16px 0;
	padding: 20px;
	background: var(--mvs-bg);
	border: 1px solid #ddd;
	border-radius: 8px;
}

.mvs-bp-album-form-inner label {
	display: block;
	font-weight: 600;
	font-size: 14px;
	margin-bottom: 4px;
	color: #1d2327;
}

.mvs-bp-album-form-inner input[type="text"],
.mvs-bp-album-form-inner textarea {
	width: 100%;
	padding: 8px 12px;
	border: 1px solid #ccc;
	border-radius: 6px;
	font-size: 14px;
	margin-bottom: 12px;
	box-sizing: border-box;
}

.mvs-bp-album-form-inner input[type="text"]:focus,
.mvs-bp-album-form-inner textarea:focus {
	border-color: #2271b1;
	outline: none;
	box-shadow: 0 0 0 1px #2271b1;
}

.mvs-bp-album-form-actions {
	display: flex;
	gap: 8px;
	align-items: center;
}

.mvs-btn-primary {
	background: #2271b1;
	color: var(--mvs-bg);
	border: none;
	padding: 8px 20px;
	border-radius: 6px;
	font-size: 14px;
	cursor: pointer;
	font-weight: 600;
}

.mvs-btn-primary:hover {
	background: #135e96;
}

.mvs-btn-primary:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

.mvs-btn-secondary {
	background: #f0f0f0;
	color: #50575e;
	border: 1px solid #ccc;
	padding: 8px 20px;
	border-radius: 6px;
	font-size: 14px;
	cursor: pointer;
}

.mvs-btn-secondary:hover {
	background: #e0e0e0;
}

.mvs-bp-album-msg {
	margin-top: 8px;
	font-size: 13px;
}

.mvs-bp-album-msg-error {
	color: #d63638;
}

/* ── 27. BP Profile — Inline Upload ── */
.mvs-bp-upload-wrap {
	margin: 16px 0;
	padding: 20px;
	background: var(--mvs-bg);
	border: 1px solid #ddd;
	border-radius: 8px;
}

.mvs-bp-upload-preview {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 12px;
}

.mvs-bp-upload-thumb {
	width: 80px;
	text-align: center;
}

.mvs-bp-upload-thumb img {
	width: 80px;
	height: 80px;
	object-fit: cover;
	border-radius: 6px;
	border: 1px solid #ddd;
}

.mvs-bp-upload-thumb-name {
	display: block;
	font-size: 11px;
	color: var(--mvs-text-secondary);
	margin-top: 4px;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.mvs-bp-upload-form-actions {
	margin-top: 12px;
}

.mvs-bp-upload-status {
	margin-top: 10px;
	padding: 8px 12px;
	border-radius: 6px;
	font-size: 13px;
	background: #f0f6fc;
	color: #2271b1;
}

.mvs-bp-upload-status--success {
	background: #edfaef;
	color: #00a32a;
}

/* ── 28. BP Profile — Single Album View ── */
.mvs-bp-back-link {
	margin-bottom: 16px;
}

.mvs-bp-back-link a {
	color: #2271b1;
	text-decoration: none;
	font-size: 14px;
}

.mvs-bp-back-link a:hover {
	text-decoration: underline;
}

.mvs-album-upload-section {
	margin: 16px 0;
}

/* ==========================================================================
   26. Group Media Sub-Tabs
   ========================================================================== */

.mvs-bp-sub-tabs {
	display: flex;
	border-bottom: 2px solid #e0e0e0;
	margin-bottom: 20px;
	gap: 0;
}

.mvs-bp-sub-tab {
	padding: 10px 20px;
	text-decoration: none;
	color: var(--mvs-text-secondary);
	border-bottom: 2px solid transparent;
	margin-bottom: -2px;
	font-weight: 500;
	font-size: 14px;
	transition: color 0.2s, border-color 0.2s;
}

.mvs-bp-sub-tab:hover {
	color: #1e1e1e;
	text-decoration: none;
}

.mvs-bp-sub-tab.active {
	color: #1e1e1e;
	border-bottom-color: #2271b1;
}

/* ==========================================================================
   27. Activity Media Thumbnails (Video/Audio)
   ========================================================================== */

.mvs-activity-media--video {
	position: relative;
}

.mvs-activity-media--video a {
	position: relative;
	display: block;
}

.mvs-activity-play-icon {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: 56px;
	height: 56px;
	background: rgba(0, 0, 0, 0.6);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 24px;
	color: var(--mvs-bg);
	z-index: 2;
	transition: background 0.2s;
	pointer-events: none;
}

.mvs-activity-play-icon::before {
	content: '\25B6';
	font-style: normal;
}

/* Full-coverage link for video thumbnail cards */
.mvs-activity-vid-link {
	width: 100%;
	height: 100%;
	position: relative;
}

.mvs-activity-media--video a:hover .mvs-activity-play-icon {
	background: rgba(0, 0, 0, 0.8);
}

.mvs-activity-media--placeholder,
.mvs-activity-media-grid .mvs-activity-media.mvs-activity-media--placeholder {
	background: linear-gradient(135deg, #0d2137, #0a0a0a);
	border-radius: 8px;
	aspect-ratio: 16 / 9;
}

.mvs-activity-media--audio,
.mvs-activity-media-grid .mvs-activity-media.mvs-activity-media--audio {
	background: linear-gradient(135deg, #4a1272, #1a0a2e);
}

.mvs-activity-media--placeholder a,
.mvs-activity-media--placeholder .mvs-activity-vid-link,
.mvs-activity-media-grid .mvs-activity-media--placeholder a,
.mvs-activity-media-grid .mvs-activity-media--placeholder .mvs-activity-vid-link {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 12px;
	text-decoration: none;
	color: #ccc;
	padding: 32px;
	width: 100%;
	height: 100%;
	box-sizing: border-box;
}

.mvs-activity-media--placeholder .mvs-activity-play-icon {
	position: static;
	transform: none;
}

.mvs-activity-media-label {
	font-size: 0.9em;
	max-width: 200px;
	text-align: center;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.mvs-activity-media--audio {
	background: linear-gradient(135deg, #4a1272, #1a0a2e);
	border-radius: 12px;
	overflow: hidden;
}

.mvs-activity-media--audio a {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 16px 20px;
	text-decoration: none;
	color: #fff;
}

.mvs-activity-audio-icon {
	width: 48px;
	height: 48px;
	background: rgba(255, 255, 255, 0.15);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 22px;
	color: #fff;
	flex-shrink: 0;
}

.mvs-activity-audio-info {
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}

.mvs-activity-audio-title {
	font-weight: 600;
	font-size: 0.95em;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.mvs-activity-audio-meta {
	font-size: 0.82em;
	color: #888;
}

/* ==========================================================================
   28. Enhanced Single Media Player
   ========================================================================== */

.mvs-media-video video {
	display: block;
	width: 100%;
	height: auto;
	border-radius: 4px;
}

.mvs-audio-info {
	padding: 12px 24px 0;
	display: flex;
	gap: 8px;
	align-items: center;
	font-size: 0.9em;
	color: var(--mvs-text-secondary);
}

.mvs-audio-artist {
	font-weight: 600;
	color: #333;
}

.mvs-audio-album::before {
	content: "\00b7";
	margin: 0 4px;
}

.mvs-media-audio audio {
	display: block;
	width: 100%;
	margin-top: 8px;
}

/* ==========================================================================
   29. Album Grid Items (Video/Audio)
   ========================================================================== */

.mvs-grid-item {
	position: relative;
}

.mvs-grid-item a {
	display: block;
	position: relative;
	text-decoration: none;
	color: inherit;
}

.mvs-grid-play-icon {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: 44px;
	height: 44px;
	background: rgba(0, 0, 0, 0.55);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 18px;
	color: var(--mvs-bg);
	z-index: 2;
	pointer-events: none;
	transition: background 0.2s;
}

.mvs-grid-item a:hover .mvs-grid-play-icon {
	background: rgba(0, 0, 0, 0.8);
}

.mvs-grid-item-placeholder--video {
	background: linear-gradient(135deg, #0d2137, #0a0a0a);
	aspect-ratio: 16 / 9;
	display: flex;
	align-items: center;
	justify-content: center;
}

.mvs-grid-item-placeholder--audio {
	background: linear-gradient(135deg, #4a1272, #1a0a2e);
	aspect-ratio: 1;
	display: flex;
	align-items: center;
	justify-content: center;
}

.mvs-grid-audio-icon {
	font-size: 36px;
	color: rgba(255, 255, 255, 0.8);
}

/* ==========================================================================
   30. Playlist UI
   ========================================================================== */

.mvs-playlist {
	max-width: 700px;
	margin: 20px auto;
	background: #fafafa;
	border: 1px solid #e0e0e0;
	border-radius: 8px;
	overflow: hidden;
}

.mvs-playlist-player {
	padding: 16px 20px;
	background: #1a1a1a;
}

.mvs-playlist-player audio {
	width: 100%;
}

.mvs-playlist-now-playing {
	padding: 10px 20px;
	background: var(--mvs-text);
	color: var(--mvs-bg);
	font-size: 0.95em;
	font-weight: 600;
	min-height: 20px;
}

.mvs-playlist-tracks {
	list-style: none;
	margin: 0;
	padding: 0;
}

.mvs-playlist-track {
	display: flex;
	align-items: center;
	border-bottom: 1px solid #e8e8e8;
	transition: background 0.15s;
}

.mvs-playlist-track:last-child {
	border-bottom: none;
}

.mvs-playlist-track:hover {
	background: #f0f0f0;
}

.mvs-playlist-track--active {
	background: #e8f4fc;
}

.mvs-playlist-track--active:hover {
	background: #dbeefa;
}

.mvs-playlist-track-btn {
	flex: 1;
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 16px;
	background: none;
	border: none;
	cursor: pointer;
	text-align: left;
	font: inherit;
	color: inherit;
	min-width: 0;
}

.mvs-playlist-track-num {
	width: 28px;
	text-align: center;
	color: #888;
	font-size: 0.85em;
	flex-shrink: 0;
}

.mvs-playlist-track--active .mvs-playlist-track-num {
	color: var(--mvs-primary);
	font-weight: 700;
}

.mvs-playlist-track-info {
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}

.mvs-playlist-track-title {
	font-weight: 500;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.mvs-playlist-track-artist {
	font-size: 0.82em;
	color: #888;
}

.mvs-playlist-track-duration {
	color: #888;
	font-size: 0.85em;
	flex-shrink: 0;
}

.mvs-playlist-track-link {
	padding: 12px 14px;
	color: #888;
	text-decoration: none;
	font-size: 1.1em;
}

.mvs-playlist-track-link:hover {
	color: var(--mvs-primary);
}

/* ==========================================================================
   27. Collections & Rule Builder
   ========================================================================== */

.mvs-collection-card-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 10px 14px;
	background: #f8f9fa;
	border-bottom: 1px solid #eee;
}

/* --- Collection Single Page --- */

.mvs-single-collection {
	max-width: 1200px;
	margin: 0 auto;
	padding: 24px 16px 0;
}

/* Info Card */
.mvs-collection-card-info {
	background: var(--mvs-bg);
	border: 1px solid #e5e7eb;
	border-radius: 12px;
	padding: 24px 28px;
	margin-bottom: 24px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.mvs-collection-card-title {
	margin: 0 0 12px;
	font-size: 1.6em;
	font-weight: 700;
	line-height: 1.3;
	color: #111827;
}

.mvs-collection-card-meta {
	display: flex;
	align-items: center;
	gap: 14px;
	flex-wrap: wrap;
	font-size: 0.9em;
	color: #6b7280;
}

.mvs-collection-meta-author {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.mvs-collection-meta-author a {
	color: #dc2626;
	text-decoration: none;
	font-weight: 500;
}

.mvs-collection-meta-author a:hover {
	text-decoration: underline;
}

.mvs-collection-avatar {
	border-radius: 50%;
	width: 24px;
	height: 24px;
}

.mvs-collection-meta-text {
	color: #6b7280;
}

.mvs-collection-card-desc {
	margin-top: 14px;
	padding-top: 14px;
	border-top: 1px solid #f3f4f6;
	color: #4b5563;
	font-size: 0.95em;
	line-height: 1.6;
}

.mvs-collection-card-desc p {
	margin: 0;
}

/* Search bar — reuses .mvs-explore-search layout */
.mvs-collection-search {
	margin-bottom: 24px;
}

.mvs-collection-search form {
	display: flex;
	gap: 0;
}

.mvs-collection-search-input {
	flex: 1;
	padding: 10px 16px;
	border: 1px solid #e5e7eb;
	border-radius: 8px 0 0 8px;
	font-size: 0.95em;
	background: var(--mvs-bg);
	transition: border-color 0.2s;
}

.mvs-collection-search-input:focus {
	outline: none;
	border-color: #3b82f6;
	box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.mvs-collection-search-btn {
	padding: 10px 20px;
	border: 1px solid #3b82f6;
	border-left: 0;
	border-radius: 0 8px 8px 0;
	background: #3b82f6;
	color: var(--mvs-bg);
	font-size: 0.95em;
	font-weight: 500;
	cursor: pointer;
	transition: background 0.2s;
}

.mvs-collection-search-btn:hover {
	background: #2563eb;
}

/* Rules display (inline in meta) */
.mvs-collection-card-meta .mvs-rule-pill {
	padding: 3px 10px;
	border-radius: 16px;
	font-size: 0.85em;
	background: #f3f4f6;
	color: #374151;
	font-weight: 500;
}

.mvs-collection-type-badge {
	display: inline-block;
	padding: 2px 8px;
	border-radius: 10px;
	font-size: 0.75em;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	background: #e8f0fe;
	color: #1a73e8;
}

.mvs-collection-count {
	font-size: 0.85em;
	color: var(--mvs-text-secondary);
}

.mvs-collection-rules-preview {
	display: flex;
	flex-wrap: wrap;
	gap: 4px;
	margin-top: 6px;
}

.mvs-rule-pill {
	display: inline-block;
	padding: 2px 8px;
	border-radius: 4px;
	font-size: 0.75em;
	background: #f0f0f0;
	color: #555;
}

/* Type toggle */
.mvs-collection-type-toggle {
	display: flex;
	gap: 0;
	border: 1px solid #ddd;
	border-radius: 6px;
	overflow: hidden;
	width: fit-content;
}

.mvs-toggle-btn {
	padding: 8px 20px;
	border: none;
	background: var(--mvs-bg);
	cursor: pointer;
	font-size: 0.9em;
	color: #555;
	transition: background 0.15s, color 0.15s;
}

.mvs-toggle-btn:not(:last-child) {
	border-right: 1px solid #ddd;
}

.mvs-toggle-btn.active {
	background: var(--mvs-primary);
	color: var(--mvs-bg);
}

.mvs-field-hint {
	margin-top: 6px;
	font-size: 0.85em;
	color: #888;
	font-style: italic;
}

/* Rule builder */
.mvs-rules-builder {
	margin-top: 16px;
}

.mvs-rules-builder > label {
	display: block;
	font-weight: 600;
	margin-bottom: 10px;
}

.mvs-rules-list {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-bottom: 12px;
}

.mvs-rule-row {
	display: flex;
	gap: 8px;
	align-items: center;
}

.mvs-rule-row select,
.mvs-rule-row input {
	padding: 8px 10px;
	border: 1px solid #ddd;
	border-radius: 4px;
	font-size: 0.9em;
}

.mvs-rule-key {
	min-width: 140px;
	flex: 0 0 auto;
}

.mvs-rule-value,
.mvs-rule-value-text {
	flex: 1;
	min-width: 120px;
}

.mvs-rule-remove {
	flex: 0 0 auto;
	width: 32px;
	height: 32px;
	border: 1px solid #ddd;
	border-radius: 4px;
	background: var(--mvs-bg);
	color: #cc0000;
	font-size: 1.2em;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.15s;
}

.mvs-rule-remove:hover,
.mvs-rule-remove:focus {
	background: #fee;
	color: #cc0000;
	border-color: #cc0000;
}

.mvs-rules-preview {
	margin-top: 12px;
	padding: 10px 14px;
	background: #e8f5e9;
	border-radius: 6px;
	font-size: 0.9em;
	color: #2e7d32;
	font-weight: 500;
}

/* Wide modal variant for collection rule builder */
.mvs-modal--wide {
	max-width: 680px;
}

@media (max-width: 600px) {
	.mvs-rule-row {
		flex-wrap: wrap;
	}
	.mvs-rule-key {
		min-width: 100%;
	}
}

/* ==========================================================================
   27. Theme Compatibility — Reign / BuddyBoss / Generic
   ========================================================================== */

/* Reign theme: upload button alignment in BP activity and profile */
.theme-flavor .mvs-bp-upload-btn,
.theme-flavor .mvs-upload-dropzone,
.theme-flavor .mvs-upload-block {
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0 auto;
}

.theme-flavor #mvs-activity-media-btn,
.theme-flavor .mvs-bp-upload-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin: 8px 0;
	vertical-align: middle;
}

/* Reign BP activity form: align the photo/video button with text area */
@media screen and (min-width: 46.8em) {
    .wb-reign-theme #whats-new-form #mvs-activity-media-btn {
        margin-left: 65px;
    }
}

/* Reign BP profile/group media grids */
.theme-flavor /* BuddyBoss theme compatibility */
.buddyboss-theme .mvs-upload-dropzone,
.buddyboss-theme .mvs-upload-block {
	display: flex;
	align-items: center;
	justify-content: center;
}

.buddyboss-theme #mvs-activity-media-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

/* Generic: ensure upload button never overflows on narrow containers */
.mvs-bp-upload-btn,
#mvs-activity-media-btn {
	max-width: 100%;
	box-sizing: border-box;
}

/* ==========================================================================
   26. Album Placeholder
   ========================================================================== */

.mvs-grid-item-placeholder--album {
	background: linear-gradient(135deg, #6c757d, #495057);
	aspect-ratio: 1;
	display: flex;
	align-items: center;
	justify-content: center;
}

.mvs-grid-album-icon {
	font-size: 36px;
	opacity: 0.8;
}

.mvs-grid-item-placeholder--collection {
	background: linear-gradient(135deg, #4a90d9, #357abd);
	aspect-ratio: 1;
	display: flex;
	align-items: center;
	justify-content: center;
}

.mvs-grid-collection-icon {
	font-size: 36px;
	opacity: 0.8;
}

.mvs-collection-card .mvs-collection-type-badge {
	position: absolute;
	top: 8px;
	right: 8px;
	background: rgba(0, 0, 0, 0.6);
	color: var(--mvs-bg);
	padding: 2px 8px;
	border-radius: 4px;
	font-size: 11px;
	text-transform: uppercase;
}

.mvs-collection-card .mvs-dashboard-card-thumb {
	position: relative;
}

.mvs-collection-card .mvs-dashboard-card-meta {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.mvs-collection-card .mvs-collection-rules-preview {
	max-height: 52px;
	overflow: hidden;
}

/* ==========================================================================
   27. Notification Bell
   ========================================================================== */

.mvs-dashboard-header {
	display: flex;
	align-items: center;
	gap: 16px;
}

.mvs-dashboard-heading {
	font-size: 1.4em;
	font-weight: 700;
}

.mvs-notification-bell {
	position: relative;
	cursor: pointer;
	margin-left: auto;
	user-select: none;
}

.mvs-notification-bell-icon {
	font-size: 1.4em;
}

.mvs-notification-badge {
	position: absolute;
	top: -6px;
	right: -8px;
	background: #d63638;
	color: var(--mvs-bg);
	font-size: 11px;
	font-weight: 700;
	min-width: 18px;
	height: 18px;
	line-height: 18px;
	text-align: center;
	border-radius: 9px;
	padding: 0 4px;
}

.mvs-notification-dropdown {
	position: absolute;
	top: 100%;
	right: 0;
	width: 340px;
	max-height: 400px;
	overflow-y: auto;
	background: var(--mvs-bg, #fff);
	border: 1px solid var(--mvs-border, #ddd);
	border-radius: 8px;
	box-shadow: var(--mvs-shadow-lg, 0 8px 32px rgba(0, 0, 0, 0.18));
	z-index: 9999;
	margin-top: 8px;
}

.mvs-notification-dropdown-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 12px 16px;
	border-bottom: 1px solid #eee;
}

.mvs-notification-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.mvs-notification-item {
	padding: 10px 16px;
	border-bottom: 1px solid #f0f0f0;
	font-size: 0.9em;
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.mvs-notification-item:last-child {
	border-bottom: none;
}

.mvs-notification-unread {
	background: #f0f7ff;
}

.mvs-notification-time {
	color: #999;
	font-size: 0.8em;
}

.mvs-notification-empty {
	padding: 20px 16px;
	text-align: center;
	color: #999;
	margin: 0;
}

/* ==========================================================================
   28. Comment Edit/Delete Actions
   ========================================================================== */

.mvs-comment-header {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 4px;
}

.mvs-comment-avatar {
	width: 32px;
	height: 32px;
	border-radius: 50%;
	object-fit: cover;
	flex-shrink: 0;
}

.mvs-comment-actions {
	display: flex;
	gap: 6px;
	margin-top: 6px;
}

.mvs-comment-edit-form {
	margin-top: 6px;
}

.mvs-comment-edit-textarea {
	width: 100%;
	padding: 8px;
	border: 1px solid #ddd;
	border-radius: 4px;
	font-size: 0.9em;
	resize: vertical;
	box-sizing: border-box;
}

.mvs-comment-edit-actions {
	display: flex;
	gap: 6px;
	margin-top: 6px;
}

/* ==========================================================================
   29. Follow Button
   ========================================================================== */

.mvs-follow-btn-wrap {
	display: inline-flex;
	align-items: center;
	flex-shrink: 0;
}

.mvs-follow-btn {
	border-radius: 8px;
	padding: 6px 16px;
	font-size: 0.8125rem;
	font-weight: 600;
	transition: all 0.2s;
	background: #0095f6;
	color: var(--mvs-bg);
	border: 1px solid #0095f6;
}

.mvs-follow-btn:hover {
	background: #1877f2;
	border-color: #1877f2;
}

.mvs-follow-btn.active {
	background: var(--mvs-bg);
	color: #333;
	border-color: var(--mvs-border);
}

.mvs-follow-btn.active:hover {
	background: #fafafa;
	border-color: var(--mvs-border);
}

/* ==========================================================================
   30. Album Cover Picker
   ========================================================================== */

.mvs-media-picker-item {
	position: relative;
}

.mvs-media-picker-cover-btn {
	position: absolute;
	bottom: 4px;
	left: 4px;
	background: rgba(0, 0, 0, 0.7);
	color: var(--mvs-bg);
	border: none;
	border-radius: 4px;
	padding: 2px 8px;
	font-size: 11px;
	cursor: pointer;
	opacity: 0;
	transition: opacity 0.2s;
	z-index: 3;
}

.mvs-media-picker-item:hover .mvs-media-picker-cover-btn {
	opacity: 1;
}

.mvs-media-picker-cover-badge {
	position: absolute;
	top: 4px;
	left: 4px;
	background: var(--mvs-primary);
	color: var(--mvs-bg);
	border-radius: 4px;
	padding: 2px 8px;
	font-size: 11px;
	font-weight: 700;
	z-index: 3;
}

.mvs-media-picker-cover {
	outline: 3px solid #0073aa;
	outline-offset: -3px;
}

/* ==========================================================================
   27. Grid Pagination
   ========================================================================== */

.mvs-grid-pagination {
	margin-top: 24px;
	text-align: center;
}

.mvs-grid-pagination-info {
	display: block;
	margin-bottom: 12px;
	font-size: 13px;
	color: var(--mvs-text-secondary);
}

.mvs-grid-pagination-links ul {
	display: flex;
	justify-content: center;
	gap: 4px;
	list-style: none;
	margin: 0;
	padding: 0;
	flex-wrap: wrap;
}

.mvs-grid-pagination-links li {
	margin: 0;
}

.mvs-grid-pagination-links a,
.mvs-grid-pagination-links span {
	display: inline-block;
	padding: 8px 14px;
	border: 1px solid #ddd;
	border-radius: 4px;
	text-decoration: none;
	font-size: 13px;
	color: #333;
	background: var(--mvs-bg);
	transition: all 0.15s;
}

.mvs-grid-pagination-links a:hover {
	background: #f0f0f0;
	border-color: #bbb;
}

.mvs-grid-pagination-links .current {
	background: #2271b1;
	color: var(--mvs-bg);
	border-color: #2271b1;
	font-weight: 600;
}

.mvs-grid-pagination-links .dots {
	border-color: transparent;
	background: transparent;
}

/* ==========================================================================
   28. Upload Form Fixes
   ========================================================================== */

.mvs-upload-block {
	max-width: 680px;
	margin: 0 auto;
}

.mvs-upload-dropzone {
	border: 2px dashed #c3c4c7;
	border-radius: 8px;
	padding: 40px 20px;
	text-align: center;
	cursor: pointer;
	transition: all 0.2s;
	background: #fafafa;
}

.mvs-upload-dropzone:hover,
.mvs-upload-dropzone.mvs-dragover {
	border-color: #2271b1;
	background: #f0f6fc;
}

.mvs-upload-icon {
	color: #999;
	margin-bottom: 12px;
}

.mvs-upload-text {
	margin: 0 0 16px;
	font-size: 14px;
	color: var(--mvs-text-secondary);
}

.mvs-upload-input {
	display: none;
}

.mvs-upload-privacy {
	margin-top: 12px;
	padding: 6px 12px;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	font-size: 13px;
}

.mvs-upload-fields {
	margin-top: 16px;
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.mvs-upload-fields input,
.mvs-upload-fields textarea {
	width: 100%;
	padding: 8px 12px;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	font-size: 13px;
}

/* ==========================================================================
   29. BP Activity Media Button Alignment
   ========================================================================== */

#mvs-activity-media-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 14px;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	background: var(--mvs-bg);
	color: var(--mvs-text);
	cursor: pointer;
	font-size: 13px;
	line-height: 1.4;
	vertical-align: middle;
	margin: 4px 0;
	transition: all 0.15s;
}

#mvs-activity-media-btn:hover {
	background: #f0f0f0;
	color: var(--mvs-text);
	border-color: #999;
}

#mvs-activity-media-btn .dashicons {
	font-size: 18px;
	width: 18px;
	height: 18px;
	line-height: 18px;
}

/* Activity form: media preview grid */
.mvs-activity-media-preview {
	display: flex;
	flex-wrap: nowrap;
	gap: 8px;
	margin-top: 12px;
	padding: 10px;
	background: #f8f9fa;
	border: 1px solid #e0e0e0;
	border-radius: 8px;
	overflow-x: auto;
	max-width: 100%;
}

/* Single image: show larger preview */
.mvs-activity-media-preview.mvs-preview-grid-1 .mvs-preview-item {
	width: 200px;
	height: 150px;
}
.mvs-activity-media-preview.mvs-preview-grid-1 .mvs-preview-item img {
	width: 200px;
	height: 150px;
}

/* Preview item: fixed square cell */
.mvs-preview-item {
	position: relative;
	width: 100px;
	height: 100px;
	min-width: 100px;
	border-radius: 6px;
	overflow: hidden;
	background: #eee;
	flex-shrink: 0;
}

.mvs-preview-item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

#buddypress .mvs-activity-media-remove,
.mvs-activity-media-remove {
	position: absolute;
	top: 4px;
	right: 4px;
	width: 22px;
	height: 22px;
	border-radius: 50%;
	background: rgba(0, 0, 0, 0.65);
	color: var(--mvs-bg);
	border: none;
	cursor: pointer;
	font-size: 13px;
	line-height: 22px;
	text-align: center;
	padding: 0;
	backdrop-filter: blur(4px);
	transition: background 0.15s;
}

#buddypress .mvs-activity-media-remove:hover,
.mvs-activity-media-remove:hover {
	background: var(--mvs-danger);
}

/* ==========================================================================
   30. Single Media Page Fixes
   ========================================================================== */

.mvs-media-content img {
	max-width: 100%;
	height: auto;
	border-radius: 4px;
}

.mvs-social-bar {
	display: flex;
	align-items: center;
	gap: 8px;
	flex-wrap: wrap;
	padding: 10px 16px;
	border-top: 1px solid #efefef;
}

.mvs-reactions {
	display: flex;
	gap: 4px;
}

.mvs-reaction-btn {
	display: inline-flex;
	align-items: center;
	gap: 3px;
	padding: 5px 10px;
	border: 1px solid #efefef;
	border-radius: 20px;
	background: var(--mvs-bg);
	cursor: pointer;
	font-size: 14px;
	transition: all 0.15s;
}

.mvs-reaction-btn:hover,
.mvs-reaction-btn.active {
	background: #f0f6fc;
	border-color: #0095f6;
}

.mvs-reaction-btn .mvs-count {
	font-size: 12px;
	color: var(--mvs-text-secondary);
}

.mvs-social-bar button.active .mvs-count {
	color: var(--mvs-bg);
}

.mvs-favorite-btn {
	padding: 5px 12px;
	border: 1px solid #efefef;
	border-radius: 20px;
	background: var(--mvs-bg);
	cursor: pointer;
	font-size: 13px;
	transition: all 0.15s;
}

.mvs-favorite-btn:hover,
.mvs-favorite-btn.active {
	background: #fce4e4;
	border-color: #ed4956;
	color: #ed4956;
}

.mvs-share-btn {
	padding: 5px 12px;
	border: 1px solid #efefef;
	border-radius: 20px;
	background: var(--mvs-bg);
	cursor: pointer;
	font-size: 13px;
	transition: all 0.15s;
}

.mvs-share-btn:hover {
	border-color: #0095f6;
	color: #0095f6;
}

.mvs-view-count {
	margin-left: auto;
	font-size: 0.8125rem;
	color: #8e8e8e;
}

/* Single Media Responsive */
@media (max-width: 680px) {
	.mvs-single-media {
		padding: 0;
	}

	.mvs-media-article {
		border-radius: 0;
		border-left: none;
		border-right: none;
	}
}

@media (max-width: 480px) {
	.mvs-media-header {
		padding: 12px;
	}

	.mvs-media-title {
		font-size: 1.25em;
	}

	.mvs-social-bar {
		padding: 10px 12px;
		gap: 6px;
	}

	.mvs-reaction-btn {
		padding: 4px 8px;
		font-size: 13px;
	}

	.mvs-comments-section {
		padding: 10px 12px 12px;
	}

	.mvs-media-description {
		padding: 10px 12px 0;
	}

	.mvs-media-footer {
		padding: 6px 12px 12px;
	}
}

/* ==========================================================================
   31. Explore Page Grid Fixes
   ========================================================================== */

@media (max-width: 768px) {
	}

@media (max-width: 480px) {
	}

/* ==========================================================================
   32. Profile Header (Dashboard) & Profile Edit
   ========================================================================== */

/* Dashboard Profile Header */
.mvs-dashboard-profile-header {
	margin-bottom: 1.5rem;
	padding: 1.25rem;
	background: #f8f9fa;
	border: 1px solid var(--mvs-border, #dcdcde);
	border-radius: 12px;
}

.mvs-dashboard-profile-view {
	display: flex;
	align-items: center;
	gap: 1rem;
}

.mvs-dashboard-profile-avatar {
	width: 64px;
	height: 64px;
	border-radius: 50%;
	object-fit: cover;
	flex-shrink: 0;
}

.mvs-dashboard-profile-info {
	flex: 1;
	min-width: 0;
}

.mvs-dashboard-profile-name {
	font-size: 1.125rem;
	margin: 0 0 0.125rem;
	font-weight: 600;
}

.mvs-dashboard-profile-bio {
	font-size: 0.8125rem;
	color: var(--mvs-text-secondary);
	margin: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.mvs-dashboard-profile-actions {
	display: flex;
	gap: 8px;
	flex-shrink: 0;
}

.mvs-dashboard-profile-edit-btn {
	flex-shrink: 0;
}

/* Inline Edit Form */
.mvs-dashboard-profile-edit-form {
	padding-top: 0.5rem;
}

.mvs-profile-form-inline {
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.mvs-profile-field-row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 1rem;
}

.mvs-profile-form-actions {
	display: flex;
	gap: 0.5rem;
}

/* Standalone Profile Edit Page */
.mvs-profile-edit {
	max-width: 600px;
	margin: 2rem auto;
	padding: 0 1rem;
}

.mvs-profile-edit h2 {
	font-size: 1.5rem;
	margin-bottom: 1.5rem;
}

/* Messages */
.mvs-profile-message {
	padding: 0.75rem 1rem;
	border-radius: 6px;
	margin-bottom: 1rem;
	font-size: 0.875rem;
}

.mvs-profile-message--success {
	background: #d4edda;
	color: #155724;
	border: 1px solid #c3e6cb;
}

.mvs-profile-message--error {
	background: #f8d7da;
	color: #721c24;
	border: 1px solid #f5c6cb;
}

/* Avatar Section */
.mvs-profile-avatar-section {
	display: flex;
	align-items: center;
	gap: 1.5rem;
	margin-bottom: 2rem;
	padding: 1.5rem;
	background: #f8f9fa;
	border-radius: 12px;
}

.mvs-profile-avatar-preview {
	flex-shrink: 0;
}

.mvs-profile-avatar-img {
	width: 96px;
	height: 96px;
	border-radius: 50%;
	object-fit: cover;
	border: 3px solid #fff;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.mvs-profile-avatar-actions {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
}

.mvs-profile-avatar-upload-label {
	cursor: pointer;
	display: inline-block;
}

.mvs-profile-avatar-input {
	display: none;
}

.mvs-profile-avatar-remove {
	font-size: 0.8125rem;
	color: #dc3545;
	background: none;
	border: none;
	cursor: pointer;
	padding: 0;
	text-align: left;
}

.mvs-profile-avatar-remove:hover {
	text-decoration: underline;
}

.mvs-profile-avatar-hint {
	font-size: 0.75rem;
	color: #6c757d;
	margin: 0;
}

/* Form Fields */
.mvs-profile-form {
	display: flex;
	flex-direction: column;
	gap: 1.25rem;
}

.mvs-profile-field {
	display: flex;
	flex-direction: column;
	gap: 0.375rem;
}

.mvs-profile-field label {
	font-weight: 600;
	font-size: 0.875rem;
	color: #333;
}

.mvs-profile-field input[type="text"],
.mvs-profile-field textarea {
	padding: 0.625rem 0.75rem;
	border: 1px solid #ccc;
	border-radius: 6px;
	font-size: 0.9375rem;
	font-family: inherit;
	transition: border-color 0.2s;
	width: 100%;
	box-sizing: border-box;
}

.mvs-profile-field input[type="text"]:focus,
.mvs-profile-field textarea:focus {
	border-color: var(--mvs-primary);
	outline: none;
	box-shadow: 0 0 0 2px rgba(0, 115, 170, 0.15);
}

.mvs-profile-field textarea {
	resize: vertical;
	min-height: 80px;
}

/* Actions */
.mvs-profile-actions {
	margin-top: 0.5rem;
}

/* Shared button styles (used across profile and dashboard) */
.mvs-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.375rem;
	padding: 0.625rem 1.25rem;
	border-radius: 6px;
	font-size: 0.875rem;
	font-weight: 600;
	cursor: pointer;
	border: 1px solid transparent;
	transition: background 0.2s, border-color 0.2s;
	text-decoration: none;
	line-height: 1.4;
}

.mvs-btn--primary {
	background: var(--mvs-primary);
	color: var(--mvs-bg);
	border-color: var(--mvs-primary);
}

.mvs-btn--primary:hover {
	background: #005f8d;
}

.mvs-btn--primary:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

.mvs-btn--secondary {
	background: var(--mvs-bg);
	color: #333;
	border-color: #ccc;
}

.mvs-btn--secondary:hover {
	background: #f0f0f0;
	color: #333;
}

.mvs-btn--text {
	background: none;
	border: none;
	padding: 0.25rem 0;
}

/* Mobile */
@media (max-width: 480px) {
	.mvs-profile-avatar-section {
		flex-direction: column;
		text-align: center;
	}

	.mvs-profile-avatar-actions {
		align-items: center;
	}

	.mvs-profile-avatar-remove {
		text-align: center;
	}

	.mvs-dashboard-profile-view {
		flex-wrap: wrap;
	}

	.mvs-dashboard-profile-edit-btn {
		width: 100%;
	}

	.mvs-profile-field-row {
		grid-template-columns: 1fr;
	}
}

/* ==========================================================================
   33a. Search Tabs & User Search
   ========================================================================== */

.mvs-search-bar {
	display: flex;
	align-items: center;
	background: var(--mvs-bg);
	border: 1.5px solid #e2e2e2;
	border-radius: 100px;
	padding: 5px 5px 5px 6px;
	gap: 0;
	transition: border-color 0.2s, box-shadow 0.2s;
	max-width: 600px;
}

.mvs-search-bar:focus-within {
	border-color: var(--mvs-primary);
	box-shadow: 0 0 0 3px rgba(0, 115, 170, 0.12);
}

.mvs-search-mode {
	display: flex;
	background: var(--mvs-surface-2);
	border-radius: 100px;
	padding: 2px;
	flex-shrink: 0;
	gap: 2px;
}

.mvs-search-mode-btn {
	padding: 5px 14px;
	border: none;
	background: transparent;
	border-radius: 100px;
	cursor: pointer;
	font-size: 0.8125rem;
	font-weight: 500;
	color: var(--mvs-text-secondary);
	transition: background 0.15s, color 0.15s;
	white-space: nowrap;
}

.mvs-search-mode-btn.active {
	background: var(--mvs-bg);
	color: var(--mvs-primary);
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.mvs-search-field {
	display: flex;
	align-items: center;
	flex: 1;
	padding: 0 12px;
	gap: 8px;
	min-width: 0;
}

.mvs-search-icon {
	width: 16px;
	height: 16px;
	color: var(--mvs-text-muted);
	flex-shrink: 0;
}

.mvs-search-field input {
	flex: 1;
	border: none;
	outline: none;
	background: transparent;
	font-size: 0.9375rem;
	color: var(--mvs-text);
	padding: 6px 0;
	min-width: 0;
}

.mvs-search-field input::placeholder {
	color: var(--mvs-text-muted);
}

.mvs-user-search-results {
	margin-top: 12px;
}

.mvs-user-search-empty {
	text-align: center;
	color: var(--mvs-text-secondary);
	padding: 16px;
}

.mvs-user-card {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 16px;
	border: 1px solid #dbdbdb;
	border-radius: 8px;
	margin-bottom: 8px;
	text-decoration: none;
	transition: border-color 0.2s, box-shadow 0.2s;
}

.mvs-user-card:hover {
	border-color: var(--mvs-primary);
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.mvs-user-card-avatar {
	border-radius: 50%;
	object-fit: cover;
}

.mvs-user-card-info {
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.mvs-user-card-info strong {
	font-size: 0.9375rem;
	color: #1a1a1a;
}

.mvs-user-card-info span {
	font-size: 0.8125rem;
	color: #8e8e8e;
}

/* Login prompt links styled like buttons */
.mvs-login-prompt {
	opacity: 0.7;
	cursor: pointer;
	text-decoration: none;
}

.mvs-login-to-comment {
	text-align: center;
	padding: 12px;
	color: var(--mvs-text-secondary);
}

.mvs-login-to-comment a {
	color: var(--mvs-primary);
}

/* ==========================================================================
   33. Logged-Out CTA Banner
   ========================================================================== */

.mvs-logged-out-banner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: var(--mvs-bg);
	padding: 14px 24px;
	border-radius: 8px;
	margin: 0 auto 20px;
	max-width: 1200px;
	position: relative;
}

.mvs-logged-out-banner__content {
	font-size: 0.9375rem;
}

.mvs-logged-out-banner__content strong {
	font-weight: 700;
}

.mvs-logged-out-banner__actions {
	display: flex;
	gap: 8px;
	flex-shrink: 0;
}

.mvs-logged-out-banner__actions .mvs-btn--primary {
	background: var(--mvs-bg);
	color: #667eea;
	border: none;
}

.mvs-logged-out-banner__actions .mvs-btn--secondary {
	background: transparent;
	color: var(--mvs-bg);
	border: 1px solid rgba(255, 255, 255, 0.6);
}

.mvs-logged-out-banner__close {
	background: none;
	border: none;
	color: rgba(255, 255, 255, 0.7);
	font-size: 20px;
	cursor: pointer;
	padding: 4px;
	line-height: 1;
	position: absolute;
	top: 8px;
	right: 8px;
}

.mvs-logged-out-banner__close:hover {
	color: var(--mvs-bg);
}

@media (max-width: 600px) {
	.mvs-logged-out-banner {
		flex-direction: column;
		text-align: center;
		padding: 16px 20px 20px;
	}
}

/* ==========================================================================
   34. Frontend Empty States
   ========================================================================== */

.mvs-empty-state-frontend {
	text-align: center;
	padding: 48px 24px;
	color: var(--mvs-text-secondary);
}

.mvs-empty-state-icon {
	display: block;
	font-size: 48px;
	margin-bottom: 12px;
	line-height: 1;
	opacity: 0.7;
}

.mvs-empty-state-frontend h3 {
	margin: 0 0 8px;
	font-size: 1.125rem;
	color: #333;
}

.mvs-empty-state-frontend p {
	margin: 0 0 16px;
	font-size: 0.9375rem;
	color: var(--mvs-text-secondary);
}

/* ==========================================================================
   34b. Profile Completion Prompt
   ========================================================================== */

.mvs-profile-prompt {
	display: flex;
	align-items: center;
	gap: 10px;
	background: #fef3cd;
	border: 1px solid #ffc107;
	border-radius: 6px;
	padding: 10px 16px;
	margin-bottom: 16px;
	font-size: 0.875rem;
	position: relative;
}

.mvs-profile-prompt-icon {
	font-size: 20px;
	flex-shrink: 0;
}

.mvs-profile-prompt-text {
	flex: 1;
	color: #856404;
}

.mvs-profile-prompt-text a {
	color: #533f03;
	font-weight: 600;
}

.mvs-profile-prompt-close {
	background: none;
	border: none;
	font-size: 18px;
	cursor: pointer;
	color: #856404;
	padding: 4px;
	line-height: 1;
}

/* ==========================================================================
   35. Accessibility — Focus & Reduced Motion
   ========================================================================== */

/* Visible focus ring on all interactive elements */
.mvs-btn:focus-visible,
.mvs-reaction-btn:focus-visible,
.mvs-favorite-btn:focus-visible,
.mvs-share-btn:focus-visible,
.mvs-follow-btn:focus-visible,
.mvs-dashboard-tab:focus-visible,
.mvs-comment-form button:focus-visible,
.mvs-comment-form textarea:focus-visible,
.mvs-tag-cloud-item:focus-visible,
.mvs-notification-bell:focus-visible,
.mvs-modal-close:focus-visible,
.mvs-dashboard-dropzone:focus-visible {
	outline: 2px solid #0073aa;
	outline-offset: 2px;
}

/* Focus trap visual — modals */
.mvs-modal:focus-within {
	box-shadow: 0 0 0 4px rgba(0, 115, 170, 0.15);
}

/* Respect prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
		scroll-behavior: auto !important;
	}
}

/* Hidden attribute override — ensure hidden works even with inline display */
[hidden] {
	display: none !important;
}

/* ==========================================================================
   36. Mobile Touch Targets & Responsiveness
   ========================================================================== */

@media (max-width: 768px) {
	/* Ensure minimum 44px touch targets */
	.mvs-reaction-btn {
		min-width: 44px;
		min-height: 44px;
		padding: 8px 10px;
	}

	.mvs-favorite-btn,
	.mvs-share-btn {
		min-height: 44px;
		padding: 10px 14px;
	}

	.mvs-follow-btn {
		min-height: 44px;
		padding: 10px 16px;
	}

	/* Increase spacing between action buttons */
	.mvs-social-actions {
		gap: 8px;
	}

	.mvs-social-actions-left {
		gap: 8px;
	}

	/* Sticky dashboard tabs */
	.mvs-dashboard-tabs {
		position: sticky;
		top: 0;
		z-index: 10;
		background: var(--mvs-bg);
		padding: 8px 0;
		border-bottom: 1px solid #dbdbdb;
		margin: 0 -20px;
		padding-left: 20px;
		padding-right: 20px;
		overflow-x: auto;
		white-space: nowrap;
		-webkit-overflow-scrolling: touch;
	}

	.mvs-dashboard-tab {
		min-height: 44px;
	}

	/* Prevent horizontal overflow on long text */
	.mvs-media-title {
		word-break: break-word;
		overflow-wrap: break-word;
	}

	.mvs-media-author-name {
		max-width: 150px;
	}

	.mvs-grid-item-info {
		max-width: 100%;
		overflow: hidden;
	}

	.mvs-grid-item-author {
		white-space: nowrap;
		overflow: hidden;
		text-overflow: ellipsis;
		max-width: 120px;
	}

	/* Single media — sticky bottom action bar */
	.mvs-social-bar {
		position: sticky;
		bottom: 0;
		background: var(--mvs-bg);
		border-top: 1px solid #dbdbdb;
		padding: 8px 16px;
		margin: 0 -16px;
		z-index: 5;
	}

	.mvs-social-actions {
		flex-wrap: wrap;
	}

	/* Notification bell touch target */
	.mvs-notification-bell {
		min-width: 44px;
		min-height: 44px;
		display: flex;
		align-items: center;
		justify-content: center;
	}

	/* Upload dropzone larger on mobile */
	.mvs-dashboard-dropzone {
		min-height: 120px;
	}

	/* Tag cloud horizontal scroll */
	.mvs-tag-cloud {
		overflow-x: auto;
		white-space: nowrap;
		-webkit-overflow-scrolling: touch;
		padding-bottom: 8px;
	}

	.mvs-tag-cloud-item {
		min-height: 36px;
		padding: 6px 12px;
	}

	/* Modal full-screen on mobile */
	.mvs-modal {
		width: 100%;
		max-width: 100%;
		height: 100%;
		max-height: 100%;
		border-radius: 0;
		margin: 0;
	}

	.mvs-modal-body {
		max-height: calc(100vh - 120px);
		overflow-y: auto;
	}
}

/* Bottom navigation bar for mobile logged-in users */
@media (max-width: 600px) {
	.mvs-explore-header h1 {
		font-size: 1.25rem;
	}

	.mvs-explore-search input {
		font-size: 16px; /* Prevent zoom on iOS */
	}

	.mvs-media-grid.mvs-cols-3 {
		grid-template-columns: repeat(2, 1fr);
	}

	.mvs-dashboard-grid {
		grid-template-columns: repeat(2, 1fr);
	}

	/* Comment form stacked on mobile */
	.mvs-comment-form {
		flex-direction: column;
	}

	.mvs-comment-form button {
		align-self: flex-end;
	}
}

/* ==========================================================================
   RTL Support
   ========================================================================== */

[dir="rtl"] [dir="rtl"] [dir="rtl"] [dir="rtl"] [dir="rtl"] .mvs-grid-item-info { flex-direction: row-reverse; }
[dir="rtl"] .mvs-grid-item-overlay { text-align: right; }

[dir="rtl"] .mvs-search-bar { flex-direction: row-reverse; }
[dir="rtl"] .mvs-search-field { flex-direction: row-reverse; }

[dir="rtl"] .mvs-activity-media-remove { right: auto; left: 4px; }

[dir="rtl"] .mvs-explore-header { text-align: right; }
[dir="rtl"] .mvs-tag-cloud { direction: rtl; }

[dir="rtl"] [dir="rtl"] [dir="rtl"] .mvs-logged-out-banner__content { text-align: right; }
[dir="rtl"] .mvs-logged-out-banner__close { right: auto; left: 16px; }

[dir="rtl"] .mvs-chat-trigger { right: auto; left: 20px; }

[dir="rtl"] .mvs-bp-album-form,
[dir="rtl"] .mvs-bp-album-msg { text-align: right; }

/* ==========================================================================
   Mobile — Search Bar Responsive Fixes
   ========================================================================== */

@media (max-width: 768px) {
	.mvs-search-bar {
		max-width: 100%;
	}

	.mvs-search-mode-btn {
		padding: 5px 10px;
		font-size: 0.75rem;
	}
}

@media (max-width: 480px) {
	.mvs-explore-header h1 {
		font-size: 1.25rem;
	}

	.mvs-search-bar {
		border-radius: var(--mvs-radius-lg);
		padding: 4px;
	}

	.mvs-search-mode {
		display: none; /* Collapsed on very small screens — defaults to media mode */
	}
}


/* ── Lightbox social sidebar ───────────────────────────────────────── */
.mvs-lightbox-overlay {
	position: fixed; inset: 0; z-index: 100000;
	background: rgba(0,0,0,.85);
	display: flex; align-items: center; justify-content: center;
}
.mvs-lightbox {
	display: flex; max-width: 95vw; max-height: 92vh;
	background: #fff; border-radius: 6px; overflow: hidden;
	position: relative; box-shadow: 0 20px 60px rgba(0,0,0,.5);
}
.mvs-lightbox-close {
	position: absolute; top: 12px; right: 12px; z-index: 10;
	background: rgba(0,0,0,.5); border: none; border-radius: 50%;
	width: 36px; height: 36px; display: flex; align-items: center; justify-content: center;
	cursor: pointer; color: #fff;
}
.mvs-lightbox-close:hover { background: rgba(0,0,0,.7); }
.mvs-lightbox-close svg { width: 20px; height: 20px; }
.mvs-lightbox-loading {
	width: 600px; height: 500px; display: flex; align-items: center; justify-content: center;
}
.mvs-lightbox-media {
	flex: 1; min-width: 0; display: flex; align-items: center; justify-content: center;
	background: #000; position: relative; max-height: 92vh;
}
.mvs-lightbox-media img {
	max-width: 100%; max-height: 92vh; object-fit: contain; display: block;
}
.mvs-lightbox-nav {
	position: absolute; top: 50%; transform: translateY(-50%);
	background: rgba(255,255,255,.85); border: none; border-radius: 50%;
	width: 36px; height: 36px; cursor: pointer; display: flex; align-items: center; justify-content: center;
	box-shadow: 0 2px 8px rgba(0,0,0,.2);
}
.mvs-lightbox-nav:hover { background: #fff; }
.mvs-lightbox-nav--prev { left: 12px; }
.mvs-lightbox-nav--next { right: 12px; }
.mvs-lightbox-position {
	position: absolute; bottom: 12px; left: 50%; transform: translateX(-50%);
	background: rgba(0,0,0,.6); color: #fff; padding: 4px 12px; border-radius: 12px;
	font-size: 13px;
}

/* Sidebar */
.mvs-lightbox-sidebar {
	width: 340px; flex-shrink: 0; display: flex; flex-direction: column;
	border-left: 1px solid #efefef; overflow-y: auto;
}
.mvs-lightbox-author {
	padding: 14px 16px; border-bottom: 1px solid #efefef;
}
.mvs-lightbox-author-link {
	display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit;
}
.mvs-lightbox-author-avatar {
	width: 36px; height: 36px; border-radius: 50%; object-fit: cover;
}
.mvs-lightbox-stats {
	padding: 6px 16px; font-size: 13px; color: #666;
}
.mvs-lightbox-reactions {
	display: flex; gap: 2px; padding: 8px 16px; border-bottom: 1px solid #efefef;
}
.mvs-lightbox-reaction {
	background: none; border: 1px solid #e0e0e0; border-radius: 20px;
	padding: 4px 10px; cursor: pointer; font-size: 14px;
	display: flex; align-items: center; gap: 4px; transition: all .15s;
}
.mvs-lightbox-reaction:hover { background: #f5f5f5; border-color: #ccc; }
.mvs-lightbox-reaction.active {
	background: #eff6ff; border-color: #3b82f6; color: #1d4ed8;
}
.mvs-lightbox-actions {
	display: flex; gap: 8px; padding: 10px 16px; border-bottom: 1px solid #efefef;
}
.mvs-lightbox-action {
	background: none; border: none; cursor: pointer; font-size: 14px;
	padding: 6px 12px; border-radius: 6px; text-decoration: none; color: #333;
}
.mvs-lightbox-action:hover { background: #f5f5f5; }
.mvs-lightbox-action.active { color: #e11d48; }
.mvs-lightbox-desc {
	padding: 10px 16px; font-size: 14px; line-height: 1.5;
	border-bottom: 1px solid #efefef;
}
.mvs-lightbox-desc strong { margin-right: 6px; }
.mvs-lightbox-comments {
	flex: 1; display: flex; flex-direction: column; min-height: 0;
}
.mvs-lightbox-comment-list {
	flex: 1; overflow-y: auto; padding: 12px 16px;
}
.mvs-lightbox-comment {
	display: flex; align-items: flex-start; gap: 8px;
	margin-bottom: 10px; font-size: 14px; line-height: 1.4;
}
.mvs-lightbox-comment-author-link {
	display: inline-flex; align-items: center; gap: 6px;
	text-decoration: none; color: inherit; flex-shrink: 0;
}
.mvs-lightbox-comment-author-link:hover strong { text-decoration: underline; }
.mvs-lightbox-comment-avatar {
	width: 24px; height: 24px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
}
.mvs-lightbox-comment strong { margin-right: 4px; font-weight: 600; }
.mvs-lightbox-no-comments {
	color: #999; font-size: 14px; text-align: center; padding: 20px 0;
}
.mvs-lightbox-view-all-comments {
	display: block; text-align: center; padding: 8px 0; font-size: 13px;
	color: #8e8e8e; text-decoration: none; border-top: 1px solid #efefef;
}
.mvs-lightbox-view-all-comments:hover { color: #262626; }
.mvs-lightbox-comment-form {
	display: flex; border-top: 1px solid #efefef; padding: 0;
}
.mvs-lightbox-comment-input {
	flex: 1; border: none; padding: 14px 16px; font-size: 14px; outline: none;
}
.mvs-lightbox-comment-post {
	background: none; border: none; color: #3b82f6; font-weight: 600;
	padding: 14px 16px; cursor: pointer; font-size: 14px;
}
.mvs-lightbox-comment-post:disabled { color: #ccc; cursor: default; }
.mvs-lightbox-comment-post:not(:disabled):hover { color: #1d4ed8; }

@media (max-width: 768px) {
	.mvs-lightbox { flex-direction: column; max-height: 95vh; }
	.mvs-lightbox-sidebar { width: 100%; max-height: 45vh; border-left: none; border-top: 1px solid #efefef; }
	.mvs-lightbox-media { max-height: 50vh; }
}
