:root {

    /* accents */
    --primary-light: #E698BC;
    --primary-old: #943E65;
    --primary-accessible: #962f5e;
    --primary-accent: #833357;
    --primary-dark: #7A224A;

    --secondary-light: #FFFCF8;
    --secondary-accent: #FFF9F3;
    --secondary-dark: #FFEAD6;

    --tertiary-light: #EDE2FF;
    --tertiary-accent: #E0CEFF;
    --tertiary-dark: #9E82CF;

    /* neutral */
    --dark-text: #000000;
    --remain-dark-text: #000000;
    --light-background: #FFF9F3;
    --light-text: #FFF9F3;
    --dark-background: #962f5e;
    --black: #000000;

    /* status */
    --success-light:#A8E79B;
    --success-med: #65BE5B;
    --success-dark: #3C8C33;

    --error-light:#E98080;
    --error-med: #F45A5A;
    --error-dark: #C42D2D;

    --cutive: "Cutive", serif;
    --cantarell: "Cantarell", sans-serif;
    --cormorant-upright: "Cormorant Upright", serif;
}


/* DARK MODE */
@media (prefers-color-scheme: dark) {
    :root {
        --primary-accessible: #FFF9F3;

        --secondary-accent: #1B1A57;
        /* background / text should flip */
        --light-background: #1b1a57;
        --dark-background: #FFF9F3;

        --dark-text: #FFF9F3;
        --remain-dark-text: #000000;
        --light-text: #FFF9F3;
        --fuschia: #962f5e;

            /* accents */
    /* neutral */
    --dark-text: #FFF9F3;
    --light-background: #1B1A57;
    --light-text: #1B1A57;
    --black: #FFF9F3;

    /* status */
    --success-light:#A8E79B;

    --error:#ed9595;

        
    }

}



.cutive-regular {
    font-family: "Cutive", serif;
    font-weight: 400;
    font-style: normal;
}

.cormorant-upright-regular {
    font-family: "Cormorant Upright", serif;
    font-weight: 400;
    font-style: normal;
}

.cormorant-upright-medium {
    font-family: "Cormorant Upright", serif;
    font-weight: 500;
    font-style: normal;
}

.cormorant-upright-semibold {
    font-family: "Cormorant Upright", serif;
    font-weight: 600;
    font-style: normal;
}

.cantarell-regular {
    font-family: "Cantarell", sans-serif;
    font-weight: 400;
    font-style: normal;
}

html{
    min-height: 100vh;
}
body {
    background-color: var(--light-background);
    margin: 0;
    font-size: clamp(1rem, 2.5vw, 1.125rem);
    line-height: 1.6;
    position: relative;
    min-height: 100vh;
}


main {
    color: var(--dark-text);
}

figure {
    margin: 0;
}


/* Font Sizes */

h1 {
    font-family: var(--cutive);
    font-size: clamp(1.75rem, 3.5vw, 2.25rem);

}

h2 {
    font-family: var(--cutive);
    font-size: clamp(1.5rem, 3.5vw, 2rem);
}

h3 {
    font-family: var(--cormorant-upright);
    font-size: clamp(1.25rem, 2.5vw, 1.5rem);
    font-weight: 400;
}

h4 {
    font-family: var(--cantarell);
    font-size: clamp(1rem, 2.5vw, 1.25rem);
    font-weight: 400;
}

p, li {
    font-family: var(--cantarell);
    font-size: clamp(1rem, 2vw, 1.25rem);
    font-weight: 400;
    line-height: 1.6;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
    overflow-clip-margin: content-box;
    overflow: clip;
}

.skip-link {
    position: absolute;
    top: -3.5rem;
    left: 0;
    background: var(--dark-background);
    color: var(--light-text);
    font-size: clamp(1rem, 2vw, 1.15rem);
    padding: 0.5rem;
    z-index: 100;
    font-family: var(--cantarell);
    }

.skip-link:focus { 
    top: 0.5rem;
    left: 0.5rem;
    outline: 3px solid var(--primary-accessible);
    border-radius: 0rem 2rem 0rem 2rem;
    outline-offset: 5px;  
}


.skip-link-2 {
    position: absolute;
    right: 0rem;
    bottom: -0rem;
    background: var(--primary-accessible);
    color: var(--primary-accessible);
    font-size: clamp(1.25rem, 2vw, 1.15rem);
    padding: 0.5rem;
    font-family: var(--cantarell);
    z-index: 100;
}

.skip-link-2:focus {
    bottom: 0.5rem; 
    right: 0.5rem;
    outline: 3px solid var(--light-background);
    color: var(--primary-accessible);
    background-color: var(--light-background);
    border-radius: 0rem 2rem 0rem 2rem;
    outline-offset: 5px;
}

/* SECTIONS */

/* Intro Section */
.intro-section {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 3rem 3rem 3rem;
    gap: 2rem;
    max-width: 1200px;
    align-self: center;
    margin: 0 auto;
}

.intro-text {
    flex: 1;
}

.intro-image img {
    width: 100%;
    max-width: 400px;
    border-radius: 12px;
}

@media (max-width: 768px) {
    .intro-section {
        flex-direction: column;
        text-align: center;
    }
}


.cs-logo,
.cs-petes-logo {
    position: relative;
}

.cs-petes-logo {
    position: absolute;
    top: 0rem;
    right: 0rem;
    max-width: 40%;
}

/* .cs-petes-logo img{
    position: relative;
    bottom: 100%;
    left: 100%;
    width: 45%;
} */

.cs-petes-logo img {
    width: 100%;
    height: auto;
    display: block;
}
/* 
.cs-logo img,
.cs-petes-logo img {
    width: clamp(20rem, 15vw, 20rem);
} */


/* Nav Bar Layout */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 3rem 4rem;
    font-size: clamp(1.5rem, 4vw, 1.5rem); !important
}

.logo{
    max-width: 5rem;
    height: auto;
    display: block;
    position: sticky;
}

/* ---------- Responsive Navbar (No JS) ---------- */

/* hide checkbox */
.menu-toggle {
    display: none;
}

/* hamburger base */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 10px;
    z-index: 1001; /* keep above menu */
}

.hamburger span {
    width: 40px;
    height: 2px;
    background-color: var(--black);
    transition: all 0.3s ease;
    border-radius: 2px;
}

/* Default desktop menu */
.menu {
    list-style: none;
    display: flex;
    align-items: flex-end;
    gap: 1.5rem;
    font-size: 24px;
    font-size: clamp(1.5rem, 4vw, 1.5rem); !important
    padding: 0;
    margin: 0;
    color: var(--black);
}

.menu li {
    margin: auto;
}


/* Responsive adjustments */
@media (max-width: 768px) {
.hamburger {
    display: flex;
}

  /* Stack menu vertically when toggled */
.menu {
    position: absolute;
    top: 100px;
    right: 0;
    width: 100%;
    background-color: var(--secondary-accent);
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    z-index: 1000;
    color: var(--dark-text);
    transition: max-height 0.3s ease;
}

.menu.open {
    max-height: 100vh;
    padding: 12rem 0;
    margin-top: 1rem;
}

.hamburger {
    flex-direction: column;
    cursor: pointer;
    gap: 10px;
    z-index: 1001;
    background: none;
    border: none;
    padding: 0;
    margin: 0;
    width: 3rem;
}

.hamburger.open span:nth-child(1) {
    transform: rotate(45deg) translateY(8px) translateX(8px);
}

.hamburger.open span:nth-child(2) {
    opacity: 0;
}

.hamburger.open span:nth-child(3) {
    transform: rotate(-45deg) translateY(-8px) translateX(8px);
}

.menu-image {
    display: block;
    width: 100%;
    text-align: center;
}

.menu-image img {
    max-width: 120px;
    border-radius: 8px;
    margin-top: 1rem;
}
}


.menu a {
    text-decoration: none;
    color: var(--black);
    font-family: var(--cormorant-upright);
    font-weight: 400;
}

.menu a:hover,
.menu a:focus-visible {
    color: var(--primary-accessible);
    transform: scale(1.1);
}



/* Case Study Cards */
.case-study-section {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem 4rem;
}


.case-study-card {
    position: relative;
    width: 100%;
    max-width: 1000px;
    /* aspect-ratio: 1200 / 700; */
    border: 1px solid #000000;
    border-radius: 30px;
    box-shadow: 0 6px 16px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-align: center;
    text-decoration: none;
    height: auto;
}




.inner-case-study-image {
    position: relative;
    width: 100%;
    max-width: 1000px;
    border: 1px solid #000000;
    border-radius: 30px;
    box-shadow: 0 6px 16px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    padding: 1rem 2.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-align: center;
    text-decoration: none;
}



#petes-little-lunch-box {
        background: linear-gradient(180deg, #FFEEDC 31%, #C73715 97%);
}

#cvs-microinteractions {
        background: linear-gradient(164deg, #FFFFFF 25%, #CC0000 97%);
}

#sunset-cove {
        background: linear-gradient(180deg, #FF7699 0%, #ACB0E8 97%);
}

/* Hover enlarge effect */
.case-study-card:hover {
    transform: scale(1.03);
    box-shadow: 0 12px 30px rgba(0,0,0,0.15);
}

/* Info section: text + logo */
.cs-card-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    flex-wrap: wrap;
    /* margin-bottom: 2rem; */
}

.cs-text {
    display: block;
    color: var(--remain-dark-text);
    text-align: left;
    margin: 2%;
}

.cs-text h2,
.cs-text h3 {
    margin: 0;
}




.cs-featured-image {
    width: 100%;
    display: flex;
    justify-content: center;
}

.cs-featured-image img {
    width: 100%;
    max-width: 700px;
    transition: transform 0.4s ease;

}


/* Slight zoom of image on hover */
.case-study-card:hover .cs-featured-image img {
    transform: scale(1.05);
}


/* Pill tags */

.cs-pill-tags {
    display: flex;
    flex-direction: column;
    margin-top: auto;
    position: absolute;
    top: 80%;
    /* position: static;
    margin-top: 1rem; */
    right: 5%;
    flex-wrap: wrap;
    gap: 0.25rem;
}


.cs-pill-tags li {
    font-size: clamp(0.75rem, 2vw, 0.95rem);
    padding: clamp(0.25rem, 1vw, 0.5rem) clamp(0.6rem, 2vw, 1rem);
    white-space: nowrap;
    background: var(--light-background);
    border: 1px solid var(--dark-text);
    border-radius: 999px;
    padding: 0.25rem 0.5rem; 
    font-family: "Cormorant Upright", sans-serif;
    color: var(--black);
    transition: all 0.3s ease;
    list-style-type: none;
}


.cs-pill-tags li:hover,
.cs-pill-tags li:focus-visible {
    background: var(--fuschia);
    color: var(--dark-background);
    border: 1px solid var(--primary-accessible);

}


/* FOOTER */
footer {
    position: relative;
    color: var(--light-text);
    background-color: var(--primary-accessible);
    padding: 5rem 4rem 2rem 4rem;
    margin-top: 2rem;
}

/* .footer-message {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
} */

.footer-message h2{
    margin: 0;
}

.connection {
    display: flex;
    justify-content: space-between;
}

.footer-links {
    display: flex;
    justify-content: space-between;
    flex-direction: column;
    align-items: flex-end;
    font-family: var(--cormorant-upright);
    font-size: clamp(1.25rem, 2.5vw, 1.5rem);
}

.footer-links a:hover {
    transform: scale(1);
}

.icons {
    display: flex;
    align-items: center;
    text-decoration: none;
}
.links {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--secondary-accent);
}

.links a:hover {
    color: var(--primary-accessible);
}

.links h4{
    margin: 0;
}



.copyright {
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: var(--cantarell);
    padding-top: 2rem;
}
















/* ---------- Responsive Tweaks ---------- */
@media (max-width: 1200px) {
    .case-study-card {
        padding: 2rem;
    }
    .cs-pill-tags {
        position: static;
        max-width: 100%;
        margin-top: 1rem;
    }
    .cs-pill-tags ul {
        display: flex;
        justify-content: center;
        gap: 0.75rem;
        padding: 0;
        margin: 0;
        list-style: none;
    }
    .cs-pill-tags span {
        font-size: 0.85rem;
        padding: 0.4rem 1rem;
    }
}

@media (max-width: 900px) {
    /* .cs-card-info {
        justify-content: center;
    } */

    .cs-text h1 {
        font-size: 1.5rem;
    }

    .cs-text h3 {
        font-size: 1rem;
        max-width: 100%;
    }


    .cs-logo img {
        width: 5rem;
    }

    .cs-logo  {
        /* display: flex;
        justify-content: center; */
        margin: auto !important;
    }


    .cs-featured-image img {
        width: 90%;
    }
}

@media (max-width: 600px) {
    h1 {
        font-size: 1.5rem;
    }

    .case-study-card {
        padding: 1.5rem;
        height: auto;
    }

    .cs-text h2 {
        font-size: 1.3rem;
    }

    .cs-text h3 {
        font-size: 1rem;
    }

    .cs-pill-tags ul {
        display: flex;
        flex-direction: column;
        gap: 0.2rem;
    }

    .connection {
        display: flex;
        flex-direction: column;
    }
    .footer-links {
        flex-direction: row;
    }

    .case-study-section {
        height: 100%;
    }
    .cs-featured-image img {
        max-width: 100%;
    }

    .menu a {
        font-size: 1.2rem;
    }
}


@media (max-width: 768px) {
    .case-study-card {
    max-width: 90%;
    }
}

@media (max-width: 480px) {
    .case-study-card {
    max-width: 100%;
    }
}



@media (prefers-reduced-motion: reduce) {
    * {
        transition: none !important;
    }
}


form{
    display: flex;
}

label {
    font-family: var(--cutive);
    font-size: clamp(1.75rem, 3.5vw, 2.25rem);
}



/* FORM */

    #form-feedback {
    margin-top: 1rem;
    font-weight: bold;
    }

    input[aria-invalid="true"],
    textarea[aria-invalid="true"] {
    border: 2px solid red;
    }


    button {
        background-color: var(--primary-accessible);
        color: var(--secondary-accent);
        border-color: var(--secondary-accent);
        font-family: var(--cantarell);
        border: 2px solid var(--primary-accessible);
        border-radius: 3rem;
        padding: 0.75rem;
        display: inline-block;
        text-align: center;
        transition: transform 0.3s ease;
        width: 15rem;
        font-size: clamp(0.75rem, 3.5vw, 1rem);
        align-items: center;
        margin: 0.25rem auto;
    }


    .button-link {
        display: inline-block;
        padding: 10px 20px;
        margin: 10px;
        color: #fff;
        background-color: var(--fuchsia);
        text-decoration: none;
        border-radius: 30px;
        font-size: 18px;
        font-weight: bold;
        text-align: center;
        transition: transform 0.3s ease;
        outline: none;
    }

    button:hover {
        background-color: var(--secondary-accent);
        border-radius: 30px;
        color: var(--primary-accessible);
        transform: scale(1.03);
        transition: transform 0.4s ease, box-shadow 0.4s ease;
    }

    button:active {
        transform: scale(1.03);
    }


    #contact-main {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    .message{
        font-family: var(--cutive);
        font-size: clamp(1.25rem, 3.5vw, 1.5rem);
        margin: 0;
    }

    form{
        display: flex;
    }

    .form-fields {
        margin: 0.2rem;
    }

    label {
        font-family: var(--cantarell);
        font-size: clamp(1rem, 3.5vw, 1.25rem);
        display: flex;
        flex-direction: column;
        margin: 0.25rem;
        max-width: 30rem;
    }


    input[aria-invalid="true"],
    textarea[aria-invalid="true"] {
    border: 2px solid var(--error-dark); /* optional, highlights the input */
    }

    p[role="alert"] {
        color: var(--error);       /* red text for errors */
        margin-top: 0.25em;
        margin-bottom: 1em;
        font-family: var(--cantarell);
        font-size: clamp(0.5rem, 3.5vw, 0.75rem);
        margin-top: -0.5rem;
        display: block;
        min-height: 1.25rem;
        margin:0.25rem;

    }

    fieldset {
        border: none;
        display: flex;
        flex-direction: column;
        width: 30rem;
    }

    @media (max-width: 600px) {
            fieldset {
                border: none;
                display: flex;
                flex-direction: column;
                width: auto;
            }
    }

    input {
        max-width: 30rem;
        font-family: var(--cantarell);
        border: 0.5px solid #000000;
        border-radius: 0.5rem;
    }

    textarea{
        border: 0.5px solid #000000;
        border-radius: 0.75rem;
    }

    .sr-only {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }


    .error-message{
        margin: auto;
        color: var(--error);       /* red text for errors */

    }



.gallery {
    padding: 0 4rem;
}

/* Intro section */

.gallery-intro {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    padding: 2rem;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.gallery-text {
    align-self: center;
    text-align: center;
}

.gallery-intro img{
    border-radius: 2rem;
    width: 50%;
    height: auto;
    margin: auto;
}

figcaption{
    font-family: var(--cantarell);
}

/* Masonry */

.masonry-gallery {
    column-count: 3;
    column-gap: 20px;
}

.masonry-gallery img {
    width: 100%;
    margin-bottom: 15px;
    display: block;
    break-inside: avoid;
}
/* Figure container */
.gallery-item {
    position: relative;
    overflow: hidden;
    cursor: default;
    display: inline-block;
}

/* Image */
.gallery-item img {
    width: 100%;
    height: auto;
    display: block;
    transition: filter 0.3s ease, transform 0.3s ease;
    border-radius: 0; /* remove rounded corners */
}

/* Caption overlay */
.gallery-item figcaption {
    position: absolute;
    top: 0; /* cover the whole image */
    left: 0;
    width: 100%;
    height: 100%;
    display: flex; /* center text */
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.2); /* dim overlay */
    color: white;
    font-size: 1.2rem;
    font-weight: 500;
    text-align: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* Hover & focus effects */
.gallery-item:hover img,
.gallery-item:focus img {
    filter: brightness(70%);
}

.gallery-item:hover figcaption,
.gallery-item:focus figcaption {
    opacity: 1;
}

@media (max-width: 600px) {

    .gallery {
        padding: 1rem 2rem;
    }

    .masonry-gallery {
        column-count: 1;
    }

}




/* CASE STUDY */

.main-content {
    display: flex;
    justify-content: center;
}

.case-study {
    padding: 0rem 4rem;
}


/* CASE STUDIES */

.case-study {
    padding: 0rem 4rem;
    color: var(--dark-text);
}

.case-study-content {
    padding: 0rem 14rem;
    color: var(--dark-text);

}

.cs-intro {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    padding: 2rem 6rem 0rem 6rem;
}

#cs-overview {
    width: 60%;
}

.cs-specs {
    width: 50%;
    margin-top: 0;
    margin-bottom: 10px;
    padding: 2rem 4rem;

    h3{
        margin-bottom: 0;
    }
}

.big-title {
    text-align: center;
    margin: 3rem 0rem 0rem 0rem;
}

.cs-centered-images {
    display: flex;
    justify-content: center;
}


.cs-specs h5 {
    margin-top: 0;
    margin-bottom: 5px;
}


.cs-specs p {
    margin-top: 0;
    margin-bottom: 30px;
}

.case-study-nav{
    font-family: var(--cormorant-upright);
    font-weight: bold;
    text-align: center;
    position: sticky;
    top: 0;
    background-color: var(--cream);
    color: #000000;
    padding: 20px 0px;
    /* box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.1); */
}

.case-study-nav a{
    font-size: 25px;
    font-weight: bold;
    text-decoration: none;
    color: #000000;
    margin: 15px;
}

.case-study-nav a.active{
    color: var(--fuchsia);
}


.project-centered{
    display: grid;
}

.project-centered img{
    max-width: 100%;
    margin: auto;
}

.project-grid img{
    width: 100%;
    padding: 20px;
}

@media  (max-width: 1000px) {
    .cs-intro{
        display: flex;
        flex-direction: column;
        padding: 0;
    }
    .cs-specs{
        padding: 0;
        margin: auto;
    }
}


.hero-image img{
    border-radius: 1rem;
}



.button-container {
    text-align: center; 
}

.button-link {
    display: inline-block;
    padding: 10px 20px;
    margin: 10px;
    color: var(--light-text);
    background-color: var(--primary-accessible);
    text-decoration: none;
    border-radius: 30px;
    font-size: 18px;
    font-weight: bold;
    font-family: var(--cantarell);
    text-align: center;
    border: 2px solid transparent;
    transition: transform 0.3s ease;
}

.button-link:hover {
    background-color: var(--light-background);
    border: 2px solid var(--primary-accessible);
    border-radius: 30px;
    color: var(--primary-accessible);
    transform: scale(1.03);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.button-link:active {
    transform: scale(1.03);
}

.side-by-side {
    display: flex;
}
.side-by-side article{
    padding: 0.5rem;
}

.image img{
    border: 2px solid var(--primary-accessible);
    border-radius: 1rem;
}

figcaption{
    text-align: center;
}

@media (max-width:1200px){
    .side-by-side {
        display: flex;
        flex-direction: column;
    }  
}


/* ABOUT PAGE */

.two-column{
    display: flex;
    margin:  15% 0;
    max-width: 70%;
    margin: 50px auto;
}

.info-stack{
    margin: 0 5%;
    display: flex;
    align-items: center;
    flex-direction: column;
    text-align: center;
    width: fit-content;
}


.resume {
    padding: 2rem 4rem;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    gap: 2rem;
}

.resume-left-section {
    display: flex;
    flex-direction: column;
    width: 80%;
    background-color: var(--light-background);
    border: 1px solid var(--dark-background);
    border-radius: 30px;
    padding: 2rem;
}

.resume-right-section {
    display: flex;
    flex-direction: column;
    width: 60%;
    background-color: var(--light-background);
    border: 1px solid var(--dark-background);
    border-radius: 30px;
    padding: 2rem;
}

.me {
    height: 100%;
}

@media (max-width: 1000px){
    .two-column{
        display: flex;
        flex-direction: column;
        width: auto;
    }
    .resume{
        display: flex;
        flex-direction: column;
    }
    .resume-left-section, .resume-right-section {
        width:90%;
    }
}

.middle {
    display: flex;
    justify-content: space-around;
}