/* Base Styles */
:root {
    --primary-color: #30D158;
    --accent-color: #30D158;
    --text-color: #333333;
    --heading-color: #30D158;
    --background-color: #ffffff;
    --card-bg: rgba(0, 0, 0, 0.05);
    --border-color: rgba(0, 0, 0, 0.1);
    --mobile-nav-background: rgba(255, 255, 255, 0.1);
    --mobile-nav-backdrop-filter: blur(10px);
    --mobile-menu-height: 0;
}

@media (prefers-color-scheme: dark) {
    :root {
        --primary-color: #30D158;
        --accent-color: #30D158;
        --text-color: #f0f0f0;
        --heading-color: #30D158;
        --background-color: #121212;
        --card-bg: rgba(255, 255, 255, 0.05);
        --border-color: rgba(255, 255, 255, 0.1);
    }
}

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

body {
    font-family: 'SF Pro Display', 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.no-scroll {
    overflow: hidden;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 0;
}

a {
    text-decoration: none;
    color: var(--text-color);
    transition: all 0.3s ease;
}

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

h1, h2, h3 {
    margin-bottom: 1rem;
    font-weight: 700;
}

h2 {
    text-align: center;
    margin-bottom: 2.5rem;
    color: var(--heading-color);
    display: inline-block;
}

/* Project section styling for better spacing in Impressum and similar pages */
.project-section {
    margin-bottom: 2.5rem;
}

.project-section h2 {
    margin-top: 3rem;
    margin-bottom: 1.5rem;
    text-align: left;
}

.project-section:first-child h2 {
    margin-top: 0;
}

.project-section p {
    margin-bottom: 1.5rem;
}

.project-section p:last-child {
    margin-bottom: 0;
}

/* Glassmorphism Effect */
.glassmorphism {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 15px;
    border: 1px solid var(--border-color);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.1);
}

/* @media (prefers-color-scheme: dark) {
    .glassmorphism, .nav-links.active {
        background: rgba(30, 30, 30, 0.7);
        box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    }
} */

/* Header and Navigation */
header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 1rem 0;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 2rem;
    margin: 0 auto;
    width: 90%;
    max-width: 1200px;
    transition: all 0.3s ease;
    position: relative;
    overflow: visible;
}

nav.expanded {
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.1);
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--heading-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.logo:hover {
    color: var(--accent-color);
}

.burger-menu {
    display: none;
    flex-direction: column;
    justify-content: center;
    width: 30px;
    height: 30px;
    cursor: pointer;
    z-index: 2;
    padding: 5px;
    position: relative;
}

.burger-menu span {
    display: block;
    width: 100%;
    height: 3px;
    background-color: var(--accent-color);
    border-radius: 10px;
    transition: all 0.3s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    position: absolute;
    left: 0;
}

.burger-menu span:nth-child(1) {
    top: 7px;
}

.burger-menu span:nth-child(2) {
    top: 50%;
    transform: translateY(-50%);
}

.burger-menu span:nth-child(3) {
    bottom: 7px;
}

.burger-menu.active span:nth-child(1) {
    top: 50%;
    transform: translateY(-50%) rotate(45deg);
}

.burger-menu.active span:nth-child(2) {
    opacity: 0;
}

.burger-menu.active span:nth-child(3) {
    top: 50%;
    transform: translateY(-50%) rotate(-45deg);
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 2rem;
}

.nav-links a {
    font-weight: 500;
    padding: 0.5rem 0;
    position: relative;
    display: block;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

@media (max-width: 768px) {
    /* Base container */
    nav.mobile-nav {
        overflow: hidden;
        max-height: 60px; /* collapsed height */
        transition: max-height 0.4s ease;
        /* Glassmorphism background */
        background: var(--mobile-nav-background);
        backdrop-filter: var(--mobile-nav-backdrop-filter);
        -webkit-backdrop-filter: var(--mobile-nav-backdrop-filter);
        border-radius: 15px;
        border: 1px solid var(--border-color);
        margin: 0.5rem auto;
        width: 95%;
        box-sizing: border-box;
    }

    nav.mobile-nav.expanded {
        overflow: visible;
        display: flex;
        flex-direction: column;
    }

    /* Header inside nav: logo and burger aligned */
    nav.mobile-nav .nav-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%; /* Ensure it spans the full width */
    }

    /* Always show burger on mobile */
    nav.mobile-nav .burger-menu {
        display: flex;
    }

    /* Links container flows under header */
    nav.mobile-nav .nav-links {
        display: none;
        flex-direction: column;
        list-style: none;
        margin: 0;
        padding: 0 1rem 0.5rem;
        gap: 0.5rem;
    }
    
    nav.mobile-nav .nav-links.active {
        display: flex;
    }

    nav.mobile-nav .nav-links li {
        width: 100%;
        text-align: center;
    }

    nav.mobile-nav .nav-links a {
        display: block;
        padding: 0.75rem 1rem;
        color: var(--text-color);
        font-weight: 600;
        border-radius: 10px;
        transition: background 0.3s ease, color 0.3s ease;
    }

    nav.mobile-nav .nav-links a:hover {
        color: var(--accent-color);
    }

    /* Expanded state shows links via increased max-height */
    nav.mobile-nav.expanded {
        max-height: max-content;
    }

    /* Dark mode adjustments for mobile nav */
    @media (prefers-color-scheme: dark) {
        nav.mobile-nav {
            background: rgba(30, 30, 30, 0.7);
            border: 1px solid rgba(255, 255, 255, 0.1);
        }
    }
}

/* Hero Section */
.hero {
    padding-top: 80px;
    padding-bottom: 2rem;
    display: flex;
    align-items: center;
    min-height: 100vh;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--accent-color);
    opacity: 0.05;
    z-index: -1;
}

.hero-content {
    display: flex;
    align-items: center;
    padding: 3.5rem;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    gap: 3rem;
}

.profile-image {
    flex-shrink: 0;
    border-radius: 12px;
    overflow: hidden;
    border: 4px solid var(--accent-color);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

.profile-image img {
    display: block;
    width: 250px;
    height: 250px;
    object-fit: cover;
}

.profile-text {
    flex: 1;
}

.profile-text h1 {
    font-size: 3rem;
    margin-bottom: 0.5rem;
    position: relative;
    display: inline-block;
}

.profile-text h1::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 80px;
    height: 4px;
    background-color: var(--accent-color);
}

.subtitle {
    font-size: 1.4rem;
    margin-bottom: 1.5rem;
    margin-top: 1rem;
    color: var(--accent-color);
}

.description {
    font-size: 1.1rem;
    line-height: 1.7;
    max-width: 600px;
    margin-bottom: 2rem;
}

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

.primary-button, .secondary-button {
    display: inline-block;
    padding: 0.8rem 1.8rem;
    border-radius: 30px;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.primary-button {
    background-color: var(--accent-color);
    color: white;
    border: 2px solid var(--accent-color);
}

.secondary-button {
    background-color: transparent;
    border: 2px solid var(--accent-color);
    color: var(--text-color);
}

.primary-button:hover, .secondary-button:hover {
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.primary-button:hover {
    background-color: transparent;
    color: var(--accent-color);
}

.secondary-button:hover {
    background-color: var(--accent-color);
    color: white;
}

/* Projects Section */
.projects {
    padding: 2rem 0;
}

.projects h2 {
    margin: 0 auto 2.5rem;
}

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

.project-card {
    overflow: hidden;
    padding-bottom: 1rem;
    transition: border-color 0.3s ease;
    position: relative;
    border-radius: 15px;
    border: 1px solid var(--border-color);
}

.project-card:hover {
    border-color: var(--accent-color);
}

.project-image {
    width: 100%;
    height: 250px;
    overflow: hidden;
    border-radius: 15px 15px 0 0;
    display: flex;
    justify-content: center;
    align-items: center;
    background: var(--card-bg);
}

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


.project-info {
    padding: 1.5rem;
}

.project-type {
    font-size: 0.9rem;
    color: var(--accent-color);
    margin-bottom: 0.5rem;
}

.project-description {
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.technologies {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.technologies span {
    background: rgba(48, 209, 88, 0.2);
    padding: 0.3rem 0.8rem;
    border-radius: 30px;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-color);
}

.show-more-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: var(--accent-color);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 30px;
    font-weight: 600;
    font-size: 0.9rem;
    height: 40px;
    box-sizing: border-box;
    transition: box-shadow 0.3s ease;
}

.show-more-btn:hover {
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    color: white;
}

.project-buttons {
    display: flex;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 0.5rem;
}

.app-store-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    transition: transform 0.2s ease;
}

.app-store-btn:hover {
    transform: scale(1.05);
}

.app-store-btn img {
    height: 40px;
    width: auto;
    display: block;
}

/* Experience Section */
.experience {
    padding: 2rem 0;
}

.experience h2 {
    margin: 0 auto 2.5rem;
}

.experience-content {
    padding: 2.5rem;
}

.experience-item {
    margin-bottom: 2.5rem;
}

.experience-item:last-child {
    margin-bottom: 0;
}

.experience-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.5rem;
}

.experience-header h3 {
    margin-bottom: 0.25rem;
    color: var(--heading-color);
}

.experience-date {
    font-size: 0.9rem;
    color: var(--accent-color);
}

.experience-location {
    font-size: 0.95rem;
    font-style: italic;
    margin-bottom: 0.75rem;
}

.experience-description {
    margin-bottom: 1rem;
}

.experience-highlights {
    list-style-position: inside;
    margin-left: 1rem;
}

.experience-highlights li {
    margin-bottom: 0.5rem;
}

.experience-highlights li::marker {
    color: var(--accent-color);
}

/* Contact Section */
.contact {
    padding: 2rem 0;
}

.contact-content {
    max-width: 600px;
    margin: 0 auto;
    padding: 2.5rem;
    text-align: center;
}

.contact-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-top: 2rem;
}

.contact-links a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    background: rgba(48, 209, 88, 0.2);
    border-radius: 30px;
    transition: all 0.3s ease;
    color: var(--text-color);
    font-weight: 500;
}

.contact-links a:hover {
    background-color: var(--accent-color);
    color: #ffffff !important;
}

.contact-links a i {
    font-size: 1.1rem;
}

@media (max-width: 768px) {
    /* Navigation */
    header {
        padding: 0.5rem 0;
    }
    
    nav {
        padding: 0.75rem 1.5rem;
        width: 95%;
        transition: height 0.3s ease;
    }
    
    .burger-menu {
        display: flex;
        position: relative;
        z-index: 10;
    }
    
    .nav-links {
        display: none;
        position: static;
        top: 100%;
        left: 0;
        width: 100%;
        flex-direction: column;
        align-items: center;
        padding: 0;
        z-index: 1000;
        border-radius: 0 0 15px 15px;
        overflow: hidden;
    }
    
    .nav-links.active {
        display: flex;
        padding: 1rem 0;
        /* Match .glassmorphism settings */
        border-radius: 15px;
    }
    
    .nav-links li {
        margin: 0.5rem 0;
        width: 90%;
        text-align: center;
    }
    
    .nav-links a {
        font-size: 1.1rem;
        padding: 0.75rem 1rem;
        display: block;
        width: 100%;
        color: var(--text-color);
        border-radius: 10px;
        transition: all 0.3s ease;
        font-weight: 600;
    }
    
    .nav-links a:hover {
        color: var(--accent-color);
    }
    
    /* Hero Section */
    .hero {
        padding: 100px 1rem 2rem 1rem;
        min-height: 90vh;
    }
    
    .hero-content {
        flex-direction: column;
        text-align: center;
        padding: 2.5rem;
        width: 92%;
        margin: 0 auto;
        border-radius: 12px;
    }
    
    .profile-image {
        margin-right: 0;
        margin-bottom: 2rem;
    }
    
    .profile-image img {
        width: 240px;
        height: 240px;
    }
    
    .profile-text h1::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .experience-header {
        flex-direction: column;
    }
    
    .experience-date {
        margin-bottom: 0.5rem;
    }
    
    /* Section spacing */
    .container {
        width: 92%;
        padding: 1rem 0;
    }
    
    .experience-content,
    .contact-content {
        padding: 1.5rem;
    }
    
    .projects-grid {
        gap: 1.5rem;
    }
    
    .project-card,
    .contact-content,
    .experience-content {
        margin-bottom: 1rem;
    }
    
    /* Contact section adjustments */
    .contact-links {
        gap: 1rem;
    }
    
    .contact-links a {
        padding: 0.7rem 1.2rem;
    }
}

/* Extra small devices */
@media (max-width: 480px) {
    .hero-buttons {
        flex-direction: column;
    }
    
    .primary-button, .secondary-button {
        width: 100%;
        text-align: center;
    }
    
    .profile-text h1 {
        font-size: 2.4rem;
    }
    
    .subtitle {
        font-size: 1.2rem;
    }
    
    .contact-links {
        flex-direction: column;
    }
    
    .contact-links a {
        width: 100%;
        justify-content: center;
    }
    
    .profile-image img {
        width: 200px;
        height: 200px;
    }
    
    .hero-content,
    .experience-content,
    .contact-content {
        padding: 1.5rem;
    }
}

/* Dark mode support for mobile navigation */
@media (max-width: 768px) and (prefers-color-scheme: dark) {
    .nav-links.active {
        /* Inherit exact dark mode glassmorphism properties */
        border-radius: 15px;
    }
}

/* Footer Styles */
footer {
    background: var(--card-bg);
    padding: 2rem 0;
    margin-top: 4rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-links {
    display: flex;
    gap: 1.5rem;
}

.footer-links a {
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.9rem;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.footer-links a:hover {
    opacity: 1;
    text-decoration: underline;
}

@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links {
        justify-content: center;
    }
}
