/* General Body Styling */
body {
    font-family: 'Arial', sans-serif;
    background-color: #000;
    color: #fff;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    line-height: 1.6;
    font-size: 16px; /* Set the default font size for mobile */
}

/* Header Styling */
header {
    background-color: #D32F2F; /* Intense Red */
    padding: 20px 20px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
    transition: all 0.3s ease;
}

header h1 {
    font-size: 2.5rem; /* Adjust font size for mobile */
    color: #fff;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 2px;
}

header:hover {
    background-color: #b71c1c; /* Darker red */
}

header h1:hover {
    letter-spacing: 4px; /* Dynamic hover effect */
}

/* Main Container */
.container {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    padding: 10px;
    gap: 20px;
}

/* Sidebar (Capítulos) Styling */
.sidebar {
    background-color: #212121;
    width: 100%;
    padding: 15px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    flex: 1;
    min-width: 250px;
    max-width: 100%;
    box-sizing: border-box;
    transition: transform 0.3s ease;
}

.sidebar h2 {
    color: #D32F2F;
    font-size: 1.8rem; /* Adjust font size for mobile */
    margin-bottom: 15px;
    text-align: center;
    font-weight: bold;
    text-transform: uppercase;
}

/* Chapter List Styling */
.sidebar ul {
    list-style: none;
    padding: 0;
}

.sidebar ul li {
    margin-bottom: 10px; /* Reduced space for smaller screens */
}

.sidebar ul li button {
    background-color: #D32F2F;
    color: #fff;
    border: none;
    padding: 12px;
    width: 100%;
    text-align: left;
    font-size: 1em; /* Smaller font size for mobile */
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.3s ease;
    box-sizing: border-box;
    font-weight: bold;
}

.sidebar ul li button:hover {
    background-color: #c62828;
    transform: translateX(5px); /* Hover effect: slide to the right */
}

/* Video Player Styling */
.video-player {
    flex: 2;
    background-color: #212121;
    border-radius: 12px;
    padding: 15px;
    box-sizing: border-box;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s ease;
}

.video-player iframe {
    width: 100%;
    height: 250px; /* Adjusted height for smaller screens */
    border-radius: 12px;
}

.video-player:hover {
    transform: scale(1.05);
}

/* For small screens (600px) */
@media (max-width: 600px) {
    body {
        font-size: 14px; /* Adjust the body font size for very small screens */
    }

    header h1 {
        font-size: 1.8rem; /* Smaller font size */
    }

    .sidebar {
        padding: 10px;
    }

    .sidebar h2 {
        font-size: 1.6rem; /* Smaller font size */
    }

    .sidebar ul li button {
        font-size: 0.9em; /* Smaller buttons */
        padding: 10px;
    }

    .video-player {
        height: 200px; /* Reduced height of the iframe */
        margin-top: 10px;
    }

    .container {
        flex-direction: column;
        gap: 15px;
    }
}

/* For medium screens (600px - 1024px) */
@media (max-width: 1024px) {
    .sidebar {
        width: 100%;
        padding: 15px;
    }

    .video-player {
        height: 350px; /* Adjusted height for medium screens */
    }

    .container {
        flex-direction: column;
    }

    .video-player iframe {
        height: 400px;
    }
}

/* For larger screens (1024px - 1920px) */
@media (min-width: 1024px) and (max-width: 1920px) {
    header h1 {
        font-size: 3rem; /* Larger font for medium screens */
    }

    .sidebar {
        padding: 20px;
        max-width: 300px;
    }

    .video-player iframe {
        height: 500px;
    }

    .container {
        flex-direction: row;
    }
}

/* Extra Large Screens (4K screens) */
@media (min-width: 1920px) {
    header h1 {
        font-size: 4.5rem;
    }

    .sidebar {
        width: 350px;
        padding: 30px;
    }

    .video-player iframe {
        height: 600px;
    }

    .video-player {
        padding: 30px;
    }

    .container {
        gap: 40px;
    }
}

/* Custom Scrollbars */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-thumb {
    background-color: #D32F2F;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background-color: #c62828;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

body {
    animation: fadeIn 1.5s ease-out;
}

/* Shadows and Depth Effects */
.shadow-lg {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
}

.shadow-md {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}
