/* Post Share Buttons — front end */

.psb {
	--psb-h: 42px;
	--psb-pad: 16px;
	--psb-font: 14px;
	--psb-radius: 8px;
	--psb-gap: 8px;
	--psb-custom: #1646A0;
	margin: 32px 0;
	font-family: inherit;
	line-height: 1;
}

.psb__heading {
	margin: 0 0 12px !important;
	padding: 0;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	opacity: 0.75;
}

.psb__list {
	display: flex;
	flex-wrap: wrap;
	gap: var(--psb-gap);
	margin: 0 !important;
	padding: 0 !important;
	list-style: none !important;
}

.psb__item {
	margin: 0 !important;
	padding: 0 !important;
	list-style: none !important;
}

.psb__item::before,
.psb__item::marker {
	display: none !important;
	content: none !important;
}

.psb__item[hidden] {
	display: none !important;
}

/* Alignment */
.psb--align-center .psb__heading { text-align: center; }
.psb--align-center .psb__list { justify-content: center; }

/* Sizes */
.psb--size-sm { --psb-h: 34px; --psb-pad: 12px; --psb-font: 13px; --psb-gap: 6px; }
.psb--size-lg { --psb-h: 50px; --psb-pad: 20px; --psb-font: 15px; --psb-gap: 10px; }

/* Shapes */
.psb--shape-square { --psb-radius: 0; }
.psb--shape-rounded { --psb-radius: 8px; }
.psb--shape-pill { --psb-radius: 999px; }

/* Button */
.psb .psb__btn {
	--psb-bg: var(--psb-brand);
	--psb-fg: #fff;
	--psb-bd: var(--psb-brand);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	box-sizing: border-box;
	height: var(--psb-h);
	min-height: 0;
	margin: 0;
	padding: 0 var(--psb-pad);
	border: 2px solid var(--psb-bd);
	border-radius: var(--psb-radius);
	background: var(--psb-bg);
	color: var(--psb-fg) !important;
	font-family: inherit;
	font-size: var(--psb-font);
	font-weight: 600;
	line-height: 1;
	letter-spacing: 0;
	text-transform: none;
	text-decoration: none !important;
	white-space: nowrap;
	cursor: pointer;
	box-shadow: none;
	transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
	-webkit-appearance: none;
	appearance: none;
}

.psb .psb__btn:hover {
	transform: translateY(-2px);
	box-shadow: 0 10px 20px -10px rgba(0, 0, 0, 0.45);
}

.psb .psb__btn:focus-visible {
	outline: 3px solid var(--psb-brand);
	outline-offset: 2px;
}

.psb .psb__icon {
	display: block;
	flex: none;
	width: 1.15em;
	height: 1.15em;
	fill: currentColor;
}

/* Colour styles */
.psb--style-custom .psb__btn {
	--psb-bg: var(--psb-custom);
	--psb-bd: var(--psb-custom);
}

.psb--style-outline .psb__btn {
	--psb-bg: transparent;
	--psb-fg: var(--psb-brand);
}

.psb--style-outline .psb__btn:hover {
	--psb-bg: var(--psb-brand);
	--psb-fg: #fff;
}

.psb--style-minimal .psb__btn {
	--psb-bg: #F1F4F9;
	--psb-bd: #F1F4F9;
	--psb-fg: var(--psb-brand);
}

.psb--style-minimal .psb__btn:hover {
	--psb-bg: var(--psb-brand);
	--psb-bd: var(--psb-brand);
	--psb-fg: #fff;
}

/* Icons only */
.psb--icons-only .psb__btn {
	width: var(--psb-h);
	padding: 0;
}

.psb--icons-only .psb__icon {
	width: 42%;
	height: 42%;
	min-width: 14px;
	min-height: 14px;
}

.psb--icons-only .psb__label {
	position: absolute !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

/* Floating sidebar (desktop) */
.psb--floating {
	position: fixed;
	top: 50%;
	left: 18px;
	z-index: 9990;
	margin: 0;
	transform: translateY(-50%);
}

.psb--floating .psb__list {
	flex-direction: column;
	flex-wrap: nowrap;
}

.psb--floating .psb__btn:hover {
	transform: translateX(3px);
}

@media (max-width: 1023px) {
	.psb--floating { display: none !important; }
}

/* Close button on sticky bars */
.psb__close {
	display: none;
}

.psb--dbar .psb__close,
.psb--bar .psb__close {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: none;
	width: 32px;
	height: 32px;
	margin: 0 0 0 4px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: #5B6472;
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
}

.psb--dbar .psb__close:hover,
.psb--bar .psb__close:hover {
	background: #F1F4F9;
	color: #0A1F44;
}

/* Sticky bars: shared */
.psb--dbar,
.psb--bar {
	position: fixed;
	right: 0;
	left: 0;
	z-index: 9990;
	display: none;
	margin: 0;
	background: #fff;
	transition: transform 0.3s ease, visibility 0.3s;
	visibility: hidden;
}

.psb--dbar.psb--pos-bottom,
.psb--bar.psb--pos-bottom {
	bottom: 0;
	box-shadow: 0 -8px 24px -8px rgba(10, 31, 68, 0.22);
	transform: translateY(110%);
}

.psb--dbar.psb--pos-top,
.psb--bar.psb--pos-top {
	top: 0;
	box-shadow: 0 8px 24px -8px rgba(10, 31, 68, 0.22);
	transform: translateY(-110%);
}

.psb--dbar.is-visible,
.psb--bar.is-visible {
	transform: none;
	visibility: visible;
}

/* Desktop bar */
.psb--dbar {
	padding: 12px 24px;
}

.psb--dbar .psb__inner {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 18px;
	max-width: 1240px;
	margin: 0 auto;
}

.psb--dbar.psb--align-left .psb__inner {
	justify-content: flex-start;
}

.psb--dbar .psb__heading {
	margin: 0 !important;
	white-space: nowrap;
}

.psb--dbar .psb__list {
	flex-wrap: nowrap;
}

.psb--dbar .psb__close {
	margin-left: auto;
}

.psb--dbar.psb--align-center .psb__close {
	margin-left: 4px;
}

@media (min-width: 768px) {
	.psb--dbar { display: block; }
}

@media (min-width: 768px) and (max-width: 1100px) {
	.psb--dbar .psb__heading { display: none; }
}

@media (min-width: 768px) and (max-width: 1023px) {
	.psb--dbar:not(.psb--icons-only) .psb__label { display: none; }
	.psb--dbar:not(.psb--icons-only) .psb__btn { width: var(--psb-h); padding: 0; }
}

body.admin-bar .psb--dbar.psb--pos-top { top: 32px; }

/* Mobile bar */
.psb--bar {
	--psb-gap: 6px;
	padding: 8px 10px;
}

.psb--bar.psb--pos-bottom {
	padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px));
}

.psb--bar .psb__inner {
	display: flex;
	align-items: center;
	gap: 6px;
}

.psb--bar .psb__list {
	flex: 1;
	flex-wrap: nowrap;
	overflow-x: auto;
	scrollbar-width: none;
}

.psb--bar .psb__list::-webkit-scrollbar { display: none; }

.psb--bar .psb__item {
	flex: 1 0 36px;
}

.psb--bar .psb__btn {
	width: 100%;
	--psb-h: 42px;
}

@media (max-width: 767px) {
	.psb--bar { display: block; }
	body.psb-has-bar { padding-bottom: calc(62px + env(safe-area-inset-bottom, 0px)); }
	body.admin-bar .psb--bar.psb--pos-top { top: 46px; }
}

@media (max-width: 600px) {
	body.admin-bar .psb--bar.psb--pos-top { top: 0; }
}

/* Toast */
.psb-toast {
	position: fixed;
	bottom: 88px;
	left: 50%;
	z-index: 99999;
	padding: 12px 20px;
	border-radius: 999px;
	background: #0A1F44;
	color: #fff;
	font-family: inherit;
	font-size: 14px;
	font-weight: 500;
	line-height: 1.2;
	box-shadow: 0 12px 30px -10px rgba(10, 31, 68, 0.5);
	opacity: 0;
	transform: translate(-50%, 10px);
	transition: opacity 0.2s ease, transform 0.2s ease;
	pointer-events: none;
}

.psb-toast.is-visible {
	opacity: 1;
	transform: translate(-50%, 0);
}

@media (prefers-reduced-motion: reduce) {
	.psb .psb__btn,
	.psb--dbar,
	.psb--bar,
	.psb-toast { transition: none; }
	.psb .psb__btn:hover { transform: none; }
}

@media print {
	.psb { display: none !important; }
}
