:root {
    --bg-gradient: linear-gradient(180deg, rgba(2, 2, 18, 1) 0%, rgba(16, 2, 8, 1) 50%, rgba(6, 2, 0, 1) 100%);
    --font-color: rgb(251, 249, 248);
}

html,
body {
    margin: 0;
    padding: 0;
}

body {
    height: 100dvh;
    width: 100dvw;
    background: #020212;
    background: var(--bg-gradient);
    font-size: clamp(10px, 2vw, 22px);
}

#confetti-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

main {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    box-sizing: border-box;
    width: 100%;
    height: 100%;
    padding: 1rem;
}

h1 {
    color: var(--font-color);
    text-align: center;
    line-height: 1.1;
    font-family: 'Expose', sans-serif;
    font-weight: 700;
    font-size: 3.2em;
}

.phase {
    position: relative;
    border: none;
    background: transparent;
    padding: 0;
    cursor: default;
    outline-offset: 4px;
    opacity: 1;
    transition: filter 0.2s, opacity 0.3s;
    user-select: none;
    -webkit-user-select: none;
    touch-action: manipulation;
}

.phase[disabled]{
    opacity: 0;
}

.phase-shadow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 8px;
    background: hsl(0deg 0% 0% / 0.25);
    will-change: transform;
    transform: translateY(2px);
    transition:
        transform 600ms cubic-bezier(.3, .7, .4, 1);
}

.phase-edge {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 8px;
    background: linear-gradient(to left,
            hsl(340deg 100% 16%) 0%,
            hsl(340deg 100% 32%) 8%,
            hsl(340deg 100% 32%) 92%,
            hsl(340deg 100% 16%) 100%);
}

.phase-front {
    display: block;
    position: relative;
    padding: 0.6em 1.2em;
    border-radius: 8px;
    font-family: 'Bespoke Sans', sans-serif;
    font-size: 1.5em;
    font-weight: 540;
    color: var(--font-color);
    background: hsl(345deg 100% 47%);
    will-change: transform;
    transform: translateY(-4px);
    transition:
        transform 600ms cubic-bezier(.3, .7, .4, 1);
}

.phase:hover {
    filter: brightness(110%);
}

.phase:hover .phase-front {
    transform: translateY(-6px);
    transition:
        transform 250ms cubic-bezier(.3, .7, .4, 1.5);
}

.phase:active .phase-front {
    transform: translateY(-2px);
    transition: transform 34ms;
}

.phase:hover .phase-shadow {
    transform: translateY(4px);
    transition:
        transform 250ms cubic-bezier(.3, .7, .4, 1.5);
}

.phase:active .phase-shadow {
    transform: translateY(1px);
    transition: transform 34ms;
}

.phase:focus:not(:focus-visible) {
    outline: none;
}

.phase.final {
    cursor: not-allowed;
}

.phase.final,
.phase.final:hover,
.phase.final:hover .phase-front,
.phase.final:active .phase-front {
    filter: none;
    transform: none;
    transition: none;
}

.phase.final:hover .phase-front,
.phase.final:active .phase-front {
    transform: translateY(-4px);
}

.phase.final .phase-front {
    background: hsl(279, 72%, 22%);
}

.phase.final .phase-edge {
    background: linear-gradient(to left,
            hsl(279, 100%, 10%) 0%,
            hsl(279deg 100% 16%) 8%,
            hsl(279, 100%, 10%) 92%,
            hsl(279, 100%, 12%) 100%);
}