/* main.css - Core styles, variables, and layout */

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* CSS Variables */
:root {
    /* Retrofuture palette - warmer, more vibrant */
    --bg: #0a0a0a;
    --bg-alt: #0f0e0e;
    --text: #e8e8e8;
    --text-bright: #ffffff;
    --accent: #ff6b6b;
    --accent-glow: #ff4444;
    --secondary: #4ecdc4;
    --tertiary: #f7b731;
    --muted: #888888;
    --border: rgba(255, 107, 107, 0.15);
    
    /* Refined glow effects */
    --glow-sm: 0 0 20px rgba(255, 107, 107, 0.3);
    --glow-md: 0 0 40px rgba(255, 107, 107, 0.2);
    --glow-text: 0 0 8px rgba(255, 107, 107, 0.4);
}

/* Selection styles */
::selection {
    background: var(--accent);
    color: var(--bg);
}

/* Prevent horizontal scroll on all devices */
html {
    overflow-x: hidden;
    max-width: 100%;
}

/* Body and main layout */
body {
    font-family: 'Libre Franklin', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    position: relative;
    max-width: 100%;
}

/* CRT effect - subtle */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(transparent 50%, rgba(255, 107, 107, 0.01) 50%),
        linear-gradient(90deg, rgba(255, 0, 0, 0.02), rgba(0, 255, 0, 0.01), rgba(0, 0, 255, 0.02));
    background-size: 100% 4px, 3px 100%;
    pointer-events: none;
    z-index: 2;
    opacity: 0.4;
}

/* Animated grid background */
.grid-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.03;
    background-image: 
        linear-gradient(var(--accent) 1px, transparent 1px),
        linear-gradient(90deg, var(--accent) 1px, transparent 1px);
    background-size: 100px 100px;
    z-index: 0;
    animation: gridMove 20s linear infinite;
}

/* Typography */
h1, h2, h3 {
    font-weight: 300;
    letter-spacing: -0.02em;
    color: var(--text-bright);
}

h1 {
    font-size: clamp(3rem, 8vw, 5.5rem);
    line-height: 0.9;
}

h2 {
    font-size: clamp(2rem, 5vw, 3rem);
    line-height: 1.1;
}

a {
    color: var(--text);
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

a:hover {
    color: var(--accent);
    text-shadow: var(--glow-text);
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    position: relative;
    z-index: 10;
}

/* Section structure */
section {
    padding: 3rem 0;
    position: relative;
}

/* Section animations */
section[data-section] {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

section[data-section].visible {
    opacity: 1;
    transform: translateY(0);
}

/* Section headers */
.section-header {
    margin-bottom: 2.5rem;
    font-family: 'JetBrains Mono', monospace;
    font-size: 2.2rem;
    letter-spacing: 0.05em;
    color: var(--muted);
    display: flex;
    align-items: center;
}

.section-header::before {
    content: '> ';
    color: var(--accent);
    margin-right: 0.5rem;
}

.section-name {
    color: var(--secondary);
}

/* Section taglines */
.section-tagline {
    font-family: 'Carrois Gothic', sans-serif;
    font-size: 2rem;
    font-weight: 400;
    color: var(--text-bright);
    margin-bottom: 2.5rem;
    letter-spacing: -0.02em;
    position: relative;
    padding-bottom: 1.5rem;
}

.section-tagline::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 2px;
    background: var(--accent);
    box-shadow: var(--glow-sm);
}

/* Footer */
footer {
    margin-top: 4rem;
    padding: 2rem 0;
    border-top: 1px solid var(--border);
    text-align: center;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.8rem;
    color: var(--muted);
}

/* Note: Mobile responsive styles are in mobile.css */