Jump to content

MediaWiki:Common.css: Difference between revisions

From Eldrasil Wiki
No edit summary
No edit summary
Line 1: Line 1:
.mw-body {
Got it. Below is a dark, subtly blue theme for Minerva plus a structured Main_Page layout. Paste the CSS into MediaWiki:Common.css (or MediaWiki:Minerva.css if you want skin-specific styling), then use the HTML on Main_Page.
position: relative;
min-height: 100vh; /* full viewport height */
background-image:
linear-gradient(rgba(0, 0, 0, 0.9), rgba(0, 0, 0, 0.9)),
url('/wiki/assets/bg.jpeg');
background-size: cover;
background-position: center;
background-repeat: no-repeat;
}
body.page-Main_Page #firstHeading {
    display: none;
}
 
/* General body styles for the main page content area */
 
.mw-parser-output {
 
    background-color: #1c1c24; /* Dark background for the content area */


    color: #e0e0e0;
CSS (Common.css)
/* Eldrasil Wiki — Dark theme with subtle blue accent */


/* Tokens /
:root {
--bg: #0f1318;
--surface: #141a21;
--surface-2: #1b232c;
--text: #e5e9f0;
--muted: #a9b4c2;
--blue: #6ea8ff; / subtle blue /
--blue-2: #89b8ff; / hover */
--link: #7fb3ff;
--link-visited: #a5c4ff;
--border: #243040;
--radius: 12px;
--shadow: 0 2px 12px rgba(0,0,0,0.35);
}
}


 
/* Global dark mode */
 
body.skin-minerva,
/* Main container for the entire layout */
body {
 
color-scheme: dark;
.eldrasil-main-container {
background: var(--bg);
 
color: var(--text);
    display: flex;
 
    flex-wrap: wrap;
 
    gap: 20px;
 
    padding: 20px;
 
    max-width: 1200px;
 
    margin: auto;
 
}
}


 
/* Constrain width on desktop so content isn't too wide /
 
@media (min-width: 768px) {
/* Left and right columns */
body.skin-minerva #mw-mf-page-center .content,
 
body.skin-minerva #content,
.eldrasil-left-column, .eldrasil-right-column {
body.skin-minerva .content,
    display: flex;
body .mw-body {
    flex-direction: column;
max-width: 1100px; / adjust to taste: 960–1100px */
    gap: 20px;
margin-left: auto !important;
margin-right: auto !important;
padding-left: 16px;
padding-right: 16px;
}
}
.eldrasil-left-column {
    flex: 3;
    min-width: 300px;
}
}


.eldrasil-right-column {
/* Improve line length of top-level paragraphs */
    flex: 1;
body.skin-minerva .mw-parser-output > p {
    min-width: 250px;
max-width: 75ch;
}
}


/* Links */
.mw-parser-output a,
a { color: var(--link); }
a:visited { color: var(--link-visited); }
a:hover, a:focus { color: var(--blue-2); }


 
/* Headings and common boxes */
/* General box styling */
.mw-parser-output h1, .mw-parser-output h2, .mw-parser-output h3 {
.eldrasil-box {
color: var(--text);
    background-color: #2a2a3e;
    border: 1px solid #4a4a6a;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}
}
 
.mw-parser-output table.wikitable,
 
.mw-parser-output .infobox {
 
background: var(--surface);
/* Welcome section */
color: var(--text);
 
border: 1px solid var(--border);
.eldrasil-welcome-box {
    display: flex;
    align-items: center;
    gap: 20px;
 
}
}
hr { border-color: var(--border); }


 
/* Messages/TOC/navboxes on dark */
 
.mw-message-box, .ambox, .navbox, .portal, .toc, .mw-notification {
.eldrasil-welcome-box img {
background: var(--surface);
    width: 200px;
border-color: var(--border);
    height: 260px;
color: var(--text);
}
}


 
/* Search inputs (Minerva) */
 
.skin-minerva .search-box,
.eldrasil-welcome-text h2 {
.skin-minerva .mw-ui-input,
 
.skin-minerva input[type="search"] {
    margin: 0;
background: var(--surface);
 
color: var(--text);
    color: #ffffff;
border: 1px solid var(--border);
 
    font-size: 1.8em;
 
}
}
.skin-minerva input[type="search"]::placeholder { color: var(--muted); }


/* Images */
.mw-parser-output img { border-radius: 8px; }


 
/* Main Page specific */
.eldrasil-welcome-text p {
body.page-Main_Page .eld-hero {
 
background: linear-gradient(180deg, rgba(110,168,255,0.06), rgba(110,168,255,0.02)), var(--surface);
    margin: 5px 0 0;
border: 1px solid var(--border);
 
padding: 28px;
    font-size: 1.1em;
border-radius: var(--radius);
 
box-shadow: var(--shadow);
}
}
 
body.page-Main_Page .eld-hero__title {
 
font-size: 2rem;
 
margin: 0 0 8px 0;
/* Stats section */
letter-spacing: 0.2px;
 
.eldrasil-stats-box {
 
    display: flex;
 
    justify-content: space-around;
 
    text-align: center;
 
}
}
 
body.page-Main_Page .eld-hero__tagline {
 
color: var(--muted);
 
margin: 0 0 16px 0;
.eldrasil-stat {
font-size: 1rem;
 
    font-size: 1.1em;
 
}
}
 
body.page-Main_Page .eld-hero__actions {
 
display: flex;
 
gap: 12px;
.eldrasil-stat-number {
flex-wrap: wrap;
 
    display: block;
 
    font-size: 1.5em;
 
    font-weight: bold;
 
    color: #ffffff;
 
}
}
 
.eld-btn {
 
display: inline-flex;
 
align-items: center;
/* Content grid */
padding: 10px 14px;
 
border-radius: 10px;
.eldrasil-content-grid {
text-decoration: none;
 
font-weight: 600;
    display: grid;
border: 1px solid var(--border);
 
background: var(--surface-2);
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
color: var(--text);
 
    gap: 15px;
 
    text-align: center;
 
}
}
 
.eld-btn--primary {
 
background: linear-gradient(180deg, rgba(110,168,255,0.18), rgba(110,168,255,0.08));
 
border-color: #2a3a52;
.eldrasil-content-item {
 
    background-color: #3a3a5a;
 
    padding: 15px;
 
    border-radius: 6px;
 
    transition: background-color 0.3s;
 
    cursor: pointer;
 
}
}
.eld-btn:hover { filter: brightness(1.1); }


 
/* Grid/cards */
 
body.page-Main_Page .eld-section-title {
.eldrasil-content-item:hover {
margin: 22px 0 10px 0;
 
border-bottom: 1px solid var(--border);
    background-color: #4a4a7a;
padding-bottom: 6px;
 
}
}
 
body.page-Main_Page .eld-grid {
 
display: grid;
 
grid-template-columns: 1fr;
.eldrasil-content-item img {
gap: 16px;
 
margin-top: 18px;
    width: 50px;
 
    height: 50px;
 
    margin-bottom: 10px;
 
}
}
 
@media (min-width: 650px) {
 
body.page-Main_Page .eld-grid { grid-template-columns: repeat(2, 1fr); }
 
.eldrasil-content-item a {
 
    color: #e0e0e0;
 
    text-decoration: none;
 
    font-weight: bold;
 
}
}
 
@media (min-width: 1000px) {
 
body.page-Main_Page .eld-grid { grid-template-columns: repeat(3, 1fr); }
 
/* Sidebar boxes */
 
.eldrasil-sidebar-box h3 {
 
    margin-top: 0;
 
    color: #ffffff;
 
    border-bottom: 2px solid #4a4a6a;
 
    padding-bottom: 10px;
 
    margin-bottom: 15px;
 
}
}
 
.eld-card {
 
background: var(--surface);
 
border: 1px solid var(--border);
.eldrasil-gametime {
border-radius: var(--radius);
 
padding: 16px;
    text-align: center;
box-shadow: var(--shadow);
 
}
 
 
 
.eldrasil-gametime .time {
 
    font-size: 2.5em;
 
    font-weight: bold;
 
    color: #ffffff;
 
    margin-bottom: 5px;
 
}
 
 
 
.eldrasil-gametime .date {
 
    font-size: 1.1em;
 
}
 
 
 
.eldrasil-news ul {
 
    list-style: none;
 
    padding: 0;
 
}
 
 
 
.eldrasil-news li {
 
    margin-bottom: 15px;
 
}
 
 
 
.eldrasil-news a {
 
    color: #a0a0ff;
 
    text-decoration: none;
 
    font-weight: bold;
 
}
 
 
 
.eldrasil-news p {
 
    margin: 5px 0 0 15px;
 
    font-size: 0.95em;
 
    line-height: 1.4;
 
}
}
.eld-card h3 { margin-top: 0; font-size: 1.1rem; }
.eld-card p { color: var(--muted); margin-bottom: 10px; }
.eld-card a { color: var(--link); }

Revision as of 00:43, 16 October 2025

Got it. Below is a dark, subtly blue theme for Minerva plus a structured Main_Page layout. Paste the CSS into MediaWiki:Common.css (or MediaWiki:Minerva.css if you want skin-specific styling), then use the HTML on Main_Page.

CSS (Common.css)
/* Eldrasil Wiki — Dark theme with subtle blue accent */

/* Tokens /
:root {
--bg: #0f1318;
--surface: #141a21;
--surface-2: #1b232c;
--text: #e5e9f0;
--muted: #a9b4c2;
--blue: #6ea8ff; / subtle blue /
--blue-2: #89b8ff; / hover */
--link: #7fb3ff;
--link-visited: #a5c4ff;
--border: #243040;
--radius: 12px;
--shadow: 0 2px 12px rgba(0,0,0,0.35);
}

/* Global dark mode */
body.skin-minerva,
body {
color-scheme: dark;
background: var(--bg);
color: var(--text);
}

/* Constrain width on desktop so content isn't too wide /
@media (min-width: 768px) {
body.skin-minerva #mw-mf-page-center .content,
body.skin-minerva #content,
body.skin-minerva .content,
body .mw-body {
max-width: 1100px; / adjust to taste: 960–1100px */
margin-left: auto !important;
margin-right: auto !important;
padding-left: 16px;
padding-right: 16px;
}
}

/* Improve line length of top-level paragraphs */
body.skin-minerva .mw-parser-output > p {
max-width: 75ch;
}

/* Links */
.mw-parser-output a,
a { color: var(--link); }
a:visited { color: var(--link-visited); }
a:hover, a:focus { color: var(--blue-2); }

/* Headings and common boxes */
.mw-parser-output h1, .mw-parser-output h2, .mw-parser-output h3 {
color: var(--text);
}
.mw-parser-output table.wikitable,
.mw-parser-output .infobox {
background: var(--surface);
color: var(--text);
border: 1px solid var(--border);
}
hr { border-color: var(--border); }

/* Messages/TOC/navboxes on dark */
.mw-message-box, .ambox, .navbox, .portal, .toc, .mw-notification {
background: var(--surface);
border-color: var(--border);
color: var(--text);
}

/* Search inputs (Minerva) */
.skin-minerva .search-box,
.skin-minerva .mw-ui-input,
.skin-minerva input[type="search"] {
background: var(--surface);
color: var(--text);
border: 1px solid var(--border);
}
.skin-minerva input[type="search"]::placeholder { color: var(--muted); }

/* Images */
.mw-parser-output img { border-radius: 8px; }

/* Main Page specific */
body.page-Main_Page .eld-hero {
background: linear-gradient(180deg, rgba(110,168,255,0.06), rgba(110,168,255,0.02)), var(--surface);
border: 1px solid var(--border);
padding: 28px;
border-radius: var(--radius);
box-shadow: var(--shadow);
}
body.page-Main_Page .eld-hero__title {
font-size: 2rem;
margin: 0 0 8px 0;
letter-spacing: 0.2px;
}
body.page-Main_Page .eld-hero__tagline {
color: var(--muted);
margin: 0 0 16px 0;
font-size: 1rem;
}
body.page-Main_Page .eld-hero__actions {
display: flex;
gap: 12px;
flex-wrap: wrap;
}
.eld-btn {
display: inline-flex;
align-items: center;
padding: 10px 14px;
border-radius: 10px;
text-decoration: none;
font-weight: 600;
border: 1px solid var(--border);
background: var(--surface-2);
color: var(--text);
}
.eld-btn--primary {
background: linear-gradient(180deg, rgba(110,168,255,0.18), rgba(110,168,255,0.08));
border-color: #2a3a52;
}
.eld-btn:hover { filter: brightness(1.1); }

/* Grid/cards */
body.page-Main_Page .eld-section-title {
margin: 22px 0 10px 0;
border-bottom: 1px solid var(--border);
padding-bottom: 6px;
}
body.page-Main_Page .eld-grid {
display: grid;
grid-template-columns: 1fr;
gap: 16px;
margin-top: 18px;
}
@media (min-width: 650px) {
body.page-Main_Page .eld-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1000px) {
body.page-Main_Page .eld-grid { grid-template-columns: repeat(3, 1fr); }
}
.eld-card {
background: var(--surface);
border: 1px solid var(--border);
border-radius: var(--radius);
padding: 16px;
box-shadow: var(--shadow);
}
.eld-card h3 { margin-top: 0; font-size: 1.1rem; }
.eld-card p { color: var(--muted); margin-bottom: 10px; }
.eld-card a { color: var(--link); }