/*Font*/
@font-face {
    font-family: "CreatoDisplay";
    src: url("../assets/fonts/CreatoDisplay-Regular.otf") format("opentype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "CreatoDisplay";
    src: url("../assets/fonts/CreatoDisplay-Black.otf") format("opentype");
    font-weight: 900;
    font-style: normal;
    font-display: swap;
}

/*Regeln*/
:root {
    /* Blau aus Figma: HSB 249/100/100= #2600FF*/
    --accent: #2600ff;

    /* Typografieregeln*/
    --fs-hero: clamp(2rem, 10vw, 2.5rem); /* 40px*/
    --fs-heading: clamp(1.5rem, 6.5vw, 1.875rem); /* 30px*/
    --fs-regular: 1rem; /* 16px*/

    --text: #000;
    --bg: #fff;
}

/*Ich bin ehrlich keine Ahnung ist anscheinend wichtig da hab ich mir helfen lassen*/
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    /* Basis für rem ig? */
    font-size: 16px;
}

body {
    margin: 0;
    font-family:
        "CreatoDisplay",
        system-ui,
        -apple-system,
        "Segoe UI",
        Roboto,
        Arial,
        sans-serif;
    color: var(--text);
    background: var(--bg);
}
/*Für Barierrefreiheit rauskopiert*/
a {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 0.15em;
}
a:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 3px;
}

/*Typo Vorgaben*/
/*Hero: Großer Text anfang*/
#intro h1 {
    font-size: var(--fs-hero);
    font-weight: 900;
    line-height: 1.05;
    margin: 0;
}

#intro a,
.accent {
    color: var(--accent);
    text-transform: uppercase;
}

/* Zwischenüberschriften: Skills/ Projects/ Contact*/
h2,
h3 {
    font-size: var(--fs-heading);
    font-weight: 900;
    line-height: 1.1;
    margin: 0;
}

/* Fließtext*/
p,
li {
    font-size: var(--fs-regular);
    font-weight: 400;
    line-height: 1.5;
}

/* Standardabstand für Absätze*/
p {
    margin: 0 0 1em 0;
}

/*Bilder responsiv*/
img {
    display: block;
    max-width: 100%;
    height: auto;
}
/* Grundlayout*/
/* Abstände zwischen Bereichen */
main {
    display: block;
}
section {
    padding: 2rem 1.25rem; /* oben/unten & links/rechts*/
}
/* Intro mehr Abstand */
#intro {
    padding-top: 3rem;
    padding-bottom: 3rem;
}

/* Header*/
header {
    position: sticky;
    top: 0;
    background: var(--bg);
    padding: 1rem 1.25rem;
    z-index: 10;
}

.site-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Link*/
.site-nav a {
    text-decoration: none;
    color: var(--text);
}

/* Links blauer Kreis*/
.nav-home {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--accent);
    display: block;
}

/* Rechts i */
.nav-imprint {
    font-size: var(--fs-hero); /* gleiche Größe wie Hero */
    font-weight: 900;
    line-height: 1;
}

/* Fokus */
.site-nav a:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 4px;
}

/*About*/
#about figure {
    margin: 2rem 0;
}
#about img {
    width: 100%;
    height: auto;
}
/* Skills-Liste*/
#about ul {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0 0 0;
}
#about li {
    margin-bottom: 0.5rem;
}

/* 10) Projects / Blog/ Contact*/
#projects,
#blog,
#contact {
    padding-top: 3rem;
}
footer p {
    margin: 0;
}

/* fußzeile*/
.site-footer {
    background: var(--accent);
    color: #fff;
    padding: 1.5rem 1.25rem;

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

.site-footer a {
    color: #fff;
    text-decoration: none;
    font-weight: 700;
}

.site-footer a:hover {
    text-decoration: underline;
}

.site-footer a:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 3px;
}

.site-footer p {
    margin: 0;
}

/* Links nebeneinander (Impressum/Datenschutz) */
.footer-legal {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.footer-copy {
    font-size: 0.875rem;
}

/* Bewertungspunkte*/
.skills {
    list-style: none;
    padding: 0;
    margin: 1.25rem 0 0 0;
}

.skill {
    display: flex;
    align-items: center; /* Punkte mittig*/
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.skill__name {
    font-weight: 900;
}

.skill__dots {
    display: inline-flex;
    align-items: center;
    gap: 10px; /* Abstand*/
}

.dot {
    width: 15px;
    height: 15px;
    border-radius: 999px;
    border: 3px solid var(--accent); /* Outline 3px*/
    background: transparent;
    flex: 0 0 auto;
}

.dot.is-filled {
    background: var(--accent);
}

/*Project silder und blaue Punkte mit abgerunderter weißer Fläche*/
.carousel {
    margin-top: 1.5rem;
}

.carousel__viewport {
    position: relative;
    overflow: hidden;
    border-radius: 0;
}

/* Slides: nur aktives sichtbar */
.carousel__slide {
    display: none;
    margin: 0;
}

.carousel__slide.is-active {
    display: block;
}

.carousel__slide img {
    width: 100%;
    height: auto;
    display: block;
}

/* Weiße Pill auf dem Bild */
.carousel__pill {
    position: absolute;
    left: 50%;
    bottom: 16px;
    transform: translateX(-50%);

    display: inline-flex;
    align-items: center;
    gap: 10px;

    background: #fff;
    border-radius: 20px;
    padding: 10px 14px;

    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
}

/* Dots: gleiche Größe wie Skills */
.carousel__dot {
    width: 15px;
    height: 15px;
    border-radius: 999px;
    border: 3px solid var(--accent);
    background: transparent;
    padding: 0;
}

.carousel__dot.is-active {
    background: var(--accent);
}

.carousel__dot:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 3px;
}

.carousel__dot {
    cursor: pointer;
    transition: transform 120ms ease;
}

.carousel__dot:hover {
    transform: scale(1.08);
}

/* Abstände proportional vergrößert yupie*/
.blog-grid {
    margin-top: 1.5rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(10px, 3vw, 18px); /* proportional zum Display :)*/
}

.blog-grid__item {
    margin: 0;
}

.blog-grid__item img {
    width: 100%;
    height: auto;
    display: block;
}

/* irgendwie hat es mit dem Formatfüllend nicht geklappt
ok egal funktioniert immer noch nicht :/ an dieser Stelle lass ich es*/
#project-cover,
#project-slider {
    padding-left: 0;
    padding-right: 0;
}

/* Weil vorher keine icons gehabt kommt jetzt zum Schluss*/
.contact-icons {
    display: flex;
    gap: 1.5rem;
    margin-top: 1.5rem;
    align-items: center;
}

.contact-icons img {
    width: 32px;
    height: 32px;
    display: block;
}

/* CSS für Projektseite*/

.project-kicker {
    font-size: var(--fs-hero);
    font-weight: 900;
    line-height: 1.05;
    margin: 0 0 0.5rem 0;
}

.project-title {
    font-size: var(--fs-hero);
    font-weight: 900;
    line-height: 1.05;
    margin: 0;

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

.project-title__name,
.project-title__year {
    color: var(--accent);
}

.project-title__dots {
    display: inline-flex;
    gap: 10px;
    align-items: center;
}
/* Desktop Homepage*/

/* Projektseite: Desktop-Grid verstecken (Mobile nutzt Slider)*/
.project-images--desktop {
    display: none;
}

@media (min-width: 1024px) {
    /* Typo Desktop */
    :root {
        --fs-hero: clamp(4rem, 7vw, 7.5rem); /* bis ~120px */
        --fs-heading: clamp(3rem, 5vw, 5rem); /* bis ~80px */
        --fs-regular: clamp(1.8rem, 2.3vw, 2.1875rem); /* bis ~35px */
    }

    /* Header Desktop */
    .nav-home {
        width: 56px;
        height: 56px;
    }

    .nav-imprint {
        font-size: clamp(2rem, 3vw, 3.5rem);
    }

    /* Desktop-Layout */
    section {
        padding: 3rem 0;
    }

    main {
        margin: 0;
    }

    /* Intro*/
    #intro {
        padding-top: 3rem;
        padding-bottom: 3rem;
    }

    #intro h1 {
        letter-spacing: -0.02em;
    }

    /* Überschriften*/
    h2,
    h3 {
        font-size: var(--fs-heading);
    }

    /* Skills Kreise + Slider Kreise) W40/H40 --- */
    .dot,
    .carousel__dot {
        width: 40px;
        height: 40px;
        border: 9px solid var(--accent);
    }
    .carousel__dot {
        border-width: 9px;
    }

    /* Pill: Corner Radius 60 */
    .carousel__pill {
        border-radius: 60px;
        padding: 18px 22px;
        gap: 16px;
        bottom: 24px; /* etwas mehr Luft */
    }

    /* About: Foto links, Text+Skills rechts, Skills dürfen nicht umbrechen*/
    #about {
        display: grid;
        grid-template-columns: minmax(320px, 420px) 1fr;
        grid-template-areas:
            "title title"
            "photo text"
            "photo skills";
        gap: 3.5rem;
        align-items: start;

        padding-left: 0;
        padding-right: 3rem;
    }

    #about h2 {
        grid-area: title;
    }
    #about figure {
        grid-area: photo;
        margin: 0;
    }
    #about .about-text {
        grid-area: text;
    }
    #about section[aria-labelledby="skills-heading"] {
        grid-area: skills;
    }

    /* Textabstände wieder normal */
    #about .about-text p {
        margin: 0 0 1em 0;
    }
    #about .about-text p:last-child {
        margin-bottom: 0;
    }

    /* Skills rechts unter dem Text */
    #about section[aria-labelledby="skills-heading"] {
        grid-area: skills;
    }

    /* Skills nicht umbrechen*/
    .skill {
        flex-wrap: nowrap;
    }

    .skill__name {
        white-space: nowrap;
    }

    .skill__dots {
        flex-wrap: nowrap;
    }

    /* Projects: Bildformat 16:9*/
    #projects {
        padding-left: 0;
        padding-right: 0;
    }

    .carousel__viewport {
        width: 100%;
    }

    .carousel__slide img {
        width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
        object-fit: cover;
    }

    /* Blog: alle 4 nebeneinander, außen ohne Rand*/
    #blog {
        padding-left: 0;
        padding-right: 0;
    }

    .blog-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: clamp(12px, 1.2vw, 24px);
        margin-top: 2rem;
    }

    #about p {
        margin: 0 0 1em 0; /* konsistent */
    }
    #about p:last-of-type {
        margin-bottom: 0; /* keine extra Lücke vor Skills */
    }

    .skill {
        padding-right: 2rem; /* Abstand vom rechten Rand */
    }

    /* Contact Icons größer auf Desktop */
    .contact-icons img {
        width: 56px;
        height: 56px;
    }

    #contact .contact-icons {
        margin-top: 2rem;
    }

    /* Projektseite Desktop: Slider aus, Grid an*/
    .project-images--mobile {
        display: none;
    }
    .project-images--desktop {
        display: block;
    }

    /* Projektbilder Desktop: 2x2 Grid wie Blog*/
    .project-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: clamp(12px, 1.2vw, 24px);
        margin-top: 2rem;
    }

    .project-grid__item {
        margin: 0;
    }

    .project-grid__item img {
        width: 100%;
        height: auto;
        display: block;
        object-fit: cover;
        aspect-ratio: 4 / 3;
    }

    #project-cover img {
        width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
        object-fit: cover;
    }

    /* ===== Projektseite Desktop: Titel + Dots ===== */
    .project-title {
        justify-content: flex-start; /* nicht mehr rechts rausdrücken */
        gap: 2rem;
    }

    .project-title__dots {
        margin-left: 1.5rem; /* Dots näher an den Titel */
    }

    /* ===== Projektseite Desktop: Cover formatfüllend ===== */
    #project-cover {
        padding: 0; /* komplett randlos */
        margin: 0;
    }

    #project-cover figure {
        margin: 0; /* WICHTIG: entfernt die Default-Figure-Ränder */
    }

    /* ===== Projektseite Desktop: Fließtext Abstand ===== */
    #project-text {
        padding-left: 3rem;
        padding-right: 3rem;
    }
}
