/* Skill Tree & Infinity Tree */

/* Skill tree area */
#skillTreeArea {
    position: absolute;
    display: none;
    width: 3000px;
    height: 3000px;
    left: 0;
    top: 0;
    background-color: #909090;
    background-image: url(../assets/backgrounds/skilltreebg.jpg);
    background-size: 1920px 1080px;
}

#skillResetButton {
    position: absolute;
    width: 400px;
    height: 300px;
    padding: 32px;
    font-size: 32pt;
    left: calc(50vw - 200px);
    top: 200px;
    background-color: #15151560;
    border: 1px solid #70707080;
    border-radius: 30px;
    backdrop-filter: blur(32px);
    transition:
        background-color 0.2s ease-out,
        transform 0.2s ease-out;
    box-shadow: 0px 0px 8px #00000040;
}

#skillResetButton:hover {
    background-color: #15151570;
    transform: scale(1.02);
}

#skillResetButton:active {
    background-color: #15151560;
    transform: scale(1);
}

.skillUpgrade {
    width: 150px;
    height: 150px;
    border-radius: 15px;
    background-color: #30303050;
    border: 1px solid #80808080;
    backdrop-filter: blur(16px);
    padding-inline: 4px;
    font-size: 16pt;
    cursor: default;
}

.skillUpgrade.hidden {
    display: none;
}

.skillUpgrade.bought {
    transition:
        background-color 0.2s ease-in-out,
        transform 0.2s ease-in-out,
        color 1s ease-in-out;
    color: #e0e0e0;
    backdrop-filter: blur(24px);
}

.skillUpgrade.unlocked {
    cursor: pointer;
    box-shadow: 0px 0px 16px #dddddd80;
    background-color: #30303050;
    backdrop-filter: blur(18px);
    transition:
        background-color 0.2s ease-in-out,
        transform 0.2s ease-in-out;
}

.skillUpgrade.unlocked:hover {
    background-color: #30303070;
    transform: scale(1.05);
}

.skillUpgrade.branch {
    color: #eaeaea90;
    background-color: #30303020;
    backdrop-filter: blur(12px);
}

/* Infinity area */
#infinityArea {
    position: absolute;
    display: none;
    width: 3000px;
    height: 4000px;
    left: 0;
    top: 0;
    background: #121940;
    background: linear-gradient(
        120deg,
        rgba(18, 25, 64, 1) 0%,
        rgba(73, 30, 89, 1) 100%
    );
}

#infinityArea > .areaBackground {
    position: absolute;
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
    background-image: url(../assets/backgrounds/area1bg.jpg);
    background-size: 100%;
    opacity: 0.1;
}

#infinityStat {
    color: #111;
    text-shadow:
        -1px -1px 0 #ddd,
        1px -1px 0 #ddd,
        -1px 1px 0 #ddd,
        1px 1px 0 #ddd;
    position: absolute;
    left: 0;
    width: 100%;
    text-align: center;
    top: 500px;
    width: 100vw;
    font-size: 64pt;
}

#infinityDisclaimer {
    color: #eeeeee90;
    position: absolute;
    left: 0;
    width: 100%;
    text-align: center;
    top: 615px;
    width: 100vw;
    font-size: 24pt;
}

#breakInfinityBar {
    position: absolute;
    left: 25vw;
    top: 650px;
    width: 50vw;
    height: 40px;
    border-radius: 20px;
    background-color: #202020a0;
    backdrop-filter: blur(24px);
    z-index: 1;
}

#breakInfinityLabel {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    align-content: center;
    z-index: 3;
}

#breakInfinityProgressBar {
    position: absolute;
    left: 0;
    top: 0;
    width: 50%;
    height: 40px;
    border-radius: 20px;
    background-color: #aa50ee;
    z-index: 2;
}

#infinityTreeArea {
    position: absolute;
    top: 800px;
    left: 50px;
    width: 1500px;
    height: calc(100% - 50vw);
}

#infinityResetButton {
    position: absolute;
    width: 400px;
    height: 300px;
    padding: 32px;
    font-size: 64pt;
    left: 50vw;
    top: 200px;
    transform: translate(-50%, 0%);
    background-color: #15151560;
    border: 1px solid #70707080;
    border-radius: 30px;
    backdrop-filter: blur(12px);
    transition:
        background-color 0.1s ease-in-out,
        transform 0.15s ease-in-out;
}

#infinityResetButton .innerText {
    text-shadow:
        -2px -2px 0 #ff0088,
        2px -2px 0 #aa00ff,
        -2px 2px 0 #aa00ff,
        2px 2px 0 #ff0088;
    color: #000;
}

#ipReward {
    position: absolute;
    left: 0;
    top: calc(50% + 32px);
    font-size: 24pt;
    font-weight: 400;
    color: #eeeeeea0;
    width: 100%;
    text-align: center;
}

#infinityResetButton:hover {
    background-color: #15151570;
    animation:
        infinityHover 1s ease-out forwards,
        bounceUpInfinity 0.5s ease-in-out forwards;
}

#infinityResetButton:active {
    background-color: #15151560;
    animation:
        infinityHover 1s ease-out forwards,
        bounceDownInfinity 0.3s ease-in-out forwards;
}

@keyframes infinityHover {
    0% { box-shadow: 0px 0px 0px #ffffff40; }
    100% { box-shadow: 0px 0px 32px #ffffff40; }
}

@keyframes bounceUpInfinity {
    0% { transform: translate(-50%, 0); }
    50% { transform: translate(-50%, -12px); }
    100% { transform: translate(-50%, -9px); }
}

@keyframes bounceDownInfinity {
    0% { transform: translate(-50%, -9px); }
    50% { transform: translate(-50%, 3px); }
    100% { transform: translate(-50%, 0px); }
}

/* Infinity tree upgrades */
.infinityUpgrade {
    width: 250px;
    height: 180px;
    border-radius: 15px;
    background-color: #30303050;
    border: 1px solid #80808080;
    backdrop-filter: blur(24px);
    padding-inline: 8px;
    font-size: 16pt;
    cursor: default;
    transition:
        background-color 0.15s ease-in-out,
        color 0.5 ease-in-out;
}

.infinityUpgrade * {
    box-sizing: border-box;
}

.infinityUpgrade.hidden {
    display: none;
}

.infinityUpgrade.bought {
    transition:
        background-color 0.2s ease-in-out,
        transform 0.2s ease-in-out,
        color 1s ease-in-out;
    color: #e0e0e0;
    backdrop-filter: blur(32px);
    transform: scale(0.95);
}

.infinityUpgrade.unlocked {
    cursor: pointer;
    box-shadow: 0px 0px 16px #dddddd40;
    background-color: #30303050;
    backdrop-filter: blur(24px);
    transition:
        background-color 0.2s ease-in-out,
        transform 0.2s ease-in-out;
}

.infinityUpgrade.unlocked:hover {
    background-color: #30303070;
    transform: scale(1.05);
}

.infinityUpgrade.branch {
    color: #eaeaea90;
    background-color: #30303020;
    backdrop-filter: blur(12px);
}

.infinityUpgrade.branch * {
    opacity: 0.5;
}

.infinityUpgrade h3 {
    position: absolute;
    top: 8px;
    left: 0;
    width: 100%;
    font-size: 20pt;
    font-weight: 700;
    color: #eee;
}

.infinityUpgrade p {
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    transform: translateY(-50%);
    font-size: 16pt;
    font-weight: 400;
    padding-inline: 16px;
    line-height: 0.85;
    color: #ddd;
}

.infinityUpgrade h4 {
    position: absolute;
    bottom: 8px;
    left: 0;
    width: 100%;
    font-size: 18pt;
    font-weight: 700;
    color: #ddd;
}
