/* ============================================
   nordwind. creative studio
   ============================================ */

/* Clash Display — hero slogan (desktop) */
@import url('https://api.fontshare.com/v2/css?f[]=clash-display@700,800&display=swap');

:root {
    --bg: #0c0c0c;
    --bg-light: #111111;
    --text: #ffffff;
    --text-muted: #777777;
    --accent: #de7a22;
    --teal: #1a5c5e;
    --teal-dark: #0f3d3f;
    --font: 'Inter', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg);
    color: var(--text);
    font-family: var(--font);
    overflow-x: hidden;
    line-height: 1.6;
}

::selection {
    background: var(--accent);
    color: var(--bg);
}

/* ---- Typography ---- */
h1, h2, h3 {
    font-weight: 700;
    line-height: 1.1;
}

h2 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    letter-spacing: -0.03em;
}

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

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

.section-label {
    display: inline-block;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

/* ---- Section base ---- */
.section {
    position: relative;
    min-height: 100vh;
}

/* ============================================
   NAVBAR
   ============================================ */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.5rem 3rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    mix-blend-mode: difference;
}

.logo {
    font-weight: 800;
    font-size: 1.1rem;
    letter-spacing: 0.05em;
    color: var(--text);
    text-decoration: none;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
}

.nav-links a {
    color: var(--text);
    text-decoration: none;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 400;
    transition: opacity 0.3s;
}

.nav-links a:hover {
    opacity: 0.6;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    width: 28px;
    height: 20px;
    position: relative;
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--text);
    position: absolute;
    left: 0;
    transition: all 0.3s;
}

.menu-toggle span:first-child {
    top: 4px;
}

.menu-toggle span:last-child {
    bottom: 4px;
}

.menu-toggle.active span:first-child {
    top: 50%;
    transform: translateY(-50%) rotate(45deg);
}

.menu-toggle.active span:last-child {
    bottom: 50%;
    transform: translateY(50%) rotate(-45deg);
}

/* Mobile menu overlay */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: var(--bg);
    z-index: 999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s;
}

.mobile-menu.active {
    opacity: 1;
    pointer-events: all;
}

.mobile-menu a {
    color: var(--text);
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

/* Fixed hero background — dark backdrop behind shrinking hero image */
.hero-bg-fixed {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    background: var(--bg);
    z-index: 0;
}

/* ============================================
   SEITE 1: HERO
   Desktop: image shrinks + desaturates, slogan fades in
   Mobile:  inset frame recession with "nordwind." title
   ============================================ */
.hero-section {
    height: 200vh;
    position: relative;
}

.hero-sticky {
    position: sticky;
    top: 0;
    width: 100%;
    height: 100vh;
    z-index: 1;
    overflow: hidden;
}

/* --- Desktop: fullscreen image, GSAP shrinks it --- */
.hero-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background-color: #1a1410;
    background-size: cover;
    background-position: center;
    will-change: transform, filter, border-radius;
    transform-origin: center center;
    z-index: 1;
}

/* Slogan sits BEHIND the image (z-index 1) — revealed as image shrinks */
.hero-slogan-track {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3;
    pointer-events: none;
    opacity: 0;
}

.hero-slogan {
    font-family: 'Clash Display', var(--font);
    font-size: clamp(2.5rem, 8vw, 7rem);
    font-weight: 700;
    letter-spacing: -0.04em;
    line-height: 1.05;
    text-align: center;
}

.slogan-line {
    display: block;
}

/* Mobile-only title — hidden on desktop */
.hero-title {
    display: none;
}

/* Mobile-only word-by-word hero — hidden on desktop */
.hero-words {
    display: none;
}

.hero-word {
    display: none;
}

/* ============================================
   SEITE 2: PROJECTS (Accordion)
   ============================================ */
.projects-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 6rem 0;
    min-height: 100vh;
    background: var(--bg);
    position: relative;
    z-index: 1;
}

.section-header {
    text-align: center;
    margin-bottom: 2rem;
}

.projects-slider {
    display: flex;
    width: 100%;
    height: 65vh;
    gap: 8px;
    padding: 0 1.5rem;
}

.project-card {
    position: relative;
    height: 100%;
    background-color: #151515;
    border-radius: 16px;
    overflow: hidden;
    flex: 1;
    transition: flex 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.project-card.active {
    flex: 6;
}

.project-card:not(.active):hover {
    flex: 1.3;
}

.video-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0.5;
    transition: opacity 0.6s;
}

.project-card.active .video-placeholder {
    opacity: 1;
}

.project-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.45;
    transition: opacity 0.6s;
}

.project-card.active .project-video {
    opacity: 1;
}

/* DRAGGED video has letterboxing baked in — crop it out */
.project-card:nth-child(6) .project-video {
    transform: scale(1.2);
}

/* Collapsed title (vertical, bottom-aligned) */
.collapsed-info {
    position: absolute;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    writing-mode: vertical-rl;
    white-space: nowrap;
    z-index: 2;
    opacity: 1;
    transition: opacity 0.3s;
    pointer-events: none;
}

.project-card.active .collapsed-info {
    opacity: 0;
}

.collapsed-info h3 {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.5);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin: 0;
    transform: rotate(180deg);
}

.collapsed-info .num {
    margin-right: 8px;
    color: rgba(255, 255, 255, 0.25);
    font-weight: 400;
}

/* Expanded info */
.project-info {
    position: relative;
    z-index: 2;
    padding: 2rem;
    width: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, transparent 100%);
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease 0.1s;
}

.project-card.active .project-info {
    opacity: 1;
    transform: translateY(0);
}

.project-info .project-number {
    display: block;
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
    color: var(--text-muted);
    letter-spacing: 0.1em;
}

.project-info h3 {
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    margin-bottom: 0.3rem;
    color: white;
    text-transform: none;
    letter-spacing: -0.02em;
}

.project-info p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.btn-text {
    display: inline-block;
    padding: 8px 20px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 30px;
    color: white;
    text-decoration: none;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    transition: all 0.3s;
}

.btn-text:hover {
    background: white;
    color: black;
}

.btn-watch-video {
    display: inline-block;
    padding: 8px 20px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 30px;
    color: white;
    background: transparent;
    font-family: inherit;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-watch-video:hover {
    background: white;
    color: black;
    border-color: white;
}

/* Video Modal */
.video-modal {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.video-modal.active {
    opacity: 1;
    pointer-events: all;
}

.video-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.92);
}

.video-modal-player {
    position: relative;
    z-index: 1;
    width: 90vw;
    max-width: 1200px;
    max-height: 85vh;
    border-radius: 8px;
    background: #000;
}

.video-modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    z-index: 2;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.video-modal-close:hover {
    background: rgba(255, 255, 255, 0.25);
}

/* ============================================
   SEITE 3: HOW WE WORK (maxmilkin.com style)
   Letters scrambled → rearrange on scroll
   ============================================ */
.process-section {
    position: relative;
    height: 300vh;
    z-index: 1;
}

.process-bg {
    position: absolute;
    inset: 0;
    background: #0e0e0e url('assets/images/Beide-Work.png') center center / cover no-repeat;
    z-index: 0;
}

.process-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
    opacity: 0.04;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 256px 256px;
}

/* Sticky container that stays in viewport while scrolling */
.process-sticky {
    position: sticky;
    top: 0;
    height: 100vh;
    width: 100%;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 6rem;
    overflow: hidden;
}

.process-title {
    font-size: clamp(3rem, 10vw, 8rem);
    font-weight: 900;
    color: rgba(255, 255, 255, 0.07);
    letter-spacing: -0.03em;
    text-transform: uppercase;
    margin-bottom: 2rem;
    text-align: center;
}

/* The canvas where letters are absolutely positioned */
.scramble-canvas {
    position: relative;
    width: 100%;
    max-width: 900px;
    height: 60vh;
    /* Letters are positioned inside here */
}

.scramble-letter {
    position: absolute;
    font-family: var(--font);
    will-change: transform;
    line-height: 1;
    white-space: pre;
}

/* Invisible scroll spacer */
.process-scroll-spacer {
    height: 200vh;
    position: relative;
    z-index: 0;
}

/* Hidden final reference text (used by JS to calculate target positions) */
.process-final-text {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 900px;
    padding: 0 2rem;
    /* Visible but transparent for position measurement, then hidden */
    visibility: hidden;
    pointer-events: none;
    z-index: -1;
    padding-top: calc(6rem + clamp(3rem, 10vw, 8rem) + 2rem); /* Match sticky padding + title + margin */
}

.final-block {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    margin-bottom: 2.5rem;
}

.final-number {
    font-size: clamp(3rem, 5vw, 4.5rem);
    font-weight: 300;
    color: rgba(255, 255, 255, 0.15);
    font-style: italic;
    line-height: 1;
    min-width: 50px;
}

.final-content {
    flex: 1;
}

.final-heading {
    font-size: clamp(1.2rem, 2.5vw, 1.8rem);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 0.6rem;
    color: white;
}

.final-body {
    font-size: clamp(0.75rem, 1.2vw, 0.88rem);
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.65);
    max-width: 500px;
}

/* ============================================
   SEITE 4: ABOUT
   ============================================ */
.about-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 8rem 0;
    background: var(--bg);
    position: relative;
    z-index: 1;
    overflow: hidden;
}

.about-overlay {
    display: flex;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
    gap: 0;
}

.about-person {
    flex: 0 0 30%;
    overflow: hidden;
    border-radius: 8px;
}

.about-person-left {
    /* Show left half of the image (the left guy) */
    overflow: hidden;
}

.about-person-left .about-img-full {
    width: 200%;
    max-width: none;
    display: block;
    object-fit: cover;
    object-position: left center;
}

.about-person-right {
    overflow: hidden;
}

.about-person-right .about-img-full {
    width: 200%;
    max-width: none;
    display: block;
    object-fit: cover;
    object-position: right center;
    margin-left: -100%;
}

.about-text-center {
    flex: 1;
    min-width: 0;
    padding: 0 3rem;
    text-align: center;
}

.about-text-center h2 {
    margin-bottom: 1.5rem;
    font-size: clamp(1.4rem, 3.5vw, 2.6rem);
    letter-spacing: -0.02em;
}

.about-text-center p {
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.8;
    margin-bottom: 1rem;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}

/* ============================================
   SEITE 5: CONTACT
   ============================================ */
.contact-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8rem 0;
    background: var(--bg);
    position: relative;
    z-index: 1;
}

.contact-container {
    width: 100%;
    max-width: 550px;
    margin: 0 auto;
    padding: 0 2rem;
    text-align: center;
}

.contact-container h2 {
    margin-bottom: 1rem;
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    letter-spacing: -0.02em;
}

.contact-divider {
    width: 60px;
    height: 2px;
    background: var(--text);
    margin: 0 auto 3rem;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    text-align: left;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

input,
textarea {
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    padding: 0.8rem 0;
    color: white;
    font-family: inherit;
    font-size: 1rem;
    transition: border-color 0.3s;
    resize: none;
}

input:focus,
textarea:focus {
    outline: none;
    border-bottom-color: var(--accent);
}

/* Budget buttons */
.budget-options {
    display: flex;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.budget-btn {
    padding: 0.6rem 1.5rem;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 30px;
    color: var(--text-muted);
    font-family: inherit;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s;
    letter-spacing: 0.05em;
}

.budget-btn:hover {
    border-color: rgba(255, 255, 255, 0.4);
    color: white;
}

.budget-btn.selected {
    background: white;
    color: var(--bg);
    border-color: white;
}

.btn-primary {
    align-self: center;
    margin-top: 1rem;
    padding: 0.9rem 3rem;
    background: white;
    color: black;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    font-family: inherit;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: transform 0.2s, opacity 0.2s;
}

.btn-primary:hover {
    transform: scale(1.05);
    opacity: 0.9;
}

/* ============================================
   FOOTER
   ============================================ */
footer {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding: 3rem 2rem;
    background: var(--bg);
    position: relative;
    z-index: 1;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.footer-logo {
    font-weight: 800;
    font-size: 1.1rem;
    letter-spacing: 0.05em;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: white;
}

.footer-copy {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.3);
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .menu-toggle {
        display: block;
    }

    .hero-slogan-track {
        display: none;
    }

    .hero-title {
        display: none !important;
    }

    /* Hero — word-by-word scroll on mobile */
    .hero-section {
        height: 350vh;
    }

    .hero-image {
        display: none;
    }

    .hero-words {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 3;
        pointer-events: none;
        gap: 0.15em;
    }

    .navbar {
        background: var(--bg);
        mix-blend-mode: normal;
    }

    .hero-word {
        display: block;
        font-family: 'Clash Display', var(--font);
        font-size: clamp(3.5rem, 18vw, 9rem);
        font-weight: 800;
        letter-spacing: -0.03em;
        line-height: 1;
        color: var(--text);
        opacity: 0;
        will-change: transform, opacity;
    }

    .hero-word.accent {
        color: var(--accent);
    }

    /* About — stack vertically on mobile */
    .about-overlay {
        flex-direction: column;
        gap: 2rem;
        padding: 0 1.5rem;
    }

    .about-person {
        flex: none;
        width: 60%;
    }

    .about-person-left .about-img-full {
        width: 200%;
    }

    .about-person-right .about-img-full {
        width: 200%;
        margin-left: -100%;
    }

    .about-text-center {
        padding: 0;
    }

    /* Projects — vertical stack */
    .projects-section {
        padding: 4rem 0;
    }

    .projects-slider {
        flex-direction: column;
        height: auto;
        gap: 6px;
        padding: 0 1rem;
    }

    .project-card {
        flex: none;
        height: 56px;
        border-radius: 12px;
        transition: height 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    }

    .project-card.active {
        flex: none;
        height: 65vh;
    }

    .project-card:not(.active):hover {
        flex: none;
    }

    /* Collapsed label: horizontal on mobile */
    .collapsed-info {
        bottom: auto;
        top: 50%;
        left: 1.2rem;
        transform: translateY(-50%);
        writing-mode: horizontal-tb;
    }

    .collapsed-info h3 {
        font-size: 0.75rem;
        transform: none;
    }

    .collapsed-info .num {
        display: inline;
        margin-right: 6px;
    }

    .project-info h3 {
        font-size: 1.2rem;
    }

    .project-info p {
        font-size: 0.8rem;
        margin-bottom: 1rem;
    }

    /* Process */
    .process-title {
        font-size: clamp(2rem, 12vw, 4rem);
    }

    .process-section {
        height: 300vh;
    }

    .scramble-canvas {
        height: 75vh;
    }

    /* About */
    .about-overlay {
        flex-direction: column;
        gap: 2rem;
        padding: 0 1.5rem;
    }

    /* Contact */
    .budget-options {
        flex-wrap: wrap;
    }

    /* Footer */
    .footer-content {
        flex-direction: column;
        text-align: center;
    }

    .footer-links {
        justify-content: center;
        flex-wrap: wrap;
    }
}

@media (max-width: 480px) {
    .project-card.active {
        height: 55vh;
    }

    .project-info {
        padding: 1rem;
    }

    .project-info h3 {
        font-size: 1rem;
    }

    .project-info p {
        font-size: 0.75rem;
        line-height: 1.5;
    }

    .btn-watch-video {
        font-size: 0.65rem;
        padding: 6px 14px;
    }

    .process-section {
        height: 200vh;
    }
}
