/* ==========================================================================
   Abook Frontend Responsive Styles
   古籍知识库前台响应式样式
   ========================================================================== */

/* ---------- 空状态 ---------- */
.abook-empty-state {
    text-align: center;
    padding: 30px;
    color: var(--ink-light);
}

/* ---------- 积分变动 ---------- */
.points-plus {
    color: var(--jade);
    font-weight: 500;
}

.points-minus {
    color: var(--cinnabar);
    font-weight: 500;
}
/* ---------- 响应式布局 ---------- */
@media (max-width: 960px) {
    .abook-tree-layout {
        flex-direction: column;
    }

    .abook-tree-sidebar {
        flex: 0 0 auto;
        position: static;
        max-height: 300px;
        width: 100%;
    }

    .abook-tree-body {
        max-height: 240px;
    }

    .abook-book-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
        gap: 16px;
    }
}

@media (max-width: 768px) {
    .abook-front-wrap,
    .abook-school-wrap,
    .abook-profile-wrap {
        padding: 16px 12px 32px;
    }

    .abook-search-box {
        flex-direction: column;
        padding: 12px 16px;
    }

    .abook-search-box input[type="text"] {
        width: 100%;
    }

    .abook-search-box .abook-btn-front {
        width: 100%;
    }

    .abook-book-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 14px;
    }

    .abook-book-card {
        padding: 18px 14px;
    }

    .abook-book-cover {
        font-size: 32px;
    }

    .abook-book-title {
        font-size: 14px;
    }

    .abook-tree-sidebar {
        max-height: 250px;
    }

    .abook-book-row {
        padding: 10px 14px;
        gap: 12px;
    }

    .abook-row-icon {
        flex: 0 0 32px;
        font-size: 22px;
    }

    .abook-row-title {
        font-size: 13px;
    }

    .abook-detail-row label {
        width: 80px;
    }

    .abook-download-link-item {
        flex-wrap: wrap;
    }

    .abook-upload-modal-content {
        width: 95%;
    }

    .abook-profile-header {
        flex-wrap: wrap;
        gap: 12px;
        padding: 20px;
    }

    .abook-profile-stats {
        margin-left: 0;
        text-align: left;
    }

    .abook-profile-tabs {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .abook-chat-area {
        height: 340px;
    }
}

@media (max-width: 480px) {
    .abook-book-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .abook-book-card {
        padding: 16px 12px;
    }

    .abook-category-item {
        padding: 5px 12px;
        font-size: 12px;
    }

    .abook-btn-front {
        padding: 8px 16px;
        font-size: 13px;
    }

    .abook-school-title {
        font-size: 18px;
    }

    .abook-profile-tabs .tab-btn {
        padding: 8px 16px;
        font-size: 13px;
    }
}
/* ---------- 首页响应式 ---------- */
@media (max-width: 960px) {
    .jch-hero-body {
        flex-direction: column;
        text-align: center;
        padding-top: 40px;
        padding-bottom: 76px;
    }

    .jch-hero-cta { justify-content: center; }

    .jch-bagua { width: 250px; height: 250px; }
    .jch-trigram { transform: translate(-50%, -50%) rotate(var(--a)) translateY(-106px) rotate(calc(var(--a) * -1)); font-size: 22px; }
    .jch-taiji { font-size: 52px; }
    .jch-bagua::after { inset: 56px; }

    .jch-couplet { display: none; }

    .jch-stats { grid-template-columns: repeat(2, 1fr); margin-top: -40px; }
    .jch-stat:nth-child(3) { border-left: 0; }
    .jch-stat:nth-child(n+3) { border-top: 1px solid rgba(212,175,95,.18); }

    .jch-matrix-head { display: none; }
    .jch-matrix-row { grid-template-columns: 1fr; gap: 0; padding: 8px; }
    .jch-matrix-cell { border-left: 0; align-self: auto; align-items: flex-start; padding: 14px 20px; }
    .jch-cell-label { display: inline-block; }
    .jch-matrix-cell .jch-dl-btn,
    .jch-matrix-cell .jch-dl-soon { min-width: 150px; }

    .jch-module-grid,
    .jch-skill-grid { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
    .jch-nav { gap: 14px; }
    .jch-nav-links { gap: 14px; }
    .jch-nav-links a { font-size: 13px; letter-spacing: 1px; }

    .jch-hero-title { font-size: 42px; letter-spacing: 6px; }
    .jch-hero-sub { font-size: 13.5px; }

    .jch-head h2 { font-size: 23px; letter-spacing: 4px; }
    .jch-head h2::before,
    .jch-head h2::after { width: 30px; }

    .jch-contact-grid { grid-template-columns: 1fr; }

    .jch-section { padding-top: 44px; }
}
