blog-博客美化-标题背景色带代码

博客美化-标题背景色带代码

1.自定义背景色

<!--此处自定义标题背景色-->
#cnblogs_post_body h1 {
    background: #390;
    border-radius: 6px 6px 6px 6px;
    color: #FFFFFF;
    font-family: FZShuTi;
    font-size: 25px;
    font-weight: bold;
    height: 25px;
    line-height: 25px;
    margin: 18px 0 !important;
    padding: 12px 0 8px 5px;
#    text-shadow: 2px 2px 3px #222222;
    text-align:center;
    margin-bottom: 20px;
}
#cnblogs_post_body h2 {
background-color: #390;
    border-radius: 3px;
    text-align:left;
    color: white;
    font-size: 22px;
#    text-shadow: 1px 1px 2px #222222;
    padding-left: 15px;
    margin-bottom: 12px;
    width:100%
}
#cnblogs_post_body h3 {
background-color: #390;
    border-radius: 3px;
    text-align:left;
    color: white;
    font-size: 16px;
#    text-shadow: 1px 1px 2px #222222;
    padding: 5px 15px;
    margin-bottom: 10px;
    width:50%
}
#cnblogs_post_body h4 {
    background-color: #390;
    border-radius: 3px;
    text-align:left;
    color: white;
    font-size: 14px;
#    text-shadow: 1px 1px 2px #222222;
    padding: 5px 15px;
    margin-bottom: 10px;
    width:50%
}
code {
    padding: 1px 3px;
    margin: 0 3px;
    background: #ddd;
    border: 1px solid #ccc;
    font-family: Menlo,Monaco,Andale Mono,lucida console,Courier New,monospace;
    word-wrap: break-word;
    font-size: 14px;
}
#cnblogs_post_body table {
    text-align: center;
    width: 100%;
    border: 1px solid #dedede;
    margin: 15px 0;
    border-collapse: collapse;
}
#cnblogs_post_body table thead tr {
    background: #f8f8f8;
}
#cnblogs_post_body table tbody tr:hover {
    background: #efefef;
}
#cnblogs_post_body h2 {
background: gray !important;
background: #406CA4 !important;
border-radius: 4px 4px 4px 4px !important;
box-shadow: 0 0 0 1px #5F5A4B, 1px 1px 6px 1px rgba(10, 10, 0, 0.5);
color: #FFFFF0;
font-family: "微软雅黑", "宋体", "黑体", Arial;
font-size: 17px;
font-weight: bold;
margin: 15px 0 !important;
padding: 5px 0 5px 20px;
}

h1 a:visited, 
h1 a:link {  
color : green;  
} 
#top   
{  
color : red;  
}
posted @ 2023-05-17 18:13  天生帅才  阅读(60)  评论(0编辑  收藏  举报
// 百度统计