MediaWiki:Common.css: Difference between revisions
Appearance
No edit summary |
No edit summary |
||
| Line 35: | Line 35: | ||
max-width: 820px; | max-width: 820px; | ||
margin: 0 auto; | margin: 0 auto; | ||
} | |||
/* ── Hide MW default page title (h1#firstHeading) ─────────────── | |||
{{Adhyaya}} template renders the Sanskrit doc/chapter title. | |||
MW's English page-name h1 is redundant. | |||
────────────────────────────────────────────────────────────────*/ | |||
h1.firstHeading, | |||
#firstHeading, | |||
.mw-page-title-main { | |||
display: none !important; | |||
} | } | ||
| Line 42: | Line 52: | ||
.mw-parser-output h3, | .mw-parser-output h3, | ||
.mw-parser-output h4, | .mw-parser-output h4, | ||
.mw-parser-output .mw-heading h1, | .mw-parser-output .mw-heading h1, | ||
.mw-parser-output .mw-heading h2, | .mw-parser-output .mw-heading h2, | ||
.mw-parser-output .mw-heading h3 | .mw-parser-output .mw-heading h3 { | ||
font-family: 'Adishila', 'Noto Serif Devanagari', serif !important; | font-family: 'Adishila', 'Noto Serif Devanagari', serif !important; | ||
border: none !important; | border: none !important; | ||
border-bottom: none !important; | border-bottom: none !important; | ||
padding: 0 !important; | padding: 0 !important; | ||
background: none !important; | background: none !important; | ||
} | } | ||
.mw-parser-output .mw-heading { | .mw-parser-output .mw-heading { | ||
border: none !important; | border: none !important; | ||
| Line 68: | Line 69: | ||
} | } | ||
/* ── | /* ── Chapter heading ({{Adhyaya}} template → h1) ──────────────── | ||
. | Black, large — matches reference site's # प्रथमोऽध्यायः | ||
. | Same style for doc title and chapter titles. | ||
font-size: 1. | ────────────────────────────────────────────────────────────────*/ | ||
.adhyaya-block h1, | |||
.adhyaya-heading { | |||
font-size: 1.6em !important; | |||
font-weight: 500 !important; | font-weight: 500 !important; | ||
color: # | color: #1a1a1a !important; | ||
line-height: | line-height: 1.4; | ||
margin: | margin: 32px 0 8px !important; | ||
padding: 0 !important; | padding: 0 !important; | ||
border: none !important; | border: none !important; | ||
border-bottom: | border-bottom: none !important; | ||
} | } | ||
/* ── Adhikarana heading (=== ===) — | /* ── Adhikarana heading (=== === or h2/h3 inside content) ──────── | ||
Orange dotted — section labels within a chapter | |||
ref site: ## उपोद्घातः style | |||
────────────────────────────────────────────────────────────────*/ | |||
.mw-parser-output .mw-heading2 h2, | |||
.mw-parser-output h2, | |||
.mw-parser-output .mw-heading3 h3, | .mw-parser-output .mw-heading3 h3, | ||
.mw-parser-output h3 { | .mw-parser-output h3 { | ||
| Line 89: | Line 97: | ||
color: #e65100 !important; | color: #e65100 !important; | ||
line-height: 1.6; | line-height: 1.6; | ||
margin: 30px 0 10px !important; | |||
padding: 0 !important; | |||
border: none !important; | border: none !important; | ||
border-bottom: 1px dotted #e65100 !important; | border-bottom: 1px dotted #e65100 !important; | ||
width: | width: 60%; | ||
} | } | ||
/* Hide MW edit pencil icons | /* Hide MW edit pencil icons */ | ||
.mw-heading .mw-editsection { display: none !important; } | .mw-heading .mw-editsection, | ||
.adhyaya-block .mw-editsection { display: none !important; } | |||
/* ── Paragraphs ─────────────────────────────────────────────────*/ | /* ── Paragraphs ─────────────────────────────────────────────────*/ | ||
| Line 111: | Line 121: | ||
} | } | ||
/* ── Shloka block ( | /* ── Shloka block (introductory verses, stotra text) ──────────── | ||
Black — these are the stotra/shloka lines of the text itself, | |||
NOT pramana quotes. ref site: normal black text, no italic. | |||
────────────────────────────────────────────────────────────────*/ | ────────────────────────────────────────────────────────────────*/ | ||
.shloka-block { | .shloka-block { | ||
| Line 123: | Line 133: | ||
.shloka-line { | .shloka-line { | ||
display: block; | display: block; | ||
font-style: | font-style: normal; | ||
color: # | color: #333; | ||
line-height: 1.6; | line-height: 1.6; | ||
} | } | ||
/* ── Verse block (VerseBlock template) | /* ── Verse block (VerseBlock template — scripture verse-text) ──── | ||
Red italic — these are the actual mantra/sutra/shloka lines | |||
being commented on. ref site: .verse-text color #c65, italic. | |||
────────────────────────────────────────────────────────────────*/ | ────────────────────────────────────────────────────────────────*/ | ||
.verse-block { | .verse-block { | ||
| Line 146: | Line 156: | ||
display: block; | display: block; | ||
font-style: italic; | font-style: italic; | ||
color: # | color: #c65; | ||
font-weight: | font-weight: 500; | ||
line-height: 1.6; | line-height: 1.6; | ||
} | } | ||
Revision as of 07:33, 13 April 2026
@font-face {
font-family: "Adishila";
src: url("/resources/fonts/adishila/Adishila.ttf") format("truetype");
font-weight: normal;
font-style: normal;
}
@font-face {
font-family: "Adishila";
src: url("/resources/fonts/adishila/AdishilaBold.ttf") format("truetype");
font-weight: bold;
font-style: normal;
}
/* ── Force Adishila everywhere ──────────────────────────────────
MW sets font-family on html/body, sidebar, etc. We override
everything inside .mw-parser-output and key page elements.
────────────────────────────────────────────────────────────────*/
.mw-parser-output,
.mw-parser-output *,
.mw-parser-output pre,
.mw-parser-output code,
.mw-parser-output tt,
.mw-parser-output kbd {
font-family: 'Adishila', 'Noto Serif Devanagari', serif !important;
}
/* ── Base ────────────────────────────────────────────────────────
font-size NOT !important — ReaderToolbar JS owns it.
────────────────────────────────────────────────────────────────*/
.mw-parser-output {
font-size: 20px;
line-height: 1.75;
color: #555;
max-width: 820px;
margin: 0 auto;
}
/* ── Hide MW default page title (h1#firstHeading) ───────────────
{{Adhyaya}} template renders the Sanskrit doc/chapter title.
MW's English page-name h1 is redundant.
────────────────────────────────────────────────────────────────*/
h1.firstHeading,
#firstHeading,
.mw-page-title-main {
display: none !important;
}
/* ── Headings — reset all MW defaults ───────────────────────────*/
.mw-parser-output h1,
.mw-parser-output h2,
.mw-parser-output h3,
.mw-parser-output h4,
.mw-parser-output .mw-heading h1,
.mw-parser-output .mw-heading h2,
.mw-parser-output .mw-heading h3 {
font-family: 'Adishila', 'Noto Serif Devanagari', serif !important;
border: none !important;
border-bottom: none !important;
padding: 0 !important;
background: none !important;
}
.mw-parser-output .mw-heading {
border: none !important;
border-bottom: none !important;
margin: 0;
padding: 0;
}
/* ── Chapter heading ({{Adhyaya}} template → h1) ────────────────
Black, large — matches reference site's # प्रथमोऽध्यायः
Same style for doc title and chapter titles.
────────────────────────────────────────────────────────────────*/
.adhyaya-block h1,
.adhyaya-heading {
font-size: 1.6em !important;
font-weight: 500 !important;
color: #1a1a1a !important;
line-height: 1.4;
margin: 32px 0 8px !important;
padding: 0 !important;
border: none !important;
border-bottom: none !important;
}
/* ── Adhikarana heading (=== === or h2/h3 inside content) ────────
Orange dotted — section labels within a chapter
ref site: ## उपोद्घातः style
────────────────────────────────────────────────────────────────*/
.mw-parser-output .mw-heading2 h2,
.mw-parser-output h2,
.mw-parser-output .mw-heading3 h3,
.mw-parser-output h3 {
font-size: 1em !important;
font-weight: 500 !important;
color: #e65100 !important;
line-height: 1.6;
margin: 30px 0 10px !important;
padding: 0 !important;
border: none !important;
border-bottom: 1px dotted #e65100 !important;
width: 60%;
}
/* Hide MW edit pencil icons */
.mw-heading .mw-editsection,
.adhyaya-block .mw-editsection { display: none !important; }
/* ── Paragraphs ─────────────────────────────────────────────────*/
.mw-parser-output p { margin: 0 0 0.85rem; }
.mw-parser-output p:empty,
.mw-parser-output > div > p:empty,
.mw-heading + p:empty,
.mw-heading2 + p:empty,
.adhyaya-block + p:empty,
.verse-block + p:empty {
display: none !important;
margin: 0 !important;
}
/* ── Shloka block (introductory verses, stotra text) ────────────
Black — these are the stotra/shloka lines of the text itself,
NOT pramana quotes. ref site: normal black text, no italic.
────────────────────────────────────────────────────────────────*/
.shloka-block {
display: block;
text-align: left;
margin: 10px 0 0;
}
.shloka-line {
display: block;
font-style: normal;
color: #333;
line-height: 1.6;
}
/* ── Verse block (VerseBlock template — scripture verse-text) ────
Red italic — these are the actual mantra/sutra/shloka lines
being commented on. ref site: .verse-text color #c65, italic.
────────────────────────────────────────────────────────────────*/
.verse-block {
display: block;
margin: 10px 0 0;
text-align: left;
}
.verse-block .shloka-block {
text-align: left;
margin: 0;
}
.verse-block .shloka-line {
display: block;
font-style: italic;
color: #c65;
font-weight: 500;
line-height: 1.6;
}
/* Suppress empty p after verse-block */
.verse-block + p { display: none !important; margin: 0 !important; }
/* ── Uvacha block ────────────────────────────────────────────────
Speaker attribution — bold, left orange border, matches
reference site's blockquote style
────────────────────────────────────────────────────────────────*/
.uvacha-block {
display: block;
font-weight: bold;
color: #c65;
margin: 1.2rem 0 0;
padding: 2px 0 2px 12px;
border-left: 3px solid #c65;
text-align: left;
font-style: normal;
}
/* Verse immediately after uvacha — no extra gap */
.uvacha-block + .verse-block {
margin-top: 4px;
}
/* ── Bhashyam: primary commentary, plain running prose ──────────*/
.bhashyam-block {
display: block;
font-size: 1em;
line-height: 1.85;
color: #555;
margin: 0.55em 0 0.8em 60px;
padding: 0;
border: none;
background: transparent;
}
/* ── Teeka: sub-commentary in a titled grey bubble ──────────────*/
.teeka-block {
display: block;
background: #f6f6f7;
border: 1px solid #e2e2e6;
border-radius: 8px;
padding: 10px 14px 12px;
margin: 0.7em 0 0.7em 0;
font-size: 0.93em;
line-height: 1.8;
color: #555;
}
.teeka-title {
font-family: system-ui, -apple-system, sans-serif !important;
font-size: 0.78em;
font-weight: 600;
letter-spacing: 0.06em;
text-transform: uppercase;
color: #777;
margin-bottom: 6px;
padding-bottom: 5px;
border-bottom: 1px solid #ddd;
}
.teeka-body { font-family: inherit; }
/* Shloka verse inside a teeka bubble */
.teeka-block .shloka-block {
margin: 0 0 0.6em;
text-align: left;
}
.teeka-block .shloka-line {
display: block;
font-style: italic;
color: #be100e;
line-height: 1.6;
font-size: 1em;
}
/* ── Adhyaya block ───────────────────────────────────────────────*/
.adhyaya-block {
margin: 0 0 4px;
}
.adhyaya-trans {
font-size: 0.9em;
color: #666;
margin: 2px 0 0;
}
.adhyaya-intro {
margin-top: 10px;
line-height: 1.85;
color: #555;
}
/* ── Nyaya ──────────────────────────────────────────────────────*/
.nyaya-block {
margin: 40px 0;
padding-top: 14px;
border-top: 1px solid #eee;
}
.nyaya-title {
font-size: 1em;
font-weight: 500;
color: #e65100;
margin-bottom: 0.4rem;
border-bottom: 1px dotted #e65100;
width: 50%;
}
.nyaya-title span { display: block; font-size: 0.85em; color: #666; }
.nyaya-body { color: #555; line-height: 1.85; margin-top: 0.5rem; }
/* ── Prasna ─────────────────────────────────────────────────────*/
.prasna-block {
margin: 40px 0;
padding-top: 14px;
border-top: 1px solid #eee;
}
.prasna-title {
font-size: 1em;
font-weight: 500;
color: #e65100;
margin-bottom: 0.4rem;
border-bottom: 1px dotted #e65100;
width: 50%;
}
.prasna-title span { display: block; font-size: 0.85em; color: #666; }
.prasna-question, .prasna-answer { color: #555; line-height: 1.85; margin-top: 0.5rem; }
.prasna-answer { margin-left: 60px; }
/* ── Verse actions ──────────────────────────────────────────────*/
.verse-actions {
display: flex;
flex-direction: row;
align-items: center;
gap: 6px;
margin-top: 6px;
padding-left: 2px;
justify-content: center;
}
.verse-action-btn {
display: inline-flex;
align-items: center;
justify-content: center;
padding: 4px;
border-radius: 6px;
cursor: pointer;
opacity: 0.75;
transition: all 0.2s ease;
}
.verse-action-btn:hover { opacity: 1; background-color: rgba(0,0,0,0.05); }
/* ── Icons ──────────────────────────────────────────────────────*/
.icon {
display: inline-block;
width: 18px; height: 18px;
background-repeat: no-repeat;
background-position: center;
background-size: contain;
transform: translateY(2px);
pointer-events: none;
}
.icon-copy { background-image: url('/images/copy.svg'); }
.icon-commentary { background-image: url('/images/commentary.svg'); }
/* ── Copy tooltip ───────────────────────────────────────────────*/
.copy-tooltip {
position: absolute;
bottom: calc(100% + 8px);
left: 50%;
transform: translateX(-50%) translateY(4px);
white-space: nowrap;
pointer-events: none;
z-index: 9999;
display: inline-flex;
align-items: center;
padding: 2px 8px;
border-radius: 999px;
font-size: 0.75rem;
font-weight: 500;
background: rgba(30,30,30,0.82);
color: #fff;
backdrop-filter: blur(6px);
opacity: 0;
transition: opacity 0.2s ease, transform 0.2s ease;
}
.copy-tooltip.copy-tooltip-visible {
opacity: 1;
transform: translateX(-50%) translateY(0);
}
/* ── Code blocks ────────────────────────────────────────────────*/
pre, code, .mw-code, tt, kbd {
font-family: 'Adishila', 'Noto Serif Devanagari', serif !important;
background-color: transparent !important;
border: none !important;
padding: 0.3em 0 !important;
line-height: 1.75;
}
/* ── mw-collapsible resets ──────────────────────────────────────*/
.mw-collapsible,
.mw-collapsible-content,
blockquote,
.quotebox {
background-color: transparent !important;
border: none !important;
font-style: normal !important;
padding: 0 !important;
margin-left: 0 !important;
}
/* ── Cargo store hidden ─────────────────────────────────────────*/
.cargo-store-only { display: none !important; }
/* ── Floating chapter nav (right side on doc root page) ─────────
Lists all adhyayas as links, floats right like reference site
────────────────────────────────────────────────────────────────*/
.gr-chapter-nav {
float: right;
clear: right;
margin: 0 0 1.5em 1.5em;
padding: 10px 14px 12px;
background: #f9f9f9;
border: 1px solid #e2e2e6;
border-radius: 8px;
min-width: 160px;
max-width: 220px;
font-size: 0.82em;
line-height: 1.9;
}
.gr-chapter-nav-title {
font-family: system-ui, -apple-system, sans-serif !important;
font-size: 0.78em;
font-weight: 600;
text-transform: uppercase;
letter-spacing: 0.06em;
color: #888;
border-bottom: 1px solid #ddd;
margin-bottom: 6px;
padding-bottom: 4px;
}
.gr-chapter-nav ul { list-style: none; margin: 0; padding: 0; }
.gr-chapter-nav li { margin: 0; padding: 0; }
.gr-chapter-nav a { color: #1a2e40; text-decoration: none; display: block; }
.gr-chapter-nav a:hover { color: #f57c00; }
.gr-doc-teekas { margin-bottom: 1em; }
@media (max-width: 720px) {
.gr-chapter-nav { float: none; margin: 0 0 1em; max-width: 100%; }
}
/* ── Main page (gr-home) ─────────────────────────────────────────*/
.gr-home {
max-width: 820px;
margin: 0 auto;
padding: 0;
}
.gr-home-group { margin-bottom: 32px; }
.gr-home-group-title {
font-family: 'Adishila', 'Noto Serif Devanagari', serif !important;
font-size: 1em !important;
font-weight: 700;
color: #1a2e40;
border: none !important;
border-bottom: 2px solid #1a2e40 !important;
width: 100%;
padding-bottom: 4px;
margin: 0 0 12px !important;
line-height: 1.75;
}
.gr-home-section { margin-bottom: 16px; }
.gr-home-section-title {
font-family: system-ui, -apple-system, sans-serif !important;
font-size: 0.78em;
font-weight: 600;
text-transform: uppercase;
letter-spacing: 0.07em;
color: #e65100;
margin-bottom: 6px;
}
.gr-home-list {
list-style: decimal;
margin: 0 0 0 1.4em;
padding: 0;
}
.gr-home-list li { font-size: 1em; line-height: 1.9; color: #333; }
.gr-home-list li a { color: #1a2e40; text-decoration: none; }
.gr-home-list li a:hover { color: #f57c00; }
.gr-home-list li a.new { color: #aaa; }
.gr-home-note { font-size: 0.85em; color: #888; }
/* ── Modals ─────────────────────────────────────────────────────*/
.grantha-new-btn {
background: rgba(255,255,255,0.1);
border: 1px solid rgba(255,255,255,0.3);
color: white;
padding: 6px 14px;
border-radius: 20px;
cursor: pointer;
margin-right: 10px;
}
.grantha-modal {
position: fixed; inset: 0;
background: rgba(0,0,0,0.35);
display: flex; align-items: center; justify-content: center;
z-index: 10000;
}
.grantha-modal-box {
background: white; padding: 20px;
border-radius: 10px; width: 300px;
}
.gm-title { font-weight: bold; margin-bottom: 10px; }
.gm-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 12px; }
/* ── Main page sidebar hide ─────────────────────────────────────*/
body.page-Main_Page #mw-panel,
body.page-Main_Page .vector-sidebar-container { display: none !important; }
body.page-Main_Page #footer { display: none !important; }
/* ── Responsive ─────────────────────────────────────────────────*/
@media (max-width: 600px) {
.mw-parser-output { font-size: 16px; }
.mw-parser-output h2,
.mw-parser-output .mw-heading2 h2 { width: 100% !important; }
.mw-parser-output h3,
.mw-parser-output .mw-heading3 h3 { width: 100% !important; }
.nyaya-title, .prasna-title { width: 100%; }
.bhashyam-block, .teeka-block { margin-left: 10px; }
}
/* ════════════════════════════════════════════════════════════════
VECTOR 2022 HEADER
════════════════════════════════════════════════════════════════*/
.vector-header-container {
background: #1a2e40 !important;
border-bottom: 1px solid rgba(255,255,255,0.08);
}
.vector-header {
background: transparent !important;
max-width: 100% !important;
display: flex !important;
align-items: center !important;
justify-content: space-between !important;
padding-left: 20px !important;
padding-right: 20px !important;
}
.vector-header-start {
flex: 0 0 auto !important;
display: flex !important;
align-items: center !important;
gap: 12px;
}
.vector-header-end {
flex: 0 0 auto !important;
display: flex !important;
align-items: center !important;
gap: 16px;
margin-left: auto;
}
.mw-logo { display: flex !important; align-items: center; opacity: 1 !important; }
.mw-logo-wordmark { color: #ffffff !important; font-weight: 700; font-size: 18px; }
.mw-logo-icon { content: url('/favicon.ico'); width: 24px; height: 24px; }
.vector-header .vector-icon { filter: invert(1); opacity: 0.9; }
.cdx-search-input .vector-icon,
.cdx-search-input svg,
.cdx-search-input path,
.cdx-search-input__end-button .vector-icon,
.cdx-search-input__end-button svg,
.cdx-search-input__end-button path {
filter: none !important; fill: #202124 !important; opacity: 1 !important;
}
.vector-header-end > *:not(#p-search) { color: rgba(255,255,255,0.9) !important; }
.vector-user-links a { color: rgba(255,255,255,0.9) !important; }
/* ── Search ─────────────────────────────────────────────────────*/
#p-search { margin-left: 8px; }
.vector-search-box,
.vector-search-box-expanded,
.vector-search-box-auto-expand-width {
min-width: 0 !important; flex-grow: 0 !important;
position: relative !important; margin: 0 !important;
}
.cdx-search-input__input,
.cdx-text-input__input {
background: #ffffff !important;
border: none !important;
border-radius: 8px !important;
color: #202124 !important;
padding: 6px 10px !important;
font-family: system-ui, sans-serif !important;
}
.cdx-search-input__input::placeholder,
.cdx-text-input__input::placeholder {
color: rgba(32,33,36,0.5) !important;
}
.cdx-search-input__end-button { background: transparent !important; border: none !important; }
.cdx-typeahead-search,
.cdx-typeahead-search__menu,
.cdx-menu {
background: #ffffff !important; color: #202124 !important;
border-radius: 10px !important;
box-shadow: 0 6px 24px rgba(0,0,0,0.2) !important;
filter: none !important;
}
.cdx-menu-item, .cdx-menu-item * { color: #202124 !important; filter: none !important; }
.cdx-menu-item:hover,
.cdx-menu-item--active,
.cdx-menu-item--selected { background: #f1f3f4 !important; }
.cdx-menu-item__icon,
.cdx-menu-item__icon svg,
.cdx-menu-item__icon path { fill: #202124 !important; filter: none !important; }