/* ============================================
   kovarik.eu — Personal Developer Portfolio
   Dark Theme CSS
   ============================================ */

:root {
    --bg-primary: #0f0f1a;
    --bg-secondary: #161625;
    --bg-darker: #0a0a14;
    --bg-card: #1a1a2e;
    --accent: #00d4ff;
    --accent-secondary: #7c3aed;
    --accent-gradient: linear-gradient(135deg, #00d4ff, #7c3aed);
    --text-primary: #e4e4e7;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;
    --border-color: rgba(255, 255, 255, 0.06);
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
}

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

/* ---- Scrollbar ---- */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-darker); }
::-webkit-scrollbar-thumb { background: var(--accent-secondary); border-radius: 4px; }

/* ============================================
   NAVBAR
   ============================================ */
#mainNav {
    background: rgba(15, 15, 26, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    transition: all 0.3s ease;
    padding: 0.75rem 0;
}

#mainNav.scrolled {
    background: rgba(15, 15, 26, 0.95);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

#mainNav .navbar-brand {
    font-family: var(--font-mono);
    color: var(--accent) !important;
    font-size: 1.15rem;
    letter-spacing: -0.02em;
}

#mainNav .nav-link {
    color: var(--text-secondary) !important;
    font-weight: 500;
    font-size: 0.9rem;
    letter-spacing: 0.02em;
    padding: 0.5rem 1rem !important;
    transition: color 0.3s ease;
    position: relative;
}

#mainNav .nav-link:hover,
#mainNav .nav-link.active {
    color: var(--accent) !important;
}

#mainNav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--accent-gradient);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

#mainNav .nav-link:hover::after,
#mainNav .nav-link.active::after {
    width: 60%;
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    background: var(--bg-primary);
}

#particleCanvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.hero-section > .container {
    position: relative;
    z-index: 1;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.08), transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.hero-section::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -15%;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(124, 58, 237, 0.06), transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.hero-label {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--accent);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.hero-name {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 0.5rem;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-title {
    font-size: clamp(1.1rem, 2.5vw, 1.5rem);
    font-weight: 300;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.hero-description {
    font-size: 1.05rem;
    color: var(--text-secondary);
    max-width: 550px;
    margin-bottom: 2rem;
    line-height: 1.8;
}

.hero-code-block {
    font-family: var(--font-mono);
    font-size: 0.82rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.5rem;
    line-height: 1.8;
    max-width: 480px;
    position: relative;
    overflow: hidden;
}

.hero-code-block::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--accent-gradient);
}

.hero-code-block .code-dots {
    display: flex;
    gap: 6px;
    margin-bottom: 1rem;
}

.hero-code-block .code-dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.hero-code-block .code-dots span:nth-child(1) { background: #ff5f57; }
.hero-code-block .code-dots span:nth-child(2) { background: #febc2e; }
.hero-code-block .code-dots span:nth-child(3) { background: #28c840; }

.code-keyword { color: #c792ea; }
.code-type { color: #82aaff; }
.code-string { color: #c3e88d; }
.code-comment { color: #546e7a; font-style: italic; }
.code-property { color: #f78c6c; }
.code-bracket { color: #89ddff; }

/* ============================================
   BUTTONS
   ============================================ */
.btn-accent {
    background: var(--accent-gradient);
    color: var(--bg-primary) !important;
    font-weight: 600;
    border: none;
    padding: 0.7rem 2rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    letter-spacing: 0.02em;
}

.btn-accent:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 212, 255, 0.25);
    color: var(--bg-primary) !important;
}

.btn-outline-accent {
    border: 1px solid var(--accent);
    color: var(--accent) !important;
    font-weight: 500;
    padding: 0.7rem 2rem;
    border-radius: 8px;
    background: transparent;
    transition: all 0.3s ease;
}

.btn-outline-accent:hover {
    background: rgba(0, 212, 255, 0.1);
    transform: translateY(-2px);
    color: var(--accent) !important;
}

/* ============================================
   SECTION STYLES
   ============================================ */
section {
    padding: 6rem 0;
}

.section-alt {
    background-color: var(--bg-secondary);
}

.section-label {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--accent);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 0.75rem;
    display: block;
}

.section-title {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.section-subtitle {
    font-size: 1.05rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin-bottom: 3rem;
}

.section-divider {
    width: 60px;
    height: 3px;
    background: var(--accent-gradient);
    border: none;
    margin-bottom: 2rem;
    border-radius: 2px;
}

/* ============================================
   ABOUT SECTION
   ============================================ */
.about-text p {
    color: var(--text-secondary);
    font-size: 1.05rem;
    margin-bottom: 1rem;
}

.about-highlights {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.highlight-item {
    text-align: center;
    padding: 1.5rem 1rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.highlight-item:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
}

.highlight-number {
    font-size: 2rem;
    font-weight: 700;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: block;
    margin-bottom: 0.25rem;
}

.highlight-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ============================================
   SKILLS / TECH SECTION
   ============================================ */
.skill-category {
    margin-bottom: 2.5rem;
}

.skill-category-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.skill-category-title i {
    color: var(--accent);
    width: 20px;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.skill-tag {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    padding: 0.45rem 1rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-secondary);
    transition: all 0.3s ease;
    cursor: default;
}

.skill-tag:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(0, 212, 255, 0.05);
}

/* ============================================
   EXPERIENCE / TIMELINE
   ============================================ */
.timeline {
    position: relative;
    padding-left: 2rem;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, var(--accent), var(--accent-secondary), transparent);
}

.timeline-item {
    position: relative;
    padding-bottom: 3rem;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -2rem;
    top: 6px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent);
    border: 3px solid var(--bg-primary);
    transform: translateX(-5px);
}

.timeline-period {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--accent);
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}

.timeline-role {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.timeline-company {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.timeline-desc {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.7;
}

/* ============================================
   PROJECTS
   ============================================ */
.project-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    height: 100%;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--accent-gradient);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.project-card:hover {
    border-color: rgba(0, 212, 255, 0.2);
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.project-card:hover::before {
    transform: scaleX(1);
}

.project-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: rgba(0, 212, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.25rem;
    font-size: 1.3rem;
    color: var(--accent);
}

.project-card h4 {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.project-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.project-tech span {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    padding: 0.2rem 0.6rem;
    background: rgba(0, 212, 255, 0.08);
    border-radius: 4px;
    color: var(--accent);
}

/* ============================================
   CONTACT
   ============================================ */
.contact-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
}

.contact-card:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
}

.contact-card i {
    font-size: 2rem;
    margin-bottom: 1rem;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.contact-card h5 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.contact-card a,
.contact-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    text-decoration: none;
    transition: color 0.3s ease;
}

.contact-card a:hover {
    color: var(--accent);
}

/* ============================================
   ANIMATIONS
   ============================================ */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

.fade-in-delay-1 { transition-delay: 0.1s; }
.fade-in-delay-2 { transition-delay: 0.2s; }
.fade-in-delay-3 { transition-delay: 0.3s; }
.fade-in-delay-4 { transition-delay: 0.4s; }

/* ============================================
   TYPING CURSOR
   ============================================ */
.typing-cursor::after {
    content: '|';
    animation: blink 1s step-end infinite;
    color: var(--accent);
    font-weight: 300;
}

@keyframes blink {
    50% { opacity: 0; }
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    section {
        padding: 4rem 0;
    }

    .hero-code-block {
        margin-top: 2rem;
    }

    .about-highlights {
        grid-template-columns: repeat(2, 1fr);
    }

    .timeline {
        padding-left: 1.5rem;
    }
}

@media (max-width: 576px) {
    html {
        font-size: 14px;
    }

    .about-highlights {
        grid-template-columns: 1fr 1fr;
    }
}

/* ============================================
   SCROLL PROGRESS INDICATOR
   ============================================ */
#scrollProgress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: var(--accent-gradient);
    z-index: 9999;
    transition: width 0.1s linear;
    box-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}