/* Расписание и календарь. Токены и шрифты — общие с журналом (app.css), стиль Yaca:
   плоские карточки с тонкой рамкой, моноширинные подписи, акцент только на важном. */

.slot-top { flex: none; }
.sch-list { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 4px var(--gut) calc(28px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 12px; }
.pill { flex: none; height: 38px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--accent); background: var(--accent-soft); color: var(--accent-ink); font: 600 13px/1 var(--f-body); }

/* ---------- полоса недели ---------- */
.wk { display: flex; align-items: center; gap: 2px; margin: 0 -6px; }
.wk .step { flex: none; width: 28px; height: 56px; display: grid; place-items: center; color: var(--muted); }
.wk .step svg { width: 20px; height: 20px; }
.wk-days { flex: 1; min-width: 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 4px; }
.wd { height: 62px; border-radius: var(--r); border: 1px solid var(--line); background: var(--surface); display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 4px; }
.wd .w { font: 600 10px/1 var(--f-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.wd .n { font-size: 17px; font-weight: 600; line-height: 1; }
.wd i { width: 5px; height: 5px; border-radius: 50%; background: transparent; }
.wd.has i { background: var(--line-strong); }
.wd.dim { background: transparent; border-style: dashed; }
.wd.dim .n { color: var(--muted); font-weight: 500; }
.wd.today { border-color: var(--accent); }
.wd.today .n { color: var(--accent-ink); }
.wd.sel { background: var(--accent-soft); border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.wd.sel .w { color: var(--accent-ink); }

/* ---------- карточки пар ---------- */
.lessons { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.les { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; }
.les-top { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; font-size: 13px; color: var(--muted); }
.les-top time { font-weight: 600; color: var(--ink); }
.les-title { font-size: 16px; font-weight: 600; line-height: 1.25; overflow-wrap: anywhere; }
.les-meta { display: flex; align-items: center; gap: 4px 10px; font-size: 14px; color: var(--muted); }
.les-meta .who { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.les-meta .unknown { font-style: italic; }
/* Тип пары: цветная плашка у правого края. Цвета из токенов Yaca, в тёмной теме меняются сами. */
.kind { flex: none; margin-left: auto; font: 600 12px/1 var(--f-mono); padding: 5px 9px; border-radius: 6px; border: 1px solid var(--line); background: var(--zebra); color: var(--muted); }
.kind.k-lecture { background: var(--accent-soft); border-color: var(--accent); color: var(--accent-ink); }
.kind.k-practice { background: var(--present-bg); border-color: var(--present-line); color: var(--present-ink); }
.kind.k-lab { background: var(--note-bg); border-color: var(--note-line); color: var(--warn); }
.kind.k-seminar { background: var(--sem-bg); border-color: var(--sem-line); color: var(--sem-ink); }
.kind.k-exam { background: var(--del-bg); border-color: var(--stale); color: var(--stale); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags:empty { display: none; }
.tag { font: 500 12px/1 var(--f-mono); padding: 5px 8px; border-radius: 6px; border: 1px solid var(--line); background: var(--zebra); color: var(--muted); }
.tag.live { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-ink); }
.les.now { background: var(--accent-soft); border-color: var(--accent); }
.les.now .tag.live { background: var(--surface); }
.gap { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--muted); padding: 0 4px; }
.gap::before, .gap::after { content: ""; flex: 1; border-top: 1px dashed var(--line-strong); opacity: .6; }

.void { border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); padding: 22px 18px; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; margin-top: 4px; }
.void.dashed { background: transparent; border-style: dashed; border-color: var(--line-strong); }
.void-t { font-size: 20px; font-weight: 600; line-height: 1.2; }
.void p { color: var(--muted); max-width: 36ch; }
.void .btn { margin-top: 6px; }

/* ---------- календарь ---------- */
.cal { display: flex; flex-direction: column; gap: 12px; }
.cal-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.cal-title { font-size: 17px; font-weight: 600; }
.cal-title .mono { color: var(--muted); font-weight: 500; font-size: 13px; }
.cal-head .icon-btn[disabled] { opacity: .35; cursor: default; }
.cal-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 4px; }
.cal-grid b { text-align: center; font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding-bottom: 2px; }
.cd { height: 46px; border-radius: 8px; border: 1px solid transparent; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; background: var(--surface); }
.cd .mono { font-size: 14px; font-weight: 500; }
.cd i { width: 5px; height: 5px; border-radius: 50%; }
.cd.has i { background: var(--line-strong); }
.cd.dim { background: transparent; color: var(--muted); }
.cd.today { border-color: var(--accent); }
.cd.sel { background: var(--accent-soft); border-color: var(--accent); color: var(--accent-ink); }
.cal-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 11px; color: var(--muted); }
.lg::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; margin-right: 6px; vertical-align: 1px; }
.lg.has::before { background: var(--line-strong); }
.lg.dim::before { border: 1px dashed var(--line-strong); }
.cal-note { font-size: 13px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 12px; }

@media (min-width: 640px) {
  .sch-list { padding-left: var(--gut); padding-right: var(--gut); }
  .wk-days { max-width: 520px; }
}
@media (hover: hover) {
  .wd:hover:not(.sel), .cd:hover:not(.sel) { background: var(--zebra); }
}
