/* 插件市场页面样式 */

/* 页面标题 */
.page-title {
    font-size: 28px;
    margin: 30px 0;
    text-align: center;
    color: #333;
}

/* 筛选栏 */
.filter-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #fff;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.filter-group {
    display: flex;
    align-items: center;
    margin-right: 20px;
}

.filter-group label {
    margin-right: 10px;
    font-weight: 500;
    color: #666;
}

.filter-select {
    padding: 8px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: #fff;
    font-size: 14px;
    color: #333;
    appearance: none;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="%23666" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="6 9 12 15 18 9"></polyline></svg>');
    background-repeat: no-repeat;
    background-position: right 10px center;
    padding-right: 30px;
}

/* 插件列表 */
.plugin-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 40px;
}

.plugin-item {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
    display: flex;
    flex-direction: column;
}

.plugin-item:hover {
    transform: translateY(-10px);
}

.plugin-image {
    width: 100%;
    height: 180px;
    overflow: hidden;
}

.plugin-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.plugin-item:hover .plugin-image img {
    transform: scale(1.05);
}

.plugin-info {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.plugin-name {
    font-size: 18px;
    margin-bottom: 10px;
    color: #333;
}

.plugin-description {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
    line-height: 1.6;
    flex: 1;
}

.plugin-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    font-size: 14px;
    color: #666;
}

.plugin-rating {
    color: #f39c12;
    font-weight: 500;
}

.plugin-price {
    margin-bottom: 20px;
}

.current-price {
    font-size: 20px;
    color: #e74c3c;
    font-weight: bold;
}

.original-price {
    font-size: 14px;
    color: #999;
    text-decoration: line-through;
    margin-left: 10px;
}

.free-tag {
    display: inline-block;
    padding: 3px 10px;
    background-color: #1aad19;
    color: #fff;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
}

.plugin-action {
    margin-top: auto;
}

.buy-btn {
    background-color: #e74c3c;
    color: #fff;
    border: none;
    width: 100%;
    padding: 12px;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.buy-btn:hover {
    background-color: #c0392b;
}

.cart-btn {
    background-color: #f39c12;
    color: #fff;
    border: none;
    padding: 10px 15px;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.3s;
    margin-right: 10px;
}

.cart-btn:hover {
    background-color: #d35400;
}

.demo-btn {
    background-color: #3498db;
    color: #fff;
    border: none;
    padding: 10px 15px;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.demo-btn:hover {
    background-color: #2980b9;
}

/* 加载更多 */
.load-more {
    text-align: center;
    margin: 40px 0;
}

.load-more-btn {
    background-color: #fff;
    color: #1aad19;
    border: 1px solid #1aad19;
    padding: 12px 30px;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s;
}

.load-more-btn:hover {
    background-color: #1aad19;
    color: #fff;
}

/* 插件详情页面 */
.plugin-detail {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 30px;
}

.plugin-header {
    display: flex;
    margin-bottom: 30px;
}

.plugin-cover {
    width: 40%;
    margin-right: 30px;
}

.plugin-cover img {
    width: 100%;
    height: auto;
    border-radius: 8px;
}

.plugin-basic-info {
    flex: 1;
}

.plugin-title {
    font-size: 28px;
    margin-bottom: 15px;
    color: #333;
}

.plugin-rating {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    font-size: 16px;
    color: #666;
}

.plugin-rating span {
    margin-right: 20px;
}

.plugin-desc {
    font-size: 16px;
    color: #666;
    margin-bottom: 20px;
    line-height: 1.8;
}

.plugin-price {
    margin-bottom: 25px;
}

.plugin-actions {
    display: flex;
}

/* 标签页 */
.plugin-tabs {
    margin-bottom: 30px;
}

.tabs-nav {
    display: flex;
    border-bottom: 1px solid #ddd;
    margin-bottom: 20px;
}

.tab-btn {
    padding: 12px 24px;
    font-size: 16px;
    color: #666;
    background-color: transparent;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    margin-right: 5px;
}

.tab-btn.active {
    color: #1aad19;
    border-bottom: 3px solid #1aad19;
    font-weight: 500;
}

.tab-btn:hover {
    color: #1aad19;
}

.tab-content {
    display: none;
    padding: 20px 0;
}

.tab-content.active {
    display: block;
}

/* 功能特点 */
.feature-list {
    list-style: none;
}

.feature-list li {
    padding: 12px 0;
    border-bottom: 1px dashed #eee;
    font-size: 16px;
    color: #333;
}

.feature-list li i {
    color: #1aad19;
    margin-right: 10px;
}

/* 截图展示 */
.screenshot-gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.screenshot-item {
    flex: 1 1 300px;
    overflow: hidden;
    border-radius: 8px;
}

.screenshot-item img {
    width: 100%;
    height: auto;
    transition: transform 0.3s;
}

.screenshot-item:hover img {
    transform: scale(1.05);
}

/* 用户评价 */
.review-list {
    margin-top: 20px;
}

.review-item {
    padding: 20px 0;
    border-bottom: 1px solid #eee;
    display: flex;
}

.review-avatar {
    margin-right: 20px;
}

.review-avatar img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
}

.review-content {
    flex: 1;
}

.review-user-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.review-username {
    font-weight: 500;
    color: #333;
}

.review-rating {
    color: #f39c12;
}

.review-date {
    color: #999;
    font-size: 14px;
}

.review-text {
    color: #666;
    line-height: 1.6;
}

/* 常见问题 */
.faq-item {
    margin-bottom: 15px;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
}

.faq-question {
    font-weight: 500;
    color: #333;
    margin-bottom: 10px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-question::after {
    content: '+';
    font-size: 20px;
    color: #1aad19;
}

.faq-question.active::after {
    content: '-';
}

.faq-answer {
    display: none;
    color: #666;
    line-height: 1.6;
}

.faq-answer.show {
    display: block;
}

/* 相关插件 */
.related-plugins {
    margin-top: 40px;
}

.related-plugins h3 {
    font-size: 20px;
    margin-bottom: 20px;
    color: #333;
}

.related-plugin-list {
    display: flex;
    overflow-x: auto;
    gap: 20px;
    padding-bottom: 10px;
}

.related-plugin-item {
    min-width: 250px;
    background-color: #f8f8f8;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s;
    cursor: pointer;
}

.related-plugin-item:hover {
    transform: translateY(-5px);
}

.related-plugin-image {
    height: 150px;
    overflow: hidden;
}

.related-plugin-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.related-plugin-info {
    padding: 15px;
}

.related-plugin-name {
    font-size: 16px;
    margin-bottom: 10px;
    color: #333;
}

.related-plugin-description {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.related-plugin-price {
    font-size: 16px;
    color: #e74c3c;
    font-weight: bold;
}

/* 加载中状态 */
.loading {
    text-align: center;
    padding: 50px 0;
    color: #666;
    font-size: 16px;
}

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 5px solid #f3f3f3;
    border-top: 5px solid #1aad19;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 无结果状态 */
.no-result {
    text-align: center;
    padding: 50px 0;
    color: #999;
    font-size: 16px;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .plugin-list {
        grid-template-columns: repeat(2, 1fr);
    }

    .plugin-header {
        flex-direction: column;
    }

    .plugin-cover {
        width: 100%;
        margin-right: 0;
        margin-bottom: 20px;
    }
}

@media (max-width: 768px) {
    .filter-bar {
        flex-wrap: wrap;
    }

    .filter-group {
        margin-bottom: 15px;
    }

    .plugin-list {
        grid-template-columns: 1fr;
    }

    .tabs-nav {
        overflow-x: auto;
        padding-bottom: 10px;
    }

    .tab-btn {
        white-space: nowrap;
    }
}

@media (max-width: 576px) {
    .plugin-detail {
        padding: 20px;
    }

    .plugin-title {
        font-size: 24px;
    }

    .plugin-actions {
        flex-direction: column;
    }

    .cart-btn, .demo-btn {
        margin-right: 0;
        margin-bottom: 10px;
        width: 100%;
    }
}