* {
    margin: 0;
    padding: 0;
    font-family: Arial, Helvetica, sans-serif;
    box-sizing: border-box; /* Ensures that padding and border are included in the element's total width and height */
}

html, body {
    width: 100%;
    height: 100%;
    overflow-x: hidden; /* Prevents horizontal scrolling */
}

main {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh; /* Ensures main is at least as tall as the viewport */
}

.simulation-container {
    background-color: rgba(220, 229, 236, 1);
    width: 90%; /* Responsive width */
    max-width: 1000px; /* Max width to maintain design integrity */
    min-height: 700px; /* Minimum height */
    margin: 20px auto; /* Auto margins for centering */
    margin-top: 0px;
}

.title {
    margin: 0;
    padding: 5px;
    letter-spacing: 0.1em;
    background-color: rgb(0, 140, 255);
    color: white;
    display: flex;
    justify-content: center;
    width: 100%; /* Ensure it fills the container */
    z-index: 2;
}

.content-container, .instruction-main {
    position: relative; /* Adjusted to relative for better flow control */
    padding: 10px;
    z-index: 2;
}

.content-main, .instruments {
    position: relative; /* Changed to relative */
    display: block; /* Using block to better handle responsive adjustments */
    margin: 10px auto; /* Centering */
    width: 80%; /* Relative width */
    text-align: justify;
    font-size: 1em; /* Relative font size */
    z-index: 2;
}
.instruments-img {
    position: absolute;
    top: 100px;
    width: 560px;
    left: 110px;
    height: auto;
    display: block;
    margin: 10px auto;
    
    
}

.instruction-main1, .step {
    position: relative;
    display: block;
    width: 100%; /* Ensure full width usage */
    z-index: 2;
    
    left: 1%;
}

.step-number {
    background-color: rgb(20, 117, 228);
    color: white;
    padding: 5px 7px;
    border-radius: 5px;
}

.next-exp {
    position: absolute;
    
    left: 85%;
    top: 285%;
    padding: 10px 15px;
    color: white;
    background-color: rgb(20, 117, 228);
    font-weight: 600;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    z-index: 2;

   
}

@media (max-width: 768px) {
    .simulation-container {
        width: 95%; /* Using more of the screen on smaller devices */
    }

    .content-main, .instruments, .instructions {
        width: 90%; /* Slightly wider on small screens */
        font-size: 0.9em; /* Smaller font size */
    }

    
}

@media (max-width: 480px) {
    .title, .content-main, .instruments, .instructions {
        font-size: 0.8em; /* Even smaller font sizes for very small devices */
    }

   
}
