/* Frontend */
.f1m-panel,
.f1m-block,
.f1m-driver-card {
	font-family: inherit;
	color: #1f2330;
}

.f1m-panel {
	background: #f3f1ee;
	border-radius: 20px;
	padding: 22px;
	border: 1px solid #ddd6cf;
}

.f1m-topbar {
	display: flex;
	align-items: center;
	gap: 24px;
	flex-wrap: wrap;
	margin-bottom: 24px;
}

.f1m-season-chip {
	background: #ffffff;
	border: 2px solid #1f2330;
	border-radius: 999px;
	padding: 10px 18px;
	font-weight: 700;
	line-height: 1;
}

.f1m-tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}

.f1m-tab {
	background: transparent;
	border: none;
	border-bottom: 3px solid transparent;
	padding: 10px 6px;
	font-size: 18px;
	font-weight: 700;
	cursor: pointer;
	color: #4e5462;
}

.f1m-tab.is-active {
	color: #11151f;
	border-bottom-color: #cf2127;
}

.f1m-tab-panel {
	display: none;
}

.f1m-tab-panel.is-active {
	display: block;
}

.f1m-title {
	margin: 0 0 18px;
	font-size: clamp(26px, 4vw, 42px);
	line-height: 1.05;
	font-weight: 800;
	color: #1f2330;
}

.f1m-table-wrap {
	background: #ffffff;
	border-radius: 18px;
	padding: 24px;
	border: 1px solid #ddd6cf;
	overflow-x: auto;
}

.f1m-table {
	width: 100%;
	border-collapse: collapse;
}

.f1m-table th,
.f1m-table td {
	padding: 16px 10px;
	border-bottom: 1px solid #ddd6cf;
	text-align: left;
	vertical-align: middle;
}

.f1m-table thead th {
	font-size: 13px;
	text-transform: uppercase;
	letter-spacing: .02em;
	color: #5b6170;
}

.f1m-table tbody tr:last-child td {
	border-bottom: none;
}

.f1m-pilot-thumb,
.f1m-team-logo {
	width: 28px;
	height: 28px;
	border-radius: 999px;
	object-fit: cover;
	vertical-align: middle;
	margin-right: 8px;
}

.f1m-driver-photo .f1m-pilot-thumb {
	width: 120px;
	height: 120px;
	margin-right: 0;
}

.f1m-avatar-placeholder,
.f1m-team-logo-placeholder {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border-radius: 999px;
	background: #1f2330;
	color: #fff;
	font-size: 13px;
	font-weight: 700;
	margin-right: 8px;
}

.f1m-inline-link {
	text-decoration: none;
	color: inherit;
	font-weight: 700;
}

.f1m-inline-link:hover {
	text-decoration: underline;
}

.f1m-flag {
	margin-right: 8px;
}

.f1m-driver-card {
	background: #f3f1ee;
	border-radius: 20px;
	padding: 22px;
	border: 1px solid #ddd6cf;
}

.f1m-driver-header {
	display: flex;
	gap: 20px;
	align-items: center;
	margin-bottom: 22px;
}

.f1m-driver-name {
	margin: 0 0 8px;
	font-size: clamp(28px, 4vw, 44px);
	line-height: 1;
}

.f1m-driver-subline {
	margin: 0;
	color: #4e5462;
	font-size: 16px;
}

.f1m-stats-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 14px;
	margin-bottom: 22px;
}

.f1m-stat-box,
.f1m-historic-box,
.f1m-admin-card {
	background: #ffffff;
	border: 1px solid #ddd6cf;
	border-radius: 18px;
	padding: 18px;
}

.f1m-stat-label {
	display: block;
	font-size: 12px;
	text-transform: uppercase;
	color: #5b6170;
	margin-bottom: 6px;
}

.f1m-historic-box h3 {
	margin-top: 0;
}

.f1m-historic-list {
	list-style: none;
	padding: 0;
	margin: 0;
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 8px 16px;
}

.f1m-message {
	background: #fff7d6;
	border: 1px solid #e1ca5f;
	border-radius: 12px;
	padding: 14px 16px;
}

.f1m-admin-grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 16px;
	margin-top: 16px;
}

@media (max-width: 900px) {
	.f1m-stats-grid,
	.f1m-historic-list,
	.f1m-admin-grid {
		grid-template-columns: 1fr;
	}

	.f1m-driver-header {
		flex-direction: column;
		align-items: flex-start;
	}
}


.f1m-cell-flex {
	display: inline-flex;
	align-items: center;
	gap: 8px;
}

.f1m-country-chip {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	flex-wrap: wrap;
	padding: 6px 10px;
	border: 1px solid #ddd6cf;
	border-radius: 999px;
	background: #faf8f5;
	line-height: 1;
}

.f1m-country-code {
	font-size: 12px;
	font-weight: 800;
	letter-spacing: .04em;
	text-transform: uppercase;
	color: #1f2330;
}

.f1m-country-name {
	font-size: 13px;
	color: #4e5462;
}

.f1m-driver-subline .f1m-country-chip {
	margin-right: 10px;
	vertical-align: middle;
}
