/* "Cours du jour" widget — live metal prices. Standalone Gutenberg block. */

.ad-metal-widget-wrap {
	position: relative;
	display: flex;
	justify-content: center;
	margin: 40px auto;
}

.ad-metal-widget__dial {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 640px;
	max-width: 140%;
	transform: translate(-38%, -50%);
	opacity: 0.1;
	pointer-events: none;
	z-index: 0;
	animation: adMetalDialSpin 120s linear infinite;
}

@keyframes adMetalDialSpin {
	to { transform: translate(-38%, -50%) rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
	.ad-metal-widget__dial { animation: none; }
}

.ad-metal-widget {
	position: relative;
	z-index: 1;
	overflow: hidden;
	width: 100%;
	max-width: 480px;
	background: linear-gradient(155deg, #1c1c1c, #141414);
	border: 1px solid rgba(223, 187, 63, 0.35);
	border-radius: 8px;
	padding: 24px 28px;
	box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
	font-family: Montserrat, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.ad-metal-widget::before {
	content: "";
	position: absolute;
	top: -1px;
	left: -1px;
	right: -1px;
	height: 2px;
	background: linear-gradient(90deg, transparent, #DFBB3F, transparent);
}

.ad-metal-widget__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding-bottom: 16px;
	margin-bottom: 4px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.ad-metal-widget__title {
	font-size: 18px;
	font-weight: 700;
	color: #f5f0e8;
	letter-spacing: 0.01em;
}

.ad-metal-widget__date {
	font-size: 11px;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: #DFBB3F;
	font-weight: 600;
}

.ad-metal-widget__rows {
	display: grid;
	grid-template-columns: 1fr auto auto;
	align-items: baseline;
	column-gap: 14px;
}

.ad-metal-widget__row {
	display: contents;
}

.ad-metal-widget__row > * {
	padding: 12px 0;
}

.ad-metal-widget__divider {
	grid-column: 1 / -1;
	height: 1px;
	background: rgba(255, 255, 255, 0.06);
}

.ad-metal-widget__label {
	font-size: 13.5px;
	color: rgba(245, 240, 232, 0.75);
	letter-spacing: 0.01em;
}

.ad-metal-widget__label small {
	display: block;
	font-size: 10.5px;
	color: #999;
	text-transform: uppercase;
	letter-spacing: 0.12em;
	margin-top: 2px;
	font-weight: 600;
}

.ad-metal-widget__value {
	font-size: 21px;
	font-weight: 700;
	color: #DFBB3F;
	font-variant-numeric: tabular-nums;
	line-height: 1;
	text-align: right;
	white-space: nowrap;
}

.ad-metal-widget__unit {
	display: block;
	font-size: 9.5px;
	font-weight: 600;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: #999;
	margin-top: 5px;
	text-align: right;
}

.ad-metal-widget__delta {
	font-size: 12.5px;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
	text-align: left;
	white-space: nowrap;
}

.ad-metal-widget__delta.up { color: #3ba46b; }
.ad-metal-widget__delta.down { color: #ee2e2b; }
.ad-metal-widget__delta.flat { color: #999; }

.ad-metal-widget__foot {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 16px;
	padding-top: 14px;
	border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.ad-metal-widget__update {
	font-size: 10.5px;
	color: #999;
	letter-spacing: 0.05em;
	text-transform: uppercase;
}

.ad-metal-widget__link {
	color: #DFBB3F;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.02em;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	text-decoration: none;
}

.ad-metal-widget__link:hover {
	color: #F0D585;
}

@media (max-width: 480px) {
	.ad-metal-widget { padding: 20px; }
	.ad-metal-widget__value { font-size: 18px; }
	.ad-metal-widget__dial { display: none; }
}
