/* Style for page Accident_prevention*/

body,
h2,
h4,
h5,
article,

/* Resetting default margin and padding for list elements */
ul {
    margin: 0;
    padding: 0;
}

/* Making sure HTML and body take full height of the viewport */
body, html {
    height: 100%;
}

/* Applying box-sizing border-box to all elements with padding */
* {
    box-sizing: border-box;
    padding: 3px;
}

/* Styling for the body */
body {
    font-family: "calibri";
    line-height: 1.6;
    background-color: #f4f4f4;
}

/* Styling for the header */
header {
    background-color: rgb(19, 26, 46);
    height: 15%;
    text-align: center;
    font-size: 20px;
}

/* Styling for the logo image */
.logo_img {
    height: 75%; 
    width: 15%;
    float: right;
    margin-right: 1%;
    margin-top: 1%;
}

/* Styling for the navigation */
nav {
    margin-top: 0.5%;
    margin-left: 15%;
}

/* Styling for list items */
li {
    display: inline;
}

/* Styling for login and sign-in links in the navigation */
.login_signin_nav {
    float: left;
    margin-left: 1%;
    margin-top: -4%;
}

/* Styling for links */
a {
    text-decoration: none;
    color: white;
}

/* Hover effect for links */
a:hover {
    border-bottom: 2px solid rgba(240, 219, 219, 0.436);
}

/* Styling for dropdown content */
.dropdown-content {
    display: none;
    position: absolute;
    font-size: 15px;
    left: 4%;
    width: 105%;
    background-color: rgb(19, 26, 46);
}

/* Styling for dropdown links */
.dropdown-content a {
    display: block;
    padding: 7%;
}

/* Hover effect for dropdown links */
.dropdown-content a:hover {
    border-bottom: none;
    background-color: rgba(240, 219, 219, 0.436);
}

/* Display dropdown content on hover */
.dropdown:hover .dropdown-content {
    display: block;
}

/* CSS for inactive links */
a[href="#"]:hover::after {
    content: "Link is not active"; 
    display: inline-block; 
    position: absolute;
    background-color: #333;
    color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    z-index: 1;
    margin-top: 20px;
    margin-right: -180px; /* Adjust the distance from the link */
}

/* Styling for the main content area */
.main_content {
    display: flex;
    justify-content: space-evenly;
    flex-wrap: wrap;
    padding: 20px;
    background-color: rgb(202, 183, 160);
    width: 100%;
}

/* Styling for h2 */
h2 {
    color: black;
    text-decoration: underline;
    font-weight: bold;
}

/* Styling for h4 */
h4 {
    margin-top: 20px;
    margin-right: 25px;
    margin-left: 25px;
}

/* Styling for h5 */
h5 {
    margin-top: 10px;
    margin-right: 25px;
}

/* Styling for article */
article {
    font-size: 20px;
}

/* Styling for the opening section */
.opening {
    max-width: 80%;
    margin: 0 auto;
    text-align: right;
}

/* Styling for text container */
.text-container {
    width: 680px; 
    height: 780px; 
    background-color: rgba(243, 244, 240, 0.723);
    border: 1.5px solid rgb(19, 26, 46);
    margin-bottom: 20px; 
    border-radius: 12%;
    margin-top: 10px;
    margin-right: 20px;
}

/* Styling for paragraphs within text container */
.text-container p {
    margin-top: 5px; 
    margin-right: 25px;
    margin-left: 25px;
    font-size: 17px;
}

/* Styling for accident image */
.accident_img {
    width: 400px;
    height: auto;
    margin-right: 20%;
    margin-top: 5%;
    border-radius: 5%;
}

/* Styling for video container */
.video-container {
    width: 640px;
    height: 360px;
    border-radius: 2%;
    margin-right: 18px;
    margin-top: 5px;
}

/* Additional styling for text container */
.text-container {
    margin-top: 10px;
}

/* Styling for button area */
.button_area {
    display: flex;
    justify-content: space-evenly;
    flex-wrap: wrap;
    padding: 15px;
    background-color: rgb(202, 183, 160);
    margin-top: -20px;
}

/* Styling for quiz button */
.button_quiz {
    background-color: #007bff;
    color: white;
    padding: 10px 20px;
    border-radius: 5px;
    font-size: 16px;
    text-align: center;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
    margin-top: auto;
    width: 150px;
}

/* Hover effect for quiz button */
.button_quiz:hover {
    background-color: #0056b3;
}

/* Styling for footer */
footer {
    background-color: rgb(19, 26, 46);
    color: #ffffffea;
    text-align: center;
    padding: 1%;
    width: 100%;
    height: 7%;
    display: block;
}

/* Styling for contact */
.contact {
    margin-top: -4%;
    margin-right: 90%;
    float: left;
}

/* Media query for medium screens */
@media screen and (max-width: 1500px) {
    /* Adjusting sizes for video and image containers */
    .video-container {
        width: 320px;
        height: 230px;
        margin-right: 35px;
    }
    
    .accident_img {
        width: 320px;
        height: 230px;
        margin-right: 35px;
    }
    
    /* Adjusting size for text container */
    .text-container {
        width: 440px; 
        height: 780px;
    }
}

/* Media query for small screens */
@media screen and (max-width: 900px) {

    /* Adjusting logo size */
    .link_logo {
        width: 30%;
        height: 80%;
        margin-left: auto;
    }

    /* Removing hover effect for logo */
    .link_logo:hover {
        border-bottom: none;
    }

    /* Adjusting logo image size */
    .logo_img {
        width: 100%;
        height: 100%;
    }

    /* Adjusting header for smaller screens */
    header {
        display: flex;
        align-items: center;
        font-size: 15px;
    }

    /* Adjusting login and sign-in navigation */
    .login_signin_nav {
        margin-left: auto;
    }

    /* Displaying list items as blocks */
    li {
        display: block;
    }

    /* Adjusting contact information */
    .contact {
        margin-top: -6%;
        font-size: 12px;
        margin-top: -55px;
    }

    /* Adjusting dropdown content width */
    .dropdown-content {
        left: 15%;
        width: 70%;
    }

    .video-container {
        width: 320px;
        height: 230px;
        margin-right: 10px;
    }
    
    .accident_img {
        width: 320px;
        height: 230px;
        margin-right: 10px;
        margin-top: -10px;
    }
    
    /* Adjusting size for text container */
    .text-container {
        width: 350px; 
        height: 900px;
    }

}











