Html 缩小时Div向下移动

Html 缩小时Div向下移动,html,css,Html,Css,我的问题是eTextSection1不会移动(这很好),但由于某种原因,当我缩小时,eTextSection2会向下移动页面。我怎样才能阻止这一切?我玩这个已经有一段时间了,但我运气不好,所以非常感谢你的帮助。 这里是正在运行的站点 可能是因为css中没有.eTextSection2{。请尝试将上的position属性设置为位置:绝对;将css更改为该属性 在Whitbox类中使用Diplay:flex .eTextSection1{ width:240px;

我的问题是eTextSection1不会移动(这很好),但由于某种原因,当我缩小时,eTextSection2会向下移动页面。我怎样才能阻止这一切?我玩这个已经有一段时间了,但我运气不好,所以非常感谢你的帮助。 这里是正在运行的站点


可能是因为css中没有.eTextSection2{。

请尝试将
上的position属性设置为
位置:绝对;
将css更改为该属性

在Whitbox类中使用Diplay:flex

.eTextSection1{

        width:240px;
        border-style:solid;
position:relative;

    border-bottom:solid;
        border-width:2px;

        }

        .eTextSection2{

        width:240px;
        border-style:solid;
position:relative;

    border-bottom:solid;
        border-width:2px;
        left:2px;
        }
.whiteBox{
display:flex;
    background-color:white;
    width:800px;
    height:800px;
    margin-left:auto;
    margin-right:auto;
    position:relative;
    top:80px;
    -webkit-box-shadow: 10px 11px 5px -6px rgba(0,0,0,0.43);
-moz-box-shadow: 10px 11px 5px -6px rgba(0,0,0,0.43);
box-shadow: 10px 11px 5px -6px rgba(0,0,0,0.43);
margin-bottom:100px;
    }

我不知道你的意思。这里有一个指向实际问题的链接。很抱歉,我没有看到。eTextSection2..尝试更改.eTextSection2的位置
.eTextSection1{

        width:240px;
        border-style:solid;
position:relative;

    border-bottom:solid;
        border-width:2px;

        }

        .eTextSection2{

        width:240px;
        border-style:solid;
position:relative;

    border-bottom:solid;
        border-width:2px;
        left:200px;
        bottom:400px;
        }
.whiteBox{
    background-color:white;
    width:800px;
    height:800px;
    margin-left:auto;
    margin-right:auto;
    position:relative;
    top:80px;
    -webkit-box-shadow: 10px 11px 5px -6px rgba(0,0,0,0.43);
-moz-box-shadow: 10px 11px 5px -6px rgba(0,0,0,0.43);
box-shadow: 10px 11px 5px -6px rgba(0,0,0,0.43);
margin-bottom:100px;
    }
.eTextSection1{

        width:240px;
        border-style:solid;
position:relative;

    border-bottom:solid;
        border-width:2px;

        }

        .eTextSection2{

        width:240px;
        border-style:solid;
position:relative;

    border-bottom:solid;
        border-width:2px;
        left:2px;
        }
.whiteBox{
display:flex;
    background-color:white;
    width:800px;
    height:800px;
    margin-left:auto;
    margin-right:auto;
    position:relative;
    top:80px;
    -webkit-box-shadow: 10px 11px 5px -6px rgba(0,0,0,0.43);
-moz-box-shadow: 10px 11px 5px -6px rgba(0,0,0,0.43);
box-shadow: 10px 11px 5px -6px rgba(0,0,0,0.43);
margin-bottom:100px;
    }