:root {
    color-scheme: dark;
    --text: #eeeeee;
    --base: #d2d2d5;
    --mantle: #3d3db6;
    --crust: #181825;
    --back: rgba(3, 3, 25, 0.8);
}

body {
    font-family: russiangothic, ms ui gothic, nec_apc3, Tahoma, serif;
    background-color: var(--back);
    color: var(--text);
    margin: 0;
    padding: 0;
}

h4 {
    padding: 0;
    margin: 0;
    text-align: center;
    color: var(--text);
}

.back-button-wrapper {
    position: absolute;
    top: 15px;
    left: 25px;
}

.back-button {
    width: 150px;
    padding: 15px;
    display: flex;
    text-align: center;
    justify-content: center;
    background: var(--mantle);
    text-decoration: none;
    color: var(--text);
    font-size: 20px;
    border-radius: 8px;
}

h1 {
    text-align: center;
    padding: 1.5rem 0 0.5rem;
}

.chart-container {
    width: 90%;
    max-width: 1000px;
    margin: 2rem auto;
    background: #1b1e2a;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0,0,0,0.4);
    padding: 1rem;
    justify-content: center;
    display: flex;
}

#loadingOverlay {
    position: fixed;
    inset: 0;
    background: #000;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    z-index: 9999;
    font-size: 2.5rem;
    font-weight: 500;
    transition: opacity 0.6s ease;
}
#loadingOverlay.fade-out {
    opacity: 0;
    pointer-events: none;
}
.dots span {
    opacity: 0.2;
    animation: blink 1.5s infinite;
}
.dots span:nth-child(2) { animation-delay: 0.3s; }
.dots span:nth-child(3) { animation-delay: 0.6s; }
@keyframes blink {
    0%, 80%, 100% { opacity: 0.2; }
    40% { opacity: 1; }
}

#tempTitleOverlay {
    position: absolute;
    height: 60px;
    cursor: pointer;
    z-index: 5;
    width: 300px;
}