/* CSS for practice pages */

html, body {
    height: 100%;
    margin: 0;
    overflow-x: hidden;
    background-color: #2e3236;
    color: #fff;
    font-family: Arial, Helvetica, sans-serif;
}

#main {
    display: flex;
    height: 100vh;
}

.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
}

.sidebar {
    position: fixed;
    top: 56px; /* Height of the navbar */
    bottom: 0;
    width: 250px;
    padding: 20px;
    background-color: #343a40;
    border-right: 1px solid #fff;
    overflow-y: auto; /* Allow scrolling for sidebar content */
}

.sidebar h2 {
    font-size: 2rem;
    margin-bottom: 20px;
}

.sidebar .section {
    margin-bottom: 15px;
}

.sidebar .section h3 {
    font-size: 1.5rem;
    margin-top: 20px;
    margin-bottom: 10px;
}

.clear-filter-button{
    width: 200px;
}

.checkbox {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
    font-size: 16px;
}

.checkbox input[type="checkbox"] {
    margin-right: 10px;
}

.checkbox:hover,
.checkbox:checked {
   background-color: #707070 ;
}


.main-content {
    margin-left: 250px; /* Width of the sidebar */
    margin-top: 56px; /* Height of the navbar */
    padding: 20px;
    overflow-y: auto; /* Allow scrolling for main content */
    height: calc(100vh - 56px); /* Full height minus navbar height */
}


.clear-filters-button-mobile {
    display: none;
}

.sidebar::-webkit-scrollbar {
    width: 8px;
}

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

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

.switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
  }
  
  .switch input { 
    opacity: 0;
    width: 0;
    height: 0;
  }
  
  .slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    -webkit-transition: .4s;
    transition: .4s;
  }
  
  .slider:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    -webkit-transition: .4s;
    transition: .4s;
  }
  
  input:checked + .slider {
    background-color: #2196F3;
  }
  
  input:focus + .slider {
    box-shadow: 0 0 1px #2196F3;
  }
  
  input:checked + .slider:before {
    -webkit-transform: translateX(26px);
    -ms-transform: translateX(26px);
    transform: translateX(26px);
  }
  
  /* Rounded sliders */
  .slider.round {
    border-radius: 34px;
  }
  
  .slider.round:before {
    border-radius: 50%;
  }

  .main-content {
    flex-grow: 1;
    padding: 20px;
}

.main-content-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #dee2e6;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.dropdown-item.active, .dropdown-item:active {
    color: var(--bs-dropdown-link-active-color);
    text-decoration: none;
    background-color: #6c757d;
}

.btn-outline-secondary {
    --bs-btn-color: #fff;
    --bs-btn-border-color: #6c757d;
}

.sort-by-component {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #dee2e6;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.sort-by-dropdown .dropdown-menu {
    min-width: auto;
}

.sort-by-dropdown .dropdown-item.active {
    font-weight: bold;
}

@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        height: calc(100vh - 56px); /* Full height minus navbar height */
    }
    .main-content {
        margin-left: 0;
    }
    .clear-filters-button {
        display: none;
    }
    .clear-filters-button-mobile {
        display: block;
        background-color: #dc3545;
        color: white;
        border: none;
        padding: 10px;
        cursor: pointer;
        width: 100%;
        margin-top: 10px;
    }
    .clear-filters-button-mobile:hover {
        background-color: #c82333;
    }
}

/* Quiz Box */

*{
    margin: 0;
    padding: 0;
    font-family: 'Poppins',sans-serif;
    box-sizing: border-box;
}

.app{
    background: #fff;
    width: 90%;
    max-width: 1100px;
    margin: 70px auto 0;
    border-radius: 10px;
    padding: 30px;
}
.app h1{
    font-size: 25px;
    color: #001e4d;
    font-weight: 600;
    border-bottom: 1px solid #333;
    padding-bottom: 30px;
}
.quiz{
    padding: 20px 0;
}
.quiz h2{
    font-size: 18px;
    color: #001e4d;
    font-weight: 600;
}
.ans-key{
    background: #fff;
    color: #222;
    font-weight: 500;
    width: 100%;
    border: 1px solid #222;
    padding: 10px;
    margin: 10px 0;
    text-align: left;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
}
.ans-key:hover:not([disabled]){
    background: #222;
    color: #fff;
}
.ans-key:disabled{
    cursor: no-drop;
}
#next-btn{
    background: #001e4d;
    color: #fff;
    font-weight: 500;
    width: 150px;
    border: 0;
    padding: 10px;
    margin: 20px auto 0;
    border-radius: 4px;
    cursor: pointer;
    display: none;
}
.correct{
    background: #9aeabc;
}
.incorrect{
    background: #ff9393;
}

/* problems CSS */
.problem-card {
    background-color: #084154 ;
    color: #fff;
    padding: 20px;
    margin: 30px 20px;
    border-radius: 15px;
    display: flex;
    flex-direction: column;
}
.problem-details {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.problem-tags {
    display: flex;
    gap: 10px;
}
.problem-tag {
    background-color: #000;
    color: #fff;
    padding: 5px 10px;
    border-radius: 25px;
}
.see-problem-button {
    background-color: #5794A8;
    color: #fff;
    font-weight: bold;
    padding: 5px 15px;
    border: none;
    border-radius: 25px;
    /* display: flex; */
    align-items: center;
    gap: 5px;
    cursor: pointer;
    margin-top: 10px;
}

.problem-description,
.problem-solution,
.problem-reference,
.problem-practice {
    background-color: #343a40;
    color: #fff;
    padding: 15px;
    margin: 10px 0;
    border-radius: 10px;
}
.section-title {
    font-size: 18px;
    font-weight: bold;
}

.btn{
    --bs-btn-color: #fff;
}
