@import url('https://fonts.googleapis.com/css2?family=Zen+Kaku+Gothic+New&display=swap');

:root {
    --bg-color: #000000;
    --text-color: #c9d1d9;
    --accent-color: #58a6ff;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Zen Kaku Gothic New', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
}

* {
    font-family: 'Zen Kaku Gothic New', sans-serif;
}

#ui-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 10;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    box-sizing: border-box;
}

#game-state {
    margin-top: 20px;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    align-items: center;
}

#instruction {
    color: #eee;
    margin-top: 5px;
    margin-bottom: 6px;
    font-size: 23px;
    letter-spacing: 2px;
    opacity: 1;
}

#instruction-en {
    color: #eee;
    margin-top: 0px;
    font-size: 17px;
    letter-spacing: 1px;
    opacity: 1;
}

#video-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1;
    overflow: hidden;
}

/* Make canvas fill but maintain aspect ratio */
#output_canvas {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scaleX(-1);
    /* Mirror image */
    display: block;
    /* Remove bottom whitespace */
}

#audio-settings {
    margin-top: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

#result-text {
    position: absolute;
    bottom: 0;
    left: 0;
    z-index: 100;
    width: calc(100% - 80px);
    display: flex;
    justify-content: space-between;
    padding: 40px;
    font-size: 17px;
    opacity: 0;
    pointer-events: none;
    transition: opacity .5s;
}

#result-text.active {
    opacity: 1;
    pointer-events: auto;
}

.chart-container {
    width: 100%;
    margin-bottom: 25px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 10px;
    padding: 10px;
}

.instruction-bottom {
    position: absolute;
    bottom: 0;
    left: 0;
    z-index: 100;
    width: calc(100% - 80px);
    display: flex;
    justify-content: space-between;
    padding: 40px;
    font-size: 17px;
    opacity: 0;
    transition: opacity 1s;
}

.instruction-bottom.active {
    opacity: 1;
}

.instruction-bottom p {
    margin: 0;
    color: #888;
    transition: color 2s, text-shadow 0.3s, opacity 0.3s;
}

.instruction-bottom p.highlight {
    color: #eee;
}

#progress-container {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    z-index: 1000;
}

#progress-bar {
    width: 0%;
    height: 100%;
    background: #888;
    transition: width 0.1s linear;
}