老师 帮忙看下代码

来源:4-8 自由编程

lcy_18

2021-03-02 13:46:14

/*About区域*/

.about{

width: 1200px;

margin: 0 auto;

}

.about .about-title {

margin: 30px auto;

}

.about .about-title h3{

font-size: 32px;

text-align: center;

}

.about .about-title div{

width: 60px;

height: 3px;

background-color: #07CBC9;

margin: 10px auto;

}

.about .about-title p{

font-size: 14px;

color: gray;

text-align: center;

}

.about .about-content{

position: relative;

}

.about .about-content .content-middle{

width: 650px;

height: 435px;

margin: 0 auto;

}

.about .about-content .content-left{

position: absolute;

top: 0;

left: 0;

}

.about .about-content .content-left h4{

font-size: 30px;

width: 160px;

line-height: 48px;

}

.about .about-content .content-left .main-left{

width: 300px;

padding: 20px;

font-size: 18px;

border: 1px solid gray;

background: rgba(255,255,255,.5);

margin-top: 20px;

}

.about .about-content .content-left .main-left .button{

width: 140px;

height: 40px;

background-color: black;

color: white;

margin-top: 30px;

text-align: center;

line-height: 40px;

}

.about .about-content .content-right div{

width: 260px;

padding: 40px 0;

border: 1px solid #07CBC9;

}

.about .about-content .content-right div p{

text-align: center;

}

.about .about-content .content-right div p.text1{

font-size: 28px;

font-weight: bold;

}

.about .about-content .content-right div p.text2{

width: 60px;

height: 3px;

background-color: #07CBC9;

margin: 10px auto;

}

.about .about-content .content-right div.first{

position: absolute;

top: 0;

right: 0;

margin-bottom: 30px;

}

.about .about-content .content-right div.second{

position: absolute;

top: 190px;

right: 0;

}


写回答

2回答

好帮手慕张

2021-03-02

同学你好,测试代码效果是正确的,继续加油。祝学习愉快!

0

好帮手慕张

2021-03-02

同学你好,由于同学只粘贴了css代码,老师使用之前同学提交过的结构骨架代码测试发现,同学样式中多个很多元素和结构中的元素对应不上,无法测试完整效果,建议同学粘贴全部代码上来,方便快速高效的检查代码。

祝学习愉快!

0
hcy_18
hp><!-- About区域 -->

    <div class="about">

        <!-- 标题和简短描述区 -->

        <div class="about-title">

            <h3>About</h3>

            <div></div>

            <p>Lorem Ipsum is simply dummy text of the printing and typesetting<br/>

                industry. Lorem Ipsum has been the industry's standard dummy<br/>

                text ever since the 1500s.</p>

        </div>

        <!-- 详细描述区 -->

        <div class="about-content">

            <div class="content-left">

                <h4>A WORD ABOUT US</h4>

                <div class="main-left">

                    <div class="text">Praesent dignissim viverra est, sed bibendum ligula congue non. Sed ac nisl et felis gravida commodo? Suspendisse eget ullamcorper ipsum. Suspendisse diam amet.</div>

                    <div class="button">EXPLORE</div>

                </div>

            </div>

            <div class="content-middle">

                <img src="images/bb3.jpg">

            </div>

            <div class="content-right">

                <div class="first">

                    <p class="text1">70000</p>

                    <p class="text2"></p>

                    <p>Students</p>

                </div>

                <div class="second">

                    <p class="text1">600</p>

                    <p class="text2"></p>

                    <p>Faculty</p>

                </div>

            </div>

        </div>

    </div>


h021-03-02
共1条回复

0 学习 · 15276 问题

查看课程