:root {

    --c-green: hsl(150, 40%, 50%);
    --c-accent: hsl(14, 13%, 26%);
    --c-background: hsl(0, 0%, 100%);
    --c-background: hsl(45, 33%, 99%);

    --c-text: hsl(20, 10%, 25%);
    --c-text-muted: hsla(20, 10%, 30%, 0.8);
    --c-text-dim: hsla(20, 10%, 30%, .5);
    --c-text-faint: hsla(20, 10%, 30%, .1);
    --c-border: hsl(0, 4%, 89%);

    --c-link: hsl(210, 40%, 46%);
    --c-mark: hsl(45, 100%, 81%);
    
    --c-primary: hsl(20, 10%, 48%);
    --c-primary: hsl(20, 10%, 40%);
    --c-primary: hsl(20, 15%, 26%);
    --c-pane: hsl(45, 30%, 96.5%);

    --pc-callout-note-color: #086ddd;
    --pc-callout-tip-color: #00bfbc;
    --pc-callout-success-color: #08b94e;
    --pc-callout-warning-color: #ec7500;
    --pc-callout-danger-color: #e93147;
    --pc-callout-example-color: #8a1cc6;
    --pc-callout-quote-color: #9e9e9e;

    --font-size-smaller: .85rem;
    --content-max-width: 70ch;
}

* {
    box-sizing: border-box;
}

html,
body {
    padding: 0;
    margin: 0;
}

html {
    font-family: Helvetica, Arial, sans-serif;
    font-family: Arial, Helvetica, sans-serif;
    color: var(--c-text);
    background-color: var(--c-background);
    padding: 0;
    font-size: clamp(16px, calc(.2vw + 15px), 18px);
    line-height: 1.5;
    font-weight: 300;
    background-size: auto 60vh;
    background-color: var(--c-background);

    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;

}

body {
    /* margin: 0 auto; */
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    align-items: center;
    padding: 0 clamp(1rem, 5vw, 2rem);


}

main {
    max-width: var(--content-max-width);
    width: 100%;
    flex: 1;
    align-content: start;

}

hr {
    width: 100%;
    border: 0;
    border-top: 1px solid var(--c-text-faint);
    margin: 2rem 0;
}

time {
    display: inline-block;
    font-family: monospace;
    font-size: var(--font-size-smaller);
}

blockquote {
    border-left: .2rem solid var(--c-border);
    padding-left: 1rem;
    margin: 2rem 0 2rem 1rem;
    /* font-size: 1.05rem; */
    /* color: var(--c-text-muted); */
    font-style: italic;
}

mark {
    background: var(--c-mark);
    padding: .1rem .2rem;
    border-radius: .2rem;
    /* color: var(--c-background); */
}

footer {
    max-width: var(--content-max-width);
    width: 100%;

    /* border: 1px solid var(--c-border); */
    font-size: var(--font-size-smaller);
    /* font-size: 0.9rem; */
    color: var(--c-text-muted);
    display: flex;
    /* justify-content: space-between; */
    align-items: center;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    padding: 2rem;
}

a {
    color: var(--c-link);
}

p {
    margin-block: 1rem;
}

ul,
ol {
    margin-block: 2rem;
}

li {
    margin-bottom: .5rem;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    line-height: 1.2;
    font-weight: 500;
}

h1 {
    font-size: 2.2rem;
    /* font-size: 3rem; */
    letter-spacing: -0.03em;
    margin-block: 3rem;
    margin-bottom: 2rem;
}

h2 {
    font-size: 1.6rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

h3 {
    font-size: 1.4rem;
    margin-block: 1.5rem;
    margin-bottom: 1rem;
    /* margin-bottom: .5rem; */
}

figure{

    margin: 0;
    margin-block: 2rem;

    img{
        margin: 0;
    }

    figcaption{
        font-size: var(--font-size-smaller);
        color: var(--c-text-muted);
        /* text-align: center; */
        margin-top: .125rem;
    }
}

img {
    display: inline-block;
    max-width: 100%;
    margin-block: 2rem;
    vertical-align: middle;

    /* max-height: 45vh; */
    /* object-fit: cover; */
}

/* general */


.muted {
    /* color: var(--c-text-muted); */
    /* color:red; */
    opacity: 0.7;
}

.dim {
    /* color: var(--c-text-muted); */
    color: pink;
    opacity: 0.5;
}

.accent {
    color: var(--c-accent);
}

.lead {
    font-size: 1.2rem;
    line-height: 1.5;
    color: var(--c-text);
    margin-block: 3rem;
}

.small,
small {
    font-size: var(--font-size-smaller);
}

.btn {
    display: inline-block;
    padding: .5rem 1rem;
    border-radius: .5rem;
    text-decoration: none;
    /* border:var(--c-text-muted) solid 1px; */
    transition: opacity 0.2s ease;
    width: fit-content;
    background: white;
    border: 1px solid var(--c-border);
    white-space: nowrap;
    color: var(--c-text);

    &:hover {
        opacity: .8;
    }

    &.btn__primary {
        border-color: var(--c-primary);
        background: var(--c-primary);
        color: var(--c-background);
    }

    /* &.btn__primary:hover {
         color: var(--c-text);
    } */
}


/* main header */

.mainHeader {
    display: flex;
    justify-content: space-between;
    max-width: var(--content-max-width);
    width: 100%;
   
    padding: 3rem 0;
    align-items: center;
    gap: 1rem;

    /* border: 1px solid var(--c-border);
    border-top: none; */
    /* background:red; */
    nav {
        font-size: 16px;
        display: flex;
        gap: .125rem 1rem;
        text-transform: lowercase;
        letter-spacing: 0.025em;
        /* font-size: var(--font-size-smaller); */
        opacity: 0.8;
        flex-wrap: wrap;
        justify-content: center;
        /* font-family: monospace; */


    }

    a {
        text-decoration: none;
        transition: opacity 0.2s ease;
        color: var(--c-text);

        &[aria-current="page"] {
            /* font-weight: 900; */
            /* opacity: 1; */
            color: #000;
            /* color: var(--c-link); */

            /* text-decoration: underline;
            text-underline-offset: 0.3rem;      */

            &:hover {
                opacity: 1;
            }
        }

        &:hover {
            opacity: 0.6;
        }
    }
}

/* logo */

.logo {
    font-size: 16px;
    display: inline-block;
    /* font-size: var(--font-size-smaller); */
    font-family: monospace;
    color: var(--c-background);
    color: black;
    text-decoration: none;

}

/* hero */

.hero {
    text-align: center;
    padding: 2rem 0;
    padding-bottom: 4rem;
    color: var(--c-text);
    /* background-color: red; */
    display: flex;
    min-height: 60vh;
    flex-direction: column;
    justify-content: center;
    /* background: red; */
    /* border: 1px solid var(--c-border);
    border-top: none; */
    /* background:red; */

    h1 {
        font-size: clamp(2.5rem, 8vw, 4rem);
        font-weight: 500;
        letter-spacing: -0.04em;
        margin: 0;
        /* color: var(--c-accent); */
    }

    p {
        font-size: clamp(1.1rem, 3vw, 1.3rem);
        max-width: 55ch;
        margin-inline: auto;
        color: var(--c-text-muted);
        margin-top: 1rem;
        margin-bottom: 2rem;
        /* font-weight: 300; */
    }

    .btn {
        margin: 0;
        align-self: center;
    }
}

/* notification */

.notification {
    position: fixed;
    top: .5rem;
    left: .5rem;
    font-size: .75rem;
    background: #00000005;
    padding: .25rem .5rem;
    border-radius: 2rem;
    color: var(--c-text-muted);
    z-index: 100;
    backdrop-filter: blur(5px);
    pointer-events: none;
}


/* present */

.present {

    /* padding: 5rem 2rem; */

    /* text-align: center; */
    /* display: flex;
    flex-wrap: wrap; */
    background: var(--c-pane);
    /* border:1px solid var(--c-border); */
    /* border-radius: .25rem; */
    /* padding:2rem; */
    box-shadow: 0 0 0 2rem var(--c-pane);

    h3 {
        font-size: 2rem;
        font-weight: 500;
        margin-top: 0;
        margin-bottom: 1rem;
    }

    hr {
        /* margin: 0; */
        display: none;
    }
}



/* post */

.post {
    text-decoration: none;
    display: block;
    color: var(--c-text);
    /* margin: 2rem 0; */
    /* padding:1rem; */

    h1 {
        font-size: 1.4rem;
        font-weight: 400;
        margin: 0;
        margin-bottom: 0rem;
        text-decoration: none;
    }

    p {
        margin: .5rem 0rem;
        color: var(--c-text-muted);
    }

    small {
        display: block;
        /* font-size: 1rem; */
        color: var(--c-link);
    }

    &:hover {
        background: var(--c-pane);
        box-shadow: 0 0 0 1rem var(--c-pane);

    }
}

/* project */
.project {
    /* margin-block: 3rem; */
    /* border-bottom: 1px solid var(--c-text-faint); */

    /*
    h2 {
        margin-top: 0;
        margin-bottom:2rem;
    } */


    img {
        width: 100%;
        /* border-radius: .5rem; */
        /* margin-bottom: 2rem; */
        /* preserve aspect ratio */
        height: auto;
        object-fit: cover;
        border: 1px solid var(--c-border);
        margin: .5rem 0;
    }
}


/* principles list */

.principles-list {

    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap:2rem;
    /* background: var(--c-pane); */

    li {
        /* background: var(--c-pane); */
        /* padding: 2rem; */
        position: relative;
        flex: 1 1 30ch;
        /* padding: 2rem; */
        margin: 0;
    }
}

.principle {
    text-decoration: none;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    color: var(--c-text);
    pointer-events: none;

    h3 {
        /* position: absolute;
        top: 0;
        left: 0;
        font-size: 1rem; */
        /* color: var(--c-text-dim); */
        margin: 0;

        font-size: 1.4rem;
        display: flex;
        align-items: center;
        gap: 0.5rem;
        /* font-family: monospace; */
        /* color: var(--c-text-dim); */
    }

    b {
        /* display: block; */
        color: var(--c-text-muted);
        font-weight: 100;
    }

    p {
        margin: 0;
        /* color: var(--c-text-muted); */
        /* font-size: 1.2rem; */
        /* max-width: 15ch; */
        line-height: 1.4;
    }

    &:hover {
        background: var(--c-pane);
        box-shadow: 0 0 0 1rem var(--c-pane);
    }
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: .6rem;
    padding: .4rem 1rem;
    border-radius: 999px;
    background: var(--c-pane);
    color: var(--c-muted);
    font-size: var(--font-size-smaller);
    white-space: nowrap;
}

.status-dot {
    position: relative;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--c-green);
    flex-shrink: 0;
}

.status-dot::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: var(--c-green);
    animation: status-pulse 4s ease-out infinite;
}

@keyframes status-pulse {
    80% {
        transform: scale(1);
        opacity: .6;
    }

    100% {
        transform: scale(2.5);
        opacity: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .status-dot::after {
        animation: none;
        opacity: 0;
    }
}

.callout {
    --callout-color: var(--pc-callout-note-color);
    margin-block: 1rem;
    padding: .5rem .75rem;
    border-radius: .25rem;
    background-color: color-mix(in srgb, var(--callout-color), transparent 93%);
    border: 1px solid color-mix(in srgb, var(--callout-color), transparent 75%);
    /* border-left: 3px solid color-mix(in srgb, var(--callout-color), transparent 30%); */
    font-size: 0.9em;
    /* line-height: 1.2; */
    text-align: left;
    color: color-mix(in srgb, var(--callout-color) 60%, var(--c-text));

    a {

        color: var(--callout-color);

    }

    &-title {
        font-weight: bold;

        &:first-letter {
            text-transform: capitalize;
        }
    }

    &[data-callout="tip"],
    &[data-callout="abstract"] {
        --callout-color: var(--pc-callout-tip-color);
    }

    &[data-callout="success"] {
        --callout-color: var(--pc-callout-success-color);
    }

    &[data-callout="warning"],
    &[data-callout="question"] {
        --callout-color: var(--pc-callout-warning-color);
    }

    &[data-callout="danger"],
    &[data-callout="bug"],
    &[data-callout="failure"] {
        --callout-color: var(--pc-callout-danger-color);
    }

    &[data-callout="example"] {
        --callout-color: var(--pc-callout-example-color);
    }

    &[data-callout="quote"],
    &[data-callout="cite"] {
        --callout-color: var(--pc-callout-quote-color);
    }
}

/* overrides */
.__pel {
    /* custom styles for pel elements */
    max-width: 100% !important;
    border-radius: 0 !important;
}

/* layout helpers */

.m-0 {
    margin: 0;
}

.mt-0 {
    margin-top: 0;
}

.mt-1 {
    margin-top: 1rem;
}

.mt-2 {
    margin-top: 2rem;
}

.mt-3 {
    margin-top: 3rem;
}

.mt-4 {
    margin-top: 4rem;
}

.mt-5 {
    margin-top: 5rem;
}

.mt-6 {
    margin-top: 6rem;
}

.mb-1 {
    margin-bottom: 1rem;
}

.mb-2 {
    margin-bottom: 2rem;
}

.mb-3 {
    margin-bottom: 3rem;
}

.mb-4 {
    margin-bottom: 4rem;
}

.mb-0 {
    margin-bottom: 0;
}

.cell {
    border: 1px solid var(--c-border);
    border-top: none;
    padding: 2rem;

    :first-child {
        margin-top: 0;
    }

    :last-child {
        margin-bottom: 0;
    }
}

.p-2 {
    padding: 2rem;
}

.no-pe {
    pointer-events: none;
}

.list {
    list-style: none;
    padding: 0;
    /* margin: 0; */
    display: flex;
    flex-wrap: wrap;
    /* border-left: 1px solid var(--c-border); */
    gap: 3rem;

    li {
        margin: 0;
    }

    /*
    > * {
        padding: 2rem 0;
        border-bottom: 1px solid var(--c-border);
        &:last-child {
                border-bottom: none;
            }

        >*:first-child {
         margin-top: 0;
        }
        >*:last-child {
         margin-bottom: 0;
         }
          */

}

.grid {
    list-style: none;
    padding: 0;

    display: flex;
    flex-wrap: wrap;
    border-right: 1px solid var(--c-border);

    &>* {

        flex: 1 1 40ch;
        /* background: var(--c-pane); */
        /* background:red; */
        border-left: 1px solid var(--c-border);
        border-bottom: 1px solid var(--c-border);
        /* border-bottom: none; */
        padding: 2rem;
        margin: 0;

        :first-child {
            margin-top: 0;
        }

        :last-child {
            margin-bottom: 0;
        }
    }
}


.grid__no-padding {

    &>* {
        padding: 0;
    }
}

.grid__hover {
    &>* {
        transition: all 0.15s ease;

        &:hover {
            text-decoration: none;
            background-color: var(--c-pane);
        }
    }
}



/* media queries */

@media (max-width: 700px) {

    .mainHeader {
        padding-top: 2rem;
        justify-content: center;
        flex-direction: column;
    }
}
