.fahrplan-widget {
	max-width: 560px;
	margin: 1.5em 0;
	padding: 1.5em;
	border: 1px solid #e0e0e0;
	border-radius: 10px;
	background: #fafafa;
	font-family: inherit;
}

.fahrplan-form {
	display: flex;
	align-items: flex-end;
	flex-wrap: wrap;
	gap: 0.75em;
}

.fahrplan-field {
	position: relative;
	flex: 1 1 200px;
	display: flex;
	flex-direction: column;
}

.fahrplan-field label {
	font-size: 0.8em;
	font-weight: 600;
	margin-bottom: 0.3em;
	color: #444;
}

.fahrplan-field input[type="text"] {
	padding: 0.6em 0.7em;
	border: 1px solid #ccc;
	border-radius: 6px;
	font-size: 0.95em;
	width: 100%;
	box-sizing: border-box;
}

.fahrplan-field input[type="text"]:focus {
	outline: none;
	border-color: #2271b1;
	box-shadow: 0 0 0 2px rgba(34, 113, 177, 0.15);
}

.fahrplan-swap {
	flex: 0 0 auto;
	background: #fff;
	border: 1px solid #ccc;
	border-radius: 50%;
	width: 2.2em;
	height: 2.2em;
	cursor: pointer;
	font-size: 1em;
	line-height: 1;
	margin-bottom: 0.15em;
}

.fahrplan-swap:hover {
	background: #f0f0f0;
}

.fahrplan-submit {
	flex: 1 1 100%;
	padding: 0.7em 1em;
	background: #2271b1;
	color: #fff;
	border: none;
	border-radius: 6px;
	font-size: 0.95em;
	font-weight: 600;
	cursor: pointer;
}

.fahrplan-submit:hover {
	background: #135e96;
}

.fahrplan-submit:disabled {
	background: #9db8cb;
	cursor: not-allowed;
}

.fahrplan-suggestions {
	position: absolute;
	top: 100%;
	left: 0;
	right: 0;
	z-index: 20;
	background: #fff;
	border: 1px solid #ccc;
	border-top: none;
	border-radius: 0 0 6px 6px;
	max-height: 220px;
	overflow-y: auto;
	display: none;
}

.fahrplan-suggestions.is-open {
	display: block;
}

.fahrplan-suggestion {
	padding: 0.55em 0.7em;
	cursor: pointer;
	font-size: 0.9em;
}

.fahrplan-suggestion:hover,
.fahrplan-suggestion.is-active {
	background: #eef4fa;
}

.fahrplan-status {
	margin-top: 1em;
	font-size: 0.9em;
	color: #555;
	min-height: 1.2em;
}

.fahrplan-status.is-error {
	color: #b32d2e;
}

.fahrplan-results {
	margin-top: 0.5em;
	display: flex;
	flex-direction: column;
	gap: 0.9em;
}

.fahrplan-journey {
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 8px;
	padding: 0.9em 1em;
}

.fahrplan-journey-header {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	font-weight: 600;
	margin-bottom: 0.5em;
	font-size: 0.95em;
}

.fahrplan-journey-meta {
	font-size: 0.8em;
	font-weight: 400;
	color: #666;
}

.fahrplan-leg {
	display: flex;
	gap: 0.6em;
	align-items: flex-start;
	padding: 0.35em 0;
	font-size: 0.88em;
	border-top: 1px dashed #eee;
}

.fahrplan-leg:first-child {
	border-top: none;
}

.fahrplan-leg-time {
	flex: 0 0 90px;
	color: #333;
	font-variant-numeric: tabular-nums;
}

.fahrplan-leg-line {
	flex: 0 0 auto;
	background: #2271b1;
	color: #fff;
	border-radius: 4px;
	padding: 0.1em 0.5em;
	font-size: 0.85em;
	font-weight: 600;
	white-space: nowrap;
}

.fahrplan-leg-line.is-walk {
	background: #999;
}

.fahrplan-leg-route {
	flex: 1 1 auto;
	color: #444;
}

.fahrplan-attribution {
	margin-top: 1.2em;
	font-size: 0.75em;
	color: #999;
}

.fahrplan-attribution a {
	color: #999;
	text-decoration: underline;
}

@media (max-width: 480px) {
	.fahrplan-form {
		flex-direction: column;
		align-items: stretch;
	}

	.fahrplan-swap {
		align-self: center;
	}

	.fahrplan-leg-time {
		flex-basis: 75px;
	}
}
