
/* =========================================
   YOD WORK PAGE
========================================= */

.work-page {
    --w-dark: #171522;
    --w-deep: #242132;
    --w-violet: #8B5CF6;
    --w-lavender: #A78BFA;
    --w-soft: #E9E3F5;
    --w-white: #F8F7FA;
    --w-muted: #777382;

    background: var(--w-white);
    color: var(--w-dark);
    font-family: 'DM Sans', sans-serif;
    overflow-x: hidden;
}

.work-page * {
    box-sizing: border-box;
}

.work-page a {
    text-decoration: none;
    color: inherit;
}

.work-container {
    width: min(1160px, calc(100% - 100px));
    margin: 0 auto;
}


/* =========================================
   NAVIGATION
========================================= */

.work-header {
    position: relative;
    z-index: 100;
    background: var(--w-dark);
    border-bottom: 1px solid rgba(255,255,255,0.09);
}

.work-nav-wrap {
    width: min(1320px, calc(100% - 100px));
    min-height: 84px;
    margin: auto;

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

.work-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    color: white;
}

.work-brand-symbol {
    width: 43px;
    height: 43px;

    display: grid;
    place-items: center;

    border: 1px solid rgba(167,139,250,0.65);
    border-radius: 10px;

    color: var(--w-lavender);

    font-family: 'Space Grotesk', sans-serif;
    font-size: 15px;
    font-weight: 700;
}

.work-brand-name {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.1px;
}

.work-nav {
    display: flex;
    align-items: center;
    gap: 32px;
}

.work-nav > a {
    color: rgba(255,255,255,0.7);
    font-size: 13px;
    transition: color .25s ease;
}

.work-nav > a:hover,
.work-nav > a.active {
    color: white;
}

.work-nav .work-nav-contact {
    padding: 13px 17px;
    background: var(--w-violet);
    color: white;
    border-radius: 5px;
}

.work-nav-contact span {
    margin-left: 8px;
}

.work-menu-toggle {
    display: none;
    background: none;
    border: 0;
    cursor: pointer;
}


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

.work-hero {
    min-height: 650px;
    position: relative;
    overflow: hidden;

    background:
        radial-gradient(
            ellipse at 82% 40%,
            rgba(139,92,246,0.24),
            transparent 38%
        ),
        linear-gradient(120deg, #171522, #242132);

    color: white;
}

.work-hero::before {
    content: "";
    position: absolute;
    inset: 0;

    background-image:
        linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);

    background-size: 70px 70px;

    mask-image: linear-gradient(to bottom, black, transparent);
}

.work-hero-glow {
    position: absolute;
    width: 450px;
    height: 450px;

    right: -130px;
    top: 90px;

    border-radius: 50%;
    background: rgba(139,92,246,0.17);
    filter: blur(100px);

    animation: workGlow 8s ease-in-out infinite alternate;
}

.work-hero-inner {
    position: relative;
    z-index: 2;

    padding-top: 135px;
    padding-bottom: 50px;
}

.work-eyebrow,
.work-section-label {
    font-size: 11px;
    letter-spacing: 2.5px;
    font-weight: 700;
    color: var(--w-lavender);
}

.work-hero h1 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(52px, 7vw, 88px);
    line-height: 1.06;
    letter-spacing: -4px;
    font-weight: 500;

    margin: 30px 0;
}

.work-hero h1 span {
    color: var(--w-lavender);
}

.work-hero-description {
    max-width: 560px;

    color: rgba(255,255,255,0.65);
    font-size: 15px;
    line-height: 1.9;
}

.work-explore-link {
    display: inline-flex;
    gap: 16px;

    margin-top: 35px;
    padding-bottom: 10px;

    border-bottom: 1px solid var(--w-lavender);

    color: white;
    font-size: 13px;
}

.work-explore-link span {
    color: var(--w-lavender);
}

.work-hero-bottom {
    display: flex;
    gap: 36px;

    margin-top: 105px;
    padding-top: 25px;

    border-top: 1px solid rgba(255,255,255,0.12);
}

.work-hero-bottom span {
    font-size: 10px;
    letter-spacing: 2px;
    color: rgba(255,255,255,0.45);
}


/* =========================================
   INTRODUCTION
========================================= */

.work-intro {
    padding: 105px 0;
    background: var(--w-soft);
}

.work-intro-inner {
    display: grid;
    grid-template-columns: .7fr 1.3fr;
    gap: 60px;
}

.work-intro-copy h2 {
    max-width: 720px;

    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(34px, 4vw, 49px);
    line-height: 1.2;
    font-weight: 500;
    letter-spacing: -1.8px;

    margin: 0 0 25px;
}

.work-intro-copy p {
    max-width: 620px;

    color: #696573;
    font-size: 14px;
    line-height: 1.9;
}


/* =========================================
   PROJECT SECTIONS
========================================= */

.work-projects {
    background: var(--w-white);
}

.work-project {
    padding: 115px 0;
    border-bottom: 1px solid #e3e0e8;
}

.project-layout {
    display: grid;
    grid-template-columns: 1.12fr .88fr;
    align-items: center;
    gap: 75px;
}


/* REVERSE SECOND PROJECT */

.project-reverse .project-layout {
    grid-template-columns: .88fr 1.12fr;
}

.project-reverse .project-visual {
    order: 2;
}

.project-reverse .project-information {
    order: 1;
}


/* =========================================
   BROWSER MOCKUP
========================================= */

.project-browser {
    position: relative;

    overflow: hidden;

    border: 1px solid #ded9e9;
    border-radius: 12px;

    background: #fff;

    box-shadow:
        0 30px 80px rgba(31,24,54,0.13),
        0 5px 15px rgba(31,24,54,0.05);

    transition:
        transform .55s cubic-bezier(.2,.7,.2,1),
        box-shadow .55s ease;
}

.project-visual:hover .project-browser {
    transform: translateY(-7px);
    box-shadow:
        0 40px 90px rgba(31,24,54,0.17),
        0 8px 20px rgba(31,24,54,0.07);
}

.browser-bar {
    height: 49px;

    display: flex;
    align-items: center;
    gap: 14px;

    padding: 0 15px;

    background: #f1eff5;
    border-bottom: 1px solid #e5e1eb;
}

.browser-dots {
    display: flex;
    gap: 5px;
    flex-shrink: 0;
}

.browser-dots span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #c7c2cf;
}

.browser-dots span:first-child {
    background: #d58d96;
}

.browser-dots span:nth-child(2) {
    background: #d9bd7d;
}

.browser-dots span:nth-child(3) {
    background: #8dbd9c;
}

.browser-address {
    flex: 1;
    min-width: 0;

    padding: 7px 12px;

    border-radius: 4px;
    background: white;

    font-size: 10px;
    color: #85808e;

    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.browser-open {
    color: var(--w-violet);
    font-size: 18px;
    font-weight: 700;
}


/* LIVE PREVIEW */

.live-preview {
    height: 410px;
    position: relative;
    overflow: hidden;
    background: #eae7ef;
}

.live-preview iframe {
    display: block;
    width: 100%;
    height: 100%;

    border: 0;
    background: white;
}

/* Fallback remains available if the remote
   website prevents iframe embedding. */

.preview-fallback {
    position: absolute;
    inset: 0;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    padding: 25px;

    background:
        radial-gradient(
            circle at 50% 35%,
            rgba(139,92,246,0.15),
            transparent 45%
        ),
        #242132;

    color: white;
    text-align: center;

    opacity: 0;
    pointer-events: none;

    transition: opacity .3s ease;
}

.preview-fallback span {
    color: var(--w-lavender);
    font-family: 'Space Grotesk', sans-serif;
    font-size: 17px;
    font-weight: 700;
    letter-spacing: 2px;
}

.preview-fallback p {
    max-width: 260px;
    margin: 15px 0;

    color: rgba(255,255,255,.65);
    font-size: 12px;
    line-height: 1.7;
}

.preview-fallback a {
    color: white;
    border-bottom: 1px solid var(--w-lavender);
    padding-bottom: 7px;
    font-size: 12px;
}


/* Show fallback when iframe is detected as
   inaccessible by the script. */

.live-preview.preview-blocked .preview-fallback {
    opacity: 1;
    pointer-events: auto;
}

.project-visual-caption {
    display: flex;
    justify-content: space-between;

    margin-top: 17px;

    color: #928d9b;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1.6px;
}


/* =========================================
   PROJECT INFORMATION
========================================= */

.project-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;

    color: var(--w-violet);

    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.5px;
}

.project-type {
    color: #85808e;
}

.project-information h2 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(36px, 4vw, 52px);
    line-height: 1.1;
    letter-spacing: -2px;
    font-weight: 600;

    margin: 27px 0 15px;
}

.project-information h2 span {
    color: var(--w-violet);
}

.project-information h3 {
    max-width: 440px;

    font-family: 'Space Grotesk', sans-serif;
    font-size: 20px;
    font-weight: 500;
    line-height: 1.4;

    margin: 0 0 20px;
}

.project-description {
    color: #777382;
    font-size: 13px;
    line-height: 1.9;
    max-width: 450px;
}

.project-deliverables {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;

    margin-top: 27px;
}

.project-deliverables span {
    padding: 9px 12px;

    border: 1px solid #e1dce9;
    border-radius: 4px;

    color: #625e6c;
    font-size: 10px;
}

.project-tech {
    margin-top: 30px;
    padding-top: 22px;
    border-top: 1px solid #e1dce9;
}

.project-tech > span {
    color: #9993a0;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1.6px;
}

.project-tech p {
    color: #5c5866;
    font-size: 11px;
    line-height: 1.8;
    margin: 9px 0 0;
}

.project-visit {
    display: inline-flex;
    align-items: center;
    gap: 24px;

    margin-top: 30px;
    padding-bottom: 10px;

    border-bottom: 1px solid var(--w-violet);

    color: var(--w-violet);
    font-size: 13px;
    font-weight: 700;

    transition: gap .25s ease;
}

.project-visit:hover {
    gap: 34px;
}

.project-visit span {
    font-size: 17px;
}


/* =========================================
   TECHNOLOGY SECTION
========================================= */

.work-technology {
    padding: 115px 0;
    background: var(--w-graphite);
    color: white;
}

.technology-inner {
    display: grid;
    grid-template-columns: .8fr 1.2fr;
    gap: 70px;
}

.technology-heading h2 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(36px, 4vw, 49px);
    font-weight: 500;
    line-height: 1.2;
    letter-spacing: -1.7px;
    margin: 25px 0 0;
}

.technology-content > p {
    max-width: 530px;

    color: rgba(255,255,255,.58);
    font-size: 14px;
    line-height: 1.9;

    margin: 0 0 30px;
}

.technology-list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.technology-list span {
    padding: 12px 16px;

    border: 1px solid rgba(255,255,255,.16);
    border-radius: 4px;

    color: rgba(255,255,255,.8);
    font-size: 11px;

    transition:
        background .25s ease,
        border-color .25s ease,
        transform .25s ease;
}

.technology-list span:hover {
    background: rgba(139,92,246,.16);
    border-color: var(--w-violet);
    transform: translateY(-3px);
}


/* =========================================
   CTA
========================================= */

.work-cta {
    padding: 125px 0;

    background:
        radial-gradient(
            circle at 80% 20%,
            rgba(139,92,246,0.23),
            transparent 35%
        ),
        var(--w-deep);

    color: white;
    text-align: center;
}

.work-cta-inner h2 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(43px, 5.5vw, 70px);
    font-weight: 500;
    line-height: 1.12;
    letter-spacing: -2.5px;

    margin: 27px 0;
}

.work-cta-inner h2 span {
    color: var(--w-lavender);
}

.work-cta-inner > p {
    max-width: 490px;
    margin: 0 auto 35px;

    color: rgba(255,255,255,.6);
    font-size: 14px;
    line-height: 1.8;
}

.work-cta-button {
    display: inline-flex;
    align-items: center;
    gap: 24px;

    padding: 17px 24px;

    background: var(--w-violet);
    border-radius: 5px;

    color: white;
    font-size: 13px;
    font-weight: 700;

    transition:
        transform .25s ease,
        background .25s ease;
}

.work-cta-button:hover {
    transform: translateY(-4px);
    background: #7545df;
}


/* =========================================
   FOOTER
========================================= */

.work-footer {
    background: #12111a;
    color: white;
    padding: 55px 0 25px;
}

.work-footer-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 25px;
}

.work-footer-top > p {
    color: rgba(255,255,255,.48);
    font-size: 13px;
}

.work-footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 28px;

    padding: 35px 0;
}

.work-footer-links a {
    color: rgba(255,255,255,.62);
    font-size: 12px;
    transition: color .2s ease;
}

.work-footer-links a:hover {
    color: var(--w-lavender);
}

.work-footer-bottom {
    display: flex;
    justify-content: space-between;
    gap: 20px;

    padding-top: 22px;
    border-top: 1px solid rgba(255,255,255,.12);

    color: rgba(255,255,255,.38);
    font-size: 10px;
}


/* =========================================
   SCROLL REVEAL
========================================= */

.work-page .reveal {
    opacity: 0;
    transform: translateY(25px);

    transition:
        opacity .8s ease,
        transform .8s cubic-bezier(.2,.7,.2,1);
}

.work-page .reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

@keyframes workGlow {
    from {
        transform: translate(0,0) scale(1);
    }

    to {
        transform: translate(-40px,30px) scale(1.15);
    }
}


/* =========================================
   TABLET
========================================= */

@media (max-width: 950px) {

    .work-container {
        width: min(100% - 60px, 760px);
    }

    .work-nav-wrap {
        width: calc(100% - 60px);
    }

    .work-nav {
        gap: 18px;
    }

    .project-layout,
    .project-reverse .project-layout {
        grid-template-columns: 1fr 1fr;
        gap: 35px;
    }

    .live-preview {
        height: 330px;
    }

    .project-information h2 {
        font-size: 37px;
    }

}


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

@media (max-width: 760px) {

    .work-nav-wrap {
        min-height: 75px;
    }

    .work-menu-toggle {
        display: flex;
        flex-direction: column;
        gap: 6px;
        padding: 10px;
    }

    .work-menu-toggle span {
        width: 25px;
        height: 2px;
        background: white;
        transition: transform .25s ease;
    }

    .work-menu-toggle.open span:first-child {
        transform: translateY(4px) rotate(45deg);
    }

    .work-menu-toggle.open span:last-child {
        transform: translateY(-4px) rotate(-45deg);
    }

    .work-nav {
        display: none;

        position: absolute;
        top: 75px;
        left: 0;
        right: 0;

        padding: 25px 30px 30px;

        background: var(--w-dark);

        flex-direction: column;
        align-items: stretch;
        gap: 23px;

        border-top: 1px solid rgba(255,255,255,.1);
    }

    .work-nav.open {
        display: flex;
    }

    .work-nav > a {
        font-size: 14px;
    }

    .work-nav .work-nav-contact {
        text-align: center;
    }

}


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

@media (max-width: 600px) {

    .work-container {
        width: calc(100% - 40px);
    }

    .work-nav-wrap {
        width: calc(100% - 40px);
    }

    .work-brand-name {
        font-size: 10px;
    }

    .work-hero {
        min-height: auto;
    }

    .work-hero-inner {
        padding-top: 90px;
        padding-bottom: 35px;
    }

    .work-hero h1 {
        font-size: clamp(45px, 11vw, 62px);
        letter-spacing: -2.5px;
    }

    .work-hero-description {
        font-size: 14px;
    }

    .work-hero-bottom {
        flex-wrap: wrap;
        gap: 17px;
        margin-top: 75px;
    }

    .work-hero-bottom span {
        font-size: 9px;
    }

    .work-intro,
    .work-project,
    .work-technology {
        padding: 80px 0;
    }

    .work-intro-inner {
        grid-template-columns: 1fr;
        gap: 25px;
    }

    .work-intro-copy h2 {
        font-size: 35px;
    }

    .project-layout,
    .project-reverse .project-layout {
        grid-template-columns: 1fr;
        gap: 35px;
    }

    .project-reverse .project-visual,
    .project-reverse .project-information {
        order: initial;
    }

    .live-preview {
        height: 320px;
    }

    .project-information h2 {
        font-size: 39px;
    }

    .project-information h3 {
        font-size: 19px;
    }

    .project-description {
        font-size: 13px;
    }

    .technology-inner {
        grid-template-columns: 1fr;
        gap: 35px;
    }

    .technology-heading h2 {
        font-size: 39px;
    }

    .work-cta {
        padding: 90px 0;
    }

    .work-cta-inner h2 {
        font-size: 44px;
        letter-spacing: -1.5px;
    }

    .work-footer-top {
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
    }

    .work-footer-links {
        gap: 18px;
    }

    .work-footer-bottom {
        flex-direction: column;
        gap: 10px;
    }

}


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

@media (prefers-reduced-motion: reduce) {

    .work-page *,
    .work-page *::before,
    .work-page *::after {
        animation-duration: .01ms !important;
        transition-duration: .01ms !important;
        scroll-behavior: auto !important;
    }

    .work-page .reveal {
        opacity: 1;
        transform: none;
    }

}
