@import './design-tokens.css'; * { margin: 0; padding: 0; box-sizing: border-box; } html, body, #root { width: 100%; height: 100%; overflow: hidden; } body { font-family: var(--font-family-base); font-size: var(--font-size-base); line-height: var(--line-height-base); color: var(--color-text-primary); background-color: var(--color-bg-base); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; /* 禁用全局文本选择,原生应用风格 | Disable global text selection for native app feel */ user-select: none; -webkit-user-select: none; } button { font-family: inherit; font-size: inherit; cursor: pointer; } input, textarea, select { font-family: inherit; font-size: inherit; /* 输入框允许文本选择 | Allow text selection in inputs */ user-select: text; -webkit-user-select: text; } :focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; } ::selection { background-color: var(--color-primary); color: var(--color-text-inverse); } /* 允许特定元素文本选择 | Allow text selection for specific elements */ .selectable, pre, code, .code-preview-content, .file-preview-content, .output-log-content, .json-viewer { user-select: text; -webkit-user-select: text; } /* 全局滚动条样式 */ ::-webkit-scrollbar { width: 8px; height: 8px; } ::-webkit-scrollbar-track { background: transparent; } ::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.1); border-radius: 4px; transition: background 0.2s ease; } ::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.2); } ::-webkit-scrollbar-thumb:active { background: rgba(255, 255, 255, 0.3); } ::-webkit-scrollbar-corner { background: transparent; } .scrollable { overflow: auto; } .scrollable::-webkit-scrollbar { width: 10px; height: 10px; } .scrollable::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.12); border-radius: 5px; border: 2px solid transparent; background-clip: padding-box; } .scrollable::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.2); background-clip: padding-box; } .scrollable::-webkit-scrollbar-corner { background: transparent; } @keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } } @keyframes slideDown { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } } @keyframes slideUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } } @keyframes scaleIn { from { opacity: 0; transform: scale(0.95); } to { opacity: 1; transform: scale(1); } } @keyframes spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } } .animate-fadeIn { animation: fadeIn var(--transition-base); } .animate-slideDown { animation: slideDown var(--transition-base); } .animate-slideUp { animation: slideUp var(--transition-base); } .animate-scaleIn { animation: scaleIn var(--transition-base); } .animate-spin { animation: spin 1s linear infinite; }