@charset "utf-8";

/*==================================================
獣医師出勤表
===================================*/
.shift-cal {
	--shift-brown: #8b4513;
	--shift-line: #e3d6c3;
	--shift-head: #fff5df;
	--shift-close-bg: #f2ece1;
	--shift-close-text: #a89477;
	--shift-name-w: 110px;
	--shift-period-w: 54px;
	font-size: 15px;
	color: #707070;
}

/* --- 月タブ --- */
.shift-cal__tabs {
	display: flex;
	justify-content: center;
	flex-wrap: wrap;
	gap: 10px;
	margin: 0 auto 24px;
	padding: 0;
	list-style: none;
}
.shift-cal__tab {
	appearance: none;
	border: 1px solid var(--shift-brown);
	background: #ffffff;
	color: var(--shift-brown);
	font-family: inherit;
	font-size: 17px;
	line-height: 1;
	padding: 11px 26px;
	border-radius: 999px;
	cursor: pointer;
	transition: background-color .2s, color .2s;
}
.shift-cal__tab:hover {
	background: var(--shift-head);
}
.shift-cal__tab.is-active {
	background: var(--shift-brown);
	color: #ffffff;
}

/* --- パネル --- */
.shift-cal__panel {
	display: none;
}
.shift-cal__panel.is-active {
	display: block;
}
.shift-cal__month {
	text-align: center;
	color: var(--shift-brown);
	font-size: 22px;
	margin: 0 0 14px;
}

/* --- 横スクロール --- */
.shift-cal__scroll {
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
	border: 1px solid var(--shift-line);
	border-radius: 6px;
	background: #ffffff;
}

/* --- 表本体 --- */
.shift-cal__table {
	border-collapse: separate;
	border-spacing: 0;
	width: max-content;
	min-width: 100%;
	table-layout: fixed;
	background: #ffffff;
}
.shift-cal__table th,
.shift-cal__table td {
	border-right: 1px solid var(--shift-line);
	border-bottom: 1px solid var(--shift-line);
	padding: 8px 4px;
	text-align: center;
	vertical-align: middle;
	font-weight: normal;
	white-space: nowrap;
}
.shift-cal__table tr:last-child th,
.shift-cal__table tr:last-child td {
	border-bottom: none;
}

/* 日付ヘッダー */
.shift-cal__week th {
	width: 62px;
	min-width: 62px;
	background: var(--shift-head);
	color: var(--shift-brown);
	font-size: 13px;
	line-height: 1.4;
	position: sticky;
	top: 0;
	z-index: 2;
}
.shift-cal__wd {
	font-size: 11px;
}
.shift-cal__week th.is-sun {
	color: #ff2727;
}
.shift-cal__week th.is-sat {
	color: #2b7fd4;
}
.shift-cal__week th.is-close {
	background: var(--shift-close-bg);
	color: #a89477;
}

/* 左端の固定2列 */
.shift-cal__corner,
.shift-cal__name,
.shift-cal__period {
	position: sticky;
	z-index: 3;
	background: #ffffff;
}
.shift-cal__corner {
	left: 0;
	width: calc(var(--shift-name-w) + var(--shift-period-w));
	min-width: calc(var(--shift-name-w) + var(--shift-period-w));
	background: var(--shift-head);
	z-index: 4;
}
.shift-cal__corner-label {
	color: var(--shift-brown);
	font-size: 15px;
}
.shift-cal__name {
	left: 0;
	width: var(--shift-name-w);
	min-width: var(--shift-name-w);
	color: var(--shift-brown);
	font-size: 14px;
	border-left: 4px solid var(--doctor-color, transparent);
}
.shift-cal__period {
	left: var(--shift-name-w);
	width: var(--shift-period-w);
	min-width: var(--shift-period-w);
	background: #fbf8f1;
	font-size: 13px;
	box-shadow: 2px 0 4px rgba(0, 0, 0, .06);
}

/* 記号 */
.shift-cal__table td.is-open {
	font-size: 16px;
}
.shift-cal__table td.is-off {
	color: #d0c9bd;
	font-size: 15px;
}
.shift-cal__table td.is-close {
	background: var(--shift-close-bg);
	color: #a89477;
	font-size: 14px;
}

/* 獣医師の区切り */
.shift-cal__row--first th,
.shift-cal__row--first td {
	border-top: 2px solid var(--shift-line);
}
.shift-cal__table tbody tr:first-child th,
.shift-cal__table tbody tr:first-child td {
	border-top: none;
}

.shift-cal__empty {
	text-align: center;
	font-size: 16px;
	color: #a08c6c;
}

/*==================================================
タブレット
===================================*/
@media screen and (max-width: 1024px) {
	.shift-cal {
		--shift-name-w: 92px;
		--shift-period-w: 48px;
	}
	.shift-cal__week th {
		width: 56px;
		min-width: 56px;
	}
}

/*==================================================
スマートフォン
===================================*/
@media screen and (max-width: 767px) {
	.shift-cal {
		--shift-name-w: 78px;
		--shift-period-w: 42px;
		font-size: 13px;
	}
	.shift-cal__tab {
		font-size: 15px;
		padding: 9px 20px;
	}
	.shift-cal__month {
		font-size: 18px;
	}
	.shift-cal__week th {
		width: 48px;
		min-width: 48px;
		font-size: 11px;
	}
	.shift-cal__wd {
		font-size: 10px;
	}
	.shift-cal__name {
		font-size: 12px;
	}
	.shift-cal__period {
		font-size: 11px;
	}
	.shift-cal__table th,
	.shift-cal__table td {
		padding: 6px 2px;
	}
}
