/* ST Currency Widgets — front-end styles
   All colours are CSS variables so Elementor Style controls can override them. */

/* ============ Currency Converter ============ */
.stcw-converter {
	--stcw-accent: #16a34a;
	--stcw-accent2: #a3e635;
	--stcw-card: #ffffff;
	--stcw-field: #f6f8f6;
	--stcw-text: #0f1411;
	--stcw-radius: 18px;
	--stcw-line: #e7ece8;
	--stcw-muted: #5b6660;

	box-sizing: border-box;
	max-width: 460px;
	padding: 28px;
	background: var(--stcw-card);
	border: 1px solid var(--stcw-line);
	border-radius: calc(var(--stcw-radius) + 8px);
	color: var(--stcw-text);
	font-family: inherit;
}
.stcw-converter *,
.stcw-ticker * {
	box-sizing: border-box;
}
.stcw-c-head {
	display: flex;
	flex-direction: column;
	gap: 4px;
	margin-bottom: 16px;
}
.stcw-c-title {
	font-size: 18px;
	font-weight: 700;
	line-height: 1.2;
}
.stcw-c-sub {
	font-size: 13px;
	color: var(--stcw-muted);
}
.stcw-field {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 12px 16px;
	background: var(--stcw-field);
	border: 1px solid var(--stcw-line);
	border-radius: var(--stcw-radius);
}
.stcw-field + .stcw-field {
	margin-top: 8px; /* applies only when the swap button is hidden */
}
.stcw-field-main {
	display: flex;
	flex-direction: column;
	gap: 4px;
	flex: 1 1 auto;
	min-width: 0;
}
.stcw-field-label {
	font-size: 10px;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--stcw-muted);
}
.stcw-amount {
	width: 100%;
	padding: 0;
	border: 0;
	background: transparent;
	font-family: inherit;
	font-size: 24px;
	font-weight: 600;
	color: var(--stcw-text);
	outline: none;
	font-variant-numeric: tabular-nums;
}
.stcw-result {
	font-size: 24px;
	font-weight: 600;
	color: var(--stcw-accent);
	font-variant-numeric: tabular-nums;
	line-height: 1.2;
}
.stcw-select {
	flex: 0 0 auto;
}
.stcw-select select {
	appearance: none;
	-webkit-appearance: none;
	padding: 10px 32px 10px 12px;
	border: 1px solid var(--stcw-line);
	border-radius: 10px;
	background-color: var(--stcw-card);
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none'%3E%3Cpath d='M6 9l6 6 6-6' stroke='%235b6660' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 10px center;
	font-family: inherit;
	font-size: 15px;
	font-weight: 600;
	color: var(--stcw-text);
	cursor: pointer;
}
.stcw-swap-wrap {
	display: flex;
	justify-content: center;
	margin: 8px 0;
}
.stcw-swap {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 42px;
	height: 42px;
	border: 0;
	border-radius: 12px;
	background: #0b0f0c;
	color: var(--stcw-accent2);
	cursor: pointer;
	transition: transform 0.25s ease;
}
.stcw-swap:hover {
	transform: rotate(180deg);
}
.stcw-meta {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	margin-top: 14px;
}
.stcw-rate-line {
	font-size: 13px;
	font-weight: 500;
	color: var(--stcw-muted);
	font-variant-numeric: tabular-nums;
}
.stcw-mid {
	flex: 0 0 auto;
	padding: 3px 9px;
	border-radius: 20px;
	background: rgba(22, 163, 74, 0.12);
	background: color-mix(in srgb, var(--stcw-accent) 12%, transparent);
	font-size: 11px;
	font-weight: 600;
	color: var(--stcw-accent);
}
.stcw-cta {
	display: block;
	width: 100%;
	margin-top: 16px;
	padding: 14px 24px;
	border: 0;
	border-radius: 12px;
	background: linear-gradient(120deg, var(--stcw-accent2), var(--stcw-accent));
	color: #06270f;
	font-family: inherit;
	font-size: 15px;
	font-weight: 600;
	text-align: center;
	text-decoration: none;
	cursor: pointer;
}
.stcw-updated {
	margin-top: 12px;
	font-size: 11px;
	color: var(--stcw-muted);
}

/* ============ Live Rates Ticker ============ */
.stcw-ticker {
	--stcw-tk-bg: #0b0f0c;
	--stcw-tk-pill: #14181a;
	--stcw-tk-pair: #ffffff;
	--stcw-tk-rate: #cdd5cf;
	--stcw-tk-up: #a3e635;
	--stcw-tk-down: #fca5a5;
	--stcw-tk-duration: 36s;

	position: relative;
	overflow: hidden;
	padding: 14px 0;
	background: var(--stcw-tk-bg);
}
.stcw-tk-track {
	display: flex;
	width: max-content;
	animation: stcw-marquee var(--stcw-tk-duration) linear infinite;
}
.stcw-ticker:hover .stcw-tk-track {
	animation-play-state: paused;
}
.stcw-tk-group {
	display: flex;
	flex: 0 0 auto;
	gap: 14px;
	padding-left: 14px;
}
.stcw-tk-pill {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 10px 16px;
	border: 1px solid rgba(255, 255, 255, 0.06);
	border-radius: 14px;
	background: var(--stcw-tk-pill);
	white-space: nowrap;
	font-family: inherit;
}
.stcw-tk-pair {
	font-size: 14px;
	font-weight: 700;
	color: var(--stcw-tk-pair);
}
.stcw-tk-rate {
	font-size: 14px;
	color: var(--stcw-tk-rate);
	font-variant-numeric: tabular-nums;
}
.stcw-tk-chg {
	font-size: 12px;
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}
.stcw-tk-up {
	color: var(--stcw-tk-up);
}
.stcw-tk-down {
	color: var(--stcw-tk-down);
}
@keyframes stcw-marquee {
	from {
		transform: translateX(0);
	}
	to {
		transform: translateX(-50%);
	}
}
@media (prefers-reduced-motion: reduce) {
	.stcw-tk-track {
		animation: none;
	}
}
