MediaWiki:Common.css: Difference between revisions

From Librarian Chick
Jump to navigation Jump to search
Logo: align left edge to sidebar boundary
Logo: always left-aligned at sidebar boundary
 
Line 1: Line 1:
/* Logo: left edge aligned with sidebar/content boundary */
/* Logo: left edge always aligned with sidebar/content boundary */
#p-logo {
#p-logo {
     position: fixed;
     position: fixed;
Line 10: Line 10:
     background-repeat: no-repeat !important;
     background-repeat: no-repeat !important;
     background-position: left center !important;
     background-position: left center !important;
     width: 416px !important;
    /* Never wider than the viewport minus the sidebar */
     width: min(416px, calc(100vw - 170px)) !important;
     height: 100px !important;
     height: 100px !important;
    aspect-ratio: 416 / 100;
     display: block;
     display: block;
}
}
Line 19: Line 21:
#mw-panel    { padding-top: 110px; }
#mw-panel    { padding-top: 110px; }


@media (max-width: 900px) {
/* Scale the reserved band down on narrow screens */
    #p-logo { left: 160px; }
@media (max-width: 700px) {
     .mw-wiki-logo { width: 300px !important; height: 72px !important; }
     .mw-wiki-logo { height: 72px !important; }
     #mw-head, #mw-head-base { top: 82px; height: 82px; }
     #mw-head     { top: 82px; }
    #mw-head-base { height: 82px; }
     #mw-page-base { padding-top: 82px; }
     #mw-page-base { padding-top: 82px; }
     #mw-panel    { padding-top: 82px; }
     #mw-panel    { padding-top: 82px; }
}
}
@media (max-width: 600px) {
@media (max-width: 480px) {
    #p-logo { left: 0; }
     .mw-wiki-logo { height: 48px !important; }
     .mw-wiki-logo { width: 200px !important; height: 48px !important; }
     #mw-head     { top: 58px; }
     #mw-head, #mw-head-base { top: 58px; height: 58px; }
    #mw-head-base { height: 58px; }
     #mw-page-base { padding-top: 58px; }
     #mw-page-base { padding-top: 58px; }
     #mw-panel    { padding-top: 58px; }
     #mw-panel    { padding-top: 58px; }
}
}

Latest revision as of 00:00, 24 March 2026

/* Logo: left edge always aligned with sidebar/content boundary */
#p-logo {
    position: fixed;
    left: 160px;
    top: 5px;
    z-index: 1000;
}
.mw-wiki-logo {
    background-size: contain !important;
    background-repeat: no-repeat !important;
    background-position: left center !important;
    /* Never wider than the viewport minus the sidebar */
    width: min(416px, calc(100vw - 170px)) !important;
    height: 100px !important;
    aspect-ratio: 416 / 100;
    display: block;
}
#mw-head      { top: 110px; }
#mw-head-base { height: 110px; }
#mw-page-base { padding-top: 110px; }
#mw-panel     { padding-top: 110px; }

/* Scale the reserved band down on narrow screens */
@media (max-width: 700px) {
    .mw-wiki-logo { height: 72px !important; }
    #mw-head      { top: 82px; }
    #mw-head-base { height: 82px; }
    #mw-page-base { padding-top: 82px; }
    #mw-panel     { padding-top: 82px; }
}
@media (max-width: 480px) {
    .mw-wiki-logo { height: 48px !important; }
    #mw-head      { top: 58px; }
    #mw-head-base { height: 58px; }
    #mw-page-base { padding-top: 58px; }
    #mw-panel     { padding-top: 58px; }
}