/* Global */
:root {
    --std-spacing: 3.2rem;
    
    /* Barebones overrides */
    --theme-hue: #fdfcfa;
    --accent-hue: 247;
    --background-color: var(--theme-hue);
    --accent-color: hsl(var(--accent-hue), 100%, 59%);				
    --text-color-normal: #0b0726;
    --button-primary-color: var(--theme-hue);
    --swiper-navigation-size: 20px;
    --swiper-navigation-color: var(--accent-color);
}

@keyframes scroll-progress {
    to {
        background-color: var(--accent-color);
        width: 100%;
    }
}

@keyframes project-scale {
    from { 
        transform: scale(1); 
        filter: blur(0);
    }
    10% {
        transform: scale(1.01);
        filter: blur(5px);
    }
    20% {
        transform: scale(1); 
    }
    to { 
        transform: scale(0.75); 
    }
}

@keyframes reveal {
    to {
        clip-path: inset(0 0 0 0);
    }
}

body {
    box-sizing: border-box;
    margin: 0;
}

section {
    padding-top: calc(0.5 * var(--std-spacing));
    padding-bottom: calc(0.5 * var(--std-spacing));
}

section:first-of-type {
    scroll-margin-top: calc(3 * var(--std-spacing));
}

section + section {
    padding-top: calc(1.5 * var(--std-spacing));
}

@media (min-width: 900px) {
    section {
        padding-top: var(--std-spacing);
        padding-bottom: var(--std-spacing);
    }
    section + section {
        padding-top: calc(3 * var(--std-spacing));
    }
}

.demo-container-xs {
    max-width: 400px;
    margin: auto;
}

@media (max-width: 900px) {
    .row {
        gap: calc(0.25 * var(--std-spacing));
    }
}

.h1, .h2, .h3, .h4, .h5, .h6, h1, h2, h3, h4, h5, h6, p, ul {
    margin-bottom: calc(0.5 * var(--std-spacing));
    color: var(--text-color-normal);
}

.h1, .h2, h1, h2 {
    font-family: 'Josefin Sans', sans-serif;
    text-wrap: balance;
}

h1 {
    font-size: clamp(2.4rem, 0.8rem + 4.267vw, 4rem);
}

.h3, .h4, .h5, .h6, h3, h4, h5, h6, a, p, ul, ol {
    font-family: 'Inter', sans-serif;
    font-weight: 300;
}

b, strong {
    font-weight: 600;
}

pre {
    margin-top: 0;
}

pre:has(+ pre) {
    margin-bottom: 0;
}

code {
    font-family: 'Roboto Mono', monospace;
}

@media (max-width: 900px) {
    pre, code {
        max-width: 90vw;
    }
    pre {
        border: 1px solid var(--accent-color);
        box-shadow: inset 0 0 5px #555;
    }
}

.tw-pretty {
    text-wrap: pretty;
}

a:not([class]) {
    color: var(--accent-color);
}

a:not([class]):hover {
    color: var(--text-color-normal);
}

a, a:hover,
li, li:hover {
    transition: all ease-in-out 0.3s;
}

ul {
    list-style-type: disc;
    margin-bottom: 0;
}

hr.primary {
    border-top: 1px solid var(--accent-color);
    width: 85%;
    max-width: 960px;
}

.text-brand, .text-primary {
    color: var(--accent-color);
}

.button {
    height: unset;
    min-height: 38px;
    padding-block: 1rem;
}

.button.button-primary {
    border: 2px solid var(--accent-color);
    max-width: 300px;
    font-size: 2rem;
    font-weight: normal;
    text-transform: capitalize;
    line-height: 1;
}

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

.placeholder {
    background-color: lightgray;
    border-radius: 4px;
    cursor: inherit;
}

.placeholder.landscape {
    aspect-ratio: 16/9;
}

.placeholder.portrait {
    aspect-ratio: 4/5;
}

img:not(.logo), video {
    border-radius: 4px;
}

video {
    aspect-ratio: 16/9;
    background-color: #000e;
}

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

.mb-1 {
    margin-bottom: calc(0.5 * var(--std-spacing));
}

.mb-2 {
    margin-bottom: calc(1 * var(--std-spacing));
}

.mb-3 {
    margin-bottom: calc(1.5 * var(--std-spacing));
}

/* General */
.hp-title, .projects-title {
    clip-path: inset(0 100% 0 0);
    animation: reveal 500ms forwards cubic-bezier(0.77, 0, 0.175, 1);
}

#intro .text-wrapper, #intro .button, 
.versions .intro {
    clip-path: inset(0 100% 0 0);
    animation: reveal 750ms forwards cubic-bezier(0.77, 0, 0.175, 1);
}



/* Nav */
@media (max-width: 900px) {
    .navbar {
        box-shadow: 0 1px 10px 0 #00000033;
        position: sticky;
        top: 0;
        z-index: 100;
    }
    .scroll-progress {
        display: none;
    }
}

@media (max-width: 900px) and (prefers-reduced-motion: no-preference) {
    @supports (animation-timeline: scroll()) {
        .scroll-progress {
            display: block;
            margin: 0;
            height: 3px;
            width: 0%;
            background-color: var(--accent-color);
            animation: scroll-progress 1s linear;
            animation-timeline: scroll();
        }
    }
}

.navbar .container,
footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar .container {
    padding-block: 2rem;
    background-color: var(--theme-hue);
}

.container .navbar-list {
    display: flex;
    margin-left: auto;  
    margin-bottom: 0;
    padding-inline-end: 0;
    list-style: none;
}

.container .navbar-list li {
    padding: 0 1rem;
    margin-bottom: 0;
    font-size: 1.4rem;
    line-height: clamp(2rem, 0.8rem + 3.2vw, 3.2rem);
}

.container .navbar-list li:hover {
    background-color: var(--accent-color);
    color: var(--theme-hue);
}

.navbar-link, .navbar-brand {
    text-decoration: none;
    color: var(--text-color-normal)
}

.container .navbar-list li:hover .navbar-link {
    color: var(--theme-hue);
}


.navbar-brand {
    font-family: 'Josefin Sans', sans-serif;
    font-size: clamp(2rem, 0.8rem + 3.2vw, 3.2rem);
    line-height: 1;
}


/* Intro & About */
.lead {
    font-size: 2rem;
}

.text-wrapper {
    margin-bottom: calc(var(--std-spacing) * 2 / 3);
    @media (min-width: 900px) {
        margin-bottom: calc(1.5 * var(--std-spacing));
    }
}

.centered {
    text-align: center;
    @media (min-width: 900px) {
        text-align: left;
    }
}

.home .button.centered {
    @media (max-width: 900px) {
        display: flex;
        justify-self: center;
    }
}


/* Project Intros */
/* .card .card-header,
.card .card-footer {
    border: none;
}

.card {
    border: 1px solid lightgray;
    margin-bottom: calc(0.75 * var(--std-spacing));
}

.card > *  {
    background-color: transparent;
}

.card .card-header {
    padding: 0;
}

.card .card-footer {
    padding: calc(0.75 * var(--std-spacing)) calc(0.5 * var(--std-spacing));
} */


/* Project Details */
.project {
    container-type: inline-size;
    margin: 0 auto;
    padding-block: 2rem;
    /* border-radius: 4px;
    box-shadow: 0px 6px 6px 6px #e0e0e0; */
}

img:not(.logo), video {
    box-shadow: 0 0 1px #5555;
}

.swiper-slide img {
    box-shadow: none;
}

.project + .project {
    margin-top: calc(1.5 * var(--std-spacing));
}

@media (min-width: 900px) {
    .project + .project {
        margin-top: calc(4 * var(--std-spacing));
    }

    @supports (animation-timeline: view()) {
        .project {
            animation: project-scale linear both;
            animation-timeline: view();
            animation-range: cover 75% cover 100%;
        }
    }
}

.project-card {
    display: grid;
    max-width: 100%;
    row-gap: 2rem;
    grid-template-areas: "logo" "content" "screengrabs";
    grid-template-columns: minmax(0, 1fr);

    .logo-wrapper {
        grid-area: logo;
    }

    .screengrabs-wrapper {
        grid-area: screengrabs;
    }

    .content-wrapper {
        grid-area: content;
    }
}

.project-card .logo-wrapper {
    .logo {
        max-width: 300px;
        max-height: 150px;
    }

    .project-link:hover .logo,
    .project-link:focus-within .logo {
        filter: grayscale(0.75);    
        cursor: pointer;
    }
}

.project#aifkk {
    .logo {
        filter: drop-shadow(2px 2px 4px #1a2857);
    }
}

.project-card .swiper {
    display: flex;
    flex-direction: column;
    max-width: 100vw;
    
    .swiper-slide {
        display: flex;
        flex-direction: column;
        justify-content: center;
        margin: auto;
    }
    
    .swiper-controls {
        display: flex;
        justify-content: flex-start;
        order: 2;
        margin-top: calc(0.5 * var(--std-spacing));
        margin-inline-start: -10px;
        gap: calc(1.25 * var(--std-spacing));
        min-height: var(--std-spacing);
    }

    .swiper-button-prev,
    .swiper-button-next {
        position: relative;
        margin-top: 0;
    }
    .swiper-button-prev:hover,
    .swiper-button-next:hover {
        filter: drop-shadow(0 1px 0 var(--accent-color));
    }

    img, video {
        margin: 0;
    }
}

.project-card .content-wrapper {
    ul {
        list-style-position: outside;
        margin-inline-start: 2rem;
    }
}

@container (min-width: 640px) {
    .project-card {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        column-gap: 6%;
        grid-template-areas: ". logo" "screengrabs content";
    }
    
    .project-card .swiper {
        display: block;
        margin-top: calc(-1 * var(--std-spacing));

        .swiper-controls {
            margin-top: 0;
        }
    }
}

.project:nth-child(even) {
    @container (min-width: 640px) {
        .project-card {
            grid-template-areas: "logo ." "content screengrabs";
        }
        .project-card .swiper {
            .swiper-controls {
                justify-content: flex-end;
                margin-inline-start: 0;
            }
        }
    }
} 

.samples-img-wrapper {
    margin-bottom: 2rem;
}

/* Footer */
footer {
    padding-top: var(--std-spacing);
    padding-bottom: var(--std-spacing);
    margin-top: var(--std-spacing);
    border-top: 1px solid #00000033;
}

@media (min-width: 900px) {
    footer {
        padding-top: calc(1.5 * var(--std-spacing));
        padding-bottom: calc(1.5 * var(--std-spacing));
        margin-top: calc(1.5 * var(--std-spacing));
    }
}

footer .container .navbar-list {
    margin-left: 0;
    margin-right: auto;
}

footer a.animated-arrow {
    text-decoration: none;
    transition: all ease-in 0.5s;
    font-size: calc(0.75 * var(--std-spacing));
    color: var(--accent-color);
}

footer a.animated-arrow:hover {
    transform: scale(1.5);
}
