.calendar-heading { align-items: flex-end; margin-top: 0; }
.calendar-heading > div:first-child { margin-right: auto; }
.calendar-heading h3 { margin-bottom: 4px; }
.calendar-heading span { color: var(--work-muted); font-size: 12px; }
.calendar-controls { display: flex; gap: 6px; }
.work-calendar { border: 1px solid var(--work-line); border-radius: 14px; overflow: hidden; background: var(--work-surface); margin-bottom: 20px; }
.calendar-weekdays, .calendar-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.calendar-weekdays { background: var(--work-tint); border-bottom: 1px solid var(--work-line); }
.calendar-weekdays span { padding: 9px; text-align: center; color: var(--work-muted); font-size: 12px; }
.calendar-day { min-height: 128px; padding: 9px; border-right: 1px solid var(--work-line); border-bottom: 1px solid var(--work-line); min-width: 0; }
.calendar-day:nth-child(7n) { border-right: 0; }
.calendar-day:nth-last-child(-n+7) { border-bottom: 0; }
.calendar-day > time { display: grid; place-items: center; width: 27px; height: 27px; margin-bottom: 5px; color: var(--work-muted); font-size: 12px; border-radius: 50%; }
.calendar-day.is-today > time { background: var(--work-accent); color: #fff; font-weight: 700; }
.calendar-day.is-outside { opacity: .42; background: color-mix(in srgb, var(--work-tint) 45%, transparent); }
.calendar-task { display: grid; gap: 2px; width: 100%; margin: 4px 0; padding: 6px 7px; border: 0; border-left: 3px solid var(--work-accent); border-radius: 5px; background: var(--work-tint); color: var(--work-text); text-align: left; cursor: pointer; }
.calendar-task.priority-urgent { border-left-color: #b94c37; }
.calendar-task.priority-high { border-left-color: #bf8b24; }
.calendar-task span, .calendar-task small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.calendar-task span { font-size: 11px; font-weight: 650; }
.calendar-task small, .calendar-more { color: var(--work-muted); font-size: 10px; }
.calendar-lower { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; }
.recurrence-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--work-line); }
.recurrence-row > div { display: grid; gap: 4px; min-width: 0; }
.recurrence-row strong { overflow-wrap: anywhere; }
.recurrence-row span { color: var(--work-muted); font-size: 12px; }
.timeline-row { display: grid; grid-template-columns: 12px minmax(0, 1fr); gap: 9px; width: 100%; padding: 10px 0; border: 0; border-bottom: 1px solid var(--work-line); color: var(--work-text); background: transparent; text-align: left; cursor: pointer; }
.timeline-dot { width: 8px; height: 8px; margin-top: 5px; border-radius: 50%; background: var(--work-accent); }
.timeline-row > span:last-child { display: grid; gap: 3px; min-width: 0; }
.timeline-row small { color: var(--work-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rhythm-entry { padding: 13px 0; border-bottom: 1px solid var(--work-line); }
.rhythm-entry header { display: flex; justify-content: space-between; gap: 12px; }
.rhythm-entry header span { color: var(--work-muted); font-size: 11px; }
.rhythm-entry p { display: grid; grid-template-columns: 70px minmax(0, 1fr); gap: 10px; margin: 8px 0 0; color: var(--work-muted); font-size: 12px; white-space: pre-wrap; }
.rhythm-entry b { color: var(--work-text); font-weight: 600; }
@media (max-width: 900px) { .calendar-lower { grid-template-columns: 1fr; } .calendar-day { min-height: 100px; padding: 6px; } .calendar-task small { display: none; } }
@media (max-width: 600px) { .calendar-heading { align-items: stretch; } .calendar-heading, .calendar-heading > .work-header-actions { display: grid; grid-template-columns: 1fr; } .calendar-controls { justify-content: space-between; } .work-calendar { overflow-x: auto; } .calendar-weekdays, .calendar-days { min-width: 700px; } }
