/* Reset default margin and padding */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Set a background color and center the content */
body {
    background-color: #282A36;
    display: flex;
    flex-direction: column;
    justify-content: start;
    align-items: center;
    min-height: 100vh; /* Adjust this value as needed */
    font-family: Helvetica, Arial, sans-serif;
    color: #F8F8F2;
}

h1 {
    padding: 20px;
}

/* Create a container for the video list */
.video-list {
    max-width: 800px;
    width: 100%;
    padding: 20px;
    background-color: #21222C;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Style each video entry */
.video-entry {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.video-thumbnail {
    width: 200px;
    height: 120px;
    margin-right: 2vw;
    border-radius: 5px;
    overflow: hidden;
    position: relative; /* Added position relative for absolute positioning of child elements */
}

.video-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Added video duration overlay */
.video-thumbnail .duration {
    position: absolute;
    bottom: 5px;
    right: 5px;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 2px 4px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: bold;
}

.video-title {
    font-size: 16px;
    font-weight: bold;
    width: calc(90% - 200px);
}

iframe {
    border: none;
    margin: 20px;
    width: 560px;
    height: 315px;
}

a {
    color: inherit; /* blue colors for links too */
    text-decoration: inherit; /* no underline */
}

.dropdown {
    position: relative;
    width: 100%;
    max-width: 300px;
    padding-bottom: 20px;
}

.dropdown-select {
    width: 100%;
    padding: 10px;
    font-size: 16px;
    border: 2px solid #4a4a4a;
    border-radius: 5px;
    appearance: none;
    background-color: #21222C;
    color: #F8F8F2;
    background-image: url('data:image/svg+xml;utf8,<svg fill="%23e0e0e0" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg"><path d="M7 10l5 5 5-5z"/><path d="M0 0h24v24H0z" fill="none"/></svg>');
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 30px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.dropdown-select:hover {
    background-color: #21222C;
}

.dropdown-select:focus {
    outline: none;
    border-color: #6200ee;
    box-shadow: 0 0 0 3px rgba(98, 0, 238, 0.2);
}

/* Responsive styles */
@media screen and (max-width: 600px) {
    .video-list {
        padding: 10px;
    }

    .video-entry {
        align-items: flex-start;
        margin-bottom: 1px;
    }

    .video-thumbnail {
        width: 40vw;
        height: auto;
    }

    .video-title {
        width: 55vw;
    }

    iframe {
        margin: 0;
        width: 100%;
        height: calc(100vw * (9 / 16));
    }
}

@media (prefers-color-scheme: light) {
    body {
        background-color: #FFFFFF;
        color: #282A36;
    }

    .video-list {
        background-color: #f0f0f0;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    }

    .dropdown-select {
        border: 2px solid #cccccc;
        background-color: #FFFFFF;
        color: #282A36;
        background-image: url('data:image/svg+xml;utf8,<svg fill="%23282A36" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg"><path d="M7 10l5 5 5-5z"/><path d="M0 0h24v24H0z" fill="none"/></svg>');
    }

    .dropdown-select:hover {
        background-color: #f0f0f0;
    }

    .dropdown-select:focus {
        border-color: #6200ee;
        box-shadow: 0 0 0 3px rgba(98, 0, 238, 0.2);
    }
}
