MediaWiki:Common.css: Difference between revisions

From Disaster Risk Gateway
No edit summary
No edit summary
 
(230 intermediate revisions by the same user not shown)
Line 1: Line 1:
/* ===== HIDE VECTOR/MF HEADERS & DEFAULT FOOTER LINKS ===== */
/* ===== IMPORT BARLOW ===== */
@import url('https://fonts.googleapis.com/css2?family=Barlow:wght@400;500;600;700&display=swap');
 
/* ===== GLOBAL FONT ===== */
html, body, #content, #mw-content-text, .drg-navbar-container, .mainpage-card, #drg-footer, .drg-footer-inner, .drg-column {
  font-family: 'Barlow', Arial, sans-serif;
}
 
/* ===== HIDE VECTOR PORTLETS & DEFAULT FOOTER LINKS ===== */
#p-logo,
#p-logo,
#mw-head, #mw-head-base,
#mw-head,
#mw-head-base,
#mw-navigation,
#mw-navigation,
#mw-panel,
#mw-panel,
Line 7: Line 16:
[id^="mw-mf-"],
[id^="mw-mf-"],
header.vector-header,
header.vector-header,
.vector-page-toolbar,
header.mw-body-header.vector-page-titlebar,
#footer-places,
#footer-places,
#footer-info-lastmod {
#footer-info-lastmod,
    display: none !important;
#p-views,
#p-cactions,
*#p-personal,
.vector-user-links,
#left-navigation,
#right-navigation {
  display: none !important;
}
 
/* ===== REMOVE ALL <hr> ===== */
hr {
  display: none !important;
}
}


/* ===== RESET & SPACING ===== */
/* ===== RESET & BASE STYLING ===== */
html { font-size:100%; margin:0; }
html {
  font-size: 100%;
  margin: 0;
  min-height: 100vh;
  background: #fff;
}
body {
body {
    margin:0;
  margin: 0;
    padding-top:60px !important; /* space for navbar */
  padding-top: 60px;
  background: #fff;
  color: #000;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
#content,
#mw-content-text {
  flex-grow: 1;
}
}
#content { margin-top:0 !important; }


/* ===== MYRIAD PALETTE ===== */
/* ===== MYRIAD COLOR PALETTE ===== */
:root {
:root {
    --myriad-blue:  #374CFF;
  --myriad-blue:  #374CFF;
    --myriad-purple: #8836EA;
  --myriad-dark:  #000091;
    --myriad-pink:  #DB20D2;
  --myriad-purple: #8836EA;
    --myriad-yellow:#FFCE00;
  --myriad-pink:  #DB20D2;
    --myriad-green:  #5AE09A;
  --myriad-yellow: #FFCE00;
  --myriad-green:  #5AE09A;
  --myriad-light:  #e5ccff;
}
}


/* ===== GLOBAL LINKS & BUTTONS ===== */
/* ===== GLOBAL LINKS & BUTTONS ===== */
a { color: var(--myriad-blue); text-decoration:none; }
a {
a:hover { text-decoration:underline; }
  color: var(--myriad-blue);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
.drg-button {
.drg-button {
    display:inline-block;
  display: inline-block;
    padding:.5em 1em;
  padding: .5em 1em;
    font-variant:small-caps;
  font-variant: small-caps;
    border-radius:7px;
  border-radius: 7px;
    background:var(--myriad-blue);
  background: var(--myriad-blue);
    color:#fff!important;
  color: #fff !important;
    transition:background 200ms;
  transition: background 200ms;
    text-decoration:none!important;
  text-decoration: none !important;
}
 
/* === Responsive logo === */
.logo-container {
  max-width: 43.75rem; /* 700px ÷ 16 */
  margin: 0 auto;
  padding: 0.3125rem;  /* 5px ÷ 16 */
  text-align: center;
}
 
.responsive-logo img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
}
}


/* ===== NAVBAR ===== */
/* ===== NAVBAR ===== */
#drg-navbar {
#drg-navbar {
    position:fixed; top:0; left:0; right:0;
  position: fixed;
    background:#fff;
  top: 0;
    border-bottom:1px solid #ddd;
  left: 0;
    z-index:10000;
  right: 0;
  background: #fff;
  border-bottom: 1px solid #ddd;
  z-index: 10000;
  overflow: visible !important;
}
}
.drg-navbar-container {
.drg-navbar-container {
    max-width:1200px; margin:0 auto;
  max-width: 1200px;
    display:flex; align-items:center;
  margin: 0 auto;
    justify-content:space-between;
  display: flex;
    padding:.75em 1em; gap:1em;
  align-items: center;
    flex-wrap:wrap;
  padding: .75em 1em;
  gap: 1em;
  flex-wrap: nowrap;
  overflow-x: visible !important;
  position: relative;
}
.drg-navbar-logo {
  display: flex;
  align-items: center;
  gap: .5em;
  flex-shrink: 0;
  margin-right: 2em;
}
}
/* Logo */
.drg-navbar-logo img {
.drg-navbar-logo img {
    height:40px; width:auto;
  height: 40px;
    display:block;
  width: auto;
  transition: transform 0.3s ease, box-shadow 0.3s ease;  
}
}


/* Nav links */
/* Hover glow effect in Myriad Green */
.drg-navbar-links {
.drg-navbar-logo:hover img {
    display:flex; gap:2em;
  transform: scale(1.05);
    flex-grow:1; justify-content:center;
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.8),
    flex-wrap:wrap;
              0 0 24px var(--myriad-green);
}
}
.drg-navbar-links a {
 
    position:relative; padding-bottom:2px;
.drg-navbar-logo .drg-logo-text {
    font-weight:500;
  font-weight: bold;
  font-size: 1.25rem;
  color: #000;
}
}
.drg-navbar-links a::after {
 
    content:""; position:absolute;
/* ===== NAVBAR LINK HOVER & ACTIVE ===== */
    bottom:0; left:0; height:2px; width:0;
#drg-navbar a {
    background:var(--myriad-blue);
  color: var(--myriad-blue);
    transition:width 200ms ease;
  transition: color 0.3s ease, transform 0.3s ease, text-shadow 0.3s ease;
}
}
.drg-navbar-links a:hover::after {
 
    width:100%;
#drg-navbar a:hover {
  color: var(--myriad-green);
  transform: scale(1.08);
  text-decoration: underline;
}
}


/* ===== SEARCH FORM ===== */
/* Hover & active for navbar dropdown*/
.drg-search {
#drg-navbar .drg-nav > span,
    display:flex; align-items:center;
#drg-navbar .drg-user > span,
#drg-navbar .drg-tools > span {
  color: var(--myriad-blue);
  transition: color 0.3s ease, transform 0.3s ease, text-shadow 0.3s ease;
}
}
.drg-search input[type="search"] {
 
    padding:.4em .6em;
#drg-navbar .drg-nav:hover > span,
    border:1px solid #ccc;
#drg-navbar .drg-user:hover > span,
    border-radius:4px 0 0 4px;
#drg-navbar .drg-tools:hover > span {
    width:200px;
  color: var(--myriad-green);
    background-image:none!important;
  transform: scale(1.08);
  text-decoration: underline;
}
}
.drg-search input[type="submit"] {
 
    padding:.4em 1em;
/* Active page link stays green */
    border:none;
#drg-navbar a.current,
    border-radius:0 4px 4px 0;
#drg-navbar a.active,
    background:var(--myriad-blue);
#drg-navbar .selected a {
    color:#fff;
  color: var(--myriad-green);
    cursor:pointer;
  font-weight: 600;  
  text-decoration: underline;
}
}


/* ===== USER DROPDOWN ===== */
/* ===== NAVIGATION DROPDOWN ===== */
.drg-nav {
  position: relative;
  cursor: pointer;
  z-index: 10002;
}
.drg-nav > span {
  font-weight: 500;
  padding: .4em .6em;
}
.drg-nav > span::after {
  content: "▾";
  margin-left: .3em;
  font-size: .75em;
}
.drg-nav-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
  list-style: none;
  margin: .2em 0 0;
  padding: 0;
  min-width: 160px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  z-index: 9999 !important;
}
.drg-nav-dropdown li a {
  display: block;
  padding: .5em 1em;
  color: #000;
  text-decoration: none;
  white-space: nowrap;
}
.drg-nav-dropdown li a:hover {
  background: #f5f5f5;
}
.drg-nav:hover .drg-nav-dropdown {
  display: block !important;
}
.flat-link {
  font-weight: 500;
  margin-right: 1.5em;
}
.drg-navbar-actions {
.drg-navbar-actions {
    display:flex; align-items:center;
  display: flex;
    gap:1em; position:relative;
  align-items: center;
  gap: 1em;
  margin-left: auto;
  flex-wrap: nowrap;
}
 
/* ===== USER & TOOLS DROPDOWNS ===== */
.drg-user, .drg-tools {
  position: relative;
  cursor: pointer;
}
.drg-user > span, .drg-tools > span {
  padding: .4em .6em;
}
.drg-user > span::after, .drg-tools > span::after {
  content: "▾";
  margin-left: .3em;
  font-size: .75em;
}
}
.drg-user {
.drg-user-dropdown,
    position:relative; cursor:pointer;
.drg-tools-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
  list-style: none;
  margin: .2em 0 0;
  padding: 0;
  min-width: 160px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  z-index: 9999 !important;
}
}
.drg-user > span {
.drg-user-dropdown li a,
    padding:.4em .6em; display:inline-block;
.drg-tools-dropdown li a {
  display: block;
  padding: .5em 1em;
  color: #000;
  text-decoration: none;
  white-space: nowrap;
}
}
.drg-user-dropdown {
.drg-user-dropdown li a:hover,
    display:none;
.drg-tools-dropdown li a:hover {
    position:absolute; top:100%; right:0;
  background: #f5f5f5;
    background:#fff; border:1px solid #ccc;
    border-radius:4px; list-style:none;
    margin:.2em 0 0; padding:0;
    min-width:160px;
    box-shadow:0 2px 6px rgba(0,0,0,0.1);
    z-index:10001;
}
}
.drg-user:hover .drg-user-dropdown,
.drg-user:hover .drg-user-dropdown,
.drg-user-dropdown:hover {
.drg-tools:hover .drg-tools-dropdown {
    display:block;
  display: block !important;
}
 
/* ===== MAIN PAGE FLIP CARDS ===== */
.mainpage-cards {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem;
  margin: 3rem auto;
  max-width: 1200px;
  padding: 0 1rem;
}
 
/* Card container */
.mainpage-card {
  flex: 0 1 220px;
  max-width: 220px;
  height: 220px;
  perspective: 1000px;
  text-decoration: none;
  color: inherit;
  display: block;
  overflow: visible;
}
}
.drg-user-dropdown li {
 
    border-bottom:1px solid #eee;
/* Inner wrapper for flip effect */
.card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.6s;
  transform-style: preserve-3d;
}
}
.drg-user-dropdown li:last-child {
 
    border-bottom:none;
/* Flip on hover */
.mainpage-card:hover .card-inner {
  transform: rotateY(180deg);
}
}
.drg-user-dropdown li a {
 
    display:block; padding:.5em 1em;
/* Front and back faces */
    color:#000; white-space:nowrap;
.card-front, .card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 1rem;
  box-sizing: border-box;
  box-shadow: 0 6px 18px rgba(0,0,0,0.08);
  overflow: hidden;
}
}
.drg-user-dropdown li a:hover {
 
    background:#f5f5f5;
/* Front face */
.card-front {
  background: #fff;
  color: var(--myriad-blue);
  text-align: center;
}
}


/* ===== REMOVE EXTRA HR ABOVE OUR FOOTER ===== */
/* Remove MediaWiki wrapper box around images */
hr + #drg-footer {
.card-front .thumb,
    display: none !important;
.card-front .mw-thumbnail {
  background: none !important;
  border: none !important;
  padding: 0 !important;
  margin: 0 auto !important;
  width: auto !important;
  box-shadow: none !important;
}
}


/* ===== DRG FOOTER ===== */
/* Image */
.card-front img {
  background: none !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0;
  display: block;
  margin: 0 auto;
  max-width: 120px;
  max-height: 50%;
  width: auto;
  height: auto;
}
 
/* Remove code block grey background*/
.mainpage-card .card-front pre,
.mainpage-card .card-front code,
.mainpage-card .card-front .mw-code {
    display: inline !important;
    font: inherit !important;
    line-height: inherit !important;
    margin: 0 !important;
    padding: 0 !important;
    background: none !important;
    border: none !important;
    color: inherit !important;
    white-space: normal !important;
    vertical-align: baseline !important;
}
 
/* Front titles */
.card-front h3 {
  font-size: 1.25rem;
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-weight: 600;
}
 
/* Back face */
.card-back {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  transform: rotateY(180deg);
  text-align: center;
  font-size: 0.95rem;
  line-height: 1.4;
  display: flex;
  justify-content: center;
  align-items: center;
}
 
/* Full-size back button */
.card-back a {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  text-decoration: none;
  color: #fff;
  background-color: var(--myriad-blue);
  border-radius: 16px;
  font-weight: 600;
  font-size: 1.1rem;
  transition: background 0.3s, transform 0.3s;
  padding: 1.5rem;
  box-sizing: border-box;
  text-align: center;
}
 
.card-back a:hover {
  background-color: var(--myriad-pink);
  transform: scale(1.02);
}
 
/* Hover animation for front */
.mainpage-card:hover .card-front {
  transform: scale(1.03);
  box-shadow: 0 12px 25px rgba(0,0,0,0.15);
  border: 2px solid var(--myriad-blue);
  background: #fff;
}
 
/* Responsive */
@media (max-width: 768px) {
  .mainpage-cards {
    gap: 1rem;
    padding: 0 1rem;
  }
  .mainpage-card {
    flex: 1 1 90%;
    max-width: 90%;
  }
}
 
/* ===== REMOVE DEFAULT MEDIAWIKI FOOTER BORDER ===== */
.mw-footer {
    border-top: none;
    padding: 0;
    padding: 0.75em;
}
 
/* ===== FOOTER STYLES ===== */
#drg-footer {
#drg-footer {
    border-top:1px solid #ccc;
  background: linear-gradient(to top, #374cff 0%, #db20d2 80%, #ffffff 100%);
    background:#fff;
  color: #fff;
    padding-top:2em;
  padding: 10em 0; /* top/bottom padding for the DRG footer */
    font-family:sans-serif;
  margin: 0;
    color:#000;
  box-sizing: border-box;
    font-size:1.1rem;
  overflow: hidden;
    margin:1em 0 2em;
  position: relative;
  width: 100vw;
  left: 50%;
  margin-left: -50vw;
}
}
.drg-columns {
 
    display:flex; justify-content:center;
/* ===== Override default MediaWiki footer container ===== */
    align-items:stretch; gap:2em;
.mw-footer-container {
    max-width:1200px; margin:0 auto;
  padding-top: 0;
    flex-wrap:nowrap;
  padding-bottom: 0;
}
}
.drg-column {
 
    flex:1 1 33%; display:flex;
.mw-footer-container #drg-footer {
    flex-direction:column; gap:1em;
  margin-top: 0 !important;
    min-width:0;
  margin-bottom: 0 !important;
}
}
.drg-column-left {
 
    align-items:flex-end; text-align:left;
/* Remove default MediaWiki footer border */
    padding-right:1.5em;
.mw-footer {
  border-top: none;
  background: transparent;  
}
}
.drg-column-right {
 
    align-items:flex-start; text-align:right;
/* Hide the default footer icons */
    padding-left:1.5em;
#footer-icons {
  display: none;
}
}
.drg-column-left a,
 
.drg-column-right a {
/* ===== INNER FOOTER CONTENT ===== */
    color:#000; text-decoration:none;
.drg-footer-inner {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}
}
.drg-column-left a:hover,
 
.drg-column-right a:hover {
.drg-columns {
    text-decoration:underline;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2em;
  text-align: center;
}
}
.drg-divider {
 
    width:1px; background:#666;
.drg-column {
    opacity:0.4; align-self:stretch;
  flex: 0 1 calc(33.333% - 2em);
  display: flex;
  flex-direction: column;
  gap: 1em;
  align-items: center;
  box-sizing: border-box;
}
}
.drg-column-center {
 
    text-align:center; align-items:center;
.drg-column-left,
    justify-content:center;
.drg-column-center,
}
.drg-column-right {
.drg-eu-flag {
  align-items: center;
    margin-bottom:1em;
}
}
.drg-eu-flag img {
.drg-eu-flag img {
    height:4em; width:auto; max-width:100%;
  max-height: 4em !important;
  width: auto !important;
  display: block;
  margin: 0 auto;
  border: 1px solid #fff;  
  box-sizing: border-box;
}
}
.drg-eu-text {
.drg-eu-text {
    font-weight:bold; line-height:1.5;
  font-weight: bold;
    font-size:1em; max-width:400px;
  color: #fff;
    text-align:center; color:#000;
  line-height: 1.5;
  font-size: 1em;
  max-width: 400px;
  text-align: center;
}
}
.drg-disclaimer {
 
    max-width:900px; margin:2em auto 0;
.drg-disclaimer-wrapper {
    padding:1em 0 0; border-top:1px solid #eee;
  margin-top: 2em;
    font-size:0.9em; color:#666;
  text-align: center;
    text-align:center;
  font-size: 0.9rem;
  color: rgba(255,255,255,0.8);
}
}
.drg-disclaimer a {
.drg-disclaimer a {
    color:var(--myriad-blue); text-decoration:underline;
  color: #fff;
  text-decoration: underline;
}
 
/* ===== FOOTER LINKS - WHITE WITH HOVER POP ===== */
#drg-footer a {
  color: #fff; /* white links */
  text-decoration: none;
  transition: color 0.3s ease, transform 0.3s ease, text-shadow 0.3s ease;
}
 
#drg-footer a:hover {
  color: var(--myriad-green);
  transform: scale(1.08); /* pop */
  text-decoration: underline;
}
}


/* ===== MOBILE ===== */
@media (max-width: 768px) {
@media (max-width:768px) {
  .drg-columns {
    .drg-navbar-container {
    flex-direction: column;
        flex-direction:column; align-items:stretch;
     align-items: center;
    }
     gap: 1.5em;
    .drg-navbar-links {
  }
        justify-content:center;
  .drg-column {
     }
    flex: 1 1 100%;
    .drg-columns {
     max-width: 500px;
        flex-direction:column; align-items:center;
  }
     }
    .drg-divider {
        display:none;
    }
    .drg-column {
        width:100%; text-align:center!important;
        align-items:center!important; padding:0!important;
     }
    .drg-eu-text {
        max-width:90%;
    }
}
}

Latest revision as of 09:53, 15 August 2025

/* ===== IMPORT BARLOW ===== */
@import url('https://fonts.googleapis.com/css2?family=Barlow:wght@400;500;600;700&display=swap');

/* ===== GLOBAL FONT ===== */
html, body, #content, #mw-content-text, .drg-navbar-container, .mainpage-card, #drg-footer, .drg-footer-inner, .drg-column {
  font-family: 'Barlow', Arial, sans-serif;
}

/* ===== HIDE VECTOR PORTLETS & DEFAULT FOOTER LINKS ===== */
#p-logo,
#mw-head,
#mw-head-base,
#mw-navigation,
#mw-panel,
#mw-mf-page-header,
[id^="mw-mf-"],
header.vector-header,
.vector-page-toolbar,
header.mw-body-header.vector-page-titlebar,
#footer-places,
#footer-info-lastmod,
#p-views,
#p-cactions,
*#p-personal,
.vector-user-links,
#left-navigation,
#right-navigation {
  display: none !important;
}

/* ===== REMOVE ALL <hr> ===== */
hr {
  display: none !important;
}

/* ===== RESET & BASE STYLING ===== */
html {
  font-size: 100%;
  margin: 0;
  min-height: 100vh;
  background: #fff;
}
body {
  margin: 0;
  padding-top: 60px;
  background: #fff;
  color: #000;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
#content,
#mw-content-text {
  flex-grow: 1;
}

/* ===== MYRIAD COLOR PALETTE ===== */
:root {
  --myriad-blue:   #374CFF;
  --myriad-dark:   #000091;
  --myriad-purple: #8836EA;
  --myriad-pink:   #DB20D2;
  --myriad-yellow: #FFCE00;
  --myriad-green:  #5AE09A;
  --myriad-light:  #e5ccff;
}

/* ===== GLOBAL LINKS & BUTTONS ===== */
a {
  color: var(--myriad-blue);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
.drg-button {
  display: inline-block;
  padding: .5em 1em;
  font-variant: small-caps;
  border-radius: 7px;
  background: var(--myriad-blue);
  color: #fff !important;
  transition: background 200ms;
  text-decoration: none !important;
}

/* === Responsive logo === */
.logo-container {
  max-width: 43.75rem; /* 700px ÷ 16 */
  margin: 0 auto;
  padding: 0.3125rem;  /* 5px ÷ 16 */
  text-align: center;
}

.responsive-logo img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
}

/* ===== NAVBAR ===== */
#drg-navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: #fff;
  border-bottom: 1px solid #ddd;
  z-index: 10000;
  overflow: visible !important;
}
.drg-navbar-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  padding: .75em 1em;
  gap: 1em;
  flex-wrap: nowrap;
  overflow-x: visible !important;
  position: relative;
}
.drg-navbar-logo {
  display: flex;
  align-items: center;
  gap: .5em;
  flex-shrink: 0;
  margin-right: 2em;
}
.drg-navbar-logo img {
  height: 40px;
  width: auto;
  transition: transform 0.3s ease, box-shadow 0.3s ease; 
}

/* Hover glow effect in Myriad Green */
.drg-navbar-logo:hover img {
  transform: scale(1.05);
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.8),
              0 0 24px var(--myriad-green);
}

.drg-navbar-logo .drg-logo-text {
  font-weight: bold;
  font-size: 1.25rem;
  color: #000;
}

/* ===== NAVBAR LINK HOVER & ACTIVE ===== */
#drg-navbar a {
  color: var(--myriad-blue);
  transition: color 0.3s ease, transform 0.3s ease, text-shadow 0.3s ease;
}

#drg-navbar a:hover {
  color: var(--myriad-green);
  transform: scale(1.08); 
  text-decoration: underline;
}

/* Hover & active for navbar dropdown*/
#drg-navbar .drg-nav > span,
#drg-navbar .drg-user > span,
#drg-navbar .drg-tools > span {
  color: var(--myriad-blue);
  transition: color 0.3s ease, transform 0.3s ease, text-shadow 0.3s ease;
}

#drg-navbar .drg-nav:hover > span,
#drg-navbar .drg-user:hover > span,
#drg-navbar .drg-tools:hover > span {
  color: var(--myriad-green);
  transform: scale(1.08);
  text-decoration: underline;
}

/* Active page link stays green */
#drg-navbar a.current,
#drg-navbar a.active,
#drg-navbar .selected a {
  color: var(--myriad-green);
  font-weight: 600; 
  text-decoration: underline;
}

/* ===== NAVIGATION DROPDOWN ===== */
.drg-nav {
  position: relative;
  cursor: pointer;
  z-index: 10002;
}
.drg-nav > span {
  font-weight: 500;
  padding: .4em .6em;
}
.drg-nav > span::after {
  content: "▾";
  margin-left: .3em;
  font-size: .75em;
}
.drg-nav-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
  list-style: none;
  margin: .2em 0 0;
  padding: 0;
  min-width: 160px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  z-index: 9999 !important;
}
.drg-nav-dropdown li a {
  display: block;
  padding: .5em 1em;
  color: #000;
  text-decoration: none;
  white-space: nowrap;
}
.drg-nav-dropdown li a:hover {
  background: #f5f5f5;
}
.drg-nav:hover .drg-nav-dropdown {
  display: block !important;
}
.flat-link {
  font-weight: 500;
  margin-right: 1.5em;
}
.drg-navbar-actions {
  display: flex;
  align-items: center;
  gap: 1em;
  margin-left: auto;
  flex-wrap: nowrap;
}

/* ===== USER & TOOLS DROPDOWNS ===== */
.drg-user, .drg-tools {
  position: relative;
  cursor: pointer;
}
.drg-user > span, .drg-tools > span {
  padding: .4em .6em;
}
.drg-user > span::after, .drg-tools > span::after {
  content: "▾";
  margin-left: .3em;
  font-size: .75em;
}
.drg-user-dropdown,
.drg-tools-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
  list-style: none;
  margin: .2em 0 0;
  padding: 0;
  min-width: 160px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  z-index: 9999 !important;
}
.drg-user-dropdown li a,
.drg-tools-dropdown li a {
  display: block;
  padding: .5em 1em;
  color: #000;
  text-decoration: none;
  white-space: nowrap;
}
.drg-user-dropdown li a:hover,
.drg-tools-dropdown li a:hover {
  background: #f5f5f5;
}
.drg-user:hover .drg-user-dropdown,
.drg-tools:hover .drg-tools-dropdown {
  display: block !important;
}

/* ===== MAIN PAGE FLIP CARDS ===== */
.mainpage-cards {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem;
  margin: 3rem auto;
  max-width: 1200px;
  padding: 0 1rem;
}

/* Card container */
.mainpage-card {
  flex: 0 1 220px;
  max-width: 220px;
  height: 220px;
  perspective: 1000px;
  text-decoration: none;
  color: inherit;
  display: block;
  overflow: visible;
}

/* Inner wrapper for flip effect */
.card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.6s;
  transform-style: preserve-3d;
}

/* Flip on hover */
.mainpage-card:hover .card-inner {
  transform: rotateY(180deg);
}

/* Front and back faces */
.card-front, .card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 1rem;
  box-sizing: border-box;
  box-shadow: 0 6px 18px rgba(0,0,0,0.08);
  overflow: hidden;
}

/* Front face */
.card-front {
  background: #fff;
  color: var(--myriad-blue);
  text-align: center;
}

/* Remove MediaWiki wrapper box around images */
.card-front .thumb,
.card-front .mw-thumbnail {
  background: none !important;
  border: none !important;
  padding: 0 !important;
  margin: 0 auto !important;
  width: auto !important;
  box-shadow: none !important;
}

/* Image */
.card-front img {
  background: none !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0;
  display: block;
  margin: 0 auto;
  max-width: 120px;
  max-height: 50%;
  width: auto;
  height: auto;
}

/* Remove code block grey background*/
.mainpage-card .card-front pre,
.mainpage-card .card-front code,
.mainpage-card .card-front .mw-code {
    display: inline !important;
    font: inherit !important;
    line-height: inherit !important;
    margin: 0 !important;
    padding: 0 !important;
    background: none !important;
    border: none !important;
    color: inherit !important;
    white-space: normal !important;
    vertical-align: baseline !important;
}

/* Front titles */
.card-front h3 {
  font-size: 1.25rem;
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-weight: 600;
}

/* Back face */
.card-back {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  transform: rotateY(180deg);
  text-align: center;
  font-size: 0.95rem;
  line-height: 1.4;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Full-size back button */
.card-back a {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  text-decoration: none;
  color: #fff;
  background-color: var(--myriad-blue);
  border-radius: 16px;
  font-weight: 600;
  font-size: 1.1rem;
  transition: background 0.3s, transform 0.3s;
  padding: 1.5rem;
  box-sizing: border-box;
  text-align: center;
}

.card-back a:hover {
  background-color: var(--myriad-pink);
  transform: scale(1.02);
}

/* Hover animation for front */
.mainpage-card:hover .card-front {
  transform: scale(1.03);
  box-shadow: 0 12px 25px rgba(0,0,0,0.15);
  border: 2px solid var(--myriad-blue);
  background: #fff;
}

/* Responsive */
@media (max-width: 768px) {
  .mainpage-cards {
    gap: 1rem;
    padding: 0 1rem;
  }
  .mainpage-card {
    flex: 1 1 90%;
    max-width: 90%;
  }
}

/* ===== REMOVE DEFAULT MEDIAWIKI FOOTER BORDER ===== */
.mw-footer {
    border-top: none; 
    padding: 0;
    padding: 0.75em;
}

/* ===== FOOTER STYLES ===== */
#drg-footer {
  background: linear-gradient(to top, #374cff 0%, #db20d2 80%, #ffffff 100%);
  color: #fff;
  padding: 10em 0; /* top/bottom padding for the DRG footer */
  margin: 0;
  box-sizing: border-box;
  overflow: hidden;
  position: relative;
  width: 100vw;
  left: 50%;
  margin-left: -50vw;
}

/* ===== Override default MediaWiki footer container ===== */
.mw-footer-container {
  padding-top: 0;
  padding-bottom: 0;
}

.mw-footer-container #drg-footer {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

/* Remove default MediaWiki footer border */
.mw-footer {
  border-top: none;
  background: transparent; 
}

/* Hide the default footer icons */
#footer-icons {
  display: none;
}

/* ===== INNER FOOTER CONTENT ===== */
.drg-footer-inner {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.drg-columns {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2em;
  text-align: center;
}

.drg-column {
  flex: 0 1 calc(33.333% - 2em);
  display: flex;
  flex-direction: column;
  gap: 1em;
  align-items: center;
  box-sizing: border-box;
}

.drg-column-left,
.drg-column-center,
.drg-column-right {
  align-items: center;
}

.drg-eu-flag img {
  max-height: 4em !important;
  width: auto !important;
  display: block;
  margin: 0 auto;
  border: 1px solid #fff;   
  box-sizing: border-box;
}

.drg-eu-text {
  font-weight: bold;
  color: #fff;
  line-height: 1.5;
  font-size: 1em;
  max-width: 400px;
  text-align: center;
}

.drg-disclaimer-wrapper {
  margin-top: 2em;
  text-align: center;
  font-size: 0.9rem;
  color: rgba(255,255,255,0.8);
}

.drg-disclaimer a {
  color: #fff;
  text-decoration: underline;
}

/* ===== FOOTER LINKS - WHITE WITH HOVER POP ===== */
#drg-footer a {
  color: #fff; /* white links */
  text-decoration: none;
  transition: color 0.3s ease, transform 0.3s ease, text-shadow 0.3s ease;
}

#drg-footer a:hover {
  color: var(--myriad-green); 
  transform: scale(1.08); /* pop */
  text-decoration: underline;
}

@media (max-width: 768px) {
  .drg-columns {
    flex-direction: column;
    align-items: center;
    gap: 1.5em;
  }
  .drg-column {
    flex: 1 1 100%;
    max-width: 500px;
  }
}