/* ===== карточки мониторинга (главная) ===== */
.fxr-monitor .heading { margin-bottom: 12px; }
.fxr-monitor__stale {
	display: inline-block;
	margin: 0 0 12px;
	padding: 7px 14px;
	border-radius: 6px;
	background: #fff4e5;
	border: 1px solid #ffd8a8;
	color: #8a5300;
	font-size: .92em;
}

.fxr-cards { display: grid; grid-template-columns: minmax(0, 1fr); gap: 15px; }
@media (min-width: 576px) { .fxr-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 992px) { .fxr-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .fxr-cards { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; } }
.fxr-card {
	display: flex;
	flex-direction: column;
	margin: 0;
	border-color: #c5d0df;
	border-radius: 5px;
	overflow: hidden;
	box-shadow: none;
}
.fxr-card > .panel-body { flex: 1 1 auto; padding: 14px 16px; }
.fxr-card > .panel-footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 10px 16px;
	background: #f4f7fb;
	border-top: 1px solid #e3e9f1;
	border-radius: 0;
}
.fxr-card__name {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 1.25em;
	font-weight: 700;
	color: #2a6596;
	line-height: 1.3;
}
.fxr-card__name span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fxr-card__broker { display: flex; align-items: center; gap: 6px; margin-top: 3px; font-size: 1em; color: #888; }
.fxr-card__balance { margin: 12px 0 10px; }
.fxr-card__cap {
	font-size: .76em;
	font-weight: 600;
	letter-spacing: .04em;
	text-transform: uppercase;
	color: #8a97a5;
}
.fxr-card__money { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 1px; }
.fxr-card__sum { font-size: 1.5em; font-weight: 700; color: #232323; white-space: nowrap; }
.fxr-card__stats { display: flex; flex-direction: column; gap: 5px; }
.fxr-card__row {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 10px;
	font-size: 1.05em;
	line-height: 1.4;
}
.fxr-card__row > span:first-child { display: flex; align-items: center; gap: 6px; color: #888; white-space: nowrap; }
.fxr-card__row > span:last-child { font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }
.fxr-card__row .text-success { color: #2e9e5b; }
.fxr-card__row .text-danger { color: #e23c3c; }
.fxr-card__row .text-muted { color: #888; }
.fxr-card__sync { display: flex; align-items: center; gap: 6px; font-size: 1em; color: #888; white-space: nowrap; }
.fxr-card__spark { height: 40px; margin: 0 0 10px; }
.fxr-card__spark svg { display: block; width: 100%; height: 40px; overflow: visible; }
.fxr-spark { stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.fxr-spark--up { stroke: #2e9e5b; }
.fxr-spark--down { stroke: #e23c3c; }
.fxr-card__profit { display: inline-flex; align-items: baseline; gap: 6px; text-align: right; }
.fxr-card__profit b { font-size: 1.18em; }
.fxr-card__cur { font-size: .82em; font-weight: 400; color: #888; white-space: nowrap; }
.fxr-card__link { font-size: 1em; font-weight: 600; white-space: nowrap; }
.fxr-icon { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: 0 0 auto; }
.fxr-icon--lg { width: 18px; height: 18px; }
.fxr-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.fxr-dd {
	display: inline-block;
	padding: 4px 10px;
	border-radius: 12px;
	font-weight: 700;
	font-size: .95em;
	white-space: nowrap;
}
.fxr-dd--low { background: #dff3e4; color: #1f7a37; }
.fxr-dd--mid { background: #fdf3d5; color: #8a6d00; }
.fxr-dd--high { background: #ffeede; color: #b35c00; }
.fxr-dd--crit { background: #fde3e3; color: #b42318; }

/* ===== полный обзор (promo) ===== */
.fxr-promo {
	background: #fff;
	color: #232323;
	font-size: 14.5px;
	border: 1px solid #c5d0df;
	border-radius: 5px;
	overflow: hidden;
}
.fxr-promo .promo-header { padding: 12px 16px; background: #2a6596; }
.fxr-promo .header-line {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 4px 8px;
	color: #fff;
	font-size: 1em;
	line-height: 1.4;
	text-align: center;
}
.fxr-promo .divider { opacity: .55; }
.fxr-promo .label {
	font-size: .82em;
	font-weight: 600;
	letter-spacing: .03em;
	text-transform: uppercase;
	color: #8a97a5;
}
.fxr-promo .balance-hero { padding: 16px; border-bottom: 9px solid #e9eef4; }
.fxr-promo .balance-hero .value { margin-top: 2px; font-size: 2em; font-weight: 800; line-height: 1.1; color: #2a6596; }
.fxr-promo .balance-hero .right { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-top: 10px; font-size: .98em; color: #4a5c6e; }
.fxr-promo .green { color: #2e9e5b; }
.fxr-promo .red { color: #e23c3c; }
.fxr-promo .value.accent { color: #2a6596; }

.fxr-promo .mini-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	border-bottom: 9px solid #e9eef4;
}
.fxr-promo .mini-card { padding: 12px 6px; text-align: center; border-right: 9px solid #e9eef4; }
.fxr-promo .mini-card:last-child { border-right: 0; }
.fxr-promo .mini-card .value { margin: 3px 0 1px; font-size: 1.15em; font-weight: 700; }
.fxr-promo .mini-card .pct { font-size: .82em; color: #8a97a5; }

.fxr-promo .info-table { padding: 2px 16px; }
.fxr-promo .info-table .fxr-row {
	display: grid;
	grid-template-columns: 1fr auto;
	align-items: center;
	gap: 12px;
	padding: 11px 0;
	border-bottom: 1px solid #eef2f6;
	font-size: 1.02em;
}
.fxr-promo .info-table .fxr-row:last-child { border-bottom: 0; }
.fxr-promo .info-table .label {
	font-size: 1em;
	font-weight: 500;
	letter-spacing: 0;
	text-transform: none;
	white-space: nowrap;
	color: #4a5c6e;
	text-align: left;
}
.fxr-promo .info-table .value { font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }
.fxr-promo .fxr-promo__cur { font-size: .85em; font-weight: 500; color: #8a97a5; }

.fxr-promo .chart-card { padding: 14px 16px; border-bottom: 1px solid #e9eef4; }
.fxr-promo .chart-card .head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.fxr-promo .chart-card .title { font-size: .95em; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: #1f2d3d; }
.fxr-promo .chart-card .delta { padding: 3px 12px; border-radius: 14px; font-size: .92em; font-weight: 700; white-space: nowrap; }
.fxr-promo .chart-card .delta.pos { background: #e6f6ea; color: #2e9e5b; }
.fxr-promo .chart-card .delta.neg { background: #fde8e8; color: #e23c3c; }
.fxr-promo .chart-wrapper { position: relative; height: 170px; }
.fxr-promo .chart-days { margin-top: 8px; font-size: .9em; color: #8a97a5; text-align: center; }
.fxr-promo .promo-footer {
	padding: 12px 16px;
	background: #f4f7fb;
	color: #8a97a5;
	font-size: .9em;
	text-align: center;
}

/* ===== модальное окно ===== */
#fxr-modal .modal-dialog { width: 100%; max-width: 560px; display: inline-block; vertical-align: middle; margin: 30px auto; }
#fxr-modal .modal-header { background: #f4f7fb; }
#fxr-modal .modal-body { max-height: calc(100vh - 180px); overflow-y: auto; padding: 0; }
#fxr-modal .fxr-modal__body { padding: 0; }
#fxr-modal .fxr-modal__loading { padding: 60px 20px; text-align: center; color: #7a8896; }
#fxr-modal .fxr-promo { border: 0; border-radius: 0; }

.fxr-detail { padding-top: 4px; }

@media (min-width: 768px) {
	.fxr-promo .balance-hero { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; }
	.fxr-promo .balance-hero .right { flex-direction: column; align-items: flex-end; gap: 5px; margin-top: 0; }
	.fxr-promo .chart-wrapper { height: 210px; }
}
@media (max-width: 767px) {
	.fxr-cards { gap: 12px; }
	.fxr-card > .panel-footer { padding: 10px 14px; }
	.fxr-card__link { padding: 10px 0; }
	.fxr-promo .header-line { font-size: .95em; }
	.fxr-promo .balance-hero .value { font-size: 1.8em; }
	.fxr-promo .info-table { padding: 2px 14px; }
	#fxr-modal .modal-header { padding: 10px 14px; }
	#fxr-modal .modal-title { font-size: 16px; }
	#fxr-modal .modal-dialog { margin: 8px; max-width: calc(100% - 16px); }
	#fxr-modal .modal-body { max-height: calc(100vh - 130px); }
}
