/**
 * Niche Lounge Reviews — Badge styling
 *
 * Dark graphite / luxury aesthetic. All colors lean on theme custom
 * properties so the badges sit naturally inside the site's existing
 * design system (--base-2, --contrast, --border, --accent). When the
 * theme doesn't provide these, the fallbacks reproduce the same
 * charcoal-on-cream look the site already uses.
 *
 * @package Niche_Lounge_Reviews
 * @since   1.2.0
 */

.nl-review-badges {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 8px 0;
	font-family: inherit;
}

.nl-review-badges--loop {
	margin: 6px 0 10px;
}

.nl-review-badges--single {
	gap: 8px;
	margin: 12px 0 18px;
}

/* Leading icon inside a pill (e.g. the crown on Exclusive Collection). Inherits
   the pill's text colour via currentColor and sits before the label; the pill is
   already an inline-flex row with a 6px gap, so the icon aligns automatically. */
.nl-review-badge__icon {
	flex: 0 0 auto;
	width: 12px;
	height: 12px;
	display: inline-block;
	vertical-align: middle;
}

.nl-review-badge {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 5px 11px;
	background: var(--base-2, rgba(20, 20, 20, 0.85));
	color: var(--contrast, #f3efe9);
	border: 1px solid var(--border, rgba(255, 255, 255, 0.10));
	border-radius: 999px;
	font-size: 10.5px;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	line-height: 1;
	white-space: nowrap;
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	box-shadow: 0 1px 0 rgba(255, 255, 255, 0.02) inset, 0 1px 2px rgba(0, 0, 0, 0.18);
	transition: border-color 0.2s ease, background 0.2s ease;
}

.nl-review-badge:hover {
	border-color: var(--border-strong, rgba(255, 255, 255, 0.18));
}

/* Single-badge loop card variant — slightly smaller, no nowrap so long
   labels (e.g. "Highly Recommended") fit narrow mobile cards. */
.nl-review-badges--loop .nl-review-badge {
	font-size: 9.5px;
	padding: 4px 9px;
	letter-spacing: 0.05em;
	white-space: normal;
}

/* Per-key accent — a faint left bar in the brand accent for descriptive
   badges, kept extremely subtle so the row reads as a coherent set. */
.nl-review-badge--very_long_lasting,
.nl-review-badge--strong_projection,
.nl-review-badge--subtle_and_refined,
.nl-review-badge--summer_ready,
.nl-review-badge--winter_pick {
	box-shadow:
		inset 2px 0 0 var(--accent, rgba(180, 140, 90, 0.55)),
		0 1px 2px rgba(0, 0, 0, 0.18);
}

/* Light themes / cream backgrounds — swap the surface so badges remain legible. */
@media (prefers-color-scheme: light) {
	.nl-review-badge {
		background: var(--base-2, #1a1a1a);
		color: var(--contrast, #f3efe9);
	}
}

/* Mobile — keep cards from blowing out. */
@media (max-width: 480px) {
	.nl-review-badges--loop {
		gap: 4px;
	}
	.nl-review-badges--loop .nl-review-badge {
		font-size: 9px;
		padding: 3px 8px;
	}
}

/* RTL — pad consistently, flip the accent bar. */
html[dir="rtl"] .nl-review-badge--very_long_lasting,
html[dir="rtl"] .nl-review-badge--strong_projection,
html[dir="rtl"] .nl-review-badge--subtle_and_refined,
html[dir="rtl"] .nl-review-badge--summer_ready,
html[dir="rtl"] .nl-review-badge--winter_pick {
	box-shadow:
		inset -2px 0 0 var(--accent, rgba(180, 140, 90, 0.55)),
		0 1px 2px rgba(0, 0, 0, 0.18);
}
