@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --color-primary: #0f172a;
    --color-primary-contrast: #ffffff;
    --color-primary-soft: #e2e8f0;
    --color-secondary: #475569;
    --color-accent: #3b82f6;
    --color-accent-soft: #dbeafe;
    --color-surface: #ffffff;
    --color-surface-soft: #f8fafc;
    --color-surface-raised: #f1f5f9;
    --color-text: #0f172a;
    --color-text-soft: #64748b;
    --color-text-muted: #94a3b8;
    --color-border: #e2e8f0;
    --color-success: #10b981;
    --color-success-soft: #d1fae5;
    --color-warning: #f59e0b;
    --color-warning-soft: #fef3c7;
    --color-danger: #ef4444;
    --color-danger-soft: #fee2e2;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-pill: 9999px;
    --font-main: 'Inter', system-ui, -apple-system, sans-serif;
    --font-title: 'Inter', system-ui, -apple-system, sans-serif;
    --sidebar-width: 280px;
    --transition-fast: 150ms ease;
    --transition-base: 200ms ease;
    --transition-slow: 300ms ease;
}

[data-theme="dark"] {
    --color-primary: #f8fafc;
    --color-primary-contrast: #0f172a;
    --color-primary-soft: #1e293b;
    --color-secondary: #94a3b8;
    --color-accent: #60a5fa;
    --color-accent-soft: #1e3a5f;
    --color-surface: #0f172a;
    --color-surface-soft: #1e293b;
    --color-surface-raised: #334155;
    --color-text: #f1f5f9;
    --color-text-soft: #94a3b8;
    --color-text-muted: #64748b;
    --color-border: #334155;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4), 0 2px 4px -1px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -2px rgba(0, 0, 0, 0.3);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.5), 0 10px 10px -5px rgba(0, 0, 0, 0.4);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    overflow-x: hidden;
    font-family: var(--font-main);
    color: var(--color-text);
    background:
        radial-gradient(circle at top left, rgba(66, 133, 244, 0.08), transparent 32%),
        radial-gradient(circle at top right, rgba(20, 128, 74, 0.08), transparent 28%),
        var(--color-surface);
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--color-primary);
    text-decoration: none;
}

button,
input,
textarea,
select {
    font: inherit;
    color: inherit;
}

img {
    max-width: 100%;
    display: block;
}

.fade-in {
    animation: fadeIn var(--transition-slow) ease-out both;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.loading {
    position: relative;
    pointer-events: none;
    opacity: 0.7;
}

.loading::after {
    content: "";
    position: absolute;
    inset: 0;
    background: var(--color-surface);
    opacity: 0.5;
    border-radius: inherit;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid var(--color-border);
    border-top-color: var(--color-accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
