I am trying to create a drop down button within a navigation bar. The button either is the entire width of the page or disrupts the that creates my navigation bar. Sorry about the length of the css code, I thought it was better to include all relevant parts in case there was something wrong other than the button.
My css code:
.website-title-layout {
color:rgb(255, 165, 0);
background-color:rgb(0, 191, 255);
text-align: center;
border-radius: 0px;
position: fixed;
top: 0;
right: 0;
width: 100%;
margin-bottom: 100px;
}
.website-title-layout a {
color:rgb(255, 165,0)
font-family: Merriweather, serif;
padding: px 5px 5px 5px;
display: inline-block;
}
.website-title a {
text-decoration: none;
font-size: 60px;
color:rgb(255, 255, 255);
font-weight: bold;
posistion: fixed;
}
.website-title a:hover {
background-color:rgb(255, 165, 0);
}
.page-title a {
text-decoration: none;
font-size: 40px;
color:rgb(255, 255, 255);
}
.page-title a:hover {
background-color:rgb(255, 165, 0);
}
.main-navigation-bar {
text-align: center;
font-family: "Merriweather", serf;
border-radius: 0px;
background-color:rgb(0, 191, 255);
posistion: fixed;
}
.main-navigation-bar a {
text-decoration: none;
color:rgb(255, 255, 255);
font-size: 25px;
padding: 10px 10px 10px 10px;
display: inline-block;
posistion: fixed;
}
.main-navigation-bar a:hover {
background-color:rgb(255, 165, 0);
}
/* got the answer for the above from https://stackoverflow.com/questions/676324/div-background-color-to-change-onhover from user3689455 comment for the a:hover*/
.drop-down-btn {
background-color:rgb(0, 191, 255);
color:rgb(255, 255, 255);
padding: 10px 10px 10px 10px;
font-size: 25px;
border: none;
font-family: "Merriweather", serif;
}
.drop-downn-btn a {
text-decoration: none;
background-color:rgb(0, 191, 255);
color:rgb(255, 255, 255);
padding: 10px 10px 10px 10px;
font-size: 25px;
}
.dropdown {
posistion: relative;
display: inline-block;
}
.drop-down-content {
display: none;
posistion:absolute;
background-color:rgb(0, 191, 255);
min-width: 50px;
}
.drop-down-content a {
font-size: 15px;
color:rgb(255, 255, 255);
padding: 10px 10px 10px 10px;
text-decoration: none;
}
.drop-down-content a:hover {
background-color:rgb(255, 165, 0);
}
.drop-down:hover .drop-down-content {
display: block;
}
.drop-down:hover .drop-down-btn {
background-color:rgb(255, 165, 0)
}
My HTML code:
First Meditation
Contact
Homepage
The benefits
The Hinderances
Additional Resources
Questionaire
Contact
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…