/* Копия оформления старого сайта расписания ШАИ */

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    background: #fff;
    color: #333;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 13px;
}

a { color: #1a4a7a; }

/* ------------------------------------------------ бегущая строка */

.ticker {
    overflow: hidden;
    white-space: nowrap;
    color: #e01010;
    font-size: 13px;
    height: 18px;
    line-height: 18px;
}

.ticker span {
    display: inline-block;
    padding-left: 100%;
    animation: ticker-move 22s linear infinite;
}

@keyframes ticker-move {
    from { transform: translateX(0); }
    to   { transform: translateX(-100%); }
}

/* ------------------------------------------------ шапка */

h1.site-title {
    margin: 14px 0 0;
    text-align: center;
    color: #8d8d8d;
    font-size: 30px;
    font-weight: bold;
    letter-spacing: 2px;
    font-family: Arial, Helvetica, sans-serif;
}

.semester {
    margin: 16px 0 0;
    text-align: center;
    color: #444;
    font-size: 14px;
}

.frieze {
    display: block;
    margin: 22px auto 0;
    max-width: 494px;
    width: 100%;
    height: auto;
}

/* серая полоса «Сегодня / неделя / изменено» */

.statusbar {
    margin: 22px 14px 0;
    padding: 7px 10px;
    text-align: center;
    border-radius: 6px;
    background: linear-gradient(to bottom, #ffffff 0%, #f2f2f2 45%, #d9d9d9 100%);
    box-shadow: 0 1px 2px rgba(0, 0, 0, .18);
    font-size: 14px;
    color: #333;
}

.statusbar .gap { display: inline-block; width: 26px; }
.statusbar .week { color: #e01010; font-size: 17px; font-weight: normal; }

/* ------------------------------------------------ разделы выбора */

.picker { max-width: 760px; margin: 0 auto; padding: 0 12px 40px; text-align: center; }

h2.section {
    margin: 26px 0 6px;
    color: #8d8d8d;
    font-size: 22px;
    font-weight: bold;
}

h3.section {
    margin: 34px 0 8px;
    color: #555;
    font-size: 17px;
    font-family: "Times New Roman", Times, serif;
    font-weight: bold;
}

.hint { margin: 4px 0 10px; color: #6b6b6b; font-size: 13px; }

/* сегментированные кнопки курсов */

.courses { display: inline-flex; margin: 4px 0 6px; border-radius: 5px; overflow: hidden; box-shadow: 0 1px 2px rgba(0,0,0,.25); }

.courses button {
    appearance: none;
    border: 1px solid #b6b6b6;
    border-right-width: 0;
    background: linear-gradient(to bottom, #fdfdfd 0%, #ececec 50%, #dedede 100%);
    color: #333;
    font: inherit;
    font-size: 13px;
    padding: 7px 15px;
    cursor: pointer;
}

.courses button:first-child { border-radius: 5px 0 0 5px; }
.courses button:last-child { border-right-width: 1px; border-radius: 0 5px 5px 0; }
.courses button:hover { background: linear-gradient(to bottom, #ffffff 0%, #f3f3f3 50%, #e6e6e6 100%); }

.courses button.active {
    background: linear-gradient(to bottom, #3d7fb5 0%, #1d5286 55%, #123f6b 100%);
    color: #fff;
    border-color: #14476f;
    text-shadow: 0 -1px 0 rgba(0,0,0,.4);
}

/* обычные кнопки */

.btn {
    appearance: none;
    display: inline-block;
    padding: 6px 14px;
    margin: 8px 4px 0;
    border: 1px solid #b0b0b0;
    border-radius: 5px;
    background: linear-gradient(to bottom, #fcfcfc 0%, #ededed 50%, #dcdcdc 100%);
    color: #222;
    font: inherit;
    font-size: 13px;
    cursor: pointer;
    box-shadow: 0 1px 1px rgba(0,0,0,.15);
}

.btn:hover { background: linear-gradient(to bottom, #ffffff 0%, #f4f4f4 50%, #e7e7e7 100%); }
.btn:active { background: linear-gradient(to bottom, #e2e2e2 0%, #efefef 100%); }
.btn.accent { color: #cc0000; font-weight: bold; }

input[type="text"] {
    width: 210px;
    padding: 3px 5px;
    border: 1px solid #9b9b9b;
    border-radius: 2px;
    font: inherit;
    font-size: 13px;
}

/* выпадающие списки выбора */

.panel {
    max-width: 640px;
    margin: 12px auto 0;
    border: 1px solid #cfcfcf;
    border-radius: 6px;
    background: #fbfbfb;
    text-align: left;
    max-height: 340px;
    overflow-y: auto;
    box-shadow: 0 1px 4px rgba(0,0,0,.12);
}

.panel:empty { display: none; }
.panel .group-of { padding: 6px 10px; background: #eef2f6; color: #33608c; font-weight: bold; border-bottom: 1px solid #dde4ea; position: sticky; top: 0; }
.panel a.item { display: block; padding: 6px 12px; border-bottom: 1px solid #ededed; color: #1a4a7a; text-decoration: none; }
.panel a.item:hover { background: #eaf2fb; }
.panel a.item .muted { color: #888; font-weight: normal; }
.panel .empty { padding: 10px 12px; color: #888; }

.muted { color: #888; }

/* ------------------------------------------------ страница расписания */

.rasp-head { max-width: 1880px; margin: 0 auto; }

.rasp-title {
    margin: 16px 0 4px;
    text-align: center;
    font-size: 21px;
    color: #222;
}

.rasp-title small { font-size: 13px; color: #555; font-weight: normal; }

.tabs { margin: 14px 12px 0; border-bottom: 1px solid #c9c9c9; }

.tabs button {
    appearance: none;
    border: 1px solid #c9c9c9;
    border-bottom: none;
    background: #f4f4f4;
    color: #555;
    font: inherit;
    font-size: 13px;
    padding: 7px 18px;
    margin: 0 2px -1px 0;
    border-radius: 4px 4px 0 0;
    cursor: pointer;
}

.tabs button.active { background: #fff; color: #1a4a7a; border-bottom: 1px solid #fff; }

.grid-wrap { margin: 0 12px; overflow-x: auto; }

table.grid {
    width: 100%;
    min-width: 900px;
    border-collapse: separate;
    border-spacing: 2px;
    margin-top: 6px;
    table-layout: fixed;
}

table.grid th {
    background: linear-gradient(to bottom, #f6f6f6 0%, #e9e9e9 55%, #dcdcdc 100%);
    border: 1px solid #cfcfcf;
    color: #333;
    font-weight: normal;
    font-size: 13px;
    padding: 6px 4px;
    text-align: center;
}

table.grid th.corner { width: 92px; }

table.grid td.daycell {
    background: linear-gradient(to right, #ededed 0%, #e0e0e0 100%);
    border: 1px solid #cfcfcf;
    text-align: center;
    color: #444;
    font-size: 12px;
    width: 92px;
    padding: 4px;
}

table.grid td.daycell .dow { font-size: 15px; color: #333; }
table.grid td.daycell .wk { font-size: 11px; color: #666; }
table.grid td.daycell .date { font-size: 11px; color: #8a8a8a; display: block; }
table.grid td.daycell.today { background: linear-gradient(to right, #ffe9c9 0%, #ffdca8 100%); }

table.grid td.slot {
    border: 1px solid #d6d6d6;
    background: #fff;
    vertical-align: top;
    height: 50px;
    padding: 3px 4px;
    font-size: 12px;
    line-height: 1.35;
}

table.grid td.slot.today { box-shadow: inset 0 0 0 2px #ffcf8a; }

.lesson { border-radius: 4px; padding: 3px 5px; margin-bottom: 3px; }
.lesson:last-child { margin-bottom: 0; }
.lesson .disc { font-weight: bold; color: #222; }
.lesson .meta { color: #444; }
.lesson .tag { color: #666; font-size: 11px; text-transform: uppercase; }
.lesson .repl { color: #cc0000; font-weight: bold; }
.lesson .weeks { color: #777; font-size: 11px; }
.lesson a { color: inherit; text-decoration: none; border-bottom: 1px dotted rgba(0,0,0,.28); }

/* цвета типов занятий — как в легенде старого сайта */
.t-lek   { background: #e2f4dd; }
.t-pr    { background: #d8effb; }
.t-lab   { background: #e6e6f5; }
.t-sem   { background: #f6e6d3; }
.t-kp    { background: #f7f7f7; }
.t-kons  { background: #eef8fc; }
.t-zach  { background: #fbd3d3; }
.t-zacho { background: #fbd3d3; }
.t-ekz   { background: #ffb9b9; }
.t-pekz  { background: #eef8fc; }
.t-other { background: #f2f2f2; }

/* легенда */

.legend { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 14px 12px 0; }

.legend div {
    border-radius: 12px;
    padding: 6px 8px;
    text-align: center;
    font-size: 11px;
    color: #444;
}

/* нижние кнопки */

.toolbar { display: flex; align-items: center; justify-content: center; gap: 14px; margin: 20px 12px 40px; flex-wrap: wrap; }
.toolbar .spacer { width: 40px; }

/* список сессии */

table.list { width: calc(100% - 24px); margin: 10px 12px 0; border-collapse: collapse; }
table.list th { background: linear-gradient(to bottom, #f6f6f6, #e2e2e2); border: 1px solid #cfcfcf; padding: 6px 8px; font-weight: normal; text-align: left; }
table.list td { border: 1px solid #e0e0e0; padding: 6px 8px; }
table.list tr.today td { background: #fff6e6; }

.notice { margin: 24px 12px; text-align: center; color: #777; }
.error { margin: 24px 12px; text-align: center; color: #cc0000; }

/* ------------------------------------------------ печать */

@media print {
    .ticker, .toolbar, .tabs, .frieze, .picker, .backlink { display: none !important; }
    .statusbar { box-shadow: none; }
    table.grid { min-width: 0; }
    body { font-size: 11px; }
}
