MediaWiki:Common.css

From Toon Wiki
Revision as of 23:17, 22 December 2025 by Admin (talk | contribs) (Enhanced styling)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Note: After publishing, you may have to bypass your browser's cache to see the changes.

  • Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
  • Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
  • Internet Explorer / Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5
  • Opera: Press Ctrl-F5.
/* ============================================
   TOON WIKI - AVATAR WIKI STYLE
   Modern, Clean, Engaging Design
   ============================================ */

:root {
    --aw-brown-dark: #611e03;
    --aw-brown-medium: #8b4513;
    --aw-brown-light: #c8651d;
    --aw-cream: #fff8dc;
    --aw-cream-dark: #f5ecd3;
    --aw-text: #3a3a3a;
    --aw-text-light: #666;
    --aw-border: #d4c4a8;
    --aw-air: #ff9900;
    --aw-water: #1e90ff;
    --aw-earth: #228b22;
    --aw-fire: #cc0000;
    --aw-radius: 6px;
    --aw-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

/* ===== Base Layout ===== */
body {
    background: linear-gradient(135deg, #f8f5f0 0%, #f0ebe3 100%);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}
.mw-body {
    background: var(--aw-cream);
    border: 1px solid var(--aw-border);
    border-radius: var(--aw-radius);
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}

/* ===== Typography ===== */
.mw-parser-output {
    font-size: 15px;
    line-height: 1.7;
    color: var(--aw-text);
}
.mw-parser-output p {
    margin-bottom: 1em;
}
.mw-parser-output a {
    color: var(--aw-brown-medium);
    transition: all 0.15s ease;
}
.mw-parser-output a:hover {
    color: var(--aw-brown-dark);
}
.mw-parser-output a.new {
    color: #ba0000;
}

/* ===== Page Title ===== */
.mw-page-title-main {
    color: var(--aw-brown-dark);
    font-weight: 700;
    font-size: 1.8em;
    letter-spacing: -0.02em;
}

/* ===== Section Headers ===== */
.mw-parser-output h2 {
    border-bottom: 3px solid var(--aw-brown-dark);
    color: var(--aw-brown-dark);
    font-size: 1.5em;
    font-weight: 600;
    padding-bottom: 8px;
    margin: 2em 0 1em 0;
}
.mw-parser-output h3 {
    color: var(--aw-brown-dark);
    font-size: 1.2em;
    font-weight: 600;
    border-bottom: 2px solid var(--aw-border);
    padding-bottom: 6px;
    margin: 1.5em 0 0.8em 0;
}
.mw-parser-output h4 {
    color: var(--aw-brown-medium);
    font-weight: 600;
}

/* ===== Quote Box ===== */
.quote-box {
    background: linear-gradient(135deg, var(--aw-cream-dark) 0%, var(--aw-cream) 100%);
    border: none;
    border-left: 5px solid var(--aw-brown-dark);
    border-radius: 0 var(--aw-radius) var(--aw-radius) 0;
    color: var(--aw-text);
    padding: 20px 25px;
    margin: 1.5em 0;
    box-shadow: var(--aw-shadow);
    position: relative;
    overflow: hidden;
}
.quote-box::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 10px;
    font-size: 80px;
    color: rgba(139, 69, 19, 0.1);
    font-family: Georgia, serif;
}
.quote-box p {
    position: relative;
    z-index: 1;
    margin: 0;
}
.quote-air { border-left-color: var(--aw-air); }
.quote-air::before { color: rgba(255, 153, 0, 0.15); }
.quote-water { border-left-color: var(--aw-water); }
.quote-water::before { color: rgba(30, 144, 255, 0.15); }
.quote-earth { border-left-color: var(--aw-earth); }
.quote-earth::before { color: rgba(34, 139, 34, 0.15); }
.quote-fire { border-left-color: var(--aw-fire); }
.quote-fire::before { color: rgba(204, 0, 0, 0.15); }

/* ===== Character Infobox ===== */
.character-infobox {
    background: white;
    border: 2px solid var(--aw-border);
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
    overflow: hidden;
    font-size: 13px;
}
.character-infobox > div:first-child {
    background: linear-gradient(135deg, var(--aw-brown-dark) 0%, #7a2a08 100%);
    color: white;
    font-size: 1.25em;
    padding: 15px;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}
.character-infobox table {
    border-collapse: collapse;
}
.character-infobox th {
    background: var(--aw-cream);
    color: var(--aw-brown-dark);
    font-weight: 600;
    padding: 8px 12px;
    border-bottom: 1px solid var(--aw-border);
    text-align: left;
    vertical-align: top;
}
.character-infobox td {
    background: white;
    padding: 8px 12px;
    border-bottom: 1px solid #f0f0f0;
    vertical-align: top;
}
.character-infobox tr:hover th,
.character-infobox tr:hover td {
    background: var(--aw-cream-dark);
}
.character-infobox a {
    color: var(--aw-brown-medium);
}

/* ===== Infobox Gallery as Tabs ===== */
.infobox-image {
    background: #f5f5f5;
    padding: 0;
    position: relative;
}
.infobox-image .gallery {
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
}
.infobox-image .gallerybox {
    width: 100% !important;
    margin: 0;
    border: none;
    border-radius: 0;
}
/* Hide all gallery items except first by default */
.infobox-image .gallerybox:not(:first-child) {
    display: none;
}
/* Show tab when active */
.infobox-image .gallerybox.active {
    display: block !important;
}
.infobox-image .gallerybox .thumb {
    width: 100%;
    height: auto;
    padding: 15px;
    background: white;
}
.infobox-image .gallerybox img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
    border-radius: 4px;
}
.infobox-image .gallerytext {
    display: none;
}

/* Tab Navigation */
.infobox-tabs {
    display: flex;
    background: var(--aw-cream);
    border-top: 1px solid var(--aw-border);
}
.infobox-tabs .tab-btn {
    flex: 1;
    padding: 10px 8px;
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: var(--aw-text-light);
    background: var(--aw-cream);
    border: none;
    border-right: 1px solid var(--aw-border);
    cursor: pointer;
    transition: all 0.2s ease;
}
.infobox-tabs .tab-btn:last-child {
    border-right: none;
}
.infobox-tabs .tab-btn:hover {
    background: var(--aw-cream-dark);
    color: var(--aw-brown-dark);
}
.infobox-tabs .tab-btn.active {
    background: var(--aw-brown-dark);
    color: white;
}

/* ===== Icons Bar ===== */
#icons {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
    background: var(--aw-cream-dark);
    border: 1px solid var(--aw-border);
    border-radius: var(--aw-radius);
    padding: 8px 12px;
    margin-bottom: 1em;
}
#icons img {
    transition: transform 0.2s ease;
}
#icons img:hover {
    transform: scale(1.2);
}

/* ===== Table of Contents ===== */
.toc,
.mw-toc {
    background: linear-gradient(135deg, var(--aw-cream-dark) 0%, var(--aw-cream) 100%);
    border: 1px solid var(--aw-border);
    border-radius: var(--aw-radius);
    padding: 15px 20px;
    margin: 1.5em 0;
    box-shadow: var(--aw-shadow);
    display: inline-block;
    max-width: 350px;
}
.toc a,
.mw-toc a {
    color: var(--aw-brown-medium);
    text-decoration: none;
}
.toc a:hover,
.mw-toc a:hover {
    color: var(--aw-brown-dark);
    text-decoration: underline;
}
.toctitle h2,
.mw-toc-heading {
    color: var(--aw-brown-dark);
    border: none;
    font-size: 1em;
    font-weight: 700;
    margin: 0 0 10px 0;
}
.toc ul,
.mw-toc ul {
    margin: 0;
    padding-left: 1.5em;
}
.toc li,
.mw-toc li {
    padding: 3px 0;
}

/* ===== Thumbnails & Figures ===== */
figure.mw-halign-left,
figure.mw-halign-right,
.thumb {
    background: white;
    border: 1px solid var(--aw-border);
    border-radius: var(--aw-radius);
    box-shadow: var(--aw-shadow);
    overflow: hidden;
    transition: box-shadow 0.2s ease;
}
figure.mw-halign-left:hover,
figure.mw-halign-right:hover,
.thumb:hover {
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}
figure figcaption,
.thumbcaption {
    background: var(--aw-cream-dark);
    color: var(--aw-text);
    font-size: 12px;
    line-height: 1.4;
    padding: 8px 12px;
    border-top: 1px solid var(--aw-border);
}

/* ===== Standard Gallery ===== */
.gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-start;
}
.gallery .gallerybox {
    background: white;
    border: 1px solid var(--aw-border);
    border-radius: var(--aw-radius);
    overflow: hidden;
    transition: all 0.2s ease;
}
.gallery .gallerybox:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    transform: translateY(-2px);
}
.gallery .gallerytext {
    background: var(--aw-cream-dark);
    color: var(--aw-text);
    font-size: 11px;
    padding: 6px 8px;
    text-align: center;
}

/* ===== Family Tree ===== */
.familytree {
    background: var(--aw-cream-dark);
    border: 1px solid var(--aw-border);
    border-radius: var(--aw-radius);
    padding: 15px;
    overflow-x: auto;
}
.family-tree-element {
    background: white;
    border: 2px solid var(--aw-brown-dark);
    border-radius: 4px;
    padding: 5px 10px;
    color: var(--aw-text);
    transition: all 0.2s ease;
    white-space: nowrap;
}
.family-tree-element:hover {
    background: var(--aw-brown-dark);
    color: white;
}
.family-tree-element a {
    color: var(--aw-brown-medium);
}
.family-tree-element:hover a {
    color: white;
}
.family-tree-line-solid-right { border-right: 2px solid var(--aw-brown-medium); }
.family-tree-line-solid-bottom { border-bottom: 2px solid var(--aw-brown-medium); }
.family-tree-line-solid-left { border-left: 2px solid var(--aw-brown-medium); }
.family-tree-line-solid-top { border-top: 2px solid var(--aw-brown-medium); }

/* ===== References ===== */
.references,
.mw-references-wrap {
    background: var(--aw-cream-dark);
    border: 1px solid var(--aw-border);
    border-radius: var(--aw-radius);
    font-size: 13px;
    padding: 15px 20px;
    margin-top: 1.5em;
}
.reference a {
    color: var(--aw-brown-medium);
}

/* ===== Categories ===== */
#catlinks {
    background: var(--aw-cream-dark);
    border: 1px solid var(--aw-border);
    border-radius: var(--aw-radius);
    margin-top: 2em;
    padding: 12px 15px;
}
#catlinks a {
    color: var(--aw-brown-medium);
}

/* ===== Imported Content Notice ===== */
.mw-parser-output > div:first-child {
    margin-bottom: 1em;
}

/* ===== Disambiguation ===== */
.mw-parser-output > dl > dd {
    font-style: italic;
    color: var(--aw-text-light);
    margin-bottom: 1em;
}

/* ===== Mobile Responsive ===== */
@media screen and (max-width: 768px) {
    .character-infobox {
        float: none !important;
        width: 100% !important;
        max-width: 400px !important;
        margin: 1em auto !important;
    }
    figure.mw-halign-left,
    figure.mw-halign-right {
        float: none !important;
        margin: 1em auto !important;
        max-width: 100% !important;
    }
    .quote-box {
        margin: 1em 0 !important;
        padding: 15px !important;
    }
    .quote-box::before {
        font-size: 50px;
    }
    #icons {
        justify-content: center;
    }
    .toc,
    .mw-toc {
        max-width: 100%;
        display: block;
    }
    .mw-parser-output h2 {
        font-size: 1.3em;
    }
}

/* ===== Smooth Scrolling ===== */
html {
    scroll-behavior: smooth;
}

/* ===== Selection Color ===== */
::selection {
    background: var(--aw-brown-light);
    color: white;
}

/* ===== Focus States for Accessibility ===== */
a:focus,
button:focus {
    outline: 2px solid var(--aw-brown-dark);
    outline-offset: 2px;
}

/* ===== Print Styles ===== */
@media print {
    .toc,
    #icons,
    .infobox-tabs {
        display: none !important;
    }
    .character-infobox {
        float: none !important;
        width: 100% !important;
        box-shadow: none !important;
    }
}