/* ==========================================================================
   RBM - STATYCZNE STRONY: ADAPTACYJNY NAGŁÓWEK, TREŚĆ, UDOSTĘPNIANIE
   ORAZ STYLIZACJA NATYWNYCH OBRAZKÓW I GALERII WP (JAK W RBM - GALERIA)
   ========================================================================== */
:root {
	--rbm-accent: #E5007E;
	--rbm-accent-hover: #C2006A;
	--rbm-date-bg: #009FE3;
	--rbm-navy: #0b2545;
	--rbm-text: #1e293b;
	--rbm-muted: #64748b;
	--rbm-bg: #ffffff;
	--rbm-surface: #ffffff;
	--rbm-surface-soft: #f8fafc;
	--rbm-border: rgba(11, 37, 69, 0.1);
	--rbm-shadow: 0 12px 32px rgba(11, 37, 69, 0.12);
	--rbm-shadow-sm: 0 4px 16px rgba(11, 37, 69, 0.08);
	--rbm-font-sans: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
	--rbm-font-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
}

html.rbm-dark-mode {
	--rbm-navy: #f1f5f9;
	--rbm-text: #e2e8f0;
	--rbm-muted: #94a3b8;
	--rbm-bg: #0b1324;
	--rbm-surface: #132038;
	--rbm-surface-soft: #1a2944;
	--rbm-border: rgba(255, 255, 255, 0.12);
	--rbm-shadow: 0 14px 36px rgba(0, 0, 0, 0.45);
	--rbm-shadow-sm: 0 4px 18px rgba(0, 0, 0, 0.35);
}

.rbm-art-hdr,
.rbm-art-hdr *,
.rbm-art-content,
.rbm-art-content *,
.rbm-content-lb,
.rbm-content-lb * {
	box-sizing: border-box;
}

/* ==========================================================================
   1. ADAPTACYJNY NAGŁÓWEK WPISU / STRONY
   ========================================================================== */
.rbm-art-hdr {
	--rbm-hdr-radius: 18px;
	position: relative;
	width: 100%;
	border-radius: var(--rbm-hdr-radius);
	font-family: var(--rbm-font-sans);
	box-shadow: var(--rbm-shadow);
	margin-bottom: 24px;
	z-index: 20;
}

.rbm-art-bg-layer {
	position: absolute;
	inset: 0;
	border-radius: inherit;
	overflow: hidden;
	z-index: 1;
	pointer-events: none;
}

.rbm-art-bg-img {
	position: absolute;
	inset: 0;
	width: 100% !important;
	height: 100% !important;
	object-fit: cover;
	display: block;
}

.rbm-art-bg-gradient {
	position: absolute;
	inset: 0;
	background: linear-gradient(
		180deg,
		rgba(11, 19, 36, 0.28) 0%,
		rgba(11, 19, 36, 0.18) 34%,
		rgba(11, 19, 36, 0.62) 66%,
		rgba(11, 19, 36, 0.92) 100%
	);
}

.rbm-art-soft-waves {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	display: block;
}

.rbm-art-hdr.has-image {
	min-height: 380px;
	display: flex;
	flex-direction: column;
	background: #0b1324;
	color: #ffffff;
}

.rbm-art-hdr.has-image .rbm-art-inner {
	position: relative;
	z-index: 5;
	flex: 1;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	gap: 28px;
	padding: 22px 28px 28px;
}

.rbm-art-hdr.no-image {
	background: var(--rbm-surface);
	border: 1px solid var(--rbm-border);
	border-top: 4px solid var(--rbm-accent);
	color: var(--rbm-navy);
	box-shadow: var(--rbm-shadow-sm);
}

.rbm-art-hdr.no-image .rbm-art-inner {
	position: relative;
	z-index: 5;
	display: flex;
	flex-direction: column;
	gap: 18px;
	padding: 24px 28px 26px;
}

.rbm-art-top-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 10px 14px;
}

.rbm-art-badges-left,
.rbm-art-actions-right {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
}

.rbm-art-date-pill {
	display: inline-flex;
	align-items: center;
	padding: 6px 14px;
	border-radius: 999px;
	background: var(--rbm-date-bg);
	color: #ffffff;
	font-size: 12.5px;
	font-weight: 700;
	line-height: 1.2;
	box-shadow: 0 4px 12px color-mix(in srgb, var(--rbm-date-bg) 36%, transparent);
}

.rbm-art-cat-pill {
	display: inline-flex;
	align-items: center;
	padding: 6px 13px;
	border-radius: 999px;
	font-size: 12px;
	font-weight: 700;
	line-height: 1.2;
	text-decoration: none !important;
	transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.rbm-art-hdr.has-image .rbm-art-cat-pill {
	background: rgba(255, 255, 255, 0.16);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	border: 1px solid rgba(255, 255, 255, 0.28);
	color: #ffffff !important;
}

.rbm-art-hdr.no-image .rbm-art-cat-pill {
	background: var(--rbm-surface-soft);
	border: 1px solid var(--rbm-border);
	color: var(--rbm-navy) !important;
}

.rbm-art-cat-pill:hover {
	background: var(--rbm-accent) !important;
	border-color: var(--rbm-accent) !important;
	color: #ffffff !important;
	transform: translateY(-1px);
}

.rbm-art-comments-pill {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	height: 36px;
	padding: 0 13px;
	border-radius: 999px;
	font-size: 13px;
	font-weight: 700;
	text-decoration: none !important;
	transition: background-color 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.rbm-art-comments-pill svg {
	width: 14px;
	height: 14px;
	flex-shrink: 0;
}

.rbm-art-hdr.has-image .rbm-art-comments-pill {
	background: rgba(11, 37, 69, 0.62);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	border: 1px solid rgba(255, 255, 255, 0.28);
	color: #ffffff !important;
}

.rbm-art-hdr.no-image .rbm-art-comments-pill {
	background: var(--rbm-surface-soft);
	border: 1px solid var(--rbm-border);
	color: var(--rbm-navy) !important;
}

.rbm-art-comments-pill.has-comments {
	background: var(--rbm-accent) !important;
	border-color: transparent !important;
	color: #ffffff !important;
}

.rbm-art-comments-pill:hover {
	transform: translateY(-1px);
	border-color: var(--rbm-accent) !important;
}

.rbm-art-bottom-block {
	display: flex;
	flex-direction: column;
	gap: 12px;
	max-width: 920px;
}

.rbm-art-breadcrumbs {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 7px;
	font-size: 12.5px;
	font-weight: 600;
}

.rbm-art-hdr.has-image .rbm-art-breadcrumbs,
.rbm-art-hdr.has-image .rbm-art-breadcrumbs a {
	color: rgba(255, 255, 255, 0.82) !important;
	text-decoration: none;
}

.rbm-art-hdr.no-image .rbm-art-breadcrumbs,
.rbm-art-hdr.no-image .rbm-art-breadcrumbs a {
	color: var(--rbm-muted) !important;
	text-decoration: none;
}

.rbm-art-breadcrumbs a:hover {
	text-decoration: underline;
}

.rbm-art-title-row {
	display: flex;
	align-items: stretch;
	gap: 15px;
}

.rbm-art-accent-bar {
	width: 5px;
	align-self: stretch;
	min-height: 32px;
	border-radius: 999px;
	background: linear-gradient(180deg, #f3168e 0%, var(--rbm-accent) 100%);
	flex-shrink: 0;
}

.rbm-art-title {
	margin: 0 !important;
	padding: 2px 0;
	font-family: var(--rbm-font-serif);
	font-style: italic;
	font-weight: 600;
	font-size: clamp(26px, 3.6vw, 44px);
	line-height: 1.15;
	letter-spacing: -0.01em;
}

.rbm-art-hdr.has-image .rbm-art-title {
	color: #ffffff !important;
	text-shadow: 0 3px 16px rgba(0, 0, 0, 0.45);
}

.rbm-art-hdr.no-image .rbm-art-title {
	color: var(--rbm-navy) !important;
}

.rbm-art-submeta {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px 20px;
	padding-left: 20px;
	font-size: 13px;
	font-weight: 600;
}

.rbm-art-hdr.has-image .rbm-art-submeta {
	color: rgba(255, 255, 255, 0.88);
}

.rbm-art-hdr.no-image .rbm-art-submeta {
	color: var(--rbm-muted);
}

.rbm-art-submeta-item {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.rbm-art-submeta-item svg {
	width: 15px;
	height: 15px;
	opacity: 0.85;
}

/* ==========================================================================
   2. SYSTEM UDOSTĘPNIANIA
   ========================================================================== */
.rbm-share-box {
	position: relative;
	display: inline-flex;
}

button.rbm-share-trigger {
	appearance: none !important;
	-webkit-appearance: none !important;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	height: 36px !important;
	padding: 0 16px !important;
	margin: 0 !important;
	border-radius: 999px !important;
	font-family: var(--rbm-font-sans) !important;
	font-size: 13px !important;
	font-weight: 700 !important;
	line-height: 1 !important;
	cursor: pointer;
	transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

button.rbm-share-trigger svg {
	width: 15px;
	height: 15px;
	flex-shrink: 0;
}

.rbm-share-box.is-on-dark button.rbm-share-trigger {
	background: rgba(255, 255, 255, 0.18) !important;
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	border: 1px solid rgba(255, 255, 255, 0.34) !important;
	color: #ffffff !important;
	box-shadow: 0 4px 14px rgba(0, 0, 0, 0.18) !important;
}

.rbm-share-box.is-on-dark button.rbm-share-trigger:hover,
.rbm-share-box.is-on-dark.is-open button.rbm-share-trigger {
	background: var(--rbm-accent) !important;
	border-color: var(--rbm-accent) !important;
	color: #ffffff !important;
}

.rbm-share-box:not(.is-on-dark) button.rbm-share-trigger {
	background: var(--rbm-surface-soft) !important;
	border: 1px solid var(--rbm-border) !important;
	color: var(--rbm-navy) !important;
	box-shadow: var(--rbm-shadow-sm) !important;
}

.rbm-share-box:not(.is-on-dark) button.rbm-share-trigger:hover,
.rbm-share-box:not(.is-on-dark).is-open button.rbm-share-trigger {
	background: var(--rbm-accent) !important;
	border-color: var(--rbm-accent) !important;
	color: #ffffff !important;
}

.rbm-share-popover {
	position: absolute;
	top: calc(100% + 10px);
	right: 0;
	min-width: 205px;
	padding: 8px;
	border-radius: 14px;
	background: var(--rbm-surface);
	border: 1px solid var(--rbm-border);
	box-shadow: 0 16px 38px rgba(11, 37, 69, 0.24);
	display: flex;
	flex-direction: column;
	gap: 3px;
	opacity: 0;
	visibility: hidden;
	transform: translateY(6px);
	transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
	z-index: 95;
}

.rbm-share-box.is-open .rbm-share-popover {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}

.rbm-share-opt,
button.rbm-share-opt {
	appearance: none !important;
	-webkit-appearance: none !important;
	display: flex !important;
	align-items: center;
	gap: 10px;
	width: 100%;
	padding: 8px 10px !important;
	margin: 0 !important;
	border: none !important;
	border-radius: 9px !important;
	background: transparent !important;
	color: var(--rbm-navy) !important;
	text-decoration: none !important;
	font-family: var(--rbm-font-sans) !important;
	font-size: 13.5px !important;
	font-weight: 600 !important;
	line-height: 1.2 !important;
	text-align: left;
	box-shadow: none !important;
	cursor: pointer;
	transition: background-color 0.16s ease, color 0.16s ease;
}

.rbm-share-opt:hover,
button.rbm-share-opt:hover {
	background: var(--rbm-surface-soft) !important;
	color: var(--rbm-accent) !important;
}

.rbm-share-opt-ico {
	width: 28px;
	height: 28px;
	border-radius: 8px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: #ffffff;
	flex-shrink: 0;
}

.rbm-share-opt-ico svg { width: 15px; height: 15px; }
.rbm-share-opt-ico.is-fb { background: #1877F2; }
.rbm-share-opt-ico.is-wa { background: #25D366; }
.rbm-share-opt-ico.is-x { background: #0f172a; }
.rbm-share-opt-ico.is-copy { background: #009FE3; }
.rbm-share-opt-ico.is-mail { background: #E5007E; }
.rbm-share-opt-ico.is-print { background: #64748b; }
.rbm-share-opt.is-copied .rbm-share-opt-ico.is-copy { background: #16a34a; }

.rbm-share-inline {
	display: inline-flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 6px;
}

.rbm-share-ico-btn,
button.rbm-share-ico-btn {
	appearance: none !important;
	-webkit-appearance: none !important;
	width: 34px !important;
	height: 34px !important;
	min-width: 34px !important;
	padding: 0 !important;
	margin: 0 !important;
	border-radius: 50% !important;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	text-decoration: none !important;
	box-shadow: none !important;
	cursor: pointer;
	transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.rbm-share-inline.is-on-dark .rbm-share-ico-btn {
	background: rgba(255, 255, 255, 0.16) !important;
	backdrop-filter: blur(6px);
	border: 1px solid rgba(255, 255, 255, 0.28) !important;
	color: #ffffff !important;
}

.rbm-share-inline:not(.is-on-dark) .rbm-share-ico-btn {
	background: var(--rbm-surface-soft) !important;
	border: 1px solid var(--rbm-border) !important;
	color: var(--rbm-navy) !important;
}

.rbm-share-ico-btn:hover {
	background: var(--rbm-accent) !important;
	border-color: var(--rbm-accent) !important;
	color: #ffffff !important;
	transform: translateY(-1px);
}

.rbm-share-ico-btn svg { width: 15px; height: 15px; display: block; }
.rbm-share-copy-btn .rbm-ico-done { display: none; }
.rbm-share-copy-btn.is-copied .rbm-ico-default { display: none; }
.rbm-share-copy-btn.is-copied .rbm-ico-done { display: inline-flex; }
.rbm-share-copy-btn.is-copied { background: #16a34a !important; border-color: #16a34a !important; color: #ffffff !important; }

/* ==========================================================================
   3. WIDŻET TREŚCI ARTYKUŁU / STRONY (RBM - TREŚĆ)
   ========================================================================== */
.rbm-art-content {
	width: 100%;
	font-family: var(--rbm-font-sans);
	color: var(--rbm-text);
}

.rbm-art-content.is-card {
	background: var(--rbm-surface);
	border: 1px solid var(--rbm-border);
	border-radius: 18px;
	box-shadow: var(--rbm-shadow-sm);
	padding: 32px 36px;
}

.rbm-art-content-body {
	font-size: 16px;
	line-height: 1.78;
	color: var(--rbm-text);
	word-wrap: break-word;
}

.rbm-art-content-body::after {
	content: "";
	display: table;
	clear: both;
}

.rbm-art-content-body > *:first-child {
	margin-top: 0;
}

.rbm-art-content-body p {
	margin: 0 0 1.25em;
}

.rbm-art-content-body h2,
.rbm-art-content-body h3,
.rbm-art-content-body h4 {
	color: var(--rbm-navy);
	font-weight: 700;
	line-height: 1.3;
	margin: 1.6em 0 0.65em;
}

.rbm-art-content-body h2 {
	font-family: var(--rbm-font-serif);
	font-style: italic;
	font-size: clamp(22px, 2.2vw, 28px);
}

.rbm-art-content-body a {
	color: var(--rbm-date-bg);
	text-decoration: underline;
	text-underline-offset: 3px;
	transition: color 0.2s ease;
}

.rbm-art-content-body a:hover {
	color: var(--rbm-accent);
}

.rbm-art-content-body blockquote {
	margin: 1.5em 0;
	padding: 16px 22px;
	border-left: 4px solid var(--rbm-accent);
	border-radius: 0 12px 12px 0;
	background: var(--rbm-surface-soft);
	color: var(--rbm-navy);
	font-style: italic;
}

.rbm-art-content-body ul,
.rbm-art-content-body ol {
	margin: 0 0 1.25em;
	padding-left: 1.4em;
}

.rbm-art-content-body li {
	margin-bottom: 0.45em;
}

.rbm-art-content-body table {
	width: 100%;
	border-collapse: collapse;
	margin: 1.5em 0;
	font-size: 14.5px;
	border: 1px solid var(--rbm-border);
	border-radius: 10px;
	overflow: hidden;
}

.rbm-art-content-body th,
.rbm-art-content-body td {
	padding: 10px 14px;
	border-bottom: 1px solid var(--rbm-border);
	text-align: left;
}

.rbm-art-content-body th {
	background: var(--rbm-surface-soft);
	color: var(--rbm-navy);
	font-weight: 700;
}

/* ==========================================================================
   3B. STYLIZACJA NATYWNYCH OBRAZKÓW I GALERII WP (JAK W RBM - GALERIA!)
   Dotyczy wyłącznie zwykłych fotek i galerii w treści (nie rusza RBM - Galeria)
   ========================================================================== */

/* Pojedyncze obrazki (Gutenberg .wp-block-image + klasyczny edytor .wp-caption / p > img) */
.rbm-art-content-body figure.wp-block-image:not(.cfg-single-album *),
.rbm-art-content-body .wp-caption {
	margin: 1.5em auto;
	max-width: 100%;
}

.rbm-art-content-body .wp-block-image img,
.rbm-art-content-body .wp-caption img,
.rbm-art-content-body p > img,
.rbm-art-content-body p > a > img {
	max-width: 100%;
	height: auto;
	display: block;
	border-radius: 14px !important;
	border: 1px solid var(--rbm-border);
	box-shadow: var(--rbm-shadow-sm);
	transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.28s ease;
}

.rbm-art-content-body .wp-block-image a,
.rbm-art-content-body .wp-caption a,
.rbm-art-content-body p > a.rbm-lb-trigger {
	display: inline-block;
	text-decoration: none !important;
	position: relative;
}

.rbm-art-content-body .wp-block-image img.rbm-lb-img,
.rbm-art-content-body p > img.rbm-lb-img {
	cursor: zoom-in;
}

.rbm-art-content-body .wp-block-image img:hover,
.rbm-art-content-body .wp-caption img:hover,
.rbm-art-content-body p > a > img:hover,
.rbm-art-content-body p > img.rbm-lb-img:hover {
	transform: translateY(-2px);
	box-shadow: var(--rbm-shadow);
	border-color: rgba(229, 0, 126, 0.32);
}

/* Wyrównanie lewo/prawo/środek w treści */
.rbm-art-content-body .alignleft {
	float: left;
	margin: 0.35em 1.5em 1em 0 !important;
}

.rbm-art-content-body .alignright {
	float: right;
	margin: 0.35em 0 1em 1.5em !important;
}

.rbm-art-content-body .aligncenter {
	display: block;
	margin-left: auto !important;
	margin-right: auto !important;
	text-align: center;
}

.rbm-art-content-body .aligncenter img {
	margin-left: auto;
	margin-right: auto;
}

/* Podpisy pod pojedynczymi obrazkami */
.rbm-art-content-body figure.wp-block-image figcaption,
.rbm-art-content-body .wp-caption-text {
	margin: 8px 0 0 !important;
	font-size: 13px;
	font-style: italic;
	color: var(--rbm-muted);
	text-align: center;
	line-height: 1.45;
}

/* --- GALERIA GUTENBERGA (.wp-block-gallery) — WYGLĄD 1:1 Z RBM GALERIA --- */
.rbm-art-content-body .wp-block-gallery,
.rbm-art-content-body figure.wp-block-gallery {
	display: grid !important;
	grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
	gap: 14px !important;
	margin: 1.8em 0 !important;
	padding: 0 !important;
}

.rbm-art-content-body .wp-block-gallery.columns-2 { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
.rbm-art-content-body .wp-block-gallery.columns-3 { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
.rbm-art-content-body .wp-block-gallery.columns-4 { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
.rbm-art-content-body .wp-block-gallery.columns-5 { grid-template-columns: repeat(5, minmax(0, 1fr)) !important; }

.rbm-art-content-body .wp-block-gallery > .wp-block-image,
.rbm-art-content-body .wp-block-gallery .blocks-gallery-item {
	position: relative !important;
	width: 100% !important;
	max-width: 100% !important;
	margin: 0 !important;
	padding: 0 !important;
	aspect-ratio: 4 / 3;
	border-radius: 13px !important;
	overflow: hidden !important;
	background: var(--rbm-surface-soft);
	border: 1px solid var(--rbm-border);
	box-shadow: var(--rbm-shadow-sm);
	transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.rbm-art-content-body .wp-block-gallery > .wp-block-image:hover,
.rbm-art-content-body .wp-block-gallery .blocks-gallery-item:hover {
	transform: translateY(-3px);
	box-shadow: var(--rbm-shadow);
	border-color: rgba(229, 0, 126, 0.36);
}

.rbm-art-content-body .wp-block-gallery > .wp-block-image a,
.rbm-art-content-body .wp-block-gallery .blocks-gallery-item figure,
.rbm-art-content-body .wp-block-gallery .blocks-gallery-item a {
	display: block !important;
	width: 100% !important;
	height: 100% !important;
	margin: 0 !important;
}

.rbm-art-content-body .wp-block-gallery img {
	position: absolute !important;
	inset: 0 !important;
	width: 100% !important;
	height: 100% !important;
	object-fit: cover !important;
	border: none !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	cursor: zoom-in;
	transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1), filter 0.3s ease !important;
}

.rbm-art-content-body .wp-block-gallery > .wp-block-image:hover img,
.rbm-art-content-body .wp-block-gallery .blocks-gallery-item:hover img {
	transform: scale(1.06) !important;
	filter: brightness(0.86);
}

.rbm-art-content-body .wp-block-gallery > .wp-block-image figcaption,
.rbm-art-content-body .wp-block-gallery .blocks-gallery-item figcaption {
	position: absolute !important;
	left: 0;
	right: 0;
	bottom: 0;
	margin: 0 !important;
	padding: 20px 10px 8px !important;
	background: linear-gradient(180deg, rgba(11, 19, 36, 0) 0%, rgba(11, 19, 36, 0.82) 100%) !important;
	color: #ffffff !important;
	font-size: 12px !important;
	font-style: normal !important;
	font-weight: 600;
	text-align: center;
	pointer-events: none;
	z-index: 3;
}

.rbm-art-content-body .wp-block-gallery > figcaption.blocks-gallery-caption {
	grid-column: 1 / -1;
	margin: 4px 0 0 !important;
	font-size: 13px;
	font-style: italic;
	color: var(--rbm-muted);
	text-align: center;
}

/* --- KLASYCZNA GALERIA WORDPRESSA ([gallery]) --- */
.rbm-art-content-body .gallery {
	display: grid !important;
	grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
	gap: 14px !important;
	margin: 1.8em 0 !important;
}

.rbm-art-content-body .gallery.gallery-columns-2 { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
.rbm-art-content-body .gallery.gallery-columns-3 { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
.rbm-art-content-body .gallery.gallery-columns-4 { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
.rbm-art-content-body .gallery.gallery-columns-5 { grid-template-columns: repeat(5, minmax(0, 1fr)) !important; }

.rbm-art-content-body .gallery br { display: none !important; }

.rbm-art-content-body .gallery .gallery-item {
	position: relative;
	float: none !important;
	width: 100% !important;
	margin: 0 !important;
	padding: 0 !important;
	aspect-ratio: 4 / 3;
	border-radius: 13px;
	overflow: hidden;
	background: var(--rbm-surface-soft);
	border: 1px solid var(--rbm-border);
	box-shadow: var(--rbm-shadow-sm);
	transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.rbm-art-content-body .gallery .gallery-item:hover {
	transform: translateY(-3px);
	box-shadow: var(--rbm-shadow);
	border-color: rgba(229, 0, 126, 0.36);
}

.rbm-art-content-body .gallery .gallery-icon,
.rbm-art-content-body .gallery .gallery-icon a {
	display: block;
	width: 100%;
	height: 100%;
	margin: 0;
}

.rbm-art-content-body .gallery img {
	position: absolute;
	inset: 0;
	width: 100% !important;
	height: 100% !important;
	object-fit: cover;
	border: none !important;
	border-radius: 0 !important;
	cursor: zoom-in;
	transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1), filter 0.3s ease;
}

.rbm-art-content-body .gallery .gallery-item:hover img {
	transform: scale(1.06);
	filter: brightness(0.86);
}

.rbm-art-content-body .gallery .gallery-caption {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	margin: 0;
	padding: 18px 10px 7px;
	background: linear-gradient(180deg, rgba(11, 19, 36, 0) 0%, rgba(11, 19, 36, 0.82) 100%);
	color: #ffffff;
	font-size: 12px;
	font-weight: 600;
	text-align: center;
	pointer-events: none;
	z-index: 3;
}

/* Ikonka lupy na kafelkach natywnych galerii (identyczna jak w RBM - Galeria) */
.rbm-art-content-body .wp-block-gallery > .wp-block-image::after,
.rbm-art-content-body .wp-block-gallery .blocks-gallery-item::after,
.rbm-art-content-body .gallery .gallery-item::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%) scale(0.82);
	width: 42px;
	height: 42px;
	border-radius: 50%;
	background-color: var(--rbm-accent);
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2.3' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'/%3E%3Cline x1='11' y1='8' x2='11' y2='14'/%3E%3Cline x1='8' y1='11' x2='14' y2='11'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: center;
	background-size: 19px 19px;
	border: 1.5px solid rgba(255, 255, 255, 0.9);
	opacity: 0;
	pointer-events: none;
	z-index: 4;
	transition: opacity 0.22s ease, transform 0.22s ease;
}

.rbm-art-content-body .wp-block-gallery > .wp-block-image:hover::after,
.rbm-art-content-body .wp-block-gallery .blocks-gallery-item:hover::after,
.rbm-art-content-body .gallery .gallery-item:hover::after {
	opacity: 1;
	transform: translate(-50%, -50%) scale(1);
}

/* Wbudowany Lightbox dla zdjęć i galerii we wpisach */
.rbm-content-lb {
	position: fixed;
	inset: 0;
	z-index: 999999;
	background: rgba(8, 15, 32, 0.88);
	backdrop-filter: blur(6px);
	-webkit-backdrop-filter: blur(6px);
	display: none;
	align-items: center;
	justify-content: center;
	padding: 24px;
	font-family: var(--rbm-font-sans);
}

.rbm-content-lb.is-open {
	display: flex;
}

.rbm-content-lb-stage {
	max-width: min(1120px, 92vw);
	max-height: 86vh;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 12px;
}

.rbm-content-lb-stage img {
	max-width: 100%;
	max-height: 76vh;
	border-radius: 14px;
	border: 3px solid rgba(255, 255, 255, 0.92);
	box-shadow: 0 22px 54px rgba(0, 0, 0, 0.55);
	object-fit: contain;
	display: block;
}

.rbm-content-lb-meta {
	display: flex;
	align-items: center;
	justify-content: center;
	flex-wrap: wrap;
	gap: 10px;
	color: #f1f5f9;
	font-size: 13.5px;
	font-weight: 600;
	text-align: center;
}

.rbm-content-lb-count {
	padding: 3px 10px;
	border-radius: 999px;
	background: #E5007E;
	color: #ffffff;
	font-size: 12px;
	font-weight: 700;
}

button.rbm-content-lb-btn {
	appearance: none !important;
	-webkit-appearance: none !important;
	position: fixed;
	width: 44px !important;
	height: 44px !important;
	padding: 0 !important;
	margin: 0 !important;
	border-radius: 50% !important;
	border: 1px solid rgba(255, 255, 255, 0.25) !important;
	background: rgba(11, 19, 36, 0.72) !important;
	color: #ffffff !important;
	font-size: 24px !important;
	line-height: 1 !important;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	box-shadow: none !important;
	transition: background-color 0.2s ease;
}

button.rbm-content-lb-btn:hover {
	background: #E5007E !important;
	border-color: #E5007E !important;
}

button.rbm-content-lb-close { top: 20px; right: 20px; }
button.rbm-content-lb-prev { left: 20px; top: 50%; transform: translateY(-50%); }
button.rbm-content-lb-next { right: 20px; top: 50%; transform: translateY(-50%); }

/* Dolny pasek udostępniania pod treścią */
.rbm-art-content-footer {
	margin-top: 28px;
	padding-top: 20px;
	border-top: 1px solid var(--rbm-border);
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 12px;
}

.rbm-art-share-cta-label {
	font-size: 14px;
	font-weight: 700;
	color: var(--rbm-navy);
}

/* ==========================================================================
   4. STYLE ZACHOWANYCH OSOBNYCH WIDŻETÓW (TYTUŁ, META, OBRAZEK)
   ========================================================================== */
.rbm-title-text {
	margin: 0;
	font-family: var(--rbm-font-serif);
	font-style: italic;
	font-weight: 600;
	color: var(--rbm-navy);
	line-height: 1.2;
}

.rbm-meta-wrap {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	font-family: var(--rbm-font-sans);
	font-size: 13.5px;
	font-weight: 600;
	color: var(--rbm-muted);
}

.rbm-meta-item {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.rbm-single-hero-box {
	width: 100%;
	height: 360px;
	border-radius: 16px;
	overflow: hidden;
	box-shadow: var(--rbm-shadow-sm);
	background: var(--rbm-surface-soft);
}

.rbm-single-hero-img {
	width: 100% !important;
	height: 100% !important;
	object-fit: cover;
	display: block;
}

/* ==========================================================================
   5. RESPONSYWNOŚĆ I DRUKOWANIE
   ========================================================================== */
@media (max-width: 1024px) {
	.rbm-art-content-body .wp-block-gallery,
	.rbm-art-content-body figure.wp-block-gallery,
	.rbm-art-content-body .gallery {
		grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
		gap: 12px !important;
	}
}

@media (max-width: 767px) {
	.rbm-art-hdr {
		--rbm-hdr-radius: 14px;
		margin-bottom: 16px;
	}

	.rbm-art-hdr.has-image .rbm-art-inner,
	.rbm-art-hdr.no-image .rbm-art-inner {
		padding: 16px 16px 18px;
		gap: 16px;
	}

	.rbm-art-date-pill,
	.rbm-art-cat-pill {
		font-size: 11.5px;
		padding: 5px 11px;
	}

	.rbm-art-comments-pill,
	button.rbm-share-trigger {
		height: 33px !important;
		font-size: 12.5px !important;
		padding: 0 12px !important;
	}

	.rbm-art-title-row { gap: 11px; }
	.rbm-art-accent-bar { width: 4px; min-height: 26px; }
	.rbm-art-submeta { padding-left: 15px; font-size: 12px; }

	.rbm-art-content.is-card {
		padding: 20px 16px;
		border-radius: 14px;
	}

	.rbm-art-content-body {
		font-size: 15px;
		line-height: 1.72;
	}

	.rbm-art-content-body .alignleft,
	.rbm-art-content-body .alignright {
		float: none !important;
		display: block;
		margin: 1em auto !important;
	}

	.rbm-art-content-body .wp-block-gallery,
	.rbm-art-content-body figure.wp-block-gallery,
	.rbm-art-content-body .gallery {
		grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
		gap: 8px !important;
	}

	.rbm-art-content-body .wp-block-gallery > .wp-block-image,
	.rbm-art-content-body .wp-block-gallery .blocks-gallery-item,
	.rbm-art-content-body .gallery .gallery-item {
		border-radius: 10px !important;
	}

	button.rbm-content-lb-prev { left: 10px; }
	button.rbm-content-lb-next { right: 10px; }

	.rbm-share-popover { right: 0; min-width: 190px; }
}

@media print {
	.rbm-art-actions-right,
	.rbm-art-content-footer,
	.rbm-share-box,
	.rbm-share-inline {
		display: none !important;
	}
}