/* Главная «Сегодня»: рабочий день без лишнего шума */
.today-home{max-width:1440px;margin:0 auto}
.today-head{align-items:flex-start!important;gap:20px 28px!important;margin-bottom:20px!important}
.today-head .grow{flex:1 1 480px!important}
.today-head h1{font-size:34px;line-height:1.15;letter-spacing:-.035em;margin:3px 0 14px!important}
.today-head .v11-ph-date{color:var(--accent);font-size:12px}
.today-head .qbar{flex:0 1 auto;justify-content:flex-end;margin:20px 0 0;max-width:520px}
.today-head .qa{min-height:40px;display:inline-flex;align-items:center;justify-content:center}
.today-summary{display:flex;align-items:stretch;flex:1 0 100%;flex-wrap:nowrap;gap:0!important;margin:0!important;padding:4px;background:var(--surface);border:1px solid var(--line);border-radius:16px;box-shadow:var(--shadow);overflow-x:auto;scrollbar-width:none}
.today-summary::-webkit-scrollbar{display:none}
.today-summary .sum-base,.today-summary .sum-sig{display:inline-flex!important;align-items:center;gap:4px;flex:0 0 auto;min-height:36px;margin:0;padding:6px 13px;border-left:1px solid var(--line);font-size:12.5px;line-height:1.35;white-space:nowrap}
.today-summary .sum-base:first-child{border-left:0}
.today-summary .sum-base:nth-child(3){flex:1 0 auto;min-width:230px}
.today-summary .sum-base b{font-size:15px}
.today-summary .sum-sig{color:var(--muted)}
.today-summary .sum-link{color:var(--accent)}
.today-grid{grid-template-columns:minmax(0,1.5fr) minmax(310px,.85fr);gap:24px;align-items:start}
.today-agenda{gap:20px}
.today-aside{gap:16px;position:sticky;top:calc(var(--top-h) + 18px)}
.today-schedule{padding:0;background:transparent;box-shadow:none}
.today-schedule>.card-head{margin:0 0 12px;padding:0 2px;align-items:flex-end}
.today-schedule>.card-head h2{font-size:20px;letter-spacing:-.02em}
.today-section-sub{margin-top:3px;color:var(--muted);font-size:12.5px}
.today-schedule>.dl{gap:8px;padding:10px;background:var(--surface);border-radius:20px;box-shadow:var(--shadow)}
.today-schedule .dl-it.next{margin:-10px -10px 4px;border-radius:20px 20px 14px 14px!important;padding:22px!important;grid-template-columns:max-content minmax(0,1fr) auto}
.today-schedule .dl-it.next>.dl-t{font-size:24px;white-space:nowrap}
.today-schedule .dl-it.next .dl-tt{white-space:nowrap}
.today-schedule .dl-it.next .dl-name{max-width:100%;overflow-wrap:anywhere}
.today-schedule .dl-it.next .dl-name{font-size:22px;letter-spacing:-.025em}
.today-schedule .dl-it.next .v11-tiles{margin-top:4px}
.today-schedule .dl-it.next .v11-tiles>div{padding:11px 12px}
.today-schedule .dl-it.next .v11-tiles b{margin-top:3px}
.today-schedule .dl-it:not(.next){min-height:58px;background:transparent;border-radius:12px}
.today-schedule .dl-it:not(.next):hover{background:var(--surface-2)}
.today-schedule .dl-gap{min-height:34px;background:var(--surface-2)}
.today-schedule .dl-empty{padding:24px}
.today-aside>.card:first-child{border-top:3px solid var(--accent)}
.today-aside .card-head h2{font-size:17px}
.today-aside .inb-it{padding:13px 0}
.today-aside .inb-it:last-child{padding-bottom:2px}
.today-aside .inb-g b{font-size:14px}
.today-aside .inb-act .btn{min-height:34px}
.today-home .alert{margin-bottom:16px}
@media (max-width:1120px){
  .today-head{display:block!important}
  .today-head .qbar{justify-content:flex-start;max-width:none;margin-top:0}
  .today-grid{grid-template-columns:minmax(0,1.25fr) minmax(290px,.9fr);gap:18px}
  .today-schedule .dl-it.next{grid-template-columns:max-content minmax(0,1fr);grid-template-areas:"t b" "a a" "x x"}
  .today-schedule .dl-it.next>.dl-acts{justify-content:flex-start}
  .today-summary .sum-base:nth-child(3){min-width:200px}
}
@media (max-width:860px){
  .today-grid{grid-template-columns:1fr}
  .today-aside{position:static;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:start}
  .today-aside>.card:first-child{grid-column:1/-1}
  .today-head h1{font-size:29px}
  .today-summary{margin:0 0 4px!important}
}
@media (max-width:600px){
  .today-head{margin-bottom:14px!important}
  .today-head h1{font-size:26px;margin-bottom:12px!important}
  .today-head .qbar{margin:0 -16px 12px;padding:0 16px 2px}
  .today-head .qa{min-height:44px}
  .today-summary{border-radius:14px;margin-inline:-2px!important}
  .today-summary .sum-base,.today-summary .sum-sig{min-height:38px;padding:6px 11px;font-size:12px}
  .today-summary .sum-base:nth-child(3){min-width:215px}
  .today-schedule>.card-head{align-items:flex-start;gap:10px}
  .today-schedule>.card-head>.actions{gap:4px}
  .today-schedule>.card-head .btn{padding-inline:10px}
  .today-schedule>.card-head .btn.ghost{display:none}
  .today-section-sub{font-size:12px}
  .today-schedule>.dl{padding:8px;border-radius:18px}
  .today-schedule .dl-it.next{margin:-8px -8px 4px;padding:17px!important;border-radius:18px 18px 12px 12px!important}
  .today-schedule .dl-it.next>.dl-t{font-size:20px}
  .today-schedule .dl-it.next .dl-name{font-size:20px}
  .today-schedule .dl-it.next .dl-acts .btn{min-height:42px}
  .today-schedule .dl-it.next .v11-tiles{grid-template-columns:1fr!important;gap:6px}
  .today-schedule .dl-it.next .v11-tiles>div{padding:9px 11px}
  .today-aside{display:flex;flex-direction:column;min-width:0}
  .today-aside>.card{width:100%;min-width:0}
  .today-aside>.card:first-child{border-top-width:1px}
}
@media (prefers-reduced-motion:reduce){.today-home *{scroll-behavior:auto!important}}

/* Следующий урок на другой день — не теряется после конца сегодняшнего расписания. */
.today-next-other{display:flex;align-items:center;gap:12px;margin:0 0 12px;padding:14px 16px;border:1px solid var(--accent-line);border-radius:16px;background:var(--accent-soft)}
.today-next-other-icon{display:grid;place-items:center;flex:none;width:40px;height:40px;border-radius:12px;background:var(--surface);color:var(--accent)}
.today-next-other>.grow{display:flex;flex-direction:column;gap:2px;min-width:0}
.today-next-other-name{align-self:flex-start;padding:0;border:0;background:none;color:var(--ink);font:inherit;font-size:17px;font-weight:800;cursor:pointer;text-align:left}
.today-next-other-name:hover{color:var(--accent)}
.today-empty .btn{margin-top:12px}
/* Скрытая панель «Ещё» не участвует в ширине страницы. */
.qa-more:not([open])>.qa-menu{display:none!important}
.today-head .qa-menu{left:auto;right:0;max-width:calc(100vw - 24px)}
.today-head .qbar,.today-summary{max-width:100%;min-width:0}
.today-aside .inb-g{min-width:0;overflow-wrap:anywhere}
@media (max-width:600px){
  .today-head .qbar{width:100%;max-width:100%;margin:0 0 12px!important;padding:0 0 2px;contain:inline-size}
  .today-head .qa{flex:0 0 auto}
  .today-summary{contain:inline-size}
  .today-aside .inb-act{grid-column:1/-1;max-width:100%;padding-left:0}
  .today-aside .inb-act .btn{min-height:44px;white-space:normal}
  .today-next-other{align-items:flex-start;flex-wrap:wrap}
  .today-next-other>.chip{margin-left:52px}
}

/* Финальная полировка: единый фон и аккуратные стыки поверхностей. */
html.v11 body{
  background-color:var(--bg);
  background-image:radial-gradient(color-mix(in srgb,var(--accent) 8%,transparent) .7px,transparent .8px);
  background-size:22px 22px;
  background-attachment:fixed;
}
html.v11 .topbar,html.v11 .rail{border-color:color-mix(in srgb,var(--line) 82%,transparent)}
html.v11 .today-home .card{
  border:1px solid color-mix(in srgb,var(--line) 88%,transparent);
  box-shadow:var(--shadow)!important;
}
.today-summary{padding:5px;border-color:color-mix(in srgb,var(--line) 90%,transparent);box-shadow:var(--shadow)}
.today-summary .sum-base,.today-summary .sum-sig{border-left-color:color-mix(in srgb,var(--line) 80%,transparent)}
.today-schedule>.dl{
  padding:10px;border:1px solid color-mix(in srgb,var(--line) 88%,transparent);border-radius:22px;
  box-shadow:var(--shadow);
}
.today-schedule .dl-it.next{
  margin:0 0 5px;border-radius:16px!important;
  background:linear-gradient(118deg,var(--brand) 0%,var(--brand-2) 72%,var(--brand-3) 130%)!important;
  box-shadow:0 12px 26px color-mix(in srgb,var(--brand) 20%,transparent)!important;
}
.today-schedule .dl-it.next::after{top:-125px;right:-95px;width:300px;height:300px;background:radial-gradient(circle,color-mix(in srgb,var(--gold) 24%,transparent),transparent 68%)}
.today-schedule .dl-it:not(.next){padding-inline:12px}
.today-schedule .dl-now{margin-inline:4px}
.today-aside>.card:first-child{border-top:1px solid color-mix(in srgb,var(--line) 88%,transparent)}
.today-aside .inb-it{border-top-color:color-mix(in srgb,var(--line) 75%,transparent)}
.today-home .m3{background:color-mix(in srgb,var(--surface-2) 72%,var(--surface));border:1px solid color-mix(in srgb,var(--line) 58%,transparent)}
@media(max-width:600px){
  html.v11 body{background-attachment:scroll}
  .today-schedule>.dl{padding:8px;border-radius:19px}
  .today-schedule .dl-it.next{margin:0 0 4px;border-radius:14px!important}
  .today-summary{box-shadow:var(--shadow)}
}

/* Широкий рабочий стол: используем пространство, а не оставляем пустую полосу справа. */
@media(min-width:1500px){
  .main:has(.today-home){max-width:1720px}
  .today-home{max-width:none;margin:0}
  .today-grid{grid-template-columns:minmax(0,1.65fr) minmax(390px,.85fr);gap:28px}
  .today-agenda{gap:24px}
  .today-schedule>.card-head{margin-bottom:14px}
  .today-schedule .dl-it:not(.next){min-height:64px;padding-inline:16px}
  .today-schedule .dl-it.next{padding:24px!important}
  .today-schedule .dl-it.next .v11-tiles>div{padding:13px 15px}
  .today-aside{gap:18px}
  .today-aside .inb-it{padding:15px 0}
}
.today-schedule>.today-next-other-v11{margin-bottom:12px}
.today-schedule>.dl-it.next{margin:0 0 12px}
@media(max-width:600px){
  .today-schedule>.dl-it.next{margin-bottom:10px}
}


/* v7: планшет — компактная типографика, длинные подписи переносятся. */
.today-schedule .dl-it.next .dl-top .chip{min-height:28px;padding-block:3px;line-height:1.3}
@media (min-width:768px) and (max-width:1180px){
  .today-head h1{font-size:28px;letter-spacing:-.025em}
  .today-head .qbar{gap:8px}
  .today-head .qa{padding-inline:13px;font-size:13px}
  .today-schedule>.card-head h2{font-size:18px}
  .today-schedule .dl-it.next{padding:18px!important;gap:10px 12px}
  .today-schedule .dl-it.next>.dl-t{font-size:20px}
  .today-schedule .dl-it.next .dl-name{font-size:19px;letter-spacing:-.015em}
  .today-schedule .dl-it.next .dl-top{gap:6px}
  .today-schedule .dl-it.next .dl-top .chip{max-width:100%;font-size:11px;white-space:normal;overflow-wrap:anywhere}
  .today-schedule .dl-it.next .v11-tiles b{white-space:normal;line-height:1.3;overflow:visible;text-overflow:clip}
}
@media (min-width:861px) and (max-width:1000px){
  .today-grid{grid-template-columns:minmax(0,1fr)}
  .today-aside{position:static;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:start}
  .today-aside>.card:first-child{grid-column:1/-1}
}

/* Промежуточный десктоп: не сжимаем урок и входящие в две тесные колонки. */
@media (min-width:1001px) and (max-width:1350px){
  .today-grid{grid-template-columns:minmax(0,1fr)}
  .today-aside{position:static;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:start}
  .today-aside>.card:first-child{grid-column:1/-1}
  .today-schedule .dl-it.next{grid-template-columns:max-content minmax(0,1fr);grid-template-areas:"t b" "a a" "x x"}
  .today-schedule .dl-it.next>.dl-acts{justify-content:flex-start}
  .today-schedule .dl-it.next .dl-top{flex-wrap:wrap}
  .today-schedule .dl-it.next .v11-tiles b{white-space:normal;line-height:1.35;overflow:visible;text-overflow:clip}
}

/* v8: широкий монитор — масштабируем не только колонки, но и читаемость. */
@media(min-width:1500px){
  .today-head h1{font-size:38px}
  .today-head .v11-ph-date{font-size:13px}
  .today-head .qa{font-size:15px;min-height:44px}
  .today-summary .sum-base,.today-summary .sum-sig{font-size:14px;min-height:40px}
  .today-summary .sum-base b{font-size:17px}
  .today-schedule>.card-head h2{font-size:22px}
  .today-section-sub{font-size:14px}
  .today-schedule .dl-it.next{min-height:214px;padding:26px!important;gap:14px 16px}
  .today-schedule .dl-it.next>.dl-t{font-size:28px}
  .today-schedule .dl-it.next .dl-name{font-size:24px}
  .today-schedule .dl-it.next .dl-top .chip{font-size:13px;min-height:32px}
  .today-schedule .dl-it.next .dl-m{font-size:15px}
  .today-schedule .dl-it.next .dl-acts .btn{font-size:14px;min-height:42px}
  .today-schedule .dl-it.next .v11-tiles>div{min-height:76px;padding:14px 16px;font-size:15px}
  .today-schedule .dl-it.next .v11-tiles span{font-size:13px}
  .today-schedule .dl-it.next .v11-tiles b{font-size:15px;line-height:1.4;white-space:normal}
  .today-schedule .dl-it:not(.next){min-height:70px;font-size:16px}
  .today-schedule .dl-it:not(.next) .dl-name{font-size:16px}
  .today-schedule .dl-it:not(.next) .dl-m{font-size:14px}
  .today-aside .card-head h2{font-size:20px}
  .today-aside .inb-g b{font-size:15px;line-height:1.45}
  .today-aside .inb-g span{font-size:14px;line-height:1.45}
  .today-aside .inb-act .btn{font-size:14px;min-height:40px}
  .today-aside .card-head .muted{font-size:13px}
  .today-home .m3 span{font-size:13px}
  .today-home .m3 b{font-size:24px}
}
