MediaWiki:Common.css: Difference between revisions

From AbhiprayaVedi
No edit summary
No edit summary
Line 1: Line 1:
/* ================================================================
/* ================================================================
   AbhiprayaVedi - Ver4.1 — Timeless Skin, Gap Fix
   LANGUAGE-AWARE TYPOGRAPHY & COLOR VARIABLES
   ================================================================ */
   ================================================================ */


/* Reduce gap between tab bar and article content */
/* English articles */
#firstHeading {
.mw-body[lang="en"],
    margin-bottom: 4px;
.article-container[lang="en"],
    padding-bottom: 2px;
.right-sidebar[lang="en"],
#mw-content-text[lang="en"],
#mw-navigation[lang="en"],
.form-container[lang="en"] {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.6;
  --color-primary: #212529;
  --color-secondary: #667eea;
  --color-accent: #17a2b8;
  --color-neutral: #f8f9fa;
}
}


#mw-content-text,
/* Malayalam articles */
.mw-body-content,
.mw-body[lang="ml"],
.mw-parser-output,
.article-container[lang="ml"],
.page-content {
.right-sidebar[lang="ml"],
    padding-top: 0;
#mw-content-text[lang="ml"],
    margin-top: 0;
#mw-navigation[lang="ml"],
.form-container[lang="ml"] {
  font-family: 'Manjari','Meera','Rachana','AnjaliOldLipi','Noto Sans Malayalam',sans-serif;
  line-height: 1.75;
  --color-primary: #4a2f87;
  --color-secondary: #f59e0b;
  --color-accent: #78350f;
  --color-neutral: #f8f9fa;
}
}


/* ================================================================
/* ================================================================
   BASE FONT SIZE
   ARTICLE HEADER
   ================================================================ */
   ================================================================ */
body {
.article-container .article-header {
    font-size: 17px;
  background: var(--color-neutral);
  border-bottom: 2px solid var(--color-primary);
  padding: 6px 16px;
  margin: 0 0 10px 0;
  border-radius: 6px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 15px;
}
}
.mw-body {
 
    font-size: 1.05em;
.article-container .author-name {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--color-primary);
  line-height: 1.4;
  margin: 0;
}
}


/* ================================================================
.article-container .date-info {
  ARTICLE CONTAINER
  font-size: 1rem;
  ================================================================ */
  color: #6c757d;
.article-container {
  text-align: center;
    max-width: 1200px;
  line-height: 1.4;
    margin: 0 auto;
  margin: 0;
    padding: 0 20px 20px 20px; /* top padding 0 */
  flex: 1 1 auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 1.05em;
}
}
.article-container[data-language="Malayalam"] {
 
    font-family: 'Manjari','Meera','Rachana','AnjaliOldLipi','Noto Sans Malayalam',sans-serif;
.article-container .category-badge {
    line-height: 1.75;
  font-size: 0.9rem;
  font-weight: 600;
  background: var(--color-secondary);
  color: #fff;
  padding: 5px 12px;
  border-radius: 20px;
  line-height: 1.4;
  margin: 0;
}
}


/* ================================================================
@media (max-width: 768px) {
  HEADER
  .article-container .article-header {
  ================================================================ */
     flex-direction: column;
.article-container .article-header {
     align-items: flex-start;
     background: #f8f9fa;
     gap: 10px;
    border-bottom: 2px solid #495057;
  }
    padding: 2px 16px;
  .article-container .date-info { text-align: left; }
    margin-top: 0;
  .article-container .category-badge { align-self: flex-start; }
    margin-bottom: 10px;
    border-radius: 6px;
}
.article-container .author-info {
    display: flex;
     align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
     gap: 15px;
    padding: 0;
    margin: 0;
    width: 100%;
}
.article-container .author-info > * {
    flex: 0 0 auto;
    width: auto;
    float: none;
}
.article-container .author-info .date-info {
    flex: 1 1 auto;
    text-align: center;
}
}


/* ================================================================
/* ================================================================
   INTRODUCTION
   FIRST HEADING (Article Title)
   ================================================================ */
   ================================================================ */
.article-container .introduction-section {
.mw-body h1.firstHeading {
    background: linear-gradient(135deg, #fff9e6 0%, #fff3cd 100%);
  font-weight: 700;
    border-left: 5px solid #f59e0b;
  line-height: 1.3;
    padding: 2px 16px;
  margin: 0.4em 0;
    margin-top: 0;
  color: var(--color-primary);
    margin-bottom: 10px;
    border-radius: 6px;
    font-size: 1.12em;
    line-height: 1.65;
    color: #78350f;
    font-weight: 500;
}
}


/* ================================================================
/* ================================================================
   CONTENT LAYOUT
   SIDEBAR & CATEGORY LISTINGS
   ================================================================ */
   ================================================================ */
.content-wrapper {
.right-sidebar,
    display: flex;
.right-sidebar .mw-category,
    gap: 30px;
.right-sidebar .mw-list-item {
    margin-bottom: 30px;
  font-size: 0.95rem;
}
  line-height: 1.5;
.main-content { flex: 1 1 70%; min-width: 0; }
  color: var(--color-primary);
.right-sidebar { flex: 0 0 300px; }
@media (max-width: 968px) {
    .content-wrapper { flex-direction: column; }
    .right-sidebar { flex: 1 1 auto; max-width: 100%; }
}
}


/* ================================================================
/* ================================================================
   ARTICLE TEXT
   NAVIGATION TABS
   ================================================================ */
   ================================================================ */
.article-text {
#mw-navigation .tab {
    font-size: 1.15em;
  font-size: 0.95rem;
    line-height: 1.85;
  font-weight: 600;
    color: #212529;
  padding: 6px 12px;
    text-align: left;
  border-radius: 4px;
  background: var(--color-neutral);
  color: var(--color-primary);
}
}
.article-text p { margin-bottom: 1.2em; }
 
.article-text h2 {
#mw-navigation .tab.active {
    font-size: 1.6em;
  background: var(--color-secondary);
    margin: 1.5em 0 0.8em;
  color: #fff;
    color: #212529;
    border-bottom: 2px solid #dee2e6;
    padding-bottom: 0.3em;
}
}
.article-text h3 {
 
    font-size: 1.3em;
#mw-navigation .tab:hover {
    margin: 1.3em 0 0.7em;
  background: var(--color-accent);
    color: #495057;
  color: #fff;
}
}


/* ================================================================
/* ================================================================
   AUTHOR INFOBOX
   FORM USABILITY (Form:Article, Submit:Article)
   ================================================================ */
   ================================================================ */
.author-infobox {
.form-container {
    background: #f8f9fa;
  max-width: 900px;
    border: 1px solid #ced4da;
  margin: 0 auto;
    border-radius: 8px;
  padding: 20px;
    margin-bottom: 20px;
    overflow: hidden;
}
}
.author-photo { text-align: center; padding: 12px; background: white; border-bottom: 1px solid #dee2e6; }
 
.author-photo img { max-width: 100%; height: auto; border-radius: 6px; }
.form-header {
.author-name-box {
  background: var(--color-primary);
    text-align: center;
  color: #fff;
    padding: 10px 15px;
  padding: 25px;
    font-size: 1.3rem;
  border-radius: 8px;
    font-weight: 700;
  margin-bottom: 25px;
    color: #212529;
  text-align: center;
    background: #e9ecef;
    border-bottom: 1px solid #dee2e6;
}
}
.author-name-box a { color: #0056b3; text-decoration: none; }
.author-name-box a:hover { text-decoration: underline; }
.author-bio { padding: 12px 15px; font-size: 1em; line-height: 1.65; color: #495057; }


/* ================================================================
.form-section {
  RESPONSIVE
  background: #fff;
  ================================================================ */
  padding: 25px;
@media (max-width: 768px) {
  border-radius: 8px;
    .article-container .author-info {
  margin-bottom: 20px;
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    .article-container .author-info .date-info { text-align: left; }
    .article-container .author-info .category-badge { align-self: flex-start; }
}
}


.form-required {
  border-left: 5px solid #dc3545; /* red for required */
}


/* ================================================================
.form-optional {
  DEBUG OUTLINES — temporary visual aid
  border-left: 5px solid #28a745; /* green for optional */
  ================================================================ */
}


.article-container {
.form-table {
    outline: 2px dashed red;       /* main container */
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 12px;
}
}


.article-header {
.form-label {
    outline: 2px dashed blue;     /* header box */
  width: 180px;
  text-align: right;
  padding: 10px 15px 10px 0;
  vertical-align: top;
}
}


.author-info {
.form-field {
    outline: 2px dashed green;     /* author info flex container */
  padding: 10px 0;
}
}


.author-info > * {
.form-hint {
    outline: 1px solid orange;     /* each child inside author-info */
  color: #666;
  font-size: 0.85rem;
  margin-top: 4px;
  display: block;
}
}


.introduction-section {
/* Tightened rhythm for inputs */
    outline: 2px dashed purple;   /* intro section */
.mw-htmlform-field label,
.mw-htmlform-field input,
.mw-htmlform-field textarea,
.mw-htmlform-field select {
  line-height: 1.3;
  font-size: 1rem;
}
}


.content-wrapper {
/* Submission controls */
    outline: 2px dashed brown;     /* main content wrapper */
.form-controls {
  text-align: center;
  padding: 25px;
  background: var(--color-neutral);
  border-radius: 8px;
}
}


.right-sidebar {
.form-controls p {
    outline: 2px dashed teal;     /* sidebar */
  margin-bottom: 15px;
  color: #666;
}
}

Revision as of 04:27, 10 April 2026

/* ================================================================
   LANGUAGE-AWARE TYPOGRAPHY & COLOR VARIABLES
   ================================================================ */

/* English articles */
.mw-body[lang="en"],
.article-container[lang="en"],
.right-sidebar[lang="en"],
#mw-content-text[lang="en"],
#mw-navigation[lang="en"],
.form-container[lang="en"] {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.6;
  --color-primary: #212529;
  --color-secondary: #667eea;
  --color-accent: #17a2b8;
  --color-neutral: #f8f9fa;
}

/* Malayalam articles */
.mw-body[lang="ml"],
.article-container[lang="ml"],
.right-sidebar[lang="ml"],
#mw-content-text[lang="ml"],
#mw-navigation[lang="ml"],
.form-container[lang="ml"] {
  font-family: 'Manjari','Meera','Rachana','AnjaliOldLipi','Noto Sans Malayalam',sans-serif;
  line-height: 1.75;
  --color-primary: #4a2f87;
  --color-secondary: #f59e0b;
  --color-accent: #78350f;
  --color-neutral: #f8f9fa;
}

/* ================================================================
   ARTICLE HEADER
   ================================================================ */
.article-container .article-header {
  background: var(--color-neutral);
  border-bottom: 2px solid var(--color-primary);
  padding: 6px 16px;
  margin: 0 0 10px 0;
  border-radius: 6px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 15px;
}

.article-container .author-name {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--color-primary);
  line-height: 1.4;
  margin: 0;
}

.article-container .date-info {
  font-size: 1rem;
  color: #6c757d;
  text-align: center;
  line-height: 1.4;
  margin: 0;
  flex: 1 1 auto;
}

.article-container .category-badge {
  font-size: 0.9rem;
  font-weight: 600;
  background: var(--color-secondary);
  color: #fff;
  padding: 5px 12px;
  border-radius: 20px;
  line-height: 1.4;
  margin: 0;
}

@media (max-width: 768px) {
  .article-container .article-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  .article-container .date-info { text-align: left; }
  .article-container .category-badge { align-self: flex-start; }
}

/* ================================================================
   FIRST HEADING (Article Title)
   ================================================================ */
.mw-body h1.firstHeading {
  font-weight: 700;
  line-height: 1.3;
  margin: 0.4em 0;
  color: var(--color-primary);
}

/* ================================================================
   SIDEBAR & CATEGORY LISTINGS
   ================================================================ */
.right-sidebar,
.right-sidebar .mw-category,
.right-sidebar .mw-list-item {
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--color-primary);
}

/* ================================================================
   NAVIGATION TABS
   ================================================================ */
#mw-navigation .tab {
  font-size: 0.95rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 4px;
  background: var(--color-neutral);
  color: var(--color-primary);
}

#mw-navigation .tab.active {
  background: var(--color-secondary);
  color: #fff;
}

#mw-navigation .tab:hover {
  background: var(--color-accent);
  color: #fff;
}

/* ================================================================
   FORM USABILITY (Form:Article, Submit:Article)
   ================================================================ */
.form-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 20px;
}

.form-header {
  background: var(--color-primary);
  color: #fff;
  padding: 25px;
  border-radius: 8px;
  margin-bottom: 25px;
  text-align: center;
}

.form-section {
  background: #fff;
  padding: 25px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.form-required {
  border-left: 5px solid #dc3545; /* red for required */
}

.form-optional {
  border-left: 5px solid #28a745; /* green for optional */
}

.form-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 12px;
}

.form-label {
  width: 180px;
  text-align: right;
  padding: 10px 15px 10px 0;
  vertical-align: top;
}

.form-field {
  padding: 10px 0;
}

.form-hint {
  color: #666;
  font-size: 0.85rem;
  margin-top: 4px;
  display: block;
}

/* Tightened rhythm for inputs */
.mw-htmlform-field label,
.mw-htmlform-field input,
.mw-htmlform-field textarea,
.mw-htmlform-field select {
  line-height: 1.3;
  font-size: 1rem;
}

/* Submission controls */
.form-controls {
  text-align: center;
  padding: 25px;
  background: var(--color-neutral);
  border-radius: 8px;
}

.form-controls p {
  margin-bottom: 15px;
  color: #666;
}