* { margin: 0; padding: 0; box-sizing: border-box; } body { font-family: sans-serif; } .navbar { background-color: #efe2d0; width: 100%; transition: top 550ms; } .navbar a { float: left; display: block; color: #000; text-align: center; font-size: 15px; text-decoration: none; font-weight: bold; padding: 32px; } .navbar a:hover { background-color: #628563; } .navbar a.active { background-color: #774040; color: #fff; } #logo { width: 70px; height: 70px; } .mainquizpage { background-color: #263f36; color: #f5eee6; background-size: cover; width: 100%; min-height: 100vh; display: flex; flex-direction: column; justify-content: center; align-items: center; background-color: black; } .quizcontainer { align-items: center; width: 600px; height: 575px; background-color: #f5eee6; display: flex; justify-content: space-around; flex-direction: column; } .quizdetails { width: 80%; height: 50px; display: flex; justify-content: space-around; align-items: center; color: black; } .quizdetails h1 { font-size: 1.2rem; } .displayqcontainer { width: 80%; height: 8rem; display: flex; align-items: center; justify-content: center; border: 2px solid darkgray; color: black; } .displayqcontainer h1 { font-size: 1.1rem; text-align: center; padding: 3px; } .optionmain { width: 80%; height: 12rem; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-around; } .optionmain span { width: 45%; height: 3rem; border: 2px solid darkgray; overflow: hidden; } .optionbox h1 { color: #f5eee6; } span label { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: transform 0.3s; font-weight: 600; color: rgb(22, 22, 22); } span label:hover { -ms-transform: scale(1.12); -webkit-transform: scale(1.12); transform: scale(1.12); color: rgb(19, 94, 137); } input[type="radio"] { position: relative; display: none; } input[type=radio]:checked~.option { background: darkgray; } .nextcontainer { width: 50%; height: 3rem; display: flex; justify-content: center; } .nextcontainer button { width: 8rem; height: 2rem; background: none; color: rgb(25, 25, 25); font-weight: 600; border: 2px solid gray; cursor: pointer; outline: none; } .nextcontainer button::hover { background-color: rgb(143, 93, 93); } .displaycontainer { display: none; position: fixed; z-index: 1; left: 0; top: 0; width: 100%; height: 100%; overflow: auto; background-color: rgb(0, 0, 0); background-color: rgba(0, 0, 0, 0.4); flex-direction: column; align-items: center; justify-content: center; -webkit-animation: fadeIn 1.2s ease-in-out; animation: fadeIn 1.2s ease-in-out; } .box { height: 30rem; width: 25rem; background-color: rgb(43, 42, 42); display: flex; flex-direction: column; align-items: center; justify-content: space-around; } .box h1 { font-size: 1.3rem; height: 3rem; color: lightgray; text-align: center; } .displaydetails { width: 15rem; height: 10rem; display: flex; flex-direction: column; align-items: center; justify-content: space-around; } .displaydetails p { color: white; text-align: center; } .button { height: 2rem; width: 100%; display: flex; align-items: center; justify-content: center; } .button button { width: 10rem; height: 2rem; background: none; outline: none; border: 1px solid rgb(252, 242, 241); color: white; font-size: 1.1rem; cursor: pointer; } .button button:hover { background-color: rgb(83, 82, 82); } .buttoncontainer button { width: 150px; height: 40px; background: none; color: rgb(25, 25, 25); font-weight: 600; border: 2px solid gray; cursor: pointer; outline: none; margin-left: 110px; } .buttoncontainer button:hover { background-color: rgb(83, 82, 82); } .quizdetails { color: black; } footer { display: flex; justify-content: center; height: 50px; background-color: #774040; width: 100%; } footer a { font-weight: bold; color: #f5eee6; text-decoration: none; padding: 10px; line-height: 2; } footer a:hover { background-color: #628563; color: #000; }