/* Keep the existing calendar and date details on either side of daily notes. */
.qoom-calendar-window { container: qoom-calendar / inline-size; }
.qoom-calendar-window > .calendar-card {
  display: grid;
  grid-template-columns: minmax(400px, 1.6fr) minmax(260px, 1fr) minmax(220px, .8fr);
  overflow: hidden;
  color: #354052;
}
.qoom-calendar-window .calendar-box { min-width: 0; }
.qoom-calendar-window .box-head { margin-top: 24px; padding: 0 20px; flex-wrap: wrap; gap: 10px; }
.qoom-calendar-window .box-head > div:last-child { font-size: 13px !important; gap: 10px; }
.qoom-calendar-window .box-head .el-switch { margin-left: 0 !important; }
.qoom-calendar-window .calendar-grid { padding: 0 12px; row-gap: 12px; margin-top: 20px; height: calc(100% - 130px); }
.qoom-calendar-window .calendar-grid .items { width: 92%; font-size: 17px; }
.qoom-calendar-window .calendar-grid .items:focus-visible { outline: 2px solid #7d65c7; outline-offset: 2px; }
.qoom-calendar-memo-dot {
  position: absolute; right: 5px; bottom: 5px; width: 7px; height: 7px;
  border-radius: 50%; box-shadow: 0 0 0 1.5px #fff; background: #27a568;
}
.qoom-calendar-memo-dot.is-draft { background: #ef5350; }
.qoom-calendar-window .calendar-lunar { min-width: 0; width: auto; height: 100%; margin: 0; background: #f6f7fb; }
.qoom-calendar-window .lunar-other { padding: 16px; }
.qoom-calendar-window .LR { font-size: 13px; }
.qoom-calendar-memo {
  min-width: 0; min-height: 0; height: 100%; padding: 26px 22px 18px;
  display: flex; flex-direction: column; gap: 20px;
  border-inline: 1px solid #e9ebf3; background: #fcfcff; overflow-y: auto;
}
.qoom-calendar-memo [hidden] { display: none !important; }
.qoom-calendar-memo-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.qoom-calendar-memo h2 { margin: 0 0 7px; font-size: 20px; font-weight: 600; color: #35364b; }
.qoom-calendar-memo time { display: block; font-size: 13px; color: #8c90a1; letter-spacing: .4px; }
.qoom-calendar-memo button {
  flex-shrink: 0; border: 1px solid #e2ddec; border-radius: 9px; padding: 7px 13px;
  background: #fff; color: #7257b4; font: inherit; font-size: 14px; cursor: pointer;
  transition: background .15s, border-color .15s;
}
.qoom-calendar-memo button:hover { background: #f1ecfa; border-color: #c9bcdf; }
.qoom-calendar-memo button:focus-visible { outline: 2px solid #9279c9; outline-offset: 2px; }
.qoom-calendar-memo button:disabled { opacity: .45; cursor: default; }
.qoom-calendar-memo-empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 24px 0; }
.qoom-calendar-memo-empty svg { width: 54px; height: 54px; color: #b8a8d6; margin-bottom: 18px; }
.qoom-calendar-memo-empty p { margin: 0 0 8px; font-size: 15px; color: #66667d; }
.qoom-calendar-memo-empty span { max-width: 220px; font-size: 13px; line-height: 1.7; color: #9a9aab; }
.qoom-calendar-memo-empty button { margin-top: 22px; }
.qoom-calendar-memo-content {
  flex: 1; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 15px; line-height: 1.9;
  color: #505369; user-select: text;
}
.qoom-calendar-memo-form { flex: 1; min-height: 280px; display: flex; flex-direction: column; }
.qoom-calendar-memo-form label { flex: 1; display: flex; flex-direction: column; gap: 10px; font-size: 13px; color: #777b8d; }
.qoom-calendar-memo textarea {
  display: block; width: 100%; flex: 1; min-height: 220px; padding: 14px;
  border: 1px solid #e0deeb; border-radius: 12px; resize: none; background: #fff;
  color: #43475d; font-family: inherit; line-height: 1.8; font-size: 15px;
  outline: none; user-select: text;
}
.qoom-calendar-memo textarea:focus { border-color: #a28cce; box-shadow: 0 0 0 3px #9279c91a; }
.qoom-calendar-memo textarea::placeholder { color: #b0afbd; }
.qoom-calendar-memo-count { text-align: right; font-size: 12px; color: #a2a1af; margin: 8px 0 16px; }
.qoom-calendar-memo-actions { display: flex; justify-content: flex-end; gap: 8px; }
.qoom-calendar-memo .qoom-calendar-memo-save { background: #7d65c7; border-color: #7d65c7; color: #fff; }
.qoom-calendar-memo .qoom-calendar-memo-save:hover:not(:disabled) { background: #6c55b6; }
.qoom-calendar-memo-status { margin: 0; min-height: 18px; font-size: 12px; line-height: 1.6; color: #8f86a6; }
.qoom-calendar-memo-status.is-error { color: #c35466; }
@container qoom-calendar (max-width: 980px) {
  .qoom-calendar-window > .calendar-card { grid-template-columns: minmax(0, 1.3fr) minmax(260px, 1fr); overflow-y: auto; align-content: start; }
  .qoom-calendar-window .calendar-box, .qoom-calendar-memo { height: 560px; }
  .qoom-calendar-window .calendar-lunar { grid-column: 1 / -1; height: auto; overflow: visible; padding-bottom: 16px; }
  .qoom-calendar-window .lunar-other { max-width: 640px; margin: auto; }
}
@container qoom-calendar (max-width: 680px) {
  .qoom-calendar-window > .calendar-card { grid-template-columns: minmax(0, 1fr); }
  .qoom-calendar-window .calendar-box { height: 490px; }
  .qoom-calendar-window .calendar-grid { height: calc(100% - 120px); row-gap: 6px; }
  .qoom-calendar-window .box-head { padding-inline: 16px; }
  .qoom-calendar-window .box-head > div:last-child { display: none !important; }
  .qoom-calendar-memo { height: 430px; padding: 22px; border-inline: 0; border-block: 1px solid #e9ebf3; }
}
