Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

MediaWiki:Common.css: Difference between revisions

MediaWiki interface page
No edit summary
No edit summary
Line 1: Line 1:
/* --- 1. BASE LAYOUT (Shape & Position) --- */
/* --- CITIZEN SKIN INFOBOX --- */
 
/* 1. Base Layout & Shape */
.infobox {
.infobox {
     float: right;
     float: right;
Line 5: Line 7:
     width: 300px;
     width: 300px;
     padding: 0;
     padding: 0;
     margin-left: 1em;
     margin-left: 1rem;
     margin-bottom: 1em;
     margin-bottom: 1rem;
     font-size: 90%;
     font-size: 0.9rem;
     box-shadow: 0 2px 4px rgba(0,0,0,0.1);
     border-radius: var(--border-radius-base, 4px); /* Matches Citizen rounded corners */
    border-radius: 4px;
     overflow: hidden;
     overflow: hidden;
    box-shadow: var(--box-shadow-card, 0 2px 8px rgba(0,0,0,0.1)); /* Uses Citizen shadow if available */
      
      
     /* Default Light Mode Colors */
     /* Variable Fallbacks for seamless integration */
     background-color: #f8f9fa;
     background-color: var(--background-color-surface, #ffffff);
     border: 1px solid #a2a9b1;
     border: 1px solid var(--border-color-base, #eaecf0);
     color: #202122;
     color: var(--color-base, #202122);
}
}


/* 2. Header (Liquipedia Blue) */
.infobox-header {
.infobox-header {
     text-align: center;
     text-align: center;
     font-weight: bold;
     font-weight: bold;
     padding: 10px;
     padding: 12px;
     font-size: 1.2em;
     font-size: 1.1rem;
      
      
     /* Default Light Mode Colors */
     /* Force Liquipedia Blue in Light Mode */
     background-color: #2b7bb9; /* Liquipedia Blue */
     background-color: #2b7bb9;  
     color: #ffffff;
     color: #ffffff;
    border-bottom: 1px solid rgba(0,0,0,0.1);
}
}


/* 3. Image Area */
.infobox-image {
.infobox-image {
     text-align: center;
     text-align: center;
     padding: 15px 0;
     padding: 15px 0;
   
     background-color: var(--background-color-base, #ffffff);
    /* Default Light Mode Colors */
     border-bottom: 1px solid var(--border-color-subtle, #eaecf0);
     background-color: #ffffff;
     border-bottom: 1px solid #eaecf0;
}
}


/* 4. Rows & Text */
.infobox-row {
.infobox-row {
     display: flex;
     display: flex;
     flex-direction: row;
     flex-direction: row;
     padding: 8px 10px;
     padding: 10px 12px;
   
     border-bottom: 1px solid var(--border-color-subtle, #eaecf0);
    /* Default Light Mode Colors */
    line-height: 1.5;
     border-bottom: 1px solid #eaecf0;
}
}


Line 51: Line 52:
     width: 90px;
     width: 90px;
     min-width: 90px;
     min-width: 90px;
     padding-right: 10px;
     padding-right: 12px;
     font-weight: bold;
     font-weight: 600;
     opacity: 0.85;
     opacity: 0.8;
}
}


/* --- 2. DARK MODE OVERRIDES --- */
/* --- CITIZEN DARK MODE OVERRIDES --- */
 
/* Citizen uses this specific class on the HTML tag */
/* This targets the specific "Night Mode" class used by modern MediaWiki skins */
html.skin-citizen-dark .infobox-header {
html.skin-theme-client-pref-night .infobox {
     background-color: #3a6c8e; /* Muted Blue for Dark Mode */
    background-color: #202124 !important;
     color: #ffffff;
    border-color: #4a4d50 !important;
     border-bottom: 1px solid var(--border-color-base);
    color: #eaecf0 !important;
}
 
html.skin-theme-client-pref-night .infobox-header {
     background-color: #3a6c8e !important; /* Muted Blue */
     color: #ffffff !important;
     border-bottom: 1px solid #4a4d50 !important;
}
 
html.skin-theme-client-pref-night .infobox-image {
    background-color: #1a1a1a !important; /* Dark background for transparent PNGs */
    border-bottom: 1px solid #4a4d50 !important;
}
 
html.skin-theme-client-pref-night .infobox-row {
    border-bottom: 1px solid #36393d !important;
}
}


/* Also support OS-level Dark Mode preference */
/* Optional: Make the image background match the card in dark mode */
@media screen and (prefers-color-scheme: dark) {
html.skin-citizen-dark .infobox-image {
    html.skin-theme-client-pref-os .infobox {
     background-color: transparent;
        background-color: #202124;
        border-color: #4a4d50;
        color: #eaecf0;
    }
    html.skin-theme-client-pref-os .infobox-header {
        background-color: #3a6c8e;
        border-bottom: 1px solid #4a4d50;
    }
     html.skin-theme-client-pref-os .infobox-image {
        background-color: #1a1a1a;
        border-bottom: 1px solid #4a4d50;
    }
    html.skin-theme-client-pref-os .infobox-row {
        border-bottom: 1px solid #36393d;
    }
}
}

Revision as of 01:37, 29 December 2025

/* --- CITIZEN SKIN INFOBOX --- */

/* 1. Base Layout & Shape */
.infobox {
    float: right;
    clear: right;
    width: 300px;
    padding: 0;
    margin-left: 1rem;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    border-radius: var(--border-radius-base, 4px); /* Matches Citizen rounded corners */
    overflow: hidden;
    box-shadow: var(--box-shadow-card, 0 2px 8px rgba(0,0,0,0.1)); /* Uses Citizen shadow if available */
    
    /* Variable Fallbacks for seamless integration */
    background-color: var(--background-color-surface, #ffffff);
    border: 1px solid var(--border-color-base, #eaecf0);
    color: var(--color-base, #202122);
}

/* 2. Header (Liquipedia Blue) */
.infobox-header {
    text-align: center;
    font-weight: bold;
    padding: 12px;
    font-size: 1.1rem;
    
    /* Force Liquipedia Blue in Light Mode */
    background-color: #2b7bb9; 
    color: #ffffff;
}

/* 3. Image Area */
.infobox-image {
    text-align: center;
    padding: 15px 0;
    background-color: var(--background-color-base, #ffffff);
    border-bottom: 1px solid var(--border-color-subtle, #eaecf0);
}

/* 4. Rows & Text */
.infobox-row {
    display: flex;
    flex-direction: row;
    padding: 10px 12px;
    border-bottom: 1px solid var(--border-color-subtle, #eaecf0);
    line-height: 1.5;
}

.infobox-label {
    width: 90px;
    min-width: 90px;
    padding-right: 12px;
    font-weight: 600;
    opacity: 0.8;
}

/* --- CITIZEN DARK MODE OVERRIDES --- */
/* Citizen uses this specific class on the HTML tag */
html.skin-citizen-dark .infobox-header {
    background-color: #3a6c8e; /* Muted Blue for Dark Mode */
    color: #ffffff;
    border-bottom: 1px solid var(--border-color-base);
}

/* Optional: Make the image background match the card in dark mode */
html.skin-citizen-dark .infobox-image {
    background-color: transparent;
}