.wo-calendar-wrap {
  position: relative;
  max-width: 100%;
  border: 1px solid #d9dde3;
  background: #fff;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
}

.wo-calendar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  padding: 18px 20px;
  border-bottom: 1px solid #e8ebef;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
}

.wo-calendar-title {
  margin: 0;
  font-size: 1.4rem;
  text-align: center;
}

.wo-nav-btn {
  border: 1px solid #cfd6de;
  background: #fff;
  padding: 10px 14px;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  border-radius: 10px;
  transition: background 0.2s ease, transform 0.2s ease;
}

.wo-nav-btn:hover {
  background: #f4f7fa;
  transform: translateY(-1px);
}

.wo-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.wo-calendar-heading {
  padding: 12px 10px;
  background: #f7f9fb;
  border-bottom: 1px solid #e8ebef;
  border-right: 1px solid #e8ebef;
  font-weight: 600;
  text-align: center;
  font-size: 14px;
}

.wo-calendar-heading:last-child {
  border-right: 0;
}

.wo-calendar-day {
  min-height: 130px;
  padding: 10px;
  border-right: 1px solid #e8ebef;
  border-bottom: 1px solid #e8ebef;
  box-sizing: border-box;
  background: #fff;
}

.wo-calendar-day:nth-child(7n) {
  border-right: 0;
}

.wo-calendar-day--empty {
  background: #fafbfd;
}

.wo-calendar-day-number {
  font-weight: 700;
  margin-bottom: 8px;
  color: #1c2430;
}

.wo-calendar-day--has-events {
  background: #fcfdff;
}

.wo-calendar-events {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.wo-event-link {
  --wo-event-colour: #1b3a70;
  display: block;
  width: 100%;
  text-align: left;
  border: 0;
  border-left: 4px solid var(--wo-event-colour);
  background: #f4f7fb;
  color: #1b2430;
  padding: 7px 9px;
  cursor: pointer;
  font-size: 13px;
  line-height: 1.35;
  border-radius: 8px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.wo-event-link:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.08);
}

.wo-event-time {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: var(--wo-event-colour);
  margin-bottom: 2px;
}

.wo-event-title {
  display: block;
}


.wo-view-toggle {
  display: flex;
  gap: 10px;
  padding: 16px 20px 0;
  background: #fff;
}

.wo-view-btn {
  border: 1px solid #cfd6de;
  background: #fff;
  padding: 10px 16px;
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
  border-radius: 10px;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.wo-view-btn:hover {
  background: #f4f7fa;
}

.wo-view-btn.is-active {
  background: #1b3a70;
  color: #fff;
  border-color: #1b3a70;
}

.wo-list-view {
  background: #fff;
}

.wo-list-items {
  padding: 20px;
}

.wo-list-item {
  margin-bottom: 15px;
}

.wo-list-item:last-child {
  margin-bottom: 0;
}

.wo-list-item__button {
  border-left-width: 6px;
  background: #fff;
  border: 1px solid #e8ebef;
  border-left: 6px solid var(--wo-event-colour);
  padding: 16px 18px;
}

.wo-list-item__date {
  font-size: 13px;
  font-weight: 700;
  color: #556070;
  margin-bottom: 6px;
}

.wo-list-item__title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.wo-list-item__meta {
  font-size: 14px;
  margin-top: 4px;
}

.wo-no-events {
  margin: 0;
  padding: 18px;
  border: 1px solid #e8ebef;
  border-radius: 10px;
  background: #f8fafc;
}

.wo-modal-details-heading {
  margin: 18px 0 8px;
  font-size: 16px;
  font-weight: 700;
}

.wo-loading-indicator[hidden],
.wo-modal[hidden] {
  display: none;
}

.wo-loading .wo-loading-indicator {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.78);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  z-index: 5;
  backdrop-filter: blur(1px);
}

.wo-spinner {
  width: 22px;
  height: 22px;
  border: 3px solid #d9dde3;
  border-top-color: #1b3a70;
  border-radius: 50%;
  animation: wo-spin 0.8s linear infinite;
}

@keyframes wo-spin {
  to {
    transform: rotate(360deg);
  }
}

.wo-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
}

.wo-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(12, 18, 27, 0.6);
}

.wo-modal__dialog {
  position: relative;
  max-width: 620px;
  margin: 7vh auto;
  background: #fff;
  z-index: 2;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
  border-radius: 18px;
  overflow: hidden;
}

.wo-modal__content {
  padding: 28px;
}

.wo-modal__content h3 {
  margin: 0 0 10px;
  font-size: 1.6rem;
}

.wo-modal__meta {
  display: inline-block;
  margin: 0 0 16px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #f4f7fb;
  font-size: 12px;
  font-weight: 700;
}

.wo-modal__row {
  margin: 0 0 10px;
}

.wo-modal__label {
  font-weight: 700;
}

.wo-modal__details {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid #e8ebef;
  white-space: pre-line;
}

.wo-modal__close {
  position: absolute;
  top: 10px;
  right: 12px;
  border: 0;
  background: transparent;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  color: #5b6572;
}

body.wo-modal-open {
  overflow: hidden;
}

.wo-admin-table th {
  width: 180px;
}

.wo-admin-help {
  max-width: 900px;
}

.wo-admin-card {
  background: #fff;
  border: 1px solid #d9dde3;
  border-radius: 14px;
  padding: 20px;
  margin-top: 20px;
}

.wo-admin-card h2 {
  margin-top: 0;
}

@media (max-width: 782px) {
  .wo-view-toggle {
    padding: 12px 12px 0;
    flex-wrap: wrap;
  }

  .wo-list-items {
    padding: 12px;
  }

  .wo-calendar-grid--headings {
    display: none;
  }

  .wo-calendar-grid--days {
    grid-template-columns: 1fr;
  }

  .wo-calendar-day {
    min-height: 0;
    border-right: 0;
  }

  .wo-calendar-header {
    padding: 12px;
  }

  .wo-calendar-title {
    font-size: 1.15rem;
  }

  .wo-modal__dialog {
    margin: 4vh 15px;
    max-width: none;
  }

  .wo-modal__content {
    padding: 22px 18px;
  }
}


.wo-list-month-group {
    margin-bottom: 28px;
}

.wo-list-month-heading {
    margin: 0 0 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e5e5e5;
    font-size: 1.1em;
}
