/* Vzhled jedné položky termínu. */
.course-term {
    display: grid;
    grid-template-areas:
        "groups name status"
        "groups date status"
        "groups note status";
    grid-template-columns: max-content minmax(0, 1fr) auto;
    column-gap: 12px;
    align-items: center;
    padding: 8px 12px;
    border-bottom: 1px solid #ccc;
    color: black;
}

.course-term--zah {
    background-color: #e0ffe0;
}

.course-term--zdrav {
    background-color: #ffe0e0;
}

.course-term__name {
    grid-area: name;
}

.course-term__groups {
    grid-area: groups;
    align-self: center;
}

.course-term__date {
    grid-area: date;
}

.course-term__status {
    grid-area: status;
    font-weight: bold;
    text-align: right;
}

.course-term__status--green {
    color: green;
}

.course-term__note {
    grid-area: note;
    color: gray;
    font-weight: normal;
}

.course-term__status--red,
.course-term__note--red {
    color: red;
}

.course-groups {
    display: inline-flex;
    flex-wrap: nowrap;
    gap: 4px;
    vertical-align: middle;
}

.course-group {
    display: inline-flex;
    width: 24px;
    height: 24px;
    box-sizing: border-box;
    align-items: center;
    justify-content: center;
    border-radius: 3px;
    color: white;
    font-size: 12px;
    font-weight: bold;
    line-height: 1;
}

.course-group--a {
    background-color: #2e7d32;
}

.course-group--b {
    background-color: #1565c0;
}

.course-group--c {
    background-color: #e56a00;
}

.course-group--ce {
    background-color: #7b1fa2;
}

.course-group--d {
    background-color: #c62828;
}

.course-group--be {
    background-color: #00796b;
}

/* Termíny profesního školení mohou obsahovat ukazatel kapacity. */
.course-term--prof {
    grid-template-areas:
        "name status"
        "capacity capacity";
    grid-template-columns: minmax(0, 1fr) auto;
}

.course-term__capacity {
    grid-area: capacity;
    margin-top: 6px;
}

.course-term__capacity .graph {
    width: 100%;
    height: 15px;
    background-color: #eee;
}

.course-term__capacity .graphi {
    height: 100%;
}

/* Dialog s přihláškou na profesní školení. */
.course-prof-dialog {
	box-sizing: border-box;
	width: min(900px, 95vw);
	height: min(700px, 90vh);
	height: min(700px, 90dvh);
	max-width: none;
	max-height: none;
	margin: auto;
	padding: 0;
	overflow: hidden;
	border: 0;
	background: #fff;
	box-shadow: 0 5px 25px rgba(0, 0, 0, 0.45);
}

.course-prof-dialog::backdrop {
	background: rgba(0, 0, 0, 0.8);
}

.course-prof-dialog__content {
	display: grid;
	grid-template-rows: auto minmax(0, 1fr);
	width: 100%;
	height: 100%;
}

.course-prof-dialog__toolbar {
	display: flex;
	min-width: 0;
	align-items: center;
	justify-content: flex-end;
	border-bottom: 1px solid #ddd;
	background: #f5f5f5;
}

.course-prof-dialog__external {
	margin-right: auto;
	padding: 8px 12px;
	font-size: 9pt;
}

.course-prof-dialog__close {
	width: 42px;
	height: 42px;
	padding: 0;
	border: 0;
	background: transparent;
	color: #222;
	cursor: pointer;
	font: 28px/1 sans-serif;
}

.course-prof-dialog__close:hover,
.course-prof-dialog__close:focus-visible {
	background: #e5e5e5;
}

.course-prof-dialog__frame {
	display: block;
	width: 100%;
	height: 100%;
	border: 0;
}
