/* Wikiqedia — replica of MediaWiki's Vector 2022 (desktop) and Minerva (mobile) skins. */

/* ---------- Design tokens (Codex) ---------- */
:root {
  --bg-page: #f8f9fa;
  --bg: #fff;
  --bg-subtle: #f8f9fa;
  --bg-interactive: #eaecf0;
  --bg-interactive-hover: #dadde3;
  --bg-infobox-header: #ededed;
  --text: #202122;
  --text-emphasized: #101418;
  --text-subtle: #54595d;
  --text-placeholder: #72777d;
  --icon: #404244;
  --link: #3366cc;
  --link-hover: #3056a9;
  --link-visited: #6a60b0;
  --link-new: #d73333;
  --link-new-visited: #a55858;
  --border: #a2a9b1;
  --border-subtle: #c8ccd1;
  --border-muted: #dadde3;
  --border-light: #eaecf0;
  --border-input: #72777d;
  --progressive: #36c;
  --shadow: rgba(0, 0, 0, 0.2);
  --mobile-header: #eaecf0;
  --target: rgba(0, 127, 255, 0.133);
  --font-sans: sans-serif;
  --font-mobile: -apple-system, 'BlinkMacSystemFont', 'Segoe UI', 'Roboto', 'Inter', 'Helvetica', 'Arial', sans-serif;
  --font-serif: 'Linux Libertine', 'Georgia', 'Times', 'Source Serif 4', serif;
  --font-size-body: 16px;
  color-scheme: light;
}

html.wq-theme-dark {
  --bg-page: #101418;
  --bg: #101418;
  --bg-subtle: #202122;
  --bg-interactive: #27292d;
  --bg-interactive-hover: #404244;
  --bg-infobox-header: #27292d;
  --text: #eaecf0;
  --text-emphasized: #f8f9fa;
  --text-subtle: #a2a9b1;
  --text-placeholder: #a2a9b1;
  --icon: #c8ccd1;
  --link: #88a3e8;
  --link-hover: #a6bbf5;
  --link-visited: #a799cd;
  --link-new: #fd7865;
  --link-new-visited: #ef9a8b;
  --border: #72777d;
  --border-subtle: #54595d;
  --border-muted: #404244;
  --border-light: #27292d;
  --border-input: #a2a9b1;
  --progressive: #6485d1;
  --shadow: rgba(0, 0, 0, 0.6);
  --mobile-header: #27292d;
  --target: rgba(100, 133, 209, 0.25);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  html.wq-theme-os {
    --bg-page: #101418; --bg: #101418; --bg-subtle: #202122; --bg-interactive: #27292d; --bg-interactive-hover: #404244;
    --bg-infobox-header: #27292d; --text: #eaecf0; --text-emphasized: #f8f9fa; --text-subtle: #a2a9b1; --text-placeholder: #a2a9b1;
    --icon: #c8ccd1; --link: #88a3e8; --link-hover: #a6bbf5; --link-visited: #a799cd; --link-new: #fd7865; --link-new-visited: #ef9a8b;
    --border: #72777d; --border-subtle: #54595d; --border-muted: #404244; --border-light: #27292d; --border-input: #a2a9b1;
    --progressive: #6485d1; --shadow: rgba(0, 0, 0, 0.6); --mobile-header: #27292d; --target: rgba(100, 133, 209, 0.25);
    color-scheme: dark;
  }
}
html.wq-theme-dark .mw-parser-output img, html.wq-theme-dark .mw-logo-icon { filter: brightness(0.92); }
html.wq-theme-dark .mw-logo-icon { filter: invert(1) hue-rotate(180deg) brightness(1.1); }
@media (prefers-color-scheme: dark) { html.wq-theme-os .mw-logo-icon { filter: invert(1) hue-rotate(180deg) brightness(1.1); } }

html.wq-font-small { --font-size-body: 14px; }
html.wq-font-large { --font-size-body: 20px; }

/* ---------- Base ---------- */
html { font-size: 100%; scroll-padding-top: 60px; }
html, body { height: 100%; }
body {
  margin: 0;
  background-color: var(--bg-page);
  color: var(--text);
  font-family: var(--font-sans);
  -webkit-text-size-adjust: 100%;
}
a { color: var(--link); text-decoration: none; }
a:visited { color: var(--link-visited); }
a:hover { text-decoration: underline; }
a:active { color: #233566; }
a.new, a.new:visited { color: var(--link-new); }
a.new:visited { color: var(--link-new-visited); }
img { border: 0; vertical-align: middle; }
button { font-family: inherit; }
:target { scroll-margin-top: 60px; }
.wq-visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mw-jump-link { position: absolute; left: -9999px; }
.mw-jump-link:focus { left: 8px; top: 8px; z-index: 10; background: var(--bg); padding: 4px; }
html:not(.wq-mobile) .minerva-only { display: none !important; }
html.wq-mobile .vector-only { display: none !important; }

/* ---------- Icons (Codex, MIT) ---------- */
.vector-icon {
  display: inline-block;
  width: 20px; height: 20px; min-width: 20px; min-height: 20px;
  vertical-align: middle;
  background-color: var(--icon);
  -webkit-mask-size: contain; mask-size: contain;
  -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
  -webkit-mask-position: center; mask-position: center;
  flex-shrink: 0;
}
.vector-icon.wq-progressive { background-color: var(--link); }
.vector-icon.wq-small { width: 12px; height: 12px; min-width: 12px; min-height: 12px; }
.wq-icon-menu { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M1 3h18v2H1zm0 6h18v2H1zm0 6h18v2H1z'/%3E%3C/svg%3E"); }
.wq-icon-search { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M8 1a7 7 0 0 1 5.605 11.191l5.102 5.102-1.414 1.414-5.102-5.102A7 7 0 1 1 8 1m0 2a5 5 0 1 0 0 10A5 5 0 0 0 8 3'/%3E%3C/svg%3E"); }
.wq-icon-language { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m17.835 19-1.248-3h-4.174l-1.248 3.001H9l4.577-11.005h1.846L20 19zm-4.59-5h2.51L14.5 10.982zM7.618 3H12v2H9.991a8.5 8.5 0 0 1-1.423 4.02q-.24.358-.528.707.634.367 1.379.711l.908.42-.839 1.816-.907-.42a18 18 0 0 1-2.026-1.09c-1.255.979-2.912 1.8-5.076 2.31l-.973.228-.458-1.946.973-.23c1.631-.383 2.885-.954 3.85-1.608C3.29 8.527 2.317 6.884 2.065 5H0V3h5.382l-.724-1.447 1.79-.895L7.617 3ZM4.094 5c.243 1.282.974 2.489 2.29 3.586A6.54 6.54 0 0 0 7.98 5z'/%3E%3C/svg%3E"); }
.wq-icon-verticalEllipsis { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M11.5 19h-3v-3h3zm0-7.5h-3v-3h3zm0-7.5h-3V1h3z'/%3E%3C/svg%3E"); }
.wq-icon-ellipsis { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M4 11.5H1v-3h3zm7.5 0h-3v-3h3zm7.5 0h-3v-3h3z'/%3E%3C/svg%3E"); }
.wq-icon-listBullet { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M1 3h2v2H1zm0 6h2v2H1zm0 6h2v2H1zM5 3h14v2H5zm0 6h14v2H5zm0 6h14v2H5z'/%3E%3C/svg%3E"); }
.wq-icon-userAvatar { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M12 11a6 6 0 0 1 6 6v2H2v-2a6 6 0 0 1 6-6z'/%3E%3Ccircle cx='10' cy='5' r='4'/%3E%3C/svg%3E"); }
.wq-icon-userAvatarOutline { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M12 11a6 6 0 0 1 6 6v2H2v-2a6 6 0 0 1 6-6zm-4 2a4 4 0 0 0-4 4h12a4 4 0 0 0-4-4zm2-12a4 4 0 1 1 0 8 4 4 0 0 1 0-8m0 2a2 2 0 1 0 0 4 2 2 0 0 0 0-4'/%3E%3C/svg%3E"); }
.wq-icon-expand { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m16.7 8-6 6H9.3l-6-6 1.4-1.4 5.3 5.3 5.3-5.3z'/%3E%3C/svg%3E"); }
.wq-icon-appearance { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M8.87 16A4 4 0 0 1 1 15V4a3 3 0 0 1 6 0v2H5V4a1 1 0 0 0-2 0v7.5A4 4 0 0 1 8.9 14h2.2a4 4 0 0 1 5.9-2.5V4a1 1 0 1 0-2 0v2h-2V4a3 3 0 0 1 6 0v11a4 4 0 0 1-7.870 1zM5 13a2 2 0 1 0 0 4 2 2 0 0 0 0-4m10 0a2 2 0 1 0 0 4 2 2 0 0 0 0-4'/%3E%3C/svg%3E"); }
.wq-icon-heart { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M11.039 3.656c2.158-2.332 5.937-2.179 7.893.318a4.99 4.99 0 0 1-.272 6.487L10.757 19H9.243L1.34 10.461a4.99 4.99 0 0 1-.272-6.487c1.956-2.497 5.735-2.65 7.893-.318L10 4.776z'/%3E%3C/svg%3E"); }
.wq-icon-logIn { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M19 19H5v-2h12V3H5V1h14z'/%3E%3Cpath d='M14.018 9.293v1.414L9.31 15.414 7.896 14l3-3H1V9h9.896l-3-3L9.31 4.586z'/%3E%3C/svg%3E"); }
.wq-icon-home { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m19.707 10.293-1.414 1.414L17 10.414V20H3v-9.586l-1.293 1.293-1.414-1.414L10 .586zM5 8.414V18h3v-5h4v5h3V8.414l-5-5z'/%3E%3C/svg%3E"); }
.wq-icon-die { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M19 19H1V1h18zM3 17h14V3H3z'/%3E%3Ccircle cx='6.5' cy='6.5' r='1.5'/%3E%3Ccircle cx='13.5' cy='6.5' r='1.5'/%3E%3Ccircle cx='10' cy='10' r='1.5'/%3E%3Ccircle cx='6.5' cy='13.5' r='1.5'/%3E%3Ccircle cx='13.5' cy='13.5' r='1.5'/%3E%3C/svg%3E"); }
.wq-icon-mapPin { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M9.15 19.07h1.7l5.5-8a7.16 7.2 0 1 0-12.7 0zM10 16.8l-4.1-6a5.16 5.14 0 1 1 8.2 0z'/%3E%3Ccircle cx='10' cy='8' r='2'/%3E%3C/svg%3E"); }
.wq-icon-settings { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M11.835 3.505a6.7 6.7 0 0 1 1.46.603l2.362-1.18 1.414 1.415-1.18 2.361a6.7 6.7 0 0 1 .603 1.46L19 9v2l-2.506.835a6.7 6.7 0 0 1-.603 1.46l1.18 2.362-1.414 1.414-2.362-1.18a6.7 6.7 0 0 1-1.46.603L11 19H9l-.836-2.506a6.7 6.7 0 0 1-1.46-.603l-2.361 1.18-1.414-1.414 1.18-2.362a6.7 6.7 0 0 1-.604-1.46L1 11V9l2.505-.836a6.7 6.7 0 0 1 .603-1.46l-1.18-2.361 1.415-1.414 2.361 1.18a6.7 6.7 0 0 1 1.46-.604L9 1h2zM10 7a3 3 0 1 0 0 6 3 3 0 0 0 0-6'/%3E%3C/svg%3E"); }
.wq-icon-bookmarkOutline { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M17 19h-2l-5-5-5 5H3V1h14zM5 16l5-5 5 5V3H5z'/%3E%3C/svg%3E"); }
.wq-icon-edit { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m15.4.4 4.2 4.2-3.2 3.2-4.2-4.2zM10.8 5 15 9.2l-8.6 8.6-4.5 1.5-1.2-1.2 1.5-4.5z'/%3E%3C/svg%3E"); }
.wq-icon-download { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M19 19H1v-2h18zm-8-7.104 3.5-3.5 1.414 1.414-5.207 5.208H9.293L4.086 9.81 5.5 8.396l3.5 3.5V1h2z'/%3E%3C/svg%3E"); }
.wq-icon-modifiedHistory, .wq-icon-history { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 1a9 9 0 110 18v-2a7 7 0 10-4-1.257V13h2.001L8 18l-1 1H2v-2l2.346-.001A8.97 8.97 0 011 10a9 9 0 019-9'/%3E%3Cpath d='M11 10h3v2H9V5h2z'/%3E%3C/svg%3E"); }
.wq-icon-chevronNext { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M14 9.293v1.414l-5.982 6-1.415-1.414L11.896 10 6.603 4.707l1.414-1.414z'/%3E%3C/svg%3E"); }
.wq-icon-arrowPrevious { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.83 9l5.58-5.58L10 2l-8 8 8 8 1.41-1.41L5.83 11H18V9z'/%3E%3C/svg%3E"); }
.wq-icon-speechBubbles { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M2 1h11a1 1 0 0 1 1 1v8a1 1 0 0 1-1 1H6l-4 3v-3H2a1 1 0 0 1-1-1V2a1 1 0 0 1 1-1m1 2v6h1v1l1.3-1H12V3zm13 2h2a1 1 0 0 1 1 1v8a1 1 0 0 1-1 1v3l-4-3H8a1 1 0 0 1-1-1v-1h2v-1h7z'/%3E%3C/svg%3E"); }
.vector-icon { -webkit-mask-image: var(--i); mask-image: var(--i); }

/* ---------- Buttons ---------- */
.cdx-button {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 32px; min-width: 32px; padding: 0 11px; box-sizing: border-box;
  border: 1px solid transparent; border-radius: 2px; background: transparent;
  color: var(--text); font-size: 14px; font-weight: 700; cursor: pointer;
  text-decoration: none !important;
}
.cdx-button:hover { background-color: rgba(0, 24, 73, 0.027); }
html.wq-theme-dark .cdx-button:hover { background-color: rgba(255, 255, 255, 0.06); }
.cdx-button--icon-only { padding: 0; width: 32px; }

/* ---------- Header ---------- */
.vector-header-container { background: var(--bg); }
.vector-header {
  display: flex; justify-content: space-between; align-items: center;
  max-width: 99.75rem; height: 50px; margin: 0 auto; padding: 8px 2.75rem;
  box-sizing: content-box; background: var(--bg);
}
html.wq-width-wide .vector-header, html.wq-width-wide .mw-page-container { max-width: none; }
.vector-header-start, .vector-header-end { display: flex; align-items: center; }
.vector-header-start { flex-shrink: 0; }
.vector-header-end { flex-grow: 1; justify-content: flex-end; gap: 12px; }
.vector-main-menu-landmark { margin-right: 14px; margin-left: -6px; }
.mw-logo { display: flex; align-items: center; color: var(--text) !important; text-decoration: none !important; min-width: 0; }
.mw-logo-icon { width: 50px; height: 50px; margin-right: 10px; display: block; }
.mw-logo-container { display: flex; flex-direction: column; justify-content: center; }
.mw-logo-wordmark { display: block; height: 22px; line-height: 22px; }
.wq-wordmark {
  font-family: 'Linux Libertine', 'Hoefler Text', Georgia, 'Times New Roman', Times, serif;
  font-variant: small-caps; font-size: 23px; letter-spacing: 0.035em; color: #000; white-space: nowrap; line-height: 1;
}
html.wq-theme-dark .wq-wordmark { color: #f8f9fa; }
@media (prefers-color-scheme: dark) { html.wq-theme-os .wq-wordmark { color: #f8f9fa; } }
.wq-wordmark::first-letter { font-size: 1.16em; }
.mw-logo-tagline {
  display: block; margin-top: 5px; font-family: 'Linux Libertine', 'Hoefler Text', Georgia, 'Times New Roman', serif;
  font-size: 12.6px; line-height: 13px; color: var(--text); white-space: nowrap; letter-spacing: 0.01em;
}

/* Search */
.vector-search-box { flex-grow: 1; max-width: 500px; margin-right: auto; margin-left: 2.25rem; min-width: 0; }
.cdx-search-input { position: relative; display: flex; }
.cdx-text-input { position: relative; flex-grow: 1; min-width: 0; }
.cdx-text-input__input {
  width: 100%; box-sizing: border-box; height: 32px; padding: 4px 8px 4px 34px;
  font-family: inherit; font-size: 14px; line-height: 22px; color: var(--text);
  background: var(--bg); border: 1px solid var(--border-input); border-radius: 2px 0 0 2px;
  -webkit-appearance: none; appearance: none; outline: 0;
}
.cdx-text-input__input::placeholder { color: var(--text-placeholder); opacity: 1; }
.cdx-text-input__input:focus { border-color: var(--progressive); box-shadow: inset 0 0 0 1px var(--progressive); }
.cdx-text-input__input::-webkit-search-cancel-button { -webkit-appearance: none; }
.cdx-text-input__icon { position: absolute; left: 9px; top: 6px; display: flex; pointer-events: none; }
.cdx-text-input__icon .vector-icon { background-color: var(--text-subtle); }
.cdx-search-input__end-button {
  margin-left: -1px; height: 32px; padding: 1px 11px; font-size: 14px; font-weight: 700; color: var(--text);
  background: var(--bg-subtle); border: 1px solid var(--border-input); border-radius: 0 2px 2px 0; cursor: pointer;
}
.cdx-search-input__end-button:hover { background: var(--bg); }
.wq-suggestions {
  display: none; position: absolute; top: 100%; left: 0; right: 0; z-index: 50; margin: 0; padding: 0;
  list-style: none; background: var(--bg); border: 1px solid var(--border-input); border-top: 0;
  box-shadow: 0 4px 4px 0 rgba(0, 0, 0, 0.06), 0 0 8px 0 rgba(0, 0, 0, 0.08); border-radius: 0 0 2px 2px;
}
.wq-suggestions.open { display: block; }
.wq-suggestions li a {
  display: flex; align-items: center; gap: 12px; padding: 8px 12px; color: var(--text); text-decoration: none;
}
.wq-suggestions li a:hover, .wq-suggestions li.active a { background: var(--bg-interactive); }
.wq-suggestions .wq-thumb {
  flex: 0 0 40px; height: 40px; border-radius: 2px; background: var(--bg-subtle) center / cover no-repeat;
  border: 1px solid var(--border-light); box-sizing: border-box;
}
.wq-suggestions .wq-thumb:not([style]) { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%23a2a9b1'%3E%3Cpath d='M5 1a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V3a2 2 0 0 0-2-2zm0 3h10v1H5zm0 2h10v1H5zm0 2h10v1H5zm0 2h10v1H5zm0 2h10v1H5zm0 2h5v1H5z'/%3E%3C/svg%3E"); background-size: 20px; }
.wq-suggestions .wq-s-title { font-size: 14px; font-weight: 700; line-height: 1.4; }
.wq-suggestions .wq-s-desc { font-size: 13px; color: var(--text-subtle); line-height: 1.4; }
.wq-suggestions .wq-s-containing a { border-top: 1px solid var(--border-subtle); font-size: 14px; }
.wq-suggestions .wq-s-containing .vector-icon { background-color: var(--text-subtle); margin: 0 10px; }
.wq-suggestions mark { background: none; color: inherit; font-weight: 700; }

/* User links */
.vector-user-links { display: flex; align-items: center; flex-shrink: 0; }
.vector-user-links-main { display: flex; list-style: none; margin: 0; padding: 0; }
.vector-user-links-main li { margin-left: 4px; font-size: 14px; }
.vector-user-links-main li a { padding: 0 4px; }
.vector-user-menu-overflow { display: none; }
.vector-appearance-dropdown { display: none; }
html.wq-appearance-unpinned .vector-appearance-dropdown { display: block; }

/* ---------- Dropdowns ---------- */
.vector-dropdown { position: relative; }
.vector-dropdown-content {
  display: none; position: absolute; top: 100%; left: -8px; z-index: 50; box-sizing: border-box;
  min-width: 200px; max-height: 70vh; overflow: auto; padding: 16px; background: var(--bg);
  border: 1px solid var(--border); border-radius: 2px; box-shadow: 0 2px 6px -1px var(--shadow); font-size: 14px;
}
.vector-dropdown.open > .vector-dropdown-content { display: block; }
.vector-user-links .vector-dropdown-content, #vector-page-tools-dropdown .vector-dropdown-content, #p-lang-btn .vector-dropdown-content { left: auto; right: 0; }
.vector-dropdown-content .mw-list-item a .vector-icon { margin-right: 8px; background-color: var(--text); }
.vector-dropdown .vector-dropdown-label { color: var(--text); }

/* Menus inside dropdowns / panels */
.vector-menu-heading {
  display: block; margin: 6px 0; padding: 6px 0; font-size: 14px; font-weight: 400; color: var(--text-subtle);
  border-bottom: 1px solid var(--border-light); word-wrap: break-word;
}
.vector-menu-content-list { list-style: none; margin: 0; padding: 0; }
.vector-menu-content-list .mw-list-item a { display: flex; align-items: center; padding: 6px 0; font-size: 14px; }
.vector-pinnable-element .vector-menu:first-of-type .vector-menu-heading { margin-top: 0; }

/* Pinnable headers */
.vector-pinnable-header {
  display: flex; align-items: center; gap: 8px; margin: 0 0 6px; padding: 0 0 6px;
  border-bottom: 1px solid var(--border-light); font-size: 14px; line-height: 1.6;
}
.vector-pinnable-header-label { flex-grow: 1; margin: 0; font-family: var(--font-sans); font-size: 14px; font-weight: 700; color: var(--text-emphasized); border: 0; padding: 0; line-height: 1.6; }
.vector-pinnable-header-toggle-button {
  padding: 4px 8px; font-size: 12px; line-height: 1.2; color: var(--text); background: var(--bg-interactive);
  border: 0; border-radius: 2px; cursor: pointer; white-space: nowrap;
}
.vector-pinnable-header-toggle-button:hover { background: var(--bg-interactive-hover); }
.vector-pinned-container .vector-pinnable-header-pin-button,
.vector-unpinned-container .vector-pinnable-header-unpin-button { display: none; }
.vector-pinned-container .vector-pinnable-header-unpin-button { display: inline-block; }

/* ---------- Page layout ---------- */
.mw-page-container {
  max-width: 99.75rem; min-width: 0; margin: 0 auto; padding: 0.05px 2.75rem 0; box-sizing: border-box;
  background: var(--bg); min-height: calc(100% - 66px);
}
.mw-page-container-inner {
  display: grid; column-gap: 24px; padding-top: 24px;
  grid-template: min-content 1fr min-content / 12.25rem minmax(0, 1fr);
  grid-template-areas: 'columnStart pageContent' 'columnStart pageContent' 'footer footer';
}
.vector-column-start { grid-area: columnStart; margin-top: 2.8rem; min-width: 0; }
.mw-content-container { grid-area: pageContent; min-width: 0; }
.mw-footer-container { grid-area: footer; padding: 50px 0 82px; }
html.wq-toc-unpinned.wq-mainmenu-unpinned .mw-page-container-inner,
html.wq-no-toc.wq-mainmenu-unpinned .mw-page-container-inner { grid-template-columns: minmax(0, 1fr); grid-template-areas: 'pageContent' 'pageContent' 'footer'; }
html.wq-toc-unpinned.wq-mainmenu-unpinned .vector-column-start,
html.wq-no-toc.wq-mainmenu-unpinned .vector-column-start { display: none; }

.vector-sticky-pinned-container { position: sticky; top: 24px; max-height: calc(100vh - 24px); overflow-y: auto; box-sizing: border-box; padding-bottom: 24px; scrollbar-width: thin; }
html.wq-sticky .vector-sticky-pinned-container { top: 74px; max-height: calc(100vh - 74px); }
.vector-column-start .vector-sticky-pinned-container { margin-left: -12px; padding-left: 16px; }
.vector-main-menu-container { margin-left: 4px; }
#vector-main-menu-pinned-container:not(:empty) { margin-bottom: 20px; }

.mw-body {
  display: grid; column-gap: 24px;
  grid-template-columns: minmax(0, 1fr) min-content;
  grid-template-areas: 'titlebar columnEnd' 'toolbar columnEnd' 'content columnEnd';
  grid-template-rows: min-content min-content 1fr;
}
html.wq-appearance-unpinned.wq-tools-unpinned .mw-body { grid-template-columns: minmax(0, 1fr); grid-template-areas: 'titlebar' 'toolbar' 'content'; }
html.wq-appearance-unpinned.wq-tools-unpinned .vector-column-end { display: none; }
.vector-page-titlebar { grid-area: titlebar; }
.vector-page-toolbar { grid-area: toolbar; }
.vector-body { grid-area: content; }
.vector-column-end { grid-area: columnEnd; width: 12.25rem; margin-top: 2.8rem; }
.vector-column-end .vector-sticky-pinned-container { padding-left: 0; }
.vector-column-end .vector-pinned-container { padding: 0 16px; }
#vector-page-tools-pinned-container:not(:empty) { margin-bottom: 20px; }

/* Title bar */
.vector-page-titlebar { position: relative; display: flex; align-items: center; min-height: 39.6px; }
.vector-page-titlebar::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--border); }
.firstHeading {
  flex-grow: 1; margin: 0; padding: 0; overflow-wrap: break-word; word-wrap: break-word;
  font-family: var(--font-serif); font-size: 1.8em; font-weight: 400; line-height: 1.375; color: var(--text-emphasized);
}
html.wq-main-page .vector-page-titlebar .firstHeading { visibility: hidden; height: 39.6px; }
html.wq-main-page .vector-page-titlebar::after { display: none; }
.vector-page-titlebar-toc { display: none; margin-left: -6px; margin-right: 8px; }
html.wq-toc-unpinned:not(.wq-no-toc) .vector-page-titlebar-toc { display: block; }
.vector-page-titlebar-toc .vector-dropdown-content { width: 300px; max-height: 65vh; }
.mw-portlet-lang { flex-shrink: 0; margin-right: -12px; }
.wq-lang-btn { color: var(--link) !important; font-weight: 700; padding: 0 11px; }
.wq-lang-btn .vector-dropdown-label-text { white-space: nowrap; }
#p-lang-btn .vector-dropdown-content { width: 520px; max-width: 80vw; }
.wq-lang-list { column-width: 140px; column-gap: 16px; }
.wq-lang-list li { padding: 4px 0; break-inside: avoid; }
.wq-lang-empty { margin: 0; }

/* Toolbar */
.vector-page-toolbar-container { display: flex; justify-content: space-between; box-shadow: 0 1px var(--border-subtle); margin-bottom: 1px; height: 32px; }
#left-navigation, #right-navigation { display: flex; align-items: flex-end; }
#right-navigation { margin-right: -12px; }
.vector-menu-tabs { display: flex; height: 32px; list-style: none; margin: 0; padding: 0; font-size: 14px; }
.vector-menu-tabs li { margin: 0 8px; }
#left-navigation .vector-menu-tabs li:first-child { margin-left: 0; }
.vector-menu-tabs a { position: relative; display: inline-flex; align-items: center; height: 32px; color: var(--link); white-space: nowrap; border-radius: 2px; }
.vector-menu-tabs a:visited { color: var(--link); }
.vector-menu-tabs .selected a, .vector-menu-tabs .selected a:visited { color: var(--text); }
.vector-menu-tabs .selected a::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--text); }
.vector-menu-tabs a:hover { text-decoration: none; }
.vector-menu-tabs li:not(.selected) a:hover::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--link); }
.vector-page-tools-dropdown { margin-left: 4px; }
.wq-tools-label .wq-tools-text { display: none; }
.wq-tools-actions { display: none; }
#vector-page-tools-dropdown .vector-dropdown-content { min-width: 200px; }
html.wq-tools-pinned #vector-page-tools-dropdown { display: none; }

/* Body */
.vector-body { position: relative; z-index: 0; font-size: var(--font-size-body); line-height: 1.625; }
.vector-body-before-content { overflow: hidden; display: flow-root; }
.mw-indicators { float: right; font-size: 14px; line-height: 1.6; margin-top: 8px; position: relative; z-index: 1; }
#coordinates { font-size: 0.92em; line-height: 2; white-space: nowrap; }
#coordinates .wq-globe { display: inline-block; width: 14px; height: 14px; margin-right: 3px; vertical-align: -2px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #fff 0, #9db8d6 45%, #4b72a0 100%); }
#siteSub { display: block; margin-top: 8px; font-size: 14px; line-height: 1.625; color: var(--text); }
.mw-body-content { margin-top: 16px; font-size: var(--font-size-body); line-height: 1.625; }
.mw-parser-output { color: var(--text); word-wrap: break-word; }
.mw-parser-output::after { content: ''; display: block; clear: both; }

/* Typography in content */
.mw-parser-output p { margin: 0.5em 0 1em 0; }
.mw-parser-output p:first-child, .mf-section-0 > p:first-of-type { margin-top: 0.5em; }
.mw-parser-output a.external { word-break: normal; }
.mw-parser-output a.external.text::after, .mw-parser-output a.external.free::after {
  content: ''; display: inline-block; width: 0.857em; height: 0.857em; margin-left: 0.143em; vertical-align: -0.05em;
  background-color: currentColor; opacity: 0.85;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M6 1h5v5L8.86 3.85 4.7 8 4 7.3l4.15-4.16zM2 3h2v1H2v6h6V8h1v2a1 1 0 0 1-1 1H2a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M6 1h5v5L8.86 3.85 4.7 8 4 7.3l4.15-4.16zM2 3h2v1H2v6h6V8h1v2a1 1 0 0 1-1 1H2a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1'/%3E%3C/svg%3E") center / contain no-repeat;
}
.mw-parser-output ul { list-style-type: disc; margin: 0.3em 0 0 1.6em; padding: 0; }
.mw-parser-output ol { margin: 0.3em 0 0 3.2em; padding: 0; }
.mw-parser-output li { margin-bottom: 0.1em; }
.mw-parser-output ul ul, .mw-parser-output ol ol { margin-top: 0; }
.mw-parser-output dl { margin: 0.2em 0 0.5em; }
.mw-parser-output dt { font-weight: 700; }
.mw-parser-output dd { margin-left: 1.6em; margin-bottom: 0.1em; }
.mw-parser-output blockquote { overflow: hidden; margin: 1em 0; padding: 0 32px; }
.mw-parser-output blockquote p { margin: 0.5em 0; }
.mw-parser-output sup, .mw-parser-output sub { line-height: 1; }
.mw-parser-output small { font-size: 85%; }
.mw-parser-output hr { height: 1px; background: var(--border); border: 0; margin: 0.2em 0; }
.mw-parser-output pre, .mw-parser-output code { font-family: monospace, monospace; background: var(--bg-subtle); border: 1px solid var(--border-light); border-radius: 2px; color: var(--text); }
.mw-parser-output code { padding: 1px 4px; }
.mw-parser-output pre { padding: 14px; white-space: pre-wrap; line-height: 1.3; }
.nowrap { white-space: nowrap; }

/* Headings */
.mw-heading { display: flow-root; color: var(--text-emphasized); }
.mw-heading h2, .mw-heading h3, .mw-heading h4 { display: inline; margin: 0; padding: 0; font-size: inherit; font-weight: inherit; font-family: inherit; line-height: inherit; color: inherit; }
.mw-heading2 {
  margin: 0.25em 0 0.25em; padding: 0.5em 0 0.17em; border-bottom: 1px solid var(--border);
  font-family: var(--font-serif); font-size: 1.5em; font-weight: 400; line-height: 1.375;
}
.mw-heading3 { margin: 0.3em 0 0.3em; padding: 0.5em 0 0; font-size: 1.2em; font-weight: 700; line-height: 1.6; }
.mw-heading4 { margin: 0.3em 0 0.3em; padding: 0.5em 0 0; font-size: 100%; font-weight: 700; line-height: 1.6; }
.mw-editsection {
  margin-left: 13px; font-family: var(--font-sans); font-size: 13px; font-weight: 400; line-height: 1;
  vertical-align: baseline; white-space: nowrap; unicode-bidi: isolate; user-select: none; color: var(--text-subtle);
}
.mw-heading3 .mw-editsection, .mw-heading4 .mw-editsection { font-size: 13px; }
.mw-editsection-bracket { margin: 0 0.25em; color: var(--text-subtle); }
.mw-editsection-bracket:first-child { margin-left: 0; }
.mf-collapsible-icon { display: none; }

/* Hatnote */
.hatnote { font-style: italic; padding-left: 1.6em; margin-bottom: 0.5em; }
.hatnote i { font-style: normal; }
div.hatnote + div.hatnote { margin-top: -0.5em; }

/* References */
sup.reference { font-size: 0.8em; font-weight: 400; line-height: 1; unicode-bidi: isolate; white-space: nowrap; font-style: normal; }
sup.reference a { color: var(--link); }
.Template-Fact { font-size: 0.8em; line-height: 1; }
.mw-references-wrap { margin-top: 0.3em; }
.mw-references-columns { column-width: 30em; }
.mw-references-columns li { break-inside: avoid-column; }
ol.references { font-size: 90%; margin: 0 0 0.5em 3.2em; list-style-type: decimal; }
ol.references li { margin-bottom: 0.1em; }
ol.references li:target, sup.reference:target { background-color: var(--target); }
.mw-cite-backlink a { font-weight: 400; }
cite.citation { font-style: inherit; word-wrap: break-word; }

/* Infobox */
.infobox {
  float: right; clear: right; width: 22em; margin: 0.5em 0 0.5em 1em; padding: 0.2em;
  border: 1px solid var(--border); border-spacing: 3px; background-color: var(--bg-subtle);
  color: var(--text); font-size: 88%; line-height: 1.5em;
}
html:not(.wq-theme-dark) .infobox { color: #000; }
.infobox td, .infobox th { vertical-align: top; text-align: left; padding: 1px; }
.infobox-above { font-size: 125%; font-weight: 700; text-align: center !important; padding: 0.2em 0.4em; }
.infobox-subheader, .infobox-image, .infobox-full-data, .infobox-below { text-align: center !important; }
.infobox-header { text-align: center !important; background-color: var(--bg-infobox-header); }
.infobox-label { padding-right: 0.6em !important; }
.infobox-caption { padding-top: 0.2em; }
.infobox-image img { max-width: 100%; height: auto; }
.infobox-below { border-top: 1px solid var(--border); }

/* Figures */
.mw-parser-output figure[typeof~='mw:File/Thumb'] {
  display: table; float: right; clear: right; margin: 0.5em 0 1.3em 1.4em; width: 1px;
  border: 1px solid var(--border-subtle); border-bottom: 0; background-color: var(--bg-subtle); text-align: left;
}
.mw-parser-output figure.mw-halign-left { float: left !important; clear: left !important; margin: 0.5em 1.4em 1.3em 0 !important; }
.mw-parser-output figure.mw-halign-center { float: none !important; margin: 0.5em auto 1.3em !important; }
.mw-parser-output figure.mw-halign-none { float: none !important; margin-left: 0 !important; }
.mw-parser-output figure > a { display: block; margin: 3px 3px 0; line-height: 0; }
.mw-parser-output figure img { max-width: none; height: auto; border: 1px solid var(--border-subtle); box-sizing: content-box; background: var(--bg); }
.mw-parser-output figure > figcaption {
  display: table-caption; caption-side: bottom; padding: 0 6px 6px; line-height: 1.4; font-size: 88.4%;
  background-color: var(--bg-subtle); border: 1px solid var(--border-subtle); border-top: 0;
}

/* Tables */
.wikitable { background-color: var(--bg-subtle); color: var(--text); margin: 1em 0; border: 1px solid var(--border); border-collapse: collapse; font-size: 100%; }
.wikitable > tr > th, .wikitable > tr > td, .wikitable > * > tr > th, .wikitable > * > tr > td { border: 1px solid var(--border); padding: 0.2em 0.4em; }
.wikitable > tr > th, .wikitable > * > tr > th { background-color: var(--bg-interactive); text-align: center; }
.wikitable > caption { font-weight: 700; padding: 0.2em 0.4em; }
.mw-parser-output .noprint { }

/* Categories */
.catlinks {
  clear: both; margin-top: 1em; padding: 5px; border: 1px solid var(--border); background-color: var(--bg-subtle);
  font-size: var(--font-size-body); line-height: 1.625;
}
.catlinks ul { display: inline; margin: 0; padding: 0; list-style: none; }
.catlinks li { display: inline-block; margin: 0.125em 0; padding: 0 0.5em; border-left: 1px solid var(--border-subtle); line-height: 1.25em; }
.catlinks li:first-child { padding-left: 0.25em; border-left: 0; }

/* ---------- Table of contents ---------- */
.vector-toc { font-size: 14px; padding-right: 16px; }
.vector-toc .vector-pinnable-header { margin-left: 12px; }
.vector-toc-contents, .vector-toc-list { list-style: none; margin: 0; padding: 0; }
.vector-toc-list-item { position: relative; display: list-item; list-style: none; padding-left: 12px; margin: 0; }
.vector-toc-level-1 { padding-left: 0; }
.vector-toc-level-1 > .vector-toc-link { padding-left: 12px; }
.vector-toc-link { display: block; padding: 6px 0; line-height: 1.15; color: var(--link); word-break: break-word; }
.vector-toc-link:visited { color: var(--link); }
.vector-toc-link:hover { text-decoration: underline; }
.vector-toc-list-item-active > .vector-toc-link, .vector-toc-list-item-active > .vector-toc-link:visited { color: var(--text); font-weight: 700; }
.vector-toc-toggle {
  position: absolute; top: 1px; left: -11px; width: 22px; height: 22px; min-width: 22px; min-height: 22px; padding: 0;
  display: flex; align-items: center; justify-content: center; font-size: 11.2px;
}
.vector-toc-toggle .vector-icon { width: 12px; height: 12px; min-width: 12px; min-height: 12px; background-color: var(--text); transition: transform 0.2s; transform: rotate(-90deg); }
.vector-toc-list-item-expanded > .vector-toc-toggle .vector-icon { transform: rotate(0); }
.vector-toc-list-item > .vector-toc-list { display: none; }
.vector-toc-list-item-expanded > .vector-toc-list { display: block; }
.vector-toc-level-2 .vector-toc-link { padding-left: 12px; }
.vector-toc-level-2 .vector-toc-toggle { left: 1px; }

/* ---------- Appearance panel ---------- */
.vector-appearance { font-size: 14px; }
.vector-appearance .vector-menu { margin-bottom: 6px; }
.vector-appearance .vector-menu-heading { margin-top: 6px; }
.cdx-radio { margin-bottom: 4px; }
.cdx-radio__wrapper { position: relative; display: flex; align-items: center; min-height: 22px; padding-bottom: 4px; }
.cdx-radio__input { position: absolute; left: 0; top: 0; width: 20px; height: 20px; margin: 0; opacity: 0; z-index: 1; cursor: pointer; }
.cdx-radio__icon {
  position: absolute; left: 0; top: 1px; width: 20px; height: 20px; box-sizing: border-box;
  border: 1px solid var(--border-input); border-radius: 50%; background: var(--bg); transition: border 0.1s;
}
.cdx-radio__input:checked + .cdx-radio__icon { border: 6px solid var(--progressive); background: var(--bg); }
.cdx-radio__input:hover + .cdx-radio__icon { border-color: var(--progressive); }
.cdx-radio__label { padding-left: 28px; font-size: 14px; line-height: 22px; }
.cdx-radio__label label { cursor: pointer; }

/* ---------- Footer ---------- */
.mw-footer { padding: 12px 0; font-size: 12px; line-height: 1.4; border-top: 1px solid var(--border); }
.mw-footer ul { list-style: none; margin: 0; padding: 0; }
#footer-info li { padding: 6px 0; }
#footer-places { padding-top: 6px; }
#footer-places li { display: inline-block; margin-right: 12px; padding: 6px 0; line-height: 2; }
#footer-icons { float: right; margin-top: -2px; }
#footer-icons li { display: inline-block; margin-left: 8px; }
.wq-footer-badge {
  display: inline-flex; flex-direction: column; justify-content: center; height: 29px; box-sizing: border-box; padding: 0 8px;
  border: 1px solid var(--border-subtle); border-radius: 2px; background: var(--bg); color: var(--text) !important;
  font-size: 10px; font-weight: 700; line-height: 1.1; text-decoration: none !important;
}
.wq-footer-badge small { font-size: 8px; font-weight: 400; color: var(--text-subtle); }
.mw-footer::after { content: ''; display: block; clear: both; }

/* ---------- Sticky header ---------- */
.vector-sticky-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100; display: flex; align-items: center; justify-content: space-between;
  height: 50px; padding: 0 2.75rem 0 1.5rem; box-sizing: border-box; background: var(--bg);
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.1); transform: translateY(-100%); visibility: hidden; transition: transform 0.25s, visibility 0.25s;
}
html.wq-sticky .vector-sticky-header { transform: none; visibility: visible; }
.vector-sticky-header-start, .vector-sticky-header-end { display: flex; align-items: center; gap: 8px; min-width: 0; }
.vector-sticky-header-icon-start { width: 32px; display: flex; justify-content: center; }
.vector-sticky-header-icon-start .vector-icon { visibility: hidden; }
.vector-sticky-header-context-bar { border-left: 1px solid var(--border-subtle); padding-left: 16px; min-width: 0; }
.vector-sticky-header-context-bar-primary { font-family: var(--font-serif); font-size: 1.5rem; line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--text-emphasized); }
.wq-sticky-lang { color: var(--link) !important; }
.vector-sticky-header-end .cdx-button--icon-only .vector-icon { background-color: var(--icon); }

/* ---------- Responsive (desktop skin) ---------- */
@media (max-width: 1119px) {
  html .vector-column-end { display: none; }
  html .mw-body { grid-template-columns: minmax(0, 1fr); grid-template-areas: 'titlebar' 'toolbar' 'content'; }
  .vector-appearance-dropdown { display: block; }
  #vector-page-tools-dropdown { display: block !important; }
  .vector-header { padding-left: 1.5rem; padding-right: 1.5rem; }
  .mw-page-container { padding-left: 1.5rem; padding-right: 1.5rem; }
}
@media (max-width: 999px) {
  .mw-page-container-inner { grid-template-columns: minmax(0, 1fr) !important; grid-template-areas: 'pageContent' 'pageContent' 'footer' !important; }
  .vector-column-start { display: none !important; }
  html:not(.wq-no-toc) .vector-page-titlebar-toc { display: block; }
  .vector-user-links-main { display: none; }
  .vector-user-menu-overflow { display: block; }
  .vector-search-box { margin-left: 1rem; }
}
@media (max-width: 1000px) { .mw-logo-tagline { display: none; } .mw-logo-wordmark { height: auto; } }

/* ============================================================
   Mobile skin (Minerva) — html.wq-mobile
   ============================================================ */
html.wq-mobile body { background: var(--bg); font-family: var(--font-mobile); line-height: 1.4; }
html.wq-mobile { --font-size-body: 16px; }
html.wq-mobile.wq-font-small { --font-size-body: 14px; }
html.wq-mobile.wq-font-large { --font-size-body: 20px; }
html.wq-mobile .mw-page-container { padding: 0; max-width: 993px; min-height: 0; }
html.wq-mobile .mw-page-container-inner { display: block; padding-top: 0; }
html.wq-mobile .mw-body { display: block; padding: 0 16px; }
.header-container { background: var(--mobile-header); padding: 0 16px; }
.minerva-header { display: flex; align-items: center; height: 54px; max-width: 993px; margin: 0 auto; }
.mf-button { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0; border: 0; background: transparent; cursor: pointer; border-radius: 2px; }
.mf-button .vector-icon { background-color: var(--text-subtle); }
#mw-mf-main-menu-button { margin-left: -12px; }
.branding-box { display: flex; align-items: center; margin-left: 4px; text-decoration: none !important; }
.branding-box .wq-wordmark { font-size: 23px; }
.mf-header-end { display: flex; margin-left: auto; margin-right: -12px; }

/* drawer */
.mf-drawer {
  position: fixed; top: 0; bottom: 0; left: 0; z-index: 200; width: 300px; max-width: 85vw; overflow-y: auto;
  background: var(--bg); transform: translateX(-100%); transition: transform 0.2s ease; box-shadow: 0 0 20px rgba(0, 0, 0, 0.25);
}
html.wq-drawer-open .mf-drawer { transform: none; }
.mf-drawer ul { list-style: none; margin: 0; padding: 8px 0; border-bottom: 1px solid var(--border-light); }
.mf-drawer li a { display: flex; align-items: center; gap: 16px; padding: 10px 20px; color: var(--text); font-weight: 700; font-size: 15px; text-decoration: none; }
.mf-drawer li a .vector-icon { background-color: var(--text-subtle); }
.mf-drawer .mf-drawer-small { border: 0; }
.mf-drawer .mf-drawer-small a { font-weight: 400; font-size: 13px; color: var(--link); padding: 6px 20px; }
.mf-drawer-mask { position: fixed; inset: 0; z-index: 150; background: rgba(0, 0, 0, 0.3); opacity: 0; pointer-events: none; transition: opacity 0.2s; }
html.wq-drawer-open .mf-drawer-mask { opacity: 1; pointer-events: auto; }

/* search overlay */
.mf-search-overlay[hidden] { display: none !important; }
.mf-search-overlay { position: fixed; inset: 0; z-index: 300; background: var(--bg); }
.mf-search-form { display: flex; align-items: center; gap: 4px; height: 54px; padding: 0 8px; background: var(--mobile-header); }
.mf-search-input { flex: 1; height: 36px; padding: 4px 10px; font-size: 16px; border: 1px solid var(--border-input); border-radius: 2px; background: var(--bg); color: var(--text); font-family: inherit; -webkit-appearance: none; }
.mf-suggestions { position: static; display: block; border: 0; box-shadow: none; }

/* title, tabs, page actions */
html.wq-mobile .vector-page-titlebar { display: block; margin: 20px 0 12px; min-height: 0; }
html.wq-mobile .vector-page-titlebar::after { display: none; }
html.wq-mobile .firstHeading { font-size: 1.7em; line-height: 1.375; color: var(--text); }
html.wq-mobile.wq-main-page .vector-page-titlebar .firstHeading { visibility: visible; height: auto; }
.minerva__tab-container { border-bottom: 1px solid var(--border-muted); }
.minerva__tab { display: inline-block; margin-right: 10px; padding: 0 0 6px; color: var(--text-subtle) !important; font-weight: 700; text-decoration: none !important; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.minerva__tab.selected { color: var(--text) !important; border-bottom-color: var(--text-subtle); }
.page-actions-menu { border-bottom: 1px solid var(--border-subtle); }
.page-actions-menu__list { display: flex; list-style: none; margin: 0; padding: 0; height: 50px; align-items: center; }
.page-actions-menu__list-item { margin-left: 4px; }
.page-actions-menu__list-item.wq-mf-lang { margin-right: auto; margin-left: -12px; }
.page-actions-menu__list-item:last-child { margin-right: -12px; }
.page-actions-menu .vector-icon { background-color: var(--text-subtle); }

/* content */
html.wq-mobile .vector-body-before-content { display: none; }
html.wq-mobile .mw-body-content { margin-top: 0; line-height: 1.65; }
html.wq-mobile .mw-parser-output { padding-top: 0; }
html.wq-mobile .mf-section-0 { display: flex; flex-direction: column; }
html.wq-mobile .mf-section-0 > * { order: 0; }
html.wq-mobile .mf-section-0 > .hatnote { order: -2; }
html.wq-mobile .mf-section-0 > p:first-of-type { order: -1; }
html.wq-mobile .hatnote {
  margin: 0 0 1px; padding: 5px 7px; background: var(--bg-subtle); color: var(--text-subtle); font-size: 13px; line-height: 1.65; font-style: italic;
}
html.wq-mobile .infobox { float: none; width: 100% !important; margin: 0.5em 0 1.8em; box-sizing: border-box; font-size: 90%; border-color: var(--border-muted); }
html.wq-mobile .mw-parser-output figure[typeof~='mw:File/Thumb'] { float: none !important; margin: 0.5em auto 1.3em !important; }
html.wq-mobile .mw-parser-output figure img { max-width: calc(100vw - 40px); height: auto; }
html.wq-mobile .mw-heading2 {
  display: flex; align-items: center; margin: 0; padding: 12px 0; border-bottom: 1px solid var(--border-muted); cursor: pointer;
  font-size: 1.5em; color: var(--text); -webkit-tap-highlight-color: transparent;
}
html.wq-mobile .mw-heading2 h2 { flex: 1; }
html.wq-mobile .mf-collapsible-icon {
  display: inline-block; width: 16px; height: 16px; margin-right: 6px; flex-shrink: 0; background-color: var(--text-subtle);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m16.7 8-6 6H9.3l-6-6 1.4-1.4 5.3 5.3 5.3-5.3z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m16.7 8-6 6H9.3l-6-6 1.4-1.4 5.3 5.3 5.3-5.3z'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: transform 0.15s;
}
html.wq-mobile .mf-collapsible-heading.open .mf-collapsible-icon { transform: rotate(180deg); }
html.wq-mobile .collapsible-block { display: none; padding-bottom: 12px; }
html.wq-mobile .collapsible-block.open-block { display: block; }
html.wq-mobile .mw-heading2 .mw-editsection { display: none; }
html.wq-mobile .mw-heading2.open .mw-editsection { display: inline-flex; }
html.wq-mobile .mw-editsection-bracket { display: none; }
html.wq-mobile .mw-editsection a { display: inline-block; width: 20px; height: 20px; font-size: 0; background-color: var(--text-subtle);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m15.4.4 4.2 4.2-3.2 3.2-4.2-4.2zM10.8 5 15 9.2l-8.6 8.6-4.5 1.5-1.2-1.2 1.5-4.5z'/%3E%3C/svg%3E") center / 18px no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m15.4.4 4.2 4.2-3.2 3.2-4.2-4.2zM10.8 5 15 9.2l-8.6 8.6-4.5 1.5-1.2-1.2 1.5-4.5z'/%3E%3C/svg%3E") center / 18px no-repeat; }
html.wq-mobile .mw-heading3 .mw-editsection, html.wq-mobile .mw-heading4 .mw-editsection { display: none; }
html.wq-mobile ol.references { margin-left: 2em; }
html.wq-mobile .mw-references-columns { column-width: auto; }
html.wq-mobile .catlinks { display: none; }
html.wq-mobile .wikitable { display: block; overflow-x: auto; }

/* mobile footer */
.minerva-footer-wrap { max-width: 993px; margin: 32px auto 0; }
.last-modified-bar { display: block; padding: 12px 16px; background: var(--mobile-header); border-top: 1px solid var(--border-subtle); border-bottom: 1px solid var(--border-subtle); color: var(--text-subtle) !important; font-size: 14px; text-decoration: none !important; }
.last-modified-bar__content { display: flex; align-items: center; gap: 8px; }
.last-modified-bar__text { flex: 1; }
.last-modified-bar .vector-icon { background-color: var(--text-subtle); }
.last-modified-text-accent { color: var(--text); }
.read-more-container { padding: 16px 16px 8px; background: var(--mobile-header); }
.read-more-container h2 { margin: 8px 0 12px; font-family: var(--font-mobile); font-size: 12px; font-weight: 400; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-subtle); }
.ext-related-articles-card-list { list-style: none; margin: 0; padding: 0; }
.ext-related-articles-card { margin-bottom: 8px; background: var(--bg); border: 1px solid var(--border-subtle); border-radius: 2px; }
.ext-related-articles-card a { display: flex; align-items: center; gap: 12px; padding: 8px; min-height: 64px; color: var(--text); text-decoration: none; }
.ext-related-articles-card-thumb { flex: 0 0 64px; height: 64px; background: var(--bg-subtle) center / cover no-repeat; border-radius: 2px; }
.ext-related-articles-card-detail h3 { margin: 0; font-size: 16px; font-weight: 700; line-height: 1.3; }
.ext-related-articles-card-extract { margin: 2px 0 0; font-size: 14px; color: var(--text-subtle); line-height: 1.4; }
.minerva-footer { padding: 24px 16px 32px; background: var(--mobile-header); }
.minerva-footer-logo { margin-bottom: 16px; }
.minerva-footer-logo .wq-wordmark { font-size: 22px; }
.minerva-footer .footer-info { font-size: 14px; line-height: 1.4; margin-bottom: 9px; }
.minerva-footer .footer-places { list-style: none; margin: 0; padding: 0; font-size: 14px; line-height: 1.4; }
.minerva-footer .footer-places li { display: inline; }
.minerva-footer .footer-places li:not(:last-child)::after { content: ' • '; color: var(--text-subtle); }

/* ---------- Main page ---------- */
.wq-mp-welcome { margin: 0 0 1em; padding: 16px 12px; text-align: center; background: var(--bg-subtle); border: 1px solid var(--border-muted); }
.wq-mp-welcome h1 { margin: 0; border: 0; font-family: var(--font-serif); font-size: 1.8em; font-weight: 400; line-height: 1.3; }
.wq-mp-welcome .wq-mp-sub { font-size: 95%; }
.wq-mp-welcome .wq-mp-count { font-size: 85%; margin-top: 4px; }
.wq-mp-cols { display: flex; gap: 12px; align-items: flex-start; }
.wq-mp-col { flex: 1 1 0; min-width: 0; }
.wq-mp-box { margin-bottom: 12px; border: 1px solid #cef2e0; background: #f5fffa; padding: 0 8px 8px; }
.wq-mp-box.blue { border-color: #cedff2; background: #f5faff; }
html.wq-theme-dark .wq-mp-box { border-color: #2d4a3a; background: #12201a; }
html.wq-theme-dark .wq-mp-box.blue { border-color: #2d3a4a; background: #121a24; }
.wq-mp-box h2 { margin: 0 -8px 8px; padding: 2px 8px; font-family: var(--font-sans); font-size: 120%; font-weight: 700; border: 1px solid #a3bfb1; background: #cef2e0; color: #000; }
.wq-mp-box.blue h2 { border-color: #a3b0bf; background: #cedff2; }
html.wq-theme-dark .wq-mp-box h2 { background: #1f3a2d; border-color: #2d4a3a; color: var(--text); }
html.wq-theme-dark .wq-mp-box.blue h2 { background: #1f2d3a; border-color: #2d3a4a; }
.wq-mp-box .wq-mp-img { float: left; margin: 0.5em 0.9em 0.4em 0; }
.wq-mp-box .wq-mp-img img { width: 140px; height: auto; }
.wq-mp-box p { margin: 0.4em 0; }
.wq-mp-box ul { margin-left: 1.6em; }
.wq-mp-box::after { content: ''; display: block; clear: both; }
@media (max-width: 999px) { .wq-mp-cols { flex-direction: column; } .wq-mp-col { width: 100%; } }
html.wq-mobile .wq-mp-cols { flex-direction: column; }
html.wq-mobile .wq-mp-col { width: 100%; }

@media print {
  .vector-header-container, .vector-column-start, .vector-column-end, .vector-page-toolbar, .vector-sticky-header,
  .minerva-only, .mw-editsection, .mw-footer-container, .vector-page-titlebar-toc, .mw-portlet-lang { display: none !important; }
  .mw-page-container-inner, .mw-body { display: block !important; }
  body { background: #fff; }
}

/* ---------- Page & reference previews ---------- */
.wq-popup {
  position: absolute; z-index: 400; width: 320px; background: var(--bg); color: var(--text); border-radius: 2px;
  box-shadow: 0 30px 90px -20px rgba(0, 0, 0, 0.3), 0 0 1px 1px rgba(0, 0, 0, 0.05); overflow: hidden;
  font-family: var(--font-sans); font-size: 14px; line-height: 1.6; animation: wq-fade 0.15s ease-out;
}
html.wq-theme-dark .wq-popup { box-shadow: 0 30px 90px -20px rgba(0, 0, 0, 0.9), 0 0 1px 1px rgba(255, 255, 255, 0.12); }
@keyframes wq-fade { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.wq-popup-thumb { display: block; background: center / cover no-repeat; }
.wq-popup-thumb.landscape { height: 192px; }
.wq-popup.is-portrait .wq-popup-body { display: flex; flex-direction: row-reverse; }
.wq-popup.is-portrait { width: 450px; }
.wq-popup.is-portrait .wq-popup-thumb { flex: 0 0 160px; min-height: 200px; margin: -16px -16px -16px 16px; }
.wq-popup-body { padding: 16px; }
.wq-popup-extract { display: block; color: var(--text) !important; text-decoration: none !important; max-height: 9.6em; overflow: hidden; position: relative; }
.wq-popup-extract p { margin: 0; }
.wq-popup-extract::after { content: ''; position: absolute; right: 0; bottom: 0; width: 25%; height: 1.6em; background: linear-gradient(to right, transparent, var(--bg) 70%); }
.wq-popup-ref { width: 340px; }
.wq-popup-ref-head { padding: 12px 16px 0; font-size: 12px; font-weight: 700; color: var(--text-subtle); text-transform: uppercase; letter-spacing: 0.04em; }
.wq-popup-ref-body { padding: 8px 16px 16px; max-height: 240px; overflow: auto; }
.wq-ref-drawer {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 400; max-height: 50vh; overflow: auto; background: var(--bg);
  box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.2); border-top: 1px solid var(--border-subtle); font-size: 14px; line-height: 1.5;
  animation: wq-up 0.2s ease-out;
}
@keyframes wq-up { from { transform: translateY(100%); } to { transform: none; } }
.wq-ref-drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 8px 16px; color: var(--text-subtle); font-weight: 700; }
.wq-ref-drawer-head button { border: 0; background: none; font-size: 24px; color: var(--text-subtle); cursor: pointer; padding: 0 4px; }
.wq-ref-drawer-body { padding: 0 16px 20px; }

/* ---------- Special pages (/new) ---------- */
html.wq-special #ca-talk, html.wq-special .wq-views, html.wq-special #vector-page-tools-dropdown,
html.wq-special #p-lang-btn, html.wq-special #siteSub, html.wq-special .page-actions-menu,
html.wq-special .minerva__tab-container a + a { display: none !important; }
.wq-new { max-width: 900px; }
.wq-mbox { display: flex; gap: 12px; align-items: flex-start; margin: 0 0 1.5em; padding: 12px 16px; border: 1px solid #fc3; border-left-width: 6px; background: #fef6e7; color: #202122; font-size: 15px; line-height: 1.6; }
html.wq-theme-dark .wq-mbox { background: #3a2f12; border-color: #a66200; color: var(--text); }
.wq-mbox-icon { flex: 0 0 auto; width: 28px; height: 28px; border-radius: 50%; background: #fc3; color: #000; font: 700 18px/28px var(--font-serif); text-align: center; }
.wq-mbox p { margin: 0 0 0.4em !important; }
.wq-field { margin: 0 0 1.4em; }
.wq-field > label, .wq-label { display: block; margin-bottom: 4px; font-weight: 700; font-size: 14px; }
.wq-help { margin: 2px 0 6px; font-size: 13px; color: var(--text-subtle); line-height: 1.5; }
.wq-input, .wq-textarea, .wq-select {
  width: 100%; box-sizing: border-box; padding: 6px 8px; font: inherit; font-size: 14px; color: var(--text);
  background: var(--bg); border: 1px solid var(--border-input); border-radius: 2px;
}
.wq-input:focus, .wq-textarea:focus, .wq-select:focus { outline: 0; border-color: var(--progressive); box-shadow: inset 0 0 0 1px var(--progressive); }
.wq-textarea { min-height: 360px; font-family: monospace, monospace; font-size: 13px; line-height: 1.5; resize: vertical; }
.wq-slug-row { display: flex; align-items: stretch; }
.wq-slug-prefix { display: flex; align-items: center; padding: 0 8px; border: 1px solid var(--border-input); border-right: 0; border-radius: 2px 0 0 2px; background: var(--bg-subtle); color: var(--text-subtle); font-size: 14px; white-space: nowrap; }
.wq-slug-row .wq-input { border-radius: 0 2px 2px 0; }
.wq-select { width: auto; }
.wq-error { margin-top: 4px; color: #d73333; font-size: 13px; font-weight: 700; }
.wq-error:empty { display: none; }
.wq-ok { margin-top: 4px; color: #14866d; font-size: 13px; }
.wq-ok:empty { display: none; }
.wq-input.invalid { border-color: #d73333; }
.wq-prompt { position: relative; }
.wq-prompt textarea { min-height: 220px; background: var(--bg-subtle); }
.wq-copy { position: absolute; top: 6px; right: 6px; }
.wq-btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 32px; padding: 0 12px; border-radius: 2px;
  border: 1px solid var(--border-input); background: var(--bg-subtle); color: var(--text); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer;
}
.wq-btn:hover { background: var(--bg); }
.wq-btn-primary { background: #36c; border-color: #36c; color: #fff; }
.wq-btn-primary:hover { background: #3056a9; border-color: #3056a9; }
.wq-btn[disabled] { background: #c8ccd1; border-color: #c8ccd1; color: #fff; cursor: default; }
.wq-check { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; line-height: 1.5; }
.wq-check input { margin-top: 4px; }
.wq-submit-row { display: flex; align-items: center; gap: 12px; }
.wq-select {
  -webkit-appearance: none; appearance: none; width: auto; min-width: 160px; min-height: 32px;
  padding: 4px 36px 4px 12px; line-height: 22px; cursor: pointer;
  background: var(--bg) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%23202122'%3E%3Cpath d='m16.7 8-6 6H9.3l-6-6 1.4-1.4 5.3 5.3 5.3-5.3z'/%3E%3C/svg%3E") no-repeat right 12px center / 12px 12px;
}
.wq-select:hover { border-color: var(--text-subtle); }
html.wq-theme-dark .wq-select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%23eaecf0'%3E%3Cpath d='m16.7 8-6 6H9.3l-6-6 1.4-1.4 5.3 5.3 5.3-5.3z'/%3E%3C/svg%3E"); }
.wq-prompt textarea { padding-right: 96px; }
