/* Grundlegende Variablen & Reset */
:root {
    --bg-color: #0f172a;
    --card-bg: #1e293b;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --accent: #38bdf8; /* Ein helles Blau */
    --font-main: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-main);
    line-height: 1.6;
    scroll-behavior: smooth;
}

#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--accent), #667eea);
    z-index: 10001;
    transition: width 0.1s ease;
    box-shadow: 0 0 10px var(--accent);
}

a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }

/* Utility Classes */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 4rem 2rem;
}

h2 {
    font-size: 2rem;
    margin-bottom: 2rem;
    text-align: center;
    border-bottom: 2px solid var(--accent);
    display: inline-block;
    padding-bottom: 0.5rem;
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    position: sticky;
    top: 0;
    background-color: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(5px);
    z-index: 1000;
}

.logo { 
    font-size: 1.5rem; 
    font-weight: bold; 
    color: var(--accent);
    cursor: pointer;
    transition: all 0.3s ease;
    user-select: none;
}

.logo:hover {
    transform: scale(1.1);
    text-shadow: 0 0 20px var(--accent);
}

.nav-links { display: flex; gap: 2rem; }
.nav-links a:hover { color: var(--accent); }

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    transition: color 0.3s;
}

.mobile-menu-toggle:hover {
    color: var(--accent);
}

/* Hero Section */
.hero {
    height: 80vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 1rem;
}

.hero h1 { font-size: 3.5rem; margin-bottom: 1rem; }
.highlight { color: var(--accent); }

.gradient-text {
    background: linear-gradient(90deg, #38bdf8, #667eea, #f472b6, #38bdf8);
    background-size: 300% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 5s ease infinite;
}

@keyframes gradient-shift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.hero p { font-size: 1.25rem; color: var(--text-secondary); margin-bottom: 2rem; min-height: 2rem; }

#typed-text { color: var(--text-primary); }

.cursor {
    color: var(--accent);
    animation: blink 0.7s infinite;
    font-weight: 100;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    background: var(--accent);
    color: var(--bg-color);
    font-weight: bold;
    border-radius: 5px;
}
.btn:hover { opacity: 0.9; transform: translateY(-2px); }

.btn-outline {
    background: transparent;
    border: 2px solid var(--accent);
    color: var(--accent);
}
.btn-outline:hover { background: var(--accent); color: var(--bg-color); }

/* About Section */
.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.about-text p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-secondary);
}

.about-text p:last-child {
    margin-bottom: 0;
}

/* Skills Grid */
.skills-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
}

.skill-card {
    background: var(--card-bg);
    padding: 1rem 2rem;
    border-radius: 8px;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    animation: float 3s ease-in-out infinite;
}

.skill-card:nth-child(1) { animation-delay: 0s; }
.skill-card:nth-child(2) { animation-delay: 0.2s; }
.skill-card:nth-child(3) { animation-delay: 0.4s; }
.skill-card:nth-child(4) { animation-delay: 0.6s; }
.skill-card:nth-child(5) { animation-delay: 0.8s; }

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.skill-card i {
    font-size: 1.6rem;
}

.skill-card:hover {
    border-color: var(--accent);
    box-shadow: 0 10px 30px rgba(56, 189, 248, 0.4);
    transition: all 0.1s ease;
}

/* Projects Grid */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.project-card {
    background: var(--card-bg);
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.1s ease;
    transform-style: preserve-3d;
}

.project-card:hover {
    box-shadow: 0 15px 40px rgba(56, 189, 248, 0.3);
}

.project-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.project-info { padding: 1.5rem; }
.project-info h3 { margin-bottom: 0.5rem; color: var(--accent); }
.project-info p { color: var(--text-secondary); margin-bottom: 1rem; font-size: 0.9rem; }

.project-links { display: flex; gap: 1rem; }
.project-links a { color: var(--text-primary); font-size: 0.9rem; }
.project-links a:hover { color: var(--accent); }

/* Footer */
footer {
    text-align: center;
    padding: 4rem 1rem;
    background: var(--card-bg);
}

.socials {
    margin: 2rem 0;
    font-size: 1.5rem;
}
.socials a { margin: 0 1rem; }
.copyright { color: var(--text-secondary); font-size: 0.8rem; }

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeInUp 0.6s ease-out forwards;
}

.skill-card, .project-card, .about-content {
    opacity: 0;
}

/* Cursor Trail */
#cursor-trail {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
}

.trail-particle {
    position: absolute;
    width: 8px;
    height: 8px;
    background: var(--accent);
    border-radius: 50%;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.5s ease;
    box-shadow: 0 0 10px var(--accent);
    animation: fadeOut 0.8s ease-out forwards;
}

@keyframes fadeOut {
    0% {
        opacity: 0.8;
        transform: scale(1);
    }
    100% {
        opacity: 0;
        transform: scale(0.3);
    }
}

/* Easter Egg */
.party-mode {
    animation: rainbow-bg 2s linear infinite;
}

@keyframes rainbow-bg {
    0% { filter: hue-rotate(0deg); }
    100% { filter: hue-rotate(360deg); }
}

.easter-egg-message {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 3rem 4rem;
    border-radius: 20px;
    font-size: 1.5rem;
    font-weight: bold;
    text-align: center;
    z-index: 10000;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: bounceIn 0.6s ease-out;
}

@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.3);
    }
    50% {
        transform: translate(-50%, -50%) scale(1.05);
    }
    100% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

/* Toast Notifications */
.toast-notification {
    position: fixed;
    top: 100px;
    right: 20px;
    background: linear-gradient(135deg, var(--accent), #667eea);
    color: white;
    padding: 1rem 2rem;
    border-radius: 10px;
    font-weight: bold;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    z-index: 10000;
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.3s ease;
}

.toast-notification.show {
    opacity: 1;
    transform: translateX(0);
}

/* Developer Console */
.dev-console {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 500px;
    max-width: 90vw;
    height: 400px;
    background: var(--card-bg);
    border: 2px solid var(--accent);
    border-radius: 10px;
    box-shadow: 0 10px 50px rgba(0, 0, 0, 0.5);
    z-index: 10000;
    display: flex;
    flex-direction: column;
    font-family: 'Courier New', monospace;
    transition: all 0.3s ease;
}

.dev-console.hidden {
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
}

.console-header {
    background: var(--accent);
    color: var(--bg-color);
    padding: 0.75rem 1rem;
    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 8px 8px 0 0;
}

#console-close {
    background: none;
    border: none;
    color: var(--bg-color);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
}

.console-output {
    flex: 1;
    padding: 1rem;
    overflow-y: auto;
    font-size: 0.9rem;
}

.console-line {
    margin: 0.5rem 0;
    color: var(--text-secondary);
}

.console-line.input {
    color: var(--accent);
}

.console-line.success {
    color: #4ade80;
}

.console-line.error {
    color: #f87171;
}

.console-input-wrapper {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    border-top: 1px solid var(--accent);
    background: rgba(56, 189, 248, 0.1);
}

.console-prompt {
    color: var(--accent);
    margin-right: 0.5rem;
    font-weight: bold;
}

.console-input {
    flex: 1;
    background: none;
    border: none;
    color: var(--text-primary);
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    outline: none;
}

/* Matrix Mode */
.matrix-mode {
    background: #000;
    color: #0f0;
}

.matrix-mode .navbar,
.matrix-mode .card-bg,
.matrix-mode .skill-card,
.matrix-mode .project-card {
    background: #001a00;
    border-color: #0f0;
}

.matrix-mode .highlight,
.matrix-mode .accent {
    color: #0f0 !important;
}

/* Responsive Design für Handys */
@media (max-width: 768px) {
    .hero h1 { font-size: 2.5rem; }
    
    .mobile-menu-toggle { display: block; }
    
    .nav-links {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: var(--card-bg);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.5);
        padding: 2rem 0;
        gap: 0;
    }
    
    .nav-links.active {
        left: 0;
    }
    
    .nav-links li {
        padding: 1rem 0;
    }
    
    .container {
        padding: 3rem 1.5rem;
    }
    
    h2 {
        font-size: 1.75rem;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .about-text p {
        font-size: 1rem;
    }
}