/* ============================================
   BASTIEN BRUNIER — Monteur Vidéo
   V5 — Sharp edges / Unified type / Full footer
   ============================================ */

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

::selection {
    background: var(--blue);
    color: #fff;
}

:root {
    --dark: #0C0C0C;
    --dark-soft: #161616;
    --light: #e4e3d7;
    --light-alt: #d5d4c8;
    --blue: #6b8cff;
    --blue-glow: rgba(107, 140, 255, 0.25);
    --white: #FFFFFF;
    --gray: #888;
    --gray-dark: #555;
    --radius: 8px;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--dark);
    color: var(--white);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

/* ==================== CURSOR ==================== */
/* FluidGlass (React) - #cursor-root */

#cursor-root {
    position: fixed;
    inset: 0;
    z-index: 10000;
    pointer-events: none;
}

#cursor-root canvas {
    pointer-events: none !important;
}

/* ==================== LOADER ==================== */

.loader {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: var(--dark);
    display: flex;
    align-items: center;
    justify-content: center;
}

.loader.done { pointer-events: none; }

.loader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.loader-text {
    font-size: clamp(2.5rem, 6vw, 5rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--white);
    text-align: center;
    max-width: 90vw;
}

.loader-word {
    display: inline-block;
    white-space: nowrap;
}

.loader-char {
    display: inline-block;
}

.loader-space {
    display: inline-block;
    width: 0.3em;
}

.loader-cursor {
    display: inline-block;
    color: var(--blue);
    font-weight: 300;
    animation: cursorBlink 0.8s step-end infinite;
}

@keyframes cursorBlink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}


/* ==================== NAV ==================== */

.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 3rem;
    z-index: 500;
    mix-blend-mode: difference;
}

.nav-logo {
    font-weight: 700;
    font-size: 0.85rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

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

.nav-links a {
    font-size: 0.7rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.85);
    transition: color 0.3s ease;
}

.nav-links a:hover { color: #fff; }

.nav-burger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    z-index: 600;
}

.nav-burger span {
    display: block;
    width: 24px;
    height: 2px;
    background: #fff;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav-burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-burger.open span:nth-child(2) { opacity: 0; }
.nav-burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile menu overlay */
.mobile-menu {
    position: fixed;
    inset: 0;
    background: var(--dark);
    z-index: 499;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s ease;
}

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

.mobile-link {
    font-size: clamp(2rem, 8vw, 3.5rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    text-transform: uppercase;
    color: var(--white);
    transition: color 0.3s ease;
}

.mobile-link:hover { color: var(--blue); }

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

.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--dark);
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
    isolation: isolate;
    -webkit-mask-image: -webkit-radial-gradient(white, black);
    will-change: border-radius, width, height;
}

.hero-bg iframe {
    position: absolute;
    width: 120%;
    height: 120%;
    top: -10%;
    left: -10%;
    pointer-events: none;
    border: none;
}

.hero-bg-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 1;
}

.hero-center {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 80%;
    height: 80vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* Canvas knockout background */
.hero-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    border-radius: var(--radius);
}

.hero-center .hero-tag,
.hero-center .hero-title {
    position: relative;
    z-index: 1;
}

/* Mobile : photo en fond + rectangle beige */
@media (max-width: 768px) {
    .hero {
        background: url('../img/bastien-hero.jpg') center center / cover no-repeat;
    }
    .hero-bg { display: none; }
    .hero-center {
        width: 92%;
        height: 60vh;
        background: var(--light);
        border-radius: var(--radius);
        margin-bottom: 10vh;
    }
    .hero-canvas { display: none; }
    #heroBastien { color: var(--dark); }
}

.hero-tag {
    font-size: 1.05rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--dark);
    margin-bottom: 3rem;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
}

.hero-title {
    font-size: clamp(5rem, 15vw, 14rem);
    font-weight: 900;
    line-height: 0.9;
    letter-spacing: -0.05em;
    text-transform: uppercase;
    color: var(--dark);
}

/* Bastien invisible on desktop — canvas draws the knockout */
@media (min-width: 769px) {
    #heroBastien {
        color: transparent;
    }
}


.hero-title .line {
    display: block;
    overflow: hidden;
}

.hero-title .line-inner {
    display: block;
}

.hero-scroll {
    position: absolute;
    bottom: 2.5rem;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.65rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.5);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
}

.hero-scroll::after {
    content: '';
    width: 1px;
    height: 30px;
    background: rgba(255,255,255,0.5);
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%, 100% { opacity: 0.3; transform: scaleY(1); }
    50% { opacity: 1; transform: scaleY(1.4); }
}

/* Hero video info bar */
.hero-video-info {
    position: absolute;
    bottom: 1rem;
    left: 1.5rem;
    right: 1.5rem;
    z-index: 3;
    display: flex;
    justify-content: space-between;
    align-items: center;
    opacity: 0;
    transform: translateY(20px);
}

.hero-video-title,
.hero-video-channel {
    font-size: 0.75rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.6);
    font-weight: 500;
}

.hero-video-channel {
    color: var(--white);
    font-weight: 600;
}

@media (max-width: 768px) {
    .hero-video-info { display: none; }
}

/* ==================== INTRO — LIGHT ==================== */

.intro {
    background: var(--dark);
    color: var(--white);
    padding: 10rem 5vw;
}

.intro-content {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 7rem;
    align-items: center;
    text-align: center;
}

.intro .section-tag {
    color: var(--blue);
}

.intro-text {
    font-size: clamp(1.4rem, 3vw, 2.2rem);
    line-height: 1.6;
    color: var(--white);
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    max-width: 800px;
    letter-spacing: -0.01em;
}

.intro-text strong {
    font-weight: 600;
    color: var(--blue);
}

.intro-stats {
    display: flex;
    gap: 0;
    list-style: none;
    width: 100%;
}

.intro-stats li {
    flex: 1;
    text-align: center;
    padding: 3rem 2rem;
    position: relative;
}

.intro-stats li::after {
    content: '';
    position: absolute;
    top: 20%;
    right: 0;
    height: 60%;
    width: 1px;
    background: rgba(255, 255, 255, 0.1);
}

.intro-stats li:last-child::after { display: none; }

.intro-stats .counter {
    display: block;
    font-size: clamp(3rem, 5.5vw, 4.5rem);
    font-weight: 700;
    line-height: 1;
    color: var(--white);
    letter-spacing: -0.03em;
    white-space: nowrap;
}

.intro-stats .counter .suffix {
    color: var(--blue);
}

.intro-stats span {
    font-size: 0.75rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--gray);
    margin-top: 1rem;
    display: block;
    font-weight: 500;
}

/* ==================== REEL — LIGHT ==================== */

.reel {
    background: var(--light);
    color: var(--dark);
    padding: 10rem 5vw;
}

.section-tag {
    font-size: 0.7rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--dark);
    margin-bottom: 1.2rem;
    font-weight: 600;
}

.section-title {
    font-size: clamp(2rem, 4.5vw, 3.5rem);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-bottom: 4rem;
}

.reel-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.reel-card {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    background: var(--dark);
    border-radius: var(--radius);
    cursor: pointer;
    transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1),
                box-shadow 0.5s ease;
}

.reel-card:hover {
    transform: scale(1.02);
    box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}

.reel-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.reel-card:hover img { transform: scale(1.06); }

.reel-card .play {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.2);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.reel-card:hover .play { opacity: 1; }

.play-circle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 30px rgba(0,0,0,0.2);
    transition: transform 0.3s ease;
}

.reel-card:hover .play-circle { transform: scale(1.1); }

.play-circle svg {
    width: 20px;
    height: 20px;
    fill: var(--dark);
    margin-left: 3px;
}

.reel-card.active img,
.reel-card.active .play { display: none; }

.reel-card iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* ==================== SERVICES — DARK ==================== */

.services {
    background: var(--dark);
    color: var(--white);
    padding: 10rem 5vw;
}

.services .section-tag {
    color: var(--blue);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
}

.srv {
    padding: 3rem;
    position: relative;
    transition: background 0.4s ease;
}

.srv::after {
    content: '';
    position: absolute;
    top: 15%;
    right: 0;
    height: 70%;
    width: 1px;
    background: rgba(255,255,255,0.08);
}

.srv:last-child::after { display: none; }
.srv:hover { background: rgba(255, 255, 255, 0.03); }

.srv-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
    overflow: hidden;
}

.srv-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.srv h3 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 1rem;
    transition: color 0.3s ease;
}

.srv:hover h3 { color: var(--blue); }

.srv p {
    font-size: 1rem;
    color: var(--gray);
    line-height: 1.7;
    font-family: 'Inter', sans-serif;
}

/* ==================== TRUST — LIGHT — Scrolling marquee ==================== */

.trust {
    background: var(--light);
    color: var(--dark);
    padding: 6rem 0;
    overflow: hidden;
}

.trust .section-tag {
    padding-left: 5vw;
    margin-bottom: 3rem;
}

.trust-track {
    display: flex;
    white-space: nowrap;
    will-change: transform;
}

.trust-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0 2.5rem;
    flex-shrink: 0;
    transition: opacity 0.3s ease;
}

.trust-item:hover { opacity: 0.7; }

.trust-avatar {
    width: 83px;
    height: 83px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 2px solid var(--light-alt);
    transition: border-color 0.3s ease, transform 0.3s ease;
}

.trust-item:hover .trust-avatar { transform: scale(1.1); }

.trust-item:hover .trust-avatar { border-color: var(--dark); }

.trust-item span {
    display: none;
}


/* ==================== PROCESS — DARK (service-style) ==================== */

.process {
    background: var(--dark);
    color: var(--white);
    padding: 10rem 5vw;
}

.process .section-tag {
    color: var(--blue);
}

.process-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
}

.proc {
    padding: 3rem;
    position: relative;
    transition: background 0.4s ease;
}

.proc::after {
    content: '';
    position: absolute;
    top: 15%;
    right: 0;
    height: 70%;
    width: 1px;
    background: rgba(255,255,255,0.08);
}

.proc:last-child::after { display: none; }
.proc:hover { background: rgba(59, 130, 246, 0.05); }

.proc-icon {
    width: 44px;
    height: 44px;
    background: rgba(59, 130, 246, 0.1);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
}

.proc-icon svg {
    width: 20px;
    height: 20px;
    stroke: var(--blue);
    fill: none;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.proc h3 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 1rem;
    transition: color 0.3s ease;
}

.proc:hover h3 { color: var(--blue); }

.proc p {
    font-size: 1rem;
    color: var(--gray);
    line-height: 1.7;
    font-family: 'Inter', sans-serif;
}

/* ==================== FOOTER — DARK — FULL SCREEN SPLIT ==================== */

.footer {
    background: var(--dark);
    color: var(--white);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 0 8vw;
    position: relative;
}

.footer-top {
    flex: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6vw;
    padding: 8rem 0;
}

.footer-left {
    flex: 1.2;
}

.footer-right {
    flex: 0 0 38%;
    max-width: 480px;
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.footer-tag {
    font-size: 0.7rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--blue);
    margin-bottom: 2.5rem;
    font-weight: 600;
}

.footer-title {
    font-size: clamp(4rem, 10vw, 9rem);
    font-weight: 700;
    line-height: 1.02;
    letter-spacing: -0.04em;
    text-transform: uppercase;
}

.footer-title .blue { color: var(--blue); }

.ft-wrap {
    display: block;
    overflow: hidden;
    padding-top: 0.15em;
}

.ft-line { display: block; }

.footer-desc {
    font-size: 1.2rem;
    color: var(--gray);
    line-height: 1.75;
    font-family: 'Inter', sans-serif;
}

.footer-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.footer-list li {
    border-top: 1px solid rgba(255,255,255,0.1);
}

.footer-list li:last-child {
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.footer-list a {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.3rem 0;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 1.05rem;
    letter-spacing: 0.04em;
    color: rgba(255,255,255,0.6);
    transition: color 0.3s ease, padding-left 0.3s ease;
}

.footer-list a:hover {
    color: var(--blue);
    padding-left: 0.5rem;
}

.footer-list a svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2.5rem 0;
    border-top: 1px solid rgba(255,255,255,0.08);
}

.footer-copy {
    font-size: 0.72rem;
    color: rgba(255,255,255,0.6);
    letter-spacing: 0.05em;
}

.footer-credit {
    font-size: 0.72rem;
    letter-spacing: 0.05em;
    color: rgba(255,255,255,0.6);
}

.footer-credit a {
    color: rgba(255,255,255,0.9);
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;
    transition: color 0.3s ease;
}

.footer-credit a:hover {
    color: var(--blue);
}

/* ==================== RESPONSIVE ==================== */

@media (max-width: 1024px) {
    .services-grid,
    .process-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .srv:nth-child(2)::after,
    .srv:nth-child(3)::after,
    .srv:nth-child(4)::after,
    .proc:nth-child(2)::after,
    .proc:nth-child(3)::after,
    .proc:nth-child(4)::after {
        display: none;
    }

    .intro-stats { gap: 3rem; }
}

@media (max-width: 768px) {
    .nav { padding: 1.25rem 1.5rem; }
    .nav-links { display: none; }
    .nav-burger { display: flex; }

    .hero-title { font-size: clamp(3rem, 15vw, 6rem); }
    .hero-center { width: 92%; height: 75vh; }

    .intro { padding: 6rem 1.5rem; }
    .intro-content { gap: 3.5rem; }
    .intro-stats { gap: 2.5rem; }

    .reel, .services, .process { padding: 6rem 1.5rem; }
    .reel { padding-bottom: 6rem; }
    .reel-grid { grid-template-columns: 1fr; gap: 1rem; }

    .services-grid,
    .process-grid { grid-template-columns: 1fr; }

    .srv::after,
    .proc::after { display: none; }

    .trust { padding: 4rem 0; }
    .trust-avatar { width: 64px; height: 64px; }

    .footer {
        min-height: auto;
        padding: 0 1.5rem;
    }

    .footer-top {
        flex-direction: column;
        gap: 3rem;
        padding: 6rem 0;
        align-items: flex-start;
    }

    .footer-right { flex: none; max-width: 100%; }
    .footer-title { font-size: clamp(2.5rem, 12vw, 4rem); }
    .footer-list a { font-size: 0.95rem; }

    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
        padding: 2rem 0;
    }

    .hero-scroll { display: none; }
}

@media (max-width: 480px) {
    .intro-stats { flex-direction: column; gap: 2rem; }
    .intro-stats li::after { display: none; }
    .trust-item span { font-size: 1.2rem; }
    .play-circle { width: 48px; height: 48px; }
    .play-circle svg { width: 16px; height: 16px; }
}

@media (hover: none) and (pointer: coarse) {
    #cursor-root { display: none; }
    .reel-card .play { opacity: 1; background: rgba(0,0,0,0.15); }
}
