/* Social Sharing Module — Frontend Styles */

/* ─── Wrapper ─── */
.jwp-stk-ss-wrap {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
	margin: 12px 0;
}

.jwp-stk-ss__label {
	font-size: 13px;
	font-weight: 600;
	color: currentColor;
	flex-shrink: 0;
}

/* ─── List ─── */
.jwp-stk-ss__list {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.jwp-stk-ss__item {
	margin: 0;
	padding: 0;
}

/* ─── Buttons ─── */
.jwp-stk-ss__btn {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	padding: 6px 12px;
	border-radius: 4px;
	font-size: 12px;
	font-weight: 600;
	line-height: 1;
	text-decoration: none;
	cursor: pointer;
	transition: opacity 0.15s ease, transform 0.1s ease;
	border: 1px solid transparent;
	color: #fff;
	background: #555d6c;
}

.jwp-stk-ss__btn:hover,
.jwp-stk-ss__btn:focus-visible {
	opacity: 0.88;
	transform: translateY( -1px );
	outline: 2px solid currentColor;
	outline-offset: 2px;
}

button.jwp-stk-ss__btn {
	background: #555d6c;
	border: 1px solid transparent;
}

/* ─── Per-network colours ─── */
.jwp-stk-ss__item--facebook  .jwp-stk-ss__btn { background: #1877f2; }
.jwp-stk-ss__item--x         .jwp-stk-ss__btn { background: #000; }
.jwp-stk-ss__item--twitter   .jwp-stk-ss__btn { background: #1da1f2; }
.jwp-stk-ss__item--pinterest .jwp-stk-ss__btn { background: #e60023; }
.jwp-stk-ss__item--whatsapp  .jwp-stk-ss__btn { background: #25d366; }
.jwp-stk-ss__item--email     .jwp-stk-ss__btn { background: #555d6c; }
.jwp-stk-ss__item--sms       .jwp-stk-ss__btn { background: #34a853; }
.jwp-stk-ss__item--copy      .jwp-stk-ss__btn { background: #555d6c; }

/* ─── Network name ─── */
.jwp-stk-ss__net-name {
	white-space: nowrap;
}

/* ─── SVG icons ─── */
.jwp-stk-ss__btn svg {
	flex-shrink: 0;
	display: block;
}

/* ─── Sticky popup ─── */
.jwp-stk-ss-sticky {
	position: fixed;
	top: 50%;
	transform: translateY( -50% );
	z-index: 9999;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0;
}

.jwp-stk-ss-sticky--left  { left: 0; }
.jwp-stk-ss-sticky--right { right: 0; align-items: flex-end; }

/* Toggle button */
.jwp-stk-ss-sticky__toggle {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	background: #333;
	color: #fff;
	border: none;
	cursor: pointer;
	border-radius: 0 4px 4px 0;
	transition: background 0.15s ease;
}

.jwp-stk-ss-sticky--right .jwp-stk-ss-sticky__toggle {
	border-radius: 4px 0 0 4px;
}

.jwp-stk-ss-sticky__toggle:hover,
.jwp-stk-ss-sticky__toggle:focus-visible {
	background: #111;
	outline: 2px solid #333;
	outline-offset: 2px;
}

/* Sticky list */
.jwp-stk-ss-sticky__list {
	flex-direction: column;
	gap: 2px;
	background: #fff;
	border: 1px solid #ddd;
	border-radius: 0 4px 4px 0;
	padding: 4px;
	box-shadow: 2px 2px 8px rgba( 0, 0, 0, 0.12 );
	margin: 0;
	list-style: none;
}

.jwp-stk-ss-sticky--right .jwp-stk-ss-sticky__list {
	border-radius: 4px 0 0 4px;
}

.jwp-stk-ss-sticky .jwp-stk-ss__btn {
	padding: 8px 10px;
	border-radius: 3px;
	width: 100%;
	justify-content: flex-start;
}

/* Hide/show list */
.jwp-stk-ss-sticky__list[hidden] {
	display: none;
}

.jwp-stk-ss-sticky.is-open .jwp-stk-ss-sticky__toggle {
	background: #111;
}

/* ─── Appearance modifiers ─── */

/* Icon Only — hide the text label */
.jwp-stk-ss--icon .jwp-stk-ss__net-name {
	display: none;
}

.jwp-stk-ss--icon .jwp-stk-ss__btn {
	padding: 6px 8px;
}

.jwp-stk-ss-sticky.jwp-stk-ss--icon .jwp-stk-ss__btn {
	padding: 8px;
	justify-content: center;
}

/* Text Only — hide the SVG icon */
.jwp-stk-ss--text .jwp-stk-ss__btn svg {
	display: none;
}

/* ─── Custom button style (CSS custom properties) ─── */

/* When button_style_mode is custom, override per-network colours with unified vars.
   Specificity: 2 classes — same as per-network rules; placed after so it wins. */
.jwp-stk-ss--custom .jwp-stk-ss__btn {
	background: var( --jwp-ss-bg, #555d6c );
	color: var( --jwp-ss-text, #fff );
	padding: var( --jwp-ss-padding, 6px 12px );
	border-radius: var( --jwp-ss-radius, 4px );
}

.jwp-stk-ss--custom .jwp-stk-ss__btn svg {
	color: var( --jwp-ss-icon, currentColor );
	fill: currentColor;
}

/* Custom style — hover colors */
.jwp-stk-ss--custom .jwp-stk-ss__btn:hover,
.jwp-stk-ss--custom .jwp-stk-ss__btn:focus-visible {
	background-color: var( --jwp-ss-hover-bg, #444d5c );
	color: var( --jwp-ss-hover-text, #fff );
}

/* ─── Button Size ─── */
.jwp-stk-ss--small .jwp-stk-ss__btn {
	padding: 4px 8px;
	font-size: 11px;
}

.jwp-stk-ss--large .jwp-stk-ss__btn {
	padding: 10px 18px;
	font-size: 14px;
}

/* ─── Button Type: Outline ─── */
.jwp-stk-ss--outline .jwp-stk-ss__btn {
	background: transparent !important;
	border: 2px solid currentColor;
	color: inherit;
