/* Brand tokens */
:root {
    --color-rpt-primary: rgb(0, 120, 182);   /* #0078b6, darkened from #0086cf for WCAG AA contrast (4.81:1 vs 3.95:1) */
    --color-rpt-secondary: rgb(0, 77, 108);  /* #004c6c */
    --color-rpt-dark: rgb(64, 64, 64);       /* #404040 */
    --color-rpt-white: #ffffff;
    --radius-card: 12px;
    --shadow-card: 0 1px 3px rgba(0, 76, 108, 0.15);
}

/* Base link/text color overrides (minima defaults to #2a7ae2) */
a {
    color: var(--color-rpt-primary);
}
a:visited {
    color: var(--color-rpt-secondary);
}
/* Content links must not rely on color alone (WCAG 1.4.1) */
main.page-content a:not(.mock-button) {
    text-decoration: underline;
}
main.page-content .tag-list a {
    text-decoration: none;
}
body {
    color: var(--color-rpt-dark);
}

/* Animations */
@keyframes spin {
    from { transform: rotateY(0deg); }
    to { transform: rotateY(360deg); }
}

/* Buttons, site-wide */
button, .mock-button {
    border-radius: 8px;
    cursor: pointer;
}
button {
    background-color: var(--color-rpt-primary);
    color: var(--color-rpt-white);
    border: none;
    padding: 0.5em 1em;
}
button:hover {
    background-color: var(--color-rpt-secondary);
}

/* Link buttons: outlined, not filled (filled blue-on-white was hard to read) */
.mock-button {
    background-color: transparent;
    color: var(--color-rpt-primary);
    border: 2px solid var(--color-rpt-primary);
    padding: calc(0.5em - 2px) calc(1em - 2px);
}
.mock-button:hover,
.mock-button:focus {
    background-color: var(--color-rpt-primary);
    color: var(--color-rpt-white);
}

/* Header / footer */
header.site-header {
    background-color: var(--color-rpt-primary);
    border-bottom: none;
}
header.site-header .site-title,
header.site-header .site-title:visited,
header.site-header .site-nav .page-link {
    color: var(--color-rpt-white);
}
.site-logo {
    padding: 4px 12px;
}
header.site-header .nav-dropdown[open] > summary {
    color: var(--color-rpt-white);
    text-decoration: underline;
}
header.site-header .nav-dropdown-menu a {
    color: var(--color-rpt-dark);
}
footer.site-footer {
    background-color: var(--color-rpt-secondary);
    color: var(--color-rpt-white);
    border-top: none;
}
footer.site-footer a,
footer.site-footer .footer-heading,
footer.site-footer .footer-col-wrapper {
    color: var(--color-rpt-white);
}
footer.site-footer .svg-icon {
    fill: var(--color-rpt-white);
}
footer.site-footer .social-media-list .fa-soundcloud,
footer.site-footer .social-media-list .fa-envelope {
    margin-right: 5px;
}
footer.site-footer a:hover {
    text-decoration: underline;
}
footer.site-footer .footer-author {
    margin: 0 0 10px;
    font-weight: 600;
}

/* Footer layout: mobile-first stack, grid from 600px up */
footer.site-footer .footer-col-wrapper {
    margin-left: 0;
    display: flex;
    flex-direction: column;
    gap: 25px;
}
footer.site-footer .footer-col {
    float: none;
    width: 100%;
    margin-bottom: 0;
    padding-left: 0;
}
footer.site-footer .footer-col-2 img {
    display: block;
}
@media screen and (min-width: 600px) {
    footer.site-footer .footer-col-wrapper {
        display: grid;
        grid-template-columns: 1fr 1fr;
        column-gap: 40px;
        row-gap: 25px;
        align-items: start;
    }
}
.site-header .wrapper {
    display: flex;
    justify-content: space-evenly;
}
.site-nav {
    margin: auto;
    display: flex;
    align-items: center;
}
.site-nav-links {
    display: flex;
    align-items: center;
    gap: 1.5em;
    list-style: none;
    margin: 0;
    padding: 0;
}
.site-nav-links > li {
    position: relative;
}
.nav-dropdown > summary {
    cursor: pointer;
    list-style: none;
}
.nav-dropdown > summary::-webkit-details-marker {
    display: none;
}
.nav-dropdown[open] > summary {
    color: var(--color-rpt-primary);
}
.nav-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 1001;
    list-style: none;
    margin: 0.5em 0 0;
    padding: 0.5em 0;
    min-width: max-content;
    background-color: var(--color-rpt-white);
    border: 1px solid #e8e8e8;
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
}
.nav-dropdown-menu li {
    padding: 0.25em 1em;
}
.nav-dropdown-menu a {
    white-space: nowrap;
}

@media screen and (max-width: 600px) {
    header.site-header .site-nav {
        position: static;
        background-color: transparent;
        border: 0;
        text-align: left;
    }
    .site-nav-links {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
    }
    .nav-dropdown-menu {
        position: static;
        border: 0;
        border-radius: 0;
        padding-left: 1em;
    }
}

.sponsor {
    display: grid;
    grid-template-columns: 1fr 4fr;
    grid-column-gap: 1em;
}
.sponsor .logo {
    align-self: center;
}

/* index.html JC list */
.jc-list {
    margin-bottom: 0;
}

/* Person.html */
.person {
    position: relative;
    background-color: #eaf6fc;
    padding: 2px;
    white-space: pre-wrap;
}
.person-social {
    display: none;
}
.person:hover .person-social {
    position: absolute;
    width: 100%;
    left: 50%;
    top: calc(-100% - .5em);
    display: flex;
    flex-direction: row;
    justify-content: space-evenly;
    background-color: #eaf6fc;
    border-top-left-radius: 25%;
    border-top-right-radius: 25%;
    padding-top: .5em;
    padding-bottom: 2px;
    min-width: min-content;
    transform: translateX(-50%);
}
.person-social i, .person-social svg {
    font-size: 1.2em;
    padding: .2em;
}

/* Image.html */
.image {
    max-width: 100%;
    margin: auto;
    transition: all 400ms;
    text-align: center;
}
.fig a * {
    max-width: 100%;
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
}

/* Tags */
.tag-list ul {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
    list-style: none;
}
.tag-list li {
    padding: .25em .5em;
    background-color: #eaf6fc;
    border-radius: .5em;
    margin: .33em;
    font-size: .8em;
    box-shadow: var(--shadow-card);
}
.tag-list li:hover {
    background-color: #d7eefd;
}
.tag-list a:hover {
    text-decoration: none;
}

/* Journal club showcase cards */
.jc-showcase {
    margin-top: 2em;
}
.jc-showcase:not(.placeholder) {
    display: flex;
    flex-direction: column;
    gap: 1em;
    background-color: var(--color-rpt-white);
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
    padding: 1.5em;
}
.jc-body {
    width: 100%;
}
.jc-info {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: space-evenly;
    width: 100%;
}
.jc-details {
    display: flex;
    flex-direction: column;
}
.jc-organisers {
    display: flex;
    flex-direction: column;
}

@media screen and (min-width: 800px) {
    .jc-showcase:not(.placeholder) {
        flex-direction: row;
        justify-content: space-between;
    }
    .jc-body {
        width: 60%;
    }
    .jc-info {
        flex-direction: column;
        justify-content: center;
        width: 30%;
        min-height: 100%;
    }
}

/* Map container */
#map {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-card);
    overflow: hidden;
}

/* Biohazard / notice callouts */
.biohazard {
    padding: 1em;
    text-align: justify;
    border-radius: var(--radius-card);
    border: 2px solid var(--color-rpt-secondary);
}
.biohazard h3 {
    background-color: #ffe8a3;
    text-align: center;
}
.biohazard:not(:hover):not(:focus) h3 {
    margin: 0;
}
.biohazard a {
    font-weight: bold;
}
.biohazard:not(:hover):not(:focus) p {
    display: none;
}
p.elipsis {
    display: none;
    margin-bottom: 0;
}
.biohazard:not(:hover):not(:focus) p.elipsis {
    display: block;
    text-align: center;
}

/* Homepage CTA buttons */
.cta-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75em;
}

/* Homepage JC teaser cards */
.jc-teaser-grid {
    display: flex;
    flex-direction: column;
    gap: 1em;
    margin-bottom: 1em;
}
.jc-teaser-card {
    background-color: var(--color-rpt-white);
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
    padding: 1em 1.25em;
}
.jc-teaser-card h4 {
    margin: 0.25em 0;
}
.jc-teaser-label {
    font-size: 0.75em;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-rpt-primary);
    font-weight: 700;
}
@media screen and (min-width: 600px) {
    .jc-teaser-grid {
        flex-direction: row;
    }
    .jc-teaser-card {
        flex: 1;
    }
}
