.tmi-widget {
	box-sizing: border-box;
	width: 100%;
	max-width: 560px;
	margin: 0 auto;
	background: #fff;
	border: 1px solid #e5e9ee;
	border-radius: 14px;
	overflow: hidden;
	box-shadow: 0 5px 18px rgba(18, 38, 63, 0.08);
	color: #101b2c;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}

.tmi-widget *,
.tmi-widget *::before,
.tmi-widget *::after {
	box-sizing: border-box;
}

.tmi-header {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 14px 16px;
	border-bottom: 1px solid #e8ebef;
	min-height: 64px;
}

.tmi-header-icon {
	width: 30px;
	height: 30px;
	display: flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 30px;
}

.tmi-flag {
	font-size: 22px;
	line-height: 1;
}

.tmi-header-text {
	min-width: 0;
	flex: 1;
}

.tmi-title {
	font-size: 14px;
	font-weight: 750;
	line-height: 1.25;
	color: #101b2c;
}

.tmi-source {
	margin-top: 2px;
	font-size: 10px;
	line-height: 1.3;
	color: #647084;
}

.tmi-badge {
	flex: 0 0 auto;
	padding: 5px 10px;
	border: 1px solid #9bf1c1;
	border-radius: 999px;
	background: #f2fff7;
	color: #0aa657;
	font-size: 9px;
	font-weight: 800;
	letter-spacing: .35px;
}

.tmi-body {
	padding: 14px 16px;
}

.tmi-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 10px;
}

.tmi-rate-card {
	min-width: 0;
	padding: 13px 7px 11px;
	border: 1px solid #dce2e9;
	border-radius: 10px;
	background: #f1f4f8;
	text-align: center;
}

.tmi-currency {
	font-size: 10px;
	font-weight: 750;
	letter-spacing: .5px;
	color: #536074;
	line-height: 1.2;
}

.tmi-value {
	margin-top: 4px;
	font-size: 20px;
	font-weight: 800;
	letter-spacing: -.25px;
	line-height: 1.25;
	color: #0b1423;
	white-space: nowrap;
}

.tmi-unit {
	margin-top: 3px;
	font-size: 9px;
	color: #667287;
	line-height: 1.2;
}

.tmi-conversion {
	margin-top: 10px;
	min-height: 41px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 0 12px;
	border-radius: 9px;
	background: #f0f2f5;
	color: #637084;
	font-size: 12px;
}

.tmi-conversion strong {
	color: #101b2c;
	font-size: 12px;
	font-weight: 800;
	white-space: nowrap;
}

.tmi-arrow {
	margin-left: 5px;
	font-size: 16px;
	vertical-align: -1px;
}

.tmi-footer {
	min-height: 38px;
	padding: 10px 16px 12px;
	border-top: 1px solid #e8ebef;
	font-size: 10px;
	color: #697487;
}

.tmi-grid-single {
	grid-template-columns: minmax(0, 1fr);
	max-width: 170px;
}

@media (max-width: 420px) {
	.tmi-header {
		padding: 13px 14px;
		gap: 9px;
	}

	.tmi-body {
		padding: 12px 14px;
	}

	.tmi-grid {
		gap: 8px;
	}

	.tmi-rate-card {
		padding-left: 4px;
		padding-right: 4px;
	}

	.tmi-value {
		font-size: 18px;
	}

	.tmi-badge {
		padding: 4px 8px;
		font-size: 8px;
	}
}

@media (max-width: 330px) {
	.tmi-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}
