/* Tool-specific styles that will be extended by individual tool pages */

/* Tool page layout */
.tool-page {
    padding: var(--space-3xl) 0;
}

.tool-header {
    text-align: center;
    margin-bottom: var(--space-3xl);
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.tool-header h1 {
    font-size: 2.5rem;
    margin-bottom: var(--space-md);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-md);
}

.tool-header h1 i {
    color: var(--primary-color);
}

.tool-description {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: var(--space-lg);
}

.tool-meta {
    display: flex;
    justify-content: center;
    gap: var(--space-xl);
    margin-top: var(--space-lg);
}

.tool-meta-item {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    color: var(--text-muted);
}

.tool-meta-item i {
    color: var(--primary-color);
}

/* Tool workflow */
.tool-workflow {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-2xl);
    margin-bottom: var(--space-3xl);
}

.workflow-step {
    text-align: center;
    padding: var(--space-xl);
    background-color: var(--bg-secondary);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
}

.step-number {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0 auto var(--space-lg);
}

.workflow-step h3 {
    margin-bottom: var(--space-md);
}

/* Tool options */
.tool-options {
    background-color: var(--bg-secondary);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    margin-bottom: var(--space-3xl);
}

.options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: var(--space-lg);
    margin-top: var(--space-lg);
}

.option-card {
    padding: var(--space-lg);
    background-color: var(--bg-primary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.option-card:hover {
    border-color: var(--primary-color);
    background-color: var(--bg-tertiary);
}

.option-card.active {
    border-color: var(--primary-color);
    background-color: var(--bg-tertiary);
    box-shadow: var(--shadow-md);
}

.option-icon {
    width: 50px;
    height: 50px;
    background-color: var(--bg-tertiary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--space-md);
}

.option-icon i {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.option-card h4 {
    margin-bottom: var(--space-sm);
}

.option-card p {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 0;
}

/* Tool results */
.tool-results {
    background-color: var(--bg-secondary);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
}

.result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-xl);
}

.result-actions {
    display: flex;
    gap: var(--space-md);
}

.result-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-lg);
    background-color: var(--bg-primary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    margin-bottom: var(--space-md);
}

.result-info {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.result-icon {
    width: 50px;
    height: 50px;
    background-color: var(--bg-tertiary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
}

.result-icon i {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.result-details h4 {
    margin-bottom: var(--space-xs);
}

.result-details p {
    margin-bottom: 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.result-actions {
    display: flex;
    gap: var(--space-sm);
}

/* Loading states */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--space-3xl);
    text-align: center;
}

.loading-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid var(--border-color);
    border-top-color: var(--primary-color);
    border-radius: var(--radius-full);
    animation: spin 1s linear infinite;
    margin-bottom: var(--space-lg);
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading-text {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Empty states */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--space-3xl);
    text-align: center;
}

.empty-state-icon {
    font-size: 4rem;
    color: var(--text-muted);
    margin-bottom: var(--space-lg);
}

.empty-state h3 {
    margin-bottom: var(--space-md);
}

.empty-state p {
    color: var(--text-muted);
    max-width: 400px;
    margin-bottom: var(--space-xl);
}

/* Advanced options */
.advanced-options {
    margin-top: var(--space-xl);
    padding-top: var(--space-xl);
    border-top: 1px solid var(--border-color);
}

.advanced-toggle {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 1rem;
    cursor: pointer;
    padding: var(--space-sm);
}

.advanced-toggle i {
    transition: transform var(--transition-fast);
}

.advanced-toggle.active i {
    transform: rotate(180deg);
}

.advanced-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height var(--transition-normal);
}

.advanced-content.active {
    max-height: 1000px;
    margin-top: var(--space-lg);
}

/* Range slider */
.range-slider {
    margin-bottom: var(--space-lg);
}

.range-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-md);
}

.range-value {
    font-weight: 600;
    color: var(--primary-color);
}

.range-track {
    height: 6px;
    background-color: var(--bg-tertiary);
    border-radius: var(--radius-full);
    position: relative;
    margin-bottom: var(--space-lg);
}

.range-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: var(--radius-full);
    width: 50%;
}

.range-thumb {
    width: 20px;
    height: 20px;
    background-color: var(--primary-color);
    border-radius: var(--radius-full);
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    cursor: pointer;
    box-shadow: var(--shadow-md);
}

.range-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* File list */
.file-list {
    margin-bottom: var(--space-xl);
}

.file-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-md);
    background-color: var(--bg-tertiary);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-sm);
    transition: all var(--transition-fast);
}

.file-item:hover {
    background-color: var(--bg-secondary);
}

.file-item-info {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.file-item-icon {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.file-item-details {
    flex: 1;
}

.file-item-details h4 {
    margin-bottom: var(--space-xs);
    font-size: 1rem;
}

.file-item-details p {
    margin-bottom: 0;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.file-item-actions {
    display: flex;
    gap: var(--space-sm);
}

.file-item-action {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: var(--space-xs);
    border-radius: var(--radius-sm);
}

.file-item-action:hover {
    color: var(--text-primary);
    background-color: var(--bg-primary);
}

/* Sortable list */
.sortable-list {
    margin-bottom: var(--space-xl);
}

.sortable-item {
    display: flex;
    align-items: center;
    padding: var(--space-md);
    background-color: var(--bg-tertiary);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-sm);
    cursor: move;
    transition: all var(--transition-fast);
}

.sortable-item:hover {
    background-color: var(--bg-secondary);
    transform: translateX(4px);
}

.sortable-item.dragging {
    opacity: 0.5;
    background-color: var(--bg-primary);
}

.sortable-handle {
    margin-right: var(--space-md);
    color: var(--text-muted);
    cursor: move;
}

.sortable-content {
    flex: 1;
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.sortable-index {
    width: 30px;
    height: 30px;
    background-color: var(--bg-primary);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--primary-color);
}

/* Responsive tool adjustments */
@media (max-width: 768px) {
    .tool-header h1 {
        font-size: 2rem;
        flex-direction: column;
        gap: var(--space-sm);
    }
    
    .tool-meta {
        flex-direction: column;
        gap: var(--space-md);
    }
    
    .result-header {
        flex-direction: column;
        gap: var(--space-lg);
        text-align: center;
    }
    
    .result-item {
        flex-direction: column;
        gap: var(--space-md);
        text-align: center;
    }
    
    .result-info {
        flex-direction: column;
    }
    
    .file-item {
        flex-direction: column;
        gap: var(--space-md);
        text-align: center;
    }
    
    .file-item-info {
        flex-direction: column;
    }
}