*{margin:0;padding:0;box-sizing:border-box}
body{
    font-family:"Ping Fang SC","Microsoft YaHei",sans-serif;
    color:#6b7280;
    min-height:100vh;
    padding:30px 16px;
    transition:background 0.3s ease;
    background: linear-gradient(135deg, #2d3748, #1a202c);
}
#app{
    display:flex;
    gap:24px;
    max-width:1400px;
    margin:0 auto;
    align-items:flex-start
}
.main{flex:1;min-width:0}
.sidebar{
    width:280px;
    flex-shrink:0;
    position:sticky;
    top:30px
}
.card{
    background:rgba(255,255,255,0.95);
    border-radius:24px;
    box-shadow:0 8px 30px rgba(0,0,0,0.08);
    overflow:hidden;
    margin-bottom:20px
}

.header-card{
    padding:28px 32px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    flex-wrap:wrap;
    gap:16px;
    background: linear-gradient(135deg, #2d3748, #1a202c);
    color:white!important;
}
.header-icon{font-size:40px}
.header-title{font-size:26px;font-weight:700;color:white!important}
.header-sub{opacity:.9;font-size:14px;margin-top:4px;color:white!important}

.search-box{
    display:flex;
    align-items:center;
    gap:10px;
    background:rgba(255,255,255,0.3);
    border-radius:20px;
    padding:10px 18px;
}
.search-box input{
    background:none;
    border:none;
    outline:none;
    color:white!important;
    font-size:14px;
    width:190px;
}
.breadcrumb{
    background:rgba(255,255,255,0.9);
    border-radius:18px;
    padding:14px 20px;
    font-size:13px;
    display:flex;
    align-items:center;
    gap:6px;
    margin-bottom:16px;
}
.breadcrumb a{
    color:#f87171;
    text-decoration:none;
    font-weight:500;
}

.list-header{
    display:grid;
    grid-template-columns:1fr 100px 140px 80px;
    padding:16px 26px;
    font-size:12px;
    background:#fdf2f8;
    font-weight:600;
    align-items:center;
    text-align:center;
}
.list-header div:first-child{text-align:left}

.item{
    display:grid;
    grid-template-columns:1fr 100px 140px 80px;
    align-items:center;
    padding:16px 26px;
    border-bottom:1px solid #f0f0f0;
    cursor:pointer;
    text-align:center;
}
.item div:first-child{text-align:left}
.item:hover{background:#fafafa}

.col-name{
    display:flex;
    align-items:center;
    gap:6px;
    overflow:hidden;
}
.file-icon{font-size:22px}
.file-name{
    font-size:15px;
    font-weight:500;
    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
}
.col-size,.col-time{
    font-size:13px;
    color:#9ca3af;
}
.download-btn{
    width:60px;
    padding:6px 0;
    background:#f87171;
    color:#fff;
    border:none;
    border-radius:12px;
    font-size:12px;
    cursor:pointer;
    text-align:center;
}

.notice-board{padding:24px}
.notice-title{
    font-size:16px;
    color:#f87171;
    font-weight:700;
    margin-bottom:14px;
}
#notice{
    font-size:13px;
    line-height:1.7;
    white-space:pre-wrap;
    max-height:400px;
    overflow-y:auto;
}
.widget{padding:24px;text-align:center}
.clock{
    font-size:22px;
    font-weight:bold;
    color:#f87171;
    margin-bottom:8px;
}
.date{
    font-size:13px;
    color:#999;
    margin-bottom:12px;
}
.weather{
    font-size:14px;
    padding:8px 12px;
    background:#fdf2f8;
    border-radius:12px;
    display:inline-block;
}

/* ========== 正确的预览样式 ========== */
.preview-modal{
    position:fixed;
    top:0;left:0;
    width:100vw;height:100vh;
    background:rgba(0,0,0,0.8);
    display:flex;
    align-items:center;
    justify-content:center;
    z-index:9999;
    opacity:0;
    pointer-events:none;
    transition:opacity 0.3s ease;
}
.preview-modal.show{
    opacity:1;
    pointer-events:all;
}
.preview-box{
    background:#fff;
    width:94%;
    max-width:1000px;
    max-height:85vh;
    border-radius:20px;
    display:flex;
    flex-direction:column;
    overflow:hidden;
}
.preview-header{
    padding:18px 24px;
    background:#fdf2f8;
    display:flex;
    justify-content:space-between;
    align-items:center;
}
.preview-btn{
    padding:8px 14px;
    border-radius:10px;
    border:none;
    color:white;
    cursor:pointer;
}
.btn-download{background:#38bdf8}
.btn-close{background:#f87171}
#previewBody{
    flex:1;
    display:flex;
    align-items:center;
    justify-content:center;
    padding:20px;
    background:#f9f9f9;
}
#previewBody img{
    max-width:100%;
    max-height:100%;
    object-fit:contain;
    border-radius:10px;
}
#previewBody pre{
    width:100%;
    height:100%;
    padding:20px;
    background:#fff;
    border-radius:10px;
    white-space:pre-wrap;
    word-wrap:break-word;
    overflow:auto;
}

@media(max-width:900px){
    #app{flex-direction:column}
    .sidebar{width:100%}
}
