/* Catalog page desktop adaptations; mobile keeps original styles */
.pt-pc-header {
    display: none;
}

.pt-dir-menubar {
    display: none;
}

@media (min-width: 768px) {
    .pt-pc-header {
        display: block;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        z-index: 1000;
        background: #fff;
        box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    }

    .pt-pc-header-inner {
        height: 64px;
        margin: 0 auto;
        padding: 0 16px;
        display: flex;
        align-items: center;
        justify-content: space-between;
        max-width: 960px;
    }

    .pt-pc-logo {
        font-size: 24px;
        font-weight: 700;
        line-height: 1;
    }

    .pt-pc-menu {
        display: flex;
        align-items: center;
        gap: 18px;
    }

    .pt-pc-menu-item {
        font-size: 15px;
        color: #333;
        padding: 8px 12px;
        border-radius: 6px;
        transition: background-color .2s ease, color .2s ease;
    }

    .pt-pc-menu-item:visited {
        color: #333;
    }

    .pt-pc-menu-item:hover {
        color: #f55;
        background: #fff1f1;
    }

    .pt-dir-mobile-header {
        display: none;
    }

    .pt-dir-main {
        max-width: 960px;
        margin: 0 auto;
        padding: 76px 0 16px;
    }

    .pt-dir-menubar {
        display: flex;
        align-items: center;
        gap: 8px;
        height: 40px;
        padding: 0 12px;
        margin-bottom: 10px;
        border-radius: 8px;
        background: #fff;
        color: #777;
        font-size: 14px;
    }

    .pt-dir-menu-item {
        color: #666;
    }

    .pt-dir-menu-item:hover {
        color: #f55;
    }

    .pt-dir-menu-sep {
        color: #aaa;
    }

    .pt-dir-menu-current {
        color: #333;
        max-width: 60%;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .pt-dir-content {
        border-radius: 10px;
    }

    #chapter-container {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0 16px;
    }

    .chapter-list {
        border-bottom: 1px solid #ececec !important;
    }

    .chapter-list a {
        min-height: 46px;
        padding: 0 8px;
        transition: background-color .2s ease;
    }

    .chapter-list a:hover {
        background: #fff4f4;
    }

    .chapter-line-wrap {
        width: 100%;
        min-width: 0;
    }

    .chapter-name {
        flex: 1;
        min-width: 0;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .chapter-list .size16 {
        font-size: 15px;
        line-height: 1.4;
    }
}

@media (min-width: 768px) and (max-width: 1024px) {
    #chapter-container {
        grid-template-columns: 1fr;
    }
}
