css+div布局实现网盘仪表盘后台代码

代码语言:html

所属分类:布局界面

代码描述:css+div布局实现网盘仪表盘后台代码

代码标签: css div 布局 网盘 仪表盘 后台 代码

下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开

<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>云存储 Dashboard</title>
<style>
    /* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
}

body {
    background-color: #f5f7fa;
    color: #333;
}

.container {
    display: flex;
    min-height: 100vh;
}

/* 侧边栏样式 */
.sidebar {
    width: 250px;
    background-color: #2c3e50;
    color: white;
    padding: 20px;
    display: flex;
    flex-direction: column;
}

.logo {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
    font-size: 1.5rem;
    font-weight: bold;
}

.logo i {
    margin-right: 10px;
    color: #3498db;
}

.nav-menu ul {
    list-style: none;
}

.nav-menu li {
    margin-bottom: 15px;
    padding: 10px;
    border-radius: 5px;
    transition: background-color 0.3s;
}

.nav-menu li:hover, .nav-menu li.active {
    background-color: #34495e;
}

.nav-menu a {
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
}

.nav-menu i {
    margin-right: 10px;
    width: 20px;
    text-align: center;
}

.storage-info {
    margin-top: auto;
    padding-top: 20px;
}

.storage-text {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.progress-bar {
    height: 8px;
    background-color: #34495e;
    border-radius: 4px;
    overflow: hidden;
}

.progress {
    height: 100%;
    background-color: #3498db;
    border-radius: 4px;
}

/* 主内容区样式 */
.main-content {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
}

/* 顶部栏样式 */
.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.search-bar {
    display: flex;
    align-items: center;
    background-color: white;
    border-radius: 30px;
    padding: 10px 20px;
    width: 400px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.search-bar i {
    color: #7f8c8d;
    margin-right: 10px;
}

.search-bar input {
    border: none;
    outline: none;
    width: 100%;
    font-size: 0.9rem;
}

.user-profile {
    display: flex;
    align-items: center;
}.........完整代码请登录后点击上方下载按钮下载查看

网友评论0