/* Cinematic film system — clean, sparse, movie-like */

:root {
    --film-ink: #020d50;
    --film-mist: #f5f6f8;
    --film-line: rgba(2, 13, 80, 0.1);
    --film-cyan: #0675e7;
}

body.smooth-scroll {
    overflow-x: hidden;
}

/* Geyop for subheadings / kickers */
.film-kicker,
.film-subhead,
h3.film-subhead,
.film-grid h3 {
    font-family: 'Geyop', 'MADE Outer Sans', system-ui, sans-serif;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.film-kicker {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.55);
    margin-bottom: 1rem;
}

.film-title {
    font-family: 'ALTRONED', 'MADE Outer Sans', system-ui, sans-serif;
    font-size: clamp(1.65rem, 3.2vw, 2.5rem);
    line-height: 1.18;
    letter-spacing: 0.01em;
    font-weight: 400;
    margin: 0 0 1rem;
}

.film-lede {
    font-family: 'MADE Outer Sans', system-ui, sans-serif;
    font-size: 0.92rem;
    line-height: 1.7;
    max-width: 28rem;
    color: rgba(255, 255, 255, 0.68);
    margin: 0;
}

.film-copy .film-title { color: inherit; }
.film-copy .film-lede { color: inherit; opacity: 0.78; }

/* Typewriter */
.film-type {
    display: inline;
    border-right: 2px solid rgba(0, 212, 255, 0.75);
    padding-right: 2px;
    white-space: pre-wrap;
    animation: filmCaret 0.85s step-end infinite;
}
.film-type.is-done {
    border-right-color: transparent;
    animation: none;
}
@keyframes filmCaret {
    50% { border-right-color: transparent; }
}

.film-float {
    animation: filmFloat 4.2s ease-in-out infinite;
}
.film-float--slow {
    animation: filmFloat 6.2s ease-in-out infinite;
}
.film-float--tilt {
    animation: filmFloatTilt 5.4s ease-in-out infinite;
}
.film-drift {
    animation: filmDrift 7s ease-in-out infinite;
}
.film-drift--opp {
    animation: filmDriftOpp 8s ease-in-out infinite;
}
.film-spin-slow {
    animation: filmSpin 16s linear infinite;
}
.film-spin {
    animation: filmSpin 11s linear infinite;
}
.film-pulse {
    animation: filmPulse 3.2s ease-in-out infinite;
}
@keyframes filmFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-14px); }
}
@keyframes filmFloatTilt {
    0%, 100% { transform: translateY(0) rotate(-2deg); }
    50% { transform: translateY(-16px) rotate(2deg); }
}
@keyframes filmDrift {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(14px, -10px); }
}
@keyframes filmDriftOpp {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(-14px, 8px); }
}
@keyframes filmSpin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
@keyframes filmPulse {
    0%, 100% { opacity: 0.55; transform: scale(1); }
    50% { opacity: 0.95; transform: scale(1.06); }
}
@media (prefers-reduced-motion: reduce) {
    .film-float,
    .film-float--slow,
    .film-float--tilt,
    .film-drift,
    .film-drift--opp,
    .film-spin-slow,
    .film-spin,
    .film-pulse { animation: none !important; }
}

/* Instant “what we do” strip */
.film-pillars {
    position: relative;
    z-index: 4;
    display: grid;
    gap: 1px;
    background: rgba(255, 255, 255, 0.1);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
@media (min-width: 768px) {
    .film-pillars { grid-template-columns: repeat(3, 1fr); }
}
.film-pillars__item {
    background: #020d50;
    padding: 1.35rem 1.5rem;
}
.film-pillars__item .film-kicker {
    margin-bottom: 0.45rem;
    color: rgba(0, 212, 255, 0.7);
}
.film-pillars__item p {
    margin: 0;
    font-family: 'MADE Outer Sans', system-ui, sans-serif;
    font-size: 0.88rem;
    line-height: 1.55;
    color: rgba(255, 255, 255, 0.72);
}
.film-pillars__item strong {
    display: block;
    font-family: 'ALTRONED', 'MADE Outer Sans', system-ui, sans-serif;
    font-size: 1.05rem;
    font-weight: 400;
    color: #fff;
    margin-bottom: 0.35rem;
}

.film-hero {
    position: relative;
    min-height: 72vh;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
    color: #fff;
    background: #020d50;
}

.film-hero__bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at 70% 30%, rgba(6, 117, 231, 0.22), transparent 55%),
        linear-gradient(160deg, #020d50 0%, #06153f 55%, #020d50 100%);
}

.film-hero__content {
    position: relative;
    z-index: 3;
    width: 100%;
    max-width: 72rem;
    margin: 0 auto;
    padding: 7.5rem 1.5rem 4.5rem;
}

@media (min-width: 768px) {
    .film-hero { min-height: 82vh; align-items: center; }
    .film-hero__content { padding: 8rem 2.5rem 5rem; }
}

.film-actor {
    position: absolute;
    z-index: 2;
    pointer-events: none;
}

.film-actor__img {
    display: block;
    width: 100%;
    height: auto;
    user-select: none;
    -webkit-user-drag: none;
}

.film-actor--hero {
    right: -4%;
    bottom: -6%;
    width: min(48vw, 400px);
    opacity: 0.95;
}

@media (max-width: 767px) {
    .film-actor--hero {
        right: -14%;
        bottom: -2%;
        width: 56vw;
        opacity: 0.5;
    }
}

.film-chapter {
    position: relative;
    overflow: hidden;
    min-height: auto;
    display: flex;
    align-items: center;
}

@media (min-width: 768px) {
    .film-chapter { min-height: 0; }
    .film-chapter--tall { min-height: 85vh; }
}

.film-chapter--ink {
    background: #020d50;
    color: #fff;
}

.film-chapter--mist {
    background: var(--film-mist);
    color: var(--film-ink);
}

.film-chapter--white {
    background: #fff;
    color: var(--film-ink);
}

.film-chapter__inner {
    position: relative;
    z-index: 4;
    width: 100%;
    max-width: 72rem;
    margin: 0 auto;
    padding: 3.5rem 1.5rem;
}

@media (min-width: 768px) {
    .film-chapter__inner { padding: 4.5rem 2.5rem; }
}

/* Two-column content + visual — fills empty side gaps */
.film-row {
    display: grid;
    gap: 2rem;
    align-items: center;
}
@media (min-width: 900px) {
    .film-row {
        grid-template-columns: 1.05fr 0.95fr;
        gap: 3rem;
    }
    .film-row--flip { grid-template-columns: 0.95fr 1.05fr; }
    .film-row--flip .film-visual { order: -1; }
}

.film-visual {
    position: relative;
    min-height: 16rem;
    display: grid;
    place-items: center;
}

.film-visual__bg {
    position: absolute;
    inset: 4% 2%;
    width: 96%;
    height: 92%;
    object-fit: contain;
    opacity: 0.72;
    pointer-events: none;
    transform-origin: center center;
    filter: saturate(1.25) brightness(1.08);
}

.film-visual__fg {
    position: relative;
    z-index: 1;
    width: min(78%, 340px);
    height: auto;
    display: block;
}

.film-visual__stack {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    width: 100%;
    max-width: 28rem;
}
.film-visual__stack img {
    width: 100%;
    height: auto;
    display: block;
    opacity: 0.9;
}

.film-doors__mid > img {
    will-change: transform;
}

/* ===== Split: full robot in center → opens left/right ===== */
.film-split {
    position: relative;
    min-height: 100vh;
    overflow: hidden;
    background: #020d50;
    color: #fff;
}

.film-split__stage {
    position: relative;
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 6rem 1.25rem 4rem;
}

.film-split__assemble {
    position: absolute;
    left: 50%;
    top: 52%;
    width: min(72vw, 460px);
    height: min(88vh, 720px);
    transform: translate(-50%, -50%);
    z-index: 2;
    pointer-events: none;
}

.film-split__half {
    position: absolute;
    inset: 0;
}

.film-split__half img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    display: block;
    user-select: none;
    -webkit-user-drag: none;
}

.film-split__copy {
    position: relative;
    z-index: 3;
    text-align: center;
    max-width: 28rem;
    margin: 0 auto;
    padding: 1.75rem 1.5rem;
    background: rgba(2, 13, 80, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.12);
    opacity: 0;
}

.film-split__copy .film-lede {
    margin-inline: auto;
    color: rgba(255, 255, 255, 0.72);
}

@media (max-width: 767px) {
    .film-split__assemble {
        width: min(88vw, 340px);
        height: min(70vh, 520px);
    }
}

/* ===== Doors — content ABOVE panels once revealed ===== */
.film-doors {
    position: relative;
    min-height: 100vh;
    overflow: hidden;
    background: #06153f;
    color: #fff;
}

.film-doors__panel {
    position: absolute;
    left: 0;
    right: 0;
    height: 50%;
    z-index: 2;
    background: #020d50;
}

.film-doors__panel--top { top: 0; }
.film-doors__panel--bottom { bottom: 0; }

.film-doors__mid {
    position: relative;
    z-index: 3;
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 5rem 1.5rem;
}

.film-doors__mid img {
    width: min(42vw, 320px);
    margin-bottom: 1.25rem;
}

.film-doors__mid .film-copy {
    text-align: center;
    max-width: 26rem;
    padding: 1.25rem 1rem;
    background: rgba(6, 21, 63, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.film-list {
    list-style: none;
    margin: 2rem 0 0;
    padding: 0;
    max-width: 34rem;
}

.film-list li {
    display: grid;
    grid-template-columns: 2rem 1fr;
    gap: 0.75rem;
    padding: 0.85rem 0;
    border-bottom: 1px solid var(--film-line);
    font-size: 0.9rem;
}

.film-chapter--ink .film-list li {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

.film-list .idx {
    font-family: 'Geyop', 'MADE Outer Sans', system-ui, sans-serif;
    color: var(--film-cyan);
    font-size: 0.7rem;
    letter-spacing: 0.12em;
    padding-top: 0.2rem;
}

.film-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    margin-top: 1.5rem;
    padding: 0.7rem 1.15rem;
    border: 1px solid rgba(255, 255, 255, 0.28);
    color: #fff;
    text-decoration: none;
    font-size: 0.7rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    transition: background 0.25s, color 0.25s, border-color 0.25s;
}

.film-btn:hover {
    background: #fff;
    color: #020d50;
    border-color: #fff;
}

.film-btn--solid {
    background: #0675e7;
    border-color: #0675e7;
}

.film-btn--solid:hover {
    background: #fff;
    color: #020d50;
}

.film-btn--dark {
    border-color: rgba(2, 13, 80, 0.25);
    color: #020d50;
}

.film-btn--dark:hover {
    background: #020d50;
    color: #fff;
    border-color: #020d50;
}

.film-grid {
    display: grid;
    gap: 1px;
    background: var(--film-line);
    border: 1px solid var(--film-line);
}

@media (min-width: 768px) {
    .film-grid { grid-template-columns: repeat(3, 1fr); }
}

.film-grid a,
.film-grid .film-card {
    background: #fff;
    padding: 1.5rem 1.25rem;
    text-decoration: none;
    color: inherit;
    transition: background 0.3s;
}

.film-grid a:hover {
    background: #f0f4fb;
}

.film-grid h3 {
    font-size: 0.85rem;
    font-weight: 400;
    margin: 0 0 0.5rem;
    color: var(--film-ink);
}

.film-grid p {
    font-family: 'MADE Outer Sans', system-ui, sans-serif;
    font-size: 0.85rem;
    line-height: 1.6;
    color: rgba(2, 13, 80, 0.6);
    margin: 0;
    letter-spacing: normal;
    text-transform: none;
}

/* Portfolio work cards */
.film-work {
    display: grid;
    gap: 1.5rem;
}
@media (min-width: 768px) {
    .film-work { grid-template-columns: repeat(2, 1fr); gap: 1.75rem; }
}
@media (min-width: 1100px) {
    .film-work { grid-template-columns: repeat(3, 1fr); }
}
.film-work__card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--film-line);
    text-decoration: none;
    color: inherit;
    overflow: hidden;
    transition: border-color 0.3s, transform 0.35s ease;
}
.film-work__card:hover {
    border-color: rgba(6, 117, 231, 0.55);
    transform: translateY(-4px);
}
.film-work__chrome {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.55rem 0.75rem;
    background: #f3f5f8;
    border-bottom: 1px solid var(--film-line);
}
.film-work__dots {
    display: inline-flex;
    gap: 0.3rem;
}
.film-work__dots i {
    width: 0.45rem;
    height: 0.45rem;
    display: block;
    background: rgba(2, 13, 80, 0.2);
}
.film-work__dots i:nth-child(1) { background: #f87171; }
.film-work__dots i:nth-child(2) { background: #fbbf24; }
.film-work__dots i:nth-child(3) { background: #34d399; }
.film-work__url {
    flex: 1;
    min-width: 0;
    padding: 0.25rem 0.55rem;
    background: #fff;
    border: 1px solid var(--film-line);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.68rem;
    color: rgba(2, 13, 80, 0.45);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.film-work__media {
    position: relative;
    aspect-ratio: 16 / 10;
    background:
        linear-gradient(145deg, rgba(6, 117, 231, 0.12), transparent 50%),
        #e8edf5;
    overflow: hidden;
}
.film-work__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    display: block;
    transition: transform 0.7s ease;
}
.film-work__card:hover .film-work__media img {
    transform: scale(1.05);
}
.film-work__placeholder {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 70% 30%, rgba(6, 117, 231, 0.25), transparent 50%),
        #020d50;
}
.film-work__veil {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 45%, rgba(2, 13, 80, 0.72) 100%);
    opacity: 0;
    transition: opacity 0.35s ease;
}
.film-work__card:hover .film-work__veil { opacity: 1; }
.film-work__index {
    position: absolute;
    left: 0.85rem;
    bottom: 0.75rem;
    z-index: 2;
    font-family: 'Geyop', system-ui, sans-serif;
    font-size: 0.7rem;
    letter-spacing: 0.16em;
    color: #fff;
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 0.35s ease, transform 0.35s ease;
}
.film-work__card:hover .film-work__index {
    opacity: 0.9;
    transform: translateY(0);
}
.film-work__body {
    padding: 1.15rem 1.15rem 1.35rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    flex: 1;
}
.film-work__cat {
    margin: 0;
    font-family: 'Geyop', system-ui, sans-serif;
    font-size: 0.62rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #0675e7;
}
.film-work__title {
    margin: 0;
    font-family: 'ALTRONED', 'MADE Outer Sans', system-ui, sans-serif;
    font-size: 1.05rem;
    font-weight: 400;
    color: var(--film-ink);
    line-height: 1.25;
}
.film-work__desc {
    margin: 0.15rem 0 0;
    font-family: 'MADE Outer Sans', system-ui, sans-serif;
    font-size: 0.84rem;
    line-height: 1.55;
    color: rgba(2, 13, 80, 0.58);
    flex: 1;
}
.film-work__cta {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: 0.85rem;
    font-family: 'Geyop', system-ui, sans-serif;
    font-size: 0.65rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--film-ink);
    transition: color 0.25s, gap 0.25s;
}
.film-work__card:hover .film-work__cta {
    color: #0675e7;
    gap: 0.65rem;
}

.film-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 2px;
    width: 100%;
    background: #0675e7;
    transform-origin: left center;
    transform: scaleX(0);
    z-index: 10040;
}

body.film-mode .binary-rain,
body.film-mode .nk-rail,
body.film-mode .cinematic-cursor,
body.film-mode .cursor-follower {
    display: none !important;
}

body.film-mode,
body.film-mode * {
    cursor: inherit;
}
body.film-mode {
    cursor: auto !important;
}
body.film-mode a,
body.film-mode button,
body.film-mode [role="button"],
body.film-mode summary,
body.film-mode label[for] {
    cursor: pointer !important;
}

body.film-mode h1:not(.film-title) {
    font-size: clamp(1.5rem, 3vw, 2.25rem);
    line-height: 1.2;
}

body.film-mode h2:not(.film-title) {
    font-size: clamp(1.35rem, 2.4vw, 1.85rem);
    line-height: 1.25;
}

/* Keep chrome + menu above pinned ScrollTrigger layers */
.nk-chrome {
    z-index: 10050 !important;
}
.nk-overlay {
    z-index: 10060 !important;
    position: fixed !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    overflow: hidden !important;
}
.nk-overlay-shell {
    position: relative !important;
    height: 100% !important;
    max-height: 100dvh !important;
    overflow: hidden !important;
}
.nk-overlay-scroll {
    position: absolute !important;
    top: 4.25rem !important;
    bottom: 4.25rem !important;
    left: 0 !important;
    right: 0 !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    overscroll-behavior: contain !important;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-y;
}
.nk-nav-list {
    justify-content: flex-start !important;
}
.nk-overlay nav,
.nk-nav-list,
.nk-nav-list > li,
.nk-nav-link,
.nk-nav-label {
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
    animation: none !important;
}
.nk-nav-link {
    color: #fff !important;
}
.nk-nav-link.is-active {
    color: #00d4ff !important;
}
.nk-nav-label {
    font-size: clamp(1.35rem, 3.2vw, 2.25rem) !important;
    color: inherit !important;
}
.nk-overlay-art {
    opacity: 0.1 !important;
}
html.nk-nav-open,
html.nk-nav-open body {
    overflow: hidden !important;
}
