/* VR Store - Typography System */
/* Comprehensive typography standardization for consistent design */

/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Space+Grotesk:wght@300;400;500;600;700&display=swap');

/* Typography Variables */
:root {
    /* Font Families */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-heading: 'Space Grotesk', 'Inter', sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
    
    /* Font Weights */
    --font-weight-light: 300;
    --font-weight-normal: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
    --font-weight-extrabold: 800;
    --font-weight-black: 900;
    
    /* Font Sizes - Mobile First */
    --text-xs: 0.75rem;     /* 12px */
    --text-sm: 0.875rem;    /* 14px */
    --text-base: 1rem;      /* 16px */
    --text-lg: 1.125rem;    /* 18px */
    --text-xl: 1.25rem;     /* 20px */
    --text-2xl: 1.5rem;     /* 24px */
    --text-3xl: 1.875rem;   /* 30px */
    --text-4xl: 2.25rem;    /* 36px */
    --text-5xl: 3rem;       /* 48px */
    --text-6xl: 3.75rem;    /* 60px */
    
    /* Line Heights */
    --leading-none: 1;
    --leading-tight: 1.25;
    --leading-snug: 1.375;
    --leading-normal: 1.5;
    --leading-relaxed: 1.625;
    --leading-loose: 2;
    
    /* Letter Spacing */
    --tracking-tighter: -0.05em;
    --tracking-tight: -0.025em;
    --tracking-normal: 0em;
    --tracking-wide: 0.025em;
    --tracking-wider: 0.05em;
    --tracking-widest: 0.1em;
}

/* Base Typography */
html {
    font-size: 16px;
    line-height: var(--leading-normal);
}

body {
    font-family: var(--font-primary);
    font-weight: var(--font-weight-normal);
    font-size: var(--text-base);
    line-height: var(--leading-relaxed);
    color: var(--text-secondary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: var(--font-weight-bold);
    line-height: var(--leading-tight);
    margin-bottom: var(--spacing-md);
    color: var(--text-primary);
    letter-spacing: var(--tracking-tight);
}

h1 {
    font-size: clamp(var(--text-3xl), 5vw, var(--text-6xl));
    font-weight: var(--font-weight-extrabold);
    line-height: var(--leading-none);
    letter-spacing: var(--tracking-tighter);
    background: linear-gradient(135deg, var(--neon-purple), var(--neon-cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 20px rgba(139, 92, 246, 0.6);
    filter: drop-shadow(0 0 10px rgba(139, 92, 246, 0.8));
}

h2 {
    font-size: clamp(var(--text-2xl), 4vw, var(--text-5xl));
    font-weight: var(--font-weight-bold);
    line-height: var(--leading-tight);
    color: var(--text-primary);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

h3 {
    font-size: clamp(var(--text-xl), 3vw, var(--text-4xl));
    font-weight: var(--font-weight-semibold);
    line-height: var(--leading-snug);
    color: var(--text-primary);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

h4 {
    font-size: clamp(var(--text-lg), 2.5vw, var(--text-3xl));
    font-weight: var(--font-weight-semibold);
    line-height: var(--leading-snug);
    color: var(--text-secondary);
}

h5 {
    font-size: clamp(var(--text-base), 2vw, var(--text-2xl));
    font-weight: var(--font-weight-medium);
    line-height: var(--leading-normal);
    color: var(--text-secondary);
}

h6 {
    font-size: clamp(var(--text-sm), 1.5vw, var(--text-xl));
    font-weight: var(--font-weight-medium);
    line-height: var(--leading-normal);
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
}

/* Paragraph and Text Elements */
p {
    margin-bottom: var(--spacing-md);
    color: var(--text-secondary);
    font-size: var(--text-base);
    line-height: var(--leading-relaxed);
    font-weight: var(--font-weight-normal);
}

.lead {
    font-size: var(--text-lg);
    font-weight: var(--font-weight-normal);
    line-height: var(--leading-relaxed);
    color: var(--text-secondary);
    margin-bottom: var(--spacing-lg);
}

.text-large {
    font-size: var(--text-xl);
    line-height: var(--leading-normal);
}

.text-small {
    font-size: var(--text-sm);
    line-height: var(--leading-normal);
}

.text-xs {
    font-size: var(--text-xs);
    line-height: var(--leading-tight);
}

/* Links */
a {
    color: var(--text-accent);
    text-decoration: none;
    transition: var(--transition-fast);
    font-weight: var(--font-weight-medium);
}

a:hover {
    color: var(--neon-purple);
    text-shadow: 0 0 8px rgba(139, 92, 246, 0.5);
}

a:focus {
    outline: 2px solid var(--neon-purple);
    outline-offset: 2px;
    border-radius: var(--radius-sm);
}

/* Lists */
ul, ol {
    margin-bottom: var(--spacing-md);
    padding-left: var(--spacing-lg);
}

li {
    margin-bottom: var(--spacing-xs);
    line-height: var(--leading-relaxed);
    color: var(--text-secondary);
}

/* Code and Preformatted Text */
code {
    font-family: var(--font-mono);
    font-size: 0.875em;
    background: var(--bg-card);
    padding: 0.125rem 0.25rem;
    border-radius: var(--radius-sm);
    color: var(--neon-cyan);
    border: 1px solid rgba(139, 92, 246, 0.2);
}

pre {
    font-family: var(--font-mono);
    background: var(--bg-card);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    overflow-x: auto;
    border: 1px solid rgba(139, 92, 246, 0.2);
    margin-bottom: var(--spacing-md);
}

pre code {
    background: none;
    padding: 0;
    border: none;
    font-size: var(--text-sm);
}

/* Blockquotes */
blockquote {
    border-left: 4px solid var(--neon-purple);
    padding-left: var(--spacing-lg);
    margin: var(--spacing-lg) 0;
    font-style: italic;
    color: var(--text-muted);
    background: rgba(139, 92, 246, 0.05);
    padding: var(--spacing-md) var(--spacing-lg);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

blockquote p:last-child {
    margin-bottom: 0;
}

/* Text Utilities */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.text-justify { text-align: justify; }

.font-light { font-weight: var(--font-weight-light); }
.font-normal { font-weight: var(--font-weight-normal); }
.font-medium { font-weight: var(--font-weight-medium); }
.font-semibold { font-weight: var(--font-weight-semibold); }
.font-bold { font-weight: var(--font-weight-bold); }
.font-extrabold { font-weight: var(--font-weight-extrabold); }
.font-black { font-weight: var(--font-weight-black); }

.italic { font-style: italic; }
.not-italic { font-style: normal; }

.uppercase { text-transform: uppercase; }
.lowercase { text-transform: lowercase; }
.capitalize { text-transform: capitalize; }
.normal-case { text-transform: none; }

.underline { text-decoration: underline; }
.line-through { text-decoration: line-through; }
.no-underline { text-decoration: none; }

.tracking-tighter { letter-spacing: var(--tracking-tighter); }
.tracking-tight { letter-spacing: var(--tracking-tight); }
.tracking-normal { letter-spacing: var(--tracking-normal); }
.tracking-wide { letter-spacing: var(--tracking-wide); }
.tracking-wider { letter-spacing: var(--tracking-wider); }
.tracking-widest { letter-spacing: var(--tracking-widest); }

.leading-none { line-height: var(--leading-none); }
.leading-tight { line-height: var(--leading-tight); }
.leading-snug { line-height: var(--leading-snug); }
.leading-normal { line-height: var(--leading-normal); }
.leading-relaxed { line-height: var(--leading-relaxed); }
.leading-loose { line-height: var(--leading-loose); }

/* Color Utilities */
.text-primary { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }
.text-accent { color: var(--text-accent); }
.text-success { color: var(--success); }
.text-warning { color: var(--warning); }
.text-error { color: var(--error); }
.text-info { color: var(--info); }

/* Gradient Text */
.text-gradient {
    background: linear-gradient(135deg, var(--neon-purple), var(--neon-cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-gradient-alt {
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-pink));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Responsive Typography */
@media (max-width: 768px) {
    :root {
        --text-xs: 0.7rem;
        --text-sm: 0.8rem;
        --text-base: 0.9rem;
        --text-lg: 1rem;
        --text-xl: 1.125rem;
        --text-2xl: 1.25rem;
        --text-3xl: 1.5rem;
        --text-4xl: 1.875rem;
        --text-5xl: 2.25rem;
        --text-6xl: 3rem;
    }
    
    body {
        font-size: var(--text-base);
        line-height: var(--leading-relaxed);
    }
    
    h1, h2, h3, h4, h5, h6 {
        margin-bottom: var(--spacing-sm);
    }
    
    p {
        margin-bottom: var(--spacing-sm);
    }
}

@media (max-width: 480px) {
    :root {
        --text-xs: 0.65rem;
        --text-sm: 0.75rem;
        --text-base: 0.85rem;
        --text-lg: 0.95rem;
        --text-xl: 1rem;
        --text-2xl: 1.125rem;
        --text-3xl: 1.25rem;
        --text-4xl: 1.5rem;
        --text-5xl: 1.875rem;
        --text-6xl: 2.25rem;
    }
}

/* Print Styles */
@media print {
    body {
        font-family: 'Times New Roman', serif;
        font-size: 12pt;
        line-height: 1.4;
        color: #000;
    }
    
    h1, h2, h3, h4, h5, h6 {
        color: #000;
        text-shadow: none;
        background: none;
        -webkit-text-fill-color: initial;
    }
    
    a {
        color: #000;
        text-decoration: underline;
    }
    
    .text-gradient,
    .text-gradient-alt {
        color: #000;
        background: none;
        -webkit-text-fill-color: initial;
    }
}

/* Accessibility Improvements */
@media (prefers-reduced-motion: reduce) {
    * {
        text-shadow: none !important;
        filter: none !important;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    body {
        color: #000;
        background: #fff;
    }
    
    h1, h2, h3, h4, h5, h6 {
        color: #000;
        text-shadow: none;
        background: none;
        -webkit-text-fill-color: initial;
    }
    
    a {
        color: #0000EE;
        text-decoration: underline;
    }
    
    .text-gradient,
    .text-gradient-alt {
        color: #000;
        background: none;
        -webkit-text-fill-color: initial;
    }
}

/* Focus Visible for Better Accessibility */
*:focus-visible {
    outline: 2px solid var(--neon-purple);
    outline-offset: 2px;
    border-radius: var(--radius-sm);
}

/* Selection Styles */
::selection {
    background: rgba(139, 92, 246, 0.3);
    color: var(--text-primary);
}

::-moz-selection {
    background: rgba(139, 92, 246, 0.3);
    color: var(--text-primary);
}