.modern-page--rozvrh .modern-page__layout { max-width: 92rem; }
.modern-page--rozvrh .modern-page-content,
.modern-page--rozvrh .modern-page-content > * { max-width: none; }
.school-schedule { padding: clamp(1rem, 2.5vw, 2rem) !important; background: #fff; border: 1px solid #dce3ec; border-radius: 1.4rem; box-shadow: 0 20px 54px rgba(16, 40, 74, .12); }
.tt-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1.2rem; }
.tt-toolbar .eyebrow { margin: 0 0 .25rem; color: #6d4ed8; font-size: .78rem; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.tt-toolbar h2 { margin: 0; color: #10284a; font-size: clamp(1.5rem, 3vw, 2.35rem); }
.tt-external { display: inline-flex; flex: 0 0 auto; padding: .65rem 1rem; color: #10284a; background: #eef2f7; border-radius: 999px; font-weight: 850; text-decoration: none; }
.tt-external:hover, .tt-external:focus-visible { color: #10284a; background: #b8f35b; }
.tt-type-tabs { display: inline-flex; gap: .35rem; padding: .3rem; margin-bottom: 1rem; background: #eef2f7; border-radius: 999px; }
.tt-type-tabs a { padding: .62rem 1rem; color: #46566c; border-radius: 999px; font-weight: 800; text-decoration: none; }
.tt-type-tabs a.is-active { color: #fff; background: #10284a; box-shadow: 0 5px 18px rgba(16, 40, 74, .2); }
.tt-controls { display: grid; grid-template-columns: minmax(13rem, 1fr) minmax(11rem, .45fr); gap: .8rem; margin-bottom: 1.5rem; }
.tt-controls label { display: grid; gap: .4rem; }
.tt-controls label > span { color: #56657a; font-size: .78rem; font-weight: 850; letter-spacing: .04em; text-transform: uppercase; }
.tt-controls select { width: 100%; min-height: 3.2rem; padding: .72rem 2.6rem .72rem .9rem; color: #10284a; background: #fff; border: 1px solid #cfd8e5; border-radius: .8rem; font: inherit; font-weight: 750; }
.tt-days { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: .75rem; align-items: start; }
.tt-day { min-width: 0; overflow: hidden; background: #f7f9fc; border: 1px solid #e0e6ee; border-radius: 1rem; }
.tt-day > header { display: flex; align-items: baseline; justify-content: space-between; gap: .5rem; padding: .78rem .85rem; color: #fff; background: #10284a; }
.tt-day > header strong { font-size: .9rem; letter-spacing: .1em; }
.tt-day > header span { color: #d7dfec; font-size: .78rem; }
.tt-slots { display: grid; gap: .55rem; padding: .65rem; }
.tt-slot { display: grid; gap: .3rem; }
.tt-slot > time { color: #617086; font-size: .72rem; font-weight: 850; }
.tt-slot__lessons { display: grid; gap: .35rem; }
.tt-lesson { position: relative; overflow: hidden; padding: .65rem .65rem .65rem .78rem; background: #fff; border: 1px solid #e1e6ed; border-radius: .72rem; box-shadow: 0 4px 14px rgba(16, 40, 74, .06); }
.tt-lesson::before { position: absolute; inset: 0 auto 0 0; width: .3rem; background: var(--lesson-color); content: ''; }
.tt-lesson--changed { background: #fff8e9; border-color: #f0c865; }
.tt-lesson--cancelled { background: #f4f5f7; border-color: #c8ced7; }
.tt-lesson--cancelled::before { background: #7b8798; }
.tt-lesson--cancelled .tt-lesson__title strong { color: #6b7280; text-decoration: line-through; }
.tt-lesson--cancelled .tt-lesson__change { color: #a52c38; border-top-color: #d3d7dd; font-weight: 900; }
.tt-lesson__title { display: flex; align-items: start; justify-content: space-between; gap: .45rem; }
.tt-lesson__title strong { color: #10284a; font-size: .83rem; line-height: 1.25; }
.tt-lesson__title span { padding: .15rem .35rem; color: #5b476f; background: #eee8fa; border-radius: .35rem; font-size: .66rem; font-weight: 850; }
.tt-lesson__meta { display: grid; gap: .08rem; margin-top: .34rem; color: #526278; font-size: .7rem; line-height: 1.35; }
.tt-lesson p { margin: .38rem 0 0; color: #66758a; font-size: .7rem; line-height: 1.35; }
.tt-lesson__change { margin-top: .42rem; padding-top: .4rem; color: #8b5900; border-top: 1px dashed #e6c26b; font-size: .68rem; font-weight: 700; line-height: 1.35; }
.tt-dayoff, .tt-day-empty { padding: 1.25rem .75rem; color: #68768a; text-align: center; }
.tt-empty { display: grid; gap: .3rem; padding: 2rem; color: #5b6a7e; background: #f5f7fa; border: 1px dashed #cbd5e1; border-radius: 1rem; text-align: center; }
.tt-empty strong { color: #10284a; }

@media (max-width: 75rem) {
  .tt-days { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 52rem) {
  .school-schedule { margin-inline: -.35rem !important; padding: .8rem !important; }
  .tt-controls { grid-template-columns: 1fr; }
  .tt-days { grid-template-columns: 1fr; }
  .tt-day > header { position: sticky; top: 0; z-index: 1; }
  .tt-slots { gap: .75rem; }
  .tt-slot { grid-template-columns: 4.7rem minmax(0, 1fr); align-items: start; }
  .tt-slot > time { padding-top: .65rem; }
  .tt-lesson { padding: .75rem .75rem .75rem .9rem; }
  .tt-lesson__title strong { font-size: .94rem; }
  .tt-lesson__meta, .tt-lesson p { font-size: .78rem; }
}

@media (max-width: 31rem) {
  .tt-toolbar { align-items: flex-start; }
  .tt-external { padding: .55rem .75rem; font-size: .78rem; }
  .tt-type-tabs { display: grid; grid-template-columns: repeat(3, 1fr); width: 100%; border-radius: .9rem; }
  .tt-type-tabs a { padding: .58rem .4rem; border-radius: .65rem; font-size: .78rem; text-align: center; }
  .tt-slot { grid-template-columns: 1fr; }
  .tt-slot > time { padding-top: 0; }
}
