Jump to content

MediaWiki:Common.css: Difference between revisions

From Fedoverse Wiki, the free encyclopedia
No edit summary
No edit summary
Line 255: Line 255:
         max-width: 100% !important;
         max-width: 100% !important;
     }
     }
}
/* --- SOCIAL MEDIA PILL BUTTONS --- */
.social-badge {
    display: inline-flex;
    align-items: center;
    margin: 2px 4px 2px 0;
}
.social-badge a {
    display: inline-flex !important;
    align-items: center;
    gap: 5px;
    padding: 3px 9px !important;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.3;
    text-decoration: none !important;
    color: #ffffff !important;
    background-image: none !important; /* Removes default MediaWiki external link arrow */
    padding-right: 9px !important;
    transition: transform 0.15s ease, opacity 0.15s ease;
}
.social-badge a:hover {
    transform: translateY(-1px);
    opacity: 0.9;
    color: #ffffff !important;
}
/* YouTube */
.social-badge.yt a {
    background-color: #ff0000 !important;
}
.social-badge.yt a::before {
    content: "";
    display: inline-block;
    width: 14px;
    height: 10px;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M23.498 6.186a3.016 3.016 0 0 0-2.122-2.136C19.505 3.545 12 3.545 12 3.545s-7.505 0-9.377.505A3.017 3.017 0 0 0 .502 6.186C0 8.07 0 12 0 12s0 3.93.502 5.814a3.016 3.016 0 0 0 2.122 2.136c1.871.505 9.376.505 9.376.505s7.505 0 9.377-.505a3.015 3.015 0 0 0 2.122-2.136C24 15.93 24 12 24 12s0-3.93-.502-5.814zM9.545 15.568V8.432L15.818 12l-6.273 3.568z"/></svg>') no-repeat center;
    background-size: contain;
}
/* Twitch */
.social-badge.twitch a {
    background-color: #9146ff !important;
}
.social-badge.twitch a::before {
    content: "";
    display: inline-block;
    width: 12px;
    height: 12px;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M11.571 4.714h1.715v5.143H11.57zm4.715 0H18v5.143h-1.714zM6 0L1.714 4.286v15.428h5.143V24l4.286-4.286h3.428L22.286 12V0zm14.571 11.143l-3.428 3.428h-3.429l-3 3v-3H6.857V1.714h13.714Z"/></svg>') no-repeat center;
    background-size: contain;
}
}



Revision as of 19:54, 10 September 2026

/* CSS placed here will be applied to all skins */

/* --- 0. LOCAL FONT DECLARATIONS --- */
@font-face {
    font-family: 'Mountains of Christmas';
    font-style: normal;
    font-weight: 700;
    src: url('/images/fonts/MountainsofChristmas-Bold.ttf') format('truetype');
}

@font-face {
    font-family: 'Mountains of Christmas';
    font-style: normal;
    font-weight: 400;
    src: url('/images/fonts/MountainsofChristmas-Regular.ttf') format('truetype');
}

/* --- 1. UI CLEANUP & READ-ONLY HIDING --- */

/* --- UNIFY BACKGROUND & FIX VIEWPORT HEIGHT --- */

/* 1. Force identical pure-white background across all document layers */
html,
body,
.mw-page-container,
.mw-header,
.mw-content-container {
    background-color: #ffffff !important;
}

/* 2. Stretch the container to fill 100% of the screen height */
html,
body {
    min-height: 100% !important;
}

.mw-page-container {
    min-height: 100vh !important;
    box-sizing: border-box !important;
    border: none !important;
    box-shadow: none !important;
}

/* Footers: Privacy, disclaimers, powered by */
#footer-places,
#footer-icons,
.mw-footer-container {
    display: none !important;
}

/* Sidebar & Navigation controls */
#mw-sidebar-button,
#vector-main-menu-dropdown {
    display: none !important;
}

/* User account / Log in links */
#p-personal,
#pt-login,
#pt-login-2,
#p-vector-user-menu-overflow,
.vector-user-links,
.user-links-collapsible-item {
    display: none !important;
}

/* Page tabs & toolbars (Namespaces, views, actions) */
.vector-page-toolbar,
.mw-article-toolbar,
#p-namespaces,
#p-views,
#p-cactions,
#vector-page-tools-dropdown {
    display: none !important;
}

/* Spacing left behind by removed tabs */
.mw-body-header {
    border-bottom: none !important;
    margin-bottom: 0 !important;
}

/* Watch page elements (Forms & VisualEditor) */
#wpWatchthis,
.page-mw-watchthis,
.mw-editWatchlist,
.mw-widget-checkDef-watchthis,
label[for="wpWatchthis"],
.oo-ui-fieldLayout:has(#wpWatchthis),
.oo-ui-fieldLayout:has([name="wpWatchthis"]) {
    display: none !important;
}

/* Right sidebar / column tools / appearance column */
.vector-column-end,
.no-font-mode-scale.vector-column-end {
    display: none !important;
}

/* --- 2. HEADER ALIGNMENT & INSTANT SEARCH POSITIONING --- */

/* Remove gap between header items */
.mw-header .vector-header-start {
    gap: 0 !important;
}

/* Eliminate search shift, margin delays, and animation latency */
#p-search,
.vector-search-box,
.vector-typeahead-search-container,
.cdx-typeahead-search,
.vector-typeahead-search {
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    transition: none !important;
}

.cdx-typeahead-search__input-wrapper,
.cdx-search-input {
    margin-left: 0 !important;
    transition: none !important;
}

/* --- 3. TABLE OF CONTENTS --- */

#vector-toc,
.vector-toc {
    margin-top: 0 !important;
}

ul#mw-panel-toc-list.vector-toc-contents {
    margin-left: 6px !important;
}

/* Hide TOC header & unpin button */
.vector-pinnable-header-pinned.vector-toc-pinnable-header.vector-pinnable-header,
.vector-pinnable-header-toggle-button.vector-pinnable-header-unpin-button {
    display: none !important;
}

/* --- 4. BRANDING & MEDIA --- */

/* Neutralize any legacy container inversion */
.mw-logo-container.skin-invert {
    filter: none !important;
}

/* Wordmark typography & light mode color */
.mw-logo-wordmark,
.mw-logo-wordmark * {
    color: #202122 !important;
    font-family: "Mountains of Christmas", cursive, serif !important;
    font-weight: 700 !important;
}

/* Modern infobox images */
.portable-infobox .pi-image img,
.infobox img {
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* --- 5. MATERIAL FLOATING SEARCH BAR --- */

/* Hide search buttons & dropdown filler */
#searchButton,
.cdx-search-input__end-button,
.cdx-menu-item--search-for {
    display: none !important;
}

/* Search container & layout stability */
.vector-typeahead-search-container {
    max-width: none !important;
    margin: 0 !important;
    transform: none !important;
}

.cdx-search-input {
    border-radius: 8px !important;
    border: 1px solid transparent !important;
    background-color: #f1f3f4 !important;
    transition: background-color 0.2s, box-shadow 0.2s, border 0.2s;
}

.cdx-search-input:focus-within {
    background-color: #ffffff !important;
    box-shadow: 0 4px 6px rgba(32, 33, 36, 0.2) !important;
    border: 1px solid #dfe1e5 !important;
    border-radius: 8px !important;
}

/* Search inputs */
.cdx-text-input,
.cdx-text-input:focus-within,
.cdx-text-input.cdx-text-input--status-default {
    border: none !important;
    box-shadow: none !important;
    outline: none !important;
    background: transparent !important;
}

.cdx-text-input__input {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding-right: 32px !important;
    transition: none !important;
}

/* Search dropdown results */
.cdx-menu {
    border-radius: 8px !important;
    box-shadow: 0 6px 12px rgba(32, 33, 36, 0.15) !important;
    border: 1px solid #dfe1e5 !important;
    margin-top: 8px !important;
    background-color: #ffffff !important;
    overflow: hidden !important;
    padding: 0 !important;
}

.cdx-menu-item:hover,
.cdx-menu-item[aria-selected="true"] {
    background-color: #eeeeee !important;
}

/* --- 6. MOBILE FIXES (LOGO, SEARCH & INFOBOX) --- */

/* Mobile search toggle button spacing */
.search-toggle {
    margin-right: 8px !important;
}

/* Restore the logo icon on mobile using inline alignment */
.mw-logo-icon {
    display: inline-block !important;
    vertical-align: middle !important;
    margin-right: 6px !important;
}

.mw-logo-container {
    display: inline-block !important;
    vertical-align: middle !important;
}

/* Unfloat infobox only on narrow viewports (<= 500px) */
@media (max-width: 500px) {
    .portable-infobox,
    .infobox {
        float: none !important;
        clear: both !important;
        margin: 1em auto !important;
        max-width: 100% !important;
    }
}

/* --- SOCIAL MEDIA PILL BUTTONS --- */
.social-badge {
    display: inline-flex;
    align-items: center;
    margin: 2px 4px 2px 0;
}

.social-badge a {
    display: inline-flex !important;
    align-items: center;
    gap: 5px;
    padding: 3px 9px !important;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.3;
    text-decoration: none !important;
    color: #ffffff !important;
    background-image: none !important; /* Removes default MediaWiki external link arrow */
    padding-right: 9px !important;
    transition: transform 0.15s ease, opacity 0.15s ease;
}

.social-badge a:hover {
    transform: translateY(-1px);
    opacity: 0.9;
    color: #ffffff !important;
}

/* YouTube */
.social-badge.yt a {
    background-color: #ff0000 !important;
}
.social-badge.yt a::before {
    content: "";
    display: inline-block;
    width: 14px;
    height: 10px;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M23.498 6.186a3.016 3.016 0 0 0-2.122-2.136C19.505 3.545 12 3.545 12 3.545s-7.505 0-9.377.505A3.017 3.017 0 0 0 .502 6.186C0 8.07 0 12 0 12s0 3.93.502 5.814a3.016 3.016 0 0 0 2.122 2.136c1.871.505 9.376.505 9.376.505s7.505 0 9.377-.505a3.015 3.015 0 0 0 2.122-2.136C24 15.93 24 12 24 12s0-3.93-.502-5.814zM9.545 15.568V8.432L15.818 12l-6.273 3.568z"/></svg>') no-repeat center;
    background-size: contain;
}

/* Twitch */
.social-badge.twitch a {
    background-color: #9146ff !important;
}
.social-badge.twitch a::before {
    content: "";
    display: inline-block;
    width: 12px;
    height: 12px;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M11.571 4.714h1.715v5.143H11.57zm4.715 0H18v5.143h-1.714zM6 0L1.714 4.286v15.428h5.143V24l4.286-4.286h3.428L22.286 12V0zm14.571 11.143l-3.428 3.428h-3.429l-3 3v-3H6.857V1.714h13.714Z"/></svg>') no-repeat center;
    background-size: contain;
}