/* ==========================================================================
   Trade Academy: site sidebar (inc/home-sidebar.php, ta_home_sidebar()).
   Used on the home page and everywhere the theme shows the main sidebar.
   ========================================================================== */

.ta-aside {
	--ta-text: var(--cs-color-primary, #FFFFFF);
	--ta-muted: var(--cs-color-secondary, #B4BFD0);
	--ta-border: var(--cs-color-border, #22324F);
	--ta-surface: #101D35;
	color: var(--ta-text);
}
.ta-aside a {
	text-decoration: none;
}
/* The theme gives every sidebar widget area a card look; our cards bring their own. */
.cs-widget-area.cs-sidebar__area.ta-aside .widget {
	padding: 0;
	background: none;
}


.ta-aside .cs-sidebar__inner {
	display: flex;
	flex-direction: column;
	gap: 20px;
}
.ta-aside-card {
	position: relative;
	padding: 22px;
	border: 1px solid var(--ta-border);
	border-radius: 26px;
	background: linear-gradient(180deg, #13223F 0%, #101D35 100%);
}
.ta-aside-card__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 16px;
}
.ta-aside-card__kicker {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	color: #4DB3F0;
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}
.ta-aside-card__kicker::before {
	content: "";
	width: 16px;
	height: 2px;
	border-radius: 2px;
	background: currentColor;
}
.ta-aside .ta-aside-card__more {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	color: var(--ta-muted);
	font-size: 0.8125rem;
	font-weight: 600;
	transition: color 0.2s ease;
}
.ta-aside .ta-aside-card__more:hover {
	color: #FFFFFF;
}

/* Term of the day */
.ta-aside .ta-term__main {
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding: 18px 18px 16px;
	border: 1px solid rgba(77, 179, 240, 0.25);
	border-radius: 18px;
	background:
		radial-gradient(90% 120% at 100% 0%, rgba(3, 139, 220, 0.28), transparent 60%),
		rgba(11, 21, 38, 0.6);
	color: #FFFFFF;
	transition: border-color 0.25s ease, transform 0.25s ease;
}
.ta-aside .ta-term__main:hover {
	border-color: rgba(77, 179, 240, 0.55);
	transform: translateY(-2px);
}
.ta-term__title {
	font-size: 1.375rem;
	font-weight: 800;
	line-height: 1.15;
	letter-spacing: -0.03em;
}
.ta-term__text {
	display: -webkit-box;
	overflow: hidden;
	color: var(--ta-muted);
	font-size: 0.875rem;
	line-height: 1.55;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
}
.ta-term__cta {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin-top: 4px;
	color: #4DB3F0;
	font-size: 0.8125rem;
	font-weight: 700;
}
.ta-term__main:hover .ta-term__cta svg {
	transform: translateX(3px);
}
.ta-term__cta svg {
	transition: transform 0.2s ease;
}
.ta-term__search {
	position: relative;
	margin-top: 14px;
}
.ta-term__search-icon {
	position: absolute;
	top: 50%;
	left: 14px;
	display: flex;
	color: var(--ta-muted);
	transform: translateY(-50%);
	pointer-events: none;
}
.ta-aside .ta-term__search input {
	width: 100%;
	height: 46px;
	padding: 0 14px 0 42px;
	border: 1px solid var(--ta-border);
	border-radius: 14px;
	background: #0B1526;
	box-shadow: none;
	color: #FFFFFF;
	font-size: 0.9375rem;
}
.ta-aside .ta-term__search input:focus {
	border-color: #038BDC;
	outline: none;
	box-shadow: 0 0 0 3px rgba(3, 139, 220, 0.2);
}
.ta-term__chips {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 14px 0 0;
	padding: 0;
	list-style: none;
}
.ta-aside .ta-term__chips a {
	display: inline-flex;
	padding: 6px 12px;
	border: 1px solid var(--ta-border);
	border-radius: 999px;
	color: #CFE9FB;
	font-size: 0.8125rem;
	font-weight: 600;
	transition: border-color 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}
.ta-aside .ta-term__chips a:hover {
	border-color: #038BDC;
	background: #038BDC;
	color: #FFFFFF;
}

/* Broker ranking */
.ta-brokers__list {
	display: flex;
	flex-direction: column;
	gap: 6px;
	margin: 0;
	padding: 0;
	list-style: none;
}
.ta-broker {
	position: relative;
	display: grid;
	grid-template-columns: 18px 48px minmax(0, 1fr) auto;
	align-items: center;
	gap: 12px;
	margin: 0;
	padding: 10px 12px 10px 10px;
	border: 1px solid transparent;
	border-radius: 18px;
	transition: background-color 0.25s ease, border-color 0.25s ease;
}
.ta-broker:hover {
	border-color: rgba(77, 179, 240, 0.25);
	background: rgba(77, 179, 240, 0.07);
}
.ta-broker.is-top {
	border-color: rgba(77, 179, 240, 0.3);
	background:
		radial-gradient(100% 140% at 0% 0%, rgba(3, 139, 220, 0.22), transparent 60%),
		rgba(11, 21, 38, 0.55);
}
.ta-broker__rank {
	color: var(--ta-muted);
	font-size: 0.875rem;
	font-weight: 800;
	text-align: center;
	font-variant-numeric: tabular-nums;
}
.ta-broker.is-top .ta-broker__rank {
	color: #4DB3F0;
}
.ta-broker__logo {
	display: block;
	overflow: hidden;
	width: 48px;
	height: 48px;
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-radius: 14px;
	background: #0B1526;
}
.ta-broker__logo.is-light {
	background: #FFFFFF;
}
.ta-broker__logo img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
}
.ta-broker__body {
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}
.ta-aside .ta-broker__name {
	overflow: hidden;
	color: #FFFFFF;
	font-size: 1rem;
	font-weight: 700;
	letter-spacing: -0.02em;
	text-overflow: ellipsis;
	white-space: nowrap;
	transition: color 0.2s ease;
}
.ta-broker__name::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
	border-radius: inherit;
}
.ta-aside .ta-broker:hover .ta-broker__name {
	color: #7CC8F5;
}
.ta-broker__tagline {
	color: var(--ta-muted);
	font-size: 0.75rem;
}
.ta-broker__chevron {
	display: flex;
	color: var(--ta-muted);
	transition: transform 0.2s ease, color 0.2s ease;
}
.ta-broker:hover .ta-broker__chevron {
	color: #4DB3F0;
	transform: translateX(3px);
}
.ta-aside .ta-brokers__cta {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin-top: 14px;
	padding: 12px;
	border: 1px solid var(--ta-border);
	border-radius: 14px;
	color: #FFFFFF;
	font-size: 0.875rem;
	font-weight: 600;
	transition: border-color 0.2s ease, color 0.2s ease;
}
.ta-aside .ta-brokers__cta:hover {
	border-color: #038BDC;
	color: #4DB3F0;
}


/* Keep the sticky sidebar below the auto-hiding header when it is shown. */
.cs-sticky-sidebar-enabled.cs-stick-to-top .ta-aside .cs-sidebar__inner {
	top: calc(var(--ta-header-offset, 0px) + 24px);
	transition: top 0.3s ease;
}
