/* --- BASIS-EINSTELLUNGEN --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --accent: #747574;
    --dark: #000000;
    --light: #f8f8f8;
}

body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    background-color: #ffffff;
    color: var(--dark);
}

h1,
h2,
h3 {
    font-weight: 700;
    margin-bottom: 15px;
}

/* --- HEADER --- */
header {
    height: 20vh;
    background-color: var(--dark);
    color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

/* --- NAVIGATION --- */
nav {
    background-color: var(--light);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid #ddd;
}

nav ul {
    list-style: none;
    display: flex;
    justify-content: center;
}

nav a {
    text-decoration: none;
    color: var(--dark);
    padding: 15px 20px;
    display: block;
    font-weight: bold;
    transition: 0.3s;
}

nav a:hover {
    color: var(--accent);
}

/* --- HAUPTLAYOUT (CSS Grid) --- */
.page-layout {
    max-width: 1200px;
    margin: 40px auto;
    padding: 20px;
    display: grid;
    grid-template-columns: 3fr 1fr;
    gap: 40px;
}

/* --- SEKTIONEN --- */
section {
    margin-bottom: 60px;
}


.about-flex {
    display: flex;
    flex-direction: row;
    gap: 30px;
    align-items: flex-start;
}

.profile-img {
    width: 200px;
    height: auto;
    border-radius: 10px;
    object-fit: cover;
    flex-shrink: 0;

}

.text {
    flex: 1;
}


.project-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.project-card {
    border: 1px solid #eee;
    padding: 20px;
    text-align: center;
    transition: 0.3s;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.project-card:hover {
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    border-color: var(--accent);
}

.project-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    margin-bottom: 15px;
}

.btn {
    display: inline-block;
    background-color: var(--dark);
    color: #fff;
    padding: 8px 15px;
    text-decoration: none;
    margin-top: 10px;
    font-size: 0.9em;
    transition: 0.3s;
}

.btn:hover {
    background-color: var(--accent);
    color: var(--dark);
}

/* --- ASIDE (Sidebar) --- */
aside {
    background-color: #fafafa;
    padding: 25px;
    border-left: 5px solid var(--accent);
    height: fit-content;
}

.skills {
    list-style: none;
    margin-bottom: 20px;
}

.skills li {
    padding: 5px 0;
    border-bottom: 1px solid #eee;
}


@media (max-width: 900px) {
    .page-layout {
        grid-template-columns: 1fr;
        /* Sidebar rutscht unter den Hauptinhalt */
    }

    .project-grid {
        grid-template-columns: repeat(2, 1fr);
        /* 2 Spalten auf Tablets */
    }

    aside {
        border-left: none;
        border-top: 5px solid var(--accent);
        margin-top: 20px;
    }
}

@media (max-width: 600px) {
    .about-flex {
        flex-direction: column;
        /* Bild über den Text auf Handys */
        align-items: center;
        text-align: center;
    }

    .project-grid {
        grid-template-columns: 1fr;
        /* 1 Spalte auf Handys */
    }

    nav ul {
        flex-direction: column;
        align-items: center;
    }
}

/* --- FOOTER --- */
footer {
    text-align: center;
    padding: 40px;
    background-color: var(--dark);
    color: #fff;
}

footer a {
    color: var(--accent);
    text-decoration: none;
}