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:
/* --- CITIZEN INFOBOX (ALL LEFT ALIGN) --- */
/* --- LIQUIPEDIA STYLE UNIFIED BOX --- */


/* 1. The Outer Container (The only part with a border) */
.infobox {
.infobox {
     float: right;
     float: right;
Line 7: Line 8:
     margin-left: 1rem;
     margin-left: 1rem;
     margin-bottom: 1rem;
     margin-bottom: 1rem;
    padding: 0;
   
    /* Design: One solid box */
    background-color: var(--background-color-surface, #fff);
    border: 1px solid #a2a9b1; /* Standard Grey Border */
    border-radius: 2px; /* Very slight rounding like Liquipedia */
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
   
     font-size: 0.9rem;
     font-size: 0.9rem;
   
    /* Skin Integration */
    background-color: var(--background-color-surface, #fff);
    border: 1px solid var(--border-color-base, #eaecf0);
     color: var(--color-base, #222);
     color: var(--color-base, #222);
   
    border-radius: var(--border-radius-base, 4px);
    box-shadow: var(--box-shadow-card, 0 1px 2px rgba(0,0,0,0.1));
    overflow: hidden;
}
}


/* HEADER: Left Aligned */
/* 2. The Header */
.infobox-header {
.infobox-header {
     text-align: left !important; /* Force Left */
     text-align: center;
     font-weight: bold;
     font-weight: bold;
     padding: 12px 15px; /* Added left padding for breathing room */
     padding: 10px;
     font-size: 1.1rem;
     font-size: 1.1rem;
     background-color: #2b7bb9;  
   
     color: #ffffff;  
    /* Liquipedia Blue */
     background-color: #2b7bb9;
     color: #ffffff;
    border-bottom: 1px solid #a2a9b1;
}
}


/* ROW CONTAINER */
/* 3. The Image Area */
.infobox-image {
    text-align: center;
    padding: 10px 0;
    background-color: #fff; /* Always white for images */
    border-bottom: 1px solid #eaecf0;
}
 
/* 4. The Rows (Clean lines, no gaps) */
.infobox-row {
.infobox-row {
     display: flex;
     display: flex;
     flex-wrap: nowrap; /* Forces side-by-side */
     flex-direction: row; /* FORCE Side-by-Side */
     align-items: flex-start;
    flex-wrap: nowrap;
     align-items: center; /* Vertically center the text */
      
      
     border-bottom: 1px solid var(--border-color-subtle, #eaecf0);
    /* Remove the "Card" look */
     padding: 0;
    margin: 0 !important;
     border-radius: 0 !important;
    background-color: transparent !important;
    box-shadow: none !important;
   
    /* Add a clean divider line */
    border-bottom: 1px solid #eaecf0;
     padding: 8px 12px;
}
}


/* LABEL COLUMN: Left Aligned */
/* 5. The Label (Left Side) */
.infobox-label {
.infobox-label {
     flex: 0 0 100px;     /* Slightly smaller fixed width */
     flex: 0 0 45%; /* Takes up 45% of the width */
     max-width: 100px;
     max-width: 45%;
      
      
    padding: 8px 0 8px 15px; /* Matches header left padding */
     font-weight: bold;
     font-weight: 600;
     color: #54595d;
     opacity: 0.8;
     text-align: right; /* Aligns text near the center line */
     text-align: left;
    padding-right: 15px; /* Space between label and value */
}
}


/* VALUE COLUMN: Left Aligned */
/* 6. The Value (Right Side) */
.infobox-row > span:last-child {
.infobox-row > span:last-child {
     flex: 1 1 auto;
     flex: 1;
    min-width: 0;        /* Prevents breaking */
   
    padding: 8px 15px 8px 10px;
     text-align: left;
     text-align: left;
     word-wrap: break-word;
    color: var(--color-base, #222);
     word-break: break-word;
}
}


/* IMAGE (Still Centered by default, looks better for photos) */
/* Optional: Zebra Striping (Makes it look like data) */
.infobox-image {
.infobox-row:nth-child(even) {
    text-align: center;
     background-color: rgba(0,0,0,0.02) !important;
    padding: 10px 0;
     background-color: var(--background-color-surface, #fff);
    border-bottom: 1px solid var(--border-color-subtle, #eaecf0);
}
}


/* DARK MODE OVERRIDES */
/* --- DARK MODE ADJUSTMENTS --- */
html.skin-citizen-dark .infobox-header,
html.skin-citizen-dark .infobox-header,
html[data-theme="dark"] .infobox-header {
html[data-theme="dark"] .infobox-header {
     background-color: #3a6c8e;  
     background-color: #3a6c8e;
     border-bottom: 1px solid var(--border-color-base);
     border-bottom: 1px solid #4a4d50;
}
 
html.skin-citizen-dark .infobox,
html[data-theme="dark"] .infobox {
    background-color: #202124;
    border-color: #4a4d50;
}
 
html.skin-citizen-dark .infobox-row,
html[data-theme="dark"] .infobox-row {
    border-bottom: 1px solid #4a4d50;
}
 
html.skin-citizen-dark .infobox-image,
html[data-theme="dark"] .infobox-image {
    background-color: #202124;
}
}

Revision as of 02:07, 29 December 2025

/* --- LIQUIPEDIA STYLE UNIFIED BOX --- */

/* 1. The Outer Container (The only part with a border) */
.infobox {
    float: right;
    clear: right;
    width: 300px;
    margin-left: 1rem;
    margin-bottom: 1rem;
    padding: 0;
    
    /* Design: One solid box */
    background-color: var(--background-color-surface, #fff);
    border: 1px solid #a2a9b1; /* Standard Grey Border */
    border-radius: 2px; /* Very slight rounding like Liquipedia */
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
    
    font-size: 0.9rem;
    color: var(--color-base, #222);
}

/* 2. The Header */
.infobox-header {
    text-align: center;
    font-weight: bold;
    padding: 10px;
    font-size: 1.1rem;
    
    /* Liquipedia Blue */
    background-color: #2b7bb9;
    color: #ffffff;
    border-bottom: 1px solid #a2a9b1;
}

/* 3. The Image Area */
.infobox-image {
    text-align: center;
    padding: 10px 0;
    background-color: #fff; /* Always white for images */
    border-bottom: 1px solid #eaecf0;
}

/* 4. The Rows (Clean lines, no gaps) */
.infobox-row {
    display: flex;
    flex-direction: row; /* FORCE Side-by-Side */
    flex-wrap: nowrap;
    align-items: center; /* Vertically center the text */
    
    /* Remove the "Card" look */
    margin: 0 !important;
    border-radius: 0 !important;
    background-color: transparent !important;
    box-shadow: none !important;
    
    /* Add a clean divider line */
    border-bottom: 1px solid #eaecf0;
    padding: 8px 12px;
}

/* 5. The Label (Left Side) */
.infobox-label {
    flex: 0 0 45%; /* Takes up 45% of the width */
    max-width: 45%;
    
    font-weight: bold;
    color: #54595d;
    text-align: right; /* Aligns text near the center line */
    padding-right: 15px; /* Space between label and value */
}

/* 6. The Value (Right Side) */
.infobox-row > span:last-child {
    flex: 1;
    text-align: left;
    color: var(--color-base, #222);
    word-break: break-word;
}

/* Optional: Zebra Striping (Makes it look like data) */
.infobox-row:nth-child(even) {
    background-color: rgba(0,0,0,0.02) !important;
}

/* --- DARK MODE ADJUSTMENTS --- */
html.skin-citizen-dark .infobox-header,
html[data-theme="dark"] .infobox-header {
    background-color: #3a6c8e;
    border-bottom: 1px solid #4a4d50;
}

html.skin-citizen-dark .infobox,
html[data-theme="dark"] .infobox {
    background-color: #202124;
    border-color: #4a4d50;
}

html.skin-citizen-dark .infobox-row,
html[data-theme="dark"] .infobox-row {
    border-bottom: 1px solid #4a4d50;
}

html.skin-citizen-dark .infobox-image,
html[data-theme="dark"] .infobox-image {
    background-color: #202124;
}