@font-face {
    font-family: "Fredoka";
    src: url("../../../fonts/Fredoka-VariableFont_wdth,wght.woff2") format("woff2");
}


:root {
    font-family: "Fredoka", sans-serif;
    line-height: 1.6;
    scroll-behavior: smooth;
    --bg: oklch(0.99 0.003 325);
    --primary: oklch(0.25 0.01 325);

}

*, *::before, *::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    background-color: var(--bg);
    color: var(--primary);
}

.container {
    max-width: 80rem;
    margin-inline: auto;
    padding-inline: 1rem
}

nav ul {
    list-style: none;
    padding: 0;
    margin: 0 0 0 -2rem;
    display: flex;
    flex-wrap: wrap;


    a {
        display: block;
        padding-block: 1rem;
        color: inherit;
        text-decoration: none;
        padding-inline: 2rem
    }
}

.row {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;

    > * {
        border-style: dashed;
        padding: 1rem;
        border-color: var(--primary);
        border-width: 1px;
        flex-grow: 1;
    }

    > *:first-child {

        flex-grow: 2;
    }

}

.visually-hidden {
    border: 0;
    clip-path: inset(50%);
    height: 1px;
    margin: 0;
    overflow: hidden;
    position: absolute;
    white-space: nowrap;
    width: 1px;
}

main nav {
    --bg: oklch(0.8133 0.1 29.65);
    --primary: oklch(0.1133 0.1 29.65);

    ul {
        display: flex;

        flex-wrap: wrap;

        :not(:first-child) > a {
            display: block;
            background-color: var(--bg);
            color: var(--primary);
            transition: color 0.2s ease-in-out 0.1s,
            background-color 0.2s ease-in-out 0.1s;


            &:hover, &:focus-visible {
                background-color: var(--primary);
                color: var(--bg);

            }
        }

        > :first-child {
            font-weight: bold;
            margin-right: auto;
        }
    }
}

.cards {
    list-style: None;
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin: 0;
    padding: 0;

    li {


        display: flex;
        flex-direction: column;
        flex-basis: 18rem;
        position: relative;
        border-radius: .5em;
        box-shadow: 0 0 .2rem oklch(0 0 0 / .2), 0 0 2rem oklch(0 0 0 / .1);
        overflow: hidden;
        transition: box-shadow .2s ease-in-out;

        &:hover,
        &:has(.overlay-link:focus-visible) {
            box-shadow: 0 0 0.5rem oklch(0 0 0 / .4), 0 0 3rem oklch(0 0 0 / .2);
        }

        &::before {
            content: "";
            position: absolute;
            inset: 0;
            z-index: 2;
            mix-blend-mode: overlay;
            background-color: oklch(.2 .2 264 / .6);
            scale: 0;
            border-radius: 50%;
            transition: scale .8s ease-in-out .5s,
            border-radius 1s ease-out .5s;

        }

        &:hover::before,
        &:has(.overlay-link:focus-visible)::before {
            scale: 1;
            border-radius: 0;
            transition: scale .2s ease-in-out,
            border-radius .2s ease-in-out .05s;
        }
    }

    .content {
        z-index: 3;
        background-color: var(--bg);
    }

    img {
        order: -1
    }

    .overlay-link::after {
        content: "";
        position: absolute;
        inset: 0;
    }

    a:not(.overlay-link) {
        position: relative;
        z-index: 1
    }
}