/* =========================================================
   THE CREATURE OF WELLSTOWN
   NES PROJECT PAGE
========================================================= */

/* =========================================================
   FONTS
========================================================= */

/* @import url('https://fonts.googleapis.com/css2?family=Silkscreen:wght@400;700&display=swap'); */


/* =========================================================
   VARIABLES
========================================================= */

/* :root {
    --background: #0a111a;
    --surface: #212334;
    --surface-light: #292b3d;
    --surface-dark: #171925;

    --mcol: #34dd50;
    --mcol-dark: #b9283a;
    --mcol-light: #ef4054;

    --text: #afb1bd;
    --text-light: #d5d6dd;
    --text-muted: #777a8a;

    --border: #383a4d;
    --border-dark: #151722;

    --shadow: rgba(0, 0, 0, 0.45);

    --content-width: 1200px;
} */


/* =========================================================
   RESET
========================================================= */

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;

    background: var(--background);
    color: var(--text);

    font-family: "Silkscreen", monospace;
    font-size: 14px;
    line-height: 1.8;

    overflow-x: hidden;
}

img,
video {
    max-width: 100%;
}

a {
    color: inherit;
}


/* =========================================================
   GLOBAL CONTAINER
========================================================= */

.container {
    width: min(
        calc(100% - 4rem),
        var(--content-width)
    );

    margin-inline: auto;
}


/* =========================================================
   HEADER
========================================================= */

.site-header {
    position: relative;

    width: 100%;

    background: var(--background);

    border-bottom: 1px solid var(--border-dark);
}

.header-content {
    width: min(
        calc(100% - 4rem),
        var(--content-width)
    );

    min-height: 100px;

    margin-inline: auto;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 2rem;
}


/* Brand */

.brand {
    display: flex;
    align-items: center;

    gap: 1rem;

    color: var(--text-light);

    text-decoration: none;
}

.logo {
    width: 52px;
    height: 52px;

    object-fit: contain;

    image-rendering: pixelated;
}

.brand-info {
    display: flex;
    flex-direction: column;

    gap: 0;

    line-height: 1.2;
}

.brand-text {
    color: var(--text-light);

    font-size: 1rem;
    font-weight: 700;
}

.brand-text-small {
    color: var(--text-muted);

    font-size: 0.55rem;

    text-transform: uppercase;
}


/* Header email */

.header-email {
    color: var(--text-muted);

    font-size: 0.65rem;

    text-decoration: none;

    transition:
        color 0.15s ease;
}

.header-email:hover {
    color: var(--mcol);
}


/* =========================================================
   PROJECT PAGE
========================================================= */

.project-page {
    background: var(--background);

    padding-bottom: 8rem;
}


/* =========================================================
   PROJECT HERO
========================================================= */

.project-hero {
    padding-top: 7rem;
    padding-bottom: 5rem;
}

.project-hero-meta {
    display: flex;
    align-items: center;

    gap: 1rem;

    margin-bottom: 2rem;
}


/* 01 */

.project-hero-meta .project-number {
    margin: 0;

    color: var(--mcol);

    font-size: 0.8rem;
    font-weight: 700;
}


/* Assembly / memory optimization */

.project-category {
    color: var(--text-muted);

    font-size: 0.6rem;

    letter-spacing: 0.05em;
    text-transform: uppercase;
}


/* Main title */

.project-hero h1 {
    max-width: 1000px;

    margin: 0;

    color: var(--mcol);

    font-size: clamp(
        3rem,
        8vw,
        3rem
    );

    font-weight: 700;

    line-height: 0.95;

    letter-spacing: -0.04em;

    /*
       Pixel fonts look particularly good
       when the title is slightly oversized.
    */
}

.project-hero h1 span {
    color: var(--mcol);
}


/* Intro underneath title */

.project-lead {
    max-width: 760px;

    margin: 3rem 0 0;

    color: var(--text);

    font-size: 0.9rem;

    line-height: 2;
}


/* =========================================================
   VIDEO
========================================================= */

.project-media {
    margin-bottom: 7rem;
}

.media-header {
    position: relative;

    overflow: hidden;

    background: #000;

    border: 4px solid var(--surface);

    box-shadow:
        0 15px 40px var(--shadow);
}

.media-header video {
    display: block;

    width: 100%;
    height: auto;

    max-height: 720px;

    background: #000;
}

.media-caption {
    margin: 0.75rem 0 0;

    color: var(--text-muted);

    font-size: 0.55rem;
}


/* =========================================================
   SECTION STRUCTURE
========================================================= */

.project-section {
    display: grid;

    grid-template-columns: 80px minmax(0, 1fr);

    gap: 4rem;

    padding-top: 6rem;
    padding-bottom: 6rem;

    border-top: 2px solid var(--border-dark);
}

.section-label {
    align-self: start;

    position: sticky;
    top: 2rem;
}

.section-label span {
    display: block;

    margin-bottom: 0.5rem;

    color: var(--mcol);

    font-size: 0.7rem;
}

.section-label p {
    margin: 0;

    color: var(--text-muted);

    font-size: 0.55rem;

    line-height: 1.6;

    text-transform: uppercase;
}


/* =========================================================
   SECTION CONTENT
========================================================= */

.section-content {
    max-width: 900px;
    min-width: 0;
}

.section-content h2 {
    margin: 0 0 2rem;

    color: var(--mcol);

    font-size: clamp(
        1.8rem,
        4vw,
        3.5rem
    );

    font-weight: 200;

    line-height: 1.15;

    letter-spacing: -0.03em;
}

.section-content h3 {
    color: var(--mcol);
}

.section-content p {
    max-width: 760px;

    margin: 0 0 1.5rem;

    color: var(--text);

    font-size: 0.9rem;

    line-height: 2;
}

.section-content pre {
    max-width: 760px;


    color: var(--text);

    font-size: 1rem;

    line-height: 1;
    
}

.section-content strong {


    color: var(--text);

    font-size: 1.2rem;
    font-weight: 500;

    line-height: 1;
    
}

.section-content em {
        color: var(--mcol-dark);
    }


.section-intro {
    color: var(--text-light) !important;

    font-size: 0.9rem !important;

    line-height: 2 !important;
}


/* =========================================================
   TEXT COLUMNS
========================================================= */

.text-columns {
    display: grid;

    grid-template-columns: 1fr 1fr;

    gap: 3rem;
}

.text-columns p {
    margin: 0;
}

.inline-content{
    display:inline-flex;
    gap:70px;
}


/* =========================================================
   PROJECT STATS
========================================================= */

.project-stats {
    display: grid;

    grid-template-columns: repeat(4, 1fr);

    margin-top: 4rem;

    border-top: 2px solid var(--border);
    border-bottom: 2px solid var(--border);
}
.project-stats2 {
    display: grid;

    grid-template-columns: repeat(3, 1fr);

    margin-top: 4rem;

    border-top: 2px solid var(--border);
    border-bottom: 2px solid var(--border);
}
		

.project-stat {
    min-height: 130px;

    padding: 2rem 1.25rem;

    border-right: 1px solid var(--border);
}

.project-stat:last-child {
    border-right: none;
}

.project-stat strong {
    display: block;

    color: var(--mcol);

    font-size: 1.5rem;

    line-height: 1;
}

.project-stat span {
    display: block;

    margin-top: 1rem;

    color: var(--text-muted);

    font-size: 0.8rem;

    line-height: 1.6;

    text-transform: uppercase;
}


/* =========================================================
   CHALLENGE GRID
========================================================= */

.challenge-grid {
    display: grid;

    grid-template-columns: repeat(1, 1fr);

    gap: 1px;

    margin-top: 2rem;

    border: 2px solid var(--border-dark);

    background: var(--border-dark);
}

.challenge {
    min-height: 120px;

    padding: 1rem;

    background: var(--surface);

    
}

.challenge span {
    color: var(--mcol);

    font-size: 0.6rem;
}

.challenge h3 {
    margin: 1rem 0 0rem;

    color: var(--text-light);

    font-size: 0.9rem;

    line-height: 1.4;
}

.challenge p {
    margin: 0;

    color: var(--text-muted);

    font-size: 0.9rem;

    line-height: 1.8;
}


/* =========================================================
   ENTITY TYPES
========================================================= */
.image-display {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
}

.image-display img {
    height: 100px;
    width: auto;
    flex: 0 0 auto;
    object-fit: contain;
    display: block;
}

.image-scroller {
    width: 100%;
    max-width: 100%;

    overflow: hidden;

    padding: 1rem 0 1.5rem;
}

.image-track {
    display: flex;
    align-items: center;

    width: max-content;

    gap: 1rem;

    animation: image-scroll 30s linear infinite;
}

.image-track img {
    /* display: block; */

    height: 100px;
    width: auto;

    flex: 0 0 auto;

    object-fit: contain;
}


/* =========================================================
   AUTOMATIC SCROLL
========================================================= */

@keyframes image-scroll {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(
            calc(-50% - 0.5rem)
        );
    }
}


/* =========================================================
   ACCESSIBILITY
========================================================= */

@media (prefers-reduced-motion: reduce) {
    .image-track {
        animation: image-scroll 30s linear infinite;
    }
}

.entity-types {
    display: flex;

    flex-wrap: wrap;

    gap: 0.75rem;

    margin: 3rem 0;
}

.entity-types span {
    display: inline-block;

    padding: 0.6rem 0.9rem;

    background: var(--surface);

    border: 1px solid var(--border);

    color: var(--text);

    font-size: 0.8rem;

    line-height: 1.4;
}

.entity-types span em{

    color: var(--mcol);

}



/* =========================================================
   LINKS
========================================================= */

.project-links-section {
    padding-top: 6rem;

    border-top: 2px solid var(--border-dark);
}

.project-links {
    display: grid;

    grid-template-columns: 1fr 1fr;

    gap: 1rem;
}

.project-link-large {
    display: flex;

    align-items: center;
    justify-content: space-between;

    padding: 1.5rem 2rem;

    background: var(--surface);

    border: 2px solid var(--border);

    color: var(--text-light);

    font-size: 0.7rem;

    text-decoration: none;

    transition:
        background 0.15s ease,
        border-color 0.15s ease,
        color 0.15s ease;
}

.project-link-large:hover {
    background: var(--surface-light);

    border-color: var(--mcol);

    color: var(--mcol);
}

.project-link-large span:last-child {
    color: var(--mcol);

    font-size: 1rem;
}


/* =========================================================
   GENERAL LINKS
========================================================= */

.project-page a {
    transition:
        color 0.15s ease;
}

.project-page a:hover {
    color: var(--mcol);
}


/* =========================================================
   SELECTION
========================================================= */

::selection {
    background: var(--mcol);

    color: var(--background);
}


/* =========================================================
   SCROLLBAR
========================================================= */

::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--background);
}

::-webkit-scrollbar-thumb {
    background: var(--border);

    border: 2px solid var(--background);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--mcol);
}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 800px) {

    .container {
        width: min(
            calc(100% - 2rem),
            var(--content-width)
        );
    }


    /* Header */

    /* .header-content {
        width: calc(100% - 2rem);

        min-height: 80px;
    }

    .header-email {
        display: none;
    } */


    /* Hero */

    .project-hero {
        padding-top: 4rem;
        padding-bottom: 3rem;
    }

    /* .project-hero h1 {
        font-size: clamp(
            2.7rem,
            14vw,
            5rem
        );
    } */

    .project-lead {
        margin-top: 2rem;

        font-size: 0.7rem;

        line-height: 1.9;
    }


    /* Video */

    .project-media {
        margin-bottom: 4rem;
    }

    .media-header {
        border-width: 2px;
    }


    /* Sections */

    .project-section {
        grid-template-columns: 1fr;

        gap: 2rem;

        padding-top: 4rem;
        padding-bottom: 4rem;
    }

    .section-label {
        position: static;
    }

    

    


    /* Text */

    .text-columns {
        grid-template-columns: 1fr;

        gap: 0;
    }


    /* Stats */

    .project-stats {
        grid-template-columns: 1fr 1fr;
    }
    .project-stats2 {
        grid-template-columns: 1fr 1fr;
    }

    .project-stat {
        min-height: 110px;

        padding: 1.5rem 1rem;
    }

    .project-stat:nth-child(2) {
        border-right: none;
    }

    .project-stat:nth-child(-n + 2) {
        border-bottom: 1px solid var(--border);
    }


    /* Challenges */

    .challenge-grid {
        grid-template-columns: 1fr;
    }

    .challenge {
        min-height: auto;

        padding: 1.5rem;
    }


    /* Links */

    .project-links {
        grid-template-columns: 1fr;
    }
}


/* =========================================================
   VERY SMALL SCREENS
========================================================= */

@media (max-width: 450px) {

    body {
        font-size: 12px;
    }

    .brand-text {
        font-size: 0.8rem;
    }

    .brand-text-small {
        font-size: 0.45rem;
    }

    .logo {
        width: 42px;
        height: 42px;
    }

    .project-hero h1 {
        font-size: 2.5rem;
    }

    .inline-content{
    display:block;
    gap:70px;
}

    .project-stats {
        grid-template-columns: 1fr;
    }
    /* .project-stats2 {
        grid-template-columns: 1fr;
    } */

    .project-stat {
        border-right: none;

        border-bottom: 1px solid var(--border);
    }

    .project-stat:last-child {
        border-bottom: none;
    }
}