/* 花体英文字体转换工具样式 */

/* 结果展示区域 */
#results {
    display: none;
}

#results.show {
    display: block;
}

.result-card {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.result-card:hover {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    border-color: #d1d5db;
}

.font-type-label {
    color: #6b7280;
    font-size: 12px;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 6px;
    white-space: nowrap;
    min-width: 60px;
    text-align: center;
}

.converted-text {
    flex: 1;
    font-size: 16px;
    line-height: 1.5;
    color: #111827;
    word-break: break-all;
    padding: 8px 12px;
    border-radius: 8px;
    min-height: 40px;
    display: flex;
    align-items: center;
}

.copy-button {
    background: #3b82f6;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
}

.copy-button:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

.copy-button:active {
    transform: translateY(0);
}

.copy-btn {
    background: #3b82f6;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.copy-btn:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

.copy-btn:active {
    transform: translateY(0);
}

.copy-btn.copied {
    background: #10b981;
}

.copy-btn.copied:hover {
    background: #059669;
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: #6b7280;
}

.empty-state svg {
    margin: 0 auto 1rem;
    opacity: 0.5;
}

.empty-state h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #374151;
}

.empty-state p {
    font-size: 0.875rem;
    line-height: 1.5;
}

/* 消息提示 */
.message {
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.message.error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
}

.message.success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #16a34a;
}

.message svg {
    flex-shrink: 0;
    width: 1.25rem;
    height: 1.25rem;
}

/* 响应式设计 */
@media (max-width: 640px) {
    .font-preview {
        font-size: 1.125rem;
        padding: 0.5rem;
    }
    
    .font-result-item {
        padding: 0.75rem;
    }
    
    .font-name {
        font-size: 0.8125rem;
    }
    
    .copy-btn {
        padding: 0.375rem 0.75rem;
        font-size: 0.8125rem;
    }
}

@media (max-width: 480px) {
    .font-preview {
        font-size: 1rem;
        line-height: 1.5;
        min-height: 2.5rem;
    }
    
    .empty-state {
        padding: 2rem 0.5rem;
    }
    
    .empty-state h3 {
        font-size: 1rem;
    }
    
    .empty-state p {
        font-size: 0.8125rem;
    }
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid #f3f4f6;
    border-radius: 50%;
    border-top-color: #3b82f6;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* 字符计数样式 */
#charCount.warning {
    color: #f59e0b;
}

#charCount.danger {
    color: #ef4444;
}

/* 输入框焦点状态优化 */
#inputText:focus {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* 按钮组响应式 */
@media (max-width: 640px) {
    .space-x-4 > * + * {
        margin-left: 0;
        margin-top: 0.75rem;
    }
    
    .space-x-4 {
        flex-direction: column;
        gap: 0;
    }
}

/* 示例按钮网格响应式优化 */
@media (max-width: 768px) {
    .grid.grid-cols-2.md\:grid-cols-3.lg\:grid-cols-4 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 480px) {
    .grid.grid-cols-2.md\:grid-cols-3.lg\:grid-cols-4 {
        grid-template-columns: repeat(1, minmax(0, 1fr));
    }
}