/* Veila App - Base Styles & Reset */

/* Font Loading */
@font-face {
    font-family: 'Manrope';
    src: url('/assets/fonts/Manrope-VariableFont_wght.ttf') format('truetype');
    font-weight: 200 800;
    font-style: normal;
    font-display: swap;
}

/* Global Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Base Typography */
html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: 'Manrope', -apple-system, BlinkMacSystemFont, "Segoe UI", "SF Pro Display", Roboto, sans-serif;
    font-weight: 300;
    line-height: 1.5;
    color: var(--text-primary);
    background: linear-gradient(135deg, #080808 0%, #0f0f0f 50%, #151515 100%);
    height: 100vh;
    overflow: hidden;
}

/* Background gradient effect */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 20%, rgba(124, 58, 237, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(114, 47, 55, 0.02) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

/* Links */
a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition-base);
}

a:hover {
    color: var(--accent-purple);
}

/* Buttons */
button {
    font-family: inherit;
    font-size: inherit;
    color: inherit;
    background: none;
    border: none;
    cursor: pointer;
    transition: var(--transition-base);
}

button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Forms */
input,
textarea,
select {
    font-family: inherit;
    font-size: inherit;
    color: inherit;
    background: var(--glass-secondary);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    padding: var(--spacing-sm) var(--spacing-md);
    transition: var(--transition-base);
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--border-active);
    background: var(--glass-hover);
    box-shadow: var(--shadow-glow);
}

/* Scrollbar Styles */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb {
    background: var(--glass-secondary);
    border-radius: 5px;
    border: 1px solid var(--border-glass);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--glass-hover);
    border-color: var(--border-active);
}

/* Selection */
::selection {
    background: var(--accent-purple);
    color: white;
}

::-moz-selection {
    background: var(--accent-purple);
    color: white;
}

/* Utility Classes */
.hidden {
    display: none !important;
}

.visible {
    visibility: visible !important;
}

.invisible {
    visibility: hidden !important;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Loading States */
.loading {
    position: relative;
    pointer-events: none;
    opacity: 0.7;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid var(--accent-purple);
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Focus Visible */
:focus-visible {
    outline: 2px solid var(--accent-purple);
    outline-offset: 2px;
}

/* Prevent text selection */
.no-select {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Text truncation */
.truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Line clamp */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}