/* COLORS */
:root {
    --text: black;
    --dark: rgba(52, 66, 103); /* #344267 */
    --accent: rgba(166, 179, 210); /* #A6B3D2 */
    --light-1: rgba(227, 231, 241); /* #E3E7F1 */
    --light-2: rgba(234, 238, 241); /* #EAEEF1 */
    --gray: rgba(237, 237, 237); /* #EDEDED */
}

::-moz-selection {
    background: var(--dark);
    color: white;
}

::selection {
    background: var(--dark);
    color: white;
}

/* GENERAL */
.js-loading *,
.js-loading *:before,
.js-loading *:after {
    animation-play-state: paused !important;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    opacity: 0;
    pointer-events: none;
    animation: fadeInActivate 1.5s ease forwards;
    font-family: Mulish;
    font-size: calc(14px + 0.4vw);
    line-height: calc(24px + 0.6vw);
    font-weight: 300;
    color: var(--text);
    min-height: 100vh;
    overflow-x: hidden;
}

@keyframes fadeInActivate {
    to {
        opacity: 1;
        pointer-events: auto;
    }
}

p {
    margin-bottom: calc(10px + 0.5vw);
    transition: 0.5s;
}

p:last-child {
    margin-bottom: 0;
}

.emphasis {
    font-style: italic;
    letter-spacing: calc(1px + 0.1vw);
    font-family: Charis SIL;
}

.bold {
    font-weight: 700;
}

.center {
    text-align: center;
}

h1, h2, h3, h4, h5 {
    font-family: Be Vietnam Pro;
    font-weight: 800;
}

h1 {
    font-size: calc(20px + 1.2vw);
    line-height: calc(40px + 1vw);
    letter-spacing: calc(1.5px + 0.1vw);
}

h3 {
    font-size: calc(18px + 1vw);
    line-height: calc(36px + 2vw);
    letter-spacing: calc(3px + 0.3vw);
    text-transform: uppercase;
    border-bottom: 2px solid var(--light-2);
    margin-bottom: calc(18px + 2vw);
}

a, .link {
    text-decoration: none;
    color: var(--dark);
    font-weight: 400;
    transition: 0.5s;
}

a.emphasis, .no-link {
    font-style: normal;
    text-decoration: underline;
    cursor: pointer;
    transition: 0.5s;
}

.no-link {
    color: var(--dark) !important;
    cursor: initial !important;
    text-decoration: none !important;
}

a:hover, .link:hover {
   opacity: 0.8;
}

.space-before {
    margin-top: calc(12px + 0.8vw);
}

/* NAV MENU */
header {
    font-family: Charis SIL;
    font-size: calc(12px + 0.3vw);
    position: fixed;
    top: 0;
    left: 0;
    display: flex;
    justify-content: center;
    width: 100%;
    padding: calc(20px + 1.5vw) 20px calc(24px + 2vw);
    z-index: 999999;
    transition: 0.5s;
    background: linear-gradient(rgba(227, 231, 241, 1), rgba(255, 255, 255, 0));
}

header.sticky {
    padding: calc(16px + 1vw) 20px calc(20px + 2vw);
}

header ul {
    margin: auto;
    display: flex;
    list-style: none;
    position: relative;
}

header a {
    color: var(--text);
    text-transform: lowercase;
    letter-spacing: calc(1px + 0.1vw);
    position: relative;
    display: block;
}

header a:hover {
    color: var(--dark);
}

header ul li {
    margin: 0 calc(8px + 0.2vw) 0;
    display: flex;
}

header ul li:first-child {
    margin-left: 0;
}

header ul li:last-child {
    margin-right: 0;
}

.menu-selected.click {
    pointer-events: auto;
}

.menu-selected {
    pointer-events: none;
    font-weight: 600;
    border-bottom: 4px solid var(--accent);
}

.has-dropdown {
    cursor: pointer;
    display: block;
}

.dropdown {
    opacity: 0;
    pointer-events: none;
    transition: 0.5s;
    background-color: rgba(255, 255, 255, 0.8);
    position: absolute;
    width: calc(80px + 6vw);
    line-height: calc(20px + 0.4vw);
    transform: translateX(-10%);
    font-size: calc(11px + 0.3vw);
    font-style: italic;
    padding: calc(8px + 0.1vw) 0;
}

.dropdown ul {
    display: block;
}

.dropdown ul li {
    margin: 0 !important;
}

.dropdown ul li a {
    transition: 0.5s;
    width: 100%;
    padding: calc(2px + 0.3vw) calc(12px + 0.5vw);
    display: flex;
}

.has-dropdown:hover > .dropdown {
    opacity: 1;
    pointer-events: auto;
    cursor: default;
}

.dropdown ul li a.menu-selected {
    pointer-events: none;
    border-bottom: none;
}

.dropdown ul li a.menu-selected.click {
    pointer-events: auto;
}

/* MASTHEAD */
section {
    padding: calc(28px + 4vw) calc(30px + 5vw);
    height: auto;
    transition: 0.5s;
    position: relative;
}

.first-sec {
    margin-top: calc(64px + 0.7vw);
}

.first-sec h3 a {
    font-weight: 800;
}

.first-sec h3 .bar {
    font-weight: 700;
    color: var(--accent);
}

.first-sec h3 .page {
    font-weight: 600;
    margin-right: 30px;
}

#masthead-content {
    display: grid;
    column-gap: calc(20px + 4vw);
    row-gap: calc(20px + 4vw);
    grid-template-columns: 2fr 1fr;
    align-items: center;
    transition: 0.5s;
}

@media (max-width: 850px) {
    #masthead-content {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 700px) {
    #masthead-content {
        grid-template-columns: 1fr;
    }

    #pic-and-links {
        order: -1;
    }
}

#prof-pic {
    width: 100%;
    border-radius: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    transition: 0.5s;
    filter: drop-shadow(5px 5px 5px rgba(0, 0, 0, 0.4));
    background: linear-gradient(rgba(166, 179, 210, 0.9), rgba(227, 231, 241, 0.7));
}

.social-links {
    width: 100%;
    display: flex;
    justify-content: center;
    position: relative;
    margin-top: calc(12px + 0.8vw);
}

.social-links i {
    font-size: calc(18px + 0.6vw);
}

.social-links a {
    color: var(--accent);
}

.social-links a:hover {
    color: var(--dark);
    transition: 0.5s;
}

.social-links a:not(:last-child) {
    margin-right: calc(12px + 0.6vw);
}

#down-arrow {
    padding-top: calc(20px + 2vw);
    position: relative;
    text-align: center;
}

#down-arrow a {
    position: relative;
    display: block;
    margin: auto;
    transition: 0.5s;
    height: calc(28px + 3vw);
    width: calc(28px + 3vw);
}

#down-arrow a:hover {
    transition: 0.5s;
    opacity: 0.8;
    transform: scale(1.1);
}

#down-arrow img {
    width: 100%;
}

.anchor {
    position: absolute;
    left: 0;
    top: -40px;
    width: 100%;
}

.page.anchor {
    top: -100px;
}

/* PUBLICATIONS */
.pub, .rproj, #projects, #art, #travel, #fun-facts, 
.fact-imgs, .favs, .fav-box {
    width: 100%;
    display: grid;
    column-gap: calc(16px + 3vw);
    row-gap: calc(16px + 3vw);
    grid-template-columns: 1fr 4fr;
    align-items: center;
    transition: 0.5s;
}

.pub:not(:last-child) {
   margin-bottom: calc(20px + 2vw);
}

.pub img, .rproj img, .proj img, .art-cat img, 
.fact-imgs img {
    width: 100%;
    border-radius: calc(10px + 1.5vw);
    filter: drop-shadow(5px 5px 5px rgba(0, 0, 0, 0.4));
    background: linear-gradient(rgba(166, 179, 210, 0.9), rgba(227, 231, 241, 0.7));
}

@media (max-width: 700px) {
    .pub {
        grid-template-columns: 1fr 2fr;
        align-items: start;
    }
}

@media (max-width: 550px) {
    .pub {
        grid-template-columns: 1fr;
    }
}

.pub-box .title, .rproj-box .title, .proj-details .title, 
.art-details .title, .fav-box .title, .mini-section .title {
    color: var(--dark);
    font-style: italic;
    letter-spacing: calc(1px + 0.1vw);
    font-family: Charis SIL;
    font-size: calc(16px + 0.6vw);
    margin-bottom: calc(6px + 0.2vw);
}

.pub-box .details a {
    text-decoration: underline;
}

p .bar {
    font-weight: 700;
    color: var(--accent);
    margin: 0 7px;
}

/* UPDATES */
.month {
    transition: 0.5s;
}

.month:not(:last-child) {
    padding-bottom: calc(10px + 0.5vw);
}

.month .emphasis {
    margin-bottom: 2px;
}

.list li {
    display: flex;
}

.list li:not(:last-child) {
    margin-bottom: 5px;
}

.list li::before {
    content: "\2022";
    color: var(--accent);
    list-style-position: outside;
    margin-right: calc(12px + 0.6vw);
    font-size: calc(10px + 0.3vw);
}

/* FOOTER */
footer {
    font-weight: 700;
    width: 100%;
    text-align: center;
    color: white;
    background-color: var(--accent);
    padding: calc(28px + 4vw) calc(30px + 5vw);
    margin-top: calc(18px + 3vw);
    position: relative;
}

footer .bar {
    color: var(--light-2);
}

footer a {
    color: white;
}

footer i {
    font-size: calc(14px + 0.4vw) !important;
}

svg.triangle {
    position: absolute;
    top: -4vw;
    left: 0;
    width: 100%;
    height: 4vw;
}

/* BACK TO TOP */
#back-to-top {
    opacity: 0;
    transform: translateY(100%);
    visibility: hidden;
    pointer-events: none;
    position: fixed;
    bottom: calc(20px + 1vw);
    right: calc(20px + 1vw);
    width: calc(24px + 1.5vw);
    height: calc(24px + 1.5vw);
    z-index: 9999;
    transition: 0.5s;
}

#back-to-top img {
    width: 100%;
}

#back-to-top.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
    visibility: visible;
    transition: 0.5s;
}

#back-to-top.active:hover {
    transition: 0.5s;
    transform: translateY(-5px) scale(1.1);
}

/* RESEARCH */
.rproj {
    grid-template-columns: 1fr 3fr;
    align-items: start;
    position: relative;
}

.rproj.right {
    grid-template-columns: 3fr 1fr;
}

.rproj.right .rproj-box {
    order: -1;
}

@media (max-width: 700px) {
    .rproj {
        grid-template-columns: 1fr 2fr;
    }

    .rproj.right {
        grid-template-columns: 2fr 1fr;
    }
}

@media (max-width: 550px) {
    .rproj, .rproj.right {
        grid-template-columns: 1fr;
    }

    .rproj.right .rproj-box {
        order: initial;
    }
}

.rproj:not(:last-child) {
    margin-bottom: calc(20px + 2vw);
}

.rproj img {
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

/* PROJECTS */
#projects, #art, #travel {
    grid-template-columns: 1fr 1fr 1fr;
}

@media (max-width: 950px) {
    #projects, #art, #travel {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 620px) {
    #projects, #art, #travel {
        grid-template-columns: 1fr;
    }

    .proj-details .title, .proj-details i, .art-details .title {
        font-size: calc(18px + 1vw) !important;
        line-height: calc(30px + 0.6vw);
    }
}

.proj-group, .art-group {
    cursor: pointer;
    transition: 0.5s;
    position: relative;
    overflow: hidden;
    border-radius: calc(10px + 1.5vw);
    filter: drop-shadow(5px 5px 5px rgba(0, 0, 0, 0.4));
}

.proj-group.clicked, .art-group.clicked {
    transition: 0.5s !important;
}

.proj-group:hover, .art-group:hover {
    cursor: auto;
    transform: scale(1.05) !important;
}

.proj-group:hover .overlay, .art-group:hover .overlay {
    opacity: 1;
    transition: 0.5s;
    pointer-events: all;
}

.proj-group .overlay, .art-group .overlay {
    background: linear-gradient(rgba(166, 179, 210, 0.9), rgba(227, 231, 241, 0.7));
    position: absolute;
    overflow: hidden;
    aspect-ratio: 1 / 1;
    z-index: 999;
    width: 100%;
    text-align: center;
    color: white;
    opacity: 0;
    transition: 0.5s;
    pointer-events: none;
    display: flex;
    align-items: center;
}

.proj-group:hover img, .art-group:hover img {
    filter: blur(2px);
}

.proj-group img, .art-group img {
    aspect-ratio: 1 / 1;
    object-fit: cover; 
    filter: none;
    overflow: hidden;
    display: block;
    transition: 0.5s;
}

.proj-details, .art-details {
    padding: calc(20px + 2vw);
    transition: 0.5s;
    color: white;
    width: 100%;
}

.proj-details .title, .art-details .title {
    color: white;
    margin-bottom: calc(8px + 0.4vw);
    font-size: calc(14px + 0.6vw);
}

.proj-details i {
    font-size: calc(14px + 0.6vw);
    cursor: pointer;
    color: white;
    transition: 0.5s;
}

.proj-details a:not(:last-child) {
    margin-right: calc(10px + 0.1vw);
}

.proj-details i:hover {
    transition: 0.5s;
    opacity: 0.8;
}

/* ART */
.art-group:hover {
    cursor: pointer;
}

.art-details .title {
    letter-spacing: calc(3px + 0.2vw);
}

.heading {
    position: relative;
}
.subheading {
    letter-spacing: calc(1px + 0.1vw);
    color: var(--text);
    font-weight: 600;
    position: absolute;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    transition: 0.5s;
    display: flex;
    align-items: center;
    cursor: pointer;
}

.subheading:hover {
    right: 8px;
}

.subheading.icon-right:hover {
    opacity: 0.8;
    right: 0;
}

.subheading span {
    transition: 0.5s;
}

.subheading:hover span {
    color: var(--dark);
    transition: 0.5s;
}

.subheading i {
    color: var(--accent);
    margin-right: calc(10px + 0.2vw);
    font-size: calc(20px + 0.6vw);
    transition: 0.5s;
}

.subheading.icon-right i {
    margin-right: 0;
    margin-left: calc(10px + 0.2vw);
}

@media (max-width: 650px) {
    .subheading.travel span {
        opacity: 0;
        width: 0;
        transition: 0.5s;
    }

    .subheading.travel i {
        margin-right: 0;
        margin-left: 0;
        transition: 0.5s;
    }
}

@media (max-width: 500px) {
    .subheading span {
        opacity: 0;
        width: 0;
        transition: 0.5s;
    }

    .subheading i {
        margin-right: 0;
        margin-left: 0;
        transition: 0.5s;
    }
}

.subheading + .dropdown {
    opacity: 0;
    right: 0;
    z-index: 999;
    top: 75%;
    transition: 0.5s;
    display: block;
    transform: scaleY(0);
    transform-origin: 50% 0;
}

.subheading + .dropdown li {
    padding: calc(2px + 0.3vw) calc(12px + 0.5vw);
    display: flex;
    letter-spacing: calc(1px + 0.1vw);
    cursor: pointer;
    transition: 0.5s;
}

.subheading + .dropdown li:hover {
    padding-left: calc(14px + 0.7vw);
    color: var(--dark);
    transition: 0.5s;
}

.subheading + .dropdown li.selected {
    background-color: var(--accent);
    color: white;
    font-weight: 400;
    pointer-events: none;
}

.subheading + .dropdown.visible {
    opacity: 1;
    pointer-events: auto;
    transform: scaleY(1);
}

/* FUN FACTS */
.list img {
    width: calc(12px + 0.6vw);
    margin: 0 5px;
}

#fun-facts {
    grid-template-columns: 3fr 1fr;
    align-items: start;
}

.fact-imgs {
    grid-template-columns: 1fr;
    column-gap: calc(14px + 2vw);
    row-gap: calc(14px + 2vw);
}

@media (max-width: 1000px) {
    #fun-facts {
        grid-template-columns: 2fr 1fr;
    }
}

@media (max-width: 800px) {
    #fun-facts {
        grid-template-columns: 1fr;
    }
    .fact-imgs {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 500px) {
    .fact-imgs {
        grid-template-columns: 1fr;
    }
}

.favs {
    grid-template-columns: 1fr;
}

.fav-box {
    grid-template-columns: 1fr 7fr;
}

.fav-box:nth-child(even) {
    grid-template-columns: 7fr 1fr;
}

.fav-box:nth-child(even) .fav-details {
    order: -1;
}

.fav-box .icon {
    font-size: calc(20px + 4vw);
    text-align: center;
    color: var(--light-1);
}

.fav-box svg.icon {
    width: calc(20px + 4vw);
    height: auto;
    margin: auto;
}

.fav-box:nth-child(3n+2) .icon {
    color: var(--accent);
}

.fav-box:nth-child(3n+3) .icon {
    color: var(--dark);
}

@media (max-width: 600px) {
    .fav-box {
        align-items: start;
        grid-template-columns: 1fr 7fr !important;
    }
    .fav-box .icon {
        margin-top: 5px;
        order: -1;
    }

}

/* RESOURCES */
.link {
    cursor: pointer;
    position: relative;
    display: inline-block;
    left: 100%;
    transform: translateX(-100%);
    margin-top: calc(16px + 0.6vw);
    margin-bottom: 0;
}

.link:hover {
    letter-spacing: 0.5px;
}

.mini-section .emoji {
    font-style: normal;
}

.mini-section {
    padding-top: calc(16px + 0.6vw);
}

.mini-section .title {
    background: var(--gray);
    padding: calc(12px + 0.1vw) calc(44px + 0.4vw) calc(12px + 0.1vw) calc(16px + 0.2vw);
    border-radius: calc(10px + 0.5vw);
    position: relative;
}

.mini-section img {
    width: calc(12px + 0.1vw);
    height: auto;
    cursor: pointer;
    position: absolute;
    top: 50%;
    right: calc(16px + 0.2vw);
    transform: translateY(-50%);
    transition: 0.5s;
}

.mini-section img:hover {
    opacity: 0.8;
    transition: 0.5s;
    transform: translateY(-50%) scale(1.1);
}

.mini-section img.rotate {
    transform: translateY(-50%) rotate(180deg);
}

.mini-section img.rotate:hover {
    transform: translateY(-50%) scale(1.1) rotate(180deg);
}

.mini-section .list {
    transition: 0.5s;
    transform-origin: 50% 0;
}

.mini-section .list.hide {
    pointer-events: none;
    opacity: 0;
    transform: scaleY(0);
    visibility: hidden;
    height: 0;
    transition: 0.5s;
}

.msg.bold.center {
    margin-top: calc(20px + 2vw);
}