body {
	margin: 0;
	font-family: Arial, sans-serif;
	background: #fff;
	color: #1f2933;
}

.page-shell {
	max-width: 1440px;
	margin: 0 auto;
	padding: 24px 16px 48px;
}

.page-shell h1 {
	margin: 0 0 8px;
	font-family: Georgia, 'Times New Roman', serif;
	font-size: 2.1rem;
}

.page-shell p {
	margin: 0 0 16px;
	line-height: 1.5;
}

.scheduler-panel {
	background: #fff;
	border: 1px solid #d3d8de;
	padding: 16px;
}

.scheduler-form {
	overflow-x: auto;
	overflow-y: hidden;
}

.scheduler-top {
	display: flex;
	gap: 12px;
	min-width: 76rem;
	align-items: flex-start;
}

.scheduler-filters {
	flex: 0 0 56%;
}

.scheduler-key {
	flex: 1 1 44%;
	min-width: 22rem;
}

.select-row {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	align-items: center;
	margin-bottom: 8px;
	font-size: 13px;
}

.select-row label {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	font-weight: 400;
}

.select-row select {
	min-width: 10rem;
	margin-left: 0;
	padding: 3px 4px;
	border: 1px solid #767676;
	background: #fff;
	font-size: 13px;
}

.filter-grid {
	width: 98%;
	border: 0;
	border-collapse: collapse;
	margin-top: 0.5rem;
}

.filter-grid td {
	padding: 10px;
	vertical-align: top;
	border-bottom: 0;
	border-right: 1px solid #d6dbe1;
}

.filter-grid td:last-child {
	border-right: 0;
}

.mini-grid {
	width: 100%;
	border-collapse: collapse;
}

.mini-grid td {
	border: 0;
	padding: 4px 6px 4px 0;
	font-size: 13px;
}

.mini-grid .heading-cell {
	font-weight: 700;
	padding-bottom: 6px;
}

.mini-grid select {
	width: 100%;
	padding: 2px 4px;
	border: 1px solid #767676;
	background: #fff;
	font-size: 13px;
}

.button-row {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	width: 98%;
	margin-top: 12px;
}

.button-row button {
	min-width: 8rem;
	border: 0;
	padding: 8px 16px;
	background: #01579c;
	color: #fff;
	text-decoration: underline;
	cursor: pointer;
	font-size: 13px;
}

.helper-text {
	margin: 12px 0 6px;
	font-size: 12px;
}

.total-row {
	margin: 0;
	font-weight: 700;
}

.scheduler-status {
	min-height: 1.2em;
	margin-top: 8px;
	color: #8d2b0b;
	font-weight: 700;
}

.key-card {
	min-width: 30rem;
}

.key-title {
	margin: 0 0 8px;
	background: #7eb5e0;
	color: #fff;
	padding: 2px 6px;
	font-size: 15px;
}

.key-grid {
	display: grid;
	grid-template-columns: 1fr 1fr 1.4fr;
	gap: 12px;
	padding-left: 0.6rem;
	font-size: 0.92rem;
	line-height: 1.35;
}

.key-grid p {
	margin: 0 0 6px;
}

.key-list div {
	margin-bottom: 2px;
}

.table-wrap {
	max-height: 70vh;
	overflow-y: auto;
	overflow-x: auto;
	min-width: 76rem;
	margin-top: 10px;
	border: 1px solid #d3d8de;
	background: #fff;
}

.schedule-table {
	width: 100%;
	min-width: 1400px;
	border-collapse: collapse;
}

.schedule-table th,
.schedule-table td {
	padding: 10px 8px;
	border-bottom: 1px solid #e4e7eb;
	text-align: left;
	vertical-align: top;
	font-size: 0.93rem;
}

.schedule-table th {
	position: sticky;
	top: 0;
	z-index: 2;
	background: #0b4f6c;
	color: #fff;
	cursor: pointer;
}

.schedule-table th.sort-asc::after {
	content: ' ▲';
	font-size: 0.75rem;
}

.schedule-table th.sort-desc::after {
	content: ' ▼';
	font-size: 0.75rem;
}

.schedule-table tbody tr:nth-child(even) {
	background: #f8fafc;
}

.course-link {
	color: #01579c;
	text-decoration: underline;
}

@media (max-width: 1100px) {
	.scheduler-top {
		flex-direction: column;
	}

	.scheduler-filters,
	.scheduler-key {
		flex: 1 1 auto;
		width: 100%;
	}

	.key-card {
		min-width: 0;
	}
}

@media (max-width: 780px) {
	.select-row {
		flex-direction: column;
		align-items: stretch;
	}

	.select-row label {
		display: flex;
		flex-direction: column;
		gap: 4px;
	}

	.select-row select {
		min-width: 0;
		margin-left: 0;
	}

	.key-grid {
		grid-template-columns: 1fr;
		padding-left: 0;
	}
}