css布局网页(参考apple官网)

 

 

简单来说分为七个部分

 

1.第一部分 (头部)

2.第二部分(导航栏)

带二级导航/选项卡内容

3.第三部分

 4.第四部分 分别切换

 5.第五部分(轮播)

 6.第六部分

7.第七部分(底部)

对了,还有响应式

/* -----------响应式----------- */

#box_1 img{

    width: 20px;

    height: 0px;

    position: relative;

    left: -1140px;

    top: 6px;

}

.xys{

    width: 200px;

    height: 0px;

    position: absolute;

    /* border: 1px black solid; */

    top: 30px;

    overflow: hidden;

    z-index:1;

}

.xys ul li{

    width: 200px;

    height: 50px;

    background-color:rgb(45, 43, 43);

    color: white;text-align: center;

    line-height: 20px;

}

@media only screen and (max-width:800px){

   .dhl li a{

    display: none;

    transition: 0.5s;

   }

   .dhl_1{

    display: none;

    transition: 0.5s;

   }

   .xys{

    transition: 1s;

   }

   #box_1 img{

      height: 20px;

      transition: 3s;

}

#box_1 img:hover ~.xys{

    height: 500px;

    transition: 1s;

}

#box_1 .xys ul li{

    background-color: rgb(53, 53, 53);

}

#box_1 .xys ul li:hover{

    background-color: rgb(77, 77, 77);

}

#box_1 .xys:hover{

    height: 600px;

}

/* -------------屏幕缩小后响应式二级标签 摸苹果---------------- */

 

}

 

 今天就不上代码了,代码量有点大,需要的私我奥

 

评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值