/* Font Definitions */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 300;
    font-display: swap;
    src: url('./fonts/inter-v19-latin-300.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('./fonts/inter-v19-latin-regular.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('./fonts/inter-v19-latin-500.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('./fonts/inter-v19-latin-600.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('./fonts/inter-v19-latin-700.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* Variables & Reset */
:root {
    --primary: #3b82f6;
    --primary-dark: #2563eb;
    --primary-light: #60a5fa;
    --secondary: #64748b;
    --accent: #8b5cf6;
    
    --bg-body: #ffffff;
    --bg-alt: #f8fafc;
    --bg-card: #ffffff;
    
    --text-main: #0f172a;
    --text-muted: #475569;
    --text-light: #94a3b8;
    
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.24);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-dreamy: 0 20px 40px -10px rgba(59, 130, 246, 0.15);
    
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    
    --gradient-primary: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
    --gradient-glow: linear-gradient(135deg, #60a5fa 0%, #c084fc 50%, #f472b6 100%);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-main);
    background-color: var(--bg-body);
    -webkit-font-smoothing: antialiased;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 1px 0 rgba(0,0,0,0.05);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.nav-logo h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-main);
    letter-spacing: -0.025em;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-logo a {
    text-decoration: none;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2.5rem;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.2s ease;
    position: relative;
    padding: 0.5rem 0;
}

.nav-menu a:hover, .nav-menu a.active {
    color: var(--primary);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 6px;
}

.hamburger span {
    width: 24px;
    height: 2px;
    background: var(--text-main);
    transition: 0.3s;
    border-radius: 2px;
}

/* Hero Section */
.hero {
    padding: 180px 0 120px;
    background: radial-gradient(circle at top right, rgba(59, 130, 246, 0.05), transparent 40%),
                radial-gradient(circle at bottom left, rgba(139, 92, 246, 0.05), transparent 40%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-content {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
}

.hero-text h1 {
    font-size: 4rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: var(--text-main);
    letter-spacing: -0.02em;
}

.hero-text h2 {
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--secondary);
    margin-bottom: 2rem;
}

.hero-text p {
    font-size: 1.125rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    line-height: 1.75;
    max-width: 540px;
}

.highlight {
    background: var(--gradient-glow);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientMove 4s ease infinite;
    display: inline-block;
}

@keyframes gradientMove {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn {
    padding: 14px 28px;
    border-radius: var(--radius-sm);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid transparent;
    cursor: pointer;
    font-size: 1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.2);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(59, 130, 246, 0.3);
}

.btn-secondary {
    background: white;
    color: var(--text-main);
    border: 1px solid #e2e8f0;
}

.btn-secondary:hover {
    border-color: var(--primary);
    color: var(--primary);
    transform: translateY(-2px);
    background: #f8fafc;
}

.hero-image {
    display: flex;
    justify-content: center;
    position: relative;
    height: 100%; /* Ensure full height for sticky to work */
    align-items: flex-start; /* Better for sticky positioning */
}

.profile-placeholder {
    width: 320px;
    height: 320px;
    border-radius: 40px;
    background: var(--gradient-primary);
    background-image: url('./pictures/6324208a-337a-4968-b78a-162bc868b3a5.webp');
    background-size: cover;
    background-position: center;
    box-shadow: 0 25px 50px -12px rgba(59, 130, 246, 0.25);
    transform: rotate(-3deg);
    transition: transform 0.4s ease;
    border: 8px solid white;
}

.hero-image:hover .profile-placeholder {
    transform: rotate(0deg) scale(1.02);
}

/* Section Styles */
.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 4rem;
    color: var(--text-main);
    letter-spacing: -0.02em;
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--primary);
    margin: 1rem auto 0;
    border-radius: 2px;
}

/* About Section */
.about {
    padding: 120px 0;
    background: #fff;
}

.about-content {
    max-width: 900px;
    margin: 0 auto;
}

.about-text p {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 4rem;
    text-align: center;
    line-height: 1.8;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2.5rem;
}

.skill-category {
    padding: 2.5rem;
    background: #fff;
    border-radius: var(--radius-md);
    border: 1px solid #f1f5f9;
    box-shadow: var(--shadow-lg);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.skill-category:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
    border-color: #e2e8f0;
}

.skill-category h4 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--text-main);
}

.skill-category ul {
    list-style: none;
}

.skill-category li {
    padding: 0.75rem 0;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 12px;
}

.skill-category li::before {
    content: '';
    width: 20px;
    height: 20px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%233b82f6' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'%3E%3C/polyline%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
}

/* Services Section */
.services {
    padding: 120px 0;
    background: var(--bg-alt);
}

.services-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
}

.service-card {
    background: white;
    padding: 3rem 2.5rem;
    border-radius: var(--radius-lg);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid rgba(255,255,255,0.1);
    box-shadow: var(--shadow-sm);
    position: relative;
    overflow: hidden;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-dreamy);
}

.service-icon {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    background: #eff6ff;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 20px;
    transition: 0.3s;
}

.service-card:hover .service-icon {
    background: var(--primary);
    color: white;
    transform: rotate(6deg);
}

.service-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.service-card p {
    color: var(--text-muted);
    line-height: 1.6;
}

/* Projects Section */
.page-header {
    padding: 160px 0 80px;
    background: var(--bg-alt);
    text-align: center;
}

.page-title {
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 1.5rem;
    letter-spacing: -0.03em;
}

.page-description {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 650px;
    margin: 0 auto;
    line-height: 1.6;
}

.projects-showcase {
    padding: 80px 0 120px;
}

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

.project-card {
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all 0.4s ease;
    border: 1px solid #f1f5f9;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.project-image {
    height: 240px;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.project-card:hover .project-image::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, transparent 0%, rgba(0,0,0,0.1) 100%);
}

.project-placeholder {
    font-size: 5rem;
    color: rgba(255,255,255,0.9);
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.2));
    transition: transform 0.4s ease;
}

.project-card:hover .project-placeholder {
    transform: scale(1.1);
}

.project-content {
    padding: 2.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.project-badge {
    align-self: flex-start;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.3);
}

.project-content h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 1rem;
    line-height: 1.3;
}

.project-content p {
    color: var(--text-muted);
    margin-bottom: 2rem;
    line-height: 1.6;
    flex-grow: 1;
}

.tech-stack {
    margin-bottom: 2rem;
}

.tech-stack h4 {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
}

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

.tech-tag {
    padding: 0.4rem 0.9rem;
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 600;
    border: 1px solid transparent;
}

/* Tag variations */
.tech-tag.frontend {
    background: #dbeafe;
    color: #1e40af;
}
.tech-tag.backend {
    background: #dcfce7;
    color: #166534;
}
.tech-tag.database {
    background: #fef3c7;
    color: #92400e;
}
.tech-tag.styling {
    background: #fce7f3;
    color: #be185d;
}
.tech-tag.other, .tech-tag.security {
    background: #f1f5f9;
    color: #475569;
}

.project-features {
    margin-bottom: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #f1f5f9;
}

.project-features ul {
    list-style: none;
}

.project-features li {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.project-features li::before {
    content: '';
    width: 6px;
    height: 6px;
    background: var(--primary);
    border-radius: 50%;
}

.project-link .btn {
    width: 100%;
}

/* Contact */
.contact {
    padding: 120px 0;
    background: var(--bg-alt);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
}

.contact-info h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.contact-form {
    background: white;
    padding: 3rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 16px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #f8fafc;
}

.form-group input:focus,
.form-group textarea:focus {
    background: white;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
    outline: none;
}

/* Footer */
.footer {
    background: #0f172a;
    padding: 4rem 0 2rem;
    color: #94a3b8;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 2rem;
    border-bottom: 1px solid #1e293b;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 2rem;
}

.footer p {
    font-size: 0.95rem;
}

.footer a {
    color: #94a3b8;
    text-decoration: none;
    transition: color 0.2s;
}

.footer a:hover {
    color: white;
}

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

.service-card,
.project-card,
.skill-category {
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.service-card:nth-child(2) { animation-delay: 0.1s; }
.service-card:nth-child(3) { animation-delay: 0.2s; }
.service-card:nth-child(4) { animation-delay: 0.3s; }

/* Responsive */
@media (max-width: 900px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-text p {
        margin: 0 auto 2.5rem;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .hamburger { display: flex; }
    
    .nav-menu {
        position: fixed;
        top: 80px;
        left: 0;
        width: 100%;
        background: white;
        flex-direction: column;
        padding: 2rem;
        gap: 1rem;
        border-bottom: 1px solid #e2e8f0;
        transform: translateY(-150%);
        transition: transform 0.3s ease;
        z-index: 999;
    }
    
    .nav-menu.active {
        transform: translateY(0);
        box-shadow: var(--shadow-lg);
    }
    
    .hero-text h1 { font-size: 2.75rem; }
    
    .section-title { font-size: 2rem; }

    .page-title {
        font-size: 2rem;
        word-break: break-word;
        hyphens: auto;
    }
}

@media (max-width: 480px) {
    .container { padding: 0 20px; }
    
    .hero { padding: 140px 0 80px; }
    
    .hero { padding: 140px 0 80px; }
    
    .hero-text h1 { font-size: 2.25rem; }

    .page-title { font-size: 1.75rem; }
    
    .btn { width: 100%; }
    
    .service-card { padding: 2rem; }
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    border: none;
    font-size: 20px;
    cursor: pointer;
    opacity: 0;
    transform: translateY(20px) scale(0.8);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 100;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
}

.back-to-top.visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.back-to-top:hover {
    background: var(--primary-dark);
    transform: translateY(-4px) scale(1.1);
    box-shadow: 0 8px 24px rgba(59, 130, 246, 0.4);
}


/* Proper styling for Legal Pages (Impressum/Datenschutz) */
.impressum-content {
    padding: 80px 0;
    background: var(--bg-alt);
}

.impressum-section {
    background: white;
    padding: 2.5rem;
    margin-bottom: 2rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    border: 1px solid #e2e8f0;
}

.impressum-section h2 {
    font-size: 1.5rem;
    color: var(--text-main);
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #f1f5f9;
}

.impressum-section h3 {
    font-size: 1.2rem;
    color: var(--text-main);
    margin: 2rem 0 1rem;
}

.impressum-section p, .impressum-section ul {
    color: var(--text-muted);
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.impressum-section ul {
    padding-left: 1.5rem;
}

.contact-info {
    background: #f8fafc;
    padding: 1.5rem;
    border-radius: var(--radius-sm);
    border: 1px solid #e2e8f0;
}

.impressum-footer {
    text-align: center;
    color: var(--text-light);
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid #e2e8f0;
}

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: 30px;
    right: 30px;
    left: auto;
    transform: none;
    width: 400px;
    max-width: 90%;
    background: #ffffff;
    padding: 1.5rem 2rem;
    z-index: 9999;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    border-radius: var(--radius-lg);
    border: 1px solid #e2e8f0;
    animation: fadeInUp 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.cookie-content-wrapper {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
}

.cookie-text p {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin: 0;
}

.cookie-text a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
}

.cookie-buttons {
    display: flex;
    gap: 12px;
    width: 100%;
    justify-content: flex-end;
}

.btn-cookie {
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
}

.btn-cookie-accept {
    background: var(--primary);
    color: white;
}

.btn-cookie-accept:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.btn-cookie-decline {
    background: #f1f5f9;
    color: var(--text-muted);
}

.btn-cookie-decline:hover {
    background: #e2e8f0;
    color: var(--text-main);
}

@media (max-width: 640px) {
    .cookie-banner {
        bottom: 20px;
        width: 92%;
        padding: 1.5rem;
    }
    
    .cookie-content-wrapper {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.5rem;
    }
    
    .cookie-buttons {
        width: 100%;
        justify-content: flex-end;
    }
}

/* Button Loader */
.btn-loading {
    position: relative;
    color: transparent !important;
    pointer-events: none;
}

.btn-loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-top: -10px;
    margin-left: -10px;
    border: 2px solid white;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}
