/* General styles */
.learnflash-outter	{
	margin-top: 1em !important;
}

.learnflash-badge {
    display: inline-block;
    padding: 5px 10px;
    border-radius: 3px;
    font-weight: bold;
    font-size: 0.8rem;
    margin: 0 0 0 10px;
    text-align: center;
}

.learnflash-completed {
    background-color: #28a745; /* Green for completed */
    color: #fff;
}

.learnflash-in-progress {
    background-color: blue;
    color: #fff;
}

.learnflash-mark-complete {
    margin-left: 10px;
}

.ld-topic-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #e5e5e5;
}

.ld-topic-row a {
    color: #333;
    text-decoration: none;
}

.ld-topic-row a:hover {
    color: #007bff;
}

.ld-status-icon {
    display: inline-block;
    width: 20px;
    height: 20px;
    margin-right: 10px;
    border-radius: 50%;
    text-align: center;
    line-height: 20px;
    font-size: 12px;
}

.ld-status-complete {
    background-color: #28a745;
    color: #fff;
}

.ld-status-incomplete {
    background-color: #ccc;
    color: #fff;
}
	
/* Sidebar styles */
/* Sidebar styles */
.sidebar {
    position: fixed;
    left: -250px;
    top: 0;
    width: 250px;
    height: 100vh;
    background-color: #f8f9fa;
    box-shadow: 2px 0 5px rgba(0,0,0,0.5);
    transition: left 0.3s;
    z-index: 1000;
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    flex-shrink: 0;
    padding: 10px;
    background-color: #ddd;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sidebar-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.sidebar-logo {
    flex-shrink: 0;
    padding: 10px;
    max-height: 100px;
    overflow: hidden;
}

.sidebar-logo img {
    max-width: 100%;
    height: auto;
}

.sidebar-scroll {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
}

/* Custom scrollbar for WebKit browsers */
.sidebar-scroll::-webkit-scrollbar {
    width: 6px;
}

.sidebar-scroll::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.sidebar-scroll::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 3px;
}

.sidebar-scroll::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Sidebar list styles */
.sidebar ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
}

.sidebar li {
    border-bottom: 1px solid #ccc;
    padding: 8px 0;
}

.sidebar a {
    color: #808080;
    text-decoration: none;
    font-size: 0.9em;
    display: block;
    transition: color 0.3s;
}

.sidebar a:hover {
    color: black;
}

.sidebar h4 {
    font-size: 1.2em;
    margin: 0;
    padding: 10px 0;
}

.sidebar-module-title {
    flex-shrink: 0;
}

.sidebar-topics-list {
    flex: 1;
}


/* Rest of your existing CSS remains unchanged */

@media (max-width: 991px) {
    .breadcrumb-container {
        display: none; /* Hide breadcrumb on mobile */
    }
    .progress-container .progress {
        width: 100%; /* Full width for the progress bar on its own row */
    }
    .hamburger-menu-button {
        margin-right: auto; /* Push everything else to the right */
    }
    .learnflash-page-header .row > * {
        flex: 0 0 auto; /* Prevents elements from taking full width */
        width: auto; /* Width auto for natural content width */
    }
    .learnflash-page-header .row {
        flex-wrap: nowrap; /* Prevents wrapping of elements */
        align-items: center; /* Align items in a neat row */
    }
}

@media (min-width: 992px) {
    .progress-container .progress {
        width: 80%; /* Reduced width on desktop */
    }
}

/* Ensures accordion button elements are laid out using flexbox */
.accordion-button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%; /* Ensure the button stretches full width of its container */
}

/* Style for the module link to allow it to grow and fill space as needed */
.accordion-button .module-link-container {
    flex-grow: 1;
    margin-right: 10px; /* Ensures some space between the module name and progress bar */
}

/* Fixed width for progress and other components */
.accordion-button .progress-container,
.accordion-button .ld-expand-button,
.accordion-button .topics-count {
    flex-shrink: 0; /* Prevents these elements from shrinking */
}

/* Specific styles for the progress bar container */
.accordion-button .progress-container {
    width: 200px; /* Fixed width for progress bar container */
    display: flex;
    justify-content: flex-end; /* Aligns the progress bar to the right */
}

/* Topic count and chevron icon placement */
.accordion-button .topics-count,
.accordion-button .ld-expand-button {
    margin-left: 10px; /* Spacing between elements */
}

/* General responsive adjustments for accordion on mobile */
@media (max-width: 768px) {
    .accordion-button .progress-container {
        width: 80px; /* Significantly reduce width on mobile */
    }

    /* Ensure module link container uses available space efficiently */
    .accordion-button .module-link-container {
        flex-grow: 1;
        white-space: nowrap; /* Prevent module names from breaking */
        overflow: hidden;
        text-overflow: ellipsis; /* Add ellipsis if the text is too long */
    }

    /* Smaller margins and font sizes for mobile */
    .accordion-button .topics-count,
    .accordion-button .ld-expand-button {
        margin-left: 5px; /* Smaller left margin on mobile */
        font-size: 0.8rem; /* Smaller font size for icons and text */
    }

    /* Adjust the font size and padding within the accordion button for better fit */
    .accordion-button {
        padding: 10px 5px; /* Reduce padding to save space */
    }

    /* Hide additional texts or icons if not crucial for mobile view */
    .accordion-button .ld-expand-button i {
        display: none; /* Optionally hide the down chevron on mobile */
    }

    /* Adjust the overall size and layout of progress bars */
    .accordion-button .progress {
        height: 5px; /* Thinner progress bars on mobile */
    }

    /* Reduce size and padding of list items within accordion */
    .accordion-body ul.list-unstyled {
        padding-left: 10px; /* Smaller padding for list items */
    }

    .accordion-body .ld-topic-row {
        padding: 5px 0; /* Reduce vertical padding in list items */
    }
}
