:root {
	color-scheme: light;
	font-family: Arial, sans-serif;
	color: #17231d;
	background: #f3f6f3;
	font-synthesis: none;
	text-rendering: optimizeLegibility;
}

* {
	box-sizing: border-box;
}

body {
	min-width: 320px;
	margin: 0;
	line-height: 1.5;
}

a {
	color: #176b45;
}

a:hover {
	color: #104c31;
}

.site-header {
	background: #fff;
	border-bottom: 1px solid #dfe7e0;
}

.site-header-inner,
.page-content {
	width: min(100% - 2rem, 900px);
	margin: 0 auto;
}

.site-header-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1.5rem;
	padding: 1rem 0;
}

.site-title {
	margin: 0;
	font-size: 1.5rem;
}

.site-title a {
	color: inherit;
	text-decoration: none;
}

.site-nav {
	display: flex;
	flex-wrap: wrap;
	gap: 0.35rem;
}

.site-nav a,
.button,
button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 2.7rem;
	padding: 0.6rem 0.9rem;
	border: 1px solid #d3ded5;
	border-radius: 9px;
	background: #fff;
	color: #176b45;
	font: inherit;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
}

.site-nav a:hover,
.button:hover,
button:hover {
	background: #f0f7f2;
}

.site-nav a:focus-visible,
.button:focus-visible,
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible {
	outline: 3px solid #78b994;
	outline-offset: 2px;
}

.page-content {
	padding-top: 2rem;
	padding-bottom: 3rem;
}

h1,
h2,
h3 {
	line-height: 1.25;
}

.page-content > h1:first-child,
.page-content > h2:first-child {
	margin-top: 0;
}

.card,
.calendar-card,
.workout,
.uebung {
	padding: 1.25rem 1.5rem;
	margin: 1.25rem 0;
	border: 1px solid #dfe7e0;
	border-radius: 14px;
	background: #fff;
	box-shadow: 0 8px 24px #17231d0a;
}

.card h2,
.uebung h2,
.uebung h3 {
	margin-top: 0;
}

.form-card {
	max-width: 680px;
}

form label {
	display: block;
	margin: 0.9rem 0 0.35rem;
	font-weight: 600;
}

input[type="text"],
input[type="url"],
input[type="number"],
textarea {
	width: 100%;
	max-width: 100%;
	padding: 0.65rem 0.75rem;
	border: 1px solid #cbd6cd;
	border-radius: 8px;
	background: #fff;
	color: inherit;
	font: inherit;
}

textarea {
	min-height: 7rem;
	resize: vertical;
}

input[type="checkbox"] {
	width: 1.1rem;
	height: 1.1rem;
	margin: 0 0.45rem 0 0;
	accent-color: #218253;
	vertical-align: middle;
}

form label:has(input[type="checkbox"]) {
	display: flex;
	align-items: center;
	font-weight: 400;
}

fieldset {
	min-width: 0;
	padding: 1rem;
	margin: 1.25rem 0;
	border: 1px solid #dfe7e0;
	border-radius: 10px;
}

legend {
	padding: 0 0.35rem;
	font-weight: 700;
}

.region {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(8rem, 11rem);
	align-items: center;
	gap: 0.75rem;
	padding: 0.6rem 0;
	border-bottom: 1px solid #edf1ed;
}

.region:last-child {
	border-bottom: 0;
}

.region label {
	margin: 0;
	font-weight: 400;
}

.region .intensity {
	width: 100%;
}

button[type="submit"],
.button-primary,
.actions a:first-child {
	border-color: #176b45;
	background: #176b45;
	color: #fff;
}

button[type="submit"]:hover,
.button-primary:hover,
.actions a:first-child:hover {
	border-color: #104c31;
	background: #104c31;
	color: #fff;
}

button:disabled {
	opacity: 0.55;
	cursor: not-allowed;
}

.error,
.success {
	padding: 0.75rem 1rem;
	border: 1px solid;
	border-radius: 9px;
}

.error {
	border-color: #efcaca;
	background: #fff4f3;
	color: #a52222;
}

.success {
	border-color: #cce4d2;
	background: #f0f7f2;
	color: #176b45;
}

.uebung {
	margin-bottom: 1rem;
}

.beschreibung {
	white-space: pre-wrap;
	overflow-wrap: anywhere;
}

.regionen {
	margin: 0.5rem 0 0;
	padding-left: 1.2rem;
}

.actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.65rem;
	margin-top: 1.5rem;
}

.workout-cta {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1.5rem;
	padding: 1.5rem 1.75rem;
	margin-bottom: 2rem;
	border-radius: 14px;
	background: #176b45;
	color: #fff;
	box-shadow: 0 8px 24px #17231d1a;
}

.workout-cta h2 {
	margin: 0;
	font-size: clamp(1.35rem, 3vw, 1.75rem);
}

.workout-cta p {
	margin: 0.35rem 0 0;
	color: #e1f0e5;
}

.workout-cta-button {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	min-height: 3.25rem;
	padding: 0.8rem 1.2rem;
	border: 2px solid #fff;
	border-radius: 10px;
	background: #fff;
	color: #145a3a;
	font-size: 1.05rem;
	font-weight: 700;
	text-align: center;
	text-decoration: none;
	transition: background-color 150ms ease, transform 150ms ease;
}

.workout-cta-button:hover {
	transform: translateY(-1px);
	background: #eaf5ed;
	color: #104c31;
}

.workout-cta-button:focus-visible {
	outline-color: #fff;
	outline-offset: 4px;
}

.calendar-card {
	padding: 1.5rem;
}

.calendar-heading,
.month-navigation {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
}

.calendar-heading h2 {
	margin: 0;
	font-size: 1.35rem;
	text-align: center;
}

.month-navigation a {
	display: grid;
	width: 2.5rem;
	height: 2.5rem;
	place-items: center;
	border: 1px solid #dfe7e0;
	border-radius: 50%;
	font-size: 1.4rem;
	line-height: 1;
	text-decoration: none;
}

.month-navigation a[aria-disabled="true"] {
	color: #a5afa8;
	pointer-events: none;
}

.calendar-grid {
	display: grid;
	grid-template-columns: repeat(7, minmax(0, 1fr));
	gap: 0.35rem;
	margin-top: 1rem;
	text-align: center;
}

.weekday {
	padding: 0.35rem 0;
	color: #66736b;
	font-size: 0.82rem;
	font-weight: 700;
}

.calendar-day {
	display: grid;
	min-height: 2.7rem;
	place-items: center;
	border-radius: 10px;
	font-size: 0.95rem;
}

.calendar-day.has-workout {
	background: #218253;
	color: #fff;
	font-weight: 700;
}

.calendar-day.is-today:not(.has-workout) {
	outline: 2px solid #218253;
	outline-offset: -2px;
	font-weight: 700;
}

.calendar-legend {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	margin: 1rem 0 0;
	color: #526057;
	font-size: 0.9rem;
}

.legend-dot {
	width: 0.8rem;
	height: 0.8rem;
	border-radius: 50%;
	background: #218253;
}

.streak {
	padding: 1rem 1.1rem;
	margin-top: 1rem;
	border-radius: 12px;
	background: #f0f7f2;
}

.streak strong {
	color: #176b45;
}

.workout {
	text-align: center;
}

#current-exercise {
	margin: 1rem 0;
	font-size: clamp(1.75rem, 6vw, 2.75rem);
	font-weight: 700;
	line-height: 1.2;
	overflow-wrap: anywhere;
}

.timer {
	margin: 0.25rem 0;
	font-size: clamp(3rem, 12vw, 5rem);
	font-weight: 700;
	font-variant-numeric: tabular-nums;
}

.buttons {
	display: flex;
	justify-content: center;
	gap: 0.75rem;
	margin-top: 1rem;
}

.progress {
	width: 100%;
	height: 0.75rem;
	margin-top: 1rem;
	accent-color: #218253;
}

@media (max-width: 600px) {
	.site-header-inner {
		align-items: flex-start;
		flex-direction: column;
		gap: 0.5rem;
	}

	.page-content {
		padding-top: 1.25rem;
	}

	.workout-cta {
		align-items: stretch;
		flex-direction: column;
		gap: 1rem;
		padding: 1.25rem;
	}

	.card,
	.calendar-card,
	.workout,
	.uebung {
		padding: 1rem;
	}
}

@media (max-width: 420px) {
	.site-header-inner,
	.page-content {
		width: min(100% - 1.5rem, 900px);
	}

	.calendar-grid {
		gap: 0.15rem;
	}

	.calendar-day {
		min-height: 2.4rem;
	}

	.region {
		grid-template-columns: 1fr;
		gap: 0.25rem;
	}

	.buttons {
		flex-direction: column;
	}
}
