/* Shared public and cabinet navigation; homepage keeps its approved shell. */
.portal-page:not(.cabinet-layout){min-height:100dvh;display:flex;flex-direction:column}
.portal-page:not(.cabinet-layout)>main{flex:1;width:100%}
.portal-page .portal-header{gap:18px}
.portal-header .header-shortcuts{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.portal-page .portal-header .back-home{display:inline-flex;align-items:center;justify-content:center;gap:8px;width:auto;min-height:40px;margin:0;padding:9px 13px;border:1px solid #164364;border-radius:9px;background:#082a49;color:#e7f4ff;font-size:12px;font-weight:600;line-height:1.45;white-space:nowrap}
.portal-page .portal-header .back-home:hover{background:#082a49;border-color:#2a5575}
.portal-header .back-home svg{width:16px;height:16px;flex:none;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
body.portal-page>footer.portal-footer,body.portal-page.nf-has-support>footer.portal-footer{min-height:0;align-items:center;padding:16px 28px;gap:10px 20px}
body.portal-page.nf-has-support>footer.portal-footer{padding-right:max(100px,calc(80px + env(safe-area-inset-right)));padding-bottom:calc(16px + env(safe-area-inset-bottom))}
.portal-page .portal-footer>span{width:auto;margin-right:auto}
body.cabinet-layout>footer.portal-footer,body.cabinet-layout.nf-has-support>footer.portal-footer{height:43px;padding-top:8px;padding-bottom:8px}
@media(max-width:760px){
 .portal-page .portal-header{gap:12px;flex-wrap:wrap}
 .portal-header .header-shortcuts{order:3;width:100%}
 .portal-page .portal-header .back-home{order:0;font-size:11px;min-height:36px;padding:8px 11px}
 body.portal-page>footer.portal-footer,body.portal-page.nf-has-support>footer.portal-footer{padding-top:12px;padding-bottom:calc(12px + env(safe-area-inset-bottom));padding-left:20px;gap:10px 16px}
 body.cabinet-layout{grid-template-rows:auto minmax(0,1fr) auto}
 body.cabinet-layout .portal-header{height:auto;min-height:64px}
 body.cabinet-layout>footer.portal-footer,body.cabinet-layout.nf-has-support>footer.portal-footer{height:auto;min-height:40px;padding-left:12px}
}
/* Long localized headings must wrap inside the legal-page column. */
.portal-page .legal-main{min-width:0;overflow-wrap:anywhere}
