/* ============================================
   Steam游戏库 - 网站栏目独立样式（新增文件，不影响其他样式）
   浅色主题，与网站整体浅色背景匹配（白卡片 + 浅灰边框）
   ============================================ */

.steam-library {
    background: transparent;
    color: #333;
    padding: 20px 0 40px 0;
}

/* ---------- 顶部标题 ---------- */
.steam-library .sl-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 16px;
}

.steam-library .sl-header h1 {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
    color: #262626;
}

.steam-library .sl-header .sl-total {
    color: rgba(0, 0, 0, 0.45);
    font-size: 13px;
}

/* ---------- 工具栏（搜索/筛选） ---------- */
.steam-library .sl-toolbar {
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    padding: 12px;
    margin-bottom: 16px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.steam-library .sl-toolbar .sl-form-inline {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.steam-library .sl-toolbar .form-control {
    height: 34px;
    background: #fff;
    border: 1px solid #d9d9d9;
    color: #333;
    border-radius: 6px;
}

.steam-library .sl-toolbar .form-control:focus {
    border-color: #1890ff;
    box-shadow: none;
    background: #fff;
    color: #333;
}

.steam-library .sl-toolbar select.form-control option {
    background: #fff;
    color: #333;
}

.steam-library .sl-search {
    position: relative;
    width: 300px;
    max-width: 100%;
    border-radius: 6px;
    padding: 2px;
    background: linear-gradient(90deg, #1890ff, #36cfc9, #1890ff, #722ed1, #1890ff);
    background-size: 300% 100%;
    animation: sl-glow-flow 4s ease infinite;
}

@keyframes sl-glow-flow {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.steam-library .sl-search .sl-search-inner {
    display: flex;
    border-radius: 4px;
    overflow: hidden;
    background: #fff;
}

.steam-library .sl-search input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 0 10px;
    height: 30px;
    color: #333;
    outline: none;
}

.steam-library .sl-search .sl-search-btn {
    border: none;
    background: #1890ff;
    color: #fff;
    padding: 0 16px;
    cursor: pointer;
}

.steam-library .sl-nsfw {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #555;
    font-size: 13px;
    cursor: pointer;
}

/* ---------- 游戏卡片网格（固定一行 5 个） ---------- */
.steam-library .sl-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 16px;
}

.steam-library .sl-card {
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    display: block;
    color: inherit;
}

.steam-library .sl-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    border-color: #d9d9d9;
    text-decoration: none;
    color: inherit;
}

.steam-library .sl-card .sl-cover {
    position: relative;
    width: 100%;
    padding-top: 46.74%; /* 460:215 */
    background: #f0f0f0;
    overflow: hidden;
}

.steam-library .sl-card .sl-cover img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.steam-library .sl-card .sl-body {
    padding: 8px;
}

.steam-library .sl-card .sl-title {
    font-size: 12px;
    font-weight: 600;
    color: #333;
    line-height: 1.3;
    height: 32px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.steam-library .sl-card .sl-meta {
    margin-top: 4px;
    display: flex;
    align-items: center;
    gap: 4px;
    flex-wrap: wrap;
}

.steam-library .sl-tag {
    display: inline-block;
    font-size: 10px;
    line-height: 16px;
    padding: 0 4px;
    border-radius: 3px;
    color: #fff;
    white-space: nowrap;
}

.steam-library .sl-tag-green { background: #52c41a; }
.steam-library .sl-tag-gray  { background: #bfbfbf; color: #fff; }
.steam-library .sl-tag-orange { background: #fa8c16; }
.steam-library .sl-tag-purple { background: #722ed1; }
.steam-library .sl-tag-gold { background: #ffe58f; color: #874d00; }
.steam-library .sl-tag-blue { background: #1890ff; }

.steam-library .sl-lang {
    font-size: 10px;
    color: rgba(0, 0, 0, 0.45);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100%;
}

/* ---------- 分页 ---------- */
.steam-library .sl-pager {
    margin-top: 16px;
    text-align: center;
}

.steam-library .sl-pager .pagination {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 4px;
    padding-left: 0;
    margin: 0;
    list-style: none;
}

.steam-library .sl-pager .pagination > li > a,
.steam-library .sl-pager .pagination > li > span {
    background: #fff;
    border: 1px solid #e8e8e8;
    color: #555;
    padding: 5px 12px;
    border-radius: 6px;
    display: block;
}

.steam-library .sl-pager .pagination > li > a:hover {
    background: #f5f5f5;
    border-color: #1890ff;
    color: #1890ff;
}

.steam-library .sl-pager .pagination > .active > span {
    background: #1890ff;
    border-color: #1890ff;
    color: #fff;
}

.steam-library .sl-pager .pagination > .disabled > span {
    color: rgba(0, 0, 0, 0.25);
    background: #fafafa;
}

/* ---------- 空状态 ---------- */
.steam-library .sl-empty {
    text-align: center;
    padding: 80px 0;
    color: rgba(0, 0, 0, 0.45);
}

/* ============================================
   详情页
   ============================================ */
.steam-library .sl-detail-top {
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    padding: 16px;
    margin-bottom: 16px;
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.steam-library .sl-detail-top .sl-detail-cover {
    width: 460px;
    max-width: 100%;
    flex-shrink: 0;
}

.steam-library .sl-detail-top .sl-detail-cover img {
    width: 100%;
    aspect-ratio: 460/215;
    object-fit: cover;
    border-radius: 6px;
    background: #f0f0f0;
}

.steam-library .sl-detail-info {
    flex: 1;
    min-width: 260px;
}

.steam-library .sl-detail-info h1 {
    margin: 0 0 4px 0;
    font-size: 24px;
    font-weight: 600;
    color: #262626;
}

.steam-library .sl-detail-info .sl-sub-title {
    color: rgba(0, 0, 0, 0.45);
    font-size: 13px;
}

.steam-library .sl-detail-tags {
    margin: 12px 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.steam-library .sl-detail-desc {
    margin: 12px 0;
    font-size: 13px;
    color: rgba(0, 0, 0, 0.65);
}

.steam-library .sl-detail-desc .sl-desc-item {
    display: flex;
    gap: 8px;
    margin-bottom: 4px;
}

.steam-library .sl-detail-desc .sl-desc-label {
    color: rgba(0, 0, 0, 0.45);
    width: 70px;
    flex-shrink: 0;
}

.steam-library .sl-actions {
    margin-top: 16px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.steam-library .sl-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: none;
    border-radius: 6px;
    padding: 0 20px;
    height: 40px;
    font-size: 15px;
    cursor: pointer;
    text-decoration: none;
}

.steam-library .sl-btn-primary {
    background: #1890ff;
    color: #fff;
}

.steam-library .sl-btn-primary:hover {
    background: #40a9ff;
    color: #fff;
    text-decoration: none;
}

.steam-library .sl-btn-disabled {
    background: #f5f5f5;
    border: 1px solid #e8e8e8;
    color: rgba(0, 0, 0, 0.25);
    cursor: not-allowed;
}

.steam-library .sl-btn-default {
    background: #fff;
    border: 1px solid #d9d9d9;
    color: #555;
}

.steam-library .sl-btn-default:hover {
    border-color: #1890ff;
    color: #1890ff;
    text-decoration: none;
}

.steam-library .sl-panel {
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    margin-bottom: 16px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.steam-library .sl-panel-head {
    padding: 12px 16px;
    border-bottom: 1px solid #e8e8e8;
    font-size: 15px;
    font-weight: 600;
    color: #262626;
}

.steam-library .sl-panel-body {
    padding: 16px;
    color: rgba(0, 0, 0, 0.65);
    line-height: 1.8;
    word-break: break-word;
}

.steam-library .sl-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fff;
    border: 1px solid #d9d9d9;
    color: #555;
    border-radius: 6px;
    padding: 0 14px;
    height: 32px;
    font-size: 13px;
    margin-bottom: 16px;
    cursor: pointer;
    text-decoration: none;
}

.steam-library .sl-back:hover {
    border-color: #1890ff;
    color: #1890ff;
    text-decoration: none;
}

/* ---------- 响应式（平板降级 4/3 列，手机 2 列） ---------- */
@media (max-width: 1199px) {
    .steam-library .sl-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 991px) {
    .steam-library .sl-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .steam-library .sl-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .steam-library .sl-detail-top .sl-detail-cover {
        width: 100%;
    }
}
