@import url('https://fonts.googleapis.com/css2?family=Inter+Tight:ital,wght@0,700;0,800;0,900;1,400;1,700&family=Space+Grotesk:wght@400;500;600;700&family=DM+Sans:wght@400;500&display=swap');

:root {
    --primary:        #1a1a2e;
    --accent:         hsl(187, 74%, 32%);
    --accent-dark:    hsl(187, 74%, 28%);
    --accent-light:   hsl(187, 40%, 95%);
    --accent-border:  hsl(187, 40%, 88%);
    --accent-end:     hsl(217, 82%, 56%);
    --body:           #2f2f2f;
    --body-strong:    #333333;
    --body-muted:     #444444;
    --meta:           #555555;
    --meta-soft:      #666666;
    --border:         #e2e2e2;
    --bg:             #ffffff;
    --bg-soft:        #f6f8fa;
    --transition:     all 0.28s ease;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'DM Sans', sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--body);
    background-color: var(--bg);
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 1rem;
}

a {
    text-decoration: none;
    color: var(--accent);
    transition: var(--transition);
}

a:hover {
    color: var(--accent-dark);
}

.container {
    width: 90%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 15px;
}

/* ── Editorial bar ───────────────────────────────────────── */
.editorial-bar {
    display: flex;
    align-items: center;
    gap: 0;
    padding: 0 1.5rem;
    height: 34px;
    background: #0d0d1a;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    overflow: hidden;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1002;
}

.editorial-bar > span {
    font-family: 'DM Sans', sans-serif;
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.38);
    white-space: nowrap;
    padding: 0 1.25rem;
    border-right: 1px solid rgba(255,255,255,0.08);
}

.editorial-bar > span:first-child {
    padding-left: 0;
}

.editorial-bar > span:last-child {
    border-right: none;
    margin-left: auto;
}

.editorial-bar__pulse {
    display: flex !important;
    align-items: center;
    gap: 0.5rem;
    color: hsl(187, 74%, 52%) !important;
}

.editorial-bar__pulse .pulse-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: hsl(187, 74%, 52%);
    animation: pulse-anim 2s ease infinite;
}

@keyframes pulse-anim {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.45; transform: scale(0.7); }
}

/* ── Header ─────────────────────────────────────────────── */
header {
    position: fixed;
    top: 34px;
    left: 0;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 1px 0 var(--border);
    z-index: 1000;
    transition: var(--transition);
}

/* 4 px teal → purple gradient bar — the sole decorative accent */
header::after {
    content: '';
    display: block;
    height: 4px;
    background: linear-gradient(to right, var(--accent), var(--accent-end));
    border-radius: 0 0 1px 1px;
}

header .container {
    display: flex;
    align-items: center;
    padding-top: 1rem;
    padding-bottom: 1rem;
}

header.scrolled .container {
    padding-top: 0.6rem;
    padding-bottom: 0.6rem;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo h1 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--primary);
    margin: 0;
    letter-spacing: -0.01em;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2.5rem;
}

.nav-menu a {
    font-family: 'DM Sans', sans-serif;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--meta);
    position: relative;
    padding-bottom: 4px;
    transition: color 0.2s;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 0.25s ease;
    border-radius: 1px;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--primary);
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
    width: 100%;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 4px;
}

.nav-toggle span {
    width: 22px;
    height: 2px;
    background-color: var(--primary);
    border-radius: 1px;
    transition: var(--transition);
}

/* ── Hero ────────────────────────────────────────────────── */
.hero {
    padding: 11rem 0 7.5rem;
    min-height: 70vh;
    display: flex;
    align-items: center;
    background-color: var(--primary);
    color: white;
    text-align: center;
    position: relative;
    overflow: hidden;
    isolation: isolate;
}

/* ── Video background — clip layer ──────────────────────── */
.hero-bg-video {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

/* Oversized inner wrapper — extra 25% top/bottom so parallax
   translateY never reveals a gap at any scroll depth */
.hero-bg-video__inner {
    position: absolute;
    top: -25%;
    left: -2%;
    width: 104%;
    height: 150%;
    will-change: transform;
}

.hero-bg-video__inner video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 50% 50%;
    pointer-events: none;
}

/* Dark cinematic overlay — keeps text legible over any footage */
.hero-bg-video__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(10, 10, 30, 0.80) 0%,
        rgba(10, 10, 30, 0.60) 50%,
        rgba(10, 10, 30, 0.75) 100%
    );
    z-index: 1;
}

/* Gradient wipe at the bottom — blends hero into the next section */
.hero-bg-video__overlay::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 160px;
    background: linear-gradient(to bottom, transparent, var(--primary));
    pointer-events: none;
}

/* Hero content sits above the video and overlay */
.hero .container {
    position: relative;
    z-index: 2;
}

/* ── Parallax reveal — section content ──────────────────── */
[data-parallax-reveal] {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

[data-parallax-reveal].revealed {
    opacity: 1;
    transform: translateY(0);
}

[data-parallax-reveal][data-delay="1"] { transition-delay: 0.1s; }
[data-parallax-reveal][data-delay="2"] { transition-delay: 0.2s; }
[data-parallax-reveal][data-delay="3"] { transition-delay: 0.3s; }
[data-parallax-reveal][data-delay="4"] { transition-delay: 0.4s; }
[data-parallax-reveal][data-delay="5"] { transition-delay: 0.5s; }

/* dot grid texture */
.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: radial-gradient(circle, rgba(255,255,255,0.06) 1px, transparent 1px);
    background-size: 28px 28px;
    pointer-events: none;
    z-index: 1;
    opacity: 0.4;
}

/* radial glow */
.hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 70% 55% at 50% 110%, hsl(217, 82%, 22%) 0%, transparent 65%);
    pointer-events: none;
    z-index: 1;
    opacity: 0.5;
}

.hero .container {
    position: relative;
    z-index: 1;
}

/* eyebrow badge above title */
.hero-eyebrow {
    display: inline-block;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.18);
    color: rgba(255,255,255,0.85);
    font-size: 0.75rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 0.35rem 1rem;
    border-radius: 999px;
    margin-bottom: 1.5rem;
    animation: fadeInUp 0.8s ease both;
}

.hero h1 {
    font-family: 'Inter Tight', sans-serif;
    font-size: clamp(3.2rem, 8vw, 6.5rem);
    font-weight: 800;
    color: white;
    margin-bottom: 1.25rem;
    letter-spacing: -0.04em;
    line-height: 1.0;
    animation: fadeInUp 0.9s ease 0.1s both;
}

.hero h1 .accent-word {
    background: linear-gradient(90deg, var(--accent), var(--accent-end));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero p {
    font-size: 1.1rem;
    max-width: 560px;
    margin: 0 auto 2.5rem;
    color: rgba(255,255,255,0.65);
    line-height: 1.65;
    animation: fadeInUp 0.9s ease 0.2s both;
}

/* specialisms tag row */
.hero-tags {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    animation: fadeInUp 0.9s ease 0.3s both;
}

.hero-tags span {
    background: rgba(255,255,255,0.07);
    border: 1px solid rgba(255,255,255,0.14);
    color: rgba(255,255,255,0.75);
    font-size: 0.78rem;
    font-weight: 500;
    padding: 0.3rem 0.85rem;
    border-radius: 999px;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.hero-tags span:hover {
    background: rgba(255,255,255,0.13);
    border-color: var(--accent);
    color: white;
}

/* ── Mobile fallback: hide video, show static gradient ──────── */
@media (max-width: 768px) {
    .hero-bg-video {
        display: none;
    }
    .hero {
        background: linear-gradient(135deg, var(--primary) 0%, hsl(220, 50%, 15%) 100%);
    }
    .hero::after {
        background: radial-gradient(ellipse 70% 55% at 50% 110%, hsl(217, 82%, 26%) 0%, transparent 65%);
    }
    /* Editorial bar — hide middle segment so "Available" stays visible */
    .editorial-bar > span:nth-child(2) {
        display: none;
    }
}

/* ── Brand strip (homepage) ──────────────────────────────── */
.brand-strip {
    padding: 0;
    background: var(--primary);
    border-top: 1px solid rgba(255,255,255,0.06);
    border-bottom: 1px solid rgba(255,255,255,0.06);
    overflow: hidden;
}

.brand-strip-inner {
    mask-image: linear-gradient(to right, transparent 0%, black 6%, black 94%, transparent 100%);
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 6%, black 94%, transparent 100%);
}

.brand-track {
    display: flex;
    gap: 0;
    width: max-content;
    animation: brand-scroll 28s linear infinite;
}

.brand-strip:hover .brand-track {
    animation-play-state: paused;
}

@keyframes brand-scroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.brand-strip {
    padding: 1.25rem 0;
}

.brand-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.45rem 1.1rem 0.45rem 0.65rem;
    margin: 0 0.45rem;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 999px;
    white-space: nowrap;
    transition: background 0.2s, border-color 0.2s;
    cursor: default;
}

.brand-pill:hover {
    background: rgba(255,255,255,0.1);
    border-color: rgba(255,255,255,0.2);
}

.brand-pill img {
    width: 20px;
    height: 20px;
    border-radius: 3px;
    object-fit: contain;
    flex-shrink: 0;
}

.brand-pill span {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.78rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    color: rgba(255,255,255,0.65);
}

/* ── Filters ─────────────────────────────────────────────── */
.filters {
    padding: 2rem 0;
    background-color: var(--bg-soft);
    border-bottom: 1px solid var(--border);
}

.filter-options {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.filter-btn {
    background: none;
    border: 1.5px solid var(--border);
    padding: 0.45rem 1.25rem;
    border-radius: 999px;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--meta);
    cursor: pointer;
    transition: var(--transition);
}

.filter-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.filter-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: white;
}

/* ── Showreel grid ───────────────────────────────────────── */
.showreel {
    padding: 4rem 0 6rem;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 2rem;
}

.video-item {
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border);
    background: var(--bg);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    transition: transform 0.28s ease, box-shadow 0.28s ease;
    opacity: 0;
    animation: fadeInUp 0.7s ease forwards;
}

.video-item:nth-child(2) { animation-delay: 0.1s; }
.video-item:nth-child(3) { animation-delay: 0.2s; }
.video-item:nth-child(4) { animation-delay: 0.3s; }
.video-item:nth-child(5) { animation-delay: 0.4s; }
.video-item:nth-child(6) { animation-delay: 0.5s; }

.video-item:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 28px rgba(0,0,0,0.1);
}

.video-container {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    background: var(--primary);
}

.video-thumbnail {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 1;
}

.video-container.has-iframe .video-thumbnail {
    opacity: 0;
    transform: scale(1.05);
    pointer-events: none;
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 2;
}

.video-container.has-iframe iframe {
    opacity: 1;
}

.video-overlay {
    position: absolute;
    inset: 0;
    background: rgba(26, 26, 46, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.6;
    transition: opacity 0.25s ease;
    z-index: 2;
}

.video-item:hover .video-overlay {
    opacity: 1;
}

.video-container.has-iframe .video-overlay {
    opacity: 0;
    pointer-events: none;
}

.play-button {
    width: 60px;
    height: 60px;
    background: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.3rem;
    transform: scale(0.85);
    transition: transform 0.2s ease, background 0.2s ease;
    box-shadow: 0 4px 16px rgba(0,0,0,0.3);
}

.video-item:hover .play-button {
    transform: scale(1);
    background: var(--accent-dark);
}

.video-info {
    padding: 1.4rem 1.5rem 1.5rem;
    border-top: 1px solid var(--border);
}

.video-info h3 {
    font-size: 1.05rem;
    margin-bottom: 0.3rem;
    letter-spacing: -0.01em;
    color: var(--primary);
}

.video-info .client {
    font-family: 'DM Sans', sans-serif;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.6rem;
}

.video-info .description {
    font-size: 0.875rem;
    color: var(--meta-soft);
    line-height: 1.55;
}

/* ── Footer ──────────────────────────────────────────────── */
footer {
    background-color: var(--primary);
    color: rgba(255,255,255,0.85);
    padding: 3rem 0 1.5rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.footer-info h3 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1rem;
    color: white;
    margin-bottom: 0.25rem;
}

.footer-info p {
    font-size: 0.875rem;
    color: rgba(255,255,255,0.55);
}

.social-links {
    display: flex;
    gap: 1.25rem;
}

.social-links a {
    color: rgba(255,255,255,0.6);
    font-size: 1.3rem;
    transition: color 0.2s, transform 0.2s;
}

.social-links a:hover {
    color: var(--accent);
    transform: translateY(-3px);
}

.copyright {
    text-align: center;
    padding-top: 1.25rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 0.8rem;
    color: rgba(255,255,255,0.35);
}

/* ── Animations ──────────────────────────────────────────── */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 992px) {
    .video-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }
}

@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100vh;
        background: var(--bg);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2.5rem;
        transition: left 0.3s ease;
        z-index: 999;
    }

    .nav-menu.active {
        left: 0;
    }

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

    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 1.5rem;
    }
}

@media (max-width: 576px) {
    .video-grid {
        grid-template-columns: 1fr;
    }

    .filter-options {
        justify-content: flex-start;
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 0.5rem;
        -webkit-overflow-scrolling: touch;
    }

    .filter-btn {
        white-space: nowrap;
        flex-shrink: 0;
    }
}

@media (hover: none) {
    .video-overlay {
        opacity: 1;
        background: rgba(26,26,46,0.25);
    }

    .play-button {
        transform: scale(1);
    }
}
