/* 容器 - 横排布局 */
#bangumi-container {
    display: flex;
    flex-flow: row wrap;
    justify-content: flex-start;
    gap: 16px;
    margin-top: 1em;
}

/* 单个卡片 */
.bangumi-item {
    position: relative;
    cursor: pointer;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.3);
    transition: ease all 0.3s;
    overflow: hidden;
    background: #f7fbf7;
    display: flex;
    flex-flow: column nowrap;
    justify-content: flex-start;
    border-radius: 8px;
    width: calc(25% - 16px);  /* 一排4个，减去 gap 间距 */
}

.bangumi-item:hover {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    transform: translateY(-2px);
}

/* 封面图区域 */
.bangumi-thumb {
    width: 100%;
    padding-top: 141%;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
}

/* 标题 */
.bangumi-title,
.bangumi-title a {
    margin: 8px 8px 4px !important;
    font-size: 14px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    text-align: center !important;
    color: #202020 !important;
    font-weight: 700 !important;
    border: none !important;
    text-decoration: none !important;
}

/* 评分 */
.bangumi-rating {
    text-align: center;
    font-size: 12px;
    color: #f5a623;
    margin-bottom: 4px;
}

/* 进度 */
.bangumi-progress {
    text-align: center;
    font-size: 11px;
    color: #666;
    margin-bottom: 8px;
}

/* 详情面板（悬浮显示） */
.bangumi-info {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    transition: all 0.3s;
    background-color: rgba(247, 251, 247, 0.95);
    color: black;
    font-size: 12px;
    line-height: 1.4;
    transform: translateY(100%);
    padding: 8px;
    border-radius: 8px;
}

.bangumi-item:hover .bangumi-info {
    transform: translateY(0);
}

.bangumi-info-basic {
    white-space: normal;
    word-break: break-word;
}

.bangumi-info-basic a {
    color: #1abc9c;
    text-decoration: none;
}

/* 加载更多按钮 */
.bangumi-loadmore {
    display: block;
    padding: 10px;
    background: #304040;
    color: white;
    transition: 0.2s;
    margin: 20px auto !important;
    width: 150px;
    text-align: center;
    cursor: pointer;
    border-radius: 4px;
}

.bangumi-loadmore:hover {
    background: #1dc6f4;
}

/* 空状态 */
.bangumi-empty {
    text-align: center;
    padding: 50px;
    color: #999;
    width: 100%;
}

/* 响应式布局 */
@media screen and (max-width: 767px) {
    .bangumi-item {
        width: calc(50% - 12px);
    }
}

@media screen and (max-width: 480px) {
    .bangumi-item {
        width: calc(100% - 0px);
    }
}