/**
 * Transformations Widget styles.
 *
 * Ported from the concept-1 prototype (`.tabs`/`.tab`, `.ba-card`,
 * `.ba-images`, `.ba-body`, `.ba-meta`). Colours reference Design System
 * tokens with hard-coded fallbacks so the widget renders correctly even when
 * the theme token stylesheet is absent; the inherited Style controls override
 * these via {{WRAPPER}}-scoped inline selectors (Req 3.7).
 *
 * @package Rhino_Boxing_Widgets
 */

.rhino-transformations {
	color: var(--atmo-white, #FFFFFF);
}

/* === Header === */
.rhino-transformations__head {
	text-align: center;
	margin-bottom: 32px;
}

.rhino-transformations .overline {
	display: inline-block;
	font-size: 13px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.12em;
	color: var(--brand, #E59744);
	margin-bottom: 10px;
}

.rhino-transformations__heading {
	font-family: "Anton", system-ui, -apple-system, sans-serif;
	text-transform: uppercase;
	color: var(--atmo-white, #FFFFFF);
	line-height: 1.1;
	margin: 0;
}

/* === Tabs / filter control === */
.rhino-transformations__tabs {
	display: flex;
	gap: 6px;
	justify-content: center;
	flex-wrap: wrap;
	margin-bottom: 40px;
}

.rhino-transformations__tab {
	background: var(--atmo2, #141414);
	border: 1px solid var(--border, #2A2A2A);
	color: var(--placeholder, #B8B8B8);
	font-family: "Archivo", system-ui, -apple-system, sans-serif;
	font-weight: 600;
	font-size: 13px;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	padding: 10px 22px;
	border-radius: 9999px;
	cursor: pointer;
	transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.rhino-transformations__tab:hover,
.rhino-transformations__tab:focus-visible {
	color: #fff;
	border-color: var(--brand, #E59744);
	outline: none;
}

.rhino-transformations__tab.is-active {
	background: var(--brand, #E59744);
	color: #000;
	border-color: var(--brand, #E59744);
}

/* === Grid === */
.rhino-transformations__grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 28px;
}

/* Hidden by the filter script. */
.rhino-transformations .ba-card[hidden],
.rhino-transformations .ba-card.is-hidden {
	display: none;
}

/* === Before/After card (ported) === */
.rhino-transformations .ba-card {
	background: var(--atmo2, #141414);
	border: 1px solid var(--border, #2A2A2A);
	border-radius: 16px;
	overflow: hidden;
}

.rhino-transformations .ba-images {
	display: grid;
	grid-template-columns: 1fr 1fr;
}

.rhino-transformations .ba-images figure {
	position: relative;
	margin: 0;
}

.rhino-transformations .ba-images img {
	width: 100%;
	height: 480px;
	object-fit: cover;
	object-position: top center;
	display: block;
}

/* Video-only transformation: a single clip spanning the full card width,
   locked to the same height as the before/after images. A fixed-height
   container with absolutely-filled children prevents any global iframe
   aspect-ratio/embed rule from shrinking the video. */
.rhino-transformations .ba-video {
	position: relative;
	width: 100%;
	height: 480px;
	background: #000;
	overflow: hidden;
}

.rhino-transformations .ba-video video,
.rhino-transformations .ba-video iframe {
	position: absolute;
	inset: 0;
	width: 100% !important;
	height: 100% !important;
	max-width: none;
	border: 0;
	display: block;
}

.rhino-transformations .ba-video video {
	object-fit: cover;
}

@media (max-width: 767px) {
	.rhino-transformations .ba-video {
		height: 340px;
	}
}

.rhino-transformations .ba-images figcaption {
	position: absolute;
	top: 12px;
	left: 12px;
	background: rgba(0, 0, 0, 0.7);
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	padding: 4px 10px;
	border-radius: 9999px;
}

.rhino-transformations .ba-images figure:last-child figcaption {
	background: var(--brand, #E59744);
	color: #000;
}

.rhino-transformations .ba-body {
	padding: 22px 24px;
}

.rhino-transformations .ba-body .ba-meta {
	font-size: 13px;
	color: var(--brand, #E59744);
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	margin-bottom: 6px;
}

.rhino-transformations__name {
	font-family: "Anton", system-ui, -apple-system, sans-serif;
	text-transform: uppercase;
	margin: 0 0 8px;
	color: var(--atmo-white, #FFFFFF);
}

.rhino-transformations__story {
	font-family: "Archivo", system-ui, -apple-system, sans-serif;
	font-size: 14px;
	line-height: 1.7;
	margin: 0;
	color: var(--atmo-white, #FFFFFF);
}

/* === Empty state === */
.rhino-transformations__empty {
	text-align: center;
	padding: 48px 24px;
	font-size: 16px;
	color: var(--placeholder, #B8B8B8);
}

.rhino-transformations__empty[hidden] {
	display: none;
}

/* === Responsive === */
@media (max-width: 767px) {
	.rhino-transformations__grid {
		grid-template-columns: 1fr;
	}

	.rhino-transformations .ba-images img {
		height: 340px;
	}
}

/* === Section container + vertical rhythm ===
   The widget renders no themed `.section`/`.container` wrapper of its own, so
   when it is placed in a full-width Elementor section it would otherwise bleed
   edge-to-edge. Constrain it to the concept-1 container width, centre it, and
   add the section padding so it matches the rest of the page. */
.rhino-transformations {
	max-width: 1280px;
	margin-left: auto;
	margin-right: auto;
	padding: 80px 24px;
}
@media (max-width: 767px) {
	.rhino-transformations { padding: 56px 20px; }
}
