/* style.css */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: #f8f9fa;
    /* A very light gray, almost white */
}

/* Prevent body scrolling when an overlay is active */
body.body-no-scroll {
    overflow: hidden;
}

.wrapper {
    display: flex;
    width: 100%;
    margin-top: 50px;
}

#sidebar {
    width: 250px;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 1000;
    background: #f8f9fa;
    color: #333;
    transition: transform 0.3s ease-in-out;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.1);
    overflow-y: auto; /* Allow vertical scrolling if content is too long */
}

#sidebar.collapsed {
    transform: translateX(-100%);
}

.sidebar-header {
    padding: 20px;
    background: #ffffff;
    border-bottom: 1px solid #dee2e6;
}

#sidebar ul.components {
    padding: 20px 0;
}

#sidebar ul li a {
    padding: 10px;
    font-size: 1.1em;
    display: block;
    color: #495057;
    text-decoration: none;
}

#sidebar ul li a:hover {
    color: #007bff;
    background: #e9ecef;
}

#content {
    width: 100%;
    /* Adjust padding to account for the fixed sidebar button */
    padding-left: 20px;
    padding-top: 20px;
    min-height: 100vh;
    transition: all 0.3s;
}

/* New button styles */
#sidebarCollapse {
    position: fixed;
    top: 20px;
    left: 260px;
    z-index: 1001;
    background-color: #ffffff;
    border: 1px solid #dee2e6;
    border-radius: 5px;
    width: 40px;
    height: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: transform 0.3s ease-in-out;
}

#sidebar.collapsed~#sidebarCollapse {
    transform: translateX(-250px);
}

.hamburger-line {
    width: 20px;
    height: 2px;
    background-color: #000000;
    margin: 3px 0;
    display: block;
}

/* Sidebar Overlay */
#sidebar-overlay {
    display: none; /* Hidden by default */
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999; /* Below sidebar, above content */
    cursor: pointer;
    transition: opacity 0.3s ease-in-out;
}

/* Custom image styling for screenshots */
.app-screenshot {
    width: 378px;
    /* Approximately 10cm wide at 96 DPI */
    height: auto;
    /* Automatically adjust height to maintain aspect ratio */
    border: 1px solid #dee2e6;
    background-color: #f8f9fa;
    padding: 10px;
    /* Space between the image and the border */
}

/* For smaller screens, allow images to be more flexible */
@media (max-width: 576px) {
    .app-screenshot {
        width: 100%;
        height: auto;
    }
    #content {
        /* Adjust padding to account for the fixed sidebar button */
        padding-left: 20px;
        padding-top: 50px;    }
}

/* Code Block Styling */
pre {
    background-color: #f4f4f4;
    border: 1px solid #ddd;
    border-left: 3px solid #007bff;
    color: #666;
    page-break-inside: avoid;
    font-family: monospace;
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 1.6em;
    max-width: 100%;
    overflow: auto;
    padding: 1em 1.5em;
    display: block;
    word-wrap: break-word;
}