/* ============================================================
   GHISLAIN ROY DESIGN — Main Stylesheet
   ============================================================
   Table of contents:
   1.  Custom Properties (design tokens)
   2.  Custom Font (@font-face)
   3.  Reset & Base
   4.  Typography
   5.  Layout Utilities
   6.  Header & Navigation
   7.  Hero Section
   8.  Testimonials Carousel
   9.  Footer
   10. Logos / Masonry Grid
   11. Illustrations Page
   12. Motion Page
   13. About Page
   14. Lightbox
   15. Responsive / Mobile
   16. Édition Page
   17. UX/UI Page
   18. Case Study Pages
   ============================================================ */

/* ============================================================
   1. CUSTOM PROPERTIES
   ============================================================ */
:root {
    /* Colours */
    --color-red: #c13b2a;
    --color-dark: #262424; /* headings, buttons, body text */
    --color-gray-light: #f4f4f4; /* nav pills, testimonials bg, logos page bg */
    --color-white: #ffffff;
    --color-border: #d8d8d8;
    --color-text-muted: #888888;

    /* Typography */
    --font-body: "Inter", sans-serif;
    --font-script: "GroyHand", cursive;

    /* Layout */
    --container-max: 960px; /* standard max content width */
    --container-pad: 32px; /* horizontal padding inside .container */
    --section-pad: 100px; /* vertical padding for main sections */

    /* Transitions */
    --transition: 0.2s ease;
}

/* ============================================================
   2. CUSTOM FONT (@font-face)
   ——————————————————————————————————————————————————————————
   GroyHand is a custom OTF font in the fonts/ folder.
   font-display: swap shows the fallback (cursive) immediately,
   then swaps in GroyHand once it loads — no invisible text.

   To convert to WOFF2 for faster loading (~30% smaller):
     https://cloudconvert.com/otf-to-woff2
   Then add a src line:
     url('../fonts/GroyHand.woff2') format('woff2'),
   before the OTF line (browser uses the first format it supports).
   ============================================================ */

/* Regular weight */
@font-face {
    font-family: "GroyHand";
    src: url("../fonts/GroyHand.otf") format("opentype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

/* Bold weight */
@font-face {
    font-family: "GroyHand";
    src: url("../fonts/GroyHand-Bold.otf") format("opentype");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* ============================================================
   3. RESET & BASE
   ============================================================ */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    font-weight: 500; /* Inter Medium — Figma spec */
    font-size: 20px; /* Figma spec */
    line-height: 1.45; /* 145% — Figma spec */
    color: var(--color-dark);
    background-color: var(--color-white);
    /* Smooth font rendering on WebKit (Safari/Chrome) and Firefox on macOS */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

a {
    color: inherit;
    text-decoration: none;
}

ul {
    list-style: none;
}

/* ============================================================
   4. TYPOGRAPHY
   Figma specs:
     Heading     — Inter Bold 42px, 110% line-height
     Body        — Inter Medium 20px, 145% line-height, #262424
     Small text  — Inter 14px, 145% line-height, #262424
   ============================================================ */
h1,
h2,
h3 {
    font-weight: 700;
    line-height: 1.1;
}

/* Red display heading — hero section */
.heading-display {
    font-size: 42px;
    color: var(--color-red);
    margin-bottom: 1.25rem;
}

/* Underlined service keywords in hero intro */
.hero-intro u {
    text-decoration: underline;
    text-underline-offset: 3px;
    font-weight: 700;
}

/* Handwritten script text — uses custom GroyHand font */
.font-script {
    font-family: var(--font-script);
    font-size: clamp(0.95rem, 1.5vw, 1.2rem);
    font-weight: 400;
    letter-spacing: 0.01em;
}

/* ============================================================
   5. LAYOUT UTILITIES
   ============================================================ */

/* Centred content wrapper */
.container {
    width: 100%;
    max-width: var(--container-max);
    margin-left: auto;
    margin-right: auto;
    padding-left: var(--container-pad);
    padding-right: var(--container-pad);
}

/* Space between the nav and page content on every page */
main {
    padding-top: 48px;
}

/* Two-column flex layout */
.two-col {
    display: flex;
    align-items: center;
    gap: 56px;
}

/* ============================================================
   6. HEADER & NAVIGATION
   ——————————————————————————————————————————————————————————
   Desktop: logo centered above a single pill nav row.
   Mobile (≤700px): logo left + hamburger right; tapping the
   burger reveals a full-width vertical dropdown menu.
   ============================================================ */

/* ── Desktop header ── */
.site-header {
    padding: 32px 0 24px;
    text-align: center;
    background: var(--color-white);
    position: relative; /* anchor for mobile dropdown */
}

/* Logo */
.site-logo {
    display: inline-block;
    margin-bottom: 22px;
}

.site-logo img {
    width: 134px;
    margin: 0 auto;
}

/* ── Hamburger button — hidden on desktop ── */
.nav-hamburger {
    display: none; /* shown only in the ≤700px media query */
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: var(--color-dark);
    flex-shrink: 0;
    border-radius: 8px;
    transition: background var(--transition);
}

.nav-hamburger:hover {
    background: var(--color-gray-light);
}

.nav-hamburger svg {
    display: block;
    width: 24px;
    height: 24px;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    fill: none;
}

/* Swap open ↔ close icons via JS-toggled .is-open class */
.nav-hamburger .icon-close {
    display: none;
}
.nav-hamburger .icon-open {
    display: block;
}
.nav-hamburger.is-open .icon-close {
    display: block;
}
.nav-hamburger.is-open .icon-open {
    display: none;
}

/* Nav row — centers the pill group and EN button */
.site-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    flex-wrap: wrap;
}

/* ── Main pill container ── */
.nav-pills {
    display: flex;
    align-items: center;
    gap: 2px;
    background: var(--color-gray-light);
    border-radius: 999px;
    padding: 7px 10px;
}

/* Individual nav link */
.nav-link {
    display: inline-block;
    padding: 9px 18px;
    border-radius: 999px;
    font-size: 16px;
    font-weight: 500;
    color: var(--color-dark);
    transition: color var(--transition);
    white-space: nowrap;
    line-height: 1.2;
}

.nav-link:hover {
    color: var(--color-red);
}
.nav-link.active {
    color: var(--color-red);
    font-weight: 600;
}

/* ── Language toggle ──
   Height must match nav-pills:
   pills: 7px + 9px + (16px × 1.2 lh ≈ 19px) + 9px + 7px = 51px
   lang:  16px + 19px + 16px = 51px ✓ */
.nav-lang {
    display: inline-flex;
    align-items: center;
    background: var(--color-gray-light);
    border-radius: 999px;
    padding: 16px 28px;
    font-size: 16px;
    font-weight: 500;
    color: var(--color-dark);
    transition: color var(--transition);
}

.nav-lang:hover {
    color: var(--color-red);
}

/* ============================================================
   7. HERO SECTION
   ============================================================ */
.hero {
    padding: var(--section-pad) 0;
}

.hero-body {
    flex: 1; /* fills remaining width after the mascot column */
    max-width: 560px;
}

.hero-intro {
    margin-bottom: 2.25rem;
}

/* Button group */
.btn-group {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

/* Base button */
.btn {
    display: inline-block;
    padding: 14px 28px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    font-family: var(--font-body);
    cursor: pointer;
    transition:
        background var(--transition),
        color var(--transition),
        border-color var(--transition);
    border: 2px solid transparent;
    text-align: center;
    line-height: 1.2;
}

.btn-primary {
    background-color: var(--color-dark);
    color: var(--color-white);
    border-color: var(--color-dark);
}
.btn-primary:hover {
    background-color: #0f0e0e;
    border-color: #0f0e0e;
}

.btn-outline {
    background: transparent;
    color: var(--color-dark);
    border-color: var(--color-dark);
}
.btn-outline:hover {
    background-color: var(--color-dark);
    color: var(--color-white);
}

/* Small button variant — for edition labels, year tags, etc. */
.btn--sm {
    padding: 6px 16px;
    font-size: 0.82rem;
    border-radius: 8px;
}

/* Mascot — flex: 0 0 auto so it doesn't grow and gives space to the text */
.hero-image {
    display: flex;
    justify-content: center;
    flex: 0 0 auto;
}

.hero-image img {
    max-width: 300px;
    width: 100%;
}

/* ============================================================
   8. TESTIMONIALS CAROUSEL
   ——————————————————————————————————————————————————————————
   Full viewport width — no .container wrapper on the track.
   JS (main.js § 4) decides at runtime:
     • cards fit  → centered static row, no animation
     • cards overflow → infinite left-scrolling marquee
   ============================================================ */
.testimonials {
    padding: 64px 0 52px;
    background-color: var(--color-gray-light);
}

/* Edge-to-edge scrollable track */
.testimonials-track {
    display: flex;
    justify-content: center; /* JS switches to flex-start when marquee activates */
    gap: 20px;
    overflow-x: hidden; /* scrollbar hidden; scrollLeft driven by JS */
    padding: 4px 40px 12px;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE / old Edge */
}

.testimonials-track::-webkit-scrollbar {
    display: none; /* Chrome / Safari */
}

/* Individual card */
.testimonial-card {
    flex: 0 0 340px;
    background: var(--color-white);
    border-radius: 12px;
    padding: 28px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    display: flex;
    flex-direction: column;
    gap: 20px;
    user-select: none;
}

/* Quote text */
.testimonial-quote {
    font-size: 14px;
    font-weight: 400;
    color: var(--color-dark);
    line-height: 1.45;
    flex: 1;
}

/* Author row */
.testimonial-author {
    display: flex;
    align-items: center;
    gap: 14px;
}

/* Avatar — rounded rectangle; object-fit: contain for landscape logos */
.testimonial-avatar {
    width: 52px;
    height: 44px;
    border-radius: 8px;
    object-fit: contain;
    flex-shrink: 0;
    background-color: var(--color-gray-light);
    padding: 4px;
}

/* Initials fallback when no image is available */
.testimonial-avatar--initials {
    width: 52px;
    height: 44px;
    border-radius: 8px;
    background-color: var(--color-dark);
    color: var(--color-white);
    font-size: 14px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    letter-spacing: 0.02em;
}

.testimonial-name {
    font-size: 14px;
    font-weight: 700;
    color: var(--color-dark);
    line-height: 1.3;
}

.testimonial-company {
    font-size: 13px;
    font-weight: 400;
    color: var(--color-text-muted);
    line-height: 1.3;
}

/* ============================================================
   9. FOOTER
   ============================================================ */

/* Red CTA band */
.footer-cta {
    background-color: var(--color-red);
    padding: 44px 0;
    color: var(--color-white);
}

.footer-cta .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}

.footer-cta-text {
    color: var(--color-white);
}

/* Social icons */
.social-links {
    display: flex;
    gap: 22px;
    align-items: center;
}

.social-link {
    color: var(--color-white);
    transition: opacity var(--transition);
    display: flex;
    align-items: center;
}

.social-link:hover {
    opacity: 0.72;
}

.social-link svg {
    width: 22px;
    height: 22px;
    fill: currentColor;
}

/* Dark sub-footer bar */
.footer-bar {
    background-color: var(--color-dark);
    color: #9a9a9a;
    font-size: 13px;
    font-weight: 400;
    padding: 16px 0;
}

.footer-bar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.footer-nav {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    align-items: center;
}

.footer-nav a {
    color: #9a9a9a;
    font-size: 13px;
    transition: color var(--transition);
}

.footer-nav a:hover {
    color: var(--color-white);
}

/* Email icon — slightly larger than the social icon default */
.social-link--email svg {
    width: 26px;
    height: 26px;
}

/* EN language link — subtle separator from the page links */
.footer-nav-lang {
    margin-left: 8px;
    padding-left: 16px;
    border-left: 1px solid rgba(255, 255, 255, 0.18);
}

/* ============================================================
   10. LOGOS / MASONRY GRID
   ——————————————————————————————————————————————————————————
   CSS column-count masonry: 3 equal-width columns, cards flow
   top-to-bottom with variable heights.
   Reused by logos.html and illustrations.html.
   ============================================================ */
.logos-grid {
    columns: 3;
    column-gap: 16px;
    padding: 48px 0 96px;
}

/* 2-column override — used by Imprimé and any future page that needs wider cards */
.logos-grid--2col {
    columns: 2;
}

/* Light-gray page background (logos page) */
.page-logos {
    background-color: var(--color-gray-light);
}

/* Logo card — full-bleed image on gray, same style as .illus-card */
.logo-card {
    break-inside: avoid;
    background: var(--color-gray-light);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 16px;
    display: block;
    box-shadow: 0 0px 0px rgba(0, 0, 0, 0.1);
    transition:
        box-shadow var(--transition),
        transform var(--transition);
}

.logo-card:hover {
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.18);
    transform: translateY(-2px);
}

.logo-card img {
    width: 100%;
    height: auto;
}

/* ============================================================
   12. ILLUSTRATIONS PAGE
   ——————————————————————————————————————————————————————————
   Same masonry grid (.logos-grid), but cards are full-bleed
   images with no white box. White page background.
   ============================================================ */

/* Full-bleed illustration card */
.illus-card {
    break-inside: avoid;
    border-radius: 12px;
    overflow: hidden; /* clips image to rounded corners */
    margin-bottom: 16px;
    display: block;
    box-shadow: 0 0px 0px rgba(0, 0, 0, 0.1);
    transition:
        box-shadow var(--transition),
        transform var(--transition);
}

.illus-card:hover {
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.18);
    transform: translateY(-2px);
}

.illus-card img {
    width: 100%;
    height: auto;
}

/* ============================================================
   13. MOTION PAGE
   ============================================================ */

/* Centered video wrapper */
.motion-video-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-bottom: var(--section-pad);
    gap: 18px;
}

/* Responsive video — never wider than the container */
.motion-video {
    width: 100%;
    max-width: 680px;
    border-radius: 12px;
    background: #000; /* black letterbox while video loads */
    display: block;
}

/* Music credit — same style as testimonial text */
.motion-credit {
    font-size: 14px;
    font-weight: 400;
    line-height: 1.45;
    color: var(--color-dark);
}

.motion-credit a {
    color: var(--color-dark);
    text-decoration: underline;
    text-underline-offset: 3px;
    transition: color var(--transition);
}

.motion-credit a:hover {
    color: var(--color-red);
}

/* ============================================================
   14. ABOUT PAGE
   ============================================================ */

/* ── Bio section ── */
.about-hero {
    padding: var(--section-pad) 0;
}

.about-heading {
    font-size: 42px;
    font-weight: 700;
    color: var(--color-red);
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

/* Space between paragraphs */
.about-body p + p,
.about-full p + p {
    margin-top: 1.25rem;
}

/* Full-width paragraphs that sit below the two-col block */
.about-full {
    margin-top: 1.25rem;
}

/* Illustration column — doesn't grow, lets text fill the rest */
.about-illustration {
    display: flex;
    justify-content: center;
    flex: 0 0 auto;
}

.about-illustration img {
    max-width: 320px;
    width: 100%;
}

/* ── Tools band ── */
.tools-band {
    background: var(--color-gray-light);
    padding: 56px 0;
}

.tools-band .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 60px;
    /* no flex-wrap — heading stays left, icons stay right on desktop */
}

.tools-heading {
    font-size: 26px;
    font-weight: 700;
    white-space: nowrap;
}

.tool-icons {
    display: flex;
    gap: 14px;
    align-items: center;
    flex-wrap: nowrap; /* keep all icons on one line on desktop */
}

img.tool-icon {
    width: 60px;
    height: 60px;
    object-fit: contain;
    border-radius: 8px;
    display: block;
    flex-shrink: 0;
}

/* ── Timeline ── */
.timeline {
    padding: 72px 0 72px;
}

/* Same scrolling track pattern as testimonials */
.timeline-track {
    display: flex;
    justify-content: center; /* JS switches to flex-start when marquee activates */
    gap: 48px;
    overflow-x: hidden;
    padding: 4px 40px 24px;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.timeline-track::-webkit-scrollbar {
    display: none;
}

/* Individual period column */
.timeline-item {
    flex: 0 0 230px;
}

.timeline-year {
    font-size: 17px;
    font-weight: 700;
    color: var(--color-red);
    margin-bottom: 18px;
    white-space: nowrap;
}

.timeline-events {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Each event with a small red dot */
.timeline-events li {
    font-size: 15px;
    font-weight: 400;
    line-height: 1.5;
    color: var(--color-dark);
    padding-left: 16px;
    position: relative;
}

.timeline-events li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 7px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--color-red);
    flex-shrink: 0;
}

/* ── Footer CTA link (about page override) ── */
.footer-cta-link {
    color: var(--color-white);
    text-decoration: underline;
    text-underline-offset: 3px;
    font-style: italic;
    transition: opacity var(--transition);
}

.footer-cta-link:hover {
    opacity: 0.75;
}

/* ============================================================
   14. LIGHTBOX
   ——————————————————————————————————————————————————————————
   Full-screen image viewer triggered by clicking any gallery
   card (.logo-card or .illus-card). Built and controlled
   entirely by JS (main.js § 5) — no per-page HTML needed.

   Uses visibility + opacity so the fade-in/out can be
   CSS-transitioned (display:none can't be transitioned).
   ============================================================ */

.lightbox {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    /* Hidden state */
    visibility: hidden;
    opacity: 0;
    transition:
        opacity 0.2s ease,
        visibility 0.2s ease;
}

.lightbox.is-open {
    visibility: visible;
    opacity: 1;
}

/* The enlarged image */
.lightbox-img {
    max-width: min(90vw, 1000px);
    max-height: 85vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 8px;
    display: block;
    user-select: none;
    /* Subtle scale-in when opening */
    transition: transform 0.2s ease;
    transform: scale(0.96);
}

.lightbox.is-open .lightbox-img {
    transform: scale(1);
}

/* Shared styles for all three control buttons */
.lightbox-btn {
    position: absolute;
    background: rgba(255, 255, 255, 0.12);
    border: none;
    color: #fff;
    cursor: pointer;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
}

.lightbox-btn:hover {
    background: rgba(255, 255, 255, 0.28);
}
.lightbox-btn:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 2px;
}

.lightbox-btn svg {
    width: 22px;
    height: 22px;
    stroke: currentColor;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    fill: none;
    display: block;
}

/* Close — top-right corner */
.lightbox-close {
    top: 16px;
    right: 16px;
}

/* Prev / Next — vertically centred on the sides */
.lightbox-prev {
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
}

.lightbox-next {
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
}

/* Hide arrows when there is only one image */
.lightbox.single .lightbox-prev,
.lightbox.single .lightbox-next {
    display: none;
}

/* Gallery and case study cards get a zoom cursor */
.logo-card,
.illus-card,
.pages-strip-card {
    cursor: zoom-in;
}

/* ============================================================
   15. RESPONSIVE / MOBILE
   ============================================================ */

/* ── Tablet (≤768px) ── */
@media (max-width: 768px) {
    :root {
        --section-pad: 64px;
        --container-pad: 20px;
    }

    main {
        padding-top: 32px;
    }

    .heading-display {
        font-size: clamp(1.75rem, 6vw, 2.4rem);
    }

    body {
        font-size: 17px;
    }

    /* Stack hero vertically; mascot goes above text */
    .hero .two-col {
        flex-direction: column;
        gap: 36px;
    }

    .hero-image {
        order: -1;
    }

    .hero-image img {
        max-width: 200px;
    }

    .hero-body {
        max-width: 100%;
        text-align: center;
    }

    .btn-group {
        justify-content: center;
    }

    /* 2-column masonry on tablet */
    .logos-grid {
        columns: 2;
    }

    .testimonial-card {
        flex: 0 0 290px;
    }

    .testimonials-track {
        padding-left: 20px;
        padding-right: 20px;
    }

    /* About page — stack bio vertically on tablet */
    .about-hero .two-col {
        flex-direction: column;
        gap: 36px;
    }

    .about-illustration {
        order: -1; /* illustration above text on mobile */
    }

    .about-illustration img {
        max-width: 220px;
    }

    .tools-band .container {
        flex-direction: column;
        text-align: center;
        gap: 24px;
    }

    .tool-icons {
        justify-content: center;
        flex-wrap: wrap; /* allow wrapping on small screens */
    }
    img.tool-icon {
        max-width: 60px;
    }
    .timeline-track {
        padding-left: 20px;
        padding-right: 20px;
    }

    /* Stack footer CTA on small screens */
    .footer-cta .container {
        flex-direction: column;
        text-align: center;
    }

    .social-links {
        justify-content: center;
    }

    .footer-bar .container {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
}

/* ── Mobile navigation (≤700px) ──
   Switches from centered pill bar to hamburger + dropdown.
   ─────────────────────────────────────────────────────── */
@media (max-width: 700px) {
    /* Header becomes a flex row: logo left, hamburger right */
    .site-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 16px var(--container-pad);
        text-align: left;
    }

    .site-logo {
        margin-bottom: 0;
    }

    .site-logo img {
        width: 120px;
    }

    /* Reveal hamburger button */
    .nav-hamburger {
        display: flex;
    }

    /* Nav hidden by default; JS adds .is-open to reveal it */
    .site-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        z-index: 200;
        background: var(--color-white);
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        padding: 20px var(--container-pad) 24px;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    }

    .site-nav.is-open {
        display: flex;
    }

    /* Nav pills become a vertical list */
    .nav-pills {
        flex-direction: column;
        border-radius: 12px;
        width: 100%;
        padding: 8px;
        gap: 2px;
    }

    .nav-link {
        border-radius: 8px;
        text-align: left;
        padding: 11px 16px;
        font-size: 15px;
    }

    /* EN button full-width, text centered via flex */
    .nav-lang {
        display: flex;
        justify-content: center;
        border-radius: 8px;
        padding: 12px 16px;
        width: 100%;
        font-size: 15px;
    }
}

/* ── Small phones (≤480px) ── */
@media (max-width: 480px) {
    /* Single-column masonry on phones */
    .logos-grid,
    .logos-grid--2col {
        columns: 1;
    }

    .pages-strip {
        grid-template-columns: 1fr;
    }

    .pages-strip-card img {
        height: 320px;
    }
}

/* ============================================================
   ÉDITION PAGE — Alternating text / image project rows
   ——————————————————————————————————————————————————————————
   Each .edition-project is a two-column row:
     odd  rows: text left  / image right
     even rows: image left / text right  (reversed via CSS)
   ============================================================ */

.edition-list {
    padding: 48px 0 96px;
    display: flex;
    flex-direction: column;
    gap: 80px; /* breathing room between projects */
}

.edition-project {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: center;
}

/* Even rows: swap image to left by reversing column order */
.edition-project:nth-child(even) {
    direction: rtl; /* flip child order */
}

.edition-project:nth-child(even) > * {
    direction: ltr; /* restore text direction inside children */
}

/* ── Text side (shared with UX/UI page) ── */
.edition-text,
.uxui-text {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.edition-title,
.uxui-title {
    font-size: 22px;
    font-weight: 700;
    line-height: 1.25;
    color: var(--color-dark);
}

.edition-desc,
.uxui-desc {
    font-size: 16px;
    font-weight: 400;
    line-height: 1.6;
    color: var(--color-dark);
}

.edition-tags,
.uxui-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 4px;
}

/* ── Image side ── */
.edition-image {
    background: var(--color-gray-light);
    border-radius: 16px;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    display: flex;
    align-items: center;
    justify-content: center;
}

.edition-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Inline hyperlink inside description text (e.g. "rebrand complet") */
.link-inline {
    color: var(--color-dark);
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color var(--transition);
}

.link-inline:hover {
    color: var(--color-red);
}

/* ── Responsive: stack on tablet ── */
@media (max-width: 768px) {
    .edition-project {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    /* Reset the direction trick on small screens */
    .edition-project:nth-child(even) {
        direction: ltr;
    }

    /* Image always appears above text on mobile */
    .edition-image {
        order: -1;
    }

    .edition-list {
        gap: 56px;
    }
}

/* ============================================================
   UX/UI (WEB) PAGE
   ——————————————————————————————————————————————————————————
   Two sections:
   1. Featured case studies — alternating layout inside gray cards
   2. Additional work grid — 3-column screenshot grid
   ============================================================ */

/* ── Featured case studies ── */
.uxui-featured {
    padding: 48px 0 64px;
    display: flex;
    flex-direction: column;
    gap: 32px;
}

/* Gray card wrapping each featured project */
.uxui-case {
    background: var(--color-gray-light);
    border-radius: 20px;
    padding: 48px 52px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: center;
}

/* Even cards: image left / text right */
.uxui-case:nth-child(even) {
    direction: rtl;
}

.uxui-case:nth-child(even) > * {
    direction: ltr;
}

/* Text side — shares rules with .edition-text/title/desc/tags (see Édition section) */

/* Image side — drop shadow so laptop mockup floats */
.uxui-image {
    display: flex;
    align-items: center;
    justify-content: center;
}

.uxui-image img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    object-fit: cover;
}

/* Videos blend into the gray card background — white areas become transparent */
.uxui-image video {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    object-fit: cover;
    mix-blend-mode: multiply;
}

/* ── Additional work grid ── */
.uxui-grid-section {
    padding: 0 0 96px;
}

.uxui-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.uxui-grid-item {
    border-radius: 12px;
    overflow: hidden;
    background: var(--color-gray-light);
    aspect-ratio: 4 / 3;
    display: block; /* works as both <div> and <a> */
    text-decoration: none;
    box-shadow: 0 0px 0px rgba(0, 0, 0, 0.1);
    transition:
        box-shadow var(--transition),
        transform var(--transition);
}

.uxui-grid-item:hover {
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.18);
    transform: translateY(-2px);
}

.uxui-grid-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
    display: block;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .uxui-case {
        grid-template-columns: 1fr;
        gap: 28px;
        padding: 32px 28px;
    }

    .uxui-case:nth-child(even) {
        direction: ltr;
    }

    .uxui-image {
        order: -1;
    }

    .uxui-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

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

/* ============================================================
   CASE STUDY PAGES
   ——————————————————————————————————————————————————————————
   Shared layout for broady-windsor.html, proship.html, etc.

   .case-layout .container overrides max-width to 720px —
   narrower than the standard 960px for reading-heavy content.
   The full-width .pages-strip-band sits outside .case-layout
   so it isn't constrained.
   ============================================================ */

/* Narrow container for case study pages — better reading line length */
.case-layout .container {
    max-width: 720px;
}

/* ── Hero ── */
.case-hero {
    padding: 48px 0 40px;
    text-align: center;
}

.case-hero-title {
    font-size: clamp(32px, 5vw, 52px);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 16px;
}

.case-hero-meta {
    font-size: 15px;
    font-weight: 400;
    color: var(--color-text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0 12px;
}

.case-hero-meta span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

/* Pipe divider between meta items */
.case-hero-meta span + span::before {
    content: "|";
    color: var(--color-border);
}

/* ── Hero image ── */
.case-hero-image {
    padding: 0 0 64px;
}

.case-hero-image img {
    width: 100%;
    max-width: 760px;
    height: auto;
    display: block;
    margin: 0 auto;
}

/* ── Content sections ── */
.case-section {
    padding: 0 0 56px;
}

.case-section-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 16px;
}

.case-section-body {
    font-size: 16px;
    font-weight: 400;
    line-height: 1.7;
    color: var(--color-dark);
    width: 100%;
    display: block;
}

/* ── Gray card for diagrams / screenshots ── */
.case-card {
    background: var(--color-gray-light);
    border-radius: 16px;
    overflow: hidden;
    margin-top: 32px;
}

.case-card img {
    width: 100%;
    height: auto;
    display: block;
}

/* ── Full-page screenshots grid ── */
.pages-strip-band {
    background: var(--color-gray-light);
    padding: 48px 0;
    margin: 8px 0 64px;
}

/* Centered grid — 4 cols, content stays ≤ ~1160px */
.pages-strip {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 40px;
}

/* Clickable card wrapper — mirrors .logo-card / .illus-card pattern */
.pages-strip-card {
    border-radius: 8px;
    overflow: hidden;
    cursor: zoom-in;
    box-shadow: 0 0px 0px rgba(0, 0, 0, 0.1);
    transition:
        transform var(--transition),
        box-shadow var(--transition);
}

.pages-strip-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.16);
}

/* Each thumbnail — fixed size, top of page visible, bottom cropped */
.pages-strip-card img {
    width: 100%;
    height: 480px;
    object-fit: cover;
    object-position: top;
}

/* ── Two-column card row — personas, before/after comparisons ── */
.case-2col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-top: 32px;
}

.case-2col .case-card {
    margin-top: 0;
}

/* Extra breathing room when a paragraph follows a card row */
.case-2col + .case-section-body {
    margin-top: 32px;
}

/* ── Full-bleed video — slider demos, screen recordings ── */
.case-video {
    margin-top: 32px;
    border-radius: 16px;
    overflow: hidden;
    background: var(--color-dark);
}

.case-video video {
    width: 100%;
    display: block;
}

/* ── Impact section ── */
.case-impact {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 48px;
    padding: 0 0 96px;
}

.case-impact-text {
    flex: 1;
    max-width: 560px;
}

.case-impact-text .case-section-title {
    margin-bottom: 12px;
}

.case-impact-action {
    flex-shrink: 0;
    padding-top: 6px; /* align button roughly with first line of text */
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .case-layout .container {
        padding-left: 24px;
        padding-right: 24px;
    }

    .case-hero {
        padding: 32px 0 28px;
        text-align: left;
    }

    .case-hero-meta {
        justify-content: flex-start;
    }

    .pages-strip {
        grid-template-columns: repeat(2, 1fr);
        padding: 0 24px;
    }

    .pages-strip-card img {
        height: 360px;
    }

    .case-2col {
        grid-template-columns: 1fr;
    }

    .case-impact {
        flex-direction: column;
        gap: 24px;
    }
}
