﻿/* --- KONFIGURACJA ZMIENNYCH --- */
:root {
    --bg-color: #050505;
    --text-color: #f0f0f0;
    --accent-color: #00f2ff;
    --accent-glow: rgba(0, 242, 255, 0.3);
    --glass-bg: rgba(15, 15, 15, 0.6); 
    --glass-border: rgba(255, 255, 255, 0.12);
    --transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* --- RESET I PODSTAWY --- */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { 
    background-color: var(--bg-color); 
    color: var(--text-color); 
    font-family: 'Space Grotesk', sans-serif; 
    overflow-x: hidden; 
}

/* --- TŁO I GRAIN --- */
#bg-canvas { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: -2; pointer-events: none; }
.wow-bg { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: -3; background: #050505; }
.grain { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-image: url('https://grainy-gradients.vercel.app/noise.svg'); opacity: 0.04; pointer-events: none; z-index: 2; }

/* --- SZKLANE MENU (Z EFEKTEM DYNAMICZNYCH ROGÓW) --- */
nav { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    padding: 0.8rem 2rem; 
    position: sticky; 
    top: -1px; /* Próg aktywacji dla skryptu */
    margin: 30px auto 0 auto;
    width: 90%; 
    max-width: 1100px; 
    z-index: 1000; 
    background: rgba(15, 15, 15, 0.7);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    transition: border-radius 0.3s ease, width 0.3s ease, margin-top 0.3s ease, max-width 0.3s ease;
}

/* Stan po przyklejeniu (aktywowany przez JS) */
nav.is-pinned {
    margin-top: 0;
    width: 100%;
    max-width: 100%;
    border-radius: 0 0 20px 20px; /* Górne rogi stają się proste */
    border-left: none;
    border-right: none;
    border-top: none;
}

.logo { font-weight: 700; font-size: 1.3rem; letter-spacing: 2px; }
.highlight { color: var(--accent-color); text-shadow: 0 0 10px var(--accent-glow); }
nav ul { display: flex; list-style: none; gap: 2rem; }
nav a { color: var(--text-color); text-decoration: none; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 1px; transition: var(--transition); opacity: 0.8; }
nav a:hover { color: var(--accent-color); opacity: 1; }

/* --- HERO SECTION --- */
.hero { 
    height: 100vh; margin-top: -80px; width: 100%;
    display: flex; align-items: center; justify-content: center; 
    position: relative; z-index: 10;
}
.hero .content { 
    width: 90%; max-width: 900px; padding: 5rem 3rem; text-align: center; 
    background: var(--glass-bg); backdrop-filter: blur(25px); 
    -webkit-backdrop-filter: blur(25px); border: 1px solid var(--glass-border); 
    border-radius: 40px; box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6);
    display: flex; flex-direction: column; justify-content: center; align-items: center;
}
.hero h1 { font-size: clamp(1.8rem, 5vw, 3.2rem); line-height: 1.2; margin-bottom: 2rem; min-height: 2.4em; }
.typewriter-text { color: var(--accent-color); text-shadow: 0 0 15px var(--accent-glow); }
.cursor { display: inline-block; width: 3px; background-color: var(--accent-color); margin-left: 8px; animation: blink 1s infinite; }
@keyframes blink { 50% { opacity: 0; } }
.hero p { font-size: clamp(1rem, 2vw, 1.1rem); opacity: 0.7; margin-bottom: 3rem; max-width: 650px; }

/* --- PRZYCISKI --- */
.buttons { display: flex; gap: 1.5rem; justify-content: center; }
.cta-btn { padding: 1rem 2.5rem; border-radius: 50px; cursor: pointer; font-weight: 600; text-decoration: none; transition: var(--transition); text-transform: uppercase; font-size: 0.85rem; position: relative; overflow: hidden; border: none; }
.primary { background: var(--accent-color); color: #000 !important; }
.secondary { background: transparent; border: 1px solid var(--accent-color); color: var(--accent-color); }

/* --- KARTY Z PŁYNEM (START 50% -> HOVER 90%) --- */
.container { max-width: 1200px; margin: 0 auto; padding: 120px 20px; }
.section-title { text-align: center; font-size: clamp(2.2rem, 4vw, 2.8rem); margin-bottom: 5rem; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 2.5rem; }

.tech-card { 
    display: flex; flex-direction: column; align-items: center; justify-content: center; 
    text-align: center; padding: 3.5rem 2rem; min-height: 380px; border-radius: 24px;
    background: rgba(255, 255, 255, 0.03); border: 1px solid var(--glass-border);
    position: relative; overflow: hidden; z-index: 1; transition: var(--transition);
}
.tech-card::before {
    content: ""; position: absolute; left: -50%; width: 200%; height: 200%;
    background: rgba(0, 242, 255, 0.15); border-radius: 43%; z-index: -1;
    animation: rotateLiquid 12s linear infinite; top: 50%;
    transition: top 1s cubic-bezier(0.4, 0, 0.2, 1);
}
.tech-card::after {
    content: ""; position: absolute; left: -45%; width: 200%; height: 200%;
    background: rgba(0, 242, 255, 0.08); border-radius: 40%; z-index: -1;
    animation: rotateLiquid 18s linear infinite reverse; top: 52%; 
    transition: top 1.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.tech-card:hover::before { top: -10%; }
.tech-card:hover::after { top: -8%; }
@keyframes rotateLiquid { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

.tech-card:hover { transform: translateY(-10px); border-color: var(--accent-color); box-shadow: 0 20px 40px var(--accent-glow); }
.tech-tag { margin-bottom: 1.5rem; background: rgba(0, 242, 255, 0.1); color: var(--accent-color); padding: 4px 12px; border-radius: 4px; font-size: 0.75rem; text-transform: uppercase; border: 1px solid var(--accent-glow); position: relative; z-index: 2; }
.icon { font-size: 3.2rem; margin-bottom: 1.5rem; color: var(--accent-color); position: relative; z-index: 2; }
.tech-card h3 { margin-bottom: 1rem; font-size: 1.7rem; color: #fff; position: relative; z-index: 2; }
.tech-card p { opacity: 0.85; font-size: 1rem; position: relative; z-index: 2; }

/* --- KONTAKT --- */
.contact-wrapper { max-width: 750px; margin: 0 auto; padding: 6rem 2rem; }
.contact-form { display: flex; flex-direction: column; gap: 1.5rem; align-items: center; }
.input-group { width: 100%; }
.input-group input, .input-group textarea { width: 100%; padding: 1.2rem; background: rgba(255, 255, 255, 0.04); border: 1px solid var(--glass-border); border-radius: 15px; color: #fff; font-family: inherit; }

/* --- STOPKA --- */
footer { text-align: center; padding: 80px 20px; opacity: 0.5; }

@media (max-width: 768px) {
    nav { width: 95%; padding: 0.8rem 1rem; margin-top: 10px; border-radius: 15px !important; }
    nav ul { display: none; }
    .hero { margin-top: -50px; }
}