Css Div浮动到高位

Css Div浮动到高位,css,Css,出于某种原因,菜单打开时,菜单div浮动得太高,但当它关闭时,它是完美的。我真的不知道该怎么做才能使菜单div向下移动到它下面的右侧div footer { width: 100%; position: absolute; bottom: 0; left: 0; } #footer-content { display: none; } #footer-left { width: 20%; height: 145px; f

出于某种原因,菜单打开时,菜单div浮动得太高,但当它关闭时,它是完美的。我真的不知道该怎么做才能使菜单div向下移动到它下面的右侧div

footer {
    width: 100%;
    position: absolute;
    bottom: 0;
    left: 0;
} 

#footer-content {
    display: none;
} 

#footer-left {
    width: 20%;
    height: 145px;  
    float: left;
    background-color: #52291c;/*#805f4c;*/
    opacity: 0.8;
} #footer-left h3 {
    width: 95%;
    font-size: 20px;
    font-weight: lighter;
    margin-top: 95px;
    opacity: 1;
    text-align: right;
} #footer-left h3 a {
    color: #fff;
    text-shadow: 1px 1px #000;
    text-transform: lowercase;  
} 

#footer-right {
    width: 80%;
    height: 145px;
    float: right;
    background-color: #B29F63; /*#B29F63*/
    opacity: 0.3;   
} #footer-right ul {
    margin: 30px 15px;
    font-size: 24px;    
} #footer-right ul li a {
    color: #52291c;
}

.doing-tricks {
    width: 150px;
    position: relative;
    left: 21%;
    top: 132px; 
    font-size: 24px;
    z-index: 100;
} .doing-tricks a {
    color: #52291c; 
}

.toggle-footer {
    width: 100px;
    margin: 0px auto;
    padding: 10px;
    cursor: pointer;
    color: #52291c;
    text-align: center;
    text-shadow: 1px 1px #fff;
    background: #B29F63;
    background: -moz-linear-gradient(top,  rgba(254,255,255,1) 0%, rgba(178,159,99,1) 100%); /* FF3.6+ */
    background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(254,255,255,1)), color-stop(100%,rgba(178,159,99,1))); /* Chrome,Safari4+ */
    background: -webkit-linear-gradient(top,  rgba(254,255,255,1) 0%,rgba(178,159,99,1) 100%); /* Chrome10+,Safari5.1+ */
    background: -o-linear-gradient(top,  rgba(254,255,255,1) 0%,rgba(178,159,99,1) 100%); /* Opera 11.10+ */
    background: -ms-linear-gradient(top,  rgba(254,255,255,1) 0%,rgba(178,159,99,1) 100%); /* IE10+ */
    background: linear-gradient(to bottom,  rgba(254,255,255,1) 0%,rgba(178,159,99,1) 100%); /* W3C */
    opacity: 0.8;
    border-top-left-radius:  5px;
    border-top-right-radius: 5px;
}

jFiddle:

使
变为
的绝对位置
而不是
相对位置

.doing-tricks {
    ...
    position: absolute;
    ...
}

然后你需要调整页脚内文本的顶部位置。

aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa。。。