/**
 * The venue scheduler, on top of the application frame (apply.css).
 *
 * A month at a time, because a rental is planned months ahead — a day strip
 * like the visit panel's would be thirty days of scrolling for something
 * somebody wants next April. A day that has nothing free is disabled and says
 * why; a day that does carries a mark, so the shape of a busy month is
 * visible before anything is clicked.
 */

.cal {
  border: 2px solid var(--line-strong);
  border-radius: 4px;
  background: var(--surface);
  padding: 12px;
}

.cal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}

.cal__month {
  flex: 1;
  margin: 0;
  text-align: center;
  font-weight: 700;
}

.cal__nav {
  flex: none;
  min-width: 44px;
  min-height: 44px;
  border: 2px solid var(--line-strong);
  border-radius: 4px;
  background: var(--paper);
  color: var(--ink);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}

.cal__nav:hover:not([disabled]) {
  background: var(--accent-soft);
}

.cal__nav[disabled] {
  opacity: 0.3;
  cursor: default;
}

.cal__grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
}

.cal__dow {
  padding-bottom: 4px;
  text-align: center;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--muted);
}

.cal__blank {
  min-height: 44px;
}

.cal__day {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 4px;
  background: var(--paper);
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.cal__day:hover:not([disabled]) {
  border-color: var(--line-strong);
}

.cal__day[disabled] {
  background: transparent;
  color: var(--muted);
  opacity: 0.45;
  cursor: default;
}

/* A day with room left says so without relying on colour alone. */
.cal__day.is-open::after {
  content: '';
  position: absolute;
  bottom: 5px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--ink);
}

.cal__day.is-on,
.cal__day.is-on:hover {
  border-color: var(--ink);
  background: var(--accent);
  color: var(--on-accent);
}

.cal__day.is-on::after {
  background: var(--on-accent);
}

.cal__key {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 10px 0 0;
  color: var(--muted);
}

.cal__key span {
  flex: none;
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-top: 8px;
  border-radius: 50%;
  background: var(--ink);
}

/* ---- The times on the chosen day ----------------------------------------- */

.slots {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}

.slot {
  min-height: 44px;
  padding: 8px 16px;
  border: 2px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.slot:hover {
  background: var(--accent-soft);
}

.slot.is-on {
  border-color: var(--ink);
  background: var(--accent);
  color: var(--on-accent);
}

/* ---- What has been chosen, and what it costs ------------------------------ */

.hold {
  margin-top: 20px;
  padding: 16px 18px;
  border: 2px solid var(--line-strong);
  border-radius: 4px;
  background: var(--accent-soft);
}

.hold dl {
  display: grid;
  gap: 8px;
  margin: 12px 0 0;
}

.hold .fact {
  gap: 2px;
}

.pay__card {
  min-height: 56px;
}

@media (min-width: 640px) {
  .hold dl {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 24px;
  }
}
