html {
    overflow-x: hidden;
    height: 100%;
    margin: 0;
    padding: 0;
}

body {
    font-family: Arial, sans-serif;
    background-color: #555fb5; /* Light mode background color */
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    height: 100%; /* Full height to ensure footer is pushed down */
    color: #fcf7ff; /* Light mode text color */
}

/* Container Styles */
.container {
    width: 90%; /* Slightly reduced width for a tighter look */
    max-width: 600px; /* Set a maximum width for the container */
    margin: 20px auto; /* Reduced margin for smaller spacing */
    padding: 15px; /* Reduced padding */
    background-color: #fcf7ff; /* Light mode content background */
    border-radius: 5px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    flex: 1; /* Allows the container to grow and push the footer down */
    color: #14110f; /* Dark text for the container */
}

h1, p {
    text-align: center;
}

ul {
    list-style: none;
    padding: 0;
}

ul li {
    margin: 8px 0; /* Reduced margin for list items */
    text-align: center;
}

ul li a {
    color: #72a1e5; /* Updated link color */
    text-decoration: none;
    font-size: 18px;
}

ul li a:hover {
    text-decoration: none;
    color: #1e0a74; /* Updated hover link color */
    transition: ease 0.2s;
}

#submit-container {
    position: sticky;
    bottom: 0;
    background: #fcf7ff; /* Updated container background */
    padding: 10px;
    border-radius: 3px;
}

#submit-btn {
    padding: 10px 15px;
    font-size: 16px;
    cursor: pointer;
    background-color: #72a1e5; /* Updated button background */
    color: #fcf7ff; /* Updated button text color */
    border: none;
    border-radius: 4px;
}

#submit-btn:hover {
    background-color: #1e0a74; /* Updated button hover color */
    transition: ease 0.2s;
    transform: scale(1.05);
}

#back-to-top {
    position: fixed; /* Change to fixed for proper scrolling behavior */
    top: 20px; 
    left: 20px; 
    display: none; /* Initially hidden */
    background: #72a1e5;
    color: #fcf7ff;
    border: none;
    border-radius: 5px;
    padding: 8px 12px; /* Adjusted size */
    font-size: 14px; /* Adjusted font size */
    cursor: pointer;
    z-index: 1000;
}
@media(max-width: 700px){
    #back-to-top{
        /* top: 30px; */
        right: 20px;
        left: 459px;
        top:40px;
    }
}
@media(max-width: 576px){
    #back-to-top{
        /* top: 30px; */
        right: 20px;
        left: 280px;
        top:40px;
    }
}

#back-to-top:hover {
    background-color: #1e0a74;
    transition: ease 0.2s;
    transform: scale(1.05);
}

body.dark-mode #back-to-top:hover {
    background-color: #1e0a74;
    transition: ease 0.2s;
    transform: scale(1.05);
}

#back-to-top.show {
    display: block; /* Show the button when needed */
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: #fcf7ff;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close:hover,
.close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

/* Other styles */
#score-display {
    font-size: 20px;
    margin-bottom: 20px;
}

.quiz-note {
    font-size: small;
    font-style: italic;
    margin: 0;
}

.show-answer-btn {
    margin-top: 10px;
    padding: 5px 10px;
    background-color: #72a1e5;
    color: #fcf7ff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.show-answer-btn:hover {
    background-color: #1e0a74;
    transition: ease 0.2s;
}

button {
    margin-top: 10px;
    padding: 5px 10px;
    background-color: #72a1e5;
    color: #fcf7ff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

button:hover {
    background-color: #1e0a74;
    transform: scale(1.05);
    transition: ease 0.2s;
}

.back-button {
    padding: 10px 20px;
    margin-bottom: 15px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
}

/* Footer Styling */
footer {
    background-color: #1e0a74; /* Updated footer background */
    text-align: center;
    border-top: 1px solid #72a1e5;
    width: 100%;
    flex-shrink: 0;
    color: #fcf7ff; /* Updated footer text color */
    /* Add this to your CSS file */
    margin-top: 0; /* Remove any top margin */
    padding: 10px 0; /* Adjust padding as needed */

}

footer h3 {
    margin-bottom: 10px;
    color: #fcf7ff;
}

footer p {
    margin: 5px 0;
    color: #72a1e5;
}

footer a {
    color: #fcf7ff;
    font-weight: bold;
}

footer a:hover {
    text-decoration: underline;
}
@media (max-width: 600px) {
    footer h3 {
        font-size: 15px;
    }

    footer p {
        font-size: 12px;
    }
    footer a {
        font-size: 12px;
    }
}

#cybr-quiz {
    color: #72a1e5;
    text-decoration: none;
}

#cybr-quiz:hover {
    color: #1e0a74;
    transition: ease 0.2s;
}

/* Dark Mode Styles */
body.dark-mode {
    background-color: #14110f; /* Dark mode background color */
    color: #fcf7ff; /* Dark mode text color */
}

body.dark-mode .container {
    background-color: #1e1b43; /* Dark mode container background */
    color: #fcf7ff; /* Dark mode container text color */
}


body.dark-mode ul li a {
    color: #72a1e5; /* Dark mode link color */
}

body.dark-mode ul li a:hover {
    color: #fcf7ff; /* Dark mode link hover color */

}

body.dark-mode #submit-btn,
body.dark-mode .show-answer-btn,
body.dark-mode button {
    background-color: #72a1e5; /* Dark mode button background */
    color: #fcf7ff; /* Dark mode button text color */
}

body.dark-mode #cybr-quiz:hover {
    color: #fcf7ff;
    transition: ease 0.2s;
}

body.dark-mode #submit-container{
    background:  #14110f; /* Updated container background */
}

body.dark-mode #back-to-top {
    background: #72a1e5; /* Dark mode button background */
}

.dark-mode button:hover, body.dark-mode #submit-btn:hover {
    background-color: #1e0a74; /* Change this to a suitable hover color for dark mode */
    transform: scale(1.05); /* Slightly grow the button on hover */
}

/* In your CSS file */
.dark-mode .correct {
    background-color: #2c4d2e; /* Dark green for correct */
}

.dark-mode .partially-correct {
    background-color: #c6a22c; /* Darker yellow for partially correct */
}

.dark-mode .incorrect {
    background-color: #7c1a1a; /* Dark red for incorrect */
}

/* Default styles */
.correct {
    background-color: #d4edda; /* Soft green for correct */
}

.partially-correct {
    background-color: #ffeeba; /* Soft yellow for partially correct */
}

.incorrect {
    background-color: #f8d7da; /* Soft red for incorrect */
}

/* Style for the slider */
span {
    cursor: pointer; /* Change cursor to pointer for the slider */
}

#toggle-label {
    display: flex;
    align-items: center;
    color: #fcf7ff; /* Light mode text color */
    font-weight: bold;
}

/* Media Query */
@media (max-width: 800px) {
    #toggle-label {
        color: #14110f; 
    }
    .dark-mode #toggle-label {
        color: #fcf7ff; 
    }
}

