/* ===== 基础重置 ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: -apple-system, "Microsoft YaHei", "PingFang SC", sans-serif;
    background: #f0f2f5;
    color: #333;
    line-height: 1.6;
}
a { color: #4a90d9; text-decoration: none; }
a:hover { text-decoration: underline; }

/* ===== 容器 ===== */
.container {
    max-width: 860px;
    margin: 0 auto;
    padding: 24px 20px 60px;
}

/* ===== 头部 ===== */
.site-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 28px;
}
.site-header h1 {
    font-size: 26px;
    color: #1a1a2e;
}
.search-form {
    display: flex;
    gap: 8px;
}
.search-form input {
    padding: 8px 14px;
    border: 1px solid #d0d5dd;
    border-radius: 6px;
    width: 240px;
    font-size: 14px;
}
.search-form button {
    padding: 8px 18px;
    background: #4a90d9;
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
}
.search-form button:hover { background: #357abd; }

/* ===== 歌曲列表 ===== */
.song-list {
    list-style: none;
}
.song-item {
    background: #fff;
    border-radius: 10px;
    padding: 16px 20px;
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    transition: box-shadow 0.2s;
}
.song-item:hover { box-shadow: 0 2px 8px rgba(0,0,0,0.1); }
.song-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    flex: 1;
}
.song-title {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a2e;
}
.song-artist {
    font-size: 13px;
    color: #888;
}
.song-album {
    font-size: 12px;
    color: #aaa;
}
.song-player {
    display: flex;
    align-items: center;
    gap: 10px;
}
.song-player audio {
    height: 36px;
    max-width: 320px;
}
.play-count {
    font-size: 12px;
    color: #4a90d9;
    white-space: nowrap;
    background: #eef4fb;
    padding: 2px 8px;
    border-radius: 4px;
}

/* ===== 分页 ===== */
.pagination {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 28px;
}
.pagination a {
    padding: 6px 12px;
    border: 1px solid #d0d5dd;
    border-radius: 4px;
    color: #555;
    font-size: 14px;
}
.pagination a.active {
    background: #4a90d9;
    color: #fff;
    border-color: #4a90d9;
}

/* ===== 空状态 ===== */
.empty {
    text-align: center;
    color: #999;
    padding: 48px 0;
    font-size: 15px;
}

/* ===== 页脚 ===== */
.site-footer {
    text-align: center;
    margin-top: 36px;
    font-size: 13px;
    color: #aaa;
}

/* ===== 提示框 ===== */
.alert {
    padding: 10px 16px;
    border-radius: 6px;
    margin-bottom: 16px;
    font-size: 14px;
}
.alert-success { background: #e8f5e9; color: #2e7d32; border: 1px solid #c8e6c9; }
.alert-error   { background: #ffebee; color: #c62828; border: 1px solid #ffcdd2; }

/* ===== 管理表单 ===== */
.header-actions a {
    margin-left: 12px;
    font-size: 14px;
}
.admin-form, .admin-list {
    background: #fff;
    border-radius: 10px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
.admin-form h2, .admin-list h2 {
    font-size: 18px;
    margin-bottom: 18px;
    color: #1a1a2e;
}
.form-row {
    margin-bottom: 14px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.form-row label {
    font-size: 14px;
    font-weight: 500;
    color: #555;
}
.form-row .req { color: #e74c3c; }
.form-row input, .form-row select {
    padding: 8px 12px;
    border: 1px solid #d0d5dd;
    border-radius: 6px;
    font-size: 14px;
}
.form-row input:focus, .form-row select:focus {
    outline: none;
    border-color: #4a90d9;
}
.form-row small {
    font-size: 12px;
    color: #aaa;
}
.form-actions {
    margin-top: 18px;
    display: flex;
    gap: 10px;
    align-items: center;
}
.btn-primary {
    padding: 9px 24px;
    background: #4a90d9;
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
}
.btn-primary:hover { background: #357abd; }
.btn-cancel {
    font-size: 14px;
    color: #888;
}

/* ===== 数据表格 ===== */
.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}
.data-table th, .data-table td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid #eee;
}
.data-table th {
    color: #888;
    font-weight: 600;
    font-size: 13px;
}
.data-table tr:hover { background: #fafbfc; }
.actions {
    white-space: nowrap;
}
.btn-small {
    padding: 4px 10px;
    border: 1px solid #d0d5dd;
    border-radius: 4px;
    font-size: 12px;
    color: #555;
    background: #fff;
    cursor: pointer;
    display: inline-block;
    margin-right: 4px;
}
.btn-small:hover { background: #f0f2f5; text-decoration: none; }
.btn-danger { color: #c62828; border-color: #ffcdd2; }
.btn-danger:hover { background: #ffebee; }

/* ===== 登录页 ===== */
.login-box {
    max-width: 360px;
    margin: 80px auto 0;
    background: #fff;
    border-radius: 10px;
    padding: 36px 32px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}
.login-box h1 {
    font-size: 22px;
    text-align: center;
    margin-bottom: 24px;
    color: #1a1a2e;
}
.login-hint {
    text-align: center;
    margin-top: 18px;
    font-size: 13px;
}

/* ===== 响应式 ===== */
@media (max-width: 600px) {
    .song-player audio { max-width: 100%; }
    .search-form input { width: 160px; }
    .data-table { font-size: 12px; }
    .data-table th, .data-table td { padding: 6px 8px; }
}
