@charset "UTF-8";
@import url('https://fonts.googleapis.com/css2?family=Raleway:wght@400;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Open+Sans&family=Orbitron:wght@500&family=Roboto+Condensed:wght@300&display=swap');

#bpm-key-detector *,
#bpm-key-detector *::before,
#bpm-key-detector *::after {
    box-sizing: border-box;
}

#bpm-key-detector :root {
    --light-blue: #84c0f9;
    --main-blue: #399af7;
    --dark-blue: #1C4B78;
    --meter-width: 0;
}

#bpm-key-detector body,
#bpm-key-detector header,
#bpm-key-detector h1 {
    margin: 0;
}

#bpm-key-detector header {
    background-color: var(--main-blue);
    padding: 2rem 0;
    text-align: center;
}

#bpm-key-detector h1 {
    color: #fff;
    font-weight: 500;
}

#bpm-key-detector a#essentia-header-link {
    color: inherit;
}

#bpm-key-detector a#essentia-header-link:hover {
    text-decoration: underline;
}

#bpm-key-detector a#essentia-header-link:active {
    color: var(--dark-blue);
}

#bpm-key-detector {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    font-family: 'Raleway', sans-serif !important;
    margin-top: 48px;
}

/* FILE UPLOAD AREA */
#bpm-key-detector #file-select-area {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-evenly;
    height: 30vh;
    width: clamp(0px, 80vw, 600px);
}

#bpm-key-detector #file-drop-area {
    border: 3px dashed #BFBFBF;
    border-radius: 1rem;
    background-color: #f7f7f7;
    height: 150px;
    width: 59vw;
    max-width: 800px;
    text-align: center;
    font-size: 20px;
    line-height: 165px;
    color: #AFAFAF;
}

#bpm-key-detector #file-drop-area:hover {
    cursor: pointer;
    color: #7f7f7f;
    border-color: #7f7f7f;
}

#bpm-key-detector #file-drop-area > span {
    display: inline-block;
    vertical-align: center;
    line-height: normal;
}

#bpm-key-detector #waveform {
    width: 80%;
}

/* RESULTS AREA */
#bpm-key-detector #results {
    height: 100%;
    margin: 60px 0px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: clamp(0px, 80vw, 600px);
}

#bpm-key-detector .controls {
    display: flex;
    flex-direction: row;
    justify-content: space-evenly;
}

#bpm-key-detector .controls span {
    font-size: 20px;
    padding: 12px;
}

#bpm-key-detector #play {
    font-size: 13px;
}

#bpm-key-detector #playPauseButton {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 200px;
    height: 40px;
    border-radius: 20px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 1);
    font-family: 'Raleway', sans-serif !important;
}

#bpm-key-detector #playPauseIcon {
    font-size: 20px !important;
}

#bpm-key-detector #loader {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    border-radius: 1rem;
}

#bpm-key-detector .classifier {
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

#bpm-key-detector #danceability,
#bpm-key-detector #mood_happy,
#bpm-key-detector #mood_sad,
#bpm-key-detector #mood_relaxed,
#bpm-key-detector #mood_aggressive {
    justify-content: center;
    margin-left: -25px;
}

#bpm-key-detector #bpm-and-key {
    height: 3rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
}

#bpm-key-detector #key,
#bpm-key-detector #bpm {
    justify-content: center;
    align-items: center;
}

#bpm-key-detector .tag {
    font-weight: bold;
    font-size: 20px;
    font-family: 'Raleway', sans-serif !important;
    color: #ff6600;
}

#bpm-key-detector #key-value,
#bpm-key-detector #bpm-value {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 60%;
    height: 40px;
    margin: 0px 12px;
    border: 1px solid #999;
    font-weight: bold;
    color: #333;
    font-size: 20px;
    border-radius: 2px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

#bpm-key-detector .row-container {
    display: flex;
    flex-direction: row;
}

#bpm-key-detector .classifier span {
    margin: auto 24px;
    font-size: 30px;
}

#bpm-key-detector .classifier-meter {
    width: 80%;
    height: 40px;
    position: relative;
    border: 1px solid #999;
    border-radius: 5px;
    margin: 12px 0;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

#bpm-key-detector .classifier-meter::before {
    display: flex;
    align-items: center;
    background-color: #a1ddf9;
    width: calc(var(--meter-width, 0) * 1%);
    max-width: calc(100% - 0.3rem);
    min-width: 0;
    height: 30px;
    position: absolute;
    left: 4px;
    top: 4px;
    padding-left: .25rem;
    content: attr(data-classifier);
    text-align: center;
    font-size: 20px;
    color: black;
}

#bpm-key-detector #links {
    color: gray;
    font-weight: 300;
    font-size: 14px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
    justify-content: center;
    margin-top: 100px;
    width: clamp(90vw, 1000px, 95vw);
}

#bpm-key-detector #links span {
    color: lightgray;
    font-size: 2px;
}

#bpm-key-detector #links img {
    margin-left: 1rem;
    height: 2.6rem;
    border-radius: 5px;
}

#bpm-key-detector #waveform {
  width: 60vw;
  max-width: 900px;
}

/* Mobile styles */
@media (max-width: 768px) {
    #bpm-key-detector #file-drop-area {
        width: 80vw;
    }
    
    #bpm-key-detector #waveform {
        width: 90vw;
    }

    #bpm-key-detector #results {
        margin: 32px 0px;
    }

    #bpm-key-detector #play {
        padding: 15px 50px;
    }

    #bpm-key-detector #links {
        margin-top: 80px;
    }
}