/**
 * assets/css/widget-calendar.css — стили виджета календаря дат заездов (template-parts/widget-calendar.php).
 */

.st-cal {
  font-family: inherit;
  background: var(--secondary-background);
  padding: 20px;
  border-radius: 10px;
}

/* Шапка на одной строке */
.st-cal__title {
  margin: 0 0 15px;
}

.st-cal__header {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  margin-bottom: 10px;
  font-size: 16px;
  font-weight: bold;
}

.st-cal__nav {
  font-weight: 500;
  background: none;
  border: none;
  cursor: pointer;
  padding: 5px;
  border-radius: 5px;
  display: flex;
  align-items: center;
  color: black;
  transition-property: background-color, color;
  transition-timing-function: ease;
  transition-duration: 200ms;
  font-size: 1em;
  line-height: 1.25;
  text-transform: unset;
  width: fit-content;
}

.st-cal__nav:hover {
  background-color: var(--primary-color-light);
  color: var(--primary-color);
}

.st-cal__nav:last-child {
  justify-self: flex-end;
}

.st-cal__nav-label {
  margin: 0 5px;
}

.st-cal__current-month {
  font-weight: bold;
  text-transform: capitalize;
}

/* Таблица */
.st-cal__table {
  width: 100%;
  border-collapse: collapse;
  margin: 0;
}

.st-cal__th {
  font-size: 11px;
  color: #bbb;
  text-transform: uppercase;
  padding: 5px 5px 10px;
  font-weight: normal;
}

.st-cal__td {
  padding: 5px 0;
  text-align: center;
  font-size: 13px;
  width: calc(100% / 7);
}

.st-cal__tr {
  border-radius: 5px;
}

.st-cal__day-num {
  display: inline-block;
  width: 28px;
  height: 28px;
  line-height: 28px;
}

/* Выходные и праздники */
.st-cal__td--weekend .st-cal__day-num,
.st-cal__td--holiday .st-cal__day-num {
  color: #ff0000;
}
.st-cal__td--inactive .st-cal__day-num {
  color: #999;
}

/* Сегодня */
.st-cal__td--today .st-cal__day-num {
  border: 1px solid #333;
  border-radius: 50%;
}

/* Дни с турами */
.st-cal__td--has-trip .st-cal__link {
  background: var(--primary-color);
  color: #fff;
  text-decoration: none;
  display: inline-block;
  width: 28px;
  height: 28px;
  line-height: 28px;
  border-radius: 50%;
  font-weight: bold;
}

/* Футер */
.st-cal__footer {
  margin-top: 15px;
  padding-top: 10px;
  border-top: 1px dashed #eee;
  font-size: 12px;
  color: #666;
  text-align: center;
}
