/* 暗黑简洁主题 - 音效素材模板样式（极简扁平设计） */

/* ========== 顶部提示系统（统一风格） ========== */
.toast-notification {
    position: fixed;
    top: 60px;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    padding: 12px 20px;
    border-radius: 2px;
    font-size: 14px;
    z-index: 10001;
    opacity: 0;
    transition: all 0.2s;
    display: none;
    min-width: 280px;
    max-width: 520px;
    text-align: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.12);
    pointer-events: none;
    border: 1px solid #2a3441;
    background: #1f2833;
    color: #CCCCCC;
    line-height: 1.5;
    word-wrap: break-word;
}

.toast-notification.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    display: block;
}

.toast-notification.error {
    background: #4a1f1f;
    color: #ff6b6b;
    border-color: #5a2a2a;
}

.toast-notification.success {
    background: #1f4a2f;
    color: #4ade80;
    border-color: #2a5a3f;
}

.toast-notification.warning {
    background: #3a2f1f;
    color: #fbbf24;
    border-color: #4a3f2f;
}

.toast-notification.info {
    background: #1f2f4a;
    color: #60a5fa;
    border-color: #2f3f5a;
}

/* ========== 页面容器/标题（对齐 teaching.css） ========== */
.audio-container {
    width: 100%;
    max-width: 2000px;
    margin: 0 auto;
    min-height: calc(100vh - 140px);
    background: #1f2833;
    padding: 35px 35px;
    box-sizing: border-box;
}

.audio-header {
    text-align: center;
    margin-bottom: 30px;
}

.audio-title {
    font-size: 32px;
    font-weight: 500;
    color: #CCCCCC;
    margin-bottom: 10px;
    letter-spacing: 0;
}

.audio-description {
    font-size: 14px;
    color: #a0a8b0;
    line-height: 1.7;
    max-width: 800px;
    margin: 0 auto;
}

/* ========== 搜索框（对齐 teaching.css） ========== */
.audio-search-box {
    max-width: 560px;
    margin: 0 auto 35px;
    position: relative;
}

.audio-search-input {
    width: 100%;
    padding: 10px 46px 10px 18px;
    border: 1px solid #2a3441;
    border-radius: 2px;
    font-size: 13px;
    transition: border-color 0.2s;
    background: #1f2833;
    box-sizing: border-box;
    color: #CCCCCC;
}

.audio-search-input:focus {
    outline: none;
    border-color: #5dade2;
    background: #1f2833;
    box-shadow: none;
}

.audio-search-input::placeholder {
    color: #a0a8b0;
}

.audio-search-btn {
    position: absolute;
    right: 4px;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    background: #5dade2;
    border: none;
    border-radius: 2px;
    color: white;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.audio-search-btn:hover {
    background: #4a9bc7;
    box-shadow: none;
}

/* ========== 主导航/子导航（对齐 teaching.css） ========== */
.audio-main-nav {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 25px;
    flex-wrap: wrap;
    padding: 0;
}

.audio-main-nav-btn {
    padding: 10px 24px;
    background: #1f2833;
    border: 1px solid #2a3441;
    border-radius: 2px;
    font-size: 14px;
    font-weight: 400;
    color: #a0a8b0;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: none;
}

.audio-main-nav-btn:hover {
    border-color: #5dade2;
    color: #5dade2;
    box-shadow: none;
}

.audio-main-nav-btn.active {
    background: #5dade2;
    border-color: #5dade2;
    color: white;
    box-shadow: none;
}

.audio-sub-nav-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    padding: 10px 14px;
    flex-wrap: wrap;
    background: #2a3441;
    border-radius: 2px;
    border: 1px solid #2a3441;
    min-height: 54px;
}

.audio-sub-nav-btn {
    padding: 8px 16px;
    background: #1f2833;
    border: 1px solid #2a3441;
    border-radius: 2px;
    font-size: 13px;
    color: #a0a8b0;
    cursor: pointer;
    font-weight: 400;
    transition: all 0.2s;
    box-shadow: none;
}

.audio-sub-nav-btn:hover {
    background: #2a3441;
    border-color: #5dade2;
    color: #5dade2;
    box-shadow: none;
}

.audio-sub-nav-btn.active {
    background: #5dade2;
    border-color: #5dade2;
    color: white;
    box-shadow: none;
}

/* ========== 列表/卡片 ========== */
.audio-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 16px;
}

.audio-card {
    background: #1f2833;
    border-radius: 2px;
    border: 1px solid #2a3441;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    overflow: hidden;
    transition: box-shadow 0.2s;
    display: flex;
    flex-direction: column;
}

.audio-card:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
    border-color: #5dade2;
}

.audio-card-head {
    padding: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.audio-card-title {
    font-size: 14px;
    font-weight: 500;
    color: #CCCCCC;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

.audio-card-badge {
    flex-shrink: 0;
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 2px;
    background: #1f2f4a;
    border: 1px solid #2f3f5a;
    color: #5dade2;
    white-space: nowrap;
}

.audio-card-meta {
    display: none;
}

.audio-card-player {
    padding: 10px 12px 12px 12px;
    border-top: 1px solid #2a3441;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.audio-player-bar {
    width: 100%;
    height: 6px;
    border-radius: 999px;
    background: #2a3441;
    position: relative;
    overflow: hidden;
}

.audio-player-progress {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 35%;
    background: #5dade2;
}

.audio-player-actions {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: center;
}

.audio-btn {
    border: none;
    cursor: pointer;
    border-radius: 2px;
    padding: 8px 12px;
    font-size: 13px;
    font-weight: 500;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.audio-btn.play {
    background: #5dade2;
    color: #fff;
    box-shadow: none;
}

.audio-btn.play:hover {
    background: #4a9bc7;
}

.audio-btn.download {
    background: #1f2833;
    color: #a0a8b0;
    border: 1px solid #2a3441;
}

.audio-btn.download:hover {
    background: #2a3441;
    border-color: #5dade2;
    color: #5dade2;
    transform: none;
}

.audio-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10000;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.audio-modal.active {
    display: flex;
    opacity: 1;
}

.audio-modal-content {
    background: #1f2833;
    border-radius: 16px;
    width: 90%;
    max-width: 600px;
    max-height: 85vh;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    transform: scale(0.9) translateY(-20px);
    transition: transform 0.2s ease, opacity 0.2s ease;
    opacity: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #2a3441;
}

.audio-modal.active .audio-modal-content {
    transform: scale(1) translateY(0);
    opacity: 1;
}

.audio-modal-header {
    padding: 20px 25px;
    border-bottom: 1px solid #2a3441;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.audio-modal-header h3 {
    margin: 0;
    font-size: 18px;
    color: #CCCCCC;
}

.audio-modal-title {
    margin: 0;
    font-size: 18px;
    color: #CCCCCC;
}

.audio-modal-close {
    font-size: 28px;
    color: #a0a8b0;
    cursor: pointer;
    transition: all 0.2s ease;
    line-height: 1;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.audio-modal-close:hover {
    background: #2a3441;
    color: #CCCCCC;
}

.audio-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #2a3441;
}

.audio-modal-body::-webkit-scrollbar {
    width: 6px;
}

.audio-modal-body::-webkit-scrollbar-track {
    background: #2a3441;
}

.audio-modal-body::-webkit-scrollbar-thumb {
    background: #bdbdbd;
    border-radius: 10px;
}

.audio-modal-body::-webkit-scrollbar-thumb:hover {
    background: #9e9e9e;
}

.audio-download-disk-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    background: #1f2833;
    color: #CCCCCC;
    text-decoration: none;
    border-radius: 10px;
    border: 1px solid #2a3441;
    font-size: 15px;
    font-weight: 500;
    min-height: 40px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.2s ease;
    white-space: nowrap;
    cursor: pointer;
}

.audio-download-disk-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.2);
    border-color: #5dade2;
    color: #5dade2;
}

/* 空/加载/错误 */
.audio-loading-state,
.audio-empty-state,
.audio-error-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 0;
    color: #a0a8b0;
}

.audio-error-state {
    color: #f44336;
}

.audio-loading-state p,
.audio-empty-state p,
.audio-error-state p {
    margin: 0;
    font-size: 16px;
}

/* ========== 分页（注意：此类名可能被其他页面复用，保持简洁中性） ========== */
.pagination-container {
    margin-top: 35px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.pagination-btn {
    padding: 8px 14px;
    background: #1f2833;
    border: 1px solid #2a3441;
    border-radius: 2px;
    color: #a0a8b0;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 13px;
    font-weight: 400;
    min-width: 36px;
    text-align: center;
}

.pagination-btn:hover:not(.disabled) {
    background: #2a3441;
    border-color: #5dade2;
    color: #5dade2;
}

.pagination-btn.active {
    background: #5dade2;
    border-color: #5dade2;
    color: white;
    box-shadow: none;
}

.pagination-btn.disabled {
    background: #2a3441;
    color: #a0a8b0;
    cursor: not-allowed;
    opacity: 0.5;
}

.pagination-info {
    color: #a0a8b0;
    padding: 6px 10px;
    font-size: 12px;
    white-space: nowrap;
}

/* ========== 响应式（对齐 teaching.css 的断点节奏） ========== */
@media (max-width: 1400px) {
    .audio-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 1024px) {
    .audio-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .audio-container {
        padding: 18px 18px;
    }

    .audio-header {
        margin-bottom: 22px;
    }

    .audio-title {
        font-size: 22px;
        margin-bottom: 8px;
    }

    .audio-description {
        font-size: 13px;
        line-height: 1.6;
    }

    .audio-search-box {
        margin-bottom: 25px;
    }

    .audio-search-input {
        padding: 8px 42px 8px 14px;
        font-size: 13px;
    }

    .audio-search-btn {
        width: 28px;
        height: 28px;
        right: 3px;
    }

    .audio-main-nav {
        gap: 6px;
        margin-bottom: 18px;
    }

    .audio-main-nav-btn {
        padding: 6px 14px;
        font-size: 11px;
        min-width: 70px;
    }

    .audio-sub-nav-container {
        gap: 6px;
        padding: 10px;
        margin-bottom: 22px;
        min-height: auto;
    }

    .audio-sub-nav-btn {
        padding: 6px 12px;
        font-size: 11px;
        white-space: nowrap;
    }

    .audio-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .audio-card-head {
        padding: 10px;
    }

    .audio-card-player {
        padding: 10px;
    }

    .audio-btn {
        padding: 8px 10px;
        font-size: 12px;
    }

    .audio-modal-content {
        width: 95%;
        max-width: 500px;
    }

    .audio-modal-body {
        padding: 18px;
    }

    .pagination-container {
        margin-top: 25px;
        gap: 5px;
    }

    .pagination-btn {
        padding: 6px 10px;
        font-size: 11px;
        min-width: 32px;
    }

    .pagination-info {
        padding: 6px 10px;
        font-size: 11px;
    }
}

@media (max-width: 576px) {
    .audio-grid {
        grid-template-columns: 1fr;
    }

    .audio-modal-content {
        width: 98%;
    }
}


