/* Shared outer grid: matches the visible inner edges of the approved header.
   Only pages with the new header participate; the custom resort map is excluded. */
body.ninfo-geo-shell:has(#ninfo-site-header){--ni-content-max:1416px;--ni-content-gutter:32px}
@media(min-width:761px) and (max-width:1150px){body.ninfo-geo-shell:has(#ninfo-site-header){--ni-content-gutter:22px}}
@media(max-width:760px){body.ninfo-geo-shell:has(#ninfo-site-header){--ni-content-gutter:12px}}
body.ninfo-geo-shell:has(#ninfo-site-header) .wrapper>.container,
body.ninfo-geo-shell:has(#ninfo-site-header) .footer>.container,
body.ninfo-geo-shell:has(#ninfo-site-header) .portal-container,
body.ninfo-geo-shell:has(#ninfo-site-header) .auto-container,
body.ninfo-geo-shell:has(#ninfo-site-header) .gps-container{
 box-sizing:border-box;width:min(var(--ni-content-max),calc(100% - var(--ni-content-gutter)*2))!important;
 max-width:var(--ni-content-max)!important;margin-inline:auto!important;padding-inline:0!important;
}
body.ninfo-geo-shell:has(#ninfo-site-header) .wrapper>.container>.row{margin-inline:0!important}
body.ninfo-geo-shell:has(#ninfo-site-header) .wrapper>.container>.row>.wrapper-inner{padding-inline:0!important;width:100%!important;max-width:100%!important;min-width:0}
/* Nested sections share the already aligned outer container, not another gutter. */
body.ninfo-geo-shell:has(#ninfo-site-header) .wrapper .portal-container,
body.ninfo-geo-shell:has(#ninfo-site-header) .wrapper .gps-container{width:100%!important;max-width:none!important;padding-inline:0!important}
body.ninfo-geo-shell:has(#ninfo-site-header) .wrapper .portal-home{width:100%!important;max-width:none!important;margin-inline:0!important}
body.ninfo-geo-shell:has(#ninfo-site-header) .wrapper .sg-hub{width:100%!important;max-width:none!important;margin-inline:0!important;left:auto!important;transform:none!important}
body.ninfo-geo-shell:has(#ninfo-site-header):has(.sg-hub) .wrapper-inner>.content-box{width:100%!important;max-width:none!important;margin-inline:0!important;left:auto!important;transform:none!important}
/* Auto pages have a full-bleed background and their own aligned content container. */
body.ninfo-geo-shell:has(#ninfo-site-header):is(:has(.auto-market),:has(.auto-detail),:has(.auto-add),:has(.auto-cabinet),:has(.auto-profile),:has(.auto-map-page),:has(.auto-favorites)) .wrapper>.container{width:100%!important;max-width:none!important}
/* A fixed 300px sidebar previously overflowed its grid column at tablet widths. */
body.ninfo-geo-shell:has(#ninfo-site-header) #sidebar-box{min-width:0}
body.ninfo-geo-shell:has(#ninfo-site-header) #sidebar-box .sidebar__inner{width:auto!important;min-width:0!important;max-width:100%!important;box-sizing:border-box}
body.ninfo-geo-shell:has(#ninfo-site-header):is(:has(.nnews__grid),:has(.news-detail)) #sidebar-box .sidebar__inner-right{margin-left:0!important}
body.ninfo-geo-shell:has(#ninfo-site-header) .docs-premium__shell{width:100%!important;max-width:none!important;padding-inline:0!important}
/* Fixed sidebar tracks prevent third-party ad measurement nodes from expanding flex items. */
@media(min-width:992px){
 body.ninfo-geo-shell:has(#ninfo-site-header) .wrapper-inner:has(>.content-box :is(.afisha-page,.docs-premium)){
  display:grid!important;grid-template-columns:minmax(0,3fr) minmax(0,1fr)!important;gap:28px!important;
 }
 body.ninfo-geo-shell:has(#ninfo-site-header) .wrapper-inner:has(>.content-box :is(.afisha-page,.docs-premium))>.content-box{
  width:auto!important;max-width:none!important;min-width:0!important;flex:none!important;
 }
 body.ninfo-geo-shell:has(#ninfo-site-header) .wrapper-inner>#sidebar-box{
  flex:0 0 25%!important;width:25%;max-width:25%;min-width:0!important;overflow-x:clip;
 }
 body.ninfo-geo-shell:has(#ninfo-site-header) .wrapper-inner:is(:has(.nnews__grid),:has(.news-detail),:has(>.content-box .afisha-page),:has(>.content-box .docs-premium))>#sidebar-box{
  width:100%!important;max-width:100%!important;
 }
 body.ninfo-geo-shell:has(#ninfo-site-header) .wrapper-inner:has(>.content-box :is(.afisha-page,.docs-premium))>#sidebar-box .sidebar__inner{
  width:100%!important;max-width:100%!important;margin-inline:0!important;
 }
}

/* Main news banners: calmer headline tracking and a narrower, more legible summary. */
.portal-home:is(.portal-home--geo-novokuznetsk,.portal-home--geo-kemerovo) .portal-main-slide>span>strong{letter-spacing:-.025em;margin-bottom:16px}
.portal-home:is(.portal-home--geo-novokuznetsk,.portal-home--geo-kemerovo) .portal-main-slide>span>p{width:90%;max-width:700px;margin-top:0;font-size:15px;line-height:1.4;letter-spacing:normal}
@media(max-width:800px){
 .portal-home:is(.portal-home--geo-novokuznetsk,.portal-home--geo-kemerovo) .portal-main-slide>span>strong{margin-bottom:13px}
 .portal-home:is(.portal-home--geo-novokuznetsk,.portal-home--geo-kemerovo) .portal-main-slide>span>p{width:95%}
}

/* News category selection matches the main navigation in both city homepages. */
body .portal-home:is(.portal-home--geo-novokuznetsk,.portal-home--geo-kemerovo) .portal-news-tabs .portal-news-tabs__nav button.is-active{
 color:#ff6600!important;background:#fff0e5!important;border-color:transparent!important;border-radius:10px!important;font-weight:400!important;
}
html[data-ninfo-theme="dark"] body .portal-home:is(.portal-home--geo-novokuznetsk,.portal-home--geo-kemerovo) .portal-news-tabs .portal-news-tabs__nav button.is-active{
 background:#3b2b20!important;color:#ff6600!important;
}

body.ninfo-geo-shell:has(.sg-hub) .wrapper-inner>#sidebar-box:not(:has(*)){display:none!important}
