.activity {
    height: 100%;
    width: 100%; 
}

.activity-node-container,
.activity-node {
    z-index: 1;
}

.activity-node-container {
    width: 75%;
    position: absolute;
    top: 50%;  
    transform: translate(50%, -50%);
    z-index: 3;
    display: flex;
    flex-wrap: wrap;
    align-content: center;
    justify-content: center;
    z-index: 3;
    /*
    background-color: #655358;
    border: 0.35vmin solid rgba(var(--black), 1);
    border-radius: 2.8vmin;
    */
}

.activity-node-container--right {
    right: 56.5%;
}

.activity-node-container--center {
    right: 50%;
}

.activity-node-container--offTop {
    transform: translate(50%, -200%);
}

.activity-node {
    position: relative;
    width: 32%;
    padding-top: 31.5%;
    margin: 0.5%;
    /*
    cursor: -webkit-image-set(
	  url("../assets/interface/cursor/pointer-1x.png") 1x,
	  url("../assets/interface/cursor/pointer-2x.png") 2x
	), auto;
    */
    position: relative;
    border: 0.35vmin solid rgba(var(--black), 1);
    box-sizing: border-box;
    overflow: hidden;   
    border-radius: 1vmin;
    background-color: rgba(var(--off-black), 1);
    background-size: 100%;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 1;
    transition: transform 0.2s, opacity 0.2s;
    transition-timing-function: ease-in;
    will-change: transform opacity;
}

.activity-node-image {
    top: 0;
    left: 0;
    position: absolute;
    width: 100%;
    background-size: 100% 100%;
    background-repeat: no-repeat;
    background-position: center;
    transition: transform 0.05s;
}

/*
.activity-node:nth-child(1){
    border-radius: 5vmin 1vmin 1vmin 1vmin;
}

.activity-node:nth-child(3){
    border-radius: 1vmin 5vmin 1vmin 1vmin;
}

.activity-node:nth-child(4){
    border-radius: 1vmin 1vmin 1vmin 5vmin;
}

.activity-node:nth-child(6){
    border-radius: 1vmin 1vmin 5vmin 1vmin;
}
*/

.activity-node--not-clicked {
    transform: translateY(0%);
    opacity: 1;
}

.activity-node--clicked {
    transform: translateY(10%);
    opacity: 0;
}

.activity-node--hidden {
    transition: opacity 0.2s, transform 0.2s;
    opacity: 0;
    transform: translateY(-50%);
}

.activity-node--visible {
    opacity: 1;
    transform: translateY(0%);
    /* animation: node-bounce 0.1s ease-in-out 1; */
    animation-delay: 0.2s;
}

.activity-node--unclickable {
    pointer-events: none;
}

.activity-node--clickable {
    pointer-events: auto;
}

@keyframes node-bounce {
    0% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(3%);
    }
    100% {
        transform: translateY(0);
    }
}  


.activity-node-title {
    text-align: center;
    position: absolute;
    user-select: none;
    bottom: 4%;
    left: 50%;
    transform: translateX(-50%) rotate(-2deg);
    padding: 1% 7% 1.5% 7%;
    border-radius: 10vmin;
    background-color: rgba(var(--off-white), 1);
    color: rgba(var(--off-black), 1);
    border: 0.35vmin solid rgba(var(--black), 1);
    white-space: nowrap;
    user-select: none;
    width: 100%;
    transition: transform 0.05s;
}  

.activity-modal {
    width: 82%;
    position: absolute;
    top: 50%;  
    transform: translate(50%, -50%);
    z-index: 5;
    border-radius: 1.5vmin;
    border: 0.35vmin solid rgba(var(--black), 1);
    background-color: rgba(var(--black), 1);
    transition: transform 0.2s, opacity 0.2s;
    will-change: transform opacity;
}

.activity-modal--right {
    right: 56.8%;
}

.activity-modal--center {
    right: 50%;
}

.activity-modal--close {
    opacity: 0;
    transform: translate(50%, -50%) scale(0.8);
}

.activity-modal--open {
    opacity: 1;
    transform: translate(50%, -50%) scale(1);
    /* animation: pop-in-modal 0.2s ease-out; */
}

.activity-modal-wrapper {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    overflow-x: hidden;
    border-radius: 1.5vmin;
    scrollbar-width: none; /* Firefox */
}

.activity-modal-wrapper:-webkit-scrollbar {
    display: none; /* Chrome, Safari and Edge */
}

.overflow-y-hidden {
    overflow-y: hidden;
}

.overflow-y-scroll {
    overflow-y: scroll;
}

.activity-modal-content-container {
    background-color: none;
    width: 100%;
    height: 200%;
    position: absolute;
    top: 0;
    left: 0;
    transition: transform 0.2s ease-in-out;
    border-radius: 1.5vmin;
    border-radius: 1.5vmin;
    will-change: transform;
}

.activity-modal-content-container-top {
    width: 100%;
    height: 50%;
    position: absolute;
    top: 0;
    left: 0;
    background-size: cover;
    border-radius: 1.5vmin 1.5vmin 0 0;

}

.activity-modal-content-container-bottom {
    width: 90%;
    height: 28.5%;
    position: absolute;
    bottom: 17.6%;
    left: 5.1%;
    box-sizing: border-box;
    border-radius: 0 0 1.5vmin 1.5vmin;
    
    /* animation: screenFlicker 0.1s infinite; */
}

.activity-modal-content-container-toggle {
    width: 5.5%;
    height: 4.6%;
    position: absolute;
    left: 50%;
    bottom: 50.5%;
    transform: translate(-50%,0%);
    z-index: 5;
    background-image: url(../assets/interface/button/scroll/default.png);
    background-size: 95%;
    background-repeat: no-repeat;
    background-position: center center;
    cursor: default;
    transition: transform 0.2s;
    /*
    cursor: -webkit-image-set(
	  url("../assets/interface/cursor/pointer-1x.png") 1x,
	  url("../assets/interface/cursor/pointer-2x.png") 2x
	), auto;
    */
}

.activity-modal-content-container-toggle--hidden {
    transform: translate(-50%,150%) scale(1);
}

.activity-modal-content-container-toggle--visible {
    transform: translate(-50%,0%) scale(1);
}

.scroll-up {
    width: 6.3%;
    height: 15%;
    position: absolute;
    left: 50%;
    top: -12.3%;
    transform: translate(-50%,0%);
    z-index: 5;
    background-image: url(../assets/interface/button/scroll-up/default.png);
    background-size: 95%;
    background-repeat: no-repeat;
    background-position: center center;
    cursor: default;
    transition: transform 0.2s;
    /*
    cursor: -webkit-image-set(
	  url("../assets/interface/cursor/pointer-1x.png") 1x,
	  url("../assets/interface/cursor/pointer-2x.png") 2x
	), auto;
    */
}

.activity-modal-screen {
    background-size: cover;
    background-image: url(../assets/interface/machine/activity/frame.png);
    position: absolute;
    width: 100%;
    height: 50%;
    bottom: -0.2%;
    left: 0;
    z-index: -1;
    border-radius: 0 0 1.5vmin 1.5vmin;
}

.activity-modal-code-machine {
    position: absolute;
    width: 100%;
    bottom: 0;
    right: 0;
    height: 15%;
}

.button-close-modal {
    position: absolute;
    top: 0;
    right: 0;
    margin-top: -1%;
    margin-right: -1%;
    transition: transform 0.05s ease-in-out;
    z-index: 11;
    background-image: url(../assets/interface/button/close/default.png);
    background-size: cover;
    width: 5.7%;
    height: 9.4%;
    border-radius: 10vmin;
}

.activity-blackout {
    width: 100%;
    height: 100%;
    top: 0;
    background-color: rgba(var(--black), 1);
    transition: opacity 0.3s ease-in-out;
    position: absolute;
    z-index: 4;
}

.activity-blackout--close {
    opacity: 0;
}

.activity-blackout--open {
    opacity: 0.7;
}

@keyframes pop-in-modal {
    0% {
        transform: translate(50%, -50%) scale(0.8);
    }
    50% {
        transform: translate(50%, -50%) scale(1.05);
    }
    100% {
        transform: translate(50%, -50%) scale(1);
    }
}  

.activity-button-done {
    position: absolute;
    bottom: 64.8%;
    right: 3.4%;
    z-index: 5;
    color: white;
    padding-bottom: 0.2%;
    transform: scale(0);
    transform-origin: center;
    background-image: url(../assets/interface/button/done/default.png);
    text-shadow: 0 0.2vmin 0.1vmin rgba(var(--salmon-light));
    background-size: cover;
    width: 18.2%;
    height: 27%;
    color: rgba(var(--black), 1);
    font-family: 'Primer-Print Bold', sans-serif;
    border-radius: 0.5vmin;
    transition: transform 0.2s;
    transform: scale(0);
}

.activity-button-done--close {
    transform: scale(0);
}

.activity-button-done--open {
    /* animation: pop-in-start-button 0.2s ease-out; */
    transform: scale(1);
}

@keyframes pop-in-start-button {
    0% {
        transform: scale(0.8);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}  

.activity-button-hint {
    position: absolute;
    top: 7.3%;
    left: 3.2%;
    z-index: 3;
    border-radius: 0.6vmax;
    padding-bottom: 0.1%;
    transform-origin: center;
    color: rgba(var(--black), 1);
    font-family: 'Primer-Print Variable', sans-serif;
    background-image: url(../assets/interface/button/hint/default.png);
    text-shadow: 0 0.2vmin 0.1vmin rgba(var(--salmon-light));
    background-size: cover;
    width: 10.5%;
    height: 28%;
    transition: transform 0.2s;
    transform: scale(1);
}

.activity-button-hint:active {
    background-image: url(../assets/interface/button/hint/active.png);
    text-shadow: 0 0.2vmin 0.1vmin rgba(var(--salmon-light));

}

.activity-button-hint--visible {
    transform: scale(1);
}

.activity-button-hint--hidden {
    transform: scale(0);
}


/* Activity Node States 
.activity-node--incomplete {
}

.activity-node--complete {
}
*/
.activity-node--disabled {
    pointer-events: none;
}

.activity-node--enabled {
    pointer-events: auto;
}

.activity-node--gameEnd {
    opacity: 0;
}

.activity-node-complete-banner {
    background-image: url(../assets/interface/machine/node/complete.png);
    background-size: 100% 100%;
    width: 100%;
    background-repeat: no-repeat;
    background-position: center;
    position: absolute;
    top: 0;
    left: 0;
    transition: transform 0.05s;
}

.clue-tracker-panel {
    position: relative;
    top: auto;
    right: auto;
    width: 50%;
    min-height: 220px;
    padding: 0.9rem 0.85rem 1rem 0.85rem;
    background-color: rgba(var(--off-white), 1);
    border: 0.25vmin solid rgba(var(--off-black), 1);
    border-radius: 1vmin;
    box-shadow: 0 0.35rem 0.9rem rgba(0, 0, 0, 0.12);
    z-index: 20;
    box-sizing: border-box;
}

.clue-tracker-title {
    margin: 0 0 0.45rem 0;
    text-align: right;
    font-family: "Patrick Hand", "Primer Print Bold", sans-serif;
    font-size: clamp(1.1rem, 1.3vw, 1.45rem);
    line-height: 1;
    color: rgba(var(--off-black), 1);
}

.clue-tracker-progress {
    margin-bottom: 0.7rem;
    text-align: right;
    font-family: "Patrick Hand", "Primer Print Bold", sans-serif;
    font-size: clamp(0.95rem, 1vw, 1.1rem);
    line-height: 1.1;
    color: rgba(var(--brown-dark), 1);
}

.clue-tracker-list {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    margin-top: 0.25rem;
    max-height: 130px;
    overflow-y: auto;
}

.clue-tracker-empty {
    text-align: right;
    font-family: "Patrick Hand", "Primer Print Bold", sans-serif;
    font-size: clamp(0.9rem, 0.95vw, 1rem);
    line-height: 1.2;
    color: rgba(var(--brown-dark), 1);
    opacity: 0.85;
}

.clue-tracker-item {
    padding: 0.45rem 0.55rem;
    background-color: rgba(var(--white), 0.45);
    border: 0.18vmin solid rgba(var(--brown-dark), 0.4);
    border-radius: 0.7vmin;
    font-family: "Patrick Hand", "Primer Print Bold", sans-serif;
    font-size: clamp(0.92rem, 0.95vw, 1rem);
    line-height: 1.15;
    color: rgba(var(--off-black), 1);
    word-break: break-word;
}

.footer {
    position: absolute;
    top: 0.4rem;
    right: 0.4rem;
    bottom: 0.4rem;
    width: clamp(135px, 11vw, 190px);
    z-index: 5;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.35rem;
    transition: opacity 0.2s, transform 0.2s;
    transform: translate(0, 0) scale(1);
    opacity: 1;
}

.footer--hidden {
    pointer-events: none;
    opacity: 0;
    transform: translate(10%, 0) scale(0.98);
}

.footer--visible {
    opacity: 1;
    transform: translate(0, 0) scale(1);
}

.footer--right {
    transform: translate(0, 0) scale(1);
}

.clue-tracker-panel {
    position: relative;
    width: 100%;
    flex: 1 1 auto;
    min-height: 0;
    padding: 0.7rem 0.55rem 0.8rem 0.55rem;
    background-color: rgba(var(--off-white), 1);
    border: 0.18vmin solid rgba(var(--off-black), 1);
    border-radius: 0.7vmin;
    box-shadow: 0 0.2rem 0.5rem rgba(0, 0, 0, 0.12);
    box-sizing: border-box;
    overflow: hidden;
}

.clue-tracker-title {
    margin: 0 0 0.3rem 0;
    text-align: center;
    font-family: "Patrick Hand", "Primer Print Bold", sans-serif;
    font-size: clamp(0.95rem, 1vw, 1.2rem);
    line-height: 1;
    color: rgba(var(--off-black), 1);
}

.clue-tracker-progress {
    margin-bottom: 0.45rem;
    text-align: center;
    font-family: "Patrick Hand", "Primer Print Bold", sans-serif;
    font-size: clamp(0.8rem, 0.85vw, 0.95rem);
    line-height: 1.05;
    color: rgba(var(--brown-dark), 1);
}

.clue-tracker-list {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    max-height: calc(100% - 3.4rem);
    overflow-y: auto;
    padding-right: 0.1rem;
}

.clue-tracker-empty {
    text-align: center;
    font-family: "Patrick Hand", "Primer Print Bold", sans-serif;
    font-size: clamp(0.78rem, 0.82vw, 0.92rem);
    line-height: 1.15;
    color: rgba(var(--brown-dark), 1);
    opacity: 0.85;
}

.clue-tracker-item {
    padding: 0.35rem 0.4rem;
    background-color: rgba(var(--white), 0.42);
    border: 0.12vmin solid rgba(var(--brown-dark), 0.35);
    border-radius: 0.45vmin;
    font-family: "Patrick Hand", "Primer Print Bold", sans-serif;
    font-size: clamp(0.78rem, 0.82vw, 0.92rem);
    line-height: 1.1;
    color: rgba(var(--off-black), 1);
    word-break: break-word;
}
.clue-tracker-item--found {
    opacity: 1;
}

.clue-tracker-item--hidden {
    opacity: 1;
    color: transparent;
    user-select: none;
}

.footer-element {
    width: 100%;
    padding: 0;
    border: 0.22vmin solid rgba(var(--black), 1);
    border-radius: 0.8vmin;
    background-color: rgba(var(--off-black), 1);
    box-sizing: border-box;
    flex: 0 0 auto;
}

#footer-element-timer {
    position: relative;
    width: 100%;
    min-height: 150px;
    background-image: url(../assets/interface/machine/sidebar/Time_Keeper.png);
    background-size: 100% 100%;
    background-repeat: no-repeat;
    background-position: center;
    transition: transform 0.2s, opacity 0.2s;
}

.footer-element-time-label {
    font-size: clamp(0.78rem, 0.95vw, 1.05rem) !important;
    font-weight: 700 !important;
    position: absolute;
    top: 9%;
    left: 11%;
    width: 78%;
    height: 28%;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: rgba(var(--off-black), 1);
    line-height: 0.9;
    box-sizing: border-box;
    text-shadow: 0 0.08vmin 0.05vmin rgba(var(--teal-light), 1);
}

.footer-element-time-remaining {
    position: absolute;
    bottom: 11%;
    left: 12%;
    width: 76%;
    margin: 0;
    padding: 0;
    text-align: center;
    opacity: 1;
    font-size: clamp(1rem, 1.55vw, 1.9rem);
}

.footer-element-timer--hidden {
    transform: translate(0%,150%);
    opacity: 0;
}

.footer-button-menu {
    background-image: url(../assets/resource/interface/menu.png);
    background-size: 100%;
    background-repeat: no-repeat;
}
@media (max-width: 1100px) {
    .footer {
        width: clamp(125px, 12vw, 170px);
    }

    #footer-element-timer {
        min-height: 135px;
    }
}

@media (max-width: 800px) {
    .footer {
        width: 120px;
        top: 0.3rem;
        right: 0.3rem;
        bottom: 0.3rem;
    }

    .clue-tracker-panel {
        padding: 0.55rem 0.45rem 0.65rem 0.45rem;
    }

    #footer-element-timer {
        min-height: 120px;
    }

    .footer-element-time-label {
        font-size: clamp(0.7rem, 1.8vw, 0.9rem) !important;
    }

    .footer-element-time-remaining {
        font-size: clamp(0.9rem, 2.5vw, 1.35rem);
    }
} 

@media (max-width: 1200px) {
    .footer {
        width: clamp(170px, 18vw, 240px);
        top: 0.6rem;
        right: 0.6rem;
        gap: 0.45rem;
    }

    .clue-tracker-panel {
        min-height: 200px;
        padding: 0.8rem 0.75rem 0.9rem 0.75rem;
    }

    #footer-element-timer {
        min-height: 175px;
    }
}

@media (max-width: 900px) {
    .footer {
        width: clamp(160px, 22vw, 220px);
        top: 0.5rem;
        right: 0.5rem;
        gap: 0.4rem;
    }

    .clue-tracker-panel {
        min-height: 180px;
        padding: 0.75rem 0.7rem 0.85rem 0.7rem;
    }

    #footer-element-timer {
        min-height: 160px;
    }

    .footer-element-time-label {
        top: 8%;
        height: 30%;
        line-height: 0.95;
    }
}
@media (max-width: 700px) {
    .clue-tracker-list {
        max-height: 100px;
    }
}
@media (max-width: 700px) {
    .footer {
        width: 150px;
        top: 0.4rem;
        right: 0.4rem;
        gap: 0.35rem;
    }

    .clue-tracker-panel {
        min-height: 160px;
        padding: 0.65rem 0.6rem 0.75rem 0.6rem;
    }

    #footer-element-timer {
        min-height: 145px;
    }

    .footer-element-time-label {
        font-size: clamp(0.8rem, 2.1vw, 1rem) !important;
    }

    .footer-element-time-remaining {
        font-size: clamp(1.05rem, 3.4vw, 1.6rem);
    }
}

.activity-button-start {
    position: absolute;
    bottom: 2.5%;
    right: 1.5%;
    z-index: 3;
    padding: 1% 3%;
    border-radius: 0.6vmax;
    transform: scale(0);
    transform-origin: center;
}

.activity-button-start--close {
    transform: scale(0);
}

.activity-button-start--open {
    animation: pop-in-start-button 0.2s ease-out;
    transform: scale(1);
}

@media (hover:hover){
    .activity-node:hover > .activity-node-image {
        transition: transform 0.05s;
        transform: scale(1.05) rotate(-1deg);
    }
    .activity-node:hover > .activity-node-title {
        transition: transform 0.05s;
        transform: translateX(-50%) scale(1.1) rotate(-4deg);
    }

    .activity-node:hover > .activity-node-complete-banner {
        transition: transform 0.05s;
        transform: scale(1.15) rotate(-6deg);
    }
    .activity-node:nth-child(6):hover {
        background-size: 100%;
    }
    .activity-modal-content-container-toggle:hover {
        background-image: url(../assets/interface/button/scroll/hover.png);
    }
    .scroll-up:hover {
        background-image: url(../assets/interface/button/scroll-up/hover.png);
    }
    .button-close-modal:hover {
        background-image: url(../assets/interface/button/close/hover.png);
    }
    .activity-button-done:hover {
        background-image: url(../assets/interface/button/done/hover.png);
    }
    .activity-button-hint:hover {
        background-image: url(../assets/interface/button/hint/hover.png);
        text-shadow: 0 0.2vmin 0.1vmin rgba(var(--white));
        color: rgba(var(--black), 1);
    }
    
}

.button-close-modal:active {
    background-image: url(../assets/interface/button/close/active.png);
}

.activity-modal-content-container-toggle:active {
    background-image: url(../assets/interface/button/scroll/active.png);
}

.scroll-up:active {
    background-image: url(../assets/interface/button/scroll-up/active.png);
}

.activity-button-hint:active {
    background-image: url(../assets/interface/button/hint/active.png);
}

.activity-button-done:active {
    background-image: url(../assets/interface/button/done/active.png);
}

/*
.activity-node:active > .activity-node-image {
    transform: scale(1.05) rotate(-1deg);
}
.activity-node:active > .activity-node-title {
    transform: translateX(-50%) scale(1.1) rotate(-4deg);
}

.activity-node:active > .activity-node-complete-banner {
    transform: scale(1.15) rotate(-6deg);
}
*/