/* 工具卡片样式 */
.tool-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    padding: var(--spacing-md);
    box-shadow: var(--shadow-light);
    transition: var(--transition);
    cursor: pointer;
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
}

.tool-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-medium);
}

.tool-card:active {
    transform: translateY(-2px) scale(0.98);
}

/* 原创工具标识 */
.original-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 600;
    z-index: 2;
    box-shadow: 0 2px 8px rgba(255, 107, 107, 0.3);
}

.card-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius);
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-bottom: var(--spacing-sm);
}

.card-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: var(--spacing-xs);
    line-height: 1.3;
}

.card-description {
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: var(--spacing-sm);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-xs);
    margin-bottom: var(--spacing-sm);
}

.card-tag {
    background-color: var(--bg-secondary);
    color: var(--text-muted);
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
}

.card-action {
    width: 100%;
    padding: var(--spacing-xs) var(--spacing-sm);
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    border-radius: var(--radius);
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.card-action:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(91, 106, 255, 0.3);
}

.card-action:active {
    transform: translateY(0);
}

/* 模态框样式 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    backdrop-filter: blur(4px);
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
    animation: modal-fade-in 0.3s ease;
}

.modal-content {
    background: var(--bg-card);
    border-radius: var(--radius);
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: var(--shadow-medium);
    animation: modal-slide-up 0.3s ease;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-md);
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
}

.modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: none;
    font-size: 24px;
    cursor: pointer;
    border-radius: 6px;
    color: var(--text-secondary);
    transition: var(--transition);
}

.modal-close:hover {
    background-color: var(--bg-secondary);
    color: var(--text-primary);
}

.modal-body {
    padding: var(--spacing-md);
}

/* 模态框动画 */
@keyframes modal-fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes modal-slide-up {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 加载状态 */
.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-lg);
    color: var(--text-secondary);
}

.loading::after {
    content: '';
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-color);
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: var(--spacing-xs);
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 通知样式 */
.notification {
    position: fixed;
    top: 80px;
    right: var(--spacing-md);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: var(--spacing-sm) var(--spacing-md);
    box-shadow: var(--shadow-medium);
    z-index: 1001;
    transform: translateX(100%);
    transition: var(--transition);
}

.notification.show {
    transform: translateX(0);
}

.notification.success {
    border-left: 4px solid #10B981;
}

.notification.error {
    border-left: 4px solid #EF4444;
}

.notification.info {
    border-left: 4px solid var(--primary-color);
}