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

Template:Main Page/styles.css: Difference between revisions

Template page
Created page with "{{pp|small=yes}}: .mp-box { border: 1px solid #aaa; all colors overriden on specific elements in @media screen: padding: 0 0.5em 0.5em; margin-top: 4px; } .mp-h2, body.skin-timeless .mp-h2 { Timeless needs a higher specificity: border: 1px solid #aaa; all colors overriden on specific elements in @media screen: margin: 0.5em 0; padding: 0.2em 0.4em; font-size: 120%; font-weight: bold; font-family: inherit; } .mp-later { font-size: 85%; fon..."
Tag: Recreated
 
No edit summary
 
(53 intermediate revisions by the same user not shown)
Line 1: Line 1:
/* {{pp|small=yes}} */
/**
.mp-box {
* ComputerScience.wiki - Final Fix
border: 1px solid #aaa; /* all colors overriden on specific elements in @media screen */
* 1. Responsive Grid
padding: 0 0.5em 0.5em;
* 2. EXACT colors from your original file
margin-top: 4px;
* 3. FIX: Added 'clientpref-os' for automatic dark mode support
*/
 
/* --- 1. CONTAINER & TYPOGRAPHY --- */
.cs-container {
    max-width: 1200px;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    padding: 0 10px;
}
}


.mp-h2,
/* --- 2. HEADER --- */
body.skin-timeless .mp-h2 { /* Timeless needs a higher specificity */
.cs-header {
border: 1px solid #aaa; /* all colors overriden on specific elements in @media screen */
    text-align: center;
margin: 0.5em 0;
    padding: 30px 20px;
padding: 0.2em 0.4em;
    margin-bottom: 30px;
font-size: 120%;
    border-radius: 8px;
font-weight: bold;
    background-color: #f9f9f9;
font-family: inherit;
    border: 1px solid #ddd;
}
}


.mp-later {
.cs-title {
font-size: 85%;
    font-size: 2em;
font-weight: normal;
    font-weight: 700;
    margin: 0;
    color: #000;
    border: none;
}
}


#mp-welcomecount {
.cs-subtitle {
text-align: center;
    font-size: 1.1em;
margin: 0.4em;
    font-weight: normal;
    margin: 10px 0 0;
    color: #444;
}
}


#mp-welcome {
/* --- 3. SEARCH BAR --- */
font-size: 162%;
.cs-search {
padding: 0.1em;
    max-width: 800px;
    margin: 0 auto 40px;
    padding: 25px;
    border-radius: 8px;
    background-color: #f5f5f5;
    border: 1px solid #ddd;
}
}


#mp-welcome h1,
.cs-search input[type="search"],
#mp-welcome .mw-heading1 {
.cs-search .mw-searchInput {
font-size: inherit;
    background-color: #ffffff !important;
font-family: inherit;
    border: 1px solid #ddd !important;
display: inline;
    height: 40px !important;
border: none;
    padding: 5px 12px !important;
    border-radius: 4px !important;
    font-size: 16px !important;
    color: #333 !important;
    width: 100% !important;
}
}


#mp-free {
.cs-search input[type="submit"],
font-size: 95%;
.cs-search .oo-ui-buttonElement-button {
    min-width: 80px !important;
    background-color: #f0f0f0 !important;
    border: 1px solid #ddd !important;
    height: 40px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    color: #333 !important;
}
}


#articlecount {
.cs-search input[name="fulltext"] { display: none !important; }
font-size: 85%;
 
/* --- 4. GRID LAYOUT --- */
.cs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}
}


#articlecount > ul {
/* --- 5. CARDS & SECTIONS (Light Mode Defaults) --- */
margin: 0;
.cs-section { margin-bottom: 30px; }
padding: 0;
.cs-section-header { padding: 12px 15px; margin-bottom: 20px; border-radius: 6px; }
.cs-section-title { margin: 0; font-size: 1.3em; font-weight: 600; border: none; }
 
.cs-card {
    border-radius: 6px;
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
    border-width: 1px;
    border-style: solid;
    transition: transform 0.2s;
}
}


#articlecount > ul > li {
.cs-card:hover { transform: translateY(-3px); }
margin: 0;  
 
display: inline;
.cs-card-header { padding: 12px 15px; }
}
.cs-card-title { margin: 0; font-size: 1.1em; font-weight: 600; border: none; }
.cs-card-body { padding: 15px; flex-grow: 1; }
.cs-card-list { margin: 0; padding: 0 0 0 10px; list-style: none; }
.cs-card-list li { margin-bottom: 8px; }
.cs-card-footer { padding: 8px 15px; text-align: right; font-weight: bold; }
.cs-card-footer a { text-decoration: none; }
 
/* ========================================================= */
/* === COLOR THEMES (Light Mode) === */
/* ========================================================= */
 
/* PROGRAMMING (Green) */
.cs-section.prog .cs-section-header { background-color: #cef2e0; border: 1px solid #cef2e0; }
.cs-section.prog .cs-card { background-color: #f5fffa; border-color: #cef2e0; }
.cs-section.prog .cs-card-header { background-color: #cef2e0; border-bottom: 1px solid #cef2e0; }
.cs-section.prog .cs-card-footer { background-color: #f5fffa; border-top: 1px solid #cef2e0; }
.cs-section.prog .cs-card-footer a { color: #2e8b57; }


#articlecount > ul > li::after {
/* DATA SCIENCE (Blue) */
content: " · ";
.cs-section.data .cs-section-header { background-color: #cedff2; border: 1px solid #cedff2; }
font-weight: bold;
.cs-section.data .cs-card { background-color: #f5faff; border-color: #cedff2; }
}
.cs-section.data .cs-card-header { background-color: #cedff2; border-bottom: 1px solid #cedff2; }
.cs-section.data .cs-card-footer { background-color: #f5faff; border-top: 1px solid #cedff2; }
.cs-section.data .cs-card-footer a { color: #4169e1; }


#articlecount > ul > li:last-child::after {
/* DATABASES (Pink) */
content: "";
.cs-section.db .cs-section-header { background-color: #f2cedd; border: 1px solid #f2cedd; }
}
.cs-section.db .cs-card { background-color: #fff5fa; border-color: #f2cedd; }
.cs-section.db .cs-card-header { background-color: #f2cedd; border-bottom: 1px solid #f2cedd; }
.cs-section.db .cs-card-footer { background-color: #fff5fa; border-top: 1px solid #f2cedd; }
.cs-section.db .cs-card-footer a { color: #db7093; }


#mp-banner {
/* INFRASTRUCTURE (Purple) */
text-align: center;
.cs-section.inf .cs-section-header { background-color: #ddcef2; border: 1px solid #ddcef2; }
padding-top: 0.5em;
.cs-section.inf .cs-card { background-color: #faf5ff; border-color: #ddcef2; }
}
.cs-section.inf .cs-card-header { background-color: #ddcef2; border-bottom: 1px solid #ddcef2; }
.cs-section.inf .cs-card-footer { background-color: #faf5ff; border-top: 1px solid #ddcef2; }
.cs-section.inf .cs-card-footer a { color: #8a2be2; }


/* clear fix */
/* FUNDAMENTALS (Orange) */
.mp-contains-float::after {
.cs-section.fund .cs-section-header { background-color: #f2e0ce; border: 1px solid #f2e0ce; }
content: "";
.cs-section.fund .cs-card { background-color: #fffaf5; border-color: #f2e0ce; }
display: block;
.cs-section.fund .cs-card-header { background-color: #f2e0ce; border-bottom: 1px solid #f2e0ce; }
clear: both;
.cs-section.fund .cs-card-footer { background-color: #fffaf5; border-top: 1px solid #f2e0ce; }
}
.cs-section.fund .cs-card-footer a { color: #d2691e; }


@media (max-width: 875px) {
/* COMMUNITY (Grey) */
/* We need to improve Template:POTD as used on the main page so that these
.cs-section.comm .cs-section-header { background-color: #eee; border: 1px solid #eee; }
* hacks aren't necessary */
.cs-section.comm .cs-card { background-color: #f9f9f9; border-color: #eee; }
#mp-tfp table,
.cs-section.comm .cs-card-header { background-color: #eee; border-bottom: 1px solid #eee; }
#mp-tfp tr,
.cs-section.comm .cs-card-footer { background-color: #f9f9f9; border-top: 1px solid #eee; }
#mp-tfp td,
.cs-section.comm .cs-card-footer a { color: #444; }
#mp-tfp tbody {
display: block !important;
width: 100% !important;
box-sizing: border-box;
}


#mp-tfp tr:first-child td:first-child a.mw-file-description {
text-align: center;
display: table;
margin: 0 auto;
}
#articlecount > ul > li::after {
content: "";
font-weight: normal;
}
#articlecount > ul > li {
display: block;
}
}


@media (min-width: 875px) {
/* ========================================================= */
#mp-upper {
/* === DARK MODE FIX (Citizen Skin) === */
display: flex;
/* ========================================================= */
}
#mp-left {
flex: 1 1 55%;
margin-right: 2px;
}
#mp-right {
flex: 1 1 45%;
margin-left: 2px;
}
}


@media screen {
@media screen {
#mp-topbanner {
    /* 1. Global Components - Dark Mode */
background-color: #f9f9f9;
    html.skin-theme-clientpref-night .cs-header,
border-color: #ddd;
    html.skin-theme-clientpref-os .cs-header {  
}
        background-color: #171a1d !important;  
        border-color: #676767 !important;  
#mp-banner {
    }
background-color: #fffaf5;
    html.skin-theme-clientpref-night .cs-title,
border-color: #f2e0ce;
    html.skin-theme-clientpref-os .cs-title { color: #fff !important; }
}
    html.skin-theme-clientpref-night .cs-subtitle,
    html.skin-theme-clientpref-os .cs-subtitle { color: #ccc !important; }
#mp-left {
   
background-color: #f5fffa;
    html.skin-theme-clientpref-night .cs-search,
border-color: #cef2e0;
    html.skin-theme-clientpref-os .cs-search {  
}
        background-color: #252525 !important;  
        border-color: #676767 !important;  
#mp-left .mp-h2 {
    }
background-color: #cef2e0;
    html.skin-theme-clientpref-night .cs-search input,
border-color: #a3bfb1;
    html.skin-theme-clientpref-os .cs-search input {  
}
        background-color: #1f1f1f !important;  
        color: #fff !important;  
#mp-right {
        border-color: #555 !important;  
background-color: #f5faff;
    }
border-color: #cedff2;
    html.skin-theme-clientpref-night .cs-search input[type="submit"],
}
    html.skin-theme-clientpref-os .cs-search input[type="submit"] {  
        background-color: #444 !important;  
#mp-right .mp-h2 {
        border-color: #555 !important;  
background-color: #cedff2;
        color: #fff !important;  
border-color: #a3b0bf;
    }
}
   
    html.skin-theme-clientpref-night .cs-section-title,
#mp-middle {
    html.skin-theme-clientpref-night .cs-card-title,
background-color: #fff5fa;
    html.skin-theme-clientpref-os .cs-section-title,
border-color: #f2cedd;
    html.skin-theme-clientpref-os .cs-card-title { color: #fff !important; }
}
   
    html.skin-theme-clientpref-night .cs-card-list li,
#mp-middle .mp-h2 {
    html.skin-theme-clientpref-os .cs-card-list li { color: #ccc !important; }
background-color: #f2cedd;
border-color: #bfa3af;
}
#mp-lower {
background-color: #faf5ff;
border-color: #ddcef2;
}
#mp-lower .mp-h2 {
background-color: #ddcef2;
border-color: #afa3bf;
}
#mp-bottom {
/* no background */
border-color: #e2e2e2;
}
#mp-bottom .mp-h2 {
background-color: #eee;
border-color: #ddd;
}


/* night mode */
    /* 2. Programming Dark */
html.skin-theme-clientpref-night #mp-topbanner {
    html.skin-theme-clientpref-night .cs-section.prog .cs-section-header,
background-color: #171a1d;
    html.skin-theme-clientpref-night .cs-section.prog .cs-card-header,
border-color: #676767;
    html.skin-theme-clientpref-os .cs-section.prog .cs-section-header,
}
    html.skin-theme-clientpref-os .cs-section.prog .cs-card-header { background-color: #104437 !important; border-color: #104437 !important; }
   
html.skin-theme-clientpref-night #mp-banner {
    html.skin-theme-clientpref-night .cs-section.prog .cs-card,
background-color: #331a00;
    html.skin-theme-clientpref-night .cs-section.prog .cs-card-footer,
border-color: #663428;
    html.skin-theme-clientpref-os .cs-section.prog .cs-card,
}
    html.skin-theme-clientpref-os .cs-section.prog .cs-card-footer { background-color: #0b1e1c !important; border-color: #104437 !important; }
   
html.skin-theme-clientpref-night #mp-left {
    html.skin-theme-clientpref-night .cs-section.prog .cs-card-footer a,
background-color: #0b1e1c;
    html.skin-theme-clientpref-os .cs-section.prog .cs-card-footer a { color: #8fbc8f !important; }
border-color: #104437;
 
}
    /* 3. Data Science Dark */
    html.skin-theme-clientpref-night .cs-section.data .cs-section-header,
html.skin-theme-clientpref-night #mp-left .mp-h2 {
    html.skin-theme-clientpref-night .cs-section.data .cs-card-header,
background-color: #104437;
    html.skin-theme-clientpref-os .cs-section.data .cs-section-header,
border-color: #2f4d41;
    html.skin-theme-clientpref-os .cs-section.data .cs-card-header { background-color: #082849 !important; border-color: #082849 !important; }
}
   
    html.skin-theme-clientpref-night .cs-section.data .cs-card,
html.skin-theme-clientpref-night #mp-right {
    html.skin-theme-clientpref-night .cs-section.data .cs-card-footer,
background-color: #0d1a27;
    html.skin-theme-clientpref-os .cs-section.data .cs-card,
border-color: #082849;
    html.skin-theme-clientpref-os .cs-section.data .cs-card-footer { background-color: #0d1a27 !important; border-color: #082849 !important; }
}
   
    html.skin-theme-clientpref-night .cs-section.data .cs-card-footer a,
html.skin-theme-clientpref-night #mp-right .mp-h2 {
    html.skin-theme-clientpref-os .cs-section.data .cs-card-footer a { color: #87cefa !important; }
background-color: #082849;
 
border-color: #a3b0bf;
    /* 4. Databases Dark */
}
    html.skin-theme-clientpref-night .cs-section.db .cs-section-header,
    html.skin-theme-clientpref-night .cs-section.db .cs-card-header,
html.skin-theme-clientpref-night #mp-middle {
    html.skin-theme-clientpref-os .cs-section.db .cs-section-header,
background-color: #270e1a;
    html.skin-theme-clientpref-os .cs-section.db .cs-card-header { background-color: #882c43 !important; border-color: #882c43 !important; }
border-color: #882c43;
   
}
    html.skin-theme-clientpref-night .cs-section.db .cs-card,
    html.skin-theme-clientpref-night .cs-section.db .cs-card-footer,
html.skin-theme-clientpref-night #mp-middle .mp-h2 {
    html.skin-theme-clientpref-os .cs-section.db .cs-card,
background-color: #882c43;
    html.skin-theme-clientpref-os .cs-section.db .cs-card-footer { background-color: #270e1a !important; border-color: #882c43 !important; }
border-color: #926c80;
   
}
    html.skin-theme-clientpref-night .cs-section.db .cs-card-footer a,
    html.skin-theme-clientpref-os .cs-section.db .cs-card-footer a { color: #ffb6c1 !important; }
html.skin-theme-clientpref-night #mp-lower {
 
background-color: #130e20;
    /* 5. Infrastructure Dark */
border-color: #7545ab;
    html.skin-theme-clientpref-night .cs-section.inf .cs-section-header,
}
    html.skin-theme-clientpref-night .cs-section.inf .cs-card-header,
    html.skin-theme-clientpref-os .cs-section.inf .cs-section-header,
html.skin-theme-clientpref-night #mp-lower .mp-h2 {
    html.skin-theme-clientpref-os .cs-section.inf .cs-card-header { background-color: #7545ab !important; border-color: #7545ab !important; }
background-color: #7545ab;
   
border-color: #afa3bf;
    html.skin-theme-clientpref-night .cs-section.inf .cs-card,
}
    html.skin-theme-clientpref-night .cs-section.inf .cs-card-footer,
    html.skin-theme-clientpref-os .cs-section.inf .cs-card,
html.skin-theme-clientpref-night #mp-bottom {
    html.skin-theme-clientpref-os .cs-section.inf .cs-card-footer { background-color: #130e20 !important; border-color: #7545ab !important; }
/* no background */
   
border-color: #676767;
    html.skin-theme-clientpref-night .cs-section.inf .cs-card-footer a,
}
    html.skin-theme-clientpref-os .cs-section.inf .cs-card-footer a { color: #da70d6 !important; }
 
html.skin-theme-clientpref-night #mp-bottom .mp-h2 {
    /* 6. Fundamentals Dark */
background-color: #3d3d3d;
    html.skin-theme-clientpref-night .cs-section.fund .cs-section-header,
border-color: #676767;
    html.skin-theme-clientpref-night .cs-section.fund .cs-card-header,
}
    html.skin-theme-clientpref-os .cs-section.fund .cs-section-header,
}
    html.skin-theme-clientpref-os .cs-section.fund .cs-card-header { background-color: #663428 !important; border-color: #663428 !important; }
   
    html.skin-theme-clientpref-night .cs-section.fund .cs-card,
    html.skin-theme-clientpref-night .cs-section.fund .cs-card-footer,
    html.skin-theme-clientpref-os .cs-section.fund .cs-card,
    html.skin-theme-clientpref-os .cs-section.fund .cs-card-footer { background-color: #331a00 !important; border-color: #663428 !important; }
   
    html.skin-theme-clientpref-night .cs-section.fund .cs-card-footer a,
    html.skin-theme-clientpref-os .cs-section.fund .cs-card-footer a { color: #ffa500 !important; }


/* OS night mode */
    /* 7. Community Dark */
@media screen and ( prefers-color-scheme: dark ) {
    html.skin-theme-clientpref-night .cs-section.comm .cs-section-header,
html.skin-theme-clientpref-os #mp-topbanner {
    html.skin-theme-clientpref-night .cs-section.comm .cs-card-header,
background-color: #171a1d;
    html.skin-theme-clientpref-os .cs-section.comm .cs-section-header,
border-color: #676767;
    html.skin-theme-clientpref-os .cs-section.comm .cs-card-header { background-color: #3d3d3d !important; border-color: #3d3d3d !important; }
}
   
    html.skin-theme-clientpref-night .cs-section.comm .cs-card,
html.skin-theme-clientpref-os #mp-banner {
    html.skin-theme-clientpref-night .cs-section.comm .cs-card-footer,
background-color: #331a00;
    html.skin-theme-clientpref-os .cs-section.comm .cs-card,
border-color: #663428;
    html.skin-theme-clientpref-os .cs-section.comm .cs-card-footer { background-color: #171a1d !important; border-color: #3d3d3d !important; }
}
   
    html.skin-theme-clientpref-night .cs-section.comm .cs-card-footer a,
html.skin-theme-clientpref-os #mp-left {
    html.skin-theme-clientpref-os .cs-section.comm .cs-card-footer a { color: #ccc !important; }
background-color: #0b1e1c;
border-color: #104437;
}
html.skin-theme-clientpref-os #mp-left .mp-h2 {
background-color: #104437;
border-color: #2f4d41;
}
html.skin-theme-clientpref-os #mp-right {
background-color: #0d1a27;
border-color: #082849;
}
html.skin-theme-clientpref-os #mp-right .mp-h2 {
background-color: #082849;
border-color: #a3b0bf;
}
html.skin-theme-clientpref-os #mp-middle {
background-color: #270e1a;
border-color: #882c43;
}
html.skin-theme-clientpref-os #mp-middle .mp-h2 {
background-color: #882c43;
border-color: #926c80;
}
html.skin-theme-clientpref-os #mp-lower {
background-color: #130e20;
border-color: #7545ab;
}
html.skin-theme-clientpref-os #mp-lower .mp-h2 {
background-color: #7545ab;
border-color: #afa3bf;
}
html.skin-theme-clientpref-os #mp-bottom {
/* no background */
border-color: #676767;
}
html.skin-theme-clientpref-os #mp-bottom .mp-h2 {
background-color: #3d3d3d;
border-color: #676767;
}
}
}

Latest revision as of 23:40, 22 November 2025

/**
 * ComputerScience.wiki - Final Fix
 * 1. Responsive Grid
 * 2. EXACT colors from your original file
 * 3. FIX: Added 'clientpref-os' for automatic dark mode support
 */

/* --- 1. CONTAINER & TYPOGRAPHY --- */
.cs-container {
    max-width: 1200px;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    padding: 0 10px;
}

/* --- 2. HEADER --- */
.cs-header {
    text-align: center;
    padding: 30px 20px;
    margin-bottom: 30px;
    border-radius: 8px;
    background-color: #f9f9f9;
    border: 1px solid #ddd;
}

.cs-title {
    font-size: 2em;
    font-weight: 700;
    margin: 0;
    color: #000;
    border: none;
}

.cs-subtitle {
    font-size: 1.1em;
    font-weight: normal;
    margin: 10px 0 0;
    color: #444;
}

/* --- 3. SEARCH BAR --- */
.cs-search {
    max-width: 800px;
    margin: 0 auto 40px;
    padding: 25px;
    border-radius: 8px;
    background-color: #f5f5f5;
    border: 1px solid #ddd;
}

.cs-search input[type="search"],
.cs-search .mw-searchInput {
    background-color: #ffffff !important;
    border: 1px solid #ddd !important;
    height: 40px !important;
    padding: 5px 12px !important;
    border-radius: 4px !important;
    font-size: 16px !important;
    color: #333 !important;
    width: 100% !important;
}

.cs-search input[type="submit"],
.cs-search .oo-ui-buttonElement-button {
    min-width: 80px !important;
    background-color: #f0f0f0 !important;
    border: 1px solid #ddd !important;
    height: 40px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    color: #333 !important;
}

.cs-search input[name="fulltext"] { display: none !important; }

/* --- 4. GRID LAYOUT --- */
.cs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

/* --- 5. CARDS & SECTIONS (Light Mode Defaults) --- */
.cs-section { margin-bottom: 30px; }
.cs-section-header { padding: 12px 15px; margin-bottom: 20px; border-radius: 6px; }
.cs-section-title { margin: 0; font-size: 1.3em; font-weight: 600; border: none; }

.cs-card {
    border-radius: 6px;
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
    border-width: 1px;
    border-style: solid;
    transition: transform 0.2s;
}

.cs-card:hover { transform: translateY(-3px); }

.cs-card-header { padding: 12px 15px; }
.cs-card-title { margin: 0; font-size: 1.1em; font-weight: 600; border: none; }
.cs-card-body { padding: 15px; flex-grow: 1; }
.cs-card-list { margin: 0; padding: 0 0 0 10px; list-style: none; }
.cs-card-list li { margin-bottom: 8px; }
.cs-card-footer { padding: 8px 15px; text-align: right; font-weight: bold; }
.cs-card-footer a { text-decoration: none; }

/* ========================================================= */
/* === COLOR THEMES (Light Mode) === */
/* ========================================================= */

/* PROGRAMMING (Green) */
.cs-section.prog .cs-section-header { background-color: #cef2e0; border: 1px solid #cef2e0; }
.cs-section.prog .cs-card { background-color: #f5fffa; border-color: #cef2e0; }
.cs-section.prog .cs-card-header { background-color: #cef2e0; border-bottom: 1px solid #cef2e0; }
.cs-section.prog .cs-card-footer { background-color: #f5fffa; border-top: 1px solid #cef2e0; }
.cs-section.prog .cs-card-footer a { color: #2e8b57; }

/* DATA SCIENCE (Blue) */
.cs-section.data .cs-section-header { background-color: #cedff2; border: 1px solid #cedff2; }
.cs-section.data .cs-card { background-color: #f5faff; border-color: #cedff2; }
.cs-section.data .cs-card-header { background-color: #cedff2; border-bottom: 1px solid #cedff2; }
.cs-section.data .cs-card-footer { background-color: #f5faff; border-top: 1px solid #cedff2; }
.cs-section.data .cs-card-footer a { color: #4169e1; }

/* DATABASES (Pink) */
.cs-section.db .cs-section-header { background-color: #f2cedd; border: 1px solid #f2cedd; }
.cs-section.db .cs-card { background-color: #fff5fa; border-color: #f2cedd; }
.cs-section.db .cs-card-header { background-color: #f2cedd; border-bottom: 1px solid #f2cedd; }
.cs-section.db .cs-card-footer { background-color: #fff5fa; border-top: 1px solid #f2cedd; }
.cs-section.db .cs-card-footer a { color: #db7093; }

/* INFRASTRUCTURE (Purple) */
.cs-section.inf .cs-section-header { background-color: #ddcef2; border: 1px solid #ddcef2; }
.cs-section.inf .cs-card { background-color: #faf5ff; border-color: #ddcef2; }
.cs-section.inf .cs-card-header { background-color: #ddcef2; border-bottom: 1px solid #ddcef2; }
.cs-section.inf .cs-card-footer { background-color: #faf5ff; border-top: 1px solid #ddcef2; }
.cs-section.inf .cs-card-footer a { color: #8a2be2; }

/* FUNDAMENTALS (Orange) */
.cs-section.fund .cs-section-header { background-color: #f2e0ce; border: 1px solid #f2e0ce; }
.cs-section.fund .cs-card { background-color: #fffaf5; border-color: #f2e0ce; }
.cs-section.fund .cs-card-header { background-color: #f2e0ce; border-bottom: 1px solid #f2e0ce; }
.cs-section.fund .cs-card-footer { background-color: #fffaf5; border-top: 1px solid #f2e0ce; }
.cs-section.fund .cs-card-footer a { color: #d2691e; }

/* COMMUNITY (Grey) */
.cs-section.comm .cs-section-header { background-color: #eee; border: 1px solid #eee; }
.cs-section.comm .cs-card { background-color: #f9f9f9; border-color: #eee; }
.cs-section.comm .cs-card-header { background-color: #eee; border-bottom: 1px solid #eee; }
.cs-section.comm .cs-card-footer { background-color: #f9f9f9; border-top: 1px solid #eee; }
.cs-section.comm .cs-card-footer a { color: #444; }


/* ========================================================= */
/* === DARK MODE FIX (Citizen Skin) === */
/* ========================================================= */

@media screen {
    /* 1. Global Components - Dark Mode */
    html.skin-theme-clientpref-night .cs-header,
    html.skin-theme-clientpref-os .cs-header { 
        background-color: #171a1d !important; 
        border-color: #676767 !important; 
    }
    html.skin-theme-clientpref-night .cs-title,
    html.skin-theme-clientpref-os .cs-title { color: #fff !important; }
    html.skin-theme-clientpref-night .cs-subtitle,
    html.skin-theme-clientpref-os .cs-subtitle { color: #ccc !important; }
    
    html.skin-theme-clientpref-night .cs-search,
    html.skin-theme-clientpref-os .cs-search { 
        background-color: #252525 !important; 
        border-color: #676767 !important; 
    }
    html.skin-theme-clientpref-night .cs-search input,
    html.skin-theme-clientpref-os .cs-search input { 
        background-color: #1f1f1f !important; 
        color: #fff !important; 
        border-color: #555 !important; 
    }
    html.skin-theme-clientpref-night .cs-search input[type="submit"],
    html.skin-theme-clientpref-os .cs-search input[type="submit"] { 
        background-color: #444 !important; 
        border-color: #555 !important; 
        color: #fff !important; 
    }
    
    html.skin-theme-clientpref-night .cs-section-title,
    html.skin-theme-clientpref-night .cs-card-title,
    html.skin-theme-clientpref-os .cs-section-title,
    html.skin-theme-clientpref-os .cs-card-title { color: #fff !important; }
    
    html.skin-theme-clientpref-night .cs-card-list li,
    html.skin-theme-clientpref-os .cs-card-list li { color: #ccc !important; }

    /* 2. Programming Dark */
    html.skin-theme-clientpref-night .cs-section.prog .cs-section-header,
    html.skin-theme-clientpref-night .cs-section.prog .cs-card-header,
    html.skin-theme-clientpref-os .cs-section.prog .cs-section-header,
    html.skin-theme-clientpref-os .cs-section.prog .cs-card-header { background-color: #104437 !important; border-color: #104437 !important; }
    
    html.skin-theme-clientpref-night .cs-section.prog .cs-card,
    html.skin-theme-clientpref-night .cs-section.prog .cs-card-footer,
    html.skin-theme-clientpref-os .cs-section.prog .cs-card,
    html.skin-theme-clientpref-os .cs-section.prog .cs-card-footer { background-color: #0b1e1c !important; border-color: #104437 !important; }
    
    html.skin-theme-clientpref-night .cs-section.prog .cs-card-footer a,
    html.skin-theme-clientpref-os .cs-section.prog .cs-card-footer a { color: #8fbc8f !important; }

    /* 3. Data Science Dark */
    html.skin-theme-clientpref-night .cs-section.data .cs-section-header,
    html.skin-theme-clientpref-night .cs-section.data .cs-card-header,
    html.skin-theme-clientpref-os .cs-section.data .cs-section-header,
    html.skin-theme-clientpref-os .cs-section.data .cs-card-header { background-color: #082849 !important; border-color: #082849 !important; }
    
    html.skin-theme-clientpref-night .cs-section.data .cs-card,
    html.skin-theme-clientpref-night .cs-section.data .cs-card-footer,
    html.skin-theme-clientpref-os .cs-section.data .cs-card,
    html.skin-theme-clientpref-os .cs-section.data .cs-card-footer { background-color: #0d1a27 !important; border-color: #082849 !important; }
    
    html.skin-theme-clientpref-night .cs-section.data .cs-card-footer a,
    html.skin-theme-clientpref-os .cs-section.data .cs-card-footer a { color: #87cefa !important; }

    /* 4. Databases Dark */
    html.skin-theme-clientpref-night .cs-section.db .cs-section-header,
    html.skin-theme-clientpref-night .cs-section.db .cs-card-header,
    html.skin-theme-clientpref-os .cs-section.db .cs-section-header,
    html.skin-theme-clientpref-os .cs-section.db .cs-card-header { background-color: #882c43 !important; border-color: #882c43 !important; }
    
    html.skin-theme-clientpref-night .cs-section.db .cs-card,
    html.skin-theme-clientpref-night .cs-section.db .cs-card-footer,
    html.skin-theme-clientpref-os .cs-section.db .cs-card,
    html.skin-theme-clientpref-os .cs-section.db .cs-card-footer { background-color: #270e1a !important; border-color: #882c43 !important; }
    
    html.skin-theme-clientpref-night .cs-section.db .cs-card-footer a,
    html.skin-theme-clientpref-os .cs-section.db .cs-card-footer a { color: #ffb6c1 !important; }

    /* 5. Infrastructure Dark */
    html.skin-theme-clientpref-night .cs-section.inf .cs-section-header,
    html.skin-theme-clientpref-night .cs-section.inf .cs-card-header,
    html.skin-theme-clientpref-os .cs-section.inf .cs-section-header,
    html.skin-theme-clientpref-os .cs-section.inf .cs-card-header { background-color: #7545ab !important; border-color: #7545ab !important; }
    
    html.skin-theme-clientpref-night .cs-section.inf .cs-card,
    html.skin-theme-clientpref-night .cs-section.inf .cs-card-footer,
    html.skin-theme-clientpref-os .cs-section.inf .cs-card,
    html.skin-theme-clientpref-os .cs-section.inf .cs-card-footer { background-color: #130e20 !important; border-color: #7545ab !important; }
    
    html.skin-theme-clientpref-night .cs-section.inf .cs-card-footer a,
    html.skin-theme-clientpref-os .cs-section.inf .cs-card-footer a { color: #da70d6 !important; }

    /* 6. Fundamentals Dark */
    html.skin-theme-clientpref-night .cs-section.fund .cs-section-header,
    html.skin-theme-clientpref-night .cs-section.fund .cs-card-header,
    html.skin-theme-clientpref-os .cs-section.fund .cs-section-header,
    html.skin-theme-clientpref-os .cs-section.fund .cs-card-header { background-color: #663428 !important; border-color: #663428 !important; }
    
    html.skin-theme-clientpref-night .cs-section.fund .cs-card,
    html.skin-theme-clientpref-night .cs-section.fund .cs-card-footer,
    html.skin-theme-clientpref-os .cs-section.fund .cs-card,
    html.skin-theme-clientpref-os .cs-section.fund .cs-card-footer { background-color: #331a00 !important; border-color: #663428 !important; }
    
    html.skin-theme-clientpref-night .cs-section.fund .cs-card-footer a,
    html.skin-theme-clientpref-os .cs-section.fund .cs-card-footer a { color: #ffa500 !important; }

    /* 7. Community Dark */
    html.skin-theme-clientpref-night .cs-section.comm .cs-section-header,
    html.skin-theme-clientpref-night .cs-section.comm .cs-card-header,
    html.skin-theme-clientpref-os .cs-section.comm .cs-section-header,
    html.skin-theme-clientpref-os .cs-section.comm .cs-card-header { background-color: #3d3d3d !important; border-color: #3d3d3d !important; }
    
    html.skin-theme-clientpref-night .cs-section.comm .cs-card,
    html.skin-theme-clientpref-night .cs-section.comm .cs-card-footer,
    html.skin-theme-clientpref-os .cs-section.comm .cs-card,
    html.skin-theme-clientpref-os .cs-section.comm .cs-card-footer { background-color: #171a1d !important; border-color: #3d3d3d !important; }
    
    html.skin-theme-clientpref-night .cs-section.comm .cs-card-footer a,
    html.skin-theme-clientpref-os .cs-section.comm .cs-card-footer a { color: #ccc !important; }
}