/* 这个文件暂时为空，所有样式都在 PHP 文件中，以后可以根据需要移动到这里 */

.neodb-container {
    width: 100%;
    margin: 0;
    padding: 0 0 20px 0;
}

.neodb-nav {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    padding-bottom: 10px;
    overflow-x: auto;
}

.neodb-nav-item {
    padding: 8px 16px;
    border: none;
    background: none;
    cursor: pointer;
    font-size: 18px;
    position: relative;
}

.neodb-nav-item.active {
    color: #333;
    font-weight: bold;
}

.neodb-nav-item.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 16px;
    right: 16px;
    height: 2px;
    background-color: #333;
}

.neodb-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 16px;
    min-height: 200px;
    padding: 0;
}

.neodb-grid p {
    grid-column: 1 / -1;
    text-align: center;
    margin: 40px 0;
    color: #666;
    font-size: 14px;
}

@keyframes loading-dots {
    0%, 20% {
        content: "...";
    }
    40% {
        content: ".. .";
    }
    60% {
        content: ". ..";
    }
    80%, 100% {
        content: " ...";
    }
}

.loading::after {
    content: "...";
    display: inline-block;
    animation: loading-dots 1.5s infinite;
    width: 1.5em;
    text-align: left;
}

.neodb-item {
    display: flex;
    flex-direction: column;
}

.neodb-cover {
    margin-bottom: 5px;
    position: relative;
    padding-top: 140%;
}

.neodb-cover img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 4px;
    transition: opacity 0.2s;
}

.neodb-cover img:hover {
    opacity: 0.8;
}

.neodb-info {
    margin-top: 4px;
}

.neodb-rating {
    margin-bottom: 4px;
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.rating-stars {
    font-size: 11px;
    line-height: 1;
    letter-spacing: -2px;
}

.rating-score {
    color: #666;
}

.neodb-title {
    margin-block-end: 0 !important;
    margin: 0;
    font-size: 13px;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    display: -moz-box;
    display: box;
    -webkit-line-clamp: 2;
    -moz-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    -moz-box-orient: vertical;
    box-orient: vertical;
    white-space: normal;
    height: 2.4em;
}

.neodb-title a {
    text-decoration: none;
}

.load-more-button.button {
    padding: 6px 16px !important;
    background-color: #ffffff;
    border: 1px solid #dee2e6 !important;
    border-radius: 14px !important;
    color: #495057;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
    line-height: 1.5;
    height: auto;
    text-shadow: none;
    box-shadow: none;
}

.load-more-button.button:hover {
    background-color: #e9ecef !important;
    color: #495057 !important;
    border-color: #dee2e6 !important;
}

.load-more-button.button.loading {
    opacity: 0.7;
    cursor: not-allowed;
}

.no-more-items {
    font-size: 14px;
    color: #6c757d;
    margin: 20px 0;
}

.neodb-type-nav {
    display: flex;
    gap: 10px;
    margin: 15px 0;
    padding-bottom: 10px;
}

.neodb-type-item {
    padding: 6px 16px;
    border: 1px solid #dee2e6;
    border-radius: 14px;
    background: none;
    cursor: pointer;
    font-size: 14px;
    color: #666;
    transition: all 0.2s ease;
}

.neodb-type-item:hover {
    background-color: #f8f9fa;
}

.neodb-type-item.active {
    color: #fff;
}

.neodb-recent {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 2px 8px;
    border-radius: 4px;
    color: white;
    font-size: 12px;
    z-index: 1;
}

@media screen and (max-width: 768px) {
    .neodb-container {
        padding: 12px;
    }
    .neodb-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    .neodb-nav {
        gap: 8px;
    }
    .neodb-nav-item {
        padding: 6px 12px;
        font-size: 16px;
    }
    .neodb-type-nav {
        gap: 8px;
        margin: 12px 0;
    }
    .neodb-type-item {
        padding: 4px 12px;
        font-size: 13px;
    }
}

@media screen and (min-width: 768px) {
    .neodb-grid {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    }
}
