@charset "UTF-8";

:root {
  --color-text-main: #35383b;
  --color-bg-white: #fff;
  --color-border-light: #d5d7db;
  --color-bg-hover: #f0f0f0;
  --color-weekend-sat-text: #0059b3;
  --color-weekend-sat-bg: #e6f2ff;
  --color-weekend-sun-text: #cc0000;
  --color-weekend-sun-bg: #ffebeb;
  --color-spinner: #000;
}

/* カレンダーナビゲーション */
.calendar-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  padding: 0 4px;
}

.calendar-nav-title {
  font-size: 18px;
  font-weight: bold;
  color: var(--color-text-main);
}

.calendar-nav-btn {
  background-color: var(--color-bg-white);
  border: 1px solid var(--color-border-light);
  border-radius: 4px;
  padding: 8px 16px;
  font-size: 14px;
  color: var(--color-text-main);
  cursor: pointer;
  transition: background-color 0.2s;
}

.calendar-nav-btn:hover {
  background-color: var(--color-bg-hover);
}

.calendar-nav-placeholder {
  width: 100px;
}

.calendar table {
  width: 100%;
  margin-inline: auto;
  min-width: 940px;
  border-spacing: 0;
}

.table_work_ca {
  border-left: solid 1px var(--color-border-light);
  border-top: solid 1px var(--color-border-light);
  width: 100%;
}

.table_work_ca th,
.table_work_ca td {
  text-align: center;
  width: calc(100% / 7);
  border-right: solid 1px var(--color-border-light);
  border-bottom: solid 1px var(--color-border-light);
  color: var(--color-text-main);
  font-size: 12px;
}

.table_work_ca th {
  border-bottom: none;
  padding: 8px 0 0;
  font-weight: normal;
}

.table_work_ca .tc_date {
  padding: 8px 0;
}

.table_work_ca .tc_sche {
  color: var(--color-bg-white);
  vertical-align: top;
  height: 150px;
}

.table_work_ca td span {
  display: block;
  border-radius: 5px;
  padding: 6px 8px;
  font-size: 12px;
  text-align: left;
  margin: 2px;
}

.table_work_ca .saturday {
  color: var(--color-weekend-sat-text);
  background-color: var(--color-weekend-sat-bg);
}

.table_work_ca .sunday,
.table_work_ca .holiday {
  color: var(--color-weekend-sun-text);
  background-color: var(--color-weekend-sun-bg);
}

@media screen and (max-width: 960px) {
  .calendar-wrap {
    overflow-x: hidden;
  }

  .calendar table {
    min-width: 0;
    table-layout: fixed;
  }

  .table_work_ca th,
  .table_work_ca td {
    overflow-wrap: anywhere;
    word-break: break-word;
  }
}

@media screen and (max-width: 768px) {
  .table_work_ca .tc_sche {
    height: 100px;
  }

  .table_work_ca td span {
    padding: 1px 2px;
    font-size: 10px;
  }
}

.loading {
  position: relative;
  height: 150px;
}

.loading:before {
  content: "読み込み中";
  display: block;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, 40px);
}

.loading:after {
  content: "";
  display: block;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(0deg);
  width: 50px;
  height: 50px;
  border: 5px solid var(--color-spinner);
  border-right: 5px solid transparent;
  border-radius: 50%;
  animation: loading 2s linear infinite;
}

@keyframes loading {
  0% {
    opacity: 0.3;
  }
  50% {
    opacity: 0.9;
  }
  100% {
    transform: translate(-50%, -50%) rotate(360deg);
    opacity: 0.3;
  }
}
