/* Задача 13: «Отменить», отзыв колоды, «Обновить у учеников», журнал действий */
.undo-bar{position:fixed;left:50%;transform:translateX(-50%);bottom:calc(16px + env(safe-area-inset-bottom,0px));z-index:1000;display:flex;align-items:center;gap:12px;width:min(560px,calc(100% - 24px));padding:12px 12px 12px 16px;border-radius:16px;background:#092556;color:#fff;box-shadow:0 10px 30px rgba(9,37,86,.28);overflow:hidden}
.undo-bar[hidden]{display:none}
.undo-text{flex:1;min-width:0;font-size:14.5px;line-height:1.35;overflow-wrap:anywhere}
.undo-btn{flex:none;min-height:40px;padding:0 14px;border:0;border-radius:10px;background:#FFD54A;color:#092556;font:inherit;font-weight:800;cursor:pointer}
.undo-btn:disabled{opacity:.6}
.undo-time{position:absolute;left:0;bottom:0;height:3px;width:100%;background:#FFD54A;transform-origin:left}
@keyframes undo-time{from{transform:scaleX(1)}to{transform:scaleX(0)}}
@media (prefers-reduced-motion:reduce){.undo-time{display:none}}
/* Отзыв колоды в «Кому отправлена» */
.ds-group-top{display:flex;justify-content:space-between;align-items:flex-start;gap:10px}
.ds-act{flex:none;min-height:36px;padding:0 12px;border-radius:10px;border:1px solid #DCE3EF;background:#fff;color:#092556;font:inherit;font-size:13px;font-weight:700;cursor:pointer}
.ds-act.ds-revoke{color:#9A1B12;border-color:#F3C9C4}
.ds-act.ds-return{color:#0F5132;border-color:#BFE3CC}
.ds-act:disabled{opacity:.55}
.ds-student{display:flex;flex-direction:column;gap:4px}
.ds-student-line{display:flex;gap:6px;align-items:stretch}
.ds-student-line .ds-student-btn{flex:1;min-width:0}
.ds-student-line .ds-act{min-height:46px;border-radius:12px}
.ds-closed .ds-student-btn{background:#F7F9FC;color:#5E6F92}
.ds-off{background:#EEF2F8;color:#7A1A14}
.ds-tag{font-size:12px;color:#5E6F92;padding-left:12px}
.ds-group.ds-group-off{background:#FBFBFD;border-style:dashed}
.ds-update{display:flex;flex-wrap:wrap;align-items:center;gap:8px 12px;margin:0 0 10px;padding:10px 12px;border-radius:12px;background:#FFF8E1;border:1px solid #F5E1A4;font-size:13.5px;color:#5C4400}
.ds-update .ds-act{margin-left:auto}
/* Окно «Что изменится» */
dialog.deck-update .dialog-inner{max-width:560px}
.du-sum{margin:0 0 10px;font-size:14px;color:#183E86;line-height:1.45}
.du-list{list-style:none;margin:0 0 12px;padding:0;display:flex;flex-direction:column;gap:6px;max-height:44vh;overflow:auto}
.du-list li{display:flex;gap:8px;align-items:baseline;padding:8px 10px;border-radius:10px;background:#F7F9FC;border:1px solid #E3E9F3;font-size:14px;overflow-wrap:anywhere}
.du-list b{flex:none;font-size:12px;padding:2px 6px;border-radius:6px}
.du-add b{background:#E6F5EC;color:#0F5132}.du-del b{background:#FDECEA;color:#7A1A14}.du-chg b{background:#FFF4CC;color:#6B4C00}
.du-note{font-size:13px;color:#5E6F92;line-height:1.45;margin:0 0 12px}
.du-actions{display:flex;gap:8px;flex-wrap:wrap}.du-actions button{min-height:48px}
/* Журнал действий */
.tlog>summary{list-style:none;display:flex;flex-wrap:wrap;justify-content:space-between;gap:6px 12px;align-items:center;cursor:pointer;min-height:44px}
.tlog>summary::-webkit-details-marker{display:none}
.tlog>summary strong{font-size:16px}.tlog>summary span{font-size:13px;color:#60738a}
.tlog>summary:after{content:'▾';margin-left:auto;color:#60738a}.tlog[open]>summary:after{content:'▴'}
.tlog-list{list-style:none;margin:8px 0 0;padding:0;display:flex;flex-direction:column}
.tlog-list li{display:grid;grid-template-columns:auto 1fr;gap:2px 10px;padding:8px 0;border-top:1px solid #E3E9F3;font-size:14px}
.tlog-list time{grid-row:span 2;font-size:12.5px;color:#60738a;white-space:nowrap;padding-top:2px}
.tlog-list small{color:#60738a;font-size:12.5px;overflow-wrap:anywhere}
.tlog-day{grid-template-columns:1fr!important;font-weight:700;color:#183E86;border-top:0!important;padding-top:12px!important}
.tlog-more{margin-top:8px;min-height:40px}
.tlog [hidden]{display:none!important}
@media (max-width:640px){dialog#deck-update{position:fixed;inset:auto 0 0 0;margin:0;width:100%;max-width:none;max-height:92vh;overflow:auto;border-radius:28px 28px 0 0}}
/* «Добавить учеников» */
.ta-result p{margin:6px 0;padding:8px 10px;border-radius:10px;font-size:13.5px;line-height:1.4;overflow-wrap:anywhere}
.ta-ok{background:#E6F5EC;color:#0F5132}.ta-same{background:#EEF2F8;color:#4A5B7E}.ta-bad{background:#FDECEA;color:#7A1A14}
.deck-update .error:empty,#teacher-add-form .error:empty{display:none}
@media (max-width:640px){.ds-student-line .ds-student-btn{flex-wrap:wrap;row-gap:4px}}
