.lstm-market {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 24px;
    box-sizing: border-box;
}

.lstm-hero {
    text-align: center;
    padding: 40px 16px 32px;
    border-radius: 20px;
    background: linear-gradient(135deg, #f0fdf4 0%, #ecfeff 100%);
    margin-bottom: 28px;
}

.lstm-hero-title {
    font-size: 28px;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 12px;
    line-height: 1.35;
}

.lstm-hero-subtitle {
    font-size: 15px;
    color: #475569;
    max-width: 640px;
    margin: 0 auto 20px;
    line-height: 1.7;
}

.lstm-hero-meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
}

.lstm-hero-badge {
    font-size: 13px;
    font-weight: 600;
    color: #0f766e;
    background: #ffffff;
    border: 1px solid #d1fae5;
    padding: 6px 14px;
    border-radius: 999px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.lstm-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
}

.lstm-filter-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #475569;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    padding: 7px 14px;
    border-radius: 999px;
    text-decoration: none;
    transition: all 0.15s ease;
}

.lstm-filter-pill:hover {
    border-color: #16a34a;
    color: #16a34a;
}

.lstm-filter-pill.is-active {
    background: #16a34a;
    border-color: #16a34a;
    color: #ffffff;
}

.lstm-filter-count {
    font-size: 11px;
    opacity: 0.85;
}

.lstm-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    margin: 24px 0;
}

.lstm-card {
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border: 1px solid #f0f0f0;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 8px 24px rgba(0, 0, 0, 0.04);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.lstm-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08), 0 16px 32px rgba(0, 0, 0, 0.06);
}

.lstm-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.lstm-card-category {
    font-size: 12px;
    font-weight: 600;
    color: #16a34a;
    background: #ecfdf5;
    padding: 4px 10px;
    border-radius: 999px;
}

.lstm-card-price {
    font-size: 13px;
    font-weight: 600;
    color: #92400e;
    background: #fffbeb;
    padding: 4px 10px;
    border-radius: 999px;
}

.lstm-card-price.is-free {
    color: #0f766e;
    background: #f0fdfa;
}

.lstm-card-title {
    font-size: 18px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 8px;
    line-height: 1.4;
}

.lstm-card-desc {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.6;
    margin: 0 0 16px;
    flex-grow: 1;
}

.lstm-card-stats {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 14px;
    margin-bottom: 20px;
    font-size: 12px;
    color: #4b5563;
}

.lstm-card-stats span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.lstm-card-downloads {
    margin-left: auto;
    color: #9ca3af;
}

.lstm-dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
}

.lstm-dot-indicator { background: #3b82f6; }
.lstm-dot-condition { background: #a855f7; }
.lstm-dot-signal { background: #f59e0b; }

.lstm-card-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: auto;
}

.lstm-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 16px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.lstm-btn-arrow {
    transition: transform 0.15s ease;
}

.lstm-btn:hover .lstm-btn-arrow {
    transform: translateX(3px);
}

.lstm-btn-primary {
    background: #16a34a;
    color: #ffffff;
}

.lstm-btn-primary:hover {
    background: #15803d;
    color: #ffffff;
}

.lstm-btn-outline {
    background: #ffffff;
    color: #16a34a;
    border: 1px solid #16a34a;
}

.lstm-btn-outline:hover {
    background: #ecfdf5;
}

.lstm-card-fallback {
    display: block;
    margin-top: 8px;
    text-align: center;
    font-size: 12px;
    color: #94a3b8;
    text-decoration: none;
}

.lstm-card-fallback:hover {
    color: #16a34a;
    text-decoration: underline;
}

.lstm-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    pointer-events: none;
}

/* 权重与浏览器默认的 [hidden] { display: none } 打平，必须显式声明覆盖，
   否则未打开时这个 position: fixed 的全屏层依然会拦截整个页面的点击。 */
.lstm-modal[hidden] {
    display: none;
}

.lstm-modal.is-open {
    pointer-events: auto;
}

.lstm-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
    opacity: 0;
    transition: opacity 0.15s ease;
}

.lstm-modal-dialog {
    position: relative;
    width: 100%;
    max-width: 420px;
    background: #ffffff;
    border-radius: 16px;
    padding: 32px 28px 28px;
    text-align: center;
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.25);
    transform: translateY(12px) scale(0.97);
    opacity: 0;
    transition: opacity 0.18s ease, transform 0.18s ease;
}

.lstm-modal.is-open .lstm-modal-backdrop {
    opacity: 1;
}

.lstm-modal.is-open .lstm-modal-dialog {
    transform: translateY(0) scale(1);
    opacity: 1;
}

.lstm-modal-close {
    position: absolute;
    top: 10px;
    right: 14px;
    border: none;
    background: transparent;
    font-size: 22px;
    line-height: 1;
    color: #94a3b8;
    cursor: pointer;
    padding: 4px;
}

.lstm-modal-close:hover {
    color: #475569;
}

.lstm-modal-icon {
    font-size: 32px;
    margin-bottom: 8px;
}

.lstm-modal-title {
    margin: 0 0 12px;
    font-size: 18px;
    font-weight: 700;
    color: #0f172a;
}

.lstm-modal-desc {
    margin: 0 0 22px;
    font-size: 13.5px;
    line-height: 1.7;
    color: #64748b;
}

.lstm-modal-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.lstm-modal-actions .lstm-btn {
    justify-content: center;
    width: 100%;
}

.lstm-empty {
    text-align: center;
    color: #9ca3af;
    padding: 64px 0;
    font-size: 15px;
}

.lstm-empty-icon {
    font-size: 36px;
    margin-bottom: 12px;
}

.lstm-pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 28px;
}

.lstm-page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    border-radius: 8px;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    color: #374151;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.15s ease;
}

.lstm-page-link:hover {
    border-color: #16a34a;
    color: #16a34a;
}

.lstm-page-link.is-active {
    background: #16a34a;
    border-color: #16a34a;
    color: #ffffff;
}

.lstm-page-nav {
    font-weight: 600;
    padding: 0 14px;
}

.lstm-page-ellipsis {
    color: #9ca3af;
    padding: 0 4px;
}

.lstm-disclaimer {
    margin-top: 32px;
    padding: 14px 18px;
    border-radius: 12px;
    background: #f9fafb;
    color: #9ca3af;
    font-size: 12px;
    line-height: 1.7;
    text-align: center;
}

@media (max-width: 640px) {
    .lstm-market {
        padding: 0 16px;
    }

    .lstm-hero {
        padding: 28px 16px 24px;
    }

    .lstm-hero-title {
        font-size: 22px;
    }
}
