/* Create Ukraine flag icon for menu option
   ---------------------------------------------------------------------*/
@media screen and (min-width: 768px) {
    #nav-primary > li a.icon-ua {
        margin-inline-start: 1rem;
    }
}

#nav-primary > li a.icon-ua::before {
    display: block;
    content: ' ';
    position: absolute;
    top: 0.9rem;
    left: 0;
    width: 1.2rem;
    height: 1.2rem;
    border-radius: 50%;
    background-image: linear-gradient(to bottom,#0057b7 50%,#ffd700 50%);
    box-shadow: 0 0 3px #ccc;
}

/* Colour Social Media icons in footer on hover 
   ---------------------------------------------------------------------*/
.follow-us a:hover svg path{
    fill: #18d671 !important;
}

/* Colour Ecolabel on hover
   ---------------------------------------------------------------------*/
#svg-ecolabel:hover .svg-eco-base {fill: #28486d;}
#svg-ecolabel:hover .svg-eco-starbox1 {fill: #b41e8e;}
#svg-ecolabel:hover :is(.svg-eco-starbox2, .svg-eco-txt_brusenv) {fill: #72bf44;}
#svg-ecolabel:hover .svg-eco-starbox3 {fill: #f9b996; opacity: 1;}
#svg-ecolabel:hover :is(.svg-eco-star1, .svg-eco-star2, .svg-eco-txt_date) {fill: #fff;}
#svg-ecolabel:hover .svg-eco-txt_ecoorg {fill: #ccc;}

/* Colour CoARA Badge on hover
   ---------------------------------------------------------------------*/
#svg-coara:hover .svg-coara-background {fill: #fff;}
#svg-coara:hover :is(.svg-coara-border, .svg-coara-logo) {fill: url(#coaraGradient);}
#svg-coara:hover :is(.svg-coara-txt_support, .svg-coara-txt_coara, .svg-coara-txt_coalition) {fill: #111;}

/* Create a list item with a > marker
   ---------------------------------------------------------------------*/
ul.list-info li {
    list-style-type: "\21AA\00A0\00A0";
}

/* Fix for margin on Pinned Content items
   ---------------------------------------------------------------------*/
.pinned-content {margin-block-end: 1.875rem;}

/* Fix 'More Parent' block after 'Pulse' block
   ---------------------------------------------------------------------*/
.pulse + .content--link-to-parent {
    margin-block-start: 8rem;
}

main:has(.content--link-to-parent) {
    padding-block-end: 5rem;
}

/* Hide 'Log in' notification for elevated content on private pages 
   where user is already logged in
   ---------------------------------------------------------------------*/
main:has(section.intro .intro__private) .content__content--private:not(:has(.private__type)) {
    display: none;
}

/* Styles to create a list of files with right-aligned date
   ---------------------------------------------------------------------*/
.file-list li {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
}

.file-list--date {
    font-size: 0.9rem;
    white-space: nowrap;
}

/* Add icons for file links
   ---------------------------------------------------------------------*/
.file-link--pdf::before {
    content: "";
    display: inline-block;
    height: 1em; width: 1em;
    background-image: url("/https/scienceeurope.org/media/4efb1xkc/icon-pdf.svg");
    background-size: contain;
    background-repeat: no-repeat;
    margin-inline-end: 0.5rem;
}

/* Improve header for 'Private content' blocks 
   ---------------------------------------------------------------------*/
.content__content--private:first-child {
    margin-block-start: 0;
}

.content__content--private::before {
    top: calc(-1.5625rem / 3);
    right: calc(-1.5625rem / 3);
}

.content__content .private__type {
    display: block;
    width: calc(100%; + 6.25rem);
    margin: -3.125rem -3.125rem 1.5625rem;
    background-image: none;
}

/* Fix for primary navigation overflowing
   ---------------------------------------------------------------------*/
 @media (min-width: 992px) and (max-width: 1337px) {
     #nav-primary > li a {
         padding-inline: 1.125rem;
     }
 }
 
  /* General Fixes
   ---------------------------------------------------------------------*/
span.small {font-size: 0.9rem;}
span.nowrap {white-space: nowrap;}

.content__content :is(ul, ol) + :is(ul, ol) {
    margin-block-start: 1rem;
}

ol, ul {
    margin-inline-start: 1em;
}

ul li, ol li {
    list-style-position: outside;
    margin-block-end: 0.5rem;
}

.pinned-content .card__private {
    transform: translateY(-1rem);
}