/* 文本工具页面样式 */

/* 页面标题 */
.page-header {
    background-color: var(--light-bg);
    padding: 3rem 0;
    border-bottom: 1px solid var(--border-color);
}

.page-header h1 {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
    color: var(--dark-text);
}

.page-header p {
    color: var(--light-text);
    font-size: 1.1rem;
}

/* 工具区域 */
.tool-section {
    padding: 4rem 0;
}

/* 工具选项卡 */
.tool-tabs {
    display: flex;
    flex-wrap: wrap;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 2rem;
}

.tool-tab {
    padding: 0.8rem 1.5rem;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    font-size: 1rem;
    font-weight: 500;
    color: var(--light-text);
    cursor: pointer;
    transition: all 0.3s ease;
}

.tool-tab.active {
    border-bottom-color: var(--primary-color);
    color: var(--primary-color);
}

.tool-tab:hover:not(.active) {
    color: var(--dark-text);
    border-bottom-color: var(--border-color);
}

/* 工具面板 */
.tool-panel {
    display: none;
}

.tool-panel.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.tool-description {
    margin-bottom: 1.5rem;
}

.tool-description h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--dark-text);
}

.tool-description p {
    color: var(--light-text);
}

/* 工具输入区域 */
.tool-input {
    margin-bottom: 1.5rem;
}

.tool-input textarea {
    width: 100%;
    min-height: 200px;
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-family: inherit;
    font-size: 1rem;
    resize: vertical;
    transition: border-color 0.3s ease;
}

.tool-input textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

/* 工具操作按钮 */
.tool-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}

/* 工具结果区域 */
.tool-results {
    background-color: var(--light-bg);
    border-radius: 6px;
    padding: 1.5rem;
}

.result-item {
    display: flex;
    margin-bottom: 0.8rem;
}

.result-label {
    font-weight: 500;
    min-width: 100px;
    color: var(--dark-text);
}

.result-value {
    color: var(--primary-color);
    font-family: monospace;
}

.conversion-result, .formatted-result {
    background-color: white;
    padding: 1rem;
    border-radius: 4px;
    min-height: 100px;
    border: 1px solid var(--border-color);
    white-space: pre-wrap;
    word-wrap: break-word;
    font-family: monospace;
}

/* 使用指南 */
.usage-guide {
    padding: 4rem 0;
    background-color: var(--light-bg);
}

.usage-guide h2 {
    text-align: center;
    margin-bottom: 3rem;
    color: var(--dark-text);
}

.guide-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.guide-step {
    display: flex;
    align-items: flex-start;
}

.step-number {
    width: 40px;
    height: 40px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin-right: 1rem;
    flex-shrink: 0;
}

.step-content h3 {
    margin-bottom: 0.5rem;
    color: var(--dark-text);
}

.step-content p {
    color: var(--light-text);
}

/* 响应式调整 */
@media (max-width: 768px) {
    .page-header {
        padding: 2rem 0;
    }
    
    .tool-section, .usage-guide {
        padding: 2.5rem 0;
    }
    
    .tool-tab {
        padding: 0.8rem 1rem;
        font-size: 0.9rem;
    }
}
