/* --- Zmienne globalne i reset --- */
:root {
    --bg-color: #0d1117;
    --primary-color: #c9d1d9;
    --secondary-color: #8b949e;
    --accent-color: #58a6ff;
    --border-color: rgba(255, 255, 255, 0.1);
    --card-bg: rgba(22, 27, 34, 0.7);
    --font-main: 'Manrope', sans-serif;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    background-color: var(--bg-color);
    color: var(--primary-color);
    font-family: var(--font-main);
    line-height: 1.6;
    overflow: hidden; /* Zapobiega paskom przewijania podczas animacji */
    cursor: none;
}

/* --- Preloader --- */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--bg-color);
    z-index: 1001;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: opacity 0.8s ease-in-out;
}
#preloader.loaded {
    opacity: 0;
    pointer-events: none;
}
.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(88, 166, 255, 0.2);
    border-top-color: var(--accent-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}
#preloader p {
    color: var(--secondary-color);
    font-size: 0.9rem;
    letter-spacing: 1px;
    text-transform: lowercase;
}
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}


/* --- Główny Canvas --- */
#main-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
}

/* --- Klasy pomocnicze --- */
.hidden { display: none; }
#page-content { 
    opacity: 0; 
    transition: opacity 0.8s ease-in 0.5s; /* Opóźnione pojawienie się */
    position: relative;
    z-index: 10;
}
#page-content.visible { 
    opacity: 1; 
}

/* --- Niestandardowy kursor --- */
.custom-cursor-dot, .custom-cursor-outline { position: fixed; top: 0; left: 0; pointer-events: none; z-index: 9999; border-radius: 50%; }
.custom-cursor-dot { width: 8px; height: 8px; background-color: var(--accent-color); transform: translate(-50%, -50%); }
.custom-cursor-outline { width: 40px; height: 40px; border: 2px solid var(--accent-color); transform: translate(-50%, -50%); transition: width 0.3s ease, height 0.3s ease, border 0.3s ease, transform 0.1s ease-out; }
.custom-cursor-outline.hover { width: 60px; height: 60px; border: 2px solid var(--primary-color); background-color: rgba(88, 166, 255, 0.1); }

/* --- Kursor-światło --- */
.cursor-light { position: fixed; top: 0; left: 0; width: 400px; height: 400px; background: radial-gradient(circle, rgba(88, 166, 255, 0.15) 0%, rgba(88, 166, 255, 0) 70%); border-radius: 50%; transform: translate(-50%, -50%); pointer-events: none; z-index: -1; }

/* --- Kontener i typografia --- */
.content-wrapper { max-width: 900px; margin: 0 auto; padding: 0 2rem; }
h2 { font-size: 1.5rem; margin-bottom: 2rem; color: var(--accent-color); letter-spacing: 1px; }

/* --- Układ sekcji --- */
.hero-section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    position: relative;
}
.hero-text-container {
    opacity: 1; /* Widoczny od razu (JS zarządza widocznością całej strony) */
}
.hero-text-container h1 { font-size: clamp(3rem, 10vw, 5rem); letter-spacing: -2px; }
.hero-text-container p { font-size: 1.5rem; color: var(--secondary-color); margin-top: 0.5rem; }
.hero-section nav { margin-top: 2rem; font-size: 1.1rem; }
.hero-section nav a { color: var(--secondary-color); margin: 0 1rem; transition: color 0.3s ease; }
.hero-section nav a:hover { color: var(--primary-color); }
.hero-section nav span { color: var(--border-color); }

/* --- Reszta stylów bez zmian --- */
.content-section { padding: 6rem 0; }
.card { background: var(--card-bg); border: 1px solid var(--border-color); padding: 2rem; border-radius: 12px; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.reveal { opacity: 0; transform: translateY(30px); transition: opacity 0.8s ease-out, transform 0.8s ease-out; }
.reveal.visible { opacity: 1; transform: translateY(0); }
.projects-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5rem; }
.project-card { background: var(--card-bg); border: 1px solid var(--border-color); padding: 1.5rem; border-radius: 12px; text-decoration: none; display: flex; flex-direction: column; justify-content: space-between; transition: transform 0.3s ease, border-color 0.3s ease; }
.project-card:hover { transform: translateY(-5px); border-color: var(--accent-color); }
.project-card h3 { color: var(--primary-color); font-size: 1.25rem; margin-bottom: 0.5rem; }
.project-card p { color: var(--secondary-color); font-size: 1rem; flex-grow: 1; }
.project-tags { margin-top: 1.5rem; }
.project-tags span { background-color: rgba(88, 166, 255, 0.1); color: var(--accent-color); padding: 0.25rem 0.75rem; border-radius: 16px; font-size: 0.8rem; margin-right: 0.5rem; font-weight: 500; }
.email-link { display: inline-block; margin-top: 1rem; font-size: 1.5rem; font-weight: 600; color: var(--accent-color); }
.social-links { margin-top: 2rem; display: flex; gap: 1.5rem; justify-content: center; }
.social-links a { color: var(--secondary-color); }
.social-links a:hover { color: var(--primary-color); }
footer { text-align: center; padding: 2rem 0; color: var(--secondary-color); font-size: 0.9rem; border-top: 1px solid var(--border-color); margin-top: 4rem; }
