/* General Reset and Styling */
html, body {
    font-family: "Chakra Petch", sans-serif;
    font-weight: 400;
    font-style: normal;
    height: 100%;
    margin: 0; /* Add this to remove default margins */
    overflow: hidden; /* Prevent body scrolling */
}

.page {
    display: flex;
    height: calc(100vh - 120px); /* Use viewport height minus header height */
    overflow: hidden; /* Prevent the page itself from scrolling */
}

/* Style for the main content area */
main {
    flex-grow: 1;
    background-color: #f0f0f0;
    padding: 20px;
    box-sizing: border-box;
    margin-top: 0;
}

.site-slogan {
    font-family: "Gugi", sans-serif;
    margin: 0;
    padding: 0;
    overflow-y: hidden;
    font-size: 3em;
    font-weight: bold;
    color: steelblue;
    white-space: nowrap;
}
/* Style for the site header */
.site-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 120px;
    background-color: #ffffff;
    padding: 0 20px;
    box-sizing: border-box;
}

/* Right-aligned container */
.header-right {
    display: flex;
    align-items: center;
}

/* Site header title (logo link) */
.site-header__title {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    margin-right: 20px;
}



/* Style for the sidebar */
.sidebar {
    background-color: #000030;
    color: white;
    padding: 20px;
    box-sizing: border-box;
    margin-right: 20px;
    overflow-y: auto;
}
.plugin {
    flex: 1;
    overflow-y: auto; /* Make entire plugin scrollable */
    height: calc(100vh - 200px);
    padding: 20px;
    box-sizing: border-box;
}
.login-overlay {
    position: fixed; /* Ensure it's fixed to the viewport */
    top: 0; /* Start at the very top */
    left: 0; /* Start at the very left */
    width: 100vw; /* Full viewport width */
    height: 100vh; /* Full viewport height */
    background-color: rgba(0, 0, 0, 0.9); /* Semi-transparent black background */
    display: flex;
    justify-content: center; /* Center horizontally */
    align-items: center; /* Center vertically */
    z-index: 9999; /* Ensure it's above all other elements */
}

.login-box {
    width: 300px;
    height: 200px;
    background-color: white;
    padding: 20px;
    box-shadow: 0px 0px 10px 0px rgba(0,0,0,0.5); /* Optional: Adds a shadow for better visibility */
    display: flex;
    flex-direction: column;
    justify-content: space-around; /* Adjusts spacing between elements */
}

    .login-box form {
        display: flex;
        flex-direction: column;
    }

    .login-box input[type="text"],
    .login-box input[type="password"],
    .login-box button {
        margin-bottom: 10px; /* Adds space between form elements */
    }

.busy-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); /* Semi-transparent background */
    z-index: 1000; /* Ensure it appears above other elements */
    display: flex;
    justify-content: center;
    align-items: center;
}

.busy-overlay-content {
    color: white;
    background-color: black;
    padding: 20px;
    border-radius: 8px;
    border-width: 4px;
    border-color: white;
    border-style: solid;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    text-align: center;
}

.busy-loading-gif {
    width: 150px;
    height: 150px;
    margin-bottom: 10px;
}


/* Style for the parameters section */
.parameters {
    position: relative;
    background-color: #000030;
    padding: 20px;
    margin-bottom: 10px;
    box-sizing: border-box;
    color: white;
}

/* Style for the results section */
.results {
    background-color: #e0e0e0;
    padding: 20px;
    box-sizing: border-box;
}


.nav-menu {
    padding: 0.25rem;
    margin-left: 0.1rem; /* Add 20px margin on the left */
    margin-right: 0.1rem; /* Add 20px margin on the right */
}

/* First-level <li> styling */
.nav-menu > .plugins li > a {
    color: white;
    font-size: 120%;
    text-decoration: none;
    list-style-type: none;
}
.nav-menu .plugins li > a:hover {
    color: #e36721;
}
    /* Selected state */
    .nav-menu .plugins li > a.selected {
        color: #ffa85c; 
    }
.nav-menu > .plugins li > h4 {
    color: white;
    font-family: "Chakra Petch", sans-serif;
    font-weight: bold;
    text-decoration: none;
    list-style-type: none;
}
.nav-menu .navbar-title {
    color: lightskyblue;
    font-family: "Chakra Petch", sans-serif;
    font-weight: bold;
    font-style: italic;
}
.nav-menu > .plugins > ul > li {
    margin: 1em 0 0 0;
    list-style-type: none;
}

/* Nested <li> styling (second-level or deeper) */
.nav-menu li li {
    font-size: 100%;
    font-weight: normal;
    font-style: normal;
    list-style-type: square;
    color: white;
    margin: 0.3em 0;
    list-style-type: none;
}

/* Shared styles for logout and hamburger menu buttons */
.menu-actions {
    display: flex;
    align-items: center; /* Align vertically */
    gap: 10px; /* Space between buttons */
}

.logout-button, .hamburger-menu {
    height: 34px;
    cursor: pointer;
}
pre {
    background-color: #1e1e1e !important;
    color: #dcdcdc;
    font-family: 'Courier New', Courier, monospace;
    padding: 15px;
    border-radius: 5px;
    overflow-x: auto;
    white-space: pre-wrap;
}

code {
    font-family: 'Courier New', Courier, monospace;
}




button.hyperlink {
    background: none;
    border: none;
    color: #007bff;
    text-decoration: underline;
    cursor: pointer;
    padding: 0;
    font: inherit;
    text-align: left;
    vertical-align: top;
}

    button.hyperlink:hover {
        color: #0056b3;
    }


/* Small Screens */
@media (max-width: 640.98px) {
    .page.sidebar-hidden .sidebar {
        transform: translateX(0);
    }
    /* Style for the site logo */
    .site-logo {
        /*width: 100%;*/
        width: 120px; /* Adjust as needed */
        object-fit: contain;
    }

    /* Adjust Main Content Position */
    .page {
        display: flex;
        flex-direction: column;
        min-height: calc(100vh - 134px);
    }

    main {
        flex-grow: 1;
        padding: 20px;
        box-sizing: border-box;
    }

    .sidebar {
        position: fixed;
        top: 134px; /* 100px (logo) + 34px (header-bottom) */
        left: 0;
        width: 90%; /* 90% of screen width */
        height: calc(100vh - 134px);
        z-index: 1000;
        transform: translateX(-100%);
        transition: transform 0.3s ease-in-out;
    }

    .hamburger-menu {
        display: block;
    }

    .header-bottom {
        display: flex;
        flex-direction: column; /* Stack elements vertically */
        align-items: flex-end; 
    }

    .menu-actions {
        order: 2; /* Ensure menu actions are placed after the slogan */
    }
}




/* Large Screens */
@media (min-width: 641px) {

    /* Style for the site logo */
    .site-logo {
        /*width: 100%;*/
        height: 100px; /* Adjust as needed */
        object-fit: contain;
    }
   /* Adjust site-slogan font size back to original */
    .sidebar {
        position: relative;
        width: 400px;
        height: auto;
        transform: none; /* Sidebar always visible */
    }

    .hamburger-menu {
        display: none; /* Hide on large screens */
    }
    .header-bottom {
        display: flex;
        flex-direction: column; /* Maintain column layout for small screens */
        align-items: flex-end; /* Align items to the right */
    }

    .menu-actions {
        display: flex;
        flex-direction: row; /* Align buttons horizontally */
        gap: 10px; /* Add spacing between buttons */
        order: 2; /* Ensure buttons are below the slogan */
    }
}
