/* vvv Custom Slider Style vvv */
.slider {
    position: relative;
    background: #3e3e3e;
    width: 300px;
    height: 6px;
    user-select: none;
    border-radius: 12px;
}

.slider-track {
    position: absolute;
    background: #3e3e3e;
    /*background: linear-gradient(90deg, #fff, 20%, #000 0%);*/
    width: 100%;
    height: 100%;
    cursor: pointer;
    border-radius: 12px;
}

.slider-track-disabled {
    background: #222;
}

.slider-thumb {
    position: absolute;
    background: red;
    width: 18px;
    height: 18px;
    top: 50%;
    left: 0;
    transform: translate(-50%, -50%);
    cursor: grab;
    border-radius: 4px;
}

.slider-thumb-disabled {
    background: #4a4a4a;
}

.slider-thumb:hover {
    background: #f8e45c;
}

.slider-thumb:active {
    background: white;
}

.slider-thumb:active {
    cursor: grabbing;
}

/* ^^^ Custom Slider Style ^^^ */

/* Filter Colors */
:root {
    --filter-white: invert(100%) sepia(99%) saturate(0%) hue-rotate(231deg) brightness(107%) contrast(100%);
    --filter-yellow: brightness(0) saturate(100%) invert(79%) sepia(46%) saturate(719%) hue-rotate(357deg) brightness(104%) contrast(93%);
    --filter-disabled: brightness(0) saturate(100%) invert(21%) sepia(1%) saturate(2506%) hue-rotate(324deg) brightness(75%) contrast(75%);
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif
}

input, select {
    background: #2a2a2a;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 6px;
    transition: border-radius 0.25s;
}

input:focus {
    border-radius: 12px;
    outline: 2px solid white;
}

input:disabled {
    background: #1a1a1a;
    color: #444;
}

button {
    background: #2a2a2a;
    border-radius: 4px;
    border: none;
    padding: 4px 12px;
    color: white;
    border-radius: 999px;
    transition: transform 0.1s, background-color 0.2s;
}

button:not(:disabled):hover {
    background: #4a4a4a;
    transform: scale(0.95);
}

button:not(:disabled):active {
    background: white;
    color: #3a3a3a;
    outline: unset;
    transform: scale(1.05);
}

button:disabled {
    background: #1e1e1e;
    color: #3e3e3e;
}

button img {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    pointer-events: none;
    filter: var(--filter-white);
}

button:disabled img {
    filter: var(--filter-disabled)
}

button:not(:disabled):active img {
    filter: unset
}

#audio-playplause-button img{
    margin-left: 2px;
}

body {
    margin: 0;
    padding: 0;
    background: #1a1a1a;
    color: white;
}

#filename {
    display: flex;
    gap: 4px;
}

#filename-ext {
    padding: 0;
    margin: 0;
}

#container {
    margin: 16px 16px;
}

main {
    width: 100%;
}

.top-nav {
    display: flex;
    margin: 0;
    padding: 0;
    list-style-type: none;
    gap: 4px;
}

#export-button {
    margin-left: 8px;
}

header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #0e0e0e;
    padding: 16px;
    margin-bottom: 92px;
}

#audio-slider-container {
    background: #0e0e0e;
    width: 100%;
    padding: 16px;
    align-items: center;
    box-sizing: border-box;
    user-select: none;
    border-radius: 12px;
}

#audio-slider-controls {
    width: 100%;
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
}

#audio-slider-controls-actions {
    display: flex;
    width: 100%;
    justify-content: space-between;
    margin-right: 32px;
    align-items: center;
}

#audio-slider-controls-actions button{
    font-size: 12px;
}

#audio-slider-controls-timeline {
    display: flex;
    gap: 8px;
    justify-content: center;
}

#audio-slider-controls-timeline p {
    padding: 0;
    margin: 0;
    font-size: 12px;
    user-select: none;
}

#audio-slider {
    width: 100%;
    height: 12px;
}

#audio-slider-thumb {
    height: 24px;
    width: 12px;
}

#guide-thumb {
    position: absolute;
    background: rgba(155, 210, 255, 0.35);
    height: 48px;
    width: 1px;
    z-index: -999;
    top: 36px;
    left: 45%;
    pointer-events: none;
}

.sub-marker {
    position: absolute;
    width: 0;
    height: 0;
    left: 0;
    top: 36px;
    transform: translateX(-50%);
    cursor: pointer;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-bottom: 24px solid #f8e45c;
    background: transparent;
    border-bottom-left-radius: 3px ;
    border-bottom-right-radius: 3px ;
}

.sub-marker-unfinished {
    border-bottom-color: #4a4a4a;
}

.sub-marker-active {
    border-bottom-color: white;
    
}

.duration-guide {
    position: absolute;
    background: rgb(0, 255, 234);
    width: 32px;
    height: 1px;
    left: 0;
    top: 37px;
    pointer-events: none;
    z-index: -4;
}

#subtitles-markers-container {
    display: grid;
    grid-template-columns: 60% auto;
    gap: 12px;
    background: #0e0e0e;
    margin-bottom: 12px;
    min-height: 300px;
    max-height: 300px;
    box-sizing: border-box;
    padding: 12px;
    border-radius: 12px;
}

#subtitles-markers-controls {
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
}

#subtitles-markers-list {
    list-style-type: none;
    padding: 0;
    margin: 0;
    overflow-y: auto;
    max-height: 276px;
}

#subtitles-markers-list li {
    display: flex;
    gap: 6px;
    margin-bottom: 6px;
    padding: 0 6px;
}

#subtitles-markers-list li p {
    font-size: 12px;
    margin: 0;
    padding: 0;
}

.list-subtitle {
    user-select: none;
    cursor: pointer;
}

.list-subtitle-count {
    color: gray;
}

.list-subtitle-timer {
    cursor: pointer;
    height: 100%;
    color: rgb(153, 153, 153);
}

.list-subtitle-text {
    cursor: pointer;
}

@keyframes subItemActivated {
    0% {
        background: rgb(151, 151, 150);
    }

    100% {
        background: #3f3e3e;
    }
}

.list-subtitle-active {
    background: #3f3e3e;
    animation: subItemActivated 0.5s;
}

.subtitle-control label{
    font-size: 14px;
}

.subtitle-control input {
    width: 100%;
    box-sizing: border-box;
    margin-bottom: 12px;
}

#text-editor {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #2a2a2a;
    width: 100%;
    box-sizing: border-box;
    margin-bottom: 12px;
    resize: none;
    border: none;
    color: white;
    border-radius: 4px;
    padding: 6px 6px;
    font-size: 12px;
    transition: border-radius 0.25s;
}

#text-editor:focus {
    border-radius: 12px;
    outline: 2px solid white;
}

#text-editor:disabled {
    background: #1a1a1a;
    color: #444;
}

#timers-controls {
    display: flex;
    gap: 8px;
}

#subtitles-viewer {
    background: #0e0e0e;
    margin-top: 64px;
    text-align: center;
    padding: 8px;
    opacity: 0%;
}

#subtitle-viewer-text {
    padding: 0;
    margin: 0;
}

footer {
    position: absolute;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    bottom: 0;
    width: 100%;
    height: 64px;
    background: #0e0e0e;
    align-items: center;
    text-align: center;
    box-sizing: border-box;
    padding-inline: 16px;
}

#source-code {
    font-size: 14px;
    justify-self: flex-start;
    color: white;
    text-underline-offset:2px;
}

#source-code:hover {
    color: #f8e45c;
}

#app-title {
    font-size: 18px;
    justify-self: center;
}

#creator {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    justify-self: flex-end;
}

#creator p {
    margin: 0;
    padding: 0;
    margin-right: 8px;
}

.creator-social-wrapper {
    padding: 0;
    margin: 0;
    text-decoration: none;
    display: flex;
    align-items: center;
}

.creator-social {
    width: 24px;
    height: 24px;
    margin: 0;
    padding: 0;
    filter: var(--filter-white)
}

.creator-social:hover {
    filter: var(--filter-yellow)
}