/* 文件用途：包含所有CSS样式，包括动画、工具类等 */

@tailwind base;
@tailwind components;
@tailwind utilities;


.loading-spinner { 
    border-top-color: #3b82f6; 
    animation: spin 1s linear infinite; 
}
@keyframes spin { 
    0% { transform: rotate(0deg); } 
    100% { transform: rotate(360deg); } 
}
.risk-tag { 
    animation: pulse 2s infinite; 
}
@keyframes pulse { 
    0%, 100% { opacity: 1; } 
    50% { opacity: .5; } 
}
.fade-in { 
    animation: fadeIn 0.4s ease-out; 
}
@keyframes fadeIn { 
    from { opacity: 0; transform: translateY(10px); } 
    to { opacity: 1; transform: translateY(0); } 
}
.risk-highlight {
    background-color: #fee2e2;
    padding: 1px 3px;
    border-radius: 3px;
    font-weight: bold;
    text-decoration: underline;
}
.slide-in {
    animation: slideIn 0.3s ease-out;
}
@keyframes slideIn {
    from { opacity: 0; transform: translateX(-10px); }
    to { opacity: 1; transform: translateX(0); }
}
.toast {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.9);
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    z-index: 1000;
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    animation: toastIn 0.3s ease-out;
}
@keyframes toastIn {
    from { opacity: 0; transform: translate(-50%, -20px); }
    to { opacity: 1; transform: translate(-50%, 0); }
}
.toast-out {
    animation: toastOut 0.3s ease-in forwards;
}
@keyframes toastOut {
    from { opacity: 1; transform: translate(-50%, 0); }
    to { opacity: 0; transform: translate(-50%, -20px); }
}
.gradient-border {
    position: relative;
    background: linear-gradient(white, white) padding-box,
                linear-gradient(135deg, #f59e0b, #3b82f6) border-box;
    border: 2px solid transparent;
}
.shimmer {
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.4) 50%,
        transparent 100%
    );
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
}
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}
.single-click {
    transition: all 0.3s ease;
}
.single-click.disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}
.single-click.disabled:hover {
    transform: none !important;
}
.result-text {
    white-space: pre-wrap;
    word-break: break-word;
    line-height: 1.6;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
}