
/* Graphics */
.graphics {
    grid-column: 1/-1;
    margin-bottom: 6rem;
}

.graphics__nav {
    
}

.graphics__nav li {
    padding: 0.05rem 0;
}

.graphics__nav__header {
    border-bottom: 1px solid black;
    padding: 0.2rem 0 0.5rem !important;
    display: flex;
    align-items: center;
    position: sticky;
    top: var(--headerHeight);
    width: 100%;
    background-color: rgba(249, 249, 249, 1);
}

.graphics__nav__header:hover .bullet.outline {
    border: 1.5px solid #888888;
}

.graphics__nav__header:not(:last-child) { 
    margin-bottom: 0.4rem;
}

.graphics__nav__header .bullet {
    margin-right: 0.75rem;
}

ul:not(:first-of-type) .graphics__nav__header {
    margin-top: 1em;
}

.graphics__nav__header button::before {
    width: 1rem;
    height: 1rem;
    content: "";
    background-color: black;
    border-radius: 2rem;
}

/* Mobile */
@media only screen and (max-width: 64rem) {
    .graphics__nav ul li {
        display: none;
    }

    .graphics__nav ul.active {
        padding-bottom: 0.5rem;
        margin-bottom: 0.5rem;
        border-bottom: 1px solid black;
    }
    .graphics__nav ul.active li {
        display: block;
    }
}

/* Visualization */
.graphics__visualization {
    position: relative;
    height: 70vh;
    max-height: 70vh;
    margin-top: 2rem;
}

/* Mobile */
@media only screen and (max-width: 64rem) {
    .graphics__visualization {
        margin-top: 4rem;
        width: calc(100% - 2.5rem);
        margin-left: 2.5rem;
    }
}

.graphics__visualization__meter {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    z-index: -1;
}

.line {
    display: flex;
    align-items: center;
    position: relative;
}

.line__value {
    position: absolute;
    left: calc(-100vw/16 + 0.5rem);
    top: 50%;
    translate: 0 -50%;
    text-align: right;
}


.graphics__visualization__bar {
    display: flex;
    justify-content: space-around;
    flex-direction: row-reverse;
    margin-top: auto;
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
}

.bar {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    margin-bottom: 1px;
    width: calc(100vw/16);
    flex-grow: 1;
}

.bar__count {
    background-color: rgba(249, 249, 249, 1);;
    padding: 0.1rem 0.3rem;
}

.bar__section {
    width: 2.25rem;
    height: var(--sectionHeight, 0);
    transition: 500ms ease;
}

/* Mobile */
@media only screen and (max-width: 64rem) {
    .bar__section {
        width: 2rem;
    }
    .graphics__visualization__bar {
        left: 2rem

    }
    .line__value {
        left: -2.5rem;
    }
}

.bar__section.publications {
    background-color: black;
}

.bar__section.activities {
    background-color: #D9D9D9;
}

.bar__section.projects {
    background-color: #888888;
}

.bar__year {
    position: absolute;
    bottom: -1.5rem;
}



/* Desktop */
@media only screen and (min-width: 64rem) {
    .graphics__nav {
        grid-column: 1/5;
        height: fit-content;
    }
    
    .graphics__nav__header:not(:nth-child(1), :nth-child(2)) {
        margin-top: 1rem;
    }

    .graphics__visualization {
        margin-top: 1.75rem;
        grid-column: 8/-1;
        position: sticky;
        top: 15vh;
    }
}

/* Table */

.table {
    border-collapse: collapse;
    width: 100%;
}

.table.sticky {
    position: sticky;
    top: var(--headerHeight);
    background-color: rgba(249, 249, 249, 1);
    z-index: 10;
}

.table__row {
    display: flex;
    flex-direction: row-reverse;
    width: 100%;
}

.table__row.sticky {
    position: sticky;
    top: calc(var(--headerHeight) + 2rem);
    background-color: rgba(249, 249, 249, 1);
    align-self: flex-start;
}

table tr * {
    transition: color 300ms, background-color 300ms;
}

table tr:hover * {
    color: black;
    background-color: rgb(240, 240, 240);
}

.table td,
.table th {
    text-align: center;
    border-bottom: 1px solid black;
    padding: 0.35rem 0 0.3rem;
}

.table td {
    color: gray;
}

.table td:last-child,
.table th:last-child {
    text-align: left;
}

/* Mobile */
@media only screen and (max-width: 64rem) {

    .table__row {
        flex-wrap: wrap;
    }

    .table__row td,
    .table__row th {
        order: 1;
        width: calc(100%/6);
        padding-top: 0;
    }

    .table__row__label {
        width: 100% !important;
        padding-bottom: 0.25rem !important;
        padding-top: 0.25rem !important;
        order: 0 !important;
        border-bottom: 0 !important;
    }
}

/* Desktop */
@media only screen and (min-width: 64rem) {
    .table__row {
        display: flex;
        /* grid-template-columns: repeat(16, 1fr); */
    }

    .table__row td,
    .table__row th {
        width: calc(100vw/16);
        flex-grow: 1;
    }
    
    .table__row td:last-child,
    .table__row th:last-child {
        width: calc(100vw/16 * 7 - 2rem);
        flex-grow: 0;
    }

    .graphics__visualization {
        grid-column: 8/-1;
    }
}