几年没写CSS

/* id以containment-wrapper开头的div元素,垂直居中显示在父元素中 */
        div[id^=containment-wrapper]
        {
            position: relative;
            left: 50%;
            top: 50%;
            width: 300px;
            height: 200px;
            margin-left: -150px;
            margin-top: 0px;
        }
        
        /* 使用中 */
        .divInUse
        {
            width: 10px;
            height: 10px;
            float: right;
            margin: 6px 2px auto 3px;
            background-color: #4092B9;
        }
        
        /* 空闲 */
        .divFree
        {
            width: 10px;
            height: 10px;
            float: right;
            margin: 6px 2px auto 3px;
            background-color: #FEFEFE;
            border: 1px solid gray;
        }
        
        /* 实验室名称和房号 */
        .tdShiYanShiName
        {
            text-align: left;
            vertical-align: top;
            padding-left: 25px;
            font-size: 18px;
        }
        
        /* 统计区域 */
        #divTotal
        {
            width: 1000px;
            height: 500px;
            position: relative;
            left: 50%;
            top: 50%;
            margin-left: -475px;
        }
原文地址:https://www.cnblogs.com/coder-soldier/p/7337892.html