/**
 * 粤语拼音转换工具 - 专用样式
 * 注意：工具页面公共样式已在 tools-common.css 中定义
 * 本文件仅定义工具特有的样式
 */

/* 输入区域 */
.input-section {
    margin-bottom: 30px;
}

.input-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 12px;
}

.input-textarea {
    width: 100%;
    padding: 16px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 15px;
    line-height: 1.8;
    resize: vertical;
    transition: all 0.3s ease;
    font-family: 'Microsoft YaHei', 'SimSun', sans-serif;
}

.input-textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.input-info {
    display: flex;
    justify-content: flex-end;
    margin-top: 8px;
}

.char-count {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: #6b7280;
}

/* 快捷示例按钮 */
.example-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.example-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.example-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/* 转换选项区域 */
.options-section {
    background: #f9fafb;
    padding: 24px;
    border-radius: 12px;
    margin-bottom: 24px;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 20px;
}

.options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.option-group h3 {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 12px;
}

.radio-group,
.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.radio-label,
.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px;
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.radio-label:hover,
.checkbox-label:hover {
    border-color: #3b82f6;
    background: #eff6ff;
}

.radio-label input[type="radio"],
.checkbox-label input[type="checkbox"] {
    margin-top: 2px;
    cursor: pointer;
}

.radio-text,
.checkbox-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.radio-text strong,
.checkbox-text strong {
    color: #1f2937;
    font-size: 14px;
}

.radio-text small,
.checkbox-text small {
    color: #6b7280;
    font-size: 13px;
}

/* 操作按钮 */
.action-buttons {
    display: flex;
    gap: 12px;
    margin-bottom: 30px;
}

.btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(102, 126, 234, 0.3);
}

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-secondary {
    background: #f3f4f6;
    color: #374151;
}

.btn-secondary:hover {
    background: #e5e7eb;
}

/* 结果展示区 */
.result-section {
    margin-top: 30px;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.result-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border-radius: 12px 12px 0 0;
    font-weight: 600;
}

.result-stats {
    margin-left: auto;
    font-size: 14px;
    opacity: 0.9;
}

.result-card {
    background: white;
    border: 2px solid #e5e7eb;
    border-top: none;
    border-radius: 0 0 12px 12px;
    padding: 24px;
}

.result-item {
    margin-bottom: 20px;
}

.result-item:last-of-type {
    margin-bottom: 24px;
}

.result-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 10px;
    font-size: 15px;
}

.result-text {
    padding: 16px;
    background: #f9fafb;
    border-radius: 8px;
    font-size: 15px;
    line-height: 1.8;
    color: #1f2937;
    word-wrap: break-word;
    font-family: 'Microsoft YaHei', 'SimSun', sans-serif;
}

.result-jyutping {
    font-family: 'Courier New', monospace;
    font-size: 16px;
    font-weight: 500;
    color: #7c3aed;
}

.result-actions {
    display: flex;
    gap: 12px;
    padding-top: 16px;
    border-top: 1px solid #e5e7eb;
}

.btn-copy {
    background: linear-gradient(135deg, #06b6d4 0%, #0891b2 100%);
    color: white;
}

.btn-copy:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(6, 182, 212, 0.3);
}

/* 复制提示 */
.copy-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: rgba(16, 185, 129, 0.95);
    color: white;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    opacity: 0;
    transform: translateY(-100px);
    transition: all 0.3s ease;
    z-index: 10000;
}

.copy-toast.show {
    opacity: 1;
    transform: translateY(0);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .options-grid {
        grid-template-columns: 1fr;
    }

    .action-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
    }

    .result-actions {
        flex-direction: column;
    }

    .example-buttons {
        gap: 8px;
    }

    .example-btn {
        font-size: 13px;
        padding: 6px 12px;
    }
}

@media (max-width: 480px) {
    .input-textarea {
        font-size: 14px;
    }

    .result-text {
        font-size: 14px;
    }

    .copy-toast {
        right: 10px;
        left: 10px;
        justify-content: center;
    }
}
